@aurodesignsystem-dev/auro-formkit 0.0.0-pr624.10 → 0.0.0-pr624.100
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/bibtemplate/dist/auro-bibtemplate.d.ts +12 -2
- package/components/bibtemplate/dist/buttonVersion.d.ts +2 -0
- package/components/bibtemplate/dist/headerVersion.d.ts +1 -1
- package/components/bibtemplate/dist/iconVersion.d.ts +1 -1
- package/components/bibtemplate/dist/index.js +1242 -94
- package/components/bibtemplate/dist/registered.js +1242 -94
- package/components/checkbox/README.md +1 -1
- package/components/checkbox/demo/api.html +16 -10
- package/components/checkbox/demo/api.md +54 -19
- package/components/checkbox/demo/api.min.js +71 -46
- package/components/checkbox/demo/index.html +16 -10
- package/components/checkbox/demo/index.md +2 -2
- package/components/checkbox/demo/index.min.js +71 -46
- package/components/checkbox/demo/readme.html +16 -9
- package/components/checkbox/demo/readme.md +1 -1
- package/components/checkbox/dist/auro-checkbox-group.d.ts +1 -1
- package/components/checkbox/dist/auro-checkbox.d.ts +6 -3
- package/components/checkbox/dist/index.js +70 -45
- package/components/checkbox/dist/registered.js +70 -45
- package/components/combobox/README.md +2 -0
- package/components/combobox/demo/api.html +16 -10
- package/components/combobox/demo/api.md +121 -8
- package/components/combobox/demo/api.min.js +3314 -1013
- package/components/combobox/demo/index.html +16 -10
- package/components/combobox/demo/index.md +20 -34
- package/components/combobox/demo/index.min.js +3314 -1013
- package/components/combobox/demo/readme.html +16 -9
- package/components/combobox/demo/readme.md +2 -0
- package/components/combobox/dist/auro-combobox.d.ts +59 -14
- package/components/combobox/dist/index.js +3008 -850
- package/components/combobox/dist/registered.js +3008 -850
- package/components/counter/demo/api.html +17 -10
- package/components/counter/demo/api.md +167 -21
- package/components/counter/demo/api.min.js +3419 -773
- package/components/counter/demo/index.html +17 -10
- package/components/counter/demo/index.md +191 -34
- package/components/counter/demo/index.min.js +3419 -773
- package/components/counter/demo/readme.html +16 -9
- package/components/counter/dist/auro-counter-button.d.ts +2 -0
- package/components/counter/dist/auro-counter-group.d.ts +162 -11
- package/components/counter/dist/auro-counter.d.ts +16 -0
- package/components/counter/dist/helptextVersion.d.ts +2 -0
- package/components/counter/dist/iconVersion.d.ts +1 -1
- package/components/counter/dist/index.js +3419 -773
- package/components/counter/dist/registered.js +3419 -773
- package/components/datepicker/README.md +2 -1
- package/components/datepicker/demo/api.html +16 -10
- package/components/datepicker/demo/api.md +70 -28
- package/components/datepicker/demo/api.min.js +11970 -8081
- package/components/datepicker/demo/index.html +16 -10
- package/components/datepicker/demo/index.md +87 -8
- package/components/datepicker/demo/index.min.js +11970 -8081
- package/components/datepicker/demo/readme.html +16 -9
- package/components/datepicker/demo/readme.md +2 -1
- package/components/datepicker/dist/auro-datepicker.d.ts +152 -12
- package/components/datepicker/dist/buttonVersion.d.ts +1 -1
- package/components/datepicker/dist/iconVersion.d.ts +2 -0
- package/components/datepicker/dist/index.js +14577 -10688
- package/components/datepicker/dist/popoverVersion.d.ts +1 -1
- package/components/datepicker/dist/registered.js +14577 -10688
- package/components/dropdown/demo/api.html +16 -10
- package/components/dropdown/demo/api.md +89 -281
- package/components/dropdown/demo/api.min.js +451 -271
- package/components/dropdown/demo/index.html +16 -10
- package/components/dropdown/demo/index.md +92 -362
- package/components/dropdown/demo/index.min.js +451 -271
- package/components/dropdown/demo/readme.html +16 -9
- package/components/dropdown/dist/auro-dropdown.d.ts +43 -82
- package/components/dropdown/dist/auro-dropdownBib.d.ts +14 -0
- package/components/dropdown/dist/index.js +450 -270
- package/components/dropdown/dist/registered.js +450 -270
- package/components/form/demo/api.html +16 -9
- package/components/form/demo/api.md +1 -1
- package/components/form/demo/api.min.js +3 -3
- package/components/form/demo/autocomplete.html +19 -3
- package/components/form/demo/index.html +16 -9
- package/components/form/demo/index.min.js +3 -3
- package/components/form/demo/readme.html +16 -9
- package/components/form/demo/working.html +19 -13
- package/components/form/dist/auro-form.d.ts +1 -1
- package/components/form/dist/index.js +2 -2
- package/components/form/dist/registered.js +2 -2
- package/components/helptext/dist/auro-helptext.d.ts +0 -2
- package/components/helptext/dist/index.js +3 -5
- package/components/helptext/dist/registered.js +3 -5
- package/components/input/README.md +6 -2
- package/components/input/demo/api.html +16 -10
- package/components/input/demo/api.md +235 -135
- package/components/input/demo/api.min.js +1046 -301
- package/components/input/demo/index.html +16 -10
- package/components/input/demo/index.md +55 -32
- package/components/input/demo/index.min.js +1062 -317
- package/components/input/demo/readme.html +16 -9
- package/components/input/demo/readme.md +6 -2
- package/components/input/dist/auro-input.d.ts +26 -2
- package/components/input/dist/base-input.d.ts +47 -11
- package/components/input/dist/buttonVersion.d.ts +1 -1
- package/components/input/dist/iconVersion.d.ts +1 -1
- package/components/input/dist/index.js +1061 -316
- package/components/input/dist/registered.js +1061 -316
- package/components/layoutElement/dist/index.js +11 -8
- package/components/layoutElement/dist/registered.js +97 -0
- package/components/menu/demo/api.html +17 -10
- package/components/menu/demo/api.md +65 -8
- package/components/menu/demo/api.min.js +301 -63
- package/components/menu/demo/index.html +16 -10
- package/components/menu/demo/index.min.js +301 -63
- package/components/menu/demo/readme.html +16 -9
- package/components/menu/dist/auro-menu.d.ts +53 -7
- package/components/menu/dist/auro-menuoption.d.ts +21 -3
- package/components/menu/dist/iconVersion.d.ts +1 -1
- package/components/menu/dist/index.js +286 -48
- package/components/menu/dist/registered.js +286 -48
- package/components/menu/dist/styles/default/tokens-css.d.ts +2 -0
- package/components/radio/demo/api.html +16 -10
- package/components/radio/demo/api.md +41 -9
- package/components/radio/demo/api.min.js +95 -97
- package/components/radio/demo/index.html +16 -10
- package/components/radio/demo/index.min.js +95 -97
- package/components/radio/demo/readme.html +16 -9
- package/components/radio/dist/auro-radio-group.d.ts +1 -1
- package/components/radio/dist/auro-radio.d.ts +11 -12
- package/components/radio/dist/index.js +94 -96
- package/components/radio/dist/registered.js +94 -96
- package/components/select/README.md +1 -0
- package/components/select/demo/api.html +16 -10
- package/components/select/demo/api.js +0 -2
- package/components/select/demo/api.md +159 -125
- package/components/select/demo/api.min.js +2281 -730
- package/components/select/demo/index.html +17 -11
- package/components/select/demo/index.md +1074 -259
- package/components/select/demo/index.min.js +2283 -720
- package/components/select/demo/readme.html +16 -9
- package/components/select/demo/readme.md +1 -0
- package/components/select/dist/auro-select.d.ts +86 -25
- package/components/select/dist/index.js +2175 -755
- package/components/select/dist/registered.js +2175 -755
- package/package.json +31 -28
- /package/components/{datepicker/dist/styles/default/color-css.d.ts → counter/dist/styles/shapeSize-css.d.ts} +0 -0
- /package/components/datepicker/dist/styles/{emphasized/style-css.d.ts → classic/color-css.d.ts} +0 -0
- /package/components/{input/dist/styles/default/input-css.d.ts → datepicker/dist/styles/classic/style-css.d.ts} +0 -0
- /package/components/{input/dist/styles/default/label-css.d.ts → datepicker/dist/styles/snowflake/color-css.d.ts} +0 -0
- /package/components/{input/dist/styles/input-css.d.ts → datepicker/dist/styles/snowflake/style-css.d.ts} +0 -0
- /package/components/{menu/dist/styles/color-menu-css.d.ts → dropdown/dist/styles/style-css.d.ts} +0 -0
- /package/components/menu/dist/styles/{color-menuoption-css.d.ts → default/color-menu-css.d.ts} +0 -0
- /package/components/menu/dist/styles/{style-menu-css.d.ts → default/color-menuoption-css.d.ts} +0 -0
- /package/components/menu/dist/styles/{style-menuoption-css.d.ts → default/style-menu-css.d.ts} +0 -0
- /package/components/menu/dist/styles/{tokens-css.d.ts → default/style-menuoption-css.d.ts} +0 -0
|
@@ -39,19 +39,22 @@ let AuroElement$3 = class AuroElement extends LitElement {
|
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
resetShapeClasses() {
|
|
42
|
-
|
|
43
|
-
const wrapper = this.shadowRoot.querySelector('.wrapper');
|
|
42
|
+
const wrapper = this.shadowRoot.querySelector('.wrapper');
|
|
44
43
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
44
|
+
if (wrapper) {
|
|
45
|
+
wrapper.classList.forEach((className) => {
|
|
46
|
+
if (className.startsWith('shape-')) {
|
|
47
|
+
wrapper.classList.remove(className);
|
|
48
|
+
}
|
|
49
|
+
});
|
|
51
50
|
|
|
51
|
+
if (this.shape && this.size) {
|
|
52
52
|
wrapper.classList.add(`shape-${this.shape.toLowerCase()}-${this.size.toLowerCase()}`);
|
|
53
|
+
} else {
|
|
54
|
+
wrapper.classList.add('shape-none');
|
|
53
55
|
}
|
|
54
56
|
}
|
|
57
|
+
|
|
55
58
|
}
|
|
56
59
|
|
|
57
60
|
resetLayoutClasses() {
|
|
@@ -96,9 +99,9 @@ let AuroElement$3 = class AuroElement extends LitElement {
|
|
|
96
99
|
}
|
|
97
100
|
};
|
|
98
101
|
|
|
99
|
-
var shapeSizeCss$1 = css`.wrapper{overflow:hidden}.shape-classic-xl,.shape-classic-lg,.shape-classic-md,.shape-classic-sm,.shape-classic-xs{min-height:
|
|
102
|
+
var shapeSizeCss$1 = css`.wrapper{overflow:hidden}.shape-classic-xl,.shape-classic-lg,.shape-classic-md,.shape-classic-sm,.shape-classic-xs{min-height:56px;max-height:56px;border-style:solid;border-width:1px;border-radius:var(--ds-border-radius, 0.375rem)}.shape-classic-xl.simple,.shape-classic-lg.simple,.shape-classic-md.simple,.shape-classic-sm.simple,.shape-classic-xs.simple{border-width:0px;min-height:58px;max-height:58px;background-color:unset;box-shadow:none}.shape-classic-xl.thin,.shape-classic-lg.thin,.shape-classic-md.thin,.shape-classic-sm.thin,.shape-classic-xs.thin{border-width:1px;min-height:56px;max-height:56px;background-color:unset}.shape-classic-xl.parentBorder,.shape-classic-lg.parentBorder,.shape-classic-md.parentBorder,.shape-classic-sm.parentBorder,.shape-classic-xs.parentBorder{border:0;box-shadow:unset;min-height:54px;max-height:54px}.shape-snowflake-xl,.shape-snowflake-lg,.shape-snowflake-md,.shape-snowflake-sm,.shape-snowflake-xs{min-height:56px;max-height:56px;border-style:solid;border-width:2px;border-color:transparent;border-radius:30px}.shape-snowflake-xl.simple,.shape-snowflake-lg.simple,.shape-snowflake-md.simple,.shape-snowflake-sm.simple,.shape-snowflake-xs.simple{border-width:0px;min-height:60px;max-height:60px;background-color:unset;box-shadow:none}.shape-snowflake-xl.thin,.shape-snowflake-lg.thin,.shape-snowflake-md.thin,.shape-snowflake-sm.thin,.shape-snowflake-xs.thin{border-width:1px;min-height:58px;max-height:58px;background-color:unset}.shape-snowflake-xl.parentBorder,.shape-snowflake-lg.parentBorder,.shape-snowflake-md.parentBorder,.shape-snowflake-sm.parentBorder,.shape-snowflake-xs.parentBorder{border:0;box-shadow:unset;min-height:56px;max-height:56px}.shape-box-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-box-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-box-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-box-lg{min-height:52px;max-height:52px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-box-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-box-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-box-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-box-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-box-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-box-sm{min-height:32px;max-height:32px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-box-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-box-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-box-xs{min-height:20px;max-height:20px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-box-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-box-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-rounded-lg{min-height:56px;max-height:56px;border-style:solid;border-width:2px;border-color:transparent;border-radius:6px}.shape-rounded-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-rounded-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-rounded-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-pill-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px}.shape-pill-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-left-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px 0 0 36px}.shape-pill-left-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-left-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-left-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-right-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:0 36px 36px 0}.shape-pill-right-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-right-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-right-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px}.shape-pill-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-left-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px 0 0 36px}.shape-pill-left-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-left-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-left-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-right-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:0 36px 36px 0}.shape-pill-right-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-right-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-right-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}`;
|
|
100
103
|
|
|
101
|
-
var tokensCss$
|
|
104
|
+
var tokensCss$5 = css`:host(:not([ondark])){--ds-auro-select-border-color: var(--ds-basic-color-border-bold, #585e67);--ds-auro-select-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-select-label-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-select-placeholder-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-select-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-select-error-icon-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-select-outline-color: transparent}:host([ondark]){--ds-auro-select-border-color: var(--ds-basic-color-border-inverse, #ffffff);--ds-auro-select-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-select-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db);--ds-auro-select-placeholder-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-select-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-select-error-icon-color: var(--ds-basic-color-status-error-subtle, #fbc6c6);--ds-auro-select-outline-color: transparent}`;
|
|
102
105
|
|
|
103
106
|
class DateFormatter {
|
|
104
107
|
|
|
@@ -516,7 +519,7 @@ const {
|
|
|
516
519
|
|
|
517
520
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
518
521
|
|
|
519
|
-
let AuroLibraryRuntimeUtils$
|
|
522
|
+
let AuroLibraryRuntimeUtils$5 = class AuroLibraryRuntimeUtils {
|
|
520
523
|
|
|
521
524
|
/* eslint-disable jsdoc/require-param */
|
|
522
525
|
|
|
@@ -586,7 +589,7 @@ let AuroLibraryRuntimeUtils$4 = class AuroLibraryRuntimeUtils {
|
|
|
586
589
|
class AuroFormValidation {
|
|
587
590
|
|
|
588
591
|
constructor() {
|
|
589
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
592
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$5();
|
|
590
593
|
}
|
|
591
594
|
|
|
592
595
|
/**
|
|
@@ -646,19 +649,19 @@ class AuroFormValidation {
|
|
|
646
649
|
{
|
|
647
650
|
check: (e) => e.value?.length > 0 && e.value?.length < e.minLength,
|
|
648
651
|
validity: 'tooShort',
|
|
649
|
-
message: e => e.setCustomValidityTooShort || e.setCustomValidity || ''
|
|
652
|
+
message: e => e.getAttribute('setCustomValidityTooShort') || e.setCustomValidity || ''
|
|
650
653
|
},
|
|
651
654
|
{
|
|
652
655
|
check: (e) => e.value?.length > e.maxLength,
|
|
653
656
|
validity: 'tooLong',
|
|
654
|
-
message: e => e.setCustomValidityTooLong || e.setCustomValidity || ''
|
|
657
|
+
message: e => e.getAttribute('setCustomValidityTooLong') || e.setCustomValidity || ''
|
|
655
658
|
}
|
|
656
659
|
],
|
|
657
660
|
pattern: [
|
|
658
661
|
{
|
|
659
662
|
check: (e) => e.pattern && !new RegExp(`^${e.pattern}$`, 'u').test(e.value),
|
|
660
663
|
validity: 'patternMismatch',
|
|
661
|
-
message: e => e.setCustomValidityPatternMismatch || e.setCustomValidity || ''
|
|
664
|
+
message: e => e.getAttribute('setCustomValidityPatternMismatch') || e.setCustomValidity || ''
|
|
662
665
|
}
|
|
663
666
|
]
|
|
664
667
|
},
|
|
@@ -805,13 +808,24 @@ class AuroFormValidation {
|
|
|
805
808
|
this.getInputElements(elem);
|
|
806
809
|
this.getAuroInputs(elem);
|
|
807
810
|
|
|
808
|
-
//
|
|
811
|
+
// Check if validation should run
|
|
809
812
|
let validationShouldRun =
|
|
813
|
+
|
|
814
|
+
// If the validation was forced
|
|
810
815
|
force ||
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
816
|
+
|
|
817
|
+
// If the validation should run on input
|
|
818
|
+
elem.validateOnInput ||
|
|
819
|
+
|
|
820
|
+
// State-based checks
|
|
821
|
+
(
|
|
822
|
+
// Element is not currently focused
|
|
823
|
+
!elem.contains(document.activeElement) && // native input is not focused directly
|
|
824
|
+
!document.activeElement.shadowRoot?.contains(elem) && // native input is not focused in the shadow DOM of another component
|
|
825
|
+
|
|
826
|
+
// And element has been touched or is untouched but has a value
|
|
827
|
+
( elem.touched || (!elem.touched && typeof elem.value !== "undefined") )
|
|
828
|
+
);
|
|
815
829
|
|
|
816
830
|
if (elem.hasAttribute('error')) {
|
|
817
831
|
elem.validity = 'customError';
|
|
@@ -853,10 +867,10 @@ class AuroFormValidation {
|
|
|
853
867
|
if (!hasValue && elem.required && elem.touched) {
|
|
854
868
|
elem.validity = 'valueMissing';
|
|
855
869
|
elem.errorMessage = elem.setCustomValidityValueMissing || elem.setCustomValidity || '';
|
|
856
|
-
} else if (this.runtimeUtils.elementMatch(elem, 'auro-input')) {
|
|
870
|
+
} else if (hasValue && this.runtimeUtils.elementMatch(elem, 'auro-input')) {
|
|
857
871
|
this.validateType(elem);
|
|
858
872
|
this.validateElementAttributes(elem);
|
|
859
|
-
} else if (this.runtimeUtils.elementMatch(elem, 'auro-counter') || this.runtimeUtils.elementMatch(elem, 'auro-counter-group')) {
|
|
873
|
+
} else if (hasValue && (this.runtimeUtils.elementMatch(elem, 'auro-counter') || this.runtimeUtils.elementMatch(elem, 'auro-counter-group'))) {
|
|
860
874
|
this.validateElementAttributes(elem);
|
|
861
875
|
}
|
|
862
876
|
}
|
|
@@ -865,7 +879,9 @@ class AuroFormValidation {
|
|
|
865
879
|
elem.validity = this.auroInputElements[0].validity;
|
|
866
880
|
elem.errorMessage = this.auroInputElements[0].errorMessage;
|
|
867
881
|
|
|
868
|
-
|
|
882
|
+
// combobox has 2 inputs but no need to check validity on the 2nd one which is in fullscreen bib.
|
|
883
|
+
// combobox's 2nd input will have noValidate set true.
|
|
884
|
+
if (elem.validity === 'valid' && this.auroInputElements.length > 1 && !this.auroInputElements[1].noValidate) {
|
|
869
885
|
elem.validity = this.auroInputElements[1].validity;
|
|
870
886
|
elem.errorMessage = this.auroInputElements[1].errorMessage;
|
|
871
887
|
}
|
|
@@ -2671,7 +2687,7 @@ class AuroFloatingUI {
|
|
|
2671
2687
|
*/
|
|
2672
2688
|
mirrorSize() {
|
|
2673
2689
|
// mirror the boxsize from bibSizer
|
|
2674
|
-
if (this.element.bibSizer) {
|
|
2690
|
+
if (this.element.bibSizer && this.element.matchWidth) {
|
|
2675
2691
|
const sizerStyle = window.getComputedStyle(this.element.bibSizer);
|
|
2676
2692
|
const bibContent = this.element.bib.shadowRoot.querySelector(".container");
|
|
2677
2693
|
if (sizerStyle.width !== '0px') {
|
|
@@ -2807,6 +2823,7 @@ class AuroFloatingUI {
|
|
|
2807
2823
|
this.element.bib.style.left = "0px";
|
|
2808
2824
|
this.element.bib.style.width = '';
|
|
2809
2825
|
this.element.bib.style.height = '';
|
|
2826
|
+
this.element.style.contain = '';
|
|
2810
2827
|
|
|
2811
2828
|
// reset the size that was mirroring `size` css-part
|
|
2812
2829
|
const bibContent = this.element.bib.shadowRoot.querySelector(".container");
|
|
@@ -2831,6 +2848,7 @@ class AuroFloatingUI {
|
|
|
2831
2848
|
this.element.bib.style.position = '';
|
|
2832
2849
|
this.element.bib.removeAttribute('isfullscreen');
|
|
2833
2850
|
this.element.isBibFullscreen = false;
|
|
2851
|
+
this.element.style.contain = 'layout';
|
|
2834
2852
|
}
|
|
2835
2853
|
|
|
2836
2854
|
const isChanged = this.strategy && this.strategy !== value;
|
|
@@ -2883,22 +2901,16 @@ class AuroFloatingUI {
|
|
|
2883
2901
|
if (this.element.contains(activeElement) || this.element.bib?.contains(activeElement)) {
|
|
2884
2902
|
return;
|
|
2885
2903
|
}
|
|
2886
|
-
|
|
2904
|
+
|
|
2887
2905
|
// if fullscreen bib is in fullscreen mode, do not close
|
|
2888
2906
|
if (this.element.bib.hasAttribute('isfullscreen')) {
|
|
2889
2907
|
return;
|
|
2890
2908
|
}
|
|
2891
2909
|
|
|
2892
|
-
this.hideBib();
|
|
2910
|
+
this.hideBib("keydown");
|
|
2893
2911
|
}
|
|
2894
2912
|
|
|
2895
2913
|
setupHideHandlers() {
|
|
2896
|
-
this.preventFocusLoseOnBibClick = (event) => {
|
|
2897
|
-
event.preventDefault();
|
|
2898
|
-
event.stopPropagation();
|
|
2899
|
-
};
|
|
2900
|
-
this.element.bib.addEventListener('mousedown', this.preventFocusLoseOnBibClick);
|
|
2901
|
-
|
|
2902
2914
|
// Define handlers & store references
|
|
2903
2915
|
this.focusHandler = () => this.handleFocusLoss();
|
|
2904
2916
|
|
|
@@ -2914,7 +2926,7 @@ class AuroFloatingUI {
|
|
|
2914
2926
|
document.expandedAuroFormkitDropdown = null;
|
|
2915
2927
|
document.expandedAuroFloater = this;
|
|
2916
2928
|
} else {
|
|
2917
|
-
this.hideBib();
|
|
2929
|
+
this.hideBib("click");
|
|
2918
2930
|
}
|
|
2919
2931
|
}
|
|
2920
2932
|
};
|
|
@@ -2927,7 +2939,7 @@ class AuroFloatingUI {
|
|
|
2927
2939
|
// if something else is open, let it handle itself
|
|
2928
2940
|
return;
|
|
2929
2941
|
}
|
|
2930
|
-
this.hideBib();
|
|
2942
|
+
this.hideBib("keydown");
|
|
2931
2943
|
}
|
|
2932
2944
|
};
|
|
2933
2945
|
|
|
@@ -2948,11 +2960,6 @@ class AuroFloatingUI {
|
|
|
2948
2960
|
cleanupHideHandlers() {
|
|
2949
2961
|
// Remove event listeners if they exist
|
|
2950
2962
|
|
|
2951
|
-
if (this.preventFocusLoseOnBibClick) {
|
|
2952
|
-
this.element.bib.removeEventListener('mousedown', this.preventFocusLoseOnBibClick);
|
|
2953
|
-
delete this.preventFocusLoseOnBibClick;
|
|
2954
|
-
}
|
|
2955
|
-
|
|
2956
2963
|
if (this.focusHandler) {
|
|
2957
2964
|
document.removeEventListener('focusin', this.focusHandler);
|
|
2958
2965
|
this.focusHandler = null;
|
|
@@ -3010,7 +3017,11 @@ class AuroFloatingUI {
|
|
|
3010
3017
|
}
|
|
3011
3018
|
}
|
|
3012
3019
|
|
|
3013
|
-
|
|
3020
|
+
/**
|
|
3021
|
+
* Hides the floating UI element.
|
|
3022
|
+
* @param {String} eventType - The event type that triggered the hiding action.
|
|
3023
|
+
*/
|
|
3024
|
+
hideBib(eventType = "unknown") {
|
|
3014
3025
|
if (!this.element.disabled && !this.element.noToggle) {
|
|
3015
3026
|
this.lockScroll(false);
|
|
3016
3027
|
this.element.triggerChevron?.removeAttribute('data-expanded');
|
|
@@ -3021,7 +3032,7 @@ class AuroFloatingUI {
|
|
|
3021
3032
|
if (this.showing) {
|
|
3022
3033
|
this.cleanupHideHandlers();
|
|
3023
3034
|
this.showing = false;
|
|
3024
|
-
this.dispatchEventDropdownToggle();
|
|
3035
|
+
this.dispatchEventDropdownToggle(eventType);
|
|
3025
3036
|
}
|
|
3026
3037
|
}
|
|
3027
3038
|
document.expandedAuroFloater = null;
|
|
@@ -3030,11 +3041,13 @@ class AuroFloatingUI {
|
|
|
3030
3041
|
/**
|
|
3031
3042
|
* @private
|
|
3032
3043
|
* @returns {void} Dispatches event with an object showing the state of the dropdown.
|
|
3044
|
+
* @param {String} eventType - The event type that triggered the toggle action.
|
|
3033
3045
|
*/
|
|
3034
|
-
dispatchEventDropdownToggle() {
|
|
3046
|
+
dispatchEventDropdownToggle(eventType) {
|
|
3035
3047
|
const event = new CustomEvent(this.eventPrefix ? `${this.eventPrefix}-toggled` : 'toggled', {
|
|
3036
3048
|
detail: {
|
|
3037
3049
|
expanded: this.showing,
|
|
3050
|
+
eventType: eventType || "unknown",
|
|
3038
3051
|
},
|
|
3039
3052
|
composed: true
|
|
3040
3053
|
});
|
|
@@ -3044,7 +3057,7 @@ class AuroFloatingUI {
|
|
|
3044
3057
|
|
|
3045
3058
|
handleClick() {
|
|
3046
3059
|
if (this.element.isPopoverVisible) {
|
|
3047
|
-
this.hideBib();
|
|
3060
|
+
this.hideBib("click");
|
|
3048
3061
|
} else {
|
|
3049
3062
|
this.showBib();
|
|
3050
3063
|
}
|
|
@@ -3067,8 +3080,9 @@ class AuroFloatingUI {
|
|
|
3067
3080
|
// Space is included as it's expected behavior for interactive elements
|
|
3068
3081
|
|
|
3069
3082
|
const origin = event.composedPath()[0];
|
|
3070
|
-
if (event.key === 'Enter' || (
|
|
3071
|
-
|
|
3083
|
+
if (event.key === 'Enter' || event.key === ' ' && (!origin || origin.tagName !== "INPUT")) {
|
|
3084
|
+
|
|
3085
|
+
event.preventDefault();
|
|
3072
3086
|
this.handleClick();
|
|
3073
3087
|
}
|
|
3074
3088
|
break;
|
|
@@ -3079,7 +3093,7 @@ class AuroFloatingUI {
|
|
|
3079
3093
|
break;
|
|
3080
3094
|
case 'mouseleave':
|
|
3081
3095
|
if (this.element.hoverToggle) {
|
|
3082
|
-
this.hideBib();
|
|
3096
|
+
this.hideBib("mouseleave");
|
|
3083
3097
|
}
|
|
3084
3098
|
break;
|
|
3085
3099
|
case 'focus':
|
|
@@ -3222,6 +3236,267 @@ class AuroFloatingUI {
|
|
|
3222
3236
|
}
|
|
3223
3237
|
}
|
|
3224
3238
|
|
|
3239
|
+
// Selectors for focusable elements
|
|
3240
|
+
const FOCUSABLE_SELECTORS = [
|
|
3241
|
+
'a[href]',
|
|
3242
|
+
'button:not([disabled])',
|
|
3243
|
+
'textarea:not([disabled])',
|
|
3244
|
+
'input:not([disabled])',
|
|
3245
|
+
'select:not([disabled])',
|
|
3246
|
+
'[role="tab"]:not([disabled])',
|
|
3247
|
+
'[role="link"]:not([disabled])',
|
|
3248
|
+
'[role="button"]:not([disabled])',
|
|
3249
|
+
'[tabindex]:not([tabindex="-1"])',
|
|
3250
|
+
'[contenteditable]:not([contenteditable="false"])'
|
|
3251
|
+
];
|
|
3252
|
+
|
|
3253
|
+
// List of custom components that are known to be focusable
|
|
3254
|
+
const FOCUSABLE_COMPONENTS = [
|
|
3255
|
+
'auro-checkbox',
|
|
3256
|
+
'auro-radio',
|
|
3257
|
+
'auro-dropdown',
|
|
3258
|
+
'auro-button',
|
|
3259
|
+
'auro-combobox',
|
|
3260
|
+
'auro-input',
|
|
3261
|
+
'auro-counter',
|
|
3262
|
+
'auro-menu',
|
|
3263
|
+
'auro-select',
|
|
3264
|
+
'auro-datepicker',
|
|
3265
|
+
'auro-hyperlink',
|
|
3266
|
+
'auro-accordion',
|
|
3267
|
+
];
|
|
3268
|
+
|
|
3269
|
+
/**
|
|
3270
|
+
* Determines if a given element is a custom focusable component.
|
|
3271
|
+
* Returns true if the element matches a known focusable component and is not disabled.
|
|
3272
|
+
*
|
|
3273
|
+
* @param {HTMLElement} element The element to check for focusability.
|
|
3274
|
+
* @returns {boolean} True if the element is a focusable custom component, false otherwise.
|
|
3275
|
+
*/
|
|
3276
|
+
function isFocusableComponent(element) {
|
|
3277
|
+
const componentName = element.tagName.toLowerCase();
|
|
3278
|
+
|
|
3279
|
+
// Guard Clause: Element is a focusable component
|
|
3280
|
+
if (!FOCUSABLE_COMPONENTS.some((name) => element.hasAttribute(name) || componentName === name)) return false;
|
|
3281
|
+
|
|
3282
|
+
// Guard Clause: Element is not disabled
|
|
3283
|
+
if (element.hasAttribute('disabled')) return false;
|
|
3284
|
+
|
|
3285
|
+
// Guard Clause: The element is a hyperlink and has no href attribute
|
|
3286
|
+
if (componentName.match("hyperlink") && !element.hasAttribute('href')) return false;
|
|
3287
|
+
|
|
3288
|
+
// If all guard clauses pass, the element is a focusable component
|
|
3289
|
+
return true;
|
|
3290
|
+
}
|
|
3291
|
+
|
|
3292
|
+
/**
|
|
3293
|
+
* Retrieves all focusable elements within the container in DOM order, including those in shadow DOM and slots.
|
|
3294
|
+
* Returns a unique, ordered array of elements that can receive focus.
|
|
3295
|
+
*
|
|
3296
|
+
* @param {HTMLElement} container The container to search within
|
|
3297
|
+
* @returns {Array<HTMLElement>} An array of focusable elements within the container.
|
|
3298
|
+
*/
|
|
3299
|
+
function getFocusableElements(container) {
|
|
3300
|
+
// Get elements in DOM order by walking the tree
|
|
3301
|
+
const orderedFocusableElements = [];
|
|
3302
|
+
|
|
3303
|
+
// Define a recursive function to collect focusable elements in DOM order
|
|
3304
|
+
const collectFocusableElements = (root) => {
|
|
3305
|
+
// Check if current element is focusable
|
|
3306
|
+
if (root.nodeType === Node.ELEMENT_NODE) {
|
|
3307
|
+
// Check if this is a custom component that is focusable
|
|
3308
|
+
const isComponentFocusable = isFocusableComponent(root);
|
|
3309
|
+
|
|
3310
|
+
if (isComponentFocusable) {
|
|
3311
|
+
// Add the component itself as a focusable element and don't traverse its shadow DOM
|
|
3312
|
+
orderedFocusableElements.push(root);
|
|
3313
|
+
return; // Skip traversing inside this component
|
|
3314
|
+
}
|
|
3315
|
+
|
|
3316
|
+
// Check if the element itself matches any selector
|
|
3317
|
+
for (const selector of FOCUSABLE_SELECTORS) {
|
|
3318
|
+
if (root.matches?.(selector)) {
|
|
3319
|
+
orderedFocusableElements.push(root);
|
|
3320
|
+
break; // Once we know it's focusable, no need to check other selectors
|
|
3321
|
+
}
|
|
3322
|
+
}
|
|
3323
|
+
|
|
3324
|
+
// Process shadow DOM only for non-Auro components
|
|
3325
|
+
if (root.shadowRoot) {
|
|
3326
|
+
// Process shadow DOM children in order
|
|
3327
|
+
if (root.shadowRoot.children) {
|
|
3328
|
+
Array.from(root.shadowRoot.children).forEach(child => {
|
|
3329
|
+
collectFocusableElements(child);
|
|
3330
|
+
});
|
|
3331
|
+
}
|
|
3332
|
+
}
|
|
3333
|
+
|
|
3334
|
+
// Process slots and their assigned nodes in order
|
|
3335
|
+
if (root.tagName === 'SLOT') {
|
|
3336
|
+
const assignedNodes = root.assignedNodes({ flatten: true });
|
|
3337
|
+
for (const node of assignedNodes) {
|
|
3338
|
+
collectFocusableElements(node);
|
|
3339
|
+
}
|
|
3340
|
+
} else {
|
|
3341
|
+
// Process light DOM children in order
|
|
3342
|
+
if (root.children) {
|
|
3343
|
+
Array.from(root.children).forEach(child => {
|
|
3344
|
+
collectFocusableElements(child);
|
|
3345
|
+
});
|
|
3346
|
+
}
|
|
3347
|
+
}
|
|
3348
|
+
}
|
|
3349
|
+
};
|
|
3350
|
+
|
|
3351
|
+
// Start the traversal from the container
|
|
3352
|
+
collectFocusableElements(container);
|
|
3353
|
+
|
|
3354
|
+
// Remove duplicates that might have been collected through different paths
|
|
3355
|
+
// while preserving order
|
|
3356
|
+
const uniqueElements = [];
|
|
3357
|
+
const seen = new Set();
|
|
3358
|
+
|
|
3359
|
+
for (const element of orderedFocusableElements) {
|
|
3360
|
+
if (!seen.has(element)) {
|
|
3361
|
+
seen.add(element);
|
|
3362
|
+
uniqueElements.push(element);
|
|
3363
|
+
}
|
|
3364
|
+
}
|
|
3365
|
+
|
|
3366
|
+
return uniqueElements;
|
|
3367
|
+
}
|
|
3368
|
+
|
|
3369
|
+
/**
|
|
3370
|
+
* FocusTrap manages keyboard focus within a specified container element, ensuring that focus does not leave the container when tabbing.
|
|
3371
|
+
* It is commonly used for modal dialogs or overlays to improve accessibility by trapping focus within interactive UI components.
|
|
3372
|
+
*/
|
|
3373
|
+
class FocusTrap {
|
|
3374
|
+
/**
|
|
3375
|
+
* Creates a new FocusTrap instance for the given container element.
|
|
3376
|
+
* Initializes event listeners and prepares the container for focus management.
|
|
3377
|
+
*
|
|
3378
|
+
* @param {HTMLElement} container The DOM element to trap focus within.
|
|
3379
|
+
* @throws {Error} If the provided container is not a valid HTMLElement.
|
|
3380
|
+
*/
|
|
3381
|
+
constructor(container) {
|
|
3382
|
+
if (!container || !(container instanceof HTMLElement)) {
|
|
3383
|
+
throw new Error("FocusTrap requires a valid HTMLElement.");
|
|
3384
|
+
}
|
|
3385
|
+
|
|
3386
|
+
this.container = container;
|
|
3387
|
+
this.tabDirection = 'forward'; // or 'backward'
|
|
3388
|
+
|
|
3389
|
+
this._init();
|
|
3390
|
+
}
|
|
3391
|
+
|
|
3392
|
+
/**
|
|
3393
|
+
* Initializes the focus trap by setting up event listeners and attributes on the container.
|
|
3394
|
+
* Prepares the container for focus management, including support for shadow DOM and inert attributes.
|
|
3395
|
+
*
|
|
3396
|
+
* @private
|
|
3397
|
+
*/
|
|
3398
|
+
_init() {
|
|
3399
|
+
|
|
3400
|
+
// Add inert attribute to prevent focusing programmatically as well (if supported)
|
|
3401
|
+
if ('inert' in HTMLElement.prototype) {
|
|
3402
|
+
this.container.inert = false; // Ensure the container isn't inert
|
|
3403
|
+
this.container.setAttribute('data-focus-trap-container', true); // Mark for identification
|
|
3404
|
+
}
|
|
3405
|
+
|
|
3406
|
+
// Track tab direction
|
|
3407
|
+
this.container.addEventListener('keydown', this._onKeydown);
|
|
3408
|
+
}
|
|
3409
|
+
|
|
3410
|
+
/**
|
|
3411
|
+
* Handles keydown events to manage tab navigation within the container.
|
|
3412
|
+
* Ensures that focus wraps around when reaching the first or last focusable element.
|
|
3413
|
+
*
|
|
3414
|
+
* @param {KeyboardEvent} e The keyboard event triggered by user interaction.
|
|
3415
|
+
* @private
|
|
3416
|
+
*/
|
|
3417
|
+
_onKeydown = (e) => {
|
|
3418
|
+
|
|
3419
|
+
if (e.key === 'Tab') {
|
|
3420
|
+
|
|
3421
|
+
// Set the tab direction based on the key pressed
|
|
3422
|
+
this.tabDirection = e.shiftKey ? 'backward' : 'forward';
|
|
3423
|
+
|
|
3424
|
+
// Get the active element(s) in the document and shadow root
|
|
3425
|
+
// This will include the active element in the shadow DOM if it exists
|
|
3426
|
+
// Active element may be inside the shadow DOM depending on delegatesFocus, so we need to check both
|
|
3427
|
+
let activeElement = document.activeElement;
|
|
3428
|
+
const actives = [activeElement];
|
|
3429
|
+
while (activeElement?.shadowRoot?.activeElement) {
|
|
3430
|
+
actives.push(activeElement.shadowRoot.activeElement);
|
|
3431
|
+
activeElement = activeElement.shadowRoot.activeElement;
|
|
3432
|
+
}
|
|
3433
|
+
|
|
3434
|
+
// Update the focusable elements
|
|
3435
|
+
const focusables = this._getFocusableElements();
|
|
3436
|
+
|
|
3437
|
+
// If we're at either end of the focusable elements, wrap around to the other end
|
|
3438
|
+
const focusIndex =
|
|
3439
|
+
(actives.includes(focusables[0]) || actives.includes(this.container)) && this.tabDirection === 'backward'
|
|
3440
|
+
? focusables.length - 1
|
|
3441
|
+
: actives.includes(focusables[focusables.length - 1]) && this.tabDirection === 'forward'
|
|
3442
|
+
? 0
|
|
3443
|
+
: null;
|
|
3444
|
+
|
|
3445
|
+
if (focusIndex !== null) {
|
|
3446
|
+
focusables[focusIndex].focus();
|
|
3447
|
+
e.preventDefault(); // Prevent default tab behavior
|
|
3448
|
+
e.stopPropagation(); // Stop the event from bubbling up
|
|
3449
|
+
}
|
|
3450
|
+
}
|
|
3451
|
+
};
|
|
3452
|
+
|
|
3453
|
+
/**
|
|
3454
|
+
* Retrieves all focusable elements within the container in DOM order, including those in shadow DOM and slots.
|
|
3455
|
+
* Returns a unique, ordered array of elements that can receive focus.
|
|
3456
|
+
*
|
|
3457
|
+
* @returns {Array<HTMLElement>} An array of focusable elements within the container.
|
|
3458
|
+
* @private
|
|
3459
|
+
*/
|
|
3460
|
+
_getFocusableElements() {
|
|
3461
|
+
// Use the imported utility function to get focusable elements
|
|
3462
|
+
const elements = getFocusableElements(this.container);
|
|
3463
|
+
|
|
3464
|
+
// Filter out any elements with the 'focus-bookend' class
|
|
3465
|
+
return elements;
|
|
3466
|
+
}
|
|
3467
|
+
|
|
3468
|
+
/**
|
|
3469
|
+
* Moves focus to the first focusable element within the container.
|
|
3470
|
+
* Useful for setting initial focus when activating the focus trap.
|
|
3471
|
+
*/
|
|
3472
|
+
focusFirstElement() {
|
|
3473
|
+
const focusables = this._getFocusableElements();
|
|
3474
|
+
if (focusables.length) focusables[0].focus();
|
|
3475
|
+
}
|
|
3476
|
+
|
|
3477
|
+
/**
|
|
3478
|
+
* Moves focus to the last focusable element within the container.
|
|
3479
|
+
* Useful for setting focus when deactivating or cycling focus in reverse.
|
|
3480
|
+
*/
|
|
3481
|
+
focusLastElement() {
|
|
3482
|
+
const focusables = this._getFocusableElements();
|
|
3483
|
+
if (focusables.length) focusables[focusables.length - 1].focus();
|
|
3484
|
+
}
|
|
3485
|
+
|
|
3486
|
+
/**
|
|
3487
|
+
* Removes event listeners and attributes added by the focus trap.
|
|
3488
|
+
* Call this method to clean up when the focus trap is no longer needed.
|
|
3489
|
+
*/
|
|
3490
|
+
disconnect() {
|
|
3491
|
+
|
|
3492
|
+
if (this.container.hasAttribute('data-focus-trap-container')) {
|
|
3493
|
+
this.container.removeAttribute('data-focus-trap-container');
|
|
3494
|
+
}
|
|
3495
|
+
|
|
3496
|
+
this.container.removeEventListener('keydown', this._onKeydown);
|
|
3497
|
+
}
|
|
3498
|
+
}
|
|
3499
|
+
|
|
3225
3500
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
3226
3501
|
// See LICENSE in the project root for license information.
|
|
3227
3502
|
|
|
@@ -3272,7 +3547,7 @@ let AuroDependencyVersioning$1 = class AuroDependencyVersioning {
|
|
|
3272
3547
|
* @attr {Boolean} hiddenAudible - If present, the component will be hidden from screen readers, but seen visually
|
|
3273
3548
|
*/
|
|
3274
3549
|
|
|
3275
|
-
let AuroElement$1 = class AuroElement extends LitElement {
|
|
3550
|
+
let AuroElement$1$1 = class AuroElement extends LitElement {
|
|
3276
3551
|
|
|
3277
3552
|
// function to define props used within the scope of this component
|
|
3278
3553
|
static get properties() {
|
|
@@ -3328,7 +3603,7 @@ const cacheFetch$1 = (uri, options = {}) => {
|
|
|
3328
3603
|
return _fetchMap$1.get(uri);
|
|
3329
3604
|
};
|
|
3330
3605
|
|
|
3331
|
-
var styleCss$
|
|
3606
|
+
var styleCss$3$1 = css`:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock,:host{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host([hidden]:not(:focus):not(:active)){display:none}.util_displayHiddenVisually,:host([hiddenVisually]:not(:focus):not(:active)){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.ico_squareLarge{fill:currentColor;height:var(--auro-size-lg, var(--ds-size-300, 1.5rem))}.ico_squareSmall{fill:currentColor;height:.6rem}.ico_squareMed{fill:currentColor;height:var(--auro-size-md, var(--ds-size-200, 1rem))}.ico_squareSml{fill:currentColor;height:var(--auro-size-sm, var(--ds-size-150, 0.75rem))}:host{color:currentColor;vertical-align:middle;line-height:1;display:inline-block}svg{min-width:var(--ds-auro-icon-size, 1.5rem) !important;width:var(--ds-auro-icon-size, 1.5rem) !important;height:var(--ds-auro-icon-size, 1.5rem) !important}.componentWrapper{display:flex}.svgWrapper{height:var(--ds-auro-icon-size);width:var(--ds-auro-icon-size)}.labelWrapper{margin-left:var(--ds-size-50, 0.25rem);line-height:1.8}`;
|
|
3332
3607
|
|
|
3333
3608
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
3334
3609
|
// See LICENSE in the project root for license information.
|
|
@@ -3340,7 +3615,7 @@ var styleCss$2$1 = css`:focus:not(:focus-visible){outline:3px solid transparent}
|
|
|
3340
3615
|
*/
|
|
3341
3616
|
|
|
3342
3617
|
// build the component class
|
|
3343
|
-
let BaseIcon$1 = class BaseIcon extends AuroElement$1 {
|
|
3618
|
+
let BaseIcon$1 = class BaseIcon extends AuroElement$1$1 {
|
|
3344
3619
|
constructor() {
|
|
3345
3620
|
super();
|
|
3346
3621
|
this.onDark = false;
|
|
@@ -3371,7 +3646,7 @@ let BaseIcon$1 = class BaseIcon extends AuroElement$1 {
|
|
|
3371
3646
|
|
|
3372
3647
|
static get styles() {
|
|
3373
3648
|
return css`
|
|
3374
|
-
${styleCss$
|
|
3649
|
+
${styleCss$3$1}
|
|
3375
3650
|
`;
|
|
3376
3651
|
}
|
|
3377
3652
|
|
|
@@ -3412,9 +3687,9 @@ let BaseIcon$1 = class BaseIcon extends AuroElement$1 {
|
|
|
3412
3687
|
}
|
|
3413
3688
|
};
|
|
3414
3689
|
|
|
3415
|
-
var tokensCss$2 = css`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-alaska-color:#02426D;--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}`;
|
|
3690
|
+
var tokensCss$2$1 = css`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-alaska-color:#02426D;--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}`;
|
|
3416
3691
|
|
|
3417
|
-
var colorCss$3 = css`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[variant=accent1]){--ds-auro-icon-color:var(--ds-basic-color-texticon-accent1, #265688)}:host(:not([onDark])[variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:not([onDark])[variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-muted, #676767)}:host(:not([onDark])[variant=statusDefault]){--ds-auro-icon-color:var(--ds-basic-color-status-default, #afb9c6)}:host(:not([onDark])[variant=statusInfo]){--ds-auro-icon-color:var(--ds-basic-color-status-info, #01426a)}:host(:not([onDark])[variant=statusSuccess]){--ds-auro-icon-color:var(--ds-basic-color-status-success, #447a1f)}:host(:not([onDark])[variant=statusWarning]){--ds-auro-icon-color:var(--ds-basic-color-status-warning, #fac200)}:host(:not([onDark])[variant=statusError]){--ds-auro-icon-color:var(--ds-basic-color-status-error, #e31f26)}:host(:not([onDark])[variant=statusInfoSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-info-subtle, #ebf3f9)}:host(:not([onDark])[variant=statusSuccessSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-success-subtle, #d6eac7)}:host(:not([onDark])[variant=statusWarningSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-warning-subtle, #fff0b2)}:host(:not([onDark])[variant=statusErrorSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-error-subtle, #fbc6c6)}:host(:not([onDark])[variant=fareBasicEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-basiceconomy, #97eaf8)}:host(:not([onDark])[variant=fareBusiness]){--ds-auro-icon-color:var(--ds-basic-color-fare-business, #01426a)}:host(:not([onDark])[variant=fareEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-economy, #0074ca)}:host(:not([onDark])[variant=fareFirst]){--ds-auro-icon-color:var(--ds-basic-color-fare-first, #00274a)}:host(:not([onDark])[variant=farePremiumEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-premiumeconomy, #005154)}:host(:not([onDark])[variant=tierOneWorldEmerald]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-emerald, #139142)}:host(:not([onDark])[variant=tierOneWorldSapphire]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-sapphire, #015daa)}:host(:not([onDark])[variant=tierOneWorldRuby]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-ruby, #a41d4a)}:host([onDark]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse, #ffffff)}:host([onDark][variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}:host([onDark][variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][variant=statusError]){--ds-auro-icon-color:var(--ds-advanced-color-state-error-inverse, #f9a4a8)}`;
|
|
3692
|
+
var colorCss$3$1 = css`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[variant=accent1]){--ds-auro-icon-color:var(--ds-basic-color-texticon-accent1, #265688)}:host(:not([onDark])[variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:not([onDark])[variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-muted, #676767)}:host(:not([onDark])[variant=statusDefault]){--ds-auro-icon-color:var(--ds-basic-color-status-default, #afb9c6)}:host(:not([onDark])[variant=statusInfo]){--ds-auro-icon-color:var(--ds-basic-color-status-info, #01426a)}:host(:not([onDark])[variant=statusSuccess]){--ds-auro-icon-color:var(--ds-basic-color-status-success, #447a1f)}:host(:not([onDark])[variant=statusWarning]){--ds-auro-icon-color:var(--ds-basic-color-status-warning, #fac200)}:host(:not([onDark])[variant=statusError]){--ds-auro-icon-color:var(--ds-basic-color-status-error, #e31f26)}:host(:not([onDark])[variant=statusInfoSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-info-subtle, #ebf3f9)}:host(:not([onDark])[variant=statusSuccessSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-success-subtle, #d6eac7)}:host(:not([onDark])[variant=statusWarningSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-warning-subtle, #fff0b2)}:host(:not([onDark])[variant=statusErrorSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-error-subtle, #fbc6c6)}:host(:not([onDark])[variant=fareBasicEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-basiceconomy, #97eaf8)}:host(:not([onDark])[variant=fareBusiness]){--ds-auro-icon-color:var(--ds-basic-color-fare-business, #01426a)}:host(:not([onDark])[variant=fareEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-economy, #0074ca)}:host(:not([onDark])[variant=fareFirst]){--ds-auro-icon-color:var(--ds-basic-color-fare-first, #00274a)}:host(:not([onDark])[variant=farePremiumEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-premiumeconomy, #005154)}:host(:not([onDark])[variant=tierOneWorldEmerald]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-emerald, #139142)}:host(:not([onDark])[variant=tierOneWorldSapphire]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-sapphire, #015daa)}:host(:not([onDark])[variant=tierOneWorldRuby]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-ruby, #a41d4a)}:host([onDark]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse, #ffffff)}:host([onDark][variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}:host([onDark][variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][variant=statusError]){--ds-auro-icon-color:var(--ds-advanced-color-state-error-inverse, #f9a4a8)}`;
|
|
3418
3693
|
|
|
3419
3694
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
3420
3695
|
// See LICENSE in the project root for license information.
|
|
@@ -3572,9 +3847,9 @@ let AuroIcon$1 = class AuroIcon extends BaseIcon$1 {
|
|
|
3572
3847
|
static get styles() {
|
|
3573
3848
|
return [
|
|
3574
3849
|
super.styles,
|
|
3575
|
-
css`${tokensCss$2}`,
|
|
3576
|
-
css`${styleCss$
|
|
3577
|
-
css`${colorCss$3}`
|
|
3850
|
+
css`${tokensCss$2$1}`,
|
|
3851
|
+
css`${styleCss$3$1}`,
|
|
3852
|
+
css`${colorCss$3$1}`
|
|
3578
3853
|
];
|
|
3579
3854
|
}
|
|
3580
3855
|
|
|
@@ -3608,8 +3883,12 @@ let AuroIcon$1 = class AuroIcon extends BaseIcon$1 {
|
|
|
3608
3883
|
async firstUpdated() {
|
|
3609
3884
|
await super.firstUpdated();
|
|
3610
3885
|
|
|
3611
|
-
|
|
3612
|
-
|
|
3886
|
+
/**
|
|
3887
|
+
* icons provide a description for screen readers. Icon only instances Auro-button
|
|
3888
|
+
* depend on this description to provide context for the user using a screen reader.
|
|
3889
|
+
* Removes the SVG description for screen reader if ariaHidden is set to true.
|
|
3890
|
+
*/
|
|
3891
|
+
if (this.hasAttribute('ariaHidden') && this.svg) {
|
|
3613
3892
|
const svgDesc = this.svg.querySelector('desc');
|
|
3614
3893
|
|
|
3615
3894
|
if (svgDesc) {
|
|
@@ -3655,11 +3934,11 @@ let AuroIcon$1 = class AuroIcon extends BaseIcon$1 {
|
|
|
3655
3934
|
|
|
3656
3935
|
var iconVersion$1 = '6.1.2';
|
|
3657
3936
|
|
|
3658
|
-
var styleCss$1
|
|
3937
|
+
var styleCss$2$1 = css`:host{position:fixed;z-index:var(--depth-tooltip, 400);display:none;isolation:isolate}:host(:not([matchWidth])) .container{min-width:fit-content}:host([isfullscreen]){position:fixed;top:0;left:0}:host([isfullscreen]) .container{width:100dvw;max-width:none;height:100dvh;max-height:none;border-radius:unset;margin-top:0;box-shadow:unset;overscroll-behavior:contain}:host([data-show]){display:flex}:host([common]:not([isfullscreen])) .container,:host([rounded]:not([isfullscreen])) .container{border-radius:var(--ds-border-radius, 0.375rem)}:host([common][isfullscreen]) .container,:host([rounded][isfullscreen]) .container{border-radius:unset;box-shadow:unset}:host(:not([isfullscreen])) .container.shape-box{border-radius:unset}:host(:not([isfullscreen])) .container[class*=shape-pill],:host(:not([isfullscreen])) .container[class*=shape-snowflake]{border-radius:30px}.container{display:inline-block;overflow:auto;box-sizing:border-box;border-radius:var(--ds-border-radius, 0.375rem);margin:var(--ds-size-50, 0.25rem) 0}`;
|
|
3659
3938
|
|
|
3660
3939
|
var colorCss$2$1 = css`.container{background-color:var(--ds-auro-dropdownbib-container-color);box-shadow:var(--ds-auro-dropdownbib-boxshadow-color);color:var(--ds-auro-dropdownbib-text-color)}`;
|
|
3661
3940
|
|
|
3662
|
-
var tokensCss$1$1 = css`:host(:not([ondark])){--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-dropdown-trigger-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-border-color:
|
|
3941
|
+
var tokensCss$1$1 = css`:host(:not([ondark])){--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-muted, #676767);--ds-auro-dropdown-trigger-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-border-bold, #585e67);--ds-auro-dropdown-trigger-outline-color: transparent;--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-dropdownbib-boxshadow-color: var(--ds-elevation-200, 0px 0px 10px rgba(0, 0, 0, 0.15));--ds-auro-dropdownbib-background-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdownbib-container-color: var(--ds-basic-color-surface-default, #ffffff);--ds-auro-dropdownbib-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]){--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db);--ds-auro-dropdown-trigger-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdown-trigger-container-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-border-inverse, #ffffff);--ds-auro-dropdown-trigger-outline-color: transparent;--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-dropdownbib-boxshadow-color: var(--ds-elevation-200, 0px 0px 10px rgba(0, 0, 0, 0.15));--ds-auro-dropdownbib-background-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdownbib-container-color: var(--ds-advanced-color-shared-background-inverse, rgba(255, 255, 255, 0.15));--ds-auro-dropdownbib-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}`;
|
|
3663
3942
|
|
|
3664
3943
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
3665
3944
|
// See LICENSE in the project root for license information.
|
|
@@ -3680,7 +3959,7 @@ const DESIGN_TOKEN_BREAKPOINT_OPTIONS = [
|
|
|
3680
3959
|
*/
|
|
3681
3960
|
|
|
3682
3961
|
class AuroDropdownBib extends LitElement {
|
|
3683
|
-
|
|
3962
|
+
// not extending AuroElement because Bib needs only `shape` prop
|
|
3684
3963
|
constructor() {
|
|
3685
3964
|
super();
|
|
3686
3965
|
|
|
@@ -3690,11 +3969,14 @@ class AuroDropdownBib extends LitElement {
|
|
|
3690
3969
|
this._mobileBreakpointValue = undefined;
|
|
3691
3970
|
|
|
3692
3971
|
AuroLibraryRuntimeUtils$2$1.prototype.handleComponentTagRename(this, 'auro-dropdownbib');
|
|
3972
|
+
|
|
3973
|
+
this.shape = "rounded";
|
|
3974
|
+
this.matchWidth = false;
|
|
3693
3975
|
}
|
|
3694
3976
|
|
|
3695
3977
|
static get styles() {
|
|
3696
3978
|
return [
|
|
3697
|
-
styleCss$1
|
|
3979
|
+
styleCss$2$1,
|
|
3698
3980
|
colorCss$2$1,
|
|
3699
3981
|
tokensCss$1$1
|
|
3700
3982
|
];
|
|
@@ -3727,6 +4009,15 @@ class AuroDropdownBib extends LitElement {
|
|
|
3727
4009
|
reflect: true
|
|
3728
4010
|
},
|
|
3729
4011
|
|
|
4012
|
+
/**
|
|
4013
|
+
* If declared, the bib width will match the trigger width.
|
|
4014
|
+
* @private
|
|
4015
|
+
*/
|
|
4016
|
+
matchWidth: {
|
|
4017
|
+
type: Boolean,
|
|
4018
|
+
reflect: true
|
|
4019
|
+
},
|
|
4020
|
+
|
|
3730
4021
|
/**
|
|
3731
4022
|
* If declared, will apply border-radius to the bib.
|
|
3732
4023
|
*/
|
|
@@ -3740,6 +4031,11 @@ class AuroDropdownBib extends LitElement {
|
|
|
3740
4031
|
*/
|
|
3741
4032
|
bibTemplate: {
|
|
3742
4033
|
type: Object
|
|
4034
|
+
},
|
|
4035
|
+
|
|
4036
|
+
shape: {
|
|
4037
|
+
type: String,
|
|
4038
|
+
reflect: true
|
|
3743
4039
|
}
|
|
3744
4040
|
};
|
|
3745
4041
|
}
|
|
@@ -3819,8 +4115,16 @@ class AuroDropdownBib extends LitElement {
|
|
|
3819
4115
|
|
|
3820
4116
|
// function that renders the HTML and CSS into the scope of the component
|
|
3821
4117
|
render() {
|
|
4118
|
+
const classes = {
|
|
4119
|
+
container: true
|
|
4120
|
+
};
|
|
4121
|
+
|
|
4122
|
+
// Since this class does not inherit from AuroElement, we apply the shape-related class within the `render` function,
|
|
4123
|
+
// mimicking the class naming convention used in AuroElement.resetShapeClasses.
|
|
4124
|
+
classes[`shape-${this.shape}`] = true;
|
|
4125
|
+
|
|
3822
4126
|
return html`
|
|
3823
|
-
<div class="
|
|
4127
|
+
<div class="${classMap(classes)}" part="bibContainer">
|
|
3824
4128
|
<slot></slot>
|
|
3825
4129
|
</div>
|
|
3826
4130
|
`;
|
|
@@ -3829,23 +4133,25 @@ class AuroDropdownBib extends LitElement {
|
|
|
3829
4133
|
|
|
3830
4134
|
var dropdownVersion$1 = '3.0.0';
|
|
3831
4135
|
|
|
3832
|
-
var shapeSizeCss = css`.wrapper{overflow:hidden}.shape-classic-xl,.shape-classic-lg,.shape-classic-md,.shape-classic-sm,.shape-classic-xs{min-height:
|
|
4136
|
+
var shapeSizeCss = css`.wrapper{overflow:hidden}.shape-classic-xl,.shape-classic-lg,.shape-classic-md,.shape-classic-sm,.shape-classic-xs{min-height:56px;max-height:56px;border-style:solid;border-width:1px;border-radius:var(--ds-border-radius, 0.375rem)}.shape-classic-xl.simple,.shape-classic-lg.simple,.shape-classic-md.simple,.shape-classic-sm.simple,.shape-classic-xs.simple{border-width:0px;min-height:58px;max-height:58px;background-color:unset;box-shadow:none}.shape-classic-xl.thin,.shape-classic-lg.thin,.shape-classic-md.thin,.shape-classic-sm.thin,.shape-classic-xs.thin{border-width:1px;min-height:56px;max-height:56px;background-color:unset}.shape-classic-xl.parentBorder,.shape-classic-lg.parentBorder,.shape-classic-md.parentBorder,.shape-classic-sm.parentBorder,.shape-classic-xs.parentBorder{border:0;box-shadow:unset;min-height:54px;max-height:54px}.shape-snowflake-xl,.shape-snowflake-lg,.shape-snowflake-md,.shape-snowflake-sm,.shape-snowflake-xs{min-height:56px;max-height:56px;border-style:solid;border-width:2px;border-color:transparent;border-radius:30px}.shape-snowflake-xl.simple,.shape-snowflake-lg.simple,.shape-snowflake-md.simple,.shape-snowflake-sm.simple,.shape-snowflake-xs.simple{border-width:0px;min-height:60px;max-height:60px;background-color:unset;box-shadow:none}.shape-snowflake-xl.thin,.shape-snowflake-lg.thin,.shape-snowflake-md.thin,.shape-snowflake-sm.thin,.shape-snowflake-xs.thin{border-width:1px;min-height:58px;max-height:58px;background-color:unset}.shape-snowflake-xl.parentBorder,.shape-snowflake-lg.parentBorder,.shape-snowflake-md.parentBorder,.shape-snowflake-sm.parentBorder,.shape-snowflake-xs.parentBorder{border:0;box-shadow:unset;min-height:56px;max-height:56px}.shape-box-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-box-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-box-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-box-lg{min-height:52px;max-height:52px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-box-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-box-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-box-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-box-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-box-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-box-sm{min-height:32px;max-height:32px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-box-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-box-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-box-xs{min-height:20px;max-height:20px;border-style:solid;border-width:2px;border-color:transparent}.shape-box-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-box-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-box-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-rounded-lg{min-height:56px;max-height:56px;border-style:solid;border-width:2px;border-color:transparent;border-radius:6px}.shape-rounded-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-rounded-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-rounded-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-pill-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px}.shape-pill-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-left-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px 0 0 36px}.shape-pill-left-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-left-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-left-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-right-xl{min-height:68px;max-height:68px;border-style:solid;border-width:2px;border-color:transparent;border-radius:0 36px 36px 0}.shape-pill-right-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-right-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-right-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px}.shape-pill-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-left-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:36px 0 0 36px}.shape-pill-left-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-left-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-left-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-right-md{min-height:44px;max-height:44px;border-style:solid;border-width:2px;border-color:transparent;border-radius:0 36px 36px 0}.shape-pill-right-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-right-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-right-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}`;
|
|
3833
4137
|
|
|
3834
|
-
var colorCss$1$1 = css`:host .wrapper{border-color:var(--ds-auro-dropdown-trigger-border-color);background-color:var(--ds-auro-dropdown-trigger-background-color);color:var(--ds-auro-dropdown-trigger-text-color)}:host(:not([ondark])) .wrapper:focus,:host(:not([ondark])) .wrapper:
|
|
4138
|
+
var colorCss$1$1 = css`:host(:not([layout*=classic])){--ds-auro-dropdown-trigger-border-color: transparent}:host(:not([ondark])) .wrapper{border-color:var(--ds-auro-dropdown-trigger-border-color);background-color:var(--ds-auro-dropdown-trigger-background-color);color:var(--ds-auro-dropdown-trigger-text-color)}:host(:not([ondark])) .wrapper:focus-within,:host(:not([ondark])) .wrapper:active{--ds-auro-dropdown-trigger-border-color: var(--ds-advanced-color-state-focused, #01426a);--ds-auro-dropdown-trigger-outline-color: var(--ds-advanced-color-state-focused, #01426a)}:host(:not([onDark])[disabled]){--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0);--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0);--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-border-subtle, #dddddd)}:host(:not([ondark])[error]){--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-status-error, #e31f26)}:host([onDark]) .label{color:var(--ds-auro-dropdown-label-text-color)}:host([onDark]) .wrapper{border-color:var(--ds-auro-dropdown-trigger-border-color);background-color:var(--ds-auro-dropdown-trigger-background-color);color:var(--ds-auro-dropdown-trigger-text-color)}:host([onDark]) .wrapper:focus-within,:host([onDark]) .wrapper:active{--ds-auro-dropdown-trigger-border-color: var(--ds-advanced-color-state-focused-inverse, #ffffff);--ds-auro-dropdown-trigger-outline-color: var(--ds-advanced-color-state-focused-inverse, #ffffff)}:host([onDark][disabled]){--ds-auro-dropdown-trigger-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894);--ds-auro-dropdown-label-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894);--ds-auro-dropdown-trigger-container-color: var(--ds-advanced-color-shared-background-inverse-disabled, rgba(255, 255, 255, 0.1))}:host([ondark][error]){--ds-auro-dropdown-trigger-border-color: var(--ds-basic-color-status-error-subtle, #fbc6c6)}`;
|
|
3835
4139
|
|
|
3836
|
-
var
|
|
4140
|
+
var styleCss$1$2 = css`:host{position:relative;display:block}:host([open]){z-index:var(--depth-tooltip, 400)}.wrapper{display:flex;flex:1;flex-direction:row;align-items:center;justify-content:center;outline:none}.triggerContentWrapper{display:flex;overflow:hidden;width:100%;flex:1;align-items:center;justify-content:center;text-overflow:ellipsis;white-space:nowrap}:host([matchwidth]) #bibSizer{width:100%}`;
|
|
3837
4141
|
|
|
3838
|
-
var
|
|
4142
|
+
var classicColorCss = css``;
|
|
3839
4143
|
|
|
3840
|
-
var
|
|
4144
|
+
var classicLayoutCss = css`:host([layout*=classic]){position:relative;max-width:100%}:host([layout*=classic]) #bibSizer{position:absolute;z-index:-1;opacity:0;pointer-events:none}:host([layout*=classic]) label{transition:font-size .3s cubic-bezier(0.215, 0.61, 0.355, 1);white-space:normal}:host([layout*=classic]) .wrapper{display:flex;flex-direction:row;box-shadow:inset 0 0 0 1px var(--ds-auro-dropdown-trigger-outline-color)}@media(hover: hover){:host([layout*=classic]) .wrapper:hover{cursor:pointer}}:host([layout*=classic]) .triggerContentWrapper{overflow:hidden;flex:1;justify-content:start;text-overflow:ellipsis;white-space:nowrap}:host([layout*=classic]) #showStateIcon{display:flex;overflow:hidden;height:100%;align-items:center;padding-right:var(--ds-size-150, 0.75rem)}:host([layout*=classic]) #showStateIcon [auro-icon]{height:var(--ds-size-300, 1.5rem)}:host([layout*=classic]) #showStateIcon[data-expanded=true] [auro-icon]{transform:rotate(-180deg)}`;
|
|
3841
4145
|
|
|
3842
|
-
var
|
|
4146
|
+
var styleEmphasizedCss = css`.layout-emphasized .chevron,.layout-emphasized-left .chevron,.layout-emphasized-right .chevron{margin-right:var(--ds-size-300, 1.5rem)}:host([layout*=emphasized][shape*=pill]:not([layout*=right])) .leftIndent{width:calc(100% - var(--ds-size-300, 1.5rem));margin-left:var(--ds-size-300, 1.5rem)}:host([layout*=emphasized][shape*=pill]:not([layout*=left])) .rightIndent{width:calc(100% - var(--ds-size-300, 1.5rem));margin-right:var(--ds-size-300, 1.5rem)}:host([layout*=emphasized][shape*=pill]:not([layout*=left]):not([layout*=right])) .rightIndent{width:calc(100% - var(--ds-size-600, 3rem));margin-right:var(--ds-size-300, 1.5rem)}`;
|
|
3843
4147
|
|
|
3844
|
-
var
|
|
4148
|
+
var styleSnowflakeCss = css`:host([layout*=snowflake]) .leftIndent{width:calc(100% - var(--ds-size-600, 3rem));margin-left:var(--ds-size-300, 1.5rem)}:host([layout*=snowflake]) .rightIndent{width:calc(100% - var(--ds-size-600, 3rem));margin-right:var(--ds-size-300, 1.5rem)}.layout-snowflake .chevron,.layout-snowflake-left .chevron,.layout-snowflake-right .chevron{margin-right:var(--ds-size-300, 1.5rem)}`;
|
|
3845
4149
|
|
|
3846
|
-
var
|
|
4150
|
+
var colorCss$5 = css`:host([error]){--ds-auro-helptext-color: var(--ds-basic-color-status-error, #e31f26)}:host([onDark]){--ds-auro-helptext-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][error]){--ds-auro-helptext-color: var(--ds-basic-color-status-error-subtle, #fbc6c6)}.helptext-wrapper{color:var(--ds-auro-helptext-color)}`;
|
|
3847
4151
|
|
|
3848
|
-
var
|
|
4152
|
+
var styleCss$6 = css`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.63)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, 0.88)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}:host{position:relative;display:block}.helptext-wrapper{display:none}.helptext-wrapper[visible]{display:block}::slotted(*:not(:empty)){margin-top:var(--ds-size-50, 0.25rem);margin-bottom:0}::slotted(p){margin-block:0}`;
|
|
4153
|
+
|
|
4154
|
+
var tokensCss$4 = css`:host{--ds-auro-helptext-color: var(--ds-basic-color-texticon-muted, #676767)}`;
|
|
3849
4155
|
|
|
3850
4156
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
3851
4157
|
// See LICENSE in the project root for license information.
|
|
@@ -3854,7 +4160,7 @@ var tokensCss$3 = css`:host{--ds-auro-helptext-color: var(--ds-basic-color-texti
|
|
|
3854
4160
|
|
|
3855
4161
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
3856
4162
|
|
|
3857
|
-
let AuroLibraryRuntimeUtils$
|
|
4163
|
+
let AuroLibraryRuntimeUtils$4 = class AuroLibraryRuntimeUtils {
|
|
3858
4164
|
|
|
3859
4165
|
/* eslint-disable jsdoc/require-param */
|
|
3860
4166
|
|
|
@@ -3923,8 +4229,6 @@ let AuroLibraryRuntimeUtils$3 = class AuroLibraryRuntimeUtils {
|
|
|
3923
4229
|
|
|
3924
4230
|
/**
|
|
3925
4231
|
* Displays help text or error messages within form elements - Internal Use Only.
|
|
3926
|
-
*
|
|
3927
|
-
* @attr { Boolean } large - If declared, make font-size to 1rem(16px).
|
|
3928
4232
|
*/
|
|
3929
4233
|
let AuroHelpText$1 = class AuroHelpText extends LitElement {
|
|
3930
4234
|
|
|
@@ -3935,14 +4239,14 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
|
|
|
3935
4239
|
this.onDark = false;
|
|
3936
4240
|
this.hasTextContent = false;
|
|
3937
4241
|
|
|
3938
|
-
AuroLibraryRuntimeUtils$
|
|
4242
|
+
AuroLibraryRuntimeUtils$4.prototype.handleComponentTagRename(this, 'auro-helptext');
|
|
3939
4243
|
}
|
|
3940
4244
|
|
|
3941
4245
|
static get styles() {
|
|
3942
4246
|
return [
|
|
3943
|
-
colorCss$
|
|
3944
|
-
styleCss$
|
|
3945
|
-
tokensCss$
|
|
4247
|
+
colorCss$5,
|
|
4248
|
+
styleCss$6,
|
|
4249
|
+
tokensCss$4
|
|
3946
4250
|
];
|
|
3947
4251
|
}
|
|
3948
4252
|
|
|
@@ -3991,7 +4295,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
|
|
|
3991
4295
|
*
|
|
3992
4296
|
*/
|
|
3993
4297
|
static register(name = "auro-helptext") {
|
|
3994
|
-
AuroLibraryRuntimeUtils$
|
|
4298
|
+
AuroLibraryRuntimeUtils$4.prototype.registerComponent(name, AuroHelpText);
|
|
3995
4299
|
}
|
|
3996
4300
|
|
|
3997
4301
|
updated() {
|
|
@@ -4040,7 +4344,7 @@ let AuroHelpText$1 = class AuroHelpText extends LitElement {
|
|
|
4040
4344
|
// function that renders the HTML and CSS into the scope of the component
|
|
4041
4345
|
render() {
|
|
4042
4346
|
return html$1`
|
|
4043
|
-
<div class="helptext-wrapper" ?visible="${this.hasTextContent}">
|
|
4347
|
+
<div class="helptext-wrapper body-xs" ?visible="${this.hasTextContent}">
|
|
4044
4348
|
<slot @slotchange=${this.handleSlotChange}></slot>
|
|
4045
4349
|
</div>
|
|
4046
4350
|
`;
|
|
@@ -4084,19 +4388,22 @@ let AuroElement$2 = class AuroElement extends LitElement {
|
|
|
4084
4388
|
}
|
|
4085
4389
|
|
|
4086
4390
|
resetShapeClasses() {
|
|
4087
|
-
|
|
4088
|
-
const wrapper = this.shadowRoot.querySelector('.wrapper');
|
|
4391
|
+
const wrapper = this.shadowRoot.querySelector('.wrapper');
|
|
4089
4392
|
|
|
4090
|
-
|
|
4091
|
-
|
|
4092
|
-
|
|
4093
|
-
|
|
4094
|
-
|
|
4095
|
-
|
|
4393
|
+
if (wrapper) {
|
|
4394
|
+
wrapper.classList.forEach((className) => {
|
|
4395
|
+
if (className.startsWith('shape-')) {
|
|
4396
|
+
wrapper.classList.remove(className);
|
|
4397
|
+
}
|
|
4398
|
+
});
|
|
4096
4399
|
|
|
4400
|
+
if (this.shape && this.size) {
|
|
4097
4401
|
wrapper.classList.add(`shape-${this.shape.toLowerCase()}-${this.size.toLowerCase()}`);
|
|
4402
|
+
} else {
|
|
4403
|
+
wrapper.classList.add('shape-none');
|
|
4098
4404
|
}
|
|
4099
4405
|
}
|
|
4406
|
+
|
|
4100
4407
|
}
|
|
4101
4408
|
|
|
4102
4409
|
resetLayoutClasses() {
|
|
@@ -4145,14 +4452,14 @@ let AuroElement$2 = class AuroElement extends LitElement {
|
|
|
4145
4452
|
// See LICENSE in the project root for license information.
|
|
4146
4453
|
|
|
4147
4454
|
|
|
4148
|
-
|
|
4149
|
-
|
|
4455
|
+
|
|
4456
|
+
/*
|
|
4150
4457
|
* @slot - Default slot for the popover content.
|
|
4151
|
-
* @slot label - Defines the content of the label.
|
|
4152
4458
|
* @slot helpText - Defines the content of the helpText.
|
|
4153
4459
|
* @slot trigger - Defines the content of the trigger.
|
|
4154
4460
|
* @csspart trigger - The trigger content container.
|
|
4155
4461
|
* @csspart chevron - The collapsed/expanded state icon container.
|
|
4462
|
+
* @csspart size - The size of the dropdown bib. (height, width, maxHeight, maxWidth only)
|
|
4156
4463
|
* @csspart helpText - The helpText content container.
|
|
4157
4464
|
* @event auroDropdown-triggerClick - Notifies that the trigger has been clicked.
|
|
4158
4465
|
* @event auroDropdown-toggled - Notifies that the visibility of the dropdown bib has changed.
|
|
@@ -4167,23 +4474,25 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4167
4474
|
this.matchWidth = false;
|
|
4168
4475
|
this.noHideOnThisFocusLoss = false;
|
|
4169
4476
|
|
|
4170
|
-
this.errorMessage =
|
|
4477
|
+
this.errorMessage = undefined; // TODO - check with Doug if there is still more to do here
|
|
4171
4478
|
|
|
4172
4479
|
// Layout Config
|
|
4173
|
-
this.layout =
|
|
4174
|
-
this.shape =
|
|
4175
|
-
this.size =
|
|
4480
|
+
this.layout = undefined;
|
|
4481
|
+
this.shape = undefined;
|
|
4482
|
+
this.size = undefined;
|
|
4483
|
+
|
|
4176
4484
|
this.parentBorder = false;
|
|
4177
4485
|
|
|
4178
|
-
|
|
4179
|
-
|
|
4486
|
+
/** @private */
|
|
4487
|
+
this.handleDropdownToggle = this.handleDropdownToggle.bind(this);
|
|
4180
4488
|
|
|
4181
|
-
|
|
4182
|
-
return {
|
|
4183
|
-
// 'withValue': this.value && this.value.length > 0
|
|
4184
|
-
};
|
|
4489
|
+
this.privateDefaults();
|
|
4185
4490
|
}
|
|
4186
4491
|
|
|
4492
|
+
/**
|
|
4493
|
+
* @private
|
|
4494
|
+
* @returns {object} Class definition for the wrapper element.
|
|
4495
|
+
*/
|
|
4187
4496
|
get commonWrapperClasses() {
|
|
4188
4497
|
return {
|
|
4189
4498
|
'trigger': true,
|
|
@@ -4201,13 +4510,10 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4201
4510
|
privateDefaults() {
|
|
4202
4511
|
this.chevron = false;
|
|
4203
4512
|
this.disabled = false;
|
|
4513
|
+
this.disableFocusTrap = false;
|
|
4204
4514
|
this.error = false;
|
|
4205
|
-
this.inset = false;
|
|
4206
|
-
this.rounded = false;
|
|
4207
4515
|
this.tabIndex = 0;
|
|
4208
4516
|
this.noToggle = false;
|
|
4209
|
-
this.a11yAutocomplete = 'none';
|
|
4210
|
-
this.labeled = true;
|
|
4211
4517
|
this.a11yRole = 'button';
|
|
4212
4518
|
this.onDark = false;
|
|
4213
4519
|
this.showTriggerBorders = true;
|
|
@@ -4303,6 +4609,18 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4303
4609
|
this.floater.showBib();
|
|
4304
4610
|
}
|
|
4305
4611
|
|
|
4612
|
+
/**
|
|
4613
|
+
* When bib is open, focus on the first element inside of bib.
|
|
4614
|
+
* If not, trigger element will get focus.
|
|
4615
|
+
*/
|
|
4616
|
+
focus() {
|
|
4617
|
+
if (this.isPopoverVisible && this.focusTrap) {
|
|
4618
|
+
this.focusTrap.focusFirstElement();
|
|
4619
|
+
} else {
|
|
4620
|
+
this.trigger.focus();
|
|
4621
|
+
}
|
|
4622
|
+
}
|
|
4623
|
+
|
|
4306
4624
|
// function to define props used within the scope of this component
|
|
4307
4625
|
static get properties() {
|
|
4308
4626
|
return {
|
|
@@ -4316,6 +4634,15 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4316
4634
|
reflect: true
|
|
4317
4635
|
},
|
|
4318
4636
|
|
|
4637
|
+
/**
|
|
4638
|
+
* If declared, the dropdown will only show by calling the API .show() public method.
|
|
4639
|
+
* @default false
|
|
4640
|
+
*/
|
|
4641
|
+
disableEventShow: {
|
|
4642
|
+
type: Boolean,
|
|
4643
|
+
reflect: true
|
|
4644
|
+
},
|
|
4645
|
+
|
|
4319
4646
|
/**
|
|
4320
4647
|
* If declared, applies a border around the trigger slot.
|
|
4321
4648
|
*/
|
|
@@ -4334,17 +4661,17 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4334
4661
|
},
|
|
4335
4662
|
|
|
4336
4663
|
/**
|
|
4337
|
-
* If declared, the dropdown
|
|
4664
|
+
* If declared, the dropdown is not interactive.
|
|
4338
4665
|
*/
|
|
4339
|
-
|
|
4666
|
+
disabled: {
|
|
4340
4667
|
type: Boolean,
|
|
4341
4668
|
reflect: true
|
|
4342
4669
|
},
|
|
4343
4670
|
|
|
4344
4671
|
/**
|
|
4345
|
-
* If declared, the
|
|
4672
|
+
* If declared, the focus trap inside of bib will be turned off.
|
|
4346
4673
|
*/
|
|
4347
|
-
|
|
4674
|
+
disableFocusTrap: {
|
|
4348
4675
|
type: Boolean,
|
|
4349
4676
|
reflect: true
|
|
4350
4677
|
},
|
|
@@ -4389,27 +4716,13 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4389
4716
|
reflect: true
|
|
4390
4717
|
},
|
|
4391
4718
|
|
|
4392
|
-
/**
|
|
4393
|
-
* Makes the trigger to be full width of its parent container.
|
|
4394
|
-
*/
|
|
4395
|
-
fluid: {
|
|
4396
|
-
type: Boolean,
|
|
4397
|
-
reflect: true
|
|
4398
|
-
},
|
|
4399
|
-
|
|
4400
|
-
/**
|
|
4401
|
-
* If declared, will apply padding around trigger slot content.
|
|
4402
|
-
*/
|
|
4403
|
-
inset: {
|
|
4404
|
-
type: Boolean,
|
|
4405
|
-
reflect: true
|
|
4406
|
-
},
|
|
4407
|
-
|
|
4408
4719
|
/**
|
|
4409
4720
|
* If true, the dropdown bib is displayed.
|
|
4410
4721
|
*/
|
|
4411
4722
|
isPopoverVisible: {
|
|
4412
|
-
type: Boolean
|
|
4723
|
+
type: Boolean,
|
|
4724
|
+
reflect: true,
|
|
4725
|
+
attribute: 'open'
|
|
4413
4726
|
},
|
|
4414
4727
|
|
|
4415
4728
|
/**
|
|
@@ -4448,15 +4761,6 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4448
4761
|
reflect: true
|
|
4449
4762
|
},
|
|
4450
4763
|
|
|
4451
|
-
/**
|
|
4452
|
-
* Defines if there is a label preset.
|
|
4453
|
-
* @private
|
|
4454
|
-
*/
|
|
4455
|
-
labeled: {
|
|
4456
|
-
type: Boolean,
|
|
4457
|
-
reflect: true
|
|
4458
|
-
},
|
|
4459
|
-
|
|
4460
4764
|
/**
|
|
4461
4765
|
* Defines if the trigger should size based on the parent element providing the border UI.
|
|
4462
4766
|
* @private
|
|
@@ -4517,6 +4821,9 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4517
4821
|
reflect: true
|
|
4518
4822
|
},
|
|
4519
4823
|
|
|
4824
|
+
/**
|
|
4825
|
+
* If declared, and a function is set, that function will execute when the slot content is updated.
|
|
4826
|
+
*/
|
|
4520
4827
|
onSlotChange: {
|
|
4521
4828
|
type: Function,
|
|
4522
4829
|
reflect: false
|
|
@@ -4531,14 +4838,6 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4531
4838
|
reflect: true
|
|
4532
4839
|
},
|
|
4533
4840
|
|
|
4534
|
-
/**
|
|
4535
|
-
* If declared, will apply border-radius to trigger and default slots.
|
|
4536
|
-
*/
|
|
4537
|
-
rounded: {
|
|
4538
|
-
type: Boolean,
|
|
4539
|
-
reflect: true
|
|
4540
|
-
},
|
|
4541
|
-
|
|
4542
4841
|
/**
|
|
4543
4842
|
* @private
|
|
4544
4843
|
*/
|
|
@@ -4553,22 +4852,15 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4553
4852
|
type: String || undefined,
|
|
4554
4853
|
attribute: false,
|
|
4555
4854
|
reflect: false
|
|
4556
|
-
},
|
|
4557
|
-
|
|
4558
|
-
/**
|
|
4559
|
-
* The value for the aria-autocomplete attribute of the trigger element.
|
|
4560
|
-
*/
|
|
4561
|
-
a11yAutocomplete: {
|
|
4562
|
-
type: String,
|
|
4563
|
-
attribute: false,
|
|
4564
4855
|
}
|
|
4565
4856
|
};
|
|
4566
4857
|
}
|
|
4567
4858
|
|
|
4568
4859
|
static get styles() {
|
|
4569
4860
|
return [
|
|
4570
|
-
|
|
4861
|
+
styleCss$1$2,
|
|
4571
4862
|
tokensCss$1$1,
|
|
4863
|
+
colorCss$1$1,
|
|
4572
4864
|
|
|
4573
4865
|
// default layout
|
|
4574
4866
|
classicColorCss,
|
|
@@ -4630,13 +4922,27 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4630
4922
|
if (changedProperties.size === 0 || changedProperties.has('isPopoverVisible')) {
|
|
4631
4923
|
this.handleTriggerContentSlotChange();
|
|
4632
4924
|
}
|
|
4925
|
+
}
|
|
4633
4926
|
|
|
4927
|
+
/**
|
|
4928
|
+
* Handles the custom event `auroDropdown-toggled` to update the visibility of the dropdown bib.
|
|
4929
|
+
* @private
|
|
4930
|
+
* @param {CustomEvent} event - The custom event that contains the dropdown toggle information.
|
|
4931
|
+
*/
|
|
4932
|
+
handleDropdownToggle(event) {
|
|
4933
|
+
this.updateFocusTrap();
|
|
4934
|
+
this.isPopoverVisible = event.detail.expanded;
|
|
4935
|
+
const eventType = event.detail.eventType || "unknown";
|
|
4936
|
+
if (!this.isPopoverVisible && this.hasFocus && eventType === "keydown") {
|
|
4937
|
+
this.trigger.focus();
|
|
4938
|
+
}
|
|
4634
4939
|
}
|
|
4635
4940
|
|
|
4636
4941
|
firstUpdated() {
|
|
4637
4942
|
|
|
4638
4943
|
// Configure the floater to, this will generate the ID for the bib
|
|
4639
4944
|
this.floater.configure(this, 'auroDropdown');
|
|
4945
|
+
this.addEventListener('auroDropdown-toggled', this.handleDropdownToggle);
|
|
4640
4946
|
|
|
4641
4947
|
/**
|
|
4642
4948
|
* @description Let subscribers know that the dropdown ID ha been generated and added.
|
|
@@ -4654,6 +4960,13 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4654
4960
|
|
|
4655
4961
|
// Add the tag name as an attribute if it is different than the component name
|
|
4656
4962
|
this.runtimeUtils.handleComponentTagRename(this, 'auro-dropdown');
|
|
4963
|
+
|
|
4964
|
+
this.trigger.addEventListener('click', () => {
|
|
4965
|
+
this.dispatchEvent(new CustomEvent('auroDropdown-triggerClick', {
|
|
4966
|
+
bubbles: true,
|
|
4967
|
+
composed: true
|
|
4968
|
+
}));
|
|
4969
|
+
});
|
|
4657
4970
|
}
|
|
4658
4971
|
|
|
4659
4972
|
/**
|
|
@@ -4696,6 +5009,27 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4696
5009
|
this.hasFocus = true;
|
|
4697
5010
|
}
|
|
4698
5011
|
|
|
5012
|
+
/**
|
|
5013
|
+
* @private
|
|
5014
|
+
*/
|
|
5015
|
+
updateFocusTrap() {
|
|
5016
|
+
// If the dropdown is open, create a focus trap and focus the first element
|
|
5017
|
+
if (this.isPopoverVisible && !this.disableFocusTrap) {
|
|
5018
|
+
this.focusTrap = new FocusTrap(this.bibContent);
|
|
5019
|
+
this.focusTrap.focusFirstElement();
|
|
5020
|
+
return;
|
|
5021
|
+
}
|
|
5022
|
+
|
|
5023
|
+
// Guard Clause: Ensure there is a focus trap currently active before continuing
|
|
5024
|
+
if (!this.focusTrap) {
|
|
5025
|
+
return;
|
|
5026
|
+
}
|
|
5027
|
+
|
|
5028
|
+
// If the dropdown is not open, disconnect the focus trap if it exists
|
|
5029
|
+
this.focusTrap.disconnect();
|
|
5030
|
+
this.focusTrap = undefined;
|
|
5031
|
+
}
|
|
5032
|
+
|
|
4699
5033
|
/**
|
|
4700
5034
|
* Function to support @focusout event.
|
|
4701
5035
|
* @private
|
|
@@ -4705,64 +5039,6 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4705
5039
|
this.hasFocus = false;
|
|
4706
5040
|
}
|
|
4707
5041
|
|
|
4708
|
-
/**
|
|
4709
|
-
* Determines if the element or any children are focusable.
|
|
4710
|
-
* @private
|
|
4711
|
-
* @param {HTMLElement} element - Element to check.
|
|
4712
|
-
* @returns {Boolean} - True if the element or any children are focusable.
|
|
4713
|
-
*/
|
|
4714
|
-
containsFocusableElement(element) {
|
|
4715
|
-
this.showTriggerBorders = true;
|
|
4716
|
-
|
|
4717
|
-
const nodes = [
|
|
4718
|
-
element,
|
|
4719
|
-
...element.children
|
|
4720
|
-
];
|
|
4721
|
-
|
|
4722
|
-
const focusableElements = [
|
|
4723
|
-
'a',
|
|
4724
|
-
'auro-hyperlink',
|
|
4725
|
-
'button',
|
|
4726
|
-
'auro-button',
|
|
4727
|
-
'input',
|
|
4728
|
-
'auro-input',
|
|
4729
|
-
];
|
|
4730
|
-
|
|
4731
|
-
const focusableElementsThatNeedBorders = ['auro-input'];
|
|
4732
|
-
|
|
4733
|
-
const result = nodes.some((node) => {
|
|
4734
|
-
const tagName = node.tagName.toLowerCase();
|
|
4735
|
-
|
|
4736
|
-
if (node.tabIndex > -1) {
|
|
4737
|
-
return true;
|
|
4738
|
-
}
|
|
4739
|
-
|
|
4740
|
-
if (focusableElements.includes(tagName)) {
|
|
4741
|
-
if ((tagName === 'a' || tagName === 'auro-hyperlink' || node.hasAttribute('auro-hyperlink')) && node.hasAttribute('href')) {
|
|
4742
|
-
return true;
|
|
4743
|
-
}
|
|
4744
|
-
if (!node.hasAttribute('disabled')) {
|
|
4745
|
-
return true;
|
|
4746
|
-
}
|
|
4747
|
-
}
|
|
4748
|
-
|
|
4749
|
-
if (focusableElements.some((focusableElement) => focusableElement.startsWith('auro-') && (focusableElement === tagName || node.hasAttribute(focusableElement)))) {
|
|
4750
|
-
return true;
|
|
4751
|
-
}
|
|
4752
|
-
|
|
4753
|
-
return false;
|
|
4754
|
-
});
|
|
4755
|
-
|
|
4756
|
-
if (result) {
|
|
4757
|
-
this.showTriggerBorders = !nodes.some((node) => {
|
|
4758
|
-
const tagName = node.tagName.toLowerCase();
|
|
4759
|
-
return focusableElements.includes(tagName) && !focusableElementsThatNeedBorders.includes(tagName);
|
|
4760
|
-
});
|
|
4761
|
-
}
|
|
4762
|
-
|
|
4763
|
-
return result;
|
|
4764
|
-
}
|
|
4765
|
-
|
|
4766
5042
|
/**
|
|
4767
5043
|
* Creates and dispatches a duplicate focus event on the trigger element.
|
|
4768
5044
|
* @private
|
|
@@ -4856,14 +5132,13 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4856
5132
|
* @returns {void}
|
|
4857
5133
|
*/
|
|
4858
5134
|
handleTriggerContentSlotChange(event) {
|
|
4859
|
-
|
|
4860
5135
|
this.floater.handleTriggerTabIndex();
|
|
4861
5136
|
|
|
4862
5137
|
// Get the trigger
|
|
4863
5138
|
const trigger = this.shadowRoot.querySelector('#trigger');
|
|
4864
5139
|
|
|
4865
5140
|
// Get the trigger slot
|
|
4866
|
-
const triggerSlot = this.shadowRoot.querySelector('.
|
|
5141
|
+
const triggerSlot = this.shadowRoot.querySelector('.triggerContentWrapper slot');
|
|
4867
5142
|
|
|
4868
5143
|
// If there's a trigger slot
|
|
4869
5144
|
if (triggerSlot) {
|
|
@@ -4875,7 +5150,7 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4875
5150
|
if (triggerContentNodes) {
|
|
4876
5151
|
|
|
4877
5152
|
// See if any of them are focusable elements
|
|
4878
|
-
this.triggerContentFocusable = triggerContentNodes.some((node) =>
|
|
5153
|
+
this.triggerContentFocusable = triggerContentNodes.some((node) => getFocusableElements(node).length > 0);
|
|
4879
5154
|
|
|
4880
5155
|
// If any of them are focusable elements
|
|
4881
5156
|
if (this.triggerContentFocusable) {
|
|
@@ -4935,29 +5210,6 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4935
5210
|
}
|
|
4936
5211
|
}
|
|
4937
5212
|
|
|
4938
|
-
/**
|
|
4939
|
-
* @private
|
|
4940
|
-
* @method handleLabelSlotChange
|
|
4941
|
-
* @param {event} event - The event object representing the slot change.
|
|
4942
|
-
* @description Handles the slot change event for the label slot.
|
|
4943
|
-
*/
|
|
4944
|
-
handleLabelSlotChange (event) {
|
|
4945
|
-
|
|
4946
|
-
// Get the nodes from the event
|
|
4947
|
-
const nodes = event.target.assignedNodes();
|
|
4948
|
-
|
|
4949
|
-
// Guard clause for no nodes
|
|
4950
|
-
if (!nodes) {
|
|
4951
|
-
return;
|
|
4952
|
-
}
|
|
4953
|
-
|
|
4954
|
-
// Convert the nodes to a measurable array so we can get the length
|
|
4955
|
-
const nodesArr = Array.from(nodes);
|
|
4956
|
-
|
|
4957
|
-
// If the nodes array has a length, the dropdown is labeled
|
|
4958
|
-
this.labeled = nodesArr.length > 0;
|
|
4959
|
-
}
|
|
4960
|
-
|
|
4961
5213
|
/**
|
|
4962
5214
|
* Returns HTML for the common portion of the layouts.
|
|
4963
5215
|
* @private
|
|
@@ -4970,24 +5222,19 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
4970
5222
|
<div
|
|
4971
5223
|
id="trigger"
|
|
4972
5224
|
class="${classMap(this.commonWrapperClasses)}" part="wrapper"
|
|
4973
|
-
tabindex="${this.tabIndex}"
|
|
5225
|
+
tabindex="${ifDefined(this.triggerContentFocusable ? undefined : this.tabIndex)}"
|
|
4974
5226
|
role="${ifDefined(this.triggerContentFocusable ? undefined : this.a11yRole)}"
|
|
4975
|
-
aria-expanded="${ifDefined(this.triggerContentFocusable ? undefined : this.isPopoverVisible)}"
|
|
4976
|
-
aria-controls="${ifDefined(this.triggerContentFocusable ? undefined : this.dropdownId)}"
|
|
5227
|
+
aria-expanded="${ifDefined(this.a11yRole === 'button' || this.triggerContentFocusable ? undefined : this.isPopoverVisible)}"
|
|
5228
|
+
aria-controls="${ifDefined(this.a11yRole === 'button' || this.triggerContentFocusable ? undefined : this.dropdownId)}"
|
|
4977
5229
|
aria-labelledby="${ifDefined(this.triggerContentFocusable ? undefined : 'triggerLabel')}"
|
|
4978
5230
|
@focusin="${this.handleFocusin}"
|
|
4979
5231
|
@blur="${this.handleFocusOut}">
|
|
4980
|
-
<div class="triggerContentWrapper">
|
|
4981
|
-
<
|
|
4982
|
-
|
|
4983
|
-
|
|
4984
|
-
<div class="triggerContent">
|
|
4985
|
-
<slot
|
|
4986
|
-
name="trigger"
|
|
4987
|
-
@slotchange="${this.handleTriggerContentSlotChange}"></slot>
|
|
4988
|
-
</div>
|
|
5232
|
+
<div class="triggerContentWrapper" id="triggerLabel">
|
|
5233
|
+
<slot
|
|
5234
|
+
name="trigger"
|
|
5235
|
+
@slotchange="${this.handleTriggerContentSlotChange}"></slot>
|
|
4989
5236
|
</div>
|
|
4990
|
-
${this.chevron
|
|
5237
|
+
${this.chevron ? html`
|
|
4991
5238
|
<div
|
|
4992
5239
|
id="showStateIcon"
|
|
4993
5240
|
class="chevron"
|
|
@@ -5008,11 +5255,9 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5008
5255
|
<div id="bibSizer" part="size"></div>
|
|
5009
5256
|
<${this.dropdownBibTag}
|
|
5010
5257
|
id="bib"
|
|
5258
|
+
shape="${this.shape}"
|
|
5011
5259
|
?data-show="${this.isPopoverVisible}"
|
|
5012
|
-
?isfullscreen="${this.isBibFullscreen}"
|
|
5013
|
-
?common="${this.common}"
|
|
5014
|
-
?rounded="${this.common || this.rounded}"
|
|
5015
|
-
?inset="${this.common || this.inset}">
|
|
5260
|
+
?isfullscreen="${this.isBibFullscreen}">
|
|
5016
5261
|
<div class="slotContent">
|
|
5017
5262
|
<slot @slotchange="${this.handleDefaultSlot}"></slot>
|
|
5018
5263
|
</div>
|
|
@@ -5027,245 +5272,1290 @@ class AuroDropdown extends AuroElement$2 {
|
|
|
5027
5272
|
* @returns {html} - Returns HTML for the classic layout.
|
|
5028
5273
|
*/
|
|
5029
5274
|
renderLayoutClassic() {
|
|
5275
|
+
// TODO: check with Doug why this was never used?
|
|
5276
|
+
const helpTextClasses = {
|
|
5277
|
+
'helpText': true
|
|
5278
|
+
};
|
|
5030
5279
|
|
|
5031
5280
|
return html`
|
|
5032
|
-
|
|
5033
|
-
|
|
5034
|
-
|
|
5035
|
-
|
|
5036
|
-
|
|
5037
|
-
|
|
5038
|
-
|
|
5039
|
-
|
|
5040
|
-
|
|
5041
|
-
|
|
5042
|
-
|
|
5043
|
-
|
|
5044
|
-
|
|
5045
|
-
|
|
5046
|
-
|
|
5047
|
-
|
|
5048
|
-
|
|
5049
|
-
|
|
5050
|
-
|
|
5051
|
-
|
|
5052
|
-
|
|
5053
|
-
|
|
5054
|
-
|
|
5055
|
-
|
|
5056
|
-
|
|
5057
|
-
|
|
5058
|
-
|
|
5059
|
-
|
|
5060
|
-
|
|
5061
|
-
|
|
5062
|
-
|
|
5063
|
-
|
|
5064
|
-
|
|
5065
|
-
|
|
5066
|
-
|
|
5067
|
-
</div>
|
|
5068
|
-
<${this.helpTextTag} part="helpText" ?onDark=${this.onDark} ?error="${this.error}">
|
|
5069
|
-
<slot name="helpText"></slot>
|
|
5070
|
-
</${this.helpTextTag}>
|
|
5071
|
-
|
|
5072
|
-
<div id="bibSizer" part="size"></div>
|
|
5073
|
-
<${this.dropdownBibTag}
|
|
5074
|
-
id="bib"
|
|
5075
|
-
?data-show="${this.isPopoverVisible}"
|
|
5076
|
-
?isfullscreen="${this.isBibFullscreen}"
|
|
5077
|
-
?common="${this.common}"
|
|
5078
|
-
?rounded="${this.common || this.rounded}"
|
|
5079
|
-
?inset="${this.common || this.inset}"
|
|
5080
|
-
>
|
|
5081
|
-
<div class="slotContent">
|
|
5082
|
-
<slot @slotchange="${this.handleDefaultSlot}"></slot>
|
|
5083
|
-
</div>
|
|
5084
|
-
</${this.dropdownBibTag}>
|
|
5085
|
-
</div>
|
|
5281
|
+
${this.renderBasicHtml(helpTextClasses)}
|
|
5282
|
+
`;
|
|
5283
|
+
}
|
|
5284
|
+
|
|
5285
|
+
/**
|
|
5286
|
+
* Returns HTML for the snowflake layout. Does not support type="*".
|
|
5287
|
+
* @private
|
|
5288
|
+
* @returns {html} - Returns HTML for the snowflake layout.
|
|
5289
|
+
*/
|
|
5290
|
+
renderLayoutSnowflake() {
|
|
5291
|
+
const helpTextClasses = {
|
|
5292
|
+
'helpText': true,
|
|
5293
|
+
'leftIndent': true,
|
|
5294
|
+
'rightIndent': true
|
|
5295
|
+
};
|
|
5296
|
+
|
|
5297
|
+
return html`
|
|
5298
|
+
${this.renderBasicHtml(helpTextClasses)}
|
|
5299
|
+
`;
|
|
5300
|
+
}
|
|
5301
|
+
|
|
5302
|
+
/**
|
|
5303
|
+
* Returns HTML for the emphasized layout. Does not support type="*".
|
|
5304
|
+
* @private
|
|
5305
|
+
* @returns {html} - Returns HTML for the emphasized layout.
|
|
5306
|
+
*/
|
|
5307
|
+
renderLayoutEmphasized() {
|
|
5308
|
+
const helpTextClasses = {
|
|
5309
|
+
'helpText': true,
|
|
5310
|
+
'leftIndent': this.shape.toLowerCase().includes('pill') && !this.shape.toLowerCase().includes('right'),
|
|
5311
|
+
'rightIndent': this.shape.toLowerCase().includes('pill') && !this.shape.toLowerCase().includes('left')
|
|
5312
|
+
};
|
|
5313
|
+
|
|
5314
|
+
return html`
|
|
5315
|
+
${this.renderBasicHtml(helpTextClasses)}
|
|
5086
5316
|
`;
|
|
5087
5317
|
}
|
|
5088
5318
|
|
|
5089
5319
|
/**
|
|
5090
|
-
*
|
|
5091
|
-
* @private
|
|
5092
|
-
* @
|
|
5320
|
+
* Logic to determine the layout of the component.
|
|
5321
|
+
* @private
|
|
5322
|
+
* @param {string} [ForcedLayout] - Used to force a specific layout, pass in the layout name to use.
|
|
5323
|
+
* @returns {HTMLCollection} - Returns the HTML for the layout.
|
|
5324
|
+
*/
|
|
5325
|
+
renderLayout(ForcedLayout) {
|
|
5326
|
+
const layout = ForcedLayout || this.layout;
|
|
5327
|
+
|
|
5328
|
+
switch (layout) {
|
|
5329
|
+
case 'emphasized':
|
|
5330
|
+
return this.renderLayoutEmphasized();
|
|
5331
|
+
case 'emphasized-left':
|
|
5332
|
+
return this.renderLayoutEmphasized();
|
|
5333
|
+
case 'emphasized-right':
|
|
5334
|
+
return this.renderLayoutEmphasized();
|
|
5335
|
+
case 'snowflake':
|
|
5336
|
+
return this.renderLayoutSnowflake();
|
|
5337
|
+
case 'snowflake-left':
|
|
5338
|
+
return this.renderLayoutSnowflake();
|
|
5339
|
+
case 'snowflake-right':
|
|
5340
|
+
return this.renderLayoutSnowflake();
|
|
5341
|
+
default:
|
|
5342
|
+
return this.renderLayoutClassic();
|
|
5343
|
+
}
|
|
5344
|
+
}
|
|
5345
|
+
}
|
|
5346
|
+
|
|
5347
|
+
var dropdownVersion = '3.0.0';
|
|
5348
|
+
|
|
5349
|
+
var colorCss$3 = css`#headerContainer{box-shadow:var(--ds-auro-dropdownbib-header-boxshadow-color)}#footerContainer{background-color:var(--ds-auro-dropdownbib-footer-container-color)}`;
|
|
5350
|
+
|
|
5351
|
+
var styleCss$4 = css`#bibTemplate{display:flex;overflow:hidden;height:100%;max-height:100%;flex-direction:column}#headerContainer{display:flex;flex-direction:column;padding:var(--ds-size-200, 1rem);padding-top:var(--ds-size-400, 2rem);padding-bottom:0}#headerContainer .titleRow{display:flex;flex-direction:row;justify-content:space-between;gap:var(--ds-size-100, 0.5rem)}#headerContainer .header{max-width:calc(100vw - var(--ds-size-900, 4.5rem));padding-top:var(--ds-size-200, 1rem)}#headerContainer .subheader{width:100%}#closeButton [auro-icon]{--ds-auro-icon-size: var(--ds-size-500, 2.5rem)}#bodyContainer{position:relative;overflow:auto;flex:1 1 100%}:host([isfullscreen]) #bibTemplate{max-height:100dvh}:host([isfullscreen]) #bodyContainer{margin-top:var(--ds-size-100, 0.5rem)}#footerContainer{position:absolute;right:0;bottom:0;left:0;padding:var(--ds-size-200, 1rem)}`;
|
|
5352
|
+
|
|
5353
|
+
var tokenCss = css`:host{--ds-auro-dropdownbib-header-boxshadow-color: var(--ds-elevation-200, 0px 0px 10px rgba(0, 0, 0, 0.15));--ds-auro-dropdownbib-footer-container-color: var(--ds-basic-color-surface-default, #ffffff)}`;
|
|
5354
|
+
|
|
5355
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5356
|
+
// See LICENSE in the project root for license information.
|
|
5357
|
+
|
|
5358
|
+
// ---------------------------------------------------------------------
|
|
5359
|
+
|
|
5360
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
5361
|
+
|
|
5362
|
+
let AuroLibraryRuntimeUtils$2 = class AuroLibraryRuntimeUtils {
|
|
5363
|
+
|
|
5364
|
+
/* eslint-disable jsdoc/require-param */
|
|
5365
|
+
|
|
5366
|
+
/**
|
|
5367
|
+
* This will register a new custom element with the browser.
|
|
5368
|
+
* @param {String} name - The name of the custom element.
|
|
5369
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
5370
|
+
* @returns {void}
|
|
5371
|
+
*/
|
|
5372
|
+
registerComponent(name, componentClass) {
|
|
5373
|
+
if (!customElements.get(name)) {
|
|
5374
|
+
customElements.define(name, class extends componentClass {});
|
|
5375
|
+
}
|
|
5376
|
+
}
|
|
5377
|
+
|
|
5378
|
+
/**
|
|
5379
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
5380
|
+
* @returns {void}
|
|
5381
|
+
*/
|
|
5382
|
+
closestElement(
|
|
5383
|
+
selector, // selector like in .closest()
|
|
5384
|
+
base = this, // extra functionality to skip a parent
|
|
5385
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
5386
|
+
!el || el === document || el === window
|
|
5387
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
5388
|
+
: found
|
|
5389
|
+
? found // found a selector INside this element
|
|
5390
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
5391
|
+
) {
|
|
5392
|
+
return __Closest(base);
|
|
5393
|
+
}
|
|
5394
|
+
/* eslint-enable jsdoc/require-param */
|
|
5395
|
+
|
|
5396
|
+
/**
|
|
5397
|
+
* If the element passed is registered with a different tag name than what is passed in, the tag name is added as an attribute to the element.
|
|
5398
|
+
* @param {Object} elem - The element to check.
|
|
5399
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
5400
|
+
* @returns {void}
|
|
5401
|
+
*/
|
|
5402
|
+
handleComponentTagRename(elem, tagName) {
|
|
5403
|
+
const tag = tagName.toLowerCase();
|
|
5404
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
5405
|
+
|
|
5406
|
+
if (elemTag !== tag) {
|
|
5407
|
+
elem.setAttribute(tag, true);
|
|
5408
|
+
}
|
|
5409
|
+
}
|
|
5410
|
+
|
|
5411
|
+
/**
|
|
5412
|
+
* Validates if an element is a specific Auro component.
|
|
5413
|
+
* @param {Object} elem - The element to validate.
|
|
5414
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
5415
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
5416
|
+
*/
|
|
5417
|
+
elementMatch(elem, tagName) {
|
|
5418
|
+
const tag = tagName.toLowerCase();
|
|
5419
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
5420
|
+
|
|
5421
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
5422
|
+
}
|
|
5423
|
+
};
|
|
5424
|
+
|
|
5425
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5426
|
+
// See LICENSE in the project root for license information.
|
|
5427
|
+
|
|
5428
|
+
|
|
5429
|
+
class AuroDependencyVersioning {
|
|
5430
|
+
|
|
5431
|
+
/**
|
|
5432
|
+
* Generates a unique string to be used for child auro element naming.
|
|
5433
|
+
* @private
|
|
5434
|
+
* @param {string} baseName - Defines the first part of the unique element name.
|
|
5435
|
+
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
5436
|
+
* @returns {string} - Unique string to be used for naming.
|
|
5437
|
+
*/
|
|
5438
|
+
generateElementName(baseName, version) {
|
|
5439
|
+
let result = baseName;
|
|
5440
|
+
|
|
5441
|
+
result += '-';
|
|
5442
|
+
result += version.replace(/[.]/g, '_');
|
|
5443
|
+
|
|
5444
|
+
return result;
|
|
5445
|
+
}
|
|
5446
|
+
|
|
5447
|
+
/**
|
|
5448
|
+
* Generates a unique string to be used for child auro element naming.
|
|
5449
|
+
* @param {string} baseName - Defines the first part of the unique element name.
|
|
5450
|
+
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
5451
|
+
* @returns {string} - Unique string to be used for naming.
|
|
5452
|
+
*/
|
|
5453
|
+
generateTag(baseName, version, tagClass) {
|
|
5454
|
+
const elementName = this.generateElementName(baseName, version);
|
|
5455
|
+
const tag = literal`${unsafeStatic(elementName)}`;
|
|
5456
|
+
|
|
5457
|
+
if (!customElements.get(elementName)) {
|
|
5458
|
+
customElements.define(elementName, class extends tagClass {});
|
|
5459
|
+
}
|
|
5460
|
+
|
|
5461
|
+
return tag;
|
|
5462
|
+
}
|
|
5463
|
+
}
|
|
5464
|
+
|
|
5465
|
+
/**
|
|
5466
|
+
* Private module-level WeakMap to hold MutationObservers for each host element.
|
|
5467
|
+
*/
|
|
5468
|
+
const _observers = new WeakMap();
|
|
5469
|
+
|
|
5470
|
+
/**
|
|
5471
|
+
* Private module-level WeakMap to hold attribute matchers and targets for each host element.
|
|
5472
|
+
* Structure: {
|
|
5473
|
+
* host: {
|
|
5474
|
+
* matchers: Set<Function>,
|
|
5475
|
+
* targets: Map<HTMLElement, Map<Function, {removeOriginal: boolean, currentAttributes: Map<string, string>}>>
|
|
5476
|
+
* }
|
|
5477
|
+
* }
|
|
5478
|
+
*/
|
|
5479
|
+
const _transportConfig = new WeakMap();
|
|
5480
|
+
|
|
5481
|
+
/**
|
|
5482
|
+
* Transfers all matching attributes from a host element to a target element and observes for future changes.
|
|
5483
|
+
*
|
|
5484
|
+
* @param {Object} params - The parameters for the function.
|
|
5485
|
+
* @param {HTMLElement} params.host - The host element from which attributes will be transported.
|
|
5486
|
+
* @param {HTMLElement} params.target - The target element to which attributes will be transported.
|
|
5487
|
+
* @param {boolean} [params.removeOriginal=true] - Whether to remove the attributes from the host element.
|
|
5488
|
+
* @param {boolean} [params.observe=true] - Whether to attach a MutationObserver to the host element.
|
|
5489
|
+
* @returns {Function} A function to detach the observer when no longer needed.
|
|
5490
|
+
* @throws {TypeError} If the host or target parameters are not instances of HTMLElement.
|
|
5491
|
+
*/
|
|
5492
|
+
const transportAttributes = ({ host, target, match, removeOriginal = true }) => {
|
|
5493
|
+
// Guard Clause: Ensure host is valid HTMLElement instance
|
|
5494
|
+
if (typeof host !== 'object' || !(host instanceof HTMLElement)) {
|
|
5495
|
+
throw new TypeError('a11yUtilities.js | transportAttributes | The "host" parameter must be an instance of HTMLElement.');
|
|
5496
|
+
}
|
|
5497
|
+
|
|
5498
|
+
// Guard Clause: Ensure target is valid HTMLElement instance
|
|
5499
|
+
if (typeof target !== 'object' || !(target instanceof HTMLElement)) {
|
|
5500
|
+
throw new TypeError('a11yUtilities.js | transportAttributes | The "target" parameter must be an instance of HTMLElement.');
|
|
5501
|
+
}
|
|
5502
|
+
|
|
5503
|
+
// Guard Clause: Ensure match is a function
|
|
5504
|
+
if (typeof match !== 'function') {
|
|
5505
|
+
throw new TypeError('a11yUtilities.js | transportAttributes | The "match" parameter must be a function.');
|
|
5506
|
+
}
|
|
5507
|
+
|
|
5508
|
+
// Guard Clause: Ensure removeOriginal is a boolean
|
|
5509
|
+
if (typeof removeOriginal !== 'boolean') {
|
|
5510
|
+
throw new TypeError('a11yUtilities.js | transportAttributes | The "removeOriginal" parameter must be a boolean.');
|
|
5511
|
+
}
|
|
5512
|
+
|
|
5513
|
+
// Register this transport and get cleanup function
|
|
5514
|
+
return _registerTransport({
|
|
5515
|
+
host,
|
|
5516
|
+
target,
|
|
5517
|
+
matcher: match,
|
|
5518
|
+
removeOriginal
|
|
5519
|
+
});
|
|
5520
|
+
};
|
|
5521
|
+
|
|
5522
|
+
/**
|
|
5523
|
+
* Registers a matcher and target for a host element and attaches an observer if needed.
|
|
5524
|
+
*
|
|
5525
|
+
* @param {Object} params - The parameters object.
|
|
5526
|
+
* @param {HTMLElement} params.host - The host element to observe.
|
|
5527
|
+
* @param {HTMLElement} params.target - The target element to receive attributes.
|
|
5528
|
+
* @param {Function} params.matcher - Function that determines which attributes to transport.
|
|
5529
|
+
* @param {boolean} [params.removeOriginal=true] - Whether to remove original attributes.
|
|
5530
|
+
* @param {boolean} [params.observe=true] - Whether to observe for attribute changes.
|
|
5531
|
+
* @returns {Function} Function to detach the specific matcher and target pairing.
|
|
5532
|
+
* @private
|
|
5533
|
+
*/
|
|
5534
|
+
const _registerTransport = ({ host, target, matcher, removeOriginal = true }) => {
|
|
5535
|
+
// Initialize config for this host if it doesn't exist
|
|
5536
|
+
if (!_transportConfig.has(host)) {
|
|
5537
|
+
_transportConfig.set(host, {
|
|
5538
|
+
matchers: new Set(),
|
|
5539
|
+
targets: new Map()
|
|
5540
|
+
});
|
|
5541
|
+
}
|
|
5542
|
+
|
|
5543
|
+
const config = _transportConfig.get(host);
|
|
5544
|
+
|
|
5545
|
+
// Add the matcher to the set of matchers for this host
|
|
5546
|
+
config.matchers.add(matcher);
|
|
5547
|
+
|
|
5548
|
+
// Initialize target entry if it doesn't exist
|
|
5549
|
+
if (!config.targets.has(target)) {
|
|
5550
|
+
config.targets.set(target, new Map());
|
|
5551
|
+
}
|
|
5552
|
+
|
|
5553
|
+
// Store the matcher with its removeOriginal setting for this target
|
|
5554
|
+
config.targets.get(target).set(matcher, {
|
|
5555
|
+
removeOriginal,
|
|
5556
|
+
currentAttributes: new Map()
|
|
5557
|
+
});
|
|
5558
|
+
|
|
5559
|
+
// Perform initial attribute transport
|
|
5560
|
+
_transportAttributes({ host, target, matcher, removeOriginal });
|
|
5561
|
+
|
|
5562
|
+
// Attach observer
|
|
5563
|
+
_attachObserver(host);
|
|
5564
|
+
|
|
5565
|
+
// Return cleanup function and utility functions
|
|
5566
|
+
return {
|
|
5567
|
+
cleanup: () => _cleanupTransport(host, target, matcher),
|
|
5568
|
+
getObservedAttributes: () => _getObservedAttributes(host, target, matcher),
|
|
5569
|
+
getObservedAttribute: (attr) => _getObservedAttribute(host, target, matcher, attr),
|
|
5570
|
+
}
|
|
5571
|
+
};
|
|
5572
|
+
|
|
5573
|
+
/**
|
|
5574
|
+
* Cleans up resources associated with a specific matcher and target for a host element.
|
|
5575
|
+
*
|
|
5576
|
+
* @param {HTMLElement} host - The host element
|
|
5577
|
+
* @param {HTMLElement} target - The target element
|
|
5578
|
+
* @param {Function} matcher - The matcher function
|
|
5579
|
+
* @private
|
|
5580
|
+
*/
|
|
5581
|
+
const _cleanupTransport = (host, target, matcher) => {
|
|
5582
|
+
const config = _transportConfig.get(host);
|
|
5583
|
+
if (!config) return;
|
|
5584
|
+
|
|
5585
|
+
// Remove this matcher from this target
|
|
5586
|
+
const targetMatchers = config.targets.get(target);
|
|
5587
|
+
if (targetMatchers) {
|
|
5588
|
+
targetMatchers.delete(matcher);
|
|
5589
|
+
|
|
5590
|
+
// If this target has no more matchers, remove it
|
|
5591
|
+
if (targetMatchers.size === 0) {
|
|
5592
|
+
config.targets.delete(target);
|
|
5593
|
+
}
|
|
5594
|
+
}
|
|
5595
|
+
|
|
5596
|
+
// Check if this matcher is still used by any target
|
|
5597
|
+
let matcherStillUsed = false;
|
|
5598
|
+
for (const matcherMap of config.targets.values()) {
|
|
5599
|
+
if (matcherMap.has(matcher)) {
|
|
5600
|
+
matcherStillUsed = true;
|
|
5601
|
+
break;
|
|
5602
|
+
}
|
|
5603
|
+
}
|
|
5604
|
+
|
|
5605
|
+
// If not used anymore, remove from matchers set
|
|
5606
|
+
if (!matcherStillUsed) {
|
|
5607
|
+
config.matchers.delete(matcher);
|
|
5608
|
+
}
|
|
5609
|
+
|
|
5610
|
+
// If no more targets or matchers, detach observer
|
|
5611
|
+
if (config.targets.size === 0 || config.matchers.size === 0) {
|
|
5612
|
+
_detachObserver(host);
|
|
5613
|
+
}
|
|
5614
|
+
};
|
|
5615
|
+
|
|
5616
|
+
/**
|
|
5617
|
+
* Generic function to transport attributes from a host element to a target element.
|
|
5618
|
+
*
|
|
5619
|
+
* @param {Object} params - The parameters object.
|
|
5620
|
+
* @param {HTMLElement} params.host - The host element from which to transport attributes.
|
|
5621
|
+
* @param {HTMLElement} params.target - The target element to which attributes will be transported.
|
|
5622
|
+
* @param {Function} params.matcher - Function that takes an attribute name and returns true if it should be transported.
|
|
5623
|
+
* @param {boolean} [params.removeOriginal=true] - Whether to remove original attributes from host.
|
|
5624
|
+
* @returns {void}
|
|
5625
|
+
* @private
|
|
5626
|
+
*/
|
|
5627
|
+
const _transportAttributes = ({ host, target, matcher, removeOriginal = true }) => {
|
|
5628
|
+
// Get a list of all matching attributes on the host element and their values
|
|
5629
|
+
const matchingAttributes = host.getAttributeNames()
|
|
5630
|
+
.filter(attr => matcher(attr))
|
|
5631
|
+
.reduce((acc, attr) => {
|
|
5632
|
+
acc[attr] = host.getAttribute(attr);
|
|
5633
|
+
return acc;
|
|
5634
|
+
}, {});
|
|
5635
|
+
|
|
5636
|
+
// Move matching attributes to the target element, removing them from the host if removeOriginal is true
|
|
5637
|
+
Object.entries(matchingAttributes).forEach(([key, value]) => {
|
|
5638
|
+
_setObservedAttribute(host, target, matcher, key, value);
|
|
5639
|
+
target.setAttribute(key, value);
|
|
5640
|
+
if (removeOriginal) {
|
|
5641
|
+
host.removeAttribute(key);
|
|
5642
|
+
}
|
|
5643
|
+
});
|
|
5644
|
+
};
|
|
5645
|
+
|
|
5646
|
+
/**
|
|
5647
|
+
* Attaches a MutationObserver to the host element to monitor attribute changes.
|
|
5648
|
+
*
|
|
5649
|
+
* @param {HTMLElement} host - The element to observe for attribute changes.
|
|
5650
|
+
* @returns {MutationObserver} The observer instance.
|
|
5651
|
+
* @private
|
|
5652
|
+
*/
|
|
5653
|
+
const _attachObserver = (host) => {
|
|
5654
|
+
// If an observer for this host already exists, return it
|
|
5655
|
+
if (_observers.has(host)) {
|
|
5656
|
+
return _observers.get(host);
|
|
5657
|
+
}
|
|
5658
|
+
|
|
5659
|
+
// Create a new MutationObserver
|
|
5660
|
+
const observer = new MutationObserver((mutations) => {
|
|
5661
|
+
const config = _transportConfig.get(host);
|
|
5662
|
+
if (!config) return;
|
|
5663
|
+
|
|
5664
|
+
// For each mutation affecting attributes
|
|
5665
|
+
mutations
|
|
5666
|
+
.filter(mutation => mutation.type === 'attributes')
|
|
5667
|
+
.forEach(mutation => {
|
|
5668
|
+
const attributeName = mutation.attributeName;
|
|
5669
|
+
|
|
5670
|
+
// Find matchers that care about this attribute
|
|
5671
|
+
for (const matcher of config.matchers) {
|
|
5672
|
+
if (matcher(attributeName)) {
|
|
5673
|
+
// For each target that uses this matcher
|
|
5674
|
+
for (const [target, matcherConfigs] of config.targets.entries()) {
|
|
5675
|
+
if (matcherConfigs.has(matcher)) {
|
|
5676
|
+
const { removeOriginal } = matcherConfigs.get(matcher);
|
|
5677
|
+
_transportAttributes({
|
|
5678
|
+
host,
|
|
5679
|
+
target,
|
|
5680
|
+
matcher,
|
|
5681
|
+
removeOriginal
|
|
5682
|
+
});
|
|
5683
|
+
}
|
|
5684
|
+
}
|
|
5685
|
+
}
|
|
5686
|
+
}
|
|
5687
|
+
});
|
|
5688
|
+
});
|
|
5689
|
+
|
|
5690
|
+
// Start observing attribute changes
|
|
5691
|
+
observer.observe(host, { attributes: true });
|
|
5692
|
+
|
|
5693
|
+
// Store the observer
|
|
5694
|
+
_observers.set(host, observer);
|
|
5695
|
+
|
|
5696
|
+
return observer;
|
|
5697
|
+
};
|
|
5698
|
+
|
|
5699
|
+
/**
|
|
5700
|
+
* Detaches and cleans up the MutationObserver for a given host element.
|
|
5701
|
+
*
|
|
5702
|
+
* @param {HTMLElement} host - The element whose observer should be detached.
|
|
5703
|
+
* @private
|
|
5704
|
+
*/
|
|
5705
|
+
const _detachObserver = (host) => {
|
|
5706
|
+
if (_observers.has(host)) {
|
|
5707
|
+
const observer = _observers.get(host);
|
|
5708
|
+
observer.disconnect();
|
|
5709
|
+
_observers.delete(host);
|
|
5710
|
+
}
|
|
5711
|
+
|
|
5712
|
+
// Clean up the transport config as well
|
|
5713
|
+
if (_transportConfig.has(host)) {
|
|
5714
|
+
_transportConfig.delete(host);
|
|
5715
|
+
}
|
|
5716
|
+
};
|
|
5717
|
+
|
|
5718
|
+
/**
|
|
5719
|
+
* Gets the matcher configuration for a specific host, target, and matcher
|
|
5720
|
+
* @param {HTMLElement} host - The host element
|
|
5721
|
+
* @param {HTMLElement} target - The target element
|
|
5722
|
+
* @param {Function} matcher - The matcher function
|
|
5723
|
+
* @returns {Object|undefined} The matcher configuration if found
|
|
5724
|
+
* @private
|
|
5725
|
+
*/
|
|
5726
|
+
const _getMatcherConfig = (host, target, matcher) => {
|
|
5727
|
+
const config = _transportConfig.get(host);
|
|
5728
|
+
if (!config) return undefined;
|
|
5729
|
+
|
|
5730
|
+
const targetMatchers = config.targets.get(target);
|
|
5731
|
+
if (!targetMatchers) return undefined;
|
|
5732
|
+
|
|
5733
|
+
return targetMatchers.get(matcher);
|
|
5734
|
+
};
|
|
5735
|
+
|
|
5736
|
+
/**
|
|
5737
|
+
* Sets an observed attribute value
|
|
5738
|
+
* @param {HTMLElement} host - The host element
|
|
5739
|
+
* @param {HTMLElement} target - The target element
|
|
5740
|
+
* @param {Function} matcher - The matcher function
|
|
5741
|
+
* @param {string} key - The attribute name
|
|
5742
|
+
* @param {string} value - The attribute value
|
|
5743
|
+
* @private
|
|
5744
|
+
*/
|
|
5745
|
+
const _setObservedAttribute = (host, target, matcher, key, value) => {
|
|
5746
|
+
const matcherConfig = _getMatcherConfig(host, target, matcher);
|
|
5747
|
+
if (matcherConfig) {
|
|
5748
|
+
matcherConfig.currentAttributes.set(key, value);
|
|
5749
|
+
}
|
|
5750
|
+
};
|
|
5751
|
+
|
|
5752
|
+
const _getObservedAttribute = (host, target, matcher, attr) => {
|
|
5753
|
+
const matcherConfig = _getMatcherConfig(host, target, matcher);
|
|
5754
|
+
if (matcherConfig) return matcherConfig.currentAttributes.get(attr);
|
|
5755
|
+
return undefined;
|
|
5756
|
+
};
|
|
5757
|
+
|
|
5758
|
+
const _getObservedAttributes = (host, target, matcher) => {
|
|
5759
|
+
const matcherConfig = _getMatcherConfig(host, target, matcher);
|
|
5760
|
+
if (matcherConfig) return Array.from(matcherConfig.currentAttributes.entries());
|
|
5761
|
+
return [];
|
|
5762
|
+
};
|
|
5763
|
+
|
|
5764
|
+
const _matchers = {
|
|
5765
|
+
'aria-': attr => attr.startsWith('aria-'),
|
|
5766
|
+
'role': attr => attr.match(/^role$/)
|
|
5767
|
+
};
|
|
5768
|
+
|
|
5769
|
+
const transportAllA11yAttributes = ({ host, target, removeOriginal = true }) => {
|
|
5770
|
+
return transportAttributes({
|
|
5771
|
+
host,
|
|
5772
|
+
target,
|
|
5773
|
+
match: attr => {
|
|
5774
|
+
for (const key in _matchers) {
|
|
5775
|
+
if (_matchers[key](attr)) return true;
|
|
5776
|
+
}
|
|
5777
|
+
return false;
|
|
5778
|
+
},
|
|
5779
|
+
removeOriginal
|
|
5780
|
+
});
|
|
5781
|
+
};
|
|
5782
|
+
|
|
5783
|
+
let AuroElement$1 = class AuroElement extends LitElement {
|
|
5784
|
+
|
|
5785
|
+
/**
|
|
5786
|
+
* @type {Object} return object from transportAttributes via a11yUtilities
|
|
5787
|
+
* @property {Function} cleanup - Function to clean up the attribute watcher.
|
|
5788
|
+
* @property {Function} getCurrentAttributes - Function to get the current attributes being watched and their values.
|
|
5789
|
+
* @property {Function} getObservedAttribute - Function to get the value of a specific observed attribute by name.
|
|
5790
|
+
* @private
|
|
5791
|
+
*/
|
|
5792
|
+
attributeWatcher;
|
|
5793
|
+
|
|
5794
|
+
static get properties() {
|
|
5795
|
+
return {
|
|
5796
|
+
|
|
5797
|
+
/**
|
|
5798
|
+
* Defines the layout of an element.
|
|
5799
|
+
* @default {'default'}
|
|
5800
|
+
*/
|
|
5801
|
+
layout: {
|
|
5802
|
+
type: String,
|
|
5803
|
+
attribute: "layout",
|
|
5804
|
+
reflect: true
|
|
5805
|
+
},
|
|
5806
|
+
|
|
5807
|
+
/**
|
|
5808
|
+
* Defines the shape of an element.
|
|
5809
|
+
* @property {'default', 'rounded', 'pill', 'circle'}
|
|
5810
|
+
* @default {'default'}
|
|
5811
|
+
*/
|
|
5812
|
+
shape: {
|
|
5813
|
+
type: String,
|
|
5814
|
+
attribute: "shape",
|
|
5815
|
+
reflect: true
|
|
5816
|
+
},
|
|
5817
|
+
|
|
5818
|
+
/**
|
|
5819
|
+
* Defines the size of an element.
|
|
5820
|
+
* @property {'xs', 'sm', 'md', 'lg', 'xl'}
|
|
5821
|
+
* @default {'md'}
|
|
5822
|
+
*/
|
|
5823
|
+
size: {
|
|
5824
|
+
type: String,
|
|
5825
|
+
attribute: "size",
|
|
5826
|
+
reflect: true
|
|
5827
|
+
},
|
|
5828
|
+
|
|
5829
|
+
/**
|
|
5830
|
+
* This Boolean attribute lets you specify that the element should be rendered in dark mode.
|
|
5831
|
+
* @default {false}
|
|
5832
|
+
*/
|
|
5833
|
+
onDark: {
|
|
5834
|
+
type: Boolean,
|
|
5835
|
+
attribute: "ondark",
|
|
5836
|
+
reflect: true
|
|
5837
|
+
},
|
|
5838
|
+
|
|
5839
|
+
/**
|
|
5840
|
+
* A reference to the wrapper element in the shadow DOM.
|
|
5841
|
+
* This is used to apply layout and shape classes dynamically.
|
|
5842
|
+
* @type {HTMLElement|null}
|
|
5843
|
+
* @default {null}
|
|
5844
|
+
* @private
|
|
5845
|
+
*/
|
|
5846
|
+
wrapper: {
|
|
5847
|
+
attribute: false,
|
|
5848
|
+
reflect: false
|
|
5849
|
+
}
|
|
5850
|
+
};
|
|
5851
|
+
}
|
|
5852
|
+
|
|
5853
|
+
|
|
5854
|
+
|
|
5855
|
+
resetShapeClasses() {
|
|
5856
|
+
if (this.shape && this.size) {
|
|
5857
|
+
|
|
5858
|
+
if (this.wrapper) {
|
|
5859
|
+
this.wrapper.classList.forEach((className) => {
|
|
5860
|
+
if (className.startsWith('shape-')) {
|
|
5861
|
+
this.wrapper.classList.remove(className);
|
|
5862
|
+
}
|
|
5863
|
+
});
|
|
5864
|
+
|
|
5865
|
+
this.wrapper.classList.add(`shape-${this.shape.toLowerCase()}-${this.size.toLowerCase()}`);
|
|
5866
|
+
}
|
|
5867
|
+
}
|
|
5868
|
+
}
|
|
5869
|
+
|
|
5870
|
+
resetLayoutClasses() {
|
|
5871
|
+
if (this.layout) {
|
|
5872
|
+
if (this.wrapper) {
|
|
5873
|
+
this.wrapper.classList.forEach((className) => {
|
|
5874
|
+
if (className.startsWith('layout-')) {
|
|
5875
|
+
this.wrapper.classList.remove(className);
|
|
5876
|
+
}
|
|
5877
|
+
});
|
|
5878
|
+
|
|
5879
|
+
this.wrapper.classList.add(`layout-${this.layout.toLowerCase()}`);
|
|
5880
|
+
}
|
|
5881
|
+
}
|
|
5882
|
+
}
|
|
5883
|
+
|
|
5884
|
+
updateComponentArchitecture() {
|
|
5885
|
+
this.resetLayoutClasses();
|
|
5886
|
+
this.resetShapeClasses();
|
|
5887
|
+
}
|
|
5888
|
+
|
|
5889
|
+
updated(changedProperties) {
|
|
5890
|
+
if (changedProperties.has('layout') || changedProperties.has('shape') || changedProperties.has('size')) {
|
|
5891
|
+
this.updateComponentArchitecture();
|
|
5892
|
+
}
|
|
5893
|
+
}
|
|
5894
|
+
|
|
5895
|
+
firstUpdated() {
|
|
5896
|
+
super.firstUpdated();
|
|
5897
|
+
|
|
5898
|
+
// Set a reference to the wrapper element in the shadow DOM
|
|
5899
|
+
this.wrapper = this.shadowRoot.querySelector('.wrapper');
|
|
5900
|
+
|
|
5901
|
+
// Initialize the transportation of ARIA attributes to the target element and get the disconnect function for cleanup
|
|
5902
|
+
this.attributeWatcher = transportAllA11yAttributes({ host: this, target: this.shadowRoot.querySelector('.wrapper') });
|
|
5903
|
+
}
|
|
5904
|
+
|
|
5905
|
+
disconnectedCallback() {
|
|
5906
|
+
super.disconnectedCallback();
|
|
5907
|
+
|
|
5908
|
+
// Cleanup the ARIA observer if it exists
|
|
5909
|
+
if (this.attributeWatcher) {
|
|
5910
|
+
this.attributeWatcher.cleanup();
|
|
5911
|
+
this.attributeWatcher = null;
|
|
5912
|
+
}
|
|
5913
|
+
}
|
|
5914
|
+
|
|
5915
|
+
// Try to render the defined `this.layout` layout. If that fails, fall back to the default layout.
|
|
5916
|
+
// This will catch if an invalid layout value is passed in and render the default layout if so.
|
|
5917
|
+
render() {
|
|
5918
|
+
try {
|
|
5919
|
+
return this.renderLayout();
|
|
5920
|
+
} catch (error) {
|
|
5921
|
+
// failed to get the defined layout
|
|
5922
|
+
console.error('Failed to get the defined layout - using the default layout', error); // eslint-disable-line no-console
|
|
5923
|
+
|
|
5924
|
+
// fallback to the default layout
|
|
5925
|
+
return this.getLayout('default');
|
|
5926
|
+
}
|
|
5927
|
+
}
|
|
5928
|
+
};
|
|
5929
|
+
|
|
5930
|
+
var styleCss$3 = css`:focus:not(:focus-visible){outline:3px solid transparent}.util_insetNone{padding:0}.util_insetXxxs{padding:.125rem}.util_insetXxxs--stretch{padding:.25rem .125rem}.util_insetXxxs--squish{padding:0 .125rem}.util_insetXxs{padding:.25rem}.util_insetXxs--stretch{padding:.375rem .25rem}.util_insetXxs--squish{padding:.125rem .25rem}.util_insetXs{padding:.5rem}.util_insetXs--stretch{padding:.75rem .5rem}.util_insetXs--squish{padding:.25rem .5rem}.util_insetSm{padding:.75rem}.util_insetSm--stretch{padding:1.125rem .75rem}.util_insetSm--squish{padding:.375rem .75rem}.util_insetMd{padding:1rem}.util_insetMd--stretch{padding:1.5rem 1rem}.util_insetMd--squish{padding:.5rem 1rem}.util_insetLg{padding:1.5rem}.util_insetLg--stretch{padding:2.25rem 1.5rem}.util_insetLg--squish{padding:.75rem 1.5rem}.util_insetXl{padding:2rem}.util_insetXl--stretch{padding:3rem 2rem}.util_insetXl--squish{padding:1rem 2rem}.util_insetXxl{padding:3rem}.util_insetXxl--stretch{padding:4.5rem 3rem}.util_insetXxl--squish{padding:1.5rem 3rem}.util_insetXxxl{padding:4rem}.util_insetXxxl--stretch{padding:6rem 4rem}.util_insetXxxl--squish{padding:2rem 4rem}.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.63)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, 0.88)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3)}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host([size=xs][shape=rounded]) ::slotted(auro-icon),:host([size=xs][shape=rounded]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-200, 1rem)}:host([size=xs][shape=rounded][variant=primary]) .auro-button:focus,:host([size=xs][shape=rounded][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=rounded][variant=primary]) .auro-button:focus:after,:host([size=xs][shape=rounded][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xs][shape=rounded][variant=secondary]) .auro-button:focus,:host([size=xs][shape=rounded][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=rounded][variant=tertiary]) .auro-button:focus,:host([size=xs][shape=rounded][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=rounded][variant=ghost]) .auro-button:focus,:host([size=xs][shape=rounded][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill]) ::slotted(auro-icon),:host([size=xs][shape=pill]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-200, 1rem)}:host([size=xs][shape=pill][variant=primary]) .auro-button:focus,:host([size=xs][shape=pill][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill][variant=primary]) .auro-button:focus:after,:host([size=xs][shape=pill][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xs][shape=pill][variant=secondary]) .auro-button:focus,:host([size=xs][shape=pill][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill][variant=tertiary]) .auro-button:focus,:host([size=xs][shape=pill][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill][variant=ghost]) .auro-button:focus,:host([size=xs][shape=pill][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-left]) ::slotted(auro-icon),:host([size=xs][shape=pill-left]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-200, 1rem)}:host([size=xs][shape=pill-left][variant=primary]) .auro-button:focus,:host([size=xs][shape=pill-left][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-left][variant=primary]) .auro-button:focus:after,:host([size=xs][shape=pill-left][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xs][shape=pill-left][variant=secondary]) .auro-button:focus,:host([size=xs][shape=pill-left][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-left][variant=tertiary]) .auro-button:focus,:host([size=xs][shape=pill-left][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-left][variant=ghost]) .auro-button:focus,:host([size=xs][shape=pill-left][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-right]) ::slotted(auro-icon),:host([size=xs][shape=pill-right]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-200, 1rem)}:host([size=xs][shape=pill-right][variant=primary]) .auro-button:focus,:host([size=xs][shape=pill-right][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-right][variant=primary]) .auro-button:focus:after,:host([size=xs][shape=pill-right][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xs][shape=pill-right][variant=secondary]) .auro-button:focus,:host([size=xs][shape=pill-right][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-right][variant=tertiary]) .auro-button:focus,:host([size=xs][shape=pill-right][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=pill-right][variant=ghost]) .auro-button:focus,:host([size=xs][shape=pill-right][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=circle]) ::slotted(auro-icon),:host([size=xs][shape=circle]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=xs][shape=circle][variant=primary]) .auro-button:focus,:host([size=xs][shape=circle][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 2px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=circle][variant=primary]) .auro-button:focus:after,:host([size=xs][shape=circle][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xs][shape=circle][variant=secondary]) .auro-button:focus,:host([size=xs][shape=circle][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=circle][variant=tertiary]) .auro-button:focus,:host([size=xs][shape=circle][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 2px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=circle][variant=flat]) .auro-button:focus,:host([size=xs][shape=circle][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=circle][variant=ghost]) .auro-button:focus,:host([size=xs][shape=circle][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=square]) ::slotted(auro-icon),:host([size=xs][shape=square]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=xs][shape=square][variant=primary]) .auro-button:focus,:host([size=xs][shape=square][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 2px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=square][variant=primary]) .auro-button:focus:after,:host([size=xs][shape=square][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xs][shape=square][variant=secondary]) .auro-button:focus,:host([size=xs][shape=square][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=square][variant=tertiary]) .auro-button:focus,:host([size=xs][shape=square][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 2px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=square][variant=flat]) .auro-button:focus,:host([size=xs][shape=square][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs][shape=square][variant=ghost]) .auro-button:focus,:host([size=xs][shape=square][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=rounded]) ::slotted(auro-icon),:host([size=sm][shape=rounded]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=sm][shape=rounded][variant=primary]) .auro-button:focus,:host([size=sm][shape=rounded][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=rounded][variant=primary]) .auro-button:focus:after,:host([size=sm][shape=rounded][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=sm][shape=rounded][variant=secondary]) .auro-button:focus,:host([size=sm][shape=rounded][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=rounded][variant=tertiary]) .auro-button:focus,:host([size=sm][shape=rounded][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=rounded][variant=ghost]) .auro-button:focus,:host([size=sm][shape=rounded][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill]) ::slotted(auro-icon),:host([size=sm][shape=pill]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=sm][shape=pill][variant=primary]) .auro-button:focus,:host([size=sm][shape=pill][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill][variant=primary]) .auro-button:focus:after,:host([size=sm][shape=pill][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=sm][shape=pill][variant=secondary]) .auro-button:focus,:host([size=sm][shape=pill][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill][variant=tertiary]) .auro-button:focus,:host([size=sm][shape=pill][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill][variant=ghost]) .auro-button:focus,:host([size=sm][shape=pill][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-left]) ::slotted(auro-icon),:host([size=sm][shape=pill-left]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=sm][shape=pill-left][variant=primary]) .auro-button:focus,:host([size=sm][shape=pill-left][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-left][variant=primary]) .auro-button:focus:after,:host([size=sm][shape=pill-left][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=sm][shape=pill-left][variant=secondary]) .auro-button:focus,:host([size=sm][shape=pill-left][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-left][variant=tertiary]) .auro-button:focus,:host([size=sm][shape=pill-left][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-left][variant=ghost]) .auro-button:focus,:host([size=sm][shape=pill-left][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-right]) ::slotted(auro-icon),:host([size=sm][shape=pill-right]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=sm][shape=pill-right][variant=primary]) .auro-button:focus,:host([size=sm][shape=pill-right][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-right][variant=primary]) .auro-button:focus:after,:host([size=sm][shape=pill-right][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=sm][shape=pill-right][variant=secondary]) .auro-button:focus,:host([size=sm][shape=pill-right][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-right][variant=tertiary]) .auro-button:focus,:host([size=sm][shape=pill-right][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=pill-right][variant=ghost]) .auro-button:focus,:host([size=sm][shape=pill-right][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=circle]) ::slotted(auro-icon),:host([size=sm][shape=circle]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=sm][shape=circle][variant=primary]) .auro-button:focus,:host([size=sm][shape=circle][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=circle][variant=primary]) .auro-button:focus:after,:host([size=sm][shape=circle][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=sm][shape=circle][variant=secondary]) .auro-button:focus,:host([size=sm][shape=circle][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=circle][variant=tertiary]) .auro-button:focus,:host([size=sm][shape=circle][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=circle][variant=flat]) .auro-button:focus,:host([size=sm][shape=circle][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=circle][variant=ghost]) .auro-button:focus,:host([size=sm][shape=circle][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=square]) ::slotted(auro-icon),:host([size=sm][shape=square]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=sm][shape=square][variant=primary]) .auro-button:focus,:host([size=sm][shape=square][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=square][variant=primary]) .auro-button:focus:after,:host([size=sm][shape=square][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=sm][shape=square][variant=secondary]) .auro-button:focus,:host([size=sm][shape=square][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=square][variant=tertiary]) .auro-button:focus,:host([size=sm][shape=square][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=square][variant=flat]) .auro-button:focus,:host([size=sm][shape=square][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=sm][shape=square][variant=ghost]) .auro-button:focus,:host([size=sm][shape=square][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=rounded]) ::slotted(auro-icon),:host([size=md][shape=rounded]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=md][shape=rounded][variant=primary]) .auro-button:focus,:host([size=md][shape=rounded][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=rounded][variant=primary]) .auro-button:focus:after,:host([size=md][shape=rounded][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=md][shape=rounded][variant=secondary]) .auro-button:focus,:host([size=md][shape=rounded][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=rounded][variant=tertiary]) .auro-button:focus,:host([size=md][shape=rounded][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=rounded][variant=ghost]) .auro-button:focus,:host([size=md][shape=rounded][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill]) ::slotted(auro-icon),:host([size=md][shape=pill]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=md][shape=pill][variant=primary]) .auro-button:focus,:host([size=md][shape=pill][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill][variant=primary]) .auro-button:focus:after,:host([size=md][shape=pill][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=md][shape=pill][variant=secondary]) .auro-button:focus,:host([size=md][shape=pill][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill][variant=tertiary]) .auro-button:focus,:host([size=md][shape=pill][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill][variant=ghost]) .auro-button:focus,:host([size=md][shape=pill][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-left]) ::slotted(auro-icon),:host([size=md][shape=pill-left]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=md][shape=pill-left][variant=primary]) .auro-button:focus,:host([size=md][shape=pill-left][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-left][variant=primary]) .auro-button:focus:after,:host([size=md][shape=pill-left][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=md][shape=pill-left][variant=secondary]) .auro-button:focus,:host([size=md][shape=pill-left][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-left][variant=tertiary]) .auro-button:focus,:host([size=md][shape=pill-left][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-left][variant=ghost]) .auro-button:focus,:host([size=md][shape=pill-left][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-right]) ::slotted(auro-icon),:host([size=md][shape=pill-right]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=md][shape=pill-right][variant=primary]) .auro-button:focus,:host([size=md][shape=pill-right][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-right][variant=primary]) .auro-button:focus:after,:host([size=md][shape=pill-right][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=md][shape=pill-right][variant=secondary]) .auro-button:focus,:host([size=md][shape=pill-right][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-right][variant=tertiary]) .auro-button:focus,:host([size=md][shape=pill-right][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=pill-right][variant=ghost]) .auro-button:focus,:host([size=md][shape=pill-right][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=circle]) ::slotted(auro-icon),:host([size=md][shape=circle]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=md][shape=circle][variant=primary]) .auro-button:focus,:host([size=md][shape=circle][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=circle][variant=primary]) .auro-button:focus:after,:host([size=md][shape=circle][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=md][shape=circle][variant=secondary]) .auro-button:focus,:host([size=md][shape=circle][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=circle][variant=tertiary]) .auro-button:focus,:host([size=md][shape=circle][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=circle][variant=flat]) .auro-button:focus,:host([size=md][shape=circle][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=circle][variant=ghost]) .auro-button:focus,:host([size=md][shape=circle][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=square]) ::slotted(auro-icon),:host([size=md][shape=square]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=md][shape=square][variant=primary]) .auro-button:focus,:host([size=md][shape=square][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=square][variant=primary]) .auro-button:focus:after,:host([size=md][shape=square][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=md][shape=square][variant=secondary]) .auro-button:focus,:host([size=md][shape=square][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=square][variant=tertiary]) .auro-button:focus,:host([size=md][shape=square][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=square][variant=flat]) .auro-button:focus,:host([size=md][shape=square][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=md][shape=square][variant=ghost]) .auro-button:focus,:host([size=md][shape=square][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=rounded]) ::slotted(auro-icon),:host([size=lg][shape=rounded]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=lg][shape=rounded][variant=primary]) .auro-button:focus,:host([size=lg][shape=rounded][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=rounded][variant=primary]) .auro-button:focus:after,:host([size=lg][shape=rounded][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=lg][shape=rounded][variant=secondary]) .auro-button:focus,:host([size=lg][shape=rounded][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=rounded][variant=tertiary]) .auro-button:focus,:host([size=lg][shape=rounded][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=rounded][variant=ghost]) .auro-button:focus,:host([size=lg][shape=rounded][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill]) ::slotted(auro-icon),:host([size=lg][shape=pill]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=lg][shape=pill][variant=primary]) .auro-button:focus,:host([size=lg][shape=pill][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill][variant=primary]) .auro-button:focus:after,:host([size=lg][shape=pill][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=lg][shape=pill][variant=secondary]) .auro-button:focus,:host([size=lg][shape=pill][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill][variant=tertiary]) .auro-button:focus,:host([size=lg][shape=pill][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill][variant=ghost]) .auro-button:focus,:host([size=lg][shape=pill][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-left]) ::slotted(auro-icon),:host([size=lg][shape=pill-left]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=lg][shape=pill-left][variant=primary]) .auro-button:focus,:host([size=lg][shape=pill-left][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-left][variant=primary]) .auro-button:focus:after,:host([size=lg][shape=pill-left][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=lg][shape=pill-left][variant=secondary]) .auro-button:focus,:host([size=lg][shape=pill-left][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-left][variant=tertiary]) .auro-button:focus,:host([size=lg][shape=pill-left][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-left][variant=ghost]) .auro-button:focus,:host([size=lg][shape=pill-left][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-right]) ::slotted(auro-icon),:host([size=lg][shape=pill-right]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=lg][shape=pill-right][variant=primary]) .auro-button:focus,:host([size=lg][shape=pill-right][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-right][variant=primary]) .auro-button:focus:after,:host([size=lg][shape=pill-right][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=lg][shape=pill-right][variant=secondary]) .auro-button:focus,:host([size=lg][shape=pill-right][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-right][variant=tertiary]) .auro-button:focus,:host([size=lg][shape=pill-right][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=pill-right][variant=ghost]) .auro-button:focus,:host([size=lg][shape=pill-right][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=circle]) ::slotted(auro-icon),:host([size=lg][shape=circle]) ::slotted([auro-icon]){--ds-auro-icon-size: calc(var(--ds-size-300, 1.5rem) + var(--ds-size-50, 0.25rem))}:host([size=lg][shape=circle][variant=primary]) .auro-button:focus,:host([size=lg][shape=circle][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4.33px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=circle][variant=primary]) .auro-button:focus:after,:host([size=lg][shape=circle][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=lg][shape=circle][variant=secondary]) .auro-button:focus,:host([size=lg][shape=circle][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=circle][variant=tertiary]) .auro-button:focus,:host([size=lg][shape=circle][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=circle][variant=flat]) .auro-button:focus,:host([size=lg][shape=circle][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=circle][variant=ghost]) .auro-button:focus,:host([size=lg][shape=circle][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=square]) ::slotted(auro-icon),:host([size=lg][shape=square]) ::slotted([auro-icon]){--ds-auro-icon-size: calc(var(--ds-size-300, 1.5rem) + var(--ds-size-50, 0.25rem))}:host([size=lg][shape=square][variant=primary]) .auro-button:focus,:host([size=lg][shape=square][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4.33px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=square][variant=primary]) .auro-button:focus:after,:host([size=lg][shape=square][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=lg][shape=square][variant=secondary]) .auro-button:focus,:host([size=lg][shape=square][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=square][variant=tertiary]) .auro-button:focus,:host([size=lg][shape=square][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=square][variant=flat]) .auro-button:focus,:host([size=lg][shape=square][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=lg][shape=square][variant=ghost]) .auro-button:focus,:host([size=lg][shape=square][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=rounded]) ::slotted(auro-icon),:host([size=xl][shape=rounded]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=xl][shape=rounded][variant=primary]) .auro-button:focus,:host([size=xl][shape=rounded][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=rounded][variant=primary]) .auro-button:focus:after,:host([size=xl][shape=rounded][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xl][shape=rounded][variant=secondary]) .auro-button:focus,:host([size=xl][shape=rounded][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=rounded][variant=tertiary]) .auro-button:focus,:host([size=xl][shape=rounded][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=rounded][variant=ghost]) .auro-button:focus,:host([size=xl][shape=rounded][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill]) ::slotted(auro-icon),:host([size=xl][shape=pill]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=xl][shape=pill][variant=primary]) .auro-button:focus,:host([size=xl][shape=pill][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill][variant=primary]) .auro-button:focus:after,:host([size=xl][shape=pill][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xl][shape=pill][variant=secondary]) .auro-button:focus,:host([size=xl][shape=pill][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill][variant=tertiary]) .auro-button:focus,:host([size=xl][shape=pill][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill][variant=ghost]) .auro-button:focus,:host([size=xl][shape=pill][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-left]) ::slotted(auro-icon),:host([size=xl][shape=pill-left]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=xl][shape=pill-left][variant=primary]) .auro-button:focus,:host([size=xl][shape=pill-left][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-left][variant=primary]) .auro-button:focus:after,:host([size=xl][shape=pill-left][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xl][shape=pill-left][variant=secondary]) .auro-button:focus,:host([size=xl][shape=pill-left][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-left][variant=tertiary]) .auro-button:focus,:host([size=xl][shape=pill-left][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-left][variant=ghost]) .auro-button:focus,:host([size=xl][shape=pill-left][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-right]) ::slotted(auro-icon),:host([size=xl][shape=pill-right]) ::slotted([auro-icon]){--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}:host([size=xl][shape=pill-right][variant=primary]) .auro-button:focus,:host([size=xl][shape=pill-right][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-right][variant=primary]) .auro-button:focus:after,:host([size=xl][shape=pill-right][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xl][shape=pill-right][variant=secondary]) .auro-button:focus,:host([size=xl][shape=pill-right][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-right][variant=tertiary]) .auro-button:focus,:host([size=xl][shape=pill-right][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=pill-right][variant=ghost]) .auro-button:focus,:host([size=xl][shape=pill-right][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=circle]) ::slotted(auro-icon),:host([size=xl][shape=circle]) ::slotted([auro-icon]){--ds-auro-icon-size: calc(var(--ds-size-400, 2rem) + var(--ds-size-50, 0.25rem))}:host([size=xl][shape=circle][variant=primary]) .auro-button:focus,:host([size=xl][shape=circle][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=circle][variant=primary]) .auro-button:focus:after,:host([size=xl][shape=circle][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xl][shape=circle][variant=secondary]) .auro-button:focus,:host([size=xl][shape=circle][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=circle][variant=tertiary]) .auro-button:focus,:host([size=xl][shape=circle][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=circle][variant=flat]) .auro-button:focus,:host([size=xl][shape=circle][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=circle][variant=ghost]) .auro-button:focus,:host([size=xl][shape=circle][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=square]) ::slotted(auro-icon),:host([size=xl][shape=square]) ::slotted([auro-icon]){--ds-auro-icon-size: calc(var(--ds-size-400, 2rem) + var(--ds-size-50, 0.25rem))}:host([size=xl][shape=square][variant=primary]) .auro-button:focus,:host([size=xl][shape=square][variant=primary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 5px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=square][variant=primary]) .auro-button:focus:after,:host([size=xl][shape=square][variant=primary]) .auro-button:focus-visible:after{content:"";position:absolute;border-radius:inherit;box-sizing:content-box;top:0;left:0;width:calc(100% - 2px);height:calc(100% - 2px);border:1px solid var(--ds-auro-button-border-color)}:host([size=xl][shape=square][variant=secondary]) .auro-button:focus,:host([size=xl][shape=square][variant=secondary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 3px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=square][variant=tertiary]) .auro-button:focus,:host([size=xl][shape=square][variant=tertiary]) .auro-button:focus-visible{box-shadow:inset 0 0 0 4px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=square][variant=flat]) .auro-button:focus,:host([size=xl][shape=square][variant=flat]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xl][shape=square][variant=ghost]) .auro-button:focus,:host([size=xl][shape=square][variant=ghost]) .auro-button:focus-visible{box-shadow:inset 0 0 0 1px var(--ds-auro-button-border-inset-color)}:host([size=xs]) .inset{padding-inline:var(--ds-size-150, 0.75rem)}:host([fluid]){display:block}:host([fluid]) .auro-button{width:calc(100% - var(--ds-size-150, 0.75rem)*2)}:host([size=sm]) .inset{padding-inline:var(--ds-size-200, 1rem)}:host([fluid]){display:block}:host([fluid]) .auro-button{width:calc(100% - var(--ds-size-200, 1rem)*2)}:host([size=md]) .inset{padding-inline:var(--ds-size-300, 1.5rem)}:host([fluid]){display:block}:host([fluid]) .auro-button{width:calc(100% - var(--ds-size-300, 1.5rem)*2)}:host([size=lg]) .inset{padding-inline:var(--ds-size-400, 2rem)}:host([fluid]){display:block}:host([fluid]) .auro-button{width:calc(100% - var(--ds-size-400, 2rem)*2)}:host([size=xl]) .inset{padding-inline:var(--ds-size-500, 2.5rem)}:host([fluid]){display:block}:host([fluid]) .auro-button{width:calc(100% - var(--ds-size-500, 2.5rem)*2)}:host([shape=circle]) ::slotted(:not(auro-icon):not([auro-icon])){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host([shape=square]) ::slotted(:not(auro-icon):not([auro-icon])){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host([variant=flat]){display:inline-block}::slotted(svg){vertical-align:middle}slot{pointer-events:none}:host{display:inline-block;overflow:hidden}.auro-button{position:relative;cursor:pointer;padding:0 var(--ds-size-300, 1.5rem);padding-inline:unset;padding-block:unset;box-sizing:content-box;overflow:hidden;text-overflow:ellipsis;user-select:none;white-space:nowrap;outline:none;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:var(--ds-size-100, 0.5rem);margin:0;-webkit-touch-callout:none;-webkit-user-select:none;transition:padding 300ms ease-out}.auro-button:focus,.auro-button:focus-visible{outline:none}.auro-button:active{transform:scale(0.95)}.auro-button.loading{cursor:not-allowed}.auro-button.loading *:not([auro-loader]){visibility:hidden}@media screen and (min-width: 576px){.auro-button{width:auto}}.auro-button:disabled{cursor:not-allowed;transform:unset}`;
|
|
5931
|
+
|
|
5932
|
+
var colorCss$2 = css`[auro-loader]{color:var(--ds-auro-button-loader-color, #ffffff)}.auro-button{-webkit-tap-highlight-color:var(--ds-auro-button-tap-color);color:var(--ds-auro-button-text-color);background-color:var(--ds-auro-button-container-color);background-image:linear-gradient(var(--ds-auro-button-container-image), var(--ds-auro-button-container-image));border-color:var(--ds-auro-button-border-color)}.auro-button:not([variant=secondary]):not([variant=tertiary]):focus-visible{outline-color:var(--ds-auro-button-border-inset-color)}.auro-button:not([ondark]):active:not(:disabled),.auro-button:not([ondark]):hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background-hover, #00274a);--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background-hover, #00274a);--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border-hover, #00274a)}.auro-button:not([ondark]):disabled{--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background-disabled, #acc9e2);--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background-disabled, #acc9e2);--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border-disabled, #acc9e2)}.auro-button:not([ondark])[variant=secondary]{--ds-auro-button-container-color: var(--ds-advanced-color-button-secondary-background, #ffffff);--ds-auro-button-container-image: var(--ds-advanced-color-button-secondary-background, #ffffff);--ds-auro-button-border-color: var(--ds-advanced-color-button-secondary-border, #01426a);--ds-auro-button-text-color: var(--ds-advanced-color-button-secondary-text, #01426a);--ds-auro-button-loader-color: var(--ds-advanced-color-button-secondary-text, #01426a)}.auro-button:not([ondark])[variant=secondary]:active:not(:disabled),.auro-button:not([ondark])[variant=secondary]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-secondary-background-hover, #f2f2f2);--ds-auro-button-container-image: var(--ds-advanced-color-button-secondary-background-hover, #f2f2f2);--ds-auro-button-border-color: var(--ds-advanced-color-button-secondary-border-hover, #00274a);--ds-auro-button-text-color: var(--ds-advanced-color-button-secondary-text-hover, #00274a)}.auro-button:not([ondark])[variant=secondary]:focus,.auro-button:not([ondark])[variant=secondary]:focus-visible{--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused, #01426a)}.auro-button:not([ondark])[variant=secondary]:disabled{--ds-auro-button-container-color: var(--ds-advanced-color-button-secondary-background-disabled, #f7f7f7);--ds-auro-button-container-image: var(--ds-advanced-color-button-secondary-background-disabled, #f7f7f7);--ds-auro-button-border-color: var(--ds-advanced-color-button-secondary-border-disabled, #cfe0ef);--ds-auro-button-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}.auro-button:not([ondark])[variant=tertiary]{--ds-auro-button-container-color: var(--ds-advanced-color-button-tertiary-background, rgba(0, 0, 0, 0.05));--ds-auro-button-container-image: var(--ds-advanced-color-button-tertiary-background, rgba(0, 0, 0, 0.05));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-advanced-color-button-tertiary-text, #01426a);--ds-auro-button-loader-color: var(--ds-advanced-color-button-tertiary-text, #01426a)}.auro-button:not([ondark])[variant=tertiary]:active:not(:disabled),.auro-button:not([ondark])[variant=tertiary]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-tertiary-background-hover, rgba(0, 0, 0, 0.1));--ds-auro-button-container-image: var(--ds-advanced-color-button-tertiary-background-hover, rgba(0, 0, 0, 0.1));--ds-auro-button-border-color: transparent}.auro-button:not([ondark])[variant=tertiary]:focus,.auro-button:not([ondark])[variant=tertiary]:focus-visible{--ds-auro-button-border-color: var(--ds-advanced-color-state-focused, #01426a);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused, #01426a)}.auro-button:not([ondark])[variant=tertiary]:disabled{--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}.auro-button:not([ondark])[variant=ghost]{--ds-auro-button-container-color: transparent;--ds-auro-button-container-image: transparent;--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-advanced-color-button-ghost-text, #01426a);--ds-auro-button-loader-color: var(--ds-advanced-color-button-ghost-text, #01426a)}.auro-button:not([ondark])[variant=ghost]:active:not(:disabled),.auro-button:not([ondark])[variant=ghost]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-ghost-background-hover, rgba(0, 0, 0, 0.05));--ds-auro-button-container-image: var(--ds-advanced-color-button-ghost-background-hover, rgba(0, 0, 0, 0.05));--ds-auro-button-border-color: transparent}.auro-button:not([ondark])[variant=ghost]:focus,.auro-button:not([ondark])[variant=ghost]:focus-visible{border-color:transparent;--ds-auro-button-border-color: var(--ds-advanced-color-state-focused, #01426a);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused, #01426a)}.auro-button:not([ondark])[variant=ghost]:disabled{--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}.auro-button:not([ondark])[variant=flat]{color:var(--ds-advanced-color-button-flat-text, #676767);background-color:transparent;background-image:none;border-color:transparent}.auro-button:not([ondark])[variant=flat]:active:not(:disabled),.auro-button:not([ondark])[variant=flat]:hover:not(:disabled){color:var(--ds-advanced-color-button-flat-text-hover, #525252);background-color:transparent;background-image:none;border-color:transparent}.auro-button:not([ondark])[variant=flat]:disabled{color:var(--ds-advanced-color-button-flat-text-disabled, #d0d0d0);background-color:transparent;background-image:none;border-color:transparent}.auro-button:not([ondark])[variant=flat]:focus,.auro-button:not([ondark])[variant=flat]:focus-visible{--ds-auro-button-border-color: var(--ds-advanced-color-state-focused, #01426a);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused, #01426a)}.auro-button[ondark]{--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border-inverse, #ffffff);--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background-inverse, #ffffff);--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background-inverse, #ffffff);--ds-auro-button-text-color: var(--ds-advanced-color-button-primary-text-inverse, #01426a);--ds-auro-button-loader-color: var(--ds-advanced-color-button-primary-text-inverse, #01426a)}.auro-button[ondark]:active:not(:disabled),.auro-button[ondark]:hover:not(:disabled){--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border-inverse-hover, #ebf3f9);--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background-inverse-hover, #ebf3f9);--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background-inverse-hover, #ebf3f9)}.auro-button[ondark]:focus,.auro-button[ondark]:focus-visible{--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused, #01426a)}.auro-button[ondark]:disabled{--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border-inverse-disabled, rgba(255, 255, 255, 0.75));--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background-inverse-disabled, rgba(255, 255, 255, 0.75));--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background-inverse-disabled, rgba(255, 255, 255, 0.75));--ds-auro-button-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}.auro-button[ondark][variant=secondary]{--ds-auro-button-container-color: transparent;--ds-auro-button-container-image: transparent;--ds-auro-button-border-color: var(--ds-advanced-color-button-secondary-border-inverse, #ffffff);--ds-auro-button-text-color: var(--ds-advanced-color-button-secondary-text-inverse, #ffffff);--ds-auro-button-loader-color: var(--ds-advanced-color-button-secondary-text-inverse, #ffffff)}.auro-button[ondark][variant=secondary]:active:not(:disabled),.auro-button[ondark][variant=secondary]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-secondary-background-inverse-hover, rgba(255, 255, 255, 0.1));--ds-auro-button-container-image: var(--ds-advanced-color-button-secondary-background-inverse-hover, rgba(255, 255, 255, 0.1))}.auro-button[ondark][variant=secondary]:focus,.auro-button[ondark][variant=secondary]:focus-visible{--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused-inverse, #ffffff)}.auro-button[ondark][variant=secondary]:disabled{--ds-auro-button-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894);--ds-auro-button-border-color: var(--ds-advanced-color-button-secondary-border-inverse-disabled, #dddddd)}.auro-button[ondark][variant=tertiary]{--ds-auro-button-container-color: var(--ds-advanced-color-button-tertiary-background-inverse, rgba(255, 255, 255, 0.05));--ds-auro-button-container-image: var(--ds-advanced-color-button-tertiary-background-inverse, rgba(255, 255, 255, 0.05));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-advanced-color-button-tertiary-text-inverse, #ffffff);--ds-auro-button-loader-color: var(--ds-advanced-color-button-tertiary-text-inverse, #ffffff)}.auro-button[ondark][variant=tertiary]:active:not(:disabled),.auro-button[ondark][variant=tertiary]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-tertiary-background-inverse-hover, rgba(255, 255, 255, 0.1));--ds-auro-button-container-image: var(--ds-advanced-color-button-tertiary-background-inverse-hover, rgba(255, 255, 255, 0.1))}.auro-button[ondark][variant=tertiary]:focus,.auro-button[ondark][variant=tertiary]:focus-visible{--ds-auro-button-border-color: var(--ds-advanced-color-state-focused-inverse, #ffffff);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused-inverse, #ffffff)}.auro-button[ondark][variant=tertiary]:disabled{--ds-auro-button-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}.auro-button[ondark][variant=ghost]{--ds-auro-button-container-color: transparent;--ds-auro-button-container-image: transparent;--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-advanced-color-button-ghost-text-inverse, #ffffff);--ds-auro-button-loader-color: var(--ds-advanced-color-button-ghost-text-inverse, #ffffff)}.auro-button[ondark][variant=ghost]:active:not(:disabled),.auro-button[ondark][variant=ghost]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-advanced-color-button-ghost-background-inverse-hover, rgba(255, 255, 255, 0.05));--ds-auro-button-container-image: var(--ds-advanced-color-button-ghost-background-inverse-hover, rgba(255, 255, 255, 0.05));--ds-auro-button-border-color: transparent}.auro-button[ondark][variant=ghost]:focus,.auro-button[ondark][variant=ghost]:focus-visible{border-color:transparent;--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused-inverse, #ffffff)}.auro-button[ondark][variant=ghost]:disabled{--ds-auro-button-text-color: var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}.auro-button[ondark][variant=flat]{color:var(--ds-advanced-color-button-flat-text-inverse, #ffffff);background-color:transparent;background-image:none;border-color:transparent}.auro-button[ondark][variant=flat]:active:not(:disabled),.auro-button[ondark][variant=flat]:hover:not(:disabled){color:var(--ds-advanced-color-button-flat-text-inverse-hover, #adadad);background-color:transparent;background-image:none;border-color:transparent}.auro-button[ondark][variant=flat]:disabled{color:var(--ds-advanced-color-button-flat-text-inverse-disabled, #7e8894);background-color:transparent;background-image:none;border-color:transparent}.auro-button[ondark][variant=flat]:focus,.auro-button[ondark][variant=flat]:focus-visible{--ds-auro-button-border-color: var(--ds-advanced-color-state-focused-inverse, #ffffff);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused-inverse, #ffffff)}`;
|
|
5933
|
+
|
|
5934
|
+
var tokensCss$2 = css`:host(:not([onDark])){--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border, #01426a);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused-inverse, #ffffff);--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background, #01426a);--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background, #01426a);--ds-auro-button-loader-color: var(--ds-advanced-color-button-primary-text, #ffffff);--ds-auro-button-text-color: var(--ds-advanced-color-button-primary-text, #ffffff);--ds-auro-button-tap-color: transparent}:host([onDark]){--ds-auro-button-border-color: var(--ds-advanced-color-button-primary-border-inverse, #ffffff);--ds-auro-button-border-inset-color: var(--ds-advanced-color-state-focused-inverse, #ffffff);--ds-auro-button-container-color: var(--ds-advanced-color-button-primary-background-inverse, #ffffff);--ds-auro-button-container-image: var(--ds-advanced-color-button-primary-background-inverse, #ffffff);--ds-auro-button-loader-color: var(--ds-advanced-color-button-primary-text-inverse, #01426a);--ds-auro-button-text-color: var(--ds-advanced-color-button-primary-text-inverse, #01426a);--ds-auro-button-tap-color: transparent}`;
|
|
5935
|
+
|
|
5936
|
+
var shapeSize = css`.shape-rounded-xl{min-height:68px;max-height:68px;border-style:solid;overflow:hidden;border-radius:6px}.shape-rounded-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-rounded-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-rounded-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-xl{min-height:68px;max-height:68px;border-style:solid;overflow:hidden;border-radius:36px}.shape-pill-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-left-xl{min-height:68px;max-height:68px;border-style:solid;overflow:hidden;border-radius:36px 0 0 36px}.shape-pill-left-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-left-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-left-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-pill-right-xl{min-height:68px;max-height:68px;border-style:solid;overflow:hidden;border-radius:0 36px 36px 0}.shape-pill-right-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-pill-right-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-pill-right-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-circle-xl{min-height:68px;max-height:68px;border-style:solid;overflow:hidden;border-radius:50%;min-width:72px;max-width:72px;padding:0}.shape-circle-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-circle-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-circle-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-square-xl{min-height:68px;max-height:68px;border-style:solid;overflow:hidden;border-radius:6px;min-width:72px;max-width:72px;padding:0}.shape-square-xl.simple{border-width:0px;min-height:72px;max-height:72px;background-color:unset;box-shadow:none}.shape-square-xl.thin{border-width:1px;min-height:70px;max-height:70px;background-color:unset}.shape-square-xl.parentBorder{border:0;box-shadow:unset;min-height:68px;max-height:68px}.shape-rounded-lg{min-height:52px;max-height:52px;border-style:solid;overflow:hidden;border-radius:6px}.shape-rounded-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-rounded-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-rounded-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-pill-lg{min-height:52px;max-height:52px;border-style:solid;overflow:hidden;border-radius:28px}.shape-pill-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-pill-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-pill-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-pill-left-lg{min-height:52px;max-height:52px;border-style:solid;overflow:hidden;border-radius:28px 0 0 28px}.shape-pill-left-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-pill-left-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-pill-left-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-pill-right-lg{min-height:52px;max-height:52px;border-style:solid;overflow:hidden;border-radius:0 28px 28px 0}.shape-pill-right-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-pill-right-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-pill-right-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-circle-lg{min-height:52px;max-height:52px;border-style:solid;overflow:hidden;border-radius:50%;min-width:56px;max-width:56px;padding:0}.shape-circle-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-circle-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-circle-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-square-lg{min-height:52px;max-height:52px;border-style:solid;overflow:hidden;border-radius:6px;min-width:56px;max-width:56px;padding:0}.shape-square-lg.simple{border-width:0px;min-height:56px;max-height:56px;background-color:unset;box-shadow:none}.shape-square-lg.thin{border-width:1px;min-height:54px;max-height:54px;background-color:unset}.shape-square-lg.parentBorder{border:0;box-shadow:unset;min-height:52px;max-height:52px}.shape-rounded-md{min-height:44px;max-height:44px;border-style:solid;overflow:hidden;border-radius:6px}.shape-rounded-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-rounded-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-rounded-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-md{min-height:44px;max-height:44px;border-style:solid;overflow:hidden;border-radius:24px}.shape-pill-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-left-md{min-height:44px;max-height:44px;border-style:solid;overflow:hidden;border-radius:24px 0 0 24px}.shape-pill-left-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-left-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-left-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-pill-right-md{min-height:44px;max-height:44px;border-style:solid;overflow:hidden;border-radius:0 24px 24px 0}.shape-pill-right-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-pill-right-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-pill-right-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-circle-md{min-height:44px;max-height:44px;border-style:solid;overflow:hidden;border-radius:50%;min-width:48px;max-width:48px;padding:0}.shape-circle-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-circle-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-circle-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-square-md{min-height:44px;max-height:44px;border-style:solid;overflow:hidden;border-radius:6px;min-width:48px;max-width:48px;padding:0}.shape-square-md.simple{border-width:0px;min-height:48px;max-height:48px;background-color:unset;box-shadow:none}.shape-square-md.thin{border-width:1px;min-height:46px;max-height:46px;background-color:unset}.shape-square-md.parentBorder{border:0;box-shadow:unset;min-height:44px;max-height:44px}.shape-rounded-sm{min-height:32px;max-height:32px;border-style:solid;overflow:hidden;border-radius:6px}.shape-rounded-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-rounded-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-rounded-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-pill-sm{min-height:32px;max-height:32px;border-style:solid;overflow:hidden;border-radius:18px}.shape-pill-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-pill-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-pill-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-pill-left-sm{min-height:32px;max-height:32px;border-style:solid;overflow:hidden;border-radius:18px 0 0 18px}.shape-pill-left-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-pill-left-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-pill-left-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-pill-right-sm{min-height:32px;max-height:32px;border-style:solid;overflow:hidden;border-radius:0 18px 18px 0}.shape-pill-right-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-pill-right-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-pill-right-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-circle-sm{min-height:32px;max-height:32px;border-style:solid;overflow:hidden;border-radius:50%;min-width:36px;max-width:36px;padding:0}.shape-circle-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-circle-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-circle-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-square-sm{min-height:32px;max-height:32px;border-style:solid;overflow:hidden;border-radius:6px;min-width:36px;max-width:36px;padding:0}.shape-square-sm.simple{border-width:0px;min-height:36px;max-height:36px;background-color:unset;box-shadow:none}.shape-square-sm.thin{border-width:1px;min-height:34px;max-height:34px;background-color:unset}.shape-square-sm.parentBorder{border:0;box-shadow:unset;min-height:32px;max-height:32px}.shape-rounded-xs{min-height:20px;max-height:20px;border-style:solid;overflow:hidden;border-radius:4px}.shape-rounded-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-rounded-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-rounded-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-pill-xs{min-height:20px;max-height:20px;border-style:solid;overflow:hidden;border-radius:12px}.shape-pill-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-pill-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-pill-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-pill-left-xs{min-height:20px;max-height:20px;border-style:solid;overflow:hidden;border-radius:12px 0 0 12px}.shape-pill-left-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-pill-left-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-pill-left-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-pill-right-xs{min-height:20px;max-height:20px;border-style:solid;overflow:hidden;border-radius:0 12px 12px 0}.shape-pill-right-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-pill-right-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-pill-right-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-circle-xs{min-height:20px;max-height:20px;border-style:solid;overflow:hidden;border-radius:50%;min-width:24px;max-width:24px;padding:0}.shape-circle-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-circle-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-circle-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}.shape-square-xs{min-height:20px;max-height:20px;border-style:solid;overflow:hidden;border-radius:6px;min-width:24px;max-width:24px;padding:0}.shape-square-xs.simple{border-width:0px;min-height:24px;max-height:24px;background-color:unset;box-shadow:none}.shape-square-xs.thin{border-width:1px;min-height:22px;max-height:22px;background-color:unset}.shape-square-xs.parentBorder{border:0;box-shadow:unset;min-height:20px;max-height:20px}`;
|
|
5937
|
+
|
|
5938
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5939
|
+
// See LICENSE in the project root for license information.
|
|
5940
|
+
|
|
5941
|
+
// ---------------------------------------------------------------------
|
|
5942
|
+
|
|
5943
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
5944
|
+
|
|
5945
|
+
let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
5946
|
+
|
|
5947
|
+
/* eslint-disable jsdoc/require-param */
|
|
5948
|
+
|
|
5949
|
+
/**
|
|
5950
|
+
* This will register a new custom element with the browser.
|
|
5951
|
+
* @param {String} name - The name of the custom element.
|
|
5952
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
5953
|
+
* @returns {void}
|
|
5954
|
+
*/
|
|
5955
|
+
registerComponent(name, componentClass) {
|
|
5956
|
+
if (!customElements.get(name)) {
|
|
5957
|
+
customElements.define(name, class extends componentClass {});
|
|
5958
|
+
}
|
|
5959
|
+
}
|
|
5960
|
+
|
|
5961
|
+
/**
|
|
5962
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
5963
|
+
* @returns {void}
|
|
5964
|
+
*/
|
|
5965
|
+
closestElement(
|
|
5966
|
+
selector, // selector like in .closest()
|
|
5967
|
+
base = this, // extra functionality to skip a parent
|
|
5968
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
5969
|
+
!el || el === document || el === window
|
|
5970
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
5971
|
+
: found
|
|
5972
|
+
? found // found a selector INside this element
|
|
5973
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
5974
|
+
) {
|
|
5975
|
+
return __Closest(base);
|
|
5976
|
+
}
|
|
5977
|
+
/* eslint-enable jsdoc/require-param */
|
|
5978
|
+
|
|
5979
|
+
/**
|
|
5980
|
+
* If the element passed is registered with a different tag name than what is passed in, the tag name is added as an attribute to the element.
|
|
5981
|
+
* @param {Object} elem - The element to check.
|
|
5982
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
5983
|
+
* @returns {void}
|
|
5984
|
+
*/
|
|
5985
|
+
handleComponentTagRename(elem, tagName) {
|
|
5986
|
+
const tag = tagName.toLowerCase();
|
|
5987
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
5988
|
+
|
|
5989
|
+
if (elemTag !== tag) {
|
|
5990
|
+
elem.setAttribute(tag, true);
|
|
5991
|
+
}
|
|
5992
|
+
}
|
|
5993
|
+
|
|
5994
|
+
/**
|
|
5995
|
+
* Validates if an element is a specific Auro component.
|
|
5996
|
+
* @param {Object} elem - The element to validate.
|
|
5997
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
5998
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
5999
|
+
*/
|
|
6000
|
+
elementMatch(elem, tagName) {
|
|
6001
|
+
const tag = tagName.toLowerCase();
|
|
6002
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6003
|
+
|
|
6004
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
6005
|
+
}
|
|
6006
|
+
};
|
|
6007
|
+
|
|
6008
|
+
var styleCss$2 = css`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.63)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, 0.88)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3)}:focus:not(:focus-visible){outline:3px solid transparent}:host,:host>span{position:relative}:host{width:2rem;height:2rem;display:inline-block;font-size:0}:host>span{position:absolute;display:inline-block;float:none;top:0;left:0;width:2rem;height:2rem;border-radius:100%;border-style:solid;border-width:0}:host([xs]),:host([xs])>span{width:1.2rem;height:1.2rem}:host([sm]),:host([sm])>span{width:3rem;height:3rem}:host([md]),:host([md])>span{width:5rem;height:5rem}:host([lg]),:host([lg])>span{width:8rem;height:8rem}:host{--margin:0.375rem;--margin-xs:0.2rem;--margin-sm:0.5rem;--margin-md:0.75rem;--margin-lg:1rem}:host([pulse]),:host([pulse])>span{position:relative}:host([pulse]){width:calc(3rem + var(--margin)*6);height:1.5rem}:host([pulse])>span{width:1rem;height:1rem;margin:var(--margin);animation:pulse 1.5s ease infinite}:host([pulse][xs]){width:calc(2.55rem + var(--margin-xs)*6);height:1.55rem}:host([pulse][xs])>span{margin:var(--margin-xs);width:.65rem;height:.65rem}:host([pulse][sm]){width:calc(6rem + var(--margin-sm)*6);height:2.5rem}:host([pulse][sm])>span{margin:var(--margin-sm);width:2rem;height:2rem}:host([pulse][md]){width:calc(9rem + var(--margin-md)*6);height:3.5rem}:host([pulse][md])>span{margin:var(--margin-md);width:3rem;height:3rem}:host([pulse][lg]){width:calc(15rem + var(--margin-lg)*6);height:5.5rem}:host([pulse][lg])>span{margin:var(--margin-lg);width:5rem;height:5rem}:host([pulse])>span:nth-child(1){animation-delay:-400ms}:host([pulse])>span:nth-child(2){animation-delay:-200ms}:host([pulse])>span:nth-child(3){animation-delay:0ms}@keyframes pulse{0%,100%{opacity:.1;transform:scale(0.9)}50%{opacity:1;transform:scale(1.1)}}:host([orbit]),:host([orbit])>span{opacity:1}:host([orbit])>span{border-width:5px}:host([orbit])>span:nth-child(2){animation:orbit 2s linear infinite}:host([orbit][sm])>span{border-width:8px}:host([orbit][md])>span{border-width:13px}:host([orbit][lg])>span{border-width:21px}@keyframes orbit{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}:host([ringworm])>svg{animation:rotate 2s linear infinite;height:100%;width:100%;stroke:currentcolor;stroke-width:8}:host([ringworm]) .path{stroke-dashoffset:0;animation:ringworm 1.5s ease-in-out infinite;stroke-linecap:round}@keyframes rotate{100%{transform:rotate(360deg)}}@keyframes ringworm{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}:host([laser]){position:static;width:100%;display:block;height:0;overflow:hidden;font-size:unset}:host([laser])>span{position:fixed;width:100%;height:.25rem;border-radius:0;z-index:100}:host([laser])>span:nth-child(1){border-color:currentcolor;opacity:.25}:host([laser])>span:nth-child(2){border-color:currentcolor;animation:laser 2s linear infinite;opacity:1;width:50%}:host([laser][sm])>span:nth-child(2){width:20%}:host([laser][md])>span:nth-child(2){width:30%}:host([laser][lg])>span:nth-child(2){width:50%;animation-duration:1.5s}:host([laser][xl])>span:nth-child(2){width:80%;animation-duration:1.5s}@keyframes laser{0%{left:-100%}100%{left:110%}}:host>.no-animation{display:none}@media(prefers-reduced-motion: reduce){:host{display:flex;align-items:center;justify-content:center}:host>span{opacity:1}:host>.loader{display:none}:host>svg{display:none}:host>.no-animation{display:block}}`;
|
|
6009
|
+
|
|
6010
|
+
var colorCss$1 = css`:host{color:var(--ds-auro-loader-color)}:host>span{background-color:var(--ds-auro-loader-background-color);border-color:var(--ds-auro-loader-border-color)}:host([onlight]){--ds-auro-loader-color:var(--ds-basic-color-brand-primary, #01426a)}:host([ondark]){--ds-auro-loader-color:var(--ds-basic-color-texticon-inverse, #ffffff)}:host([orbit])>span{--ds-auro-loader-background-color:transparent}:host([orbit])>span:nth-child(1){--ds-auro-loader-border-color:currentcolor;opacity:.25}:host([orbit])>span:nth-child(2){--ds-auro-loader-border-color:currentcolor;border-right-color:transparent;border-bottom-color:transparent;border-left-color:transparent}`;
|
|
6011
|
+
|
|
6012
|
+
var tokensCss$1 = css`:host{--ds-auro-loader-background-color:currentcolor;--ds-auro-loader-border-color:currentcolor;--ds-auro-loader-color:currentcolor}`;
|
|
6013
|
+
|
|
6014
|
+
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
6015
|
+
// See LICENSE in the project root for license information.
|
|
6016
|
+
|
|
6017
|
+
|
|
6018
|
+
class AuroLoader extends LitElement {
|
|
6019
|
+
constructor() {
|
|
6020
|
+
super();
|
|
6021
|
+
|
|
6022
|
+
/**
|
|
6023
|
+
* @private
|
|
6024
|
+
*/
|
|
6025
|
+
this.keys = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9];
|
|
6026
|
+
|
|
6027
|
+
/**
|
|
6028
|
+
* @private
|
|
6029
|
+
*/
|
|
6030
|
+
this.mdCount = 3;
|
|
6031
|
+
|
|
6032
|
+
/**
|
|
6033
|
+
* @private
|
|
6034
|
+
*/
|
|
6035
|
+
this.smCount = 2;
|
|
6036
|
+
|
|
6037
|
+
/**
|
|
6038
|
+
* @private
|
|
6039
|
+
*/
|
|
6040
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$1();
|
|
6041
|
+
|
|
6042
|
+
this.orbit = false;
|
|
6043
|
+
this.ringworm = false;
|
|
6044
|
+
this.laser = false;
|
|
6045
|
+
this.pulse = false;
|
|
6046
|
+
}
|
|
6047
|
+
|
|
6048
|
+
// function to define props used within the scope of this component
|
|
6049
|
+
static get properties() {
|
|
6050
|
+
return {
|
|
6051
|
+
|
|
6052
|
+
/**
|
|
6053
|
+
* Sets loader to laser type.
|
|
6054
|
+
*/
|
|
6055
|
+
laser: {
|
|
6056
|
+
type: Boolean,
|
|
6057
|
+
reflect: true
|
|
6058
|
+
},
|
|
6059
|
+
|
|
6060
|
+
/**
|
|
6061
|
+
* Sets loader to orbit type.
|
|
6062
|
+
*/
|
|
6063
|
+
orbit: {
|
|
6064
|
+
type: Boolean,
|
|
6065
|
+
reflect: true
|
|
6066
|
+
},
|
|
6067
|
+
|
|
6068
|
+
/**
|
|
6069
|
+
* Sets loader to pulse type.
|
|
6070
|
+
*/
|
|
6071
|
+
pulse: {
|
|
6072
|
+
type: Boolean,
|
|
6073
|
+
reflect: true
|
|
6074
|
+
},
|
|
6075
|
+
|
|
6076
|
+
/**
|
|
6077
|
+
* Sets loader to ringworm type.
|
|
6078
|
+
*/
|
|
6079
|
+
ringworm: {
|
|
6080
|
+
type: Boolean,
|
|
6081
|
+
reflect: true
|
|
6082
|
+
}
|
|
6083
|
+
};
|
|
6084
|
+
}
|
|
6085
|
+
|
|
6086
|
+
static get styles() {
|
|
6087
|
+
return [
|
|
6088
|
+
css`${styleCss$2}`,
|
|
6089
|
+
css`${colorCss$1}`,
|
|
6090
|
+
css`${tokensCss$1}`
|
|
6091
|
+
];
|
|
6092
|
+
}
|
|
6093
|
+
|
|
6094
|
+
/**
|
|
6095
|
+
* This will register this element with the browser.
|
|
6096
|
+
* @param {string} [name="auro-loader"] - The name of element that you want to register to.
|
|
6097
|
+
*
|
|
6098
|
+
* @example
|
|
6099
|
+
* AuroLoader.register("custom-loader") // this will register this element to <custom-loader/>
|
|
6100
|
+
*
|
|
6101
|
+
*/
|
|
6102
|
+
static register(name = "auro-loader") {
|
|
6103
|
+
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroLoader);
|
|
6104
|
+
}
|
|
6105
|
+
|
|
6106
|
+
firstUpdated() {
|
|
6107
|
+
// Add the tag name as an attribute if it is different than the component name
|
|
6108
|
+
this.runtimeUtils.handleComponentTagRename(this, 'auro-loader');
|
|
6109
|
+
}
|
|
6110
|
+
|
|
6111
|
+
connectedCallback() {
|
|
6112
|
+
super.connectedCallback();
|
|
6113
|
+
}
|
|
6114
|
+
|
|
6115
|
+
/**
|
|
6116
|
+
* @private
|
|
6117
|
+
* @returns {Array} Numbered array for template map.
|
|
6118
|
+
*/
|
|
6119
|
+
defineTemplate() {
|
|
6120
|
+
let nodes = Array.from(Array(this.mdCount).keys());
|
|
6121
|
+
|
|
6122
|
+
if (this.orbit || this.laser) {
|
|
6123
|
+
nodes = Array.from(Array(this.smCount).keys());
|
|
6124
|
+
} else if (this.ringworm) {
|
|
6125
|
+
nodes = Array.from(Array(0).keys());
|
|
6126
|
+
}
|
|
6127
|
+
|
|
6128
|
+
return nodes;
|
|
6129
|
+
}
|
|
6130
|
+
|
|
6131
|
+
// When using auroElement, use the following attribute and function when hiding content from screen readers.
|
|
6132
|
+
// aria-hidden="${this.hideAudible(this.hiddenAudible)}"
|
|
6133
|
+
|
|
6134
|
+
// function that renders the HTML and CSS into the scope of the component
|
|
6135
|
+
render() {
|
|
6136
|
+
return html$1`
|
|
6137
|
+
${this.defineTemplate().map((idx) => html$1`
|
|
6138
|
+
<span part="element" class="loader node-${idx}"></span>
|
|
6139
|
+
`)}
|
|
6140
|
+
|
|
6141
|
+
<div class="no-animation body-default">Loading...</div>
|
|
6142
|
+
|
|
6143
|
+
${this.ringworm ? html$1`
|
|
6144
|
+
<svg part="element" class="circular" viewBox="25 25 50 50">
|
|
6145
|
+
<circle class="path" cx="50" cy="50" r="20" fill="none"/>
|
|
6146
|
+
</svg>`
|
|
6147
|
+
: ``
|
|
6148
|
+
}
|
|
6149
|
+
`;
|
|
6150
|
+
}
|
|
6151
|
+
}
|
|
6152
|
+
|
|
6153
|
+
var loaderVersion = '5.1.0';
|
|
6154
|
+
|
|
6155
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6156
|
+
// See LICENSE in the project root for license information.
|
|
6157
|
+
|
|
6158
|
+
|
|
6159
|
+
/**
|
|
6160
|
+
* @slot - Default slot for the text of the button.
|
|
6161
|
+
* @csspart button - Apply CSS to HTML5 button.
|
|
6162
|
+
* @csspart loader - Apply CSS to auro-loader.
|
|
6163
|
+
* @csspart text - Apply CSS to text slot.
|
|
6164
|
+
* @csspart icon - Apply CSS to icon slot.
|
|
6165
|
+
*/
|
|
6166
|
+
|
|
6167
|
+
const ICON_ONLY_SHAPES = ['circle', 'square'];
|
|
6168
|
+
|
|
6169
|
+
/**
|
|
6170
|
+
* AuroButton is a custom element that provides a styled, accessible button with support for various states and form association.
|
|
6171
|
+
* It is designed to be flexible, supporting loading states, icon slots, and integration with HTML5 forms.
|
|
6172
|
+
* @property {'default', 'rounded', 'pill', 'circle', 'square'} shape - Defines the shape of the button.
|
|
6173
|
+
* @property {'xs', 'sm', 'md', 'lg', 'xl'} size - Defines the size of the button.
|
|
6174
|
+
* @property {'primary', 'secondary', 'tertiary', 'ghost', 'flat'} variant - Sets the button variant.
|
|
6175
|
+
* @property {'submit', 'reset', 'button'} type - The type of button. Matches HTML5 Button Spec.
|
|
6176
|
+
* @property {boolean} onDark - Indicates if the button is rendered in dark mode.
|
|
6177
|
+
*/
|
|
6178
|
+
class AuroButton extends AuroElement$1 {
|
|
6179
|
+
|
|
6180
|
+
/**
|
|
6181
|
+
* Enables form association for this element.
|
|
6182
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/attachInternals
|
|
6183
|
+
* @returns {boolean} - Returns true to enable form association.
|
|
6184
|
+
*/
|
|
6185
|
+
static get formAssociated() {
|
|
6186
|
+
return true;
|
|
6187
|
+
}
|
|
6188
|
+
|
|
6189
|
+
constructor() {
|
|
6190
|
+
super();
|
|
6191
|
+
this.autofocus = false;
|
|
6192
|
+
this.disabled = false;
|
|
6193
|
+
this.loading = false;
|
|
6194
|
+
this.size = "md";
|
|
6195
|
+
this.shape = "rounded";
|
|
6196
|
+
this.onDark = false;
|
|
6197
|
+
this.fluid = false;
|
|
6198
|
+
this.loadingText = this.loadingText || 'Loading...';
|
|
6199
|
+
this.variant = 'primary';
|
|
6200
|
+
|
|
6201
|
+
// Support for HTML5 forms
|
|
6202
|
+
if (typeof this.attachInternals === 'function') {
|
|
6203
|
+
this.internals = this.attachInternals();
|
|
6204
|
+
} else {
|
|
6205
|
+
this.internals = null;
|
|
6206
|
+
|
|
6207
|
+
// eslint-disable-next-line no-console
|
|
6208
|
+
console.warn('This browser does not support form association features. Some form-related functionality may not work as expected. Consider using a polyfill or handling click events manually.');
|
|
6209
|
+
}
|
|
6210
|
+
|
|
6211
|
+
/**
|
|
6212
|
+
* Generate unique names for dependency components.
|
|
6213
|
+
*/
|
|
6214
|
+
const versioning = new AuroDependencyVersioning();
|
|
6215
|
+
|
|
6216
|
+
/**
|
|
6217
|
+
* @private
|
|
6218
|
+
*/
|
|
6219
|
+
this.loaderTag = versioning.generateTag('auro-loader', loaderVersion, AuroLoader);
|
|
6220
|
+
|
|
6221
|
+
/**
|
|
6222
|
+
* @private
|
|
6223
|
+
*/
|
|
6224
|
+
this.buttonHref = undefined;
|
|
6225
|
+
|
|
6226
|
+
/**
|
|
6227
|
+
* @private
|
|
6228
|
+
*/
|
|
6229
|
+
this.buttonTarget = undefined;
|
|
6230
|
+
|
|
6231
|
+
/**
|
|
6232
|
+
* @private
|
|
6233
|
+
*/
|
|
6234
|
+
this.buttonRel = undefined;
|
|
6235
|
+
}
|
|
6236
|
+
|
|
6237
|
+
static get styles() {
|
|
6238
|
+
return [
|
|
6239
|
+
tokensCss$2,
|
|
6240
|
+
styleCss$3,
|
|
6241
|
+
colorCss$2,
|
|
6242
|
+
shapeSize
|
|
6243
|
+
];
|
|
6244
|
+
}
|
|
6245
|
+
|
|
6246
|
+
static get properties() {
|
|
6247
|
+
return {
|
|
6248
|
+
|
|
6249
|
+
...super.properties,
|
|
6250
|
+
|
|
6251
|
+
/**
|
|
6252
|
+
* Override layout since it isn't used in this component.
|
|
6253
|
+
* @private
|
|
6254
|
+
*/
|
|
6255
|
+
layout: {
|
|
6256
|
+
type: Boolean,
|
|
6257
|
+
attribute: false,
|
|
6258
|
+
reflect: false
|
|
6259
|
+
},
|
|
6260
|
+
|
|
6261
|
+
/**
|
|
6262
|
+
* This Boolean attribute lets you specify that the button should have input focus when the page loads, unless overridden by the user.
|
|
6263
|
+
*/
|
|
6264
|
+
autofocus: {
|
|
6265
|
+
type: Boolean,
|
|
6266
|
+
reflect: true
|
|
6267
|
+
},
|
|
6268
|
+
|
|
6269
|
+
/**
|
|
6270
|
+
* If set to true, button will become disabled and not allow for interactions.
|
|
6271
|
+
*/
|
|
6272
|
+
disabled: {
|
|
6273
|
+
type: Boolean,
|
|
6274
|
+
reflect: true
|
|
6275
|
+
},
|
|
6276
|
+
|
|
6277
|
+
/**
|
|
6278
|
+
* Alters the shape of the button to be full width of its parent container.
|
|
6279
|
+
*/
|
|
6280
|
+
fluid: {
|
|
6281
|
+
type: Boolean,
|
|
6282
|
+
reflect: true
|
|
6283
|
+
},
|
|
6284
|
+
|
|
6285
|
+
/**
|
|
6286
|
+
* If set to true button text will be replaced with `auro-loader` and become disabled.
|
|
6287
|
+
*/
|
|
6288
|
+
loading: {
|
|
6289
|
+
type: Boolean,
|
|
6290
|
+
reflect: true
|
|
6291
|
+
},
|
|
6292
|
+
|
|
6293
|
+
/**
|
|
6294
|
+
* Sets custom loading text for the `aria-label` on a button in loading state. If not set, the default value of "Loading..." will be used.
|
|
6295
|
+
*/
|
|
6296
|
+
loadingText: {
|
|
6297
|
+
type: String
|
|
6298
|
+
},
|
|
6299
|
+
|
|
6300
|
+
/**
|
|
6301
|
+
* Populates `tabindex` to define the focusable sequence in keyboard navigation.
|
|
6302
|
+
*/
|
|
6303
|
+
tIndex: {
|
|
6304
|
+
type: String,
|
|
6305
|
+
reflect: true
|
|
6306
|
+
},
|
|
6307
|
+
|
|
6308
|
+
/**
|
|
6309
|
+
* Populates `tabindex` to define the focusable sequence in keyboard navigation.
|
|
6310
|
+
* Must be used with "." to ensure the host element does not retain a reference to the `tabindex` attribute.
|
|
6311
|
+
* Example: `<auro-button .tabindex="${this.disabled ? '-1' : '0'}"></auro-button>`.
|
|
6312
|
+
*/
|
|
6313
|
+
tabindex: {
|
|
6314
|
+
type: String,
|
|
6315
|
+
reflect: false
|
|
6316
|
+
},
|
|
6317
|
+
|
|
6318
|
+
/**
|
|
6319
|
+
* Sets title attribute. The information is most often shown as a tooltip text when the mouse moves over the element.
|
|
6320
|
+
*/
|
|
6321
|
+
title: {
|
|
6322
|
+
type: String,
|
|
6323
|
+
reflect: true
|
|
6324
|
+
},
|
|
6325
|
+
|
|
6326
|
+
/**
|
|
6327
|
+
* The type of the button. Possible values are: `submit`, `reset`, `button`.
|
|
6328
|
+
*/
|
|
6329
|
+
type: {
|
|
6330
|
+
type: String,
|
|
6331
|
+
reflect: true
|
|
6332
|
+
},
|
|
6333
|
+
|
|
6334
|
+
/**
|
|
6335
|
+
* Defines the value associated with the button which is submitted with the form data.
|
|
6336
|
+
*/
|
|
6337
|
+
value: {
|
|
6338
|
+
type: String,
|
|
6339
|
+
reflect: true
|
|
6340
|
+
},
|
|
6341
|
+
|
|
6342
|
+
/**
|
|
6343
|
+
* Sets button variant option.
|
|
6344
|
+
* @default primary
|
|
6345
|
+
*/
|
|
6346
|
+
variant: {
|
|
6347
|
+
type: String,
|
|
6348
|
+
reflect: true
|
|
6349
|
+
},
|
|
6350
|
+
|
|
6351
|
+
/**
|
|
6352
|
+
* @private
|
|
6353
|
+
*/
|
|
6354
|
+
buttonHref: {
|
|
6355
|
+
type: String,
|
|
6356
|
+
},
|
|
6357
|
+
|
|
6358
|
+
/**
|
|
6359
|
+
* @private
|
|
6360
|
+
*/
|
|
6361
|
+
buttonTarget: {
|
|
6362
|
+
type: String,
|
|
6363
|
+
},
|
|
6364
|
+
|
|
6365
|
+
/**
|
|
6366
|
+
* @private
|
|
6367
|
+
*/
|
|
6368
|
+
buttonRel: {
|
|
6369
|
+
type: String,
|
|
6370
|
+
},
|
|
6371
|
+
};
|
|
6372
|
+
}
|
|
6373
|
+
|
|
6374
|
+
/**
|
|
6375
|
+
* This will register this element with the browser.
|
|
6376
|
+
* @param {string} [name="auro-button"] - The name of element that you want to register to.
|
|
6377
|
+
*
|
|
6378
|
+
* @example
|
|
6379
|
+
* AuroButton.register("custom-button") // this will register this element to <custom-button/>
|
|
6380
|
+
*
|
|
5093
6381
|
*/
|
|
5094
|
-
|
|
5095
|
-
|
|
5096
|
-
'helpText': true,
|
|
5097
|
-
'leftIndent': true,
|
|
5098
|
-
'rightIndent': true
|
|
5099
|
-
};
|
|
5100
|
-
|
|
5101
|
-
return html`
|
|
5102
|
-
${this.renderBasicHtml(helpTextClasses)}
|
|
5103
|
-
`;
|
|
6382
|
+
static register(name = "auro-button") {
|
|
6383
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroButton);
|
|
5104
6384
|
}
|
|
5105
6385
|
|
|
5106
6386
|
/**
|
|
5107
|
-
*
|
|
6387
|
+
* Internal method to apply focus to the HTML5 button.
|
|
5108
6388
|
* @private
|
|
5109
|
-
* @returns {
|
|
6389
|
+
* @returns {void}
|
|
5110
6390
|
*/
|
|
5111
|
-
|
|
5112
|
-
|
|
5113
|
-
'helpText': true,
|
|
5114
|
-
'leftIndent': this.shape.toLowerCase().includes('pill') && !this.shape.toLowerCase().includes('right'),
|
|
5115
|
-
'rightIndent': this.shape.toLowerCase().includes('pill') && !this.shape.toLowerCase().includes('left')
|
|
5116
|
-
};
|
|
5117
|
-
|
|
5118
|
-
return html`
|
|
5119
|
-
${this.renderBasicHtml(helpTextClasses)}
|
|
5120
|
-
`;
|
|
6391
|
+
focus() {
|
|
6392
|
+
this.renderRoot.querySelector('button').focus();
|
|
5121
6393
|
}
|
|
5122
6394
|
|
|
5123
6395
|
/**
|
|
5124
|
-
*
|
|
6396
|
+
* Submits the form that this button is associated with.
|
|
5125
6397
|
* @private
|
|
5126
|
-
* @
|
|
5127
|
-
* @returns {HTMLCollection} - Returns the HTML for the layout.
|
|
6398
|
+
* @returns {void}
|
|
5128
6399
|
*/
|
|
5129
|
-
|
|
5130
|
-
|
|
5131
|
-
|
|
5132
|
-
switch (layout) {
|
|
5133
|
-
case 'emphasized':
|
|
5134
|
-
return this.renderLayoutEmphasized();
|
|
5135
|
-
case 'emphasized-left':
|
|
5136
|
-
return this.renderLayoutEmphasized();
|
|
5137
|
-
case 'emphasized-right':
|
|
5138
|
-
return this.renderLayoutEmphasized();
|
|
5139
|
-
case 'snowflake':
|
|
5140
|
-
return this.renderLayoutSnowflake();
|
|
5141
|
-
case 'snowflake-left':
|
|
5142
|
-
return this.renderLayoutSnowflake();
|
|
5143
|
-
case 'snowflake-right':
|
|
5144
|
-
return this.renderLayoutSnowflake();
|
|
5145
|
-
default:
|
|
5146
|
-
return this.renderLayoutClassic();
|
|
6400
|
+
surfaceSubmitEvent() {
|
|
6401
|
+
if (this.form) {
|
|
6402
|
+
this.form.requestSubmit();
|
|
5147
6403
|
}
|
|
5148
6404
|
}
|
|
5149
|
-
}
|
|
5150
|
-
|
|
5151
|
-
var dropdownVersion = '3.0.0';
|
|
5152
|
-
|
|
5153
|
-
var colorCss$1 = css`#headerContainer{box-shadow:var(--ds-auro-dropdownbib-header-boxshadow-color)}#footerContainer{background-color:var(--ds-auro-dropdownbib-footer-container-color)}`;
|
|
5154
|
-
|
|
5155
|
-
var styleCss$2 = css`#bibTemplate{display:flex;overflow:hidden;height:100%;max-height:100%;flex-direction:column}#headerContainer{display:flex;flex-direction:column}#header{display:flex;width:100%;min-height:var(--ds-size-1000, 5rem);box-sizing:border-box;align-items:end;padding-top:var(--ds-size-400, 2rem);padding-right:var(--ds-size-700, 3.5rem);padding-left:var(--ds-size-200, 1rem);pointer-events:none}#subheader{width:100%}#subheader ::slotted([auro-input]){padding:0 var(--ds-size-200, 1rem)}#closeButton{position:absolute;top:var(--ds-size-400, 2rem);right:var(--ds-size-200, 1rem);border:none;background-color:transparent;cursor:pointer}#closeButton [auro-icon]{--ds-auro-icon-size: var(--ds-size-500, 2.5rem)}#bodyContainer{position:relative;overflow:auto;flex:1 1 100%}:host([isfullscreen]) #bibTemplate{max-height:100dvh}:host([isfullscreen]) #bodyContainer{margin-top:var(--ds-size-100, 0.5rem)}#footerContainer{position:absolute;right:0;bottom:0;left:0;padding:var(--ds-size-200, 1rem)}`;
|
|
5156
|
-
|
|
5157
|
-
var tokenCss = css`:host{--ds-auro-dropdownbib-header-boxshadow-color: var(--ds-elevation-200, 0px 0px 10px rgba(0, 0, 0, 0.15));--ds-auro-dropdownbib-footer-container-color: var(--ds-basic-color-surface-default, #ffffff)}`;
|
|
5158
|
-
|
|
5159
|
-
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5160
|
-
// See LICENSE in the project root for license information.
|
|
5161
|
-
|
|
5162
|
-
// ---------------------------------------------------------------------
|
|
5163
|
-
|
|
5164
|
-
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
5165
|
-
|
|
5166
|
-
let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
5167
|
-
|
|
5168
|
-
/* eslint-disable jsdoc/require-param */
|
|
5169
6405
|
|
|
5170
6406
|
/**
|
|
5171
|
-
*
|
|
5172
|
-
* @
|
|
5173
|
-
* @
|
|
5174
|
-
* @returns {void}
|
|
6407
|
+
* Returns the form element that this button is associated with.
|
|
6408
|
+
* @private
|
|
6409
|
+
* @returns {HTMLFormElement | null}
|
|
5175
6410
|
*/
|
|
5176
|
-
|
|
5177
|
-
|
|
5178
|
-
customElements.define(name, class extends componentClass {});
|
|
5179
|
-
}
|
|
6411
|
+
get form() {
|
|
6412
|
+
return this.internals ? this.internals.form : null;
|
|
5180
6413
|
}
|
|
5181
6414
|
|
|
5182
6415
|
/**
|
|
5183
|
-
*
|
|
5184
|
-
* @returns {
|
|
6416
|
+
* @private
|
|
6417
|
+
* @returns {Boolean}
|
|
5185
6418
|
*/
|
|
5186
|
-
|
|
5187
|
-
|
|
5188
|
-
base = this, // extra functionality to skip a parent
|
|
5189
|
-
__Closest = (el, found = el && el.closest(selector)) =>
|
|
5190
|
-
!el || el === document || el === window
|
|
5191
|
-
? null // standard .closest() returns null for non-found selectors also
|
|
5192
|
-
: found
|
|
5193
|
-
? found // found a selector INside this element
|
|
5194
|
-
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
5195
|
-
) {
|
|
5196
|
-
return __Closest(base);
|
|
6419
|
+
get showText() {
|
|
6420
|
+
return !ICON_ONLY_SHAPES.includes(this.shape);
|
|
5197
6421
|
}
|
|
5198
|
-
/* eslint-enable jsdoc/require-param */
|
|
5199
6422
|
|
|
5200
6423
|
/**
|
|
5201
|
-
*
|
|
5202
|
-
* @
|
|
5203
|
-
* @
|
|
5204
|
-
* @returns {void}
|
|
6424
|
+
* Returns the current value of the projected `aria-label` attribute or undefined if not set.
|
|
6425
|
+
* @returns {string | undefined}
|
|
6426
|
+
* @private
|
|
5205
6427
|
*/
|
|
5206
|
-
|
|
5207
|
-
|
|
5208
|
-
const elemTag = elem.tagName.toLowerCase();
|
|
6428
|
+
get currentAriaLabel() {
|
|
6429
|
+
if (!this.attributeWatcher) return undefined;
|
|
5209
6430
|
|
|
5210
|
-
|
|
5211
|
-
|
|
5212
|
-
}
|
|
6431
|
+
const ariaLabel = this.attributeWatcher.getObservedAttribute("aria-label");
|
|
6432
|
+
return ariaLabel || undefined;
|
|
5213
6433
|
}
|
|
5214
6434
|
|
|
5215
6435
|
/**
|
|
5216
|
-
*
|
|
5217
|
-
* @
|
|
5218
|
-
* @
|
|
5219
|
-
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
6436
|
+
* Returns the current value of the projected `aria-labelledby` attribute or undefined if not set.
|
|
6437
|
+
* @returns {string | undefined}
|
|
6438
|
+
* @private
|
|
5220
6439
|
*/
|
|
5221
|
-
|
|
5222
|
-
|
|
5223
|
-
const elemTag = elem.tagName.toLowerCase();
|
|
6440
|
+
get currentAriaLabelledBy() {
|
|
6441
|
+
if (!this.attributeWatcher) return undefined;
|
|
5224
6442
|
|
|
5225
|
-
|
|
6443
|
+
const ariaLabelledBy = this.attributeWatcher.getObservedAttribute("aria-labelledby");
|
|
6444
|
+
return ariaLabelledBy || undefined;
|
|
5226
6445
|
}
|
|
5227
|
-
};
|
|
5228
|
-
|
|
5229
|
-
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5230
|
-
// See LICENSE in the project root for license information.
|
|
5231
|
-
|
|
5232
6446
|
|
|
5233
|
-
|
|
6447
|
+
/**
|
|
6448
|
+
* Whether or not the button is set to an icon-only shape.
|
|
6449
|
+
* @returns {boolean} - True if the button is icon-only, false otherwise.
|
|
6450
|
+
* @private
|
|
6451
|
+
*/
|
|
6452
|
+
get iconOnly() {
|
|
6453
|
+
return ICON_ONLY_SHAPES.includes(this.shape);
|
|
6454
|
+
}
|
|
5234
6455
|
|
|
5235
6456
|
/**
|
|
5236
|
-
*
|
|
6457
|
+
* Gets a class name for the font size based on the button's size and shape.
|
|
6458
|
+
* @returns {string} - The font size class name.
|
|
5237
6459
|
* @private
|
|
5238
|
-
* @param {string} baseName - Defines the first part of the unique element name.
|
|
5239
|
-
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
5240
|
-
* @returns {string} - Unique string to be used for naming.
|
|
5241
6460
|
*/
|
|
5242
|
-
|
|
5243
|
-
let result = baseName;
|
|
6461
|
+
getFontSize() {
|
|
5244
6462
|
|
|
5245
|
-
|
|
5246
|
-
|
|
6463
|
+
// Size map for standard buttons
|
|
6464
|
+
const standardButtonSizeMap = {
|
|
6465
|
+
xs: 'body-xs',
|
|
6466
|
+
sm: 'body-sm',
|
|
6467
|
+
md: 'body-default',
|
|
6468
|
+
lg: 'body-lg',
|
|
6469
|
+
xl: 'body-lg'
|
|
6470
|
+
};
|
|
5247
6471
|
|
|
5248
|
-
|
|
6472
|
+
// Size map for icon-only buttons
|
|
6473
|
+
const iconOnlyButtonSizeMap = {
|
|
6474
|
+
xs: 'heading-xs',
|
|
6475
|
+
sm: 'heading-sm',
|
|
6476
|
+
md: 'heading-sm',
|
|
6477
|
+
lg: 'heading-md',
|
|
6478
|
+
xl: 'heading-lg'
|
|
6479
|
+
};
|
|
6480
|
+
|
|
6481
|
+
// Determine which map to use based on the shape
|
|
6482
|
+
const sizeMap = this.iconOnly ? iconOnlyButtonSizeMap : standardButtonSizeMap;
|
|
6483
|
+
|
|
6484
|
+
// Return the font size based on the button size and shape
|
|
6485
|
+
return sizeMap[this.size] || 'body-default';
|
|
5249
6486
|
}
|
|
5250
6487
|
|
|
5251
6488
|
/**
|
|
5252
|
-
*
|
|
5253
|
-
* @
|
|
5254
|
-
* @
|
|
5255
|
-
* @returns {string} - Unique string to be used for naming.
|
|
6489
|
+
* Renders the default layout for the button.
|
|
6490
|
+
* @returns {TemplateResult}
|
|
6491
|
+
* @private
|
|
5256
6492
|
*/
|
|
5257
|
-
|
|
5258
|
-
const elementName = this.generateElementName(baseName, version);
|
|
5259
|
-
const tag = literal`${unsafeStatic(elementName)}`;
|
|
6493
|
+
renderLayoutDefault() {
|
|
5260
6494
|
|
|
5261
|
-
|
|
5262
|
-
|
|
5263
|
-
|
|
6495
|
+
const fontSize = this.getFontSize();
|
|
6496
|
+
const tag = this.buttonHref ? literal`a` : literal`button`;
|
|
6497
|
+
const part = this.buttonHref ? 'link' : 'button';
|
|
5264
6498
|
|
|
5265
|
-
|
|
6499
|
+
const classes = {
|
|
6500
|
+
"auro-button": true,
|
|
6501
|
+
"inset": this.showText,
|
|
6502
|
+
wrapper: true,
|
|
6503
|
+
loading: this.loading,
|
|
6504
|
+
[`${fontSize}`]: true,
|
|
6505
|
+
|
|
6506
|
+
// These remove the default borders so we can handle focus borders ourselves
|
|
6507
|
+
'simple': !['secondary'].includes(this.variant),
|
|
6508
|
+
'thin': ['secondary'].includes(this.variant),
|
|
6509
|
+
};
|
|
6510
|
+
|
|
6511
|
+
const contentClasses = {
|
|
6512
|
+
"contentWrapper": true,
|
|
6513
|
+
"util_displayHiddenVisually": this.loading
|
|
6514
|
+
};
|
|
6515
|
+
|
|
6516
|
+
return html`
|
|
6517
|
+
<${tag}
|
|
6518
|
+
part="${part}"
|
|
6519
|
+
aria-label="${ifDefined(this.loading ? this.loadingText : this.currentAriaLabel || undefined)}"
|
|
6520
|
+
aria-labelledby="${ifDefined(this.loading ? undefined : this.currentAriaLabelledBy || undefined)}"
|
|
6521
|
+
tabindex="${ifDefined(this.tIndex || this.tabindex)}"
|
|
6522
|
+
?autofocus="${this.autofocus}"
|
|
6523
|
+
class=${classMap(classes)}
|
|
6524
|
+
?disabled="${this.disabled || this.loading}"
|
|
6525
|
+
?onDark="${this.onDark}"
|
|
6526
|
+
title="${ifDefined(this.title ? this.title : undefined)}"
|
|
6527
|
+
name="${ifDefined(this.name ? this.name : undefined)}"
|
|
6528
|
+
type="${ifDefined(this.type ? this.type : undefined)}"
|
|
6529
|
+
variant="${ifDefined(this.variant ? this.variant : undefined)}"
|
|
6530
|
+
.value="${ifDefined(this.value ? this.value : undefined)}"
|
|
6531
|
+
@click="${this.type === 'submit' ? this.surfaceSubmitEvent : undefined}"
|
|
6532
|
+
href="${ifDefined(this.buttonHref || undefined)}"
|
|
6533
|
+
target="${ifDefined(this.buttonTarget || undefined)}"
|
|
6534
|
+
rel="${ifDefined(this.buttonRel || undefined)}"
|
|
6535
|
+
>
|
|
6536
|
+
${ifDefined(this.loading ? html`<${this.loaderTag} pulse part="loader"></${this.loaderTag}>` : undefined)}
|
|
6537
|
+
|
|
6538
|
+
<span class="${classMap(contentClasses)}">
|
|
6539
|
+
<span class="textSlot" part="text">
|
|
6540
|
+
<slot></slot>
|
|
6541
|
+
</span>
|
|
6542
|
+
</span>
|
|
6543
|
+
</${tag}>
|
|
6544
|
+
`;
|
|
6545
|
+
}
|
|
6546
|
+
|
|
6547
|
+
/**
|
|
6548
|
+
* Renders the layout of the button.
|
|
6549
|
+
* @returns {TemplateResult}
|
|
6550
|
+
* @private
|
|
6551
|
+
*/
|
|
6552
|
+
renderLayout() {
|
|
6553
|
+
return this.renderLayoutDefault();
|
|
5266
6554
|
}
|
|
5267
6555
|
}
|
|
5268
6556
|
|
|
6557
|
+
var buttonVersion = '11.3.0';
|
|
6558
|
+
|
|
5269
6559
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5270
6560
|
// See LICENSE in the project root for license information.
|
|
5271
6561
|
|
|
@@ -5416,9 +6706,9 @@ class BaseIcon extends AuroElement {
|
|
|
5416
6706
|
}
|
|
5417
6707
|
}
|
|
5418
6708
|
|
|
5419
|
-
var tokensCss$
|
|
6709
|
+
var tokensCss$3 = css`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-alaska-color:#02426D;--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}`;
|
|
5420
6710
|
|
|
5421
|
-
var colorCss$
|
|
6711
|
+
var colorCss$4 = css`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[variant=accent1]){--ds-auro-icon-color:var(--ds-basic-color-texticon-accent1, #265688)}:host(:not([onDark])[variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:not([onDark])[variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-muted, #676767)}:host(:not([onDark])[variant=statusDefault]){--ds-auro-icon-color:var(--ds-basic-color-status-default, #afb9c6)}:host(:not([onDark])[variant=statusInfo]){--ds-auro-icon-color:var(--ds-basic-color-status-info, #01426a)}:host(:not([onDark])[variant=statusSuccess]){--ds-auro-icon-color:var(--ds-basic-color-status-success, #447a1f)}:host(:not([onDark])[variant=statusWarning]){--ds-auro-icon-color:var(--ds-basic-color-status-warning, #fac200)}:host(:not([onDark])[variant=statusError]){--ds-auro-icon-color:var(--ds-basic-color-status-error, #e31f26)}:host(:not([onDark])[variant=statusInfoSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-info-subtle, #ebf3f9)}:host(:not([onDark])[variant=statusSuccessSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-success-subtle, #d6eac7)}:host(:not([onDark])[variant=statusWarningSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-warning-subtle, #fff0b2)}:host(:not([onDark])[variant=statusErrorSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-error-subtle, #fbc6c6)}:host(:not([onDark])[variant=fareBasicEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-basiceconomy, #97eaf8)}:host(:not([onDark])[variant=fareBusiness]){--ds-auro-icon-color:var(--ds-basic-color-fare-business, #01426a)}:host(:not([onDark])[variant=fareEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-economy, #0074ca)}:host(:not([onDark])[variant=fareFirst]){--ds-auro-icon-color:var(--ds-basic-color-fare-first, #00274a)}:host(:not([onDark])[variant=farePremiumEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-premiumeconomy, #005154)}:host(:not([onDark])[variant=tierOneWorldEmerald]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-emerald, #139142)}:host(:not([onDark])[variant=tierOneWorldSapphire]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-sapphire, #015daa)}:host(:not([onDark])[variant=tierOneWorldRuby]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-ruby, #a41d4a)}:host([onDark]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse, #ffffff)}:host([onDark][variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}:host([onDark][variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][variant=statusError]){--ds-auro-icon-color:var(--ds-advanced-color-state-error-inverse, #f9a4a8)}`;
|
|
5422
6712
|
|
|
5423
6713
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5424
6714
|
// See LICENSE in the project root for license information.
|
|
@@ -5427,7 +6717,7 @@ var colorCss$2 = css`:host{color:var(--ds-auro-icon-color)}:host([customColor]){
|
|
|
5427
6717
|
|
|
5428
6718
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
5429
6719
|
|
|
5430
|
-
let AuroLibraryRuntimeUtils$
|
|
6720
|
+
let AuroLibraryRuntimeUtils$3 = class AuroLibraryRuntimeUtils {
|
|
5431
6721
|
|
|
5432
6722
|
/* eslint-disable jsdoc/require-param */
|
|
5433
6723
|
|
|
@@ -5509,7 +6799,7 @@ class AuroIcon extends BaseIcon {
|
|
|
5509
6799
|
*/
|
|
5510
6800
|
privateDefaults() {
|
|
5511
6801
|
this.uri = 'https://cdn.jsdelivr.net/npm/@alaskaairux/icons@latest/dist';
|
|
5512
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
6802
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$3();
|
|
5513
6803
|
}
|
|
5514
6804
|
|
|
5515
6805
|
// function to define props used within the scope of this component
|
|
@@ -5576,9 +6866,9 @@ class AuroIcon extends BaseIcon {
|
|
|
5576
6866
|
static get styles() {
|
|
5577
6867
|
return [
|
|
5578
6868
|
super.styles,
|
|
5579
|
-
css`${tokensCss$
|
|
6869
|
+
css`${tokensCss$3}`,
|
|
5580
6870
|
css`${styleCss$1$1}`,
|
|
5581
|
-
css`${colorCss$
|
|
6871
|
+
css`${colorCss$4}`
|
|
5582
6872
|
];
|
|
5583
6873
|
}
|
|
5584
6874
|
|
|
@@ -5591,7 +6881,7 @@ class AuroIcon extends BaseIcon {
|
|
|
5591
6881
|
*
|
|
5592
6882
|
*/
|
|
5593
6883
|
static register(name = "auro-icon") {
|
|
5594
|
-
AuroLibraryRuntimeUtils$
|
|
6884
|
+
AuroLibraryRuntimeUtils$3.prototype.registerComponent(name, AuroIcon);
|
|
5595
6885
|
}
|
|
5596
6886
|
|
|
5597
6887
|
connectedCallback() {
|
|
@@ -5612,8 +6902,12 @@ class AuroIcon extends BaseIcon {
|
|
|
5612
6902
|
async firstUpdated() {
|
|
5613
6903
|
await super.firstUpdated();
|
|
5614
6904
|
|
|
5615
|
-
|
|
5616
|
-
|
|
6905
|
+
/**
|
|
6906
|
+
* icons provide a description for screen readers. Icon only instances Auro-button
|
|
6907
|
+
* depend on this description to provide context for the user using a screen reader.
|
|
6908
|
+
* Removes the SVG description for screen reader if ariaHidden is set to true.
|
|
6909
|
+
*/
|
|
6910
|
+
if (this.hasAttribute('ariaHidden') && this.svg) {
|
|
5617
6911
|
const svgDesc = this.svg.querySelector('desc');
|
|
5618
6912
|
|
|
5619
6913
|
if (svgDesc) {
|
|
@@ -5657,9 +6951,9 @@ class AuroIcon extends BaseIcon {
|
|
|
5657
6951
|
}
|
|
5658
6952
|
}
|
|
5659
6953
|
|
|
5660
|
-
var iconVersion = '8.0
|
|
6954
|
+
var iconVersion = '8.1.0';
|
|
5661
6955
|
|
|
5662
|
-
var styleCss$3 = css`.heading{margin:1.75rem 0;letter-spacing:var(--ds-text-heading-default-spacing, -0.2px);font-weight:var(--ds-text-heading-default-weight, 500)}.heading--display{margin-top:0;font-size:var(--ds-text-heading-display-size-breakpoint-sm, 2.75rem);font-weight:var(--ds-text-heading-display-weight, 100);line-height:var(--ds-text-heading-display-height-breakpoint-sm, 3.375rem)}@media screen and (min-width: 768px){.heading--display{font-size:var(--ds-text-heading-display-size-breakpoint-md, 3rem);line-height:var(--ds-text-heading-display-height-breakpoint-md, 3.75rem)}}@media screen and (min-width: 1024px){.heading--display{font-size:var(--ds-text-heading-display-size-breakpoint-lg, 3.5rem);line-height:var(--ds-text-heading-display-height-breakpoint-lg, 4.25rem)}}.heading--800{font-size:var(--ds-text-heading-800-size-breakpoint-sm, 2rem);font-weight:var(--ds-text-heading-800-weight, 500);line-height:var(--ds-text-heading-800-height-breakpoint-sm, 2.375rem)}@media screen and (min-width: 768px){.heading--800{font-size:var(--ds-text-heading-800-size-breakpoint-md, 2.25rem);line-height:var(--ds-text-heading-800-height-breakpoint-md, 2.625rem)}}@media screen and (min-width: 1024px){.heading--800{font-size:var(--ds-text-heading-800-size-breakpoint-lg, 2.5rem);line-height:var(--ds-text-heading-800-height-breakpoint-lg, 3rem)}}.heading--700{font-size:var(--ds-text-heading-700-size-breakpoint-sm, 1.75rem);font-weight:var(--ds-text-heading-700-weight, 500);line-height:var(--ds-text-heading-700-height-breakpoint-sm, 2.125rem)}@media screen and (min-width: 768px){.heading--700{font-size:var(--ds-text-heading-700-size-breakpoint-md, 2rem);line-height:var(--ds-text-heading-700-height-breakpoint-md, 2.375rem)}}@media screen and (min-width: 1024px){.heading--700{font-size:var(--ds-text-heading-700-size-breakpoint-lg, 2.25rem);line-height:var(--ds-text-heading-700-height-breakpoint-lg, 2.75rem)}}.heading--600{margin:1rem 0;font-size:var(--ds-text-heading-600-size-breakpoint-sm, 1.625rem);font-weight:var(--ds-text-heading-600-weight, 300);line-height:var(--ds-text-heading-600-height-breakpoint-sm, 1.875rem)}@media screen and (min-width: 768px){.heading--600{font-size:var(--ds-text-heading-600-size-breakpoint-md, 1.75rem);line-height:var(--ds-text-heading-600-height-breakpoint-md, 2.125rem)}}@media screen and (min-width: 1024px){.heading--600{font-size:var(--ds-text-heading-600-size-breakpoint-lg, 1.75rem);line-height:var(--ds-text-heading-600-height-breakpoint-lg, 2.25rem)}}.heading--500{margin:1rem 0;font-size:var(--ds-text-heading-500-size-breakpoint-sm, 1.375rem);font-weight:var(--ds-text-heading-500-weight, 300);line-height:var(--ds-text-heading-500-height-breakpoint-sm, 1.625rem)}@media screen and (min-width: 768px){.heading--500{font-size:var(--ds-text-heading-500-size-breakpoint-md, 1.5rem);line-height:var(--ds-text-heading-500-height-breakpoint-md, 1.875rem)}}@media screen and (min-width: 1024px){.heading--500{font-size:var(--ds-text-heading-500-size-breakpoint-lg, 1.5rem);line-height:var(--ds-text-heading-500-height-breakpoint-lg, 2rem)}}.heading--400{margin:.75rem 0;font-size:var(--ds-text-heading-400-size, 1.25rem);font-weight:var(--ds-text-heading-400-weight, 300);line-height:var(--ds-text-heading-400-height, 1.625rem)}.heading--300{margin:.75rem 0;font-size:var(--ds-text-heading-300-size, 1.125rem);font-weight:var(--ds-text-heading-300-weight, 300);line-height:var(--ds-text-heading-300-height, 1.625rem)}:host([no-margin-block]) .heading{margin-block:0}.util_stackMarginnone--bottom{margin-bottom:0}.util_stackMargin25--bottom{margin-bottom:var(--ds-size-25, 0.125rem)}.util_stackMargin50--bottom{margin-bottom:var(--ds-size-50, 0.25rem)}.util_stackMargin100--bottom{margin-bottom:var(--ds-size-100, 0.5rem)}.util_stackMargin150--bottom{margin-bottom:var(--ds-size-150, 0.75rem)}.util_stackMargin200--bottom{margin-bottom:var(--ds-size-200, 1rem)}.util_stackMargin300--bottom{margin-bottom:var(--ds-size-300, 1.5rem)}.util_stackMargin400--bottom{margin-bottom:var(--ds-size-400, 2rem)}.util_stackMargin600--bottom{margin-bottom:var(--ds-size-600, 3rem)}.util_stackMargin800--bottom{margin-bottom:var(--ds-size-800, 4rem)}.util_stackMarginnone--top{margin-top:0}.util_stackMargin25--top{margin-top:var(--ds-size-25, 0.125rem)}.util_stackMargin50--top{margin-top:var(--ds-size-50, 0.25rem)}.util_stackMargin100--top{margin-top:var(--ds-size-100, 0.5rem)}.util_stackMargin150--top{margin-top:var(--ds-size-150, 0.75rem)}.util_stackMargin200--top{margin-top:var(--ds-size-200, 1rem)}.util_stackMargin300--top{margin-top:var(--ds-size-300, 1.5rem)}.util_stackMargin400--top{margin-top:var(--ds-size-400, 2rem)}.util_stackMargin600--top{margin-top:var(--ds-size-600, 3rem)}.util_stackMargin800--top{margin-top:var(--ds-size-800, 4rem)}`;
|
|
6956
|
+
var styleCss$5 = css`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.63)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, 0.88)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3)}:host([no-margin-block]) .heading{margin-block:0}.util_stackMarginnone--bottom{margin-bottom:0}.util_stackMargin25--bottom{margin-bottom:var(--ds-size-25, 0.125rem)}.util_stackMargin50--bottom{margin-bottom:var(--ds-size-50, 0.25rem)}.util_stackMargin100--bottom{margin-bottom:var(--ds-size-100, 0.5rem)}.util_stackMargin150--bottom{margin-bottom:var(--ds-size-150, 0.75rem)}.util_stackMargin200--bottom{margin-bottom:var(--ds-size-200, 1rem)}.util_stackMargin300--bottom{margin-bottom:var(--ds-size-300, 1.5rem)}.util_stackMargin400--bottom{margin-bottom:var(--ds-size-400, 2rem)}.util_stackMargin600--bottom{margin-bottom:var(--ds-size-600, 3rem)}.util_stackMargin800--bottom{margin-bottom:var(--ds-size-800, 4rem)}.util_stackMarginnone--top{margin-top:0}.util_stackMargin25--top{margin-top:var(--ds-size-25, 0.125rem)}.util_stackMargin50--top{margin-top:var(--ds-size-50, 0.25rem)}.util_stackMargin100--top{margin-top:var(--ds-size-100, 0.5rem)}.util_stackMargin150--top{margin-top:var(--ds-size-150, 0.75rem)}.util_stackMargin200--top{margin-top:var(--ds-size-200, 1rem)}.util_stackMargin300--top{margin-top:var(--ds-size-300, 1.5rem)}.util_stackMargin400--top{margin-top:var(--ds-size-400, 2rem)}.util_stackMargin600--top{margin-top:var(--ds-size-600, 3rem)}.util_stackMargin800--top{margin-top:var(--ds-size-800, 4rem)}`;
|
|
5663
6957
|
|
|
5664
6958
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5665
6959
|
// See LICENSE in the project root for license information.
|
|
@@ -5669,13 +6963,12 @@ var styleCss$3 = css`.heading{margin:1.75rem 0;letter-spacing:var(--ds-text-head
|
|
|
5669
6963
|
* The auro-header component is a custom element to make using headers with the Auro Design System seamless and easy.
|
|
5670
6964
|
*
|
|
5671
6965
|
* @attr {Boolean} no-margin-block - if declared, margin-block will be set to `0`
|
|
5672
|
-
* @attr {String} level - Determines heading level for HTML element. Options are `1` - `6`
|
|
5673
|
-
* @attr {String} display - Determines presentation of header. Options are `display`, `800`, `700`, `600`, `500`, `400`, `300`.
|
|
5674
6966
|
* @attr {String} color - Allows user to pass in CSS custom property or direct hex value to change the color of the header
|
|
6967
|
+
* @attr {String} display - Determines the visual appearance of the header. Options are `display`, `800`, `700`, `600`, `500`, `400`, `300`.
|
|
6968
|
+
* @attr {String} level - Determines the semantic heading level of the HTML element. Options are `1` - `6`
|
|
5675
6969
|
* @attr {String} margin - Specify the margin(s) to be altered. Options are `top`, `bottom`, or `both`.
|
|
5676
6970
|
* @attr {String} size - Specify size of margin adjustment, either `none`, `25`, `50`, `100`, `150`, `200`, `300`, `400`, `600` or `800`.
|
|
5677
6971
|
*/
|
|
5678
|
-
|
|
5679
6972
|
/* eslint complexity: ["error", 21] */
|
|
5680
6973
|
|
|
5681
6974
|
// build the component class
|
|
@@ -5688,7 +6981,7 @@ class AuroHeader extends LitElement {
|
|
|
5688
6981
|
/**
|
|
5689
6982
|
* @private
|
|
5690
6983
|
*/
|
|
5691
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
6984
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$2();
|
|
5692
6985
|
}
|
|
5693
6986
|
|
|
5694
6987
|
// function to define props used within the scope of this component
|
|
@@ -5706,7 +6999,23 @@ class AuroHeader extends LitElement {
|
|
|
5706
6999
|
}
|
|
5707
7000
|
|
|
5708
7001
|
static get styles() {
|
|
5709
|
-
return [styleCss$
|
|
7002
|
+
return [styleCss$5];
|
|
7003
|
+
}
|
|
7004
|
+
|
|
7005
|
+
/**
|
|
7006
|
+
* Mapping of display values to their corresponding CSS classes
|
|
7007
|
+
* @private
|
|
7008
|
+
*/
|
|
7009
|
+
static get displayClassMap() {
|
|
7010
|
+
return {
|
|
7011
|
+
'display': 'heading-xl',
|
|
7012
|
+
'800': 'heading-xl',
|
|
7013
|
+
'700': 'heading-lg',
|
|
7014
|
+
'600': 'heading-md',
|
|
7015
|
+
'500': 'heading-sm',
|
|
7016
|
+
'400': 'heading-xs',
|
|
7017
|
+
'300': 'heading-2xs'
|
|
7018
|
+
};
|
|
5710
7019
|
}
|
|
5711
7020
|
|
|
5712
7021
|
/**
|
|
@@ -5718,7 +7027,7 @@ class AuroHeader extends LitElement {
|
|
|
5718
7027
|
*
|
|
5719
7028
|
*/
|
|
5720
7029
|
static register(name = "auro-header") {
|
|
5721
|
-
AuroLibraryRuntimeUtils$
|
|
7030
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroHeader);
|
|
5722
7031
|
}
|
|
5723
7032
|
|
|
5724
7033
|
firstUpdated() {
|
|
@@ -5785,23 +7094,42 @@ class AuroHeader extends LitElement {
|
|
|
5785
7094
|
this.display = 'display';
|
|
5786
7095
|
}
|
|
5787
7096
|
|
|
5788
|
-
|
|
5789
|
-
|
|
5790
|
-
|
|
5791
|
-
|
|
5792
|
-
|
|
5793
|
-
|
|
5794
|
-
|
|
7097
|
+
const headingLevel = level || '1';
|
|
7098
|
+
const spacingClasses = this.spacingDecision(this.size);
|
|
7099
|
+
|
|
7100
|
+
// Get the CSS class based on the display prop
|
|
7101
|
+
const headingClass = AuroHeader.displayClassMap[this.display];
|
|
7102
|
+
|
|
7103
|
+
const classObject = {
|
|
7104
|
+
'heading': true,
|
|
7105
|
+
[`heading--${this.display}`]: true,
|
|
7106
|
+
[headingClass]: true
|
|
7107
|
+
};
|
|
7108
|
+
|
|
7109
|
+
// Add spacing classes to the class object if they exist
|
|
7110
|
+
if (spacingClasses) {
|
|
7111
|
+
const spacingClassArray = spacingClasses.split(' ');
|
|
7112
|
+
spacingClassArray.forEach(cls => {
|
|
7113
|
+
if (cls.trim()) {
|
|
7114
|
+
classObject[cls.trim()] = true;
|
|
7115
|
+
}
|
|
7116
|
+
});
|
|
5795
7117
|
}
|
|
7118
|
+
|
|
7119
|
+
const headerClasses = classMap(classObject);
|
|
7120
|
+
|
|
7121
|
+
// unsafeStatic dynamically creates tag names at runtime
|
|
7122
|
+
const tag = unsafeStatic(`h${headingLevel}`);
|
|
7123
|
+
return html`<${tag} class="${headerClasses}" style="color: ${ifDefined(this.color ? this.color : undefined)}"><slot></slot></${tag}>`;
|
|
5796
7124
|
}
|
|
7125
|
+
|
|
5797
7126
|
// function that renders the HTML and CSS into the scope of the component
|
|
5798
|
-
|
|
5799
7127
|
render() {
|
|
5800
7128
|
return this.template(this.level);
|
|
5801
7129
|
}
|
|
5802
7130
|
}
|
|
5803
7131
|
|
|
5804
|
-
var headerVersion = '4.0.
|
|
7132
|
+
var headerVersion = '4.0.2';
|
|
5805
7133
|
|
|
5806
7134
|
// Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5807
7135
|
// See LICENSE in the project root for license information.
|
|
@@ -5814,17 +7142,30 @@ class AuroBibtemplate extends LitElement {
|
|
|
5814
7142
|
|
|
5815
7143
|
this.large = false;
|
|
5816
7144
|
|
|
5817
|
-
AuroLibraryRuntimeUtils$
|
|
7145
|
+
AuroLibraryRuntimeUtils$2.prototype.handleComponentTagRename(this, 'auro-bibtemplate');
|
|
5818
7146
|
|
|
5819
7147
|
const versioning = new AuroDependencyVersioning();
|
|
7148
|
+
|
|
7149
|
+
/**
|
|
7150
|
+
* @private
|
|
7151
|
+
*/
|
|
5820
7152
|
this.iconTag = versioning.generateTag('auro-formkit-bibtemplate-icon', iconVersion, AuroIcon);
|
|
7153
|
+
|
|
7154
|
+
/**
|
|
7155
|
+
* @private
|
|
7156
|
+
*/
|
|
5821
7157
|
this.headerTag = versioning.generateTag('auro-formkit-bibtemplate-header', headerVersion, AuroHeader);
|
|
7158
|
+
|
|
7159
|
+
/**
|
|
7160
|
+
* @private
|
|
7161
|
+
*/
|
|
7162
|
+
this.buttonTag = versioning.generateTag('auro-formkit-bibtemplate-button', buttonVersion, AuroButton);
|
|
5822
7163
|
}
|
|
5823
7164
|
|
|
5824
7165
|
static get styles() {
|
|
5825
7166
|
return [
|
|
5826
|
-
colorCss$
|
|
5827
|
-
styleCss$
|
|
7167
|
+
colorCss$3,
|
|
7168
|
+
styleCss$4,
|
|
5828
7169
|
tokenCss
|
|
5829
7170
|
];
|
|
5830
7171
|
}
|
|
@@ -5853,7 +7194,7 @@ class AuroBibtemplate extends LitElement {
|
|
|
5853
7194
|
*
|
|
5854
7195
|
*/
|
|
5855
7196
|
static register(name = "auro-bibtemplate") {
|
|
5856
|
-
AuroLibraryRuntimeUtils$
|
|
7197
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroBibtemplate);
|
|
5857
7198
|
}
|
|
5858
7199
|
|
|
5859
7200
|
/**
|
|
@@ -5911,13 +7252,16 @@ class AuroBibtemplate extends LitElement {
|
|
|
5911
7252
|
<div id="bibTemplate" part="bibtemplate">
|
|
5912
7253
|
${this.isFullscreen ? html`
|
|
5913
7254
|
<div id="headerContainer">
|
|
5914
|
-
<
|
|
5915
|
-
<${this.
|
|
5916
|
-
|
|
5917
|
-
|
|
5918
|
-
|
|
5919
|
-
|
|
5920
|
-
|
|
7255
|
+
<div class="titleRow">
|
|
7256
|
+
<${this.headerTag} class="header" display="${this.large ? 'display' : '600'}" level="3" size="none" id="header" no-margin-block>
|
|
7257
|
+
<slot name="header"></slot>
|
|
7258
|
+
</${this.headerTag}>
|
|
7259
|
+
<${this.buttonTag} id="closeButton" variant="ghost" shape="circle" size="sm" @click="${this.onCloseButtonClick}">
|
|
7260
|
+
<span><slot name="ariaLabel.close">Close</slot></span>
|
|
7261
|
+
<${this.iconTag} aria-hidden="true" category="interface" name="x-lg"></${this.iconTag}>
|
|
7262
|
+
</${this.buttonTag}>
|
|
7263
|
+
</div>
|
|
7264
|
+
<span class="subheader">
|
|
5921
7265
|
<slot name="subheader"></slot>
|
|
5922
7266
|
</span>
|
|
5923
7267
|
</div>` : null}
|
|
@@ -5937,9 +7281,9 @@ class AuroBibtemplate extends LitElement {
|
|
|
5937
7281
|
|
|
5938
7282
|
var bibTemplateVersion = '1.0.0';
|
|
5939
7283
|
|
|
5940
|
-
var colorCss = css`:host([error]){--ds-auro-helptext-color: var(--ds-basic-color-status-error, #e31f26)}:host([onDark]){--ds-auro-helptext-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][error]){--ds-auro-helptext-color: var(--ds-
|
|
7284
|
+
var colorCss = css`:host([error]){--ds-auro-helptext-color: var(--ds-basic-color-status-error, #e31f26)}:host([onDark]){--ds-auro-helptext-color: var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][error]){--ds-auro-helptext-color: var(--ds-basic-color-status-error-subtle, #fbc6c6)}.helptext-wrapper{color:var(--ds-auro-helptext-color)}`;
|
|
5941
7285
|
|
|
5942
|
-
var styleCss$1 = css`.
|
|
7286
|
+
var styleCss$1 = css`.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.63)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, 0.88)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}:host{position:relative;display:block}.helptext-wrapper{display:none}.helptext-wrapper[visible]{display:block}::slotted(*:not(:empty)){margin-top:var(--ds-size-50, 0.25rem);margin-bottom:0}::slotted(p){margin-block:0}`;
|
|
5943
7287
|
|
|
5944
7288
|
var tokensCss = css`:host{--ds-auro-helptext-color: var(--ds-basic-color-texticon-muted, #676767)}`;
|
|
5945
7289
|
|
|
@@ -6019,8 +7363,6 @@ class AuroLibraryRuntimeUtils {
|
|
|
6019
7363
|
|
|
6020
7364
|
/**
|
|
6021
7365
|
* Displays help text or error messages within form elements - Internal Use Only.
|
|
6022
|
-
*
|
|
6023
|
-
* @attr { Boolean } large - If declared, make font-size to 1rem(16px).
|
|
6024
7366
|
*/
|
|
6025
7367
|
class AuroHelpText extends LitElement {
|
|
6026
7368
|
|
|
@@ -6136,7 +7478,7 @@ class AuroHelpText extends LitElement {
|
|
|
6136
7478
|
// function that renders the HTML and CSS into the scope of the component
|
|
6137
7479
|
render() {
|
|
6138
7480
|
return html$1`
|
|
6139
|
-
<div class="helptext-wrapper" ?visible="${this.hasTextContent}">
|
|
7481
|
+
<div class="helptext-wrapper body-xs" ?visible="${this.hasTextContent}">
|
|
6140
7482
|
<slot @slotchange=${this.handleSlotChange}></slot>
|
|
6141
7483
|
</div>
|
|
6142
7484
|
`;
|
|
@@ -6145,68 +7487,7 @@ class AuroHelpText extends LitElement {
|
|
|
6145
7487
|
|
|
6146
7488
|
var helpTextVersion = '1.0.0';
|
|
6147
7489
|
|
|
6148
|
-
css`: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].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)}`;
|
|
6149
|
-
|
|
6150
|
-
css`:host ::slotted(hr){border-top-color:var(--ds-auro-menu-divider-color)}[loadingplaceholder] slot[name=loadingIcon]{color:var(--ds-auro-menu-loader-color)}[loadingplaceholder] slot[name=loadingText]{color:var(--ds-auro-menu-loader-text-color)}`;
|
|
6151
|
-
|
|
6152
|
-
css`:host{--ds-auro-menu-divider-color: var(--ds-basic-color-border-divider, rgba(0, 0, 0, 0.15));--ds-auro-menu-loader-color: var(--ds-basic-color-brand-primary, #01426a);--ds-auro-menu-loader-text-color: var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-menuoption-container-color: transparent;--ds-auro-menuoption-icon-color: transparent;--ds-auro-menuoption-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}`;
|
|
6153
|
-
|
|
6154
|
-
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
6155
|
-
// See LICENSE in the project root for license information.
|
|
6156
|
-
|
|
6157
|
-
// ---------------------------------------------------------------------
|
|
6158
|
-
|
|
6159
|
-
/**
|
|
6160
|
-
* Converts value to an array.
|
|
6161
|
-
* If the value is a JSON string representing an array, it will be parsed.
|
|
6162
|
-
* If the value is already an array, it is returned.
|
|
6163
|
-
* If the value is undefined, it returns undefined.
|
|
6164
|
-
* @private
|
|
6165
|
-
* @param {any} value - The value to be converted. Can be a string, array, or undefined.
|
|
6166
|
-
* @returns {Array|undefined} - The converted array or undefined.
|
|
6167
|
-
* @throws {Error} - Throws an error if the value is not an array, undefined,
|
|
6168
|
-
* or if the value cannot be parsed into an array from a JSON string.
|
|
6169
|
-
*/
|
|
6170
|
-
function arrayConverter(value) {
|
|
6171
|
-
// Allow undefined
|
|
6172
|
-
if (value === undefined) {
|
|
6173
|
-
return undefined;
|
|
6174
|
-
}
|
|
6175
|
-
|
|
6176
|
-
// Return the value if it is already an array
|
|
6177
|
-
if (Array.isArray(value)) {
|
|
6178
|
-
return value;
|
|
6179
|
-
}
|
|
6180
|
-
|
|
6181
|
-
try {
|
|
6182
|
-
// If value is a JSON string, parse it
|
|
6183
|
-
const parsed = typeof value === 'string' ? JSON.parse(value) : value;
|
|
6184
|
-
|
|
6185
|
-
// Check if the parsed value is an array
|
|
6186
|
-
if (Array.isArray(parsed)) {
|
|
6187
|
-
return parsed;
|
|
6188
|
-
}
|
|
6189
|
-
} catch (error) {
|
|
6190
|
-
// If JSON parsing fails, continue to throw an error below
|
|
6191
|
-
/* eslint-disable no-console */
|
|
6192
|
-
console.error('JSON parsing failed:', error);
|
|
6193
|
-
}
|
|
6194
|
-
|
|
6195
|
-
// Throw error if the input is not an array or undefined
|
|
6196
|
-
throw new Error('Invalid value: Input must be an array or undefined');
|
|
6197
|
-
}
|
|
6198
|
-
|
|
6199
|
-
css`: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}`;
|
|
6200
|
-
|
|
6201
|
-
css`: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)}:host([disabled]){--ds-auro-menuoption-text-color: var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:hover),:host(.active){--ds-auro-menuoption-container-color: var(--ds-basic-color-surface-neutral-subtle, #f7f7f7)}:host([selected]){--ds-auro-menuoption-container-color: var(--ds-advanced-color-state-selected, #01426a);--ds-auro-menuoption-text-color: var(--ds-basic-color-texticon-inverse, #ffffff);--ds-auro-menuoption-icon-color: var(--ds-basic-color-texticon-inverse, #ffffff)}:host([selected]):host(:hover),:host([selected]):host(.active){--ds-auro-menuoption-container-color: var(--ds-advanced-color-state-selected-hover, #00274a)}`;
|
|
6202
|
-
|
|
6203
|
-
css`:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock,:host{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host([hidden]:not(:focus):not(:active)){display:none}.util_displayHiddenVisually,:host([hiddenVisually]:not(:focus):not(:active)){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.ico_squareLarge{fill:currentColor;height:var(--auro-size-lg, var(--ds-size-300, 1.5rem))}.ico_squareSmall{fill:currentColor;height:.6rem}.ico_squareMed{fill:currentColor;height:var(--auro-size-md, var(--ds-size-200, 1rem))}.ico_squareSml{fill:currentColor;height:var(--auro-size-sm, var(--ds-size-150, 0.75rem))}:host{color:currentColor;vertical-align:middle;line-height:1;display:inline-block}svg{min-width:var(--ds-auro-icon-size, 1.5rem) !important;width:var(--ds-auro-icon-size, 1.5rem) !important;height:var(--ds-auro-icon-size, 1.5rem) !important}.componentWrapper{display:flex}.svgWrapper{height:var(--ds-auro-icon-size);width:var(--ds-auro-icon-size)}.labelWrapper{margin-left:var(--ds-size-50, 0.25rem);line-height:1.8}`;
|
|
6204
|
-
|
|
6205
|
-
css`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-default, #2a2a2a);--ds-auro-alaska-color:#02426D;--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}`;
|
|
6206
|
-
|
|
6207
|
-
css`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[variant=accent1]){--ds-auro-icon-color:var(--ds-basic-color-texticon-accent1, #265688)}:host(:not([onDark])[variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-disabled, #d0d0d0)}:host(:not([onDark])[variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-muted, #676767)}:host(:not([onDark])[variant=statusDefault]){--ds-auro-icon-color:var(--ds-basic-color-status-default, #afb9c6)}:host(:not([onDark])[variant=statusInfo]){--ds-auro-icon-color:var(--ds-basic-color-status-info, #01426a)}:host(:not([onDark])[variant=statusSuccess]){--ds-auro-icon-color:var(--ds-basic-color-status-success, #447a1f)}:host(:not([onDark])[variant=statusWarning]){--ds-auro-icon-color:var(--ds-basic-color-status-warning, #fac200)}:host(:not([onDark])[variant=statusError]){--ds-auro-icon-color:var(--ds-basic-color-status-error, #e31f26)}:host(:not([onDark])[variant=statusInfoSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-info-subtle, #ebf3f9)}:host(:not([onDark])[variant=statusSuccessSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-success-subtle, #d6eac7)}:host(:not([onDark])[variant=statusWarningSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-warning-subtle, #fff0b2)}:host(:not([onDark])[variant=statusErrorSubtle]){--ds-auro-icon-color:var(--ds-basic-color-status-error-subtle, #fbc6c6)}:host(:not([onDark])[variant=fareBasicEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-basiceconomy, #97eaf8)}:host(:not([onDark])[variant=fareBusiness]){--ds-auro-icon-color:var(--ds-basic-color-fare-business, #01426a)}:host(:not([onDark])[variant=fareEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-economy, #0074ca)}:host(:not([onDark])[variant=fareFirst]){--ds-auro-icon-color:var(--ds-basic-color-fare-first, #00274a)}:host(:not([onDark])[variant=farePremiumEconomy]){--ds-auro-icon-color:var(--ds-basic-color-fare-premiumeconomy, #005154)}:host(:not([onDark])[variant=tierOneWorldEmerald]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-emerald, #139142)}:host(:not([onDark])[variant=tierOneWorldSapphire]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-sapphire, #015daa)}:host(:not([onDark])[variant=tierOneWorldRuby]){--ds-auro-icon-color:var(--ds-basic-color-tier-program-oneworld-ruby, #a41d4a)}:host([onDark]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse, #ffffff)}:host([onDark][variant=disabled]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-disabled, #7e8894)}:host([onDark][variant=muted]){--ds-auro-icon-color:var(--ds-basic-color-texticon-inverse-muted, #ccd2db)}:host([onDark][variant=statusError]){--ds-auro-icon-color:var(--ds-advanced-color-state-error-inverse, #f9a4a8)}`;
|
|
6208
|
-
|
|
6209
|
-
var styleCss = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}[auro-dropdown]{--ds-auro-dropdown-trigger-border-color: var(--ds-auro-select-border-color);--ds-auro-dropdown-trigger-background-color: var(--ds-auro-select-background-color);--ds-auro-dropdown-trigger-container-color: var(--ds-auro-select-background-color)}.mainContent{position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;flex:1}.valueContainer [slot=displayValue]{display:none}.accents{display:flex;flex-direction:row;justify-content:center;align-items:center}::slotted([slot=typeIcon]){margin-right:8px}.displayValue{display:block}.displayValue:not(.force){display:none}.displayValue:not(.force).hasContent:is(.withValue):not(.hasFocus){display:block}.triggerContent{display:flex;align-items:center;justify-content:center;width:100%;padding:0 8px 0 24px}.layout-emphasized .triggerContent,.layout-snowflake .triggerContent{display:flex;align-items:center;justify-content:center;width:100%;padding:0 8px 0 24px}.layout-classic .triggerContent{display:flex;align-items:center;justify-content:center;width:100%;padding:0 8px 0 24px}:host(:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-advanced-color-state-error-inverse, #f9a4a8);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}#slotHolder{display:none}:host([disabled]) *{user-select:none}`;
|
|
7490
|
+
var styleCss = css`.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.body-default{font-size:var(--wcss-body-default-font-size, 1rem);line-height:var(--wcss-body-default-line-height, 1.5)}.body-default,.body-lg{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-lg{font-size:var(--wcss-body-lg-font-size, 1.125rem);line-height:var(--wcss-body-lg-line-height, 1.63)}.body-sm{font-size:var(--wcss-body-sm-font-size, 0.875rem);line-height:var(--wcss-body-sm-line-height, 1.25)}.body-sm,.body-xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0)}.body-xs{font-size:var(--wcss-body-xs-font-size, 0.75rem);line-height:var(--wcss-body-xs-line-height, 1)}.body-2xs{font-family:var(--wcss-body-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-body-2xs-font-size, 0.625rem);font-weight:var(--wcss-body-weight, 450);letter-spacing:var(--wcss-body-letter-spacing, 0);line-height:var(--wcss-body-2xs-line-height, 0.88)}.display-2xl{font-family:var(--wcss-display-2xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-2xl-font-size, clamp(3.5rem, 6vw, 5.375rem));font-weight:var(--wcss-display-2xl-weight, 300);letter-spacing:var(--wcss-display-2xl-letter-spacing, 0);line-height:var(--wcss-display-2xl-line-height, 1.3)}.display-xl{font-family:var(--wcss-display-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xl-font-size, clamp(3rem, 5.3333333333vw, 4.5rem));font-weight:var(--wcss-display-xl-weight, 300);letter-spacing:var(--wcss-display-xl-letter-spacing, 0);line-height:var(--wcss-display-xl-line-height, 1.3)}.display-lg{font-family:var(--wcss-display-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-lg-font-size, clamp(2.75rem, 4.6666666667vw, 4rem));font-weight:var(--wcss-display-lg-weight, 300);letter-spacing:var(--wcss-display-lg-letter-spacing, 0);line-height:var(--wcss-display-lg-line-height, 1.3)}.display-md{font-family:var(--wcss-display-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-md-font-size, clamp(2.5rem, 4vw, 3.5rem));font-weight:var(--wcss-display-md-weight, 300);letter-spacing:var(--wcss-display-md-letter-spacing, 0);line-height:var(--wcss-display-md-line-height, 1.3)}.display-sm{font-family:var(--wcss-display-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-sm-font-size, clamp(2rem, 3.6666666667vw, 3rem));font-weight:var(--wcss-display-sm-weight, 300);letter-spacing:var(--wcss-display-sm-letter-spacing, 0);line-height:var(--wcss-display-sm-line-height, 1.3)}.display-xs{font-family:var(--wcss-display-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-display-xs-font-size, clamp(1.75rem, 3vw, 2.375rem));font-weight:var(--wcss-display-xs-weight, 300);letter-spacing:var(--wcss-display-xs-letter-spacing, 0);line-height:var(--wcss-display-xs-line-height, 1.3)}.heading-xl{font-family:var(--wcss-heading-xl-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xl-font-size, clamp(2rem, 3vw, 2.5rem));font-weight:var(--wcss-heading-xl-weight, 300);letter-spacing:var(--wcss-heading-xl-letter-spacing, 0);line-height:var(--wcss-heading-xl-line-height, 1.3)}.heading-lg{font-family:var(--wcss-heading-lg-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-lg-font-size, clamp(1.75rem, 2.6666666667vw, 2.25rem));font-weight:var(--wcss-heading-lg-weight, 300);letter-spacing:var(--wcss-heading-lg-letter-spacing, 0);line-height:var(--wcss-heading-lg-line-height, 1.3)}.heading-md{font-family:var(--wcss-heading-md-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-md-font-size, clamp(1.625rem, 2.3333333333vw, 1.75rem));font-weight:var(--wcss-heading-md-weight, 300);letter-spacing:var(--wcss-heading-md-letter-spacing, 0);line-height:var(--wcss-heading-md-line-height, 1.3)}.heading-sm{font-family:var(--wcss-heading-sm-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-sm-font-size, clamp(1.375rem, 2vw, 1.5rem));font-weight:var(--wcss-heading-sm-weight, 300);letter-spacing:var(--wcss-heading-sm-letter-spacing, 0);line-height:var(--wcss-heading-sm-line-height, 1.3)}.heading-xs{font-family:var(--wcss-heading-xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-xs-font-size, clamp(1.25rem, 1.6666666667vw, 1.25rem));font-weight:var(--wcss-heading-xs-weight, 450);letter-spacing:var(--wcss-heading-xs-letter-spacing, 0);line-height:var(--wcss-heading-xs-line-height, 1.3)}.heading-2xs{font-family:var(--wcss-heading-2xs-family, "AS Circular", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-heading-2xs-font-size, clamp(1.125rem, 1.5vw, 1.125rem));font-weight:var(--wcss-heading-2xs-weight, 450);letter-spacing:var(--wcss-heading-2xs-letter-spacing, 0);line-height:var(--wcss-heading-2xs-line-height, 1.3)}.accent-2xl{font-family:var(--wcss-accent-2xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xl-font-size, clamp(2rem, 3.1666666667vw, 2.375rem));font-weight:var(--wcss-accent-2xl-weight, 450);letter-spacing:var(--wcss-accent-2xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-2xl-line-height, 1)}.accent-2xl,.accent-xl{text-transform:uppercase}.accent-xl{font-family:var(--wcss-accent-xl-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xl-font-size, clamp(1.625rem, 2.3333333333vw, 2rem));font-weight:var(--wcss-accent-xl-weight, 450);letter-spacing:var(--wcss-accent-xl-letter-spacing, 0.05em);line-height:var(--wcss-accent-xl-line-height, 1.3)}.accent-lg{font-family:var(--wcss-accent-lg-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-lg-font-size, clamp(1.5rem, 2.1666666667vw, 1.75rem));font-weight:var(--wcss-accent-lg-weight, 450);letter-spacing:var(--wcss-accent-lg-letter-spacing, 0.05em);line-height:var(--wcss-accent-lg-line-height, 1.3)}.accent-lg,.accent-md{text-transform:uppercase}.accent-md{font-family:var(--wcss-accent-md-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-md-font-size, clamp(1.375rem, 1.8333333333vw, 1.5rem));font-weight:var(--wcss-accent-md-weight, 500);letter-spacing:var(--wcss-accent-md-letter-spacing, 0.05em);line-height:var(--wcss-accent-md-line-height, 1.3)}.accent-sm{font-family:var(--wcss-accent-sm-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-sm-font-size, clamp(1.125rem, 1.5vw, 1.25rem));font-weight:var(--wcss-accent-sm-weight, 500);letter-spacing:var(--wcss-accent-sm-letter-spacing, 0.05em);line-height:var(--wcss-accent-sm-line-height, 1.3)}.accent-sm,.accent-xs{text-transform:uppercase}.accent-xs{font-family:var(--wcss-accent-xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-xs-font-size, clamp(1rem, 1.3333333333vw, 1rem));font-weight:var(--wcss-accent-xs-weight, 500);letter-spacing:var(--wcss-accent-xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-xs-line-height, 1.3)}.accent-2xs{font-family:var(--wcss-accent-2xs-family, "Good OT", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif);font-size:var(--wcss-accent-2xs-font-size, clamp(0.875rem, 1.1666666667vw, 0.875rem));font-weight:var(--wcss-accent-2xs-weight, 450);letter-spacing:var(--wcss-accent-2xs-letter-spacing, 0.1em);line-height:var(--wcss-accent-2xs-line-height, 1.3);text-transform:uppercase}[auro-dropdown]{--ds-auro-dropdown-trigger-border-color: var(--ds-auro-select-border-color);--ds-auro-dropdown-trigger-background-color: var(--ds-auro-select-background-color);--ds-auro-dropdown-trigger-container-color: var(--ds-auro-select-background-color)}:host{display:inline-block}:host([layout*=emphasized]) [auro-dropdown],:host([layout*=snowflake]) [auro-dropdown]{--ds-auro-select-border-color: transparent}:host([layout*=emphasized]) .mainContent,:host([layout*=snowflake]) .mainContent{text-align:center}.mainContent{position:relative;display:flex;overflow:hidden;flex:1;flex-direction:column;align-items:center;justify-content:center}.valueContainer [slot=displayValue]{display:none}.accents{display:flex;flex-direction:row;align-items:center;justify-content:center}::slotted([slot=typeIcon]){margin-right:var(--ds-size-100, 0.5rem)}.displayValue{display:block}.displayValue:not(.force){display:none}.displayValue:not(.force).hasContent:is(.withValue):not(.hasFocus){display:block}.triggerContent{display:flex;width:100%;align-items:center;justify-content:center}:host([layout*=emphasized]) .triggerContent,:host([layout*=snowflake]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem) 0 var(--ds-size-300, 1.5rem)}:host([layout*=classic]) .triggerContent{padding:0 var(--ds-size-100, 0.5rem)}:host([layout*=classic]) .mainContent{align-items:start}:host([layout*=classic]) label{overflow:hidden;cursor:text;text-overflow:ellipsis;white-space:nowrap}:host([layout*=classic]) .value{height:auto}label{color:var(--ds-auro-select-label-text-color)}:host(:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-status-error, #e31f26);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-default, #2a2a2a)}:host([ondark]:is([validity]:not([validity=valid]))) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-status-error-subtle, #fbc6c6);--ds-auro-dropdown-helptext-text-color: var(--ds-basic-color-texticon-inverse, #ffffff)}#slotHolder{display:none}:host([fluid]){width:100%}:host([disabled]){pointer-events:none;user-select:none}:host([disabled]:not([ondark])) [auro-dropdown]{--ds-auro-select-border-color: var(--ds-basic-color-border-subtle, #dddddd)}:host(:not([layout*=classic])[disabled][ondark]) [auro-dropdown]{--ds-auro-select-border-color: transparent}`;
|
|
6210
7491
|
|
|
6211
7492
|
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
6212
7493
|
// See LICENSE in the project root for license information.
|
|
@@ -6217,14 +7498,20 @@ var styleCss = css`.util_displayInline{display:inline}.util_displayInlineBlock{d
|
|
|
6217
7498
|
* The auro-select element is a wrapper for auro-dropdown and auro-menu to create a dropdown menu control.
|
|
6218
7499
|
*
|
|
6219
7500
|
* @slot - Default slot for the menu content.
|
|
7501
|
+
* @slot ariaLabel.bib.close - Sets aria-label on close button in fullscreen bib
|
|
6220
7502
|
* @slot bib.fullscreen.headline - Defines the headline to display above menu-options
|
|
6221
7503
|
* @slot label - Defines the content of the label.
|
|
7504
|
+
* @slot {HTMLSlotElement} optionalLabel - Allows overriding the optional display text "(optional)", which appears next to the label.
|
|
6222
7505
|
* @slot helpText - Defines the content of the helpText.
|
|
6223
|
-
* @slot placeholder - Defines the content of the placeholder to be shown when there is no value
|
|
6224
7506
|
* @slot valueText - Dropdown value text display.
|
|
7507
|
+
* @slot displayValue - Allows custom HTML content to display the selected value when select is not focused.
|
|
6225
7508
|
* @event auroSelect-valueSet - Notifies that the component has a new value set.
|
|
6226
7509
|
* @event input - Notifies every time the value prop of the element is changed. The updated `value` and `optionSelected` will be delivered in `detail` object.
|
|
6227
7510
|
* @event auroFormElement-validated - Notifies that the `validity` and `errorMessage` values have changed.
|
|
7511
|
+
*
|
|
7512
|
+
* @csspart dropdownTrigger - Apply CSS to the trigger content container.
|
|
7513
|
+
* @csspart dropdownChevron - Apply CSS to the collapsed/expanded state icon container.
|
|
7514
|
+
* @csspart dropdownSize - Apply size styles to the dropdown bib. (height, width, maxHeight, maxWidth only)
|
|
6228
7515
|
* @csspart helpText - Apply CSS to the help text.
|
|
6229
7516
|
*/
|
|
6230
7517
|
|
|
@@ -6239,12 +7526,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6239
7526
|
const idSubstrEnd = 8;
|
|
6240
7527
|
const idSubstrStart = 2;
|
|
6241
7528
|
|
|
6242
|
-
this.matchWidth =
|
|
6243
|
-
|
|
6244
|
-
// Layout Config
|
|
6245
|
-
this.layout = 'classic';
|
|
6246
|
-
this.shape = 'classic';
|
|
6247
|
-
this.size = 'xl';
|
|
7529
|
+
this.matchWidth = false;
|
|
6248
7530
|
|
|
6249
7531
|
// floaterConfig
|
|
6250
7532
|
this.placement = 'bottom-start';
|
|
@@ -6269,7 +7551,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6269
7551
|
/**
|
|
6270
7552
|
* @private
|
|
6271
7553
|
*/
|
|
6272
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
7554
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$5();
|
|
6273
7555
|
|
|
6274
7556
|
/**
|
|
6275
7557
|
* Generate unique names for dependency components.
|
|
@@ -6319,6 +7601,11 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6319
7601
|
this.fullscreenBreakpoint = 'sm';
|
|
6320
7602
|
this.onDark = false;
|
|
6321
7603
|
this.isPopoverVisible = false;
|
|
7604
|
+
|
|
7605
|
+
// Layout Config
|
|
7606
|
+
this.layout = 'classic';
|
|
7607
|
+
this.shape = 'classic';
|
|
7608
|
+
this.size = 'lg';
|
|
6322
7609
|
}
|
|
6323
7610
|
|
|
6324
7611
|
// This function is to define props used within the scope of this component
|
|
@@ -6360,6 +7647,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6360
7647
|
reflect: true
|
|
6361
7648
|
},
|
|
6362
7649
|
|
|
7650
|
+
/**
|
|
7651
|
+
* When attribute is present, element will be 100% width of container element.
|
|
7652
|
+
*/
|
|
7653
|
+
fluid: {
|
|
7654
|
+
type: Boolean,
|
|
7655
|
+
reflect: true
|
|
7656
|
+
},
|
|
7657
|
+
|
|
6363
7658
|
/**
|
|
6364
7659
|
* @private
|
|
6365
7660
|
*/
|
|
@@ -6384,14 +7679,6 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6384
7679
|
reflect: true
|
|
6385
7680
|
},
|
|
6386
7681
|
|
|
6387
|
-
/**
|
|
6388
|
-
* If set, makes dropdown width match the size of the content, rather than the width of the trigger.
|
|
6389
|
-
*/
|
|
6390
|
-
flexMenuWidth: {
|
|
6391
|
-
type: Boolean,
|
|
6392
|
-
reflect: true
|
|
6393
|
-
},
|
|
6394
|
-
|
|
6395
7682
|
/**
|
|
6396
7683
|
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
6397
7684
|
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
@@ -6485,7 +7772,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6485
7772
|
* "top" | "right" | "bottom" | "left" |
|
|
6486
7773
|
* "bottom-start" | "top-start" | "top-end" |
|
|
6487
7774
|
* "right-start" | "right-end" | "bottom-end" |
|
|
6488
|
-
* "left-start" | "left-end"
|
|
7775
|
+
* "left-start" | "left-end".
|
|
6489
7776
|
* @default bottom-start
|
|
6490
7777
|
*/
|
|
6491
7778
|
placement: {
|
|
@@ -6493,6 +7780,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6493
7780
|
reflect: true
|
|
6494
7781
|
},
|
|
6495
7782
|
|
|
7783
|
+
/**
|
|
7784
|
+
* Define custom placeholder text.
|
|
7785
|
+
*/
|
|
7786
|
+
placeholder: {
|
|
7787
|
+
type: String,
|
|
7788
|
+
reflect: true
|
|
7789
|
+
},
|
|
7790
|
+
|
|
6496
7791
|
/**
|
|
6497
7792
|
* Populates the `required` attribute on the element. Used for client-side validation.
|
|
6498
7793
|
*/
|
|
@@ -6539,11 +7834,12 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6539
7834
|
},
|
|
6540
7835
|
|
|
6541
7836
|
/**
|
|
6542
|
-
* Value selected for the component.
|
|
6543
|
-
* @type {String|Array<String>}
|
|
7837
|
+
* Value selected for the component.
|
|
6544
7838
|
*/
|
|
6545
7839
|
value: {
|
|
6546
|
-
type:
|
|
7840
|
+
type: String,
|
|
7841
|
+
reflect: true,
|
|
7842
|
+
attribute: 'value'
|
|
6547
7843
|
},
|
|
6548
7844
|
|
|
6549
7845
|
/**
|
|
@@ -6590,20 +7886,82 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6590
7886
|
static get styles() {
|
|
6591
7887
|
return [
|
|
6592
7888
|
css`${shapeSizeCss$1}`,
|
|
6593
|
-
css`${tokensCss$
|
|
7889
|
+
css`${tokensCss$5}`,
|
|
6594
7890
|
css`${styleCss}`,
|
|
6595
7891
|
];
|
|
6596
7892
|
}
|
|
6597
7893
|
|
|
6598
7894
|
/**
|
|
6599
|
-
*
|
|
7895
|
+
* Formatted value based on `multiSelect` state.
|
|
7896
|
+
* Default type is `String`, changing to `Array<String>` when `multiSelect` is true.
|
|
6600
7897
|
* @private
|
|
6601
|
-
* @
|
|
7898
|
+
* @returns {String|Array<String>}
|
|
6602
7899
|
*/
|
|
6603
|
-
get
|
|
6604
|
-
|
|
6605
|
-
|
|
7900
|
+
get formattedValue() {
|
|
7901
|
+
if (this.multiSelect) {
|
|
7902
|
+
if (!this.value) {
|
|
7903
|
+
return undefined;
|
|
7904
|
+
}
|
|
7905
|
+
if (this.value.startsWith("[")) {
|
|
7906
|
+
return JSON.parse(this.value);
|
|
7907
|
+
}
|
|
7908
|
+
return [this.value];
|
|
7909
|
+
}
|
|
7910
|
+
return this.value;
|
|
7911
|
+
}
|
|
7912
|
+
|
|
7913
|
+
/**
|
|
7914
|
+
* Returns classmap configuration for html5 input labels in all layouts.
|
|
7915
|
+
* @private
|
|
7916
|
+
* @returns {Record<string, boolean>}
|
|
7917
|
+
*/
|
|
7918
|
+
get commonLabelClasses() {
|
|
7919
|
+
const obj = {
|
|
7920
|
+
'is-disabled': this.disabled,
|
|
7921
|
+
'withValue': false,
|
|
7922
|
+
'util_displayHiddenVisually': this.hasDisplayValueContent && !this.hasFocus && this.value && this.value.length > 0,
|
|
7923
|
+
[this.labelFontClass]: true
|
|
6606
7924
|
};
|
|
7925
|
+
|
|
7926
|
+
if (this.placeholder) {
|
|
7927
|
+
obj.withValue = true;
|
|
7928
|
+
} else if (this.optionSelected) {
|
|
7929
|
+
if (Array.isArray(this.optionSelected)) {
|
|
7930
|
+
obj.withValue = this.optionSelected.length > 0;
|
|
7931
|
+
} else {
|
|
7932
|
+
obj.withValue = true;
|
|
7933
|
+
}
|
|
7934
|
+
}
|
|
7935
|
+
return obj;
|
|
7936
|
+
}
|
|
7937
|
+
|
|
7938
|
+
/**
|
|
7939
|
+
* Returns the label font class based on layout and selection state.
|
|
7940
|
+
* @private
|
|
7941
|
+
* @returns {string} - The font class for the label.
|
|
7942
|
+
*/
|
|
7943
|
+
get labelFontClass() {
|
|
7944
|
+
const isSelected = this.hasValue;
|
|
7945
|
+
|
|
7946
|
+
if (this.layout.startsWith('emphasized')) {
|
|
7947
|
+
return isSelected ? 'body-sm' : 'accent-xl';
|
|
7948
|
+
}
|
|
7949
|
+
|
|
7950
|
+
if (this.layout === 'snowflake') {
|
|
7951
|
+
return isSelected ? 'body-xs' : 'body-lg';
|
|
7952
|
+
}
|
|
7953
|
+
|
|
7954
|
+
// classic layout (default)
|
|
7955
|
+
return isSelected ? 'body-xs' : 'body-default';
|
|
7956
|
+
}
|
|
7957
|
+
|
|
7958
|
+
/**
|
|
7959
|
+
* Whether or not the component has a value.
|
|
7960
|
+
* @returns {boolean} - Returns true if the component has a value or placeholder.
|
|
7961
|
+
* @private
|
|
7962
|
+
*/
|
|
7963
|
+
get hasValue() {
|
|
7964
|
+
return this.placeholder || (this.value && this.value.length > 0); // eslint-disable-line no-extra-parens
|
|
6607
7965
|
}
|
|
6608
7966
|
|
|
6609
7967
|
/**
|
|
@@ -6616,10 +7974,30 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6616
7974
|
|
|
6617
7975
|
this.dropdown.addEventListener('auroDropdown-toggled', () => {
|
|
6618
7976
|
this.isPopoverVisible = this.dropdown.isPopoverVisible;
|
|
7977
|
+
|
|
7978
|
+
if (this.dropdown.isPopoverVisible) {
|
|
7979
|
+
this.updateMenuShapeSize();
|
|
7980
|
+
// wait til the bib gets fully rendered
|
|
7981
|
+
setTimeout(() => {
|
|
7982
|
+
if (this.dropdown.isBibFullscreen) {
|
|
7983
|
+
// trigger holds the focus since menu is not a focusable element.
|
|
7984
|
+
this.dropdown.trigger.focus();
|
|
7985
|
+
|
|
7986
|
+
// default focus indicator on the first menu option
|
|
7987
|
+
if (this.menu.index < 0) {
|
|
7988
|
+
this.menu.navigateOptions('down');
|
|
7989
|
+
}
|
|
7990
|
+
}
|
|
7991
|
+
});
|
|
7992
|
+
}
|
|
7993
|
+
});
|
|
7994
|
+
|
|
7995
|
+
this.dropdown.addEventListener('auroDropdown-strategy-change', () => {
|
|
7996
|
+
this.updateMenuShapeSize();
|
|
6619
7997
|
});
|
|
6620
7998
|
|
|
6621
7999
|
// setting up bibtemplate
|
|
6622
|
-
this.bibtemplate = this.dropdown.querySelector(this.bibtemplateTag._$litStatic$);
|
|
8000
|
+
this.bibtemplate = this.dropdown.querySelector(this.bibtemplateTag._$litStatic$);
|
|
6623
8001
|
|
|
6624
8002
|
if (this.customBibWidth) {
|
|
6625
8003
|
this.dropdown.dropdownWidth = this.customBibWidth;
|
|
@@ -6638,7 +8016,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6638
8016
|
*
|
|
6639
8017
|
*/
|
|
6640
8018
|
static register(name = "auro-select") {
|
|
6641
|
-
AuroLibraryRuntimeUtils$
|
|
8019
|
+
AuroLibraryRuntimeUtils$5.prototype.registerComponent(name, AuroSelect);
|
|
6642
8020
|
}
|
|
6643
8021
|
|
|
6644
8022
|
/**
|
|
@@ -6682,6 +8060,30 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6682
8060
|
this.dropdown.requestUpdate();
|
|
6683
8061
|
}
|
|
6684
8062
|
|
|
8063
|
+
/**
|
|
8064
|
+
* Update menu to default for fullscreen bib, otherwise to this.size and this.shape.
|
|
8065
|
+
* @private
|
|
8066
|
+
*/
|
|
8067
|
+
updateMenuShapeSize() {
|
|
8068
|
+
if (!this.menu) {
|
|
8069
|
+
return;
|
|
8070
|
+
}
|
|
8071
|
+
|
|
8072
|
+
if (this.dropdown && this.dropdown.isBibFullscreen) {
|
|
8073
|
+
this.menu.setAttribute('size', 'md');
|
|
8074
|
+
this.menu.setAttribute('shape', 'box');
|
|
8075
|
+
} else {
|
|
8076
|
+
// set menu's default size if there it's not specified.
|
|
8077
|
+
if (!this.menu.getAttribute('size')) {
|
|
8078
|
+
this.menu.setAttribute('size', this.layout !== 'emphasized' ? 'md' : this.size);
|
|
8079
|
+
}
|
|
8080
|
+
|
|
8081
|
+
if (!this.getAttribute('shape')) {
|
|
8082
|
+
this.menu.setAttribute('shape', this.layout === 'classic' ? 'box' : this.shape);
|
|
8083
|
+
}
|
|
8084
|
+
}
|
|
8085
|
+
}
|
|
8086
|
+
|
|
6685
8087
|
/**
|
|
6686
8088
|
* Binds all behavior needed to the menu after rendering.
|
|
6687
8089
|
* @private
|
|
@@ -6698,6 +8100,8 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6698
8100
|
return;
|
|
6699
8101
|
}
|
|
6700
8102
|
|
|
8103
|
+
this.updateMenuShapeSize();
|
|
8104
|
+
|
|
6701
8105
|
if (this.multiSelect) {
|
|
6702
8106
|
this.menu.multiSelect = this.multiSelect;
|
|
6703
8107
|
}
|
|
@@ -6735,7 +8139,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6735
8139
|
|
|
6736
8140
|
this.menu.addEventListener('auroMenu-selectValueReset', () => {
|
|
6737
8141
|
this.optionSelected = this.menu.optionSelected;
|
|
6738
|
-
this.
|
|
8142
|
+
this.validate(this);
|
|
6739
8143
|
});
|
|
6740
8144
|
|
|
6741
8145
|
this.menu.addEventListener('auroMenu-activatedOption', (evt) => {
|
|
@@ -6757,46 +8161,58 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6757
8161
|
configureSelect() {
|
|
6758
8162
|
|
|
6759
8163
|
this.addEventListener('keydown', (evt) => {
|
|
6760
|
-
|
|
6761
|
-
|
|
8164
|
+
// when the focus is on trigger not on close button
|
|
8165
|
+
if (this.dropdown.shadowRoot.activeElement === this.dropdown.trigger) {
|
|
8166
|
+
if (evt.key === 'ArrowUp') {
|
|
8167
|
+
evt.preventDefault();
|
|
6762
8168
|
|
|
6763
|
-
|
|
8169
|
+
this.dropdown.show();
|
|
8170
|
+
|
|
8171
|
+
if (this.dropdown.isPopoverVisible) {
|
|
8172
|
+
this.menu.navigateOptions('up');
|
|
8173
|
+
}
|
|
6764
8174
|
|
|
6765
|
-
|
|
6766
|
-
this.menu.navigateOptions('up');
|
|
8175
|
+
return;
|
|
6767
8176
|
}
|
|
6768
8177
|
|
|
6769
|
-
|
|
6770
|
-
|
|
8178
|
+
if (evt.key === 'ArrowDown') {
|
|
8179
|
+
evt.preventDefault();
|
|
6771
8180
|
|
|
6772
|
-
|
|
6773
|
-
evt.preventDefault();
|
|
8181
|
+
this.dropdown.show();
|
|
6774
8182
|
|
|
6775
|
-
|
|
8183
|
+
if (this.dropdown.isPopoverVisible) {
|
|
8184
|
+
this.menu.navigateOptions('down');
|
|
8185
|
+
}
|
|
6776
8186
|
|
|
6777
|
-
|
|
6778
|
-
this.menu.navigateOptions('down');
|
|
8187
|
+
return;
|
|
6779
8188
|
}
|
|
6780
8189
|
|
|
6781
|
-
|
|
6782
|
-
|
|
8190
|
+
if (evt.key === 'Enter') {
|
|
8191
|
+
if (!this.dropdown.isPopoverVisible) {
|
|
8192
|
+
evt.preventDefault();
|
|
8193
|
+
this.menu.makeSelection();
|
|
8194
|
+
}
|
|
6783
8195
|
|
|
6784
|
-
|
|
6785
|
-
if (!this.dropdown.isPopoverVisible) {
|
|
6786
|
-
evt.preventDefault();
|
|
6787
|
-
this.menu.makeSelection();
|
|
8196
|
+
return;
|
|
6788
8197
|
}
|
|
6789
|
-
|
|
6790
|
-
return;
|
|
6791
8198
|
}
|
|
6792
8199
|
|
|
6793
|
-
if (evt.key === 'Tab') {
|
|
8200
|
+
if (evt.key === 'Tab' && this.dropdown.isPopoverVisible) {
|
|
6794
8201
|
if (this.dropdown.isBibFullscreen) {
|
|
6795
8202
|
evt.preventDefault();
|
|
8203
|
+
|
|
8204
|
+
// when the focus is on trigger not on close button
|
|
8205
|
+
if (this.dropdown.shadowRoot.activeElement === this.dropdown.trigger) {
|
|
8206
|
+
// `dropdown.focus` will move focus to the first focusable element in bib when it's open,
|
|
8207
|
+
// when bib it not open, it will focus onto trigger.
|
|
8208
|
+
this.dropdown.focus();
|
|
8209
|
+
} else {
|
|
8210
|
+
// when close button has the focus, move focus back to the trigger
|
|
8211
|
+
this.dropdown.trigger.focus();
|
|
8212
|
+
}
|
|
6796
8213
|
} else {
|
|
6797
8214
|
this.dropdown.hide();
|
|
6798
8215
|
}
|
|
6799
|
-
|
|
6800
8216
|
return;
|
|
6801
8217
|
}
|
|
6802
8218
|
|
|
@@ -6807,7 +8223,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6807
8223
|
this.addEventListener('focusin', this.handleFocusin);
|
|
6808
8224
|
|
|
6809
8225
|
this.addEventListener('blur', () => {
|
|
6810
|
-
this.
|
|
8226
|
+
this.validate();
|
|
6811
8227
|
this.hasFocus = false;
|
|
6812
8228
|
});
|
|
6813
8229
|
}
|
|
@@ -6877,6 +8293,26 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6877
8293
|
}
|
|
6878
8294
|
}
|
|
6879
8295
|
|
|
8296
|
+
/**
|
|
8297
|
+
* Hides the dropdown bib if its open.
|
|
8298
|
+
* @returns {void}
|
|
8299
|
+
*/
|
|
8300
|
+
hideBib() {
|
|
8301
|
+
if (this.dropdown && this.dropdown.isPopoverVisible) {
|
|
8302
|
+
this.dropdown.hide();
|
|
8303
|
+
}
|
|
8304
|
+
}
|
|
8305
|
+
|
|
8306
|
+
/**
|
|
8307
|
+
* Shows the dropdown bib if there are options to show.
|
|
8308
|
+
* @returns {void}
|
|
8309
|
+
*/
|
|
8310
|
+
showBib() {
|
|
8311
|
+
if (this.dropdown && !this.dropdown.isPopoverVisible) {
|
|
8312
|
+
this.dropdown.show();
|
|
8313
|
+
}
|
|
8314
|
+
}
|
|
8315
|
+
|
|
6880
8316
|
/**
|
|
6881
8317
|
* Function to support @focusin event.
|
|
6882
8318
|
* @private
|
|
@@ -6961,38 +8397,47 @@ class AuroSelect extends AuroElement$3 {
|
|
|
6961
8397
|
// Add the tag name as an attribute if it is different than the component name
|
|
6962
8398
|
this.runtimeUtils.handleComponentTagRename(this, 'auro-select');
|
|
6963
8399
|
|
|
6964
|
-
this.configureMenu();
|
|
6965
8400
|
this.configureDropdown();
|
|
8401
|
+
this.configureMenu();
|
|
6966
8402
|
this.configureSelect();
|
|
8403
|
+
}
|
|
6967
8404
|
|
|
6968
|
-
|
|
6969
|
-
|
|
6970
|
-
|
|
6971
|
-
|
|
8405
|
+
/**
|
|
8406
|
+
* Update the menu value. With checks for menu existence. Awaits value update.
|
|
8407
|
+
* @param {string} value - The value to set in the menu.
|
|
8408
|
+
* @returns {void}
|
|
8409
|
+
* @private
|
|
8410
|
+
*/
|
|
8411
|
+
async updateMenuValue(value) {
|
|
8412
|
+
if (!this.menu) return;
|
|
8413
|
+
|
|
8414
|
+
this.menu.setAttribute('value', value);
|
|
8415
|
+
if (value) {
|
|
8416
|
+
this.menu.value = value;
|
|
8417
|
+
} else {
|
|
8418
|
+
this.menu.reset();
|
|
6972
8419
|
}
|
|
8420
|
+
await this.menu.updateComplete;
|
|
6973
8421
|
}
|
|
6974
8422
|
|
|
6975
8423
|
async updated(changedProperties) {
|
|
6976
|
-
if (changedProperties.has('multiSelect')) {
|
|
8424
|
+
if (changedProperties.has('multiSelect') && !changedProperties.has('value')) {
|
|
6977
8425
|
this.clearSelection();
|
|
6978
8426
|
}
|
|
6979
8427
|
|
|
6980
8428
|
if (changedProperties.has('value')) {
|
|
6981
8429
|
if (this.value) {
|
|
6982
|
-
|
|
6983
|
-
|
|
6984
|
-
this.menu.value = this.value;
|
|
8430
|
+
await this.updateMenuValue(this.value);
|
|
6985
8431
|
|
|
6986
|
-
|
|
6987
|
-
|
|
6988
|
-
|
|
6989
|
-
this.optionSelected = this.menu.optionSelected;
|
|
8432
|
+
if (this.menu) {
|
|
8433
|
+
this.optionSelected = this.menu.optionSelected;
|
|
8434
|
+
}
|
|
6990
8435
|
} else {
|
|
6991
|
-
this.
|
|
8436
|
+
await this.updateMenuValue(undefined);
|
|
6992
8437
|
}
|
|
6993
8438
|
|
|
6994
8439
|
this._updateNativeSelect();
|
|
6995
|
-
this.
|
|
8440
|
+
this.validate();
|
|
6996
8441
|
|
|
6997
8442
|
// LEGACY EVENT
|
|
6998
8443
|
this.dispatchEvent(new CustomEvent('auroSelect-valueSet', {
|
|
@@ -7007,7 +8452,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7007
8452
|
composed: true,
|
|
7008
8453
|
detail: {
|
|
7009
8454
|
optionSelected: this.optionSelected,
|
|
7010
|
-
value: this.
|
|
8455
|
+
value: this.formattedValue
|
|
7011
8456
|
}
|
|
7012
8457
|
}));
|
|
7013
8458
|
}
|
|
@@ -7019,6 +8464,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7019
8464
|
if (changedProperties.has('error')) {
|
|
7020
8465
|
this.validate(true);
|
|
7021
8466
|
}
|
|
8467
|
+
|
|
8468
|
+
if (changedProperties.has('shape') && this.menu) {
|
|
8469
|
+
this.menu.setAttribute('shape', this.layout === 'classic' ? 'box' : this.shape);
|
|
8470
|
+
}
|
|
8471
|
+
|
|
8472
|
+
if (changedProperties.has('size') && this.menu) {
|
|
8473
|
+
this.menu.setAttribute('size', this.layout !== 'emphasized' ? 'md' : this.size);
|
|
8474
|
+
}
|
|
7022
8475
|
}
|
|
7023
8476
|
|
|
7024
8477
|
/**
|
|
@@ -7029,16 +8482,6 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7029
8482
|
this.validation.reset(this);
|
|
7030
8483
|
}
|
|
7031
8484
|
|
|
7032
|
-
/**
|
|
7033
|
-
* Hide dropdownbib.
|
|
7034
|
-
* @private
|
|
7035
|
-
*/
|
|
7036
|
-
hideBib() {
|
|
7037
|
-
if (this.dropdown) {
|
|
7038
|
-
this.dropdown.hide();
|
|
7039
|
-
}
|
|
7040
|
-
}
|
|
7041
|
-
|
|
7042
8485
|
/**
|
|
7043
8486
|
* Validates value.
|
|
7044
8487
|
* @param {boolean} [force=false] - Whether to force validation.
|
|
@@ -7058,13 +8501,13 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7058
8501
|
const selectedValue = selectedOption.value;
|
|
7059
8502
|
|
|
7060
8503
|
if (this.multiSelect) {
|
|
7061
|
-
const currentArray =
|
|
8504
|
+
const currentArray = this.formattedValue;
|
|
7062
8505
|
|
|
7063
8506
|
if (!currentArray.includes(selectedValue)) {
|
|
7064
|
-
this.value = [
|
|
8507
|
+
this.value = JSON.stringify([
|
|
7065
8508
|
...currentArray,
|
|
7066
8509
|
selectedValue
|
|
7067
|
-
];
|
|
8510
|
+
]);
|
|
7068
8511
|
}
|
|
7069
8512
|
} else {
|
|
7070
8513
|
const currentValue = this.value;
|
|
@@ -7087,12 +8530,17 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7087
8530
|
}
|
|
7088
8531
|
|
|
7089
8532
|
if (this.multiSelect) {
|
|
7090
|
-
nativeSelect.value = this.
|
|
8533
|
+
nativeSelect.value = this.multiSelect ? this.multiSelect[0] : '';
|
|
7091
8534
|
} else {
|
|
7092
8535
|
nativeSelect.value = this.value || '';
|
|
7093
8536
|
}
|
|
7094
8537
|
}
|
|
7095
8538
|
|
|
8539
|
+
/**
|
|
8540
|
+
* Returns HTML for the hidden a11y screen reader content.
|
|
8541
|
+
* @private
|
|
8542
|
+
* @returns {html} - Returns HTML for the hidden a11y screen reader content.
|
|
8543
|
+
*/
|
|
7096
8544
|
renderAriaHtml() {
|
|
7097
8545
|
return html`
|
|
7098
8546
|
<div aria-live="polite" class="util_displayHiddenVisually">
|
|
@@ -7113,10 +8561,15 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7113
8561
|
`;
|
|
7114
8562
|
}
|
|
7115
8563
|
|
|
8564
|
+
/**
|
|
8565
|
+
* Returns HTML for the hidden HTML5 select.
|
|
8566
|
+
* @private
|
|
8567
|
+
* @returns {html} - Returns HTML for the hidden HTML5 select.
|
|
8568
|
+
*/
|
|
7116
8569
|
renderNativeSelect() {
|
|
7117
8570
|
return html`
|
|
7118
|
-
<div class="nativeSelectWrapper">
|
|
7119
|
-
<select
|
|
8571
|
+
<div class="nativeSelectWrapper util_displayHidden">
|
|
8572
|
+
<select
|
|
7120
8573
|
tabindex="-1"
|
|
7121
8574
|
id="${`native-select-${this.id || this.uniqueId}`}"
|
|
7122
8575
|
name="${this.name || ''}"
|
|
@@ -7129,8 +8582,8 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7129
8582
|
${this.options.map((option) => {
|
|
7130
8583
|
const optionValue = option.value || option.textContent;
|
|
7131
8584
|
return html`
|
|
7132
|
-
<option
|
|
7133
|
-
value="${optionValue}"
|
|
8585
|
+
<option
|
|
8586
|
+
value="${optionValue}"
|
|
7134
8587
|
?selected="${this.value === optionValue}">
|
|
7135
8588
|
${option.textContent}
|
|
7136
8589
|
</option>
|
|
@@ -7152,14 +8605,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7152
8605
|
? html`
|
|
7153
8606
|
<${this.helpTextTag} ?onDark="${this.onDark}">
|
|
7154
8607
|
<p id="${this.uniqueId}" part="helpText">
|
|
7155
|
-
<slot name="
|
|
8608
|
+
<slot name="helpText"></slot>
|
|
7156
8609
|
</p>
|
|
7157
8610
|
</${this.helpTextTag}>
|
|
7158
8611
|
`
|
|
7159
8612
|
: html`
|
|
7160
8613
|
<${this.helpTextTag} error ?onDark="${this.onDark}">
|
|
7161
8614
|
<p id="${this.uniqueId}" role="alert" aria-live="assertive" part="helpText">
|
|
7162
|
-
|
|
8615
|
+
${this.errorMessage}
|
|
7163
8616
|
</p>
|
|
7164
8617
|
</${this.helpTextTag}>
|
|
7165
8618
|
`
|
|
@@ -7172,17 +8625,16 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7172
8625
|
* @private
|
|
7173
8626
|
* @returns {import("lit").TemplateResult} - Returns HTML for the emphasized layout.
|
|
7174
8627
|
*/
|
|
7175
|
-
// TODO update to use util class
|
|
7176
8628
|
renderLayoutEmphasized() {
|
|
7177
8629
|
const placeholderClass = {
|
|
7178
|
-
|
|
8630
|
+
'util_displayHidden': this.value
|
|
7179
8631
|
};
|
|
7180
8632
|
|
|
7181
8633
|
const displayValueClasses = {
|
|
7182
8634
|
'displayValue': true,
|
|
7183
8635
|
'hasContent': this.hasDisplayValueContent,
|
|
7184
8636
|
'hasFocus': this.isPopoverVisible,
|
|
7185
|
-
'withValue': this.
|
|
8637
|
+
'withValue': this.commonLabelClasses.withValue,
|
|
7186
8638
|
'force': this.forceDisplayValue,
|
|
7187
8639
|
};
|
|
7188
8640
|
|
|
@@ -7193,22 +8645,21 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7193
8645
|
|
|
7194
8646
|
return html`
|
|
7195
8647
|
<div
|
|
7196
|
-
class="${classMap(this.commonWrapperClasses)}"
|
|
7197
8648
|
part="wrapper">
|
|
7198
8649
|
<div id="slotHolder" aria-hidden="true">
|
|
7199
8650
|
<slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
|
|
7200
8651
|
</div>
|
|
7201
8652
|
<${this.dropdownTag}
|
|
8653
|
+
a11yRole="select"
|
|
7202
8654
|
?autoPlacement="${this.autoPlacement}"
|
|
7203
8655
|
?error="${this.validity !== undefined && this.validity !== 'valid'}"
|
|
7204
|
-
?matchWidth="${
|
|
8656
|
+
?matchWidth="${this.matchWidth}"
|
|
7205
8657
|
?noFlip="${this.noFlip}"
|
|
7206
8658
|
?onDark="${this.onDark}"
|
|
7207
8659
|
.fullscreenBreakpoint="${this.fullscreenBreakpoint}"
|
|
7208
8660
|
.offset="${this.offset}"
|
|
7209
8661
|
.placement="${this.placement}"
|
|
7210
8662
|
chevron
|
|
7211
|
-
fluid
|
|
7212
8663
|
for="selectMenu"
|
|
7213
8664
|
layout="${this.layout}"
|
|
7214
8665
|
part="dropdown"
|
|
@@ -7220,15 +8671,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7220
8671
|
</div>
|
|
7221
8672
|
<div class="mainContent">
|
|
7222
8673
|
<div class="${classMap(valueContainerClasses)}">
|
|
7223
|
-
<label>
|
|
8674
|
+
<label class="${classMap(this.commonLabelClasses)}">
|
|
7224
8675
|
<slot name="label"></slot>
|
|
8676
|
+
${this.required ? undefined : html`<slot name="optionalLabel"> (optional)</slot>`}
|
|
7225
8677
|
</label>
|
|
7226
8678
|
<div class="value" id="value"></div>
|
|
7227
|
-
${
|
|
7228
|
-
|
|
7229
|
-
|
|
7230
|
-
</div>
|
|
7231
|
-
`}
|
|
8679
|
+
<div id="placeholder" class="${classMap(placeholderClass)}">
|
|
8680
|
+
${this.placeholder}
|
|
8681
|
+
</div>
|
|
7232
8682
|
</div>
|
|
7233
8683
|
<div class="${classMap(displayValueClasses)}" aria-hidden="true" part="displayValue">
|
|
7234
8684
|
<slot name="displayValue"></slot>
|
|
@@ -7238,6 +8688,7 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7238
8688
|
</div>
|
|
7239
8689
|
<div class="menuWrapper"></div>
|
|
7240
8690
|
<${this.bibtemplateTag} ?large="${this.largeFullscreenHeadline}" @close-click="${this.hideBib}">
|
|
8691
|
+
<slot name="ariaLabel.bib.close" slot="ariaLabel.close">Close</slot>
|
|
7241
8692
|
<slot></slot>
|
|
7242
8693
|
</${this.bibtemplateTag}>
|
|
7243
8694
|
<div slot="helpText">
|
|
@@ -7255,14 +8706,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7255
8706
|
*/
|
|
7256
8707
|
renderLayoutSnowflake() {
|
|
7257
8708
|
const placeholderClass = {
|
|
7258
|
-
|
|
8709
|
+
'util_displayHidden': this.value
|
|
7259
8710
|
};
|
|
7260
8711
|
|
|
7261
8712
|
const displayValueClasses = {
|
|
7262
8713
|
'displayValue': true,
|
|
7263
8714
|
'hasContent': this.hasDisplayValueContent,
|
|
7264
8715
|
'hasFocus': this.isPopoverVisible,
|
|
7265
|
-
'withValue': this.
|
|
8716
|
+
'withValue': this.commonLabelClasses.withValue,
|
|
7266
8717
|
'force': this.forceDisplayValue,
|
|
7267
8718
|
};
|
|
7268
8719
|
|
|
@@ -7273,7 +8724,6 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7273
8724
|
|
|
7274
8725
|
return html`
|
|
7275
8726
|
<div
|
|
7276
|
-
class="${classMap(this.commonWrapperClasses)}"
|
|
7277
8727
|
part="wrapper">
|
|
7278
8728
|
<div id="slotHolder" aria-hidden="true">
|
|
7279
8729
|
<slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
|
|
@@ -7281,14 +8731,13 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7281
8731
|
<${this.dropdownTag}
|
|
7282
8732
|
?autoPlacement="${this.autoPlacement}"
|
|
7283
8733
|
?error="${this.validity !== undefined && this.validity !== 'valid'}"
|
|
7284
|
-
?matchWidth="${
|
|
8734
|
+
?matchWidth="${this.matchWidth}"
|
|
7285
8735
|
?noFlip="${this.noFlip}"
|
|
7286
8736
|
?onDark="${this.onDark}"
|
|
7287
8737
|
.fullscreenBreakpoint="${this.fullscreenBreakpoint}"
|
|
7288
8738
|
.offset="${this.offset}"
|
|
7289
8739
|
.placement="${this.placement}"
|
|
7290
8740
|
chevron
|
|
7291
|
-
fluid
|
|
7292
8741
|
for="selectMenu"
|
|
7293
8742
|
layout="${this.layout}"
|
|
7294
8743
|
part="dropdown"
|
|
@@ -7300,15 +8749,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7300
8749
|
</div>
|
|
7301
8750
|
<div class="mainContent">
|
|
7302
8751
|
<div class="${classMap(valueContainerClasses)}">
|
|
7303
|
-
<label>
|
|
8752
|
+
<label class="${classMap(this.commonLabelClasses)}">
|
|
7304
8753
|
<slot name="label"></slot>
|
|
8754
|
+
${this.required ? undefined : html`<slot name="optionalLabel"> (optional)</slot>`}
|
|
7305
8755
|
</label>
|
|
7306
8756
|
<div class="value" id="value"></div>
|
|
7307
|
-
${
|
|
7308
|
-
|
|
7309
|
-
|
|
7310
|
-
</div>
|
|
7311
|
-
`}
|
|
8757
|
+
<div id="placeholder" class="${classMap(placeholderClass)}">
|
|
8758
|
+
${this.placeholder}
|
|
8759
|
+
</div>
|
|
7312
8760
|
</div>
|
|
7313
8761
|
<div class="${classMap(displayValueClasses)}" aria-hidden="true" part="displayValue">
|
|
7314
8762
|
<slot name="displayValue"></slot>
|
|
@@ -7318,12 +8766,14 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7318
8766
|
</div>
|
|
7319
8767
|
<div class="menuWrapper"></div>
|
|
7320
8768
|
<${this.bibtemplateTag} ?large="${this.largeFullscreenHeadline}" @close-click="${this.hideBib}">
|
|
8769
|
+
<slot name="ariaLabel.bib.close" slot="ariaLabel.close">Close</slot>
|
|
7321
8770
|
<slot></slot>
|
|
7322
8771
|
</${this.bibtemplateTag}>
|
|
7323
8772
|
<div slot="helpText">
|
|
7324
8773
|
${this.renderHtmlHelpText()}
|
|
7325
8774
|
</div>
|
|
7326
8775
|
</${this.dropdownTag}>
|
|
8776
|
+
${this.renderNativeSelect()}
|
|
7327
8777
|
</div>
|
|
7328
8778
|
`;
|
|
7329
8779
|
}
|
|
@@ -7334,11 +8784,80 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7334
8784
|
* @returns {import("lit").TemplateResult} - Returns HTML for the classic layout.
|
|
7335
8785
|
*/
|
|
7336
8786
|
renderLayoutClassic() {
|
|
8787
|
+
const placeholderClass = {
|
|
8788
|
+
'util_displayHidden': this.value
|
|
8789
|
+
};
|
|
8790
|
+
|
|
8791
|
+
const displayValueClasses = {
|
|
8792
|
+
'displayValue': true,
|
|
8793
|
+
'hasContent': this.hasDisplayValueContent,
|
|
8794
|
+
'hasFocus': this.isPopoverVisible,
|
|
8795
|
+
'withValue': this.commonLabelClasses.withValue,
|
|
8796
|
+
'force': this.forceDisplayValue,
|
|
8797
|
+
};
|
|
8798
|
+
|
|
8799
|
+
const valueContainerClasses = {
|
|
8800
|
+
'valueContainer': true,
|
|
8801
|
+
'util_displayHiddenVisually': (this.forceDisplayValue || !(this.dropdown && this.dropdown.isPopoverVisible)) && this.hasDisplayValueContent
|
|
8802
|
+
};
|
|
8803
|
+
|
|
8804
|
+
const valueClasses = {
|
|
8805
|
+
'value': true,
|
|
8806
|
+
'body-default': true
|
|
8807
|
+
};
|
|
8808
|
+
|
|
7337
8809
|
return html`
|
|
7338
8810
|
<div
|
|
7339
|
-
class="${classMap(this.commonWrapperClasses)} thin"
|
|
7340
8811
|
part="wrapper">
|
|
7341
|
-
|
|
8812
|
+
<div id="slotHolder" aria-hidden="true">
|
|
8813
|
+
<slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
|
|
8814
|
+
</div>
|
|
8815
|
+
<${this.dropdownTag}
|
|
8816
|
+
?autoPlacement="${this.autoPlacement}"
|
|
8817
|
+
?error="${this.validity !== undefined && this.validity !== 'valid'}"
|
|
8818
|
+
?matchWidth="${!this.flexMenuWidth}"
|
|
8819
|
+
?noFlip="${this.noFlip}"
|
|
8820
|
+
?onDark="${this.onDark}"
|
|
8821
|
+
.fullscreenBreakpoint="${this.fullscreenBreakpoint}"
|
|
8822
|
+
.offset="${this.offset}"
|
|
8823
|
+
.placement="${this.placement}"
|
|
8824
|
+
chevron
|
|
8825
|
+
for="selectMenu"
|
|
8826
|
+
layout="${this.layout}"
|
|
8827
|
+
part="dropdown"
|
|
8828
|
+
shape="${this.shape}"
|
|
8829
|
+
size="${this.size}">
|
|
8830
|
+
<div slot="trigger" aria-haspopup="true" id="triggerFocus" class="triggerContent">
|
|
8831
|
+
<div class="accents left">
|
|
8832
|
+
<slot name="typeIcon"></slot>
|
|
8833
|
+
</div>
|
|
8834
|
+
<div class="mainContent">
|
|
8835
|
+
<div class="${classMap(valueContainerClasses)}">
|
|
8836
|
+
<label class="${classMap(this.commonLabelClasses)}">
|
|
8837
|
+
<slot name="label"></slot>
|
|
8838
|
+
${this.required ? undefined : html`<slot name="optionalLabel"> (optional)</slot>`}
|
|
8839
|
+
</label>
|
|
8840
|
+
<div class="${classMap(valueClasses)}" id="value"></div>
|
|
8841
|
+
<div id="placeholder" class="${classMap(placeholderClass)}">
|
|
8842
|
+
${this.placeholder}
|
|
8843
|
+
</div>
|
|
8844
|
+
</div>
|
|
8845
|
+
<div class="${classMap(displayValueClasses)}" aria-hidden="true" part="displayValue">
|
|
8846
|
+
<slot name="displayValue"></slot>
|
|
8847
|
+
</div>
|
|
8848
|
+
</div>
|
|
8849
|
+
<div class="accents right"></div>
|
|
8850
|
+
</div>
|
|
8851
|
+
<div class="menuWrapper"></div>
|
|
8852
|
+
<${this.bibtemplateTag} ?large="${this.largeFullscreenHeadline}" @close-click="${this.hideBib}">
|
|
8853
|
+
<slot name="ariaLabel.bib.close" slot="ariaLabel.close">Close</slot>
|
|
8854
|
+
<slot></slot>
|
|
8855
|
+
</${this.bibtemplateTag}>
|
|
8856
|
+
<div slot="helpText">
|
|
8857
|
+
${this.renderHtmlHelpText()}
|
|
8858
|
+
</div>
|
|
8859
|
+
</${this.dropdownTag}>
|
|
8860
|
+
${this.renderNativeSelect()}
|
|
7342
8861
|
</div>
|
|
7343
8862
|
`;
|
|
7344
8863
|
}
|
|
@@ -7372,105 +8891,6 @@ class AuroSelect extends AuroElement$3 {
|
|
|
7372
8891
|
|
|
7373
8892
|
// When using auroElement, use the following attribute and function when hiding content from screen readers.
|
|
7374
8893
|
// aria-hidden="${this.hideAudible(this.hiddenAudible)}"
|
|
7375
|
-
|
|
7376
|
-
// function that renders the HTML and CSS into the scope of the component
|
|
7377
|
-
renderBACKUP() {
|
|
7378
|
-
const placeholderClass = {
|
|
7379
|
-
hidden: this.value,
|
|
7380
|
-
};
|
|
7381
|
-
|
|
7382
|
-
return html`
|
|
7383
|
-
<div class="outerWrapper">
|
|
7384
|
-
<div aria-live="polite" class="util_displayHiddenVisually">
|
|
7385
|
-
${this.optionActive && this.options.length > 0
|
|
7386
|
-
? html`
|
|
7387
|
-
${`${this.optionActive.innerText}, option ${this.options.indexOf(this.optionActive) + 1} of ${this.options.length}`}
|
|
7388
|
-
`
|
|
7389
|
-
: undefined
|
|
7390
|
-
};
|
|
7391
|
-
|
|
7392
|
-
${this.optionSelected && this.options.length > 0
|
|
7393
|
-
? html`
|
|
7394
|
-
${`${this.optionSelected.innerText} selected`}
|
|
7395
|
-
`
|
|
7396
|
-
: undefined
|
|
7397
|
-
};
|
|
7398
|
-
</div>
|
|
7399
|
-
<div id="slotHolder" aria-hidden="true">
|
|
7400
|
-
<slot name="bib.fullscreen.headline" @slotchange="${this.handleSlotChange}"></slot>
|
|
7401
|
-
</div>
|
|
7402
|
-
<${this.dropdownTag}
|
|
7403
|
-
?autoPlacement="${this.autoPlacement}"
|
|
7404
|
-
?disabled="${this.disabled}"
|
|
7405
|
-
?error="${this.validity !== undefined && this.validity !== 'valid'}"
|
|
7406
|
-
?matchWidth="${!this.flexMenuWidth}"
|
|
7407
|
-
?noFlip="${this.noFlip}"
|
|
7408
|
-
?onDark="${this.onDark}"
|
|
7409
|
-
.fullscreenBreakpoint="${this.fullscreenBreakpoint}"
|
|
7410
|
-
.offset="${this.offset}"
|
|
7411
|
-
.placement="${this.placement}"
|
|
7412
|
-
chevron
|
|
7413
|
-
fluid
|
|
7414
|
-
for="selectMenu"
|
|
7415
|
-
layout="${this.layout}"
|
|
7416
|
-
part="dropdown"
|
|
7417
|
-
shape="${this.shape}"
|
|
7418
|
-
size="${this.size}">
|
|
7419
|
-
<span slot="trigger" aria-haspopup="true" id="triggerFocus">
|
|
7420
|
-
<span id="placeholder"
|
|
7421
|
-
class="${classMap(placeholderClass)}"
|
|
7422
|
-
?aria-hidden="${this.optionSelected && this.optionSelected.length ? 'true' : false}"
|
|
7423
|
-
>
|
|
7424
|
-
<slot name="placeholder"></slot>
|
|
7425
|
-
</span>
|
|
7426
|
-
<slot name="valueText" id="valueText"></slot>
|
|
7427
|
-
</span>
|
|
7428
|
-
|
|
7429
|
-
<${this.bibtemplateTag} ?large="${this.largeFullscreenHeadline}" @close-click="${this.hideBib}">
|
|
7430
|
-
<slot></slot>
|
|
7431
|
-
</${this.bibtemplateTag}>
|
|
7432
|
-
<slot name="label" slot="label"></slot>
|
|
7433
|
-
<p slot="helpText">
|
|
7434
|
-
${!this.validity || this.validity === undefined || this.validity === 'valid'
|
|
7435
|
-
? html`
|
|
7436
|
-
<span id="${this.uniqueId}" part="helpText">
|
|
7437
|
-
<slot name="helpText"></slot>
|
|
7438
|
-
</span>`
|
|
7439
|
-
: html`
|
|
7440
|
-
<span id="${this.uniqueId}" role="alert" aria-live="assertive" part="helpText">
|
|
7441
|
-
${this.errorMessage}
|
|
7442
|
-
</span>`
|
|
7443
|
-
}
|
|
7444
|
-
</p>
|
|
7445
|
-
</${this.dropdownTag}>
|
|
7446
|
-
<div class="nativeSelectWrapper">
|
|
7447
|
-
<select
|
|
7448
|
-
tabindex="-1"
|
|
7449
|
-
id="${`native-select-${this.id || this.uniqueId}`}"
|
|
7450
|
-
name="${this.name || ''}"
|
|
7451
|
-
?disabled="${this.disabled}"
|
|
7452
|
-
?required="${this.required}"
|
|
7453
|
-
aria-hidden="true"
|
|
7454
|
-
autocomplete="${ifDefined$1(this.autocomplete)}"
|
|
7455
|
-
@change="${this._handleNativeSelectChange}">
|
|
7456
|
-
<option value="" ?selected="${!this.value}"></option>
|
|
7457
|
-
${this.options.map((option) => {
|
|
7458
|
-
const optionValue = option.value || option.textContent;
|
|
7459
|
-
return html`
|
|
7460
|
-
<option
|
|
7461
|
-
value="${optionValue}"
|
|
7462
|
-
?selected="${this.value === optionValue}">
|
|
7463
|
-
${option.textContent}
|
|
7464
|
-
</option>
|
|
7465
|
-
`;
|
|
7466
|
-
})}
|
|
7467
|
-
</select>
|
|
7468
|
-
</div>
|
|
7469
|
-
<!-- Help text and error message template -->
|
|
7470
|
-
${this.renderHtmlHelpText()}
|
|
7471
|
-
</div>
|
|
7472
|
-
`;
|
|
7473
|
-
}
|
|
7474
8894
|
}
|
|
7475
8895
|
|
|
7476
8896
|
AuroSelect.register();
|