BetaBeta pública — Consulta las notas de lanzamiento
Documentación

Segmented Control

Mutually exclusive option selector with connected segments.

Paquete
@solidiom/segmented-control
Versión
0.6.0
Estado
experimental

Generado a partir del código fuente público del paquete.

API

Indicatorcomponente

                        Indicator(props: SegmentedControlIndicatorProps): Element
                      

Propiedades

class?
string — CSS class.
style?
string | CSSProperties — Inline styles.

hijos: Element

Ver código fuente

Itemcomponente

                        Item(props: SegmentedControlItemProps): Element
                      

Propiedades

class?
string — CSS class.
disabled?
boolean — Whether this item is disabled.
value
string — Unique identifier for this segment.

hijos: Element

Ver código fuente

Rootcomponente

                        Root(props: SegmentedControlRootProps): Element
                      

Propiedades

defaultValue?
string — Default value for uncontrolled mode.
disabled?
boolean — Whether all items are disabled.
id?
string — Element id.
loop?
boolean — Whether keyboard navigation wraps around. Default: true.
name?
string — Form field name for hidden radio inputs.
onValueChange?
(value: string, details: ChangeDetails<SegmentedControlReason>) => void — Called when the selected segment changes.
orientation?
"horizontal" | "vertical" — Orientation of the control. Default: "horizontal".
value?
Accessor<string | undefined> — Controlled value — the currently selected segment.

hijos: Element

Ver código fuente

SegmentedControlIndicatorPropsinterfaz

Propiedades

class?
string — CSS class.
style?
string | CSSProperties — Inline styles.

hijos: Element

Ver código fuente

SegmentedControlItemPropsinterfaz

Propiedades

class?
string — CSS class.
disabled?
boolean — Whether this item is disabled.
value
string — Unique identifier for this segment.

hijos: Element

Ver código fuente

SegmentedControlReasontipo

Reason for a segmented control value change.

Ver código fuente

SegmentedControlRootPropsinterfaz

Propiedades

defaultValue?
string — Default value for uncontrolled mode.
disabled?
boolean — Whether all items are disabled.
id?
string — Element id.
loop?
boolean — Whether keyboard navigation wraps around. Default: true.
name?
string — Form field name for hidden radio inputs.
onValueChange?
(value: string, details: ChangeDetails<SegmentedControlReason>) => void — Called when the selected segment changes.
orientation?
"horizontal" | "vertical" — Orientation of the control. Default: "horizontal".
value?
Accessor<string | undefined> — Controlled value — the currently selected segment.

hijos: Element

Ver código fuente