{/*
* _____ _
*|_ _|_ _____ _ __ | |_ _ _
* | | \ \ /\ / / _ \ '_ \| __| | | | Auto-generated file
* | | \ V V / __/ | | | |_| |_| | DO NOT EDIT - changes will be overwritten
* |_| \_/\_/ \___|_| |_|\__|\__, | Generated by: npx nx generate:ui twenty-docs
* |___/
*
* This file is generated from the documentation data in packages/twenty-ui/generated.
* To update it, edit the component prop types or design tokens in twenty-ui and run:
* npx nx generate:ui twenty-docs
*/}
### Slider.Root
CSS class applied to the element, or a function that
returns a class based on the component's state.
Color of the indicator and thumbs.
The uncontrolled value of the slider when it's initially rendered.
To render a controlled slider, use the `value` prop instead.
Whether the slider should ignore user interaction.
Identifies the form that owns the slider inputs.
Useful when the slider is rendered outside the form.
Options to format the value.
The granularity with which the slider can step through values when using Page Up/Page Down or Shift + Arrow Up/Arrow Down.
The locale used by `Intl.NumberFormat` when formatting the value.
Defaults to the user's runtime locale.
The maximum allowed value of the slider.
Should not be equal to min.
The minimum allowed value of the slider.
Should not be equal to max.
The minimum steps between values in a range slider.
Identifies the field when a form is submitted.
Callback function that is fired when the slider's value changed.
Receives the new value as the first argument; the originating event is
available as `eventDetails.event`. The value is also reflected on
`eventDetails.event.target.value` for form integration.
The `eventDetails.reason` indicates what triggered the change:
- `'input-change'` when the hidden range input emits a change event (for example, via form integration)
- `'track-press'` when the control track is pressed
- `'drag'` while dragging a thumb
- `'keyboard'` for keyboard input
- `'none'` when the change is triggered without a specific interaction
Callback function that is fired when a value change is committed.
Does not fire if the value did not change, or if the change was canceled.
**Warning**: This is a generic event, not a change event.
The `eventDetails.reason` indicates what triggered the commit:
- `'drag'` while dragging a thumb
- `'track-press'` when the control track is pressed
- `'keyboard'` for keyboard input
- `'input-change'` when the hidden range input emits a change event (for example, via form integration)
- `'none'` when the commit occurs without a specific interaction
The component orientation.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
The granularity with which the slider can step through values. (A "discrete" slider.)
The `min` prop serves as the origin for the valid values.
We recommend (max - min) to be evenly divisible by the step.
Style applied to the element, or a function that
returns a style object based on the component's state.
How the thumb(s) are aligned relative to `Slider.Control` when the value is at `min` or `max`:
- `center`: The center of the thumb is aligned with the control edge
- `edge`: The thumb is inset within the control such that its edge is aligned with the control edge
- `edge-client-only`: Same as `edge` but renders after React hydration on the client, reducing bundle size in return
Controls how thumbs behave when they collide during pointer interactions.
- `'push'` (default): Thumbs push each other without restoring their previous positions when dragged back.
- `'swap'`: Thumbs swap places when dragged past each other.
- `'none'`: Thumbs cannot move past each other; excess movement is ignored.
The value of the slider.
For range sliders, provide an array with one value per thumb.
### Slider.Control
CSS class applied to the element, or a function that
returns a class based on the component's state.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
Style applied to the element, or a function that
returns a style object based on the component's state.
### Slider.Track
CSS class applied to the element, or a function that
returns a class based on the component's state.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
Style applied to the element, or a function that
returns a style object based on the component's state.
### Slider.Indicator
CSS class applied to the element, or a function that
returns a class based on the component's state.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
Style applied to the element, or a function that
returns a style object based on the component's state.
### Slider.Thumb
A string value forwarded to the [`aria-valuetext`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-valuetext) attribute of the `input`.
Ignored when `getAriaValueText` is provided.
CSS class applied to the element, or a function that
returns a class based on the component's state.
Whether the thumb should ignore user interaction.
A function which returns a string value for the [`aria-label`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-label) attribute of the `input`.
A function which returns a string value for the [`aria-valuetext`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-valuetext) attribute of the `input`.
This is important for screen reader users.
The index of the thumb which corresponds to the index of its value in the
`value` or `defaultValue` array.
This prop is required to support server-side rendering for range sliders
with multiple thumbs.
A ref to access the nested input element.
A blur handler forwarded to the `input`.
A focus handler forwarded to the `input`.
A keydown handler forwarded to the `input`.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
Style applied to the element, or a function that
returns a style object based on the component's state.
Optional tab index attribute forwarded to the `input`.
### Slider.Label
CSS class applied to the element, or a function that
returns a class based on the component's state.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
Style applied to the element, or a function that
returns a style object based on the component's state.
### Slider.Value
CSS class applied to the element, or a function that
returns a class based on the component's state.
Allows you to replace the component's HTML element
with a different tag, or compose it with another component.
Accepts a `ReactElement` or a function that returns the element to render.
Style applied to the element, or a function that
returns a style object based on the component's state.