@aurodesignsystem-dev/auro-formkit 0.0.0-pr593.0

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 (268) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/LICENSE +201 -0
  3. package/NOTICE +2 -0
  4. package/README.md +314 -0
  5. package/components/bibtemplate/dist/auro-bibtemplate.d.ts +39 -0
  6. package/components/bibtemplate/dist/headerVersion.d.ts +2 -0
  7. package/components/bibtemplate/dist/iconVersion.d.ts +2 -0
  8. package/components/bibtemplate/dist/index.d.ts +2 -0
  9. package/components/bibtemplate/dist/index.js +709 -0
  10. package/components/bibtemplate/dist/registered.js +709 -0
  11. package/components/bibtemplate/dist/styles/color-css.d.ts +2 -0
  12. package/components/bibtemplate/dist/styles/style-css.d.ts +2 -0
  13. package/components/bibtemplate/dist/styles/tokens-css.d.ts +2 -0
  14. package/components/checkbox/README.md +142 -0
  15. package/components/checkbox/demo/api.html +55 -0
  16. package/components/checkbox/demo/api.js +17 -0
  17. package/components/checkbox/demo/api.md +401 -0
  18. package/components/checkbox/demo/api.min.js +1833 -0
  19. package/components/checkbox/demo/index.html +51 -0
  20. package/components/checkbox/demo/index.js +8 -0
  21. package/components/checkbox/demo/index.md +327 -0
  22. package/components/checkbox/demo/index.min.js +1808 -0
  23. package/components/checkbox/demo/readme.html +50 -0
  24. package/components/checkbox/demo/readme.md +142 -0
  25. package/components/checkbox/dist/auro-checkbox-group.d.ts +166 -0
  26. package/components/checkbox/dist/auro-checkbox.d.ts +129 -0
  27. package/components/checkbox/dist/helptextVersion.d.ts +2 -0
  28. package/components/checkbox/dist/index.d.ts +3 -0
  29. package/components/checkbox/dist/index.js +1757 -0
  30. package/components/checkbox/dist/registered.js +1758 -0
  31. package/components/checkbox/dist/styles/auro-checkbox-css.d.ts +2 -0
  32. package/components/checkbox/dist/styles/auro-checkbox-group-css.d.ts +2 -0
  33. package/components/checkbox/dist/styles/color-css.d.ts +2 -0
  34. package/components/checkbox/dist/styles/colorGroup-css.d.ts +2 -0
  35. package/components/checkbox/dist/styles/tokens-css.d.ts +2 -0
  36. package/components/combobox/README.md +152 -0
  37. package/components/combobox/demo/api.html +57 -0
  38. package/components/combobox/demo/api.js +36 -0
  39. package/components/combobox/demo/api.md +1209 -0
  40. package/components/combobox/demo/api.min.js +15117 -0
  41. package/components/combobox/demo/index.html +56 -0
  42. package/components/combobox/demo/index.js +26 -0
  43. package/components/combobox/demo/index.md +621 -0
  44. package/components/combobox/demo/index.min.js +14971 -0
  45. package/components/combobox/demo/readme.html +50 -0
  46. package/components/combobox/demo/readme.md +152 -0
  47. package/components/combobox/dist/auro-combobox.d.ts +384 -0
  48. package/components/combobox/dist/bibtemplateVersion.d.ts +2 -0
  49. package/components/combobox/dist/dropdownVersion.d.ts +2 -0
  50. package/components/combobox/dist/index.d.ts +2 -0
  51. package/components/combobox/dist/index.js +13554 -0
  52. package/components/combobox/dist/inputVersion.d.ts +2 -0
  53. package/components/combobox/dist/registered.js +13556 -0
  54. package/components/combobox/dist/styles/style-css.d.ts +2 -0
  55. package/components/counter/README.md +146 -0
  56. package/components/counter/demo/api.html +54 -0
  57. package/components/counter/demo/api.js +20 -0
  58. package/components/counter/demo/api.md +584 -0
  59. package/components/counter/demo/api.min.js +7111 -0
  60. package/components/counter/demo/index.html +54 -0
  61. package/components/counter/demo/index.js +21 -0
  62. package/components/counter/demo/index.md +244 -0
  63. package/components/counter/demo/index.min.js +7075 -0
  64. package/components/counter/demo/readme.html +50 -0
  65. package/components/counter/demo/readme.md +146 -0
  66. package/components/counter/dist/auro-counter-button.d.ts +12 -0
  67. package/components/counter/dist/auro-counter-group.d.ts +235 -0
  68. package/components/counter/dist/auro-counter-wrapper.d.ts +22 -0
  69. package/components/counter/dist/auro-counter.d.ts +97 -0
  70. package/components/counter/dist/bibtemplateVersion.d.ts +2 -0
  71. package/components/counter/dist/dropdownVersion.d.ts +2 -0
  72. package/components/counter/dist/iconVersion.d.ts +2 -0
  73. package/components/counter/dist/index.d.ts +3 -0
  74. package/components/counter/dist/index.js +7018 -0
  75. package/components/counter/dist/registered.js +7019 -0
  76. package/components/counter/dist/styles/color-css.d.ts +2 -0
  77. package/components/counter/dist/styles/counter-button-color-css.d.ts +2 -0
  78. package/components/counter/dist/styles/counter-button-css.d.ts +2 -0
  79. package/components/counter/dist/styles/counter-group-css.d.ts +2 -0
  80. package/components/counter/dist/styles/counter-wrapper-color-css.d.ts +2 -0
  81. package/components/counter/dist/styles/counter-wrapper-css.d.ts +2 -0
  82. package/components/counter/dist/styles/style-css.d.ts +2 -0
  83. package/components/counter/dist/styles/tokens-css.d.ts +2 -0
  84. package/components/datepicker/README.md +140 -0
  85. package/components/datepicker/demo/api.html +57 -0
  86. package/components/datepicker/demo/api.js +35 -0
  87. package/components/datepicker/demo/api.md +1479 -0
  88. package/components/datepicker/demo/api.min.js +24534 -0
  89. package/components/datepicker/demo/index.html +56 -0
  90. package/components/datepicker/demo/index.js +19 -0
  91. package/components/datepicker/demo/index.md +112 -0
  92. package/components/datepicker/demo/index.min.js +24255 -0
  93. package/components/datepicker/demo/readme.html +50 -0
  94. package/components/datepicker/demo/readme.md +140 -0
  95. package/components/datepicker/dist/auro-calendar-cell.d.ts +163 -0
  96. package/components/datepicker/dist/auro-calendar-month.d.ts +20 -0
  97. package/components/datepicker/dist/auro-calendar.d.ts +133 -0
  98. package/components/datepicker/dist/auro-datepicker.d.ts +466 -0
  99. package/components/datepicker/dist/bibtemplateVersion.d.ts +2 -0
  100. package/components/datepicker/dist/buttonVersion.d.ts +2 -0
  101. package/components/datepicker/dist/dropdownVersion.d.ts +2 -0
  102. package/components/datepicker/dist/index.d.ts +2 -0
  103. package/components/datepicker/dist/index.js +24185 -0
  104. package/components/datepicker/dist/inputVersion.d.ts +2 -0
  105. package/components/datepicker/dist/popoverVersion.d.ts +2 -0
  106. package/components/datepicker/dist/registered.js +24185 -0
  107. package/components/datepicker/dist/styles/color-calendar-css.d.ts +2 -0
  108. package/components/datepicker/dist/styles/color-cell-css.d.ts +2 -0
  109. package/components/datepicker/dist/styles/color-css.d.ts +2 -0
  110. package/components/datepicker/dist/styles/color-month-css.d.ts +2 -0
  111. package/components/datepicker/dist/styles/style-auro-calendar-cell-css.d.ts +2 -0
  112. package/components/datepicker/dist/styles/style-auro-calendar-css.d.ts +2 -0
  113. package/components/datepicker/dist/styles/style-auro-calendar-month-css.d.ts +2 -0
  114. package/components/datepicker/dist/styles/style-css.d.ts +2 -0
  115. package/components/datepicker/dist/styles/tokens-css.d.ts +2 -0
  116. package/components/datepicker/dist/utilities.d.ts +78 -0
  117. package/components/datepicker/dist/utilitiesCalendar.d.ts +38 -0
  118. package/components/datepicker/dist/utilitiesCalendarRender.d.ts +50 -0
  119. package/components/datepicker/dist/vendor/wc-range-datepicker/day.d.ts +5 -0
  120. package/components/datepicker/dist/vendor/wc-range-datepicker/range-datepicker-calendar.d.ts +60 -0
  121. package/components/datepicker/dist/vendor/wc-range-datepicker/range-datepicker-cell.d.ts +1 -0
  122. package/components/datepicker/dist/vendor/wc-range-datepicker/range-datepicker.d.ts +57 -0
  123. package/components/dropdown/README.md +144 -0
  124. package/components/dropdown/demo/api.html +57 -0
  125. package/components/dropdown/demo/api.js +21 -0
  126. package/components/dropdown/demo/api.md +1434 -0
  127. package/components/dropdown/demo/api.min.js +3826 -0
  128. package/components/dropdown/demo/index.html +55 -0
  129. package/components/dropdown/demo/index.js +19 -0
  130. package/components/dropdown/demo/index.md +510 -0
  131. package/components/dropdown/demo/index.min.js +3789 -0
  132. package/components/dropdown/demo/readme.html +50 -0
  133. package/components/dropdown/demo/readme.md +144 -0
  134. package/components/dropdown/dist/auro-dropdown.d.ts +406 -0
  135. package/components/dropdown/dist/auro-dropdownBib.d.ts +46 -0
  136. package/components/dropdown/dist/dropdownVersion.d.ts +2 -0
  137. package/components/dropdown/dist/helptextVersion.d.ts +2 -0
  138. package/components/dropdown/dist/iconVersion.d.ts +2 -0
  139. package/components/dropdown/dist/index.d.ts +2 -0
  140. package/components/dropdown/dist/index.js +3734 -0
  141. package/components/dropdown/dist/registered.js +3734 -0
  142. package/components/dropdown/dist/styles/bibColors-css.d.ts +2 -0
  143. package/components/dropdown/dist/styles/bibStyles-css.d.ts +2 -0
  144. package/components/dropdown/dist/styles/color-css.d.ts +2 -0
  145. package/components/dropdown/dist/styles/style-css.d.ts +2 -0
  146. package/components/dropdown/dist/styles/tokens-css.d.ts +2 -0
  147. package/components/form/README.md +142 -0
  148. package/components/form/demo/api.html +49 -0
  149. package/components/form/demo/api.js +3 -0
  150. package/components/form/demo/api.md +51 -0
  151. package/components/form/demo/api.min.js +638 -0
  152. package/components/form/demo/autocomplete.html +15 -0
  153. package/components/form/demo/index.html +50 -0
  154. package/components/form/demo/index.js +4 -0
  155. package/components/form/demo/index.md +403 -0
  156. package/components/form/demo/index.min.js +639 -0
  157. package/components/form/demo/readme.html +50 -0
  158. package/components/form/demo/readme.md +142 -0
  159. package/components/form/demo/registerDemoDeps.js +23 -0
  160. package/components/form/demo/working.html +118 -0
  161. package/components/form/dist/auro-form.d.ts +223 -0
  162. package/components/form/dist/index.d.ts +2 -0
  163. package/components/form/dist/index.js +614 -0
  164. package/components/form/dist/registered.d.ts +1 -0
  165. package/components/form/dist/registered.js +614 -0
  166. package/components/form/dist/styles/style-css.d.ts +2 -0
  167. package/components/helptext/dist/auro-helptext.d.ts +61 -0
  168. package/components/helptext/dist/index.d.ts +2 -0
  169. package/components/helptext/dist/index.js +209 -0
  170. package/components/helptext/dist/registered.js +209 -0
  171. package/components/helptext/dist/styles/color-css.d.ts +2 -0
  172. package/components/helptext/dist/styles/style-css.d.ts +2 -0
  173. package/components/helptext/dist/styles/tokens-css.d.ts +2 -0
  174. package/components/input/README.md +135 -0
  175. package/components/input/demo/api.html +42 -0
  176. package/components/input/demo/api.js +29 -0
  177. package/components/input/demo/api.md +1252 -0
  178. package/components/input/demo/api.min.js +7238 -0
  179. package/components/input/demo/index.html +43 -0
  180. package/components/input/demo/index.js +20 -0
  181. package/components/input/demo/index.md +202 -0
  182. package/components/input/demo/index.min.js +7157 -0
  183. package/components/input/demo/readme.html +50 -0
  184. package/components/input/demo/readme.md +135 -0
  185. package/components/input/dist/auro-input.d.ts +31 -0
  186. package/components/input/dist/base-input.d.ts +512 -0
  187. package/components/input/dist/buttonVersion.d.ts +2 -0
  188. package/components/input/dist/helptextVersion.d.ts +2 -0
  189. package/components/input/dist/i18n.d.ts +18 -0
  190. package/components/input/dist/iconVersion.d.ts +2 -0
  191. package/components/input/dist/index.d.ts +2 -0
  192. package/components/input/dist/index.js +7063 -0
  193. package/components/input/dist/registered.js +7063 -0
  194. package/components/input/dist/styles/borders-css.d.ts +2 -0
  195. package/components/input/dist/styles/color-css.d.ts +2 -0
  196. package/components/input/dist/styles/input-css.d.ts +2 -0
  197. package/components/input/dist/styles/label-css.d.ts +2 -0
  198. package/components/input/dist/styles/mixins-css.d.ts +2 -0
  199. package/components/input/dist/styles/notificationIcons-css.d.ts +2 -0
  200. package/components/input/dist/styles/style-css.d.ts +2 -0
  201. package/components/input/dist/styles/tokens-css.d.ts +2 -0
  202. package/components/input/dist/utilities.d.ts +25 -0
  203. package/components/menu/README.md +145 -0
  204. package/components/menu/demo/api.html +55 -0
  205. package/components/menu/demo/api.js +27 -0
  206. package/components/menu/demo/api.md +954 -0
  207. package/components/menu/demo/api.min.js +1538 -0
  208. package/components/menu/demo/index.html +52 -0
  209. package/components/menu/demo/index.js +28 -0
  210. package/components/menu/demo/index.md +61 -0
  211. package/components/menu/demo/index.min.js +1484 -0
  212. package/components/menu/demo/readme.html +50 -0
  213. package/components/menu/demo/readme.md +145 -0
  214. package/components/menu/dist/auro-menu-utils.d.ts +42 -0
  215. package/components/menu/dist/auro-menu.d.ts +205 -0
  216. package/components/menu/dist/auro-menuoption.d.ts +63 -0
  217. package/components/menu/dist/dropdownVersion.d.ts +2 -0
  218. package/components/menu/dist/iconVersion.d.ts +2 -0
  219. package/components/menu/dist/index.d.ts +4 -0
  220. package/components/menu/dist/index.js +1426 -0
  221. package/components/menu/dist/registered.js +1427 -0
  222. package/components/menu/dist/styles/color-menu-css.d.ts +2 -0
  223. package/components/menu/dist/styles/color-menuoption-css.d.ts +2 -0
  224. package/components/menu/dist/styles/style-menu-css.d.ts +2 -0
  225. package/components/menu/dist/styles/style-menuoption-css.d.ts +2 -0
  226. package/components/menu/dist/styles/tokens-css.d.ts +2 -0
  227. package/components/radio/README.md +137 -0
  228. package/components/radio/demo/api.html +53 -0
  229. package/components/radio/demo/api.js +19 -0
  230. package/components/radio/demo/api.md +562 -0
  231. package/components/radio/demo/api.min.js +1944 -0
  232. package/components/radio/demo/index.html +50 -0
  233. package/components/radio/demo/index.js +8 -0
  234. package/components/radio/demo/index.md +150 -0
  235. package/components/radio/demo/index.min.js +1901 -0
  236. package/components/radio/demo/readme.html +50 -0
  237. package/components/radio/demo/readme.md +137 -0
  238. package/components/radio/dist/auro-radio-group.d.ts +194 -0
  239. package/components/radio/dist/auro-radio.d.ts +144 -0
  240. package/components/radio/dist/helptextVersion.d.ts +2 -0
  241. package/components/radio/dist/index.d.ts +3 -0
  242. package/components/radio/dist/index.js +1850 -0
  243. package/components/radio/dist/registered.js +1851 -0
  244. package/components/radio/dist/styles/auro-radio-group-css.d.ts +2 -0
  245. package/components/radio/dist/styles/color-css.d.ts +2 -0
  246. package/components/radio/dist/styles/groupColor-css.d.ts +2 -0
  247. package/components/radio/dist/styles/style-css.d.ts +2 -0
  248. package/components/radio/dist/styles/tokens-css.d.ts +2 -0
  249. package/components/select/README.md +144 -0
  250. package/components/select/demo/api.html +71 -0
  251. package/components/select/demo/api.js +35 -0
  252. package/components/select/demo/api.md +1313 -0
  253. package/components/select/demo/api.min.js +7763 -0
  254. package/components/select/demo/index.html +66 -0
  255. package/components/select/demo/index.js +9 -0
  256. package/components/select/demo/index.md +815 -0
  257. package/components/select/demo/index.min.js +7651 -0
  258. package/components/select/demo/readme.html +50 -0
  259. package/components/select/demo/readme.md +144 -0
  260. package/components/select/dist/auro-select.d.ts +359 -0
  261. package/components/select/dist/bibtemplateVersion.d.ts +2 -0
  262. package/components/select/dist/dropdownVersion.d.ts +2 -0
  263. package/components/select/dist/index.d.ts +2 -0
  264. package/components/select/dist/index.js +6300 -0
  265. package/components/select/dist/registered.js +6300 -0
  266. package/components/select/dist/styles/style-css.d.ts +2 -0
  267. package/package.json +217 -0
  268. package/packages/build-tools/src/postinstall.mjs +12 -0
@@ -0,0 +1,1313 @@
1
+ <!--
2
+ The apiExamples.md file is a compiled document. No edits should be made directly to this file.
3
+
4
+ apiExamples.md is created by running `npm run build:markdownDocs`.
5
+
6
+ This file is generated based on a template fetched from `./docs/partials/apiExamples.md`
7
+ -->
8
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../docs/api.md) -->
9
+ <!-- The below content is automatically added from ./../docs/api.md -->
10
+
11
+ # auro-select
12
+
13
+ The auro-select element is a wrapper for auro-dropdown and auro-menu to create a dropdown menu control.
14
+
15
+ ## Properties
16
+
17
+ | Property | Attribute | Type | Default | Description |
18
+ |---------------------------------|---------------------------------|-----------|----------------|--------------------------------------------------|
19
+ | [autoPlacement](#autoPlacement) | `autoPlacement` | `boolean` | "false" | If declared, bib's position will be automatically calculated where to appear. |
20
+ | [autocomplete](#autocomplete) | `autocomplete` | `string` | | If declared, sets the autocomplete attribute for the select element. |
21
+ | [disabled](#disabled) | `disabled` | `boolean` | | When attribute is present, element shows disabled state. |
22
+ | [error](#error) | `error` | `string` | | When defined, sets persistent validity to `customError` and sets `setCustomValidity` = attribute value. |
23
+ | [flexMenuWidth](#flexMenuWidth) | `flexMenuWidth` | `boolean` | | If set, makes dropdown width match the size of the content, rather than the width of the trigger. |
24
+ | [fullscreenBreakpoint](#fullscreenBreakpoint) | `fullscreenBreakpoint` | `string` | "sm" | Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)<br />at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.<br /><br />When expanded, the dropdown will automatically display in fullscreen mode<br />if the screen size is equal to or smaller than the selected breakpoint. |
25
+ | [largeFullscreenHeadline](#largeFullscreenHeadline) | `largeFullscreenHeadline` | `boolean` | | If declared, make bib.fullscreen.headline in HeadingDisplay.<br />Otherwise, Heading 600 |
26
+ | [multiSelect](#multiSelect) | `multiselect` | `boolean` | | Sets multi-select mode, allowing multiple options to be selected at once. |
27
+ | [name](#name) | `name` | `string` | | The name for the select element. |
28
+ | [noCheckmark](#noCheckmark) | `noCheckmark` | `boolean` | | When true, checkmark on selected option will no longer be present. |
29
+ | [noFlip](#noFlip) | `noFlip` | `boolean` | "false" | If declared, the bib will NOT flip to an alternate position<br />when there isn't enough space in the specified `placement`. |
30
+ | [noValidate](#noValidate) | `noValidate` | `boolean` | | If set, disables auto-validation on blur. |
31
+ | [offset](#offset) | `offset` | `number` | "0" | Gap between the trigger element and bib. |
32
+ | [onDark](#onDark) | `onDark` | `boolean` | | If declared, onDark styles will be applied to the trigger. |
33
+ | [optionSelected](#optionSelected) | `optionSelected` | | | Specifies the current selected menuOption. |
34
+ | [placement](#placement) | `placement` | `string` | "bottom-start" | Position where the bib should appear relative to the trigger.<br />Accepted values:<br />"top" \| "right" \| "bottom" \| "left" \|<br />"bottom-start" \| "top-start" \| "top-end" \|<br />"right-start" \| "right-end" \| "bottom-end" \|<br />"left-start" \| "left-end" |
35
+ | [required](#required) | `required` | `boolean` | | Populates the `required` attribute on the element. Used for client-side validation. |
36
+ | [setCustomValidity](#setCustomValidity) | `setCustomValidity` | `string` | | Sets a custom help text message to display for all validityStates. |
37
+ | [setCustomValidityCustomError](#setCustomValidityCustomError) | `setCustomValidityCustomError` | `string` | | Custom help text message to display when validity = `customError`. |
38
+ | [setCustomValidityValueMissing](#setCustomValidityValueMissing) | `setCustomValidityValueMissing` | `string` | | Custom help text message to display when validity = `valueMissing`. |
39
+ | [validity](#validity) | `validity` | `string` | | Specifies the `validityState` this element is in. |
40
+ | [value](#value) | `value` | | | Value selected for the component. |
41
+
42
+ ## Methods
43
+
44
+ | Method | Type | Description |
45
+ |------------|----------------------------------------|--------------------------------------------------|
46
+ | [reset](#reset) | `(): void` | Resets component to initial state. |
47
+ | [validate](#validate) | `(force?: boolean \| undefined): void` | Validates value.<br /><br />**force**: Whether to force validation. |
48
+
49
+ ## Events
50
+
51
+ | Event | Type | Description |
52
+ |-----------------------------|--------------------|--------------------------------------------------|
53
+ | `auroFormElement-validated` | | Notifies that the `validity` and `errorMessage` values have changed. |
54
+ | `auroSelect-valueSet` | `CustomEvent<any>` | Notifies that the component has a new value set. |
55
+ | [input](#input) | `CustomEvent<any>` | Notifies every time the value prop of the element is changed. |
56
+
57
+ ## Slots
58
+
59
+ | Name | Description |
60
+ |---------------------------|--------------------------------------------------|
61
+ | | Default slot for the menu content. |
62
+ | `bib.fullscreen.headline` | Defines the headline to display above menu-options |
63
+ | [helpText](#helpText) | Defines the content of the helpText. |
64
+ | [label](#label) | Defines the content of the label. |
65
+ | [placeholder](#placeholder) | Defines the content of the placeholder to be shown when there is no value |
66
+
67
+ ## CSS Shadow Parts
68
+
69
+ | Part | Description |
70
+ |------------|-----------------------------|
71
+ | [helpText](#helpText) | Apply CSS to the help text. |
72
+ <!-- AURO-GENERATED-CONTENT:END -->
73
+
74
+ ## API Examples
75
+
76
+ ### Default example
77
+
78
+ A baseline `auro-select` using `auro-menu` and `auro-menuoption` elements.
79
+
80
+ <div class="exampleWrapper">
81
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/basic.html) -->
82
+ <!-- The below content is automatically added from ./../apiExamples/basic.html -->
83
+ <auro-select>
84
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
85
+ <span slot="label">Select Example</span>
86
+ <auro-menu>
87
+ <auro-menuoption value="stops">Stops</auro-menuoption>
88
+ <auro-menuoption value="price">Price</auro-menuoption>
89
+ <auro-menuoption value="duration">Duration</auro-menuoption>
90
+ <auro-menuoption value="departure">Departure</auro-menuoption>
91
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
92
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
93
+ </auro-menu>
94
+ </auro-select>
95
+ <!-- AURO-GENERATED-CONTENT:END -->
96
+ </div>
97
+ <div class="exampleWrapper--ondark" aria-hidden>
98
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/onDark.html) -->
99
+ <!-- The below content is automatically added from ./../apiExamples/onDark.html -->
100
+ <auro-select onDark>
101
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
102
+ <span slot="label">Select Example</span>
103
+ <auro-menu>
104
+ <auro-menuoption value="stops">Stops</auro-menuoption>
105
+ <auro-menuoption value="price">Price</auro-menuoption>
106
+ <auro-menuoption value="duration">Duration</auro-menuoption>
107
+ <auro-menuoption value="departure">Departure</auro-menuoption>
108
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
109
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
110
+ </auro-menu>
111
+ </auro-select>
112
+ <!-- AURO-GENERATED-CONTENT:END -->
113
+ </div>
114
+ <auro-accordion alignRight>
115
+ <span slot="trigger">See code</span>
116
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/basic.html) -->
117
+ <!-- The below code snippet is automatically added from ./../apiExamples/basic.html -->
118
+
119
+ ```html
120
+ <auro-select>
121
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
122
+ <span slot="label">Select Example</span>
123
+ <auro-menu>
124
+ <auro-menuoption value="stops">Stops</auro-menuoption>
125
+ <auro-menuoption value="price">Price</auro-menuoption>
126
+ <auro-menuoption value="duration">Duration</auro-menuoption>
127
+ <auro-menuoption value="departure">Departure</auro-menuoption>
128
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
129
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
130
+ </auro-menu>
131
+ </auro-select>
132
+ ```
133
+ <!-- AURO-GENERATED-CONTENT:END -->
134
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/onDark.html) -->
135
+ <!-- The below content is automatically added from ./../apiExamples/onDark.html -->
136
+ <auro-select onDark>
137
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
138
+ <span slot="label">Select Example</span>
139
+ <auro-menu>
140
+ <auro-menuoption value="stops">Stops</auro-menuoption>
141
+ <auro-menuoption value="price">Price</auro-menuoption>
142
+ <auro-menuoption value="duration">Duration</auro-menuoption>
143
+ <auro-menuoption value="departure">Departure</auro-menuoption>
144
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
145
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
146
+ </auro-menu>
147
+ </auro-select>
148
+ <!-- AURO-GENERATED-CONTENT:END -->
149
+ </auro-accordion>
150
+
151
+ ### Property Examples
152
+
153
+ #### value <a name="value"></a>
154
+ Use the `value` property to define a preset value on the `auro-select` element. The `value` of `auro-select` must match the `value` defined of a single `auro-menuoption`. Upon initially rendering the component, if the `value` does not match an `auro-menuoption`, the `value` of `auro-select` will be set to `undefined`.
155
+
156
+ To pre-set the value of auro-select on load, use the `value` property. The `selected` attribute on auro-menuoption is designed to illustrate state in the DOM.
157
+
158
+ <div class="exampleWrapper">
159
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/value.html) -->
160
+ <!-- The below content is automatically added from ./../apiExamples/value.html -->
161
+ <auro-button id="validValueExampleBtn">Set Value to Valid Option</auro-button>
162
+ <auro-button id="invalidValueExampleBtn">Set Value to Invalid Option</auro-button>
163
+ <br/><br/>
164
+ <auro-select id="valueExample" value='["price"]'>
165
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
166
+ <span slot="label">Name</span>
167
+ <auro-menu>
168
+ <auro-menuoption id="option-0" value="stops">Stops</auro-menuoption>
169
+ <auro-menuoption id="option-1" value="price">Price</auro-menuoption>
170
+ <auro-menuoption id="option-2" value="duration">Duration</auro-menuoption>
171
+ <auro-menuoption id="option-3" value="departure">Departure</auro-menuoption>
172
+ <auro-menuoption id="option-4" value="arrival">Arrival</auro-menuoption>
173
+ <auro-menuoption id="option-5" value="prefer alaska">Prefer Alaska</auro-menuoption>
174
+ </auro-menu>
175
+ </auro-select>
176
+ <!-- AURO-GENERATED-CONTENT:END -->
177
+ </div>
178
+ <auro-accordion alignRight>
179
+ <span slot="trigger">See code</span>
180
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/value.html) -->
181
+ <!-- The below code snippet is automatically added from ./../apiExamples/value.html -->
182
+
183
+ ```html
184
+ <auro-button id="validValueExampleBtn">Set Value to Valid Option</auro-button>
185
+ <auro-button id="invalidValueExampleBtn">Set Value to Invalid Option</auro-button>
186
+ <br/><br/>
187
+ <auro-select id="valueExample" value='["price"]'>
188
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
189
+ <span slot="label">Name</span>
190
+ <auro-menu>
191
+ <auro-menuoption id="option-0" value="stops">Stops</auro-menuoption>
192
+ <auro-menuoption id="option-1" value="price">Price</auro-menuoption>
193
+ <auro-menuoption id="option-2" value="duration">Duration</auro-menuoption>
194
+ <auro-menuoption id="option-3" value="departure">Departure</auro-menuoption>
195
+ <auro-menuoption id="option-4" value="arrival">Arrival</auro-menuoption>
196
+ <auro-menuoption id="option-5" value="prefer alaska">Prefer Alaska</auro-menuoption>
197
+ </auro-menu>
198
+ </auro-select>
199
+ ```
200
+ <!-- AURO-GENERATED-CONTENT:END -->
201
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/value.js) -->
202
+ <!-- The below code snippet is automatically added from ./../apiExamples/value.js -->
203
+
204
+ ```js
205
+ export function valueExample() {
206
+ const valueExample = document.querySelector('#valueExample');
207
+
208
+ document.querySelector('#validValueExampleBtn').addEventListener('click', () => {
209
+ valueExample.value = ['arrival'];
210
+ });
211
+
212
+ document.querySelector('#invalidValueExampleBtn').addEventListener('click', () => {
213
+ valueExample.value = ['flight course'];
214
+ });
215
+ }
216
+ ```
217
+ <!-- AURO-GENERATED-CONTENT:END -->
218
+ </auro-accordion>
219
+
220
+ #### Autocomplete <a name="autocomplete"></a>
221
+ Use the `autocomplete` attribute to let browser's know what information to use to fill out the form.
222
+
223
+ <div class="exampleWrapper">
224
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/autocomplete.html) -->
225
+ <!-- The below content is automatically added from ./../apiExamples/autocomplete.html -->
226
+ <div class="autofill-example-form">
227
+ <div class="input-row">
228
+ <auro-input autocomplete="given-name">
229
+ <span slot="label">First Name</span>
230
+ <span slot="bib.fullscreen.headline">First Name</span>
231
+ </auro-input>
232
+ <auro-input autocomplete="family-name">
233
+ <span slot="label">Last Name</span>
234
+ <span slot="bib.fullscreen.headline">Last Name</span>
235
+ </auro-input>
236
+ </div>
237
+ <div class="input-row">
238
+ <auro-input autocomplete="address-line1">
239
+ <span slot="label">Street Address</span>
240
+ <span slot="bib.fullscreen.headline">Street Address</span>
241
+ </auro-input>
242
+ <auro-input autocomplete="address-level2">
243
+ <span slot="label">City</span>
244
+ <span slot="bib.fullscreen.headline">City</span>
245
+ </auro-input>
246
+ <auro-select autocomplete="address-level1">
247
+ <span slot="bib.fullscreen.headline">Select Your State</span>
248
+ <span slot="label">Select Your State</span>
249
+ <auro-menu>
250
+ <auro-menuoption value="AL">Alabama</auro-menuoption>
251
+ <auro-menuoption value="AK">Alaska</auro-menuoption>
252
+ <auro-menuoption value="AZ">Arizona</auro-menuoption>
253
+ <auro-menuoption value="AR">Arkansas</auro-menuoption>
254
+ <auro-menuoption value="CA">California</auro-menuoption>
255
+ <auro-menuoption value="CO">Colorado</auro-menuoption>
256
+ <auro-menuoption value="CT">Connecticut</auro-menuoption>
257
+ <auro-menuoption value="DE">Delaware</auro-menuoption>
258
+ <auro-menuoption value="DC">District of Columbia</auro-menuoption>
259
+ <auro-menuoption value="FL">Florida</auro-menuoption>
260
+ <auro-menuoption value="GA">Georgia</auro-menuoption>
261
+ <auro-menuoption value="HI">Hawaii</auro-menuoption>
262
+ <auro-menuoption value="ID">Idaho</auro-menuoption>
263
+ <auro-menuoption value="IL">Illinois</auro-menuoption>
264
+ <auro-menuoption value="IN">Indiana</auro-menuoption>
265
+ <auro-menuoption value="IA">Iowa</auro-menuoption>
266
+ <auro-menuoption value="KS">Kansas</auro-menuoption>
267
+ <auro-menuoption value="KY">Kentucky</auro-menuoption>
268
+ <auro-menuoption value="LA">Louisiana</auro-menuoption>
269
+ <auro-menuoption value="ME">Maine</auro-menuoption>
270
+ <auro-menuoption value="MD">Maryland</auro-menuoption>
271
+ <auro-menuoption value="MA">Massachusetts</auro-menuoption>
272
+ <auro-menuoption value="MI">Michigan</auro-menuoption>
273
+ <auro-menuoption value="MN">Minnesota</auro-menuoption>
274
+ <auro-menuoption value="MS">Mississippi</auro-menuoption>
275
+ <auro-menuoption value="MO">Missouri</auro-menuoption>
276
+ <auro-menuoption value="MT">Montana</auro-menuoption>
277
+ <auro-menuoption value="NE">Nebraska</auro-menuoption>
278
+ <auro-menuoption value="NV">Nevada</auro-menuoption>
279
+ <auro-menuoption value="NH">New Hampshire</auro-menuoption>
280
+ <auro-menuoption value="NJ">New Jersey</auro-menuoption>
281
+ <auro-menuoption value="NM">New Mexico</auro-menuoption>
282
+ <auro-menuoption value="NY">New York</auro-menuoption>
283
+ <auro-menuoption value="NC">North Carolina</auro-menuoption>
284
+ <auro-menuoption value="ND">North Dakota</auro-menuoption>
285
+ <auro-menuoption value="OH">Ohio</auro-menuoption>
286
+ <auro-menuoption value="OK">Oklahoma</auro-menuoption>
287
+ <auro-menuoption value="OR">Oregon</auro-menuoption>
288
+ <auro-menuoption value="PA">Pennsylvania</auro-menuoption>
289
+ <auro-menuoption value="RI">Rhode Island</auro-menuoption>
290
+ <auro-menuoption value="SC">South Carolina</auro-menuoption>
291
+ <auro-menuoption value="SD">South Dakota</auro-menuoption>
292
+ <auro-menuoption value="TN">Tennessee</auro-menuoption>
293
+ <auro-menuoption value="TX">Texas</auro-menuoption>
294
+ <auro-menuoption value="UT">Utah</auro-menuoption>
295
+ <auro-menuoption value="VT">Vermont</auro-menuoption>
296
+ <auro-menuoption value="VA">Virginia</auro-menuoption>
297
+ <auro-menuoption value="WA">Washington</auro-menuoption>
298
+ <auro-menuoption value="WV">West Virginia</auro-menuoption>
299
+ <auro-menuoption value="WI">Wisconsin</auro-menuoption>
300
+ <auro-menuoption value="WY">Wyoming</auro-menuoption>
301
+ </auro-menu>
302
+ </auro-select>
303
+ </div>
304
+ </div>
305
+ <!-- AURO-GENERATED-CONTENT:END -->
306
+ </div>
307
+ <auro-accordion alignRight>
308
+ <span slot="trigger">See code</span>
309
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/autocomplete.html) -->
310
+ <!-- The below code snippet is automatically added from ./../apiExamples/autocomplete.html -->
311
+
312
+ ```html
313
+ <div class="autofill-example-form">
314
+ <div class="input-row">
315
+ <auro-input autocomplete="given-name">
316
+ <span slot="label">First Name</span>
317
+ <span slot="bib.fullscreen.headline">First Name</span>
318
+ </auro-input>
319
+ <auro-input autocomplete="family-name">
320
+ <span slot="label">Last Name</span>
321
+ <span slot="bib.fullscreen.headline">Last Name</span>
322
+ </auro-input>
323
+ </div>
324
+ <div class="input-row">
325
+ <auro-input autocomplete="address-line1">
326
+ <span slot="label">Street Address</span>
327
+ <span slot="bib.fullscreen.headline">Street Address</span>
328
+ </auro-input>
329
+ <auro-input autocomplete="address-level2">
330
+ <span slot="label">City</span>
331
+ <span slot="bib.fullscreen.headline">City</span>
332
+ </auro-input>
333
+ <auro-select autocomplete="address-level1">
334
+ <span slot="bib.fullscreen.headline">Select Your State</span>
335
+ <span slot="label">Select Your State</span>
336
+ <auro-menu>
337
+ <auro-menuoption value="AL">Alabama</auro-menuoption>
338
+ <auro-menuoption value="AK">Alaska</auro-menuoption>
339
+ <auro-menuoption value="AZ">Arizona</auro-menuoption>
340
+ <auro-menuoption value="AR">Arkansas</auro-menuoption>
341
+ <auro-menuoption value="CA">California</auro-menuoption>
342
+ <auro-menuoption value="CO">Colorado</auro-menuoption>
343
+ <auro-menuoption value="CT">Connecticut</auro-menuoption>
344
+ <auro-menuoption value="DE">Delaware</auro-menuoption>
345
+ <auro-menuoption value="DC">District of Columbia</auro-menuoption>
346
+ <auro-menuoption value="FL">Florida</auro-menuoption>
347
+ <auro-menuoption value="GA">Georgia</auro-menuoption>
348
+ <auro-menuoption value="HI">Hawaii</auro-menuoption>
349
+ <auro-menuoption value="ID">Idaho</auro-menuoption>
350
+ <auro-menuoption value="IL">Illinois</auro-menuoption>
351
+ <auro-menuoption value="IN">Indiana</auro-menuoption>
352
+ <auro-menuoption value="IA">Iowa</auro-menuoption>
353
+ <auro-menuoption value="KS">Kansas</auro-menuoption>
354
+ <auro-menuoption value="KY">Kentucky</auro-menuoption>
355
+ <auro-menuoption value="LA">Louisiana</auro-menuoption>
356
+ <auro-menuoption value="ME">Maine</auro-menuoption>
357
+ <auro-menuoption value="MD">Maryland</auro-menuoption>
358
+ <auro-menuoption value="MA">Massachusetts</auro-menuoption>
359
+ <auro-menuoption value="MI">Michigan</auro-menuoption>
360
+ <auro-menuoption value="MN">Minnesota</auro-menuoption>
361
+ <auro-menuoption value="MS">Mississippi</auro-menuoption>
362
+ <auro-menuoption value="MO">Missouri</auro-menuoption>
363
+ <auro-menuoption value="MT">Montana</auro-menuoption>
364
+ <auro-menuoption value="NE">Nebraska</auro-menuoption>
365
+ <auro-menuoption value="NV">Nevada</auro-menuoption>
366
+ <auro-menuoption value="NH">New Hampshire</auro-menuoption>
367
+ <auro-menuoption value="NJ">New Jersey</auro-menuoption>
368
+ <auro-menuoption value="NM">New Mexico</auro-menuoption>
369
+ <auro-menuoption value="NY">New York</auro-menuoption>
370
+ <auro-menuoption value="NC">North Carolina</auro-menuoption>
371
+ <auro-menuoption value="ND">North Dakota</auro-menuoption>
372
+ <auro-menuoption value="OH">Ohio</auro-menuoption>
373
+ <auro-menuoption value="OK">Oklahoma</auro-menuoption>
374
+ <auro-menuoption value="OR">Oregon</auro-menuoption>
375
+ <auro-menuoption value="PA">Pennsylvania</auro-menuoption>
376
+ <auro-menuoption value="RI">Rhode Island</auro-menuoption>
377
+ <auro-menuoption value="SC">South Carolina</auro-menuoption>
378
+ <auro-menuoption value="SD">South Dakota</auro-menuoption>
379
+ <auro-menuoption value="TN">Tennessee</auro-menuoption>
380
+ <auro-menuoption value="TX">Texas</auro-menuoption>
381
+ <auro-menuoption value="UT">Utah</auro-menuoption>
382
+ <auro-menuoption value="VT">Vermont</auro-menuoption>
383
+ <auro-menuoption value="VA">Virginia</auro-menuoption>
384
+ <auro-menuoption value="WA">Washington</auro-menuoption>
385
+ <auro-menuoption value="WV">West Virginia</auro-menuoption>
386
+ <auro-menuoption value="WI">Wisconsin</auro-menuoption>
387
+ <auro-menuoption value="WY">Wyoming</auro-menuoption>
388
+ </auro-menu>
389
+ </auro-select>
390
+ </div>
391
+ </div>
392
+ ```
393
+ <!-- AURO-GENERATED-CONTENT:END -->
394
+ </auro-accordion>
395
+
396
+ #### required <a name="required"></a>
397
+ When present, the `required` attribute specifies that a select field must be filled out before submitting the form.
398
+
399
+ When the validity check fails the validityState, equals `valueMissing`. The error message for the `valueMissing` validityState can be set to a custom string using the `setCustomValidityValueMissing`. There is no default error message defined.
400
+
401
+ <div class="exampleWrapper">
402
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/required.html) -->
403
+ <!-- The below content is automatically added from ./../apiExamples/required.html -->
404
+ <auro-select required setCustomValidityValueMissing="Custom required validation error message.">
405
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
406
+ <span slot="label">required field</span>
407
+ <label slot="placeholder">Placeholder Text</label>
408
+ <auro-menu>
409
+ <auro-menuoption value="stops">Stops</auro-menuoption>
410
+ <auro-menuoption value="price">Price</auro-menuoption>
411
+ <auro-menuoption value="duration">Duration</auro-menuoption>
412
+ <auro-menuoption value="departure">Departure</auro-menuoption>
413
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
414
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
415
+ </auro-menu>
416
+ </auro-select>
417
+ <!-- AURO-GENERATED-CONTENT:END -->
418
+ </div>
419
+ <auro-accordion alignRight>
420
+ <span slot="trigger">See code</span>
421
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/required.html) -->
422
+ <!-- The below code snippet is automatically added from ./../apiExamples/required.html -->
423
+
424
+ ```html
425
+ <auro-select required setCustomValidityValueMissing="Custom required validation error message.">
426
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
427
+ <span slot="label">required field</span>
428
+ <label slot="placeholder">Placeholder Text</label>
429
+ <auro-menu>
430
+ <auro-menuoption value="stops">Stops</auro-menuoption>
431
+ <auro-menuoption value="price">Price</auro-menuoption>
432
+ <auro-menuoption value="duration">Duration</auro-menuoption>
433
+ <auro-menuoption value="departure">Departure</auro-menuoption>
434
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
435
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
436
+ </auro-menu>
437
+ </auro-select>
438
+ ```
439
+ <!-- AURO-GENERATED-CONTENT:END -->
440
+ </auro-accordion>
441
+
442
+ #### error <a name="error"></a>
443
+ Use the `error` boolean attribute to toggle the error UI.
444
+
445
+ <div class="exampleWrapper">
446
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/error.html) -->
447
+ <!-- The below content is automatically added from ./../apiExamples/error.html -->
448
+ <auro-select error="Custom error message">
449
+ <span slot="label">error select example</span>
450
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
451
+ <label slot="placeholder">Placeholder Text</label>
452
+ <auro-menu>
453
+ <auro-menuoption value="stops">Stops</auro-menuoption>
454
+ <auro-menuoption value="price">Price</auro-menuoption>
455
+ <auro-menuoption value="duration">Duration</auro-menuoption>
456
+ <auro-menuoption value="departure">Departure</auro-menuoption>
457
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
458
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
459
+ </auro-menu>
460
+ </auro-select>
461
+ <!-- AURO-GENERATED-CONTENT:END -->
462
+ </div>
463
+ <div class="exampleWrapper--ondark" aria-hidden>
464
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/onDarkError.html) -->
465
+ <!-- The below content is automatically added from ./../apiExamples/onDarkError.html -->
466
+ <auro-select onDark error="Custom error message">
467
+ <span slot="label">error select example</span>
468
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
469
+ <label slot="placeholder">Placeholder Text</label>
470
+ <auro-menu>
471
+ <auro-menuoption value="stops">Stops</auro-menuoption>
472
+ <auro-menuoption value="price">Price</auro-menuoption>
473
+ <auro-menuoption value="duration">Duration</auro-menuoption>
474
+ <auro-menuoption value="departure">Departure</auro-menuoption>
475
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
476
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
477
+ </auro-menu>
478
+ </auro-select>
479
+ <!-- AURO-GENERATED-CONTENT:END -->
480
+ </div>
481
+ <auro-accordion alignRight>
482
+ <span slot="trigger">See code</span>
483
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/error.html) -->
484
+ <!-- The below code snippet is automatically added from ./../apiExamples/error.html -->
485
+
486
+ ```html
487
+ <auro-select error="Custom error message">
488
+ <span slot="label">error select example</span>
489
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
490
+ <label slot="placeholder">Placeholder Text</label>
491
+ <auro-menu>
492
+ <auro-menuoption value="stops">Stops</auro-menuoption>
493
+ <auro-menuoption value="price">Price</auro-menuoption>
494
+ <auro-menuoption value="duration">Duration</auro-menuoption>
495
+ <auro-menuoption value="departure">Departure</auro-menuoption>
496
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
497
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
498
+ </auro-menu>
499
+ </auro-select>
500
+ ```
501
+ <!-- AURO-GENERATED-CONTENT:END -->
502
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/onDarkError.html) -->
503
+ <!-- The below content is automatically added from ./../apiExamples/onDarkError.html -->
504
+ <auro-select onDark error="Custom error message">
505
+ <span slot="label">error select example</span>
506
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
507
+ <label slot="placeholder">Placeholder Text</label>
508
+ <auro-menu>
509
+ <auro-menuoption value="stops">Stops</auro-menuoption>
510
+ <auro-menuoption value="price">Price</auro-menuoption>
511
+ <auro-menuoption value="duration">Duration</auro-menuoption>
512
+ <auro-menuoption value="departure">Departure</auro-menuoption>
513
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
514
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
515
+ </auro-menu>
516
+ </auro-select>
517
+ <!-- AURO-GENERATED-CONTENT:END -->
518
+ </auro-accordion>
519
+
520
+ #### disabled <a name="disabled"></a>
521
+ Use the `disabled` boolean attribute to toggle the disabled UI.
522
+
523
+ <div class="exampleWrapper">
524
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/disabled.html) -->
525
+ <!-- The below content is automatically added from ./../apiExamples/disabled.html -->
526
+ <auro-select disabled>
527
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
528
+ <label slot="placeholder">Placeholder Text</label>
529
+ <span slot="label">disabled select example</span>
530
+ <auro-menu>
531
+ <auro-menuoption value="stops">Stops</auro-menuoption>
532
+ <auro-menuoption value="price">Price</auro-menuoption>
533
+ <auro-menuoption value="duration">Duration</auro-menuoption>
534
+ <auro-menuoption value="departure">Departure</auro-menuoption>
535
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
536
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
537
+ </auro-menu>
538
+ </auro-select>
539
+ <!-- AURO-GENERATED-CONTENT:END -->
540
+ </div>
541
+ <div class="exampleWrapper--ondark" aria-hidden>
542
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/onDarkDisabled.html) -->
543
+ <!-- The below content is automatically added from ./../apiExamples/onDarkDisabled.html -->
544
+ <auro-select onDark disabled>
545
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
546
+ <label slot="placeholder">Placeholder Text</label>
547
+ <span slot="label">disabled select example</span>
548
+ <auro-menu>
549
+ <auro-menuoption value="stops">Stops</auro-menuoption>
550
+ <auro-menuoption value="price">Price</auro-menuoption>
551
+ <auro-menuoption value="duration">Duration</auro-menuoption>
552
+ <auro-menuoption value="departure">Departure</auro-menuoption>
553
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
554
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
555
+ </auro-menu>
556
+ </auro-select>
557
+ <!-- AURO-GENERATED-CONTENT:END -->
558
+ </div>
559
+ <auro-accordion alignRight>
560
+ <span slot="trigger">See code</span>
561
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/disabled.html) -->
562
+ <!-- The below code snippet is automatically added from ./../apiExamples/disabled.html -->
563
+
564
+ ```html
565
+ <auro-select disabled>
566
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
567
+ <label slot="placeholder">Placeholder Text</label>
568
+ <span slot="label">disabled select example</span>
569
+ <auro-menu>
570
+ <auro-menuoption value="stops">Stops</auro-menuoption>
571
+ <auro-menuoption value="price">Price</auro-menuoption>
572
+ <auro-menuoption value="duration">Duration</auro-menuoption>
573
+ <auro-menuoption value="departure">Departure</auro-menuoption>
574
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
575
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
576
+ </auro-menu>
577
+ </auro-select>
578
+ ```
579
+ <!-- AURO-GENERATED-CONTENT:END -->
580
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/onDarkDisabled.html) -->
581
+ <!-- The below content is automatically added from ./../apiExamples/onDarkDisabled.html -->
582
+ <auro-select onDark disabled>
583
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
584
+ <label slot="placeholder">Placeholder Text</label>
585
+ <span slot="label">disabled select example</span>
586
+ <auro-menu>
587
+ <auro-menuoption value="stops">Stops</auro-menuoption>
588
+ <auro-menuoption value="price">Price</auro-menuoption>
589
+ <auro-menuoption value="duration">Duration</auro-menuoption>
590
+ <auro-menuoption value="departure">Departure</auro-menuoption>
591
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
592
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
593
+ </auro-menu>
594
+ </auro-select>
595
+ <!-- AURO-GENERATED-CONTENT:END -->
596
+ </auro-accordion>
597
+
598
+ #### multiselect <a name="multiselect"></a>
599
+ Sets multi-select mode, allowing multiple options to be selected at once.
600
+
601
+ <div class="exampleWrapper">
602
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/multiselect.html) -->
603
+ <!-- The below content is automatically added from ./../apiExamples/multiselect.html -->
604
+ <auro-select multiselect>
605
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
606
+ <label slot="placeholder">Select one or more options</label>
607
+ <span slot="label">multiselect select example</span>
608
+ <auro-menu>
609
+ <auro-menuoption value="1">Option 1</auro-menuoption>
610
+ <auro-menuoption value="2">Option 2</auro-menuoption>
611
+ <auro-menuoption value="3">Option 3</auro-menuoption>
612
+ </auro-menu>
613
+ </auro-select>
614
+ <!-- AURO-GENERATED-CONTENT:END -->
615
+ </div>
616
+ <auro-accordion alignRight>
617
+ <span slot="trigger">See code</span>
618
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/multiselect.html) -->
619
+ <!-- The below code snippet is automatically added from ./../apiExamples/multiselect.html -->
620
+
621
+ ```html
622
+ <auro-select multiselect>
623
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
624
+ <label slot="placeholder">Select one or more options</label>
625
+ <span slot="label">multiselect select example</span>
626
+ <auro-menu>
627
+ <auro-menuoption value="1">Option 1</auro-menuoption>
628
+ <auro-menuoption value="2">Option 2</auro-menuoption>
629
+ <auro-menuoption value="3">Option 3</auro-menuoption>
630
+ </auro-menu>
631
+ </auro-select>
632
+ ```
633
+ <!-- AURO-GENERATED-CONTENT:END -->
634
+ </auro-accordion>
635
+
636
+ #### flexMenuWidth <a name="flexMenuWidth"></a>
637
+ Use the `flexMenuWidth` boolean attribute to toggle the width of the `<auro-select>` element to match the width of the bib content, rather than the width of the trigger.
638
+
639
+ <div class="exampleWrapper">
640
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=../apiExamples/flexMenuWidth.html) -->
641
+ <!-- The below content is automatically added from ../apiExamples/flexMenuWidth.html -->
642
+ <auro-select flexMenuWidth id="flexMenuWidthExample">
643
+ <span slot="label">flexMenuWidth select example</span>
644
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
645
+ <label slot="placeholder">Placeholder Text</label>
646
+ <auro-menu>
647
+ <auro-menuoption value="united states">United States has a country code of (+1)</auro-menuoption>
648
+ <auro-menuoption value="costa rica">Costa Rica has a country code of (+506)</auro-menuoption>
649
+ <auro-menuoption value="mexico">Mexico has a country code of (+52)</auro-menuoption>
650
+ <auro-menuoption value="afghanistan">Afghanistan has a country code of (+93)</auro-menuoption>
651
+ <auro-menuoption value="albania">Albania has a country code of (+355)</auro-menuoption>
652
+ </auro-menu>
653
+ </auro-select>
654
+ <style>
655
+ #flexMenuWidthExample::part(dropdownTrigger) {
656
+ width: 25%;
657
+ }
658
+ </style>
659
+ <!-- AURO-GENERATED-CONTENT:END -->
660
+ </div>
661
+ <auro-accordion alignRight>
662
+ <span slot="trigger">See code</span>
663
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=../apiExamples/flexMenuWidth.html) -->
664
+ <!-- The below code snippet is automatically added from ../apiExamples/flexMenuWidth.html -->
665
+
666
+ ```html
667
+ <auro-select flexMenuWidth id="flexMenuWidthExample">
668
+ <span slot="label">flexMenuWidth select example</span>
669
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
670
+ <label slot="placeholder">Placeholder Text</label>
671
+ <auro-menu>
672
+ <auro-menuoption value="united states">United States has a country code of (+1)</auro-menuoption>
673
+ <auro-menuoption value="costa rica">Costa Rica has a country code of (+506)</auro-menuoption>
674
+ <auro-menuoption value="mexico">Mexico has a country code of (+52)</auro-menuoption>
675
+ <auro-menuoption value="afghanistan">Afghanistan has a country code of (+93)</auro-menuoption>
676
+ <auro-menuoption value="albania">Albania has a country code of (+355)</auro-menuoption>
677
+ </auro-menu>
678
+ </auro-select>
679
+ <style>
680
+ #flexMenuWidthExample::part(dropdownTrigger) {
681
+ width: 25%;
682
+ }
683
+ </style>
684
+ ```
685
+ <!-- AURO-GENERATED-CONTENT:END -->
686
+ </auro-accordion>
687
+
688
+ ### Slot Examples
689
+
690
+ #### label <a name="label"></a>
691
+ Use the `label` slot to give your users contextual information about their selection options. This `label` content is also helpful for assistive devices.
692
+
693
+ <div class="exampleWrapper">
694
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/label.html) -->
695
+ <!-- The below content is automatically added from ./../apiExamples/label.html -->
696
+ <auro-select>
697
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
698
+ <span slot="label">Please select a preference</span>
699
+ <auro-menu>
700
+ <auro-menuoption value="stops">Stops</auro-menuoption>
701
+ <auro-menuoption value="price">Price</auro-menuoption>
702
+ <auro-menuoption value="duration">Duration</auro-menuoption>
703
+ <auro-menuoption value="departure">Departure</auro-menuoption>
704
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
705
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
706
+ </auro-menu>
707
+ </auro-select>
708
+ <!-- AURO-GENERATED-CONTENT:END -->
709
+ </div>
710
+ <auro-accordion alignRight>
711
+ <span slot="trigger">See code</span>
712
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/label.html) -->
713
+ <!-- The below code snippet is automatically added from ./../apiExamples/label.html -->
714
+
715
+ ```html
716
+ <auro-select>
717
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
718
+ <span slot="label">Please select a preference</span>
719
+ <auro-menu>
720
+ <auro-menuoption value="stops">Stops</auro-menuoption>
721
+ <auro-menuoption value="price">Price</auro-menuoption>
722
+ <auro-menuoption value="duration">Duration</auro-menuoption>
723
+ <auro-menuoption value="departure">Departure</auro-menuoption>
724
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
725
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
726
+ </auro-menu>
727
+ </auro-select>
728
+ ```
729
+ <!-- AURO-GENERATED-CONTENT:END -->
730
+ </auro-accordion>
731
+
732
+ #### helpText <a name="helpText"></a>
733
+ Use the `helptext` slot to provide additional information back to your user about their selection option(s).
734
+
735
+ <div class="exampleWrapper">
736
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/helpText.html) -->
737
+ <!-- The below content is automatically added from ./../apiExamples/helpText.html -->
738
+ <auro-select>
739
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
740
+ <label slot="placeholder">Placeholder Text</label>
741
+ <span slot="helpText">Custom help text message.</span>
742
+ <span slot="label">helpText select example</span>
743
+ <auro-menu>
744
+ <auro-menuoption value="stops">Stops</auro-menuoption>
745
+ <auro-menuoption value="price">Price</auro-menuoption>
746
+ <auro-menuoption value="duration">Duration</auro-menuoption>
747
+ <auro-menuoption value="departure">Departure</auro-menuoption>
748
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
749
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
750
+ </auro-menu>
751
+ </auro-select>
752
+ <!-- AURO-GENERATED-CONTENT:END -->
753
+ </div>
754
+ <auro-accordion alignRight>
755
+ <span slot="trigger">See code</span>
756
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/helpText.html) -->
757
+ <!-- The below code snippet is automatically added from ./../apiExamples/helpText.html -->
758
+
759
+ ```html
760
+ <auro-select>
761
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
762
+ <label slot="placeholder">Placeholder Text</label>
763
+ <span slot="helpText">Custom help text message.</span>
764
+ <span slot="label">helpText select example</span>
765
+ <auro-menu>
766
+ <auro-menuoption value="stops">Stops</auro-menuoption>
767
+ <auro-menuoption value="price">Price</auro-menuoption>
768
+ <auro-menuoption value="duration">Duration</auro-menuoption>
769
+ <auro-menuoption value="departure">Departure</auro-menuoption>
770
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
771
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
772
+ </auro-menu>
773
+ </auro-select>
774
+ ```
775
+ <!-- AURO-GENERATED-CONTENT:END -->
776
+ </auro-accordion>
777
+
778
+ ## Functional Examples
779
+
780
+ ### Reset State
781
+
782
+ Use the `reset()` method to reset the `<auro-select>`'s `value` and `validity` state. Doing so will preserve all other attributes and properties.
783
+
784
+ <div class="exampleWrapper">
785
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/resetState.html) -->
786
+ <!-- The below content is automatically added from ./../apiExamples/resetState.html -->
787
+ <auro-button id="resetStateBtn">Reset</auro-button>
788
+ <br/><br/>
789
+ <auro-select id="resetStateExample" value='["price"]'>
790
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
791
+ <label slot="placeholder">Placeholder Text</label>
792
+ <span slot="label">Name</span>
793
+ <auro-menu>
794
+ <auro-menuoption value="stops">Stops</auro-menuoption>
795
+ <auro-menuoption value="price">Price</auro-menuoption>
796
+ <auro-menuoption value="duration">Duration</auro-menuoption>
797
+ <auro-menuoption value="departure">Departure</auro-menuoption>
798
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
799
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
800
+ </auro-menu>
801
+ </auro-select>
802
+ <!-- AURO-GENERATED-CONTENT:END -->
803
+ </div>
804
+ <auro-accordion alignRight>
805
+ <span slot="trigger">See code</span>
806
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/resetState.html) -->
807
+ <!-- The below code snippet is automatically added from ./../apiExamples/resetState.html -->
808
+
809
+ ```html
810
+ <auro-button id="resetStateBtn">Reset</auro-button>
811
+ <br/><br/>
812
+ <auro-select id="resetStateExample" value='["price"]'>
813
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
814
+ <label slot="placeholder">Placeholder Text</label>
815
+ <span slot="label">Name</span>
816
+ <auro-menu>
817
+ <auro-menuoption value="stops">Stops</auro-menuoption>
818
+ <auro-menuoption value="price">Price</auro-menuoption>
819
+ <auro-menuoption value="duration">Duration</auro-menuoption>
820
+ <auro-menuoption value="departure">Departure</auro-menuoption>
821
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
822
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
823
+ </auro-menu>
824
+ </auro-select>
825
+ ```
826
+ <!-- AURO-GENERATED-CONTENT:END -->
827
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/resetState.js) -->
828
+ <!-- The below code snippet is automatically added from ./../apiExamples/resetState.js -->
829
+
830
+ ```js
831
+ export function resetStateExample() {
832
+ const elem = document.querySelector('#resetStateExample');
833
+
834
+ document.querySelector('#resetStateBtn').addEventListener('click', () => {
835
+ elem.reset();
836
+ });
837
+ }
838
+ ```
839
+ <!-- AURO-GENERATED-CONTENT:END -->
840
+ </auro-accordion>
841
+
842
+ ### Extract value
843
+
844
+ The following example illustrates how a user may query the `element.value` or `element.optionSelected` for the current value or complete option object that is selected.
845
+
846
+ <div class="exampleWrapper">
847
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/valueExtraction.html) -->
848
+ <!-- The below content is automatically added from ./../apiExamples/valueExtraction.html -->
849
+ <auro-select id="valueExtraction">
850
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
851
+ <label slot="placeholder">Placeholder Text</label>
852
+ <span slot="label">Select Example</span>
853
+ <auro-menu>
854
+ <auro-menuoption value="stops">Stops</auro-menuoption>
855
+ <auro-menuoption value="price">Price</auro-menuoption>
856
+ <auro-menuoption value="duration">Duration</auro-menuoption>
857
+ <auro-menuoption value="departure">Departure</auro-menuoption>
858
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
859
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
860
+ </auro-menu>
861
+ </auro-select>
862
+ <auro-button id="valueExtractionBtn">Get current value</auro-button>
863
+ <!-- AURO-GENERATED-CONTENT:END -->
864
+ </div>
865
+ <auro-accordion alignRight>
866
+ <span slot="trigger">See code</span>
867
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/valueExtraction.html) -->
868
+ <!-- The below code snippet is automatically added from ./../apiExamples/valueExtraction.html -->
869
+
870
+ ```html
871
+ <auro-select id="valueExtraction">
872
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
873
+ <label slot="placeholder">Placeholder Text</label>
874
+ <span slot="label">Select Example</span>
875
+ <auro-menu>
876
+ <auro-menuoption value="stops">Stops</auro-menuoption>
877
+ <auro-menuoption value="price">Price</auro-menuoption>
878
+ <auro-menuoption value="duration">Duration</auro-menuoption>
879
+ <auro-menuoption value="departure">Departure</auro-menuoption>
880
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
881
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
882
+ </auro-menu>
883
+ </auro-select>
884
+ <auro-button id="valueExtractionBtn">Get current value</auro-button>
885
+ ```
886
+ <!-- AURO-GENERATED-CONTENT:END -->
887
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/valueExtraction.js) -->
888
+ <!-- The below code snippet is automatically added from ./../apiExamples/valueExtraction.js -->
889
+
890
+ ```js
891
+ export function valueExtractionExample() {
892
+ const valueExtractionExample = document.querySelector('#valueExtraction');
893
+ const valueExtractionBtn = document.querySelector('#valueExtractionBtn');
894
+
895
+ valueExtractionBtn.addEventListener('click', () => {
896
+ console.warn('Value selected:', valueExtractionExample.value);
897
+ console.warn('Option selected:', valueExtractionExample.optionSelected);
898
+
899
+ alert(`Value selected: ${valueExtractionExample.value}`);
900
+ })
901
+ }
902
+ ```
903
+ <!-- AURO-GENERATED-CONTENT:END -->
904
+ </auro-accordion>
905
+
906
+ ### Custom Validity with Error State
907
+
908
+ This example programmatically adds the `error` state when a user selects an option that is greater than `2`.
909
+
910
+ <div class="exampleWrapper">
911
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/customErrorValidity.html) -->
912
+ <!-- The below content is automatically added from ./../apiExamples/customErrorValidity.html -->
913
+ <auro-select id="primaryError">
914
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
915
+ <label slot="placeholder">Placeholder Text</label>
916
+ <span slot="label">Select Example</span>
917
+ <auro-menu>
918
+ <auro-menuoption value="1">1</auro-menuoption>
919
+ <auro-menuoption value="2">2</auro-menuoption>
920
+ <auro-menuoption value="3">3</auro-menuoption>
921
+ <auro-menuoption value="4">4</auro-menuoption>
922
+ <auro-menuoption value="5">5</auro-menuoption>
923
+ <auro-menuoption value="6">6</auro-menuoption>
924
+ </auro-menu>
925
+ </auro-select>
926
+ <!-- AURO-GENERATED-CONTENT:END -->
927
+ </div>
928
+ <auro-accordion alignRight>
929
+ <span slot="trigger">See code</span>
930
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/customErrorValidity.html) -->
931
+ <!-- The below code snippet is automatically added from ./../apiExamples/customErrorValidity.html -->
932
+
933
+ ```html
934
+ <auro-select id="primaryError">
935
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
936
+ <label slot="placeholder">Placeholder Text</label>
937
+ <span slot="label">Select Example</span>
938
+ <auro-menu>
939
+ <auro-menuoption value="1">1</auro-menuoption>
940
+ <auro-menuoption value="2">2</auro-menuoption>
941
+ <auro-menuoption value="3">3</auro-menuoption>
942
+ <auro-menuoption value="4">4</auro-menuoption>
943
+ <auro-menuoption value="5">5</auro-menuoption>
944
+ <auro-menuoption value="6">6</auro-menuoption>
945
+ </auro-menu>
946
+ </auro-select>
947
+ ```
948
+ <!-- AURO-GENERATED-CONTENT:END -->
949
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/customErrorValidity.js) -->
950
+ <!-- The below code snippet is automatically added from ./../apiExamples/customErrorValidity.js -->
951
+
952
+ ```js
953
+ export function customErrorValidityExample(elem) {
954
+ const customErrorValidityExample = document.querySelector('#primaryError');
955
+
956
+ customErrorValidityExample.addEventListener('auroSelect-valueSet', () => {
957
+ if (+customErrorValidityExample.value > 2) {
958
+ customErrorValidityExample.setAttribute('error', 'Quantity Exceeded');
959
+ } else if (customErrorValidityExample.hasAttribute('error')) {
960
+ customErrorValidityExample.removeAttribute('error');
961
+ }
962
+ })
963
+ };
964
+ ```
965
+ <!-- AURO-GENERATED-CONTENT:END -->
966
+ </auro-accordion>
967
+
968
+ ### Loading<a name="loading"></a>
969
+ While content is loading, the menu can either remain empty or display a loading placeholder
970
+
971
+ <div class="exampleWrapper">
972
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/loading.html) -->
973
+ <!-- The below content is automatically added from ./../apiExamples/loading.html -->
974
+ <auro-select id="loadingExample">
975
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
976
+ <span slot="label">Please select a preference</span>
977
+ <auro-menu id="loadingExampleSelectMenu">
978
+ <auro-loader slot="loadingIcon" orbit xs></auro-loader><span slot="loadingText">Loading...</span>
979
+ </auro-menu>
980
+ </auro-select>
981
+ <!-- AURO-GENERATED-CONTENT:END -->
982
+ </div>
983
+ <auro-accordion alignRight>
984
+ <span slot="trigger">See code</span>
985
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/loading.js) -->
986
+ <!-- The below code snippet is automatically added from ./../apiExamples/loading.js -->
987
+
988
+ ```js
989
+ export function auroMenuLoadingExample() {
990
+ const select = document.querySelector("#loadingExample");
991
+ const menu = document.querySelector("#loadingExampleSelectMenu");
992
+
993
+ const emptyMenu = () => {
994
+ const menuoptions = menu.querySelectorAll('auro-menuoption');
995
+ menuoptions.forEach(mo => menu.removeChild(mo));
996
+ }
997
+
998
+ const fillMenu = () => {
999
+ menu.innerHTML += `
1000
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1001
+ <auro-menuoption value="price">Price</auro-menuoption>
1002
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1003
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1004
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1005
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>`;
1006
+ }
1007
+
1008
+ select.addEventListener("click", () => {
1009
+ if (!menu.hasAttribute('loading') && !select.value) {
1010
+ emptyMenu();
1011
+ menu.setAttribute('loading', 'loading');
1012
+ setTimeout(() => {
1013
+ menu.removeAttribute('loading');
1014
+ fillMenu();
1015
+ }, 1000);
1016
+ }
1017
+ });
1018
+ }
1019
+ ```
1020
+ <!-- AURO-GENERATED-CONTENT:END -->
1021
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/loading.html) -->
1022
+ <!-- The below code snippet is automatically added from ./../apiExamples/loading.html -->
1023
+
1024
+ ```html
1025
+ <auro-select id="loadingExample">
1026
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1027
+ <span slot="label">Please select a preference</span>
1028
+ <auro-menu id="loadingExampleSelectMenu">
1029
+ <auro-loader slot="loadingIcon" orbit xs></auro-loader><span slot="loadingText">Loading...</span>
1030
+ </auro-menu>
1031
+ </auro-select>
1032
+ ```
1033
+ <!-- AURO-GENERATED-CONTENT:END -->
1034
+ </auro-accordion>
1035
+
1036
+ ### Customized bib position
1037
+ The bib position can be customized with `placement`, `offset`, `flip`, `autoPlacement` attributes.
1038
+
1039
+ - `placement` specifies the preferred position where the bib should appear relative to the trigger.
1040
+ - `offset` sets the distance between the trigger and the bib.
1041
+ - When `autoPlacement` is enabled, smart positioning logic is applied to determine the best placement for the bib. If all sides have sufficient space, the bib will appear in the position specified by `placement`.
1042
+ - Unless `noFlip` is enabled, if there isn't enough space for the preferred `placement`, the bib will automatically flip to an alternative position.
1043
+
1044
+ <div class="exampleWrapper">
1045
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/floaterConfig.html) -->
1046
+ <!-- The below content is automatically added from ./../apiExamples/floaterConfig.html -->
1047
+ <div style="width: 350px">
1048
+ <auro-select offset="20" noFlip placement="bottom-end">
1049
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1050
+ <span slot="label">bottom-end bib with 20px offset and noFlip</span>
1051
+ <auro-menu>
1052
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1053
+ <auro-menuoption value="price">Price</auro-menuoption>
1054
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1055
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1056
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1057
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1058
+ </auro-menu>
1059
+ </auro-select>
1060
+ <auro-select offset="20" placement="bottom-end">
1061
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1062
+ <span slot="label">bottom-end bib with 20px offset and flip</span>
1063
+ <auro-menu>
1064
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1065
+ <auro-menuoption value="price">Price</auro-menuoption>
1066
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1067
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1068
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1069
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1070
+ </auro-menu>
1071
+ </auro-select>
1072
+ <auro-select offset="20" noFlip placement="right" autoPlacement noFlip >
1073
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1074
+ <span slot="label">right bib with 20px offset, noFlip and autoPlacement</span>
1075
+ <auro-menu>
1076
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1077
+ <auro-menuoption value="price">Price</auro-menuoption>
1078
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1079
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1080
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1081
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1082
+ </auro-menu>
1083
+ </auro-select>
1084
+ </div>
1085
+ <!-- AURO-GENERATED-CONTENT:END -->
1086
+ </div>
1087
+ <auro-accordion alignRight>
1088
+ <span slot="trigger">See code</span>
1089
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/floaterConfig.html) -->
1090
+ <!-- The below code snippet is automatically added from ./../apiExamples/floaterConfig.html -->
1091
+
1092
+ ```html
1093
+ <div style="width: 350px">
1094
+ <auro-select offset="20" noFlip placement="bottom-end">
1095
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1096
+ <span slot="label">bottom-end bib with 20px offset and noFlip</span>
1097
+ <auro-menu>
1098
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1099
+ <auro-menuoption value="price">Price</auro-menuoption>
1100
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1101
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1102
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1103
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1104
+ </auro-menu>
1105
+ </auro-select>
1106
+ <auro-select offset="20" placement="bottom-end">
1107
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1108
+ <span slot="label">bottom-end bib with 20px offset and flip</span>
1109
+ <auro-menu>
1110
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1111
+ <auro-menuoption value="price">Price</auro-menuoption>
1112
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1113
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1114
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1115
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1116
+ </auro-menu>
1117
+ </auro-select>
1118
+ <auro-select offset="20" noFlip placement="right" autoPlacement noFlip >
1119
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1120
+ <span slot="label">right bib with 20px offset, noFlip and autoPlacement</span>
1121
+ <auro-menu>
1122
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1123
+ <auro-menuoption value="price">Price</auro-menuoption>
1124
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1125
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1126
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1127
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1128
+ </auro-menu>
1129
+ </auro-select>
1130
+ </div>
1131
+ ```
1132
+ <!-- AURO-GENERATED-CONTENT:END -->
1133
+ </auro-accordion>
1134
+
1135
+ ### Dropdown with fullscreen bib
1136
+
1137
+ You can make the dropdown open in fullscreen at a specific breakpoint by setting `fullscreenBreakpoint`.
1138
+
1139
+ The default value of `fullscreenBreakpoint` is `sm`.
1140
+
1141
+ Breakpoint token can be found [here](https://auro.alaskaair.com/getting-started/developers/design-tokens)
1142
+
1143
+ To support fullcreen bib, setting `bib.fullscreen.headline` is **STRONGLY RECOMMENDED**.
1144
+
1145
+ <div class="exampleWrapper">
1146
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/fullscreenBreakpoint.html) -->
1147
+ <!-- The below content is automatically added from ./../apiExamples/fullscreenBreakpoint.html -->
1148
+ <auro-select fullscreenBreakpoint="lg">
1149
+ <span slot="label">Select Example</span>
1150
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1151
+ <auro-menu>
1152
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1153
+ <auro-menuoption value="price">Price</auro-menuoption>
1154
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1155
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1156
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1157
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1158
+ </auro-menu>
1159
+ </auro-select>
1160
+ <!-- AURO-GENERATED-CONTENT:END -->
1161
+ </div>
1162
+ <auro-accordion alignRight>
1163
+ <span slot="trigger">See code</span>
1164
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/fullscreenBreakpoint.html) -->
1165
+ <!-- The below code snippet is automatically added from ./../apiExamples/fullscreenBreakpoint.html -->
1166
+
1167
+ ```html
1168
+ <auro-select fullscreenBreakpoint="lg">
1169
+ <span slot="label">Select Example</span>
1170
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1171
+ <auro-menu>
1172
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1173
+ <auro-menuoption value="price">Price</auro-menuoption>
1174
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1175
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1176
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1177
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1178
+ </auro-menu>
1179
+ </auro-select>
1180
+ ```
1181
+ <!-- AURO-GENERATED-CONTENT:END -->
1182
+ </auro-accordion>
1183
+
1184
+ #### in Dialog
1185
+
1186
+ The component can be in a dialog.
1187
+
1188
+ <div class="exampleWrapper">
1189
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/inDialog.html) -->
1190
+ <!-- The below content is automatically added from ./../apiExamples/inDialog.html -->
1191
+ <div>
1192
+ <auro-button id="select-dialog-opener">Select in Dialog</auro-button>
1193
+ <auro-dialog id="select-dialog">
1194
+ <span slot="header">Select in Dialog</span>
1195
+ <div slot="content">
1196
+ <auro-select id="valueExample" value='["price"]'>
1197
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1198
+ <span slot="label">Name</span>
1199
+ <auro-menu>
1200
+ <auro-menuoption id="option-0" value="stops">Stops</auro-menuoption>
1201
+ <auro-menuoption id="option-1" value="price">Price</auro-menuoption>
1202
+ <auro-menuoption id="option-2" value="duration">Duration</auro-menuoption>
1203
+ <auro-menuoption id="option-3" value="departure">Departure</auro-menuoption>
1204
+ <auro-menuoption id="option-4" value="arrival">Arrival</auro-menuoption>
1205
+ <auro-menuoption id="option-5" value="prefer alaska">Prefer Alaska</auro-menuoption>
1206
+ </auro-menu>
1207
+ </auro-select>
1208
+ </div>
1209
+ </auro-dialog>
1210
+ </div>
1211
+ <!-- AURO-GENERATED-CONTENT:END -->
1212
+ </div>
1213
+ <auro-accordion alignRight>
1214
+ <span slot="trigger">See code</span>
1215
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/inDialog.html) -->
1216
+ <!-- The below code snippet is automatically added from ./../apiExamples/inDialog.html -->
1217
+
1218
+ ```html
1219
+ <div>
1220
+ <auro-button id="select-dialog-opener">Select in Dialog</auro-button>
1221
+ <auro-dialog id="select-dialog">
1222
+ <span slot="header">Select in Dialog</span>
1223
+ <div slot="content">
1224
+ <auro-select id="valueExample" value='["price"]'>
1225
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1226
+ <span slot="label">Name</span>
1227
+ <auro-menu>
1228
+ <auro-menuoption id="option-0" value="stops">Stops</auro-menuoption>
1229
+ <auro-menuoption id="option-1" value="price">Price</auro-menuoption>
1230
+ <auro-menuoption id="option-2" value="duration">Duration</auro-menuoption>
1231
+ <auro-menuoption id="option-3" value="departure">Departure</auro-menuoption>
1232
+ <auro-menuoption id="option-4" value="arrival">Arrival</auro-menuoption>
1233
+ <auro-menuoption id="option-5" value="prefer alaska">Prefer Alaska</auro-menuoption>
1234
+ </auro-menu>
1235
+ </auro-select>
1236
+ </div>
1237
+ </auro-dialog>
1238
+ </div>
1239
+ ```
1240
+ <!-- AURO-GENERATED-CONTENT:END -->
1241
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/inDialog.js) -->
1242
+ <!-- The below code snippet is automatically added from ./../apiExamples/inDialog.js -->
1243
+
1244
+ ```js
1245
+ export function inDialogExample() {
1246
+ document.querySelector("#select-dialog-opener").addEventListener("click", () => {
1247
+ const dialog = document.querySelector("#select-dialog");
1248
+ dialog.open = true;
1249
+ });
1250
+ };
1251
+ ```
1252
+ <!-- AURO-GENERATED-CONTENT:END -->
1253
+ </auro-accordion>
1254
+
1255
+ #### Watch for value changes
1256
+
1257
+ The following example listens for the `auroMenu-selectedOption` event. Once triggered, element.value or element.optionSelected may be queried for the new value or complete option object.
1258
+
1259
+ <div class="exampleWrapper">
1260
+ <!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/valueAlert.html) -->
1261
+ <!-- The below content is automatically added from ./../apiExamples/valueAlert.html -->
1262
+ <auro-select id="valueAlert">
1263
+ <span slot="label">Select Example</span>
1264
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1265
+ <label slot="placeholder">Placeholder Text</label>
1266
+ <auro-menu id="valueAlertMenu">
1267
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1268
+ <auro-menuoption value="price">Price</auro-menuoption>
1269
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1270
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1271
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1272
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1273
+ </auro-menu>
1274
+ </auro-select>
1275
+ <!-- AURO-GENERATED-CONTENT:END -->
1276
+ </div>
1277
+ <auro-accordion alignRight>
1278
+ <span slot="trigger">See code</span>
1279
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/valueAlert.html) -->
1280
+ <!-- The below code snippet is automatically added from ./../apiExamples/valueAlert.html -->
1281
+
1282
+ ```html
1283
+ <auro-select id="valueAlert">
1284
+ <span slot="label">Select Example</span>
1285
+ <span slot="bib.fullscreen.headline">Bib Headline</span>
1286
+ <label slot="placeholder">Placeholder Text</label>
1287
+ <auro-menu id="valueAlertMenu">
1288
+ <auro-menuoption value="stops">Stops</auro-menuoption>
1289
+ <auro-menuoption value="price">Price</auro-menuoption>
1290
+ <auro-menuoption value="duration">Duration</auro-menuoption>
1291
+ <auro-menuoption value="departure">Departure</auro-menuoption>
1292
+ <auro-menuoption value="arrival">Arrival</auro-menuoption>
1293
+ <auro-menuoption value="prefer alaska">Prefer Alaska</auro-menuoption>
1294
+ </auro-menu>
1295
+ </auro-select>
1296
+ ```
1297
+ <!-- AURO-GENERATED-CONTENT:END -->
1298
+ <!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/valueAlert.js) -->
1299
+ <!-- The below code snippet is automatically added from ./../apiExamples/valueAlert.js -->
1300
+
1301
+ ```js
1302
+ export function valueAlertExample() {
1303
+ const select = document.querySelector('#valueAlert');
1304
+ const menu = document.querySelector('#valueAlertMenu');
1305
+
1306
+ menu.addEventListener('auroMenu-selectedOption', () => {
1307
+ console.warn('Select value changed to:', select.value);
1308
+ console.warn('Select optionSelected changed to:', select.optionSelected);
1309
+ });
1310
+ }
1311
+ ```
1312
+ <!-- AURO-GENERATED-CONTENT:END -->
1313
+ </auro-accordion>