For AI agents: the complete documentation index is available at https://a3s-lab.github.io/UI/v0.4.1/en/llms.txt, the full documentation bundle is available at https://a3s-lab.github.io/UI/v0.4.1/en/llms-full.txt, and this page is available as Markdown at https://a3s-lab.github.io/UI/v0.4.1/en/components/context-selector.md.

Context Selector

Context Selector provides one compact contract for model, permission, and workspace choices. Native Select is preferred when options fit ordinary selection behavior.

Live preview

Usage

<label class="context-selector" data-kind="workspace">
  <span data-context-label>Workspace</span>
  <select aria-label="Workspace"><option>A3S UI</option></select>
  <span data-context-description>Files and task history stay scoped here.</span>
</label>

Parameters

APIValuesPurpose
data-kindmodel, permission, workspaceChoice semantics
Native <select>PreferredOrdinary finite choice
button[aria-haspopup]OptionalRich searchable anchored menu
data-context-descriptionRecommendedConsequence of the choice

States and variants

Unavailable choices remain visible with their reason when that helps users recover. Do not imply that a visual selection grants permission.

Accessibility

Use a native label and control name. Anchored menus restore focus to their trigger and constrain themselves to the viewport.