@aurodesignsystem-dev/auro-formkit 0.0.0-pr1408.14 → 0.0.0-pr1408.16

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 (54) hide show
  1. package/components/checkbox/demo/api.min.js +1 -1
  2. package/components/checkbox/demo/index.min.js +1 -1
  3. package/components/checkbox/demo/keyboardBehavior.md +0 -0
  4. package/components/checkbox/dist/index.js +1 -1
  5. package/components/checkbox/dist/registered.js +1 -1
  6. package/components/combobox/demo/api.min.js +139 -142
  7. package/components/combobox/demo/index.min.js +139 -142
  8. package/components/combobox/demo/keyboardBehavior.md +1 -2
  9. package/components/combobox/dist/index.js +105 -115
  10. package/components/combobox/dist/registered.js +105 -115
  11. package/components/counter/demo/api.md +1 -1
  12. package/components/counter/demo/api.min.js +202 -146
  13. package/components/counter/demo/index.min.js +202 -146
  14. package/components/counter/dist/auro-counter.d.ts +11 -8
  15. package/components/counter/dist/index.js +202 -146
  16. package/components/counter/dist/keyboardStrategy.d.ts +4 -0
  17. package/components/counter/dist/registered.js +202 -146
  18. package/components/datepicker/demo/api.min.js +107 -118
  19. package/components/datepicker/demo/index.min.js +107 -118
  20. package/components/datepicker/dist/index.js +102 -113
  21. package/components/datepicker/dist/registered.js +102 -113
  22. package/components/dropdown/demo/api.md +29 -29
  23. package/components/dropdown/demo/api.min.js +117 -121
  24. package/components/dropdown/demo/index.min.js +117 -121
  25. package/components/dropdown/dist/auro-dropdown.d.ts +3 -3
  26. package/components/dropdown/dist/auro-dropdownBib.d.ts +1 -40
  27. package/components/dropdown/dist/dropdownBibKeyboardStrategy.d.ts +7 -0
  28. package/components/dropdown/dist/index.js +101 -109
  29. package/components/dropdown/dist/registered.js +101 -109
  30. package/components/form/demo/api.min.js +629 -544
  31. package/components/form/demo/index.min.js +629 -544
  32. package/components/form/demo/keyboardBehavior.md +0 -0
  33. package/components/input/demo/api.min.js +1 -1
  34. package/components/input/demo/index.min.js +1 -1
  35. package/components/input/demo/keyboardBehavior.md +0 -0
  36. package/components/input/dist/index.js +1 -1
  37. package/components/input/dist/registered.js +1 -1
  38. package/components/menu/demo/api.min.js +34 -27
  39. package/components/menu/demo/index.min.js +34 -27
  40. package/components/menu/dist/auro-menu.d.ts +0 -6
  41. package/components/menu/dist/index.js +34 -27
  42. package/components/menu/dist/registered.js +34 -27
  43. package/components/radio/demo/api.min.js +1 -1
  44. package/components/radio/demo/index.min.js +1 -1
  45. package/components/radio/dist/index.js +1 -1
  46. package/components/radio/dist/registered.js +1 -1
  47. package/components/select/demo/api.min.js +214 -164
  48. package/components/select/demo/index.min.js +214 -164
  49. package/components/select/demo/keyboardBehavior.md +3 -3
  50. package/components/select/dist/index.js +180 -137
  51. package/components/select/dist/registered.js +180 -137
  52. package/components/select/dist/selectKeyboardStrategy.d.ts +5 -2
  53. package/custom-elements.json +1518 -1481
  54. package/package.json +8 -6
@@ -1305,7 +1305,7 @@ function restoreTriggerAfterClose(dropdown, focusTarget) {
1305
1305
  * @returns {{isExpanded: boolean, isModal: boolean, isPopover: boolean, activeInput: HTMLElement|null}}
1306
1306
  * isModal and isPopover reflect the display mode (fullscreen vs not) regardless of expanded state.
1307
1307
  */
1308
- function createDisplayContext(component, options = {}) {
1308
+ function createDisplayContext$1(component, options = {}) {
1309
1309
  const dd = options.dropdown || component.dropdown;
1310
1310
  // isPopoverVisible reflects as the `open` attribute.
1311
1311
  // It reports whether the bib is open in any mode (popover or modal).
@@ -1335,11 +1335,11 @@ function createDisplayContext(component, options = {}) {
1335
1335
  * @param {Object} strategy - Map of key names to handler functions.
1336
1336
  * @param {Object} [options] - Optional config passed to createDisplayContext.
1337
1337
  */
1338
- function applyKeyboardStrategy(component, strategy, options = {}) {
1338
+ function applyKeyboardStrategy$1(component, strategy, options = {}) {
1339
1339
  component.addEventListener('keydown', async (evt) => {
1340
1340
  const handler = strategy[evt.key] || strategy.default;
1341
1341
  if (typeof handler === 'function') {
1342
- const ctx = createDisplayContext(component, options);
1342
+ const ctx = createDisplayContext$1(component, options);
1343
1343
  await handler(component, evt, ctx);
1344
1344
  }
1345
1345
  });
@@ -1363,9 +1363,16 @@ function navigateArrow(component, direction, options = {}) {
1363
1363
  }
1364
1364
  }
1365
1365
 
1366
+ /* eslint-disable new-cap */
1367
+
1366
1368
  const selectKeyboardStrategy = {
1367
1369
  ArrowUp(component, evt, ctx) {
1368
1370
  evt.preventDefault();
1371
+ if (evt.altKey || evt.metaKey) {
1372
+ // navigate to first enabled option
1373
+ selectKeyboardStrategy.Home(component, evt, ctx);
1374
+ return;
1375
+ }
1369
1376
  navigateArrow(component, 'up', {
1370
1377
  ctx,
1371
1378
  showFn: () => component.dropdown.show(),
@@ -1374,30 +1381,36 @@ const selectKeyboardStrategy = {
1374
1381
 
1375
1382
  ArrowDown(component, evt, ctx) {
1376
1383
  evt.preventDefault();
1384
+ if (evt.altKey || evt.metaKey) {
1385
+ // navigate to last enabled option
1386
+ selectKeyboardStrategy.End(component, evt, ctx);
1387
+ return;
1388
+ }
1377
1389
  navigateArrow(component, 'down', {
1378
1390
  ctx,
1379
1391
  showFn: () => component.dropdown.show(),
1380
1392
  });
1381
1393
  },
1382
1394
 
1383
- Enter(component, evt) {
1395
+ Enter(component, evt, ctx) {
1384
1396
  evt.preventDefault();
1397
+ evt.stopPropagation();
1398
+ if (!ctx.isExpanded) {
1399
+ component.dropdown.show();
1400
+ return;
1401
+ }
1385
1402
  component.menu.makeSelection();
1386
1403
  },
1387
1404
 
1388
- Tab(component, evt, ctx) {
1405
+ Escape(component, evt, ctx) {
1389
1406
  if (!ctx.isExpanded) {
1390
1407
  return;
1391
1408
  }
1409
+ component.dropdown.hide();
1410
+ },
1392
1411
 
1393
- // Shift+Tab moves the highlight to the first non-disabled option
1394
- // without making a selection or closing the bib.
1395
- if (evt.shiftKey) {
1396
- evt.preventDefault();
1397
- const firstActive = component.menu.menuService.menuOptions.find((option) => option.isActive);
1398
- if (firstActive) {
1399
- component.menu.updateActiveOption(firstActive);
1400
- }
1412
+ Tab(component, evt, ctx) {
1413
+ if (!ctx.isExpanded) {
1401
1414
  return;
1402
1415
  }
1403
1416
 
@@ -1408,9 +1421,41 @@ const selectKeyboardStrategy = {
1408
1421
  }
1409
1422
  component.dropdown.hide();
1410
1423
  },
1424
+ Home(component, evt, ctx) {
1425
+ if (!ctx.isExpanded) {
1426
+ return;
1427
+ }
1428
+ evt.preventDefault();
1429
+ evt.stopPropagation();
1430
+ const firstOption = component.menu.menuService.menuOptions.find((option) => !option.disabled);
1431
+ if (firstOption) {
1432
+ component.menu.updateActiveOption(firstOption);
1433
+ }
1434
+ },
1435
+
1436
+ End(component, evt, ctx) {
1437
+ if (!ctx.isExpanded) {
1438
+ return;
1439
+ }
1440
+ evt.preventDefault();
1441
+ evt.stopPropagation();
1442
+ const lastOption = [...component.menu.menuService.menuOptions].reverse().find((option) => !option.disabled);
1443
+ if (lastOption) {
1444
+ component.menu.updateActiveOption(lastOption);
1445
+ }
1446
+ },
1411
1447
 
1412
- default(component, evt) {
1448
+ default(component, evt, ctx) {
1413
1449
  component.updateActiveOptionBasedOnKey(evt.key);
1450
+ if (evt.key === ' ') {
1451
+ evt.preventDefault();
1452
+ evt.stopPropagation();
1453
+ if (ctx.isExpanded) {
1454
+ component.dropdown.hide();
1455
+ return;
1456
+ }
1457
+ component.dropdown.show();
1458
+ }
1414
1459
  },
1415
1460
  };
1416
1461
 
@@ -3267,6 +3312,11 @@ class AuroFloatingUI {
3267
3312
  this.clickHandler = null;
3268
3313
  this.keyDownHandler = null;
3269
3314
 
3315
+ /**
3316
+ * @private
3317
+ */
3318
+ this.enableKeyboardHandling = true;
3319
+
3270
3320
  /**
3271
3321
  * @private
3272
3322
  */
@@ -3527,11 +3577,10 @@ class AuroFloatingUI {
3527
3577
  return;
3528
3578
  }
3529
3579
 
3530
- const { activeElement } = document;
3531
3580
  // if focus is still inside of trigger or bib, do not close
3532
3581
  if (
3533
- this.element.contains(activeElement) ||
3534
- this.element.bib?.contains(activeElement)
3582
+ this.element.matches(":focus") ||
3583
+ this.element.matches(":focus-within")
3535
3584
  ) {
3536
3585
  return;
3537
3586
  }
@@ -3602,7 +3651,9 @@ class AuroFloatingUI {
3602
3651
  document.addEventListener("focusin", this.focusHandler);
3603
3652
  }
3604
3653
 
3605
- document.addEventListener("keydown", this.keyDownHandler);
3654
+ if (this.enableKeyboardHandling) {
3655
+ document.addEventListener("keydown", this.keyDownHandler);
3656
+ }
3606
3657
 
3607
3658
  // send this task to the end of queue to prevent conflicting
3608
3659
  // it conflicts if showBib gets call from a button that's not this.element.trigger
@@ -3858,8 +3909,9 @@ class AuroFloatingUI {
3858
3909
  this.element.bib.setAttribute("id", `${this.id}-floater-bib`);
3859
3910
  }
3860
3911
 
3861
- configure(elem, eventPrefix) {
3912
+ configure(elem, eventPrefix, enableKeyboardHandling = true) {
3862
3913
  AuroFloatingUI.setupMousePressChecker();
3914
+ this.enableKeyboardHandling = enableKeyboardHandling;
3863
3915
 
3864
3916
  this.eventPrefix = eventPrefix;
3865
3917
  if (this.element !== elem) {
@@ -3892,7 +3944,9 @@ class AuroFloatingUI {
3892
3944
 
3893
3945
  this.handleEvent = this.handleEvent.bind(this);
3894
3946
  if (this.element.trigger) {
3895
- this.element.trigger.addEventListener("keydown", this.handleEvent);
3947
+ if (this.enableKeyboardHandling) {
3948
+ this.element.trigger.addEventListener("keydown", this.handleEvent);
3949
+ }
3896
3950
  this.element.trigger.addEventListener("click", this.handleEvent);
3897
3951
  this.element.trigger.addEventListener("mouseenter", this.handleEvent);
3898
3952
  this.element.trigger.addEventListener("mouseleave", this.handleEvent);
@@ -4370,12 +4424,83 @@ let p$3 = class p{registerComponent(t,a){customElements.get(t)||customElements.d
4370
4424
 
4371
4425
  var iconVersion$2 = '9.1.2';
4372
4426
 
4427
+ /**
4428
+ * Computes display state once per keydown event.
4429
+ * Centralizes null-safety checks and makes the shared/modal/popover branching explicit.
4430
+ *
4431
+ * @param {HTMLElement} component - The component with a dropdown reference.
4432
+ * @param {Object} [options] - Optional config.
4433
+ * @param {HTMLElement} [options.dropdown] - Explicit dropdown reference. Falls back to component.dropdown.
4434
+ * @param {Function} [options.inputResolver] - Called with (component, ctx) to resolve the active input element.
4435
+ * @returns {{isExpanded: boolean, isModal: boolean, isPopover: boolean, activeInput: HTMLElement|null}}
4436
+ * isModal and isPopover reflect the display mode (fullscreen vs not) regardless of expanded state.
4437
+ */
4438
+ function createDisplayContext(component, options = {}) {
4439
+ const dd = options.dropdown || component.dropdown;
4440
+ // isPopoverVisible reflects as the `open` attribute.
4441
+ // It reports whether the bib is open in any mode (popover or modal).
4442
+ const isExpanded = Boolean(dd && dd.isPopoverVisible);
4443
+ const isFullscreen = Boolean(dd && dd.isBibFullscreen);
4444
+
4445
+ const ctx = {
4446
+ isExpanded,
4447
+ isModal: isFullscreen,
4448
+ isPopover: !isFullscreen,
4449
+ activeInput: null,
4450
+ };
4451
+
4452
+ if (options.inputResolver) {
4453
+ const resolvedInput = options.inputResolver(component, ctx);
4454
+ // Guard against resolvers returning undefined or non-HTMLElement values.
4455
+ ctx.activeInput = resolvedInput instanceof HTMLElement ? resolvedInput : null;
4456
+ }
4457
+
4458
+ return ctx;
4459
+ }
4460
+
4461
+ /**
4462
+ * Wires up a keydown listener that dispatches to strategy[evt.key] or strategy.default.
4463
+ * Handles both sync and async handlers.
4464
+ * @param {HTMLElement} component - The component to attach the listener to.
4465
+ * @param {Object} strategy - Map of key names to handler functions.
4466
+ * @param {Object} [options] - Optional config passed to createDisplayContext.
4467
+ */
4468
+ function applyKeyboardStrategy(component, strategy, options = {}) {
4469
+ component.addEventListener('keydown', async (evt) => {
4470
+ const handler = strategy[evt.key] || strategy.default;
4471
+ if (typeof handler === 'function') {
4472
+ const ctx = createDisplayContext(component, options);
4473
+ await handler(component, evt, ctx);
4474
+ }
4475
+ });
4476
+ }
4477
+
4373
4478
  var styleCss$2$1 = i$6`:host{position:fixed;z-index:var(--depth-tooltip, 400);display:none;isolation:isolate}:host dialog{width:auto;max-width:none;height:auto;max-height:none;padding:0;border:none;margin:0;outline:none;transform:translateZ(0)}:host dialog::backdrop{background:transparent}:host(:not([isfullscreen])) dialog{position:relative;inset:unset}:host(:not([isfullscreen])) .container.shape-box{border-radius:unset}:host(:not([isfullscreen])) .container[class*=shape-pill],:host(:not([isfullscreen])) .container[class*=shape-snowflake]{border-radius:30px}:host(:not([isfullscreen])) .container[class*=shape-rounded]{border-radius:16px}:host(:not([matchWidth])) .container{min-width:fit-content}:host([isfullscreen]){position:fixed;top:0;left:0}:host([isfullscreen]) .container{width:100dvw;max-width:none;height:100dvh;max-height:none;border-radius:unset;margin-top:0;box-shadow:unset;overscroll-behavior:contain}:host([isfullscreen]) .container::backdrop{background:var(--ds-color-background-primary, #fff)}:host(:popover-open){position:fixed;overflow:visible;padding:0;border:none;margin:0;background:transparent;inset:unset;outline:none}:host([data-show]){display:flex}:host([common]:not([isfullscreen])) .container,:host([rounded]:not([isfullscreen])) .container{border-radius:var(--ds-border-radius, 0.375rem)}:host([common][isfullscreen]) .container,:host([rounded][isfullscreen]) .container{border-radius:unset;box-shadow:unset}.container{display:inline-block;overflow:auto;box-sizing:border-box;border-radius:var(--ds-border-radius, 0.375rem);margin:var(--ds-size-50, 0.25rem) 0}.util_displayHiddenVisually{position:absolute;overflow:hidden;width:1px;height:1px;padding:0;border:0;margin:-1px;clip-path:inset(50%);white-space:nowrap}`;
4374
4479
 
4375
4480
  var colorCss$2$1 = i$6`.container{background-color:var(--ds-auro-dropdownbib-container-color);box-shadow:var(--ds-auro-dropdownbib-boxshadow-color);color:var(--ds-auro-dropdownbib-text-color)}`;
4376
4481
 
4377
4482
  var tokensCss$1$1 = i$6`:host(:not([ondark])),:host(:not([appearance=inverse])){--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-dropdown-trigger-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-hover-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-border-bold, #585e67);--ds-auro-dropdown-trigger-outline-color: transparent;--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-dropdownbib-boxshadow-color: var(--ds-elevation-200, 0px 0px 10px rgba(0, 0, 0, 0.15));--ds-auro-dropdownbib-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdownbib-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdownbib-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]),:host([appearance=inverse]){--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db);--ds-auro-dropdown-trigger-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdown-trigger-hover-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdown-trigger-container-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-border-inverse, #ffffff);--ds-auro-dropdown-trigger-outline-color: transparent;--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-dropdownbib-boxshadow-color: var(--ds-elevation-200, 0px 0px 10px rgba(0, 0, 0, 0.15));--ds-auro-dropdownbib-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdownbib-container-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdownbib-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}`;
4378
4483
 
4484
+ /**
4485
+ * Creates a keyboard strategy for dialog-specific key handling.
4486
+ * All other keydown behavior is left to the browser's native bubbling path.
4487
+ * @param {HTMLElement} bib - The dropdown bib element.
4488
+ * @returns {Object} Keyboard handlers keyed by `event.key`.
4489
+ */
4490
+ // eslint-disable-next-line no-unused-vars
4491
+ function createDropdownBibKeyboardStrategy(bib) {
4492
+ return {
4493
+ // eslint-disable-next-line no-unused-vars
4494
+ Enter(_dialog, event) {
4495
+ // Floating UI handles Enter key to open the dropdown
4496
+ },
4497
+ // eslint-disable-next-line no-unused-vars
4498
+ Escape(_dialog, event) {
4499
+ // Floating UI handles Escape key to close the dropdown
4500
+ }
4501
+ };
4502
+ }
4503
+
4379
4504
  // Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
4380
4505
  // See LICENSE in the project root for license information.
4381
4506
  /* eslint-disable max-lines */
@@ -4500,11 +4625,7 @@ class AuroDropdownBib extends i$3 {
4500
4625
  },
4501
4626
 
4502
4627
  /**
4503
- * Set by auro-dropdown when a menu option is highlighted via
4504
- * aria-activedescendant. The dialog keyboard bridge checks this
4505
- * flag so that Enter selects the highlighted option instead of
4506
- * activating the focused interactive element (e.g. the trigger
4507
- * button, or the bibtemplate close button in fullscreen).
4628
+ * Tracks whether a menu option is currently highlighted.
4508
4629
  * @private
4509
4630
  */
4510
4631
  hasActiveDescendant: {
@@ -4578,7 +4699,7 @@ class AuroDropdownBib extends i$3 {
4578
4699
 
4579
4700
  const dialog = this.shadowRoot.querySelector('dialog');
4580
4701
  this._setupCancelHandler(dialog);
4581
- this._setupKeyboardBridge(dialog);
4702
+ applyKeyboardStrategy(dialog, createDropdownBibKeyboardStrategy());
4582
4703
 
4583
4704
  this.dispatchEvent(new CustomEvent('auro-dropdownbib-connected', {
4584
4705
  bubbles: true,
@@ -4605,92 +4726,6 @@ class AuroDropdownBib extends i$3 {
4605
4726
  });
4606
4727
  }
4607
4728
 
4608
- /**
4609
- * showModal() creates a closed focus scope — keyboard events inside
4610
- * the dialog's shadow DOM do NOT bubble out to the combobox/select
4611
- * keydown handlers in the parent shadow DOM. This handler bridges
4612
- * that gap by re-dispatching navigation keys so they cross the
4613
- * shadow boundary and reach the menu navigation logic in the parent
4614
- * component.
4615
- *
4616
- * The trade-off: intercepting these keys means native keyboard
4617
- * behaviors that would normally "just work" must be manually
4618
- * re-implemented here:
4619
- *
4620
- * - Enter on buttons: Custom elements (auro-button) don't get the
4621
- * native Enter→click that <button> provides, so we call .click()
4622
- * directly when Enter is pressed on a button-like element.
4623
- *
4624
- * - Tab: Intercepted and re-dispatched so parent components
4625
- * (select/combobox) can select the active option and close the
4626
- * dialog. The <dialog> provides containment and isolation
4627
- * (inert background, VoiceOver focus trapping, top layer), while
4628
- * the content inside is a role="listbox" navigated via
4629
- * aria-activedescendant (options are not focusable). Tab keyboard
4630
- * behavior follows listbox conventions (select + close) because
4631
- * the dialog's native Tab trap only cycles between the close
4632
- * button and browser chrome.
4633
- *
4634
- * - Escape: The native <dialog> fires a `cancel` event on ESC
4635
- * (handled by _setupCancelHandler), so the re-dispatched Escape
4636
- * is a secondary path for parent components that also listen for
4637
- * Escape keydown.
4638
- *
4639
- * @param {HTMLDialogElement} dialog - The dialog element to attach the keyboard bridge to.
4640
- * @private
4641
- */
4642
- _setupKeyboardBridge(dialog) {
4643
- const navKeys = new Set([
4644
- 'ArrowUp',
4645
- 'ArrowDown',
4646
- 'Enter',
4647
- 'Escape',
4648
- 'Tab'
4649
- ]);
4650
-
4651
- dialog.addEventListener('keydown', (event) => {
4652
- if (!navKeys.has(event.key)) {
4653
- return;
4654
- }
4655
-
4656
- // Custom elements (auro-button) don't get the native Enter→click
4657
- // behavior that <button> has. Find the button in the composed path
4658
- // and click it directly — but only when no menu option is
4659
- // highlighted. In fullscreen mode focus stays on the close button
4660
- // while arrow keys move the active-descendant highlight through
4661
- // the listbox. If the user presses Enter with an option
4662
- // highlighted, the intent is to select that option, not to click
4663
- // the close button. In that case we fall through and bridge the
4664
- // Enter key to the parent component's keyboard strategy.
4665
- if (event.key === 'Enter') {
4666
- if (!this.hasActiveDescendant) {
4667
- const buttonSelector = 'button, [role="button"], auro-button, [auro-button]';
4668
- const btn = event.composedPath().find((el) => el.matches && el.matches(buttonSelector));
4669
- if (btn) {
4670
- event.preventDefault();
4671
- event.stopPropagation();
4672
- btn.click();
4673
- return;
4674
- }
4675
- }
4676
- }
4677
-
4678
- event.preventDefault();
4679
- event.stopPropagation();
4680
- const newEvent = new KeyboardEvent('keydown', {
4681
- key: event.key,
4682
- code: event.code,
4683
- shiftKey: event.shiftKey,
4684
- altKey: event.altKey,
4685
- ctrlKey: event.ctrlKey,
4686
- metaKey: event.metaKey,
4687
- bubbles: true,
4688
- composed: true,
4689
- cancelable: true
4690
- });
4691
- this.dispatchEvent(newEvent);
4692
- });
4693
- }
4694
4729
 
4695
4730
  /**
4696
4731
  * Blocks touch-driven page scroll while a fullscreen modal dialog is open.
@@ -5065,7 +5100,7 @@ let AuroHelpText$1 = class AuroHelpText extends i$3 {
5065
5100
  }
5066
5101
  };
5067
5102
 
5068
- var formkitVersion$1 = '202603310525';
5103
+ var formkitVersion$1 = '202604022013';
5069
5104
 
5070
5105
  class AuroElement extends i$3 {
5071
5106
  static get properties() {
@@ -5246,7 +5281,7 @@ class AuroDropdown extends AuroElement {
5246
5281
  this.appearance = 'default';
5247
5282
  this.chevron = false;
5248
5283
  this.disabled = false;
5249
- this.disableFocusTrap = false;
5284
+ this.disableKeyboardHandling = false;
5250
5285
  this.error = false;
5251
5286
  this.tabIndex = 0;
5252
5287
  this.noToggle = false;
@@ -5344,9 +5379,8 @@ class AuroDropdown extends AuroElement {
5344
5379
  // showModal() fires asynchronously via Lit's update cycle, which
5345
5380
  // falls outside the user activation window and causes iOS to
5346
5381
  // dismiss the keyboard.
5347
- if (this.isBibFullscreen && this.bibElement && this.bibElement.value) {
5348
- const useModal = !this.disableFocusTrap;
5349
- this.bibElement.value.open(useModal);
5382
+ if (this.bibElement && this.bibElement.value) {
5383
+ this.bibElement.value.open(this.isBibFullscreen);
5350
5384
  }
5351
5385
  }
5352
5386
 
@@ -5460,9 +5494,9 @@ class AuroDropdown extends AuroElement {
5460
5494
  },
5461
5495
 
5462
5496
  /**
5463
- * If declared, the focus trap inside of bib will be turned off.
5497
+ * If declared, the dropdown will not handle keyboard events and will require the consumer to manage this behavior.
5464
5498
  */
5465
- disableFocusTrap: {
5499
+ disableKeyboardHandling: {
5466
5500
  type: Boolean,
5467
5501
  reflect: true
5468
5502
  },
@@ -5740,7 +5774,7 @@ class AuroDropdown extends AuroElement {
5740
5774
  if (this.isPopoverVisible) {
5741
5775
  // Fullscreen: use showModal() for native accessibility (inert outside, focus trap)
5742
5776
  // Desktop: use show() for Floating UI positioning + FocusTrap for focus management
5743
- const useModal = this.isBibFullscreen && !this.disableFocusTrap;
5777
+ const useModal = this.isBibFullscreen;
5744
5778
  this.bibElement.value.open(useModal);
5745
5779
  } else {
5746
5780
  this.bibElement.value.close();
@@ -5750,7 +5784,7 @@ class AuroDropdown extends AuroElement {
5750
5784
  // When fullscreen strategy changes while open, re-open dialog with correct mode
5751
5785
  // (e.g. resizing from desktop → mobile while dropdown is open)
5752
5786
  if (changedProperties.has('isBibFullscreen') && this.isPopoverVisible && this.bibElement.value) {
5753
- const useModal = this.isBibFullscreen && !this.disableFocusTrap;
5787
+ const useModal = this.isBibFullscreen;
5754
5788
  this.bibElement.value.close();
5755
5789
  this.bibElement.value.open(useModal);
5756
5790
  }
@@ -5772,7 +5806,7 @@ class AuroDropdown extends AuroElement {
5772
5806
 
5773
5807
  firstUpdated() {
5774
5808
  // Configure the floater to, this will generate the ID for the bib
5775
- this.floater.configure(this, 'auroDropdown');
5809
+ this.floater.configure(this, 'auroDropdown', !this.disableKeyboardHandling);
5776
5810
 
5777
5811
  // Prevent `contain: layout` on the dropdown host. Layout containment
5778
5812
  // creates a containing block for position:fixed descendants (the bib),
@@ -5862,7 +5896,7 @@ class AuroDropdown extends AuroElement {
5862
5896
  * @private
5863
5897
  */
5864
5898
  updateFocusTrap() {
5865
- if (this.isPopoverVisible && !this.disableFocusTrap) {
5899
+ if (this.isPopoverVisible) {
5866
5900
  if (!this.isBibFullscreen) {
5867
5901
  // Desktop: show() doesn't trap focus, so use FocusTrap
5868
5902
  this.focusTrap = new FocusTrap(this.bibContent);
@@ -6080,6 +6114,7 @@ class AuroDropdown extends AuroElement {
6080
6114
  aria-expanded="${o(this.a11yRole === 'button' || this.triggerContentFocusable ? undefined : this.isPopoverVisible)}"
6081
6115
  aria-controls="${o(this.a11yRole === 'button' || this.triggerContentFocusable ? undefined : this.dropdownId)}"
6082
6116
  aria-labelledby="${o(this.triggerContentFocusable ? undefined : 'triggerLabel')}"
6117
+ aria-disabled="${o(this.disabled ? 'true' : undefined)}"
6083
6118
  @focusin="${this.handleFocusin}"
6084
6119
  @blur="${this.handleFocusOut}">
6085
6120
  <div class="triggerContentWrapper" id="triggerLabel">
@@ -6818,7 +6853,7 @@ class AuroHelpText extends i$3 {
6818
6853
  }
6819
6854
  }
6820
6855
 
6821
- var formkitVersion = '202603310525';
6856
+ var formkitVersion = '202604022013';
6822
6857
 
6823
6858
  var styleCss$2 = 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);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, 0.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, 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-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-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, 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, 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}`;
6824
6859
 
@@ -7353,12 +7388,28 @@ class AuroSelect extends AuroElement$1 {
7353
7388
  this.dropdown.setActiveDescendant(null);
7354
7389
  this.optionActive = null;
7355
7390
 
7356
- restoreTriggerAfterClose(this.dropdown, this.dropdown.trigger);
7391
+ if (this.dropdown.isBibFullscreen) {
7392
+ restoreTriggerAfterClose(this.dropdown, this.dropdown.trigger);
7393
+ }
7357
7394
  }
7358
7395
 
7359
7396
  if (this.dropdown.isPopoverVisible) {
7360
7397
  this.updateMenuShapeSize();
7361
7398
 
7399
+ // If there's a selected option, highlight it (per W3C APG combobox-select-only pattern)
7400
+ // No selection → first enabled option gets highlighted
7401
+ if (this.optionSelected && !Array.isArray(this.optionSelected)) {
7402
+ this.menu.updateActiveOption(this.optionSelected);
7403
+ } else if (this.multiSelect && Array.isArray(this.optionSelected) && this.optionSelected.length > 0) {
7404
+ this.menu.updateActiveOption(this.optionSelected[0]);
7405
+ } else if (!this.menu.optionActive) {
7406
+ // If no activeOption has yet to be set, then make the first enabled option active by default
7407
+ const firstActive = this.menu.menuService.menuOptions.find((option) => !option.disabled);
7408
+ this.menu.updateActiveOption(firstActive);
7409
+ }
7410
+
7411
+ // Scroll the selected option into view when dropdown opens
7412
+ this.scrollSelectedOptionIntoView();
7362
7413
  if (this.dropdown.isBibFullscreen) {
7363
7414
  // Hide the trigger from assistive technology so VoiceOver cannot reach it
7364
7415
  // behind the fullscreen dialog
@@ -7370,17 +7421,6 @@ class AuroSelect extends AuroElement$1 {
7370
7421
  // multiple Lit update cycles before moving focus into the bib
7371
7422
  doubleRaf(() => {
7372
7423
  this.bibtemplate.focusCloseButton();
7373
-
7374
- // If there's a selected option, highlight it (per W3C APG combobox-select-only pattern)
7375
- // No selection → no highlight
7376
- if (this.optionSelected && !Array.isArray(this.optionSelected)) {
7377
- this.menu.updateActiveOption(this.optionSelected);
7378
- } else if (this.multiSelect && Array.isArray(this.optionSelected) && this.optionSelected.length > 0) {
7379
- this.menu.updateActiveOption(this.optionSelected[0]);
7380
- }
7381
-
7382
- // Scroll the selected option into view when dropdown opens
7383
- this.scrollSelectedOptionIntoView();
7384
7424
  });
7385
7425
  } else {
7386
7426
  // wait til the bib gets fully rendered
@@ -7627,7 +7667,7 @@ class AuroSelect extends AuroElement$1 {
7627
7667
  configureSelect() {
7628
7668
  this.nativeSelect = this.shadowRoot.querySelector('select');
7629
7669
 
7630
- applyKeyboardStrategy(this, selectKeyboardStrategy);
7670
+ applyKeyboardStrategy$1(this, selectKeyboardStrategy);
7631
7671
 
7632
7672
  this.addEventListener('focusin', this.handleFocusin);
7633
7673
 
@@ -8066,6 +8106,7 @@ class AuroSelect extends AuroElement$1 {
8066
8106
  <slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
8067
8107
  </div>
8068
8108
  <${this.dropdownTag}
8109
+ disableKeyboardHandling
8069
8110
  appearance="${this.onDark ? 'inverse' : this.appearance}"
8070
8111
  .a11yRole=${"combobox"}
8071
8112
  ?autoPlacement="${this.autoPlacement}"
@@ -8145,6 +8186,7 @@ class AuroSelect extends AuroElement$1 {
8145
8186
  <slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
8146
8187
  </div>
8147
8188
  <${this.dropdownTag}
8189
+ disableKeyboardHandling
8148
8190
  appearance="${this.onDark ? 'inverse' : this.appearance}"
8149
8191
  .a11yRole=${"combobox"}
8150
8192
  ?autoPlacement="${this.autoPlacement}"
@@ -8230,6 +8272,7 @@ class AuroSelect extends AuroElement$1 {
8230
8272
  <slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
8231
8273
  </div>
8232
8274
  <${this.dropdownTag}
8275
+ disableKeyboardHandling
8233
8276
  appearance="${this.onDark ? 'inverse' : this.appearance}"
8234
8277
  .a11yRole=${"combobox"}
8235
8278
  ?autoPlacement="${this.autoPlacement}"
@@ -8907,7 +8950,7 @@ class AuroMenuOption extends AuroElement$1 {
8907
8950
  });
8908
8951
 
8909
8952
  return u$4`
8910
- <div class="${classes}">
8953
+ <div class="${classes}" aria-disabled="${this.disabled ? 'true' : 'false'}">
8911
8954
  ${this.selected && !this.noCheckmark
8912
8955
  ? this.generateIconHtml(checkmarkIcon.svg)
8913
8956
  : undefined}
@@ -9678,10 +9721,10 @@ class AuroMenu extends AuroElement$1 {
9678
9721
 
9679
9722
  // Event Bindings
9680
9723
 
9681
- /**
9682
- * @private
9683
- */
9684
- this.handleKeyDown = this.handleKeyDown.bind(this);
9724
+ // /**
9725
+ // * @private
9726
+ // */
9727
+ // this.handleKeyDown = this.handleKeyDown.bind(this);
9685
9728
 
9686
9729
 
9687
9730
  /**
@@ -10030,7 +10073,7 @@ class AuroMenu extends AuroElement$1 {
10030
10073
 
10031
10074
  this.provideContext();
10032
10075
 
10033
- this.addEventListener('keydown', this.handleKeyDown);
10076
+ // this.addEventListener('keydown', this.handleKeyDown);
10034
10077
  this.addEventListener('auroMenuOption-click', this.handleMouseSelect);
10035
10078
  this.addEventListener('auroMenuOption-mouseover', this.handleOptionHover);
10036
10079
  this.addEventListener('slotchange', this.handleSlotChange);
@@ -10038,7 +10081,7 @@ class AuroMenu extends AuroElement$1 {
10038
10081
  }
10039
10082
 
10040
10083
  disconnectedCallback() {
10041
- this.removeEventListener('keydown', this.handleKeyDown);
10084
+ // this.removeEventListener('keydown', this.handleKeyDown);
10042
10085
  this.removeEventListener('auroMenuOption-click', this.handleMouseSelect);
10043
10086
  this.removeEventListener('auroMenuOption-mouseover', this.handleOptionHover);
10044
10087
  this.removeEventListener('slotchange', this.handleSlotChange);
@@ -10179,26 +10222,33 @@ class AuroMenu extends AuroElement$1 {
10179
10222
 
10180
10223
  // Event Handlers
10181
10224
 
10182
- /**
10183
- * Handles keyboard navigation.
10184
- * @private
10185
- * @param {KeyboardEvent} event - Event object from the browser.
10186
- */
10187
- handleKeyDown(event) {
10188
- event.preventDefault();
10189
- switch (event.key) {
10190
- case "ArrowDown":
10191
- this.menuService.highlightNext();
10192
- break;
10193
- case "ArrowUp":
10194
- this.menuService.highlightPrevious();
10195
- break;
10196
- case "Tab":
10197
- case "Enter":
10198
- this.menuService.selectHighlightedOption();
10199
- break;
10200
- }
10201
- }
10225
+ // /**
10226
+ // * Handles keyboard navigation.
10227
+ // * @private
10228
+ // * @param {KeyboardEvent} event - Event object from the browser.
10229
+ // */
10230
+ // handleKeyDown(event) {
10231
+ // // Update to Chris keyboard handler
10232
+ // // We have a new "navigateArrow" function in that handler, maybe that replaces those keys here?
10233
+ // event.preventDefault();
10234
+ // switch (event.key) {
10235
+ // case "ArrowDown":
10236
+ // console.warn("ArrowDown key is pressed and heard from menu");
10237
+ // this.menuService.highlightNext();
10238
+ // break;
10239
+ // case "ArrowUp":
10240
+ // console.warn("ArrowUp key is pressed and heard from menu");
10241
+ // this.menuService.highlightPrevious();
10242
+ // break;
10243
+ // case "Tab":
10244
+ // case "Enter":
10245
+ // this.menuService.selectHighlightedOption();
10246
+ // // Does this need to get separated into two cases to handle the different expected behavior of tab vs enter?
10247
+ // break;
10248
+ // default:
10249
+ // break;
10250
+ // }
10251
+ // }
10202
10252
 
10203
10253
  /**
10204
10254
  * Navigates the menu options in the specified direction.