@aurodesignsystem-dev/auro-formkit 0.0.0-pr1497.0 → 0.0.0-pr1497.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/bibtemplate/dist/auro-bibtemplate.d.ts +7 -0
- package/components/bibtemplate/dist/index.js +9 -1
- package/components/bibtemplate/dist/registered.js +9 -1
- package/components/checkbox/demo/css-only.html +57 -0
- package/components/checkbox/demo/css-only.md +146 -0
- package/components/checkbox/demo/customize.min.js +1 -1
- package/components/checkbox/demo/getting-started.min.js +1 -1
- package/components/checkbox/demo/index.min.js +1 -1
- package/components/checkbox/demo/pages.json +1 -1
- package/components/checkbox/demo/styles.min.css +1 -1
- package/components/checkbox/demo/why-checkbox.html +57 -0
- package/components/checkbox/demo/why-checkbox.md +86 -0
- package/components/checkbox/dist/index.js +1 -1
- package/components/checkbox/dist/registered.js +1 -1
- package/components/combobox/demo/css-only.html +57 -0
- package/components/combobox/demo/css-only.md +209 -0
- package/components/combobox/demo/customize.min.js +250 -16
- package/components/combobox/demo/getting-started.min.js +250 -16
- package/components/combobox/demo/index.min.js +250 -16
- package/components/combobox/demo/pages.json +1 -1
- package/components/combobox/demo/styles.min.css +1 -1
- package/components/combobox/demo/why-combobox.html +57 -0
- package/components/combobox/demo/why-combobox.md +113 -0
- package/components/combobox/dist/index.js +250 -16
- package/components/combobox/dist/registered.js +250 -16
- package/components/counter/demo/css-only.html +57 -0
- package/components/counter/demo/css-only.md +184 -0
- package/components/counter/demo/customize.min.js +249 -15
- package/components/counter/demo/index.min.js +249 -15
- package/components/counter/demo/keyboard-behavior.md +1 -0
- package/components/counter/demo/pages.json +1 -1
- package/components/counter/demo/styles.min.css +1 -1
- package/components/counter/demo/why-counter.html +57 -0
- package/components/counter/demo/why-counter.md +108 -0
- package/components/counter/dist/index.js +10 -2
- package/components/counter/dist/registered.js +10 -2
- package/components/datepicker/demo/accessibility.md +54 -3
- package/components/datepicker/demo/api.md +63 -53
- package/components/datepicker/demo/css-only.html +57 -0
- package/components/datepicker/demo/css-only.md +151 -0
- package/components/datepicker/demo/customize.html +2 -0
- package/components/datepicker/demo/customize.js +19 -0
- package/components/datepicker/demo/customize.md +56 -0
- package/components/datepicker/demo/customize.min.js +36147 -0
- package/components/datepicker/demo/design.md +3 -1
- package/components/datepicker/demo/index.js +5 -1
- package/components/datepicker/demo/index.md +104 -15
- package/components/datepicker/demo/index.min.js +2485 -261
- package/components/datepicker/demo/keyboard-behavior.md +201 -2
- package/components/datepicker/demo/pages.json +1 -1
- package/components/datepicker/demo/styles.min.css +1 -1
- package/components/datepicker/demo/voiceover.md +21 -12
- package/components/datepicker/demo/why-datepicker.html +57 -0
- package/components/datepicker/demo/why-datepicker.md +133 -0
- package/components/datepicker/dist/index.js +2348 -211
- package/components/datepicker/dist/registered.js +2348 -211
- package/components/datepicker/dist/src/auro-calendar-cell.d.ts +113 -13
- package/components/datepicker/dist/src/auro-calendar-month.d.ts +38 -1
- package/components/datepicker/dist/src/auro-calendar.d.ts +258 -0
- package/components/datepicker/dist/src/auro-datepicker.d.ts +141 -41
- package/components/datepicker/dist/src/datepickerKeyboardStrategy.d.ts +5 -3
- package/components/dropdown/demo/accessibility.md +11 -0
- package/components/dropdown/demo/api.md +1 -0
- package/components/dropdown/demo/css-only.html +57 -0
- package/components/dropdown/demo/css-only.md +219 -0
- package/components/dropdown/demo/customize.md +3 -0
- package/components/dropdown/demo/customize.min.js +239 -13
- package/components/dropdown/demo/getting-started.min.js +239 -13
- package/components/dropdown/demo/index.min.js +239 -13
- package/components/dropdown/demo/keyboard-behavior.md +1 -0
- package/components/dropdown/demo/pages.json +1 -1
- package/components/dropdown/demo/styles.min.css +1 -1
- package/components/dropdown/demo/why-dropdown.html +57 -0
- package/components/dropdown/demo/why-dropdown.md +97 -0
- package/components/dropdown/dist/auro-dropdown.d.ts +34 -1
- package/components/dropdown/dist/index.js +239 -13
- package/components/dropdown/dist/registered.js +239 -13
- package/components/form/demo/css-only.html +57 -0
- package/components/form/demo/css-only.md +156 -0
- package/components/form/demo/customize.min.js +3098 -259
- package/components/form/demo/getting-started.min.js +3098 -259
- package/components/form/demo/index.min.js +3098 -259
- package/components/form/demo/pages.json +1 -1
- package/components/form/demo/registerDemoDeps.min.js +3098 -259
- package/components/form/demo/styles.min.css +1 -1
- package/components/form/demo/why-form.html +57 -0
- package/components/form/demo/why-form.md +101 -0
- package/components/input/demo/css-only.html +57 -0
- package/components/input/demo/css-only.md +199 -0
- package/components/input/demo/customize.min.js +1 -1
- package/components/input/demo/getting-started.min.js +1 -1
- package/components/input/demo/index.min.js +1 -1
- package/components/input/demo/pages.json +1 -1
- package/components/input/demo/styles.min.css +1 -1
- package/components/input/demo/why-input.html +57 -0
- package/components/input/demo/why-input.md +121 -0
- package/components/input/dist/index.js +1 -1
- package/components/input/dist/registered.js +1 -1
- package/components/menu/demo/css-only.html +57 -0
- package/components/menu/demo/css-only.md +166 -0
- package/components/menu/demo/pages.json +1 -1
- package/components/menu/demo/styles.min.css +1 -1
- package/components/menu/demo/why-menu.html +57 -0
- package/components/menu/demo/why-menu.md +104 -0
- package/components/radio/demo/css-only.html +57 -0
- package/components/radio/demo/css-only.md +151 -0
- package/components/radio/demo/customize.min.js +1764 -0
- package/components/radio/demo/demo-support.min.js +55807 -0
- package/components/radio/demo/getting-started.js +1 -1
- package/components/radio/demo/getting-started.md +1 -1
- package/components/radio/demo/getting-started.min.js +1783 -0
- package/components/radio/demo/index.min.js +1 -1
- package/components/radio/demo/pages.json +1 -1
- package/components/radio/demo/styles.min.css +1 -1
- package/components/radio/demo/why-radio.html +57 -0
- package/components/radio/demo/why-radio.md +92 -0
- package/components/radio/dist/index.js +1 -1
- package/components/radio/dist/registered.js +1 -1
- package/components/select/demo/css-only.html +57 -0
- package/components/select/demo/css-only.md +203 -0
- package/components/select/demo/customize.min.js +249 -15
- package/components/select/demo/getting-started.min.js +249 -15
- package/components/select/demo/index.min.js +249 -15
- package/components/select/demo/keyboard-behavior.md +1 -0
- package/components/select/demo/pages.json +1 -1
- package/components/select/demo/styles.min.css +1 -1
- package/components/select/demo/why-select.html +57 -0
- package/components/select/demo/why-select.md +128 -0
- package/components/select/dist/index.js +249 -15
- package/components/select/dist/registered.js +249 -15
- package/custom-elements.json +2700 -1621
- package/package.json +8 -8
|
@@ -4158,7 +4158,7 @@ function applyKeyboardStrategy(component, strategy, options = {}) {
|
|
|
4158
4158
|
});
|
|
4159
4159
|
}
|
|
4160
4160
|
|
|
4161
|
-
var styleCss$2$1 = css`: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}`;
|
|
4161
|
+
var styleCss$2$1 = css`: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([desktopmodal]:popover-open)::backdrop{background:transparent}: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}`;
|
|
4162
4162
|
|
|
4163
4163
|
var colorCss$2$1 = css`.container{background-color:var(--ds-auro-dropdownbib-container-color);box-shadow:var(--ds-auro-dropdownbib-boxshadow-color);color:var(--ds-auro-dropdownbib-text-color)}`;
|
|
4164
4164
|
|
|
@@ -4789,7 +4789,7 @@ let AuroHelpText$2 = class AuroHelpText extends LitElement {
|
|
|
4789
4789
|
}
|
|
4790
4790
|
};
|
|
4791
4791
|
|
|
4792
|
-
var formkitVersion$2 = '
|
|
4792
|
+
var formkitVersion$2 = '202606081833';
|
|
4793
4793
|
|
|
4794
4794
|
let AuroElement$2 = class AuroElement extends LitElement {
|
|
4795
4795
|
static get properties() {
|
|
@@ -4969,6 +4969,7 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4969
4969
|
_intializeDefaults() {
|
|
4970
4970
|
this.appearance = 'default';
|
|
4971
4971
|
this.chevron = false;
|
|
4972
|
+
this.desktopModal = false;
|
|
4972
4973
|
this.disabled = false;
|
|
4973
4974
|
this.disableKeyboardHandling = false;
|
|
4974
4975
|
this.error = false;
|
|
@@ -5149,6 +5150,14 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5149
5150
|
reflect: true
|
|
5150
5151
|
},
|
|
5151
5152
|
|
|
5153
|
+
/**
|
|
5154
|
+
* If declared, the dropdown will behave as a modal dialog when in a desktop viewport size.
|
|
5155
|
+
*/
|
|
5156
|
+
desktopModal: {
|
|
5157
|
+
type: Boolean,
|
|
5158
|
+
reflect: true
|
|
5159
|
+
},
|
|
5160
|
+
|
|
5152
5161
|
/**
|
|
5153
5162
|
* If declared, the dropdown will only show by calling the API .show() public method.
|
|
5154
5163
|
*/
|
|
@@ -5436,6 +5445,15 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5436
5445
|
|
|
5437
5446
|
disconnectedCallback() {
|
|
5438
5447
|
super.disconnectedCallback();
|
|
5448
|
+
this._clearPageInert();
|
|
5449
|
+
if (this._bibTabHandler) {
|
|
5450
|
+
this.removeEventListener('keydown', this._bibTabHandler);
|
|
5451
|
+
this._bibTabHandler = undefined;
|
|
5452
|
+
}
|
|
5453
|
+
if (this.focusTrap) {
|
|
5454
|
+
this.focusTrap.disconnect();
|
|
5455
|
+
this.focusTrap = undefined;
|
|
5456
|
+
}
|
|
5439
5457
|
if (this.floater) {
|
|
5440
5458
|
this.floater.hideBib('disconnect');
|
|
5441
5459
|
this.floater.disconnect();
|
|
@@ -5463,19 +5481,45 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5463
5481
|
if (this.isPopoverVisible) {
|
|
5464
5482
|
// Fullscreen: use showModal() for native accessibility (inert outside, focus trap)
|
|
5465
5483
|
// Desktop: use show() for Floating UI positioning + FocusTrap for focus management
|
|
5466
|
-
|
|
5467
|
-
this.
|
|
5484
|
+
this.bibElement.value.open(this.isBibFullscreen);
|
|
5485
|
+
this.updateFocusTrap();
|
|
5486
|
+
|
|
5487
|
+
// Desktop modal: make siblings inert so content outside is not interactive
|
|
5488
|
+
if (this.desktopModal && !this.isBibFullscreen) {
|
|
5489
|
+
this._setPageInert();
|
|
5490
|
+
}
|
|
5468
5491
|
} else {
|
|
5469
5492
|
this.bibElement.value.close();
|
|
5493
|
+
this._clearPageInert();
|
|
5470
5494
|
}
|
|
5471
5495
|
}
|
|
5472
5496
|
|
|
5473
5497
|
// When fullscreen strategy changes while open, re-open dialog with correct mode
|
|
5474
5498
|
// (e.g. resizing from desktop → mobile while dropdown is open)
|
|
5475
5499
|
if (changedProperties.has('isBibFullscreen') && this.isPopoverVisible && this.bibElement.value) {
|
|
5476
|
-
const useModal = this.isBibFullscreen;
|
|
5477
5500
|
this.bibElement.value.close();
|
|
5478
|
-
this.bibElement.value.open(
|
|
5501
|
+
this.bibElement.value.open(this.isBibFullscreen);
|
|
5502
|
+
|
|
5503
|
+
// Re-initialize focus management for the new strategy
|
|
5504
|
+
this.updateFocusTrap();
|
|
5505
|
+
|
|
5506
|
+
// Toggle inert: desktop modal needs it, fullscreen showModal() handles it natively
|
|
5507
|
+
if (this.desktopModal && !this.isBibFullscreen) {
|
|
5508
|
+
this._setPageInert();
|
|
5509
|
+
} else {
|
|
5510
|
+
this._clearPageInert();
|
|
5511
|
+
}
|
|
5512
|
+
}
|
|
5513
|
+
|
|
5514
|
+
// Handle desktopModal toggled while the dropdown is already open.
|
|
5515
|
+
// Re-initialize focus trapping and page inert state to match the new mode.
|
|
5516
|
+
if (changedProperties.has('desktopModal') && this.isPopoverVisible && !this.isBibFullscreen) {
|
|
5517
|
+
this.updateFocusTrap();
|
|
5518
|
+
if (this.desktopModal) {
|
|
5519
|
+
this._setPageInert();
|
|
5520
|
+
} else {
|
|
5521
|
+
this._clearPageInert();
|
|
5522
|
+
}
|
|
5479
5523
|
}
|
|
5480
5524
|
}
|
|
5481
5525
|
|
|
@@ -5485,8 +5529,14 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5485
5529
|
* @param {CustomEvent} event - The custom event that contains the dropdown toggle information.
|
|
5486
5530
|
*/
|
|
5487
5531
|
handleDropdownToggle(event) {
|
|
5488
|
-
this.updateFocusTrap();
|
|
5489
5532
|
this.isPopoverVisible = event.detail.expanded;
|
|
5533
|
+
|
|
5534
|
+
// Tear down FocusTrap when closing. Creation happens in updated()
|
|
5535
|
+
// after the dialog is open so getFocusableElements can find content.
|
|
5536
|
+
if (!this.isPopoverVisible) {
|
|
5537
|
+
this.updateFocusTrap();
|
|
5538
|
+
}
|
|
5539
|
+
|
|
5490
5540
|
const eventType = event.detail.eventType || "unknown";
|
|
5491
5541
|
if (!this.isPopoverVisible && this.hasFocus && eventType === "keydown") {
|
|
5492
5542
|
this.trigger.focus();
|
|
@@ -5585,19 +5635,194 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5585
5635
|
* @private
|
|
5586
5636
|
*/
|
|
5587
5637
|
updateFocusTrap() {
|
|
5638
|
+
// Always clean up existing handlers/traps before setting up new ones
|
|
5639
|
+
// to prevent duplicate listeners on repeated calls.
|
|
5640
|
+
if (this._bibTabHandler) {
|
|
5641
|
+
this.removeEventListener('keydown', this._bibTabHandler);
|
|
5642
|
+
this._bibTabHandler = undefined;
|
|
5643
|
+
}
|
|
5644
|
+
|
|
5645
|
+
if (this.focusTrap) {
|
|
5646
|
+
this.focusTrap.disconnect();
|
|
5647
|
+
this.focusTrap = undefined;
|
|
5648
|
+
}
|
|
5649
|
+
|
|
5588
5650
|
if (this.isPopoverVisible) {
|
|
5589
5651
|
if (!this.isBibFullscreen) {
|
|
5590
|
-
|
|
5591
|
-
|
|
5592
|
-
|
|
5652
|
+
if (this.desktopModal) {
|
|
5653
|
+
// Desktop modal: trap focus only within the bib content.
|
|
5654
|
+
// Can't use FocusTrap on the bib element because keydown events
|
|
5655
|
+
// from slotted content bubble through the dropdown host (light DOM),
|
|
5656
|
+
// not through the bib (shadow projection target). Using FocusTrap
|
|
5657
|
+
// on the dropdown would include the trigger in the tab cycle.
|
|
5658
|
+
// Instead, listen for Tab on the dropdown and manually wrap focus
|
|
5659
|
+
// within the bib's focusable elements.
|
|
5660
|
+
this._bibTabHandler = (event) => {
|
|
5661
|
+
if (event.key !== 'Tab') {
|
|
5662
|
+
return;
|
|
5663
|
+
}
|
|
5664
|
+
|
|
5665
|
+
// Collect focusable elements from the bib content.
|
|
5666
|
+
const focusables = getFocusableElements(this.bibContent);
|
|
5667
|
+
|
|
5668
|
+
// Fallback: try from slotted content directly
|
|
5669
|
+
if (!focusables.length) {
|
|
5670
|
+
const slot = this.shadowRoot.querySelector('.slotContent slot');
|
|
5671
|
+
const assignedNodes = slot ? slot.assignedNodes({ flatten: true }) : [];
|
|
5672
|
+
|
|
5673
|
+
for (const node of assignedNodes) {
|
|
5674
|
+
if (node.nodeType === Node.ELEMENT_NODE) {
|
|
5675
|
+
focusables.push(...getFocusableElements(node));
|
|
5676
|
+
}
|
|
5677
|
+
}
|
|
5678
|
+
}
|
|
5679
|
+
|
|
5680
|
+
if (!focusables.length) {
|
|
5681
|
+
return;
|
|
5682
|
+
}
|
|
5683
|
+
|
|
5684
|
+
event.preventDefault();
|
|
5685
|
+
|
|
5686
|
+
const direction = event.shiftKey ? -1 : 1; // eslint-disable-line no-magic-numbers
|
|
5687
|
+
|
|
5688
|
+
// Walk the active element chain through shadow roots
|
|
5689
|
+
const actives = this._getActiveElements();
|
|
5690
|
+
|
|
5691
|
+
let idx = focusables.findIndex((el) => actives.includes(el));
|
|
5692
|
+
|
|
5693
|
+
if (idx === -1) { // eslint-disable-line no-magic-numbers
|
|
5694
|
+
// Focus is not on a known element — move to first/last
|
|
5695
|
+
idx = direction === 1 ? -1 : focusables.length; // eslint-disable-line no-magic-numbers
|
|
5696
|
+
}
|
|
5697
|
+
|
|
5698
|
+
// Try each element in order, skipping any that can't receive focus
|
|
5699
|
+
// (e.g. hidden elements, elements in collapsed sections)
|
|
5700
|
+
for (let index = 0; index < focusables.length; index++) { // eslint-disable-line no-plusplus
|
|
5701
|
+
let nextIdx = idx + direction;
|
|
5702
|
+
|
|
5703
|
+
// Wrap around
|
|
5704
|
+
if (nextIdx < 0) {
|
|
5705
|
+
nextIdx = focusables.length - 1;
|
|
5706
|
+
} else if (nextIdx >= focusables.length) {
|
|
5707
|
+
nextIdx = 0;
|
|
5708
|
+
}
|
|
5709
|
+
|
|
5710
|
+
focusables[nextIdx].focus();
|
|
5711
|
+
|
|
5712
|
+
// Verify focus actually moved to the target
|
|
5713
|
+
const newActives = this._getActiveElements();
|
|
5714
|
+
|
|
5715
|
+
if (newActives.includes(focusables[nextIdx])) {
|
|
5716
|
+
return;
|
|
5717
|
+
}
|
|
5718
|
+
|
|
5719
|
+
// Focus didn't stick — skip this element and try the next
|
|
5720
|
+
idx = nextIdx;
|
|
5721
|
+
}
|
|
5722
|
+
};
|
|
5723
|
+
this.addEventListener('keydown', this._bibTabHandler);
|
|
5724
|
+
|
|
5725
|
+
// Move initial focus into the bib content, matching FocusTrap behavior
|
|
5726
|
+
requestAnimationFrame(() => {
|
|
5727
|
+
const focusables = getFocusableElements(this.bibContent);
|
|
5728
|
+
if (focusables.length) {
|
|
5729
|
+
focusables[0].focus();
|
|
5730
|
+
}
|
|
5731
|
+
});
|
|
5732
|
+
} else {
|
|
5733
|
+
// Normal desktop: use FocusTrap on the bib element
|
|
5734
|
+
this.focusTrap = new FocusTrap(this.bibContent);
|
|
5735
|
+
this.focusTrap.focusFirstElement();
|
|
5736
|
+
}
|
|
5593
5737
|
}
|
|
5594
5738
|
// Fullscreen: showModal() provides native focus trapping
|
|
5739
|
+
}
|
|
5740
|
+
}
|
|
5741
|
+
|
|
5742
|
+
/**
|
|
5743
|
+
* Returns the chain of active (focused) elements through shadow roots.
|
|
5744
|
+
* @private
|
|
5745
|
+
* @returns {Array<HTMLElement>}
|
|
5746
|
+
*/
|
|
5747
|
+
_getActiveElements() {
|
|
5748
|
+
let { activeElement } = document;
|
|
5749
|
+
const actives = [activeElement];
|
|
5750
|
+
|
|
5751
|
+
while (activeElement?.shadowRoot?.activeElement) {
|
|
5752
|
+
activeElement = activeElement.shadowRoot.activeElement;
|
|
5753
|
+
actives.push(activeElement);
|
|
5754
|
+
}
|
|
5755
|
+
|
|
5756
|
+
return actives;
|
|
5757
|
+
}
|
|
5758
|
+
|
|
5759
|
+
/**
|
|
5760
|
+
* Sets `inert` on sibling elements of the dropdown's top-level host
|
|
5761
|
+
* so that content outside the dropdown is not interactive while the modal is open.
|
|
5762
|
+
* Walks up through shadow DOM boundaries to find the outermost host element
|
|
5763
|
+
* in the light DOM, then sets `inert` on siblings at each ancestor level
|
|
5764
|
+
* to ensure all page content outside the host subtree is inert.
|
|
5765
|
+
* @private
|
|
5766
|
+
*/
|
|
5767
|
+
_setPageInert() {
|
|
5768
|
+
if (this._inertSiblings) {
|
|
5595
5769
|
return;
|
|
5596
5770
|
}
|
|
5597
5771
|
|
|
5598
|
-
|
|
5599
|
-
|
|
5600
|
-
|
|
5772
|
+
this._inertSiblings = [];
|
|
5773
|
+
|
|
5774
|
+
// Walk up through shadow DOM boundaries to find the topmost host
|
|
5775
|
+
// element in the light DOM. For example, if this dropdown is inside
|
|
5776
|
+
// auro-datepicker's shadow DOM, we walk up to the datepicker element
|
|
5777
|
+
// so we set inert on its siblings — not on the datepicker itself.
|
|
5778
|
+
let host = this;
|
|
5779
|
+
while (host.getRootNode() instanceof ShadowRoot) {
|
|
5780
|
+
host = host.getRootNode().host;
|
|
5781
|
+
}
|
|
5782
|
+
|
|
5783
|
+
// Walk up the ancestor chain, inerting siblings at each level
|
|
5784
|
+
// to ensure the entire page outside the host subtree is inert.
|
|
5785
|
+
// Uses a reference counter (data-auro-inert-count) so multiple
|
|
5786
|
+
// simultaneous modal dropdowns share inert state safely.
|
|
5787
|
+
let current = host;
|
|
5788
|
+
while (current.parentElement) {
|
|
5789
|
+
const parent = current.parentElement;
|
|
5790
|
+
for (const sibling of parent.children) {
|
|
5791
|
+
if (sibling !== current) {
|
|
5792
|
+
const count = parseInt(sibling.dataset.auroInertCount || '0', 10);
|
|
5793
|
+
if (count === 0) {
|
|
5794
|
+
sibling.dataset.auroInertWas = sibling.inert ? 'true' : 'false';
|
|
5795
|
+
}
|
|
5796
|
+
sibling.dataset.auroInertCount = String(count + 1);
|
|
5797
|
+
sibling.inert = true;
|
|
5798
|
+
this._inertSiblings.push(sibling);
|
|
5799
|
+
}
|
|
5800
|
+
}
|
|
5801
|
+
current = parent;
|
|
5802
|
+
}
|
|
5803
|
+
}
|
|
5804
|
+
|
|
5805
|
+
/**
|
|
5806
|
+
* Restores `inert` state on siblings that were tracked by `_setPageInert`.
|
|
5807
|
+
* Uses reference counting so inert is only cleared when the last modal
|
|
5808
|
+
* dropdown releases a given element. Preserves the original inert state
|
|
5809
|
+
* so externally-inerted elements are not inadvertently re-enabled.
|
|
5810
|
+
* @private
|
|
5811
|
+
*/
|
|
5812
|
+
_clearPageInert() {
|
|
5813
|
+
if (this._inertSiblings) {
|
|
5814
|
+
for (const sibling of this._inertSiblings) {
|
|
5815
|
+
const count = parseInt(sibling.dataset.auroInertCount || '1', 10) - 1;
|
|
5816
|
+
if (count <= 0) {
|
|
5817
|
+
const wasInert = sibling.dataset.auroInertWas === 'true';
|
|
5818
|
+
delete sibling.dataset.auroInertCount;
|
|
5819
|
+
delete sibling.dataset.auroInertWas;
|
|
5820
|
+
sibling.inert = wasInert;
|
|
5821
|
+
} else {
|
|
5822
|
+
sibling.dataset.auroInertCount = String(count);
|
|
5823
|
+
}
|
|
5824
|
+
}
|
|
5825
|
+
this._inertSiblings = undefined;
|
|
5601
5826
|
}
|
|
5602
5827
|
}
|
|
5603
5828
|
|
|
@@ -5836,6 +6061,7 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5836
6061
|
shape="${this.shape}"
|
|
5837
6062
|
?data-show="${this.isPopoverVisible}"
|
|
5838
6063
|
?isfullscreen="${this.isBibFullscreen}"
|
|
6064
|
+
?desktopmodal="${this.desktopModal}"
|
|
5839
6065
|
.dialogLabel="${this.bibDialogLabel}"
|
|
5840
6066
|
${ref(this.bibElement)}
|
|
5841
6067
|
>
|
|
@@ -18040,7 +18266,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
|
|
|
18040
18266
|
}
|
|
18041
18267
|
};
|
|
18042
18268
|
|
|
18043
|
-
var formkitVersion$1 = '
|
|
18269
|
+
var formkitVersion$1 = '202606081833';
|
|
18044
18270
|
|
|
18045
18271
|
// Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
18046
18272
|
// See LICENSE in the project root for license information.
|
|
@@ -19046,6 +19272,14 @@ class AuroBibtemplate extends LitElement {
|
|
|
19046
19272
|
large: {
|
|
19047
19273
|
type: Boolean,
|
|
19048
19274
|
reflect: true
|
|
19275
|
+
},
|
|
19276
|
+
|
|
19277
|
+
/**
|
|
19278
|
+
* If declared, the footer slot will be rendered even when not in fullscreen mode.
|
|
19279
|
+
*/
|
|
19280
|
+
showFooter: {
|
|
19281
|
+
type: Boolean,
|
|
19282
|
+
reflect: true
|
|
19049
19283
|
}
|
|
19050
19284
|
};
|
|
19051
19285
|
}
|
|
@@ -19148,7 +19382,7 @@ class AuroBibtemplate extends LitElement {
|
|
|
19148
19382
|
<slot></slot>
|
|
19149
19383
|
</div>
|
|
19150
19384
|
|
|
19151
|
-
${this.isFullscreen ? html`
|
|
19385
|
+
${this.isFullscreen || this.showFooter ? html`
|
|
19152
19386
|
<div id="footerContainer">
|
|
19153
19387
|
<slot name="footer"></slot>
|
|
19154
19388
|
</div>` : null}
|
|
@@ -19157,7 +19391,7 @@ class AuroBibtemplate extends LitElement {
|
|
|
19157
19391
|
}
|
|
19158
19392
|
}
|
|
19159
19393
|
|
|
19160
|
-
var formkitVersion = '
|
|
19394
|
+
var formkitVersion = '202606081833';
|
|
19161
19395
|
|
|
19162
19396
|
var styleCss$1 = css`.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}`;
|
|
19163
19397
|
|