@aurodesignsystem/auro-formkit 2.0.2 → 2.1.0-beta.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 +19 -0
- package/components/bibtemplate/dist/iconVersion.d.ts +1 -1
- package/components/bibtemplate/dist/index.js +281 -135
- package/components/bibtemplate/dist/registered.js +281 -135
- package/components/checkbox/README.md +1 -1
- package/components/checkbox/demo/api.min.js +30 -56
- package/components/checkbox/demo/index.min.js +30 -56
- package/components/checkbox/demo/readme.md +1 -1
- package/components/checkbox/dist/index.js +28 -101
- package/components/checkbox/dist/registered.js +28 -101
- package/components/combobox/README.md +1 -1
- package/components/combobox/demo/api.min.js +1289 -734
- package/components/combobox/demo/index.min.js +1289 -734
- package/components/combobox/demo/readme.md +1 -1
- package/components/combobox/dist/index.js +1024 -632
- package/components/combobox/dist/registered.js +1024 -632
- package/components/counter/README.md +1 -1
- package/components/counter/demo/api.min.js +971 -435
- package/components/counter/demo/index.js +1 -0
- package/components/counter/demo/index.min.js +972 -435
- package/components/counter/demo/readme.md +1 -1
- package/components/counter/dist/iconVersion.d.ts +1 -1
- package/components/counter/dist/index.js +972 -483
- package/components/counter/dist/registered.js +972 -483
- package/components/datepicker/README.md +1 -1
- package/components/datepicker/demo/api.md +30 -0
- package/components/datepicker/demo/api.min.js +1818 -735
- package/components/datepicker/demo/index.min.js +1818 -735
- package/components/datepicker/demo/readme.md +1 -1
- package/components/datepicker/dist/auro-calendar.d.ts +5 -1
- package/components/datepicker/dist/auro-datepicker.d.ts +7 -0
- package/components/datepicker/dist/buttonVersion.d.ts +2 -0
- package/components/datepicker/dist/index.js +1830 -817
- package/components/datepicker/dist/popoverVersion.d.ts +1 -1
- package/components/datepicker/dist/registered.js +1830 -817
- package/components/dropdown/README.md +1 -1
- package/components/dropdown/demo/api.min.js +231 -117
- package/components/dropdown/demo/index.min.js +231 -117
- package/components/dropdown/demo/readme.md +1 -1
- package/components/dropdown/dist/index.js +232 -165
- package/components/dropdown/dist/registered.js +232 -165
- package/components/form/README.md +1 -1
- package/components/form/demo/readme.md +1 -1
- package/components/form/dist/index.js +4 -28
- package/components/form/dist/registered.js +4 -28
- package/components/helptext/dist/index.js +6 -30
- package/components/helptext/dist/registered.js +6 -30
- package/components/input/README.md +1 -1
- package/components/input/demo/api.min.js +471 -164
- package/components/input/demo/index.min.js +471 -164
- package/components/input/demo/readme.md +1 -1
- package/components/input/dist/index.js +468 -220
- package/components/input/dist/registered.js +468 -220
- package/components/menu/README.md +1 -1
- package/components/menu/demo/api.min.js +183 -60
- package/components/menu/demo/index.min.js +183 -60
- package/components/menu/demo/readme.md +1 -1
- package/components/menu/dist/iconVersion.d.ts +1 -1
- package/components/menu/dist/index.js +205 -129
- package/components/menu/dist/registered.js +205 -129
- package/components/radio/README.md +1 -1
- package/components/radio/demo/api.min.js +30 -56
- package/components/radio/demo/index.min.js +30 -56
- package/components/radio/demo/readme.md +1 -1
- package/components/radio/dist/index.js +28 -101
- package/components/radio/dist/registered.js +28 -101
- package/components/select/README.md +1 -1
- package/components/select/demo/api.min.js +736 -436
- package/components/select/demo/index.min.js +736 -436
- package/components/select/demo/readme.md +1 -1
- package/components/select/dist/index.js +538 -402
- package/components/select/dist/registered.js +538 -402
- package/package.json +4 -2
|
@@ -20,46 +20,46 @@ const changeLang = () => {
|
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
21
21
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
22
22
|
*/
|
|
23
|
-
const t$
|
|
23
|
+
const t$3=globalThis,i$5=t$3.trustedTypes,s$3=i$5?i$5.createPolicy("lit-html",{createHTML:t=>t}):void 0,e$4="$lit$",h$1=`lit$${Math.random().toFixed(9).slice(2)}$`,o$4="?"+h$1,n$3=`<${o$4}>`,r$4=document,l$2=()=>r$4.createComment(""),c$3=t=>null===t||"object"!=typeof t&&"function"!=typeof t,a$2=Array.isArray,u$4=t=>a$2(t)||"function"==typeof t?.[Symbol.iterator],d$1="[ \t\n\f\r]",f$1=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,v$1=/-->/g,_=/>/g,m$1=RegExp(`>|${d$1}(?:([^\\s"'>=/]+)(${d$1}*=${d$1}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),p$2=/'/g,g=/"/g,$=/^(?:script|style|textarea|title)$/i,y$1=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),x=y$1(1),T=Symbol.for("lit-noChange"),E=Symbol.for("lit-nothing"),A=new WeakMap,C=r$4.createTreeWalker(r$4,129);function P(t,i){if(!a$2(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==s$3?s$3.createHTML(i):i}const V=(t,i)=>{const s=t.length-1,o=[];let r,l=2===i?"<svg>":3===i?"<math>":"",c=f$1;for(let i=0;i<s;i++){const s=t[i];let a,u,d=-1,y=0;for(;y<s.length&&(c.lastIndex=y,u=c.exec(s),null!==u);)y=c.lastIndex,c===f$1?"!--"===u[1]?c=v$1:void 0!==u[1]?c=_:void 0!==u[2]?($.test(u[2])&&(r=RegExp("</"+u[2],"g")),c=m$1):void 0!==u[3]&&(c=m$1):c===m$1?">"===u[0]?(c=r??f$1,d=-1):void 0===u[1]?d=-2:(d=c.lastIndex-u[2].length,a=u[1],c=void 0===u[3]?m$1:'"'===u[3]?g:p$2):c===g||c===p$2?c=m$1:c===v$1||c===_?c=f$1:(c=m$1,r=void 0);const x=c===m$1&&t[i+1].startsWith("/>")?" ":"";l+=c===f$1?s+n$3:d>=0?(o.push(a),s.slice(0,d)+e$4+s.slice(d)+h$1+x):s+h$1+(-2===d?i:x);}return [P(t,l+(t[s]||"<?>")+(2===i?"</svg>":3===i?"</math>":"")),o]};class N{constructor({strings:t,_$litType$:s},n){let r;this.parts=[];let c=0,a=0;const u=t.length-1,d=this.parts,[f,v]=V(t,s);if(this.el=N.createElement(f,n),C.currentNode=this.el.content,2===s||3===s){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes);}for(;null!==(r=C.nextNode())&&d.length<u;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(e$4)){const i=v[a++],s=r.getAttribute(t).split(h$1),e=/([.?@])?(.*)/.exec(i);d.push({type:1,index:c,name:e[2],strings:s,ctor:"."===e[1]?H:"?"===e[1]?I:"@"===e[1]?L:k}),r.removeAttribute(t);}else t.startsWith(h$1)&&(d.push({type:6,index:c}),r.removeAttribute(t));if($.test(r.tagName)){const t=r.textContent.split(h$1),s=t.length-1;if(s>0){r.textContent=i$5?i$5.emptyScript:"";for(let i=0;i<s;i++)r.append(t[i],l$2()),C.nextNode(),d.push({type:2,index:++c});r.append(t[s],l$2());}}}else if(8===r.nodeType)if(r.data===o$4)d.push({type:2,index:c});else {let t=-1;for(;-1!==(t=r.data.indexOf(h$1,t+1));)d.push({type:7,index:c}),t+=h$1.length-1;}c++;}}static createElement(t,i){const s=r$4.createElement("template");return s.innerHTML=t,s}}function S$1(t,i,s=t,e){if(i===T)return i;let h=void 0!==e?s._$Co?.[e]:s._$Cl;const o=c$3(i)?void 0:i._$litDirective$;return h?.constructor!==o&&(h?._$AO?.(false),void 0===o?h=void 0:(h=new o(t),h._$AT(t,s,e)),void 0!==e?(s._$Co??=[])[e]=h:s._$Cl=h),void 0!==h&&(i=S$1(t,h._$AS(t,i.values),h,e)),i}let M$1 = class M{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i;}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:i},parts:s}=this._$AD,e=(t?.creationScope??r$4).importNode(i,true);C.currentNode=e;let h=C.nextNode(),o=0,n=0,l=s[0];for(;void 0!==l;){if(o===l.index){let i;2===l.type?i=new R(h,h.nextSibling,this,t):1===l.type?i=new l.ctor(h,l.name,l.strings,this,t):6===l.type&&(i=new z(h,this,t)),this._$AV.push(i),l=s[++n];}o!==l?.index&&(h=C.nextNode(),o++);}return C.currentNode=r$4,e}p(t){let i=0;for(const s of this._$AV) void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++;}};class R{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,i,s,e){this.type=2,this._$AH=E,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cv=e?.isConnected??true;}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t?.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=S$1(this,t,i),c$3(t)?t===E||null==t||""===t?(this._$AH!==E&&this._$AR(),this._$AH=E):t!==this._$AH&&t!==T&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):u$4(t)?this.k(t):this._(t);}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t));}_(t){this._$AH!==E&&c$3(this._$AH)?this._$AA.nextSibling.data=t:this.T(r$4.createTextNode(t)),this._$AH=t;}$(t){const{values:i,_$litType$:s}=t,e="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=N.createElement(P(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===e)this._$AH.p(i);else {const t=new M$1(e,this),s=t.u(this.options);t.p(i),this.T(s),this._$AH=t;}}_$AC(t){let i=A.get(t.strings);return void 0===i&&A.set(t.strings,i=new N(t)),i}k(t){a$2(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const h of t)e===i.length?i.push(s=new R(this.O(l$2()),this.O(l$2()),this,this.options)):s=i[e],s._$AI(h),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e);}_$AR(t=this._$AA.nextSibling,i){for(this._$AP?.(false,true,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i;}}setConnected(t){ void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t));}}class k{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,i,s,e,h){this.type=1,this._$AH=E,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=h,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=E;}_$AI(t,i=this,s,e){const h=this.strings;let o=false;if(void 0===h)t=S$1(this,t,i,0),o=!c$3(t)||t!==this._$AH&&t!==T,o&&(this._$AH=t);else {const e=t;let n,r;for(t=h[0],n=0;n<h.length-1;n++)r=S$1(this,e[s+n],i,n),r===T&&(r=this._$AH[n]),o||=!c$3(r)||r!==this._$AH[n],r===E?t=E:t!==E&&(t+=(r??"")+h[n+1]),this._$AH[n]=r;}o&&!e&&this.j(t);}j(t){t===E?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"");}}class H extends k{constructor(){super(...arguments),this.type=3;}j(t){this.element[this.name]=t===E?void 0:t;}}class I extends k{constructor(){super(...arguments),this.type=4;}j(t){this.element.toggleAttribute(this.name,!!t&&t!==E);}}class L extends k{constructor(t,i,s,e,h){super(t,i,s,e,h),this.type=5;}_$AI(t,i=this){if((t=S$1(this,t,i,0)??E)===T)return;const s=this._$AH,e=t===E&&s!==E||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,h=t!==E&&(s===E||e);e&&this.element.removeEventListener(this.name,this,s),h&&this.element.addEventListener(this.name,this,t),this._$AH=t;}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t);}}class z{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s;}get _$AU(){return this._$AM._$AU}_$AI(t){S$1(this,t);}}const Z={I:R},j=t$3.litHtmlPolyfillSupport;j?.(N,R),(t$3.litHtmlVersions??=[]).push("3.2.1");const B=(t,i,s)=>{const e=s?.renderBefore??i;let h=e._$litPart$;if(void 0===h){const t=s?.renderBefore??null;e._$litPart$=h=new R(i.insertBefore(l$2(),t),t,void 0,s??{});}return h._$AI(t),h};
|
|
24
24
|
|
|
25
25
|
/**
|
|
26
26
|
* @license
|
|
27
27
|
* Copyright 2020 Google LLC
|
|
28
28
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
29
29
|
*/
|
|
30
|
-
const a$
|
|
30
|
+
const a$1=Symbol.for(""),o$3=t=>{if(t?.r===a$1)return t?._$litStatic$},s$2=t=>({_$litStatic$:t,r:a$1}),i$4=(t,...r)=>({_$litStatic$:r.reduce(((r,e,a)=>r+(t=>{if(void 0!==t._$litStatic$)return t._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${t}. Use 'unsafeStatic' to pass non-literal values, but\n take care to ensure page security.`)})(e)+t[a+1]),t[0]),r:a$1}),l$1=new Map,n$2=t=>(r,...e)=>{const a=e.length;let s,i;const n=[],u=[];let c,$=0,f=false;for(;$<a;){for(c=r[$];$<a&&void 0!==(i=e[$],s=o$3(i));)c+=s+r[++$],f=true;$!==a&&u.push(i),n.push(c),$++;}if($===a&&n.push(r[a]),f){const t=n.join("$$lit$$");void 0===(r=l$1.get(t))&&(n.raw=n,l$1.set(t,r=n)),e=u;}return t(r,...e)},u$3=n$2(x);
|
|
31
31
|
|
|
32
32
|
/**
|
|
33
33
|
* @license
|
|
34
34
|
* Copyright 2017 Google LLC
|
|
35
35
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
36
36
|
*/
|
|
37
|
-
const t$
|
|
37
|
+
const t$2={ATTRIBUTE:1,CHILD:2},e$3=t=>(...e)=>({_$litDirective$:t,values:e});let i$3 = class i{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,i){this._$Ct=t,this._$AM=e,this._$Ci=i;}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};
|
|
38
38
|
|
|
39
39
|
/**
|
|
40
40
|
* @license
|
|
41
41
|
* Copyright 2020 Google LLC
|
|
42
42
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
43
|
-
*/const {I:t$
|
|
43
|
+
*/const {I:t$1}=Z,s$1=()=>document.createComment(""),r$3=(o,i,n)=>{const e=o._$AA.parentNode,l=void 0===i?o._$AB:i._$AA;if(void 0===n){const i=e.insertBefore(s$1(),l),c=e.insertBefore(s$1(),l);n=new t$1(i,c,o,o.options);}else {const t=n._$AB.nextSibling,i=n._$AM,c=i!==o;if(c){let t;n._$AQ?.(o),n._$AM=o,void 0!==n._$AP&&(t=o._$AU)!==i._$AU&&n._$AP(t);}if(t!==l||c){let o=n._$AA;for(;o!==t;){const t=o.nextSibling;e.insertBefore(o,l),o=t;}}}return n},v=(o,t,i=o)=>(o._$AI(t,i),o),u$2={},m=(o,t=u$2)=>o._$AH=t,p$1=o=>o._$AH,M=o=>{o._$AP?.(false,true);let t=o._$AA;const i=o._$AB.nextSibling;for(;t!==i;){const o=t.nextSibling;t.remove(),t=o;}};
|
|
44
44
|
|
|
45
45
|
/**
|
|
46
46
|
* @license
|
|
47
47
|
* Copyright 2017 Google LLC
|
|
48
48
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
49
49
|
*/
|
|
50
|
-
const u$
|
|
50
|
+
const u$1=(e,s,t)=>{const r=new Map;for(let l=s;l<=t;l++)r.set(e[l],l);return r},c$2=e$3(class extends i$3{constructor(e){if(super(e),e.type!==t$2.CHILD)throw Error("repeat() can only be used in text expressions")}dt(e,s,t){let r;void 0===t?t=s:void 0!==s&&(r=s);const l=[],o=[];let i=0;for(const s of e)l[i]=r?r(s,i):i,o[i]=t(s,i),i++;return {values:o,keys:l}}render(e,s,t){return this.dt(e,s,t).values}update(s,[t,r,c]){const d=p$1(s),{values:p,keys:a}=this.dt(t,r,c);if(!Array.isArray(d))return this.ut=a,p;const h=this.ut??=[],v$1=[];let m$1,y,x=0,j=d.length-1,k=0,w=p.length-1;for(;x<=j&&k<=w;)if(null===d[x])x++;else if(null===d[j])j--;else if(h[x]===a[k])v$1[k]=v(d[x],p[k]),x++,k++;else if(h[j]===a[w])v$1[w]=v(d[j],p[w]),j--,w--;else if(h[x]===a[w])v$1[w]=v(d[x],p[w]),r$3(s,v$1[w+1],d[x]),x++,w--;else if(h[j]===a[k])v$1[k]=v(d[j],p[k]),r$3(s,d[x],d[j]),j--,k++;else if(void 0===m$1&&(m$1=u$1(a,k,w),y=u$1(h,x,j)),m$1.has(h[x]))if(m$1.has(h[j])){const e=y.get(a[k]),t=void 0!==e?d[e]:null;if(null===t){const e=r$3(s,d[x]);v(e,p[k]),v$1[k]=e;}else v$1[k]=v(t,p[k]),r$3(s,d[x],t),d[e]=null;k++;}else M(d[j]),j--;else M(d[x]),x++;for(;k<=w;){const e=r$3(s,v$1[w+1]);v(e,p[k]),v$1[k++]=e;}for(;x<=j;){const e=d[x++];null!==e&&M(e);}return this.ut=a,m(s,v$1),T}});
|
|
51
51
|
|
|
52
52
|
/**
|
|
53
53
|
* @license
|
|
54
54
|
* Copyright 2018 Google LLC
|
|
55
55
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
56
|
-
*/const e$
|
|
56
|
+
*/const e$2=e$3(class extends i$3{constructor(t){if(super(t),t.type!==t$2.ATTRIBUTE||"class"!==t.name||t.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return " "+Object.keys(t).filter((s=>t[s])).join(" ")+" "}update(s,[i]){if(void 0===this.st){this.st=new Set,void 0!==s.strings&&(this.nt=new Set(s.strings.join(" ").split(/\s/).filter((t=>""!==t))));for(const t in i)i[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(i)}const r=s.element.classList;for(const t of this.st)t in i||(r.remove(t),this.st.delete(t));for(const t in i){const s=!!i[t];s===this.st.has(t)||this.nt?.has(t)||(s?(r.add(t),this.st.add(t)):(r.remove(t),this.st.delete(t)));}return T}});
|
|
57
57
|
|
|
58
58
|
/**
|
|
59
59
|
* @license
|
|
60
60
|
* Copyright 2018 Google LLC
|
|
61
61
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
62
|
-
*/const o$
|
|
62
|
+
*/const o$2=o=>o??E;
|
|
63
63
|
|
|
64
64
|
const watchedItems = new Set();
|
|
65
65
|
|
|
@@ -187,25 +187,25 @@ function stopNotifyingOnLangChange(element) {
|
|
|
187
187
|
* Copyright 2019 Google LLC
|
|
188
188
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
189
189
|
*/
|
|
190
|
-
const t
|
|
190
|
+
const t=globalThis,e$1=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s=Symbol(),o$1=new WeakMap;let n$1 = class n{constructor(t,e,o){if(this._$cssResult$=true,o!==s)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e;}get styleSheet(){let t=this.o;const s=this.t;if(e$1&&void 0===t){const e=void 0!==s&&1===s.length;e&&(t=o$1.get(s)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&o$1.set(s,t));}return t}toString(){return this.cssText}};const r$2=t=>new n$1("string"==typeof t?t:t+"",void 0,s),i$2=(t,...e)=>{const o=1===t.length?t[0]:e.reduce(((e,s,o)=>e+(t=>{if(true===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+t[o+1]),t[0]);return new n$1(o,t,s)},S=(s,o)=>{if(e$1)s.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const e of o){const o=document.createElement("style"),n=t.litNonce;void 0!==n&&o.setAttribute("nonce",n),o.textContent=e.cssText,s.appendChild(o);}},c$1=e$1?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return r$2(e)})(t):t;
|
|
191
191
|
|
|
192
192
|
/**
|
|
193
193
|
* @license
|
|
194
194
|
* Copyright 2017 Google LLC
|
|
195
195
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
196
|
-
*/const{is:i$
|
|
196
|
+
*/const{is:i$1,defineProperty:e,getOwnPropertyDescriptor:r$1,getOwnPropertyNames:h,getOwnPropertySymbols:o,getPrototypeOf:n}=Object,a=globalThis,c=a.trustedTypes,l=c?c.emptyScript:"",p=a.reactiveElementPolyfillSupport,d=(t,s)=>t,u={toAttribute(t,s){switch(s){case Boolean:t=t?l:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t);}return t},fromAttribute(t,s){let i=t;switch(s){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t);}catch(t){i=null;}}return i}},f=(t,s)=>!i$1(t,s),y={attribute:true,type:String,converter:u,reflect:false,hasChanged:f};Symbol.metadata??=Symbol("metadata"),a.litPropertyMetadata??=new WeakMap;class b extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t);}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,s=y){if(s.state&&(s.attribute=false),this._$Ei(),this.elementProperties.set(t,s),!s.noAccessor){const i=Symbol(),r=this.getPropertyDescriptor(t,i,s);void 0!==r&&e(this.prototype,t,r);}}static getPropertyDescriptor(t,s,i){const{get:e,set:h}=r$1(this.prototype,t)??{get(){return this[s]},set(t){this[s]=t;}};return {get(){return e?.call(this)},set(s){const r=e?.call(this);h.call(this,s),this.requestUpdate(t,r,i);},configurable:true,enumerable:true}}static getPropertyOptions(t){return this.elementProperties.get(t)??y}static _$Ei(){if(this.hasOwnProperty(d("elementProperties")))return;const t=n(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties);}static finalize(){if(this.hasOwnProperty(d("finalized")))return;if(this.finalized=true,this._$Ei(),this.hasOwnProperty(d("properties"))){const t=this.properties,s=[...h(t),...o(t)];for(const i of s)this.createProperty(i,t[i]);}const t=this[Symbol.metadata];if(null!==t){const s=litPropertyMetadata.get(t);if(void 0!==s)for(const[t,i]of s)this.elementProperties.set(t,i);}this._$Eh=new Map;for(const[t,s]of this.elementProperties){const i=this._$Eu(t,s);void 0!==i&&this._$Eh.set(i,t);}this.elementStyles=this.finalizeStyles(this.styles);}static finalizeStyles(s){const i=[];if(Array.isArray(s)){const e=new Set(s.flat(1/0).reverse());for(const s of e)i.unshift(c$1(s));}else void 0!==s&&i.push(c$1(s));return i}static _$Eu(t,s){const i=s.attribute;return false===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=false,this.hasUpdated=false,this._$Em=null,this._$Ev();}_$Ev(){this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)));}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.();}removeController(t){this._$EO?.delete(t);}_$E_(){const t=new Map,s=this.constructor.elementProperties;for(const i of s.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t);}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return S(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(true),this._$EO?.forEach((t=>t.hostConnected?.()));}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach((t=>t.hostDisconnected?.()));}attributeChangedCallback(t,s,i){this._$AK(t,i);}_$EC(t,s){const i=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,i);if(void 0!==e&&true===i.reflect){const r=(void 0!==i.converter?.toAttribute?i.converter:u).toAttribute(s,i.type);this._$Em=t,null==r?this.removeAttribute(e):this.setAttribute(e,r),this._$Em=null;}}_$AK(t,s){const i=this.constructor,e=i._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=i.getPropertyOptions(e),r="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:u;this._$Em=e,this[e]=r.fromAttribute(s,t.type),this._$Em=null;}}requestUpdate(t,s,i){if(void 0!==t){if(i??=this.constructor.getPropertyOptions(t),!(i.hasChanged??f)(this[t],s))return;this.P(t,s,i);} false===this.isUpdatePending&&(this._$ES=this._$ET());}P(t,s,i){this._$AL.has(t)||this._$AL.set(t,s),true===i.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t);}async _$ET(){this.isUpdatePending=true;try{await this._$ES;}catch(t){Promise.reject(t);}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,s]of this._$Ep)this[t]=s;this._$Ep=void 0;}const t=this.constructor.elementProperties;if(t.size>0)for(const[s,i]of t) true!==i.wrapped||this._$AL.has(s)||void 0===this[s]||this.P(s,this[s],i);}let t=false;const s=this._$AL;try{t=this.shouldUpdate(s),t?(this.willUpdate(s),this._$EO?.forEach((t=>t.hostUpdate?.())),this.update(s)):this._$EU();}catch(s){throw t=false,this._$EU(),s}t&&this._$AE(s);}willUpdate(t){}_$AE(t){this._$EO?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=true,this.firstUpdated(t)),this.updated(t);}_$EU(){this._$AL=new Map,this.isUpdatePending=false;}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return true}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EC(t,this[t]))),this._$EU();}updated(t){}firstUpdated(t){}}b.elementStyles=[],b.shadowRootOptions={mode:"open"},b[d("elementProperties")]=new Map,b[d("finalized")]=new Map,p?.({ReactiveElement:b}),(a.reactiveElementVersions??=[]).push("2.0.4");
|
|
197
197
|
|
|
198
198
|
/**
|
|
199
199
|
* @license
|
|
200
200
|
* Copyright 2017 Google LLC
|
|
201
201
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
202
|
-
*/
|
|
202
|
+
*/class r extends b{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0;}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const s=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=B(s,this.renderRoot,this.renderOptions);}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true);}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false);}render(){return T}}r._$litElement$=true,r["finalized"]=true,globalThis.litElementHydrateSupport?.({LitElement:r});const i=globalThis.litElementPolyfillSupport;i?.({LitElement:r});(globalThis.litElementVersions??=[]).push("4.1.1");
|
|
203
203
|
|
|
204
|
-
var styleCss$4 = i$
|
|
204
|
+
var styleCss$4 = i$2`*,*:before,*:after{box-sizing:border-box}@media(prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms !important;animation-iteration-count:1 !important;transition-duration:.01ms !important}}*:focus-visible{outline:0}*:focus-visible{outline:0}:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock,:host{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host([hidden]:not(:focus):not(:active)){display:none}.util_displayHiddenVisually,:host([hiddenVisually]:not(:focus):not(:active)){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.typeIcon{display:flex;flex-direction:row;align-items:center}.typeIcon [auro-icon]{--ds-auro-icon-size: var(--ds-size-300, 1.5rem);height:var(--ds-size-300, 1.5rem);margin-right:var(--ds-size-100, 0.5rem)}.notificationIcons{display:flex;flex-direction:row;padding-right:var(--ds-size-100, 0.5rem)}:host([bordered]) .typeIcon{padding-left:var(--ds-size-100, 0.5rem)}:host([bordered]) .notificationIcons{align-items:center}.notification:not(:first-of-type){margin-left:var(--ds-size-100, 0.5rem)}.alertNotification{width:calc(var(--ds-size-300, 1.5rem) + var(--ds-size-25, 0.125rem));height:calc(var(--ds-size-300, 1.5rem) + var(--ds-size-25, 0.125rem))}.passwordBtn{width:calc(var(--ds-size-300, 1.5rem));height:calc(var(--ds-size-300, 1.5rem))}.notificationBtn{display:block;width:var(--ds-size-300, 1.5rem);height:var(--ds-size-300, 1.5rem);padding:0;border:0;background:unset;cursor:pointer}.notificationBtn [auro-icon]{display:block;height:var(--ds-size-300, 1.5rem);--ds-auro-icon-size: var(--ds-size-300, 1.5rem)}.notificationBtn [auro-icon][hidden]{display:none}:host(:not([bordered])) .typeIcon,:host(:not([bordered])) .notificationIcons{align-items:flex-end;padding-bottom:var(--ds-size-50, 0.25rem)}.clearBtn{transition:all .3s cubic-bezier(0.215, 0.61, 0.355, 1);overflow:hidden;width:0;opacity:0}:host .wrapper:hover .clearBtn,:host .wrapper:focus-within .clearBtn{width:calc(var(--ds-size-200, 1rem) + var(--ds-size-25, 0.125rem));height:calc(var(--ds-size-200, 1rem) + var(--ds-size-25, 0.125rem));opacity:1}:host(:focus-within[type=password]) .notificationIcons[hasValue] .alertNotification{overflow:hidden;width:0;height:0;padding:0;margin:0;visibility:hidden}input{border:unset}.wrapper{position:relative;overflow:hidden;border-style:solid}:host(:not([bordered],[borderless])) .wrapper{border-width:1px 0}:host([bordered]) .wrapper{border-width:1px;border-radius:var(--ds-border-radius, 0.375rem)}:host(:not([borderless])) .wrapper:focus-within:before{position:absolute;display:block;border-bottom-width:1px;border-bottom-style:solid;content:"";inset:0;pointer-events:none}:host([validity]:not([validity=valid])) .wrapper:before{border-bottom:0}label{transition:all .3s cubic-bezier(0.215, 0.61, 0.355, 1);position:absolute;overflow:hidden;pointer-events:none;text-overflow:ellipsis;white-space:nowrap}:host(:not([bordered])) label{top:calc(100% - var(--ds-size-25, 0.125rem));transform:translateY(-100%)}:host(:not([bordered])) label.withIcon{left:var(--ds-size-400, 2rem)}:host([bordered]) label{top:50%;transform:translateY(-50%)}:host([bordered]) label.withIcon{left:var(--ds-size-500, 2.5rem)}:host([bordered]) label:not(label.withIcon){left:var(--ds-size-100, 0.5rem)}:host .wrapper:focus-within label{top:var(--ds-size-100, 0.5rem);font-size:var(--ds-text-body-size-xs, 0.75rem);transform:unset}:host label.withValue{top:var(--ds-size-100, 0.5rem);font-size:var(--ds-text-body-size-xs, 0.75rem);transform:unset}:host([activeLabel]) .wrapper label{top:var(--ds-size-100, 0.5rem);font-size:var(--ds-text-body-size-xs, 0.75rem);transform:unset}:host{position:relative;display:block}.wrapper{display:flex;flex-direction:row}.main{display:flex;flex-direction:row;position:relative;flex:1}input{transition:all .3s cubic-bezier(0.215, 0.61, 0.355, 1);position:relative;overflow:hidden;min-height:var(--ds-size-700, 3.5rem);max-height:var(--ds-size-700, 3.5rem);flex:1;padding:var(--ds-size-400, 2rem) 0 var(--ds-size-50, 0.25rem);margin:0;font-family:var(--ds-font-family-default, "AS Circular", Helvetica Neue, Arial, sans-serif);font-size:var(--ds-size-200, 1rem);outline:none;text-overflow:ellipsis;white-space:nowrap}input::-ms-reveal,input::-ms-clear{display:none}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{margin:0;-webkit-appearance:none}input[type=number]{-moz-appearance:textfield;appearance:textfield}input:disabled{background:none;pointer-events:none}:host([bordered]) input{padding:var(--ds-size-400, 2rem) 0 var(--ds-size-100, 0.5rem)}`;
|
|
205
205
|
|
|
206
|
-
var colorCss$4 = i$
|
|
206
|
+
var colorCss$4 = i$2`.wrapper{border-color:transparent}input{background-color:transparent;caret-color:var(--ds-auro-input-caret-color);color:var(--ds-auro-input-text-color)}input::placeholder{color:transparent}input:focus::placeholder{color:var(--ds-auro-input-placeholder-text-color)}input:disabled{--ds-auro-input-input-text-color: var(--ds-color-text-ui-disabled-default, #adadad)}label{color:var(--ds-auro-input-label-text-color)}:host(:not([bordered],[borderless])) .wrapper{border-bottom-color:var(--ds-auro-input-border-color)}:host([bordered]) .wrapper{border-color:var(--ds-auro-input-border-color);background-color:var(--ds-auro-input-container-color)}:host([bordered]) .wrapper:focus-within{--ds-auro-input-border-color: var(--ds-color-border-ui-focus-default, #2c67b5);box-shadow:inset 0 0 0 1px var(--ds-auro-input-border-color)}:host(:not([borderless])) .wrapper:focus-within{--ds-auro-input-border-color: var(--ds-color-border-ui-focus-default, #2c67b5)}:host(:not([borderless])) .wrapper:focus-within:before{border-bottom-color:transparent}:host([validity]:not([validity=valid])){--ds-auro-input-border-color: var(--ds-color-border-error-default, #cc1816)}:host([validity]:not([validity=valid])[bordered]) .wrapper{--ds-auro-input-border-color: var(--ds-color-border-error-default, #cc1816);box-shadow:inset 0 0 0 1px var(--ds-auro-input-border-color)}:host([disabled]){--ds-auro-input-border-color: var(--ds-color-border-ui-disabled-default, #adadad);--ds-auro-input-label-text-color: var(--ds-color-text-ui-disabled-default, #adadad)}`;
|
|
207
207
|
|
|
208
|
-
var tokensCss$4 = i$
|
|
208
|
+
var tokensCss$4 = i$2`:host{--ds-auro-input-border-color: var(--ds-color-border-secondary-default, #939fad);--ds-auro-input-container-color: var(--ds-color-container-primary-default, #ffffff);--ds-auro-input-caret-color: var(--ds-color-text-ui-focus-default, #2c67b5);--ds-auro-input-label-text-color: var(--ds-color-text-tertiary-default, #6a717c);--ds-auro-input-placeholder-text-color: var(--ds-color-text-primary-default, #2a2a2a);--ds-auro-input-text-color: var(--ds-color-text-primary-default, #2a2a2a)}`;
|
|
209
209
|
|
|
210
210
|
/** Checks if value is string */
|
|
211
211
|
function isString(str) {
|
|
@@ -4056,7 +4056,7 @@ class AuroInputUtilities {
|
|
|
4056
4056
|
|
|
4057
4057
|
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
4058
4058
|
|
|
4059
|
-
let AuroLibraryRuntimeUtils$
|
|
4059
|
+
let AuroLibraryRuntimeUtils$4 = class AuroLibraryRuntimeUtils {
|
|
4060
4060
|
|
|
4061
4061
|
/* eslint-disable jsdoc/require-param */
|
|
4062
4062
|
|
|
@@ -4125,7 +4125,7 @@ let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
|
4125
4125
|
|
|
4126
4126
|
class AuroFormValidation {
|
|
4127
4127
|
constructor() {
|
|
4128
|
-
this.runtimeUtils = new AuroLibraryRuntimeUtils$
|
|
4128
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$4();
|
|
4129
4129
|
}
|
|
4130
4130
|
|
|
4131
4131
|
/**
|
|
@@ -4452,7 +4452,7 @@ class AuroFormValidation {
|
|
|
4452
4452
|
* @event auroFormElement-validated - Notifies that the `validity` and `errorMessage` value has changed.
|
|
4453
4453
|
*/
|
|
4454
4454
|
|
|
4455
|
-
class BaseInput extends r
|
|
4455
|
+
class BaseInput extends r {
|
|
4456
4456
|
|
|
4457
4457
|
constructor() {
|
|
4458
4458
|
super();
|
|
@@ -4803,9 +4803,9 @@ class BaseInput extends r$4 {
|
|
|
4803
4803
|
|
|
4804
4804
|
static get styles() {
|
|
4805
4805
|
return [
|
|
4806
|
-
i$
|
|
4807
|
-
i$
|
|
4808
|
-
i$
|
|
4806
|
+
i$2`${colorCss$4}`,
|
|
4807
|
+
i$2`${styleCss$4}`,
|
|
4808
|
+
i$2`${tokensCss$4}`
|
|
4809
4809
|
];
|
|
4810
4810
|
}
|
|
4811
4811
|
|
|
@@ -5389,7 +5389,7 @@ class BaseInput extends r$4 {
|
|
|
5389
5389
|
// See LICENSE in the project root for license information.
|
|
5390
5390
|
|
|
5391
5391
|
|
|
5392
|
-
class AuroDependencyVersioning {
|
|
5392
|
+
let AuroDependencyVersioning$1 = class AuroDependencyVersioning {
|
|
5393
5393
|
|
|
5394
5394
|
/**
|
|
5395
5395
|
* Generates a unique string to be used for child auro element naming.
|
|
@@ -5415,7 +5415,7 @@ class AuroDependencyVersioning {
|
|
|
5415
5415
|
*/
|
|
5416
5416
|
generateTag(baseName, version, tagClass) {
|
|
5417
5417
|
const elementName = this.generateElementName(baseName, version);
|
|
5418
|
-
const tag = i$
|
|
5418
|
+
const tag = i$4`${s$2(elementName)}`;
|
|
5419
5419
|
|
|
5420
5420
|
if (!customElements.get(elementName)) {
|
|
5421
5421
|
customElements.define(elementName, class extends tagClass {});
|
|
@@ -5423,7 +5423,7 @@ class AuroDependencyVersioning {
|
|
|
5423
5423
|
|
|
5424
5424
|
return tag;
|
|
5425
5425
|
}
|
|
5426
|
-
}
|
|
5426
|
+
};
|
|
5427
5427
|
|
|
5428
5428
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5429
5429
|
// See LICENSE in the project root for license information.
|
|
@@ -5435,7 +5435,7 @@ class AuroDependencyVersioning {
|
|
|
5435
5435
|
* @attr {Boolean} hiddenAudible - If present, the component will be hidden from screen readers, but seen visually
|
|
5436
5436
|
*/
|
|
5437
5437
|
|
|
5438
|
-
class AuroElement extends r
|
|
5438
|
+
class AuroElement extends r {
|
|
5439
5439
|
|
|
5440
5440
|
// function to define props used within the scope of this component
|
|
5441
5441
|
static get properties() {
|
|
@@ -5491,7 +5491,7 @@ const cacheFetch = (uri, options = {}) => {
|
|
|
5491
5491
|
return _fetchMap.get(uri);
|
|
5492
5492
|
};
|
|
5493
5493
|
|
|
5494
|
-
var styleCss$3 = i$
|
|
5494
|
+
var styleCss$3 = i$2`:focus:not(:focus-visible){outline:3px solid transparent}.util_displayInline{display:inline}.util_displayInlineBlock{display:inline-block}.util_displayBlock,:host{display:block}.util_displayFlex{display:flex}.util_displayHidden,:host([hidden]:not(:focus):not(:active)){display:none}.util_displayHiddenVisually,:host([hiddenVisually]:not(:focus):not(:active)){position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}.ico_squareLarge{fill:currentColor;height:var(--auro-size-lg, var(--ds-size-300, 1.5rem))}.ico_squareSmall{fill:currentColor;height:.6rem}.ico_squareMed{fill:currentColor;height:var(--auro-size-md, var(--ds-size-200, 1rem))}.ico_squareSml{fill:currentColor;height:var(--auro-size-sm, var(--ds-size-150, 0.75rem))}:host{color:currentColor;vertical-align:middle;line-height:1;display:inline-block}:host .logo{color:var(--ds-color-brand-midnight-400, #01426a)}svg{min-width:var(--ds-auro-icon-size, 1.5rem) !important;width:var(--ds-auro-icon-size, 1.5rem) !important;height:var(--ds-auro-icon-size, 1.5rem) !important}.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}`;
|
|
5495
5495
|
|
|
5496
5496
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5497
5497
|
// See LICENSE in the project root for license information.
|
|
@@ -5530,7 +5530,7 @@ class BaseIcon extends AuroElement {
|
|
|
5530
5530
|
}
|
|
5531
5531
|
|
|
5532
5532
|
static get styles() {
|
|
5533
|
-
return i$
|
|
5533
|
+
return i$2`
|
|
5534
5534
|
${styleCss$3}
|
|
5535
5535
|
`;
|
|
5536
5536
|
}
|
|
@@ -5572,47 +5572,88 @@ class BaseIcon extends AuroElement {
|
|
|
5572
5572
|
}
|
|
5573
5573
|
}
|
|
5574
5574
|
|
|
5575
|
-
var tokensCss$3 = i$
|
|
5575
|
+
var tokensCss$3 = i$2`:host{--ds-auro-icon-color:var(--ds-color-icon-primary-default, #676767);--ds-auro-icon-size:var(--ds-size-300, 1.5rem)}`;
|
|
5576
5576
|
|
|
5577
|
-
var colorCss$3 = i$
|
|
5577
|
+
var colorCss$3 = i$2`:host{color:var(--ds-auro-icon-color)}:host([customColor]){color:inherit}:host(:not([onDark])[accent]){--ds-auro-icon-color:var(--ds-color-icon-accent-default, #a2c270)}:host(:not([onDark])[disabled]){--ds-auro-icon-color:var(--ds-color-icon-ui-primary-disabled-default, #adadad)}:host(:not([onDark])[emphasis]){--ds-auro-icon-color:var(--ds-color-icon-emphasis-default, #2a2a2a)}:host(:not([onDark])[error]){--ds-auro-icon-color:var(--ds-color-icon-error-default, #cc1816)}:host(:not([onDark])[info]){--ds-auro-icon-color:var(--ds-color-icon-info-default, #326aa5)}:host(:not([onDark])[secondary]){--ds-auro-icon-color:var(--ds-color-icon-secondary-default, #7e8894)}:host(:not([onDark])[subtle]){--ds-auro-icon-color:var(--ds-color-icon-subtle-default, #a0c9f1)}:host(:not([onDark])[success]){--ds-auro-icon-color:var(--ds-color-icon-success-default, #40a080)}:host(:not([onDark])[tertiary]){--ds-auro-icon-color:var(--ds-color-icon-tertiary-default, #afb9c6)}:host(:not([onDark])[warning]){--ds-auro-icon-color:var(--ds-color-icon-warning-default, #c49432)}:host([onDark]){--ds-auro-icon-color:var(--ds-color-icon-primary-inverse, #f7f7f7)}:host([onDark][accent]){--ds-auro-icon-color:var(--ds-color-icon-accent-inverse, #badd81)}:host([onDark][disabled]){--ds-auro-icon-color:var(--ds-color-icon-ui-primary-disabled-inverse, #7e7e7e)}:host([onDark][emphasis]){--ds-auro-icon-color:var(--ds-color-icon-emphasis-inverse, #ffffff)}:host([onDark][error]){--ds-auro-icon-color:var(--ds-color-icon-error-inverse, #f9aca6)}:host([onDark][info]){--ds-auro-icon-color:var(--ds-color-icon-info-inverse, #89b2d4)}:host([onDark][secondary]){--ds-auro-icon-color:var(--ds-color-icon-secondary-inverse, #ccd2db)}:host([onDark][subtle]){--ds-auro-icon-color:var(--ds-color-icon-subtle-inverse, #326aa5)}:host([onDark][success]){--ds-auro-icon-color:var(--ds-color-icon-success-inverse, #8eceb9)}:host([onDark][tertiary]){--ds-auro-icon-color:var(--ds-color-icon-tertiary-inverse, #939fad)}:host([onDark][warning]){--ds-auro-icon-color:var(--ds-color-icon-warning-inverse, #f2c153)}`;
|
|
5578
5578
|
|
|
5579
|
-
// Copyright (c)
|
|
5579
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5580
5580
|
// See LICENSE in the project root for license information.
|
|
5581
5581
|
|
|
5582
|
+
// ---------------------------------------------------------------------
|
|
5583
|
+
|
|
5584
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
5585
|
+
|
|
5586
|
+
let AuroLibraryRuntimeUtils$3 = class AuroLibraryRuntimeUtils {
|
|
5587
|
+
|
|
5588
|
+
/* eslint-disable jsdoc/require-param */
|
|
5589
|
+
|
|
5590
|
+
/**
|
|
5591
|
+
* This will register a new custom element with the browser.
|
|
5592
|
+
* @param {String} name - The name of the custom element.
|
|
5593
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
5594
|
+
* @returns {void}
|
|
5595
|
+
*/
|
|
5596
|
+
registerComponent(name, componentClass) {
|
|
5597
|
+
if (!customElements.get(name)) {
|
|
5598
|
+
customElements.define(name, class extends componentClass {});
|
|
5599
|
+
}
|
|
5600
|
+
}
|
|
5601
|
+
|
|
5602
|
+
/**
|
|
5603
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
5604
|
+
* @returns {void}
|
|
5605
|
+
*/
|
|
5606
|
+
closestElement(
|
|
5607
|
+
selector, // selector like in .closest()
|
|
5608
|
+
base = this, // extra functionality to skip a parent
|
|
5609
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
5610
|
+
!el || el === document || el === window
|
|
5611
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
5612
|
+
: found
|
|
5613
|
+
? found // found a selector INside this element
|
|
5614
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
5615
|
+
) {
|
|
5616
|
+
return __Closest(base);
|
|
5617
|
+
}
|
|
5618
|
+
/* eslint-enable jsdoc/require-param */
|
|
5619
|
+
|
|
5620
|
+
/**
|
|
5621
|
+
* 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.
|
|
5622
|
+
* @param {Object} elem - The element to check.
|
|
5623
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
5624
|
+
* @returns {void}
|
|
5625
|
+
*/
|
|
5626
|
+
handleComponentTagRename(elem, tagName) {
|
|
5627
|
+
const tag = tagName.toLowerCase();
|
|
5628
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
5629
|
+
|
|
5630
|
+
if (elemTag !== tag) {
|
|
5631
|
+
elem.setAttribute(tag, true);
|
|
5632
|
+
}
|
|
5633
|
+
}
|
|
5634
|
+
|
|
5635
|
+
/**
|
|
5636
|
+
* Validates if an element is a specific Auro component.
|
|
5637
|
+
* @param {Object} elem - The element to validate.
|
|
5638
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
5639
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
5640
|
+
*/
|
|
5641
|
+
elementMatch(elem, tagName) {
|
|
5642
|
+
const tag = tagName.toLowerCase();
|
|
5643
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
5644
|
+
|
|
5645
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
5646
|
+
}
|
|
5647
|
+
};
|
|
5648
|
+
|
|
5649
|
+
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5650
|
+
// See LICENSE in the project root for license information.
|
|
5582
5651
|
|
|
5583
|
-
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
5584
|
-
/**
|
|
5585
|
-
* auro-icon provides users a way to use the Auro Icons by simply passing in the category and name.
|
|
5586
|
-
*
|
|
5587
|
-
* @attr {String} category - The category of the icon you are looking for. See https://auro.alaskaair.com/icons/usage.
|
|
5588
|
-
* @attr {String} name - The name of the icon you are looking for without the file extension. See https://auro.alaskaair.com/icons/usage
|
|
5589
|
-
* @attr {Boolean} customColor - Removes primary selector.
|
|
5590
|
-
* @attr {Boolean} customSvg - When true, auro-icon will render a custom SVG inside the default slot.
|
|
5591
|
-
* @attr {Boolean} label - Exposes content in slot as icon label.
|
|
5592
|
-
* @attr {Boolean} primary - DEPRECATED: Sets the icon to use the baseline primary icon style.
|
|
5593
|
-
* @attr {Boolean} accent - Sets the icon to use the accent style.
|
|
5594
|
-
* @attr {Boolean} emphasis - Sets the icon to use the emphasis style.
|
|
5595
|
-
* @attr {Boolean} disabled - Sets the icon to use the disabled style.
|
|
5596
|
-
* @attr {Boolean} error - Sets the icon to use the error style.
|
|
5597
|
-
* @attr {Boolean} info - Sets the icon to use the info style.
|
|
5598
|
-
* @attr {Boolean} secondary - Sets the icon to use the secondary style.
|
|
5599
|
-
* @attr {Boolean} tertiary - Sets the icon to use the tertiary style.
|
|
5600
|
-
* @attr {Boolean} subtle - Sets the icon to use the subtle style.
|
|
5601
|
-
* @attr {Boolean} success - Sets the icon to use the success style.
|
|
5602
|
-
* @attr {Boolean} warning - Sets the icon to use the warning style.
|
|
5603
|
-
* @attr {String} ariaHidden - Set aria-hidden value. Default is `true`. Option is `false`.
|
|
5604
|
-
* @attr {String} uri - Set the uri for CDN used when fetching icons
|
|
5605
|
-
* @slot - Hidden from visibility, used for a11y if icon description is needed.
|
|
5606
|
-
* @slot svg - Used for custom SVG content.
|
|
5607
|
-
*/
|
|
5608
5652
|
|
|
5609
|
-
// build the component class
|
|
5610
5653
|
class AuroIcon extends BaseIcon {
|
|
5611
5654
|
constructor() {
|
|
5612
5655
|
super();
|
|
5613
5656
|
|
|
5614
|
-
this.uri = 'https://cdn.jsdelivr.net/npm/@alaskaairux/icons@latest/dist';
|
|
5615
|
-
|
|
5616
5657
|
this.privateDefaults();
|
|
5617
5658
|
}
|
|
5618
5659
|
|
|
@@ -5636,78 +5677,144 @@ class AuroIcon extends BaseIcon {
|
|
|
5636
5677
|
this.success = false;
|
|
5637
5678
|
this.tertiary = false;
|
|
5638
5679
|
this.warning = false;
|
|
5639
|
-
this.
|
|
5680
|
+
this.uri = 'https://cdn.jsdelivr.net/npm/@alaskaairux/icons@latest/dist';
|
|
5681
|
+
this.runtimeUtils = new AuroLibraryRuntimeUtils$3();
|
|
5640
5682
|
}
|
|
5641
5683
|
|
|
5642
5684
|
// function to define props used within the scope of this component
|
|
5643
5685
|
static get properties() {
|
|
5644
5686
|
return {
|
|
5645
5687
|
...super.properties,
|
|
5688
|
+
|
|
5689
|
+
/**
|
|
5690
|
+
* Sets the icon to use the accent style.
|
|
5691
|
+
*/
|
|
5646
5692
|
accent: {
|
|
5647
5693
|
type: Boolean,
|
|
5648
5694
|
reflect: true
|
|
5649
5695
|
},
|
|
5696
|
+
|
|
5697
|
+
/**
|
|
5698
|
+
* Set aria-hidden value. Default is `true`. Option is `false`.
|
|
5699
|
+
*/
|
|
5650
5700
|
ariaHidden: {
|
|
5651
5701
|
type: String,
|
|
5652
5702
|
reflect: true
|
|
5653
5703
|
},
|
|
5704
|
+
|
|
5705
|
+
/**
|
|
5706
|
+
* The category of the icon you are looking for. See https://auro.alaskaair.com/icons/usage.
|
|
5707
|
+
*/
|
|
5654
5708
|
category: {
|
|
5655
5709
|
type: String,
|
|
5656
5710
|
reflect: true
|
|
5657
5711
|
},
|
|
5712
|
+
|
|
5713
|
+
/**
|
|
5714
|
+
* Allows custom color to be set.
|
|
5715
|
+
*/
|
|
5658
5716
|
customColor: {
|
|
5659
5717
|
type: Boolean
|
|
5660
5718
|
},
|
|
5719
|
+
|
|
5720
|
+
/**
|
|
5721
|
+
* When true, auro-icon will render a custom SVG inside the default slot.
|
|
5722
|
+
*/
|
|
5661
5723
|
customSvg: {
|
|
5662
5724
|
type: Boolean
|
|
5663
5725
|
},
|
|
5726
|
+
|
|
5727
|
+
/**
|
|
5728
|
+
* Sets the icon to use the disabled style.
|
|
5729
|
+
*/
|
|
5664
5730
|
disabled: {
|
|
5665
5731
|
type: Boolean,
|
|
5666
5732
|
reflect: true
|
|
5667
5733
|
},
|
|
5734
|
+
|
|
5735
|
+
/**
|
|
5736
|
+
* Sets the icon to use the emphasis style.
|
|
5737
|
+
*/
|
|
5668
5738
|
emphasis: {
|
|
5669
5739
|
type: Boolean,
|
|
5670
5740
|
reflect: true
|
|
5671
5741
|
},
|
|
5742
|
+
|
|
5743
|
+
/**
|
|
5744
|
+
* Sets the icon to use the error style.
|
|
5745
|
+
*/
|
|
5672
5746
|
error: {
|
|
5673
5747
|
type: Boolean,
|
|
5674
5748
|
reflect: true
|
|
5675
5749
|
},
|
|
5750
|
+
|
|
5751
|
+
/**
|
|
5752
|
+
* Sets the icon to use the info style.
|
|
5753
|
+
*/
|
|
5676
5754
|
info: {
|
|
5677
5755
|
type: Boolean,
|
|
5678
5756
|
reflect: true
|
|
5679
5757
|
},
|
|
5758
|
+
|
|
5759
|
+
/**
|
|
5760
|
+
* Exposes content in slot as icon label.
|
|
5761
|
+
*/
|
|
5680
5762
|
label: {
|
|
5681
5763
|
type: Boolean,
|
|
5682
5764
|
reflect: true
|
|
5683
5765
|
},
|
|
5766
|
+
|
|
5767
|
+
/**
|
|
5768
|
+
* The name of the icon you are looking for without the file extension. See https://auro.alaskaair.com/icons/usage.
|
|
5769
|
+
*/
|
|
5684
5770
|
name: {
|
|
5685
5771
|
type: String,
|
|
5686
5772
|
reflect: true
|
|
5687
5773
|
},
|
|
5774
|
+
|
|
5775
|
+
/**
|
|
5776
|
+
* DEPRECATED: Sets the icon to use the baseline primary icon style.
|
|
5777
|
+
*/
|
|
5688
5778
|
primary: {
|
|
5689
5779
|
type: Boolean,
|
|
5690
5780
|
reflect: true
|
|
5691
5781
|
},
|
|
5782
|
+
|
|
5783
|
+
/**
|
|
5784
|
+
* Sets the icon to use the secondary style.
|
|
5785
|
+
*/
|
|
5692
5786
|
secondary: {
|
|
5693
5787
|
type: Boolean,
|
|
5694
5788
|
reflect: true
|
|
5695
5789
|
},
|
|
5790
|
+
|
|
5791
|
+
/**
|
|
5792
|
+
* Sets the icon to use the subtle style.
|
|
5793
|
+
*/
|
|
5696
5794
|
subtle: {
|
|
5697
5795
|
type: Boolean,
|
|
5698
5796
|
reflect: true
|
|
5699
5797
|
},
|
|
5798
|
+
|
|
5799
|
+
/**
|
|
5800
|
+
* Sets the icon to use the success style.
|
|
5801
|
+
*/
|
|
5700
5802
|
success: {
|
|
5701
5803
|
type: Boolean,
|
|
5702
5804
|
reflect: true
|
|
5703
5805
|
},
|
|
5806
|
+
|
|
5807
|
+
/**
|
|
5808
|
+
* Sets the icon to use the tertiary style.
|
|
5809
|
+
*/
|
|
5704
5810
|
tertiary: {
|
|
5705
5811
|
type: Boolean,
|
|
5706
5812
|
reflect: true
|
|
5707
5813
|
},
|
|
5708
|
-
|
|
5709
|
-
|
|
5710
|
-
|
|
5814
|
+
|
|
5815
|
+
/**
|
|
5816
|
+
* Sets the icon to use the warning style.
|
|
5817
|
+
*/
|
|
5711
5818
|
warning: {
|
|
5712
5819
|
type: Boolean,
|
|
5713
5820
|
reflect: true
|
|
@@ -5718,9 +5825,9 @@ class AuroIcon extends BaseIcon {
|
|
|
5718
5825
|
static get styles() {
|
|
5719
5826
|
return [
|
|
5720
5827
|
super.styles,
|
|
5721
|
-
i$
|
|
5722
|
-
i$
|
|
5723
|
-
i$
|
|
5828
|
+
i$2`${tokensCss$3}`,
|
|
5829
|
+
i$2`${styleCss$3}`,
|
|
5830
|
+
i$2`${colorCss$3}`
|
|
5724
5831
|
];
|
|
5725
5832
|
}
|
|
5726
5833
|
|
|
@@ -5733,7 +5840,7 @@ class AuroIcon extends BaseIcon {
|
|
|
5733
5840
|
*
|
|
5734
5841
|
*/
|
|
5735
5842
|
static register(name = "auro-icon") {
|
|
5736
|
-
AuroLibraryRuntimeUtils$
|
|
5843
|
+
AuroLibraryRuntimeUtils$3.prototype.registerComponent(name, AuroIcon);
|
|
5737
5844
|
}
|
|
5738
5845
|
|
|
5739
5846
|
connectedCallback() {
|
|
@@ -5744,38 +5851,54 @@ class AuroIcon extends BaseIcon {
|
|
|
5744
5851
|
}
|
|
5745
5852
|
|
|
5746
5853
|
/**
|
|
5854
|
+
* @private
|
|
5747
5855
|
* @returns {void} Exposes CSS parts for styling from parent components.
|
|
5748
5856
|
*/
|
|
5749
5857
|
exposeCssParts() {
|
|
5750
5858
|
this.setAttribute('exportparts', 'svg:iconSvg');
|
|
5751
5859
|
}
|
|
5752
5860
|
|
|
5861
|
+
async firstUpdated() {
|
|
5862
|
+
await super.firstUpdated();
|
|
5863
|
+
|
|
5864
|
+
// Removes the SVG description for screenreader if ariaHidden is set to true
|
|
5865
|
+
if (!this.hasAttribute('ariaHidden') && this.svg) {
|
|
5866
|
+
const svgDesc = this.svg.querySelector('desc');
|
|
5867
|
+
|
|
5868
|
+
if (svgDesc) {
|
|
5869
|
+
svgDesc.remove();
|
|
5870
|
+
this.svg.removeAttribute('aria-labelledby');
|
|
5871
|
+
}
|
|
5872
|
+
}
|
|
5873
|
+
}
|
|
5874
|
+
|
|
5753
5875
|
// function that renders the HTML and CSS into the scope of the component
|
|
5754
5876
|
render() {
|
|
5755
|
-
const
|
|
5756
|
-
'
|
|
5877
|
+
const labelClasses = {
|
|
5878
|
+
'labelWrapper': true,
|
|
5757
5879
|
'util_displayHiddenVisually': !this.label
|
|
5758
5880
|
};
|
|
5759
5881
|
|
|
5760
|
-
const
|
|
5761
|
-
'
|
|
5762
|
-
'wrapper': true,
|
|
5882
|
+
const svgClasses = {
|
|
5883
|
+
'svgWrapper': true,
|
|
5763
5884
|
};
|
|
5764
5885
|
|
|
5765
|
-
return x
|
|
5766
|
-
<div
|
|
5767
|
-
|
|
5768
|
-
|
|
5769
|
-
|
|
5770
|
-
${this.
|
|
5771
|
-
|
|
5772
|
-
|
|
5773
|
-
|
|
5774
|
-
|
|
5775
|
-
|
|
5776
|
-
|
|
5886
|
+
return x`
|
|
5887
|
+
<div class="componentWrapper">
|
|
5888
|
+
<div
|
|
5889
|
+
class="${e$2(svgClasses)}"
|
|
5890
|
+
title="${o$2(this.title || undefined)}">
|
|
5891
|
+
<span aria-hidden="${o$2(this.ariaHidden || true)}" part="svg">
|
|
5892
|
+
${this.customSvg ? x`
|
|
5893
|
+
<slot name="svg"></slot>
|
|
5894
|
+
` : x`
|
|
5895
|
+
${this.svg}
|
|
5896
|
+
`
|
|
5897
|
+
}
|
|
5898
|
+
</span>
|
|
5899
|
+
</div>
|
|
5777
5900
|
|
|
5778
|
-
<div class="${e$
|
|
5901
|
+
<div class="${e$2(labelClasses)}">
|
|
5779
5902
|
<slot></slot>
|
|
5780
5903
|
</div>
|
|
5781
5904
|
</div>
|
|
@@ -5785,17 +5908,197 @@ class AuroIcon extends BaseIcon {
|
|
|
5785
5908
|
|
|
5786
5909
|
var iconVersion = '6.1.2';
|
|
5787
5910
|
|
|
5788
|
-
|
|
5911
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5912
|
+
// See LICENSE in the project root for license information.
|
|
5913
|
+
|
|
5789
5914
|
|
|
5790
|
-
var colorCss$2 = i$6`[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:after{border-color:var(--ds-auro-button-border-inset-color)}.auro-button:not([ondark]):active{--ds-auro-button-container-color: var(--ds-color-container-ui-primary-active-default, #225296);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-active-default, #225296);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-active-default, #225296)}.auro-button:not([ondark])[disabled]{--ds-auro-button-container-color: var(--ds-color-container-ui-primary-disabled-default, #a0c9f1);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-disabled-default, #a0c9f1);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-disabled-default, #a0c9f1)}@media(hover: hover){.auro-button:not([ondark]):active:not(:disabled),.auro-button:not([ondark]):hover:not(:disabled){--ds-auro-button-container-color: var(--ds-color-container-ui-primary-hover-default, #193d73);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-hover-default, #193d73);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-hover-default, #193d73)}}.auro-button:not([ondark])[variant=secondary]{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-default-default, #ffffff);--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-default-default, #ffffff);--ds-auro-button-border-color: var(--ds-color-border-ui-default-default, #2c67b5);--ds-auro-button-text-color: var(--ds-color-text-ui-default-default, #2c67b5)}@media(hover: hover){.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-color-container-ui-secondary-hover-default, rgba(0, 0, 0, 0.03));--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-hover-default, rgba(0, 0, 0, 0.03));--ds-auro-button-border-color: var(--ds-color-border-ui-hover-default, #193d73);--ds-auro-button-text-color: var(--ds-color-text-ui-hover-default, #193d73)}}.auro-button:not([ondark])[variant=secondary]:focus-visible{--ds-auro-button-border-inset-color: var(--ds-color-border-ui-focus-default, #2c67b5)}.auro-button:not([ondark])[variant=secondary]:active{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-active-default, #f0f7fd);--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-active-default, #f0f7fd);--ds-auro-button-border-color: var(--ds-color-border-ui-active-default, #225296);--ds-auro-button-text-color: var(--ds-color-text-ui-active-default, #225296)}.auro-button:not([ondark])[variant=secondary]:disabled{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-disabled-default, #f7f7f7);--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-disabled-default, #f7f7f7);--ds-auro-button-border-color: var(--ds-color-border-ui-disabled-default, #adadad);--ds-auro-button-text-color: var(--ds-color-text-ui-disabled-default, #adadad)}.auro-button:not([ondark])[variant=tertiary]{--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-default-default, rgba(0, 0, 0, 0.03));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-default-default, rgba(0, 0, 0, 0.03));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-default-default, #2c67b5)}@media(hover: hover){.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-color-container-ui-tertiary-hover-default, rgba(0, 0, 0, 0.12));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-hover-default, rgba(0, 0, 0, 0.12));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-hover-default, #193d73)}}.auro-button:not([ondark])[variant=tertiary]:focus-visible{--ds-auro-button-border-color: var(--ds-color-border-ui-default-default, #2c67b5);--ds-auro-button-border-inset-color: var(--ds-color-border-ui-default-default, #2c67b5)}.auro-button:not([ondark])[variant=tertiary]:active{--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-active-default, rgba(0, 0, 0, 0.06));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-active-default, rgba(0, 0, 0, 0.06));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-active-default, #225296)}.auro-button:not([ondark])[variant=tertiary]:disabled{--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-disabled-default, rgba(0, 0, 0, 0.03));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-disabled-default, rgba(0, 0, 0, 0.03));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-disabled-default, #adadad)}.auro-button:not([ondark])[variant=flat]{color:var(--ds-color-icon-ui-secondary-default-default);background-color:transparent;background-image:none;border-color:transparent}@media(hover: hover){.auro-button:not([ondark])[variant=flat]:active:not(:disabled),.auro-button:not([ondark])[variant=flat]:hover:not(:disabled){color:var(--ds-color-icon-ui-secondary-hover-default);background-color:transparent;background-image:none;border-color:transparent}}.auro-button:not([ondark])[variant=flat]:disabled{color:var(--ds-color-icon-ui-secondary-disabled-default);background-color:transparent;background-image:none;border-color:transparent}.auro-button[ondark]{--ds-auro-button-container-color: var(--ds-color-container-ui-primary-default-inverse, #56bbde);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-default-inverse, #56bbde);--ds-auro-button-text-color: var(--ds-color-text-primary-default, #2a2a2a);--ds-auro-button-loader-color: var(--ds-color-text-primary-inverse, #ffffff);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-default-inverse, #56bbde)}@media(hover: hover){.auro-button[ondark]:active:not(:disabled),.auro-button[ondark]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-color-container-ui-primary-hover-inverse, #a8e9f7);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-hover-inverse, #a8e9f7);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-hover-inverse, #a8e9f7)}}.auro-button[ondark]:active{--ds-auro-button-container-color: var(--ds-color-container-ui-primary-active-inverse, #6ad5ef);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-active-inverse, #6ad5ef);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-active-inverse, #6ad5ef)}.auro-button[ondark][disabled]{--ds-auro-button-container-color: var(--ds-color-container-ui-primary-disabled-inverse, #275b72);--ds-auro-button-container-image: var(--ds-color-container-ui-primary-disabled-inverse, #275b72);--ds-auro-button-text-color: var(--ds-color-text-ui-disabled-inverse, #7e7e7e);--ds-auro-button-border-color: var(--ds-color-container-ui-primary-disabled-inverse, #275b72)}.auro-button[ondark][variant=secondary]{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-default-inverse, rgba(255, 255, 255, 0.03));--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-default-inverse, rgba(255, 255, 255, 0.03));--ds-auro-button-border-color: var(--ds-color-border-ui-default-inverse, #56bbde);--ds-auro-button-text-color: var(--ds-color-text-ui-default-inverse, #56bbde)}@media(hover: hover){.auro-button[ondark][variant=secondary]:hover{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-hover-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-hover-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-border-color: var(--ds-color-border-ui-hover-inverse, #a8e9f7);--ds-auro-button-text-color: var(--ds-color-text-ui-hover-inverse, #a8e9f7)}}.auro-button[ondark][variant=secondary]:focus-visible{--ds-auro-button-border-inset-color: var(--ds-color-border-ui-focus-inverse, #56bbde)}.auro-button[ondark][variant=secondary]:active{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-border-color: var(--ds-color-border-ui-active-inverse, #6ad5ef);--ds-auro-button-text-color: var(--ds-color-text-ui-active-inverse, #6ad5ef)}.auro-button[ondark][variant=secondary]:disabled{--ds-auro-button-container-color: var(--ds-color-container-ui-secondary-disabled-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-container-image: var(--ds-color-container-ui-secondary-disabled-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-border-color: var(--ds-color-border-ui-disabled-inverse, #7e7e7e);--ds-auro-button-text-color: var(--ds-color-text-ui-disabled-inverse, #7e7e7e)}.auro-button[ondark][variant=tertiary]{--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-default-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-default-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-default-inverse, #56bbde)}@media(hover: hover){.auro-button[ondark][variant=tertiary]:active:not(:disabled),.auro-button[ondark][variant=tertiary]:hover:not(:disabled){--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-hover-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-hover-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-hover-inverse, #a8e9f7)}}.auro-button[ondark][variant=tertiary]:focus-visible{--ds-auro-button-border-color: var(--ds-color-border-ui-default-inverse, #56bbde);--ds-auro-button-border-inset-color: var(--ds-color-border-ui-default-inverse, #56bbde)}.auro-button[ondark][variant=tertiary]:active{--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-active-inverse, #6ad5ef)}.auro-button[ondark][variant=tertiary]:disabled{--ds-auro-button-container-color: var(--ds-color-container-ui-tertiary-disabled-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-container-image: var(--ds-color-container-ui-tertiary-disabled-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-border-color: transparent;--ds-auro-button-text-color: var(--ds-color-text-ui-disabled-inverse, #7e7e7e)}.auro-button[ondark][variant=flat]{color:var(--ds-color-icon-ui-secondary-default-inverse);background-color:transparent;background-image:none;border-color:transparent}@media(hover: hover){.auro-button[ondark][variant=flat]:active:not(:disabled),.auro-button[ondark][variant=flat]:hover:not(:disabled){color:var(--ds-color-icon-ui-secondary-hover-inverse);background-color:transparent;background-image:none;border-color:transparent}}.auro-button[ondark][variant=flat]:disabled{color:var(--ds-color-icon-ui-disabled-default);background-color:transparent;background-image:none;border-color:transparent}`;
|
|
5915
|
+
class AuroDependencyVersioning {
|
|
5916
|
+
|
|
5917
|
+
/**
|
|
5918
|
+
* Generates a unique string to be used for child auro element naming.
|
|
5919
|
+
* @private
|
|
5920
|
+
* @param {string} baseName - Defines the first part of the unique element name.
|
|
5921
|
+
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
5922
|
+
* @returns {string} - Unique string to be used for naming.
|
|
5923
|
+
*/
|
|
5924
|
+
generateElementName(baseName, version) {
|
|
5925
|
+
let result = baseName;
|
|
5791
5926
|
|
|
5792
|
-
|
|
5927
|
+
result += '-';
|
|
5928
|
+
result += version.replace(/[.]/g, '_');
|
|
5793
5929
|
|
|
5794
|
-
|
|
5930
|
+
return result;
|
|
5931
|
+
}
|
|
5795
5932
|
|
|
5796
|
-
|
|
5933
|
+
/**
|
|
5934
|
+
* Generates a unique string to be used for child auro element naming.
|
|
5935
|
+
* @param {string} baseName - Defines the first part of the unique element name.
|
|
5936
|
+
* @param {string} version - Version of the component that will be appended to the baseName.
|
|
5937
|
+
* @returns {string} - Unique string to be used for naming.
|
|
5938
|
+
*/
|
|
5939
|
+
generateTag(baseName, version, tagClass) {
|
|
5940
|
+
const elementName = this.generateElementName(baseName, version);
|
|
5941
|
+
const tag = i$4`${s$2(elementName)}`;
|
|
5797
5942
|
|
|
5798
|
-
|
|
5943
|
+
if (!customElements.get(elementName)) {
|
|
5944
|
+
customElements.define(elementName, class extends tagClass {});
|
|
5945
|
+
}
|
|
5946
|
+
|
|
5947
|
+
return tag;
|
|
5948
|
+
}
|
|
5949
|
+
}
|
|
5950
|
+
|
|
5951
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5952
|
+
// See LICENSE in the project root for license information.
|
|
5953
|
+
|
|
5954
|
+
// ---------------------------------------------------------------------
|
|
5955
|
+
|
|
5956
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
5957
|
+
|
|
5958
|
+
let AuroLibraryRuntimeUtils$2 = class AuroLibraryRuntimeUtils {
|
|
5959
|
+
|
|
5960
|
+
/* eslint-disable jsdoc/require-param */
|
|
5961
|
+
|
|
5962
|
+
/**
|
|
5963
|
+
* This will register a new custom element with the browser.
|
|
5964
|
+
* @param {String} name - The name of the custom element.
|
|
5965
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
5966
|
+
* @returns {void}
|
|
5967
|
+
*/
|
|
5968
|
+
registerComponent(name, componentClass) {
|
|
5969
|
+
if (!customElements.get(name)) {
|
|
5970
|
+
customElements.define(name, class extends componentClass {});
|
|
5971
|
+
}
|
|
5972
|
+
}
|
|
5973
|
+
|
|
5974
|
+
/**
|
|
5975
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
5976
|
+
* @returns {void}
|
|
5977
|
+
*/
|
|
5978
|
+
closestElement(
|
|
5979
|
+
selector, // selector like in .closest()
|
|
5980
|
+
base = this, // extra functionality to skip a parent
|
|
5981
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
5982
|
+
!el || el === document || el === window
|
|
5983
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
5984
|
+
: found
|
|
5985
|
+
? found // found a selector INside this element
|
|
5986
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
5987
|
+
) {
|
|
5988
|
+
return __Closest(base);
|
|
5989
|
+
}
|
|
5990
|
+
/* eslint-enable jsdoc/require-param */
|
|
5991
|
+
|
|
5992
|
+
/**
|
|
5993
|
+
* 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.
|
|
5994
|
+
* @param {Object} elem - The element to check.
|
|
5995
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
5996
|
+
* @returns {void}
|
|
5997
|
+
*/
|
|
5998
|
+
handleComponentTagRename(elem, tagName) {
|
|
5999
|
+
const tag = tagName.toLowerCase();
|
|
6000
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6001
|
+
|
|
6002
|
+
if (elemTag !== tag) {
|
|
6003
|
+
elem.setAttribute(tag, true);
|
|
6004
|
+
}
|
|
6005
|
+
}
|
|
6006
|
+
|
|
6007
|
+
/**
|
|
6008
|
+
* Validates if an element is a specific Auro component.
|
|
6009
|
+
* @param {Object} elem - The element to validate.
|
|
6010
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
6011
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
6012
|
+
*/
|
|
6013
|
+
elementMatch(elem, tagName) {
|
|
6014
|
+
const tag = tagName.toLowerCase();
|
|
6015
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6016
|
+
|
|
6017
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
6018
|
+
}
|
|
6019
|
+
};
|
|
6020
|
+
|
|
6021
|
+
var styleCss$2 = i$2`: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-font-family-default, "AS Circular", Helvetica Neue, Arial, sans-serif);font-size:var(--ds-text-body-size-default, 1rem);font-weight:var(--ds-text-body-default-weight, 500);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:not([variant=secondary]):not([variant=tertiary]):not([variant=flat]):after{display:block;content:"";height:calc(100% - 2px);width:calc(100% - 2px);position:absolute;top:1px;left:1px;border-radius:4px;border-style:solid;border-width:2px}.auro-button:focus-visible[variant=secondary]:after,.auro-button:focus-visible[variant=tertiary]:after{display:block;content:"";height:100%;width:100%;position:absolute;top:0;left:0;border-radius:var(--ds-border-radius, 0.375rem);border-style:solid;border-width:2px}.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-text-body-size-sm, 0.875rem);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, $ds-size-300)}.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, $ds-size-200) + var(--ds-size-50, $ds-size-50))}.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}.auro-button--rounded ::slotted(auro-icon),.auro-button--rounded ::slotted([auro-icon]){--ds-auro-icon-size:var(--ds-size-300, $ds-size-300)}: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}`;
|
|
6022
|
+
|
|
6023
|
+
var colorCss$2 = i$2`[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:after{border-color:var(--ds-auro-button-border-inset-color)}.auro-button:not([ondark]):active{--ds-auro-button-container-color:var(--ds-color-container-ui-primary-active-default, #225296);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-active-default, #225296);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-active-default, #225296)}.auro-button:not([ondark])[disabled]{--ds-auro-button-container-color:var(--ds-color-container-ui-primary-disabled-default, #a0c9f1);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-disabled-default, #a0c9f1);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-disabled-default, #a0c9f1)}@media(hover: hover){.auro-button:not([ondark]):active:not(:disabled),.auro-button:not([ondark]):hover:not(:disabled){--ds-auro-button-container-color:var(--ds-color-container-ui-primary-hover-default, #193d73);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-hover-default, #193d73);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-hover-default, #193d73)}}.auro-button:not([ondark])[variant=secondary]{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-default-default, #ffffff);--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-default-default, #ffffff);--ds-auro-button-border-color:var(--ds-color-border-ui-default-default, #2c67b5);--ds-auro-button-text-color:var(--ds-color-text-ui-default-default, #2c67b5)}@media(hover: hover){.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-color-container-ui-secondary-hover-default, rgba(0, 0, 0, 0.03));--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-hover-default, rgba(0, 0, 0, 0.03));--ds-auro-button-border-color:var(--ds-color-border-ui-hover-default, #193d73);--ds-auro-button-text-color:var(--ds-color-text-ui-hover-default, #193d73)}}.auro-button:not([ondark])[variant=secondary]:focus-visible{--ds-auro-button-border-inset-color:var(--ds-color-border-ui-focus-default, #2c67b5)}.auro-button:not([ondark])[variant=secondary]:active{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-active-default, #f0f7fd);--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-active-default, #f0f7fd);--ds-auro-button-border-color:var(--ds-color-border-ui-active-default, #225296);--ds-auro-button-text-color:var(--ds-color-text-ui-active-default, #225296)}.auro-button:not([ondark])[variant=secondary]:disabled{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-disabled-default, #f7f7f7);--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-disabled-default, #f7f7f7);--ds-auro-button-border-color:var(--ds-color-border-ui-disabled-default, #adadad);--ds-auro-button-text-color:var(--ds-color-text-ui-disabled-default, #adadad)}.auro-button:not([ondark])[variant=tertiary]{--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-default-default, rgba(0, 0, 0, 0.03));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-default-default, rgba(0, 0, 0, 0.03));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-default-default, #2c67b5)}@media(hover: hover){.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-color-container-ui-tertiary-hover-default, rgba(0, 0, 0, 0.12));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-hover-default, rgba(0, 0, 0, 0.12));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-hover-default, #193d73)}}.auro-button:not([ondark])[variant=tertiary]:focus-visible{--ds-auro-button-border-color:var(--ds-color-border-ui-default-default, #2c67b5);--ds-auro-button-border-inset-color:var(--ds-color-border-ui-default-default, #2c67b5)}.auro-button:not([ondark])[variant=tertiary]:active{--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-active-default, rgba(0, 0, 0, 0.06));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-active-default, rgba(0, 0, 0, 0.06));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-active-default, #225296)}.auro-button:not([ondark])[variant=tertiary]:disabled{--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-disabled-default, rgba(0, 0, 0, 0.03));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-disabled-default, rgba(0, 0, 0, 0.03));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-disabled-default, #adadad)}.auro-button:not([ondark])[variant=flat]{color:var(--ds-color-icon-ui-secondary-default-default);background-color:transparent;background-image:none;border-color:transparent}@media(hover: hover){.auro-button:not([ondark])[variant=flat]:active:not(:disabled),.auro-button:not([ondark])[variant=flat]:hover:not(:disabled){color:var(--ds-color-icon-ui-secondary-hover-default);background-color:transparent;background-image:none;border-color:transparent}}.auro-button:not([ondark])[variant=flat]:disabled{color:var(--ds-color-icon-ui-secondary-disabled-default);background-color:transparent;background-image:none;border-color:transparent}.auro-button[ondark]{--ds-auro-button-container-color:var(--ds-color-container-ui-primary-default-inverse, #56bbde);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-default-inverse, #56bbde);--ds-auro-button-text-color:var(--ds-color-text-primary-default, #2a2a2a);--ds-auro-button-loader-color:var(--ds-color-text-primary-inverse, #ffffff);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-default-inverse, #56bbde)}@media(hover: hover){.auro-button[ondark]:active:not(:disabled),.auro-button[ondark]:hover:not(:disabled){--ds-auro-button-container-color:var(--ds-color-container-ui-primary-hover-inverse, #a8e9f7);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-hover-inverse, #a8e9f7);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-hover-inverse, #a8e9f7)}}.auro-button[ondark]:active{--ds-auro-button-container-color:var(--ds-color-container-ui-primary-active-inverse, #6ad5ef);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-active-inverse, #6ad5ef);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-active-inverse, #6ad5ef)}.auro-button[ondark][disabled]{--ds-auro-button-container-color:var(--ds-color-container-ui-primary-disabled-inverse, #275b72);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-disabled-inverse, #275b72);--ds-auro-button-text-color:var(--ds-color-text-ui-disabled-inverse, #7e7e7e);--ds-auro-button-border-color:var(--ds-color-container-ui-primary-disabled-inverse, #275b72)}.auro-button[ondark][variant=secondary]{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-default-inverse, rgba(255, 255, 255, 0.03));--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-default-inverse, rgba(255, 255, 255, 0.03));--ds-auro-button-border-color:var(--ds-color-border-ui-default-inverse, #56bbde);--ds-auro-button-text-color:var(--ds-color-text-ui-default-inverse, #56bbde)}@media(hover: hover){.auro-button[ondark][variant=secondary]:hover{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-hover-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-hover-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-border-color:var(--ds-color-border-ui-hover-inverse, #a8e9f7);--ds-auro-button-text-color:var(--ds-color-text-ui-hover-inverse, #a8e9f7)}}.auro-button[ondark][variant=secondary]:focus-visible{--ds-auro-button-border-inset-color:var(--ds-color-border-ui-focus-inverse, #56bbde)}.auro-button[ondark][variant=secondary]:active{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-border-color:var(--ds-color-border-ui-active-inverse, #6ad5ef);--ds-auro-button-text-color:var(--ds-color-text-ui-active-inverse, #6ad5ef)}.auro-button[ondark][variant=secondary]:disabled{--ds-auro-button-container-color:var(--ds-color-container-ui-secondary-disabled-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-container-image:var(--ds-color-container-ui-secondary-disabled-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-border-color:var(--ds-color-border-ui-disabled-inverse, #7e7e7e);--ds-auro-button-text-color:var(--ds-color-text-ui-disabled-inverse, #7e7e7e)}.auro-button[ondark][variant=tertiary]{--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-default-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-default-inverse, rgba(255, 255, 255, 0.12));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-default-inverse, #56bbde)}@media(hover: hover){.auro-button[ondark][variant=tertiary]:active:not(:disabled),.auro-button[ondark][variant=tertiary]:hover:not(:disabled){--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-hover-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-hover-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-hover-inverse, #a8e9f7)}}.auro-button[ondark][variant=tertiary]:focus-visible{--ds-auro-button-border-color:var(--ds-color-border-ui-default-inverse, #56bbde);--ds-auro-button-border-inset-color:var(--ds-color-border-ui-default-inverse, #56bbde)}.auro-button[ondark][variant=tertiary]:active{--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-active-inverse, rgba(255, 255, 255, 0.06));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-active-inverse, #6ad5ef)}.auro-button[ondark][variant=tertiary]:disabled{--ds-auro-button-container-color:var(--ds-color-container-ui-tertiary-disabled-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-container-image:var(--ds-color-container-ui-tertiary-disabled-inverse, rgba(255, 255, 255, 0.25));--ds-auro-button-border-color:transparent;--ds-auro-button-text-color:var(--ds-color-text-ui-disabled-inverse, #7e7e7e)}.auro-button[ondark][variant=flat]{color:var(--ds-color-icon-ui-secondary-default-inverse);background-color:transparent;background-image:none;border-color:transparent}@media(hover: hover){.auro-button[ondark][variant=flat]:active:not(:disabled),.auro-button[ondark][variant=flat]:hover:not(:disabled){color:var(--ds-color-icon-ui-secondary-hover-inverse);background-color:transparent;background-image:none;border-color:transparent}}.auro-button[ondark][variant=flat]:disabled{color:var(--ds-color-icon-ui-disabled-default);background-color:transparent;background-image:none;border-color:transparent}`;
|
|
6024
|
+
|
|
6025
|
+
var tokensCss$2 = i$2`:host{--ds-auro-button-border-color:var(--ds-color-container-ui-primary-default-default, #2c67b5);--ds-auro-button-border-inset-color:var(--ds-color-border-emphasis-inverse, #f2f7fb);--ds-auro-button-container-color:var(--ds-color-container-ui-primary-default-default, #2c67b5);--ds-auro-button-container-image:var(--ds-color-container-ui-primary-default-default, #2c67b5);--ds-auro-button-loader-color:var(--ds-color-utility-navy-default, #265688);--ds-auro-button-text-color:var(--ds-color-text-primary-inverse, #ffffff);--ds-auro-button-tap-color:transparent}`;
|
|
6026
|
+
|
|
6027
|
+
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6028
|
+
// See LICENSE in the project root for license information.
|
|
6029
|
+
|
|
6030
|
+
// ---------------------------------------------------------------------
|
|
6031
|
+
|
|
6032
|
+
/* eslint-disable line-comment-position, no-inline-comments, no-confusing-arrow, no-nested-ternary, implicit-arrow-linebreak */
|
|
6033
|
+
|
|
6034
|
+
let AuroLibraryRuntimeUtils$1 = class AuroLibraryRuntimeUtils {
|
|
6035
|
+
|
|
6036
|
+
/* eslint-disable jsdoc/require-param */
|
|
6037
|
+
|
|
6038
|
+
/**
|
|
6039
|
+
* This will register a new custom element with the browser.
|
|
6040
|
+
* @param {String} name - The name of the custom element.
|
|
6041
|
+
* @param {Object} componentClass - The class to register as a custom element.
|
|
6042
|
+
* @returns {void}
|
|
6043
|
+
*/
|
|
6044
|
+
registerComponent(name, componentClass) {
|
|
6045
|
+
if (!customElements.get(name)) {
|
|
6046
|
+
customElements.define(name, class extends componentClass {});
|
|
6047
|
+
}
|
|
6048
|
+
}
|
|
6049
|
+
|
|
6050
|
+
/**
|
|
6051
|
+
* Finds and returns the closest HTML Element based on a selector.
|
|
6052
|
+
* @returns {void}
|
|
6053
|
+
*/
|
|
6054
|
+
closestElement(
|
|
6055
|
+
selector, // selector like in .closest()
|
|
6056
|
+
base = this, // extra functionality to skip a parent
|
|
6057
|
+
__Closest = (el, found = el && el.closest(selector)) =>
|
|
6058
|
+
!el || el === document || el === window
|
|
6059
|
+
? null // standard .closest() returns null for non-found selectors also
|
|
6060
|
+
: found
|
|
6061
|
+
? found // found a selector INside this element
|
|
6062
|
+
: __Closest(el.getRootNode().host) // recursion!! break out to parent DOM
|
|
6063
|
+
) {
|
|
6064
|
+
return __Closest(base);
|
|
6065
|
+
}
|
|
6066
|
+
/* eslint-enable jsdoc/require-param */
|
|
6067
|
+
|
|
6068
|
+
/**
|
|
6069
|
+
* 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.
|
|
6070
|
+
* @param {Object} elem - The element to check.
|
|
6071
|
+
* @param {String} tagName - The name of the Auro component to check for or add as an attribute.
|
|
6072
|
+
* @returns {void}
|
|
6073
|
+
*/
|
|
6074
|
+
handleComponentTagRename(elem, tagName) {
|
|
6075
|
+
const tag = tagName.toLowerCase();
|
|
6076
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6077
|
+
|
|
6078
|
+
if (elemTag !== tag) {
|
|
6079
|
+
elem.setAttribute(tag, true);
|
|
6080
|
+
}
|
|
6081
|
+
}
|
|
6082
|
+
|
|
6083
|
+
/**
|
|
6084
|
+
* Validates if an element is a specific Auro component.
|
|
6085
|
+
* @param {Object} elem - The element to validate.
|
|
6086
|
+
* @param {String} tagName - The name of the Auro component to check against.
|
|
6087
|
+
* @returns {Boolean} - Returns true if the element is the specified Auro component.
|
|
6088
|
+
*/
|
|
6089
|
+
elementMatch(elem, tagName) {
|
|
6090
|
+
const tag = tagName.toLowerCase();
|
|
6091
|
+
const elemTag = elem.tagName.toLowerCase();
|
|
6092
|
+
|
|
6093
|
+
return elemTag === tag || elem.hasAttribute(tag);
|
|
6094
|
+
}
|
|
6095
|
+
};
|
|
6096
|
+
|
|
6097
|
+
var styleCss$1 = i$2`: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}}`;
|
|
6098
|
+
|
|
6099
|
+
var colorCss$1 = i$2`: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-color-utility-navy-default, #265688)}:host([ondark]){--ds-auro-loader-color:var(--ds-color-utility-cyan-inverse, #a8e9f7)}:host([white]){--ds-auro-loader-color:var(--ds-color-utility-neutral-inverse, #ccd2db)}: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}`;
|
|
6100
|
+
|
|
6101
|
+
var tokensCss$1 = i$2`:host{--ds-auro-loader-background-color:currentcolor;--ds-auro-loader-border-color:currentcolor;--ds-auro-loader-color:currentcolor}`;
|
|
5799
6102
|
|
|
5800
6103
|
// Copyright (c) 2020 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
5801
6104
|
// See LICENSE in the project root for license information.
|
|
@@ -5820,7 +6123,7 @@ var tokensCss$1 = i$6`:host{--ds-auro-loader-background-color: currentcolor;--ds
|
|
|
5820
6123
|
*/
|
|
5821
6124
|
|
|
5822
6125
|
// build the component class
|
|
5823
|
-
class AuroLoader extends r
|
|
6126
|
+
class AuroLoader extends r {
|
|
5824
6127
|
constructor() {
|
|
5825
6128
|
super();
|
|
5826
6129
|
|
|
@@ -5874,9 +6177,9 @@ class AuroLoader extends r$4 {
|
|
|
5874
6177
|
|
|
5875
6178
|
static get styles() {
|
|
5876
6179
|
return [
|
|
5877
|
-
i$
|
|
5878
|
-
i$
|
|
5879
|
-
i$
|
|
6180
|
+
i$2`${styleCss$1}`,
|
|
6181
|
+
i$2`${colorCss$1}`,
|
|
6182
|
+
i$2`${tokensCss$1}`
|
|
5880
6183
|
];
|
|
5881
6184
|
}
|
|
5882
6185
|
|
|
@@ -5922,14 +6225,14 @@ class AuroLoader extends r$4 {
|
|
|
5922
6225
|
|
|
5923
6226
|
// function that renders the HTML and CSS into the scope of the component
|
|
5924
6227
|
render() {
|
|
5925
|
-
return x
|
|
5926
|
-
${this.defineTemplate().map((idx) => x
|
|
6228
|
+
return x`
|
|
6229
|
+
${this.defineTemplate().map((idx) => x`
|
|
5927
6230
|
<span part="element" class="loader node-${idx}"></span>
|
|
5928
6231
|
`)}
|
|
5929
6232
|
|
|
5930
6233
|
<div class="no-animation">Loading...</div>
|
|
5931
6234
|
|
|
5932
|
-
${this.ringworm ? x
|
|
6235
|
+
${this.ringworm ? x`
|
|
5933
6236
|
<svg part="element" class="circular" viewBox="25 25 50 50">
|
|
5934
6237
|
<circle class="path" cx="50" cy="50" r="20" fill="none"/>
|
|
5935
6238
|
</svg>`
|
|
@@ -5939,7 +6242,7 @@ class AuroLoader extends r$4 {
|
|
|
5939
6242
|
}
|
|
5940
6243
|
}
|
|
5941
6244
|
|
|
5942
|
-
var loaderVersion = '
|
|
6245
|
+
var loaderVersion = '4.0.0';
|
|
5943
6246
|
|
|
5944
6247
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
5945
6248
|
// See LICENSE in the project root for license information.
|
|
@@ -5975,10 +6278,20 @@ var loaderVersion = '3.1.1';
|
|
|
5975
6278
|
|
|
5976
6279
|
/* eslint-disable lit/no-invalid-html, lit/binding-positions */
|
|
5977
6280
|
|
|
5978
|
-
class AuroButton extends r
|
|
6281
|
+
class AuroButton extends r {
|
|
6282
|
+
|
|
6283
|
+
/**
|
|
6284
|
+
* Enables form association for this element.
|
|
6285
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/attachInternals
|
|
6286
|
+
* @returns {boolean} - Returns true to enable form association.
|
|
6287
|
+
*/
|
|
6288
|
+
static get formAssociated() {
|
|
6289
|
+
return true;
|
|
6290
|
+
}
|
|
5979
6291
|
|
|
5980
6292
|
constructor() {
|
|
5981
6293
|
super();
|
|
6294
|
+
|
|
5982
6295
|
this.autofocus = false;
|
|
5983
6296
|
this.disabled = false;
|
|
5984
6297
|
this.iconOnly = false;
|
|
@@ -5991,6 +6304,16 @@ class AuroButton extends r$4 {
|
|
|
5991
6304
|
this.slim = false;
|
|
5992
6305
|
this.fluid = false;
|
|
5993
6306
|
|
|
6307
|
+
// Support for HTML5 forms
|
|
6308
|
+
if (typeof this.attachInternals === 'function') {
|
|
6309
|
+
this.internals = this.attachInternals();
|
|
6310
|
+
} else {
|
|
6311
|
+
this.internals = null;
|
|
6312
|
+
|
|
6313
|
+
// eslint-disable-next-line no-console
|
|
6314
|
+
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.');
|
|
6315
|
+
}
|
|
6316
|
+
|
|
5994
6317
|
/**
|
|
5995
6318
|
* Generate unique names for dependency components.
|
|
5996
6319
|
*/
|
|
@@ -6089,7 +6412,7 @@ class AuroButton extends r$4 {
|
|
|
6089
6412
|
*
|
|
6090
6413
|
*/
|
|
6091
6414
|
static register(name = "auro-button") {
|
|
6092
|
-
AuroLibraryRuntimeUtils$
|
|
6415
|
+
AuroLibraryRuntimeUtils$2.prototype.registerComponent(name, AuroButton);
|
|
6093
6416
|
}
|
|
6094
6417
|
|
|
6095
6418
|
/**
|
|
@@ -6131,6 +6454,16 @@ class AuroButton extends r$4 {
|
|
|
6131
6454
|
this.notifyReady();
|
|
6132
6455
|
}
|
|
6133
6456
|
|
|
6457
|
+
surfaceSubmitEvent() {
|
|
6458
|
+
if (this.form) {
|
|
6459
|
+
this.form.requestSubmit();
|
|
6460
|
+
}
|
|
6461
|
+
}
|
|
6462
|
+
|
|
6463
|
+
get form() {
|
|
6464
|
+
return this.internals ? this.internals.form : null;
|
|
6465
|
+
}
|
|
6466
|
+
|
|
6134
6467
|
render() {
|
|
6135
6468
|
const classes = {
|
|
6136
6469
|
'util_insetLg--squish': true,
|
|
@@ -6143,27 +6476,27 @@ class AuroButton extends r$4 {
|
|
|
6143
6476
|
'loading': this.loading
|
|
6144
6477
|
};
|
|
6145
6478
|
|
|
6146
|
-
return u$
|
|
6479
|
+
return u$3`
|
|
6147
6480
|
<button
|
|
6148
6481
|
part="button"
|
|
6149
|
-
aria-label="${o$
|
|
6150
|
-
aria-labelledby="${o$
|
|
6482
|
+
aria-label="${o$2(this.arialabel ? this.arialabel : undefined)}"
|
|
6483
|
+
aria-labelledby="${o$2(this.arialabelledby ? this.arialabelledby : undefined)}"
|
|
6151
6484
|
?autofocus="${this.autofocus}"
|
|
6152
|
-
class="${e$
|
|
6485
|
+
class="${e$2(classes)}"
|
|
6153
6486
|
?disabled="${this.disabled || this.loading}"
|
|
6154
6487
|
?onDark="${this.onDark}"
|
|
6155
|
-
title="${o$
|
|
6156
|
-
name="${o$
|
|
6157
|
-
type="${o$
|
|
6158
|
-
variant="${o$
|
|
6159
|
-
.value="${o$
|
|
6160
|
-
@click="${
|
|
6488
|
+
title="${o$2(this.title ? this.title : undefined)}"
|
|
6489
|
+
name="${o$2(this.name ? this.name : undefined)}"
|
|
6490
|
+
type="${o$2(this.type ? this.type : undefined)}"
|
|
6491
|
+
variant="${o$2(this.variant ? this.variant : undefined)}"
|
|
6492
|
+
.value="${o$2(this.value ? this.value : undefined)}"
|
|
6493
|
+
@click="${this.type === 'submit' ? this.surfaceSubmitEvent : undefined}"
|
|
6161
6494
|
>
|
|
6162
|
-
${o$
|
|
6495
|
+
${o$2(this.loading ? u$3`<${this.loaderTag} pulse part="loader"></${this.loaderTag}>` : undefined)}
|
|
6163
6496
|
|
|
6164
6497
|
<span class="contentWrapper">
|
|
6165
6498
|
<span class="textSlot" part="text">
|
|
6166
|
-
${this.iconOnly ? undefined : u$
|
|
6499
|
+
${this.iconOnly ? undefined : u$3`<slot></slot>`}
|
|
6167
6500
|
</span>
|
|
6168
6501
|
|
|
6169
6502
|
<span part="icon">
|
|
@@ -6177,37 +6510,11 @@ class AuroButton extends r$4 {
|
|
|
6177
6510
|
|
|
6178
6511
|
var buttonVersion = '8.2.2';
|
|
6179
6512
|
|
|
6180
|
-
|
|
6181
|
-
* @license
|
|
6182
|
-
* Copyright 2019 Google LLC
|
|
6183
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
6184
|
-
*/
|
|
6185
|
-
const t$1=globalThis,e$2=t$1.ShadowRoot&&(void 0===t$1.ShadyCSS||t$1.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s$1=Symbol(),o$2=new WeakMap;let n$2 = class n{constructor(t,e,o){if(this._$cssResult$=true,o!==s$1)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e;}get styleSheet(){let t=this.o;const s=this.t;if(e$2&&void 0===t){const e=void 0!==s&&1===s.length;e&&(t=o$2.get(s)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&o$2.set(s,t));}return t}toString(){return this.cssText}};const r$3=t=>new n$2("string"==typeof t?t:t+"",void 0,s$1),i$3=(t,...e)=>{const o=1===t.length?t[0]:e.reduce(((e,s,o)=>e+(t=>{if(true===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+t[o+1]),t[0]);return new n$2(o,t,s$1)},S$1=(s,o)=>{if(e$2)s.adoptedStyleSheets=o.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const e of o){const o=document.createElement("style"),n=t$1.litNonce;void 0!==n&&o.setAttribute("nonce",n),o.textContent=e.cssText,s.appendChild(o);}},c$2=e$2?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return r$3(e)})(t):t;
|
|
6186
|
-
|
|
6187
|
-
/**
|
|
6188
|
-
* @license
|
|
6189
|
-
* Copyright 2017 Google LLC
|
|
6190
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
6191
|
-
*/const{is:i$2,defineProperty:e$1,getOwnPropertyDescriptor:r$2,getOwnPropertyNames:h$1,getOwnPropertySymbols:o$1,getPrototypeOf:n$1}=Object,a$1=globalThis,c$1=a$1.trustedTypes,l$1=c$1?c$1.emptyScript:"",p$1=a$1.reactiveElementPolyfillSupport,d$1=(t,s)=>t,u$1={toAttribute(t,s){switch(s){case Boolean:t=t?l$1:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t);}return t},fromAttribute(t,s){let i=t;switch(s){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t);}catch(t){i=null;}}return i}},f$1=(t,s)=>!i$2(t,s),y$1={attribute:true,type:String,converter:u$1,reflect:false,hasChanged:f$1};Symbol.metadata??=Symbol("metadata"),a$1.litPropertyMetadata??=new WeakMap;class b extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t);}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,s=y$1){if(s.state&&(s.attribute=false),this._$Ei(),this.elementProperties.set(t,s),!s.noAccessor){const i=Symbol(),r=this.getPropertyDescriptor(t,i,s);void 0!==r&&e$1(this.prototype,t,r);}}static getPropertyDescriptor(t,s,i){const{get:e,set:h}=r$2(this.prototype,t)??{get(){return this[s]},set(t){this[s]=t;}};return {get(){return e?.call(this)},set(s){const r=e?.call(this);h.call(this,s),this.requestUpdate(t,r,i);},configurable:true,enumerable:true}}static getPropertyOptions(t){return this.elementProperties.get(t)??y$1}static _$Ei(){if(this.hasOwnProperty(d$1("elementProperties")))return;const t=n$1(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties);}static finalize(){if(this.hasOwnProperty(d$1("finalized")))return;if(this.finalized=true,this._$Ei(),this.hasOwnProperty(d$1("properties"))){const t=this.properties,s=[...h$1(t),...o$1(t)];for(const i of s)this.createProperty(i,t[i]);}const t=this[Symbol.metadata];if(null!==t){const s=litPropertyMetadata.get(t);if(void 0!==s)for(const[t,i]of s)this.elementProperties.set(t,i);}this._$Eh=new Map;for(const[t,s]of this.elementProperties){const i=this._$Eu(t,s);void 0!==i&&this._$Eh.set(i,t);}this.elementStyles=this.finalizeStyles(this.styles);}static finalizeStyles(s){const i=[];if(Array.isArray(s)){const e=new Set(s.flat(1/0).reverse());for(const s of e)i.unshift(c$2(s));}else void 0!==s&&i.push(c$2(s));return i}static _$Eu(t,s){const i=s.attribute;return false===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=false,this.hasUpdated=false,this._$Em=null,this._$Ev();}_$Ev(){this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)));}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.();}removeController(t){this._$EO?.delete(t);}_$E_(){const t=new Map,s=this.constructor.elementProperties;for(const i of s.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t);}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return S$1(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(true),this._$EO?.forEach((t=>t.hostConnected?.()));}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach((t=>t.hostDisconnected?.()));}attributeChangedCallback(t,s,i){this._$AK(t,i);}_$EC(t,s){const i=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,i);if(void 0!==e&&true===i.reflect){const r=(void 0!==i.converter?.toAttribute?i.converter:u$1).toAttribute(s,i.type);this._$Em=t,null==r?this.removeAttribute(e):this.setAttribute(e,r),this._$Em=null;}}_$AK(t,s){const i=this.constructor,e=i._$Eh.get(t);if(void 0!==e&&this._$Em!==e){const t=i.getPropertyOptions(e),r="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:u$1;this._$Em=e,this[e]=r.fromAttribute(s,t.type),this._$Em=null;}}requestUpdate(t,s,i){if(void 0!==t){if(i??=this.constructor.getPropertyOptions(t),!(i.hasChanged??f$1)(this[t],s))return;this.P(t,s,i);} false===this.isUpdatePending&&(this._$ES=this._$ET());}P(t,s,i){this._$AL.has(t)||this._$AL.set(t,s),true===i.reflect&&this._$Em!==t&&(this._$Ej??=new Set).add(t);}async _$ET(){this.isUpdatePending=true;try{await this._$ES;}catch(t){Promise.reject(t);}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,s]of this._$Ep)this[t]=s;this._$Ep=void 0;}const t=this.constructor.elementProperties;if(t.size>0)for(const[s,i]of t) true!==i.wrapped||this._$AL.has(s)||void 0===this[s]||this.P(s,this[s],i);}let t=false;const s=this._$AL;try{t=this.shouldUpdate(s),t?(this.willUpdate(s),this._$EO?.forEach((t=>t.hostUpdate?.())),this.update(s)):this._$EU();}catch(s){throw t=false,this._$EU(),s}t&&this._$AE(s);}willUpdate(t){}_$AE(t){this._$EO?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=true,this.firstUpdated(t)),this.updated(t);}_$EU(){this._$AL=new Map,this.isUpdatePending=false;}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return true}update(t){this._$Ej&&=this._$Ej.forEach((t=>this._$EC(t,this[t]))),this._$EU();}updated(t){}firstUpdated(t){}}b.elementStyles=[],b.shadowRootOptions={mode:"open"},b[d$1("elementProperties")]=new Map,b[d$1("finalized")]=new Map,p$1?.({ReactiveElement:b}),(a$1.reactiveElementVersions??=[]).push("2.0.4");
|
|
6513
|
+
var colorCss = i$2`:host([error]){--ds-auro-helptext-color: var(--ds-color-text-error-default, #cc1816)}.helptext-wrapper{color:var(--ds-auro-helptext-color)}`;
|
|
6192
6514
|
|
|
6193
|
-
|
|
6194
|
-
* @license
|
|
6195
|
-
* Copyright 2017 Google LLC
|
|
6196
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
6197
|
-
*/
|
|
6198
|
-
const t=globalThis,i$1=t.trustedTypes,s=i$1?i$1.createPolicy("lit-html",{createHTML:t=>t}):void 0,e="$lit$",h=`lit$${Math.random().toFixed(9).slice(2)}$`,o="?"+h,n=`<${o}>`,r$1=document,l=()=>r$1.createComment(""),c=t=>null===t||"object"!=typeof t&&"function"!=typeof t,a=Array.isArray,u=t=>a(t)||"function"==typeof t?.[Symbol.iterator],d="[ \t\n\f\r]",f=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,v=/-->/g,_=/>/g,m=RegExp(`>|${d}(?:([^\\s"'>=/]+)(${d}*=${d}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),p=/'/g,g=/"/g,$=/^(?:script|style|textarea|title)$/i,y=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),x=y(1),T=Symbol.for("lit-noChange"),E=Symbol.for("lit-nothing"),A=new WeakMap,C=r$1.createTreeWalker(r$1,129);function P(t,i){if(!a(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==s?s.createHTML(i):i}const V=(t,i)=>{const s=t.length-1,o=[];let r,l=2===i?"<svg>":3===i?"<math>":"",c=f;for(let i=0;i<s;i++){const s=t[i];let a,u,d=-1,y=0;for(;y<s.length&&(c.lastIndex=y,u=c.exec(s),null!==u);)y=c.lastIndex,c===f?"!--"===u[1]?c=v:void 0!==u[1]?c=_:void 0!==u[2]?($.test(u[2])&&(r=RegExp("</"+u[2],"g")),c=m):void 0!==u[3]&&(c=m):c===m?">"===u[0]?(c=r??f,d=-1):void 0===u[1]?d=-2:(d=c.lastIndex-u[2].length,a=u[1],c=void 0===u[3]?m:'"'===u[3]?g:p):c===g||c===p?c=m:c===v||c===_?c=f:(c=m,r=void 0);const x=c===m&&t[i+1].startsWith("/>")?" ":"";l+=c===f?s+n:d>=0?(o.push(a),s.slice(0,d)+e+s.slice(d)+h+x):s+h+(-2===d?i:x);}return [P(t,l+(t[s]||"<?>")+(2===i?"</svg>":3===i?"</math>":"")),o]};class N{constructor({strings:t,_$litType$:s},n){let r;this.parts=[];let c=0,a=0;const u=t.length-1,d=this.parts,[f,v]=V(t,s);if(this.el=N.createElement(f,n),C.currentNode=this.el.content,2===s||3===s){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes);}for(;null!==(r=C.nextNode())&&d.length<u;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(e)){const i=v[a++],s=r.getAttribute(t).split(h),e=/([.?@])?(.*)/.exec(i);d.push({type:1,index:c,name:e[2],strings:s,ctor:"."===e[1]?H:"?"===e[1]?I:"@"===e[1]?L:k}),r.removeAttribute(t);}else t.startsWith(h)&&(d.push({type:6,index:c}),r.removeAttribute(t));if($.test(r.tagName)){const t=r.textContent.split(h),s=t.length-1;if(s>0){r.textContent=i$1?i$1.emptyScript:"";for(let i=0;i<s;i++)r.append(t[i],l()),C.nextNode(),d.push({type:2,index:++c});r.append(t[s],l());}}}else if(8===r.nodeType)if(r.data===o)d.push({type:2,index:c});else {let t=-1;for(;-1!==(t=r.data.indexOf(h,t+1));)d.push({type:7,index:c}),t+=h.length-1;}c++;}}static createElement(t,i){const s=r$1.createElement("template");return s.innerHTML=t,s}}function S(t,i,s=t,e){if(i===T)return i;let h=void 0!==e?s._$Co?.[e]:s._$Cl;const o=c(i)?void 0:i._$litDirective$;return h?.constructor!==o&&(h?._$AO?.(false),void 0===o?h=void 0:(h=new o(t),h._$AT(t,s,e)),void 0!==e?(s._$Co??=[])[e]=h:s._$Cl=h),void 0!==h&&(i=S(t,h._$AS(t,i.values),h,e)),i}class M{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i;}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:i},parts:s}=this._$AD,e=(t?.creationScope??r$1).importNode(i,true);C.currentNode=e;let h=C.nextNode(),o=0,n=0,l=s[0];for(;void 0!==l;){if(o===l.index){let i;2===l.type?i=new R(h,h.nextSibling,this,t):1===l.type?i=new l.ctor(h,l.name,l.strings,this,t):6===l.type&&(i=new z(h,this,t)),this._$AV.push(i),l=s[++n];}o!==l?.index&&(h=C.nextNode(),o++);}return C.currentNode=r$1,e}p(t){let i=0;for(const s of this._$AV) void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++;}}class R{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,i,s,e){this.type=2,this._$AH=E,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cv=e?.isConnected??true;}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t?.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=S(this,t,i),c(t)?t===E||null==t||""===t?(this._$AH!==E&&this._$AR(),this._$AH=E):t!==this._$AH&&t!==T&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):u(t)?this.k(t):this._(t);}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t));}_(t){this._$AH!==E&&c(this._$AH)?this._$AA.nextSibling.data=t:this.T(r$1.createTextNode(t)),this._$AH=t;}$(t){const{values:i,_$litType$:s}=t,e="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=N.createElement(P(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===e)this._$AH.p(i);else {const t=new M(e,this),s=t.u(this.options);t.p(i),this.T(s),this._$AH=t;}}_$AC(t){let i=A.get(t.strings);return void 0===i&&A.set(t.strings,i=new N(t)),i}k(t){a(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const h of t)e===i.length?i.push(s=new R(this.O(l()),this.O(l()),this,this.options)):s=i[e],s._$AI(h),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e);}_$AR(t=this._$AA.nextSibling,i){for(this._$AP?.(false,true,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i;}}setConnected(t){ void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t));}}class k{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,i,s,e,h){this.type=1,this._$AH=E,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=h,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=E;}_$AI(t,i=this,s,e){const h=this.strings;let o=false;if(void 0===h)t=S(this,t,i,0),o=!c(t)||t!==this._$AH&&t!==T,o&&(this._$AH=t);else {const e=t;let n,r;for(t=h[0],n=0;n<h.length-1;n++)r=S(this,e[s+n],i,n),r===T&&(r=this._$AH[n]),o||=!c(r)||r!==this._$AH[n],r===E?t=E:t!==E&&(t+=(r??"")+h[n+1]),this._$AH[n]=r;}o&&!e&&this.j(t);}j(t){t===E?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"");}}class H extends k{constructor(){super(...arguments),this.type=3;}j(t){this.element[this.name]=t===E?void 0:t;}}class I extends k{constructor(){super(...arguments),this.type=4;}j(t){this.element.toggleAttribute(this.name,!!t&&t!==E);}}class L extends k{constructor(t,i,s,e,h){super(t,i,s,e,h),this.type=5;}_$AI(t,i=this){if((t=S(this,t,i,0)??E)===T)return;const s=this._$AH,e=t===E&&s!==E||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,h=t!==E&&(s===E||e);e&&this.element.removeEventListener(this.name,this,s),h&&this.element.addEventListener(this.name,this,t),this._$AH=t;}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t);}}class z{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s;}get _$AU(){return this._$AM._$AU}_$AI(t){S(this,t);}}const j=t.litHtmlPolyfillSupport;j?.(N,R),(t.litHtmlVersions??=[]).push("3.2.1");const B=(t,i,s)=>{const e=s?.renderBefore??i;let h=e._$litPart$;if(void 0===h){const t=s?.renderBefore??null;e._$litPart$=h=new R(i.insertBefore(l(),t),t,void 0,s??{});}return h._$AI(t),h};
|
|
6515
|
+
var styleCss = i$2`.helptext-wrapper{display:none;font-size:var(--ds-text-body-size-xs, 0.75rem);line-height:var(--ds-size-200, 1rem)}:host([large]) .helptext-wrapper{font-size:var(--ds-text-body-size-default, 1rem)}.helptext-wrapper[visible]{display:block}::slotted(*:not(:empty)){margin-top:var(--ds-size-50, 0.25rem);margin-bottom:0}::slotted(p){margin-block:0}`;
|
|
6199
6516
|
|
|
6200
|
-
|
|
6201
|
-
* @license
|
|
6202
|
-
* Copyright 2017 Google LLC
|
|
6203
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
6204
|
-
*/class r extends b{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0;}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const s=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=B(s,this.renderRoot,this.renderOptions);}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(true);}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(false);}render(){return T}}r._$litElement$=true,r["finalized"]=true,globalThis.litElementHydrateSupport?.({LitElement:r});const i=globalThis.litElementPolyfillSupport;i?.({LitElement:r});(globalThis.litElementVersions??=[]).push("4.1.1");
|
|
6205
|
-
|
|
6206
|
-
var colorCss = i$3`:host([error]){--ds-auro-helptext-color: var(--ds-color-text-error-default, #cc1816)}.helptext-wrapper{color:var(--ds-auro-helptext-color)}`;
|
|
6207
|
-
|
|
6208
|
-
var styleCss = i$3`.helptext-wrapper{display:none;font-size:var(--ds-text-body-size-xs, 0.75rem);line-height:var(--ds-size-200, 1rem)}:host([large]) .helptext-wrapper{font-size:var(--ds-text-body-size-default, 1rem)}.helptext-wrapper[visible]{display:block}::slotted(*:not(:empty)){margin-top:var(--ds-size-50, 0.25rem);margin-bottom:0}::slotted(p){margin-block:0}`;
|
|
6209
|
-
|
|
6210
|
-
var tokensCss = i$3`:host{--ds-auro-helptext-color: var(--ds-color-text-tertiary-default, #6a717c)}`;
|
|
6517
|
+
var tokensCss = i$2`:host{--ds-auro-helptext-color: var(--ds-color-text-tertiary-default, #6a717c)}`;
|
|
6211
6518
|
|
|
6212
6519
|
// Copyright (c) Alaska Air. All right reserved. Licensed under the Apache-2.0 license
|
|
6213
6520
|
// See LICENSE in the project root for license information.
|
|
@@ -6414,22 +6721,22 @@ class AuroInput extends BaseInput {
|
|
|
6414
6721
|
/**
|
|
6415
6722
|
* Generate unique names for dependency components.
|
|
6416
6723
|
*/
|
|
6417
|
-
const versioning = new AuroDependencyVersioning();
|
|
6724
|
+
const versioning = new AuroDependencyVersioning$1();
|
|
6418
6725
|
|
|
6419
6726
|
/**
|
|
6420
6727
|
* @private
|
|
6421
6728
|
*/
|
|
6422
|
-
this.iconTag = versioning.generateTag('auro-icon', iconVersion, AuroIcon);
|
|
6729
|
+
this.iconTag = versioning.generateTag('auro-formkit-input-icon', iconVersion, AuroIcon);
|
|
6423
6730
|
|
|
6424
6731
|
/**
|
|
6425
6732
|
* @private
|
|
6426
6733
|
*/
|
|
6427
|
-
this.buttonTag = versioning.generateTag('auro-button', buttonVersion, AuroButton);
|
|
6734
|
+
this.buttonTag = versioning.generateTag('auro-formkit-input-button', buttonVersion, AuroButton);
|
|
6428
6735
|
|
|
6429
6736
|
/**
|
|
6430
6737
|
* @private
|
|
6431
6738
|
*/
|
|
6432
|
-
this.helpTextTag = versioning.generateTag('auro-helptext', helpTextVersion, AuroHelpText);
|
|
6739
|
+
this.helpTextTag = versioning.generateTag('auro-formkit-input-helptext', helpTextVersion, AuroHelpText);
|
|
6433
6740
|
}
|
|
6434
6741
|
|
|
6435
6742
|
/**
|
|
@@ -6441,7 +6748,7 @@ class AuroInput extends BaseInput {
|
|
|
6441
6748
|
*
|
|
6442
6749
|
*/
|
|
6443
6750
|
static register(name = "auro-input") {
|
|
6444
|
-
AuroLibraryRuntimeUtils$
|
|
6751
|
+
AuroLibraryRuntimeUtils$4.prototype.registerComponent(name, AuroInput);
|
|
6445
6752
|
}
|
|
6446
6753
|
|
|
6447
6754
|
/**
|
|
@@ -6466,7 +6773,7 @@ class AuroInput extends BaseInput {
|
|
|
6466
6773
|
'withValue': this.value && this.value.length > 0
|
|
6467
6774
|
};
|
|
6468
6775
|
|
|
6469
|
-
return u$
|
|
6776
|
+
return u$3`
|
|
6470
6777
|
<div class="wrapper" part="wrapper">
|
|
6471
6778
|
<div class="main">
|
|
6472
6779
|
<div class="typeIcon">
|
|
@@ -6475,7 +6782,7 @@ class AuroInput extends BaseInput {
|
|
|
6475
6782
|
<!-- The repeat() method is used below in order to force auro-icon to re-render when the name value is updated.
|
|
6476
6783
|
This should be cleaned up when auro-icon issue #31 is resolved. -->
|
|
6477
6784
|
${this.inputIconName
|
|
6478
|
-
? c$
|
|
6785
|
+
? c$2([this.inputIconName], (val) => val, (name) => u$3`
|
|
6479
6786
|
<${this.iconTag}
|
|
6480
6787
|
class="accentIcon"
|
|
6481
6788
|
category="payment"
|
|
@@ -6487,7 +6794,7 @@ class AuroInput extends BaseInput {
|
|
|
6487
6794
|
}
|
|
6488
6795
|
|
|
6489
6796
|
${this.type === 'date'
|
|
6490
|
-
? u$
|
|
6797
|
+
? u$3`
|
|
6491
6798
|
<${this.iconTag}
|
|
6492
6799
|
class="accentIcon"
|
|
6493
6800
|
category="interface"
|
|
@@ -6498,7 +6805,7 @@ class AuroInput extends BaseInput {
|
|
|
6498
6805
|
: undefined
|
|
6499
6806
|
}
|
|
6500
6807
|
</div>
|
|
6501
|
-
<label for=${this.id} class="${e$
|
|
6808
|
+
<label for=${this.id} class="${e$2(labelClasses)}" part="label">
|
|
6502
6809
|
<slot name="label">
|
|
6503
6810
|
${this.label}
|
|
6504
6811
|
</slot>
|
|
@@ -6509,23 +6816,23 @@ class AuroInput extends BaseInput {
|
|
|
6509
6816
|
@focusin="${this.handleFocusin}"
|
|
6510
6817
|
@blur="${this.handleBlur}"
|
|
6511
6818
|
id="${this.id}"
|
|
6512
|
-
name="${o$
|
|
6819
|
+
name="${o$2(this.name)}"
|
|
6513
6820
|
type="${this.type === 'password' && this.showPassword ? 'text' : this.getInputType(this.type)}"
|
|
6514
|
-
pattern="${o$
|
|
6515
|
-
maxlength="${o$
|
|
6516
|
-
minlength="${o$
|
|
6517
|
-
inputMode="${o$
|
|
6821
|
+
pattern="${o$2(this.definePattern())}"
|
|
6822
|
+
maxlength="${o$2(this.maxLength ? this.maxLength : undefined)}"
|
|
6823
|
+
minlength="${o$2(this.minLength ? this.minLength : undefined)}"
|
|
6824
|
+
inputMode="${o$2(this.inputMode ? this.inputMode : undefined)}"
|
|
6518
6825
|
?required="${this.required}"
|
|
6519
6826
|
?disabled="${this.disabled}"
|
|
6520
6827
|
aria-describedby="${this.uniqueId}"
|
|
6521
6828
|
aria-invalid="${this.validity !== 'valid'}"
|
|
6522
6829
|
placeholder=${this.getPlaceholder()}
|
|
6523
|
-
lang="${o$
|
|
6830
|
+
lang="${o$2(this.lang)}"
|
|
6524
6831
|
?activeLabel="${this.activeLabel}"
|
|
6525
|
-
spellcheck="${o$
|
|
6526
|
-
autocorrect="${o$
|
|
6527
|
-
autocapitalize="${o$
|
|
6528
|
-
autocomplete="${o$
|
|
6832
|
+
spellcheck="${o$2(this.spellcheck ? this.spellcheck : undefined)}"
|
|
6833
|
+
autocorrect="${o$2(this.autocorrect ? this.autocorrect : undefined)}"
|
|
6834
|
+
autocapitalize="${o$2(this.autocapitalize ? this.autocapitalize : undefined)}"
|
|
6835
|
+
autocomplete="${o$2(this.autocomplete ? this.autocomplete : undefined)}"
|
|
6529
6836
|
part="input"
|
|
6530
6837
|
/>
|
|
6531
6838
|
</div>
|
|
@@ -6533,7 +6840,7 @@ class AuroInput extends BaseInput {
|
|
|
6533
6840
|
class="notificationIcons"
|
|
6534
6841
|
part="notificationIcons"
|
|
6535
6842
|
?hasValue="${this.hasValue}">
|
|
6536
|
-
${this.validity && this.validity !== 'valid' ? u$
|
|
6843
|
+
${this.validity && this.validity !== 'valid' ? u$3`
|
|
6537
6844
|
<div class="notification alertNotification">
|
|
6538
6845
|
<${this.iconTag}
|
|
6539
6846
|
category="alert"
|
|
@@ -6542,8 +6849,8 @@ class AuroInput extends BaseInput {
|
|
|
6542
6849
|
</${this.iconTag}>
|
|
6543
6850
|
</div>
|
|
6544
6851
|
` : undefined}
|
|
6545
|
-
${this.hasValue ? u$
|
|
6546
|
-
${this.type === 'password' ? u$
|
|
6852
|
+
${this.hasValue ? u$3`
|
|
6853
|
+
${this.type === 'password' ? u$3`
|
|
6547
6854
|
<div class="notification">
|
|
6548
6855
|
<${this.buttonTag}
|
|
6549
6856
|
variant="flat"
|
|
@@ -6566,7 +6873,7 @@ class AuroInput extends BaseInput {
|
|
|
6566
6873
|
</${this.buttonTag}>
|
|
6567
6874
|
</div>
|
|
6568
6875
|
` : undefined}
|
|
6569
|
-
${!this.disabled && !this.readonly ? u$
|
|
6876
|
+
${!this.disabled && !this.readonly ? u$3`
|
|
6570
6877
|
<div class="notification">
|
|
6571
6878
|
<${this.buttonTag}
|
|
6572
6879
|
variant="flat"
|
|
@@ -6587,14 +6894,14 @@ class AuroInput extends BaseInput {
|
|
|
6587
6894
|
</div>
|
|
6588
6895
|
<!-- Help text and error message template -->
|
|
6589
6896
|
${!this.validity || this.validity === undefined || this.validity === 'valid'
|
|
6590
|
-
? u$
|
|
6897
|
+
? u$3`
|
|
6591
6898
|
<${this.helpTextTag}>
|
|
6592
6899
|
<p id="${this.uniqueId}" part="helpText">
|
|
6593
6900
|
<slot name="helptext">${this.getHelpText()}</slot>
|
|
6594
6901
|
</p>
|
|
6595
6902
|
</${this.helpTextTag}>
|
|
6596
6903
|
`
|
|
6597
|
-
: u$
|
|
6904
|
+
: u$3`
|
|
6598
6905
|
<${this.helpTextTag} error>
|
|
6599
6906
|
<p id="${this.uniqueId}" role="alert" aria-live="assertive" part="helpText">
|
|
6600
6907
|
${this.errorMessage}
|