Created by Github action --------- Co-authored-by: Crowdin Bot <support+bot@crowdin.com> Co-authored-by: github-actions <github-actions@twenty.com>
40 lines
1.6 KiB
Plaintext
40 lines
1.6 KiB
Plaintext
---
|
|
title: Attiva/Disattiva
|
|
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">
|
|
|
|
| Props | Tipo | Descrizione | Predefinito |
|
|
| ---------------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------- |
|
|
| valore | booleano | Lo stato attuale dell'interruttore | `falso` |
|
|
| onChange | funzione | Funzione di callback attivata quando lo stato dell'interruttore cambia | |
|
|
| colore | string | Colore dell'interruttore quando è | colore blu |
|
|
| dimensioneInterruttore | string | Size of the toggle, affecting both height and weight. Ha due opzioni: `small` e `medium`. | medio |
|
|
|
|
</Tab>
|
|
</Tabs>
|