Files
twenty/packages/twenty-docs/l/vi/twenty-ui/input/toggle.mdx
T
github-actions[bot] 8cadd00d34 i18n - translations (#15799)
Created by Github action

---------

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: github-actions <github-actions@twenty.com>
2025-11-13 16:34:00 +01:00

40 lines
1.6 KiB
Plaintext

---
title: Chuyển đổi
image: /images/user-guide/table-views/table.png
---
<Frame>
<img src="/images/user-guide/table-views/table.png" alt="Header" />
</Frame>
<Tabs>
<Tab title="Usage">
```jsx
import { Toggle } from "twenty-ui/input";
export const MyComponent = () => {
return (
<Toggle
value = {true}
onChange = {()=>console.log('On Change event')}
color="green"
toggleSize = "medium"
/>
);
};
```
</Tab>
<Tab title="Props">
| Thuộc Tính | Loại | Mô tả | Mặc định |
| --------------------- | ------- | --------------------------------------------------------------------------------------------------------------------------------------- | ----------- |
| giá trị | boolean | The current state of the toggle | `sai` |
| khi thay đổi | hàm | Callback function triggered when the toggle state changes | |
| màu sắc | string | Màu của chuyển đổi khi nó | là màu xanh |
| kích thước chuyển đổi | string | Kích thước của chuyển đổi, ảnh hưởng cả chiều cao và chiều rộng. Có hai tùy chọn: `nhỏ` và `trung bình` | vừa |
</Tab>
</Tabs>