Files
twenty/packages/twenty-docs/l/ja/twenty-ui/input/radio.mdx
T
Félix Malfait 5d438bb70c Docs: restructure navigation, add halftone illustrations, clean up hero images (#19728)
## Summary

- **New Getting Started section** with quickstart guide and restructured
navigation
- **Halftone-style illustrations** for User Guide and Developer
introduction cards using a Canvas 2D filter script
- **Removed hero images** (`image:` frontmatter + `<Frame><img>` blocks)
from all user-guide article pages
- **Cleaned up translations** (13 languages): removed hero images and
updated introduction cards to use halftone style
- **Cleaned up twenty-ui pages**: removed outdated hero images from
component docs
- **Deleted orphaned images**: `table.png`, `kanban.png`
- **Developer page**: fixed duplicate icon, switched to 3-column layout

## Test plan

- [ ] Verify docs site builds without errors
- [ ] Check User Guide introduction page renders halftone card images in
both light and dark mode
- [ ] Check Developer introduction page renders 3-column layout with
distinct icons
- [ ] Confirm article pages no longer show hero images at the top
- [ ] Spot-check a few translated pages to ensure hero images are
removed

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2026-04-21 09:13:55 +02:00

97 lines
4.2 KiB
Plaintext

---
title: ラジオ
---
<Frame>
<img src="/images/user-guide/create-workspace/workspace-cover.png" alt="ヘッダー" />
</Frame>
ユーザーが一連の選択肢の中から 1 つのオプションのみを選ぶことができるときに使用されます。
<Tabs>
<Tab title="使用方法">
```jsx
import { Radio } from "twenty-ui/display";
export const MyComponent = () => {
const handleRadioChange = (event) => {
console.log("Radio button changed:", event.target.checked);
};
const handleCheckedChange = (checked) => {
console.log("Checked state changed:", checked);
};
return (
<Radio
checked={true}
value="Option 1"
onChange={handleRadioChange}
onCheckedChange={handleCheckedChange}
size="large"
disabled={false}
labelPosition="right"
/>
);
};
```
</Tab>
<Tab title="プロパティ">
| プロパティ | タイプ | 説明 |
| --------------- | ----------------- | ------------------------------------------------ |
| スタイル | `React.CSS` プロパティ | コンポーネントの追加インラインスタイル |
| className | string | 追加のスタイリング用のオプションのCSSクラス |
| checked | ブール型 | ラジオボタンが選択されているかどうかを示す |
| 値 | string | ラジオボタンに関連付けられたラベルまたはテキスト |
| onChange | 関数 | 選択したラジオボタンが変更されたときに呼ばれる関数 |
| onCheckedChange | 関数 | ラジオボタンの「checked」状態が変更されたときに呼び出される関数 |
| サイズ | string | ラジオボタンのサイズ。 オプションには、`large` と `small` があります |
| disabled | ブール型 | 「true」の場合、ラジオボタンは無効になり、クリックできなくなります |
| ラベルの位置 | string | ラジオボタンに対するラベルテキストの位置。 2 つのオプション:`left` と `right` |
</Tab>
</Tabs>
## ラジオグループ
関連するラジオボタンをまとめます。
<Tabs>
<Tab title="使用方法">
```jsx
import React, { useState } from "react";
import { Radio, RadioGroup } from "twenty-ui/display";
export const MyComponent = () => {
const [selectedValue, setSelectedValue] = useState("Option 1");
const handleChange = (event) => {
setSelectedValue(event.target.value);
};
return (
<RadioGroup value={selectedValue} onChange={handleChange}>
<Radio value="Option 1" />
<Radio value="Option 2" />
<Radio value="Option 3" />
</RadioGroup>
);
};
```
</Tab>
<Tab title="プロパティ">
| プロパティ | タイプ | 説明 |
| ------------- | ----------------- | ---------------------------------------------------------------------------------- |
| 値 | string | 現在選択されているラジオボタンの値 |
| onChange | 機能 | ラジオボタンが変更されたときにトリガーされるコールバック関数 |
| onValueChange | 機能 | グループ内の選択された値が変更されたときにトリガーされるコールバック関数。 |
| children | `React.ReactNode` | Allows you to pass React components (such as Radio) as children to the Radio Group |
</Tab>
</Tabs>