@aurodesignsystem-dev/auro-formkit 0.0.0-pr1001.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 (297) 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 +50 -0
  6. package/components/bibtemplate/dist/buttonVersion.d.ts +2 -0
  7. package/components/bibtemplate/dist/headerVersion.d.ts +2 -0
  8. package/components/bibtemplate/dist/iconVersion.d.ts +2 -0
  9. package/components/bibtemplate/dist/index.d.ts +2 -0
  10. package/components/bibtemplate/dist/index.js +1940 -0
  11. package/components/bibtemplate/dist/registered.js +1940 -0
  12. package/components/bibtemplate/dist/styles/color-css.d.ts +2 -0
  13. package/components/bibtemplate/dist/styles/style-css.d.ts +2 -0
  14. package/components/bibtemplate/dist/styles/tokens-css.d.ts +2 -0
  15. package/components/checkbox/README.md +142 -0
  16. package/components/checkbox/demo/api.html +61 -0
  17. package/components/checkbox/demo/api.js +17 -0
  18. package/components/checkbox/demo/api.md +436 -0
  19. package/components/checkbox/demo/api.min.js +1870 -0
  20. package/components/checkbox/demo/index.html +57 -0
  21. package/components/checkbox/demo/index.js +8 -0
  22. package/components/checkbox/demo/index.md +327 -0
  23. package/components/checkbox/demo/index.min.js +1845 -0
  24. package/components/checkbox/demo/readme.html +57 -0
  25. package/components/checkbox/demo/readme.md +142 -0
  26. package/components/checkbox/dist/auro-checkbox-group.d.ts +166 -0
  27. package/components/checkbox/dist/auro-checkbox.d.ts +136 -0
  28. package/components/checkbox/dist/helptextVersion.d.ts +2 -0
  29. package/components/checkbox/dist/index.d.ts +3 -0
  30. package/components/checkbox/dist/index.js +1794 -0
  31. package/components/checkbox/dist/registered.js +1795 -0
  32. package/components/checkbox/dist/styles/auro-checkbox-css.d.ts +2 -0
  33. package/components/checkbox/dist/styles/auro-checkbox-group-css.d.ts +2 -0
  34. package/components/checkbox/dist/styles/color-css.d.ts +2 -0
  35. package/components/checkbox/dist/styles/colorGroup-css.d.ts +2 -0
  36. package/components/checkbox/dist/styles/tokens-css.d.ts +2 -0
  37. package/components/combobox/README.md +154 -0
  38. package/components/combobox/demo/api.html +63 -0
  39. package/components/combobox/demo/api.js +36 -0
  40. package/components/combobox/demo/api.md +1326 -0
  41. package/components/combobox/demo/api.min.js +18691 -0
  42. package/components/combobox/demo/index.html +63 -0
  43. package/components/combobox/demo/index.js +26 -0
  44. package/components/combobox/demo/index.md +725 -0
  45. package/components/combobox/demo/index.min.js +18545 -0
  46. package/components/combobox/demo/readme.html +57 -0
  47. package/components/combobox/demo/readme.md +154 -0
  48. package/components/combobox/dist/auro-combobox.d.ts +434 -0
  49. package/components/combobox/dist/bibtemplateVersion.d.ts +2 -0
  50. package/components/combobox/dist/dropdownVersion.d.ts +2 -0
  51. package/components/combobox/dist/index.d.ts +2 -0
  52. package/components/combobox/dist/index.js +16999 -0
  53. package/components/combobox/dist/inputVersion.d.ts +2 -0
  54. package/components/combobox/dist/registered.js +17001 -0
  55. package/components/combobox/dist/styles/emphasized/style-css.d.ts +2 -0
  56. package/components/combobox/dist/styles/snowflake/style-css.d.ts +2 -0
  57. package/components/combobox/dist/styles/style-css.d.ts +2 -0
  58. package/components/counter/README.md +146 -0
  59. package/components/counter/demo/api.html +61 -0
  60. package/components/counter/demo/api.js +20 -0
  61. package/components/counter/demo/api.md +730 -0
  62. package/components/counter/demo/api.min.js +10406 -0
  63. package/components/counter/demo/index.html +61 -0
  64. package/components/counter/demo/index.js +21 -0
  65. package/components/counter/demo/index.md +401 -0
  66. package/components/counter/demo/index.min.js +10370 -0
  67. package/components/counter/demo/readme.html +57 -0
  68. package/components/counter/demo/readme.md +146 -0
  69. package/components/counter/dist/auro-counter-button.d.ts +14 -0
  70. package/components/counter/dist/auro-counter-group.d.ts +386 -0
  71. package/components/counter/dist/auro-counter-wrapper.d.ts +22 -0
  72. package/components/counter/dist/auro-counter.d.ts +113 -0
  73. package/components/counter/dist/bibtemplateVersion.d.ts +2 -0
  74. package/components/counter/dist/dropdownVersion.d.ts +2 -0
  75. package/components/counter/dist/helptextVersion.d.ts +2 -0
  76. package/components/counter/dist/iconVersion.d.ts +2 -0
  77. package/components/counter/dist/index.d.ts +3 -0
  78. package/components/counter/dist/index.js +10313 -0
  79. package/components/counter/dist/registered.js +10314 -0
  80. package/components/counter/dist/styles/color-css.d.ts +2 -0
  81. package/components/counter/dist/styles/counter-button-color-css.d.ts +2 -0
  82. package/components/counter/dist/styles/counter-button-css.d.ts +2 -0
  83. package/components/counter/dist/styles/counter-group-css.d.ts +2 -0
  84. package/components/counter/dist/styles/counter-wrapper-color-css.d.ts +2 -0
  85. package/components/counter/dist/styles/counter-wrapper-css.d.ts +2 -0
  86. package/components/counter/dist/styles/shapeSize-css.d.ts +2 -0
  87. package/components/counter/dist/styles/style-css.d.ts +2 -0
  88. package/components/counter/dist/styles/tokens-css.d.ts +2 -0
  89. package/components/datepicker/README.md +141 -0
  90. package/components/datepicker/demo/api.html +63 -0
  91. package/components/datepicker/demo/api.js +35 -0
  92. package/components/datepicker/demo/api.md +1529 -0
  93. package/components/datepicker/demo/api.min.js +29755 -0
  94. package/components/datepicker/demo/index.html +62 -0
  95. package/components/datepicker/demo/index.js +19 -0
  96. package/components/datepicker/demo/index.md +204 -0
  97. package/components/datepicker/demo/index.min.js +29476 -0
  98. package/components/datepicker/demo/readme.html +57 -0
  99. package/components/datepicker/demo/readme.md +141 -0
  100. package/components/datepicker/dist/auro-calendar-cell.d.ts +163 -0
  101. package/components/datepicker/dist/auro-calendar-month.d.ts +20 -0
  102. package/components/datepicker/dist/auro-calendar.d.ts +133 -0
  103. package/components/datepicker/dist/auro-datepicker.d.ts +625 -0
  104. package/components/datepicker/dist/bibtemplateVersion.d.ts +2 -0
  105. package/components/datepicker/dist/buttonVersion.d.ts +2 -0
  106. package/components/datepicker/dist/dropdownVersion.d.ts +2 -0
  107. package/components/datepicker/dist/iconVersion.d.ts +2 -0
  108. package/components/datepicker/dist/index.d.ts +2 -0
  109. package/components/datepicker/dist/index.js +29406 -0
  110. package/components/datepicker/dist/inputVersion.d.ts +2 -0
  111. package/components/datepicker/dist/popoverVersion.d.ts +2 -0
  112. package/components/datepicker/dist/registered.js +29406 -0
  113. package/components/datepicker/dist/styles/classic/color-css.d.ts +2 -0
  114. package/components/datepicker/dist/styles/classic/style-css.d.ts +2 -0
  115. package/components/datepicker/dist/styles/color-calendar-css.d.ts +2 -0
  116. package/components/datepicker/dist/styles/color-cell-css.d.ts +2 -0
  117. package/components/datepicker/dist/styles/color-css.d.ts +2 -0
  118. package/components/datepicker/dist/styles/color-month-css.d.ts +2 -0
  119. package/components/datepicker/dist/styles/shapeSize-css.d.ts +2 -0
  120. package/components/datepicker/dist/styles/snowflake/color-css.d.ts +2 -0
  121. package/components/datepicker/dist/styles/snowflake/style-css.d.ts +2 -0
  122. package/components/datepicker/dist/styles/style-auro-calendar-cell-css.d.ts +2 -0
  123. package/components/datepicker/dist/styles/style-auro-calendar-css.d.ts +2 -0
  124. package/components/datepicker/dist/styles/style-auro-calendar-month-css.d.ts +2 -0
  125. package/components/datepicker/dist/styles/style-css.d.ts +2 -0
  126. package/components/datepicker/dist/styles/tokens-css.d.ts +2 -0
  127. package/components/datepicker/dist/utilities.d.ts +78 -0
  128. package/components/datepicker/dist/utilitiesCalendar.d.ts +38 -0
  129. package/components/datepicker/dist/utilitiesCalendarRender.d.ts +50 -0
  130. package/components/datepicker/dist/vendor/wc-range-datepicker/day.d.ts +5 -0
  131. package/components/datepicker/dist/vendor/wc-range-datepicker/range-datepicker-calendar.d.ts +60 -0
  132. package/components/datepicker/dist/vendor/wc-range-datepicker/range-datepicker-cell.d.ts +1 -0
  133. package/components/datepicker/dist/vendor/wc-range-datepicker/range-datepicker.d.ts +57 -0
  134. package/components/dropdown/README.md +144 -0
  135. package/components/dropdown/demo/api.html +63 -0
  136. package/components/dropdown/demo/api.js +21 -0
  137. package/components/dropdown/demo/api.md +1266 -0
  138. package/components/dropdown/demo/api.min.js +4442 -0
  139. package/components/dropdown/demo/index.html +61 -0
  140. package/components/dropdown/demo/index.js +19 -0
  141. package/components/dropdown/demo/index.md +337 -0
  142. package/components/dropdown/demo/index.min.js +4405 -0
  143. package/components/dropdown/demo/readme.html +57 -0
  144. package/components/dropdown/demo/readme.md +144 -0
  145. package/components/dropdown/dist/auro-dropdown.d.ts +425 -0
  146. package/components/dropdown/dist/auro-dropdownBib.d.ts +68 -0
  147. package/components/dropdown/dist/dropdownVersion.d.ts +2 -0
  148. package/components/dropdown/dist/helptextVersion.d.ts +2 -0
  149. package/components/dropdown/dist/iconVersion.d.ts +2 -0
  150. package/components/dropdown/dist/index.d.ts +2 -0
  151. package/components/dropdown/dist/index.js +4350 -0
  152. package/components/dropdown/dist/registered.js +4350 -0
  153. package/components/dropdown/dist/styles/classic/bibColors-css.d.ts +2 -0
  154. package/components/dropdown/dist/styles/classic/bibStyles-css.d.ts +2 -0
  155. package/components/dropdown/dist/styles/classic/color-css.d.ts +2 -0
  156. package/components/dropdown/dist/styles/classic/style-css.d.ts +2 -0
  157. package/components/dropdown/dist/styles/color-css.d.ts +2 -0
  158. package/components/dropdown/dist/styles/emphasized/style-css.d.ts +2 -0
  159. package/components/dropdown/dist/styles/shapeSize-css.d.ts +2 -0
  160. package/components/dropdown/dist/styles/snowflake/style-css.d.ts +2 -0
  161. package/components/dropdown/dist/styles/style-css.d.ts +2 -0
  162. package/components/dropdown/dist/styles/tokens-css.d.ts +2 -0
  163. package/components/form/README.md +142 -0
  164. package/components/form/demo/api.html +56 -0
  165. package/components/form/demo/api.js +3 -0
  166. package/components/form/demo/api.md +51 -0
  167. package/components/form/demo/api.min.js +638 -0
  168. package/components/form/demo/autocomplete.html +31 -0
  169. package/components/form/demo/index.html +57 -0
  170. package/components/form/demo/index.js +4 -0
  171. package/components/form/demo/index.md +403 -0
  172. package/components/form/demo/index.min.js +639 -0
  173. package/components/form/demo/readme.html +57 -0
  174. package/components/form/demo/readme.md +142 -0
  175. package/components/form/demo/registerDemoDeps.js +23 -0
  176. package/components/form/demo/working.html +124 -0
  177. package/components/form/dist/auro-form.d.ts +223 -0
  178. package/components/form/dist/index.d.ts +2 -0
  179. package/components/form/dist/index.js +614 -0
  180. package/components/form/dist/registered.d.ts +1 -0
  181. package/components/form/dist/registered.js +614 -0
  182. package/components/form/dist/styles/style-css.d.ts +2 -0
  183. package/components/helptext/dist/auro-helptext.d.ts +59 -0
  184. package/components/helptext/dist/index.d.ts +2 -0
  185. package/components/helptext/dist/index.js +207 -0
  186. package/components/helptext/dist/registered.js +207 -0
  187. package/components/helptext/dist/styles/color-css.d.ts +2 -0
  188. package/components/helptext/dist/styles/style-css.d.ts +2 -0
  189. package/components/helptext/dist/styles/tokens-css.d.ts +2 -0
  190. package/components/input/README.md +139 -0
  191. package/components/input/demo/api.html +48 -0
  192. package/components/input/demo/api.js +29 -0
  193. package/components/input/demo/api.md +1366 -0
  194. package/components/input/demo/api.min.js +8542 -0
  195. package/components/input/demo/index.html +49 -0
  196. package/components/input/demo/index.js +20 -0
  197. package/components/input/demo/index.md +270 -0
  198. package/components/input/demo/index.min.js +8461 -0
  199. package/components/input/demo/readme.html +57 -0
  200. package/components/input/demo/readme.md +139 -0
  201. package/components/input/dist/auro-input.d.ts +167 -0
  202. package/components/input/dist/base-input.d.ts +566 -0
  203. package/components/input/dist/buttonVersion.d.ts +2 -0
  204. package/components/input/dist/helptextVersion.d.ts +2 -0
  205. package/components/input/dist/i18n.d.ts +18 -0
  206. package/components/input/dist/iconVersion.d.ts +2 -0
  207. package/components/input/dist/index.d.ts +2 -0
  208. package/components/input/dist/index.js +8367 -0
  209. package/components/input/dist/registered.js +8367 -0
  210. package/components/input/dist/styles/classic/color-css.d.ts +2 -0
  211. package/components/input/dist/styles/classic/style-css.d.ts +2 -0
  212. package/components/input/dist/styles/color-css.d.ts +2 -0
  213. package/components/input/dist/styles/default/borders-css.d.ts +2 -0
  214. package/components/input/dist/styles/default/color-css.d.ts +2 -0
  215. package/components/input/dist/styles/default/mixins-css.d.ts +2 -0
  216. package/components/input/dist/styles/default/notificationIcons-css.d.ts +2 -0
  217. package/components/input/dist/styles/default/style-css.d.ts +2 -0
  218. package/components/input/dist/styles/emphasized/color-css.d.ts +2 -0
  219. package/components/input/dist/styles/emphasized/style-css.d.ts +2 -0
  220. package/components/input/dist/styles/mixins-css.d.ts +2 -0
  221. package/components/input/dist/styles/shapeSize-css.d.ts +2 -0
  222. package/components/input/dist/styles/snowflake/style-css.d.ts +2 -0
  223. package/components/input/dist/styles/style-css.d.ts +2 -0
  224. package/components/input/dist/styles/tokens-css.d.ts +2 -0
  225. package/components/input/dist/utilities.d.ts +25 -0
  226. package/components/layoutElement/dist/auroElement.d.ts +34 -0
  227. package/components/layoutElement/dist/index.d.ts +2 -0
  228. package/components/layoutElement/dist/index.js +98 -0
  229. package/components/layoutElement/dist/registered.js +98 -0
  230. package/components/menu/README.md +145 -0
  231. package/components/menu/demo/api.html +62 -0
  232. package/components/menu/demo/api.js +27 -0
  233. package/components/menu/demo/api.md +1011 -0
  234. package/components/menu/demo/api.min.js +1762 -0
  235. package/components/menu/demo/index.html +58 -0
  236. package/components/menu/demo/index.js +28 -0
  237. package/components/menu/demo/index.md +61 -0
  238. package/components/menu/demo/index.min.js +1708 -0
  239. package/components/menu/demo/readme.html +57 -0
  240. package/components/menu/demo/readme.md +145 -0
  241. package/components/menu/dist/auro-menu-utils.d.ts +34 -0
  242. package/components/menu/dist/auro-menu.d.ts +246 -0
  243. package/components/menu/dist/auro-menuoption.d.ts +81 -0
  244. package/components/menu/dist/dropdownVersion.d.ts +2 -0
  245. package/components/menu/dist/iconVersion.d.ts +2 -0
  246. package/components/menu/dist/index.d.ts +4 -0
  247. package/components/menu/dist/index.js +1691 -0
  248. package/components/menu/dist/registered.js +1651 -0
  249. package/components/menu/dist/styles/default/color-menu-css.d.ts +2 -0
  250. package/components/menu/dist/styles/default/color-menuoption-css.d.ts +2 -0
  251. package/components/menu/dist/styles/default/style-menu-css.d.ts +2 -0
  252. package/components/menu/dist/styles/default/style-menuoption-css.d.ts +2 -0
  253. package/components/menu/dist/styles/default/tokens-css.d.ts +2 -0
  254. package/components/radio/README.md +137 -0
  255. package/components/radio/demo/api.html +59 -0
  256. package/components/radio/demo/api.js +19 -0
  257. package/components/radio/demo/api.md +602 -0
  258. package/components/radio/demo/api.min.js +1951 -0
  259. package/components/radio/demo/index.html +56 -0
  260. package/components/radio/demo/index.js +8 -0
  261. package/components/radio/demo/index.md +150 -0
  262. package/components/radio/demo/index.min.js +1908 -0
  263. package/components/radio/demo/readme.html +57 -0
  264. package/components/radio/demo/readme.md +137 -0
  265. package/components/radio/dist/auro-radio-group.d.ts +194 -0
  266. package/components/radio/dist/auro-radio.d.ts +147 -0
  267. package/components/radio/dist/helptextVersion.d.ts +2 -0
  268. package/components/radio/dist/index.d.ts +3 -0
  269. package/components/radio/dist/index.js +1857 -0
  270. package/components/radio/dist/registered.js +1858 -0
  271. package/components/radio/dist/styles/auro-radio-group-css.d.ts +2 -0
  272. package/components/radio/dist/styles/color-css.d.ts +2 -0
  273. package/components/radio/dist/styles/groupColor-css.d.ts +2 -0
  274. package/components/radio/dist/styles/style-css.d.ts +2 -0
  275. package/components/radio/dist/styles/tokens-css.d.ts +2 -0
  276. package/components/select/README.md +145 -0
  277. package/components/select/demo/api.html +77 -0
  278. package/components/select/demo/api.js +35 -0
  279. package/components/select/demo/api.md +1413 -0
  280. package/components/select/demo/api.min.js +10502 -0
  281. package/components/select/demo/index.html +73 -0
  282. package/components/select/demo/index.js +9 -0
  283. package/components/select/demo/index.md +1151 -0
  284. package/components/select/demo/index.min.js +10390 -0
  285. package/components/select/demo/readme.html +57 -0
  286. package/components/select/demo/readme.md +145 -0
  287. package/components/select/dist/auro-select.d.ts +512 -0
  288. package/components/select/dist/bibtemplateVersion.d.ts +2 -0
  289. package/components/select/dist/dropdownVersion.d.ts +2 -0
  290. package/components/select/dist/helptextVersion.d.ts +2 -0
  291. package/components/select/dist/index.d.ts +2 -0
  292. package/components/select/dist/index.js +8898 -0
  293. package/components/select/dist/registered.js +8898 -0
  294. package/components/select/dist/styles/shapeSize-css.d.ts +2 -0
  295. package/components/select/dist/styles/style-css.d.ts +2 -0
  296. package/components/select/dist/styles/tokens-css.d.ts +2 -0
  297. package/package.json +218 -0
@@ -0,0 +1,1651 @@
1
+ import { css, LitElement, html } from 'lit';
2
+ import { classMap } from 'lit/directives/class-map.js';
3
+ import { unsafeStatic, literal, html as html$1 } from 'lit/static-html.js';
4
+ import { ifDefined } from 'lit/directives/if-defined.js';
5
+
6
+ var styleCss$2 = css`:focus:not(:focus-visible){outline:3px solid transparent}.body-default{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem))}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem))}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem))}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-md-letter-spacing, 0);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem))}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem))}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem))}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem))}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem))}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem))}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem))}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);font-weight:var(--wcss-heading-xs-weight, 450);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem))}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);font-weight:var(--wcss-heading-2xs-weight, 450);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem))}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));text-transform:uppercase}:host{display:block;vertical-align:middle;line-height:0}:host .menuWrapper{box-sizing:border-box;display:flex;flex-direction:column;width:100%;margin:0;padding:0}:host ::slotted(hr){box-sizing:content-box !important;height:0 !important;overflow:visible !important;margin:var(--ds-size-100, 0.5rem) 0 !important;border-width:0 !important;border-top-width:1px !important;border-top-style:solid !important}:host [loadingplaceholder].empty{opacity:0;position:absolute}:host [loadingplaceholder] slot[name=loadingIcon]{vertical-align:middle;display:inline-block}:host [loadingplaceholder] slot[name=loadingIcon]::slotted(*){margin-right:var(--ds-size-150, 0.75rem)}:host([root]){overflow-y:auto}:host([root]) .menuWrapper.lg{padding:var(--ds-size-150, 0.75rem);gap:var(--ds-size-50, 0.25rem)}:host([root]) .menuWrapper.xl{padding:var(--ds-size-200, 1rem);gap:var(--ds-size-100, 0.5rem)}`;
7
+
8
+ var colorCss$2 = css`:host ::slotted(hr){border-top-color:var(--ds-auro-menu-divider-color)}[loadingplaceholder] slot[name=loadingIcon]{color:var(--ds-auro-menu-loader-color)}[loadingplaceholder] slot[name=loadingText]{color:var(--ds-auro-menu-loader-text-color)}`;
9
+
10
+ var tokensCss$1 = css`:host{--ds-auro-menu-divider-color: var(--ds-basic-color-border-divider, rgba(0, 0, 0, 0.15));--ds-auro-menu-loader-color: var(--ds-basic-color-brand-primary, #01426a);--ds-auro-menu-loader-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-menuoption-container-color: transparent;--ds-auro-menuoption-container-border-color: var(--ds-auro-menuoption-container-color);--ds-auro-menuoption-icon-color: transparent;--ds-auro-menuoption-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}`;
11
+
12
+ let AuroElement$1 = class AuroElement extends LitElement {
13
+ static get properties() {
14
+ return {
15
+
16
+ /**
17
+ * Defines the language of an element.
18
+ * @default {'default'}
19
+ */
20
+ layout: {
21
+ type: String,
22
+ attribute: "layout",
23
+ reflect: true
24
+ },
25
+
26
+ shape: {
27
+ type: String,
28
+ attribute: "shape",
29
+ reflect: true
30
+ },
31
+
32
+ size: {
33
+ type: String,
34
+ attribute: "size",
35
+ reflect: true
36
+ },
37
+
38
+ onDark: {
39
+ type: Boolean,
40
+ attribute: "ondark",
41
+ reflect: true
42
+ }
43
+ };
44
+ }
45
+
46
+ resetShapeClasses() {
47
+ const wrapper = this.shadowRoot.querySelector('.wrapper');
48
+
49
+ if (wrapper) {
50
+ wrapper.classList.forEach((className) => {
51
+ if (className.startsWith('shape-')) {
52
+ wrapper.classList.remove(className);
53
+ }
54
+ });
55
+
56
+ if (this.shape && this.size) {
57
+ wrapper.classList.add(`shape-${this.shape.toLowerCase()}-${this.size.toLowerCase()}`);
58
+ } else {
59
+ wrapper.classList.add('shape-none');
60
+ }
61
+ }
62
+
63
+ }
64
+
65
+ resetLayoutClasses() {
66
+ if (this.layout) {
67
+ const wrapper = this.shadowRoot.querySelector('.wrapper');
68
+
69
+ if (wrapper) {
70
+ wrapper.classList.forEach((className) => {
71
+ if (className.startsWith('layout-')) {
72
+ wrapper.classList.remove(className);
73
+ }
74
+ });
75
+
76
+ wrapper.classList.add(`layout-${this.layout.toLowerCase()}`);
77
+ }
78
+ }
79
+ }
80
+
81
+ updateComponentArchitecture() {
82
+ this.resetLayoutClasses();
83
+ this.resetShapeClasses();
84
+ }
85
+
86
+ updated(changedProperties) {
87
+ if (changedProperties.has('layout') || changedProperties.has('shape') || changedProperties.has('size')) {
88
+ this.updateComponentArchitecture();
89
+ }
90
+ }
91
+
92
+ // Try to render the defined `this.layout` layout. If that fails, fall back to the default layout.
93
+ // This will catch if an invalid layout value is passed in and render the default layout if so.
94
+ render() {
95
+ try {
96
+ return this.renderLayout();
97
+ } catch (error) {
98
+ // failed to get the defined layout
99
+ console.error('Failed to get the defined layout - using the default layout', error); // eslint-disable-line no-console
100
+
101
+ // fallback to the default layout
102
+ return this.getLayout('default');
103
+ }
104
+ }
105
+ };
106
+
107
+ // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
108
+ // See LICENSE in the project root for license information.
109
+
110
+ // ---------------------------------------------------------------------
111
+
112
+ /* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
113
+
114
+ let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
115
+
116
+ /* eslint-disable jsdoc/require-param */
117
+
118
+ /**
119
+ * This will register a new custom element with the browser.
120
+ * @param {String} name - The name of the custom element.
121
+ * @param {Object} componentClass - The class to register as a custom element.
122
+ * @returns {void}
123
+ */
124
+ registerComponent(name, componentClass) {
125
+ if (!customElements.get(name)) {
126
+ customElements.define(name, class extends componentClass {});
127
+ }
128
+ }
129
+
130
+ /**
131
+ * Finds and returns the closest HTML Element based on a selector.
132
+ * @returns {void}
133
+ */
134
+ closestElement(
135
+ selector, // selector like in .closest()
136
+ base = this, // extra functionality to skip a parent
137
+ __Closest = (el, found = el && el.closest(selector)) =>
138
+ !el || el === document || el === window
139
+ ? null // standard .closest() returns null for non-found selectors also
140
+ : found
141
+ ? found // found a selector INside this element
142
+ : __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
143
+ ) {
144
+ return __Closest(base);
145
+ }
146
+ /* eslint-enable jsdoc/require-param */
147
+
148
+ /**
149
+ * If the element passed is registered with a different tag name than what is passed in, the tag name is added as an attribute to the element.
150
+ * @param {Object} elem - The element to check.
151
+ * @param {String} tagName - The name of the Auro component to check for or add as an attribute.
152
+ * @returns {void}
153
+ */
154
+ handleComponentTagRename(elem, tagName) {
155
+ const tag = tagName.toLowerCase();
156
+ const elemTag = elem.tagName.toLowerCase();
157
+
158
+ if (elemTag !== tag) {
159
+ elem.setAttribute(tag, true);
160
+ }
161
+ }
162
+
163
+ /**
164
+ * Validates if an element is a specific Auro component.
165
+ * @param {Object} elem - The element to validate.
166
+ * @param {String} tagName - The name of the Auro component to check against.
167
+ * @returns {Boolean} - Returns true if the element is the specified Auro component.
168
+ */
169
+ elementMatch(elem, tagName) {
170
+ const tag = tagName.toLowerCase();
171
+ const elemTag = elem.tagName.toLowerCase();
172
+
173
+ return elemTag === tag || elem.hasAttribute(tag);
174
+ }
175
+ };
176
+
177
+ // Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
178
+ // See LICENSE in the project root for license information.
179
+
180
+
181
+ /**
182
+ * Validates if an option can be interacted with.
183
+ * @private
184
+ * @param {HTMLElement} option - The option to check.
185
+ * @returns {boolean} True if option is interactive.
186
+ */
187
+ function isOptionInteractive(option) {
188
+ return !option.hasAttribute('hidden') &&
189
+ !option.hasAttribute('disabled') &&
190
+ !option.hasAttribute('static');
191
+ }
192
+
193
+ /**
194
+ * Helper method to dispatch custom events.
195
+ * @param {HTMLElement} element - Element to dispatch event from.
196
+ * @param {string} eventName - Name of the event to dispatch.
197
+ * @param {Object} [detail] - Optional detail object to include with the event.
198
+ */
199
+ function dispatchMenuEvent(element, eventName, detail = null) {
200
+ const eventConfig = {
201
+ bubbles: true,
202
+ cancelable: false,
203
+ composed: true
204
+ };
205
+
206
+ if (detail !== null) {
207
+ eventConfig.detail = detail;
208
+ }
209
+
210
+ element.dispatchEvent(new CustomEvent(eventName, eventConfig));
211
+ }
212
+
213
+ // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
214
+ // See LICENSE in the project root for license information.
215
+
216
+
217
+
218
+ // See https://git.io/JJ6SJ for "How to document your components using JSDoc"
219
+ /**
220
+ * The auro-menu element provides users a way to select from a list of options.
221
+ * @attr {HTMLElement|Array<HTMLElement>} optionSelected - An array of currently selected menu options, type `HTMLElement` by default. In multi-select mode, `optionSelected` is an array of HTML elements.
222
+ * @attr {object} optionactive - Specifies the current active menuOption.
223
+ * @attr {string} matchword - Specifies a string used to highlight matched string parts in options.
224
+ * @attr {boolean} disabled - When true, the entire menu and all options are disabled;
225
+ * @attr {boolean} nocheckmark - When true, selected option will not show the checkmark.
226
+ * @attr {boolean} loading - When true, displays a loading state using the loadingIcon and loadingText slots if provided.
227
+ * @attr {boolean} multiselect - When true, the selected option can be multiple options.
228
+ * @prop {boolean} hasLoadingPlaceholder - Indicates whether the menu has a loadingIcon or loadingText to render when in a loading state.
229
+ * @event {CustomEvent<Element>} auroMenu-activatedOption - Notifies that a menuoption has been made `active`.
230
+ * @event {CustomEvent<any>} auroMenu-customEventFired - Notifies that a custom event has been fired.
231
+ * @event {CustomEvent<{ loading: boolean; hasLoadingPlaceholder: boolean; }>} auroMenu-loadingChange - Notifies when the loading attribute is changed.
232
+ * @event {CustomEvent<any>} auroMenu-selectValueFailure - Notifies that an attempt to select a menuoption by matching a value has failed.
233
+ * @event {CustomEvent<any>} auroMenu-selectValueReset - Notifies that the component value has been reset.
234
+ * @event {CustomEvent<any>} auroMenu-selectedOption - Notifies that a new menuoption selection has been made.
235
+ * @slot loadingText - Text to show while loading attribute is set
236
+ * @slot loadingIcon - Icon to show while loading attribute is set
237
+ * @slot - Slot for insertion of menu options.
238
+ */
239
+
240
+ /* eslint-disable no-magic-numbers, max-lines, no-extra-parens */
241
+
242
+ class AuroMenu extends AuroElement$1 {
243
+ constructor() {
244
+ super();
245
+
246
+ // State properties (reactive)
247
+
248
+ /**
249
+ * @private
250
+ */
251
+ this.shape = "box";
252
+
253
+ /**
254
+ * @private
255
+ */
256
+ this.size = "sm";
257
+
258
+ // Value of the selected options
259
+ this.value = undefined;
260
+ // Currently selected option
261
+ this.optionSelected = undefined;
262
+ // String used for highlighting/filtering
263
+ this.matchWord = undefined;
264
+ // Hide the checkmark icon on selected options
265
+ this.noCheckmark = false;
266
+ // Currently active option
267
+ this.optionActive = undefined;
268
+ // Loading state
269
+ this.loading = false;
270
+ // Multi-select mode
271
+ this.multiSelect = false;
272
+
273
+ // Event Bindings
274
+
275
+ /**
276
+ * @private
277
+ */
278
+ this.handleKeyDown = this.handleKeyDown.bind(this);
279
+
280
+ /**
281
+ * @private
282
+ */
283
+ this.handleMouseSelect = this.handleMouseSelect.bind(this);
284
+
285
+ /**
286
+ * @private
287
+ */
288
+ this.handleOptionHover = this.handleOptionHover.bind(this);
289
+
290
+ /**
291
+ * @private
292
+ */
293
+ this.handleSlotChange = this.handleSlotChange.bind(this);
294
+
295
+ // Instance properties (non-reactive)
296
+
297
+ /**
298
+ * @private
299
+ */
300
+ Object.assign(this, {
301
+ // Root-level menu (true) or a nested submenu (false)
302
+ rootMenu: true,
303
+ // Currently focused/active menu item index
304
+ index: -1,
305
+ // Nested menu spacer
306
+ nestingSpacer: '<span class="nestingSpacer"></span>',
307
+ // Loading indicator for slot elements
308
+ loadingSlots: null,
309
+ // Store for menu items
310
+ items: [],
311
+ });
312
+ }
313
+
314
+ static get properties() {
315
+ return {
316
+ ...super.properties,
317
+ noCheckmark: {
318
+ type: Boolean,
319
+ reflect: true,
320
+ attribute: 'nocheckmark'
321
+ },
322
+ disabled: {
323
+ type: Boolean,
324
+ reflect: true
325
+ },
326
+ loading: {
327
+ type: Boolean,
328
+ reflect: true
329
+ },
330
+ optionSelected: {
331
+ // Allow HTMLElement, HTMLElement[] arrays and undefined
332
+ type: Object
333
+ },
334
+ optionActive: {
335
+ type: Object,
336
+ attribute: 'optionactive'
337
+ },
338
+ matchWord: {
339
+ type: String,
340
+ attribute: 'matchword'
341
+ },
342
+ multiSelect: {
343
+ type: Boolean,
344
+ reflect: true,
345
+ attribute: 'multiselect'
346
+ },
347
+
348
+ /**
349
+ * Value selected for the component.
350
+ */
351
+ value: {
352
+ type: String,
353
+ reflect: true,
354
+ attribute: 'value'
355
+ },
356
+
357
+ /**
358
+ * Indent level for submenus.
359
+ * @private
360
+ */
361
+ level: {
362
+ type: Number,
363
+ reflect: false,
364
+ attribute: false
365
+ }
366
+ };
367
+ }
368
+
369
+ static get styles() {
370
+ return [
371
+ styleCss$2,
372
+ colorCss$2,
373
+ tokensCss$1
374
+ ];
375
+ }
376
+
377
+ /**
378
+ * This will register this element with the browser.
379
+ * @param {string} [name="auro-menu"] - The name of element that you want to register to.
380
+ *
381
+ * @example
382
+ * AuroMenu.register("custom-menu") // this will register this element to <custom-menu/>
383
+ *
384
+ */
385
+ static register(name = "auro-menu") {
386
+ AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroMenu);
387
+ }
388
+
389
+ /**
390
+ * Formatted value based on `multiSelect` state.
391
+ * Default type is `String`, changing to `Array<String>` when `multiSelect` is true.
392
+ * @private
393
+ * @returns {String|Array<String>}
394
+ */
395
+ get formattedValue() {
396
+ if (this.multiSelect) {
397
+ if (!this.value) {
398
+ return undefined;
399
+ }
400
+ if (this.value.startsWith("[")) {
401
+ return JSON.parse(this.value);
402
+ }
403
+ return [this.value];
404
+ }
405
+ return this.value;
406
+ }
407
+
408
+ // Lifecycle Methods
409
+
410
+ connectedCallback() {
411
+ super.connectedCallback();
412
+
413
+ this.addEventListener('keydown', this.handleKeyDown);
414
+ this.addEventListener('mousedown', this.handleMouseSelect);
415
+ this.addEventListener('auroMenuOption-mouseover', this.handleOptionHover);
416
+ this.addEventListener('slotchange', this.handleSlotChange);
417
+ this.setTagAttribute("auro-menu");
418
+ }
419
+
420
+ disconnectedCallback() {
421
+ this.removeEventListener('keydown', this.handleKeyDown);
422
+ this.removeEventListener('mousedown', this.handleMouseSelect);
423
+ this.removeEventListener('auroMenuOption-mouseover', this.handleOptionHover);
424
+ this.removeEventListener('slotchange', this.handleSlotChange);
425
+
426
+ super.disconnectedCallback();
427
+ }
428
+
429
+ firstUpdated() {
430
+ AuroLibraryRuntimeUtils$1.prototype.handleComponentTagRename(this, 'auro-menu');
431
+
432
+ this.loadingSlots = this.querySelectorAll("[slot='loadingText'], [slot='loadingIcon']");
433
+ this.initializeMenu();
434
+ }
435
+
436
+ /**
437
+ * Sets an attribute that matches the default tag name if the tag name is not the default.
438
+ * @param {string} tagName - The tag name to set as an attribute.
439
+ * @private
440
+ */
441
+ setTagAttribute(tagName) {
442
+ if (this.tagName.toLowerCase() !== tagName) {
443
+ this.setAttribute(tagName, true);
444
+ }
445
+ }
446
+
447
+ updated(changedProperties) {
448
+ super.updated(changedProperties);
449
+
450
+ if (changedProperties.has('multiSelect') && !changedProperties.has("value")) {
451
+ // Reset selection if multiSelect mode changes
452
+ this.clearSelection();
453
+ }
454
+
455
+
456
+ if (changedProperties.has("value")) {
457
+ // Handle null/undefined case
458
+ if (this.value === undefined || this.value === null) {
459
+ this.optionSelected = undefined;
460
+ this.index = -1;
461
+ } else {
462
+ if (this.multiSelect) {
463
+ // In multiselect mode, this.value should be an array of strings
464
+ const valueArray = this.formattedValue;
465
+ const matchingOptions = this.items.filter((item) => valueArray.includes(item.value));
466
+
467
+ this.optionSelected = matchingOptions.length > 0 ? matchingOptions : undefined;
468
+ } else {
469
+ // In single-select mode, this.value should be a string
470
+ const matchingOptions = this.items.find((item) => item.value === this.value);
471
+
472
+ if (matchingOptions) {
473
+ this.optionSelected = matchingOptions;
474
+ this.index = this.items.indexOf(matchingOptions);
475
+ } else {
476
+ // If no matching option found, reset selection
477
+ this.optionSelected = undefined;
478
+ this.index = -1;
479
+ }
480
+ }
481
+
482
+ // If no matching options were found in either mode
483
+ if (!this.optionSelected || (Array.isArray(this.optionSelected) && this.optionSelected.length === 0)) {
484
+ dispatchMenuEvent(this, 'auroMenu-selectValueFailure');
485
+ this.optionSelected = undefined;
486
+ this.index = -1;
487
+ }
488
+ }
489
+
490
+ // Update UI state
491
+ this.updateItemsState(new Map([
492
+ [
493
+ 'optionSelected',
494
+ true
495
+ ]
496
+ ]));
497
+
498
+ // Notify of changes
499
+ if (this.optionSelected !== undefined) {
500
+ this.notifySelectionChange();
501
+ }
502
+ }
503
+
504
+ // Process all other UI updates
505
+ this.updateItemsState(changedProperties);
506
+ }
507
+
508
+ /**
509
+ * Updates the UI state and appearance of menu items based on changed properties.
510
+ * @private
511
+ * @param {Map<string, boolean>} changedProperties - LitElement's changed properties map.
512
+ */
513
+ updateItemsState(changedProperties) {
514
+ if (!this.items) {
515
+ return;
516
+ }
517
+
518
+ // Handle noCheckmark propagation to all menus and options
519
+ if (changedProperties.has('noCheckmark') && this.noCheckmark) {
520
+ // Update both menus and options
521
+ this.querySelectorAll('auro-menu, [auro-menu], auro-menuoption, [auro-menuoption]').forEach((element) => element.setAttribute('noCheckmark', ''));
522
+ }
523
+
524
+ // Handle layout propagation to all menus and options
525
+ const propagationTargets = this.querySelectorAll('auro-menu, [auro-menu], auro-menuoption, [auro-menuoption]');
526
+ [
527
+ 'size',
528
+ 'shape'
529
+ ].forEach((prop) => {
530
+ if (changedProperties.has(prop)) {
531
+ propagationTargets.forEach((el) => {
532
+ el.setAttribute(prop, this[prop]);
533
+ });
534
+ }
535
+ });
536
+
537
+ // Regex for matchWord if needed
538
+ let regexWord = null;
539
+
540
+ if (changedProperties.has('matchWord') && this.matchWord && this.matchWord.length) {
541
+ const escapedWord = this.matchWord.replace(/[.*+?^${}()|[\]\\]/gu, '\\$&');
542
+ regexWord = new RegExp(escapedWord, 'giu');
543
+ }
544
+
545
+ // Handle direct item updates
546
+ this.items.forEach((option) => {
547
+ // Update selection if option or value changed
548
+ if (changedProperties.has('optionSelected') || changedProperties.has('value')) {
549
+ const isSelected = this.isOptionSelected(option);
550
+ option.setAttribute('aria-selected', isSelected ? 'true' : 'false');
551
+
552
+ // Add/remove selected attribute based on state
553
+ if (isSelected) {
554
+ option.setAttribute('selected', '');
555
+ } else {
556
+ option.removeAttribute('selected');
557
+ }
558
+ }
559
+
560
+ // Update text highlighting if matchWord changed
561
+ if (changedProperties.has('matchWord') && regexWord &&
562
+ isOptionInteractive(option) && !option.hasAttribute('persistent')) {
563
+ const nested = option.querySelectorAll('.nestingSpacer');
564
+ // Create nested spacers
565
+ const nestingSpacerBundle = [...nested].map(() => this.nestingSpacer).join('');
566
+
567
+ // Update with spacers and matchWord
568
+ option.innerHTML = nestingSpacerBundle +
569
+ option.textContent.replace(
570
+ regexWord,
571
+ (match) => `<strong>${match}</strong>`
572
+ );
573
+ }
574
+
575
+ // Update disabled state
576
+ if (changedProperties.has('disabled')) {
577
+ option.disabled = this.disabled;
578
+ }
579
+ });
580
+
581
+ // Handle loading state changes
582
+ if (changedProperties.has('loading')) {
583
+ this.setAttribute("aria-busy", this.loading);
584
+ dispatchMenuEvent(this, "auroMenu-loadingChange", {
585
+ loading: this.loading,
586
+ hasLoadingPlaceholder: this.hasLoadingPlaceholder
587
+ });
588
+ }
589
+ }
590
+
591
+ // Init Methods
592
+
593
+ /**
594
+ * Initializes the menu's state and structure.
595
+ * @private
596
+ */
597
+ initializeMenu() {
598
+ this.initItems();
599
+ if (this.rootMenu) {
600
+ this.setAttribute('role', 'listbox');
601
+ this.setAttribute('root', '');
602
+ this.handleNestedMenus(this);
603
+ }
604
+ }
605
+
606
+ /**
607
+ * Initializes menu items and their attributes.
608
+ * @private
609
+ */
610
+ initItems() {
611
+ this.items = Array.from(this.querySelectorAll('auro-menuoption, [auro-menuoption]'));
612
+ if (this.noCheckmark) {
613
+ this.updateItemsState(new Map([
614
+ [
615
+ 'noCheckmark',
616
+ true
617
+ ]
618
+ ]));
619
+ }
620
+ }
621
+
622
+ // Logic Methods
623
+
624
+ /**
625
+ * Updates menu state when an option is selected.
626
+ * @private
627
+ * @param {HTMLElement} option - The option element to select.
628
+ */
629
+ handleSelectState(option) {
630
+ if (this.multiSelect) {
631
+ const currentValue = this.formattedValue || [];
632
+ const currentSelected = this.optionSelected || [];
633
+
634
+ if (!currentValue.includes(option.value)) {
635
+ this.value = JSON.stringify([
636
+ ...currentValue,
637
+ option.value
638
+ ]);
639
+ }
640
+ if (!currentSelected.includes(option)) {
641
+ this.optionSelected = [
642
+ ...currentSelected,
643
+ option
644
+ ];
645
+ }
646
+ } else {
647
+ // Single select - use arrays with single values
648
+ this.value = option.value;
649
+ this.optionSelected = option;
650
+ }
651
+
652
+ this.index = this.items.indexOf(option);
653
+ }
654
+
655
+ /**
656
+ * Deselects a menu option and updates related state.
657
+ * @private
658
+ * @param {HTMLElement} option - The menuoption to be deselected.
659
+ */
660
+ handleDeselectState(option) {
661
+ if (this.multiSelect) {
662
+ // Remove this option from array
663
+ const newFormattedValue = (this.formattedValue || []).filter((val) => val !== option.value);
664
+
665
+ // If array is empty after removal, set back to undefined
666
+ if (newFormattedValue && newFormattedValue.length === 0) {
667
+ this.value = undefined;
668
+ } else {
669
+ this.value = JSON.stringify(newFormattedValue);
670
+ }
671
+
672
+ this.optionSelected = this.optionSelected.filter((val) => val !== option);
673
+ if (this.optionSelected.length === 0) {
674
+ this.optionSelected = undefined;
675
+ }
676
+ } else {
677
+ // For single-select: Back to undefined when deselected
678
+ this.value = undefined;
679
+ this.optionSelected = undefined;
680
+ }
681
+
682
+ // Update the index tracking
683
+ this.index = this.items.indexOf(option);
684
+
685
+ // Update UI to reflect changes
686
+ this.updateItemsState(new Map([
687
+ [
688
+ 'optionSelected',
689
+ true
690
+ ]
691
+ ]));
692
+
693
+ // Notify of selection change
694
+ this.notifySelectionChange();
695
+ }
696
+
697
+ /**
698
+ * Resets all options to their default state.
699
+ * @private
700
+ */
701
+ clearSelection() {
702
+ this.optionSelected = undefined;
703
+ this.value = undefined;
704
+ }
705
+
706
+ /**
707
+ * Resets the menu to its initial state.
708
+ * This is the only way to return value to undefined.
709
+ * @public
710
+ */
711
+ reset() {
712
+ // Reset to undefined - initial state
713
+ this.value = undefined;
714
+ this.optionSelected = undefined;
715
+ this.index = -1;
716
+
717
+ // Reset UI state
718
+ this.updateItemsState(new Map([
719
+ [
720
+ 'optionSelected',
721
+ true
722
+ ]
723
+ ]));
724
+
725
+ // Dispatch reset event
726
+ dispatchMenuEvent(this, 'auroMenu-selectValueReset');
727
+ }
728
+
729
+ /**
730
+ * Handles nested menu structure.
731
+ * @private
732
+ * @param {HTMLElement} menu - Root menu element.
733
+ */
734
+ handleNestedMenus(menu) {
735
+ menu.level = menu.parentElement.level >= 0 ? menu.parentElement.level + 1 : 0;
736
+
737
+ if (menu.level > 0) {
738
+ menu.setAttribute('role', 'group');
739
+ menu.removeAttribute("root");
740
+ if (!menu.hasAttribute('aria-label')) {
741
+ menu.setAttribute('aria-label', 'submenu');
742
+ }
743
+ }
744
+
745
+ const options = menu.querySelectorAll(':scope > auro-menuoption, :scope > [auro-menuoption]');
746
+ options.forEach((option) => {
747
+ const regex = new RegExp(this.nestingSpacer, "gu");
748
+ option.innerHTML = this.nestingSpacer.repeat(menu.level) + option.innerHTML.replace(regex, '');
749
+ });
750
+ }
751
+
752
+ // Event Handlers
753
+
754
+ /**
755
+ * Handles keyboard navigation.
756
+ * @private
757
+ * @param {KeyboardEvent} event - Event object from the browser.
758
+ */
759
+ handleKeyDown(event) {
760
+ event.preventDefault();
761
+ switch (event.key) {
762
+ case "ArrowDown":
763
+ this.navigateOptions('down');
764
+ break;
765
+ case "ArrowUp":
766
+ this.navigateOptions('up');
767
+ break;
768
+ case "Enter":
769
+ this.makeSelection();
770
+ break;
771
+ }
772
+ }
773
+
774
+ /**
775
+ * Makes a selection based on the current index or clicked option.
776
+ * @private
777
+ */
778
+ makeSelection() {
779
+ if (!this.items) {
780
+ this.initItems();
781
+ }
782
+
783
+ // Get currently selected menu option based on index
784
+ const option = this.items[this.index];
785
+
786
+ // Return early if option is not interactive
787
+ if (!option || !isOptionInteractive(option)) {
788
+ return;
789
+ }
790
+
791
+ // Handle custom events first
792
+ if (option.hasAttribute('event')) {
793
+ this.handleCustomEvent(option);
794
+ return;
795
+ }
796
+
797
+ if (this.multiSelect) {
798
+ // In multiselect, toggle individual selections
799
+ this.toggleOption(option);
800
+ // In single select, only handle selection of new options
801
+ } else if (!this.isOptionSelected(option)) {
802
+ this.clearSelection();
803
+ this.handleSelectState(option);
804
+ }
805
+
806
+ this.notifySelectionChange();
807
+ }
808
+
809
+ /**
810
+ * Toggle the selection state of the menuoption.
811
+ * @private
812
+ * @param {HTMLElement} option - The menuoption to toggle.
813
+ */
814
+ toggleOption(option) {
815
+ const isCurrentlySelected = this.isOptionSelected(option);
816
+
817
+ if (isCurrentlySelected) {
818
+ this.handleDeselectState(option);
819
+ } else if (option.value === undefined || option.value === '') {
820
+ dispatchMenuEvent(this, 'auroMenu-selectValueFailure');
821
+ } else {
822
+ this.handleSelectState(option);
823
+ }
824
+ }
825
+
826
+ /**
827
+ * Handles option selection via mouse.
828
+ * @private
829
+ * @param {MouseEvent} event - Event object from the browser.
830
+ */
831
+ handleMouseSelect(event) {
832
+ if (event.target === this) {
833
+ return;
834
+ }
835
+
836
+ const option = event.target.closest('auro-menuoption, [auro-menuoption]');
837
+ if (option) {
838
+ this.index = this.items.indexOf(option);
839
+ this.makeSelection();
840
+ }
841
+ }
842
+
843
+ /**
844
+ * Handles option hover events.
845
+ * @private
846
+ * @param {CustomEvent} event - Event object from the browser.
847
+ */
848
+ handleOptionHover(event) {
849
+ const option = event.target;
850
+ this.index = this.items.indexOf(option);
851
+ this.updateActiveOption(this.index);
852
+ }
853
+
854
+ /**
855
+ * Handles slot change events.
856
+ * @private
857
+ */
858
+ handleSlotChange() {
859
+ if (this.parentElement && this.parentElement.closest('auro-menu, [auro-menu]')) {
860
+ this.rootMenu = false;
861
+ }
862
+
863
+ if (this.rootMenu) {
864
+ this.initializeMenu();
865
+ } else if (this.noCheckmark) {
866
+ this.updateItemsState(new Map([
867
+ [
868
+ 'noCheckmark',
869
+ true
870
+ ]
871
+ ]));
872
+ }
873
+ }
874
+
875
+ /**
876
+ * Navigates through options using keyboard.
877
+ * @private
878
+ * @param {string} direction - 'up' or 'down'.
879
+ */
880
+ navigateOptions(direction) {
881
+ // Return early if no items exist
882
+ if (!this.items || !this.items.length) {
883
+ return;
884
+ }
885
+
886
+ let newIndex = this.index;
887
+ const increment = direction === 'down' ? 1 : -1;
888
+ const maxIterations = this.items.length;
889
+ let iterations = 0;
890
+ let foundInteractiveOption = false;
891
+
892
+ do {
893
+ newIndex = (newIndex + increment + this.items.length) % this.items.length;
894
+ iterations += 1;
895
+
896
+ // Check if current option is interactive
897
+ const currentOption = this.items[newIndex];
898
+ if (isOptionInteractive(currentOption)) {
899
+ foundInteractiveOption = true;
900
+ break;
901
+ }
902
+
903
+ // Break if all options were checked
904
+ if (iterations >= maxIterations) {
905
+ break;
906
+ }
907
+ } while (iterations < maxIterations);
908
+
909
+ // Handle the results of the search
910
+ if (foundInteractiveOption) {
911
+ // Update only if an interactive option was found
912
+ this.index = newIndex;
913
+ this.updateActiveOption(this.index);
914
+ } else {
915
+ // All options are disabled or non-interactive
916
+ // Keep the current index unchanged
917
+ dispatchMenuEvent(this, 'auroMenu-navigateFailure', {
918
+ reason: 'No interactive options available',
919
+ direction,
920
+ currentIndex: this.index
921
+ });
922
+ }
923
+ }
924
+
925
+ /**
926
+ * Updates the active option state and dispatches events.
927
+ * @private
928
+ * @param {number} index - Index of the option to make active.
929
+ */
930
+ updateActiveOption(index) {
931
+ if (!this.items || !this.items[index]) {
932
+ return;
933
+ }
934
+
935
+ this.items.forEach((item) => item.classList.remove('active'));
936
+ this.items[index].classList.add('active');
937
+ this.optionActive = this.items[index];
938
+ this.index = index;
939
+
940
+ dispatchMenuEvent(this, 'auroMenu-activatedOption', this.items[index]);
941
+ }
942
+
943
+ /**
944
+ * Handles custom events defined on options.
945
+ * @private
946
+ * @param {HTMLElement} option - Option with custom event.
947
+ */
948
+ handleCustomEvent(option) {
949
+ const eventName = option.getAttribute('event');
950
+ dispatchMenuEvent(this, eventName);
951
+ dispatchMenuEvent(this, 'auroMenu-customEventFired');
952
+ }
953
+
954
+ /**
955
+ * Notifies selection change to parent components.
956
+ * @private
957
+ */
958
+ notifySelectionChange() {
959
+ dispatchMenuEvent(this, 'auroMenu-selectedOption');
960
+ }
961
+
962
+ /**
963
+ * Checks if an option is currently selected.
964
+ * @private
965
+ * @param {HTMLElement} option - The option to check.
966
+ * @returns {boolean}
967
+ */
968
+ isOptionSelected(option) {
969
+ if (!this.optionSelected) {
970
+ return false;
971
+ }
972
+
973
+ if (this.multiSelect) {
974
+ // In multi-select mode, check if the option is in the selected array
975
+ return Array.isArray(this.optionSelected) && this.optionSelected.some((selectedOption) => selectedOption === option);
976
+ }
977
+
978
+ return this.optionSelected === option;
979
+ }
980
+
981
+ /**
982
+ * Getter for loading placeholder state.
983
+ * @returns {boolean} - True if loading slots are present and non-empty.
984
+ */
985
+ get hasLoadingPlaceholder() {
986
+ return this.loadingSlots && this.loadingSlots.length > 0;
987
+ }
988
+
989
+ /**
990
+ * Getter for wrapper classes based on size.
991
+ * @returns {Object} - Class map for the wrapper element.
992
+ * @private
993
+ */
994
+ get wrapperClasses() {
995
+ return classMap({
996
+ 'menuWrapper': true,
997
+ [this.size]: true,
998
+ });
999
+ }
1000
+
1001
+ /**
1002
+ * Logic to determine the layout of the component.
1003
+ * @protected
1004
+ * @returns {void}
1005
+ */
1006
+ renderLayout() {
1007
+ if (this.loading) {
1008
+ return html`
1009
+ <div class="${this.wrapperClasses}">
1010
+ <auro-menuoption
1011
+ disabled
1012
+ loadingplaceholder
1013
+ class="${this.hasLoadingPlaceholder ? "" : "empty"}"
1014
+ >
1015
+ <div>
1016
+ <slot name="loadingIcon" class="body-lg"></slot>
1017
+ <slot name="loadingText"></slot>
1018
+ </div>
1019
+ </auro-menuoption>
1020
+ </div>
1021
+ `;
1022
+ }
1023
+
1024
+ return html`
1025
+ <div class="${this.wrapperClasses}">
1026
+ <slot @slotchange=${this.handleSlotChange}></slot>
1027
+ </div>
1028
+ `;
1029
+ }
1030
+ }
1031
+
1032
+ var styleCss$1 = css`.body-default{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-sm{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1rem)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);font-size:var(--wcss-body-2xs-font-size, 0.625rem);line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);font-weight:var(--wcss-display-2xl-weight, 300);line-height:var(--wcss-display-2xl-line-height, 1.3);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem))}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);font-weight:var(--wcss-display-xl-weight, 300);line-height:var(--wcss-display-xl-line-height, 1.3);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem))}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);font-weight:var(--wcss-display-lg-weight, 300);line-height:var(--wcss-display-lg-line-height, 1.3);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem))}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-md-letter-spacing, 0);font-weight:var(--wcss-display-md-weight, 300);line-height:var(--wcss-display-md-line-height, 1.3);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem))}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);font-weight:var(--wcss-display-sm-weight, 300);line-height:var(--wcss-display-sm-line-height, 1.3);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem))}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);font-weight:var(--wcss-display-xs-weight, 300);line-height:var(--wcss-display-xs-line-height, 1.3);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem))}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);font-weight:var(--wcss-heading-xl-weight, 300);line-height:var(--wcss-heading-xl-line-height, 1.3);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem))}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);font-weight:var(--wcss-heading-lg-weight, 300);line-height:var(--wcss-heading-lg-line-height, 1.3);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem))}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);font-weight:var(--wcss-heading-md-weight, 300);line-height:var(--wcss-heading-md-line-height, 1.3);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem))}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);font-weight:var(--wcss-heading-sm-weight, 300);line-height:var(--wcss-heading-sm-line-height, 1.3);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem))}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);font-weight:var(--wcss-heading-xs-weight, 450);line-height:var(--wcss-heading-xs-line-height, 1.3);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem))}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);font-weight:var(--wcss-heading-2xs-weight, 450);line-height:var(--wcss-heading-2xs-line-height, 1.3);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem))}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);font-weight:var(--wcss-accent-2xl-weight, 450);line-height:var(--wcss-accent-2xl-line-height, 1);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);font-weight:var(--wcss-accent-xl-weight, 450);line-height:var(--wcss-accent-xl-line-height, 1.3);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));text-transform:uppercase}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);font-weight:var(--wcss-accent-lg-weight, 450);line-height:var(--wcss-accent-lg-line-height, 1.3);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);font-weight:var(--wcss-accent-md-weight, 500);line-height:var(--wcss-accent-md-line-height, 1.3);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));text-transform:uppercase}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);font-weight:var(--wcss-accent-sm-weight, 500);line-height:var(--wcss-accent-sm-line-height, 1.3);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);font-weight:var(--wcss-accent-xs-weight, 500);line-height:var(--wcss-accent-xs-line-height, 1.3);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));text-transform:uppercase}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);font-weight:var(--wcss-accent-2xs-weight, 450);line-height:var(--wcss-accent-2xs-line-height, 1.3);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));text-transform:uppercase}:host{cursor:pointer;user-select:none}:host .wrapper{display:flex;align-items:center;padding-right:var(--ds-size-200, 1rem);padding-left:calc(var(--ds-size-150, 0.75rem) + var(--ds-size-300, 1.5rem) + var(--ds-size-100, 0.5rem));padding-top:var(--ds-size-50, 0.25rem);padding-bottom:var(--ds-size-50, 0.25rem);border-radius:var(--ds-size-100, 0.5rem);-webkit-tap-highlight-color:transparent}:host .wrapper[class*=shape-box]{border-radius:unset}:host .wrapper[class*=shape-snowflake]{border-radius:unset;line-height:24px}:host .wrapper[class*=shape-pill]{border-radius:30px}:host .wrapper[class*=-lg]{padding-top:var(--ds-size-75, 0.375rem);padding-bottom:var(--ds-size-75, 0.375rem);padding-right:var(--ds-size-150, 0.75rem);line-height:26px}:host .wrapper[class*=-xl]{padding-top:var(--ds-size-100, 0.5rem);padding-bottom:var(--ds-size-100, 0.5rem);padding-right:var(--ds-size-200, 1rem);line-height:26px}:host slot{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host [auro-icon]{--ds-auro-icon-size: var(--ds-size-300, 1.5rem);margin-right:var(--ds-size-150, 0.75rem);margin-left:var(--ds-size-100, 0.5rem)}:host ::slotted(.nestingSpacer){display:inline-block;width:var(--ds-size-300, 1.5rem)}:host([loadingplaceholder]) .wrapper{padding-left:calc(var(--ds-size-150, 0.75rem) + var(--ds-size-300, 1.5rem) + var(--ds-size-100, 0.5rem))}:host([selected]) .wrapper{padding-left:0}:host([nocheckmark]) .wrapper{padding-left:var(--ds-size-150, 0.75rem)}:host([nocheckmark]) .wrapper[class*=-lg]{padding-left:var(--ds-size-150, 0.75rem)}:host([nocheckmark]) .wrapper[class*=-xl]{padding-left:var(--ds-size-200, 1rem)}:host([hidden]){display:none}:host([static]){pointer-events:none}:host([disabled]:hover){cursor:auto}:host([disabled]){user-select:none;pointer-events:none}`;
1033
+
1034
+ var colorCss$1 = css`:host .wrapper{background-color:var(--ds-auro-menuoption-container-color, transparent);box-shadow:inset 0 0 0 1px var(--ds-auro-menuoption-container-border-color, transparent);color:var(--ds-auro-menuoption-text-color)}:host svg{fill:var(--ds-auro-menuoption-icon-color)}:host([disabled]){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-menuoption-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0);--ds-auro-menuoption-icon-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:hover),:host(.active){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-accent1-muted, #ebfafd)}:host(:focus){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-menuoption-container-border-color: var(--ds-basic-color-border-brand, #00274a)}:host([selected]){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-accent1-subtle, #b4eff9);--ds-auro-menuoption-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-menuoption-icon-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([selected]:hover),:host([selected].active){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-accent1-muted, #ebfafd)}:host([selected]:focus){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-accent1-subtle, #b4eff9);--ds-auro-menuoption-container-border-color: var(--ds-basic-color-border-brand, #00274a)}:host(:focus:hover),:host(:focus.active){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-accent1-muted, #ebfafd);--ds-auro-menuoption-container-border-color: var(--ds-basic-color-border-brand, #00274a)}:host([selected]:focus:hover),:host([selected]:focus.active){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-accent1-muted, #ebfafd);--ds-auro-menuoption-container-border-color: var(--ds-basic-color-border-brand, #00274a)}`;
1035
+
1036
+ // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
1037
+ // See LICENSE in the project root for license information.
1038
+
1039
+
1040
+ class AuroDependencyVersioning {
1041
+
1042
+ /**
1043
+ * Generates a unique string to be used for child auro element naming.
1044
+ * @private
1045
+ * @param {string} baseName - Defines the first part of the unique element name.
1046
+ * @param {string} version - Version of the component that will be appended to the baseName.
1047
+ * @returns {string} - Unique string to be used for naming.
1048
+ */
1049
+ generateElementName(baseName, version) {
1050
+ let result = baseName;
1051
+
1052
+ result += '-';
1053
+ result += version.replace(/[.]/g, '_');
1054
+
1055
+ return result;
1056
+ }
1057
+
1058
+ /**
1059
+ * Generates a unique string to be used for child auro element naming.
1060
+ * @param {string} baseName - Defines the first part of the unique element name.
1061
+ * @param {string} version - Version of the component that will be appended to the baseName.
1062
+ * @returns {string} - Unique string to be used for naming.
1063
+ */
1064
+ generateTag(baseName, version, tagClass) {
1065
+ const elementName = this.generateElementName(baseName, version);
1066
+ const tag = literal`${unsafeStatic(elementName)}`;
1067
+
1068
+ if (!customElements.get(elementName)) {
1069
+ customElements.define(elementName, class extends tagClass {});
1070
+ }
1071
+
1072
+ return tag;
1073
+ }
1074
+ }
1075
+
1076
+ // Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
1077
+ // See LICENSE in the project root for license information.
1078
+
1079
+
1080
+ /**
1081
+ * @attr {Boolean} hidden - If present, the component will be hidden both visually and from screen readers
1082
+ * @attr {Boolean} hiddenVisually - If present, the component will be hidden visually, but still read by screen readers
1083
+ * @attr {Boolean} hiddenAudible - If present, the component will be hidden from screen readers, but seen visually
1084
+ */
1085
+
1086
+ class AuroElement extends LitElement {
1087
+
1088
+ // function to define props used within the scope of this component
1089
+ static get properties() {
1090
+ return {
1091
+ hidden: { type: Boolean,
1092
+ reflect: true },
1093
+ hiddenVisually: { type: Boolean,
1094
+ reflect: true },
1095
+ hiddenAudible: { type: Boolean,
1096
+ reflect: true },
1097
+ };
1098
+ }
1099
+
1100
+ /**
1101
+ * @private Function that determines state of aria-hidden
1102
+ */
1103
+ hideAudible(value) {
1104
+ if (value) {
1105
+ return 'true'
1106
+ }
1107
+
1108
+ return 'false'
1109
+ }
1110
+ }
1111
+
1112
+ var error = {"svg":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" aria-labelledby=\"error__desc\" class=\"ico_squareLarge\" data-deprecated=\"true\" role=\"img\" style=\"min-width:var(--auro-size-lg, var(--ds-size-300, 1.5rem));height:var(--auro-size-lg, var(--ds-size-300, 1.5rem));fill:currentColor\" viewBox=\"0 0 24 24\" part=\"svg\"><title/><desc id=\"error__desc\">Error alert indicator.</desc><path d=\"m13.047 5.599 6.786 11.586A1.207 1.207 0 0 1 18.786 19H5.214a1.207 1.207 0 0 1-1.047-1.815l6.786-11.586a1.214 1.214 0 0 1 2.094 0m-1.165.87a.23.23 0 0 0-.085.085L5.419 17.442a.232.232 0 0 0 .203.35h12.756a.234.234 0 0 0 .203-.35L12.203 6.554a.236.236 0 0 0-.321-.084M12 15.5a.75.75 0 1 1 0 1.5.75.75 0 0 1 0-1.5m-.024-6.22c.325 0 .589.261.589.583v4.434a.586.586 0 0 1-.589.583.586.586 0 0 1-.588-.583V9.863c0-.322.264-.583.588-.583\"/></svg>"};
1113
+
1114
+ /* eslint-disable no-underscore-dangle, jsdoc/no-undefined-types, jsdoc/require-param-description */
1115
+
1116
+ const _fetchMap = new Map();
1117
+
1118
+ /**
1119
+ * A callback to parse Response body.
1120
+ *
1121
+ * @callback ResponseParser
1122
+ * @param {Fetch.Response} response
1123
+ * @returns {Promise}
1124
+ */
1125
+
1126
+ /**
1127
+ * A minimal in-memory map to de-duplicate Fetch API media requests.
1128
+ *
1129
+ * @param {String} uri
1130
+ * @param {Object} [options={}]
1131
+ * @param {ResponseParser} [options.responseParser=(response) => response.text()]
1132
+ * @returns {Promise}
1133
+ */
1134
+ const cacheFetch = (uri, options = {}) => {
1135
+ const responseParser = options.responseParser || ((response) => response.text());
1136
+ if (!_fetchMap.has(uri)) {
1137
+ _fetchMap.set(uri, fetch(uri).then(responseParser));
1138
+ }
1139
+ return _fetchMap.get(uri);
1140
+ };
1141
+
1142
+ var styleCss = css`:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock,:host{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host([hidden]:not(:focus):not(:active)){display:none}.util_displayHiddenVisually,:host([hiddenVisually]:not(:focus):not(:active)){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.ico_squareLarge{fill:currentColor;height:var(--auro-size-lg, var(--ds-size-300, 1.5rem))}.ico_squareSmall{fill:currentColor;height:.6rem}.ico_squareMed{fill:currentColor;height:var(--auro-size-md, var(--ds-size-200, 1rem))}.ico_squareSml{fill:currentColor;height:var(--auro-size-sm, var(--ds-size-150, 0.75rem))}:host{color:currentColor;vertical-align:middle;line-height:1;display:inline-block}svg{min-width:var(--ds-auro-icon-size, 1.5rem) !important;width:var(--ds-auro-icon-size, 1.5rem) !important;height:var(--ds-auro-icon-size, 1.5rem) !important}.componentWrapper{display:flex}.svgWrapper{height:var(--ds-auro-icon-size);width:var(--ds-auro-icon-size)}.labelWrapper{margin-left:var(--ds-size-50, 0.25rem);line-height:1.8}`;
1143
+
1144
+ // Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
1145
+ // See LICENSE in the project root for license information.
1146
+
1147
+
1148
+ // See https://git.io/JJ6SJ for "How to document your components using JSDoc"
1149
+ /**
1150
+ * @slot - Hidden from visibility, used for a11y if icon description is needed
1151
+ */
1152
+
1153
+ // build the component class
1154
+ class BaseIcon extends AuroElement {
1155
+ constructor() {
1156
+ super();
1157
+ this.onDark = false;
1158
+ }
1159
+
1160
+ // function to define props used within the scope of this component
1161
+ static get properties() {
1162
+ return {
1163
+ ...super.properties,
1164
+
1165
+ /**
1166
+ * Set value for on-dark version of auro-icon.
1167
+ */
1168
+ onDark: {
1169
+ type: Boolean,
1170
+ reflect: true
1171
+ },
1172
+
1173
+ /**
1174
+ * @private
1175
+ */
1176
+ svg: {
1177
+ attribute: false,
1178
+ reflect: true
1179
+ }
1180
+ };
1181
+ }
1182
+
1183
+ static get styles() {
1184
+ return css`
1185
+ ${styleCss}
1186
+ `;
1187
+ }
1188
+
1189
+ /**
1190
+ * Async function to fetch requested icon from npm CDN.
1191
+ * @private
1192
+ * @param {string} category - Icon category.
1193
+ * @param {string} name - Icon name.
1194
+ * @returns {SVGElement} DOM - Ready HTML to be appended.
1195
+ */
1196
+ async fetchIcon(category, name) {
1197
+ let iconHTML = '';
1198
+
1199
+ if (category === 'logos') {
1200
+ iconHTML = await cacheFetch(`${this.uri}/${category}/${name}.svg`);
1201
+ } else {
1202
+ iconHTML = await cacheFetch(`${this.uri}/icons/${category}/${name}.svg`);
1203
+ }
1204
+
1205
+ const dom = new DOMParser().parseFromString(iconHTML, 'text/html');
1206
+
1207
+ return dom.body.querySelector('svg');
1208
+ }
1209
+
1210
+ // lifecycle function
1211
+ async firstUpdated() {
1212
+ if (!this.customSvg) {
1213
+ const svg = await this.fetchIcon(this.category, this.name);
1214
+
1215
+ if (svg) {
1216
+ this.svg = svg;
1217
+ } else if (!svg) {
1218
+ const penDOM = new DOMParser().parseFromString(error.svg, 'text/html');
1219
+
1220
+ this.svg = penDOM.body.firstChild;
1221
+ }
1222
+ }
1223
+ }
1224
+ }
1225
+
1226
+ var tokensCss = css`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-alaska-color:#02426D;--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}`;
1227
+
1228
+ var colorCss = css`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[variant=accent1]){--ds-auro-icon-color:var(--ds-basic-color-texticon-accent1, #265688)}:host(:not([onDark])[variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:not([onDark])[variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-muted, #676767)}:host(:not([onDark])[variant=statusDefault]){--ds-auro-icon-color:var(--ds-basic-color-status-default, #afb9c6)}:host(:not([onDark])[variant=statusInfo]){--ds-auro-icon-color:var(--ds-basic-color-status-info, #01426a)}:host(:not([onDark])[variant=statusSuccess]){--ds-auro-icon-color:var(--ds-basic-color-status-success, #447a1f)}:host(:not([onDark])[variant=statusWarning]){--ds-auro-icon-color:var(--ds-basic-color-status-warning, #fac200)}:host(:not([onDark])[variant=statusError]){--ds-auro-icon-color:var(--ds-basic-color-status-error, #e31f26)}:host(:not([onDark])[variant=statusInfoSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-info-subtle, #ebf3f9)}:host(:not([onDark])[variant=statusSuccessSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-success-subtle, #d6eac7)}:host(:not([onDark])[variant=statusWarningSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-warning-subtle, #fff0b2)}:host(:not([onDark])[variant=statusErrorSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-error-subtle, #fbc6c6)}:host(:not([onDark])[variant=fareBasicEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-basiceconomy, #97eaf8)}:host(:not([onDark])[variant=fareBusiness]){--ds-auro-icon-color:var(--ds-basic-color-fare-business, #01426a)}:host(:not([onDark])[variant=fareEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-economy, #0074ca)}:host(:not([onDark])[variant=fareFirst]){--ds-auro-icon-color:var(--ds-basic-color-fare-first, #00274a)}:host(:not([onDark])[variant=farePremiumEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-premiumeconomy, #005154)}:host(:not([onDark])[variant=tierOneWorldEmerald]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-emerald, #139142)}:host(:not([onDark])[variant=tierOneWorldSapphire]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-sapphire, #015daa)}:host(:not([onDark])[variant=tierOneWorldRuby]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-ruby, #a41d4a)}:host([onDark]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse, #ffffff)}:host([onDark][variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}:host([onDark][variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][variant=statusError]){--ds-auro-icon-color:var(--ds-advanced-color-state-error-inverse, #f9a4a8)}`;
1229
+
1230
+ // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
1231
+ // See LICENSE in the project root for license information.
1232
+
1233
+ // ---------------------------------------------------------------------
1234
+
1235
+ /* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
1236
+
1237
+ class AuroLibraryRuntimeUtils {
1238
+
1239
+ /* eslint-disable jsdoc/require-param */
1240
+
1241
+ /**
1242
+ * This will register a new custom element with the browser.
1243
+ * @param {String} name - The name of the custom element.
1244
+ * @param {Object} componentClass - The class to register as a custom element.
1245
+ * @returns {void}
1246
+ */
1247
+ registerComponent(name, componentClass) {
1248
+ if (!customElements.get(name)) {
1249
+ customElements.define(name, class extends componentClass {});
1250
+ }
1251
+ }
1252
+
1253
+ /**
1254
+ * Finds and returns the closest HTML Element based on a selector.
1255
+ * @returns {void}
1256
+ */
1257
+ closestElement(
1258
+ selector, // selector like in .closest()
1259
+ base = this, // extra functionality to skip a parent
1260
+ __Closest = (el, found = el && el.closest(selector)) =>
1261
+ !el || el === document || el === window
1262
+ ? null // standard .closest() returns null for non-found selectors also
1263
+ : found
1264
+ ? found // found a selector INside this element
1265
+ : __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
1266
+ ) {
1267
+ return __Closest(base);
1268
+ }
1269
+ /* eslint-enable jsdoc/require-param */
1270
+
1271
+ /**
1272
+ * If the element passed is registered with a different tag name than what is passed in, the tag name is added as an attribute to the element.
1273
+ * @param {Object} elem - The element to check.
1274
+ * @param {String} tagName - The name of the Auro component to check for or add as an attribute.
1275
+ * @returns {void}
1276
+ */
1277
+ handleComponentTagRename(elem, tagName) {
1278
+ const tag = tagName.toLowerCase();
1279
+ const elemTag = elem.tagName.toLowerCase();
1280
+
1281
+ if (elemTag !== tag) {
1282
+ elem.setAttribute(tag, true);
1283
+ }
1284
+ }
1285
+
1286
+ /**
1287
+ * Validates if an element is a specific Auro component.
1288
+ * @param {Object} elem - The element to validate.
1289
+ * @param {String} tagName - The name of the Auro component to check against.
1290
+ * @returns {Boolean} - Returns true if the element is the specified Auro component.
1291
+ */
1292
+ elementMatch(elem, tagName) {
1293
+ const tag = tagName.toLowerCase();
1294
+ const elemTag = elem.tagName.toLowerCase();
1295
+
1296
+ return elemTag === tag || elem.hasAttribute(tag);
1297
+ }
1298
+ }
1299
+
1300
+ // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
1301
+ // See LICENSE in the project root for license information.
1302
+
1303
+
1304
+ class AuroIcon extends BaseIcon {
1305
+ constructor() {
1306
+ super();
1307
+
1308
+ this.variant = undefined;
1309
+ this.privateDefaults();
1310
+ }
1311
+
1312
+ /**
1313
+ * Internal Defaults.
1314
+ * @private
1315
+ * @returns {void}
1316
+ */
1317
+ privateDefaults() {
1318
+ this.uri = 'https://cdn.jsdelivr.net/npm/@alaskaairux/icons@latest/dist';
1319
+ this.runtimeUtils = new AuroLibraryRuntimeUtils();
1320
+ }
1321
+
1322
+ // function to define props used within the scope of this component
1323
+ static get properties() {
1324
+ return {
1325
+ ...super.properties,
1326
+
1327
+ /**
1328
+ * Set aria-hidden value. Default is `true`. Option is `false`.
1329
+ */
1330
+ ariaHidden: {
1331
+ type: String,
1332
+ reflect: true
1333
+ },
1334
+
1335
+ /**
1336
+ * The category of the icon you are looking for. See https://auro.alaskaair.com/icons/usage.
1337
+ */
1338
+ category: {
1339
+ type: String,
1340
+ reflect: true
1341
+ },
1342
+
1343
+ /**
1344
+ * Allows custom color to be set.
1345
+ */
1346
+ customColor: {
1347
+ type: Boolean,
1348
+ reflect: true
1349
+ },
1350
+
1351
+ /**
1352
+ * When true, auro-icon will render a custom SVG inside the default slot.
1353
+ */
1354
+ customSvg: {
1355
+ type: Boolean
1356
+ },
1357
+
1358
+ /**
1359
+ * Exposes content in slot as icon label.
1360
+ */
1361
+ label: {
1362
+ type: Boolean,
1363
+ reflect: true
1364
+ },
1365
+
1366
+ /**
1367
+ * The name of the icon you are looking for without the file extension. See https://auro.alaskaair.com/icons/usage.
1368
+ */
1369
+ name: {
1370
+ type: String,
1371
+ reflect: true
1372
+ },
1373
+
1374
+ /**
1375
+ * The style of the icon. The accepted variants are `accent1`, `disabled`, `muted`, `statusDefault`, `statusInfo`, `statusSuccess`, `statusWarning`, `statusError`, `statusInfoSubtle`, `statusSuccessSubtle`, `statusWarningSubtle`, `statusErrorSubtle`, `fareBasicEconomy`, `fareBusiness`, `fareEconomy`, `fareFirst`, `farePremiumEconomy`, `tierOneWorldEmerald`, `tierOneWorldSapphire`, `tierOneWorldRuby`.
1376
+ */
1377
+ variant: {
1378
+ type: String,
1379
+ reflect: true
1380
+ }
1381
+ };
1382
+ }
1383
+
1384
+ static get styles() {
1385
+ return [
1386
+ super.styles,
1387
+ css`${tokensCss}`,
1388
+ css`${styleCss}`,
1389
+ css`${colorCss}`
1390
+ ];
1391
+ }
1392
+
1393
+ /**
1394
+ * This will register this element with the browser.
1395
+ * @param {string} [name="auro-icon"] - The name of element that you want to register to.
1396
+ *
1397
+ * @example
1398
+ * AuroIcon.register("custom-icon") // this will register this element to <custom-icon/>
1399
+ *
1400
+ */
1401
+ static register(name = "auro-icon") {
1402
+ AuroLibraryRuntimeUtils.prototype.registerComponent(name, AuroIcon);
1403
+ }
1404
+
1405
+ connectedCallback() {
1406
+ super.connectedCallback();
1407
+
1408
+ // Add the tag name as an attribute if it is different than the component name
1409
+ this.runtimeUtils.handleComponentTagRename(this, 'auro-icon');
1410
+ }
1411
+
1412
+ /**
1413
+ * @private
1414
+ * @returns {void} Exposes CSS parts for styling from parent components.
1415
+ */
1416
+ exposeCssParts() {
1417
+ this.setAttribute('exportparts', 'svg:iconSvg');
1418
+ }
1419
+
1420
+ async firstUpdated() {
1421
+ await super.firstUpdated();
1422
+
1423
+ /**
1424
+ * icons provide a description for screen readers. Icon only instances Auro-button
1425
+ * depend on this description to provide context for the user using a screen reader.
1426
+ * Removes the SVG description for screen reader if ariaHidden is set to true.
1427
+ */
1428
+ if (this.hasAttribute('ariaHidden') && this.svg) {
1429
+ const svgDesc = this.svg.querySelector('desc');
1430
+
1431
+ if (svgDesc) {
1432
+ svgDesc.remove();
1433
+ this.svg.removeAttribute('aria-labelledby');
1434
+ }
1435
+ }
1436
+ }
1437
+
1438
+ // function that renders the HTML and CSS into the scope of the component
1439
+ render() {
1440
+ const labelClasses = {
1441
+ 'labelWrapper': true,
1442
+ 'util_displayHiddenVisually': !this.label
1443
+ };
1444
+
1445
+ const svgClasses = {
1446
+ 'svgWrapper': true,
1447
+ };
1448
+
1449
+ return html`
1450
+ <div class="componentWrapper">
1451
+ <div
1452
+ class="${classMap(svgClasses)}"
1453
+ title="${ifDefined(this.title || undefined)}">
1454
+ <span aria-hidden="${ifDefined(this.ariaHidden || true)}" part="svg">
1455
+ ${this.customSvg ? html`
1456
+ <slot name="svg"></slot>
1457
+ ` : html`
1458
+ ${this.svg}
1459
+ `
1460
+ }
1461
+ </span>
1462
+ </div>
1463
+
1464
+ <div class="${classMap(labelClasses)}">
1465
+ <slot></slot>
1466
+ </div>
1467
+ </div>
1468
+ `;
1469
+ }
1470
+ }
1471
+
1472
+ var iconVersion = '8.1.1';
1473
+
1474
+ var checkmarkIcon = {"svg":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" aria-labelledby=\"checkmark-sm__desc\" class=\"ico_squareLarge\" role=\"img\" style=\"min-width:var(--auro-size-lg, var(--ds-size-300, 1.5rem));height:var(--auro-size-lg, var(--ds-size-300, 1.5rem));fill:currentColor\" viewBox=\"0 0 24 24\" part=\"svg\"><title/><desc id=\"checkmark-sm__desc\">a small check mark.</desc><path d=\"M8.461 11.84a.625.625 0 1 0-.922.844l2.504 2.738c.247.27.674.27.922 0l5.496-6a.625.625 0 1 0-.922-.844l-5.035 5.496z\"/></svg>"};
1475
+
1476
+ // Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
1477
+ // See LICENSE in the project root for license information.
1478
+
1479
+
1480
+ /**
1481
+ * The auro-menu element provides users a way to define a menu option.
1482
+ *
1483
+ * @attr {String} value - Specifies the value to be sent to a server.
1484
+ * @attr {String} noCheckmark - When true, selected option will not show the checkmark.
1485
+ * @attr {Boolean} disabled - When true specifies that the menuoption is disabled.
1486
+ * @attr {Boolean} selected - Specifies that an option is selected.
1487
+ * @event auroMenuOption-mouseover - Notifies that this option has been hovered over.
1488
+ * @slot - Specifies text for an option, but is not the value.
1489
+ */
1490
+ class AuroMenuOption extends AuroElement$1 {
1491
+ constructor() {
1492
+ super();
1493
+
1494
+ /**
1495
+ * @private
1496
+ */
1497
+ this.shape = undefined;
1498
+
1499
+ /**
1500
+ * @private
1501
+ */
1502
+ this.size = undefined;
1503
+
1504
+ /**
1505
+ * Generate unique names for dependency components.
1506
+ */
1507
+ const versioning = new AuroDependencyVersioning();
1508
+ this.iconTag = versioning.generateTag('auro-formkit-menuoption-icon', iconVersion, AuroIcon);
1509
+
1510
+ this.selected = false;
1511
+ this.nocheckmark = false;
1512
+ this.disabled = false;
1513
+
1514
+ /**
1515
+ * @private
1516
+ */
1517
+ this.tabIndex = -1;
1518
+
1519
+ /**
1520
+ * @private
1521
+ */
1522
+ this.runtimeUtils = new AuroLibraryRuntimeUtils$1();
1523
+ }
1524
+
1525
+ static get properties() {
1526
+ return {
1527
+ ...super.properties,
1528
+ nocheckmark: {
1529
+ type: Boolean,
1530
+ reflect: true
1531
+ },
1532
+ selected: {
1533
+ type: Boolean,
1534
+ reflect: true
1535
+ },
1536
+ disabled: {
1537
+ type: Boolean,
1538
+ reflect: true
1539
+ },
1540
+ value: {
1541
+ type: String
1542
+ },
1543
+ tabIndex: {
1544
+ type: Number,
1545
+ reflect: true
1546
+ }
1547
+ };
1548
+ }
1549
+
1550
+ static get styles() {
1551
+ return [
1552
+ styleCss$1,
1553
+ colorCss$1,
1554
+ tokensCss$1
1555
+ ];
1556
+ }
1557
+
1558
+ /**
1559
+ * This will register this element with the browser.
1560
+ * @param {string} [name="auro-menuoption"] - The name of element that you want to register to.
1561
+ *
1562
+ * @example
1563
+ * AuroMenuOption.register("custom-menuoption") // this will register this element to <custom-menuoption/>
1564
+ *
1565
+ */
1566
+ static register(name = "auro-menuoption") {
1567
+ AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroMenuOption);
1568
+ }
1569
+
1570
+ firstUpdated() {
1571
+ // Add the tag name as an attribute if it is different than the component name
1572
+ this.runtimeUtils.handleComponentTagRename(this, 'auro-menuoption');
1573
+
1574
+ if (!this.hasAttribute('size')) {
1575
+ this.size = this.parentElement.getAttribute('size') || 'sm';
1576
+ }
1577
+ if (!this.hasAttribute('shape')) {
1578
+ this.shape = this.parentElement.getAttribute('shape') || 'box';
1579
+ }
1580
+
1581
+ this.setAttribute('role', 'option');
1582
+ this.setAttribute('aria-selected', 'false');
1583
+
1584
+ this.addEventListener('mouseover', () => {
1585
+ this.dispatchEvent(new CustomEvent('auroMenuOption-mouseover', {
1586
+ bubbles: true,
1587
+ cancelable: false,
1588
+ composed: true,
1589
+ detail: this
1590
+ }));
1591
+ });
1592
+ }
1593
+
1594
+ // observer for selected property changes
1595
+ updated(changedProperties) {
1596
+ super.updated(changedProperties);
1597
+
1598
+ if (changedProperties.has('selected')) {
1599
+ this.setAttribute('aria-selected', this.selected.toString());
1600
+ }
1601
+ }
1602
+
1603
+ /**
1604
+ * Generates an HTML element containing an SVG icon based on the provided `svgContent`.
1605
+ *
1606
+ * @private
1607
+ * @param {string} svgContent - The SVG content to be embedded.
1608
+ * @returns {Element} The HTML element containing the SVG icon.
1609
+ */
1610
+ generateIconHtml(svgContent) {
1611
+ const dom = new DOMParser().parseFromString(svgContent, 'text/html');
1612
+ const svg = dom.body.firstChild;
1613
+
1614
+ svg.setAttribute('slot', 'svg');
1615
+
1616
+ return html$1`<${this.iconTag} customColor customSvg>${svg}</${this.iconTag}>`;
1617
+ }
1618
+
1619
+ /**
1620
+ * Logic to determine the layout of the component.
1621
+ * @protected
1622
+ * @returns {void}
1623
+ */
1624
+ renderLayout() {
1625
+
1626
+ const fontClassMap = {
1627
+ xs: 'body-sm',
1628
+ sm: 'body-default',
1629
+ md: 'body-default',
1630
+ lg: 'body-lg',
1631
+ xl: 'body-lg'
1632
+ };
1633
+
1634
+ const classes = classMap({
1635
+ 'wrapper': true,
1636
+ [this.size ? fontClassMap[this.size] : 'body-sm']: true,
1637
+ });
1638
+
1639
+ return html$1`
1640
+ <div class="${classes}">
1641
+ ${this.selected && !this.nocheckmark
1642
+ ? this.generateIconHtml(checkmarkIcon.svg)
1643
+ : undefined}
1644
+ <slot></slot>
1645
+ </div>
1646
+ `;
1647
+ }
1648
+ }
1649
+
1650
+ AuroMenu.register();
1651
+ AuroMenuOption.register();