AnyLumino
API referenceastryxsurfaces

SelectableCard

Render an Astryx card with a selected state.

Astryx Props

JSON-safe SelectableCard props forwarded to Astryx.

Supported Astryx props include:

  • label (string; required): Accessibility label.
  • isSelected (boolean; required): Controlled selection state.
  • onChange ((isSelected: boolean) => void; required): Called when toggled.
  • isDisabled (boolean): Disables the card.
  • children (ReactNode): Card content.
  • padding (SpacingStep): Inner padding.
  • variant ('default' or 'transparent' or 'muted' or 'blue' or 'cyan' or 'gray' or 'green' or 'orange' or 'pink' or 'purple' or 'red' or 'teal' or 'yellow'): Background color variant.
  • width (SizeValue): Card width.
  • height (SizeValue): Card height.
  • maxWidth (SizeValue): Maximum card width.
  • xstyle (StyleXStyles): StyleX styles for layout customization (margins, positioning, sizing). Must be a stylex.create() value, not an inline style object like style={{}}.

Props typed as React nodes, render functions, event handlers, refs, or StyleX styles are documented for Astryx parity but cannot be serialized directly from Python unless the wrapper adapts them.

See Astryx component docs: https://astryx.atmeta.com/components/SelectableCard.

Functions

constructor__init__(children=None, value=False, *, label, variant='default', disabled=False, padding=None, width=None, height=None, max_width=None, **props) -> None
paramchildrenChildInput
= None

Child widget, sequence of widgets, or mapping of slot names to widgets.

paramvaluebool
= False

Synchronized component value.

paramlabelstr

Visible or accessible label for the component.

paramvariantstr
= 'default'

Astryx visual variant.

paramdisabledbool
= False

Whether the card is disabled.

parampaddingint | float | None
= None

Inner padding using the Astryx spacing scale.

paramwidthint | float | str | None
= None

Card width.

paramheightint | float | str | None
= None

Card height.

parammax_widthint | float | str | None
= None

Maximum card width.

parampropsAny
= {}

Returns

None

On this page