@aurodesignsystem/auro-formkit 4.0.0 → 4.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -23
- package/components/bibtemplate/dist/auro-bibtemplate.d.ts +1 -0
- package/components/bibtemplate/dist/index.js +158 -6
- package/components/bibtemplate/dist/registered.js +158 -6
- package/components/checkbox/demo/api.min.js +4 -3
- package/components/checkbox/demo/index.min.js +4 -3
- package/components/checkbox/dist/index.js +4 -3
- package/components/checkbox/dist/registered.js +4 -3
- package/components/combobox/demo/api.min.js +707 -133
- package/components/combobox/demo/index.min.js +707 -133
- package/components/combobox/dist/auro-combobox.d.ts +0 -8
- package/components/combobox/dist/index.js +627 -123
- package/components/combobox/dist/registered.js +627 -123
- package/components/counter/demo/api.min.js +583 -43
- package/components/counter/demo/index.min.js +583 -43
- package/components/counter/dist/index.js +583 -43
- package/components/counter/dist/registered.js +583 -43
- package/components/datepicker/demo/api.min.js +866 -75
- package/components/datepicker/demo/index.min.js +866 -75
- package/components/datepicker/dist/index.js +866 -75
- package/components/datepicker/dist/registered.js +866 -75
- package/components/dropdown/demo/api.min.js +153 -16
- package/components/dropdown/demo/index.min.js +153 -16
- package/components/dropdown/dist/auro-dropdownBib.d.ts +8 -0
- package/components/dropdown/dist/index.js +153 -16
- package/components/dropdown/dist/registered.js +153 -16
- package/components/input/demo/api.min.js +263 -12
- package/components/input/demo/index.min.js +263 -12
- package/components/input/dist/index.js +263 -12
- package/components/input/dist/registered.js +263 -12
- package/components/menu/demo/api.min.js +76 -6
- package/components/menu/demo/index.min.js +76 -6
- package/components/menu/dist/index.js +76 -6
- package/components/menu/dist/registered.js +76 -6
- package/components/radio/demo/api.min.js +4 -3
- package/components/radio/demo/index.min.js +4 -3
- package/components/radio/dist/index.js +4 -3
- package/components/radio/dist/registered.js +4 -3
- package/components/select/demo/api.min.js +403 -49
- package/components/select/demo/index.min.js +403 -49
- package/components/select/dist/auro-select.d.ts +0 -1
- package/components/select/dist/index.js +325 -41
- package/components/select/dist/registered.js +325 -41
- package/package.json +3 -3
|
@@ -4029,9 +4029,10 @@ class DateFormatter {
|
|
|
4029
4029
|
/**
|
|
4030
4030
|
* Convert a date object to string format.
|
|
4031
4031
|
* @param {Object} date - Date to convert to string.
|
|
4032
|
-
* @
|
|
4032
|
+
* @param {String} locale - Optional locale to use for the date string. Defaults to user's locale.
|
|
4033
|
+
* @returns {String} Returns the date as a string.
|
|
4033
4034
|
*/
|
|
4034
|
-
this.getDateAsString = (date) => date.toLocaleDateString(
|
|
4035
|
+
this.getDateAsString = (date, locale = undefined) => date.toLocaleDateString(locale, {
|
|
4035
4036
|
year: "numeric",
|
|
4036
4037
|
month: "2-digit",
|
|
4037
4038
|
day: "2-digit",
|
|
@@ -4223,7 +4224,7 @@ class AuroDateUtilities extends AuroDateUtilitiesBase {
|
|
|
4223
4224
|
const dateObj = new Date(this.getFourDigitYear(dateParts.year), dateParts.month - 1, dateParts.day || 1);
|
|
4224
4225
|
|
|
4225
4226
|
// Get the date string of the date object we created from the string date
|
|
4226
|
-
const actualDateStr = dateFormatter.getDateAsString(dateObj);
|
|
4227
|
+
const actualDateStr = dateFormatter.getDateAsString(dateObj, "en-US");
|
|
4227
4228
|
|
|
4228
4229
|
// Guard Clause: Generated date matches date string input
|
|
4229
4230
|
if (expectedDateStr !== actualDateStr) {
|
|
@@ -4388,7 +4389,7 @@ const {
|
|
|
4388
4389
|
|
|
4389
4390
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
4390
4391
|
|
|
4391
|
-
let AuroLibraryRuntimeUtils$
|
|
4392
|
+
let AuroLibraryRuntimeUtils$4 = class AuroLibraryRuntimeUtils {
|
|
4392
4393
|
|
|
4393
4394
|
/* eslint-disable jsdoc/require-param */
|
|
4394
4395
|
|
|
@@ -4458,7 +4459,7 @@ let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
|
4458
4459
|
class AuroFormValidation {
|
|
4459
4460
|
|
|
4460
4461
|
constructor() {
|
|
4461
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
4462
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$4();
|
|
4462
4463
|
}
|
|
4463
4464
|
|
|
4464
4465
|
/**
|
|
@@ -5840,7 +5841,7 @@ class BaseInput extends LitElement {
|
|
|
5840
5841
|
// See LICENSE in the project root for license information.
|
|
5841
5842
|
|
|
5842
5843
|
|
|
5843
|
-
class AuroDependencyVersioning {
|
|
5844
|
+
let AuroDependencyVersioning$1 = class AuroDependencyVersioning {
|
|
5844
5845
|
|
|
5845
5846
|
/**
|
|
5846
5847
|
* Generates a unique string to be used for child auro element naming.
|
|
@@ -5874,7 +5875,7 @@ class AuroDependencyVersioning {
|
|
|
5874
5875
|
|
|
5875
5876
|
return tag;
|
|
5876
5877
|
}
|
|
5877
|
-
}
|
|
5878
|
+
};
|
|
5878
5879
|
|
|
5879
5880
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5880
5881
|
// See LICENSE in the project root for license information.
|
|
@@ -6030,6 +6031,76 @@ var tokensCss$3 = css`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-d
|
|
|
6030
6031
|
|
|
6031
6032
|
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)}`;
|
|
6032
6033
|
|
|
6034
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6035
|
+
// See LICENSE in the project root for license information.
|
|
6036
|
+
|
|
6037
|
+
// ---------------------------------------------------------------------
|
|
6038
|
+
|
|
6039
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
6040
|
+
|
|
6041
|
+
let AuroLibraryRuntimeUtils$3 = class AuroLibraryRuntimeUtils {
|
|
6042
|
+
|
|
6043
|
+
/* eslint-disable jsdoc/require-param */
|
|
6044
|
+
|
|
6045
|
+
/**
|
|
6046
|
+
* This will register a new custom element with the browser.
|
|
6047
|
+
* @param {String} name - The name of the custom element.
|
|
6048
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
6049
|
+
* @returns {void}
|
|
6050
|
+
*/
|
|
6051
|
+
registerComponent(name, componentClass) {
|
|
6052
|
+
if (!customElements.get(name)) {
|
|
6053
|
+
customElements.define(name, class extends componentClass {});
|
|
6054
|
+
}
|
|
6055
|
+
}
|
|
6056
|
+
|
|
6057
|
+
/**
|
|
6058
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
6059
|
+
* @returns {void}
|
|
6060
|
+
*/
|
|
6061
|
+
closestElement(
|
|
6062
|
+
selector, // selector like in .closest()
|
|
6063
|
+
base = this, // extra functionality to skip a parent
|
|
6064
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
6065
|
+
!el || el === document || el === window
|
|
6066
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
6067
|
+
: found
|
|
6068
|
+
? found // found a selector INside this element
|
|
6069
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
6070
|
+
) {
|
|
6071
|
+
return __Closest(base);
|
|
6072
|
+
}
|
|
6073
|
+
/* eslint-enable jsdoc/require-param */
|
|
6074
|
+
|
|
6075
|
+
/**
|
|
6076
|
+
* 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.
|
|
6077
|
+
* @param {Object} elem - The element to check.
|
|
6078
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
6079
|
+
* @returns {void}
|
|
6080
|
+
*/
|
|
6081
|
+
handleComponentTagRename(elem, tagName) {
|
|
6082
|
+
const tag = tagName.toLowerCase();
|
|
6083
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6084
|
+
|
|
6085
|
+
if (elemTag !== tag) {
|
|
6086
|
+
elem.setAttribute(tag, true);
|
|
6087
|
+
}
|
|
6088
|
+
}
|
|
6089
|
+
|
|
6090
|
+
/**
|
|
6091
|
+
* Validates if an element is a specific Auro component.
|
|
6092
|
+
* @param {Object} elem - The element to validate.
|
|
6093
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
6094
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
6095
|
+
*/
|
|
6096
|
+
elementMatch(elem, tagName) {
|
|
6097
|
+
const tag = tagName.toLowerCase();
|
|
6098
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6099
|
+
|
|
6100
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
6101
|
+
}
|
|
6102
|
+
};
|
|
6103
|
+
|
|
6033
6104
|
// Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
6034
6105
|
// See LICENSE in the project root for license information.
|
|
6035
6106
|
|
|
@@ -6049,7 +6120,7 @@ class AuroIcon extends BaseIcon {
|
|
|
6049
6120
|
*/
|
|
6050
6121
|
privateDefaults() {
|
|
6051
6122
|
this.uri = 'https://cdn.jsdelivr.net/npm/@alaskaairux/icons@latest/dist';
|
|
6052
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
6123
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$3();
|
|
6053
6124
|
}
|
|
6054
6125
|
|
|
6055
6126
|
// function to define props used within the scope of this component
|
|
@@ -6131,7 +6202,7 @@ class AuroIcon extends BaseIcon {
|
|
|
6131
6202
|
*
|
|
6132
6203
|
*/
|
|
6133
6204
|
static register(name = "auro-icon") {
|
|
6134
|
-
AuroLibraryRuntimeUtils$
|
|
6205
|
+
AuroLibraryRuntimeUtils$3.prototype.registerComponent(name, AuroIcon);
|
|
6135
6206
|
}
|
|
6136
6207
|
|
|
6137
6208
|
connectedCallback() {
|
|
@@ -6199,12 +6270,192 @@ class AuroIcon extends BaseIcon {
|
|
|
6199
6270
|
|
|
6200
6271
|
var iconVersion = '8.0.1';
|
|
6201
6272
|
|
|
6273
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6274
|
+
// See LICENSE in the project root for license information.
|
|
6275
|
+
|
|
6276
|
+
|
|
6277
|
+
class AuroDependencyVersioning {
|
|
6278
|
+
|
|
6279
|
+
/**
|
|
6280
|
+
* Generates a unique string to be used for child auro element naming.
|
|
6281
|
+
* @private
|
|
6282
|
+
* @param {string} baseName - Defines the first part of the unique element name.
|
|
6283
|
+
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
6284
|
+
* @returns {string} - Unique string to be used for naming.
|
|
6285
|
+
*/
|
|
6286
|
+
generateElementName(baseName, version) {
|
|
6287
|
+
let result = baseName;
|
|
6288
|
+
|
|
6289
|
+
result += '-';
|
|
6290
|
+
result += version.replace(/[.]/g, '_');
|
|
6291
|
+
|
|
6292
|
+
return result;
|
|
6293
|
+
}
|
|
6294
|
+
|
|
6295
|
+
/**
|
|
6296
|
+
* Generates a unique string to be used for child auro element naming.
|
|
6297
|
+
* @param {string} baseName - Defines the first part of the unique element name.
|
|
6298
|
+
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
6299
|
+
* @returns {string} - Unique string to be used for naming.
|
|
6300
|
+
*/
|
|
6301
|
+
generateTag(baseName, version, tagClass) {
|
|
6302
|
+
const elementName = this.generateElementName(baseName, version);
|
|
6303
|
+
const tag = literal`${unsafeStatic(elementName)}`;
|
|
6304
|
+
|
|
6305
|
+
if (!customElements.get(elementName)) {
|
|
6306
|
+
customElements.define(elementName, class extends tagClass {});
|
|
6307
|
+
}
|
|
6308
|
+
|
|
6309
|
+
return tag;
|
|
6310
|
+
}
|
|
6311
|
+
}
|
|
6312
|
+
|
|
6313
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6314
|
+
// See LICENSE in the project root for license information.
|
|
6315
|
+
|
|
6316
|
+
// ---------------------------------------------------------------------
|
|
6317
|
+
|
|
6318
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
6319
|
+
|
|
6320
|
+
let AuroLibraryRuntimeUtils$2 = class AuroLibraryRuntimeUtils {
|
|
6321
|
+
|
|
6322
|
+
/* eslint-disable jsdoc/require-param */
|
|
6323
|
+
|
|
6324
|
+
/**
|
|
6325
|
+
* This will register a new custom element with the browser.
|
|
6326
|
+
* @param {String} name - The name of the custom element.
|
|
6327
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
6328
|
+
* @returns {void}
|
|
6329
|
+
*/
|
|
6330
|
+
registerComponent(name, componentClass) {
|
|
6331
|
+
if (!customElements.get(name)) {
|
|
6332
|
+
customElements.define(name, class extends componentClass {});
|
|
6333
|
+
}
|
|
6334
|
+
}
|
|
6335
|
+
|
|
6336
|
+
/**
|
|
6337
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
6338
|
+
* @returns {void}
|
|
6339
|
+
*/
|
|
6340
|
+
closestElement(
|
|
6341
|
+
selector, // selector like in .closest()
|
|
6342
|
+
base = this, // extra functionality to skip a parent
|
|
6343
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
6344
|
+
!el || el === document || el === window
|
|
6345
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
6346
|
+
: found
|
|
6347
|
+
? found // found a selector INside this element
|
|
6348
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
6349
|
+
) {
|
|
6350
|
+
return __Closest(base);
|
|
6351
|
+
}
|
|
6352
|
+
/* eslint-enable jsdoc/require-param */
|
|
6353
|
+
|
|
6354
|
+
/**
|
|
6355
|
+
* 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.
|
|
6356
|
+
* @param {Object} elem - The element to check.
|
|
6357
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
6358
|
+
* @returns {void}
|
|
6359
|
+
*/
|
|
6360
|
+
handleComponentTagRename(elem, tagName) {
|
|
6361
|
+
const tag = tagName.toLowerCase();
|
|
6362
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6363
|
+
|
|
6364
|
+
if (elemTag !== tag) {
|
|
6365
|
+
elem.setAttribute(tag, true);
|
|
6366
|
+
}
|
|
6367
|
+
}
|
|
6368
|
+
|
|
6369
|
+
/**
|
|
6370
|
+
* Validates if an element is a specific Auro component.
|
|
6371
|
+
* @param {Object} elem - The element to validate.
|
|
6372
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
6373
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
6374
|
+
*/
|
|
6375
|
+
elementMatch(elem, tagName) {
|
|
6376
|
+
const tag = tagName.toLowerCase();
|
|
6377
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6378
|
+
|
|
6379
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
6380
|
+
}
|
|
6381
|
+
};
|
|
6382
|
+
|
|
6202
6383
|
var styleCss$2 = 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}:host([fluid]) .auro-button,:host([fluid=true]) .auro-button{min-width:auto;width:100%}:host([variant=flat]){display:inline-block;height:var(--ds-size-300, 1.5rem);width:var(--ds-size-300, 1.5rem)}:host([variant=flat]) .auro-button{height:100%;width:100%}::slotted(svg){vertical-align:middle}slot{pointer-events:none}.auro-button{position:relative;padding:0 var(--ds-size-300, 1.5rem);cursor:pointer;border-width:1px;border-style:solid;border-radius:var(--ds-border-radius, 0.375rem);font-family:var(--ds-basic-text-body-default-font-family, AS Circular);font-size:var(--ds-basic-text-body-default-font-size, 16px);font-weight:var(--ds-basic-text-body-default-font-weight, Book);overflow:hidden;text-overflow:ellipsis;user-select:none;white-space:nowrap;min-height:var(--ds-size-600, 3rem);max-height:var(--ds-size-600, 3rem);display:inline-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}.auro-button:active{transform:scale(0.95)}.auro-button:focus-visible{outline:none}.auro-button:focus-visible:not([variant=flat]){outline-style:solid;outline-width:var(--ds-size-50, 0.25rem);outline-offset:calc(var(--ds-size-50, 0.25rem)*-1)}.auro-button:focus-visible:not([variant=flat]):not([variant=secondary]):not([variant=tertiary]){outline-width:calc(var(--ds-size-50, 0.25rem) - 1px)}.auro-button.loading{cursor:not-allowed}.auro-button.loading *:not([auro-loader]){visibility:hidden}@media screen and (min-width: 576px){.auro-button{min-width:8.75rem;width:auto}}.auro-button:disabled{cursor:not-allowed;transform:unset}.auro-button[variant=secondary]:disabled{cursor:not-allowed;transform:unset}.auro-button[variant=tertiary]:disabled{cursor:not-allowed;transform:unset}.auro-button[variant=flat]{height:unset;width:unset;min-height:unset;max-height:unset;min-width:unset;max-width:unset;border:0;border-radius:unset;gap:unset;padding:unset}.auro-button[onDark]:disabled{cursor:not-allowed;transform:unset}.auro-button[onDark][variant=secondary]:disabled{cursor:not-allowed;transform:unset}@media(hover: hover){.auro-button[onDark][variant=tertiary]:active,.auro-button[onDark][variant=tertiary]:hover{box-shadow:none}}.auro-button[onDark][variant=tertiary]:active{box-shadow:none}.auro-button[onDark][variant=tertiary]:disabled{cursor:not-allowed;transform:unset}.auro-button--slim{padding:var(--ds-size-100, 0.5rem) var(--ds-size-200, 1rem);font-size:var(--ds-basic-text-body-sm-font-size, 14px);min-width:unset;min-height:calc(var(--ds-size-500, 2.5rem) - var(--ds-size-50, 0.25rem));max-height:calc(var(--ds-size-500, 2.5rem) - var(--ds-size-50, 0.25rem))}.auro-button--iconOnly{padding:0 var(--ds-size-100, 0.5rem);border-radius:100px;min-width:unset;height:var(--ds-size-600, 3rem);width:var(--ds-size-500, 2.5rem)}.auro-button--iconOnly ::slotted(auro-icon),.auro-button--iconOnly ::slotted([auro-icon]){--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}.auro-button--iconOnly:not(.auro-button--rounded):focus-visible:not([variant=secondary]):not([variant=tertiary]):not([variant=flat]){outline-width:1px;outline-offset:-2px}.auro-button--iconOnlySlim{padding:0 var(--ds-size-50, 0.25rem);height:calc(var(--ds-size-400, 2rem) + var(--ds-size-50, 0.25rem));width:calc(var(--ds-size-300, 1.5rem) + var(--ds-size-50, 0.25rem))}.auro-button--iconOnlySlim ::slotted(auro-icon),.auro-button--iconOnlySlim ::slotted([auro-icon]){--ds-auro-icon-size:calc(var(--ds-size-200, 1rem) + var(--ds-size-50, 0.25rem))}.auro-button--rounded{border-radius:100px;box-shadow:var(--ds-elevation-300, 0px 0px 15px rgba(0, 0, 0, 0.2));height:var(--ds-size-500, 2.5rem);min-width:unset;transition:all 300ms ease-out,outline 0ms,outline-offset 0ms}.auro-button--rounded ::slotted(auro-icon),.auro-button--rounded ::slotted([auro-icon]){--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}.auro-button--rounded:focus-visible:not([variant=flat]):after{border-radius:100px}:host([rounded]) .textSlot{transition:opacity 300ms ease-in;opacity:1}:host([rounded][iconOnly]) .textSlot{opacity:0}:host([rounded][iconOnly]) .textWrapper{display:none}:host([rounded][iconOnly]) .auro-button{min-width:unset;padding:unset;width:var(--ds-size-600, 3rem)}[auro-loader]{position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);pointer-events:none}`;
|
|
6203
6384
|
|
|
6204
6385
|
var colorCss$2 = css`[auro-loader]{color:var(--ds-auro-button-loader-color)}.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-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-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=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[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-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-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-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=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}`;
|
|
6205
6386
|
|
|
6206
6387
|
var tokensCss$2 = css`:host{--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}`;
|
|
6207
6388
|
|
|
6389
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6390
|
+
// See LICENSE in the project root for license information.
|
|
6391
|
+
|
|
6392
|
+
// ---------------------------------------------------------------------
|
|
6393
|
+
|
|
6394
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
6395
|
+
|
|
6396
|
+
let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
6397
|
+
|
|
6398
|
+
/* eslint-disable jsdoc/require-param */
|
|
6399
|
+
|
|
6400
|
+
/**
|
|
6401
|
+
* This will register a new custom element with the browser.
|
|
6402
|
+
* @param {String} name - The name of the custom element.
|
|
6403
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
6404
|
+
* @returns {void}
|
|
6405
|
+
*/
|
|
6406
|
+
registerComponent(name, componentClass) {
|
|
6407
|
+
if (!customElements.get(name)) {
|
|
6408
|
+
customElements.define(name, class extends componentClass {});
|
|
6409
|
+
}
|
|
6410
|
+
}
|
|
6411
|
+
|
|
6412
|
+
/**
|
|
6413
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
6414
|
+
* @returns {void}
|
|
6415
|
+
*/
|
|
6416
|
+
closestElement(
|
|
6417
|
+
selector, // selector like in .closest()
|
|
6418
|
+
base = this, // extra functionality to skip a parent
|
|
6419
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
6420
|
+
!el || el === document || el === window
|
|
6421
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
6422
|
+
: found
|
|
6423
|
+
? found // found a selector INside this element
|
|
6424
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
6425
|
+
) {
|
|
6426
|
+
return __Closest(base);
|
|
6427
|
+
}
|
|
6428
|
+
/* eslint-enable jsdoc/require-param */
|
|
6429
|
+
|
|
6430
|
+
/**
|
|
6431
|
+
* 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.
|
|
6432
|
+
* @param {Object} elem - The element to check.
|
|
6433
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
6434
|
+
* @returns {void}
|
|
6435
|
+
*/
|
|
6436
|
+
handleComponentTagRename(elem, tagName) {
|
|
6437
|
+
const tag = tagName.toLowerCase();
|
|
6438
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6439
|
+
|
|
6440
|
+
if (elemTag !== tag) {
|
|
6441
|
+
elem.setAttribute(tag, true);
|
|
6442
|
+
}
|
|
6443
|
+
}
|
|
6444
|
+
|
|
6445
|
+
/**
|
|
6446
|
+
* Validates if an element is a specific Auro component.
|
|
6447
|
+
* @param {Object} elem - The element to validate.
|
|
6448
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
6449
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
6450
|
+
*/
|
|
6451
|
+
elementMatch(elem, tagName) {
|
|
6452
|
+
const tag = tagName.toLowerCase();
|
|
6453
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6454
|
+
|
|
6455
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
6456
|
+
}
|
|
6457
|
+
};
|
|
6458
|
+
|
|
6208
6459
|
var styleCss$1 = css`: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;font-size:1rem}:host>span{opacity:1}:host>.loader{display:none}:host>.no-animation{display:block}}`;
|
|
6209
6460
|
|
|
6210
6461
|
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}`;
|
|
@@ -6531,7 +6782,7 @@ class AuroButton extends LitElement {
|
|
|
6531
6782
|
*
|
|
6532
6783
|
*/
|
|
6533
6784
|
static register(name = "auro-button") {
|
|
6534
|
-
AuroLibraryRuntimeUtils$
|
|
6785
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroButton);
|
|
6535
6786
|
}
|
|
6536
6787
|
|
|
6537
6788
|
/**
|
|
@@ -6861,7 +7112,7 @@ class AuroInput extends BaseInput {
|
|
|
6861
7112
|
/**
|
|
6862
7113
|
* Generate unique names for dependency components.
|
|
6863
7114
|
*/
|
|
6864
|
-
const versioning = new AuroDependencyVersioning();
|
|
7115
|
+
const versioning = new AuroDependencyVersioning$1();
|
|
6865
7116
|
|
|
6866
7117
|
/**
|
|
6867
7118
|
* @private
|
|
@@ -6888,7 +7139,7 @@ class AuroInput extends BaseInput {
|
|
|
6888
7139
|
*
|
|
6889
7140
|
*/
|
|
6890
7141
|
static register(name = "auro-input") {
|
|
6891
|
-
AuroLibraryRuntimeUtils$
|
|
7142
|
+
AuroLibraryRuntimeUtils$4.prototype.registerComponent(name, AuroInput);
|
|
6892
7143
|
}
|
|
6893
7144
|
|
|
6894
7145
|
/**
|
|
@@ -77,7 +77,7 @@ var tokensCss$1 = i$5`:host{--ds-auro-menu-divider-color: var(--ds-basic-color-b
|
|
|
77
77
|
|
|
78
78
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
79
79
|
|
|
80
|
-
class AuroLibraryRuntimeUtils {
|
|
80
|
+
let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
81
81
|
|
|
82
82
|
/* eslint-disable jsdoc/require-param */
|
|
83
83
|
|
|
@@ -138,7 +138,7 @@ class AuroLibraryRuntimeUtils {
|
|
|
138
138
|
|
|
139
139
|
return elemTag === tag || elem.hasAttribute(tag);
|
|
140
140
|
}
|
|
141
|
-
}
|
|
141
|
+
};
|
|
142
142
|
|
|
143
143
|
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
144
144
|
// See LICENSE in the project root for license information.
|
|
@@ -324,7 +324,7 @@ class AuroMenu extends i$2 {
|
|
|
324
324
|
*
|
|
325
325
|
*/
|
|
326
326
|
static register(name = "auro-menu") {
|
|
327
|
-
AuroLibraryRuntimeUtils.prototype.registerComponent(name, AuroMenu);
|
|
327
|
+
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroMenu);
|
|
328
328
|
}
|
|
329
329
|
|
|
330
330
|
// Lifecycle Methods
|
|
@@ -348,7 +348,7 @@ class AuroMenu extends i$2 {
|
|
|
348
348
|
}
|
|
349
349
|
|
|
350
350
|
firstUpdated() {
|
|
351
|
-
AuroLibraryRuntimeUtils.prototype.handleComponentTagRename(this, 'auro-menu');
|
|
351
|
+
AuroLibraryRuntimeUtils$1.prototype.handleComponentTagRename(this, 'auro-menu');
|
|
352
352
|
|
|
353
353
|
this.loadingSlots = this.querySelectorAll("[slot='loadingText'], [slot='loadingIcon']");
|
|
354
354
|
this.initializeMenu();
|
|
@@ -1123,6 +1123,76 @@ var tokensCss = i$5`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-def
|
|
|
1123
1123
|
|
|
1124
1124
|
var colorCss = i$5`: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)}`;
|
|
1125
1125
|
|
|
1126
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
1127
|
+
// See LICENSE in the project root for license information.
|
|
1128
|
+
|
|
1129
|
+
// ---------------------------------------------------------------------
|
|
1130
|
+
|
|
1131
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
1132
|
+
|
|
1133
|
+
class AuroLibraryRuntimeUtils {
|
|
1134
|
+
|
|
1135
|
+
/* eslint-disable jsdoc/require-param */
|
|
1136
|
+
|
|
1137
|
+
/**
|
|
1138
|
+
* This will register a new custom element with the browser.
|
|
1139
|
+
* @param {String} name - The name of the custom element.
|
|
1140
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
1141
|
+
* @returns {void}
|
|
1142
|
+
*/
|
|
1143
|
+
registerComponent(name, componentClass) {
|
|
1144
|
+
if (!customElements.get(name)) {
|
|
1145
|
+
customElements.define(name, class extends componentClass {});
|
|
1146
|
+
}
|
|
1147
|
+
}
|
|
1148
|
+
|
|
1149
|
+
/**
|
|
1150
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
1151
|
+
* @returns {void}
|
|
1152
|
+
*/
|
|
1153
|
+
closestElement(
|
|
1154
|
+
selector, // selector like in .closest()
|
|
1155
|
+
base = this, // extra functionality to skip a parent
|
|
1156
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
1157
|
+
!el || el === document || el === window
|
|
1158
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
1159
|
+
: found
|
|
1160
|
+
? found // found a selector INside this element
|
|
1161
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
1162
|
+
) {
|
|
1163
|
+
return __Closest(base);
|
|
1164
|
+
}
|
|
1165
|
+
/* eslint-enable jsdoc/require-param */
|
|
1166
|
+
|
|
1167
|
+
/**
|
|
1168
|
+
* 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.
|
|
1169
|
+
* @param {Object} elem - The element to check.
|
|
1170
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
1171
|
+
* @returns {void}
|
|
1172
|
+
*/
|
|
1173
|
+
handleComponentTagRename(elem, tagName) {
|
|
1174
|
+
const tag = tagName.toLowerCase();
|
|
1175
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
1176
|
+
|
|
1177
|
+
if (elemTag !== tag) {
|
|
1178
|
+
elem.setAttribute(tag, true);
|
|
1179
|
+
}
|
|
1180
|
+
}
|
|
1181
|
+
|
|
1182
|
+
/**
|
|
1183
|
+
* Validates if an element is a specific Auro component.
|
|
1184
|
+
* @param {Object} elem - The element to validate.
|
|
1185
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
1186
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
1187
|
+
*/
|
|
1188
|
+
elementMatch(elem, tagName) {
|
|
1189
|
+
const tag = tagName.toLowerCase();
|
|
1190
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
1191
|
+
|
|
1192
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
1193
|
+
}
|
|
1194
|
+
}
|
|
1195
|
+
|
|
1126
1196
|
// Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
1127
1197
|
// See LICENSE in the project root for license information.
|
|
1128
1198
|
|
|
@@ -1330,7 +1400,7 @@ class AuroMenuOption extends i$2 {
|
|
|
1330
1400
|
/**
|
|
1331
1401
|
* @private
|
|
1332
1402
|
*/
|
|
1333
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils();
|
|
1403
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$1();
|
|
1334
1404
|
}
|
|
1335
1405
|
|
|
1336
1406
|
static get properties() {
|
|
@@ -1374,7 +1444,7 @@ class AuroMenuOption extends i$2 {
|
|
|
1374
1444
|
*
|
|
1375
1445
|
*/
|
|
1376
1446
|
static register(name = "auro-menuoption") {
|
|
1377
|
-
AuroLibraryRuntimeUtils.prototype.registerComponent(name, AuroMenuOption);
|
|
1447
|
+
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroMenuOption);
|
|
1378
1448
|
}
|
|
1379
1449
|
|
|
1380
1450
|
firstUpdated() {
|
|
@@ -37,7 +37,7 @@ var tokensCss$1 = i$5`:host{--ds-auro-menu-divider-color: var(--ds-basic-color-b
|
|
|
37
37
|
|
|
38
38
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
39
39
|
|
|
40
|
-
class AuroLibraryRuntimeUtils {
|
|
40
|
+
let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
41
41
|
|
|
42
42
|
/* eslint-disable jsdoc/require-param */
|
|
43
43
|
|
|
@@ -98,7 +98,7 @@ class AuroLibraryRuntimeUtils {
|
|
|
98
98
|
|
|
99
99
|
return elemTag === tag || elem.hasAttribute(tag);
|
|
100
100
|
}
|
|
101
|
-
}
|
|
101
|
+
};
|
|
102
102
|
|
|
103
103
|
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
104
104
|
// See LICENSE in the project root for license information.
|
|
@@ -284,7 +284,7 @@ class AuroMenu extends i$2 {
|
|
|
284
284
|
*
|
|
285
285
|
*/
|
|
286
286
|
static register(name = "auro-menu") {
|
|
287
|
-
AuroLibraryRuntimeUtils.prototype.registerComponent(name, AuroMenu);
|
|
287
|
+
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroMenu);
|
|
288
288
|
}
|
|
289
289
|
|
|
290
290
|
// Lifecycle Methods
|
|
@@ -308,7 +308,7 @@ class AuroMenu extends i$2 {
|
|
|
308
308
|
}
|
|
309
309
|
|
|
310
310
|
firstUpdated() {
|
|
311
|
-
AuroLibraryRuntimeUtils.prototype.handleComponentTagRename(this, 'auro-menu');
|
|
311
|
+
AuroLibraryRuntimeUtils$1.prototype.handleComponentTagRename(this, 'auro-menu');
|
|
312
312
|
|
|
313
313
|
this.loadingSlots = this.querySelectorAll("[slot='loadingText'], [slot='loadingIcon']");
|
|
314
314
|
this.initializeMenu();
|
|
@@ -1083,6 +1083,76 @@ var tokensCss = i$5`:host{--ds-auro-icon-color:var(--ds-basic-color-texticon-def
|
|
|
1083
1083
|
|
|
1084
1084
|
var colorCss = i$5`: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)}`;
|
|
1085
1085
|
|
|
1086
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
1087
|
+
// See LICENSE in the project root for license information.
|
|
1088
|
+
|
|
1089
|
+
// ---------------------------------------------------------------------
|
|
1090
|
+
|
|
1091
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
1092
|
+
|
|
1093
|
+
class AuroLibraryRuntimeUtils {
|
|
1094
|
+
|
|
1095
|
+
/* eslint-disable jsdoc/require-param */
|
|
1096
|
+
|
|
1097
|
+
/**
|
|
1098
|
+
* This will register a new custom element with the browser.
|
|
1099
|
+
* @param {String} name - The name of the custom element.
|
|
1100
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
1101
|
+
* @returns {void}
|
|
1102
|
+
*/
|
|
1103
|
+
registerComponent(name, componentClass) {
|
|
1104
|
+
if (!customElements.get(name)) {
|
|
1105
|
+
customElements.define(name, class extends componentClass {});
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
|
|
1109
|
+
/**
|
|
1110
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
1111
|
+
* @returns {void}
|
|
1112
|
+
*/
|
|
1113
|
+
closestElement(
|
|
1114
|
+
selector, // selector like in .closest()
|
|
1115
|
+
base = this, // extra functionality to skip a parent
|
|
1116
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
1117
|
+
!el || el === document || el === window
|
|
1118
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
1119
|
+
: found
|
|
1120
|
+
? found // found a selector INside this element
|
|
1121
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
1122
|
+
) {
|
|
1123
|
+
return __Closest(base);
|
|
1124
|
+
}
|
|
1125
|
+
/* eslint-enable jsdoc/require-param */
|
|
1126
|
+
|
|
1127
|
+
/**
|
|
1128
|
+
* 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.
|
|
1129
|
+
* @param {Object} elem - The element to check.
|
|
1130
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
1131
|
+
* @returns {void}
|
|
1132
|
+
*/
|
|
1133
|
+
handleComponentTagRename(elem, tagName) {
|
|
1134
|
+
const tag = tagName.toLowerCase();
|
|
1135
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
1136
|
+
|
|
1137
|
+
if (elemTag !== tag) {
|
|
1138
|
+
elem.setAttribute(tag, true);
|
|
1139
|
+
}
|
|
1140
|
+
}
|
|
1141
|
+
|
|
1142
|
+
/**
|
|
1143
|
+
* Validates if an element is a specific Auro component.
|
|
1144
|
+
* @param {Object} elem - The element to validate.
|
|
1145
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
1146
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
1147
|
+
*/
|
|
1148
|
+
elementMatch(elem, tagName) {
|
|
1149
|
+
const tag = tagName.toLowerCase();
|
|
1150
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
1151
|
+
|
|
1152
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
1153
|
+
}
|
|
1154
|
+
}
|
|
1155
|
+
|
|
1086
1156
|
// Copyright (c) 2025 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
1087
1157
|
// See LICENSE in the project root for license information.
|
|
1088
1158
|
|
|
@@ -1290,7 +1360,7 @@ class AuroMenuOption extends i$2 {
|
|
|
1290
1360
|
/**
|
|
1291
1361
|
* @private
|
|
1292
1362
|
*/
|
|
1293
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils();
|
|
1363
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$1();
|
|
1294
1364
|
}
|
|
1295
1365
|
|
|
1296
1366
|
static get properties() {
|
|
@@ -1334,7 +1404,7 @@ class AuroMenuOption extends i$2 {
|
|
|
1334
1404
|
*
|
|
1335
1405
|
*/
|
|
1336
1406
|
static register(name = "auro-menuoption") {
|
|
1337
|
-
AuroLibraryRuntimeUtils.prototype.registerComponent(name, AuroMenuOption);
|
|
1407
|
+
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroMenuOption);
|
|
1338
1408
|
}
|
|
1339
1409
|
|
|
1340
1410
|
firstUpdated() {
|