@aurodesignsystem/auro-formkit 1.6.0-beta.6 → 1.6.0-beta.7
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/.turbo/cache/01de6ab3df8b7e1e-meta.json +1 -0
- package/.turbo/cache/{754a6b5c5ce1ed00.tar.zst → 01de6ab3df8b7e1e.tar.zst} +0 -0
- package/.turbo/cache/10feda0f037804bb-meta.json +1 -1
- package/.turbo/cache/11079d2746265545-meta.json +1 -1
- package/.turbo/cache/11079d2746265545.tar.zst +0 -0
- package/.turbo/cache/115c4b73a12f5275-meta.json +1 -0
- package/.turbo/cache/115c4b73a12f5275.tar.zst +0 -0
- package/.turbo/cache/144e8e78657bf800-meta.json +1 -1
- package/.turbo/cache/18939b2c7c83b163-meta.json +1 -1
- package/.turbo/cache/1de685df0eaa39c8-meta.json +1 -1
- package/.turbo/cache/1ec139dcf090d547-meta.json +1 -1
- package/.turbo/cache/1f53ce3a28c56cdf-meta.json +1 -1
- package/.turbo/cache/23bf100310bd9f5a-meta.json +1 -1
- package/.turbo/cache/2900e7ec28e1488f-meta.json +1 -1
- package/.turbo/cache/296074aadfa2f8c9-meta.json +1 -1
- package/.turbo/cache/296074aadfa2f8c9.tar.zst +0 -0
- package/.turbo/cache/29e29355bf6fb4fd-meta.json +1 -1
- package/.turbo/cache/2cbcbc4a17387253-meta.json +1 -0
- package/.turbo/cache/2cbcbc4a17387253.tar.zst +0 -0
- package/.turbo/cache/2f6c898fbb51e995-meta.json +1 -1
- package/.turbo/cache/2f6c898fbb51e995.tar.zst +0 -0
- package/.turbo/cache/3073b96f6e4d867c-meta.json +1 -1
- package/.turbo/cache/33466ea2930c3714-meta.json +1 -1
- package/.turbo/cache/3426941a74b0731e-meta.json +1 -0
- package/.turbo/cache/{3f41d958c755a6f0.tar.zst → 3426941a74b0731e.tar.zst} +0 -0
- package/.turbo/cache/38b0799e2f7e62c5-meta.json +1 -0
- package/.turbo/cache/38b0799e2f7e62c5.tar.zst +0 -0
- package/.turbo/cache/3fbc89f461c495db-meta.json +1 -0
- package/.turbo/cache/3fbc89f461c495db.tar.zst +0 -0
- package/.turbo/cache/451e562c76f74ec6-meta.json +1 -1
- package/.turbo/cache/4520919609c97850-meta.json +1 -1
- package/.turbo/cache/452908d0b0b676bc-meta.json +1 -1
- package/.turbo/cache/48c197e39ed31fd2-meta.json +1 -1
- package/.turbo/cache/48c197e39ed31fd2.tar.zst +0 -0
- package/.turbo/cache/5058ecc7f1e34496-meta.json +1 -1
- package/.turbo/cache/5a66a99aa1344401-meta.json +1 -1
- package/.turbo/cache/5b66ce21630716cc-meta.json +1 -1
- package/.turbo/cache/6002b76d50b8d1ff-meta.json +1 -0
- package/.turbo/cache/6002b76d50b8d1ff.tar.zst +0 -0
- package/.turbo/cache/627e964e19b2bda5-meta.json +1 -0
- package/.turbo/cache/627e964e19b2bda5.tar.zst +0 -0
- package/.turbo/cache/6907ebaae4f3a96b-meta.json +1 -0
- package/.turbo/cache/6907ebaae4f3a96b.tar.zst +0 -0
- package/.turbo/cache/6f7175be597945f7-meta.json +1 -0
- package/.turbo/cache/6f7175be597945f7.tar.zst +0 -0
- package/.turbo/cache/70d7b72f15ee97a4-meta.json +1 -1
- package/.turbo/cache/7cfdc01c415c836c-meta.json +1 -0
- package/.turbo/cache/7cfdc01c415c836c.tar.zst +0 -0
- package/.turbo/cache/897b0d8a0c301207-meta.json +1 -1
- package/.turbo/cache/8b7cdb9a0d4c3112-meta.json +1 -1
- package/.turbo/cache/8e1f402b247ebed6-meta.json +1 -1
- package/.turbo/cache/8e1f402b247ebed6.tar.zst +0 -0
- package/.turbo/cache/90b8d9ccef5e09aa-meta.json +1 -1
- package/.turbo/cache/936bccb44ade3650-meta.json +1 -1
- package/.turbo/cache/94bcc4c6536ada9d-meta.json +1 -1
- package/.turbo/cache/990b9def0e83d33c-meta.json +1 -0
- package/.turbo/cache/990b9def0e83d33c.tar.zst +0 -0
- package/.turbo/cache/a532f4b8302ca13e-meta.json +1 -1
- package/.turbo/cache/a7bf477bbdabc7bc-meta.json +1 -1
- package/.turbo/cache/a90aa34f427a2f62-meta.json +1 -1
- package/.turbo/cache/aedda428051043c4-meta.json +1 -1
- package/.turbo/cache/afc38ab505ef6dbb-meta.json +1 -0
- package/.turbo/cache/{2ca214d032893e74.tar.zst → afc38ab505ef6dbb.tar.zst} +0 -0
- package/.turbo/cache/b1ed317b29e85c9d-meta.json +1 -0
- package/.turbo/cache/b1ed317b29e85c9d.tar.zst +0 -0
- package/.turbo/cache/b61416daf63fbaad-meta.json +1 -1
- package/.turbo/cache/b76edfbd1c076b0a-meta.json +1 -0
- package/.turbo/cache/b76edfbd1c076b0a.tar.zst +0 -0
- package/.turbo/cache/b9463532618cdc61-meta.json +1 -1
- package/.turbo/cache/bb3afea40c91e8ba-meta.json +1 -1
- package/.turbo/cache/c4df38a7e2cc767a-meta.json +1 -0
- package/.turbo/cache/{77bf3068f493ef24.tar.zst → c4df38a7e2cc767a.tar.zst} +0 -0
- package/.turbo/cache/c63dc7b6157da70b-meta.json +1 -1
- package/.turbo/cache/c8b63b6e8a190eb9-meta.json +1 -1
- package/.turbo/cache/d35b1eee9f2881af-meta.json +1 -1
- package/.turbo/cache/d5188c0fbe45d578-meta.json +1 -1
- package/.turbo/cache/e4b3ec56d4ae56ba-meta.json +1 -1
- package/.turbo/cache/e6f030eddf6fbf4e-meta.json +1 -1
- package/.turbo/cache/ff7e6d09efd93145-meta.json +1 -1
- package/.turbo/cache/ff7e6d09efd93145.tar.zst +0 -0
- package/CHANGELOG.md +19 -0
- package/components/checkbox/.turbo/turbo-build.log +3 -3
- package/components/checkbox/.turbo/turbo-bundler.log +3 -3
- package/components/combobox/.turbo/turbo-build.log +6 -3
- package/components/combobox/demo/api.html +1 -0
- package/components/combobox/demo/api.js +2 -0
- package/components/combobox/demo/api.md +73 -0
- package/components/combobox/demo/api.min.js +962 -835
- package/components/combobox/demo/index.min.js +920 -832
- package/components/combobox/dist/auro-combobox.d.ts +20 -0
- package/components/combobox/dist/auro-combobox.d.ts.map +1 -1
- package/components/combobox/dist/index.js +58 -22
- package/components/combobox/src/auro-combobox.js +58 -22
- package/components/counter/.turbo/turbo-build.log +2 -2
- package/components/counter/.turbo/turbo-bundler.log +3 -3
- package/components/datepicker/.turbo/turbo-build.log +2 -2
- package/components/dropdown/.turbo/turbo-build.log +3 -3
- package/components/dropdown/.turbo/turbo-bundler.log +3 -3
- package/components/form/.turbo/turbo-build.log +3 -3
- package/components/form/.turbo/turbo-bundler.log +3 -3
- package/components/input/.turbo/turbo-build.log +3 -3
- package/components/input/.turbo/turbo-bundler.log +3 -3
- package/components/menu/.turbo/turbo-build.log +6 -3
- package/components/menu/.turbo/turbo-bundler.log +3 -3
- package/components/menu/demo/api.html +2 -0
- package/components/menu/demo/api.js +2 -0
- package/components/menu/demo/api.md +164 -22
- package/components/menu/demo/api.min.js +912 -853
- package/components/menu/demo/index.min.js +905 -853
- package/components/menu/dist/auro-menu.d.ts +28 -2
- package/components/menu/dist/auro-menu.d.ts.map +1 -1
- package/components/menu/dist/auro-menuoption.d.ts +1 -1
- package/components/menu/dist/index.js +905 -853
- package/components/menu/src/auro-menu.js +57 -7
- package/components/menu/src/auro-menuoption.js +1 -1
- package/components/menu/src/styles/style-menu-css.js +1 -1
- package/components/menu/src/styles/style-menu.css +21 -3
- package/components/menu/src/styles/style-menu.scss +25 -3
- package/components/radio/.turbo/turbo-build.log +3 -3
- package/components/radio/.turbo/turbo-bundler.log +3 -3
- package/components/select/.turbo/turbo-build.log +6 -3
- package/components/select/demo/api.html +1 -0
- package/components/select/demo/api.js +2 -0
- package/components/select/demo/api.md +66 -0
- package/components/select/demo/api.min.js +927 -811
- package/components/select/demo/index.min.js +895 -811
- package/components/select/dist/auro-select.d.ts +19 -0
- package/components/select/dist/auro-select.d.ts.map +1 -1
- package/components/select/dist/index.js +32 -0
- package/components/select/src/auro-select.js +32 -0
- package/package.json +1 -1
- package/packages/build-tools/src/docProcessor.mjs +4 -4
- package/packages/build-tools/src/kitDocProcessor.mjs +4 -4
- package/.turbo/cache/05be1236a4cd5e72-meta.json +0 -1
- package/.turbo/cache/05be1236a4cd5e72.tar.zst +0 -0
- package/.turbo/cache/2ca214d032893e74-meta.json +0 -1
- package/.turbo/cache/3792d285b464b3e6-meta.json +0 -1
- package/.turbo/cache/3792d285b464b3e6.tar.zst +0 -0
- package/.turbo/cache/3ac4a22a21bdc2be-meta.json +0 -1
- package/.turbo/cache/3ac4a22a21bdc2be.tar.zst +0 -0
- package/.turbo/cache/3f41d958c755a6f0-meta.json +0 -1
- package/.turbo/cache/5d064e768a262314-meta.json +0 -1
- package/.turbo/cache/5d064e768a262314.tar.zst +0 -0
- package/.turbo/cache/6646f884a18a970a-meta.json +0 -1
- package/.turbo/cache/6646f884a18a970a.tar.zst +0 -0
- package/.turbo/cache/71212615220331ea-meta.json +0 -1
- package/.turbo/cache/71212615220331ea.tar.zst +0 -0
- package/.turbo/cache/754a6b5c5ce1ed00-meta.json +0 -1
- package/.turbo/cache/77bf3068f493ef24-meta.json +0 -1
- package/.turbo/cache/7ddb7ace73fe6ec2-meta.json +0 -1
- package/.turbo/cache/7ddb7ace73fe6ec2.tar.zst +0 -0
- package/.turbo/cache/9135f474c69d1b3c-meta.json +0 -1
- package/.turbo/cache/9135f474c69d1b3c.tar.zst +0 -0
- package/.turbo/cache/9a7ab914e08ce75f-meta.json +0 -1
- package/.turbo/cache/9a7ab914e08ce75f.tar.zst +0 -0
- package/.turbo/cache/aa68cd3545395c90-meta.json +0 -1
- package/.turbo/cache/aa68cd3545395c90.tar.zst +0 -0
- package/.turbo/cache/dce6f67be2b63c18-meta.json +0 -1
- package/.turbo/cache/dce6f67be2b63c18.tar.zst +0 -0
- package/.turbo/cache/e28ee527154c4cb2-meta.json +0 -1
- package/.turbo/cache/e28ee527154c4cb2.tar.zst +0 -0
|
@@ -7257,6 +7257,11 @@ class AuroCombobox extends r$6 {
|
|
|
7257
7257
|
*/
|
|
7258
7258
|
this.runtimeUtils = new AuroLibraryRuntimeUtils$2();
|
|
7259
7259
|
|
|
7260
|
+
/**
|
|
7261
|
+
* @private
|
|
7262
|
+
*/
|
|
7263
|
+
this.isHiddenWhileLoading = false;
|
|
7264
|
+
|
|
7260
7265
|
/**
|
|
7261
7266
|
* Generate unique names for dependency components.
|
|
7262
7267
|
*/
|
|
@@ -7392,7 +7397,7 @@ class AuroCombobox extends r$6 {
|
|
|
7392
7397
|
this.noMatchOption = undefined;
|
|
7393
7398
|
|
|
7394
7399
|
this.options.forEach((option) => {
|
|
7395
|
-
let matchString = option.
|
|
7400
|
+
let matchString = option.textContent.toLowerCase();
|
|
7396
7401
|
|
|
7397
7402
|
if (option.hasAttribute('nomatch')) {
|
|
7398
7403
|
this.noMatchOption = option;
|
|
@@ -7468,8 +7473,12 @@ class AuroCombobox extends r$6 {
|
|
|
7468
7473
|
return;
|
|
7469
7474
|
}
|
|
7470
7475
|
if (!this.dropdown.isPopoverVisible && this.input.value && this.input.value.length > 0) {
|
|
7471
|
-
if ((this.availableOptions && this.availableOptions.length > 0) || this.noMatchOption !== undefined) { // eslint-disable-line no-extra-parens
|
|
7472
|
-
this.
|
|
7476
|
+
if (this.menu.getAttribute('loading') || (this.availableOptions && this.availableOptions.length > 0) || this.noMatchOption !== undefined) { // eslint-disable-line no-extra-parens
|
|
7477
|
+
if (this.menu.hasAttribute('loading') && !this.menu.hasLoadingPlaceholder) {
|
|
7478
|
+
this.isHiddenWhileLoading = true;
|
|
7479
|
+
} else {
|
|
7480
|
+
this.dropdown.show();
|
|
7481
|
+
}
|
|
7473
7482
|
}
|
|
7474
7483
|
}
|
|
7475
7484
|
}
|
|
@@ -7501,7 +7510,7 @@ class AuroCombobox extends r$6 {
|
|
|
7501
7510
|
*/
|
|
7502
7511
|
configureMenu() {
|
|
7503
7512
|
this.menu = this.querySelector('auro-menu, [auro-menu]');
|
|
7504
|
-
|
|
7513
|
+
this.menu.addEventListener("auroMenu-loadingChange", (event) => this.handleMenuLoadingChange(event));
|
|
7505
7514
|
|
|
7506
7515
|
// a racing condition on custom-combobox with custom-menu
|
|
7507
7516
|
if (!this.menu) {
|
|
@@ -7512,7 +7521,7 @@ class AuroCombobox extends r$6 {
|
|
|
7512
7521
|
return;
|
|
7513
7522
|
}
|
|
7514
7523
|
|
|
7515
|
-
this.menu.shadowRoot.addEventListener('slotchange', () => this.handleSlotChange());
|
|
7524
|
+
this.menu.shadowRoot.addEventListener('slotchange', (event) => this.handleSlotChange(event));
|
|
7516
7525
|
|
|
7517
7526
|
if (this.checkmark) {
|
|
7518
7527
|
this.menu.removeAttribute('nocheckmark');
|
|
@@ -7534,8 +7543,8 @@ class AuroCombobox extends r$6 {
|
|
|
7534
7543
|
this.value = this.optionSelected.value;
|
|
7535
7544
|
}
|
|
7536
7545
|
|
|
7537
|
-
if (this.input.value !== this.optionSelected.
|
|
7538
|
-
this.input.value = this.optionSelected.
|
|
7546
|
+
if (this.input.value !== this.optionSelected.textContent) {
|
|
7547
|
+
this.input.value = this.optionSelected.textContent;
|
|
7539
7548
|
}
|
|
7540
7549
|
|
|
7541
7550
|
if (this.menu.matchWord !== this.input.value) {
|
|
@@ -7611,7 +7620,7 @@ class AuroCombobox extends r$6 {
|
|
|
7611
7620
|
this.menu.value = this.value;
|
|
7612
7621
|
}
|
|
7613
7622
|
|
|
7614
|
-
if (this.optionSelected && this.input.value !== this.optionSelected.
|
|
7623
|
+
if (this.optionSelected && this.input.value !== this.optionSelected.textContent) {
|
|
7615
7624
|
this.optionSelected = undefined;
|
|
7616
7625
|
}
|
|
7617
7626
|
|
|
@@ -7652,6 +7661,29 @@ class AuroCombobox extends r$6 {
|
|
|
7652
7661
|
});
|
|
7653
7662
|
}
|
|
7654
7663
|
|
|
7664
|
+
/**
|
|
7665
|
+
* Manages the visibility of the dropdown based on loading state changes.
|
|
7666
|
+
*
|
|
7667
|
+
* This method listens for loading state changes and adjusts the visibility of the dropdown accordingly.
|
|
7668
|
+
* If the dropdown is visible and loading is true without any loading placeholders, it hides the dropdown
|
|
7669
|
+
* and sets a flag to indicate it is hidden while loading. If loading is false and the dropdown was previously
|
|
7670
|
+
* hidden, it checks if the active element is within the dropdown and shows it again if true.
|
|
7671
|
+
*
|
|
7672
|
+
* @private
|
|
7673
|
+
* @param {CustomEvent} event - The event object containing details about the loading state change.
|
|
7674
|
+
* @param {boolean} event.detail.loading - Indicates whether the menu is currently loading.
|
|
7675
|
+
* @param {boolean} event.detail.hasLoadingPlaceholder - Indicates if there are loading placeholders present.
|
|
7676
|
+
* @returns {void}
|
|
7677
|
+
*/
|
|
7678
|
+
handleMenuLoadingChange(event) {
|
|
7679
|
+
if (!event.detail.loading && this.isHiddenWhileLoading) {
|
|
7680
|
+
if (this.contains(document.activeElement)) {
|
|
7681
|
+
this.dropdown.show();
|
|
7682
|
+
}
|
|
7683
|
+
this.isHiddenWhileLoading = false;
|
|
7684
|
+
}
|
|
7685
|
+
}
|
|
7686
|
+
|
|
7655
7687
|
/**
|
|
7656
7688
|
* Handle changes to the input value and trigger changes that should result.
|
|
7657
7689
|
* @private
|
|
@@ -7698,7 +7730,7 @@ class AuroCombobox extends r$6 {
|
|
|
7698
7730
|
*/
|
|
7699
7731
|
if (evt.key === 'ArrowUp' || evt.key === 'ArrowDown') {
|
|
7700
7732
|
if (this.availableOptions.length > 0) {
|
|
7701
|
-
this.
|
|
7733
|
+
this.showBib();
|
|
7702
7734
|
}
|
|
7703
7735
|
|
|
7704
7736
|
if (this.dropdown.isPopoverVisible) {
|
|
@@ -7770,8 +7802,8 @@ class AuroCombobox extends r$6 {
|
|
|
7770
7802
|
if (this.value) {
|
|
7771
7803
|
if (this.optionSelected && this.optionSelected.value === this.value) {
|
|
7772
7804
|
// If value updates and the previously selected option already matches the new value
|
|
7773
|
-
// just update the input value to use the
|
|
7774
|
-
this.input.value = this.optionSelected.
|
|
7805
|
+
// just update the input value to use the textContent of the optionSelected
|
|
7806
|
+
this.input.value = this.optionSelected.textContent;
|
|
7775
7807
|
} else {
|
|
7776
7808
|
// Otherwise just enter the value into the input
|
|
7777
7809
|
this.optionSelected = undefined;
|
|
@@ -7801,19 +7833,23 @@ class AuroCombobox extends r$6 {
|
|
|
7801
7833
|
/**
|
|
7802
7834
|
* Watch for slot changes and recalculate the menuoptions.
|
|
7803
7835
|
* @private
|
|
7836
|
+
* @param {Event} event - slotchange event
|
|
7804
7837
|
* @returns {void}
|
|
7805
7838
|
*/
|
|
7806
|
-
handleSlotChange() {
|
|
7807
|
-
|
|
7808
|
-
|
|
7809
|
-
|
|
7810
|
-
|
|
7811
|
-
|
|
7812
|
-
|
|
7813
|
-
|
|
7814
|
-
|
|
7839
|
+
handleSlotChange(event) {
|
|
7840
|
+
// treat only generic menuoptions
|
|
7841
|
+
if (!event.target.name) {
|
|
7842
|
+
this.options = this.menu.querySelectorAll('auro-menuoption, [auro-menuoption]');
|
|
7843
|
+
this.options.forEach((opt) => {
|
|
7844
|
+
if (this.checkmark) {
|
|
7845
|
+
opt.removeAttribute('nocheckmark');
|
|
7846
|
+
} else {
|
|
7847
|
+
opt.setAttribute('nocheckmark', '');
|
|
7848
|
+
}
|
|
7849
|
+
});
|
|
7815
7850
|
|
|
7816
|
-
|
|
7851
|
+
this.handleMenuOptions();
|
|
7852
|
+
}
|
|
7817
7853
|
}
|
|
7818
7854
|
|
|
7819
7855
|
// function that renders the HTML and CSS into the scope of the component
|
|
@@ -7823,7 +7859,7 @@ class AuroCombobox extends r$6 {
|
|
|
7823
7859
|
<div aria-live="polite" class="util_displayHiddenVisually">
|
|
7824
7860
|
${this.optionActive && this.availableOptions.length > 0
|
|
7825
7861
|
? u$6`
|
|
7826
|
-
${`${this.optionActive.
|
|
7862
|
+
${`${this.optionActive.textContent}, selected, ${this.availableOptions.indexOf(this.optionActive) + 1} of ${this.availableOptions.length}`}
|
|
7827
7863
|
`
|
|
7828
7864
|
: undefined
|
|
7829
7865
|
}
|
|
@@ -7866,1033 +7902,1085 @@ class AuroCombobox extends r$6 {
|
|
|
7866
7902
|
}
|
|
7867
7903
|
}
|
|
7868
7904
|
|
|
7869
|
-
var styleCss$2 = i$c`:root{--ds-asset-font-circular-family-name: "AS Circular";--ds-asset-font-circular-filename: "ASCircularWeb";--ds-asset-font-circular-weight-light: "-Light";--ds-asset-font-circular-weight-medium: "-Medium";--ds-asset-font-circular-weight-book: "-Book";--ds-border-radius: 0.375rem;--ds-size-25: 0.125rem;--ds-size-50: 0.25rem;--ds-size-75: 0.375rem;--ds-size-100: 0.5rem;--ds-size-150: 0.75rem;--ds-size-200: 1rem;--ds-size-250: 1.25rem;--ds-size-300: 1.5rem;--ds-size-400: 2rem;--ds-size-500: 2.5rem;--ds-size-600: 3rem;--ds-size-700: 3.5rem;--ds-size-800: 4rem;--ds-size-900: 4.5rem;--ds-size-1000: 5rem;--ds-unitless-scale-20: 0.25;--ds-unitless-scale-50: 0.5;--ds-unitless-scale-100: 1;--ds-unitless-scale-140: 1.4;--ds-unitless-scale-150: 1.5;--ds-unitless-scale-200: 2;--ds-unitless-scale-300: 3;--ds-unitless-scale-350: 3.5;--ds-animation-default-property: all;--ds-animation-default-duration: 0.3s;--ds-animation-default-timing: ease-out;--ds-depth-overlay: 200;--ds-depth-modal: 300;--ds-depth-tooltip: 400;--ds-elevation-100: 0px 0px 5px rgba(0, 0, 0, 0.15);--ds-elevation-200: 0px 0px 10px rgba(0, 0, 0, 0.15);--ds-elevation-300: 0px 0px 15px rgba(0, 0, 0, 0.2);--ds-grid-breakpoint-xs: 320px;--ds-grid-breakpoint-sm: 576px;--ds-grid-breakpoint-md: 768px;--ds-grid-breakpoint-lg: 1024px;--ds-grid-breakpoint-xl: 1232px;--ds-grid-column-xs: 6;--ds-grid-column-sm: 12;--ds-grid-column-md: 12;--ds-grid-column-lg: 12;--ds-grid-column-xl: 12;--ds-grid-gutter-xs: 0.5rem;--ds-grid-gutter-sm: 1rem;--ds-grid-gutter-md: 1.5rem;--ds-grid-gutter-lg: 1.5rem;--ds-grid-gutter-xl: 2rem;--ds-grid-margin-xs: 1rem;--ds-grid-margin-sm: 1rem;--ds-grid-margin-md: 1.5rem;--ds-grid-margin-lg: 2rem;--ds-grid-margin-xl: 2rem;--ds-font-family-default: "AS Circular", Helvetica Neue, Arial, sans-serif;--ds-font-family-mono: Menlo, Monaco, Consolas, "Courier New", monospace;--ds-text-heading-300-weight: 300;--ds-text-heading-300-px: 18px;--ds-text-heading-300-size: 1.125rem;--ds-text-heading-300-height: 1.625rem;--ds-text-heading-300-height-px: 26px;--ds-text-heading-400-weight: 300;--ds-text-heading-400-px: 20px;--ds-text-heading-400-size: 1.25rem;--ds-text-heading-400-height: 1.625rem;--ds-text-heading-400-height-px: 26px;--ds-text-heading-500-weight: 300;--ds-text-heading-500-px-breakpoint-sm: 22px;--ds-text-heading-500-px-breakpoint-md: 24px;--ds-text-heading-500-px-breakpoint-lg: 24px;--ds-text-heading-500-size-breakpoint-sm: 1.375rem;--ds-text-heading-500-size-breakpoint-md: 1.5rem;--ds-text-heading-500-size-breakpoint-lg: 1.5rem;--ds-text-heading-500-height-breakpoint-sm: 1.625rem;--ds-text-heading-500-height-breakpoint-px-sm: 26px;--ds-text-heading-500-height-breakpoint-md: 1.875rem;--ds-text-heading-500-height-breakpoint-px-md: 30px;--ds-text-heading-500-height-breakpoint-lg: 2rem;--ds-text-heading-500-height-breakpoint-px-lg: 32px;--ds-text-heading-600-weight: 300;--ds-text-heading-600-px-breakpoint-sm: 26px;--ds-text-heading-600-px-breakpoint-md: 28px;--ds-text-heading-600-px-breakpoint-lg: 28px;--ds-text-heading-600-size-breakpoint-sm: 1.625rem;--ds-text-heading-600-size-breakpoint-md: 1.75rem;--ds-text-heading-600-size-breakpoint-lg: 1.75rem;--ds-text-heading-600-height-breakpoint-sm: 1.875rem;--ds-text-heading-600-height-breakpoint-px-sm: 30px;--ds-text-heading-600-height-breakpoint-md: 2.125rem;--ds-text-heading-600-height-breakpoint-px-md: 34px;--ds-text-heading-600-height-breakpoint-lg: 2.25rem;--ds-text-heading-600-height-breakpoint-px-lg: 36px;--ds-text-heading-700-weight: 500;--ds-text-heading-700-px-breakpoint-sm: 28px;--ds-text-heading-700-px-breakpoint-md: 32px;--ds-text-heading-700-px-breakpoint-lg: 36px;--ds-text-heading-700-size-breakpoint-sm: 1.75rem;--ds-text-heading-700-size-breakpoint-md: 2rem;--ds-text-heading-700-size-breakpoint-lg: 2.25rem;--ds-text-heading-700-height-breakpoint-sm: 2.125rem;--ds-text-heading-700-height-breakpoint-px-sm: 34px;--ds-text-heading-700-height-breakpoint-md: 2.375rem;--ds-text-heading-700-height-breakpoint-px-md: 38px;--ds-text-heading-700-height-breakpoint-lg: 2.75rem;--ds-text-heading-700-height-breakpoint-px-lg: 44px;--ds-text-heading-800-weight: 500;--ds-text-heading-800-px-breakpoint-sm: 32px;--ds-text-heading-800-px-breakpoint-md: 36px;--ds-text-heading-800-px-breakpoint-lg: 40px;--ds-text-heading-800-size-breakpoint-sm: 2rem;--ds-text-heading-800-size-breakpoint-md: 2.25rem;--ds-text-heading-800-size-breakpoint-lg: 2.5rem;--ds-text-heading-800-height-breakpoint-sm: 2.375rem;--ds-text-heading-800-height-breakpoint-px-sm: 38px;--ds-text-heading-800-height-breakpoint-md: 2.625rem;--ds-text-heading-800-height-breakpoint-px-md: 42px;--ds-text-heading-800-height-breakpoint-lg: 3rem;--ds-text-heading-800-height-breakpoint-px-lg: 48px;--ds-text-heading-default-weight: 500;--ds-text-heading-default-margin: 0;--ds-text-heading-default-spacing: -0.2px;--ds-text-heading-medium-weight: 300;--ds-text-heading-display-weight: 100;--ds-text-heading-display-px-breakpoint-sm: 44px;--ds-text-heading-display-px-breakpoint-md: 48px;--ds-text-heading-display-px-breakpoint-lg: 56px;--ds-text-heading-display-size-breakpoint-sm: 2.75rem;--ds-text-heading-display-size-breakpoint-md: 3rem;--ds-text-heading-display-size-breakpoint-lg: 3.5rem;--ds-text-heading-display-height-breakpoint-sm: 3.375rem;--ds-text-heading-display-height-breakpoint-px-sm: 54px;--ds-text-heading-display-height-breakpoint-md: 3.75rem;--ds-text-heading-display-height-breakpoint-px-md: 60px;--ds-text-heading-display-height-breakpoint-lg: 4.25rem;--ds-text-heading-display-height-breakpoint-px-lg: 68px;--ds-text-body-default-weight: 500;--ds-text-body-size-xxs: 0.625rem;--ds-text-body-size-xs: 0.75rem;--ds-text-body-size-sm: 0.875rem;--ds-text-body-size-default: 1rem;--ds-text-body-size-lg: 1.125rem;--ds-text-body-height-xs: 1rem;--ds-text-body-height-sm: 1.25rem;--ds-text-body-height-default: 1.5rem;--ds-text-body-height-lg: 1.625rem;--ds-color-alert-notification-default: #0074c8;--ds-color-alert-warning-default: #de750c;--ds-color-alert-error-default: #df0b37;--ds-color-alert-success-default: #00805d;--ds-color-alert-advisory-default: #fff0cd;--ds-color-alert-bkg-success-default: #ddf6e8;--ds-color-alert-bkg-error-default: #ffedf1;--ds-color-background-primary-100-default: #ffffff;--ds-color-background-primary-100-inverse: #0e2b4f;--ds-color-background-primary-200-default: #f7f7f7;--ds-color-background-primary-200-inverse: #194069;--ds-color-background-primary-300-default: #e4e8ec;--ds-color-background-primary-300-inverse: #265688;--ds-color-background-primary-400-default: #dddddd;--ds-color-background-primary-400-inverse: #326aa5;--ds-color-background-success-default: #eef8f5;--ds-color-background-success-inverse: #173c30;--ds-color-background-error-default: #fff4f4;--ds-color-background-error-inverse: #74110e;--ds-color-background-warning-default: #fef8e9;--ds-color-background-warning-inverse: #5d4514;--ds-color-background-info-default: #f0f7fd;--ds-color-background-info-inverse: #193d73;--ds-color-background-subtle-default: #f7f8fa;--ds-color-background-subtle-inverse: #2a2a2a;--ds-color-background-accent-default: #ebfafd;--ds-color-background-accent-inverse: #275b72;--ds-color-background-emphasis-default: #c9e0f7;--ds-color-background-emphasis-inverse: #225296;--ds-color-background-scrimmed-default: rgba(0, 0, 0, 0.5);--ds-color-background-lightest: #ffffff;--ds-color-background-lighter: #f7f7f7;--ds-color-background-darker: #01426a;--ds-color-background-darkest: #00274a;--ds-color-background-gradient-default: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5));--ds-color-base-white: #ffffff;--ds-color-base-white-100: rgba(255, 255, 255, 0.03);--ds-color-base-white-200: rgba(255, 255, 255, 0.06);--ds-color-base-white-300: rgba(255, 255, 255, 0.12);--ds-color-base-white-400: rgba(255, 255, 255, 0.25);--ds-color-base-white-500: rgba(255, 255, 255, 0.5);--ds-color-base-white-opacity-50: rgba(255, 255, 255, 0.5);--ds-color-base-white-opacity-40: rgba(255, 255, 255, 0.4);--ds-color-base-white-opacity-0: rgba(255, 255, 255, 0);--ds-color-base-black: #000000;--ds-color-base-black-100: rgba(0, 0, 0, 0.03);--ds-color-base-black-200: rgba(0, 0, 0, 0.06);--ds-color-base-black-300: rgba(0, 0, 0, 0.12);--ds-color-base-black-400: rgba(0, 0, 0, 0.25);--ds-color-base-black-500: rgba(0, 0, 0, 0.5);--ds-color-base-black-opacity-15: rgba(0, 0, 0, 0.15);--ds-color-base-blue-100: #f0f7fd;--ds-color-base-blue-200: #c9e0f7;--ds-color-base-blue-300: #a0c9f1;--ds-color-base-blue-400: #79b2ec;--ds-color-base-blue-500: #5398e6;--ds-color-base-blue-600: #3b7fd2;--ds-color-base-blue-700: #2c67b5;--ds-color-base-blue-800: #225296;--ds-color-base-blue-900: #193d73;--ds-color-base-blue-1000: #102a51;--ds-color-base-cyan-100: #ebfafd;--ds-color-base-cyan-200: #a8e9f7;--ds-color-base-cyan-300: #6ad5ef;--ds-color-base-cyan-400: #56bbde;--ds-color-base-cyan-500: #4aa2c7;--ds-color-base-cyan-600: #3e89aa;--ds-color-base-cyan-700: #32718e;--ds-color-base-cyan-800: #275b72;--ds-color-base-cyan-900: #1d4658;--ds-color-base-cyan-1000: #12303d;--ds-color-base-error-100: #fff4f4;--ds-color-base-error-200: #f9aca6;--ds-color-base-error-300: #f16359;--ds-color-base-error-400: #cc1816;--ds-color-base-error-500: #74110e;--ds-color-base-gray-100: #f7f7f7;--ds-color-base-gray-200: #d4d4d4;--ds-color-base-gray-300: #c5c5c5;--ds-color-base-gray-400: #adadad;--ds-color-base-gray-500: #959595;--ds-color-base-gray-600: #7e7e7e;--ds-color-base-gray-700: #676767;--ds-color-base-gray-800: #525252;--ds-color-base-gray-900: #3d3d3d;--ds-color-base-gray-1000: #2a2a2a;--ds-color-base-green-100: #f3faf7;--ds-color-base-green-200: #000000;--ds-color-base-green-300: #addbca;--ds-color-base-green-400: #7ec6ac;--ds-color-base-green-500: #51ae8c;--ds-color-base-green-600: #459578;--ds-color-base-green-700: #3a7d64;--ds-color-base-green-800: #306854;--ds-color-base-green-900: #285545;--ds-color-base-green-1000: #1f4436;--ds-color-base-lime-100: #f5fbeb;--ds-color-base-lime-200: #d8efb4;--ds-color-base-lime-300: #badd81;--ds-color-base-lime-400: #a2c270;--ds-color-base-lime-500: #8ca761;--ds-color-base-lime-600: #778f53;--ds-color-base-lime-700: #647845;--ds-color-base-lime-800: #53643a;--ds-color-base-lime-900: #44522f;--ds-color-base-lime-1000: #364126;--ds-color-base-navy-100: #f2f7fb;--ds-color-base-navy-200: #cfe0ef;--ds-color-base-navy-300: #acc9e2;--ds-color-base-navy-400: #89b2d4;--ds-color-base-navy-500: #6899c6;--ds-color-base-navy-600: #4a82b7;--ds-color-base-navy-700: #326aa5;--ds-color-base-navy-800: #265688;--ds-color-base-navy-900: #194069;--ds-color-base-navy-1000: #0e2b4f;--ds-color-base-neutral-100: #f7f8fa;--ds-color-base-neutral-200: #e4e8ec;--ds-color-base-neutral-300: #ccd2db;--ds-color-base-neutral-400: #afb9c6;--ds-color-base-neutral-500: #939fad;--ds-color-base-neutral-600: #7e8894;--ds-color-base-neutral-700: #6a717c;--ds-color-base-neutral-800: #585e67;--ds-color-base-neutral-900: #484d55;--ds-color-base-neutral-1000: #393d43;--ds-color-base-pink-100: #fff7f8;--ds-color-base-pink-200: #fde0e6;--ds-color-base-pink-300: #fcc2ce;--ds-color-base-pink-400: #fa9db0;--ds-color-base-pink-500: #f7738e;--ds-color-base-pink-600: #e45472;--ds-color-base-pink-700: #bf475f;--ds-color-base-pink-800: #a03b50;--ds-color-base-pink-900: #833142;--ds-color-base-pink-1000: #692734;--ds-color-base-purple-100: #fbf8fe;--ds-color-base-purple-200: #ede3fd;--ds-color-base-purple-300: #ddc9fb;--ds-color-base-purple-400: #c9a9f8;--ds-color-base-purple-500: #b588f5;--ds-color-base-purple-600: #a268f3;--ds-color-base-purple-700: #8d47f0;--ds-color-base-purple-800: #7633d7;--ds-color-base-purple-900: #622ab2;--ds-color-base-purple-1000: #4e228d;--ds-color-base-red-100: #fef7f5;--ds-color-base-red-200: #fae2da;--ds-color-base-red-300: #f5c7b8;--ds-color-base-red-400: #f0a68d;--ds-color-base-red-500: #e9815e;--ds-color-base-red-600: #e35c2f;--ds-color-base-red-700: #d03a08;--ds-color-base-red-800: #ae3007;--ds-color-base-red-900: #902806;--ds-color-base-red-1000: #732005;--ds-color-base-success-100: #eef8f5;--ds-color-base-success-200: #8eceb9;--ds-color-base-success-300: #40a080;--ds-color-base-success-400: #0b6f4d;--ds-color-base-success-500: #173c30;--ds-color-base-turquoise-100: #f7fafa;--ds-color-base-turquoise-200: #dfe9ea;--ds-color-base-turquoise-300: #c2d5d6;--ds-color-base-turquoise-400: #9fbdbe;--ds-color-base-turquoise-500: #7ba5a6;--ds-color-base-turquoise-600: #5c8f91;--ds-color-base-turquoise-700: #3d7a7d;--ds-color-base-turquoise-800: #21686a;--ds-color-base-turquoise-900: #085659;--ds-color-base-turquoise-1000: #004447;--ds-color-base-yellow-100: #fff9df;--ds-color-base-yellow-200: #ffe87e;--ds-color-base-yellow-300: #f9ce06;--ds-color-base-yellow-400: #d6b622;--ds-color-base-yellow-500: #b49d35;--ds-color-base-yellow-600: #96873e;--ds-color-base-yellow-700: #7c7140;--ds-color-base-yellow-800: #665e3d;--ds-color-base-yellow-900: #524e38;--ds-color-base-yellow-1000: #403d30;--ds-color-base-warning-100: #fef8e9;--ds-color-base-warning-200: #f2c153;--ds-color-base-warning-300: #c49432;--ds-color-base-warning-400: #8e6b22;--ds-color-base-warning-500: #5d4514;--ds-color-state-error-100: #ff999b;--ds-color-state-error-500: #df0b37;--ds-color-state-success-100: #69cf96;--ds-color-state-success-500: #00805d;--ds-color-state-warning-500: #de750c;--ds-color-border-primary-default: #585e67;--ds-color-border-primary-inverse: #afb9c6;--ds-color-border-secondary-default: #939fad;--ds-color-border-secondary-inverse: #7e8894;--ds-color-border-tertiary-default: #dddddd;--ds-color-border-tertiary-inverse: #676767;--ds-color-border-error-default: #cc1816;--ds-color-border-error-inverse: #f9aca6;--ds-color-border-divider-default: rgba(0, 0, 0, 0.12);--ds-color-border-divider-inverse: rgba(255, 255, 255, 0.25);--ds-color-border-subtle-default: #f0f7fd;--ds-color-border-subtle-inverse: #326aa5;--ds-color-border-emphasis-default: #194069;--ds-color-border-emphasis-inverse: #f2f7fb;--ds-color-border-accent-default: #badd81;--ds-color-border-accent-inverse: #a2c270;--ds-color-border-success-default: #0b6f4d;--ds-color-border-success-inverse: #8eceb9;--ds-color-border-warning-default: #c49432;--ds-color-border-warning-inverse: #f2c153;--ds-color-border-info-default: #326aa5;--ds-color-border-info-inverse: #89b2d4;--ds-color-border-ui-default-default: #2c67b5;--ds-color-border-ui-default-inverse: #56bbde;--ds-color-border-ui-hover-default: #193d73;--ds-color-border-ui-hover-inverse: #a8e9f7;--ds-color-border-ui-active-default: #225296;--ds-color-border-ui-active-inverse: #6ad5ef;--ds-color-border-ui-focus-default: #2c67b5;--ds-color-border-ui-focus-inverse: #56bbde;--ds-color-border-ui-disabled-default: #adadad;--ds-color-border-ui-disabled-inverse: #7e7e7e;--ds-color-border-active-default: #0074c8;--ds-color-border-active-inverse: #00cff0;--ds-color-border-disabled-default: #d4d4d4;--ds-color-border-focus-default: #959595;--ds-color-brand-neutral-100: #f7f8fa;--ds-color-brand-neutral-200: #e4e8ec;--ds-color-brand-neutral-300: #ccd2db;--ds-color-brand-neutral-400: #afb9c6;--ds-color-brand-neutral-500: #939fad;--ds-color-brand-neutral-600: #7e8894;--ds-color-brand-neutral-700: #6a717c;--ds-color-brand-neutral-800: #585e67;--ds-color-brand-neutral-900: #484d55;--ds-color-brand-neutral-1000: #393d43;--ds-color-brand-gray-100: #f7f7f7;--ds-color-brand-gray-200: #dddddd;--ds-color-brand-gray-300: #c5c5c5;--ds-color-brand-gray-400: #adadad;--ds-color-brand-gray-500: #959595;--ds-color-brand-gray-600: #7e7e7e;--ds-color-brand-gray-700: #676767;--ds-color-brand-gray-800: #525252;--ds-color-brand-gray-900: #3d3d3d;--ds-color-brand-gray-1000: #2a2a2a;--ds-color-brand-red-100: #fef7f5;--ds-color-brand-red-200: #fae2da;--ds-color-brand-red-300: #f5c7b8;--ds-color-brand-red-400: #f0a68d;--ds-color-brand-red-500: #e9815e;--ds-color-brand-red-600: #e35c2f;--ds-color-brand-red-700: #d03a08;--ds-color-brand-red-800: #ae3007;--ds-color-brand-red-900: #902806;--ds-color-brand-red-1000: #732005;--ds-color-brand-yellow-100: #fff9df;--ds-color-brand-yellow-200: #ffe87e;--ds-color-brand-yellow-300: #f9ce06;--ds-color-brand-yellow-400: #d6b622;--ds-color-brand-yellow-500: #b49d35;--ds-color-brand-yellow-600: #96873e;--ds-color-brand-yellow-700: #7c7140;--ds-color-brand-yellow-800: #665e3d;--ds-color-brand-yellow-900: #524e38;--ds-color-brand-yellow-1000: #403d30;--ds-color-brand-lime-100: #f5fbeb;--ds-color-brand-lime-200: #d8efb4;--ds-color-brand-lime-300: #badd81;--ds-color-brand-lime-400: #a2c270;--ds-color-brand-lime-500: #8ca761;--ds-color-brand-lime-600: #778f53;--ds-color-brand-lime-700: #647845;--ds-color-brand-lime-800: #53643a;--ds-color-brand-lime-900: #44522f;--ds-color-brand-lime-1000: #364126;--ds-color-brand-green-100: #f3faf7;--ds-color-brand-green-200: #d4ece4;--ds-color-brand-green-300: #addbca;--ds-color-brand-green-400: #7ec6ac;--ds-color-brand-green-500: #51ae8c;--ds-color-brand-green-600: #459578;--ds-color-brand-green-700: #3a7d64;--ds-color-brand-green-800: #306854;--ds-color-brand-green-900: #285545;--ds-color-brand-green-1000: #1f4436;--ds-color-brand-turquoise-100: #f7fafa;--ds-color-brand-turquoise-200: #dfe9ea;--ds-color-brand-turquoise-300: #c2d5d6;--ds-color-brand-turquoise-400: #9fbdbe;--ds-color-brand-turquoise-500: #7ba5a6;--ds-color-brand-turquoise-600: #5c8f91;--ds-color-brand-turquoise-700: #3d7a7d;--ds-color-brand-turquoise-800: #21686a;--ds-color-brand-turquoise-900: #085659;--ds-color-brand-turquoise-1000: #004447;--ds-color-brand-cyan-100: #ebfafd;--ds-color-brand-cyan-200: #a8e9f7;--ds-color-brand-cyan-300: #6ad5ef;--ds-color-brand-cyan-400: #56bbde;--ds-color-brand-cyan-500: #4aa2c7;--ds-color-brand-cyan-600: #3e89aa;--ds-color-brand-cyan-700: #32718e;--ds-color-brand-cyan-800: #275b72;--ds-color-brand-cyan-900: #1d4658;--ds-color-brand-cyan-1000: #12303d;--ds-color-brand-blue-100: #f0f7fd;--ds-color-brand-blue-200: #c9e0f7;--ds-color-brand-blue-300: #a0c9f1;--ds-color-brand-blue-400: #79b2ec;--ds-color-brand-blue-500: #5398e6;--ds-color-brand-blue-600: #3b7fd2;--ds-color-brand-blue-700: #2c67b5;--ds-color-brand-blue-800: #225296;--ds-color-brand-blue-900: #193d73;--ds-color-brand-blue-1000: #102a51;--ds-color-brand-navy-100: #f2f7fb;--ds-color-brand-navy-200: #cfe0ef;--ds-color-brand-navy-300: #acc9e2;--ds-color-brand-navy-400: #89b2d4;--ds-color-brand-navy-500: #6899c6;--ds-color-brand-navy-600: #4a82b7;--ds-color-brand-navy-700: #326aa5;--ds-color-brand-navy-800: #265688;--ds-color-brand-navy-900: #194069;--ds-color-brand-navy-1000: #0e2b4f;--ds-color-brand-purple-100: #fbf8fe;--ds-color-brand-purple-200: #ede3fd;--ds-color-brand-purple-300: #ddc9fb;--ds-color-brand-purple-400: #c9a9f8;--ds-color-brand-purple-500: #b588f5;--ds-color-brand-purple-600: #a268f3;--ds-color-brand-purple-700: #8d47f0;--ds-color-brand-purple-800: #7633d7;--ds-color-brand-purple-900: #622ab2;--ds-color-brand-purple-1000: #4e228d;--ds-color-brand-pink-100: #fff7f8;--ds-color-brand-pink-200: #fde0e6;--ds-color-brand-pink-300: #fcc2ce;--ds-color-brand-pink-400: #fa9db0;--ds-color-brand-pink-500: #f7738e;--ds-color-brand-pink-600: #e45472;--ds-color-brand-pink-700: #bf475f;--ds-color-brand-pink-800: #a03b50;--ds-color-brand-pink-900: #833142;--ds-color-brand-pink-1000: #692734;--ds-color-brand-midnight-100: #c1daf0;--ds-color-brand-midnight-200: #569ed7;--ds-color-brand-midnight-300: #156fad;--ds-color-brand-midnight-400: #01426a;--ds-color-brand-midnight-500: #00274a;--ds-color-brand-atlas-100: #cde6ff;--ds-color-brand-atlas-200: #6bb7fb;--ds-color-brand-atlas-300: #2492eb;--ds-color-brand-atlas-400: #0074c8;--ds-color-brand-atlas-500: #054687;--ds-color-brand-atlas-400-opacity-20: rgba(0, 116, 200, 0.2);--ds-color-brand-breeze-100: #c0f7ff;--ds-color-brand-breeze-200: #5de3f7;--ds-color-brand-breeze-300: #00cff0;--ds-color-brand-breeze-400: #099dc5;--ds-color-brand-breeze-500: #0b5575;--ds-color-brand-breeze-300-opacity-30: rgba(0, 207, 240, 0.3);--ds-color-brand-tropical-100: #e2ffcd;--ds-color-brand-tropical-200: #d0fba6;--ds-color-brand-tropical-300: #c0e585;--ds-color-brand-tropical-400: #91be62;--ds-color-brand-tropical-500: #5e8741;--ds-color-brand-alpine-100: #bcaae6;--ds-color-brand-alpine-200: #9e73ea;--ds-color-brand-alpine-300: #8439ef;--ds-color-brand-alpine-400: #631db8;--ds-color-brand-alpine-500: #39115c;--ds-color-brand-flamingo-100: #ffebee;--ds-color-brand-flamingo-200: #ffc0ca;--ds-color-brand-flamingo-300: #ff94a7;--ds-color-brand-flamingo-400: #f65b7b;--ds-color-brand-flamingo-500: #b82b47;--ds-color-brand-canyon-100: #ffcab6;--ds-color-brand-canyon-200: #f99574;--ds-color-brand-canyon-300: #f26135;--ds-color-brand-canyon-400: #de3e09;--ds-color-brand-canyon-500: #b83302;--ds-color-brand-goldcoast-100: #fff0cd;--ds-color-brand-goldcoast-200: #ffdb67;--ds-color-brand-goldcoast-300: #ffd200;--ds-color-brand-goldcoast-400: #e5ad07;--ds-color-brand-goldcoast-500: #b88624;--ds-color-brand-goldgray-100: #c5c1bf;--ds-color-brand-goldgray-200: #726e6c;--ds-color-brand-gold-100: #ccbc94;--ds-color-brand-gold-200: #7f682e;--ds-color-brand-emerald: #139142;--ds-color-brand-sapphire: #015daa;--ds-color-brand-ruby: #a41d4a;--ds-color-brand-lounge: #01426a;--ds-color-brand-loungeplus: #53b390;--ds-color-container-accent-default: #f5fbeb;--ds-color-container-accent-inverse: #badd81;--ds-color-container-emphasis-default: #ebfafd;--ds-color-container-emphasis-inverse: #6ad5ef;--ds-color-container-error-default: #fff4f4;--ds-color-container-error-inverse: #74110e;--ds-color-container-info-default: #f0f7fd;--ds-color-container-info-inverse: #193d73;--ds-color-container-primary-default: #ffffff;--ds-color-container-primary-inverse: #0e2b4f;--ds-color-container-secondary-default: #f7f7f7;--ds-color-container-secondary-inverse: #194069;--ds-color-container-subtle-default: #f7f8fa;--ds-color-container-subtle-inverse: #393d43;--ds-color-container-success-default: #eef8f5;--ds-color-container-success-inverse: #173c30;--ds-color-container-tertiary-default: rgba(0, 0, 0, 0.03);--ds-color-container-tertiary-inverse: rgba(255, 255, 255, 0.06);--ds-color-container-warning-default: #fef8e9;--ds-color-container-warning-inverse: #5d4514;--ds-color-container-ui-primary-active-default: #225296;--ds-color-container-ui-primary-active-inverse: #6ad5ef;--ds-color-container-ui-primary-default-default: #2c67b5;--ds-color-container-ui-primary-default-inverse: #56bbde;--ds-color-container-ui-primary-disabled-default: #a0c9f1;--ds-color-container-ui-primary-disabled-inverse: #275b72;--ds-color-container-ui-primary-focus-default: #2c67b5;--ds-color-container-ui-primary-focus-inverse: #56bbde;--ds-color-container-ui-primary-hover-default: #193d73;--ds-color-container-ui-primary-hover-inverse: #a8e9f7;--ds-color-container-ui-secondary-active-default: #f0f7fd;--ds-color-container-ui-secondary-active-inverse: rgba(255, 255, 255, 0.06);--ds-color-container-ui-secondary-default-default: #ffffff;--ds-color-container-ui-secondary-default-inverse: rgba(255, 255, 255, 0.03);--ds-color-container-ui-secondary-disabled-default: #f7f7f7;--ds-color-container-ui-secondary-disabled-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-secondary-focus-default: #ffffff;--ds-color-container-ui-secondary-focus-inverse: rgba(255, 255, 255, 0.03);--ds-color-container-ui-secondary-hover-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-secondary-hover-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-tertiary-active-default: rgba(0, 0, 0, 0.06);--ds-color-container-ui-tertiary-active-inverse: rgba(255, 255, 255, 0.06);--ds-color-container-ui-tertiary-default-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-tertiary-default-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-tertiary-disabled-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-tertiary-disabled-inverse: rgba(255, 255, 255, 0.25);--ds-color-container-ui-tertiary-focus-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-tertiary-focus-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-tertiary-hover-default: rgba(0, 0, 0, 0.12);--ds-color-container-ui-tertiary-hover-inverse: rgba(255, 255, 255, 0.25);--ds-color-icon-primary-default: #676767;--ds-color-icon-primary-inverse: #f7f7f7;--ds-color-icon-secondary-default: #7e8894;--ds-color-icon-secondary-inverse: #ccd2db;--ds-color-icon-tertiary-default: #afb9c6;--ds-color-icon-tertiary-inverse: #939fad;--ds-color-icon-emphasis-default: #2a2a2a;--ds-color-icon-emphasis-inverse: #ffffff;--ds-color-icon-accent-default: #a2c270;--ds-color-icon-accent-inverse: #badd81;--ds-color-icon-info-default: #326aa5;--ds-color-icon-info-inverse: #89b2d4;--ds-color-icon-error-default: #cc1816;--ds-color-icon-error-inverse: #f9aca6;--ds-color-icon-warning-default: #c49432;--ds-color-icon-warning-inverse: #f2c153;--ds-color-icon-success-default: #40a080;--ds-color-icon-success-inverse: #8eceb9;--ds-color-icon-subtle-default: #a0c9f1;--ds-color-icon-subtle-inverse: #326aa5;--ds-color-icon-ui-primary-default-default: #2c67b5;--ds-color-icon-ui-primary-default-inverse: #56bbde;--ds-color-icon-ui-primary-hover-default: #193d73;--ds-color-icon-ui-primary-hover-inverse: #a8e9f7;--ds-color-icon-ui-primary-active-default: #225296;--ds-color-icon-ui-primary-active-inverse: #6ad5ef;--ds-color-icon-ui-primary-disabled-default: #adadad;--ds-color-icon-ui-primary-disabled-inverse: #7e7e7e;--ds-color-icon-ui-primary-focus-default: #2c67b5;--ds-color-icon-ui-primary-focus-inverse: #56bbde;--ds-color-icon-ui-secondary-active-default: #676767;--ds-color-icon-ui-secondary-active-inverse: #c5c5c5;--ds-color-icon-ui-secondary-default-default: #7e7e7e;--ds-color-icon-ui-secondary-default-inverse: #adadad;--ds-color-icon-ui-secondary-disabled-default: #adadad;--ds-color-icon-ui-secondary-disabled-inverse: #7e7e7e;--ds-color-icon-ui-secondary-focus-default: #7e7e7e;--ds-color-icon-ui-secondary-focus-inverse: #adadad;--ds-color-icon-ui-secondary-hover-default: #525252;--ds-color-icon-ui-secondary-hover-inverse: #dddddd;--ds-color-icon-brand-red-default: #d03a08;--ds-color-icon-brand-red-inverse: #e9815e;--ds-color-icon-brand-yellow-default: #7c7140;--ds-color-icon-brand-yellow-inverse: #f9ce06;--ds-color-icon-brand-pink-default: #bf475f;--ds-color-icon-brand-pink-inverse: #f7738e;--ds-color-icon-brand-purple-default: #8d47f0;--ds-color-icon-brand-purple-inverse: #b588f5;--ds-color-icon-brand-lime-default: #647845;--ds-color-icon-brand-lime-inverse: #badd81;--ds-color-icon-brand-green-default: #3a7d64;--ds-color-icon-brand-green-inverse: #51ae8c;--ds-color-icon-brand-turquoise-default: #3d7a7d;--ds-color-icon-brand-turquoise-inverse: #7ba5a6;--ds-color-icon-brand-navy-default: #265688;--ds-color-icon-brand-navy-inverse: #6899c6;--ds-color-icon-brand-blue-default: #2c67b5;--ds-color-icon-brand-blue-inverse: #5398e6;--ds-color-icon-brand-cyan-default: #32718e;--ds-color-icon-brand-cyan-inverse: #6ad5ef;--ds-color-icon-brand-gray-default: #676767;--ds-color-icon-brand-gray-inverse: #c5c5c5;--ds-color-icon-brand-neutral-default: #6a717c;--ds-color-icon-brand-neutral-inverse: #afb9c6;--ds-color-icon-disabled-default: rgba(0, 0, 0, 0.15);--ds-color-text-primary-default: #2a2a2a;--ds-color-text-primary-inverse: #ffffff;--ds-color-text-secondary-default: #525252;--ds-color-text-secondary-inverse: #dddddd;--ds-color-text-tertiary-default: #6a717c;--ds-color-text-tertiary-inverse: #adadad;--ds-color-text-error-default: #cc1816;--ds-color-text-error-inverse: #f9aca6;--ds-color-text-emphasis-default: #265688;--ds-color-text-emphasis-inverse: #cfe0ef;--ds-color-text-accent-default: #647845;--ds-color-text-accent-inverse: #badd81;--ds-color-text-info-default: #326aa5;--ds-color-text-info-inverse: #acc9e2;--ds-color-text-subtle-default: #32718e;--ds-color-text-subtle-inverse: #56bbde;--ds-color-text-success-default: #0b6f4d;--ds-color-text-success-inverse: #8eceb9;--ds-color-text-ui-active-default: #225296;--ds-color-text-ui-active-inverse: #6ad5ef;--ds-color-text-ui-default-default: #2c67b5;--ds-color-text-ui-default-inverse: #56bbde;--ds-color-text-ui-disabled-default: #adadad;--ds-color-text-ui-disabled-inverse: #7e7e7e;--ds-color-text-ui-focus-default: #2c67b5;--ds-color-text-ui-focus-inverse: #56bbde;--ds-color-text-ui-hover-default: #193d73;--ds-color-text-ui-hover-inverse: #a8e9f7;--ds-color-text-link-default: #0074c8;--ds-color-text-link-inverse: #00cff0;--ds-color-tier-alaska-mvp-default: #726e6c;--ds-color-tier-alaska-mvp-inverse: #c5c1bf;--ds-color-tier-alaska-mvpgold-default: #7f682e;--ds-color-tier-alaska-mvpgold-inverse: #c5c1bf;--ds-color-tier-alaska-mvpgold75k-default: #7f682e;--ds-color-tier-alaska-mvpgold75k-inverse: #c5c1bf;--ds-color-tier-alaska-mvpgold100k-default: #7f682e;--ds-color-tier-alaska-mvpgold100k-inverse: #c5c1bf;--ds-color-tier-alaska-lounge: #01426a;--ds-color-tier-alaska-loungeplus: #53b390;--ds-color-tier-fare-business-default: #005154;--ds-color-tier-fare-business-inverse: #9fbdbe;--ds-color-tier-fare-economy-default: #2c67b5;--ds-color-tier-fare-economy-inverse: #a0c9f1;--ds-color-tier-fare-first-class-default: #002c4e;--ds-color-tier-fare-first-class-inverse: #89b2d4;--ds-color-tier-fare-saver-default: #4aa2c7;--ds-color-tier-fare-saver-inverse: #a8e9f7;--ds-color-tier-oneworld-emerald: #139142;--ds-color-tier-oneworld-sapphire: #015daa;--ds-color-tier-oneworld-ruby: #a41d4a;--ds-color-ui-default-default: #0074c8;--ds-color-ui-default-inverse: #00cff0;--ds-color-ui-hover-default: #054687;--ds-color-ui-hover-inverse: #5de3f7;--ds-color-ui-active-default: #054687;--ds-color-ui-active-inverse: #5de3f7;--ds-color-ui-disabled-default: rgba(0, 116, 200, 0.2);--ds-color-ui-bkg-default-default: rgba(0, 0, 0, 0.03);--ds-color-ui-bkg-default-inverse: rgba(255, 255, 255, 0.03);--ds-color-ui-bkg-hover-default: rgba(0, 0, 0, 0.06);--ds-color-ui-bkg-hover-inverse: rgba(255, 255, 255, 0.06);--ds-color-utility-blue-default: #79b2ec;--ds-color-utility-blue-inverse: #c9e0f7;--ds-color-utility-cyan-default: #6ad5ef;--ds-color-utility-cyan-inverse: #a8e9f7;--ds-color-utility-green-default: #7ec6ac;--ds-color-utility-green-inverse: #addbca;--ds-color-utility-gray-default: #adadad;--ds-color-utility-gray-inverse: #dddddd;--ds-color-utility-lime-default: #badd81;--ds-color-utility-lime-inverse: #d8efb4;--ds-color-utility-navy-default: #265688;--ds-color-utility-navy-inverse: #acc9e2;--ds-color-utility-neutral-default: #7e8894;--ds-color-utility-neutral-inverse: #ccd2db;--ds-color-utility-pink-default: #f7738e;--ds-color-utility-pink-inverse: #fcc2ce;--ds-color-utility-purple-default: #8d47f0;--ds-color-utility-purple-inverse: #ddc9fb;--ds-color-utility-red-default: #e35c2f;--ds-color-utility-red-inverse: #f0a68d;--ds-color-utility-turquoise-default: #5c8f91;--ds-color-utility-turquoise-inverse: #9fbdbe;--ds-color-utility-yellow-default: #f9ce06;--ds-color-utility-yellow-inverse: #ffe87e;--ds-color-utility-error-default: #cc1816;--ds-color-utility-error-inverse: #f9aca6;--ds-color-utility-warning-default: #f2c153;--ds-color-utility-warning-inverse: #f2c153;--ds-color-utility-success-default: #0b6f4d;--ds-color-utility-success-inverse: #8eceb9}*,*:before,*:after{box-sizing:border-box}@media(prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms !important;animation-iteration-count:1 !important;transition-duration:.01ms !important}}*:focus-visible{outline:0}*:focus-visible{outline:0}:focus:not(:focus-visible){outline:3px solid transparent}:host{display:inline-block;width:100%;margin:0;padding:0;vertical-align:middle}:host ::slotted(auro-menuoption),:host ::slotted([auro-menuoption]){padding-left:calc(var(--ds-size-150, 0.75rem) + 24px + var(--ds-size-100, 0.5rem))}:host ::slotted([selected]){padding-left:0}:host ::slotted(hr){box-sizing:content-box !important;height:0 !important;overflow:visible !important;margin:var(--ds-size-100, 0.5rem) 0 !important;border-width:0 !important;border-top-width:1px !important;border-top-style:solid !important}:host([nocheckmark]) ::slotted(auro-menuoption){padding-left:var(--ds-size-200, 1rem)}:host([root]){overflow-y:auto}`;
|
|
7905
|
+
var styleCss$2 = i$c`:root{--ds-asset-font-circular-family-name: "AS Circular";--ds-asset-font-circular-filename: "ASCircularWeb";--ds-asset-font-circular-weight-light: "-Light";--ds-asset-font-circular-weight-medium: "-Medium";--ds-asset-font-circular-weight-book: "-Book";--ds-border-radius: 0.375rem;--ds-size-25: 0.125rem;--ds-size-50: 0.25rem;--ds-size-75: 0.375rem;--ds-size-100: 0.5rem;--ds-size-150: 0.75rem;--ds-size-200: 1rem;--ds-size-250: 1.25rem;--ds-size-300: 1.5rem;--ds-size-400: 2rem;--ds-size-500: 2.5rem;--ds-size-600: 3rem;--ds-size-700: 3.5rem;--ds-size-800: 4rem;--ds-size-900: 4.5rem;--ds-size-1000: 5rem;--ds-unitless-scale-20: 0.25;--ds-unitless-scale-50: 0.5;--ds-unitless-scale-100: 1;--ds-unitless-scale-140: 1.4;--ds-unitless-scale-150: 1.5;--ds-unitless-scale-200: 2;--ds-unitless-scale-300: 3;--ds-unitless-scale-350: 3.5;--ds-animation-default-property: all;--ds-animation-default-duration: 0.3s;--ds-animation-default-timing: ease-out;--ds-depth-overlay: 200;--ds-depth-modal: 300;--ds-depth-tooltip: 400;--ds-elevation-100: 0px 0px 5px rgba(0, 0, 0, 0.15);--ds-elevation-200: 0px 0px 10px rgba(0, 0, 0, 0.15);--ds-elevation-300: 0px 0px 15px rgba(0, 0, 0, 0.2);--ds-grid-breakpoint-xs: 320px;--ds-grid-breakpoint-sm: 576px;--ds-grid-breakpoint-md: 768px;--ds-grid-breakpoint-lg: 1024px;--ds-grid-breakpoint-xl: 1232px;--ds-grid-column-xs: 6;--ds-grid-column-sm: 12;--ds-grid-column-md: 12;--ds-grid-column-lg: 12;--ds-grid-column-xl: 12;--ds-grid-gutter-xs: 0.5rem;--ds-grid-gutter-sm: 1rem;--ds-grid-gutter-md: 1.5rem;--ds-grid-gutter-lg: 1.5rem;--ds-grid-gutter-xl: 2rem;--ds-grid-margin-xs: 1rem;--ds-grid-margin-sm: 1rem;--ds-grid-margin-md: 1.5rem;--ds-grid-margin-lg: 2rem;--ds-grid-margin-xl: 2rem;--ds-font-family-default: "AS Circular", Helvetica Neue, Arial, sans-serif;--ds-font-family-mono: Menlo, Monaco, Consolas, "Courier New", monospace;--ds-text-heading-300-weight: 300;--ds-text-heading-300-px: 18px;--ds-text-heading-300-size: 1.125rem;--ds-text-heading-300-height: 1.625rem;--ds-text-heading-300-height-px: 26px;--ds-text-heading-400-weight: 300;--ds-text-heading-400-px: 20px;--ds-text-heading-400-size: 1.25rem;--ds-text-heading-400-height: 1.625rem;--ds-text-heading-400-height-px: 26px;--ds-text-heading-500-weight: 300;--ds-text-heading-500-px-breakpoint-sm: 22px;--ds-text-heading-500-px-breakpoint-md: 24px;--ds-text-heading-500-px-breakpoint-lg: 24px;--ds-text-heading-500-size-breakpoint-sm: 1.375rem;--ds-text-heading-500-size-breakpoint-md: 1.5rem;--ds-text-heading-500-size-breakpoint-lg: 1.5rem;--ds-text-heading-500-height-breakpoint-sm: 1.625rem;--ds-text-heading-500-height-breakpoint-px-sm: 26px;--ds-text-heading-500-height-breakpoint-md: 1.875rem;--ds-text-heading-500-height-breakpoint-px-md: 30px;--ds-text-heading-500-height-breakpoint-lg: 2rem;--ds-text-heading-500-height-breakpoint-px-lg: 32px;--ds-text-heading-600-weight: 300;--ds-text-heading-600-px-breakpoint-sm: 26px;--ds-text-heading-600-px-breakpoint-md: 28px;--ds-text-heading-600-px-breakpoint-lg: 28px;--ds-text-heading-600-size-breakpoint-sm: 1.625rem;--ds-text-heading-600-size-breakpoint-md: 1.75rem;--ds-text-heading-600-size-breakpoint-lg: 1.75rem;--ds-text-heading-600-height-breakpoint-sm: 1.875rem;--ds-text-heading-600-height-breakpoint-px-sm: 30px;--ds-text-heading-600-height-breakpoint-md: 2.125rem;--ds-text-heading-600-height-breakpoint-px-md: 34px;--ds-text-heading-600-height-breakpoint-lg: 2.25rem;--ds-text-heading-600-height-breakpoint-px-lg: 36px;--ds-text-heading-700-weight: 500;--ds-text-heading-700-px-breakpoint-sm: 28px;--ds-text-heading-700-px-breakpoint-md: 32px;--ds-text-heading-700-px-breakpoint-lg: 36px;--ds-text-heading-700-size-breakpoint-sm: 1.75rem;--ds-text-heading-700-size-breakpoint-md: 2rem;--ds-text-heading-700-size-breakpoint-lg: 2.25rem;--ds-text-heading-700-height-breakpoint-sm: 2.125rem;--ds-text-heading-700-height-breakpoint-px-sm: 34px;--ds-text-heading-700-height-breakpoint-md: 2.375rem;--ds-text-heading-700-height-breakpoint-px-md: 38px;--ds-text-heading-700-height-breakpoint-lg: 2.75rem;--ds-text-heading-700-height-breakpoint-px-lg: 44px;--ds-text-heading-800-weight: 500;--ds-text-heading-800-px-breakpoint-sm: 32px;--ds-text-heading-800-px-breakpoint-md: 36px;--ds-text-heading-800-px-breakpoint-lg: 40px;--ds-text-heading-800-size-breakpoint-sm: 2rem;--ds-text-heading-800-size-breakpoint-md: 2.25rem;--ds-text-heading-800-size-breakpoint-lg: 2.5rem;--ds-text-heading-800-height-breakpoint-sm: 2.375rem;--ds-text-heading-800-height-breakpoint-px-sm: 38px;--ds-text-heading-800-height-breakpoint-md: 2.625rem;--ds-text-heading-800-height-breakpoint-px-md: 42px;--ds-text-heading-800-height-breakpoint-lg: 3rem;--ds-text-heading-800-height-breakpoint-px-lg: 48px;--ds-text-heading-default-weight: 500;--ds-text-heading-default-margin: 0;--ds-text-heading-default-spacing: -0.2px;--ds-text-heading-medium-weight: 300;--ds-text-heading-display-weight: 100;--ds-text-heading-display-px-breakpoint-sm: 44px;--ds-text-heading-display-px-breakpoint-md: 48px;--ds-text-heading-display-px-breakpoint-lg: 56px;--ds-text-heading-display-size-breakpoint-sm: 2.75rem;--ds-text-heading-display-size-breakpoint-md: 3rem;--ds-text-heading-display-size-breakpoint-lg: 3.5rem;--ds-text-heading-display-height-breakpoint-sm: 3.375rem;--ds-text-heading-display-height-breakpoint-px-sm: 54px;--ds-text-heading-display-height-breakpoint-md: 3.75rem;--ds-text-heading-display-height-breakpoint-px-md: 60px;--ds-text-heading-display-height-breakpoint-lg: 4.25rem;--ds-text-heading-display-height-breakpoint-px-lg: 68px;--ds-text-body-default-weight: 500;--ds-text-body-size-xxs: 0.625rem;--ds-text-body-size-xs: 0.75rem;--ds-text-body-size-sm: 0.875rem;--ds-text-body-size-default: 1rem;--ds-text-body-size-lg: 1.125rem;--ds-text-body-height-xs: 1rem;--ds-text-body-height-sm: 1.25rem;--ds-text-body-height-default: 1.5rem;--ds-text-body-height-lg: 1.625rem;--ds-color-alert-notification-default: #0074c8;--ds-color-alert-warning-default: #de750c;--ds-color-alert-error-default: #df0b37;--ds-color-alert-success-default: #00805d;--ds-color-alert-advisory-default: #fff0cd;--ds-color-alert-bkg-success-default: #ddf6e8;--ds-color-alert-bkg-error-default: #ffedf1;--ds-color-background-primary-100-default: #ffffff;--ds-color-background-primary-100-inverse: #0e2b4f;--ds-color-background-primary-200-default: #f7f7f7;--ds-color-background-primary-200-inverse: #194069;--ds-color-background-primary-300-default: #e4e8ec;--ds-color-background-primary-300-inverse: #265688;--ds-color-background-primary-400-default: #dddddd;--ds-color-background-primary-400-inverse: #326aa5;--ds-color-background-success-default: #eef8f5;--ds-color-background-success-inverse: #173c30;--ds-color-background-error-default: #fff4f4;--ds-color-background-error-inverse: #74110e;--ds-color-background-warning-default: #fef8e9;--ds-color-background-warning-inverse: #5d4514;--ds-color-background-info-default: #f0f7fd;--ds-color-background-info-inverse: #193d73;--ds-color-background-subtle-default: #f7f8fa;--ds-color-background-subtle-inverse: #2a2a2a;--ds-color-background-accent-default: #ebfafd;--ds-color-background-accent-inverse: #275b72;--ds-color-background-emphasis-default: #c9e0f7;--ds-color-background-emphasis-inverse: #225296;--ds-color-background-scrimmed-default: rgba(0, 0, 0, 0.5);--ds-color-background-lightest: #ffffff;--ds-color-background-lighter: #f7f7f7;--ds-color-background-darker: #01426a;--ds-color-background-darkest: #00274a;--ds-color-background-gradient-default: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5));--ds-color-base-white: #ffffff;--ds-color-base-white-100: rgba(255, 255, 255, 0.03);--ds-color-base-white-200: rgba(255, 255, 255, 0.06);--ds-color-base-white-300: rgba(255, 255, 255, 0.12);--ds-color-base-white-400: rgba(255, 255, 255, 0.25);--ds-color-base-white-500: rgba(255, 255, 255, 0.5);--ds-color-base-white-opacity-50: rgba(255, 255, 255, 0.5);--ds-color-base-white-opacity-40: rgba(255, 255, 255, 0.4);--ds-color-base-white-opacity-0: rgba(255, 255, 255, 0);--ds-color-base-black: #000000;--ds-color-base-black-100: rgba(0, 0, 0, 0.03);--ds-color-base-black-200: rgba(0, 0, 0, 0.06);--ds-color-base-black-300: rgba(0, 0, 0, 0.12);--ds-color-base-black-400: rgba(0, 0, 0, 0.25);--ds-color-base-black-500: rgba(0, 0, 0, 0.5);--ds-color-base-black-opacity-15: rgba(0, 0, 0, 0.15);--ds-color-base-blue-100: #f0f7fd;--ds-color-base-blue-200: #c9e0f7;--ds-color-base-blue-300: #a0c9f1;--ds-color-base-blue-400: #79b2ec;--ds-color-base-blue-500: #5398e6;--ds-color-base-blue-600: #3b7fd2;--ds-color-base-blue-700: #2c67b5;--ds-color-base-blue-800: #225296;--ds-color-base-blue-900: #193d73;--ds-color-base-blue-1000: #102a51;--ds-color-base-cyan-100: #ebfafd;--ds-color-base-cyan-200: #a8e9f7;--ds-color-base-cyan-300: #6ad5ef;--ds-color-base-cyan-400: #56bbde;--ds-color-base-cyan-500: #4aa2c7;--ds-color-base-cyan-600: #3e89aa;--ds-color-base-cyan-700: #32718e;--ds-color-base-cyan-800: #275b72;--ds-color-base-cyan-900: #1d4658;--ds-color-base-cyan-1000: #12303d;--ds-color-base-error-100: #fff4f4;--ds-color-base-error-200: #f9aca6;--ds-color-base-error-300: #f16359;--ds-color-base-error-400: #cc1816;--ds-color-base-error-500: #74110e;--ds-color-base-gray-100: #f7f7f7;--ds-color-base-gray-200: #d4d4d4;--ds-color-base-gray-300: #c5c5c5;--ds-color-base-gray-400: #adadad;--ds-color-base-gray-500: #959595;--ds-color-base-gray-600: #7e7e7e;--ds-color-base-gray-700: #676767;--ds-color-base-gray-800: #525252;--ds-color-base-gray-900: #3d3d3d;--ds-color-base-gray-1000: #2a2a2a;--ds-color-base-green-100: #f3faf7;--ds-color-base-green-200: #000000;--ds-color-base-green-300: #addbca;--ds-color-base-green-400: #7ec6ac;--ds-color-base-green-500: #51ae8c;--ds-color-base-green-600: #459578;--ds-color-base-green-700: #3a7d64;--ds-color-base-green-800: #306854;--ds-color-base-green-900: #285545;--ds-color-base-green-1000: #1f4436;--ds-color-base-lime-100: #f5fbeb;--ds-color-base-lime-200: #d8efb4;--ds-color-base-lime-300: #badd81;--ds-color-base-lime-400: #a2c270;--ds-color-base-lime-500: #8ca761;--ds-color-base-lime-600: #778f53;--ds-color-base-lime-700: #647845;--ds-color-base-lime-800: #53643a;--ds-color-base-lime-900: #44522f;--ds-color-base-lime-1000: #364126;--ds-color-base-navy-100: #f2f7fb;--ds-color-base-navy-200: #cfe0ef;--ds-color-base-navy-300: #acc9e2;--ds-color-base-navy-400: #89b2d4;--ds-color-base-navy-500: #6899c6;--ds-color-base-navy-600: #4a82b7;--ds-color-base-navy-700: #326aa5;--ds-color-base-navy-800: #265688;--ds-color-base-navy-900: #194069;--ds-color-base-navy-1000: #0e2b4f;--ds-color-base-neutral-100: #f7f8fa;--ds-color-base-neutral-200: #e4e8ec;--ds-color-base-neutral-300: #ccd2db;--ds-color-base-neutral-400: #afb9c6;--ds-color-base-neutral-500: #939fad;--ds-color-base-neutral-600: #7e8894;--ds-color-base-neutral-700: #6a717c;--ds-color-base-neutral-800: #585e67;--ds-color-base-neutral-900: #484d55;--ds-color-base-neutral-1000: #393d43;--ds-color-base-pink-100: #fff7f8;--ds-color-base-pink-200: #fde0e6;--ds-color-base-pink-300: #fcc2ce;--ds-color-base-pink-400: #fa9db0;--ds-color-base-pink-500: #f7738e;--ds-color-base-pink-600: #e45472;--ds-color-base-pink-700: #bf475f;--ds-color-base-pink-800: #a03b50;--ds-color-base-pink-900: #833142;--ds-color-base-pink-1000: #692734;--ds-color-base-purple-100: #fbf8fe;--ds-color-base-purple-200: #ede3fd;--ds-color-base-purple-300: #ddc9fb;--ds-color-base-purple-400: #c9a9f8;--ds-color-base-purple-500: #b588f5;--ds-color-base-purple-600: #a268f3;--ds-color-base-purple-700: #8d47f0;--ds-color-base-purple-800: #7633d7;--ds-color-base-purple-900: #622ab2;--ds-color-base-purple-1000: #4e228d;--ds-color-base-red-100: #fef7f5;--ds-color-base-red-200: #fae2da;--ds-color-base-red-300: #f5c7b8;--ds-color-base-red-400: #f0a68d;--ds-color-base-red-500: #e9815e;--ds-color-base-red-600: #e35c2f;--ds-color-base-red-700: #d03a08;--ds-color-base-red-800: #ae3007;--ds-color-base-red-900: #902806;--ds-color-base-red-1000: #732005;--ds-color-base-success-100: #eef8f5;--ds-color-base-success-200: #8eceb9;--ds-color-base-success-300: #40a080;--ds-color-base-success-400: #0b6f4d;--ds-color-base-success-500: #173c30;--ds-color-base-turquoise-100: #f7fafa;--ds-color-base-turquoise-200: #dfe9ea;--ds-color-base-turquoise-300: #c2d5d6;--ds-color-base-turquoise-400: #9fbdbe;--ds-color-base-turquoise-500: #7ba5a6;--ds-color-base-turquoise-600: #5c8f91;--ds-color-base-turquoise-700: #3d7a7d;--ds-color-base-turquoise-800: #21686a;--ds-color-base-turquoise-900: #085659;--ds-color-base-turquoise-1000: #004447;--ds-color-base-yellow-100: #fff9df;--ds-color-base-yellow-200: #ffe87e;--ds-color-base-yellow-300: #f9ce06;--ds-color-base-yellow-400: #d6b622;--ds-color-base-yellow-500: #b49d35;--ds-color-base-yellow-600: #96873e;--ds-color-base-yellow-700: #7c7140;--ds-color-base-yellow-800: #665e3d;--ds-color-base-yellow-900: #524e38;--ds-color-base-yellow-1000: #403d30;--ds-color-base-warning-100: #fef8e9;--ds-color-base-warning-200: #f2c153;--ds-color-base-warning-300: #c49432;--ds-color-base-warning-400: #8e6b22;--ds-color-base-warning-500: #5d4514;--ds-color-state-error-100: #ff999b;--ds-color-state-error-500: #df0b37;--ds-color-state-success-100: #69cf96;--ds-color-state-success-500: #00805d;--ds-color-state-warning-500: #de750c;--ds-color-border-primary-default: #585e67;--ds-color-border-primary-inverse: #afb9c6;--ds-color-border-secondary-default: #939fad;--ds-color-border-secondary-inverse: #7e8894;--ds-color-border-tertiary-default: #dddddd;--ds-color-border-tertiary-inverse: #676767;--ds-color-border-error-default: #cc1816;--ds-color-border-error-inverse: #f9aca6;--ds-color-border-divider-default: rgba(0, 0, 0, 0.12);--ds-color-border-divider-inverse: rgba(255, 255, 255, 0.25);--ds-color-border-subtle-default: #f0f7fd;--ds-color-border-subtle-inverse: #326aa5;--ds-color-border-emphasis-default: #194069;--ds-color-border-emphasis-inverse: #f2f7fb;--ds-color-border-accent-default: #badd81;--ds-color-border-accent-inverse: #a2c270;--ds-color-border-success-default: #0b6f4d;--ds-color-border-success-inverse: #8eceb9;--ds-color-border-warning-default: #c49432;--ds-color-border-warning-inverse: #f2c153;--ds-color-border-info-default: #326aa5;--ds-color-border-info-inverse: #89b2d4;--ds-color-border-ui-default-default: #2c67b5;--ds-color-border-ui-default-inverse: #56bbde;--ds-color-border-ui-hover-default: #193d73;--ds-color-border-ui-hover-inverse: #a8e9f7;--ds-color-border-ui-active-default: #225296;--ds-color-border-ui-active-inverse: #6ad5ef;--ds-color-border-ui-focus-default: #2c67b5;--ds-color-border-ui-focus-inverse: #56bbde;--ds-color-border-ui-disabled-default: #adadad;--ds-color-border-ui-disabled-inverse: #7e7e7e;--ds-color-border-active-default: #0074c8;--ds-color-border-active-inverse: #00cff0;--ds-color-border-disabled-default: #d4d4d4;--ds-color-border-focus-default: #959595;--ds-color-brand-neutral-100: #f7f8fa;--ds-color-brand-neutral-200: #e4e8ec;--ds-color-brand-neutral-300: #ccd2db;--ds-color-brand-neutral-400: #afb9c6;--ds-color-brand-neutral-500: #939fad;--ds-color-brand-neutral-600: #7e8894;--ds-color-brand-neutral-700: #6a717c;--ds-color-brand-neutral-800: #585e67;--ds-color-brand-neutral-900: #484d55;--ds-color-brand-neutral-1000: #393d43;--ds-color-brand-gray-100: #f7f7f7;--ds-color-brand-gray-200: #dddddd;--ds-color-brand-gray-300: #c5c5c5;--ds-color-brand-gray-400: #adadad;--ds-color-brand-gray-500: #959595;--ds-color-brand-gray-600: #7e7e7e;--ds-color-brand-gray-700: #676767;--ds-color-brand-gray-800: #525252;--ds-color-brand-gray-900: #3d3d3d;--ds-color-brand-gray-1000: #2a2a2a;--ds-color-brand-red-100: #fef7f5;--ds-color-brand-red-200: #fae2da;--ds-color-brand-red-300: #f5c7b8;--ds-color-brand-red-400: #f0a68d;--ds-color-brand-red-500: #e9815e;--ds-color-brand-red-600: #e35c2f;--ds-color-brand-red-700: #d03a08;--ds-color-brand-red-800: #ae3007;--ds-color-brand-red-900: #902806;--ds-color-brand-red-1000: #732005;--ds-color-brand-yellow-100: #fff9df;--ds-color-brand-yellow-200: #ffe87e;--ds-color-brand-yellow-300: #f9ce06;--ds-color-brand-yellow-400: #d6b622;--ds-color-brand-yellow-500: #b49d35;--ds-color-brand-yellow-600: #96873e;--ds-color-brand-yellow-700: #7c7140;--ds-color-brand-yellow-800: #665e3d;--ds-color-brand-yellow-900: #524e38;--ds-color-brand-yellow-1000: #403d30;--ds-color-brand-lime-100: #f5fbeb;--ds-color-brand-lime-200: #d8efb4;--ds-color-brand-lime-300: #badd81;--ds-color-brand-lime-400: #a2c270;--ds-color-brand-lime-500: #8ca761;--ds-color-brand-lime-600: #778f53;--ds-color-brand-lime-700: #647845;--ds-color-brand-lime-800: #53643a;--ds-color-brand-lime-900: #44522f;--ds-color-brand-lime-1000: #364126;--ds-color-brand-green-100: #f3faf7;--ds-color-brand-green-200: #d4ece4;--ds-color-brand-green-300: #addbca;--ds-color-brand-green-400: #7ec6ac;--ds-color-brand-green-500: #51ae8c;--ds-color-brand-green-600: #459578;--ds-color-brand-green-700: #3a7d64;--ds-color-brand-green-800: #306854;--ds-color-brand-green-900: #285545;--ds-color-brand-green-1000: #1f4436;--ds-color-brand-turquoise-100: #f7fafa;--ds-color-brand-turquoise-200: #dfe9ea;--ds-color-brand-turquoise-300: #c2d5d6;--ds-color-brand-turquoise-400: #9fbdbe;--ds-color-brand-turquoise-500: #7ba5a6;--ds-color-brand-turquoise-600: #5c8f91;--ds-color-brand-turquoise-700: #3d7a7d;--ds-color-brand-turquoise-800: #21686a;--ds-color-brand-turquoise-900: #085659;--ds-color-brand-turquoise-1000: #004447;--ds-color-brand-cyan-100: #ebfafd;--ds-color-brand-cyan-200: #a8e9f7;--ds-color-brand-cyan-300: #6ad5ef;--ds-color-brand-cyan-400: #56bbde;--ds-color-brand-cyan-500: #4aa2c7;--ds-color-brand-cyan-600: #3e89aa;--ds-color-brand-cyan-700: #32718e;--ds-color-brand-cyan-800: #275b72;--ds-color-brand-cyan-900: #1d4658;--ds-color-brand-cyan-1000: #12303d;--ds-color-brand-blue-100: #f0f7fd;--ds-color-brand-blue-200: #c9e0f7;--ds-color-brand-blue-300: #a0c9f1;--ds-color-brand-blue-400: #79b2ec;--ds-color-brand-blue-500: #5398e6;--ds-color-brand-blue-600: #3b7fd2;--ds-color-brand-blue-700: #2c67b5;--ds-color-brand-blue-800: #225296;--ds-color-brand-blue-900: #193d73;--ds-color-brand-blue-1000: #102a51;--ds-color-brand-navy-100: #f2f7fb;--ds-color-brand-navy-200: #cfe0ef;--ds-color-brand-navy-300: #acc9e2;--ds-color-brand-navy-400: #89b2d4;--ds-color-brand-navy-500: #6899c6;--ds-color-brand-navy-600: #4a82b7;--ds-color-brand-navy-700: #326aa5;--ds-color-brand-navy-800: #265688;--ds-color-brand-navy-900: #194069;--ds-color-brand-navy-1000: #0e2b4f;--ds-color-brand-purple-100: #fbf8fe;--ds-color-brand-purple-200: #ede3fd;--ds-color-brand-purple-300: #ddc9fb;--ds-color-brand-purple-400: #c9a9f8;--ds-color-brand-purple-500: #b588f5;--ds-color-brand-purple-600: #a268f3;--ds-color-brand-purple-700: #8d47f0;--ds-color-brand-purple-800: #7633d7;--ds-color-brand-purple-900: #622ab2;--ds-color-brand-purple-1000: #4e228d;--ds-color-brand-pink-100: #fff7f8;--ds-color-brand-pink-200: #fde0e6;--ds-color-brand-pink-300: #fcc2ce;--ds-color-brand-pink-400: #fa9db0;--ds-color-brand-pink-500: #f7738e;--ds-color-brand-pink-600: #e45472;--ds-color-brand-pink-700: #bf475f;--ds-color-brand-pink-800: #a03b50;--ds-color-brand-pink-900: #833142;--ds-color-brand-pink-1000: #692734;--ds-color-brand-midnight-100: #c1daf0;--ds-color-brand-midnight-200: #569ed7;--ds-color-brand-midnight-300: #156fad;--ds-color-brand-midnight-400: #01426a;--ds-color-brand-midnight-500: #00274a;--ds-color-brand-atlas-100: #cde6ff;--ds-color-brand-atlas-200: #6bb7fb;--ds-color-brand-atlas-300: #2492eb;--ds-color-brand-atlas-400: #0074c8;--ds-color-brand-atlas-500: #054687;--ds-color-brand-atlas-400-opacity-20: rgba(0, 116, 200, 0.2);--ds-color-brand-breeze-100: #c0f7ff;--ds-color-brand-breeze-200: #5de3f7;--ds-color-brand-breeze-300: #00cff0;--ds-color-brand-breeze-400: #099dc5;--ds-color-brand-breeze-500: #0b5575;--ds-color-brand-breeze-300-opacity-30: rgba(0, 207, 240, 0.3);--ds-color-brand-tropical-100: #e2ffcd;--ds-color-brand-tropical-200: #d0fba6;--ds-color-brand-tropical-300: #c0e585;--ds-color-brand-tropical-400: #91be62;--ds-color-brand-tropical-500: #5e8741;--ds-color-brand-alpine-100: #bcaae6;--ds-color-brand-alpine-200: #9e73ea;--ds-color-brand-alpine-300: #8439ef;--ds-color-brand-alpine-400: #631db8;--ds-color-brand-alpine-500: #39115c;--ds-color-brand-flamingo-100: #ffebee;--ds-color-brand-flamingo-200: #ffc0ca;--ds-color-brand-flamingo-300: #ff94a7;--ds-color-brand-flamingo-400: #f65b7b;--ds-color-brand-flamingo-500: #b82b47;--ds-color-brand-canyon-100: #ffcab6;--ds-color-brand-canyon-200: #f99574;--ds-color-brand-canyon-300: #f26135;--ds-color-brand-canyon-400: #de3e09;--ds-color-brand-canyon-500: #b83302;--ds-color-brand-goldcoast-100: #fff0cd;--ds-color-brand-goldcoast-200: #ffdb67;--ds-color-brand-goldcoast-300: #ffd200;--ds-color-brand-goldcoast-400: #e5ad07;--ds-color-brand-goldcoast-500: #b88624;--ds-color-brand-goldgray-100: #c5c1bf;--ds-color-brand-goldgray-200: #726e6c;--ds-color-brand-gold-100: #ccbc94;--ds-color-brand-gold-200: #7f682e;--ds-color-brand-emerald: #139142;--ds-color-brand-sapphire: #015daa;--ds-color-brand-ruby: #a41d4a;--ds-color-brand-lounge: #01426a;--ds-color-brand-loungeplus: #53b390;--ds-color-container-accent-default: #f5fbeb;--ds-color-container-accent-inverse: #badd81;--ds-color-container-emphasis-default: #ebfafd;--ds-color-container-emphasis-inverse: #6ad5ef;--ds-color-container-error-default: #fff4f4;--ds-color-container-error-inverse: #74110e;--ds-color-container-info-default: #f0f7fd;--ds-color-container-info-inverse: #193d73;--ds-color-container-primary-default: #ffffff;--ds-color-container-primary-inverse: #0e2b4f;--ds-color-container-secondary-default: #f7f7f7;--ds-color-container-secondary-inverse: #194069;--ds-color-container-subtle-default: #f7f8fa;--ds-color-container-subtle-inverse: #393d43;--ds-color-container-success-default: #eef8f5;--ds-color-container-success-inverse: #173c30;--ds-color-container-tertiary-default: rgba(0, 0, 0, 0.03);--ds-color-container-tertiary-inverse: rgba(255, 255, 255, 0.06);--ds-color-container-warning-default: #fef8e9;--ds-color-container-warning-inverse: #5d4514;--ds-color-container-ui-primary-active-default: #225296;--ds-color-container-ui-primary-active-inverse: #6ad5ef;--ds-color-container-ui-primary-default-default: #2c67b5;--ds-color-container-ui-primary-default-inverse: #56bbde;--ds-color-container-ui-primary-disabled-default: #a0c9f1;--ds-color-container-ui-primary-disabled-inverse: #275b72;--ds-color-container-ui-primary-focus-default: #2c67b5;--ds-color-container-ui-primary-focus-inverse: #56bbde;--ds-color-container-ui-primary-hover-default: #193d73;--ds-color-container-ui-primary-hover-inverse: #a8e9f7;--ds-color-container-ui-secondary-active-default: #f0f7fd;--ds-color-container-ui-secondary-active-inverse: rgba(255, 255, 255, 0.06);--ds-color-container-ui-secondary-default-default: #ffffff;--ds-color-container-ui-secondary-default-inverse: rgba(255, 255, 255, 0.03);--ds-color-container-ui-secondary-disabled-default: #f7f7f7;--ds-color-container-ui-secondary-disabled-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-secondary-focus-default: #ffffff;--ds-color-container-ui-secondary-focus-inverse: rgba(255, 255, 255, 0.03);--ds-color-container-ui-secondary-hover-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-secondary-hover-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-tertiary-active-default: rgba(0, 0, 0, 0.06);--ds-color-container-ui-tertiary-active-inverse: rgba(255, 255, 255, 0.06);--ds-color-container-ui-tertiary-default-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-tertiary-default-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-tertiary-disabled-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-tertiary-disabled-inverse: rgba(255, 255, 255, 0.25);--ds-color-container-ui-tertiary-focus-default: rgba(0, 0, 0, 0.03);--ds-color-container-ui-tertiary-focus-inverse: rgba(255, 255, 255, 0.12);--ds-color-container-ui-tertiary-hover-default: rgba(0, 0, 0, 0.12);--ds-color-container-ui-tertiary-hover-inverse: rgba(255, 255, 255, 0.25);--ds-color-icon-primary-default: #676767;--ds-color-icon-primary-inverse: #f7f7f7;--ds-color-icon-secondary-default: #7e8894;--ds-color-icon-secondary-inverse: #ccd2db;--ds-color-icon-tertiary-default: #afb9c6;--ds-color-icon-tertiary-inverse: #939fad;--ds-color-icon-emphasis-default: #2a2a2a;--ds-color-icon-emphasis-inverse: #ffffff;--ds-color-icon-accent-default: #a2c270;--ds-color-icon-accent-inverse: #badd81;--ds-color-icon-info-default: #326aa5;--ds-color-icon-info-inverse: #89b2d4;--ds-color-icon-error-default: #cc1816;--ds-color-icon-error-inverse: #f9aca6;--ds-color-icon-warning-default: #c49432;--ds-color-icon-warning-inverse: #f2c153;--ds-color-icon-success-default: #40a080;--ds-color-icon-success-inverse: #8eceb9;--ds-color-icon-subtle-default: #a0c9f1;--ds-color-icon-subtle-inverse: #326aa5;--ds-color-icon-ui-primary-default-default: #2c67b5;--ds-color-icon-ui-primary-default-inverse: #56bbde;--ds-color-icon-ui-primary-hover-default: #193d73;--ds-color-icon-ui-primary-hover-inverse: #a8e9f7;--ds-color-icon-ui-primary-active-default: #225296;--ds-color-icon-ui-primary-active-inverse: #6ad5ef;--ds-color-icon-ui-primary-disabled-default: #adadad;--ds-color-icon-ui-primary-disabled-inverse: #7e7e7e;--ds-color-icon-ui-primary-focus-default: #2c67b5;--ds-color-icon-ui-primary-focus-inverse: #56bbde;--ds-color-icon-ui-secondary-active-default: #676767;--ds-color-icon-ui-secondary-active-inverse: #c5c5c5;--ds-color-icon-ui-secondary-default-default: #7e7e7e;--ds-color-icon-ui-secondary-default-inverse: #adadad;--ds-color-icon-ui-secondary-disabled-default: #adadad;--ds-color-icon-ui-secondary-disabled-inverse: #7e7e7e;--ds-color-icon-ui-secondary-focus-default: #7e7e7e;--ds-color-icon-ui-secondary-focus-inverse: #adadad;--ds-color-icon-ui-secondary-hover-default: #525252;--ds-color-icon-ui-secondary-hover-inverse: #dddddd;--ds-color-icon-brand-red-default: #d03a08;--ds-color-icon-brand-red-inverse: #e9815e;--ds-color-icon-brand-yellow-default: #7c7140;--ds-color-icon-brand-yellow-inverse: #f9ce06;--ds-color-icon-brand-pink-default: #bf475f;--ds-color-icon-brand-pink-inverse: #f7738e;--ds-color-icon-brand-purple-default: #8d47f0;--ds-color-icon-brand-purple-inverse: #b588f5;--ds-color-icon-brand-lime-default: #647845;--ds-color-icon-brand-lime-inverse: #badd81;--ds-color-icon-brand-green-default: #3a7d64;--ds-color-icon-brand-green-inverse: #51ae8c;--ds-color-icon-brand-turquoise-default: #3d7a7d;--ds-color-icon-brand-turquoise-inverse: #7ba5a6;--ds-color-icon-brand-navy-default: #265688;--ds-color-icon-brand-navy-inverse: #6899c6;--ds-color-icon-brand-blue-default: #2c67b5;--ds-color-icon-brand-blue-inverse: #5398e6;--ds-color-icon-brand-cyan-default: #32718e;--ds-color-icon-brand-cyan-inverse: #6ad5ef;--ds-color-icon-brand-gray-default: #676767;--ds-color-icon-brand-gray-inverse: #c5c5c5;--ds-color-icon-brand-neutral-default: #6a717c;--ds-color-icon-brand-neutral-inverse: #afb9c6;--ds-color-icon-disabled-default: rgba(0, 0, 0, 0.15);--ds-color-text-primary-default: #2a2a2a;--ds-color-text-primary-inverse: #ffffff;--ds-color-text-secondary-default: #525252;--ds-color-text-secondary-inverse: #dddddd;--ds-color-text-tertiary-default: #6a717c;--ds-color-text-tertiary-inverse: #adadad;--ds-color-text-error-default: #cc1816;--ds-color-text-error-inverse: #f9aca6;--ds-color-text-emphasis-default: #265688;--ds-color-text-emphasis-inverse: #cfe0ef;--ds-color-text-accent-default: #647845;--ds-color-text-accent-inverse: #badd81;--ds-color-text-info-default: #326aa5;--ds-color-text-info-inverse: #acc9e2;--ds-color-text-subtle-default: #32718e;--ds-color-text-subtle-inverse: #56bbde;--ds-color-text-success-default: #0b6f4d;--ds-color-text-success-inverse: #8eceb9;--ds-color-text-ui-active-default: #225296;--ds-color-text-ui-active-inverse: #6ad5ef;--ds-color-text-ui-default-default: #2c67b5;--ds-color-text-ui-default-inverse: #56bbde;--ds-color-text-ui-disabled-default: #adadad;--ds-color-text-ui-disabled-inverse: #7e7e7e;--ds-color-text-ui-focus-default: #2c67b5;--ds-color-text-ui-focus-inverse: #56bbde;--ds-color-text-ui-hover-default: #193d73;--ds-color-text-ui-hover-inverse: #a8e9f7;--ds-color-text-link-default: #0074c8;--ds-color-text-link-inverse: #00cff0;--ds-color-tier-alaska-mvp-default: #726e6c;--ds-color-tier-alaska-mvp-inverse: #c5c1bf;--ds-color-tier-alaska-mvpgold-default: #7f682e;--ds-color-tier-alaska-mvpgold-inverse: #c5c1bf;--ds-color-tier-alaska-mvpgold75k-default: #7f682e;--ds-color-tier-alaska-mvpgold75k-inverse: #c5c1bf;--ds-color-tier-alaska-mvpgold100k-default: #7f682e;--ds-color-tier-alaska-mvpgold100k-inverse: #c5c1bf;--ds-color-tier-alaska-lounge: #01426a;--ds-color-tier-alaska-loungeplus: #53b390;--ds-color-tier-fare-business-default: #005154;--ds-color-tier-fare-business-inverse: #9fbdbe;--ds-color-tier-fare-economy-default: #2c67b5;--ds-color-tier-fare-economy-inverse: #a0c9f1;--ds-color-tier-fare-first-class-default: #002c4e;--ds-color-tier-fare-first-class-inverse: #89b2d4;--ds-color-tier-fare-saver-default: #4aa2c7;--ds-color-tier-fare-saver-inverse: #a8e9f7;--ds-color-tier-oneworld-emerald: #139142;--ds-color-tier-oneworld-sapphire: #015daa;--ds-color-tier-oneworld-ruby: #a41d4a;--ds-color-ui-default-default: #0074c8;--ds-color-ui-default-inverse: #00cff0;--ds-color-ui-hover-default: #054687;--ds-color-ui-hover-inverse: #5de3f7;--ds-color-ui-active-default: #054687;--ds-color-ui-active-inverse: #5de3f7;--ds-color-ui-disabled-default: rgba(0, 116, 200, 0.2);--ds-color-ui-bkg-default-default: rgba(0, 0, 0, 0.03);--ds-color-ui-bkg-default-inverse: rgba(255, 255, 255, 0.03);--ds-color-ui-bkg-hover-default: rgba(0, 0, 0, 0.06);--ds-color-ui-bkg-hover-inverse: rgba(255, 255, 255, 0.06);--ds-color-utility-blue-default: #79b2ec;--ds-color-utility-blue-inverse: #c9e0f7;--ds-color-utility-cyan-default: #6ad5ef;--ds-color-utility-cyan-inverse: #a8e9f7;--ds-color-utility-green-default: #7ec6ac;--ds-color-utility-green-inverse: #addbca;--ds-color-utility-gray-default: #adadad;--ds-color-utility-gray-inverse: #dddddd;--ds-color-utility-lime-default: #badd81;--ds-color-utility-lime-inverse: #d8efb4;--ds-color-utility-navy-default: #265688;--ds-color-utility-navy-inverse: #acc9e2;--ds-color-utility-neutral-default: #7e8894;--ds-color-utility-neutral-inverse: #ccd2db;--ds-color-utility-pink-default: #f7738e;--ds-color-utility-pink-inverse: #fcc2ce;--ds-color-utility-purple-default: #8d47f0;--ds-color-utility-purple-inverse: #ddc9fb;--ds-color-utility-red-default: #e35c2f;--ds-color-utility-red-inverse: #f0a68d;--ds-color-utility-turquoise-default: #5c8f91;--ds-color-utility-turquoise-inverse: #9fbdbe;--ds-color-utility-yellow-default: #f9ce06;--ds-color-utility-yellow-inverse: #ffe87e;--ds-color-utility-error-default: #cc1816;--ds-color-utility-error-inverse: #f9aca6;--ds-color-utility-warning-default: #f2c153;--ds-color-utility-warning-inverse: #f2c153;--ds-color-utility-success-default: #0b6f4d;--ds-color-utility-success-inverse: #8eceb9}*,*:before,*:after{box-sizing:border-box}@media(prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms !important;animation-iteration-count:1 !important;transition-duration:.01ms !important}}*:focus-visible{outline:0}*:focus-visible{outline:0}:focus:not(:focus-visible){outline:3px solid transparent}:host{display:inline-block;width:100%;margin:0;padding:0;vertical-align:middle}:host ::slotted(auro-menuoption),:host ::slotted([auro-menuoption]),:host auro-menuoption[loadingplaceholder]{padding-left:calc(var(--ds-size-150, 0.75rem) + 24px + var(--ds-size-100, 0.5rem))}:host ::slotted([selected]){padding-left:0}:host ::slotted(hr){box-sizing:content-box !important;height:0 !important;overflow:visible !important;margin:var(--ds-size-100, 0.5rem) 0 !important;border-width:0 !important;border-top-width:1px !important;border-top-style:solid !important}:host([nocheckmark]) ::slotted(auro-menuoption),:host([nocheckmark]) auro-menuoption[loadingplaceholder]{padding-left:var(--ds-size-200, 1rem)}:host([root]){overflow-y:auto}[loadingplaceholder]{color:var(--ds-color-text-secondary-default, #525252)}[loadingplaceholder].empty{opacity:0;position:absolute}[loadingplaceholder] slot[name=loadingIcon]{vertical-align:middle;line-height:1;display:inline-block}[loadingplaceholder] slot[name=loadingIcon]::slotted(*){margin-right:var(--ds-size-150, 0.75rem)}`;
|
|
7870
7906
|
|
|
7871
7907
|
var colorCss$2 = i$c`:host ::slotted(hr){border-top-color:var(--ds-auro-menu-divider-color) !important}`;
|
|
7872
7908
|
|
|
7873
7909
|
var tokensCss$1 = i$c`:host{--ds-auro-menu-divider-color: var(--ds-color-border-divider-default, $ds-color-border-divider-default);--ds-auro-menuoption-container-color: transparent;--ds-auro-menuoption-icon-color: transparent;--ds-auro-menuoption-text-color: var(--ds-color-text-primary-default, $ds-color-text-primary-default)}`;
|
|
7874
7910
|
|
|
7875
|
-
|
|
7911
|
+
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
7912
|
+
// See LICENSE in the project root for license information.
|
|
7876
7913
|
|
|
7877
|
-
var colorCss$1 = i$c`:host{background-color:var(--ds-auro-menuoption-container-color);color:var(--ds-auro-menuoption-text-color)}:host svg{fill:var(--ds-auro-menuoption-icon-color) !important}:host([disabled]){--ds-auro-menuoption-text-color: var(--ds-color-text-ui-disabled-default, #adadad)}:host(:hover),:host(.active){--ds-auro-menuoption-container-color: var(--ds-color-container-ui-secondary-hover-default, rgba(0, 0, 0, 0.03))}:host([selected]){--ds-auro-menuoption-container-color: var(--ds-color-container-ui-primary-default-default, #2c67b5);--ds-auro-menuoption-text-color: var(--ds-color-text-primary-inverse, #ffffff);--ds-auro-menuoption-icon-color: var(--ds-color-icon-emphasis-inverse, #ffffff)}`;
|
|
7878
7914
|
|
|
7915
|
+
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
7879
7916
|
/**
|
|
7880
|
-
*
|
|
7881
|
-
*
|
|
7882
|
-
*
|
|
7917
|
+
* The auro-menu element provides users a way to select from a list of options.
|
|
7918
|
+
* @attr {Object} optionSelected - Specifies the current selected menuOption.
|
|
7919
|
+
* @attr {String} matchWord - Specifies a string used to highlight matched string parts in options.
|
|
7920
|
+
* @attr {Boolean} disabled - When true, the entire menu and all options are disabled;
|
|
7921
|
+
* @attr {Boolean} noCheckmark - When true, selected option will not show the checkmark.
|
|
7922
|
+
* @attr {Boolean} loading - When true, displays a loading state using the loadingIcon and loadingText slots if provided.
|
|
7923
|
+
* @attr {String} value - Value selected for the menu.
|
|
7924
|
+
* @prop {Boolean} hasLoadingPlaceholder - Indicates whether the menu has a loadingIcon or loadingText to render when in a loading state.
|
|
7925
|
+
* @event auroMenu-selectedOption - Notifies that a new menuoption selection has been made.
|
|
7926
|
+
* @event selectedOption - (DEPRECATED) Notifies that a new menuoption selection has been made.
|
|
7927
|
+
* @event auroMenu-activatedOption - Notifies that a menuoption has been made `active`.
|
|
7928
|
+
* @event auroMenuActivatedOption - (DEPRECATED) Notifies that a menuoption has been made `active`.
|
|
7929
|
+
* @event auroMenu-selectValueFailure - Notifies that a an attempt to select a menuoption by matching a value has failed.
|
|
7930
|
+
* @event auroMenuSelectValueFailure - (DEPRECATED) Notifies that a an attempt to select a menuoption by matching a value has failed.
|
|
7931
|
+
* @event auroMenu-customEventFired - Notifies that a custom event has been fired.
|
|
7932
|
+
* @event auroMenuCustomEventFired - (DEPRECATED) Notifies that a custom event has been fired.
|
|
7933
|
+
* @event auroMenu-selectValueReset - Notifies that the component value has been reset.
|
|
7934
|
+
* @event auroMenu-loadingChange - Notifies when the loading attribute is changed.
|
|
7935
|
+
* @slot loadingText - Text to show while loading attribute is set
|
|
7936
|
+
* @slot loadingIcon - Icon to show while loading attribute is set
|
|
7937
|
+
* @slot - Slot for insertion of menu options.
|
|
7883
7938
|
*/
|
|
7884
|
-
const t={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},e$1=t=>(...e)=>({_$litDirective$:t,values:e});class i{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i;}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}
|
|
7885
7939
|
|
|
7886
|
-
|
|
7887
|
-
* @license
|
|
7888
|
-
* Copyright 2018 Google LLC
|
|
7889
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
7890
|
-
*/const e=e$1(class extends i{constructor(t$1){if(super(t$1),t$1.type!==t.ATTRIBUTE||"class"!==t$1.name||t$1.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return " "+Object.keys(t).filter((s=>t[s])).join(" ")+" "}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)));}return T$2}});
|
|
7940
|
+
/* eslint-disable no-magic-numbers, max-lines */
|
|
7891
7941
|
|
|
7892
|
-
|
|
7893
|
-
|
|
7894
|
-
|
|
7895
|
-
|
|
7896
|
-
|
|
7942
|
+
class AuroMenu extends r$6 {
|
|
7943
|
+
constructor() {
|
|
7944
|
+
super();
|
|
7945
|
+
this.value = undefined;
|
|
7946
|
+
this.optionSelected = undefined;
|
|
7947
|
+
this.matchWord = undefined;
|
|
7948
|
+
this.noCheckmark = false;
|
|
7949
|
+
this.optionActive = undefined;
|
|
7950
|
+
this.loading = false;
|
|
7897
7951
|
|
|
7898
|
-
|
|
7899
|
-
|
|
7952
|
+
/**
|
|
7953
|
+
* @private
|
|
7954
|
+
*/
|
|
7955
|
+
this.rootMenu = true;
|
|
7900
7956
|
|
|
7957
|
+
/**
|
|
7958
|
+
* @private
|
|
7959
|
+
*/
|
|
7960
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$2();
|
|
7901
7961
|
|
|
7902
|
-
/**
|
|
7903
|
-
|
|
7904
|
-
|
|
7905
|
-
|
|
7906
|
-
*/
|
|
7962
|
+
/**
|
|
7963
|
+
* @private
|
|
7964
|
+
*/
|
|
7965
|
+
this.nestingSpacer = '<span class="nestingSpacer"></span>';
|
|
7907
7966
|
|
|
7908
|
-
|
|
7967
|
+
/**
|
|
7968
|
+
* @private
|
|
7969
|
+
*/
|
|
7970
|
+
this.loadingSlots = null;
|
|
7971
|
+
}
|
|
7909
7972
|
|
|
7910
|
-
// function to define props used within the scope of this component
|
|
7911
7973
|
static get properties() {
|
|
7912
7974
|
return {
|
|
7913
|
-
|
|
7914
|
-
|
|
7915
|
-
|
|
7916
|
-
|
|
7917
|
-
|
|
7918
|
-
|
|
7975
|
+
noCheckmark: {
|
|
7976
|
+
type: Boolean,
|
|
7977
|
+
reflect: true
|
|
7978
|
+
},
|
|
7979
|
+
disabled: {
|
|
7980
|
+
type: Boolean,
|
|
7981
|
+
reflect: true
|
|
7982
|
+
},
|
|
7983
|
+
loading: {
|
|
7984
|
+
type: Boolean,
|
|
7985
|
+
reflect: true
|
|
7986
|
+
},
|
|
7987
|
+
optionSelected: { type: Object },
|
|
7988
|
+
optionActive: { type: Object },
|
|
7989
|
+
matchWord: { type: String },
|
|
7990
|
+
value: { type: String }
|
|
7919
7991
|
};
|
|
7920
7992
|
}
|
|
7921
7993
|
|
|
7994
|
+
static get styles() {
|
|
7995
|
+
return [
|
|
7996
|
+
styleCss$2,
|
|
7997
|
+
colorCss$2,
|
|
7998
|
+
tokensCss$1
|
|
7999
|
+
];
|
|
8000
|
+
}
|
|
8001
|
+
|
|
7922
8002
|
/**
|
|
7923
|
-
*
|
|
8003
|
+
* This will register this element with the browser.
|
|
8004
|
+
* @param {string} [name="auro-menu"] - The name of element that you want to register to.
|
|
8005
|
+
*
|
|
8006
|
+
* @example
|
|
8007
|
+
* AuroMenu.register("custom-menu") // this will register this element to <custom-menu/>
|
|
8008
|
+
*
|
|
7924
8009
|
*/
|
|
7925
|
-
|
|
7926
|
-
|
|
7927
|
-
return 'true'
|
|
7928
|
-
}
|
|
7929
|
-
|
|
7930
|
-
return 'false'
|
|
8010
|
+
static register(name = "auro-menu") {
|
|
8011
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroMenu);
|
|
7931
8012
|
}
|
|
7932
|
-
}
|
|
7933
|
-
|
|
7934
|
-
var error = {"role":"img","color":"currentColor","title":"","desc":"Error alert indicator.","width":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","height":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","xmlns":"http://www.w3.org/2000/svg","xmlns_xlink":"http://www.w3.org/1999/xlink","viewBox":"0 0 24 24","path":"/icons","style":"ico_squareLarge","type":"icon","name":"error","category":"alert","deprecated":true,"svg":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" aria-labelledby=\"error__desc\" class=\"ico_squareLarge\" data-deprecated=\"true\" role=\"img\" style=\"min-width:var(--auro-size-lg, var(--ds-size-300, 1.5rem));height:var(--auro-size-lg, var(--ds-size-300, 1.5rem));fill:currentColor\" viewBox=\"0 0 24 24\" part=\"svg\"><title/><desc id=\"error__desc\">Error alert indicator.</desc><path d=\"m13.047 5.599 6.786 11.586A1.207 1.207 0 0 1 18.786 19H5.214a1.207 1.207 0 0 1-1.047-1.815l6.786-11.586a1.214 1.214 0 0 1 2.094 0m-1.165.87a.23.23 0 0 0-.085.085L5.419 17.442a.232.232 0 0 0 .203.35h12.756a.234.234 0 0 0 .203-.35L12.203 6.554a.236.236 0 0 0-.321-.084M12 15.5a.75.75 0 1 1 0 1.5.75.75 0 0 1 0-1.5m-.024-6.22c.325 0 .589.261.589.583v4.434a.586.586 0 0 1-.589.583.586.586 0 0 1-.588-.583V9.863c0-.322.264-.583.588-.583\"/></svg>"};
|
|
7935
8013
|
|
|
7936
|
-
|
|
8014
|
+
/**
|
|
8015
|
+
* Passes the noCheckmark attribute to all nested auro-menuoptions.
|
|
8016
|
+
* @private
|
|
8017
|
+
* @returns {void}
|
|
8018
|
+
*/
|
|
8019
|
+
handleNoCheckmarkAttr() {
|
|
8020
|
+
if (this.noCheckmark) {
|
|
8021
|
+
const menus = this.querySelectorAll('auro-menu, [auro-menu]');
|
|
7937
8022
|
|
|
7938
|
-
|
|
8023
|
+
menus.forEach((menu) => {
|
|
8024
|
+
menu.setAttribute('noCheckmark', '');
|
|
8025
|
+
});
|
|
7939
8026
|
|
|
7940
|
-
|
|
7941
|
-
* A callback to parse Response body.
|
|
7942
|
-
*
|
|
7943
|
-
* @callback ResponseParser
|
|
7944
|
-
* @param {Fetch.Response} response
|
|
7945
|
-
* @returns {Promise}
|
|
7946
|
-
*/
|
|
8027
|
+
const options = this.querySelectorAll('auro-menuoption, [auro-menuoption]');
|
|
7947
8028
|
|
|
7948
|
-
|
|
7949
|
-
|
|
7950
|
-
|
|
7951
|
-
|
|
7952
|
-
* @param {Object} [options={}]
|
|
7953
|
-
* @param {ResponseParser} [options.responseParser=(response) => response.text()]
|
|
7954
|
-
* @returns {Promise}
|
|
7955
|
-
*/
|
|
7956
|
-
const cacheFetch = (uri, options = {}) => {
|
|
7957
|
-
const responseParser = options.responseParser || ((response) => response.text());
|
|
7958
|
-
if (!_fetchMap.has(uri)) {
|
|
7959
|
-
_fetchMap.set(uri, fetch(uri).then(responseParser));
|
|
8029
|
+
options.forEach((option) => {
|
|
8030
|
+
option.setAttribute('noCheckmark', '');
|
|
8031
|
+
});
|
|
8032
|
+
}
|
|
7960
8033
|
}
|
|
7961
|
-
return _fetchMap.get(uri);
|
|
7962
|
-
};
|
|
7963
8034
|
|
|
7964
|
-
|
|
8035
|
+
firstUpdated() {
|
|
8036
|
+
// Add the tag name as an attribute if it is different than the component name
|
|
8037
|
+
this.runtimeUtils.handleComponentTagRename(this, 'auro-menu');
|
|
7965
8038
|
|
|
7966
|
-
|
|
7967
|
-
// See LICENSE in the project root for license information.
|
|
8039
|
+
this.addEventListener('keydown', this.handleKeyDown);
|
|
7968
8040
|
|
|
8041
|
+
this.loadingSlots = this.querySelectorAll("[slot='loadingText'], [slot='loadingIcon']");
|
|
8042
|
+
}
|
|
7969
8043
|
|
|
7970
|
-
|
|
7971
|
-
|
|
7972
|
-
|
|
7973
|
-
|
|
7974
|
-
*/
|
|
8044
|
+
updated(changedProperties) {
|
|
8045
|
+
if (changedProperties.has('matchWord')) {
|
|
8046
|
+
this.markOptions();
|
|
8047
|
+
}
|
|
7975
8048
|
|
|
7976
|
-
|
|
7977
|
-
|
|
7978
|
-
|
|
7979
|
-
super();
|
|
7980
|
-
this.onDark = false;
|
|
7981
|
-
}
|
|
8049
|
+
if (changedProperties.has('value')) {
|
|
8050
|
+
this.selectByValue(this.value);
|
|
8051
|
+
}
|
|
7982
8052
|
|
|
7983
|
-
|
|
7984
|
-
|
|
7985
|
-
return {
|
|
7986
|
-
...super.properties,
|
|
7987
|
-
onDark: {
|
|
7988
|
-
type: Boolean,
|
|
7989
|
-
reflect: true
|
|
7990
|
-
},
|
|
8053
|
+
if (changedProperties.has('disabled')) {
|
|
8054
|
+
const options = Array.from(this.querySelectorAll('auro-menuoption, [auro-menuoption]'));
|
|
7991
8055
|
|
|
7992
|
-
|
|
7993
|
-
|
|
7994
|
-
*/
|
|
7995
|
-
svg: {
|
|
7996
|
-
attribute: false,
|
|
7997
|
-
reflect: true
|
|
8056
|
+
for (const element of options) {
|
|
8057
|
+
element.disabled = this.disabled;
|
|
7998
8058
|
}
|
|
7999
|
-
}
|
|
8000
|
-
}
|
|
8059
|
+
}
|
|
8001
8060
|
|
|
8002
|
-
|
|
8003
|
-
|
|
8004
|
-
|
|
8005
|
-
|
|
8061
|
+
if (changedProperties.has('loading')) {
|
|
8062
|
+
const event = new CustomEvent("auroMenu-loadingChange", {
|
|
8063
|
+
detail: {
|
|
8064
|
+
loading: this.loading,
|
|
8065
|
+
hasLoadingPlaceholder:
|
|
8066
|
+
this.hasLoadingPlaceholder
|
|
8067
|
+
}
|
|
8068
|
+
});
|
|
8069
|
+
this.setAttribute("aria-busy", this.hasAttribute("loading"));
|
|
8070
|
+
this.dispatchEvent(event);
|
|
8071
|
+
}
|
|
8006
8072
|
}
|
|
8007
8073
|
|
|
8008
8074
|
/**
|
|
8009
|
-
* Async function to fetch requested icon from npm CDN.
|
|
8010
8075
|
* @private
|
|
8011
|
-
* @param {
|
|
8012
|
-
* @
|
|
8013
|
-
* @returns {SVGElement} DOM - Ready HTML to be appended.
|
|
8076
|
+
* @param {Object} option - The menuoption to check for interactive state.
|
|
8077
|
+
* @returns {Boolean} Returns true if the option is interactive.
|
|
8014
8078
|
*/
|
|
8015
|
-
|
|
8016
|
-
|
|
8079
|
+
optionInteractive(option) {
|
|
8080
|
+
return !option.hasAttribute('hidden') && !option.hasAttribute('disabled') && !option.hasAttribute('static');
|
|
8081
|
+
}
|
|
8017
8082
|
|
|
8018
|
-
|
|
8019
|
-
|
|
8020
|
-
|
|
8021
|
-
|
|
8022
|
-
|
|
8023
|
-
|
|
8024
|
-
const dom = new DOMParser().parseFromString(iconHTML, 'text/html');
|
|
8083
|
+
/**
|
|
8084
|
+
* @private
|
|
8085
|
+
* @returns {void} When called will update the DOM with visible suggest text matches.
|
|
8086
|
+
*/
|
|
8087
|
+
markOptions() {
|
|
8088
|
+
if (this.items && this.items.length > 0 && (this.matchWord && this.matchWord.length > 0)) {
|
|
8025
8089
|
|
|
8026
|
-
|
|
8027
|
-
|
|
8090
|
+
// Escape special regex characters
|
|
8091
|
+
const escapedWord = this.matchWord.replace(/[.*+?^${}()|[\]\\]/gu, '\\$&');
|
|
8028
8092
|
|
|
8029
|
-
|
|
8030
|
-
|
|
8031
|
-
if (!this.customSvg) {
|
|
8032
|
-
const svg = await this.fetchIcon(this.category, this.name);
|
|
8093
|
+
// Global, case-insensitive, unicode matching regex pattern
|
|
8094
|
+
const regexWord = new RegExp(escapedWord, 'giu');
|
|
8033
8095
|
|
|
8034
|
-
|
|
8035
|
-
this.
|
|
8036
|
-
|
|
8037
|
-
|
|
8096
|
+
this.items.forEach((item) => {
|
|
8097
|
+
if (this.optionInteractive(item) && !item.hasAttribute('persistent')) {
|
|
8098
|
+
const nested = item.querySelectorAll('.nestingSpacer');
|
|
8099
|
+
const nestingSpacerBundle = [...nested].map(() => this.nestingSpacer).join('');
|
|
8038
8100
|
|
|
8039
|
-
|
|
8040
|
-
|
|
8101
|
+
item.innerHTML = nestingSpacerBundle + item.textContent.replace(regexWord, (match) => `<strong>${match}</strong>`);
|
|
8102
|
+
}
|
|
8103
|
+
});
|
|
8041
8104
|
}
|
|
8042
8105
|
}
|
|
8043
|
-
}
|
|
8044
|
-
|
|
8045
|
-
var tokensCss = i$c`:host{--ds-auro-icon-color: var(--ds-color-icon-primary-default, $ds-color-icon-primary-default);--ds-auro-icon-size: var(--ds-size-300, $ds-size-300)}`;
|
|
8046
|
-
|
|
8047
|
-
var colorCss = i$c`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[accent]){--ds-auro-icon-color: var(--ds-color-icon-accent-default, #a2c270)}:host(:not([onDark])[disabled]){--ds-auro-icon-color: var(--ds-color-icon-ui-primary-disabled-default, #adadad)}:host(:not([onDark])[emphasis]){--ds-auro-icon-color: var(--ds-color-icon-emphasis-default, #2a2a2a)}:host(:not([onDark])[error]){--ds-auro-icon-color: var(--ds-color-icon-error-default, #cc1816)}:host(:not([onDark])[info]){--ds-auro-icon-color: var(--ds-color-icon-info-default, #326aa5)}:host(:not([onDark])[secondary]){--ds-auro-icon-color: var(--ds-color-icon-secondary-default, #7e8894)}:host(:not([onDark])[subtle]){--ds-auro-icon-color: var(--ds-color-icon-subtle-default, #a0c9f1)}:host(:not([onDark])[success]){--ds-auro-icon-color: var(--ds-color-icon-success-default, #40a080)}:host(:not([onDark])[tertiary]){--ds-auro-icon-color: var(--ds-color-icon-tertiary-default, #afb9c6)}:host(:not([onDark])[warning]){--ds-auro-icon-color: var(--ds-color-icon-warning-default, #c49432)}:host([onDark]){--ds-auro-icon-color: var(--ds-color-icon-primary-inverse, #f7f7f7)}:host([onDark][accent]){--ds-auro-icon-color: var(--ds-color-icon-accent-inverse, #badd81)}:host([onDark][disabled]){--ds-auro-icon-color: var(--ds-color-icon-ui-primary-disabled-inverse, #7e7e7e)}:host([onDark][emphasis]){--ds-auro-icon-color: var(--ds-color-icon-emphasis-inverse, #ffffff)}:host([onDark][error]){--ds-auro-icon-color: var(--ds-color-icon-error-inverse, #f9aca6)}:host([onDark][info]){--ds-auro-icon-color: var(--ds-color-icon-info-inverse, #89b2d4)}:host([onDark][secondary]){--ds-auro-icon-color: var(--ds-color-icon-secondary-inverse, #ccd2db)}:host([onDark][subtle]){--ds-auro-icon-color: var(--ds-color-icon-subtle-inverse, #326aa5)}:host([onDark][success]){--ds-auro-icon-color: var(--ds-color-icon-success-inverse, #8eceb9)}:host([onDark][tertiary]){--ds-auro-icon-color: var(--ds-color-icon-tertiary-inverse, #939fad)}:host([onDark][warning]){--ds-auro-icon-color: var(--ds-color-icon-warning-inverse, #f2c153)}`;
|
|
8048
|
-
|
|
8049
|
-
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
8050
|
-
// See LICENSE in the project root for license information.
|
|
8051
|
-
|
|
8052
|
-
|
|
8053
|
-
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
8054
|
-
/**
|
|
8055
|
-
* auro-icon provides users a way to use the Auro Icons by simply passing in the category and name.
|
|
8056
|
-
*
|
|
8057
|
-
* @attr {String} category - The category of the icon you are looking for. See https://auro.alaskaair.com/icons/usage.
|
|
8058
|
-
* @attr {String} name - The name of the icon you are looking for without the file extension. See https://auro.alaskaair.com/icons/usage
|
|
8059
|
-
* @attr {Boolean} customColor - Removes primary selector.
|
|
8060
|
-
* @attr {Boolean} customSvg - When true, auro-icon will render a custom SVG inside the default slot.
|
|
8061
|
-
* @attr {Boolean} label - Exposes content in slot as icon label.
|
|
8062
|
-
* @attr {Boolean} primary - DEPRECATED: Sets the icon to use the baseline primary icon style.
|
|
8063
|
-
* @attr {Boolean} accent - Sets the icon to use the accent style.
|
|
8064
|
-
* @attr {Boolean} emphasis - Sets the icon to use the emphasis style.
|
|
8065
|
-
* @attr {Boolean} disabled - Sets the icon to use the disabled style.
|
|
8066
|
-
* @attr {Boolean} error - Sets the icon to use the error style.
|
|
8067
|
-
* @attr {Boolean} info - Sets the icon to use the info style.
|
|
8068
|
-
* @attr {Boolean} secondary - Sets the icon to use the secondary style.
|
|
8069
|
-
* @attr {Boolean} tertiary - Sets the icon to use the tertiary style.
|
|
8070
|
-
* @attr {Boolean} subtle - Sets the icon to use the subtle style.
|
|
8071
|
-
* @attr {Boolean} success - Sets the icon to use the success style.
|
|
8072
|
-
* @attr {Boolean} warning - Sets the icon to use the warning style.
|
|
8073
|
-
* @attr {String} ariaHidden - Set aria-hidden value. Default is `true`. Option is `false`.
|
|
8074
|
-
* @attr {String} uri - Set the uri for CDN used when fetching icons
|
|
8075
|
-
* @slot - Hidden from visibility, used for a11y if icon description is needed.
|
|
8076
|
-
* @slot svg - Used for custom SVG content.
|
|
8077
|
-
*/
|
|
8078
|
-
|
|
8079
|
-
// build the component class
|
|
8080
|
-
class AuroIcon extends BaseIcon {
|
|
8081
|
-
constructor() {
|
|
8082
|
-
super();
|
|
8083
8106
|
|
|
8084
|
-
|
|
8085
|
-
|
|
8086
|
-
|
|
8107
|
+
/**
|
|
8108
|
+
* Reset the menu and all options.
|
|
8109
|
+
*/
|
|
8110
|
+
resetOptionsStates() {
|
|
8111
|
+
this.optionSelected = undefined;
|
|
8112
|
+
if (this.items) {
|
|
8113
|
+
this.items.forEach((item) => {
|
|
8114
|
+
item.classList.remove('active');
|
|
8115
|
+
item.removeAttribute('selected');
|
|
8116
|
+
});
|
|
8117
|
+
}
|
|
8087
8118
|
}
|
|
8088
8119
|
|
|
8089
8120
|
/**
|
|
8090
|
-
*
|
|
8121
|
+
* Set the attributes on the selected menuoption, the menu value and stored option.
|
|
8122
|
+
* @param {Object} option - The menuoption to be selected.
|
|
8091
8123
|
* @private
|
|
8092
|
-
* @returns {void}
|
|
8093
8124
|
*/
|
|
8094
|
-
|
|
8095
|
-
|
|
8096
|
-
|
|
8097
|
-
|
|
8098
|
-
this.disabled = false;
|
|
8099
|
-
this.emphasis = false;
|
|
8100
|
-
this.error = false;
|
|
8101
|
-
this.info = false;
|
|
8102
|
-
this.label = false;
|
|
8103
|
-
this.primary = false;
|
|
8104
|
-
this.secondary = false;
|
|
8105
|
-
this.subtle = false;
|
|
8106
|
-
this.success = false;
|
|
8107
|
-
this.tertiary = false;
|
|
8108
|
-
this.warning = false;
|
|
8109
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$2();
|
|
8110
|
-
}
|
|
8111
|
-
|
|
8112
|
-
// function to define props used within the scope of this component
|
|
8113
|
-
static get properties() {
|
|
8114
|
-
return {
|
|
8115
|
-
...super.properties,
|
|
8116
|
-
accent: {
|
|
8117
|
-
type: Boolean,
|
|
8118
|
-
reflect: true
|
|
8119
|
-
},
|
|
8120
|
-
ariaHidden: {
|
|
8121
|
-
type: String,
|
|
8122
|
-
reflect: true
|
|
8123
|
-
},
|
|
8124
|
-
category: {
|
|
8125
|
-
type: String,
|
|
8126
|
-
reflect: true
|
|
8127
|
-
},
|
|
8128
|
-
customColor: {
|
|
8129
|
-
type: Boolean
|
|
8130
|
-
},
|
|
8131
|
-
customSvg: {
|
|
8132
|
-
type: Boolean
|
|
8133
|
-
},
|
|
8134
|
-
disabled: {
|
|
8135
|
-
type: Boolean,
|
|
8136
|
-
reflect: true
|
|
8137
|
-
},
|
|
8138
|
-
emphasis: {
|
|
8139
|
-
type: Boolean,
|
|
8140
|
-
reflect: true
|
|
8141
|
-
},
|
|
8142
|
-
error: {
|
|
8143
|
-
type: Boolean,
|
|
8144
|
-
reflect: true
|
|
8145
|
-
},
|
|
8146
|
-
info: {
|
|
8147
|
-
type: Boolean,
|
|
8148
|
-
reflect: true
|
|
8149
|
-
},
|
|
8150
|
-
label: {
|
|
8151
|
-
type: Boolean,
|
|
8152
|
-
reflect: true
|
|
8153
|
-
},
|
|
8154
|
-
name: {
|
|
8155
|
-
type: String,
|
|
8156
|
-
reflect: true
|
|
8157
|
-
},
|
|
8158
|
-
primary: {
|
|
8159
|
-
type: Boolean,
|
|
8160
|
-
reflect: true
|
|
8161
|
-
},
|
|
8162
|
-
secondary: {
|
|
8163
|
-
type: Boolean,
|
|
8164
|
-
reflect: true
|
|
8165
|
-
},
|
|
8166
|
-
subtle: {
|
|
8167
|
-
type: Boolean,
|
|
8168
|
-
reflect: true
|
|
8169
|
-
},
|
|
8170
|
-
success: {
|
|
8171
|
-
type: Boolean,
|
|
8172
|
-
reflect: true
|
|
8173
|
-
},
|
|
8174
|
-
tertiary: {
|
|
8175
|
-
type: Boolean,
|
|
8176
|
-
reflect: true
|
|
8177
|
-
},
|
|
8178
|
-
uri: {
|
|
8179
|
-
type: String
|
|
8180
|
-
},
|
|
8181
|
-
warning: {
|
|
8182
|
-
type: Boolean,
|
|
8183
|
-
reflect: true
|
|
8184
|
-
}
|
|
8185
|
-
};
|
|
8186
|
-
}
|
|
8125
|
+
handleLocalSelectState(option) {
|
|
8126
|
+
option.setAttribute('selected', '');
|
|
8127
|
+
option.classList.add('active');
|
|
8128
|
+
option.ariaSelected = true;
|
|
8187
8129
|
|
|
8188
|
-
|
|
8189
|
-
|
|
8190
|
-
|
|
8191
|
-
i$c`${tokensCss}`,
|
|
8192
|
-
i$c`${styleCss}`,
|
|
8193
|
-
i$c`${colorCss}`
|
|
8194
|
-
];
|
|
8130
|
+
this.value = option.value;
|
|
8131
|
+
this.optionSelected = option;
|
|
8132
|
+
this.index = this.items.indexOf(option);
|
|
8195
8133
|
}
|
|
8196
8134
|
|
|
8197
8135
|
/**
|
|
8198
|
-
*
|
|
8199
|
-
* @
|
|
8200
|
-
*
|
|
8201
|
-
* @example
|
|
8202
|
-
* AuroIcon.register("custom-icon") // this will register this element to <custom-icon/>
|
|
8203
|
-
*
|
|
8136
|
+
* Notify selection change.
|
|
8137
|
+
* @private
|
|
8138
|
+
* @return {void}
|
|
8204
8139
|
*/
|
|
8205
|
-
|
|
8206
|
-
|
|
8207
|
-
|
|
8208
|
-
|
|
8209
|
-
|
|
8210
|
-
|
|
8140
|
+
notifySelectionChange() {
|
|
8141
|
+
// this event needs to be removed after select and combobox are updated to use the new standard name
|
|
8142
|
+
this.dispatchEvent(new CustomEvent('selectedOption', {
|
|
8143
|
+
bubbles: true,
|
|
8144
|
+
cancelable: false,
|
|
8145
|
+
composed: true,
|
|
8146
|
+
}));
|
|
8211
8147
|
|
|
8212
|
-
|
|
8213
|
-
|
|
8148
|
+
this.dispatchEvent(new CustomEvent('auroMenu-selectedOption', {
|
|
8149
|
+
bubbles: true,
|
|
8150
|
+
cancelable: false,
|
|
8151
|
+
composed: true,
|
|
8152
|
+
}));
|
|
8214
8153
|
}
|
|
8215
8154
|
|
|
8216
8155
|
/**
|
|
8217
|
-
*
|
|
8156
|
+
* Process actions for making making a menuoption selection.
|
|
8218
8157
|
*/
|
|
8219
|
-
|
|
8220
|
-
this.
|
|
8221
|
-
|
|
8158
|
+
makeSelection() {
|
|
8159
|
+
if (!this.items) {
|
|
8160
|
+
this.initItems();
|
|
8161
|
+
}
|
|
8222
8162
|
|
|
8223
|
-
|
|
8224
|
-
|
|
8225
|
-
const a11y = {
|
|
8226
|
-
'labelContainer': true,
|
|
8227
|
-
'util_displayHiddenVisually': !this.label
|
|
8228
|
-
};
|
|
8163
|
+
if (this.items[this.index] && !this.items[this.index].hasAttribute('disabled')) {
|
|
8164
|
+
this.resetOptionsStates();
|
|
8229
8165
|
|
|
8230
|
-
|
|
8231
|
-
|
|
8232
|
-
};
|
|
8166
|
+
if (this.index >= 0) {
|
|
8167
|
+
const option = this.items[this.index];
|
|
8233
8168
|
|
|
8234
|
-
|
|
8235
|
-
|
|
8236
|
-
|
|
8237
|
-
|
|
8238
|
-
|
|
8239
|
-
|
|
8240
|
-
|
|
8241
|
-
|
|
8242
|
-
|
|
8243
|
-
`
|
|
8244
|
-
}
|
|
8245
|
-
</span>
|
|
8246
|
-
|
|
8247
|
-
<div class="${e(a11y)}">
|
|
8248
|
-
<slot></slot>
|
|
8249
|
-
</div>
|
|
8250
|
-
</div>
|
|
8251
|
-
`;
|
|
8252
|
-
}
|
|
8253
|
-
}
|
|
8254
|
-
|
|
8255
|
-
var iconVersion = '6.1.1';
|
|
8256
|
-
|
|
8257
|
-
var checkmarkIcon = {"role":"img","color":"currentColor","title":"","desc":"a small check mark.","width":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","height":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","xmlns":"http://www.w3.org/2000/svg","xmlns_xlink":"http://www.w3.org/1999/xlink","viewBox":"0 0 24 24","path":"/icons","style":"ico_squareLarge","type":"icon","name":"checkmark-sm","category":"interface","svg":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" aria-labelledby=\"checkmark-sm__desc\" class=\"ico_squareLarge\" role=\"img\" style=\"min-width:var(--auro-size-lg, var(--ds-size-300, 1.5rem));height:var(--auro-size-lg, var(--ds-size-300, 1.5rem));fill:currentColor\" viewBox=\"0 0 24 24\" part=\"svg\"><title/><desc id=\"checkmark-sm__desc\">a small check mark.</desc><path d=\"M8.461 11.84a.625.625 0 1 0-.922.844l2.504 2.738c.247.27.674.27.922 0l5.496-6a.625.625 0 1 0-.922-.844l-5.035 5.496z\"/></svg>"};
|
|
8169
|
+
// only handle options that are not disabled, hidden or static
|
|
8170
|
+
if (option && this.optionInteractive(option)) {
|
|
8171
|
+
// fire custom event if defined otherwise make selection
|
|
8172
|
+
if (option.hasAttribute('event')) {
|
|
8173
|
+
this.dispatchEvent(new CustomEvent(option.getAttribute('event'), {
|
|
8174
|
+
bubbles: true,
|
|
8175
|
+
cancelable: false,
|
|
8176
|
+
composed: true,
|
|
8177
|
+
}));
|
|
8258
8178
|
|
|
8259
|
-
//
|
|
8260
|
-
|
|
8179
|
+
// this event needs to be removed after select and combobox are updated to use the new standard name
|
|
8180
|
+
this.dispatchEvent(new CustomEvent('auroMenuCustomEventFired', {
|
|
8181
|
+
bubbles: true,
|
|
8182
|
+
cancelable: false,
|
|
8183
|
+
composed: true,
|
|
8184
|
+
}));
|
|
8261
8185
|
|
|
8186
|
+
this.dispatchEvent(new CustomEvent('auroMenu-customEventFired', {
|
|
8187
|
+
bubbles: true,
|
|
8188
|
+
cancelable: false,
|
|
8189
|
+
composed: true,
|
|
8190
|
+
}));
|
|
8191
|
+
} else {
|
|
8192
|
+
this.handleLocalSelectState(option);
|
|
8193
|
+
}
|
|
8194
|
+
}
|
|
8195
|
+
}
|
|
8196
|
+
}
|
|
8262
8197
|
|
|
8263
|
-
|
|
8264
|
-
|
|
8265
|
-
*
|
|
8266
|
-
* @attr {String} value - Specifies the value to be sent to a server.
|
|
8267
|
-
* @attr {String} noCheckmark - When true, selected option will not show the checkmark.
|
|
8268
|
-
* @attr {Boolean} disabled - When true specifies that the menuoption is disabled.
|
|
8269
|
-
* @attr {Boolean} selected - Specifies that an option is selected.
|
|
8270
|
-
* @event auroMenuOption-mouseover - Notifies that this option has been hovered over.
|
|
8271
|
-
* @slot Specifies text for an option, but is not the value.
|
|
8272
|
-
*/
|
|
8273
|
-
class AuroMenuOption extends r$6 {
|
|
8274
|
-
constructor() {
|
|
8275
|
-
super();
|
|
8198
|
+
this.notifySelectionChange();
|
|
8199
|
+
}
|
|
8276
8200
|
|
|
8277
|
-
|
|
8278
|
-
|
|
8279
|
-
|
|
8280
|
-
|
|
8281
|
-
|
|
8201
|
+
/**
|
|
8202
|
+
* Manage ArrowDown, ArrowUp and Enter keyboard events.
|
|
8203
|
+
* @private
|
|
8204
|
+
* @param {Object} event - Event object from the browser.
|
|
8205
|
+
*/
|
|
8206
|
+
handleKeyDown(event) {
|
|
8207
|
+
event.preventDefault();
|
|
8282
8208
|
|
|
8283
|
-
|
|
8284
|
-
|
|
8285
|
-
|
|
8209
|
+
// With ArrowDown/ArrowUp events, pass new value to selectNextItem()
|
|
8210
|
+
// With Enter event, set value and apply attrs
|
|
8211
|
+
switch (event.key) {
|
|
8212
|
+
case "ArrowDown":
|
|
8213
|
+
this.selectNextItem('down');
|
|
8214
|
+
break;
|
|
8286
8215
|
|
|
8287
|
-
|
|
8288
|
-
|
|
8289
|
-
|
|
8290
|
-
this.tabIndex = -1;
|
|
8216
|
+
case "ArrowUp":
|
|
8217
|
+
this.selectNextItem('up');
|
|
8218
|
+
break;
|
|
8291
8219
|
|
|
8292
|
-
|
|
8293
|
-
|
|
8294
|
-
|
|
8295
|
-
|
|
8220
|
+
case "Enter":
|
|
8221
|
+
this.makeSelection();
|
|
8222
|
+
break;
|
|
8223
|
+
}
|
|
8296
8224
|
}
|
|
8297
8225
|
|
|
8298
|
-
|
|
8299
|
-
|
|
8300
|
-
|
|
8301
|
-
|
|
8302
|
-
|
|
8303
|
-
|
|
8304
|
-
|
|
8305
|
-
type: Boolean,
|
|
8306
|
-
reflect: true
|
|
8307
|
-
},
|
|
8308
|
-
disabled: {
|
|
8309
|
-
type: Boolean,
|
|
8310
|
-
reflect: true
|
|
8311
|
-
},
|
|
8312
|
-
value: {
|
|
8313
|
-
type: String,
|
|
8314
|
-
reflect: true
|
|
8315
|
-
},
|
|
8316
|
-
tabIndex: {
|
|
8317
|
-
type: Number,
|
|
8318
|
-
reflect: true
|
|
8319
|
-
}
|
|
8320
|
-
};
|
|
8226
|
+
/**
|
|
8227
|
+
* Initializes all menu options in the DOM. This must be re-run every time the options are changed.
|
|
8228
|
+
* @private
|
|
8229
|
+
*/
|
|
8230
|
+
initItems() {
|
|
8231
|
+
this.items = Array.from(this.querySelectorAll('auro-menuoption, [auro-menuoption]'));
|
|
8232
|
+
this.handleNoCheckmarkAttr();
|
|
8321
8233
|
}
|
|
8322
8234
|
|
|
8323
|
-
|
|
8324
|
-
|
|
8325
|
-
|
|
8326
|
-
|
|
8327
|
-
|
|
8328
|
-
|
|
8235
|
+
/**
|
|
8236
|
+
* Sets the index value of the selected item or first non-disabled menuoption.
|
|
8237
|
+
* @private
|
|
8238
|
+
*/
|
|
8239
|
+
getSelectedIndex() {
|
|
8240
|
+
// find the first `selected` and not `disabled`, `hidden` or `static` option
|
|
8241
|
+
const index = this.items.findIndex((option) => option.hasAttribute('selected') && this.optionInteractive(option));
|
|
8242
|
+
|
|
8243
|
+
if (index >= 0) {
|
|
8244
|
+
this.index = index;
|
|
8245
|
+
this.makeSelection();
|
|
8246
|
+
}
|
|
8329
8247
|
}
|
|
8330
8248
|
|
|
8331
8249
|
/**
|
|
8332
|
-
*
|
|
8333
|
-
*
|
|
8334
|
-
*
|
|
8335
|
-
* @example
|
|
8336
|
-
* AuroMenuOption.register("custom-menuoption") // this will register this element to <custom-menuoption/>
|
|
8250
|
+
* Using value of current this.index evaluates index
|
|
8251
|
+
* of next :focus to set based on array of this.items ignoring items
|
|
8252
|
+
* with disabled attr.
|
|
8337
8253
|
*
|
|
8254
|
+
* The event.target is not used as the function needs to know where to go,
|
|
8255
|
+
* versus knowing where it is.
|
|
8256
|
+
* @param {String} moveDirection - Up or Down based on keyboard event.
|
|
8338
8257
|
*/
|
|
8339
|
-
|
|
8340
|
-
|
|
8341
|
-
|
|
8258
|
+
selectNextItem(moveDirection) {
|
|
8259
|
+
if (this.index >= 0) {
|
|
8260
|
+
this.items[this.index].classList.remove('active');
|
|
8342
8261
|
|
|
8343
|
-
|
|
8344
|
-
|
|
8345
|
-
this.runtimeUtils.handleComponentTagRename(this, 'auro-menuoption');
|
|
8262
|
+
// calculate which is the selection we should focus next
|
|
8263
|
+
let increment = 0;
|
|
8346
8264
|
|
|
8347
|
-
|
|
8348
|
-
|
|
8265
|
+
if (moveDirection === 'down') {
|
|
8266
|
+
increment = 1;
|
|
8267
|
+
} else if (moveDirection === 'up') {
|
|
8268
|
+
increment = -1;
|
|
8269
|
+
}
|
|
8349
8270
|
|
|
8350
|
-
|
|
8351
|
-
this.dispatchEvent(new CustomEvent('auroMenuOption-mouseover', {
|
|
8352
|
-
bubbles: true,
|
|
8353
|
-
cancelable: false,
|
|
8354
|
-
composed: true,
|
|
8355
|
-
detail: this
|
|
8356
|
-
}));
|
|
8357
|
-
});
|
|
8358
|
-
}
|
|
8271
|
+
this.index += increment;
|
|
8359
8272
|
|
|
8360
|
-
|
|
8361
|
-
|
|
8362
|
-
|
|
8363
|
-
this.
|
|
8273
|
+
// keep looping inside the array of options
|
|
8274
|
+
if (this.index > this.items.length - 1) {
|
|
8275
|
+
this.index = 0;
|
|
8276
|
+
} else if (this.index < 0) {
|
|
8277
|
+
this.index = this.items.length - 1;
|
|
8278
|
+
}
|
|
8279
|
+
|
|
8280
|
+
// check if new index is disabled, static or hidden, if so, execute again
|
|
8281
|
+
if (!this.optionInteractive(this.items[this.index])) {
|
|
8282
|
+
this.selectNextItem(moveDirection);
|
|
8283
|
+
} else {
|
|
8284
|
+
// apply focus to new index
|
|
8285
|
+
this.updateActiveOption(this.index);
|
|
8286
|
+
}
|
|
8287
|
+
} else {
|
|
8288
|
+
this.index = 0;
|
|
8289
|
+
|
|
8290
|
+
if (this.items[this.index].hasAttribute('hidden') || this.items[this.index].hasAttribute('disabled')) {
|
|
8291
|
+
this.selectNextItem(moveDirection);
|
|
8292
|
+
} else {
|
|
8293
|
+
this.updateActiveOption(this.index);
|
|
8294
|
+
}
|
|
8364
8295
|
}
|
|
8365
8296
|
}
|
|
8366
8297
|
|
|
8367
8298
|
/**
|
|
8368
|
-
*
|
|
8369
|
-
*
|
|
8299
|
+
* Used for applying indentation to each level of nested menu.
|
|
8370
8300
|
* @private
|
|
8371
|
-
* @param {
|
|
8372
|
-
* @returns {Element} The HTML element containing the SVG icon.
|
|
8301
|
+
* @param {String} menu - Root level menu object.
|
|
8373
8302
|
*/
|
|
8374
|
-
|
|
8375
|
-
const
|
|
8376
|
-
const svg = dom.body.firstChild;
|
|
8303
|
+
handleNestedMenus(menu) {
|
|
8304
|
+
const nestedMenus = menu.querySelectorAll('auro-menu, [auro-menu');
|
|
8377
8305
|
|
|
8378
|
-
|
|
8306
|
+
if (nestedMenus.length === 0) {
|
|
8307
|
+
return;
|
|
8308
|
+
}
|
|
8379
8309
|
|
|
8380
|
-
|
|
8381
|
-
|
|
8310
|
+
nestedMenus.forEach((nestedMenu) => {
|
|
8311
|
+
const options = nestedMenu.querySelectorAll(':scope > auro-menuoption, :scope > [auro-menuoption');
|
|
8382
8312
|
|
|
8383
|
-
|
|
8384
|
-
|
|
8385
|
-
|
|
8386
|
-
|
|
8387
|
-
|
|
8313
|
+
options.forEach((option) => {
|
|
8314
|
+
option.innerHTML = this.nestingSpacer + option.innerHTML;
|
|
8315
|
+
});
|
|
8316
|
+
|
|
8317
|
+
this.handleNestedMenus(nestedMenu);
|
|
8318
|
+
});
|
|
8388
8319
|
}
|
|
8389
|
-
}
|
|
8390
8320
|
|
|
8391
|
-
|
|
8392
|
-
|
|
8321
|
+
/**
|
|
8322
|
+
* Method to apply `selected` attribute to `menuoption` via `value`.
|
|
8323
|
+
* @private
|
|
8324
|
+
* @param {String} value - Must match a unique `menuoption` value.
|
|
8325
|
+
*/
|
|
8326
|
+
selectByValue(value) {
|
|
8327
|
+
let valueMatch = false;
|
|
8328
|
+
if (!this.items) {
|
|
8329
|
+
this.initItems();
|
|
8330
|
+
}
|
|
8393
8331
|
|
|
8332
|
+
this.index = undefined;
|
|
8394
8333
|
|
|
8395
|
-
|
|
8396
|
-
|
|
8397
|
-
|
|
8398
|
-
|
|
8399
|
-
|
|
8400
|
-
|
|
8401
|
-
|
|
8402
|
-
* @attr {String} value - Value selected for the menu.
|
|
8403
|
-
* @event auroMenu-selectedOption - Notifies that a new menuoption selection has been made.
|
|
8404
|
-
* @event selectedOption - (DEPRECATED) Notifies that a new menuoption selection has been made.
|
|
8405
|
-
* @event auroMenu-activatedOption - Notifies that a menuoption has been made `active`.
|
|
8406
|
-
* @event auroMenuActivatedOption - (DEPRECATED) Notifies that a menuoption has been made `active`.
|
|
8407
|
-
* @event auroMenu-selectValueFailure - Notifies that a an attempt to select a menuoption by matching a value has failed.
|
|
8408
|
-
* @event auroMenuSelectValueFailure - (DEPRECATED) Notifies that a an attempt to select a menuoption by matching a value has failed.
|
|
8409
|
-
* @event auroMenu-customEventFired - Notifies that a custom event has been fired.
|
|
8410
|
-
* @event auroMenuCustomEventFired - (DEPRECATED) Notifies that a custom event has been fired.
|
|
8411
|
-
* @event auroMenu-selectValueReset - Notifies that the component value has been reset.
|
|
8412
|
-
* @slot Slot for insertion of menu options.
|
|
8413
|
-
*/
|
|
8414
|
-
|
|
8415
|
-
/* eslint-disable no-magic-numbers, max-lines */
|
|
8334
|
+
if (this.value && this.value.length > 0) {
|
|
8335
|
+
for (let index = 0; index < this.items.length; index += 1) {
|
|
8336
|
+
if (this.items[index].value === value) {
|
|
8337
|
+
valueMatch = true;
|
|
8338
|
+
this.index = index;
|
|
8339
|
+
}
|
|
8340
|
+
}
|
|
8416
8341
|
|
|
8417
|
-
|
|
8418
|
-
|
|
8419
|
-
|
|
8420
|
-
this.value = undefined;
|
|
8421
|
-
this.optionSelected = undefined;
|
|
8422
|
-
this.matchWord = undefined;
|
|
8423
|
-
this.noCheckmark = false;
|
|
8424
|
-
this.optionActive = undefined;
|
|
8342
|
+
if (!valueMatch) {
|
|
8343
|
+
// reset the menu to no selection
|
|
8344
|
+
this.index = undefined;
|
|
8425
8345
|
|
|
8426
|
-
|
|
8427
|
-
|
|
8428
|
-
|
|
8429
|
-
|
|
8346
|
+
// this event needs to be removed after select and combobox are updated to use the new standard name
|
|
8347
|
+
this.dispatchEvent(new CustomEvent('auroMenuSelectValueFailure', {
|
|
8348
|
+
bubbles: true,
|
|
8349
|
+
cancelable: false,
|
|
8350
|
+
composed: true,
|
|
8351
|
+
}));
|
|
8430
8352
|
|
|
8431
|
-
|
|
8432
|
-
|
|
8433
|
-
|
|
8434
|
-
|
|
8353
|
+
this.dispatchEvent(new CustomEvent('auroMenu-selectValueFailure', {
|
|
8354
|
+
bubbles: true,
|
|
8355
|
+
cancelable: false,
|
|
8356
|
+
composed: true,
|
|
8357
|
+
}));
|
|
8358
|
+
} else {
|
|
8359
|
+
this.makeSelection();
|
|
8360
|
+
}
|
|
8361
|
+
} else {
|
|
8362
|
+
this.resetOptionsStates();
|
|
8435
8363
|
|
|
8436
|
-
|
|
8437
|
-
|
|
8438
|
-
|
|
8439
|
-
|
|
8364
|
+
this.dispatchEvent(new CustomEvent('auroMenu-selectValueReset', {
|
|
8365
|
+
bubbles: true,
|
|
8366
|
+
cancelable: false,
|
|
8367
|
+
composed: true,
|
|
8368
|
+
}));
|
|
8369
|
+
}
|
|
8440
8370
|
}
|
|
8441
8371
|
|
|
8442
|
-
|
|
8443
|
-
|
|
8444
|
-
|
|
8445
|
-
|
|
8446
|
-
|
|
8447
|
-
|
|
8448
|
-
|
|
8449
|
-
|
|
8450
|
-
|
|
8451
|
-
|
|
8452
|
-
|
|
8453
|
-
|
|
8454
|
-
|
|
8455
|
-
|
|
8456
|
-
|
|
8372
|
+
/**
|
|
8373
|
+
* Used to make the active state for options follow mouseover.
|
|
8374
|
+
* @param {Number} index - Index of the menuoption that will be made active.
|
|
8375
|
+
* @private
|
|
8376
|
+
*/
|
|
8377
|
+
updateActiveOption(index) {
|
|
8378
|
+
this.items.forEach((item) => {
|
|
8379
|
+
item.classList.remove('active');
|
|
8380
|
+
});
|
|
8381
|
+
this.items[index].classList.add('active');
|
|
8382
|
+
this.optionActive = this.items[index];
|
|
8383
|
+
|
|
8384
|
+
this.dispatchEvent(new CustomEvent('auroMenuActivatedOption', {
|
|
8385
|
+
bubbles: true,
|
|
8386
|
+
cancelable: false,
|
|
8387
|
+
composed: true,
|
|
8388
|
+
detail: this.items[index]
|
|
8389
|
+
}));
|
|
8390
|
+
|
|
8391
|
+
this.dispatchEvent(new CustomEvent('auroMenu-activatedOption', {
|
|
8392
|
+
bubbles: true,
|
|
8393
|
+
cancelable: false,
|
|
8394
|
+
composed: true,
|
|
8395
|
+
detail: this.items[index]
|
|
8396
|
+
}));
|
|
8457
8397
|
}
|
|
8458
8398
|
|
|
8459
|
-
|
|
8460
|
-
|
|
8461
|
-
|
|
8462
|
-
|
|
8463
|
-
|
|
8464
|
-
|
|
8399
|
+
/**
|
|
8400
|
+
* Used to only make a selection when a menuoption is receiving a mousedown event.
|
|
8401
|
+
* @param {Event} evt - Mousedown event.
|
|
8402
|
+
* @private
|
|
8403
|
+
*/
|
|
8404
|
+
handleMenuMouseDown(evt) {
|
|
8405
|
+
if (evt.target !== this) {
|
|
8406
|
+
this.makeSelection();
|
|
8407
|
+
}
|
|
8465
8408
|
}
|
|
8466
8409
|
|
|
8467
8410
|
/**
|
|
8468
|
-
*
|
|
8469
|
-
* @param {string} [name="auro-menu"] - The name of element that you want to register to.
|
|
8411
|
+
* Checks if there are any loading placeholders in the component.
|
|
8470
8412
|
*
|
|
8471
|
-
*
|
|
8472
|
-
*
|
|
8413
|
+
* This getter evaluates the `loadingSlots` collection to determine if it contains any items.
|
|
8414
|
+
* If the size of the collection is greater than zero, it indicates the presence of loading
|
|
8415
|
+
* placeholders, returning true; otherwise, it returns false.
|
|
8473
8416
|
*
|
|
8417
|
+
* @getter hasLoadingPlaceholder
|
|
8418
|
+
* @type {boolean}
|
|
8419
|
+
* @returns {boolean} Returns true if loading placeholders exist; false otherwise.
|
|
8474
8420
|
*/
|
|
8475
|
-
|
|
8476
|
-
|
|
8421
|
+
get hasLoadingPlaceholder() {
|
|
8422
|
+
return this.loadingSlots.length > 0;
|
|
8477
8423
|
}
|
|
8478
8424
|
|
|
8479
8425
|
/**
|
|
8480
|
-
*
|
|
8426
|
+
* Used for @slotchange event on slotted element.
|
|
8481
8427
|
* @private
|
|
8482
|
-
* @returns {void}
|
|
8483
8428
|
*/
|
|
8484
|
-
|
|
8485
|
-
if
|
|
8486
|
-
|
|
8487
|
-
|
|
8488
|
-
|
|
8489
|
-
menu.setAttribute('noCheckmark', '');
|
|
8490
|
-
});
|
|
8429
|
+
handleSlotItems() {
|
|
8430
|
+
// Determine if this is the root of the menu/submenu layout.
|
|
8431
|
+
if (this.parentElement && this.parentElement.closest('auro-menu, [auro-menu]')) {
|
|
8432
|
+
this.rootMenu = false;
|
|
8433
|
+
}
|
|
8491
8434
|
|
|
8492
|
-
|
|
8435
|
+
// If this is the root menu (not a nested menu) handle events, states and styling.
|
|
8436
|
+
if (this.rootMenu) {
|
|
8437
|
+
this.initItems();
|
|
8438
|
+
this.setAttribute('role', 'listbox');
|
|
8439
|
+
this.setAttribute('root', '');
|
|
8440
|
+
this.handleNestedMenus(this);
|
|
8441
|
+
this.markOptions();
|
|
8442
|
+
this.index = -1;
|
|
8443
|
+
this.getSelectedIndex();
|
|
8493
8444
|
|
|
8494
|
-
|
|
8495
|
-
|
|
8445
|
+
this.addEventListener('keydown', this.handleKeyDown);
|
|
8446
|
+
this.addEventListener('mousedown', this.handleMenuMouseDown);
|
|
8447
|
+
this.addEventListener('auroMenuOption-mouseover', (evt) => {
|
|
8448
|
+
this.index = this.items.indexOf(evt.target);
|
|
8449
|
+
this.updateActiveOption(this.index);
|
|
8496
8450
|
});
|
|
8451
|
+
} else {
|
|
8452
|
+
// make sure to update all menuoption noCheckmark attributes when the menu is dynamically changed
|
|
8453
|
+
this.handleNoCheckmarkAttr();
|
|
8497
8454
|
}
|
|
8498
8455
|
}
|
|
8499
8456
|
|
|
8500
|
-
|
|
8501
|
-
|
|
8502
|
-
|
|
8503
|
-
|
|
8504
|
-
|
|
8457
|
+
render() {
|
|
8458
|
+
if (this.loading) {
|
|
8459
|
+
return x$2`
|
|
8460
|
+
<auro-menuoption disabled loadingplaceholder class="${this.hasLoadingPlaceholder ? '' : 'empty'}">
|
|
8461
|
+
<div>
|
|
8462
|
+
<slot name="loadingIcon"></slot>
|
|
8463
|
+
<slot name="loadingText"></slot>
|
|
8464
|
+
</div>
|
|
8465
|
+
</auro-menuoption>
|
|
8466
|
+
`;
|
|
8467
|
+
}
|
|
8468
|
+
return x$2`<slot @slotchange=${this.handleSlotItems}></slot>`;
|
|
8505
8469
|
}
|
|
8470
|
+
}
|
|
8506
8471
|
|
|
8507
|
-
|
|
8508
|
-
if (changedProperties.has('matchWord')) {
|
|
8509
|
-
this.markOptions();
|
|
8510
|
-
}
|
|
8472
|
+
var styleCss$1 = i$c`:host{display:flex;align-items:center;padding:var(--ds-size-50, 0.25rem) var(--ds-size-200, 1rem) var(--ds-size-50, 0.25rem) 0;cursor:pointer;user-select:none;-webkit-tap-highlight-color:transparent}:host slot{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host [auro-icon]{--ds-auro-icon-size: var(--ds-size-300, 1.5rem);margin-right:var(--ds-size-150, 0.75rem);margin-left:var(--ds-size-100, 0.5rem)}:host ::slotted(.nestingSpacer){display:inline-block;width:var(--ds-size-300, 1.5rem)}:host ::slotted(strong){font-weight:700}:host([hidden]){display:none}:host([static]){pointer-events:none}:host([disabled]:hover){cursor:auto}:host([disabled]){user-select:none;pointer-events:none}`;
|
|
8511
8473
|
|
|
8512
|
-
|
|
8513
|
-
this.selectByValue(this.value);
|
|
8514
|
-
}
|
|
8474
|
+
var colorCss$1 = i$c`:host{background-color:var(--ds-auro-menuoption-container-color);color:var(--ds-auro-menuoption-text-color)}:host svg{fill:var(--ds-auro-menuoption-icon-color) !important}:host([disabled]){--ds-auro-menuoption-text-color: var(--ds-color-text-ui-disabled-default, #adadad)}:host(:hover),:host(.active){--ds-auro-menuoption-container-color: var(--ds-color-container-ui-secondary-hover-default, rgba(0, 0, 0, 0.03))}:host([selected]){--ds-auro-menuoption-container-color: var(--ds-color-container-ui-primary-default-default, #2c67b5);--ds-auro-menuoption-text-color: var(--ds-color-text-primary-inverse, #ffffff);--ds-auro-menuoption-icon-color: var(--ds-color-icon-emphasis-inverse, #ffffff)}`;
|
|
8515
8475
|
|
|
8516
|
-
|
|
8517
|
-
|
|
8476
|
+
/**
|
|
8477
|
+
* @license
|
|
8478
|
+
* Copyright 2017 Google LLC
|
|
8479
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
8480
|
+
*/
|
|
8481
|
+
const t={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},e$1=t=>(...e)=>({_$litDirective$:t,values:e});class i{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i;}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}
|
|
8518
8482
|
|
|
8519
|
-
|
|
8520
|
-
|
|
8521
|
-
|
|
8522
|
-
|
|
8523
|
-
|
|
8483
|
+
/**
|
|
8484
|
+
* @license
|
|
8485
|
+
* Copyright 2018 Google LLC
|
|
8486
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
8487
|
+
*/const e=e$1(class extends i{constructor(t$1){if(super(t$1),t$1.type!==t.ATTRIBUTE||"class"!==t$1.name||t$1.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return " "+Object.keys(t).filter((s=>t[s])).join(" ")+" "}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)));}return T$2}});
|
|
8524
8488
|
|
|
8525
|
-
|
|
8526
|
-
|
|
8527
|
-
|
|
8528
|
-
|
|
8529
|
-
|
|
8530
|
-
optionInteractive(option) {
|
|
8531
|
-
return !option.hasAttribute('hidden') && !option.hasAttribute('disabled') && !option.hasAttribute('static');
|
|
8532
|
-
}
|
|
8489
|
+
/**
|
|
8490
|
+
* @license
|
|
8491
|
+
* Copyright 2018 Google LLC
|
|
8492
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
8493
|
+
*/const o=o=>o??E$2;
|
|
8533
8494
|
|
|
8534
|
-
|
|
8535
|
-
|
|
8536
|
-
* @returns {void} When called will update the DOM with visible suggest text matches.
|
|
8537
|
-
*/
|
|
8538
|
-
markOptions() {
|
|
8539
|
-
if (this.items && this.items.length > 0 && (this.matchWord && this.matchWord.length > 0)) {
|
|
8495
|
+
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
8496
|
+
// See LICENSE in the project root for license information.
|
|
8540
8497
|
|
|
8541
|
-
// Escape special regex characters
|
|
8542
|
-
const escapedWord = this.matchWord.replace(/[.*+?^${}()|[\]\\]/gu, '\\$&');
|
|
8543
8498
|
|
|
8544
|
-
|
|
8545
|
-
|
|
8499
|
+
/**
|
|
8500
|
+
* @attr {Boolean} hidden - If present, the component will be hidden both visually and from screen readers
|
|
8501
|
+
* @attr {Boolean} hiddenVisually - If present, the component will be hidden visually, but still read by screen readers
|
|
8502
|
+
* @attr {Boolean} hiddenAudible - If present, the component will be hidden from screen readers, but seen visually
|
|
8503
|
+
*/
|
|
8546
8504
|
|
|
8547
|
-
|
|
8548
|
-
if (this.optionInteractive(item) && !item.hasAttribute('persistent')) {
|
|
8549
|
-
const nested = item.querySelectorAll('.nestingSpacer');
|
|
8550
|
-
const nestingSpacerBundle = [...nested].map(() => this.nestingSpacer).join('');
|
|
8505
|
+
class AuroElement extends r$6 {
|
|
8551
8506
|
|
|
8552
|
-
|
|
8553
|
-
|
|
8554
|
-
|
|
8555
|
-
|
|
8507
|
+
// function to define props used within the scope of this component
|
|
8508
|
+
static get properties() {
|
|
8509
|
+
return {
|
|
8510
|
+
hidden: { type: Boolean,
|
|
8511
|
+
reflect: true },
|
|
8512
|
+
hiddenVisually: { type: Boolean,
|
|
8513
|
+
reflect: true },
|
|
8514
|
+
hiddenAudible: { type: Boolean,
|
|
8515
|
+
reflect: true },
|
|
8516
|
+
};
|
|
8556
8517
|
}
|
|
8557
8518
|
|
|
8558
8519
|
/**
|
|
8559
|
-
*
|
|
8520
|
+
* @private Function that determines state of aria-hidden
|
|
8560
8521
|
*/
|
|
8561
|
-
|
|
8562
|
-
|
|
8563
|
-
|
|
8564
|
-
this.items.forEach((item) => {
|
|
8565
|
-
item.classList.remove('active');
|
|
8566
|
-
item.removeAttribute('selected');
|
|
8567
|
-
});
|
|
8522
|
+
hideAudible(value) {
|
|
8523
|
+
if (value) {
|
|
8524
|
+
return 'true'
|
|
8568
8525
|
}
|
|
8526
|
+
|
|
8527
|
+
return 'false'
|
|
8569
8528
|
}
|
|
8529
|
+
}
|
|
8570
8530
|
|
|
8571
|
-
|
|
8572
|
-
* Set the attributes on the selected menuoption, the menu value and stored option.
|
|
8573
|
-
* @param {Object} option - The menuoption to be selected.
|
|
8574
|
-
* @private
|
|
8575
|
-
*/
|
|
8576
|
-
handleLocalSelectState(option) {
|
|
8577
|
-
option.setAttribute('selected', '');
|
|
8578
|
-
option.classList.add('active');
|
|
8579
|
-
option.ariaSelected = true;
|
|
8531
|
+
var error = {"role":"img","color":"currentColor","title":"","desc":"Error alert indicator.","width":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","height":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","xmlns":"http://www.w3.org/2000/svg","xmlns_xlink":"http://www.w3.org/1999/xlink","viewBox":"0 0 24 24","path":"/icons","style":"ico_squareLarge","type":"icon","name":"error","category":"alert","deprecated":true,"svg":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" aria-labelledby=\"error__desc\" class=\"ico_squareLarge\" data-deprecated=\"true\" role=\"img\" style=\"min-width:var(--auro-size-lg, var(--ds-size-300, 1.5rem));height:var(--auro-size-lg, var(--ds-size-300, 1.5rem));fill:currentColor\" viewBox=\"0 0 24 24\" part=\"svg\"><title/><desc id=\"error__desc\">Error alert indicator.</desc><path d=\"m13.047 5.599 6.786 11.586A1.207 1.207 0 0 1 18.786 19H5.214a1.207 1.207 0 0 1-1.047-1.815l6.786-11.586a1.214 1.214 0 0 1 2.094 0m-1.165.87a.23.23 0 0 0-.085.085L5.419 17.442a.232.232 0 0 0 .203.35h12.756a.234.234 0 0 0 .203-.35L12.203 6.554a.236.236 0 0 0-.321-.084M12 15.5a.75.75 0 1 1 0 1.5.75.75 0 0 1 0-1.5m-.024-6.22c.325 0 .589.261.589.583v4.434a.586.586 0 0 1-.589.583.586.586 0 0 1-.588-.583V9.863c0-.322.264-.583.588-.583\"/></svg>"};
|
|
8580
8532
|
|
|
8581
|
-
|
|
8582
|
-
this.optionSelected = option;
|
|
8583
|
-
this.index = this.items.indexOf(option);
|
|
8584
|
-
}
|
|
8533
|
+
/* eslint-disable no-underscore-dangle, jsdoc/no-undefined-types, jsdoc/require-param-description */
|
|
8585
8534
|
|
|
8586
|
-
|
|
8587
|
-
* Notify selection change.
|
|
8588
|
-
* @private
|
|
8589
|
-
* @return {void}
|
|
8590
|
-
*/
|
|
8591
|
-
notifySelectionChange() {
|
|
8592
|
-
// this event needs to be removed after select and combobox are updated to use the new standard name
|
|
8593
|
-
this.dispatchEvent(new CustomEvent('selectedOption', {
|
|
8594
|
-
bubbles: true,
|
|
8595
|
-
cancelable: false,
|
|
8596
|
-
composed: true,
|
|
8597
|
-
}));
|
|
8535
|
+
const _fetchMap = new Map();
|
|
8598
8536
|
|
|
8599
|
-
|
|
8600
|
-
|
|
8601
|
-
|
|
8602
|
-
|
|
8603
|
-
|
|
8537
|
+
/**
|
|
8538
|
+
* A callback to parse Response body.
|
|
8539
|
+
*
|
|
8540
|
+
* @callback ResponseParser
|
|
8541
|
+
* @param {Fetch.Response} response
|
|
8542
|
+
* @returns {Promise}
|
|
8543
|
+
*/
|
|
8544
|
+
|
|
8545
|
+
/**
|
|
8546
|
+
* A minimal in-memory map to de-duplicate Fetch API media requests.
|
|
8547
|
+
*
|
|
8548
|
+
* @param {String} uri
|
|
8549
|
+
* @param {Object} [options={}]
|
|
8550
|
+
* @param {ResponseParser} [options.responseParser=(response) => response.text()]
|
|
8551
|
+
* @returns {Promise}
|
|
8552
|
+
*/
|
|
8553
|
+
const cacheFetch = (uri, options = {}) => {
|
|
8554
|
+
const responseParser = options.responseParser || ((response) => response.text());
|
|
8555
|
+
if (!_fetchMap.has(uri)) {
|
|
8556
|
+
_fetchMap.set(uri, fetch(uri).then(responseParser));
|
|
8604
8557
|
}
|
|
8558
|
+
return _fetchMap.get(uri);
|
|
8559
|
+
};
|
|
8605
8560
|
|
|
8606
|
-
|
|
8607
|
-
* Process actions for making making a menuoption selection.
|
|
8608
|
-
*/
|
|
8609
|
-
makeSelection() {
|
|
8610
|
-
if (!this.items) {
|
|
8611
|
-
this.initItems();
|
|
8612
|
-
}
|
|
8561
|
+
var styleCss = i$c`*,*:before,*:after{box-sizing:border-box}@media(prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms !important;animation-iteration-count:1 !important;transition-duration:.01ms !important}}*:focus-visible{outline:0}*:focus-visible{outline:0}:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock,:host{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host([hidden]:not(:focus):not(:active)){display:none}.util_displayHiddenVisually,:host([hiddenVisually]:not(:focus):not(:active)){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.ico_squareLarge{fill:currentColor;height:var(--auro-size-lg, var(--ds-size-300, 1.5rem))}.ico_squareSmall{fill:currentColor;height:.6rem}.ico_squareMed{fill:currentColor;height:var(--auro-size-md, var(--ds-size-200, 1rem))}.ico_squareSml{fill:currentColor;height:var(--auro-size-sm, var(--ds-size-150, 0.75rem))}:host{color:currentColor;vertical-align:middle;line-height:1;display:inline-block}:host .logo{color:var(--ds-color-brand-midnight-400, #01426a)}svg{min-width:var(--ds-auro-icon-size, 1.5rem) !important;width:var(--ds-auro-icon-size, 1.5rem) !important;height:var(--ds-auro-icon-size, 1.5rem) !important}.label{display:flex;align-items:flex-start}.label svg{margin:0 var(--ds-size-50, 0.25rem)}.labelContainer{line-height:1.8}`;
|
|
8613
8562
|
|
|
8614
|
-
|
|
8615
|
-
|
|
8563
|
+
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
8564
|
+
// See LICENSE in the project root for license information.
|
|
8616
8565
|
|
|
8617
|
-
if (this.index >= 0) {
|
|
8618
|
-
const option = this.items[this.index];
|
|
8619
8566
|
|
|
8620
|
-
|
|
8621
|
-
|
|
8622
|
-
|
|
8623
|
-
|
|
8624
|
-
|
|
8625
|
-
bubbles: true,
|
|
8626
|
-
cancelable: false,
|
|
8627
|
-
composed: true,
|
|
8628
|
-
}));
|
|
8567
|
+
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
8568
|
+
/**
|
|
8569
|
+
* @attr {Boolean} onDark - Set value for on-dark version of auro-icon
|
|
8570
|
+
* @slot - Hidden from visibility, used for a11y if icon description is needed
|
|
8571
|
+
*/
|
|
8629
8572
|
|
|
8630
|
-
|
|
8631
|
-
|
|
8632
|
-
|
|
8633
|
-
|
|
8634
|
-
|
|
8635
|
-
|
|
8573
|
+
// build the component class
|
|
8574
|
+
class BaseIcon extends AuroElement {
|
|
8575
|
+
constructor() {
|
|
8576
|
+
super();
|
|
8577
|
+
this.onDark = false;
|
|
8578
|
+
}
|
|
8636
8579
|
|
|
8637
|
-
|
|
8638
|
-
|
|
8639
|
-
|
|
8640
|
-
|
|
8641
|
-
|
|
8642
|
-
|
|
8643
|
-
|
|
8644
|
-
|
|
8645
|
-
|
|
8580
|
+
// function to define props used within the scope of this component
|
|
8581
|
+
static get properties() {
|
|
8582
|
+
return {
|
|
8583
|
+
...super.properties,
|
|
8584
|
+
onDark: {
|
|
8585
|
+
type: Boolean,
|
|
8586
|
+
reflect: true
|
|
8587
|
+
},
|
|
8588
|
+
|
|
8589
|
+
/**
|
|
8590
|
+
* @private
|
|
8591
|
+
*/
|
|
8592
|
+
svg: {
|
|
8593
|
+
attribute: false,
|
|
8594
|
+
reflect: true
|
|
8646
8595
|
}
|
|
8647
|
-
}
|
|
8596
|
+
};
|
|
8597
|
+
}
|
|
8648
8598
|
|
|
8649
|
-
|
|
8599
|
+
static get styles() {
|
|
8600
|
+
return i$c`
|
|
8601
|
+
${styleCss}
|
|
8602
|
+
`;
|
|
8650
8603
|
}
|
|
8651
8604
|
|
|
8652
8605
|
/**
|
|
8653
|
-
*
|
|
8606
|
+
* Async function to fetch requested icon from npm CDN.
|
|
8654
8607
|
* @private
|
|
8655
|
-
* @param {
|
|
8608
|
+
* @param {string} category - Icon category.
|
|
8609
|
+
* @param {string} name - Icon name.
|
|
8610
|
+
* @returns {SVGElement} DOM - Ready HTML to be appended.
|
|
8656
8611
|
*/
|
|
8657
|
-
|
|
8658
|
-
|
|
8612
|
+
async fetchIcon(category, name) {
|
|
8613
|
+
let iconHTML = '';
|
|
8659
8614
|
|
|
8660
|
-
|
|
8661
|
-
|
|
8662
|
-
|
|
8663
|
-
|
|
8664
|
-
|
|
8665
|
-
break;
|
|
8615
|
+
if (category === 'logos') {
|
|
8616
|
+
iconHTML = await cacheFetch(`${this.uri}/${category}/${name}.svg`);
|
|
8617
|
+
} else {
|
|
8618
|
+
iconHTML = await cacheFetch(`${this.uri}/icons/${category}/${name}.svg`);
|
|
8619
|
+
}
|
|
8666
8620
|
|
|
8667
|
-
|
|
8668
|
-
this.selectNextItem('up');
|
|
8669
|
-
break;
|
|
8621
|
+
const dom = new DOMParser().parseFromString(iconHTML, 'text/html');
|
|
8670
8622
|
|
|
8671
|
-
|
|
8672
|
-
|
|
8673
|
-
|
|
8623
|
+
return dom.body.querySelector('svg');
|
|
8624
|
+
}
|
|
8625
|
+
|
|
8626
|
+
// lifecycle function
|
|
8627
|
+
async firstUpdated() {
|
|
8628
|
+
if (!this.customSvg) {
|
|
8629
|
+
const svg = await this.fetchIcon(this.category, this.name);
|
|
8630
|
+
|
|
8631
|
+
if (svg) {
|
|
8632
|
+
this.svg = svg;
|
|
8633
|
+
} else if (!svg) {
|
|
8634
|
+
const penDOM = new DOMParser().parseFromString(error.svg, 'text/html');
|
|
8635
|
+
|
|
8636
|
+
this.svg = penDOM.body.firstChild;
|
|
8637
|
+
}
|
|
8674
8638
|
}
|
|
8675
8639
|
}
|
|
8640
|
+
}
|
|
8676
8641
|
|
|
8677
|
-
|
|
8678
|
-
|
|
8679
|
-
|
|
8680
|
-
|
|
8681
|
-
|
|
8682
|
-
|
|
8683
|
-
|
|
8642
|
+
var tokensCss = i$c`:host{--ds-auro-icon-color: var(--ds-color-icon-primary-default, $ds-color-icon-primary-default);--ds-auro-icon-size: var(--ds-size-300, $ds-size-300)}`;
|
|
8643
|
+
|
|
8644
|
+
var colorCss = i$c`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[accent]){--ds-auro-icon-color: var(--ds-color-icon-accent-default, #a2c270)}:host(:not([onDark])[disabled]){--ds-auro-icon-color: var(--ds-color-icon-ui-primary-disabled-default, #adadad)}:host(:not([onDark])[emphasis]){--ds-auro-icon-color: var(--ds-color-icon-emphasis-default, #2a2a2a)}:host(:not([onDark])[error]){--ds-auro-icon-color: var(--ds-color-icon-error-default, #cc1816)}:host(:not([onDark])[info]){--ds-auro-icon-color: var(--ds-color-icon-info-default, #326aa5)}:host(:not([onDark])[secondary]){--ds-auro-icon-color: var(--ds-color-icon-secondary-default, #7e8894)}:host(:not([onDark])[subtle]){--ds-auro-icon-color: var(--ds-color-icon-subtle-default, #a0c9f1)}:host(:not([onDark])[success]){--ds-auro-icon-color: var(--ds-color-icon-success-default, #40a080)}:host(:not([onDark])[tertiary]){--ds-auro-icon-color: var(--ds-color-icon-tertiary-default, #afb9c6)}:host(:not([onDark])[warning]){--ds-auro-icon-color: var(--ds-color-icon-warning-default, #c49432)}:host([onDark]){--ds-auro-icon-color: var(--ds-color-icon-primary-inverse, #f7f7f7)}:host([onDark][accent]){--ds-auro-icon-color: var(--ds-color-icon-accent-inverse, #badd81)}:host([onDark][disabled]){--ds-auro-icon-color: var(--ds-color-icon-ui-primary-disabled-inverse, #7e7e7e)}:host([onDark][emphasis]){--ds-auro-icon-color: var(--ds-color-icon-emphasis-inverse, #ffffff)}:host([onDark][error]){--ds-auro-icon-color: var(--ds-color-icon-error-inverse, #f9aca6)}:host([onDark][info]){--ds-auro-icon-color: var(--ds-color-icon-info-inverse, #89b2d4)}:host([onDark][secondary]){--ds-auro-icon-color: var(--ds-color-icon-secondary-inverse, #ccd2db)}:host([onDark][subtle]){--ds-auro-icon-color: var(--ds-color-icon-subtle-inverse, #326aa5)}:host([onDark][success]){--ds-auro-icon-color: var(--ds-color-icon-success-inverse, #8eceb9)}:host([onDark][tertiary]){--ds-auro-icon-color: var(--ds-color-icon-tertiary-inverse, #939fad)}:host([onDark][warning]){--ds-auro-icon-color: var(--ds-color-icon-warning-inverse, #f2c153)}`;
|
|
8645
|
+
|
|
8646
|
+
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
8647
|
+
// See LICENSE in the project root for license information.
|
|
8648
|
+
|
|
8649
|
+
|
|
8650
|
+
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
8651
|
+
/**
|
|
8652
|
+
* auro-icon provides users a way to use the Auro Icons by simply passing in the category and name.
|
|
8653
|
+
*
|
|
8654
|
+
* @attr {String} category - The category of the icon you are looking for. See https://auro.alaskaair.com/icons/usage.
|
|
8655
|
+
* @attr {String} name - The name of the icon you are looking for without the file extension. See https://auro.alaskaair.com/icons/usage
|
|
8656
|
+
* @attr {Boolean} customColor - Removes primary selector.
|
|
8657
|
+
* @attr {Boolean} customSvg - When true, auro-icon will render a custom SVG inside the default slot.
|
|
8658
|
+
* @attr {Boolean} label - Exposes content in slot as icon label.
|
|
8659
|
+
* @attr {Boolean} primary - DEPRECATED: Sets the icon to use the baseline primary icon style.
|
|
8660
|
+
* @attr {Boolean} accent - Sets the icon to use the accent style.
|
|
8661
|
+
* @attr {Boolean} emphasis - Sets the icon to use the emphasis style.
|
|
8662
|
+
* @attr {Boolean} disabled - Sets the icon to use the disabled style.
|
|
8663
|
+
* @attr {Boolean} error - Sets the icon to use the error style.
|
|
8664
|
+
* @attr {Boolean} info - Sets the icon to use the info style.
|
|
8665
|
+
* @attr {Boolean} secondary - Sets the icon to use the secondary style.
|
|
8666
|
+
* @attr {Boolean} tertiary - Sets the icon to use the tertiary style.
|
|
8667
|
+
* @attr {Boolean} subtle - Sets the icon to use the subtle style.
|
|
8668
|
+
* @attr {Boolean} success - Sets the icon to use the success style.
|
|
8669
|
+
* @attr {Boolean} warning - Sets the icon to use the warning style.
|
|
8670
|
+
* @attr {String} ariaHidden - Set aria-hidden value. Default is `true`. Option is `false`.
|
|
8671
|
+
* @attr {String} uri - Set the uri for CDN used when fetching icons
|
|
8672
|
+
* @slot - Hidden from visibility, used for a11y if icon description is needed.
|
|
8673
|
+
* @slot svg - Used for custom SVG content.
|
|
8674
|
+
*/
|
|
8675
|
+
|
|
8676
|
+
// build the component class
|
|
8677
|
+
class AuroIcon extends BaseIcon {
|
|
8678
|
+
constructor() {
|
|
8679
|
+
super();
|
|
8680
|
+
|
|
8681
|
+
this.uri = 'https://cdn.jsdelivr.net/npm/@alaskaairux/icons@latest/dist';
|
|
8682
|
+
|
|
8683
|
+
this.privateDefaults();
|
|
8684
8684
|
}
|
|
8685
8685
|
|
|
8686
8686
|
/**
|
|
8687
|
-
*
|
|
8687
|
+
* Internal Defaults.
|
|
8688
8688
|
* @private
|
|
8689
|
+
* @returns {void}
|
|
8689
8690
|
*/
|
|
8690
|
-
|
|
8691
|
-
|
|
8692
|
-
|
|
8691
|
+
privateDefaults() {
|
|
8692
|
+
this.accent = false;
|
|
8693
|
+
this.customColor = false;
|
|
8694
|
+
this.customSvg = false;
|
|
8695
|
+
this.disabled = false;
|
|
8696
|
+
this.emphasis = false;
|
|
8697
|
+
this.error = false;
|
|
8698
|
+
this.info = false;
|
|
8699
|
+
this.label = false;
|
|
8700
|
+
this.primary = false;
|
|
8701
|
+
this.secondary = false;
|
|
8702
|
+
this.subtle = false;
|
|
8703
|
+
this.success = false;
|
|
8704
|
+
this.tertiary = false;
|
|
8705
|
+
this.warning = false;
|
|
8706
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$2();
|
|
8707
|
+
}
|
|
8693
8708
|
|
|
8694
|
-
|
|
8695
|
-
|
|
8696
|
-
|
|
8697
|
-
|
|
8709
|
+
// function to define props used within the scope of this component
|
|
8710
|
+
static get properties() {
|
|
8711
|
+
return {
|
|
8712
|
+
...super.properties,
|
|
8713
|
+
accent: {
|
|
8714
|
+
type: Boolean,
|
|
8715
|
+
reflect: true
|
|
8716
|
+
},
|
|
8717
|
+
ariaHidden: {
|
|
8718
|
+
type: String,
|
|
8719
|
+
reflect: true
|
|
8720
|
+
},
|
|
8721
|
+
category: {
|
|
8722
|
+
type: String,
|
|
8723
|
+
reflect: true
|
|
8724
|
+
},
|
|
8725
|
+
customColor: {
|
|
8726
|
+
type: Boolean
|
|
8727
|
+
},
|
|
8728
|
+
customSvg: {
|
|
8729
|
+
type: Boolean
|
|
8730
|
+
},
|
|
8731
|
+
disabled: {
|
|
8732
|
+
type: Boolean,
|
|
8733
|
+
reflect: true
|
|
8734
|
+
},
|
|
8735
|
+
emphasis: {
|
|
8736
|
+
type: Boolean,
|
|
8737
|
+
reflect: true
|
|
8738
|
+
},
|
|
8739
|
+
error: {
|
|
8740
|
+
type: Boolean,
|
|
8741
|
+
reflect: true
|
|
8742
|
+
},
|
|
8743
|
+
info: {
|
|
8744
|
+
type: Boolean,
|
|
8745
|
+
reflect: true
|
|
8746
|
+
},
|
|
8747
|
+
label: {
|
|
8748
|
+
type: Boolean,
|
|
8749
|
+
reflect: true
|
|
8750
|
+
},
|
|
8751
|
+
name: {
|
|
8752
|
+
type: String,
|
|
8753
|
+
reflect: true
|
|
8754
|
+
},
|
|
8755
|
+
primary: {
|
|
8756
|
+
type: Boolean,
|
|
8757
|
+
reflect: true
|
|
8758
|
+
},
|
|
8759
|
+
secondary: {
|
|
8760
|
+
type: Boolean,
|
|
8761
|
+
reflect: true
|
|
8762
|
+
},
|
|
8763
|
+
subtle: {
|
|
8764
|
+
type: Boolean,
|
|
8765
|
+
reflect: true
|
|
8766
|
+
},
|
|
8767
|
+
success: {
|
|
8768
|
+
type: Boolean,
|
|
8769
|
+
reflect: true
|
|
8770
|
+
},
|
|
8771
|
+
tertiary: {
|
|
8772
|
+
type: Boolean,
|
|
8773
|
+
reflect: true
|
|
8774
|
+
},
|
|
8775
|
+
uri: {
|
|
8776
|
+
type: String
|
|
8777
|
+
},
|
|
8778
|
+
warning: {
|
|
8779
|
+
type: Boolean,
|
|
8780
|
+
reflect: true
|
|
8781
|
+
}
|
|
8782
|
+
};
|
|
8783
|
+
}
|
|
8784
|
+
|
|
8785
|
+
static get styles() {
|
|
8786
|
+
return [
|
|
8787
|
+
super.styles,
|
|
8788
|
+
i$c`${tokensCss}`,
|
|
8789
|
+
i$c`${styleCss}`,
|
|
8790
|
+
i$c`${colorCss}`
|
|
8791
|
+
];
|
|
8698
8792
|
}
|
|
8699
8793
|
|
|
8700
8794
|
/**
|
|
8701
|
-
*
|
|
8702
|
-
*
|
|
8703
|
-
*
|
|
8795
|
+
* This will register this element with the browser.
|
|
8796
|
+
* @param {string} [name="auro-icon"] - The name of element that you want to register to.
|
|
8797
|
+
*
|
|
8798
|
+
* @example
|
|
8799
|
+
* AuroIcon.register("custom-icon") // this will register this element to <custom-icon/>
|
|
8704
8800
|
*
|
|
8705
|
-
* The event.target is not used as the function needs to know where to go,
|
|
8706
|
-
* versus knowing where it is.
|
|
8707
|
-
* @param {String} moveDirection - Up or Down based on keyboard event.
|
|
8708
8801
|
*/
|
|
8709
|
-
|
|
8710
|
-
|
|
8711
|
-
|
|
8712
|
-
|
|
8713
|
-
// calculate which is the selection we should focus next
|
|
8714
|
-
let increment = 0;
|
|
8715
|
-
|
|
8716
|
-
if (moveDirection === 'down') {
|
|
8717
|
-
increment = 1;
|
|
8718
|
-
} else if (moveDirection === 'up') {
|
|
8719
|
-
increment = -1;
|
|
8720
|
-
}
|
|
8721
|
-
|
|
8722
|
-
this.index += increment;
|
|
8723
|
-
|
|
8724
|
-
// keep looping inside the array of options
|
|
8725
|
-
if (this.index > this.items.length - 1) {
|
|
8726
|
-
this.index = 0;
|
|
8727
|
-
} else if (this.index < 0) {
|
|
8728
|
-
this.index = this.items.length - 1;
|
|
8729
|
-
}
|
|
8802
|
+
static register(name = "auro-icon") {
|
|
8803
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroIcon);
|
|
8804
|
+
}
|
|
8730
8805
|
|
|
8731
|
-
|
|
8732
|
-
|
|
8733
|
-
this.selectNextItem(moveDirection);
|
|
8734
|
-
} else {
|
|
8735
|
-
// apply focus to new index
|
|
8736
|
-
this.updateActiveOption(this.index);
|
|
8737
|
-
}
|
|
8738
|
-
} else {
|
|
8739
|
-
this.index = 0;
|
|
8806
|
+
connectedCallback() {
|
|
8807
|
+
super.connectedCallback();
|
|
8740
8808
|
|
|
8741
|
-
|
|
8742
|
-
|
|
8743
|
-
} else {
|
|
8744
|
-
this.updateActiveOption(this.index);
|
|
8745
|
-
}
|
|
8746
|
-
}
|
|
8809
|
+
// Add the tag name as an attribute if it is different than the component name
|
|
8810
|
+
this.runtimeUtils.handleComponentTagRename(this, 'auro-icon');
|
|
8747
8811
|
}
|
|
8748
8812
|
|
|
8749
8813
|
/**
|
|
8750
|
-
*
|
|
8751
|
-
* @private
|
|
8752
|
-
* @param {String} menu - Root level menu object.
|
|
8814
|
+
* @returns {void} Exposes CSS parts for styling from parent components.
|
|
8753
8815
|
*/
|
|
8754
|
-
|
|
8755
|
-
|
|
8816
|
+
exposeCssParts() {
|
|
8817
|
+
this.setAttribute('exportparts', 'svg:iconSvg');
|
|
8818
|
+
}
|
|
8756
8819
|
|
|
8757
|
-
|
|
8758
|
-
|
|
8759
|
-
|
|
8820
|
+
// function that renders the HTML and CSS into the scope of the component
|
|
8821
|
+
render() {
|
|
8822
|
+
const a11y = {
|
|
8823
|
+
'labelContainer': true,
|
|
8824
|
+
'util_displayHiddenVisually': !this.label
|
|
8825
|
+
};
|
|
8760
8826
|
|
|
8761
|
-
|
|
8762
|
-
|
|
8827
|
+
const classes = {
|
|
8828
|
+
'label': this.label
|
|
8829
|
+
};
|
|
8763
8830
|
|
|
8764
|
-
|
|
8765
|
-
|
|
8766
|
-
|
|
8831
|
+
return x$2`
|
|
8832
|
+
<div
|
|
8833
|
+
class="${e(classes)}"
|
|
8834
|
+
title="${o(this.title || undefined)}">
|
|
8835
|
+
<span aria-hidden="${o(this.ariaHidden ? this.ariaHidden : true)}" part="svg">
|
|
8836
|
+
${this.customSvg ? x$2`
|
|
8837
|
+
<slot name="svg"></slot>
|
|
8838
|
+
` : x$2`
|
|
8839
|
+
${this.svg}
|
|
8840
|
+
`
|
|
8841
|
+
}
|
|
8842
|
+
</span>
|
|
8767
8843
|
|
|
8768
|
-
|
|
8769
|
-
|
|
8844
|
+
<div class="${e(a11y)}">
|
|
8845
|
+
<slot></slot>
|
|
8846
|
+
</div>
|
|
8847
|
+
</div>
|
|
8848
|
+
`;
|
|
8770
8849
|
}
|
|
8850
|
+
}
|
|
8771
8851
|
|
|
8772
|
-
|
|
8773
|
-
* Method to apply `selected` attribute to `menuoption` via `value`.
|
|
8774
|
-
* @private
|
|
8775
|
-
* @param {String} value - Must match a unique `menuoption` value.
|
|
8776
|
-
*/
|
|
8777
|
-
selectByValue(value) {
|
|
8778
|
-
let valueMatch = false;
|
|
8779
|
-
if (!this.items) {
|
|
8780
|
-
this.initItems();
|
|
8781
|
-
}
|
|
8852
|
+
var iconVersion = '6.1.1';
|
|
8782
8853
|
|
|
8783
|
-
|
|
8854
|
+
var checkmarkIcon = {"role":"img","color":"currentColor","title":"","desc":"a small check mark.","width":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","height":"var(--auro-size-lg, var(--ds-size-300, 1.5rem))","xmlns":"http://www.w3.org/2000/svg","xmlns_xlink":"http://www.w3.org/1999/xlink","viewBox":"0 0 24 24","path":"/icons","style":"ico_squareLarge","type":"icon","name":"checkmark-sm","category":"interface","svg":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" aria-labelledby=\"checkmark-sm__desc\" class=\"ico_squareLarge\" role=\"img\" style=\"min-width:var(--auro-size-lg, var(--ds-size-300, 1.5rem));height:var(--auro-size-lg, var(--ds-size-300, 1.5rem));fill:currentColor\" viewBox=\"0 0 24 24\" part=\"svg\"><title/><desc id=\"checkmark-sm__desc\">a small check mark.</desc><path d=\"M8.461 11.84a.625.625 0 1 0-.922.844l2.504 2.738c.247.27.674.27.922 0l5.496-6a.625.625 0 1 0-.922-.844l-5.035 5.496z\"/></svg>"};
|
|
8784
8855
|
|
|
8785
|
-
|
|
8786
|
-
|
|
8787
|
-
if (this.items[index].value === value) {
|
|
8788
|
-
valueMatch = true;
|
|
8789
|
-
this.index = index;
|
|
8790
|
-
}
|
|
8791
|
-
}
|
|
8856
|
+
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
8857
|
+
// See LICENSE in the project root for license information.
|
|
8792
8858
|
|
|
8793
|
-
if (!valueMatch) {
|
|
8794
|
-
// reset the menu to no selection
|
|
8795
|
-
this.index = undefined;
|
|
8796
8859
|
|
|
8797
|
-
|
|
8798
|
-
|
|
8799
|
-
|
|
8800
|
-
|
|
8801
|
-
|
|
8802
|
-
|
|
8860
|
+
/**
|
|
8861
|
+
* The auro-menu element provides users a way to define a menu option.
|
|
8862
|
+
*
|
|
8863
|
+
* @attr {String} value - Specifies the value to be sent to a server.
|
|
8864
|
+
* @attr {String} noCheckmark - When true, selected option will not show the checkmark.
|
|
8865
|
+
* @attr {Boolean} disabled - When true specifies that the menuoption is disabled.
|
|
8866
|
+
* @attr {Boolean} selected - Specifies that an option is selected.
|
|
8867
|
+
* @event auroMenuOption-mouseover - Notifies that this option has been hovered over.
|
|
8868
|
+
* @slot - Specifies text for an option, but is not the value.
|
|
8869
|
+
*/
|
|
8870
|
+
class AuroMenuOption extends r$6 {
|
|
8871
|
+
constructor() {
|
|
8872
|
+
super();
|
|
8803
8873
|
|
|
8804
|
-
|
|
8805
|
-
|
|
8806
|
-
|
|
8807
|
-
|
|
8808
|
-
|
|
8809
|
-
|
|
8810
|
-
|
|
8874
|
+
/**
|
|
8875
|
+
* Generate unique names for dependency components.
|
|
8876
|
+
*/
|
|
8877
|
+
const versioning = new AuroDependencyVersioning$2();
|
|
8878
|
+
this.iconTag = versioning.generateTag('auro-icon', iconVersion, AuroIcon);
|
|
8879
|
+
|
|
8880
|
+
this.selected = false;
|
|
8881
|
+
this.nocheckmark = false;
|
|
8882
|
+
this.disabled = false;
|
|
8883
|
+
|
|
8884
|
+
/**
|
|
8885
|
+
* @private
|
|
8886
|
+
*/
|
|
8887
|
+
this.tabIndex = -1;
|
|
8888
|
+
|
|
8889
|
+
/**
|
|
8890
|
+
* @private
|
|
8891
|
+
*/
|
|
8892
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$2();
|
|
8893
|
+
}
|
|
8894
|
+
|
|
8895
|
+
static get properties() {
|
|
8896
|
+
return {
|
|
8897
|
+
nocheckmark: {
|
|
8898
|
+
type: Boolean,
|
|
8899
|
+
reflect: true
|
|
8900
|
+
},
|
|
8901
|
+
selected: {
|
|
8902
|
+
type: Boolean,
|
|
8903
|
+
reflect: true
|
|
8904
|
+
},
|
|
8905
|
+
disabled: {
|
|
8906
|
+
type: Boolean,
|
|
8907
|
+
reflect: true
|
|
8908
|
+
},
|
|
8909
|
+
value: {
|
|
8910
|
+
type: String,
|
|
8911
|
+
reflect: true
|
|
8912
|
+
},
|
|
8913
|
+
tabIndex: {
|
|
8914
|
+
type: Number,
|
|
8915
|
+
reflect: true
|
|
8811
8916
|
}
|
|
8812
|
-
}
|
|
8813
|
-
|
|
8917
|
+
};
|
|
8918
|
+
}
|
|
8814
8919
|
|
|
8815
|
-
|
|
8816
|
-
|
|
8817
|
-
|
|
8818
|
-
|
|
8819
|
-
|
|
8820
|
-
|
|
8920
|
+
static get styles() {
|
|
8921
|
+
return [
|
|
8922
|
+
styleCss$1,
|
|
8923
|
+
colorCss$1,
|
|
8924
|
+
tokensCss$1
|
|
8925
|
+
];
|
|
8821
8926
|
}
|
|
8822
8927
|
|
|
8823
8928
|
/**
|
|
8824
|
-
*
|
|
8825
|
-
* @param {
|
|
8826
|
-
*
|
|
8929
|
+
* This will register this element with the browser.
|
|
8930
|
+
* @param {string} [name="auro-menuoption"] - The name of element that you want to register to.
|
|
8931
|
+
*
|
|
8932
|
+
* @example
|
|
8933
|
+
* AuroMenuOption.register("custom-menuoption") // this will register this element to <custom-menuoption/>
|
|
8934
|
+
*
|
|
8827
8935
|
*/
|
|
8828
|
-
|
|
8829
|
-
|
|
8830
|
-
|
|
8831
|
-
});
|
|
8832
|
-
this.items[index].classList.add('active');
|
|
8833
|
-
this.optionActive = this.items[index];
|
|
8936
|
+
static register(name = "auro-menuoption") {
|
|
8937
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroMenuOption);
|
|
8938
|
+
}
|
|
8834
8939
|
|
|
8835
|
-
|
|
8836
|
-
|
|
8837
|
-
|
|
8838
|
-
composed: true,
|
|
8839
|
-
detail: this.items[index]
|
|
8840
|
-
}));
|
|
8940
|
+
firstUpdated() {
|
|
8941
|
+
// Add the tag name as an attribute if it is different than the component name
|
|
8942
|
+
this.runtimeUtils.handleComponentTagRename(this, 'auro-menuoption');
|
|
8841
8943
|
|
|
8842
|
-
this.
|
|
8843
|
-
|
|
8844
|
-
|
|
8845
|
-
|
|
8846
|
-
|
|
8847
|
-
|
|
8944
|
+
this.setAttribute('role', 'option');
|
|
8945
|
+
this.setAttribute('aria-selected', 'false');
|
|
8946
|
+
|
|
8947
|
+
this.addEventListener('mouseover', () => {
|
|
8948
|
+
this.dispatchEvent(new CustomEvent('auroMenuOption-mouseover', {
|
|
8949
|
+
bubbles: true,
|
|
8950
|
+
cancelable: false,
|
|
8951
|
+
composed: true,
|
|
8952
|
+
detail: this
|
|
8953
|
+
}));
|
|
8954
|
+
});
|
|
8848
8955
|
}
|
|
8849
8956
|
|
|
8850
|
-
|
|
8851
|
-
|
|
8852
|
-
|
|
8853
|
-
|
|
8854
|
-
*/
|
|
8855
|
-
handleMenuMouseDown(evt) {
|
|
8856
|
-
if (evt.target !== this) {
|
|
8857
|
-
this.makeSelection();
|
|
8957
|
+
// observer for selected property changes
|
|
8958
|
+
updated(changedProperties) {
|
|
8959
|
+
if (changedProperties.has('selected')) {
|
|
8960
|
+
this.setAttribute('aria-selected', this.selected.toString());
|
|
8858
8961
|
}
|
|
8859
8962
|
}
|
|
8860
8963
|
|
|
8861
8964
|
/**
|
|
8862
|
-
*
|
|
8965
|
+
* Generates an HTML element containing an SVG icon based on the provided `svgContent`.
|
|
8966
|
+
*
|
|
8863
8967
|
* @private
|
|
8968
|
+
* @param {string} svgContent - The SVG content to be embedded.
|
|
8969
|
+
* @returns {Element} The HTML element containing the SVG icon.
|
|
8864
8970
|
*/
|
|
8865
|
-
|
|
8866
|
-
|
|
8867
|
-
|
|
8868
|
-
this.rootMenu = false;
|
|
8869
|
-
}
|
|
8971
|
+
generateIconHtml(svgContent) {
|
|
8972
|
+
const dom = new DOMParser().parseFromString(svgContent, 'text/html');
|
|
8973
|
+
const svg = dom.body.firstChild;
|
|
8870
8974
|
|
|
8871
|
-
|
|
8872
|
-
if (this.rootMenu) {
|
|
8873
|
-
this.initItems();
|
|
8874
|
-
this.setAttribute('role', 'listbox');
|
|
8875
|
-
this.setAttribute('root', '');
|
|
8876
|
-
this.handleNestedMenus(this);
|
|
8877
|
-
this.markOptions();
|
|
8878
|
-
this.index = -1;
|
|
8879
|
-
this.getSelectedIndex();
|
|
8975
|
+
svg.setAttribute('slot', 'svg');
|
|
8880
8976
|
|
|
8881
|
-
|
|
8882
|
-
this.addEventListener('mousedown', this.handleMenuMouseDown);
|
|
8883
|
-
this.addEventListener('auroMenuOption-mouseover', (evt) => {
|
|
8884
|
-
this.index = this.items.indexOf(evt.target);
|
|
8885
|
-
this.updateActiveOption(this.index);
|
|
8886
|
-
});
|
|
8887
|
-
} else {
|
|
8888
|
-
// make sure to update all menuoption noCheckmark attributes when the menu is dynamically changed
|
|
8889
|
-
this.handleNoCheckmarkAttr();
|
|
8890
|
-
}
|
|
8977
|
+
return u$6`<${this.iconTag} customColor customSvg slot="icon">${svg}</${this.iconTag}>`;
|
|
8891
8978
|
}
|
|
8892
8979
|
|
|
8893
8980
|
render() {
|
|
8894
|
-
return
|
|
8895
|
-
|
|
8981
|
+
return u$6`
|
|
8982
|
+
${this.selected && !this.nocheckmark ? this.generateIconHtml(checkmarkIcon.svg) : undefined}
|
|
8983
|
+
<slot></slot>
|
|
8896
8984
|
`;
|
|
8897
8985
|
}
|
|
8898
8986
|
}
|