Select
Choose one option from a list.
Recommended API
| Property or element | Type | Example initial value | Description |
|---|---|---|---|
name | Form field name | delivery | Name the selected value for form submission. |
<option value> | Option and value | standard, express, pickup | Set the submitted value for each visible label. |
States
| State | Trigger | Result |
|---|---|---|
opened | Activate the select control. | The system opens its option list. |
selected | Choose an option. | The field shows the selected label and holds its value. |
Svelte implementation guidance
Choose one delivery option with a native select. Keyboard navigation and popup presentation follow the browser.
Use the supplied svelte example as a starting point. Preserve the native control semantics, labels, keyboard behavior and project conventions. Verify with keyboard and the target browser.
CSS variables
| Variable | Type | Default | Description |
|---|---|---|---|
--q-text | color | #28302a | Main text and foreground color. |
--q-muted | color | #70776f | Color for secondary text. |
--q-font-size | length | 13px | Base size for the component text. |
--q-accent | color | #344e41 | Accent for active controls, indicators and focus. |
--q-surface | color | #ffffff | Surface for controls and cards. |
--q-border | color | #dce0d8 | Color for outlines and dividers. |
--q-radius | length | 10px | Base corner radius. |
--q-gap | length | calc(var(--q-space) * 2) | Space between items, based on the spacing unit. |
--q-control-px | length | calc(var(--q-space) * 4) | Horizontal padding for controls. |
--q-control-py | length | calc(var(--q-space) * 2.5) | Vertical padding for controls. |
--q-space | length | 4px | Base unit for gaps and padding. |