@tanrei/mcp 0.1.0-next.0 → 0.1.0-next.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (224) hide show
  1. package/NOTICE +4 -5
  2. package/README.md +21 -6
  3. package/bin/tanrei-mcp.js +3 -3
  4. package/dist/server.js +2218 -711
  5. package/dist/vocabulary/docs/governance/mimicry-gaps.json +95 -21
  6. package/dist/vocabulary/packages/tokens-build/generated/component-catalog.json +1825 -0
  7. package/dist/vocabulary/specs/accordion.spec.json +1 -0
  8. package/dist/vocabulary/specs/app-bar.spec.json +1 -0
  9. package/dist/vocabulary/specs/app-shell.spec.json +1 -0
  10. package/dist/vocabulary/specs/avatar.spec.json +1 -0
  11. package/dist/vocabulary/specs/badge.spec.json +1 -0
  12. package/dist/vocabulary/specs/bottom-sheet.spec.json +1 -0
  13. package/dist/vocabulary/specs/breadcrumbs.spec.json +1 -0
  14. package/dist/vocabulary/specs/button-group.spec.json +1 -0
  15. package/dist/vocabulary/specs/button-with-menu.spec.json +1 -0
  16. package/dist/vocabulary/specs/button.spec.json +1 -0
  17. package/dist/vocabulary/specs/calendar.spec.json +1 -0
  18. package/dist/vocabulary/specs/callout.spec.json +1 -0
  19. package/dist/vocabulary/specs/card.spec.json +1 -0
  20. package/dist/vocabulary/specs/carousel.spec.json +1 -0
  21. package/dist/vocabulary/specs/chat-composer.spec.json +1 -0
  22. package/dist/vocabulary/specs/checkbox-group.spec.json +1 -0
  23. package/dist/vocabulary/specs/checkbox.spec.json +1 -0
  24. package/dist/vocabulary/specs/chip-field.spec.json +1 -0
  25. package/dist/vocabulary/specs/chip.spec.json +1 -0
  26. package/dist/vocabulary/specs/code-block.spec.json +1 -0
  27. package/dist/vocabulary/specs/color-field.spec.json +1 -0
  28. package/dist/vocabulary/specs/color-input.spec.json +1 -0
  29. package/dist/vocabulary/specs/combobox-field.spec.json +1 -0
  30. package/dist/vocabulary/specs/combobox.spec.json +1 -0
  31. package/dist/vocabulary/specs/component.schema.json +1 -0
  32. package/dist/vocabulary/specs/copy-button.spec.json +1 -0
  33. package/dist/vocabulary/specs/date-time-picker.spec.json +1 -0
  34. package/dist/vocabulary/specs/description-list.spec.json +1 -0
  35. package/dist/vocabulary/specs/dialog.spec.json +1 -0
  36. package/dist/vocabulary/specs/divider.spec.json +1 -0
  37. package/dist/vocabulary/specs/drop-zone.spec.json +1 -0
  38. package/dist/vocabulary/specs/embedded-text-input.spec.json +1 -0
  39. package/dist/vocabulary/specs/empty-state.spec.json +1 -0
  40. package/dist/vocabulary/specs/fab-menu.spec.json +1 -0
  41. package/dist/vocabulary/specs/field-group.spec.json +1 -0
  42. package/dist/vocabulary/specs/field.spec.json +1 -0
  43. package/dist/vocabulary/specs/figure.spec.json +1 -0
  44. package/dist/vocabulary/specs/file-item.spec.json +1 -0
  45. package/dist/vocabulary/specs/file-picker.spec.json +1 -0
  46. package/dist/vocabulary/specs/file-upload.spec.json +1 -0
  47. package/dist/vocabulary/specs/handle.spec.json +1 -0
  48. package/dist/vocabulary/specs/image-preview.spec.json +1 -0
  49. package/dist/vocabulary/specs/inline-code.spec.json +1 -0
  50. package/dist/vocabulary/specs/inventory.json +1 -0
  51. package/dist/vocabulary/specs/keyboard-shortcut.spec.json +1 -0
  52. package/dist/vocabulary/specs/link-card.spec.json +1 -0
  53. package/dist/vocabulary/specs/link.spec.json +1 -0
  54. package/dist/vocabulary/specs/list-row.spec.json +1 -0
  55. package/dist/vocabulary/specs/list.spec.json +1 -0
  56. package/dist/vocabulary/specs/loading-indicator.spec.json +1 -0
  57. package/dist/vocabulary/specs/main-action-button.spec.json +1 -0
  58. package/dist/vocabulary/specs/marquee-text.spec.json +1 -0
  59. package/dist/vocabulary/specs/menu.spec.json +1 -0
  60. package/dist/vocabulary/specs/menubar.spec.json +1 -0
  61. package/dist/vocabulary/specs/meter.spec.json +1 -0
  62. package/dist/vocabulary/specs/modal-layer.spec.json +1 -0
  63. package/dist/vocabulary/specs/navigation-bar.spec.json +1 -0
  64. package/dist/vocabulary/specs/navigation-drawer.spec.json +1 -0
  65. package/dist/vocabulary/specs/number-field.spec.json +1 -0
  66. package/dist/vocabulary/specs/number-input.spec.json +1 -0
  67. package/dist/vocabulary/specs/number-ticker.spec.json +1 -0
  68. package/dist/vocabulary/specs/one-time-code-field.spec.json +1 -0
  69. package/dist/vocabulary/specs/one-time-code-input.spec.json +1 -0
  70. package/dist/vocabulary/specs/page-header.spec.json +1 -0
  71. package/dist/vocabulary/specs/pagination.spec.json +1 -0
  72. package/dist/vocabulary/specs/popover.spec.json +1 -0
  73. package/dist/vocabulary/specs/previous-next-links.spec.json +1 -0
  74. package/dist/vocabulary/specs/progress-indicator.spec.json +1 -0
  75. package/dist/vocabulary/specs/prose.spec.json +1 -0
  76. package/dist/vocabulary/specs/radio-button.spec.json +1 -0
  77. package/dist/vocabulary/specs/radio-group.spec.json +1 -0
  78. package/dist/vocabulary/specs/rating.spec.json +1 -0
  79. package/dist/vocabulary/specs/resizable-frame.spec.json +1 -0
  80. package/dist/vocabulary/specs/scroll-area.spec.json +1 -0
  81. package/dist/vocabulary/specs/search.spec.json +1 -0
  82. package/dist/vocabulary/specs/segmented-button.spec.json +1 -0
  83. package/dist/vocabulary/specs/select-field.spec.json +1 -0
  84. package/dist/vocabulary/specs/select.spec.json +1 -0
  85. package/dist/vocabulary/specs/side-sheet.spec.json +1 -0
  86. package/dist/vocabulary/specs/size-transition.spec.json +1 -0
  87. package/dist/vocabulary/specs/skeleton.spec.json +1 -0
  88. package/dist/vocabulary/specs/slider-field.spec.json +1 -0
  89. package/dist/vocabulary/specs/slider.spec.json +1 -0
  90. package/dist/vocabulary/specs/snackbar.spec.json +1 -0
  91. package/dist/vocabulary/specs/split-view.spec.json +1 -0
  92. package/dist/vocabulary/specs/stepper.spec.json +1 -0
  93. package/dist/vocabulary/specs/steps.spec.json +1 -0
  94. package/dist/vocabulary/specs/swatch.spec.json +1 -0
  95. package/dist/vocabulary/specs/switch.spec.json +1 -0
  96. package/dist/vocabulary/specs/tab-view.spec.json +1 -0
  97. package/dist/vocabulary/specs/table-of-contents.spec.json +1 -0
  98. package/dist/vocabulary/specs/table.spec.json +1 -0
  99. package/dist/vocabulary/specs/tabs.spec.json +1 -0
  100. package/dist/vocabulary/specs/tag-group.spec.json +1 -0
  101. package/dist/vocabulary/specs/tag.spec.json +1 -0
  102. package/dist/vocabulary/specs/text-field.spec.json +1 -0
  103. package/dist/vocabulary/specs/text-input.spec.json +1 -0
  104. package/dist/vocabulary/specs/timeline.spec.json +1 -0
  105. package/dist/vocabulary/specs/toolbar.spec.json +1 -0
  106. package/dist/vocabulary/specs/tooltip.spec.json +1 -0
  107. package/dist/vocabulary/specs/tree-view.spec.json +1 -0
  108. package/dist/vocabulary/tanrei.config.json +2 -1
  109. package/dist/vocabulary/tokens/comp/accordion.tokens.json +70 -47
  110. package/dist/vocabulary/tokens/comp/app-bar.tokens.json +99 -2
  111. package/dist/vocabulary/tokens/comp/app-shell.tokens.json +1 -1
  112. package/dist/vocabulary/tokens/comp/avatar.tokens.json +17 -5
  113. package/dist/vocabulary/tokens/comp/badge.tokens.json +2 -1
  114. package/dist/vocabulary/tokens/comp/bottom-sheet.tokens.json +143 -73
  115. package/dist/vocabulary/tokens/comp/breadcrumbs.tokens.json +3 -3
  116. package/dist/vocabulary/tokens/comp/button-group.tokens.json +26 -4
  117. package/dist/vocabulary/tokens/comp/button-with-menu.tokens.json +256 -28
  118. package/dist/vocabulary/tokens/comp/button.tokens.json +275 -22
  119. package/dist/vocabulary/tokens/comp/calendar.tokens.json +28 -18
  120. package/dist/vocabulary/tokens/comp/callout.tokens.json +55 -299
  121. package/dist/vocabulary/tokens/comp/card.tokens.json +3 -3
  122. package/dist/vocabulary/tokens/comp/carousel.tokens.json +70 -10
  123. package/dist/vocabulary/tokens/comp/chat-composer.tokens.json +37 -3
  124. package/dist/vocabulary/tokens/comp/checkbox.tokens.json +18 -22
  125. package/dist/vocabulary/tokens/comp/chip.tokens.json +67 -16
  126. package/dist/vocabulary/tokens/comp/code-block.tokens.json +15 -1
  127. package/dist/vocabulary/tokens/comp/combobox.tokens.json +202 -33
  128. package/dist/vocabulary/tokens/comp/copy-button.tokens.json +19 -2
  129. package/dist/vocabulary/tokens/comp/date-time-picker.tokens.json +66 -35
  130. package/dist/vocabulary/tokens/comp/description-list.tokens.json +45 -23
  131. package/dist/vocabulary/tokens/comp/dialog.tokens.json +95 -35
  132. package/dist/vocabulary/tokens/comp/drop-zone.tokens.json +151 -0
  133. package/dist/vocabulary/tokens/comp/embedded-text-input.tokens.json +2 -2
  134. package/dist/vocabulary/tokens/comp/field-group.tokens.json +21 -1
  135. package/dist/vocabulary/tokens/comp/field.tokens.json +33 -4
  136. package/dist/vocabulary/tokens/comp/figure.tokens.json +56 -2
  137. package/dist/vocabulary/tokens/comp/file-item.tokens.json +4 -4
  138. package/dist/vocabulary/tokens/comp/file-picker.tokens.json +3 -3
  139. package/dist/vocabulary/tokens/comp/file-upload.tokens.json +2 -7
  140. package/dist/vocabulary/tokens/comp/handle.tokens.json +343 -0
  141. package/dist/vocabulary/tokens/comp/image-preview.tokens.json +53 -23
  142. package/dist/vocabulary/tokens/comp/input-box.tokens.json +161 -26
  143. package/dist/vocabulary/tokens/comp/keyboard-shortcut.tokens.json +5 -3
  144. package/dist/vocabulary/tokens/comp/link-card.tokens.json +24 -4
  145. package/dist/vocabulary/tokens/comp/link.tokens.json +3 -3
  146. package/dist/vocabulary/tokens/comp/list-row.tokens.json +249 -0
  147. package/dist/vocabulary/tokens/comp/list.tokens.json +106 -225
  148. package/dist/vocabulary/tokens/comp/loading-indicator.tokens.json +13 -3
  149. package/dist/vocabulary/tokens/comp/main-action-button.tokens.json +96 -23
  150. package/dist/vocabulary/tokens/comp/marquee-text.tokens.json +110 -0
  151. package/dist/vocabulary/tokens/comp/menu.tokens.json +248 -43
  152. package/dist/vocabulary/tokens/comp/menubar.tokens.json +63 -12
  153. package/dist/vocabulary/tokens/comp/meter.tokens.json +173 -0
  154. package/dist/vocabulary/tokens/comp/modal-layer.tokens.json +69 -0
  155. package/dist/vocabulary/tokens/comp/navigation-bar.tokens.json +5 -36
  156. package/dist/vocabulary/tokens/comp/navigation-drawer.tokens.json +478 -122
  157. package/dist/vocabulary/tokens/comp/number-input.tokens.json +2 -2
  158. package/dist/vocabulary/tokens/comp/number-ticker.tokens.json +77 -0
  159. package/dist/vocabulary/tokens/comp/one-time-code-input.tokens.json +22 -7
  160. package/dist/vocabulary/tokens/comp/pagination.tokens.json +118 -79
  161. package/dist/vocabulary/tokens/comp/popover.tokens.json +84 -13
  162. package/dist/vocabulary/tokens/comp/previous-next-links.tokens.json +194 -0
  163. package/dist/vocabulary/tokens/comp/progress-indicator.tokens.json +14 -4
  164. package/dist/vocabulary/tokens/comp/prose.tokens.json +16 -0
  165. package/dist/vocabulary/tokens/comp/radio-button.tokens.json +16 -20
  166. package/dist/vocabulary/tokens/comp/rating.tokens.json +230 -0
  167. package/dist/vocabulary/tokens/comp/resizable-frame.tokens.json +166 -0
  168. package/dist/vocabulary/tokens/comp/scroll-area.tokens.json +99 -0
  169. package/dist/vocabulary/tokens/comp/search.tokens.json +144 -58
  170. package/dist/vocabulary/tokens/comp/segmented-button.tokens.json +75 -21
  171. package/dist/vocabulary/tokens/comp/select.tokens.json +168 -34
  172. package/dist/vocabulary/tokens/comp/side-sheet.tokens.json +60 -13
  173. package/dist/vocabulary/tokens/comp/size-transition.tokens.json +49 -0
  174. package/dist/vocabulary/tokens/comp/skeleton.tokens.json +5 -2
  175. package/dist/vocabulary/tokens/comp/slider.tokens.json +11 -10
  176. package/dist/vocabulary/tokens/comp/snackbar.tokens.json +81 -255
  177. package/dist/vocabulary/tokens/comp/split-view.tokens.json +52 -0
  178. package/dist/vocabulary/tokens/comp/stepper.tokens.json +538 -0
  179. package/dist/vocabulary/tokens/comp/swatch.tokens.json +208 -0
  180. package/dist/vocabulary/tokens/comp/switch.tokens.json +19 -18
  181. package/dist/vocabulary/tokens/comp/tab-view.tokens.json +5 -5
  182. package/dist/vocabulary/tokens/comp/table-of-contents.tokens.json +58 -33
  183. package/dist/vocabulary/tokens/comp/table.tokens.json +141 -30
  184. package/dist/vocabulary/tokens/comp/tabs.tokens.json +132 -44
  185. package/dist/vocabulary/tokens/comp/tag-group.tokens.json +15 -4
  186. package/dist/vocabulary/tokens/comp/tag.tokens.json +32 -8
  187. package/dist/vocabulary/tokens/comp/text-input.tokens.json +18 -88
  188. package/dist/vocabulary/tokens/comp/timeline.tokens.json +15 -19
  189. package/dist/vocabulary/tokens/comp/toolbar.tokens.json +121 -6
  190. package/dist/vocabulary/tokens/comp/tooltip.tokens.json +8 -32
  191. package/dist/vocabulary/tokens/comp/tree-view.tokens.json +136 -51
  192. package/dist/vocabulary/tokens/dial/dial.tokens.json +23 -3
  193. package/dist/vocabulary/tokens/fidelity/cupertino.fidelity.json +165 -0
  194. package/dist/vocabulary/tokens/fidelity/m3-like.fidelity.json +215 -5
  195. package/dist/vocabulary/tokens/fidelity/reference/androidx-material3.json +144 -0
  196. package/dist/vocabulary/tokens/fidelity/reference/apple-hig.json +196 -0
  197. package/dist/vocabulary/tokens/generated/cupertino/components.json +1749 -0
  198. package/dist/vocabulary/tokens/generated/cupertino/fidelity.json +162 -0
  199. package/dist/vocabulary/tokens/generated/m3-like/components.json +1761 -0
  200. package/dist/vocabulary/tokens/generated/m3-like/fidelity.json +182 -12
  201. package/dist/vocabulary/tokens/generated/tanrei/components.json +1764 -0
  202. package/dist/vocabulary/tokens/icon-sets/material-symbols.icon-set.json +2 -1
  203. package/dist/vocabulary/tokens/schema/system.schema.json +324 -35
  204. package/dist/vocabulary/tokens/sys/behavior.tokens.json +66 -1
  205. package/dist/vocabulary/tokens/sys/measure.tokens.json +105 -21
  206. package/dist/vocabulary/tokens/sys/motion.tokens.json +474 -2
  207. package/dist/vocabulary/tokens/sys/scroll-edge.tokens.json +50 -0
  208. package/dist/vocabulary/tokens/sys/shape.tokens.json +1 -1
  209. package/dist/vocabulary/tokens/sys/state.tokens.json +16 -3
  210. package/dist/vocabulary/tokens/sys/typescale.tokens.json +5 -5
  211. package/dist/vocabulary/tokens/systems/core.system.json +1889 -0
  212. package/dist/vocabulary/tokens/systems/cupertino.system.json +298 -79
  213. package/dist/vocabulary/tokens/{comp → systems/m3-like/comp}/fab-menu.tokens.json +5 -15
  214. package/dist/vocabulary/tokens/systems/m3-like.system.json +451 -125
  215. package/dist/vocabulary/tokens/systems/tanrei.system.json +619 -321
  216. package/dist/vocabulary/tokens/tanrei.resolver.json +48 -6
  217. package/package.json +22 -6
  218. package/dist/vocabulary/tokens/AGENTS.md +0 -15
  219. package/dist/vocabulary/tokens/comp/navigation-rail.tokens.json +0 -254
  220. package/dist/vocabulary/tokens/fidelity/m3-expressive-like.fidelity.json +0 -68
  221. package/dist/vocabulary/tokens/fidelity/reference/androidx-material3-buttons.json +0 -67
  222. package/dist/vocabulary/tokens/generated/m3-expressive-like/fidelity.json +0 -99
  223. package/dist/vocabulary/tokens/systems/m3-expressive-like.system.json +0 -83
  224. package/dist/vocabulary/tokens/vocabulary.lock.json +0 -7052
@@ -0,0 +1 @@
1
+ {"name":"select-field","title":"Select field","summary":"Lets people choose one value from a closed list as a field of a form: a label that can say the field is required or optional, a trigger that looks and measures like a text field's box and shows the chosen option, a list of options, optionally grouped, that opens from it, and a line of help or an error below.","level":"composed","listing":"default","builtFrom":["field","select"],"anatomy":[{"id":"field","description":"The Field: the label row with its glyph and its requirement mark, and the supporting row with the help and the error text. In a look whose select floats the label it draws no label row."},{"id":"select","description":"The select, as the Field's one control: the trigger with the value it shows, its leading icon and its chevron, the label that floats in it in the looks that float one, and the list of options that opens from it."}],"props":[{"name":"variant","from":"select.variant"},{"name":"size","from":"select.size"},{"name":"value","from":"select.value"},{"name":"label","from":"field.label","note":"Names the select. In a filled or outlined look the select draws it, floating in its box, and the Field draws no label row (FLD-25, SEL-15)."},{"name":"labelHidden","from":"field.labelHidden","note":"Hides the label wherever it would be drawn: the Field's row, or the select's floating label (FLD-25)."},{"name":"placeholder","from":"select.placeholder"},{"name":"supportingText","from":"field.supportingText"},{"name":"errorText","from":"field.errorText"},{"name":"error","from":"field.error","note":"The Field puts its select in the select's own error condition (FLD-8, SEL-9)."},{"name":"disabled","from":"field.disabled","note":"The Field disables its select (FLD-14, SEL-46); the select field is then left out of its form (SEF-2)."},{"name":"readOnly","from":"select.readOnly"},{"name":"clearable","from":"select.clearable"},{"name":"clearLabel","from":"select.clearLabel"},{"name":"required","from":"field.required","note":"The Field exposes its select as required (FLD-10, SEL-11)."},{"name":"optional","from":"field.optional"},{"name":"requiredMark","from":"field.requiredMark"},{"name":"requiredText","from":"field.requiredText"},{"name":"optionalText","from":"field.optionalText"},{"name":"open","from":"select.open"},{"name":"separation","from":"select.separation"},{"name":"iconSpace","from":"select.iconSpace"},{"name":"status","from":"select.status"},{"name":"statusText","from":"select.statusText"},{"name":"emptyText","from":"select.emptyText"}],"items":[{"name":"option","from":"select.option"},{"name":"option-group","from":"select.option-group"}],"slots":[{"name":"leading-icon","from":"select.leading-icon"},{"name":"label-icon","from":"field.label-icon"}],"events":[{"name":"change","from":"select.change"},{"name":"toggle","from":"select.toggle"}],"states":["enabled","disabled","hovered","focused","pressed","selected","error"],"behavior":[{"id":"SEF-1","text":"THE select field SHALL be a Field that frames one select, and nothing else. It SHALL give label, labelHidden, supportingText, errorText, error, disabled, required, optional, requiredMark, requiredText and optionalText to its Field and every other prop to its select, each unchanged; SHALL hold the label-icon slot for its Field and the leading-icon slot for its select; SHALL give its select every option and option group the product gives it, in the order given, as that select's own items, read, drawn and chosen by the select (SEL-17, SEL-31 to SEL-45); and SHALL emit its select's events as its own, each once. It SHALL draw no part of its own, hold no state of its own and have no token of its own: what it shows, how it behaves and what it exposes to assistive technology SHALL be exactly what that Field and that select do when a product places the one in the other (FLD-1 to FLD-28; SEL-1 to SEL-64) — the label row and its requirement mark (FLD-2 to FLD-6), or the label that floats in the box with the Field's row left out (FLD-25, SEL-15, SEL-7); the supporting row and the error, started where the value starts (FLD-7 to FLD-9, FLD-26); the rows drawn focused while the list is open (FLD-13, SEL-20); the name, the description and the states (FLD-10, FLD-11, FLD-14, SEL-11); and the width, which is the Field's and which the select fills (FLD-1, SEL-49)."},{"id":"SEF-2","text":"WHERE the platform has forms (the web) THE select field SHALL be the one control the form sees: it SHALL take name, submit its select's value, reset to the value it was first given, restore it on navigation, report to the form's constraint validation exactly what its select would report there (SEL-11), be submitted WHILE readOnly is true (SEL-47), and be left out WHILE disabled is true or a disabled group of the form holds it (SEL-46); its select and its Field SHALL take no part in the form themselves."},{"id":"SEF-3","text":"WHEN the select field is given focus — by the product, by a press on its label row (FLD-12), or by a form that reports its validity — THE select field SHALL pass the focus to its select's container and SHALL add no stop to the focus order: the one stop inside it is its select's (SEL-13). WHILE focus is anywhere inside it, or its select's list is open, THE select field SHALL count as focused for its Field (FLD-13)."},{"id":"SEF-4","text":"IF the select field is placed in a Field THE select field SHALL in debug builds report that it is a field already and that the bare control is the select, and both SHALL still render (FLD-15). WHILE it stands in a field group THE select field SHALL follow that group's disabled, through its own Field, and take nothing else from the group (FGR-20)."},{"id":"SEF-5","text":"THE select field SHALL have no words of its own and SHALL read none: requiredText and optionalText are read by its Field (FLD-24), emptyText by its select (SEL-62), each from the instance's prop and then from the product's words."},{"id":"SEF-6","text":"WHERE the platform has ARIA attributes (the web), WHEN the product sets an aria- attribute on the host, by the attribute or by the ARIA property that reflects it, THE select field SHALL move it to the data-aria- attribute of the same name, so that the host is no second node with its name, description or state, and SHALL expose it on the element that carries its role — an id reference by the elements it names in the host's tree or a tree around it, an error message as part of the description while the select field is invalid — except those the select field owns (aria-label, aria-labelledby, aria-disabled, aria-haspopup, aria-expanded, aria-controls), which it SHALL move and not expose: its name is label (SEF-1). WHEN the product removes the aria- attribute or its data-aria- twin, or sets the ARIA property that reflects it (ariaLabel, ariaDescribedByElements…) to null, THE select field SHALL take it off that element. WHEN the product sets an aria- attribute the select field owns THE select field SHALL report it in debug builds."}],"accessibility":{"role":"combobox","keyboard":[{"keys":"Every key","action":"The select's (its accessibility block; SEL-23, SEL-27, SEL-28, SEL-31, SEL-33, SEL-34). The select field handles no key and adds no focus stop (SEF-3)."}],"labeling":"The select field adds nothing to what its members expose and coordinates nothing: the Field gives the select its name, its description and its required, invalid and disabled states (FLD-8, FLD-10, FLD-11, FLD-14), and the select carries them on its own trigger and names its list by the same name (SEL-11, SEL-48). Assistive technology meets one control that opens a list of choices, named by label, with the chosen option's label as its value — exactly as it meets a Field around a select written by hand.","minimumTarget":true,"notes":["One level down is the same thing: a Field with a select in it, holding the same options. Every fixture has that pair as its twin, and the accessibility tree of the two is the same (SEF-1).","On the web the two members stand in the select field's own shadow root, so the form meets the select field and not the select (SEF-2), focus passes through to the trigger (SEF-3), and the options, which stay the product's children, reach the select through a slot and are read by it as data.","A select with no visible label of its own — in a header, a toolbar, a column of a table — is the bare select, named by its own label, not a select field with labelHidden."]},"tokens":"comp.field","fixtures":[{"id":"stacked-empty","props":{"variant":"stacked","label":"Country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-value","props":{"variant":"stacked","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-open","props":{"variant":"stacked","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-large","props":{"variant":"stacked","size":"large","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-small","props":{"variant":"stacked","size":"small","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-error","props":{"variant":"stacked","label":"Country","error":true,"errorText":"Choose a country."},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-disabled","props":{"variant":"stacked","label":"Country","value":"jp","disabled":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-empty","props":{"variant":"filled","label":"Country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-value","props":{"variant":"filled","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-open","props":{"variant":"filled","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-large","props":{"variant":"filled","size":"large","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-small","props":{"variant":"filled","size":"small","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-error","props":{"variant":"filled","label":"Country","error":true,"errorText":"Choose a country."},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-disabled","props":{"variant":"filled","label":"Country","value":"jp","disabled":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-empty","props":{"variant":"outlined","label":"Country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-value","props":{"variant":"outlined","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-open","props":{"variant":"outlined","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-large","props":{"variant":"outlined","size":"large","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-small","props":{"variant":"outlined","size":"small","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-error","props":{"variant":"outlined","label":"Country","error":true,"errorText":"Choose a country."},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-disabled","props":{"variant":"outlined","label":"Country","value":"jp","disabled":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-placeholder","props":{"label":"Country","placeholder":"Choose a country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-open-none-chosen","props":{"label":"Country","placeholder":"Choose a country","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-label-hidden","props":{"label":"Country","labelHidden":true,"value":"fr"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-supporting","props":{"label":"Country","value":"jp","supportingText":"Where your invoices are addressed."},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-error-value","props":{"label":"Country","value":"ke","error":true,"errorText":"We cannot ship there yet."},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-read-only","props":{"label":"Country","value":"jp","readOnly":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-required","props":{"label":"Country","required":true,"requiredText":"Required"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-optional","props":{"label":"Country","optional":true,"placeholder":"Choose a country","optionalText":"Optional"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-required-asterisk","props":{"label":"Country","required":true,"requiredMark":"asterisk"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-required-disabled","props":{"label":"Country","required":true,"value":"jp","disabled":true,"requiredText":"Required"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-required-error","props":{"label":"Country","required":true,"error":true,"errorText":"Choose a country.","requiredText":"Required"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-required-ja","props":{"label":"国","required":true,"requiredText":"必須","placeholder":"国を選択"},"items":[{"kind":"option","props":{"label":"日本","value":"jp"}},{"kind":"option","props":{"label":"カナダ","value":"ca"}},{"kind":"option","props":{"label":"フランス","value":"fr"}}]},{"id":"stacked-optional-ja","props":{"label":"国","optional":true,"optionalText":"任意","value":"jp"},"items":[{"kind":"option","props":{"label":"日本","value":"jp"}},{"kind":"option","props":{"label":"カナダ","value":"ca"}},{"kind":"option","props":{"label":"フランス","value":"fr"}}]},{"id":"outlined-required","props":{"variant":"outlined","label":"Country","required":true,"requiredText":"Required"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-label-icon","props":{"label":"Time zone","value":"Asia/Tokyo"},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}],"slots":{"label-icon":"schedule"}},{"id":"stacked-option-icon","props":{"label":"Theme","value":"dark"},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"stacked-leading-icon","props":{"label":"Language","value":"ja"},"items":[{"kind":"option","props":{"label":"English","value":"en"}},{"kind":"option","props":{"label":"日本語","value":"ja"}}],"slots":{"leading-icon":"translate"}},{"id":"open-icons","props":{"label":"Theme","value":"dark","open":true},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"open-supporting-text","props":{"label":"Plan","value":"team","open":true},"items":[{"kind":"option","props":{"label":"Free","value":"free","supportingText":"One project, community help"}},{"kind":"option","props":{"label":"Team","value":"team","supportingText":"Unlimited projects, shared roles"}},{"kind":"option","props":{"label":"Enterprise","value":"enterprise","supportingText":"Single sign-on and an audit log","disabled":true}}]},{"id":"open-disabled-chosen","props":{"label":"Plan","value":"enterprise","open":true},"items":[{"kind":"option","props":{"label":"Free","value":"free","supportingText":"One project, community help"}},{"kind":"option","props":{"label":"Team","value":"team","supportingText":"Unlimited projects, shared roles"}},{"kind":"option","props":{"label":"Enterprise","value":"enterprise","supportingText":"Single sign-on and an audit log","disabled":true}}]},{"id":"open-groups","props":{"label":"Time zone","value":"Europe/Lisbon","open":true},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}]},{"id":"open-groups-divider","props":{"label":"Time zone","value":"Europe/Lisbon","open":true,"separation":"divider"},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}]},{"id":"open-groups-gap","props":{"label":"Time zone","value":"Europe/Lisbon","open":true,"separation":"gap"},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}]},{"id":"open-many","props":{"label":"Token","value":"corner.small","open":true},"items":[{"kind":"option","props":{"label":"space25","value":"space25"}},{"kind":"option","props":{"label":"space50","value":"space50"}},{"kind":"option","props":{"label":"space75","value":"space75"}},{"kind":"option","props":{"label":"space100","value":"space100"}},{"kind":"option","props":{"label":"space125","value":"space125"}},{"kind":"option","props":{"label":"space150","value":"space150"}},{"kind":"option","props":{"label":"space175","value":"space175"}},{"kind":"option","props":{"label":"space200","value":"space200"}},{"kind":"option","props":{"label":"space250","value":"space250"}},{"kind":"option","props":{"label":"space300","value":"space300"}},{"kind":"option","props":{"label":"space400","value":"space400"}},{"kind":"option","props":{"label":"space500","value":"space500"}},{"kind":"option","props":{"label":"space600","value":"space600"}},{"kind":"option","props":{"label":"space800","value":"space800"}},{"kind":"option","props":{"label":"space1000","value":"space1000"}},{"kind":"option","props":{"label":"corner.none","value":"corner.none"}},{"kind":"option","props":{"label":"corner.extra-small","value":"corner.extra-small"}},{"kind":"option","props":{"label":"corner.small","value":"corner.small"}},{"kind":"option","props":{"label":"corner.medium","value":"corner.medium"}},{"kind":"option","props":{"label":"corner.large","value":"corner.large"}},{"kind":"option","props":{"label":"corner.extra-large","value":"corner.extra-large"}},{"kind":"option","props":{"label":"corner.full","value":"corner.full"}},{"kind":"option","props":{"label":"border.hairline","value":"border.hairline"}},{"kind":"option","props":{"label":"border.thick","value":"border.thick"}}]},{"id":"open-long-options","props":{"label":"Email me","value":"weekly","open":true},"items":[{"kind":"option","props":{"label":"Send me a summary once a week, on Monday morning, in the time zone of my account","value":"weekly"}},{"kind":"option","props":{"label":"Send me every notification as it happens, including the ones about threads I only follow","value":"all"}},{"kind":"option","props":{"label":"Never","value":"never"}}]},{"id":"long-value","props":{"label":"Email me","value":"all"},"items":[{"kind":"option","props":{"label":"Send me a summary once a week, on Monday morning, in the time zone of my account","value":"weekly"}},{"kind":"option","props":{"label":"Send me every notification as it happens, including the ones about threads I only follow","value":"all"}},{"kind":"option","props":{"label":"Never","value":"never"}}]},{"id":"empty-value-option","props":{"label":"Contrast","value":""},"items":[{"kind":"option","props":{"label":"Standard","value":""}},{"kind":"option","props":{"label":"Medium","value":"medium"}},{"kind":"option","props":{"label":"High","value":"high"}}]},{"id":"small-label-hidden","props":{"size":"small","label":"Contrast","labelHidden":true,"value":"high"},"items":[{"kind":"option","props":{"label":"Standard","value":""}},{"kind":"option","props":{"label":"Medium","value":"medium"}},{"kind":"option","props":{"label":"High","value":"high"}}]},{"id":"small-label-hidden-icons","props":{"size":"small","label":"Theme","labelHidden":true,"value":"light"},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"small-label-hidden-leading-icon","props":{"size":"small","label":"Language","labelHidden":true,"value":"en"},"items":[{"kind":"option","props":{"label":"English","value":"en"}},{"kind":"option","props":{"label":"日本語","value":"ja"}}],"slots":{"leading-icon":"translate"}},{"id":"small-label-hidden-open","props":{"size":"small","label":"Theme","labelHidden":true,"value":"light","open":true},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"small-open","props":{"size":"small","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-required-rtl","props":{"label":"المنطقة الزمنية","value":"Asia/Tokyo","required":true,"requiredText":"مطلوب","supportingText":"تُعرض المواعيد بهذا التوقيت."},"items":[{"kind":"option-group","props":{"title":"آسيا"},"items":[{"kind":"option","props":{"label":"طوكيو","value":"Asia/Tokyo","leadingIcon":"arrow_forward"}},{"kind":"option","props":{"label":"سنغافورة","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"أوروبا"},"items":[{"kind":"option","props":{"label":"برلين","value":"Europe/Berlin"}},{"kind":"option","props":{"label":"Lisbon (WET)","value":"Europe/Lisbon"}}]}],"direction":"rtl","slots":{"label-icon":"schedule"}},{"id":"open-rtl","props":{"label":"المنطقة الزمنية","value":"Asia/Tokyo","open":true},"items":[{"kind":"option-group","props":{"title":"آسيا"},"items":[{"kind":"option","props":{"label":"طوكيو","value":"Asia/Tokyo","leadingIcon":"arrow_forward"}},{"kind":"option","props":{"label":"سنغافورة","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"أوروبا"},"items":[{"kind":"option","props":{"label":"برلين","value":"Europe/Berlin"}},{"kind":"option","props":{"label":"Lisbon (WET)","value":"Europe/Lisbon"}}]}],"direction":"rtl"},{"id":"long-value-rtl","props":{"label":"Email me","value":"all"},"items":[{"kind":"option","props":{"label":"Send me a summary once a week, on Monday morning, in the time zone of my account","value":"weekly"}},{"kind":"option","props":{"label":"Send me every notification as it happens, including the ones about threads I only follow","value":"all"}},{"kind":"option","props":{"label":"Never","value":"never"}}],"direction":"rtl"},{"id":"outlined-rtl","props":{"variant":"outlined","label":"المنطقة الزمنية","value":"Europe/Lisbon"},"items":[{"kind":"option-group","props":{"title":"آسيا"},"items":[{"kind":"option","props":{"label":"طوكيو","value":"Asia/Tokyo","leadingIcon":"arrow_forward"}},{"kind":"option","props":{"label":"سنغافورة","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"أوروبا"},"items":[{"kind":"option","props":{"label":"برلين","value":"Europe/Berlin"}},{"kind":"option","props":{"label":"Lisbon (WET)","value":"Europe/Lisbon"}}]}],"direction":"rtl"}],"platforms":{"web":{"status":"lagging","name":"tanrei-select-field","props":{"variant":"variant","size":"size","value":"value","label":"label","labelHidden":"labelHidden","placeholder":"placeholder","supportingText":"supportingText","errorText":"errorText","error":"error","disabled":"disabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearLabel","required":"required","optional":"optional","requiredMark":"requiredMark","requiredText":"requiredText","optionalText":"optionalText","open":"open","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"change","toggle":"toggle"},"items":{"option":{"name":"tanrei-option","props":{"label":"label","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"disabled"},"notes":"`<tanrei-option>` children of `<tanrei-select-field>`, exactly as of `<tanrei-select>`: the product's elements in the light DOM, passed to the select inside through the default slot and read by it as data, as a select reads its own children."},"option-group":{"name":"tanrei-option-group","props":{"title":"label"},"notes":"As the option: the same element, the product's child, with its options inside it."}},"parts":{"field":"field","select":"select"},"notes":"The tag `tanrei-select-field`, the class `TanreiSelectField`, the React name `SelectField`. It takes every attribute, property, event and child of the select and of its Field, under the same names. The element is composed as every field element is; what follows is what is particular to it. Members: `<tanrei-field>` holding one `<tanrei-select>` in its default slot; the product places none, and gives the options. The host is `display: block`, as the Field is. Value member: `tanrei-select`. The host is the form's element — `name`, the value and its state, validity anchored on the select's trigger, reset to the `value` attribute, restore, `form`, a disabled fieldset — and the select inside has no `name`. Props, set as properties on the member each is from. On the Field: `label`, `labelHidden`, `supportingText`, `errorText`, `error`, `disabled`, `required`, `optional`, `requiredMark`, `requiredText`, `optionalText`. On the select: `variant`, `size`, `value`, `placeholder`, `readOnly`, `open`, `separation`, `iconSpace`, `status`, `statusText`, `emptyText`, and `inline`, the select's attribute for tests and fixtures, which is no prop of the spec and is passed on so that an open fixture and its twin are staged alike. Attributes are the members' own: kebab-case, except `readonly`. Props of one name on both members — `label`, `labelHidden`, `error`, `disabled` — are the Field's; the select's are never set by the element and reach the select through the connection. Events: `change` is the select's own composed, bubbling Event and leaves by itself with the host as its target. `toggle` is the select's CustomEvent, composed and not bubbling: it is heard on the host, as on any shadow host, and by no ancestor. Two props are the select's at every moment and are read through to it, never copied — `value` (the element's value is its value member's) and `open`, by the same accessor, as the combobox field reads its three — so each is already new in every listener of `change` and of `toggle`, capturing or bubbling, and when `open` is taken back with no event. No listener of the element's takes either. None is stopped and none is copied. Slots: `label-icon` is passed to the Field and `leading-icon` to the select, each by a slot element of the same name rendered only while the host has a child for it. The default slot is passed to the select — `<tanrei-select><slot></slot></tanrei-select>` — and is always rendered, where a field element otherwise has no default slot: the product's `<tanrei-option>` and `<tanrei-option-group>` children are assigned to it, and the select reads them through it. A child that is neither, and has no slot name the element has, is not rendered and is reported in a debug build. Parts: the member hosts are `field` and `select`. Exported from the Field: `label`, `label-icon`, `requirement-label`, `supporting-text`, `counter` (never drawn here). Exported from the select: `container`, `outline`, `active-indicator`, `label`, `requirement-label`, `value`, `placeholder`, `leading-icon`, `chevron`, `list`, `option`, `option-label`, `option-supporting-text`, `option-leading-icon`, `mark`, `group`, `group-title`, `divider`, `status`. Two names collide, `label` and `requirement-label`. Each is exported with its member's name before it, always (`field-label`, `select-label`, `field-requirement-label`, `select-requirement-label`), and under the bare name from both members as well, because the two are one thing to a person and are never drawn at once: FLD-25 is the sentence that holds it. Focus: the shadow root does not delegate. `focus()` and `blur()` call the select's; a press on the label row focuses the trigger by FLD-12 and opens nothing, a press on the trigger opens the list, and a press on the help does nothing. The list is the select's own popover in the top layer: it is placed against the trigger, both in the select's shadow tree, and a press on the Field's rows is a press outside it (SEL-27). The connection is the Field's with its control, with one value more upward, `drawnFocused` (SEL-63, FLD-13), the same value the combobox says; the element takes no part in it. Parts and tokens of its own: none. The element writes no custom property: `--tanrei-comp-field-*`, `--tanrei-comp-input-box-*` and `--tanrei-comp-select-*` reach the members by inheritance, and one select field is set apart by setting any of them on the element. What its twin cannot do that it does: nothing. The twin: `<tanrei-field label=\"Country\" required supporting-text=\"Where your invoices are addressed.\"><tanrei-select name=\"country\" value=\"jp\"><tanrei-option value=\"jp\">Japan</tanrei-option></tanrei-select></tanrei-field>`. Before the element is defined its options are running text in the page, as a select's are: hide `tanrei-select-field:not(:defined) > *` and reserve the block size. Words: none of its own; `required-text` and `optional-text` left empty are read by the Field from the product's words."},"swiftui":{"status":"planned","name":"TanreiSelectField","props":{"variant":"variant","size":"size","value":"selection","label":"label","labelHidden":"labelsHidden","placeholder":"prompt","supportingText":"supportingText","errorText":"errorText","error":"error","disabled":"disabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearLabel","required":"isRequired","optional":"isOptional","requiredMark":"requiredMark","requiredText":"requiredText","optionalText":"optionalText","open":"isPresented","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"selection","toggle":"isPresented"},"items":{"option":{"name":"TanreiSelectOption","props":{"label":"title","value":"tag","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"disabled"},"notes":"The select's own option, under the same name: the select field passes it to its select and reads nothing of it."},"option-group":{"name":"TanreiSelectSection","props":{"title":"title"},"notes":"The select's own option group, under the same name: the select field passes it to its select and reads nothing of it."}},"notes":"`TanreiSelectField(\"Country\", selection: $country, supportingText: \"…\") { TanreiSelectOption(\"Japan\").tag(\"jp\") … }`: a view whose body is `TanreiField(…) { TanreiSelect(selection:) { options } }` with each argument passed to the member it is from, and nothing else. The option content is the select's own, passed through as a view builder. `labelHidden` follows `.labelsHidden()` and `disabled` follows `.disabled(_:)`, both read by the Field. The product's words are read by the Field from the `\\.tanreiWords` environment value. Not built on this platform yet, nor is the select itself."},"compose":{"status":"planned","name":"TanreiSelectField","props":{"variant":"variant","size":"size","value":"value","label":"label","labelHidden":"labelHidden","placeholder":"placeholder","supportingText":"supportingText","errorText":"errorText","error":"isError","disabled":"enabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearContentDescription","required":"required","optional":"optional","requiredMark":"requiredMark","requiredText":"requiredText","optionalText":"optionalText","open":"expanded","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"onValueChange","toggle":"onExpandedChange"},"items":{"option":{"name":"TanreiSelectOption","props":{"label":"text","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"enabled"},"notes":"The select's own option, under the same name: the select field passes it to its select and reads nothing of it."},"option-group":{"name":"TanreiSelectGroup","props":{"title":"title"},"notes":"The select's own option group, under the same name: the select field passes it to its select and reads nothing of it."}},"notes":"`TanreiSelectField(value, onValueChange, label, supportingText = …) { TanreiSelectOption(\"Japan\", \"jp\") … }`: a composable that calls `TanreiField(…) { TanreiSelect(…) { content() } }` with each argument passed to the member it is from, and nothing else; the content lambda is the select's. `enabled` is the inverse flag and `isError` keeps Compose's name, both the Field's. The product's words are read by the Field from `LocalTanreiWords`. Not built on this platform yet, nor is the select itself."},"flutter":{"status":"planned","name":"TanreiSelectField","props":{"variant":"variant","size":"size","value":"value","label":"labelText","labelHidden":"labelHidden","placeholder":"hintText","supportingText":"helperText","errorText":"errorText","error":"isError","disabled":"enabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearSemanticLabel","required":"required","optional":"optional","requiredMark":"requiredMark","requiredText":"requiredText","optionalText":"optionalText","open":"controller","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"onChanged","toggle":"onOpenChanged"},"items":{"option":{"name":"TanreiSelectOption","props":{"label":"label","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"enabled"},"notes":"The select's own option, under the same name: the select field passes it to its select and reads nothing of it."},"option-group":{"name":"TanreiSelectGroup","props":{"title":"title"},"notes":"The select's own option group, under the same name: the select field passes it to its select and reads nothing of it."}},"notes":"`TanreiSelectField(value:, onChanged:, labelText:, helperText:, options: […])`: a widget that builds `TanreiField(child: TanreiSelect(…))` with each argument passed to the member it is from, and nothing else; `labelText`, `hintText`, `helperText`, `errorText` and `enabled` keep `InputDecoration`'s names. `TanreiSelectFormField` wraps it as a `FormField<String>` (`validator`, `onSaved`, `autovalidateMode`), which is how a Flutter form takes part, and its `errorText` is the Field's. The product's words are read by the Field from the `TanreiWords` inherited widget. Not built on this platform yet, nor is the select itself."},"react-native":{"status":"planned","name":"SelectField","props":{"variant":"variant","size":"size","value":"value","label":"label","labelHidden":"labelHidden","placeholder":"placeholder","supportingText":"supportingText","errorText":"errorText","error":"error","disabled":"disabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearAccessibilityLabel","required":"required","optional":"optional","requiredMark":"requiredMark","requiredText":"requiredText","optionalText":"optionalText","open":"open","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"onValueChange","toggle":"onOpenChange"},"items":{"option":{"name":"SelectOption","props":{"label":"label","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"disabled"},"notes":"The select's own option, under the same name: the select field passes it to its select and reads nothing of it."},"option-group":{"name":"SelectOptionGroup","props":{"title":"title"},"notes":"The select's own option group, under the same name: the select field passes it to its select and reads nothing of it."}},"notes":"`<SelectField label=\"Country\" value={value} onValueChange={setValue} supportingText=\"…\" options={[…]} />`: a component that renders `<Field …><Select … /></Field>` with each prop passed to the member it is from, and nothing else; `options` is the select's array. The product's words are read by the Field from the `TanreiWordsProvider` context. Not built on this platform yet, nor is the select itself."}}}
@@ -0,0 +1 @@
1
+ {"name":"select","title":"Select","summary":"Lets people choose one value from a closed list: a trigger that looks and measures like a text input and shows the chosen option, and a list of options, optionally grouped, that opens from it. It has no label row and no message: a Field frames it — that pair is the select field — or the product names it where its label stands elsewhere, as in a header or a toolbar.","level":"base","listing":"default","anatomy":[{"id":"container","description":"The trigger's box: it shows the chosen value and opens the list. It measures and is drawn as the text input's container of the same variant and size, carries the hover state layer and shows focus by its edge. A press anywhere on it opens the list."},{"id":"outline","description":"The border of an outlined select, which opens a gap where the floated label crosses it; in a stacked select, the line drawn inside the container's edge while it is focused or in error, which takes no layout space.","optional":true},{"id":"active-indicator","description":"The line along the bottom of a filled select; its focused state is thicker and colored.","optional":true},{"id":"label","description":"In a filled or outlined select, its name drawn inside the box: it rests in the line while nothing is chosen and the select is neither focused nor open, and floats above the value otherwise. A stacked select draws none: the label above it is the row of the Field that frames it.","optional":true},{"id":"required-asterisk","description":"After the floating label's text, an asterisk, where the Field that frames the select says it is required and marks it (SEL-7). Kept from assistive technology.","optional":true},{"id":"value","description":"The chosen option's label, on one line in the container, cut where it does not fit. It is drawn from the input part of the tokens: the text input's name for the same line."},{"id":"placeholder","description":"A hint shown in the line while nothing is chosen; never a label.","optional":true},{"id":"leading-icon","description":"A glyph at the start of the container: the one the product gives the select, or else the chosen option's own.","optional":true},{"id":"clear-button","description":"An icon-only Button of the text variant at Button's small size showing close, before the chevron, that empties the value. Drawn while clearable is true and the value is not empty; its room is kept while clearable is true. It stands over the container and is not part of it.","optional":true},{"id":"chevron","description":"The glyph expand_more of the system's icon set at the end of the container: it says that the box opens a list. It is drawn from the trailing-icon part of the tokens, is not a target of its own, does not turn while the list is open and is never mirrored. A read-only select draws none."},{"id":"list","description":"The floating surface that holds the options: the raised sheet a menu and a popover are drawn on, placed against the container as a popover is against its anchor, as wide as it, scrolling when its options do not fit."},{"id":"option","description":"One choice: a row of the list, laid out and drawn as the menu's item. It carries hover, the active highlight and press and, while it is the chosen one, the quiet selection's fill."},{"id":"option-label","description":"The option's text, its accessible name and what the container shows once the option is chosen."},{"id":"option-supporting-text","description":"A line below an option's label that says more about the choice. It is shown in the list only.","optional":true},{"id":"option-leading-icon","description":"A glyph before an option's label. Its column is kept in every row of a list where any option has one.","optional":true},{"id":"mark","description":"The glyph check of the system's icon set at the end of the chosen option's row, in a box kept at the end of every row. With the row's fill it shows the choice; the fill never shows it alone.","optional":true},{"id":"group","description":"A run of related options (an option group), optionally under a title, separated from what is next to it by a divider or by a gap.","optional":true},{"id":"group-title","description":"The heading above a group's options. It names the group, takes no focus and is not a choice.","optional":true},{"id":"divider","description":"The hairline between two groups while the separation is divider. Under gap there is none.","optional":true},{"id":"status","description":"A row after the options that says what the product's source of options is doing — a loading indicator, a count, a failure — or, while the select holds no option, that there is nothing to choose (the empty text). Not an option: it takes no input and is never active. It stands under the options, outside the region that scrolls.","optional":true},{"id":"focus-ring","description":"Gap-then-ring indicator inside an option's row while the option is the active one by the keyboard. The container itself draws no ring: its focused edge is its focus indicator."}],"props":[{"name":"variant","type":"enum","values":["stacked","filled","outlined"],"default":"stacked","description":"The text input's three looks, so that a select is drawn as the text inputs beside it. Stacked is a filled box that shows focus and error with a line inside its edge and draws no label: the label of the Field that frames it stands above it. Filled and outlined float the label inside the box. Use one style per form. A design system may leave some out (the Tanrei system ships stacked only) or add values.","axis":"tanrei.comp.input-box.variant"},{"name":"size","type":"enum","values":["small","medium","large"],"default":"medium","description":"Minimum height of the container: stacked 28 / 36 / 52, as tall as a Button of the same size, so that the box and a Button side by side in one row stand as tall as each other; filled and outlined 40 / 48 / 56, which hold the label that floats inside them; all under the default system, and never drawn below sys.target.minimum. The text input's three sizes: medium and large for forms, small for a select in an app bar, a toolbar or a dense row of controls, where nothing frames it. The size the box is drawn at, its own or its container's, is also the size of the options of the list it opens (SEL-70): a small box opens small rows, and a medium or a large box medium ones. The hit area always meets the minimum target. A design system may add values. While it is not set the select draws the size its nearest container sets — a toolbar's size — and medium where none does (SEL-73); setting it, to medium too, makes it the select's own.","axis":"tanrei.comp.input-box.size"},{"name":"value","type":"string","default":"","description":"The value of the chosen option. The select shows that option's label; while value names no option it shows the placeholder. An option whose value is the empty string is a choice like any other (\"None\", \"Any\") and is the chosen one while value is empty."},{"name":"label","type":"string","default":"","description":"Names the select for assistive technology where no Field frames it; a filled or outlined select also draws it, as the label that floats in its box. Inside a Field leave it empty: the Field's label names the select, and is what floats."},{"name":"labelHidden","type":"boolean","default":false,"description":"Does not draw the floating label of a filled or outlined select, which stays the accessible name. Inside a Field, hide the label on the Field. A stacked select draws no label, so this changes nothing there."},{"name":"placeholder","type":"string","default":"","description":"A hint shown while nothing is chosen and the label is not in the line (\"Choose a country\"). Never a replacement for label, and never a choice."},{"name":"error","type":"boolean","default":false,"description":"Draws the select in its error condition and exposes it as invalid. A Field sets it from its own error; set it here only where no Field frames the select. What a value means is the product's to validate; the select never sets this itself."},{"name":"disabled","type":"boolean","default":false,"description":"Disables the select: it takes no focus, does not open and is left out of form submission. Inside a Field, disable the Field, so that its label follows."},{"name":"readOnly","type":"boolean","default":false,"description":"The value is shown, can be focused and is submitted, but cannot be changed: the list does not open and no chevron is drawn."},{"name":"clearable","type":"boolean","default":false,"description":"Draws a clear button while a value is chosen, for a select whose value may be none: a filter, an optional setting. Without it, a chosen value is changed only by choosing another."},{"name":"clearLabel","type":"string","default":"","description":"The clear button's accessible name, in the product's language (\"Clear\"). Empty reads the product's words. Required while clearable is true.","words":"clearLabel"},{"name":"open","type":"boolean","default":false,"description":"Whether the list is shown. The select opens and closes itself and emits toggle; the product may also set it. Ignored while the select is disabled or read-only or has nothing to show: no option, no status row and no empty text (SEL-61)."},{"name":"separation","type":"enum","values":["auto","divider","gap"],"default":"auto","description":"How a group of options is told from what is next to it. divider: a line between them. gap: empty space and no line. Auto takes comp.select.separation, which follows the design system's choice."},{"name":"iconSpace","type":"enum","values":["auto","always","never"],"default":"auto","description":"Whether an option keeps the room of the leading icon column where it has no icon, so that the labels of a section start on one line — a section being an option group, or a run of adjacent options outside any group. auto: an option keeps the column while another option of its section has a leading icon, so that a section without icons starts its labels where the row's content starts. always: every option keeps it. never: only an option that has an icon has the column. The menu's iconSpace, with the same values and default (SEL-66)."},{"name":"status","type":"enum","values":["idle","loading","error"],"default":"idle","description":"What the product's source of options is doing, which the product sets: idle (the options given are final), loading (options are on their way: the status row shows a loading indicator and the list is marked busy) or error (the source failed: the status row shows statusText in the error color, announced at once). The combobox's and the search's values, with the same meaning. The select never loads anything itself."},{"name":"statusText","type":"string","default":"","description":"The status row's text, in the product's language, read to assistive technology when the list opens and when it changes: a count (\"20 of 340 projects shown\"), that loading failed (\"Projects could not be loaded\"), or, while status is loading, the loading indicator's name (\"Loading projects\"). Empty draws no status row unless status is loading."},{"name":"emptyText","type":"string","default":"","description":"Shown in the list while the select holds no option, status is idle and statusText is empty, in the product's language (\"No projects yet\"), so that the select still opens and says why there is nothing to choose. The product's: Tanrei has no words for it. Empty reads the product's words (noOptionsText); with neither, the select has nothing to show and does not open (SEL-61), and it is reported.","words":"noOptionsText"}],"items":[{"name":"option","summary":"One choice of the select: a label, the value it stands for, and optionally a supporting line and a glyph.","props":[{"name":"label","type":"string","default":"","description":"The option's text and its accessible name; the container shows it once the option is chosen. Required."},{"name":"value","type":"string","default":"","description":"Identifies the choice: the option is the chosen one while the select's value equals it. Unique within the select. The empty string is a value like any other, for an option that stands for no choice (\"None\")."},{"name":"supportingText","type":"string","default":"","description":"A line below the label that says more about the choice. Shown in the list, not in the container."},{"name":"leadingIcon","type":"string","default":"","description":"The name of an icon (a glyph of the system's icon set) before the label; the container shows it too while the option is chosen and the select has no leading icon of its own."},{"name":"disabled","type":"boolean","default":false,"description":"Prevents the option from being chosen. It stays reachable with the arrow keys."}]},{"name":"option-group","summary":"A run of related options, optionally titled. The select separates a group from what is next to it by a divider or a gap.","container":true,"props":[{"name":"title","type":"string","default":"","description":"A short heading drawn above the group's options, which also names the group; empty draws none and leaves the group unnamed."}]}],"slots":[{"name":"leading-icon","description":"A glyph at the start of the container that stands for the field whatever is chosen (a globe before a language). It takes the place of the chosen option's own glyph.","fixture":"glyph"}],"events":[{"name":"change","description":"The person chose an option whose value differs from the select's; carries the new value. Not emitted when the product sets value, when the chosen option is chosen again, or while the person only moves through the list."},{"name":"toggle","description":"The list was opened or closed by the person; carries the new open and, for a close, the reason: select, escape, back, outside, focus-out, anchor-hidden, press or tab (in the platform's casing). After a choice it follows change."}],"states":["enabled","disabled","hovered","focused","pressed","selected","error"],"behavior":[{"id":"SEL-1","text":"THE select SHALL draw its container at least comp.input-box.stacked.container.height.medium tall WHILE variant is stacked (or a variant a design system adds, which is drawn as a stacked box) and at least comp.input-box.container.height.medium tall WHILE variant is filled or outlined, for size medium (and so on for each size), with a stacked or outlined select's four corners and a filled select's top corners rounded by comp.input-box.container.shape, a filled select's bottom corners by comp.input-box.container.shape-bottom, all eased by sys.shape.corner-smoothing, and SHALL lay out in it one row, centred vertically: the leading icon where there is one (SEL-18), the value or the placeholder (SEL-16) taking the remaining width, and the chevron at the end (SEL-19), comp.input-box.container.gap.medium apart; text SHALL be comp.input-box.container.padding-inline.medium from the container's edge and a glyph comp.input-box.container.padding-inline-with-icon.medium, and the row's tallest item SHALL have at least comp.input-box.stacked.container.padding-block.medium above and below it in a stacked box and comp.input-box.container.padding-block.medium in a filled or an outlined one (and so on for each size)."},{"id":"SEL-2","text":"THE select SHALL measure as the text input of the same variant and size measures (TXI-16), at every size: the same container height, paddings and corners, and the same text style and start edge for the value as the text input's text, so that a select and a text input side by side share every horizontal line and a select below a text input shares its start edges. The two are drawn from one set of tokens (SEL-65): what a layer changes of the box, it changes for both. The label row above it and the supporting row below it are the rows of the Field that frames it (FLD-1, FLD-2, FLD-7), which are one frame for every control."},{"id":"SEL-7","text":"WHERE variant is filled or outlined, WHILE the floating label is drawn (SEL-15) and the Field that frames the select gives it an asterisk as its required mark (FLD-25) THE select SHALL draw the character \"*\" after the label's text, comp.input-box.requirement.asterisk-gap from it, in the label's text style and at the label's place, resting and floated with it, in the required-asterisk color of its variant (comp.input-box.outlined.required-asterisk.color for an outlined select; comp.input-box.outlined.error.required-asterisk.color WHILE the select is in error), and SHALL keep it from assistive technology, because the required state already says it (SEL-11). It SHALL draw no tag and no optional label: which mark a required control gets is the Field's to say (FLD-6), and a tag named there reaches a floating label as the asterisk. WHILE no Field frames it, or the Field gives no mark, or the label is not drawn, THE select SHALL draw no mark."},{"id":"SEL-9","text":"WHILE error is true — set by the product, or by the Field that frames it (FLD-8) — THE select SHALL draw every part of its trigger, in every state, from the error parts of its variant (comp.input-box.stacked.error.outline.color and the other error. parts), so that the select itself is marked and not only a text below it, and SHALL expose itself as invalid to assistive technology; its list and its options SHALL stay as they are drawn. THE select SHALL never set error itself and SHALL show no error text of its own: the words that say what is wrong are the errorText of the Field that frames it, which that Field draws and gives the select as its description (FLD-7, FLD-11)."},{"id":"SEL-11","text":"THE select SHALL take its name, its description and its required state from the Field that frames it, as every control a Field frames does (FLD-10, FLD-11): the Field's label is its accessible name and the name of its list (SEL-48), whether or not any label is drawn, and the Field's supporting text with, in error, the error text after it is its description. WHILE label is not empty THE select SHALL use it as the accessible name instead, for a select no Field frames or one whose visible label is elsewhere. It SHALL never use placeholder as the name, WHILE it has either name THE select SHALL expose that one alone, over a name the product gives it on the element (aria-label or aria-labelledby); and WHILE it has neither name and the product gives it a name of its own on the element — aria-label, or aria-labelledby naming an element — THE select SHALL expose that name as its accessible name; IF it has none of the three it SHALL still render and work, and in debug builds SHALL report that it has no accessible name. WHILE its Field says it is required THE select SHALL expose itself as required, whichever mark is drawn and where none is, and on the web SHALL report a missing value to the form's constraint validation WHILE value is the empty string; it has no requirement setting of its own and SHALL NOT validate because of one. WHILE an option's label is empty THE select SHALL still render the option and in debug builds report that it has no accessible name."},{"id":"SEL-13","text":"THE select SHALL add one stop to the focus order, its container, and no other but the clear button while it is shown (SEL-72). A press on the label row of the Field that frames it moves focus to the container and opens nothing: that press is the Field's (FLD-12). A label that floats in the container is part of the container, and a press on it is a press on the container (SEL-22, SEL-23)."},{"id":"SEL-15","text":"WHERE variant is filled or outlined and the label is drawn THE select SHALL rest the label in the value's line, in comp.input-box.label.typescale.medium for size medium (and so on), WHILE no option is chosen and the select is neither focused nor open, and otherwise float it as the text input of that variant floats its label (TXI-13): to the top of a filled container, or onto an outlined container's top edge with a gap of comp.input-box.outline.notch-padding in the outline on each side of it, in comp.input-box.label.floated-typescale.medium for size medium (and so on); a filled select that draws its label SHALL be at least twice comp.input-box.container.padding-block-with-label.medium plus one line of each of those two text styles tall (and so on for each size), so that it does not change height when the label floats. WHEN the label floats or rests THE select SHALL move and resize it over comp.input-box.motion.label-duration with comp.input-box.motion.label-easing, and at once where motion is reduced. The label SHALL wrap rather than be cut and SHALL never be drawn over the value. The label it floats SHALL be its accessible name (SEL-11) — the label of the Field that frames it, or its own label where none does — in the label color of its variant (comp.input-box.outlined.label.color for an outlined select, its error. part WHILE the select is in error). WHILE labelHidden is true — its own, or that Field's (FLD-25) — or it has no name THE select SHALL draw no label. WHERE variant is stacked, or a variant laid out as stacked (SEL-60), THE select SHALL draw no label at all: the label above it is the Field's row (FLD-2)."},{"id":"SEL-16","text":"THE select SHALL show in its container the label of the chosen option (SEL-17), on one line, in comp.input-box.input.typescale.medium for size medium (and so on) and the input color of its variant (comp.input-box.stacked.input.color for a stacked select, its error. part WHILE the select is in error); it SHALL NOT wrap it, and WHEN the container is narrower than the label needs SHALL cut it with an ellipsis, keeping the leading icon, the chevron and the paddings whole, the full label remaining what assistive technology reads. WHILE no option is chosen THE select SHALL show placeholder in the same place and style in the placeholder color of its variant (comp.input-box.stacked.placeholder.color for a stacked select), only while the label is not in the line — a stacked select, whose label is the row of its Field; floated; or not drawn — and nothing WHILE placeholder is empty. THE select SHALL NOT show an option's supporting text in its container."},{"id":"SEL-17","text":"THE select SHALL treat as the chosen option the first option, in order and across groups, whose value equals value, a disabled option and an option whose value is the empty string included; WHILE no option's value equals value THE select SHALL draw itself with nothing chosen, SHALL keep value as the product set it, and in debug builds SHALL report a value that is not empty and names no option. WHEN two options share a value THE select SHALL treat the first as the one both stand for and in debug builds report it. WHEN the options change THE select SHALL find the chosen option again by value and SHALL NOT change value or emit change."},{"id":"SEL-18","text":"WHERE the leading-icon slot holds a glyph THE select SHALL draw it at the start of its container; otherwise, WHILE the chosen option has a leadingIcon, THE select SHALL draw that glyph there; otherwise it SHALL draw none and start the value at the text padding. It SHALL draw the glyph at comp.input-box.icon.size.medium for size medium (and so on), with sys.icon.family.unselected and sys.icon.fill.unselected, sys.icon.weight and an optical size clamped between sys.icon.optical-size.min and sys.icon.optical-size.max, in the leading-icon color of its variant (comp.input-box.stacked.leading-icon.color for a stacked select, its error. part WHILE the select is in error), and SHALL keep it from assistive technology. The slot's content SHALL be a glyph only: an interactive element there SHALL be reported in debug builds."},{"id":"SEL-19","text":"WHILE readOnly is false THE select SHALL draw at the end of its container the glyph expand_more of the system's icon set, at comp.input-box.icon.size.medium for size medium (and so on), with sys.icon.family.unselected and sys.icon.fill.unselected, sys.icon.weight and an optical size clamped between sys.icon.optical-size.min and sys.icon.optical-size.max, in the trailing-icon color of its variant (comp.input-box.stacked.trailing-icon.color for a stacked select, its error. part WHILE the select is in error). THE select SHALL draw the same glyph whether the list is closed or open and wherever the list is placed, without turning or exchanging it, SHALL NOT mirror it in a right-to-left layout, SHALL keep it from assistive technology, SHALL NOT make it a target or a focus stop of its own, and SHALL draw no mark of its own in its place. WHILE readOnly is true THE select SHALL draw no chevron, because nothing opens. IF the icon set cannot draw a glyph yet (its font is still loading or failed to load) THE select SHALL draw nothing in that glyph's place, never its name as text, and keep the glyph's box."},{"id":"SEL-20","text":"WHILE hovered or focused THE select SHALL render its container, outline, active indicator, floating label and its asterisk, value, placeholder, leading icon, chevron and opacity, and the widths of its outline and active indicator, from the component tokens of the highest-precedence active state, with precedence focused over hovered; focus gained by pointer or touch SHALL select the focused state, as in a text input (TXI-6), and THE select SHALL be drawn focused for as long as its list is open, and SHALL say so to the Field that frames it, so that the rows of that Field are drawn focused with it (SEL-63, FLD-13). WHILE variant is stacked it SHALL draw no edge at rest (comp.input-box.stacked.outline.color is transparent), SHALL draw its focused outline color and width as a line inside the container's edge that takes no layout space, and WHILE in error SHALL draw that line at rest in comp.input-box.stacked.error.outline.color at comp.input-box.outline.width; a hovered stacked or filled select SHALL show the state layer on its container. WHEN its state changes THE select SHALL animate colors and widths over the state duration of its size (comp.input-box.motion.state-duration.small, .medium or .large) with comp.input-box.motion.state-easing, and SHALL change them at once where motion is reduced."},{"id":"SEL-21","text":"THE select SHALL show focus by its focused tokens — the focused outline or active indicator is its focus indicator — and SHALL NOT draw the focus ring around its container; WHERE sys.behavior.focus-style is glow it SHALL also draw the glow around the container while focused."},{"id":"SEL-22","text":"WHERE the container is shorter than the minimum target THE select SHALL extend its hit area vertically to sys.target.touch for touch input and sys.target.pointer for fine pointers, without changing its visual size; a platform that cannot tell the input type SHALL use sys.target.touch. The whole container — its paddings, the leading icon, the value and the chevron — SHALL be one target. THE select SHALL draw no press answer on its container (no pressed state layer, ripple or dim): a press on it is answered by the list, which opens with the press, and by the focused edge."},{"id":"SEL-23","text":"WHEN the person presses the container by pointer or touch, or presses Enter, Space, Down Arrow or Up Arrow while the select has focus, WHILE the list is closed and the select is neither disabled nor read-only and has something to show — an option, a status row or the empty text (SEL-68) — THE select SHALL take focus if it does not have it, set open to true, emit toggle once with open true, and present its list (SEL-24). The container is the list's anchor and its opener (POP-18): THE select SHALL NOT open or close its list when a pointer enters or leaves, when focus arrives, on a long-press or after a time, and SHALL expose on its container that it opens a list box, whether the list is open and, while it is, which element it is (aria-haspopup with the value listbox, aria-expanded and aria-controls on the web, as SEL-48 says). THE select SHALL NOT change value by opening, and SHALL NOT change value from the keyboard while its list is closed: the arrow keys and typing (SEL-33) open the list instead, so that a value never changes without the person seeing what it changed to and confirming it."},{"id":"SEL-24","text":"WHILE open is true THE select SHALL present its list in the platform's overlay layer, the one a popover's container and the menu's surface use (POP-1), and SHALL place it against its container as a popover whose placement is bottom-start is placed against its anchor (POP-2, POP-4): comp.select.list.offset below the container with the start edges aligned, its own token in the place of the popover's offset. It SHALL keep the list at least comp.select.list.viewport-margin inside the visible part of the window's safe area, above the on-screen keyboard, by the steps POP-5 gives, in that order — flipping above the container where below has no room and above has, limiting the list to the room where neither has, shifting along the container, and keeping its side while that side has room — SHALL follow the container as it moves or changes size, SHALL place the list again WHEN the on-screen keyboard shows or hides or the visible part of the window otherwise moves or changes size (POP-36), and SHALL take the start edge as the right edge in a right-to-left layout (POP-34). It SHALL stay an anchored list at every window size and SHALL NOT turn into a sheet or a dialog (POP-43): a list of options is the menu's kind of surface, which Tanrei's rule for compact windows leaves beside its control. WHEN the container is removed, hidden or scrolled out of sight so that no part of it can be seen THE select SHALL close the list with the reason anchor-hidden (SEL-27), as POP-5 says of a popover's anchor."},{"id":"SEL-25","text":"THE select SHALL fill its list with comp.select.list.color, raise it by comp.select.list.elevation, round it by comp.select.list.shape eased by sys.shape.corner-smoothing, clip its options to that shape and inset them by comp.select.list.padding-block and comp.select.list.padding-inline. It SHALL make the list as wide as its widest option needs unwrapped, its paddings included — never narrower than its container nor than comp.select.list.min-width, never wider than comp.select.list.max-width or its container where the container is wider, following the container's width as it changes, and never wider than the window's safe area less comp.select.list.viewport-margin on each side — so that a long label or a supporting text reads in fewer lines without the container, and the layout around it, changing width (SEL-49); an option whose text needs more than that width SHALL wrap (SEL-37). A list wider than its container keeps the start edges aligned and shifts along the container to stay inside the window (SEL-24). It SHALL make the list as tall as its options and its paddings, at most comp.select.list.max-height and at most the room its side leaves (POP-8), and SHALL scroll the options beyond that, vertically only, the list's paddings scrolling with them; the list has no header and no actions, so it draws no divider of a scrolling popover. WHEN the list opens with a chosen option THE select SHALL scroll it so that the whole of that option is in view. A long list MAY draw only the rows near its scroll position and the active option with its neighbours, each row it does not draw keeping its height so that every option is reached by scrolling and by the keys; such a list SHALL state each drawn option's position among all the options and their number (SEL-48), and SHALL take its width from the rows drawn as it opens and keep that width while it scrolls, so that the list does not change width under the pointer."},{"id":"SEL-26","text":"WHILE the list is open THE select SHALL keep focus on its container, because the list is an operated overlay whose focus is the field it belongs to, as the search's docked view is: it SHALL NOT move focus into the list when it opens (this is the select's own rule, where a popover moves focus in, POP-19), SHALL NOT trap focus, make anything inert or draw a scrim; a press on an option, on a group title, on the status row or on the list's surface SHALL NOT take focus from the container. One option at a time SHALL be the active option, which the keys act on and assistive technology is told of (SEL-48)."},{"id":"SEL-27","text":"WHEN the person presses Escape or the platform's back while the list is open, presses outside the list and the container, moves focus out of the select, or WHEN the container goes out of sight (SEL-24), THE select SHALL close the list, set open to false and emit toggle once with open false and that reason — escape, back, outside, focus-out or anchor-hidden, the popover's reasons (POP-21); and it SHALL do the same with the select's own reasons WHEN the person presses the container while the list is open (press), presses Tab or Shift+Tab (tab), or chooses an option (select, SEL-34). Tab closes the list at once and moves focus on from the container as it would have, as the menu's rule is and not the popover's (POP-20), because the list holds one set of options and nothing a person could tab to. A close for any reason but select SHALL choose nothing, whatever option is active, and value SHALL stay as it is. Focus SHALL stay on the container, or where the person put it WHEN the close came from focus moving to, or a press landing on, another focusable element (POP-22). Focus leaving the window SHALL NOT count as focus leaving the select. Whether a press outside also reaches the element under it SHALL follow the platform and be stated in its README, as for the menu (MNU-5)."},{"id":"SEL-28","text":"WHILE the list is open, WHEN the user presses Escape or the platform's back THE select SHALL take the key, close as SEL-27 says, and let it go no further, so that it does not also close a dialog, a sheet or a popover the select stands in (POP-23). WHILE the list is closed THE select SHALL NOT act on Escape and SHALL leave it to whatever holds the select."},{"id":"SEL-29","text":"WHERE the select stands inside a popover or a modal overlay (a dialog, a modal sheet) THE select's list SHALL belong to that overlay as POP-24 and POP-25 say of an overlay opened from inside one: a press in the list is not a press outside it, the list is presented above it and is operable while the rest of the window is inert, and the list closes with it. THE select SHALL open no overlay from inside its list."},{"id":"SEL-30","text":"WHEN the list opens THE select SHALL make it appear as a popover's container appears (POP-26) — from where that appearance starts it, grown from the middle of the edge that faces the container — over comp.select.motion.open-duration with comp.select.motion.open-easing, and WHEN it closes take it back the same way over comp.select.motion.close-duration with comp.select.motion.close-easing; WHERE motion is reduced it SHALL only fade in and out, over sys.motion.role.reduced. WHEN it is told to close while still opening, or to open while still closing, it SHALL turn round from where it is, and WHILE closed or closing it SHALL take no pointer input (POP-27, MOT-7). The value and the open state SHALL change when the list closes, not when its motion ends."},{"id":"SEL-31","text":"WHEN the list opens THE select SHALL make the chosen option the active one, or the first option that is not disabled WHILE none is chosen. WHILE the list is open THE select SHALL make active the next option with Down Arrow and the previous one with Up Arrow, in order and across groups, stopping at the last and at the first without wrapping; the first and the last option with Home and End; and the option ten after or ten before, or the last or the first where fewer remain, with Page Down and Page Up. A disabled option SHALL be reached like any other, so that people learn it exists; a group title, a divider and the status row are never active, and WHILE the list holds no option no option is active and Enter and Space choose nothing. Making an option active SHALL NOT change value. WHEN an option becomes active while part of it is scrolled out of view THE select SHALL scroll it into view."},{"id":"SEL-32","text":"WHILE an option is the active one by the keyboard THE select SHALL render it in the focused state and show the focus ring inside its row, which the list would otherwise clip, without animation; WHEN a pointer moves onto an option THE select SHALL make that option the active one, render it hovered and show no focus ring, so that the arrow keys continue from it; WHILE a pointer is at rest THE select SHALL NOT take the options that a scroll of the list or of the page carries under it for a pointer that moves onto them, so that the option a key made active stays active; WHEN the pointer leaves the list the option SHALL stay active."},{"id":"SEL-33","text":"WHEN the person types printable characters while the select has focus, each within one second of the one before, THE select SHALL treat them as one string and make active the next option after the active one, wrapping to the first, whose label begins with that string, compared without regard to case, to the width of a character or to the marks on a letter, as the label's language compares (as the combobox compares, CMB-25); a string of one character typed again SHALL move on to the next option that begins with it. WHILE the list is closed the first character SHALL open it (SEL-23) and then do the same. Typing SHALL NOT change value, and a Space typed within that second SHALL be a character of the string and SHALL NOT choose."},{"id":"SEL-34","text":"WHEN the person presses an option that is not disabled by pointer or touch, or presses Enter or Space while such an option is the active one, THE select SHALL, WHEN that option's value differs from value, set value to it, show its label in the container and emit change once with the new value; it SHALL then close the list with the reason select (SEL-27), so that toggle follows change. Choosing the option that is already chosen SHALL emit no change and still close the list. THE select SHALL NOT emit change when the product sets value, and SHALL have no way of its own to return to nothing chosen: a product that allows no choice gives an option that says so."},{"id":"SEL-35","text":"WHILE an option's disabled is true THE select SHALL NOT choose it by any input, SHALL leave the list open when it is pressed or when Enter or Space is pressed on it, SHALL expose its disabled state to assistive technology, and SHALL render its container, label, supporting text, leading icon, mark and opacity from the disabled component tokens of its condition. A disabled option whose value equals value is still the chosen one: the container shows its label, and its row draws the fill and the check from the disabled tokens."},{"id":"SEL-36","text":"WHEN the product sets open THE select SHALL show or remove its list without emitting toggle; WHEN the product sets value THE select SHALL show the chosen option's label and SHALL NOT emit change or toggle, and WHILE the list is open SHALL move the fill and the check to the new chosen option and leave the active option where it is. WHEN the options change while the list is open THE select SHALL keep the active option where an option of the same value still exists and otherwise make active the option SEL-31 names for an opening list. WHEN status, statusText or emptyText change while the list is open THE select SHALL draw the status row as it then is (SEL-68) and keep the list open. WHEN the select becomes disabled or read-only, or is left with nothing to show (SEL-61), while its list is open THE select SHALL close the list without emitting toggle."},{"id":"SEL-37","text":"THE select SHALL lay out an option as one row: comp.select.option.padding-inline.medium from each edge, the leading icon column (as SEL-66 says), the label with the supporting text below it taking the remaining width, and at the end a box of side comp.select.option.mark.size.medium for the check (SEL-39), each comp.select.option.gap.medium from the next; the box of the check SHALL keep its width in every row so that labels wrap alike. It SHALL make the row at least comp.select.option.height.medium tall, and at least sys.target.touch tall for touch input and at least sys.target.pointer tall for fine pointers, drawn so, at every size (SEL-70), because rows that touch cannot extend a hit area over each other (a platform that cannot tell the input type SHALL use sys.target.touch); pad its content by comp.select.option.padding-block.medium above and below; draw the label in comp.select.option.label.typescale and the supporting text in comp.select.option.supporting-text.typescale; and wrap text and grow the row, with long labels and with enlarged text, rather than cut anything in the list. The whole row SHALL be the option's hit area."},{"id":"SEL-38","text":"THE select SHALL draw an option from the condition it is in — selected-option for the chosen option, option for every other — and from the state it is in, with precedence pressed over focused over hovered: its row filled with the container color of that condition and state within the corners comp.select.option.shape gives, eased by sys.shape.corner-smoothing, over comp.select.list.color and under the row's content; its label, supporting text and leading icon in that condition's colors (comp.select.stacked.option.label.color, comp.select.stacked.selected-option.label.color and so on for a stacked select). The option parts hold the same values under every variant: a list does not change with the look of its field. WHEN the colors of an option change between states THE select SHALL animate them over comp.select.motion.state-duration with comp.select.motion.state-easing, and SHALL change them at once where motion is reduced."},{"id":"SEL-39","text":"WHILE an option is the chosen one THE select SHALL fill its row with the selected-option container color of its state (comp.select.stacked.selected-option.container.color at rest for a stacked select) and SHALL draw the glyph check of the system's icon set centred in the box at the end of the row, in the mark color of that condition and state (comp.select.stacked.selected-option.mark.color at rest), with sys.icon.family.selected, sys.icon.fill.selected, sys.icon.weight and an optical size clamped between sys.icon.optical-size.min and sys.icon.optical-size.max; it SHALL draw nothing in that box for any other option, SHALL NOT mirror the check in a right-to-left layout, and SHALL draw no mark of its own (no path, shape or character of its own for the check). THE select SHALL NOT show the choice by the fill alone: the check is always drawn with it, and a design system whose fill is none still marks the chosen option. WHEN the chosen option changes while the list is open THE select SHALL fade the check in or out over comp.select.motion.state-duration with comp.select.motion.state-easing without moving or scaling it."},{"id":"SEL-40","text":"THE select SHALL draw an option's leadingIcon at comp.select.option.leading-icon.size.medium through the icon helper, with the family and fill of the option's condition (sys.icon.family.selected and sys.icon.fill.selected for the chosen option, otherwise sys.icon.family.unselected and sys.icon.fill.unselected), sys.icon.weight and an optical size clamped between sys.icon.optical-size.min and sys.icon.optical-size.max, in the leading-icon color of its condition and state, hidden from assistive technology; an empty name SHALL draw nothing."},{"id":"SEL-41","text":"WHEN the option is pressed by pointer, touch, Enter or Space THE option SHALL show the pressed state without delay and SHALL keep it visible for at least sys.motion.duration.press-hold, even when the press ends sooner. WHEN that press chooses the option and closes the list (SEL-34) THE select SHALL close the list at once and SHALL NOT hold it open to show the pressed state: the pressed state is then seen only while the list closes, and the choice is shown by the new value in the container."},{"id":"SEL-42","text":"WHILE pressed THE option SHALL answer as sys.behavior.pressed-feedback names: overlay applies the pressed tokens to the whole container at once; ripple grows the pressed state layer from the point of contact (from the center for keyboard activation); dim applies the pressed opacity to the whole control and draws no state layer; none draws no answer to the press. Under ripple and dim only the container color stays with the state under the press; label, supporting text, leading icon, mark, opacity and shape still come from the pressed tokens. Under none every part stays with the state under the press. The ripple grows over comp.select.motion.feedback-duration with comp.select.motion.state-easing, fades over comp.select.motion.state-duration with comp.select.motion.state-easing once the press has ended and press-hold has passed, and appears whole where motion is reduced."},{"id":"SEL-43","text":"THE option SHALL ease its container corners by sys.shape.corner-smoothing (0 is a quarter circle, 0.6 the iOS continuous corner; a platform with only the OS curve draws it for any amount above 0) and show its keyboard focus as sys.behavior.focus-style names (ring or glow); a platform that cannot draw a choice SHALL fall back to the first value and state that in its README."},{"id":"SEL-44","text":"WHILE a group's title is not empty THE select SHALL draw it above the group's options in comp.select.group-title.typescale and comp.select.group-title.color, starting comp.select.group-title.padding-inline.medium from the rows' start edge and ending comp.select.group-title.padding-inline.medium from their end edge, with comp.select.option.padding-block.medium above and below, wrapping and growing with enlarged text rather than clipping. The title SHALL take no focus, SHALL never be the active option, SHALL NOT be reached by typing and SHALL scroll with its options. WHEN a group holds another group THE select SHALL draw the inner group's options as the outer group's, with no title or separation of the inner group's own, and in debug builds report it."},{"id":"SEL-45","text":"THE select SHALL separate a group from an adjacent group or an adjacent option outside any group as its separation names: WHILE separation is auto, as comp.select.separation names, which follows sys.behavior.separation unless a design system sets it apart; WHILE separation is divider or gap, as that value names, whatever the tokens say. Under divider it SHALL draw a line of comp.select.divider.thickness in comp.select.divider.color across the list's inner width, inside comp.select.list.padding-inline on each side, with comp.select.divider.space above and below it, exposed as a separator that takes no focus; under gap it SHALL leave comp.select.group.gap of empty space, draw no line and expose no separator. It SHALL draw neither before the first nor after the last element of the list. WHEN separation names a value the select does not define THE select SHALL treat it as auto and in debug builds report the unknown value. A platform that cannot draw a choice SHALL fall back to the first value, divider, and state that in its README."},{"id":"SEL-46","text":"WHILE disabled is true — set by the product, or by the Field that frames it (FLD-14) — THE select SHALL NOT be focusable, SHALL NOT open, SHALL NOT emit change or toggle, SHALL expose the disabled state to assistive technology, SHALL be left out of form submission on the web, SHALL draw no clear button, and SHALL render every part of its trigger, the chevron, the floating label and its asterisk included, from the disabled component tokens of its variant (of its error parts WHILE error is true)."},{"id":"SEL-47","text":"WHILE readOnly is true and disabled is false THE select SHALL stay focusable and show its value, SHALL NOT open by any input and SHALL NOT let the person change the value, SHALL NOT emit change or toggle, SHALL expose the read-only state to assistive technology, SHALL be submitted with its form on the web, and SHALL render as an enabled select without its chevron (SEL-19) and without the clear button and its room (SEL-72), including its hovered and focused states."},{"id":"SEL-48","text":"THE select SHALL expose its container, on the web, as a combobox that is not editable: named by label (SEL-11), with the chosen option's label as its value (the placeholder is not a value), and WHILE the list is open aria-controls naming the list box and aria-activedescendant naming the active option — WHILE the list is closed THE select SHALL set neither, so that its container never names an element that is not exposed —; and WHILE the list is open THE select SHALL keep the list box in the accessibility tree, also WHERE it holds no option and the list shows its status row or empty text alone (SEL-68): an empty list box that takes no room, is no focus or pointer target and holds nothing to read; and the list as a listbox named by label whose options are named by their label and described by their supporting text, each with its selected state — true for the chosen option alone — its disabled state, its position and the number of options, counted among all the options also where a long list draws only some of their rows (SEL-25), and whose groups are groups named by their title. On the other platforms THE select SHALL expose the container as the platform's control that opens a list of choices (a pop-up button, a drop-down list, a combo box) named by label with the chosen option's label as its value and its expanded state, and the options as selectable items in a list with the same names, states and positions. Icons, the chevron, the check and the divider SHALL be hidden from assistive technology."},{"id":"SEL-49","text":"WHILE no Field frames it and the product gives it no width THE select SHALL be as wide as its widest option would make it — the widest option label in the value's text style, with the leading icon column where the select or any option has a leading icon, the room of the clear button WHILE clearable is true (SEL-72), the chevron, the gaps and the paddings — so that choosing an option never changes its width, and at least as wide as its placeholder needs; it SHALL never be wider than its layout gives it, cutting the value instead (SEL-16), and WHERE the product gives it a width it SHALL fill that width. WHILE a Field frames it THE select SHALL fill the width that Field gives it (FLD-1), as a text input does, so that a field of a form is as wide as its column whatever control it holds; the width of such a pair is given to the Field."},{"id":"SEL-51","text":"WHILE the text size is enlarged THE select SHALL grow its container with the value's line, keeping the height of its size as a minimum and its glyphs at their sizes, SHALL keep the value on one line, SHALL wrap its options, its group titles and the status row's text rather than cut them, and SHALL scroll its list where the taller options no longer fit (SEL-25), so that text enlarged to 200% loses no content in the list and none but a cut value in the container, which the list and assistive technology still give in full."},{"id":"SEL-52","text":"WHERE the platform draws with a person's own forced colors (the web's forced-colors mode, and a platform's equivalent where it has one) THE select SHALL draw its floating label, that label's asterisk and the status row's text, in error too, in the platform's text color, and SHALL rely on no color of its own to show an error: the error is carried by the invalid state (SEL-9) and by the words the Field that frames it shows, in that Field's own rows (FLD-17)."},{"id":"SEL-53","text":"WHERE the platform draws with a person's own forced colors THE select SHALL draw an edge comp.input-box.outline.width wide in the platform's control text color around its container in every variant, that edge in the platform's highlight color at the focused width while focused, an edge sys.border.hairline wide in the platform's text color round its list, as a popover's container has (POP-32), the active option in the platform's highlight colors, and a disabled select and a disabled option in the platform's disabled text color; the chosen option SHALL then be shown by its check alone."},{"id":"SEL-55","text":"WHERE the layout direction is right-to-left THE select SHALL mirror its container and its list: the leading icon at the right of the container and the clear button and the chevron at the left, the chevron nearest the edge, a floating label from the right edge with its asterisk at its left, the list aligned to the container's right edge (SEL-24), and in each option the leading icon at the right and the check at the left, all paddings applied by logical start and end. The rows of the Field that frames it mirror by FLD-18."},{"id":"SEL-56","text":"THE select SHALL take its layout direction from where it is used — the direction of the nearest ancestor that sets one, and the platform's own where none does — and SHALL have no direction setting of its own; WHEN that direction changes while the select is shown THE select SHALL draw itself for the new direction at once, without a motion of its own, keeping its value, its open state, its active option and its focus, the list placed again by the new direction (SEL-24)."},{"id":"SEL-57","text":"WHERE the layout direction is right-to-left THE select SHALL draw the glyph of its leading-icon slot and an option's leadingIcon mirrored left to right exactly when the system's icon set marks that glyph's name as mirrored or the product forces mirroring for that use, and unmirrored when the product forbids it: the icon helper mirrors the glyph inside its own box, about the box's vertical centre line, changing neither its place, size, color and fill nor the order SEL-55 gives. THE select SHALL NOT mirror a glyph itself, and SHALL NOT mirror content the product gives as an image or a view of its own rather than by a glyph's name. The chevron's expand_more and the check are not marked and are never mirrored. The glyph before the label of the Field that frames it is that Field's (FLD-20)."},{"id":"SEL-58","text":"THE select SHALL lay out its floating label as text of its own direction, isolated from the text around it: it takes the base direction of its first strong character, or the layout direction where it has none, so that a left-to-right word, a number with its sign or unit, a telephone number and an address keep their own order in a right-to-left layout and reorder nothing beside them; THE select SHALL still place it and align its lines by the layout direction, not by the text's own. The texts of the rows of the Field that frames it are laid out by FLD-21."},{"id":"SEL-59","text":"THE select SHALL lay out its placeholder, the value it shows, an option's label and supporting text, a group's title and the status row's text in the same way (SEL-58): each as text of its own direction, isolated, placed and aligned by the layout direction; and SHALL cut a value that does not fit (SEL-16) at the end of its own direction, so that a left-to-right value in a right-to-left layout loses its right end and never its beginning."},{"id":"SEL-60","text":"WHEN variant or size names a value that the active design system does not have THE select SHALL render with the default value's tokens, and in debug builds report the unknown value; WHEN variant names a value the active system has but the select does not know by name (one a layer added) it SHALL draw no label and draw its edge as a stacked select does (SEL-15, SEL-20), with that value's own tokens. WHEN status names a value the select does not define THE select SHALL behave as idle and in debug builds report it."},{"id":"SEL-61","text":"WHILE the select has nothing to show — it holds no option, status is idle, statusText is empty and it has no empty text (SEL-68) — THE select SHALL draw its trigger as it is, SHALL stay focusable, SHALL NOT open by any input or because open is true, and in debug builds SHALL report a select without options; it SHALL draw no empty list. WHILE it holds no option and has a status row or an empty text it SHALL open as any select does (SEL-23), its list holding that row alone."},{"id":"SEL-62","text":"THE select SHALL have no words of its own: it shows its options' labels, its placeholder, its name and the status row's statusText, each given by the product, and SHALL take its empty text from the instance's emptyText and, WHILE that is empty, from the product's words of the name noOptionsText — the words a product sets once for all its components — and its clear button's name from clearLabel and, WHILE that is empty, from the product's words of the same name, and from nowhere else. WHILE neither gives clearLabel the clear button is as SEL-72 says: drawn, working and reported. WHILE neither gives the empty text, the select draws no empty text (SEL-61) and, WHEN the person tries to open a select that holds nothing to show, reports once in debug builds that the words are missing. The words of a requirement are read by the Field that frames it (FLD-24)."},{"id":"SEL-63","text":"THE select SHALL say to the Field that frames it what only the select knows, and SHALL say it again WHEN it changes: that it draws the label itself WHILE its variant floats one (SEL-15), so that the Field draws no label row (FLD-25); how far its value stands from its own start edge — its inline padding and, beside a leading icon, that icon and its gap (SEL-1, SEL-18) — and the padding it keeps at its end edge (SEL-1), so that the Field's supporting row starts and ends there (FLD-26); and that it is drawn focused WHILE its list is open (SEL-20), so that the Field draws its rows from their focused tokens for as long, whether or not the select has focus (FLD-13). It SHALL take from that Field its name, its description and its required, invalid and disabled states (SEL-9, SEL-11, SEL-46), whether the label is hidden (SEL-15) and whether an asterisk follows it (SEL-7), so that a Field and a select placed by hand are drawn, named, described and marked exactly as a select field is. THE select SHALL keep no count and report no refusal of an entry (FLD-27, FLD-28): it holds only what its options offer."},{"id":"SEL-64","text":"THE select SHALL draw no label row above itself, no requirement tag, no help and no error text: those are the rows of the Field that frames it (FLD-2 to FLD-7). WHILE no Field frames it THE select SHALL be complete as a bare control — its container, the label that floats in it where its variant floats one, the value it shows, its list and its options, its states and its events — named by its own label, and exactly as tall as its container."},{"id":"SEL-65","text":"THE select SHALL draw its box from the one set of tokens every input box is drawn from, the group comp.input-box (comp.input-box.container.shape, comp.input-box.container.height.medium, and so on): its container, its corners, its edges and their widths, the label that floats in it and the asterisk after it, the line that shows the chosen value and the placeholder, the leading icon and the chevron, the paddings, the gaps and the least height of its size (a stacked box's from comp.input-box.stacked.container.height.medium and comp.input-box.stacked.container.padding-block.medium for size medium, as tall as a Button of the same size, and a filled or an outlined box's from comp.input-box.container.height.medium and comp.input-box.container.padding-block.medium, and so on) — small included, and the colors of each of these in its look, at rest, hovered, focused and disabled, plain and in error. It SHALL have no token of its own for any of them: the tokens of its own group are the list's — its surface, its options and their states, its groups, its motion (SEL-25, SEL-37 to SEL-42). WHEN a design system or a product sets a token of the box THE select SHALL follow it, as the text input, the combobox, the number input and the color input do, which read the same tokens; no token is held equal to another for this. WHERE one select is to differ from the other boxes of a product, the token is set for that instance — on its element or on a subtree that holds it, in each platform's way of setting a token for a subtree — and THE select SHALL draw itself from the value it finds there."},{"id":"SEL-66","text":"THE select SHALL decide the leading icon column for each section of its list — an option group, with the options of a group inside it (SEL-44), or a run of adjacent options outside any group: the parts SEL-45 separates. WHILE iconSpace is auto an option SHALL keep the column, empty where it has no icon, WHERE an option of its section has a leading icon, so that the labels of a section start on one line, and a section where no option has one SHALL keep no column, its labels starting at the row's content start; WHILE iconSpace is always every option SHALL keep the column, whether or not any option of the list has an icon; WHILE iconSpace is never an option SHALL have the column only where it has a leading icon itself. The column kept is comp.select.option.leading-icon.size.medium wide with comp.select.option.gap.medium after it, draws nothing and is nothing to assistive technology. A group's title SHALL keep its own place whatever the column of its section is (SEL-44). WHEN an option is added or removed, or an option's leadingIcon changes, THE select SHALL decide its section again; WHEN iconSpace names a value the select does not define THE select SHALL treat it as auto and in debug builds report the unknown value."},{"id":"SEL-68","text":"WHILE the list is open and statusText is not empty or status is loading THE select SHALL draw, after the last option, a status row, outside the region that scrolls, under it and inside the list's surface, so that the region that scrolls is the list box the keys move through and the row stays in view while the options scroll (SEL-25): inset by comp.select.option.padding-inline.medium at the sides and padded by comp.select.option.padding-block.medium above and below, taking no input, no state and no focus, never the active option and never reached by typing (SEL-33). WHILE status is idle it SHALL draw statusText, wrapping, in comp.select.status.typescale and comp.select.status.color; WHILE status is error it SHALL draw it in comp.select.status.error.color; WHILE status is loading it SHALL draw, in the text's place and at the row's start, one Tanrei loading indicator of size small named by statusText, which waits its own show delay and enters as the loading indicator does (LDG-11 to LDG-14), and no text, and the row SHALL keep the height of one line of text whether or not the indicator is shown yet. The options the product leaves in the list WHILE status is loading or error SHALL stay drawn and choosable. WHILE the select holds no option, status is idle and statusText is empty THE select SHALL draw its empty text — emptyText, else the product's words (SEL-62) — in the status row's place and style, so that a person who opens a list with nothing in it is told why instead of facing a select that does not open; WHILE neither gives it the select has nothing to show (SEL-61). The row and the empty text are the combobox's (CMB-32) with the select's own tokens, which hold the combobox's values in every shipped design system; a select filters nothing, so its list is empty only while it holds no option."},{"id":"SEL-69","text":"THE select SHALL expose the status row as a live region that is present while the list is shown and holds nothing while it is closed: WHEN the list has been shown, and WHILE it is open WHEN statusText changes or the empty text appears, THE select SHALL have assistive technology read the row's text — politely, after what it is saying, WHILE status is idle (the status role on the web), and at once WHILE status is error (the alert role) — so that what the row already says as the list opens is read as well as what it comes to say, focus staying on the container (SEL-26). WHILE status is loading it SHALL announce nothing — the loading indicator does not announce itself (LDG-6) — and SHALL mark the list box as busy (aria-busy on the web) until status leaves loading. THE select SHALL NOT compose, count or translate a text: the number of options is already exposed by the list (SEL-48), and the words are the product's."},{"id":"SEL-70","text":"THE select SHALL draw the options and the group titles of its list at the size its box is drawn at — its own size, or WHILE it sets none the size a container around it gives it (SEL-73): small WHILE the box is drawn small, and medium WHILE it is drawn medium or large, a size the options lack being taken as the nearest one they have, the larger on a tie, as a container's size is; the list SHALL take a container's size only through its box, because it stands in the top layer, apart from the controls around the box, and belongs to the box that opens it. WHILE it draws medium they SHALL take the medium value of every token of the option-size axis this spec names (comp.select.option.height.medium, comp.select.option.padding-block.medium, comp.select.option.padding-inline.medium, comp.select.option.gap.medium, comp.select.option.leading-icon.size.medium, comp.select.option.mark.size.medium, comp.select.group-title.padding-inline.medium); WHILE it draws small they SHALL take the small value of each in its place (comp.select.option.height.small, comp.select.option.padding-block.small, comp.select.option.padding-inline.small, comp.select.option.gap.small, comp.select.option.leading-icon.size.small, comp.select.option.mark.size.small, comp.select.group-title.padding-inline.small), so that a small option is lower, set in less from its edges and draws smaller glyphs, the room kept for an empty leading icon column (SEL-66) shrinking with them; the heights follow the system's height ladder at either size. The text styles, the list's surface and its paddings, the dividers, the group gap and the status row SHALL be the same at both. WHEN the size the box is drawn at names a value the active design system's options do not have and that is not one of the ladder's (extra-small, small, medium, large, extra-large) THE select SHALL draw the default size's rows and in debug builds report the unknown value; a size a design system added to the options SHALL be drawn from that size's tokens, as the core values are. WHEN the size the box is drawn at changes while the list is open — its own size set, changed or removed, or the size a container gives it — THE select SHALL draw the new rows at once, without a motion, keeping the active option."},{"id":"SEL-71","text":"WHERE the platform has ARIA attributes (the web), WHEN the product sets an aria- attribute on the host, by the attribute or by the ARIA property that reflects it, THE select SHALL move it to the data-aria- attribute of the same name, so that the host is no second node with its name, description or state, and SHALL expose it on the element that carries its role — an id reference by the elements it names in the host's tree or a tree around it, an error message as part of the description while the select is invalid — except those the select owns (aria-haspopup, aria-expanded, aria-controls, aria-disabled), which it SHALL move and not expose. WHEN the product removes the aria- attribute or its data-aria- twin, or sets the ARIA property that reflects it (ariaLabel, ariaDescribedByElements…) to null, THE select SHALL take it off that element. WHEN the product sets an aria- attribute the select owns THE select SHALL report it in debug builds."},{"id":"SEL-72","text":"WHILE clearable is true and the select is neither disabled nor read-only THE select SHALL keep, at the end of its container before the chevron and comp.select.container.action-gap from it, the room of a clear button, and SHALL draw the button in that room WHILE value is not empty: an icon-only Tanrei Button of the text variant at Button's small size showing the glyph close of the system's icon set, not mirrored, its glyph centred in a box of the glyphs' size (comp.input-box.icon.size.medium for size medium, and so on), named by clearLabel, a Button in every respect — its own tokens, its press, focus ring and target (BTN-5, BTN-8, BTN-9, BTN-10) — and a focus stop after the container. The room SHALL be kept whether or not the button is drawn, so that the chevron stays where it is and a select given no width keeps its width (SEL-49) as a value is chosen and cleared. The button SHALL stand over the container and SHALL NOT be part of it: it is no child of the combobox in the accessibility tree, a press on it is no press on the container (SEL-23) and no press outside the select (SEL-27), and it neither opens nor closes the list. WHEN the button is activated THE select SHALL make value empty — it then shows the placeholder, or the option whose value is the empty string where it holds one (SEL-17) —, emit change once, move focus to the container, and leave its list as it is, open or closed, with no option chosen in it. WHILE clearable is false THE select SHALL draw no clear button and keep no room for one: a person changes the value only by choosing an option (SEL-34). WHILE clearLabel is empty and the product's words give none THE select SHALL still draw the button, working, and in debug builds report that it has no accessible name."},{"id":"SEL-73","text":"WHILE size is not set and a container around the select sets a size for what it holds — a toolbar's size (TBR-31), or another container that passes its size to a Button (BTN-48), the nearest such container where several do — THE select SHALL draw its box at that size, its height following the system's height ladder as at a size of its own, and at its nearest size where it has none of that name, in the order extra-small, small, medium, large, extra-large, the larger of two as near; a container whose size is not set SHALL pass none. WHILE size is set THE select SHALL be drawn at its own size, whatever a container sets. WHEN the size it takes changes — a container's size set, changed or removed, its own size set or removed, or the select moved into or out of such a container — THE select SHALL be drawn at the size it now takes at once. It takes a container's size as a Button does because a stacked box and a Button of one size stand as tall as each other: in a small toolbar the box stands as tall as the small Buttons beside it. The options of the list it opens are drawn at the size the box is drawn at (SEL-70): in a small toolbar a select without a size opens small rows."},{"id":"SEL-74","text":"WHEN the control height (dial.control.height) is N THE select's default row SHALL be N tall: an option of a medium or large select SHALL be drawn at comp.select.option.height.medium, which is sys.control.height.medium held at sys.target.minimum, and an option of a small select at comp.select.option.height.small, a small menu item's, so that its options stand as tall as a menu's items and as the field that opens them; the option's block padding SHALL give up half of what its height loses below the control height's reference, so that its line still fits, and the pointer and touch targets SHALL still hold the row up where they are taller (SEL-37)."},{"id":"SEL-75","text":"WHEN the control height (dial.control.height) is N THE select's default box SHALL be N tall in every look: a medium select SHALL be drawn at comp.input-box.stacked.container.height.medium WHILE it is stacked and at comp.input-box.container.height.medium WHILE it is outlined or filled, each sys.control.height.medium held at sys.target.minimum, so that it stands as tall as the Buttons beside it; the box's block paddings SHALL give up half of what its height loses below the control height's reference, so that one line of its value still fits, and the pointer and touch targets SHALL still reach beyond a box that is lower than they are. WHILE a filled select draws its label it holds the floated label above the value's line and SHALL be as tall as SEL-1 gives where that is more than N."}],"accessibility":{"role":"combobox","keyboard":[{"keys":"Tab / Shift+Tab","action":"Moves focus to the select, which is one stop, and on from it; while the clear button is shown it is the next stop. With the list open, closes the list without choosing and moves focus on."},{"keys":"Enter, Space, Down Arrow or Up Arrow, list closed","action":"Opens the list; the chosen option is the active one, or the first enabled option where none is chosen. The value does not change."},{"keys":"Down Arrow / Up Arrow, list open","action":"Makes the next or previous option active, across groups, stopping at the ends."},{"keys":"Home / End, list open","action":"Makes the first or the last option active."},{"keys":"Page Down / Page Up, list open","action":"Moves the active option by ten, stopping at the ends."},{"keys":"Printable characters","action":"Opens the list while it is closed; makes active the next option whose label begins with the characters typed within a second of each other. The value does not change."},{"keys":"Enter or Space, list open","action":"Chooses the active option, emits change if the value changed, and closes the list. On a disabled option, nothing. A Space typed while typing ahead is a character."},{"keys":"Escape","action":"Closes the list without choosing; focus stays on the select. With the list closed the select does not act on it."},{"keys":"Enter or Space on the clear button","action":"Empties the value, emits change, and returns focus to the select (SEL-72)."}],"labeling":"The accessible name of the select and of its list is the label of the Field that frames it, or its own label where no Field does; a filled or outlined select draws that name floating, and labelHidden only stops the drawing. The placeholder is never the name and never the value. The chosen option's label is the select's value. The description is what the Field gives: its supporting text with, in error, the error text after it and its optional text. The select is exposed as invalid while error is true or its Field is in error, required while its Field says so — whichever mark is drawn, and the mark itself is hidden — read-only while readOnly is true, and expanded while its list is open. An option is named by its label and described by its supporting text, and exposes whether it is the chosen one, whether it is disabled, and its position among the options; a group is named by its title. The status row is a live region: what it says is read when the list opens and when it changes, politely, and at once while the source failed; while the options are loading the list box is busy and nothing is announced. The clear button is a button named by clearLabel, after the select and not inside it. The leading icons, the chevron, the check and the divider are decorative.","minimumTarget":true,"notes":["The select is the bare control: it draws no label row, no requirement mark, no help and no error. In a form it stands in a Field, which is the select field; alone it is for a place where its label stands elsewhere or is plain from where it stands and what it shows — a theme or a language select in a header, a toolbar, a column of a table — and there its own label names it.","The pattern is the WAI-ARIA select-only combobox: focus stays on the field and the active option is its active descendant on the web, as the search's suggestions are (SRC-14), not moved into the list as the menu moves it. The field keeps its name, its description, its invalid and required states and its focused edge while the person reads the options, and typing keeps going to one place. SwiftUI, Compose, Flutter and React Native have no active descendant: there the list's options are focusable items that assistive technology moves through, and a hardware keyboard's arrow keys move the highlight as on the web.","The value changes only when the person confirms an option: a press, Enter or Space. Arrow keys and typing on a closed select open the list instead of changing the value unseen, and Tab, Escape and a press outside close it without choosing, as the menu and the docked picker close without committing (MNU-5, DTM-5). A change event may navigate, save or rebuild a page, so it must never follow a key the person pressed for something else.","A select holds one value from a closed list. Several values are checkboxes, or a list with multiple selection; a list long enough that people would rather type than scroll, or one that accepts a value not in it, is a combobox, which shares this box, this list and these options and adds a text input. A set of actions is a menu: a menu item does something, an option is a value.","Status: a select whose options come from a source that takes time or can fail says so in its list, as the combobox and the search do, with the same three props: status loading while they are on their way (the list box is busy, and a loading indicator named by statusText stands in the status row), status error with statusText saying what failed, and statusText alone for what the list should add (a count). A select that holds no option says why in emptyText, rather than not opening. The select never fetches, waits or retries: the product sets status, and the words are the product's. The loading and empty states are those of the ARIA listbox and combobox patterns, said in a live region outside the list box, as React Aria's and MUI's lists and Ant Design's select show them.","With up to about five short options and room for them, a radio group or tabs show every choice at once and take one press; a select hides the choices behind a press and is for many options or little room.","Overlay: the list is an operated overlay that is not modal. It draws no scrim, traps nothing and makes nothing inert. It is placed, sized, dismissed and moved as a popover's container is, by the popover's rules cited by id, with three rules of its own: focus stays on the field, Tab closes at once, and what it opens is a list box.","Heights are minimums: at 200% text size the container and the options grow, labels and options wrap, and only the value in the container stays on one line (SEL-51). The list scrolls when it no longer fits; it never scrolls sideways.","The chosen option is told from the others by its check, never by its fill alone; the fill supports the mark and is not held to a contrast of its own. Content on it keeps at least 4.5:1 in every state, by the menu's tokens.","An error is never shown by color alone: the invalid state carries it and the error text of the Field that frames the select says it; the line inside a stacked select's edge supports them.","The hit area of the container meets the minimum target although a small select is 40 high, and options are at least the minimum target tall (WCAG 2.5.8).","A disabled option stays reachable by the arrow keys and is read as unavailable; a select with a single option, or none, is still a select and says so, rather than turning into text.","How a state looks is a value decision of the active design system; components read the state's tokens and never compute the effect themselves.","WCAG 2.5.8 (target size): every option is drawn at least the touch target high for touch and the pointer target high for a fine pointer, at every size (SEL-37), because rows that touch cannot reach past each other. In the default system both are the minimum target, at which a small option is held; a system that sets either higher draws its small options that high.","Clearing: a select whose value may be none either lists an option for none (\"Any\", \"Not set\") or, with clearable, draws a clear button after it. The button is a focus stop of its own beside the combobox, never inside it: a control inside a combobox is a nested interactive element that assistive technology cannot reach, and a key on the combobox that clears would empty the value unseen (WAI-ARIA select-only combobox; Ant Design's allowClear and Fluent's clearable dropdown are the same button)."]},"tokens":"comp.select","fixtures":[{"id":"stacked-empty","props":{"variant":"stacked","label":"Country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-value","props":{"variant":"stacked","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-open","props":{"variant":"stacked","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-large","props":{"variant":"stacked","size":"large","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-small","props":{"variant":"stacked","size":"small","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-error","props":{"variant":"stacked","label":"Country","error":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-disabled","props":{"variant":"stacked","label":"Country","value":"jp","disabled":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-empty","props":{"variant":"filled","label":"Country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-value","props":{"variant":"filled","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-open","props":{"variant":"filled","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-large","props":{"variant":"filled","size":"large","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-small","props":{"variant":"filled","size":"small","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-error","props":{"variant":"filled","label":"Country","error":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"filled-disabled","props":{"variant":"filled","label":"Country","value":"jp","disabled":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-empty","props":{"variant":"outlined","label":"Country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-value","props":{"variant":"outlined","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-open","props":{"variant":"outlined","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-large","props":{"variant":"outlined","size":"large","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-small","props":{"variant":"outlined","size":"small","label":"Country","value":"jp"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-error","props":{"variant":"outlined","label":"Country","error":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-disabled","props":{"variant":"outlined","label":"Country","value":"jp","disabled":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-placeholder","props":{"label":"Country","placeholder":"Choose a country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-open-none-chosen","props":{"label":"Country","placeholder":"Choose a country","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-error-value","props":{"label":"Country","value":"ke","error":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-read-only","props":{"label":"Country","value":"jp","readOnly":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-clearable","props":{"variant":"stacked","label":"Country","value":"jp","clearable":true,"clearLabel":"Clear country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-clearable-empty","props":{"variant":"stacked","label":"Country","placeholder":"Any country","clearable":true,"clearLabel":"Clear country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"outlined-clearable","props":{"variant":"outlined","label":"Country","value":"jp","clearable":true,"clearLabel":"Clear country"},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"stacked-option-icon","props":{"label":"Theme","value":"dark"},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"stacked-leading-icon","props":{"label":"Language","value":"ja"},"slots":{"leading-icon":"translate"},"items":[{"kind":"option","props":{"label":"English","value":"en"}},{"kind":"option","props":{"label":"日本語","value":"ja"}}]},{"id":"open-icons","props":{"label":"Theme","value":"dark","open":true},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"open-supporting-text","props":{"label":"Plan","value":"team","open":true},"items":[{"kind":"option","props":{"label":"Free","value":"free","supportingText":"One project, community help"}},{"kind":"option","props":{"label":"Team","value":"team","supportingText":"Unlimited projects, shared roles"}},{"kind":"option","props":{"label":"Enterprise","value":"enterprise","supportingText":"Single sign-on and an audit log","disabled":true}}]},{"id":"open-disabled-chosen","props":{"label":"Plan","value":"enterprise","open":true},"items":[{"kind":"option","props":{"label":"Free","value":"free","supportingText":"One project, community help"}},{"kind":"option","props":{"label":"Team","value":"team","supportingText":"Unlimited projects, shared roles"}},{"kind":"option","props":{"label":"Enterprise","value":"enterprise","supportingText":"Single sign-on and an audit log","disabled":true}}]},{"id":"open-groups","props":{"label":"Time zone","value":"Europe/Lisbon","open":true},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}]},{"id":"open-groups-divider","props":{"label":"Time zone","value":"Europe/Lisbon","open":true,"separation":"divider"},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}]},{"id":"open-groups-gap","props":{"label":"Time zone","value":"Europe/Lisbon","open":true,"separation":"gap"},"items":[{"kind":"option-group","props":{"title":"Asia"},"items":[{"kind":"option","props":{"label":"Tokyo","value":"Asia/Tokyo"}},{"kind":"option","props":{"label":"Seoul","value":"Asia/Seoul"}},{"kind":"option","props":{"label":"Singapore","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"Europe"},"items":[{"kind":"option","props":{"label":"Lisbon","value":"Europe/Lisbon"}},{"kind":"option","props":{"label":"Berlin","value":"Europe/Berlin"}}]},{"kind":"option-group","props":{},"items":[{"kind":"option","props":{"label":"Coordinated Universal Time","value":"UTC"}}]}]},{"id":"open-many","props":{"label":"Token","value":"corner.small","open":true},"items":[{"kind":"option","props":{"label":"space25","value":"space25"}},{"kind":"option","props":{"label":"space50","value":"space50"}},{"kind":"option","props":{"label":"space75","value":"space75"}},{"kind":"option","props":{"label":"space100","value":"space100"}},{"kind":"option","props":{"label":"space125","value":"space125"}},{"kind":"option","props":{"label":"space150","value":"space150"}},{"kind":"option","props":{"label":"space175","value":"space175"}},{"kind":"option","props":{"label":"space200","value":"space200"}},{"kind":"option","props":{"label":"space250","value":"space250"}},{"kind":"option","props":{"label":"space300","value":"space300"}},{"kind":"option","props":{"label":"space400","value":"space400"}},{"kind":"option","props":{"label":"space500","value":"space500"}},{"kind":"option","props":{"label":"space600","value":"space600"}},{"kind":"option","props":{"label":"space800","value":"space800"}},{"kind":"option","props":{"label":"space1000","value":"space1000"}},{"kind":"option","props":{"label":"corner.none","value":"corner.none"}},{"kind":"option","props":{"label":"corner.extra-small","value":"corner.extra-small"}},{"kind":"option","props":{"label":"corner.small","value":"corner.small"}},{"kind":"option","props":{"label":"corner.medium","value":"corner.medium"}},{"kind":"option","props":{"label":"corner.large","value":"corner.large"}},{"kind":"option","props":{"label":"corner.extra-large","value":"corner.extra-large"}},{"kind":"option","props":{"label":"corner.full","value":"corner.full"}},{"kind":"option","props":{"label":"border.hairline","value":"border.hairline"}},{"kind":"option","props":{"label":"border.thick","value":"border.thick"}}]},{"id":"open-long-options","props":{"label":"Email me","value":"weekly","open":true},"items":[{"kind":"option","props":{"label":"Send me a summary once a week, on Monday morning, in the time zone of my account","value":"weekly"}},{"kind":"option","props":{"label":"Send me every notification as it happens, including the ones about threads I only follow","value":"all"}},{"kind":"option","props":{"label":"Never","value":"never"}}]},{"id":"long-value","props":{"label":"Email me","value":"all"},"items":[{"kind":"option","props":{"label":"Send me a summary once a week, on Monday morning, in the time zone of my account","value":"weekly"}},{"kind":"option","props":{"label":"Send me every notification as it happens, including the ones about threads I only follow","value":"all"}},{"kind":"option","props":{"label":"Never","value":"never"}}]},{"id":"empty-value-option","props":{"label":"Contrast","value":""},"items":[{"kind":"option","props":{"label":"Standard","value":""}},{"kind":"option","props":{"label":"Medium","value":"medium"}},{"kind":"option","props":{"label":"High","value":"high"}}]},{"id":"small-label-hidden","props":{"size":"small","label":"Contrast","value":"high"},"items":[{"kind":"option","props":{"label":"Standard","value":""}},{"kind":"option","props":{"label":"Medium","value":"medium"}},{"kind":"option","props":{"label":"High","value":"high"}}]},{"id":"small-label-hidden-icons","props":{"size":"small","label":"Theme","value":"light"},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"small-label-hidden-leading-icon","props":{"size":"small","label":"Language","value":"en"},"slots":{"leading-icon":"translate"},"items":[{"kind":"option","props":{"label":"English","value":"en"}},{"kind":"option","props":{"label":"日本語","value":"ja"}}]},{"id":"small-label-hidden-open","props":{"size":"small","label":"Theme","value":"light","open":true},"items":[{"kind":"option","props":{"label":"Light","value":"light","leadingIcon":"light_mode"}},{"kind":"option","props":{"label":"Dark","value":"dark","leadingIcon":"dark_mode"}},{"kind":"option","props":{"label":"Follow the device","value":"auto","leadingIcon":"computer"}}]},{"id":"small-open","props":{"size":"small","label":"Country","value":"jp","open":true},"items":[{"kind":"option","props":{"label":"Canada","value":"ca"}},{"kind":"option","props":{"label":"France","value":"fr"}},{"kind":"option","props":{"label":"Japan","value":"jp"}},{"kind":"option","props":{"label":"Kenya","value":"ke"}},{"kind":"option","props":{"label":"New Zealand","value":"nz"}}]},{"id":"open-rtl","props":{"label":"المنطقة الزمنية","value":"Asia/Tokyo","open":true},"direction":"rtl","items":[{"kind":"option-group","props":{"title":"آسيا"},"items":[{"kind":"option","props":{"label":"طوكيو","value":"Asia/Tokyo","leadingIcon":"arrow_forward"}},{"kind":"option","props":{"label":"سنغافورة","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"أوروبا"},"items":[{"kind":"option","props":{"label":"برلين","value":"Europe/Berlin"}},{"kind":"option","props":{"label":"Lisbon (WET)","value":"Europe/Lisbon"}}]}]},{"id":"long-value-rtl","props":{"label":"Email me","value":"all"},"direction":"rtl","items":[{"kind":"option","props":{"label":"Send me a summary once a week, on Monday morning, in the time zone of my account","value":"weekly"}},{"kind":"option","props":{"label":"Send me every notification as it happens, including the ones about threads I only follow","value":"all"}},{"kind":"option","props":{"label":"Never","value":"never"}}]},{"id":"outlined-rtl","props":{"variant":"outlined","label":"المنطقة الزمنية","value":"Europe/Lisbon"},"direction":"rtl","items":[{"kind":"option-group","props":{"title":"آسيا"},"items":[{"kind":"option","props":{"label":"طوكيو","value":"Asia/Tokyo","leadingIcon":"arrow_forward"}},{"kind":"option","props":{"label":"سنغافورة","value":"Asia/Singapore"}}]},{"kind":"option-group","props":{"title":"أوروبا"},"items":[{"kind":"option","props":{"label":"برلين","value":"Europe/Berlin"}},{"kind":"option","props":{"label":"Lisbon (WET)","value":"Europe/Lisbon"}}]}]},{"id":"clearable-rtl","direction":"rtl","props":{"variant":"stacked","label":"البلد","value":"jp","clearable":true,"clearLabel":"مسح البلد"},"items":[{"kind":"option","props":{"label":"كندا","value":"ca"}},{"kind":"option","props":{"label":"فرنسا","value":"fr"}},{"kind":"option","props":{"label":"اليابان","value":"jp"}},{"kind":"option","props":{"label":"كينيا","value":"ke"}}]},{"id":"icon-space-auto","props":{"label":"Share to","value":"mail","open":true},"items":[{"kind":"option-group","props":{"title":"Apps"},"items":[{"kind":"option","props":{"label":"Mail","value":"mail","leadingIcon":"mail"}},{"kind":"option","props":{"label":"Messages","value":"messages","leadingIcon":"chat"}},{"kind":"option","props":{"label":"Copy link","value":"link"}}]},{"kind":"option-group","props":{"title":"Files"},"items":[{"kind":"option","props":{"label":"Print","value":"print"}},{"kind":"option","props":{"label":"Save as PDF","value":"pdf"}}]}]},{"id":"icon-space-always","props":{"label":"Share to","value":"mail","open":true,"iconSpace":"always"},"items":[{"kind":"option-group","props":{"title":"Apps"},"items":[{"kind":"option","props":{"label":"Mail","value":"mail","leadingIcon":"mail"}},{"kind":"option","props":{"label":"Messages","value":"messages","leadingIcon":"chat"}},{"kind":"option","props":{"label":"Copy link","value":"link"}}]},{"kind":"option-group","props":{"title":"Files"},"items":[{"kind":"option","props":{"label":"Print","value":"print"}},{"kind":"option","props":{"label":"Save as PDF","value":"pdf"}}]}]},{"id":"icon-space-never","props":{"label":"Share to","value":"mail","open":true,"iconSpace":"never"},"items":[{"kind":"option-group","props":{"title":"Apps"},"items":[{"kind":"option","props":{"label":"Mail","value":"mail","leadingIcon":"mail"}},{"kind":"option","props":{"label":"Messages","value":"messages","leadingIcon":"chat"}},{"kind":"option","props":{"label":"Copy link","value":"link"}}]},{"kind":"option-group","props":{"title":"Files"},"items":[{"kind":"option","props":{"label":"Print","value":"print"}},{"kind":"option","props":{"label":"Save as PDF","value":"pdf"}}]}]},{"id":"size-small","props":{"label":"Share to","value":"mail","open":true,"size":"small"},"items":[{"kind":"option-group","props":{"title":"Apps"},"items":[{"kind":"option","props":{"label":"Mail","value":"mail","leadingIcon":"mail"}},{"kind":"option","props":{"label":"Messages","value":"messages","leadingIcon":"chat"}},{"kind":"option","props":{"label":"Copy link","value":"link","supportingText":"Anyone with the link"}}]},{"kind":"option-group","props":{"title":"Files"},"items":[{"kind":"option","props":{"label":"Print","value":"print"}},{"kind":"option","props":{"label":"Save as PDF","value":"pdf"}}]}]},{"id":"open-loading","props":{"label":"Project","placeholder":"Choose a project","open":true,"status":"loading","statusText":"Loading projects"},"items":[]},{"id":"open-status","props":{"label":"Project","value":"atlas","open":true,"statusText":"Your 3 most recent projects. Search for others on the Projects page."},"items":[{"kind":"option","props":{"label":"Atlas","value":"atlas"}},{"kind":"option","props":{"label":"Beacon","value":"beacon"}},{"kind":"option","props":{"label":"Comet","value":"comet"}}]},{"id":"open-status-error","props":{"label":"Project","placeholder":"Choose a project","open":true,"status":"error","statusText":"Projects could not be loaded. Check your connection."},"items":[]},{"id":"open-empty","props":{"label":"Project","placeholder":"Choose a project","open":true,"emptyText":"No projects yet"},"items":[]}],"platforms":{"web":{"status":"lagging","name":"tanrei-select","props":{"variant":"variant","size":"size","value":"value","label":"label","labelHidden":"labelHidden","placeholder":"placeholder","error":"error","disabled":"disabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearLabel","open":"open","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"change","toggle":"toggle"},"items":{"option":{"name":"tanrei-option","props":{"label":"label","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"disabled"},"notes":"`<tanrei-option value=\"jp\">Japan</tanrei-option>`: the label is the `label` attribute or, without one, the element's text, as `<option>`. Attributes `supporting-text`, `leading-icon`, `disabled`. `data-mirror` (`auto`, the default; `always`; `never`) on an option is the product's word on mirroring the glyph its `leading-icon` names, in the list and in the container (SEL-57), as on a glyph the product places itself. The element is data for its select: it draws nothing itself. `tanrei-option` and `tanrei-option-group` are one pair of elements for the select and the combobox: a select that needs a filter becomes a combobox with the same children. Whether an option may have the empty value is each parent's rule (a select's may, SEL-17; a combobox's may not)."},"option-group":{"name":"tanrei-option-group","props":{"title":"label"},"notes":"The title is the `label` attribute, as `<optgroup label>` and `<tanrei-menu-group label>`: a `title` attribute would also draw the browser's tooltip."}},"parts":{"container":"container","outline":"outline","active-indicator":"active-indicator","label":"label","required-asterisk":"requirement-label","value":"value","placeholder":"placeholder","leading-icon":"leading-icon","clear-button":"clear-button","chevron":"chevron","list":"list","option":"option","option-label":"option-label","option-supporting-text":"option-supporting-text","option-leading-icon":"option-leading-icon","mark":"mark","group":"group","group-title":"group-title","divider":"divider","status":"status","focus-ring":"option@focus-ring"},"notes":"The tag `tanrei-select`, the class `TanreiSelect` and the React name `Select` are the bare control, without the frame: the label row, the requirement mark and the supporting row are the Field's, and `<tanrei-select-field>` is the select in its Field. A form-associated custom element (`static formAssociated = true`): it takes `name`, submits `value`, restores it on navigation (`formStateRestoreCallback`), resets to the value it was first given, follows `<fieldset disabled>` and reports `valueMissing` while the Field that frames it says it is required and `value` is empty. Its two calls on `ElementInternals` and its form go through the shared field primitives, which the select field, the form's element where it frames a select, repeats. The trigger is a `<div role=\"combobox\" tabindex=\"0\">` in the shadow root carrying the name, the description, `aria-invalid`, `aria-required`, `aria-readonly`, `aria-haspopup=\"listbox\"`, `aria-expanded`, `aria-controls` and `aria-activedescendant` — set on that element, not through ElementInternals, which axe cannot see. The name and the description are values the Field gives (`tanrei-field-connect`, `src/primitives/field.ts`), written into the select's own shadow root, the select's own `label` winning; the connection runs in both directions (SEL-63): the control's side says `drawsLabel`, `inset: { start, end }` (lengths the select writes from its own tokens and its measured icon box) and `drawnFocused` (true while the list is open), and takes `labelHidden` and `requiredMark` (`asterisk` or `none`) beside the name, the description and the three states. A select that a Field frames is a block that fills the Field's width (SEL-49); a bare one is an inline box as wide as its widest option, measured from a hidden grid cell that stacks every option's label in the value's style. The options are `<tanrei-option>` and `<tanrei-option-group>` elements, read as data and never drawn in place: the select renders the rows itself in its shadow root, so that the combobox, its `aria-controls` listbox and its `aria-activedescendant` option are in one tree. It reads them from its own children, and — in `src/primitives/option-list.ts`, for the combobox too — through any `<slot>` among its children: the elements assigned to that slot, flattened, stand in the slot's place, in order. That is how a select field's options, which are the product's children of `<tanrei-select-field>`, reach the select inside it, and how a product's own element can pass options on. Changes are observed on the children, on each such slot (`slotchange`) and on each element assigned through one. The list is a manual popover in the top layer, placed with CSS anchor positioning and a script fallback and followed with the `FollowController` the menu uses, with the select's own light dismiss so that `toggle` carries a reason; a press outside also reaches the element under it. The select sets its own `value` before firing `change` (a composed, bubbling Event, as a native select's) and its own `open` before firing `toggle`, a CustomEvent whose `detail` holds `open` and `reason` — which is composed and not bubbling: composed so that it is heard on a select field, not bubbling so that an ancestor's own `toggle` listener, a `<details>`'s, never hears a select's. Attributes: `label-hidden`, `readonly`, `clear-label`, the rest as the properties. The `leading-icon` slot is a named slot. Parts: `container`, `outline`, `active-indicator`, `label` (the floating label), `requirement-label` (its asterisk), `value`, `placeholder`, `leading-icon`, `clear-button`, `chevron`, `list`, `option`, `option-label`, `option-supporting-text`, `option-leading-icon`, `mark`, `group`, `group-title`, `divider`, `status`. The status row (SEL-68, SEL-69) is a `<div part=\"status\">` after the list box, outside it and outside the box that scrolls; its text is drawn in a span kept from assistive technology, and two visually hidden spans, `role=\"status\"` and `role=\"alert\"`, are its live regions, always in the shadow root and given the text one animation frame after the list is shown (empty while it is closed), so that what the row already says as the list opens is read. While loading the list box has `aria-busy=\"true\"` and the row holds one `<tanrei-loading-indicator size=\"small\">` named by `status-text`. `empty-text` left empty is read from the product's words (`setWords({ noOptionsText })`). The `inline` attribute, for tests and fixtures, draws the open list in place below the trigger. What belongs to the frame and not to the element: the attributes `supporting-text`, `error-text`, `required`, `optional`, `required-mark`, `required-text`, `optional-text`, the `label-icon` slot, the parts `label-icon` and `supporting-text`, and the label row of the stacked look. In a debug build the element reports any of those seven attributes, or a child for `label-icon`, once, and names `tanrei-select-field`: nothing is kept for them in a production build, and no alias exists. Before the element is defined its options are running text in the page; what a server-rendered page shows then is the product's to guard today: hide `tanrei-select:not(:defined) > *` and reserve the block size of the select's size, and where the page must work without script put a native `<select>` or links in a `<noscript>` beside it. The native `<select>` is not used inside: its list cannot be drawn with the system's tokens, groups, glyphs and supporting text. The chevron is the icon helper's `expand_more` and the check its `check`. The clear button (SEL-72) is a `<tanrei-button variant=\"text\" size=\"small\">` after the `role=\"combobox\"` element in the shadow root, placed over the container's end, so that no button is inside the combobox; the container keeps its room with a margin before the chevron. `clear-label` left empty is read from the product's words (`setWords({ clearLabel })`)."},"swiftui":{"status":"planned","name":"TanreiSelect","props":{"variant":"variant","size":"size","value":"selection","label":"label","labelHidden":"labelsHidden","placeholder":"prompt","error":"error","disabled":"disabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearLabel","open":"isPresented","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"selection","toggle":"isPresented"},"items":{"option":{"name":"TanreiSelectOption","props":{"label":"title","value":"tag","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"disabled"},"notes":"`TanreiSelectOption(_ title:, supportingText:, leadingIcon:).tag(value)`, as the content of a `Picker`; `disabled` follows `.disabled(_:)`."},"option-group":{"name":"TanreiSelectSection","props":{"title":"title"},"notes":"`TanreiSelectSection(_ title:) { … }`, as `Section`."}},"notes":"`TanreiSelect(_ label:, selection: Binding<String>) { TanreiSelectOption(\"Japan\").tag(\"jp\") … }`, shaped as `Picker`: the platform's control of this kind, whose call site and whose accessibility a product expects. SwiftUI's own `Picker` and `Menu` are not used to draw it, for the reason TanreiMenu gives: their lists cannot be drawn with the system's tokens. The trigger is Tanrei's own box; the list is presented as TanreiMenu presents its surface (`.popover` with `presentationCompactAdaptation(.popover)`, so it stays anchored on iPhone). Writing the binding is change; `isPresented` is an optional binding, and writing it is toggle. `labelHidden` follows `.labelsHidden()`, `disabled` follows `.disabled(_:)`. The trigger is one accessibility element with the button trait, the label as its label, the chosen option's label as its value and a pop-up hint; the options are buttons with the selected trait. A press outside does not reach what is under the list. With a hardware keyboard the arrow keys move the highlight and Return chooses, focus staying on the trigger. The bare control: `label` names it where no Field frames it and floats in a filled or outlined look; in a form it stands in `TanreiField`, which is `TanreiSelectField`."},"compose":{"status":"planned","name":"TanreiSelect","props":{"variant":"variant","size":"size","value":"value","label":"label","labelHidden":"labelHidden","placeholder":"placeholder","error":"isError","disabled":"enabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearContentDescription","open":"expanded","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"onValueChange","toggle":"onExpandedChange"},"items":{"option":{"name":"TanreiSelectOption","props":{"label":"text","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"enabled"},"notes":"`TanreiSelectOption(text, value, supportingText, leadingIcon, enabled)`, called in the select's content lambda."},"option-group":{"name":"TanreiSelectGroup","props":{"title":"title"},"notes":"`TanreiSelectGroup(title) { … }`."}},"notes":"Compose idiom, as an exposed dropdown menu (`ExposedDropdownMenuBox` with a read-only field): `TanreiSelect(value, onValueChange, label) { TanreiSelectOption(\"Japan\", \"jp\") … }`; the caller keeps `value` (state hoisting). `expanded` and `onExpandedChange` are optional: left out, the select keeps its own open state. `enabled` is the inverse flag and `isError` keeps Compose's name. The trigger is Tanrei's own box with `Role.DropdownList`, the label as its content description, the chosen label as its state description and the expanded state; the list is shown in a `Popup` as TanreiMenu's is, its options `selectable` with their selected state inside a `selectableGroup`. Material's own exposed dropdown is not used to draw it: its field and its menu take Material's tokens. A press outside also reaches what is under the list. The bare control: `label` names it where no Field frames it; in a form it stands in `TanreiField`, which is `TanreiSelectField`."},"flutter":{"status":"planned","name":"TanreiSelect","props":{"variant":"variant","size":"size","value":"value","label":"labelText","labelHidden":"labelHidden","placeholder":"hintText","error":"isError","disabled":"enabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearSemanticLabel","open":"controller","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"onChanged","toggle":"onOpenChanged"},"items":{"option":{"name":"TanreiSelectOption","props":{"label":"label","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"enabled"},"notes":"`TanreiSelectOption<String>(value:, label:, supportingText:, leadingIcon:, enabled:)`, in the select's `options` list, as `DropdownMenuEntry`."},"option-group":{"name":"TanreiSelectGroup","props":{"title":"title"},"notes":"`TanreiSelectGroup(title:, options: […])`, in the same list."}},"notes":"Flutter idiom, as `DropdownMenu` and `DropdownButtonFormField`: `TanreiSelect(value:, onChanged:, labelText:, options: […])`, with `hintText` and `enabled` keeping `InputDecoration`'s names, `enabled` the inverse flag. The list is shown in the `Overlay` with `OverlayPortal`, placed as TanreiMenuAnchor places its surface; an optional `TanreiSelectController` opens and closes it, and `onOpenChanged` is toggle. Semantics: the trigger is a button with `expanded`, the label as its label and the chosen label as its value; options carry `selected` and their index in the set. A press outside also reaches what is under the list. The bare control: `labelText` names it where no Field frames it; in a form it stands in `TanreiField`, which is `TanreiSelectField`."},"react-native":{"status":"planned","name":"Select","props":{"variant":"variant","size":"size","value":"value","label":"label","labelHidden":"labelHidden","placeholder":"placeholder","error":"error","disabled":"disabled","readOnly":"readOnly","clearable":"clearable","clearLabel":"clearAccessibilityLabel","open":"open","separation":"separation","iconSpace":"iconSpace","status":"status","statusText":"statusText","emptyText":"emptyText"},"events":{"change":"onValueChange","toggle":"onOpenChange"},"items":{"option":{"name":"SelectOption","props":{"label":"label","value":"value","supportingText":"supportingText","leadingIcon":"leadingIcon","disabled":"disabled"},"notes":"`{ label, value, supportingText?, leadingIcon?, disabled? }`: an element of the `options` array."},"option-group":{"name":"SelectOptionGroup","props":{"title":"title"},"notes":"`{ kind: 'group', title?, options: SelectOption[] }` in the same array."}},"notes":"`<Select label=\"Country\" value={value} onValueChange={setValue} options={[…]} />`: `options` is an array of options and groups, as Menu's `items`. `open` and `onOpenChange` are optional: left out, the select keeps its own open state. React Native has no select of its own on both platforms, so the list is Tanrei's on the overlay layer that `TanreiProvider` renders, placed by measuring the trigger, as Menu is. The trigger has `accessibilityRole=\"combobox\"`, `accessibilityState={{ expanded, disabled }}`, the label as `accessibilityLabel` and the chosen label as `accessibilityValue.text`; options are pressable rows with `accessibilityState={{ selected, disabled }}` and their position among the options in the label. Follows the app's direction where an ancestor's is not known. A press outside does not reach what is under the list. The bare control: `label` names it where no Field frames it; in a form it stands in `Field`, which is `SelectField`."}}}