@aurodesignsystem-dev/auro-formkit 0.0.0-pr1551.0 → 0.0.0-pr1552.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 (43) hide show
  1. package/components/checkbox/demo/customize.min.js +1 -1
  2. package/components/checkbox/demo/getting-started.min.js +1 -1
  3. package/components/checkbox/demo/index.min.js +1 -1
  4. package/components/checkbox/dist/index.js +1 -1
  5. package/components/checkbox/dist/registered.js +1 -1
  6. package/components/combobox/demo/customize.min.js +207 -46
  7. package/components/combobox/demo/getting-started.min.js +207 -46
  8. package/components/combobox/demo/index.min.js +207 -46
  9. package/components/combobox/dist/index.js +207 -46
  10. package/components/combobox/dist/registered.js +207 -46
  11. package/components/counter/demo/customize.min.js +206 -45
  12. package/components/counter/demo/index.min.js +206 -45
  13. package/components/counter/dist/index.js +206 -45
  14. package/components/counter/dist/registered.js +206 -45
  15. package/components/datepicker/demo/customize.min.js +207 -46
  16. package/components/datepicker/demo/index.min.js +207 -46
  17. package/components/datepicker/dist/index.js +207 -46
  18. package/components/datepicker/dist/registered.js +207 -46
  19. package/components/dropdown/demo/customize.min.js +205 -44
  20. package/components/dropdown/demo/getting-started.min.js +205 -44
  21. package/components/dropdown/demo/index.min.js +205 -44
  22. package/components/dropdown/dist/index.js +205 -44
  23. package/components/dropdown/dist/registered.js +205 -44
  24. package/components/form/demo/customize.min.js +829 -185
  25. package/components/form/demo/getting-started.min.js +829 -185
  26. package/components/form/demo/index.min.js +829 -185
  27. package/components/form/demo/registerDemoDeps.min.js +829 -185
  28. package/components/input/demo/customize.min.js +1 -1
  29. package/components/input/demo/getting-started.min.js +1 -1
  30. package/components/input/demo/index.min.js +1 -1
  31. package/components/input/dist/index.js +1 -1
  32. package/components/input/dist/registered.js +1 -1
  33. package/components/radio/demo/customize.min.js +1 -1
  34. package/components/radio/demo/getting-started.min.js +1 -1
  35. package/components/radio/demo/index.min.js +1 -1
  36. package/components/radio/dist/index.js +1 -1
  37. package/components/radio/dist/registered.js +1 -1
  38. package/components/select/demo/customize.min.js +206 -45
  39. package/components/select/demo/getting-started.min.js +206 -45
  40. package/components/select/demo/index.min.js +206 -45
  41. package/components/select/dist/index.js +206 -45
  42. package/components/select/dist/registered.js +206 -45
  43. package/package.json +2 -2
@@ -13379,7 +13379,7 @@ let AuroHelpText$8 = class AuroHelpText extends i$3 {
13379
13379
  }
13380
13380
  };
13381
13381
 
13382
- var formkitVersion$8 = '202607100029';
13382
+ var formkitVersion$8 = '202607092329';
13383
13383
 
13384
13384
  // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
13385
13385
  // See LICENSE in the project root for license information.
@@ -27776,7 +27776,7 @@ let AuroBibtemplate$3 = class AuroBibtemplate extends i$3 {
27776
27776
  }
27777
27777
  };
27778
27778
 
27779
- var formkitVersion$2$1 = '202607100029';
27779
+ var formkitVersion$2$1 = '202607092329';
27780
27780
 
27781
27781
  let l$1$2 = class l{generateElementName(t,e){let o=t;return o+="-",o+=e.replace(/[.]/g,"_"),o}generateTag(o,s,a){const r=this.generateElementName(o,s),i=i$2`${s$3(r)}`;return customElements.get(r)||customElements.define(r,class extends a{}),i}};let d$1$2 = class d{registerComponent(t,e){customElements.get(t)||customElements.define(t,class extends e{});}closestElement(t,e=this,o=(e,s=e&&e.closest(t))=>e&&e!==document&&e!==window?s||o(e.getRootNode().host):null){return o(e)}handleComponentTagRename(t,e){const o=e.toLowerCase();t.tagName.toLowerCase()!==o&&t.setAttribute(o,true);}elementMatch(t,e){const o=e.toLowerCase();return t.tagName.toLowerCase()===o||t.hasAttribute(o)}getSlotText(t,e){const o=t.shadowRoot?.querySelector(`slot[name="${e}"]`),s=(o?.assignedNodes({flatten:true})||[]).map(t=>t.textContent?.trim()).join(" ").trim();return s||null}};let h$1$2 = class h{registerComponent(t,e){customElements.get(t)||customElements.define(t,class extends e{});}closestElement(t,e=this,o=(e,s=e&&e.closest(t))=>e&&e!==document&&e!==window?s||o(e.getRootNode().host):null){return o(e)}handleComponentTagRename(t,e){const o=e.toLowerCase();t.tagName.toLowerCase()!==o&&t.setAttribute(o,true);}elementMatch(t,e){const o=e.toLowerCase();return t.tagName.toLowerCase()===o||t.hasAttribute(o)}};var c$1$3=i$6`:host{color:var(--ds-auro-loader-color)}:host>span{background-color:var(--ds-auro-loader-background-color);border-color:var(--ds-auro-loader-border-color)}:host([onlight]),:host([appearance=brand]){--ds-auro-loader-color: var(--ds-basic-color-brand-primary, #01426a)}:host([ondark]),:host([appearance=inverse]){--ds-auro-loader-color: var(--ds-basic-color-texticon-inverse, #ffffff)}:host([orbit])>span{--ds-auro-loader-background-color: transparent}:host([orbit])>span:nth-child(1){--ds-auro-loader-border-color: currentcolor;opacity:.25}:host([orbit])>span:nth-child(2){--ds-auro-loader-border-color: currentcolor;border-right-color:transparent;border-bottom-color:transparent;border-left-color:transparent}
27782
27782
  `,u$4$2=i$6`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default,.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)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-sm{font-size:var(--wcss-body-sm-font-size, .875rem);line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm,.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)}.body-xs{font-size:var(--wcss-body-xs-font-size, .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-size:var(--wcss-body-2xs-font-size, .625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, .875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, .05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, .05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, .05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, .05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, .05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, .1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(.875rem, 1.1666666667vw, .875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, .1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}:focus:not(:focus-visible){outline:3px solid transparent}:host,:host>span{position:relative}:host{width:2rem;height:2rem;display:inline-block;font-size:0}:host>span{position:absolute;display:inline-block;float:none;top:0;left:0;width:2rem;height:2rem;border-radius:100%;border-style:solid;border-width:0;box-sizing:border-box}:host([xs]),:host([xs])>span{width:1.2rem;height:1.2rem}:host([sm]),:host([sm])>span{width:3rem;height:3rem}:host([md]),:host([md])>span{width:5rem;height:5rem}:host([lg]),:host([lg])>span{width:8rem;height:8rem}:host{--margin: .375rem;--margin-xs: .2rem;--margin-sm: .5rem;--margin-md: .75rem;--margin-lg: 1rem}:host([pulse]),:host([pulse])>span{position:relative}:host([pulse]){width:calc(3rem + var(--margin) * 6);height:calc(1rem + var(--margin) * 2)}:host([pulse])>span{width:1rem;height:1rem;margin:var(--margin);animation:pulse 1.5s ease infinite}:host([pulse][xs]){width:calc(1.95rem + var(--margin-xs) * 6);height:calc(.65rem + var(--margin-xs) * 2)}:host([pulse][xs])>span{margin:var(--margin-xs);width:.65rem;height:.65rem}:host([pulse][sm]){width:calc(6rem + var(--margin-sm) * 6);height:calc(2rem + var(--margin-sm) * 2)}:host([pulse][sm])>span{margin:var(--margin-sm);width:2rem;height:2rem}:host([pulse][md]){width:calc(9rem + var(--margin-md) * 6);height:calc(3rem + var(--margin-md) * 2)}:host([pulse][md])>span{margin:var(--margin-md);width:3rem;height:3rem}:host([pulse][lg]){width:calc(15rem + var(--margin-lg) * 6);height:calc(5rem + var(--margin-lg) * 2)}:host([pulse][lg])>span{margin:var(--margin-lg);width:5rem;height:5rem}:host([pulse])>span:nth-child(1){animation-delay:-.4s}:host([pulse])>span:nth-child(2){animation-delay:-.2s}:host([pulse])>span:nth-child(3){animation-delay:0ms}@keyframes pulse{0%,to{opacity:.1;transform:scale(.9)}50%{opacity:1;transform:scale(1.1)}}:host([orbit]),:host([orbit])>span{opacity:1}:host([orbit])>span{border-width:5px}:host([orbit])>span:nth-child(2){animation:orbit 2s linear infinite}:host([orbit][sm])>span{border-width:8px}:host([orbit][md])>span{border-width:13px}:host([orbit][lg])>span{border-width:21px}@keyframes orbit{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host([ringworm])>svg{animation:rotate 2s linear infinite;height:100%;width:100%;stroke:currentcolor;stroke-width:8}:host([ringworm]) .path{stroke-dashoffset:0;animation:ringworm 1.5s ease-in-out infinite;stroke-linecap:round}@keyframes rotate{to{transform:rotate(360deg)}}@keyframes ringworm{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}to{stroke-dasharray:89,200;stroke-dashoffset:-124px}}:host([laser]){position:static;width:100%;display:block;height:0;overflow:hidden;font-size:unset}:host([laser])>span{position:fixed;width:100%;height:.25rem;border-radius:0;z-index:100}:host([laser])>span:nth-child(1){border-color:currentcolor;opacity:.25}:host([laser])>span:nth-child(2){border-color:currentcolor;animation:laser 2s linear infinite;opacity:1;width:50%}:host([laser][sm])>span:nth-child(2){width:20%}:host([laser][md])>span:nth-child(2){width:30%}:host([laser][lg])>span:nth-child(2){width:50%;animation-duration:1.5s}:host([laser][xl])>span:nth-child(2){width:80%;animation-duration:1.5s}@keyframes laser{0%{left:-100%}to{left:110%}}:host>.no-animation{display:none}@media (prefers-reduced-motion: reduce){:host{display:flex;align-items:center;justify-content:center}:host>span{opacity:1}:host>.loader{display:none}:host>svg{display:none}:host>.no-animation{display:block}}
@@ -32053,40 +32053,12 @@ let AuroFloatingUI$3 = class AuroFloatingUI {
32053
32053
  return;
32054
32054
  }
32055
32055
 
32056
- // Chrome-specific: during popover top-layer promotion after a click on a
32057
- // slotted focusable, :focus-within can briefly evaluate false while the
32058
- // active element is still structurally inside the trigger/bib. Fall back
32059
- // to a shadow-piercing ancestry walk from the deep active element before
32060
- // treating this as a real focus loss.
32061
- try {
32062
- let active = document.activeElement;
32063
- while (active && active.shadowRoot && active.shadowRoot.activeElement) {
32064
- active = active.shadowRoot.activeElement;
32065
- }
32066
- const targets = [element, element.trigger, element.bib].filter(Boolean);
32067
- let node = active;
32068
- while (node) {
32069
- if (targets.includes(node)) {
32070
- return;
32071
- }
32072
- node =
32073
- node.parentElement ||
32074
- (node.getRootNode && node.getRootNode().host) ||
32075
- null;
32076
- }
32077
- } catch (e) {
32078
- // Defensive: fall through to the existing close path if traversal fails.
32079
- }
32080
-
32081
32056
  // if fullscreen bib is in fullscreen mode, do not close
32082
32057
  if (element.bib.hasAttribute("isfullscreen")) {
32083
32058
  return;
32084
32059
  }
32085
32060
 
32086
- // eventType "focusloss" distinguishes a Tab/click-driven close from an
32087
- // Escape keydown close. Consumers use this to decide whether to restore
32088
- // focus to the trigger (Escape) or let it advance naturally (Tab).
32089
- this.hideBib("focusloss");
32061
+ this.hideBib("keydown");
32090
32062
  }
32091
32063
 
32092
32064
  setupHideHandlers() {
@@ -32756,6 +32728,199 @@ function getFocusableElements$4(container) {
32756
32728
  return tabIndexedUniqueElements;
32757
32729
  }
32758
32730
 
32731
+ /**
32732
+ * FocusTrap manages keyboard focus within a specified container element, ensuring that focus does not leave the container when tabbing.
32733
+ * It is commonly used for modal dialogs or overlays to improve accessibility by trapping focus within interactive UI components.
32734
+ */
32735
+ let FocusTrap$3 = class FocusTrap {
32736
+ /**
32737
+ * Creates a new FocusTrap instance for the given container element.
32738
+ * Initializes event listeners and prepares the container for focus management.
32739
+ *
32740
+ * @param {HTMLElement} container The DOM element to trap focus within.
32741
+ * @param {boolean} [controlTabOrder=false] If true enables manual control of the tab order by the FocusTrap.
32742
+ * @throws {Error} If the provided container is not a valid HTMLElement.
32743
+ */
32744
+ constructor(container, controlTabOrder = false) {
32745
+ if (!container || !(container instanceof HTMLElement)) {
32746
+ throw new Error("FocusTrap requires a valid HTMLElement.");
32747
+ }
32748
+
32749
+ this.container = container;
32750
+ this.tabDirection = "forward"; // or 'backward';
32751
+ this.controlTabOrder = controlTabOrder;
32752
+
32753
+ this._init();
32754
+ }
32755
+
32756
+ /**
32757
+ * Initializes the focus trap by setting up event listeners and attributes on the container.
32758
+ * Prepares the container for focus management, including support for shadow DOM and inert attributes.
32759
+ *
32760
+ * @private
32761
+ */
32762
+ _init() {
32763
+ // Add inert attribute to prevent focusing programmatically as well (if supported)
32764
+ if ("inert" in HTMLElement.prototype) {
32765
+ this.container.inert = false; // Ensure the container isn't inert
32766
+ this.container.setAttribute("data-focus-trap-container", true); // Mark for identification
32767
+ }
32768
+
32769
+ // Track tab direction
32770
+ this.container.addEventListener("keydown", this._onKeydown);
32771
+ }
32772
+
32773
+ /**
32774
+ * Gets an array of currently active (focused) elements in the document and shadow DOM.
32775
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
32776
+ * @private
32777
+ */
32778
+ _getActiveElements() {
32779
+ // Get the active element(s) in the document and shadow root
32780
+ // This will include the active element in the shadow DOM if it exists
32781
+ // Active element may be inside the shadow DOM depending on delegatesFocus, so we need to check both
32782
+ let { activeElement } = document;
32783
+ const actives = [activeElement];
32784
+ while (activeElement?.shadowRoot?.activeElement) {
32785
+ actives.push(activeElement.shadowRoot.activeElement);
32786
+ activeElement = activeElement.shadowRoot.activeElement;
32787
+ }
32788
+ return actives;
32789
+ }
32790
+
32791
+ /**
32792
+ * Gets the next focus index based on the current index and focusable elements.
32793
+ * @param {number} currentIndex The current index of the focused element.
32794
+ * @param {Array<HTMLElement>} focusables The array of focusable elements.
32795
+ * @returns {number|null} The next focus index or null if not determined.
32796
+ */
32797
+ _getNextFocusIndex(currentIndex, focusables, actives) {
32798
+ if (this.controlTabOrder) {
32799
+ // Calculate the new index based on the current index and tab direction
32800
+ let newFocusIndex =
32801
+ currentIndex + (this.tabDirection === "forward" ? 1 : -1);
32802
+
32803
+ // Wrap-around logic
32804
+ if (newFocusIndex < 0) newFocusIndex = focusables.length - 1;
32805
+ if (newFocusIndex >= focusables.length) newFocusIndex = 0;
32806
+
32807
+ // Early return with the new index
32808
+ return newFocusIndex;
32809
+ }
32810
+
32811
+ // Determine if we need to wrap
32812
+ const atFirst =
32813
+ actives.includes(focusables[0]) || actives.includes(this.container);
32814
+ const atLast = actives.includes(focusables[focusables.length - 1]);
32815
+
32816
+ // Only wrap if at the ends
32817
+ if (this.tabDirection === "backward" && atFirst) {
32818
+ return focusables.length - 1;
32819
+ }
32820
+
32821
+ if (this.tabDirection === "forward" && atLast) {
32822
+ return 0;
32823
+ }
32824
+
32825
+ // No wrap, so don't change focus, return early
32826
+ return null;
32827
+ }
32828
+
32829
+ /**
32830
+ * Handles the Tab key press event to manage focus within the container.
32831
+ * @param {KeyboardEvent} e The keyboard event triggered by the user.
32832
+ * @returns {void}
32833
+ */
32834
+ _handleTabKey(e) {
32835
+ // Update the focusable elements
32836
+ const focusables = this._getFocusableElements();
32837
+
32838
+ // If there are no focusable elements, exit
32839
+ if (!focusables.length) return;
32840
+
32841
+ // Set the tab direction based on the key pressed
32842
+ this.tabDirection = e.shiftKey ? "backward" : "forward";
32843
+
32844
+ // Get the active elements that are currently focused
32845
+ const actives = this._getActiveElements();
32846
+
32847
+ // If we're at either end of the focusable elements, wrap around to the other end
32848
+ let focusIndex = focusables.findIndex((el) => actives.includes(el));
32849
+
32850
+ // Fallback if we have no focused element
32851
+ if (focusIndex === -1) focusIndex = 0;
32852
+
32853
+ // Get the next focus index based on the current focus index, tab direction, and controlTabOrder setting
32854
+ // Is null if no new focus index is determined
32855
+ const newFocusIndex = this._getNextFocusIndex(
32856
+ focusIndex,
32857
+ focusables,
32858
+ actives,
32859
+ );
32860
+
32861
+ // If we have a new focus index, set focus to that element
32862
+ if (newFocusIndex !== null) {
32863
+ e.preventDefault();
32864
+ focusables[newFocusIndex].focus();
32865
+ }
32866
+ }
32867
+
32868
+ /**
32869
+ * Catches the keydown event
32870
+ * @param {KeyboardEvent} e The keyboard event triggered by user interaction.
32871
+ * @private
32872
+ */
32873
+ _onKeydown = (e) => {
32874
+ // Handle tab
32875
+ if (e.key === "Tab") this._handleTabKey(e);
32876
+ };
32877
+
32878
+ /**
32879
+ * Retrieves all focusable elements within the container in DOM order, including those in shadow DOM and slots.
32880
+ * Returns a unique, ordered array of elements that can receive focus.
32881
+ *
32882
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
32883
+ * @private
32884
+ */
32885
+ _getFocusableElements() {
32886
+ // Use the imported utility function to get focusable elements
32887
+ const elements = getFocusableElements$4(this.container);
32888
+
32889
+ // Return the elements found
32890
+ return elements;
32891
+ }
32892
+
32893
+ /**
32894
+ * Moves focus to the first focusable element within the container.
32895
+ * Useful for setting initial focus when activating the focus trap.
32896
+ */
32897
+ focusFirstElement() {
32898
+ const focusables = this._getFocusableElements();
32899
+ if (focusables.length) focusables[0].focus();
32900
+ }
32901
+
32902
+ /**
32903
+ * Moves focus to the last focusable element within the container.
32904
+ * Useful for setting focus when deactivating or cycling focus in reverse.
32905
+ */
32906
+ focusLastElement() {
32907
+ const focusables = this._getFocusableElements();
32908
+ if (focusables.length) focusables[focusables.length - 1].focus();
32909
+ }
32910
+
32911
+ /**
32912
+ * Removes event listeners and attributes added by the focus trap.
32913
+ * Call this method to clean up when the focus trap is no longer needed.
32914
+ */
32915
+ disconnect() {
32916
+ if (this.container.hasAttribute("data-focus-trap-container")) {
32917
+ this.container.removeAttribute("data-focus-trap-container");
32918
+ }
32919
+
32920
+ this.container.removeEventListener("keydown", this._onKeydown);
32921
+ }
32922
+ };
32923
+
32759
32924
  // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
32760
32925
  // See LICENSE in the project root for license information.
32761
32926
 
@@ -33253,7 +33418,7 @@ let AuroDropdownBib$3 = class AuroDropdownBib extends i$3 {
33253
33418
  classes[`shape-${this.shape}`] = true;
33254
33419
 
33255
33420
  return u$c`
33256
- <dialog tabindex="-1" class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
33421
+ <dialog class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
33257
33422
  ${this.dialogLabel ? u$c`<span id="dialogLabel" class="util_displayHiddenVisually">${this.dialogLabel}</span>` : ''}
33258
33423
  <slot></slot>
33259
33424
  <span id="srAnnouncement" class="util_displayHiddenVisually" aria-live="polite" role="status"></span>
@@ -33504,7 +33669,7 @@ let AuroHelpText$2$1 = class AuroHelpText extends i$3 {
33504
33669
  }
33505
33670
  };
33506
33671
 
33507
- var formkitVersion$1$3 = '202607100029';
33672
+ var formkitVersion$1$3 = '202607092329';
33508
33673
 
33509
33674
  let AuroElement$2$2 = class AuroElement extends i$3 {
33510
33675
  static get properties() {
@@ -34258,10 +34423,7 @@ let AuroDropdown$3 = class AuroDropdown extends AuroElement$2$2 {
34258
34423
  }
34259
34424
 
34260
34425
 
34261
- // On Tab-driven close (eventType "focusloss"), let focus advance naturally
34262
- // — restoring to the trigger would trap the user on this dropdown, forcing
34263
- // an extra Tab to move on. Escape and outside-click still restore.
34264
- if (!this.isPopoverVisible && eventType !== "focusloss") {
34426
+ if (!this.isPopoverVisible) {
34265
34427
  // wait til the bib gets fully closed and rendered
34266
34428
  setTimeout(() => {
34267
34429
  // Skip if the bib re-opened, or if focus moved intentionally outside the dropdown (not to body).
@@ -34491,16 +34653,15 @@ let AuroDropdown$3 = class AuroDropdown extends AuroElement$2$2 {
34491
34653
  }
34492
34654
  });
34493
34655
  } else {
34494
- // Normal desktop (non-modal): move initial focus into the bib but
34495
- // don't trap Tab. Tab should exit the bib and let the floater's
34496
- // handleFocusLoss close it, matching native <select>/<details>
34497
- // behavior. Deferred one frame because Floating UI positions the
34498
- // popover asynchronously a synchronous focus() would target
34499
- // zero-dimension elements and be silently ignored.
34656
+ // Normal desktop: use FocusTrap on the bib element.
34657
+ // Defer focusFirstElement to the next frame because the popover
34658
+ // is positioned asynchronously by Floating UI — calling focus()
34659
+ // synchronously here would target elements with zero dimensions
34660
+ // and the focus call would be silently ignored.
34661
+ this.focusTrap = new FocusTrap$3(this.bibContent);
34500
34662
  requestAnimationFrame(() => {
34501
- const focusables = getFocusableElements$4(this.bibContent);
34502
- if (focusables.length) {
34503
- focusables[0].focus();
34663
+ if (this.focusTrap) {
34664
+ this.focusTrap.focusFirstElement();
34504
34665
  }
34505
34666
  });
34506
34667
  }
@@ -47126,7 +47287,7 @@ let AuroHelpText$1$3 = class AuroHelpText extends i$3 {
47126
47287
  }
47127
47288
  };
47128
47289
 
47129
- var formkitVersion$7 = '202607100029';
47290
+ var formkitVersion$7 = '202607092329';
47130
47291
 
47131
47292
  // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
47132
47293
  // See LICENSE in the project root for license information.
@@ -52067,7 +52228,7 @@ let AuroHelpText$1$2 = class AuroHelpText extends i$3 {
52067
52228
  }
52068
52229
  };
52069
52230
 
52070
- var formkitVersion$1$2 = '202607100029';
52231
+ var formkitVersion$1$2 = '202607092329';
52071
52232
 
52072
52233
  // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
52073
52234
  // See LICENSE in the project root for license information.
@@ -54779,40 +54940,12 @@ let AuroFloatingUI$2 = class AuroFloatingUI {
54779
54940
  return;
54780
54941
  }
54781
54942
 
54782
- // Chrome-specific: during popover top-layer promotion after a click on a
54783
- // slotted focusable, :focus-within can briefly evaluate false while the
54784
- // active element is still structurally inside the trigger/bib. Fall back
54785
- // to a shadow-piercing ancestry walk from the deep active element before
54786
- // treating this as a real focus loss.
54787
- try {
54788
- let active = document.activeElement;
54789
- while (active && active.shadowRoot && active.shadowRoot.activeElement) {
54790
- active = active.shadowRoot.activeElement;
54791
- }
54792
- const targets = [element, element.trigger, element.bib].filter(Boolean);
54793
- let node = active;
54794
- while (node) {
54795
- if (targets.includes(node)) {
54796
- return;
54797
- }
54798
- node =
54799
- node.parentElement ||
54800
- (node.getRootNode && node.getRootNode().host) ||
54801
- null;
54802
- }
54803
- } catch (e) {
54804
- // Defensive: fall through to the existing close path if traversal fails.
54805
- }
54806
-
54807
54943
  // if fullscreen bib is in fullscreen mode, do not close
54808
54944
  if (element.bib.hasAttribute("isfullscreen")) {
54809
54945
  return;
54810
54946
  }
54811
54947
 
54812
- // eventType "focusloss" distinguishes a Tab/click-driven close from an
54813
- // Escape keydown close. Consumers use this to decide whether to restore
54814
- // focus to the trigger (Escape) or let it advance naturally (Tab).
54815
- this.hideBib("focusloss");
54948
+ this.hideBib("keydown");
54816
54949
  }
54817
54950
 
54818
54951
  setupHideHandlers() {
@@ -55482,6 +55615,199 @@ function getFocusableElements$3(container) {
55482
55615
  return tabIndexedUniqueElements;
55483
55616
  }
55484
55617
 
55618
+ /**
55619
+ * FocusTrap manages keyboard focus within a specified container element, ensuring that focus does not leave the container when tabbing.
55620
+ * It is commonly used for modal dialogs or overlays to improve accessibility by trapping focus within interactive UI components.
55621
+ */
55622
+ let FocusTrap$2 = class FocusTrap {
55623
+ /**
55624
+ * Creates a new FocusTrap instance for the given container element.
55625
+ * Initializes event listeners and prepares the container for focus management.
55626
+ *
55627
+ * @param {HTMLElement} container The DOM element to trap focus within.
55628
+ * @param {boolean} [controlTabOrder=false] If true enables manual control of the tab order by the FocusTrap.
55629
+ * @throws {Error} If the provided container is not a valid HTMLElement.
55630
+ */
55631
+ constructor(container, controlTabOrder = false) {
55632
+ if (!container || !(container instanceof HTMLElement)) {
55633
+ throw new Error("FocusTrap requires a valid HTMLElement.");
55634
+ }
55635
+
55636
+ this.container = container;
55637
+ this.tabDirection = "forward"; // or 'backward';
55638
+ this.controlTabOrder = controlTabOrder;
55639
+
55640
+ this._init();
55641
+ }
55642
+
55643
+ /**
55644
+ * Initializes the focus trap by setting up event listeners and attributes on the container.
55645
+ * Prepares the container for focus management, including support for shadow DOM and inert attributes.
55646
+ *
55647
+ * @private
55648
+ */
55649
+ _init() {
55650
+ // Add inert attribute to prevent focusing programmatically as well (if supported)
55651
+ if ("inert" in HTMLElement.prototype) {
55652
+ this.container.inert = false; // Ensure the container isn't inert
55653
+ this.container.setAttribute("data-focus-trap-container", true); // Mark for identification
55654
+ }
55655
+
55656
+ // Track tab direction
55657
+ this.container.addEventListener("keydown", this._onKeydown);
55658
+ }
55659
+
55660
+ /**
55661
+ * Gets an array of currently active (focused) elements in the document and shadow DOM.
55662
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
55663
+ * @private
55664
+ */
55665
+ _getActiveElements() {
55666
+ // Get the active element(s) in the document and shadow root
55667
+ // This will include the active element in the shadow DOM if it exists
55668
+ // Active element may be inside the shadow DOM depending on delegatesFocus, so we need to check both
55669
+ let { activeElement } = document;
55670
+ const actives = [activeElement];
55671
+ while (activeElement?.shadowRoot?.activeElement) {
55672
+ actives.push(activeElement.shadowRoot.activeElement);
55673
+ activeElement = activeElement.shadowRoot.activeElement;
55674
+ }
55675
+ return actives;
55676
+ }
55677
+
55678
+ /**
55679
+ * Gets the next focus index based on the current index and focusable elements.
55680
+ * @param {number} currentIndex The current index of the focused element.
55681
+ * @param {Array<HTMLElement>} focusables The array of focusable elements.
55682
+ * @returns {number|null} The next focus index or null if not determined.
55683
+ */
55684
+ _getNextFocusIndex(currentIndex, focusables, actives) {
55685
+ if (this.controlTabOrder) {
55686
+ // Calculate the new index based on the current index and tab direction
55687
+ let newFocusIndex =
55688
+ currentIndex + (this.tabDirection === "forward" ? 1 : -1);
55689
+
55690
+ // Wrap-around logic
55691
+ if (newFocusIndex < 0) newFocusIndex = focusables.length - 1;
55692
+ if (newFocusIndex >= focusables.length) newFocusIndex = 0;
55693
+
55694
+ // Early return with the new index
55695
+ return newFocusIndex;
55696
+ }
55697
+
55698
+ // Determine if we need to wrap
55699
+ const atFirst =
55700
+ actives.includes(focusables[0]) || actives.includes(this.container);
55701
+ const atLast = actives.includes(focusables[focusables.length - 1]);
55702
+
55703
+ // Only wrap if at the ends
55704
+ if (this.tabDirection === "backward" && atFirst) {
55705
+ return focusables.length - 1;
55706
+ }
55707
+
55708
+ if (this.tabDirection === "forward" && atLast) {
55709
+ return 0;
55710
+ }
55711
+
55712
+ // No wrap, so don't change focus, return early
55713
+ return null;
55714
+ }
55715
+
55716
+ /**
55717
+ * Handles the Tab key press event to manage focus within the container.
55718
+ * @param {KeyboardEvent} e The keyboard event triggered by the user.
55719
+ * @returns {void}
55720
+ */
55721
+ _handleTabKey(e) {
55722
+ // Update the focusable elements
55723
+ const focusables = this._getFocusableElements();
55724
+
55725
+ // If there are no focusable elements, exit
55726
+ if (!focusables.length) return;
55727
+
55728
+ // Set the tab direction based on the key pressed
55729
+ this.tabDirection = e.shiftKey ? "backward" : "forward";
55730
+
55731
+ // Get the active elements that are currently focused
55732
+ const actives = this._getActiveElements();
55733
+
55734
+ // If we're at either end of the focusable elements, wrap around to the other end
55735
+ let focusIndex = focusables.findIndex((el) => actives.includes(el));
55736
+
55737
+ // Fallback if we have no focused element
55738
+ if (focusIndex === -1) focusIndex = 0;
55739
+
55740
+ // Get the next focus index based on the current focus index, tab direction, and controlTabOrder setting
55741
+ // Is null if no new focus index is determined
55742
+ const newFocusIndex = this._getNextFocusIndex(
55743
+ focusIndex,
55744
+ focusables,
55745
+ actives,
55746
+ );
55747
+
55748
+ // If we have a new focus index, set focus to that element
55749
+ if (newFocusIndex !== null) {
55750
+ e.preventDefault();
55751
+ focusables[newFocusIndex].focus();
55752
+ }
55753
+ }
55754
+
55755
+ /**
55756
+ * Catches the keydown event
55757
+ * @param {KeyboardEvent} e The keyboard event triggered by user interaction.
55758
+ * @private
55759
+ */
55760
+ _onKeydown = (e) => {
55761
+ // Handle tab
55762
+ if (e.key === "Tab") this._handleTabKey(e);
55763
+ };
55764
+
55765
+ /**
55766
+ * Retrieves all focusable elements within the container in DOM order, including those in shadow DOM and slots.
55767
+ * Returns a unique, ordered array of elements that can receive focus.
55768
+ *
55769
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
55770
+ * @private
55771
+ */
55772
+ _getFocusableElements() {
55773
+ // Use the imported utility function to get focusable elements
55774
+ const elements = getFocusableElements$3(this.container);
55775
+
55776
+ // Return the elements found
55777
+ return elements;
55778
+ }
55779
+
55780
+ /**
55781
+ * Moves focus to the first focusable element within the container.
55782
+ * Useful for setting initial focus when activating the focus trap.
55783
+ */
55784
+ focusFirstElement() {
55785
+ const focusables = this._getFocusableElements();
55786
+ if (focusables.length) focusables[0].focus();
55787
+ }
55788
+
55789
+ /**
55790
+ * Moves focus to the last focusable element within the container.
55791
+ * Useful for setting focus when deactivating or cycling focus in reverse.
55792
+ */
55793
+ focusLastElement() {
55794
+ const focusables = this._getFocusableElements();
55795
+ if (focusables.length) focusables[focusables.length - 1].focus();
55796
+ }
55797
+
55798
+ /**
55799
+ * Removes event listeners and attributes added by the focus trap.
55800
+ * Call this method to clean up when the focus trap is no longer needed.
55801
+ */
55802
+ disconnect() {
55803
+ if (this.container.hasAttribute("data-focus-trap-container")) {
55804
+ this.container.removeAttribute("data-focus-trap-container");
55805
+ }
55806
+
55807
+ this.container.removeEventListener("keydown", this._onKeydown);
55808
+ }
55809
+ };
55810
+
55485
55811
  // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
55486
55812
  // See LICENSE in the project root for license information.
55487
55813
 
@@ -55979,7 +56305,7 @@ let AuroDropdownBib$2 = class AuroDropdownBib extends i$3 {
55979
56305
  classes[`shape-${this.shape}`] = true;
55980
56306
 
55981
56307
  return u$c`
55982
- <dialog tabindex="-1" class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
56308
+ <dialog class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
55983
56309
  ${this.dialogLabel ? u$c`<span id="dialogLabel" class="util_displayHiddenVisually">${this.dialogLabel}</span>` : ''}
55984
56310
  <slot></slot>
55985
56311
  <span id="srAnnouncement" class="util_displayHiddenVisually" aria-live="polite" role="status"></span>
@@ -56230,7 +56556,7 @@ let AuroHelpText$6 = class AuroHelpText extends i$3 {
56230
56556
  }
56231
56557
  };
56232
56558
 
56233
- var formkitVersion$6 = '202607100029';
56559
+ var formkitVersion$6 = '202607092329';
56234
56560
 
56235
56561
  let AuroElement$1$2 = class AuroElement extends i$3 {
56236
56562
  static get properties() {
@@ -56984,10 +57310,7 @@ let AuroDropdown$2 = class AuroDropdown extends AuroElement$1$2 {
56984
57310
  }
56985
57311
 
56986
57312
 
56987
- // On Tab-driven close (eventType "focusloss"), let focus advance naturally
56988
- // — restoring to the trigger would trap the user on this dropdown, forcing
56989
- // an extra Tab to move on. Escape and outside-click still restore.
56990
- if (!this.isPopoverVisible && eventType !== "focusloss") {
57313
+ if (!this.isPopoverVisible) {
56991
57314
  // wait til the bib gets fully closed and rendered
56992
57315
  setTimeout(() => {
56993
57316
  // Skip if the bib re-opened, or if focus moved intentionally outside the dropdown (not to body).
@@ -57217,16 +57540,15 @@ let AuroDropdown$2 = class AuroDropdown extends AuroElement$1$2 {
57217
57540
  }
57218
57541
  });
57219
57542
  } else {
57220
- // Normal desktop (non-modal): move initial focus into the bib but
57221
- // don't trap Tab. Tab should exit the bib and let the floater's
57222
- // handleFocusLoss close it, matching native <select>/<details>
57223
- // behavior. Deferred one frame because Floating UI positions the
57224
- // popover asynchronously a synchronous focus() would target
57225
- // zero-dimension elements and be silently ignored.
57543
+ // Normal desktop: use FocusTrap on the bib element.
57544
+ // Defer focusFirstElement to the next frame because the popover
57545
+ // is positioned asynchronously by Floating UI — calling focus()
57546
+ // synchronously here would target elements with zero dimensions
57547
+ // and the focus call would be silently ignored.
57548
+ this.focusTrap = new FocusTrap$2(this.bibContent);
57226
57549
  requestAnimationFrame(() => {
57227
- const focusables = getFocusableElements$3(this.bibContent);
57228
- if (focusables.length) {
57229
- focusables[0].focus();
57550
+ if (this.focusTrap) {
57551
+ this.focusTrap.focusFirstElement();
57230
57552
  }
57231
57553
  });
57232
57554
  }
@@ -60214,7 +60536,7 @@ let AuroHelpText$5 = class AuroHelpText extends i$3 {
60214
60536
  }
60215
60537
  };
60216
60538
 
60217
- var formkitVersion$5 = '202607100029';
60539
+ var formkitVersion$5 = '202607092329';
60218
60540
 
60219
60541
  // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
60220
60542
  // See LICENSE in the project root for license information.
@@ -61979,7 +62301,7 @@ let AuroHelpText$4 = class AuroHelpText extends i$3 {
61979
62301
  }
61980
62302
  };
61981
62303
 
61982
- var formkitVersion$4 = '202607100029';
62304
+ var formkitVersion$4 = '202607092329';
61983
62305
 
61984
62306
  // Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
61985
62307
  // See LICENSE in the project root for license information.
@@ -65841,40 +66163,12 @@ let AuroFloatingUI$1 = class AuroFloatingUI {
65841
66163
  return;
65842
66164
  }
65843
66165
 
65844
- // Chrome-specific: during popover top-layer promotion after a click on a
65845
- // slotted focusable, :focus-within can briefly evaluate false while the
65846
- // active element is still structurally inside the trigger/bib. Fall back
65847
- // to a shadow-piercing ancestry walk from the deep active element before
65848
- // treating this as a real focus loss.
65849
- try {
65850
- let active = document.activeElement;
65851
- while (active && active.shadowRoot && active.shadowRoot.activeElement) {
65852
- active = active.shadowRoot.activeElement;
65853
- }
65854
- const targets = [element, element.trigger, element.bib].filter(Boolean);
65855
- let node = active;
65856
- while (node) {
65857
- if (targets.includes(node)) {
65858
- return;
65859
- }
65860
- node =
65861
- node.parentElement ||
65862
- (node.getRootNode && node.getRootNode().host) ||
65863
- null;
65864
- }
65865
- } catch (e) {
65866
- // Defensive: fall through to the existing close path if traversal fails.
65867
- }
65868
-
65869
66166
  // if fullscreen bib is in fullscreen mode, do not close
65870
66167
  if (element.bib.hasAttribute("isfullscreen")) {
65871
66168
  return;
65872
66169
  }
65873
66170
 
65874
- // eventType "focusloss" distinguishes a Tab/click-driven close from an
65875
- // Escape keydown close. Consumers use this to decide whether to restore
65876
- // focus to the trigger (Escape) or let it advance naturally (Tab).
65877
- this.hideBib("focusloss");
66171
+ this.hideBib("keydown");
65878
66172
  }
65879
66173
 
65880
66174
  setupHideHandlers() {
@@ -66544,6 +66838,199 @@ function getFocusableElements$2(container) {
66544
66838
  return tabIndexedUniqueElements;
66545
66839
  }
66546
66840
 
66841
+ /**
66842
+ * FocusTrap manages keyboard focus within a specified container element, ensuring that focus does not leave the container when tabbing.
66843
+ * It is commonly used for modal dialogs or overlays to improve accessibility by trapping focus within interactive UI components.
66844
+ */
66845
+ let FocusTrap$1 = class FocusTrap {
66846
+ /**
66847
+ * Creates a new FocusTrap instance for the given container element.
66848
+ * Initializes event listeners and prepares the container for focus management.
66849
+ *
66850
+ * @param {HTMLElement} container The DOM element to trap focus within.
66851
+ * @param {boolean} [controlTabOrder=false] If true enables manual control of the tab order by the FocusTrap.
66852
+ * @throws {Error} If the provided container is not a valid HTMLElement.
66853
+ */
66854
+ constructor(container, controlTabOrder = false) {
66855
+ if (!container || !(container instanceof HTMLElement)) {
66856
+ throw new Error("FocusTrap requires a valid HTMLElement.");
66857
+ }
66858
+
66859
+ this.container = container;
66860
+ this.tabDirection = "forward"; // or 'backward';
66861
+ this.controlTabOrder = controlTabOrder;
66862
+
66863
+ this._init();
66864
+ }
66865
+
66866
+ /**
66867
+ * Initializes the focus trap by setting up event listeners and attributes on the container.
66868
+ * Prepares the container for focus management, including support for shadow DOM and inert attributes.
66869
+ *
66870
+ * @private
66871
+ */
66872
+ _init() {
66873
+ // Add inert attribute to prevent focusing programmatically as well (if supported)
66874
+ if ("inert" in HTMLElement.prototype) {
66875
+ this.container.inert = false; // Ensure the container isn't inert
66876
+ this.container.setAttribute("data-focus-trap-container", true); // Mark for identification
66877
+ }
66878
+
66879
+ // Track tab direction
66880
+ this.container.addEventListener("keydown", this._onKeydown);
66881
+ }
66882
+
66883
+ /**
66884
+ * Gets an array of currently active (focused) elements in the document and shadow DOM.
66885
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
66886
+ * @private
66887
+ */
66888
+ _getActiveElements() {
66889
+ // Get the active element(s) in the document and shadow root
66890
+ // This will include the active element in the shadow DOM if it exists
66891
+ // Active element may be inside the shadow DOM depending on delegatesFocus, so we need to check both
66892
+ let { activeElement } = document;
66893
+ const actives = [activeElement];
66894
+ while (activeElement?.shadowRoot?.activeElement) {
66895
+ actives.push(activeElement.shadowRoot.activeElement);
66896
+ activeElement = activeElement.shadowRoot.activeElement;
66897
+ }
66898
+ return actives;
66899
+ }
66900
+
66901
+ /**
66902
+ * Gets the next focus index based on the current index and focusable elements.
66903
+ * @param {number} currentIndex The current index of the focused element.
66904
+ * @param {Array<HTMLElement>} focusables The array of focusable elements.
66905
+ * @returns {number|null} The next focus index or null if not determined.
66906
+ */
66907
+ _getNextFocusIndex(currentIndex, focusables, actives) {
66908
+ if (this.controlTabOrder) {
66909
+ // Calculate the new index based on the current index and tab direction
66910
+ let newFocusIndex =
66911
+ currentIndex + (this.tabDirection === "forward" ? 1 : -1);
66912
+
66913
+ // Wrap-around logic
66914
+ if (newFocusIndex < 0) newFocusIndex = focusables.length - 1;
66915
+ if (newFocusIndex >= focusables.length) newFocusIndex = 0;
66916
+
66917
+ // Early return with the new index
66918
+ return newFocusIndex;
66919
+ }
66920
+
66921
+ // Determine if we need to wrap
66922
+ const atFirst =
66923
+ actives.includes(focusables[0]) || actives.includes(this.container);
66924
+ const atLast = actives.includes(focusables[focusables.length - 1]);
66925
+
66926
+ // Only wrap if at the ends
66927
+ if (this.tabDirection === "backward" && atFirst) {
66928
+ return focusables.length - 1;
66929
+ }
66930
+
66931
+ if (this.tabDirection === "forward" && atLast) {
66932
+ return 0;
66933
+ }
66934
+
66935
+ // No wrap, so don't change focus, return early
66936
+ return null;
66937
+ }
66938
+
66939
+ /**
66940
+ * Handles the Tab key press event to manage focus within the container.
66941
+ * @param {KeyboardEvent} e The keyboard event triggered by the user.
66942
+ * @returns {void}
66943
+ */
66944
+ _handleTabKey(e) {
66945
+ // Update the focusable elements
66946
+ const focusables = this._getFocusableElements();
66947
+
66948
+ // If there are no focusable elements, exit
66949
+ if (!focusables.length) return;
66950
+
66951
+ // Set the tab direction based on the key pressed
66952
+ this.tabDirection = e.shiftKey ? "backward" : "forward";
66953
+
66954
+ // Get the active elements that are currently focused
66955
+ const actives = this._getActiveElements();
66956
+
66957
+ // If we're at either end of the focusable elements, wrap around to the other end
66958
+ let focusIndex = focusables.findIndex((el) => actives.includes(el));
66959
+
66960
+ // Fallback if we have no focused element
66961
+ if (focusIndex === -1) focusIndex = 0;
66962
+
66963
+ // Get the next focus index based on the current focus index, tab direction, and controlTabOrder setting
66964
+ // Is null if no new focus index is determined
66965
+ const newFocusIndex = this._getNextFocusIndex(
66966
+ focusIndex,
66967
+ focusables,
66968
+ actives,
66969
+ );
66970
+
66971
+ // If we have a new focus index, set focus to that element
66972
+ if (newFocusIndex !== null) {
66973
+ e.preventDefault();
66974
+ focusables[newFocusIndex].focus();
66975
+ }
66976
+ }
66977
+
66978
+ /**
66979
+ * Catches the keydown event
66980
+ * @param {KeyboardEvent} e The keyboard event triggered by user interaction.
66981
+ * @private
66982
+ */
66983
+ _onKeydown = (e) => {
66984
+ // Handle tab
66985
+ if (e.key === "Tab") this._handleTabKey(e);
66986
+ };
66987
+
66988
+ /**
66989
+ * Retrieves all focusable elements within the container in DOM order, including those in shadow DOM and slots.
66990
+ * Returns a unique, ordered array of elements that can receive focus.
66991
+ *
66992
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
66993
+ * @private
66994
+ */
66995
+ _getFocusableElements() {
66996
+ // Use the imported utility function to get focusable elements
66997
+ const elements = getFocusableElements$2(this.container);
66998
+
66999
+ // Return the elements found
67000
+ return elements;
67001
+ }
67002
+
67003
+ /**
67004
+ * Moves focus to the first focusable element within the container.
67005
+ * Useful for setting initial focus when activating the focus trap.
67006
+ */
67007
+ focusFirstElement() {
67008
+ const focusables = this._getFocusableElements();
67009
+ if (focusables.length) focusables[0].focus();
67010
+ }
67011
+
67012
+ /**
67013
+ * Moves focus to the last focusable element within the container.
67014
+ * Useful for setting focus when deactivating or cycling focus in reverse.
67015
+ */
67016
+ focusLastElement() {
67017
+ const focusables = this._getFocusableElements();
67018
+ if (focusables.length) focusables[focusables.length - 1].focus();
67019
+ }
67020
+
67021
+ /**
67022
+ * Removes event listeners and attributes added by the focus trap.
67023
+ * Call this method to clean up when the focus trap is no longer needed.
67024
+ */
67025
+ disconnect() {
67026
+ if (this.container.hasAttribute("data-focus-trap-container")) {
67027
+ this.container.removeAttribute("data-focus-trap-container");
67028
+ }
67029
+
67030
+ this.container.removeEventListener("keydown", this._onKeydown);
67031
+ }
67032
+ };
67033
+
66547
67034
  // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
66548
67035
  // See LICENSE in the project root for license information.
66549
67036
 
@@ -67041,7 +67528,7 @@ let AuroDropdownBib$1 = class AuroDropdownBib extends i$3 {
67041
67528
  classes[`shape-${this.shape}`] = true;
67042
67529
 
67043
67530
  return u$c`
67044
- <dialog tabindex="-1" class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
67531
+ <dialog class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
67045
67532
  ${this.dialogLabel ? u$c`<span id="dialogLabel" class="util_displayHiddenVisually">${this.dialogLabel}</span>` : ''}
67046
67533
  <slot></slot>
67047
67534
  <span id="srAnnouncement" class="util_displayHiddenVisually" aria-live="polite" role="status"></span>
@@ -67292,7 +67779,7 @@ let AuroHelpText$2 = class AuroHelpText extends i$3 {
67292
67779
  }
67293
67780
  };
67294
67781
 
67295
- var formkitVersion$2 = '202607100029';
67782
+ var formkitVersion$2 = '202607092329';
67296
67783
 
67297
67784
  let AuroElement$2$1 = class AuroElement extends i$3 {
67298
67785
  static get properties() {
@@ -68046,10 +68533,7 @@ let AuroDropdown$1 = class AuroDropdown extends AuroElement$2$1 {
68046
68533
  }
68047
68534
 
68048
68535
 
68049
- // On Tab-driven close (eventType "focusloss"), let focus advance naturally
68050
- // — restoring to the trigger would trap the user on this dropdown, forcing
68051
- // an extra Tab to move on. Escape and outside-click still restore.
68052
- if (!this.isPopoverVisible && eventType !== "focusloss") {
68536
+ if (!this.isPopoverVisible) {
68053
68537
  // wait til the bib gets fully closed and rendered
68054
68538
  setTimeout(() => {
68055
68539
  // Skip if the bib re-opened, or if focus moved intentionally outside the dropdown (not to body).
@@ -68279,16 +68763,15 @@ let AuroDropdown$1 = class AuroDropdown extends AuroElement$2$1 {
68279
68763
  }
68280
68764
  });
68281
68765
  } else {
68282
- // Normal desktop (non-modal): move initial focus into the bib but
68283
- // don't trap Tab. Tab should exit the bib and let the floater's
68284
- // handleFocusLoss close it, matching native <select>/<details>
68285
- // behavior. Deferred one frame because Floating UI positions the
68286
- // popover asynchronously a synchronous focus() would target
68287
- // zero-dimension elements and be silently ignored.
68766
+ // Normal desktop: use FocusTrap on the bib element.
68767
+ // Defer focusFirstElement to the next frame because the popover
68768
+ // is positioned asynchronously by Floating UI — calling focus()
68769
+ // synchronously here would target elements with zero dimensions
68770
+ // and the focus call would be silently ignored.
68771
+ this.focusTrap = new FocusTrap$1(this.bibContent);
68288
68772
  requestAnimationFrame(() => {
68289
- const focusables = getFocusableElements$2(this.bibContent);
68290
- if (focusables.length) {
68291
- focusables[0].focus();
68773
+ if (this.focusTrap) {
68774
+ this.focusTrap.focusFirstElement();
68292
68775
  }
68293
68776
  });
68294
68777
  }
@@ -80914,7 +81397,7 @@ let AuroHelpText$1$1 = class AuroHelpText extends i$3 {
80914
81397
  }
80915
81398
  };
80916
81399
 
80917
- var formkitVersion$1$1 = '202607100029';
81400
+ var formkitVersion$1$1 = '202607092329';
80918
81401
 
80919
81402
  // Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
80920
81403
  // See LICENSE in the project root for license information.
@@ -82035,7 +82518,7 @@ let AuroBibtemplate$1 = class AuroBibtemplate extends i$3 {
82035
82518
  }
82036
82519
  };
82037
82520
 
82038
- var formkitVersion$3 = '202607100029';
82521
+ var formkitVersion$3 = '202607092329';
82039
82522
 
82040
82523
  var styleCss$1$3 = i$6`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host{display:block;text-align:left}:host [auro-dropdown]{--ds-auro-dropdown-trigger-background-color: transparent}:host #inputInBib::part(wrapper){box-shadow:none}:host #inputInBib::part(accent-left){display:none}:host([layout*=classic]) [auro-input]{width:100%}:host([layout*=classic]) [auro-input]::part(helpText){display:none}:host([layout*=classic]) #slotHolder{display:none}`;
82041
82524
 
@@ -89405,40 +89888,12 @@ class AuroFloatingUI {
89405
89888
  return;
89406
89889
  }
89407
89890
 
89408
- // Chrome-specific: during popover top-layer promotion after a click on a
89409
- // slotted focusable, :focus-within can briefly evaluate false while the
89410
- // active element is still structurally inside the trigger/bib. Fall back
89411
- // to a shadow-piercing ancestry walk from the deep active element before
89412
- // treating this as a real focus loss.
89413
- try {
89414
- let active = document.activeElement;
89415
- while (active && active.shadowRoot && active.shadowRoot.activeElement) {
89416
- active = active.shadowRoot.activeElement;
89417
- }
89418
- const targets = [element, element.trigger, element.bib].filter(Boolean);
89419
- let node = active;
89420
- while (node) {
89421
- if (targets.includes(node)) {
89422
- return;
89423
- }
89424
- node =
89425
- node.parentElement ||
89426
- (node.getRootNode && node.getRootNode().host) ||
89427
- null;
89428
- }
89429
- } catch (e) {
89430
- // Defensive: fall through to the existing close path if traversal fails.
89431
- }
89432
-
89433
89891
  // if fullscreen bib is in fullscreen mode, do not close
89434
89892
  if (element.bib.hasAttribute("isfullscreen")) {
89435
89893
  return;
89436
89894
  }
89437
89895
 
89438
- // eventType "focusloss" distinguishes a Tab/click-driven close from an
89439
- // Escape keydown close. Consumers use this to decide whether to restore
89440
- // focus to the trigger (Escape) or let it advance naturally (Tab).
89441
- this.hideBib("focusloss");
89896
+ this.hideBib("keydown");
89442
89897
  }
89443
89898
 
89444
89899
  setupHideHandlers() {
@@ -90108,6 +90563,199 @@ function getFocusableElements(container) {
90108
90563
  return tabIndexedUniqueElements;
90109
90564
  }
90110
90565
 
90566
+ /**
90567
+ * FocusTrap manages keyboard focus within a specified container element, ensuring that focus does not leave the container when tabbing.
90568
+ * It is commonly used for modal dialogs or overlays to improve accessibility by trapping focus within interactive UI components.
90569
+ */
90570
+ class FocusTrap {
90571
+ /**
90572
+ * Creates a new FocusTrap instance for the given container element.
90573
+ * Initializes event listeners and prepares the container for focus management.
90574
+ *
90575
+ * @param {HTMLElement} container The DOM element to trap focus within.
90576
+ * @param {boolean} [controlTabOrder=false] If true enables manual control of the tab order by the FocusTrap.
90577
+ * @throws {Error} If the provided container is not a valid HTMLElement.
90578
+ */
90579
+ constructor(container, controlTabOrder = false) {
90580
+ if (!container || !(container instanceof HTMLElement)) {
90581
+ throw new Error("FocusTrap requires a valid HTMLElement.");
90582
+ }
90583
+
90584
+ this.container = container;
90585
+ this.tabDirection = "forward"; // or 'backward';
90586
+ this.controlTabOrder = controlTabOrder;
90587
+
90588
+ this._init();
90589
+ }
90590
+
90591
+ /**
90592
+ * Initializes the focus trap by setting up event listeners and attributes on the container.
90593
+ * Prepares the container for focus management, including support for shadow DOM and inert attributes.
90594
+ *
90595
+ * @private
90596
+ */
90597
+ _init() {
90598
+ // Add inert attribute to prevent focusing programmatically as well (if supported)
90599
+ if ("inert" in HTMLElement.prototype) {
90600
+ this.container.inert = false; // Ensure the container isn't inert
90601
+ this.container.setAttribute("data-focus-trap-container", true); // Mark for identification
90602
+ }
90603
+
90604
+ // Track tab direction
90605
+ this.container.addEventListener("keydown", this._onKeydown);
90606
+ }
90607
+
90608
+ /**
90609
+ * Gets an array of currently active (focused) elements in the document and shadow DOM.
90610
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
90611
+ * @private
90612
+ */
90613
+ _getActiveElements() {
90614
+ // Get the active element(s) in the document and shadow root
90615
+ // This will include the active element in the shadow DOM if it exists
90616
+ // Active element may be inside the shadow DOM depending on delegatesFocus, so we need to check both
90617
+ let { activeElement } = document;
90618
+ const actives = [activeElement];
90619
+ while (activeElement?.shadowRoot?.activeElement) {
90620
+ actives.push(activeElement.shadowRoot.activeElement);
90621
+ activeElement = activeElement.shadowRoot.activeElement;
90622
+ }
90623
+ return actives;
90624
+ }
90625
+
90626
+ /**
90627
+ * Gets the next focus index based on the current index and focusable elements.
90628
+ * @param {number} currentIndex The current index of the focused element.
90629
+ * @param {Array<HTMLElement>} focusables The array of focusable elements.
90630
+ * @returns {number|null} The next focus index or null if not determined.
90631
+ */
90632
+ _getNextFocusIndex(currentIndex, focusables, actives) {
90633
+ if (this.controlTabOrder) {
90634
+ // Calculate the new index based on the current index and tab direction
90635
+ let newFocusIndex =
90636
+ currentIndex + (this.tabDirection === "forward" ? 1 : -1);
90637
+
90638
+ // Wrap-around logic
90639
+ if (newFocusIndex < 0) newFocusIndex = focusables.length - 1;
90640
+ if (newFocusIndex >= focusables.length) newFocusIndex = 0;
90641
+
90642
+ // Early return with the new index
90643
+ return newFocusIndex;
90644
+ }
90645
+
90646
+ // Determine if we need to wrap
90647
+ const atFirst =
90648
+ actives.includes(focusables[0]) || actives.includes(this.container);
90649
+ const atLast = actives.includes(focusables[focusables.length - 1]);
90650
+
90651
+ // Only wrap if at the ends
90652
+ if (this.tabDirection === "backward" && atFirst) {
90653
+ return focusables.length - 1;
90654
+ }
90655
+
90656
+ if (this.tabDirection === "forward" && atLast) {
90657
+ return 0;
90658
+ }
90659
+
90660
+ // No wrap, so don't change focus, return early
90661
+ return null;
90662
+ }
90663
+
90664
+ /**
90665
+ * Handles the Tab key press event to manage focus within the container.
90666
+ * @param {KeyboardEvent} e The keyboard event triggered by the user.
90667
+ * @returns {void}
90668
+ */
90669
+ _handleTabKey(e) {
90670
+ // Update the focusable elements
90671
+ const focusables = this._getFocusableElements();
90672
+
90673
+ // If there are no focusable elements, exit
90674
+ if (!focusables.length) return;
90675
+
90676
+ // Set the tab direction based on the key pressed
90677
+ this.tabDirection = e.shiftKey ? "backward" : "forward";
90678
+
90679
+ // Get the active elements that are currently focused
90680
+ const actives = this._getActiveElements();
90681
+
90682
+ // If we're at either end of the focusable elements, wrap around to the other end
90683
+ let focusIndex = focusables.findIndex((el) => actives.includes(el));
90684
+
90685
+ // Fallback if we have no focused element
90686
+ if (focusIndex === -1) focusIndex = 0;
90687
+
90688
+ // Get the next focus index based on the current focus index, tab direction, and controlTabOrder setting
90689
+ // Is null if no new focus index is determined
90690
+ const newFocusIndex = this._getNextFocusIndex(
90691
+ focusIndex,
90692
+ focusables,
90693
+ actives,
90694
+ );
90695
+
90696
+ // If we have a new focus index, set focus to that element
90697
+ if (newFocusIndex !== null) {
90698
+ e.preventDefault();
90699
+ focusables[newFocusIndex].focus();
90700
+ }
90701
+ }
90702
+
90703
+ /**
90704
+ * Catches the keydown event
90705
+ * @param {KeyboardEvent} e The keyboard event triggered by user interaction.
90706
+ * @private
90707
+ */
90708
+ _onKeydown = (e) => {
90709
+ // Handle tab
90710
+ if (e.key === "Tab") this._handleTabKey(e);
90711
+ };
90712
+
90713
+ /**
90714
+ * Retrieves all focusable elements within the container in DOM order, including those in shadow DOM and slots.
90715
+ * Returns a unique, ordered array of elements that can receive focus.
90716
+ *
90717
+ * @returns {Array<HTMLElement>} An array of focusable elements within the container.
90718
+ * @private
90719
+ */
90720
+ _getFocusableElements() {
90721
+ // Use the imported utility function to get focusable elements
90722
+ const elements = getFocusableElements(this.container);
90723
+
90724
+ // Return the elements found
90725
+ return elements;
90726
+ }
90727
+
90728
+ /**
90729
+ * Moves focus to the first focusable element within the container.
90730
+ * Useful for setting initial focus when activating the focus trap.
90731
+ */
90732
+ focusFirstElement() {
90733
+ const focusables = this._getFocusableElements();
90734
+ if (focusables.length) focusables[0].focus();
90735
+ }
90736
+
90737
+ /**
90738
+ * Moves focus to the last focusable element within the container.
90739
+ * Useful for setting focus when deactivating or cycling focus in reverse.
90740
+ */
90741
+ focusLastElement() {
90742
+ const focusables = this._getFocusableElements();
90743
+ if (focusables.length) focusables[focusables.length - 1].focus();
90744
+ }
90745
+
90746
+ /**
90747
+ * Removes event listeners and attributes added by the focus trap.
90748
+ * Call this method to clean up when the focus trap is no longer needed.
90749
+ */
90750
+ disconnect() {
90751
+ if (this.container.hasAttribute("data-focus-trap-container")) {
90752
+ this.container.removeAttribute("data-focus-trap-container");
90753
+ }
90754
+
90755
+ this.container.removeEventListener("keydown", this._onKeydown);
90756
+ }
90757
+ }
90758
+
90111
90759
  // Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
90112
90760
  // See LICENSE in the project root for license information.
90113
90761
 
@@ -90605,7 +91253,7 @@ class AuroDropdownBib extends i$3 {
90605
91253
  classes[`shape-${this.shape}`] = true;
90606
91254
 
90607
91255
  return u$c`
90608
- <dialog tabindex="-1" class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
91256
+ <dialog class="${e$2(classes)}" part="bibContainer" role="${o$4(this.dialogRole)}" aria-labelledby="${o$4(this.dialogLabel ? 'dialogLabel' : undefined)}">
90609
91257
  ${this.dialogLabel ? u$c`<span id="dialogLabel" class="util_displayHiddenVisually">${this.dialogLabel}</span>` : ''}
90610
91258
  <slot></slot>
90611
91259
  <span id="srAnnouncement" class="util_displayHiddenVisually" aria-live="polite" role="status"></span>
@@ -90856,7 +91504,7 @@ let AuroHelpText$1 = class AuroHelpText extends i$3 {
90856
91504
  }
90857
91505
  };
90858
91506
 
90859
- var formkitVersion$1 = '202607100029';
91507
+ var formkitVersion$1 = '202607092329';
90860
91508
 
90861
91509
  class AuroElement extends i$3 {
90862
91510
  static get properties() {
@@ -91610,10 +92258,7 @@ class AuroDropdown extends AuroElement {
91610
92258
  }
91611
92259
 
91612
92260
 
91613
- // On Tab-driven close (eventType "focusloss"), let focus advance naturally
91614
- // — restoring to the trigger would trap the user on this dropdown, forcing
91615
- // an extra Tab to move on. Escape and outside-click still restore.
91616
- if (!this.isPopoverVisible && eventType !== "focusloss") {
92261
+ if (!this.isPopoverVisible) {
91617
92262
  // wait til the bib gets fully closed and rendered
91618
92263
  setTimeout(() => {
91619
92264
  // Skip if the bib re-opened, or if focus moved intentionally outside the dropdown (not to body).
@@ -91843,16 +92488,15 @@ class AuroDropdown extends AuroElement {
91843
92488
  }
91844
92489
  });
91845
92490
  } else {
91846
- // Normal desktop (non-modal): move initial focus into the bib but
91847
- // don't trap Tab. Tab should exit the bib and let the floater's
91848
- // handleFocusLoss close it, matching native <select>/<details>
91849
- // behavior. Deferred one frame because Floating UI positions the
91850
- // popover asynchronously a synchronous focus() would target
91851
- // zero-dimension elements and be silently ignored.
92491
+ // Normal desktop: use FocusTrap on the bib element.
92492
+ // Defer focusFirstElement to the next frame because the popover
92493
+ // is positioned asynchronously by Floating UI — calling focus()
92494
+ // synchronously here would target elements with zero dimensions
92495
+ // and the focus call would be silently ignored.
92496
+ this.focusTrap = new FocusTrap(this.bibContent);
91852
92497
  requestAnimationFrame(() => {
91853
- const focusables = getFocusableElements(this.bibContent);
91854
- if (focusables.length) {
91855
- focusables[0].focus();
92498
+ if (this.focusTrap) {
92499
+ this.focusTrap.focusFirstElement();
91856
92500
  }
91857
92501
  });
91858
92502
  }
@@ -92899,7 +93543,7 @@ class AuroHelpText extends i$3 {
92899
93543
  }
92900
93544
  }
92901
93545
 
92902
- var formkitVersion = '202607100029';
93546
+ var formkitVersion = '202607092329';
92903
93547
 
92904
93548
  var styleCss = i$6`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.body-default{font-size:var(--wcss-body-default-font-size, 1rem);font-weight:var(--wcss-body-default-weight, );line-height:var(--wcss-body-default-line-height, 1.5rem)}.body-default,.body-default-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-default-emphasized{font-size:var(--wcss-body-default-emphasized-font-size, 1rem);font-weight:var(--wcss-body-default-emphasized-weight, );line-height:var(--wcss-body-default-emphasized-line-height, 1.5rem)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);font-weight:var(--wcss-body-lg-weight, );line-height:var(--wcss-body-lg-line-height, 1.625rem)}.body-lg,.body-lg-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg-emphasized{font-size:var(--wcss-body-lg-emphasized-font-size, 1.125rem);font-weight:var(--wcss-body-lg-emphasized-weight, );line-height:var(--wcss-body-lg-emphasized-line-height, 1.625rem)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);font-weight:var(--wcss-body-sm-weight, );line-height:var(--wcss-body-sm-line-height, 1.25rem)}.body-sm,.body-sm-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-sm-emphasized{font-size:var(--wcss-body-sm-emphasized-font-size, 0.875rem);font-weight:var(--wcss-body-sm-emphasized-weight, );line-height:var(--wcss-body-sm-emphasized-line-height, 1.25rem)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);font-weight:var(--wcss-body-xs-weight, );line-height:var(--wcss-body-xs-line-height, 1rem)}.body-xs,.body-xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs-emphasized{font-size:var(--wcss-body-xs-emphasized-font-size, 0.75rem);font-weight:var(--wcss-body-xs-emphasized-weight, );line-height:var(--wcss-body-xs-emphasized-line-height, 1rem)}.body-2xs{font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-2xs-weight, );line-height:var(--wcss-body-2xs-line-height, 0.875rem)}.body-2xs,.body-2xs-emphasized{font-family:var(--wcss-body-family, "AS Circular"),system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-2xs-emphasized{font-size:var(--wcss-body-2xs-emphasized-font-size, 0.625rem);font-weight:var(--wcss-body-2xs-emphasized-weight, );line-height:var(--wcss-body-2xs-emphasized-line-height, 0.875rem)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular"),var(--wcss-display-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular"),var(--wcss-display-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular"),var(--wcss-display-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular"),var(--wcss-display-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular"),var(--wcss-display-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular"),var(--wcss-display-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular"),var(--wcss-heading-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular"),var(--wcss-heading-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular"),var(--wcss-heading-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular"),var(--wcss-heading-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular"),var(--wcss-heading-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 300);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular"),var(--wcss-heading-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 300);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT"),var(--wcss-accent-2xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT"),var(--wcss-accent-xl-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT"),var(--wcss-accent-lg-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT"),var(--wcss-accent-md-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT"),var(--wcss-accent-sm-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT"),var(--wcss-accent-xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT"),var(--wcss-accent-2xs-family-fallback, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}[auro-dropdown]{--ds-auro-dropdown-trigger-border-color: var(--ds-auro-select-border-color);--ds-auro-dropdown-trigger-background-color: var(--ds-auro-select-background-color);--ds-auro-dropdown-trigger-container-color: var(--ds-auro-select-background-color);--ds-auro-dropdown-trigger-outline-color: var(--ds-auro-select-outline-color)}:host{display:inline-block;text-align:left;vertical-align:top}:host([layout*=emphasized]) [auro-dropdown],:host([layout*=snowflake]) [auro-dropdown]{--ds-auro-select-border-color: transparent}:host([layout*=emphasized]) .mainContent,:host([layout*=snowflake]) .mainContent{text-align:center}.mainContent{position:relative;display:flex;overflow:hidden;flex:1;flex-direction:column;align-items:center;justify-content:center}.valueContainer [slot=displayValue]{display:none}.accents{display:flex;flex-direction:row;align-items:center;justify-content:center}::slotted([slot=typeIcon]){margin-right:var(--ds-size-100, 0.5rem)}.displayValue{display:block}.displayValue:not(.force){display:none}.displayValue:not(.force).hasContent:is(.withValue):not(.hasFocus){display:block}.triggerContent{display:flex;width:100%;align-items:center;justify-content:center}:host([layout*=emphasized]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem) 0 var(--ds-size-300, 1.5rem)}:host([layout*=snowflake]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem) 0 var(--ds-size-200, 1rem)}:host([layout*=snowflake]) label{padding-block:var(--ds-size-25, 0.125rem)}:host([layout*=classic]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem)}:host([layout*=classic]) .mainContent{align-items:start}:host([layout*=classic]) label{overflow:hidden;cursor:text;text-overflow:ellipsis;white-space:nowrap}:host([layout*=classic]) .value{height:auto}label{color:var(--ds-auro-select-label-text-color)}:host(:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-select-outline-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]:is([validity]:not([validity=valid]))) [auro-dropdown],:host([appearance=inverse]:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-advanced-color-state-error-inverse, #f9a4a8);--ds-auro-select-outline-color: var(--ds-advanced-color-state-error-inverse, #f9a4a8);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}#slotHolder{display:none}:host([fluid]){width:100%}:host([disabled]){pointer-events:none;user-select:none}:host([disabled]:not([ondark])) [auro-dropdown],:host([disabled]:not([appearance=inverse])) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-border-subtle, #dddddd)}:host(:not([layout*=classic])[disabled][ondark]) [auro-dropdown],:host(:not([layout*=classic])[disabled][appearance=inverse]) [auro-dropdown]{--ds-auro-select-border-color: transparent}`;
92905
93549