@aurodesignsystem/auro-skeleton 2.0.1 → 2.1.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 +16 -0
- package/README.md +116 -38
- package/demo/apiExamples.md +81 -0
- package/demo/demo.md +83 -94
- package/dist/auro-skeleton.d.ts +12 -0
- package/dist/auro-skeleton.d.ts.map +1 -0
- package/dist/auro-skeleton__bundled.js +72 -144
- package/dist/style-css.d.ts +3 -0
- package/dist/style-css.d.ts.map +1 -0
- package/index.js +15 -1
- package/package.json +66 -77
- package/packageScripts/{postinstall.js → postinstall.mjs} +4 -2
- package/{dist → src}/auro-skeleton.js +4 -8
- package/src/style-css.js +2 -0
- package/NOTICE +0 -2
- package/demo/style.css.map +0 -1
- package/dist/auro-skeleton__bundled.es5.js +0 -90
- package/dist/style-css.js +0 -3
- package/dist/style-fixed-css.js +0 -3
|
@@ -1,158 +1,86 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* http://polymer.github.io/LICENSE.txt
|
|
6
|
-
* The complete set of authors may be found at
|
|
7
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
8
|
-
* The complete set of contributors may be found at
|
|
9
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
10
|
-
* Code distributed by Google as part of the polymer project is also
|
|
11
|
-
* subject to an additional IP rights grant found at
|
|
12
|
-
* http://polymer.github.io/PATENTS.txt
|
|
3
|
+
* Copyright 2019 Google LLC
|
|
4
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
13
5
|
*/
|
|
14
|
-
const t=
|
|
6
|
+
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$2=Symbol(),o$2=new WeakMap;let n$2 = class n{constructor(t,e,o){if(this._$cssResult$=!0,o!==s$2)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$2),i$2=(t,...e)=>{const o=1===t.length?t[0]:e.reduce(((e,s,o)=>e+(t=>{if(!0===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$2)},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;
|
|
7
|
+
|
|
15
8
|
/**
|
|
16
9
|
* @license
|
|
17
|
-
* Copyright
|
|
18
|
-
*
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
22
|
-
* The complete set of contributors may be found at
|
|
23
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
24
|
-
* Code distributed by Google as part of the polymer project is also
|
|
25
|
-
* subject to an additional IP rights grant found at
|
|
26
|
-
* http://polymer.github.io/PATENTS.txt
|
|
27
|
-
*/
|
|
28
|
-
class m{constructor(t,e,s){this.__parts=[],this.template=t,this.processor=e,this.options=s}update(t){let e=0;for(const s of this.__parts)void 0!==s&&s.setValue(t[e]),e++;for(const t of this.__parts)void 0!==t&&t.commit()}_clone(){const t=s?this.template.element.content.cloneNode(!0):document.importNode(this.template.element.content,!0),e=[],i=this.template.parts,n=document.createTreeWalker(t,133,null,!1);let r,o=0,a=0,d=n.nextNode();for(;o<i.length;)if(r=i[o],u(r)){for(;a<r.index;)a++,"TEMPLATE"===d.nodeName&&(e.push(d),n.currentNode=d.content),null===(d=n.nextNode())&&(n.currentNode=e.pop(),d=n.nextNode());if("node"===r.type){const t=this.processor.handleTextExpression(this.options);t.insertAfterNode(d.previousSibling),this.__parts.push(t)}else this.__parts.push(...this.processor.handleAttributeExpressions(d,r.name,r.strings,this.options));o++}else this.__parts.push(void 0),o++;return s&&(document.adoptNode(t),customElements.upgrade(t)),t}}
|
|
29
|
-
/**
|
|
30
|
-
* @license
|
|
31
|
-
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
32
|
-
* This code may only be used under the BSD style license found at
|
|
33
|
-
* http://polymer.github.io/LICENSE.txt
|
|
34
|
-
* The complete set of authors may be found at
|
|
35
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
36
|
-
* The complete set of contributors may be found at
|
|
37
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
38
|
-
* Code distributed by Google as part of the polymer project is also
|
|
39
|
-
* subject to an additional IP rights grant found at
|
|
40
|
-
* http://polymer.github.io/PATENTS.txt
|
|
41
|
-
*/const _=window.trustedTypes&&trustedTypes.createPolicy("lit-html",{createHTML:t=>t}),f=` ${o} `;class v{constructor(t,e,s,i){this.strings=t,this.values=e,this.type=s,this.processor=i}getHTML(){const t=this.strings.length-1;let e="",s=!1;for(let i=0;i<t;i++){const t=this.strings[i],n=t.lastIndexOf("\x3c!--");s=(n>-1||s)&&-1===t.indexOf("--\x3e",n+1);const r=p.exec(t);e+=null===r?t+(s?f:a):t.substr(0,r.index)+r[1]+r[2]+"$lit$"+r[3]+o}return e+=this.strings[t],e}getTemplateElement(){const t=document.createElement("template");let e=this.getHTML();return void 0!==_&&(e=_.createHTML(e)),t.innerHTML=e,t}}
|
|
42
|
-
/**
|
|
43
|
-
* @license
|
|
44
|
-
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
45
|
-
* This code may only be used under the BSD style license found at
|
|
46
|
-
* http://polymer.github.io/LICENSE.txt
|
|
47
|
-
* The complete set of authors may be found at
|
|
48
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
49
|
-
* The complete set of contributors may be found at
|
|
50
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
51
|
-
* Code distributed by Google as part of the polymer project is also
|
|
52
|
-
* subject to an additional IP rights grant found at
|
|
53
|
-
* http://polymer.github.io/PATENTS.txt
|
|
54
|
-
*/const y=t=>null===t||!("object"==typeof t||"function"==typeof t),g=t=>Array.isArray(t)||!(!t||!t[Symbol.iterator]);class b{constructor(t,e,s){this.dirty=!0,this.element=t,this.name=e,this.strings=s,this.parts=[];for(let t=0;t<s.length-1;t++)this.parts[t]=this._createPart()}_createPart(){return new w(this)}_getValue(){const t=this.strings,e=t.length-1,s=this.parts;if(1===e&&""===t[0]&&""===t[1]){const t=s[0].value;if("symbol"==typeof t)return String(t);if("string"==typeof t||!g(t))return t}let i="";for(let n=0;n<e;n++){i+=t[n];const e=s[n];if(void 0!==e){const t=e.value;if(y(t)||!g(t))i+="string"==typeof t?t:String(t);else for(const e of t)i+="string"==typeof e?e:String(e)}}return i+=t[e],i}commit(){this.dirty&&(this.dirty=!1,this.element.setAttribute(this.name,this._getValue()))}}class w{constructor(t){this.value=void 0,this.committer=t}setValue(t){t===n||y(t)&&t===this.value||(this.value=t,e(t)||(this.committer.dirty=!0))}commit(){for(;e(this.value);){const t=this.value;this.value=n,t(this)}this.value!==n&&this.committer.commit()}}class S{constructor(t){this.value=void 0,this.__pendingValue=void 0,this.options=t}appendInto(t){this.startNode=t.appendChild(h()),this.endNode=t.appendChild(h())}insertAfterNode(t){this.startNode=t,this.endNode=t.nextSibling}appendIntoPart(t){t.__insert(this.startNode=h()),t.__insert(this.endNode=h())}insertAfterPart(t){t.__insert(this.startNode=h()),this.endNode=t.endNode,t.endNode=this.startNode}setValue(t){this.__pendingValue=t}commit(){if(null===this.startNode.parentNode)return;for(;e(this.__pendingValue);){const t=this.__pendingValue;this.__pendingValue=n,t(this)}const t=this.__pendingValue;t!==n&&(y(t)?t!==this.value&&this.__commitText(t):t instanceof v?this.__commitTemplateResult(t):t instanceof Node?this.__commitNode(t):g(t)?this.__commitIterable(t):t===r?(this.value=r,this.clear()):this.__commitText(t))}__insert(t){this.endNode.parentNode.insertBefore(t,this.endNode)}__commitNode(t){this.value!==t&&(this.clear(),this.__insert(t),this.value=t)}__commitText(t){const e=this.startNode.nextSibling,s="string"==typeof(t=null==t?"":t)?t:String(t);e===this.endNode.previousSibling&&3===e.nodeType?e.data=s:this.__commitNode(document.createTextNode(s)),this.value=t}__commitTemplateResult(t){const e=this.options.templateFactory(t);if(this.value instanceof m&&this.value.template===e)this.value.update(t.values);else{const s=new m(e,t.processor,this.options),i=s._clone();s.update(t.values),this.__commitNode(i),this.value=s}}__commitIterable(t){Array.isArray(this.value)||(this.value=[],this.clear());const e=this.value;let s,i=0;for(const n of t)s=e[i],void 0===s&&(s=new S(this.options),e.push(s),0===i?s.appendIntoPart(this):s.insertAfterPart(e[i-1])),s.setValue(n),s.commit(),i++;i<e.length&&(e.length=i,this.clear(s&&s.endNode))}clear(t=this.startNode){i(this.startNode.parentNode,t.nextSibling,this.endNode)}}class x{constructor(t,e,s){if(this.value=void 0,this.__pendingValue=void 0,2!==s.length||""!==s[0]||""!==s[1])throw new Error("Boolean attributes can only contain a single expression");this.element=t,this.name=e,this.strings=s}setValue(t){this.__pendingValue=t}commit(){for(;e(this.__pendingValue);){const t=this.__pendingValue;this.__pendingValue=n,t(this)}if(this.__pendingValue===n)return;const t=!!this.__pendingValue;this.value!==t&&(t?this.element.setAttribute(this.name,""):this.element.removeAttribute(this.name),this.value=t),this.__pendingValue=n}}class E extends b{constructor(t,e,s){super(t,e,s),this.single=2===s.length&&""===s[0]&&""===s[1]}_createPart(){return new P(this)}_getValue(){return this.single?this.parts[0].value:super._getValue()}commit(){this.dirty&&(this.dirty=!1,this.element[this.name]=this._getValue())}}class P extends w{}let N=!1;(()=>{try{const t={get capture(){return N=!0,!1}};window.addEventListener("test",t,t),window.removeEventListener("test",t,t)}catch(t){}})();class C{constructor(t,e,s){this.value=void 0,this.__pendingValue=void 0,this.element=t,this.eventName=e,this.eventContext=s,this.__boundHandleEvent=t=>this.handleEvent(t)}setValue(t){this.__pendingValue=t}commit(){for(;e(this.__pendingValue);){const t=this.__pendingValue;this.__pendingValue=n,t(this)}if(this.__pendingValue===n)return;const t=this.__pendingValue,s=this.value,i=null==t||null!=s&&(t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive),r=null!=t&&(null==s||i);i&&this.element.removeEventListener(this.eventName,this.__boundHandleEvent,this.__options),r&&(this.__options=T(t),this.element.addEventListener(this.eventName,this.__boundHandleEvent,this.__options)),this.value=t,this.__pendingValue=n}handleEvent(t){"function"==typeof this.value?this.value.call(this.eventContext||this.element,t):this.value.handleEvent(t)}}const T=t=>t&&(N?{capture:t.capture,passive:t.passive,once:t.once}:t.capture)
|
|
55
|
-
/**
|
|
56
|
-
* @license
|
|
57
|
-
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
58
|
-
* This code may only be used under the BSD style license found at
|
|
59
|
-
* http://polymer.github.io/LICENSE.txt
|
|
60
|
-
* The complete set of authors may be found at
|
|
61
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
62
|
-
* The complete set of contributors may be found at
|
|
63
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
64
|
-
* Code distributed by Google as part of the polymer project is also
|
|
65
|
-
* subject to an additional IP rights grant found at
|
|
66
|
-
* http://polymer.github.io/PATENTS.txt
|
|
67
|
-
*/;const A=new class{handleAttributeExpressions(t,e,s,i){const n=e[0];if("."===n){return new E(t,e.slice(1),s).parts}if("@"===n)return[new C(t,e.slice(1),i.eventContext)];if("?"===n)return[new x(t,e.slice(1),s)];return new b(t,e,s).parts}handleTextExpression(t){return new S(t)}};
|
|
10
|
+
* Copyright 2017 Google LLC
|
|
11
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
12
|
+
*/const{is:i$1,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$1(t,s),y$1={attribute:!0,type:String,converter:u$1,reflect:!1,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=!1),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:!0,enumerable:!0}}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=!0,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 !1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev();}_$Ev(){this._$Eg=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$ES(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)));}addController(t){(this._$E_??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.();}removeController(t){this._$E_?.delete(t);}_$ES(){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(!0),this._$E_?.forEach((t=>t.hostConnected?.()));}enableUpdating(t){}disconnectedCallback(){this._$E_?.forEach((t=>t.hostDisconnected?.()));}attributeChangedCallback(t,s,i){this._$AK(t,i);}_$EO(t,s){const i=this.constructor.elementProperties.get(t),e=this.constructor._$Eu(t,i);if(void 0!==e&&!0===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.C(t,s,i);}!1===this.isUpdatePending&&(this._$Eg=this._$EP());}C(t,s,i){this._$AL.has(t)||this._$AL.set(t,s),!0===i.reflect&&this._$Em!==t&&(this._$ET??=new Set).add(t);}async _$EP(){this.isUpdatePending=!0;try{await this._$Eg;}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)!0!==i.wrapped||this._$AL.has(s)||void 0===this[s]||this.C(s,this[s],i);}let t=!1;const s=this._$AL;try{t=this.shouldUpdate(s),t?(this.willUpdate(s),this._$E_?.forEach((t=>t.hostUpdate?.())),this.update(s)):this._$Ej();}catch(s){throw t=!1,this._$Ej(),s}t&&this._$AE(s);}willUpdate(t){}_$AE(t){this._$E_?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t);}_$Ej(){this._$AL=new Map,this.isUpdatePending=!1;}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$Eg}shouldUpdate(t){return !0}update(t){this._$ET&&=this._$ET.forEach((t=>this._$EO(t,this[t]))),this._$Ej();}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.3");
|
|
13
|
+
|
|
68
14
|
/**
|
|
69
15
|
* @license
|
|
70
|
-
* Copyright
|
|
71
|
-
*
|
|
72
|
-
* http://polymer.github.io/LICENSE.txt
|
|
73
|
-
* The complete set of authors may be found at
|
|
74
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
75
|
-
* The complete set of contributors may be found at
|
|
76
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
77
|
-
* Code distributed by Google as part of the polymer project is also
|
|
78
|
-
* subject to an additional IP rights grant found at
|
|
79
|
-
* http://polymer.github.io/PATENTS.txt
|
|
80
|
-
*/function L(t){let e=V.get(t.type);void 0===e&&(e={stringsArray:new WeakMap,keyString:new Map},V.set(t.type,e));let s=e.stringsArray.get(t.strings);if(void 0!==s)return s;const i=t.strings.join(o);return s=e.keyString.get(i),void 0===s&&(s=new l(t,t.getTemplateElement()),e.keyString.set(i,s)),e.stringsArray.set(t.strings,s),s}const V=new Map,U=new WeakMap;
|
|
81
|
-
/**
|
|
82
|
-
* @license
|
|
83
|
-
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
84
|
-
* This code may only be used under the BSD style license found at
|
|
85
|
-
* http://polymer.github.io/LICENSE.txt
|
|
86
|
-
* The complete set of authors may be found at
|
|
87
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
88
|
-
* The complete set of contributors may be found at
|
|
89
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
90
|
-
* Code distributed by Google as part of the polymer project is also
|
|
91
|
-
* subject to an additional IP rights grant found at
|
|
92
|
-
* http://polymer.github.io/PATENTS.txt
|
|
93
|
-
*/
|
|
94
|
-
/**
|
|
95
|
-
* @license
|
|
96
|
-
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
97
|
-
* This code may only be used under the BSD style license found at
|
|
98
|
-
* http://polymer.github.io/LICENSE.txt
|
|
99
|
-
* The complete set of authors may be found at
|
|
100
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
101
|
-
* The complete set of contributors may be found at
|
|
102
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
103
|
-
* Code distributed by Google as part of the polymer project is also
|
|
104
|
-
* subject to an additional IP rights grant found at
|
|
105
|
-
* http://polymer.github.io/PATENTS.txt
|
|
16
|
+
* Copyright 2017 Google LLC
|
|
17
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
106
18
|
*/
|
|
107
|
-
"
|
|
19
|
+
const t=globalThis,i=t.trustedTypes,s$1=i?i.createPolicy("lit-html",{createHTML:t=>t}):void 0,e="$lit$",h=`lit$${(Math.random()+"").slice(9)}$`,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),w=Symbol.for("lit-noChange"),T=Symbol.for("lit-nothing"),A=new WeakMap,E=r$1.createTreeWalker(r$1,129);function C(t,i){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==s$1?s$1.createHTML(i):i}const P=(t,i)=>{const s=t.length-1,o=[];let r,l=2===i?"<svg>":"",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 [C(t,l+(t[s]||"<?>")+(2===i?"</svg>":"")),o]};class V{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]=P(t,s);if(this.el=V.createElement(f,n),E.currentNode=this.el.content,2===s){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes);}for(;null!==(r=E.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]?k:"?"===e[1]?H:"@"===e[1]?I:R}),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?i.emptyScript:"";for(let i=0;i<s;i++)r.append(t[i],l()),E.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 N(t,i,s=t,e){if(i===w)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?.(!1),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=N(t,h._$AS(t,i.values),h,e)),i}class S{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,!0);E.currentNode=e;let h=E.nextNode(),o=0,n=0,l=s[0];for(;void 0!==l;){if(o===l.index){let i;2===l.type?i=new M(h,h.nextSibling,this,t):1===l.type?i=new l.ctor(h,l.name,l.strings,this,t):6===l.type&&(i=new L(h,this,t)),this._$AV.push(i),l=s[++n];}o!==l?.index&&(h=E.nextNode(),o++);}return E.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 M{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,i,s,e){this.type=2,this._$AH=T,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cv=e?.isConnected??!0;}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=N(this,t,i),c(t)?t===T||null==t||""===t?(this._$AH!==T&&this._$AR(),this._$AH=T):t!==this._$AH&&t!==w&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):u(t)?this.T(t):this._(t);}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t));}_(t){this._$AH!==T&&c(this._$AH)?this._$AA.nextSibling.data=t:this.$(r$1.createTextNode(t)),this._$AH=t;}g(t){const{values:i,_$litType$:s}=t,e="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=V.createElement(C(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===e)this._$AH.p(i);else {const t=new S(e,this),s=t.u(this.options);t.p(i),this.$(s),this._$AH=t;}}_$AC(t){let i=A.get(t.strings);return void 0===i&&A.set(t.strings,i=new V(t)),i}T(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 M(this.k(l()),this.k(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?.(!1,!0,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 R{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,i,s,e,h){this.type=1,this._$AH=T,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=T;}_$AI(t,i=this,s,e){const h=this.strings;let o=!1;if(void 0===h)t=N(this,t,i,0),o=!c(t)||t!==this._$AH&&t!==w,o&&(this._$AH=t);else {const e=t;let n,r;for(t=h[0],n=0;n<h.length-1;n++)r=N(this,e[s+n],i,n),r===w&&(r=this._$AH[n]),o||=!c(r)||r!==this._$AH[n],r===T?t=T:t!==T&&(t+=(r??"")+h[n+1]),this._$AH[n]=r;}o&&!e&&this.O(t);}O(t){t===T?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"");}}class k extends R{constructor(){super(...arguments),this.type=3;}O(t){this.element[this.name]=t===T?void 0:t;}}class H extends R{constructor(){super(...arguments),this.type=4;}O(t){this.element.toggleAttribute(this.name,!!t&&t!==T);}}class I extends R{constructor(t,i,s,e,h){super(t,i,s,e,h),this.type=5;}_$AI(t,i=this){if((t=N(this,t,i,0)??T)===w)return;const s=this._$AH,e=t===T&&s!==T||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,h=t!==T&&(s===T||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 L{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){N(this,t);}}const Z=t.litHtmlPolyfillSupport;Z?.(V,M),(t.litHtmlVersions??=[]).push("3.1.1");const j=(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 M(i.insertBefore(l(),t),t,void 0,s??{});}return h._$AI(t),h};
|
|
20
|
+
|
|
108
21
|
/**
|
|
109
22
|
* @license
|
|
110
|
-
* Copyright
|
|
111
|
-
*
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
23
|
+
* Copyright 2017 Google LLC
|
|
24
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
25
|
+
*/class s 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 i=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=j(i,this.renderRoot,this.renderOptions);}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0);}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1);}render(){return w}}s._$litElement$=!0,s[("finalized")]=!0,globalThis.litElementHydrateSupport?.({LitElement:s});const r=globalThis.litElementPolyfillSupport;r?.({LitElement:s});(globalThis.litElementVersions??=[]).push("4.0.3");
|
|
26
|
+
|
|
27
|
+
var styleCss = i$2`:root{--ds-asset-font-circular-family-name:"AS Circular";--ds-asset-font-circular-filename:"ASCircularWeb";--ds-asset-font-circular-weight-light:"-Light";--ds-asset-font-circular-weight-medium:"-Medium";--ds-asset-font-circular-weight-book:"-Book";--ds-border-radius:0.375rem;--ds-size-25:0.125rem;--ds-size-50:0.25rem;--ds-size-100:0.5rem;--ds-size-150:0.75rem;--ds-size-200:1rem;--ds-size-300:1.5rem;--ds-size-400:2rem;--ds-size-500:2.5rem;--ds-size-600:3rem;--ds-size-700:3.5rem;--ds-size-800:4rem;--ds-size-900:4.5rem;--ds-size-1000:5rem;--ds-unitless-scale-20:0.25;--ds-unitless-scale-50:0.5;--ds-unitless-scale-100:1;--ds-unitless-scale-140:1.4;--ds-unitless-scale-150:1.5;--ds-unitless-scale-200:2;--ds-unitless-scale-300:3;--ds-unitless-scale-350:3.5;--ds-animation-default-property:all;--ds-animation-default-duration:0.3s;--ds-animation-default-timing:ease-out;--ds-depth-overlay:200;--ds-depth-modal:400;--ds-depth-tooltip:300;--ds-elevation-100:0px 0px 5px rgba(0, 0, 0, 0.15);--ds-elevation-200:0px 0px 10px rgba(0, 0, 0, 0.15);--ds-elevation-300:0px 0px 15px rgba(0, 0, 0, 0.2);--ds-grid-breakpoint-xs:320px;--ds-grid-breakpoint-sm:576px;--ds-grid-breakpoint-md:768px;--ds-grid-breakpoint-lg:1024px;--ds-grid-breakpoint-xl:1232px;--ds-grid-column-xs:6;--ds-grid-column-sm:12;--ds-grid-column-md:12;--ds-grid-column-lg:12;--ds-grid-column-xl:12;--ds-grid-gutter-xs:0.5rem;--ds-grid-gutter-sm:1rem;--ds-grid-gutter-md:1.5rem;--ds-grid-gutter-lg:1.5rem;--ds-grid-gutter-xl:2rem;--ds-grid-margin-xs:1rem;--ds-grid-margin-sm:1rem;--ds-grid-margin-md:1.5rem;--ds-grid-margin-lg:2rem;--ds-grid-margin-xl:2rem;--ds-font-family-default:"AS Circular", Helvetica Neue, Arial, sans-serif;--ds-font-family-mono:Menlo, Monaco, Consolas, "Courier New", monospace;--ds-text-heading-300-weight:300;--ds-text-heading-300-px:18px;--ds-text-heading-300-size:1.125rem;--ds-text-heading-300-height:1.625rem;--ds-text-heading-300-height-px:26px;--ds-text-heading-400-weight:300;--ds-text-heading-400-px:20px;--ds-text-heading-400-size:1.25rem;--ds-text-heading-400-height:1.625rem;--ds-text-heading-400-height-px:26px;--ds-text-heading-500-weight:300;--ds-text-heading-500-px-breakpoint-sm:22px;--ds-text-heading-500-px-breakpoint-md:24px;--ds-text-heading-500-px-breakpoint-lg:24px;--ds-text-heading-500-size-breakpoint-sm:1.375rem;--ds-text-heading-500-size-breakpoint-md:1.5rem;--ds-text-heading-500-size-breakpoint-lg:1.5rem;--ds-text-heading-500-height-breakpoint-sm:1.625rem;--ds-text-heading-500-height-breakpoint-px-sm:26px;--ds-text-heading-500-height-breakpoint-md:1.875rem;--ds-text-heading-500-height-breakpoint-px-md:30px;--ds-text-heading-500-height-breakpoint-lg:2rem;--ds-text-heading-500-height-breakpoint-px-lg:32px;--ds-text-heading-600-weight:300;--ds-text-heading-600-px-breakpoint-sm:26px;--ds-text-heading-600-px-breakpoint-md:28px;--ds-text-heading-600-px-breakpoint-lg:28px;--ds-text-heading-600-size-breakpoint-sm:1.625rem;--ds-text-heading-600-size-breakpoint-md:1.75rem;--ds-text-heading-600-size-breakpoint-lg:1.75rem;--ds-text-heading-600-height-breakpoint-sm:1.875rem;--ds-text-heading-600-height-breakpoint-px-sm:30px;--ds-text-heading-600-height-breakpoint-md:2.125rem;--ds-text-heading-600-height-breakpoint-px-md:34px;--ds-text-heading-600-height-breakpoint-lg:2.25rem;--ds-text-heading-600-height-breakpoint-px-lg:36px;--ds-text-heading-700-weight:500;--ds-text-heading-700-px-breakpoint-sm:28px;--ds-text-heading-700-px-breakpoint-md:32px;--ds-text-heading-700-px-breakpoint-lg:36px;--ds-text-heading-700-size-breakpoint-sm:1.75rem;--ds-text-heading-700-size-breakpoint-md:2rem;--ds-text-heading-700-size-breakpoint-lg:2.25rem;--ds-text-heading-700-height-breakpoint-sm:2.125rem;--ds-text-heading-700-height-breakpoint-px-sm:34px;--ds-text-heading-700-height-breakpoint-md:2.375rem;--ds-text-heading-700-height-breakpoint-px-md:38px;--ds-text-heading-700-height-breakpoint-lg:2.75rem;--ds-text-heading-700-height-breakpoint-px-lg:44px;--ds-text-heading-800-weight:500;--ds-text-heading-800-px-breakpoint-sm:32px;--ds-text-heading-800-px-breakpoint-md:36px;--ds-text-heading-800-px-breakpoint-lg:40px;--ds-text-heading-800-size-breakpoint-sm:2rem;--ds-text-heading-800-size-breakpoint-md:2.25rem;--ds-text-heading-800-size-breakpoint-lg:2.5rem;--ds-text-heading-800-height-breakpoint-sm:2.375rem;--ds-text-heading-800-height-breakpoint-px-sm:38px;--ds-text-heading-800-height-breakpoint-md:2.625rem;--ds-text-heading-800-height-breakpoint-px-md:42px;--ds-text-heading-800-height-breakpoint-lg:3rem;--ds-text-heading-800-height-breakpoint-px-lg:48px;--ds-text-heading-default-weight:500;--ds-text-heading-default-margin:0;--ds-text-heading-default-spacing:-0.2px;--ds-text-heading-medium-weight:300;--ds-text-heading-display-weight:100;--ds-text-heading-display-px-breakpoint-sm:44px;--ds-text-heading-display-px-breakpoint-md:48px;--ds-text-heading-display-px-breakpoint-lg:56px;--ds-text-heading-display-size-breakpoint-sm:2.75rem;--ds-text-heading-display-size-breakpoint-md:3rem;--ds-text-heading-display-size-breakpoint-lg:3.5rem;--ds-text-heading-display-height-breakpoint-sm:3.375rem;--ds-text-heading-display-height-breakpoint-px-sm:54px;--ds-text-heading-display-height-breakpoint-md:3.75rem;--ds-text-heading-display-height-breakpoint-px-md:60px;--ds-text-heading-display-height-breakpoint-lg:4.25rem;--ds-text-heading-display-height-breakpoint-px-lg:68px;--ds-text-body-default-weight:500;--ds-text-body-size-xxs:0.625rem;--ds-text-body-size-xs:0.75rem;--ds-text-body-size-sm:0.875rem;--ds-text-body-size-default:1rem;--ds-text-body-size-lg:1.125rem;--ds-text-body-height-xs:1rem;--ds-text-body-height-sm:1.25rem;--ds-text-body-height-default:1.5rem;--ds-text-body-height-lg:1.625rem;--ds-color-alert-notification-default:#0074c8;--ds-color-alert-warning-default:#de750c;--ds-color-alert-error-default:#df0b37;--ds-color-alert-success-default:#00805d;--ds-color-alert-advisory-default:#fff0cd;--ds-color-alert-bkg-success-default:#ddf6e8;--ds-color-alert-bkg-error-default:#ffedf1;--ds-color-background-lightest:#ffffff;--ds-color-background-lighter:#f8f8f8;--ds-color-background-darker:#01426a;--ds-color-background-darkest:#00274a;--ds-color-background-gradient-default:linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5));--ds-color-base-white:#ffffff;--ds-color-base-white-opacity-50:rgba(255, 255, 255, 0.5);--ds-color-base-white-opacity-40:rgba(255, 255, 255, 0.4);--ds-color-base-white-opacity-0:rgba(255, 255, 255, 0);--ds-color-base-black:#000000;--ds-color-base-black-opacity-15:rgba(0, 0, 0, 0.15);--ds-color-state-error-100:#ff999b;--ds-color-state-error-500:#df0b37;--ds-color-state-success-100:#69cf96;--ds-color-state-success-500:#00805d;--ds-color-state-warning-500:#de750c;--ds-color-border-primary-default:#626b79;--ds-color-border-primary-inverse:#9fabbb;--ds-color-border-active-default:#0074c8;--ds-color-border-active-inverse:#00cff0;--ds-color-border-error-default:#df0b37;--ds-color-border-disabled-default:#dbdbdb;--ds-color-border-focus-default:#222222;--ds-color-border-divider-default:rgba(0, 0, 0, 0.15);--ds-color-border-divider-inverse:#ffffff;--ds-color-brand-midnight-100:#c1daf0;--ds-color-brand-midnight-200:#569ed7;--ds-color-brand-midnight-300:#156fad;--ds-color-brand-midnight-400:#01426a;--ds-color-brand-midnight-500:#00274a;--ds-color-brand-atlas-100:#cde6ff;--ds-color-brand-atlas-200:#6bb7fb;--ds-color-brand-atlas-300:#2492eb;--ds-color-brand-atlas-400:#0074c8;--ds-color-brand-atlas-500:#054687;--ds-color-brand-breeze-100:#c0f7ff;--ds-color-brand-breeze-200:#5de3f7;--ds-color-brand-breeze-300:#00cff0;--ds-color-brand-breeze-400:#099dc5;--ds-color-brand-breeze-500:#0b5575;--ds-color-brand-tropical-100:#e2ffcd;--ds-color-brand-tropical-200:#d0fba6;--ds-color-brand-tropical-300:#c0e585;--ds-color-brand-tropical-400:#91be62;--ds-color-brand-tropical-500:#5e8741;--ds-color-brand-alpine-100:#bcaae6;--ds-color-brand-alpine-200:#9e73ea;--ds-color-brand-alpine-300:#8439ef;--ds-color-brand-alpine-400:#631db8;--ds-color-brand-alpine-500:#39115c;--ds-color-brand-flamingo-100:#ffebee;--ds-color-brand-flamingo-200:#ffc0ca;--ds-color-brand-flamingo-300:#ff94a7;--ds-color-brand-flamingo-400:#f65b7b;--ds-color-brand-flamingo-500:#b82b47;--ds-color-brand-canyon-100:#ffcab6;--ds-color-brand-canyon-200:#f99574;--ds-color-brand-canyon-300:#f26135;--ds-color-brand-canyon-400:#de3e09;--ds-color-brand-canyon-500:#b83302;--ds-color-brand-goldcoast-100:#fff0cd;--ds-color-brand-goldcoast-200:#ffdb67;--ds-color-brand-goldcoast-300:#ffd200;--ds-color-brand-goldcoast-400:#e5ad07;--ds-color-brand-goldcoast-500:#b88624;--ds-color-brand-neutral-100:#f9fbfc;--ds-color-brand-neutral-200:#e2eaef;--ds-color-brand-neutral-300:#cbd8e2;--ds-color-brand-neutral-400:#9fabbb;--ds-color-brand-neutral-500:#626b79;--ds-color-brand-gray-100:#f8f8f8;--ds-color-brand-gray-200:#dbdbdb;--ds-color-brand-gray-300:#b2b2b2;--ds-color-brand-gray-400:#767676;--ds-color-brand-gray-500:#222222;--ds-color-brand-goldgray-100:#c5c1bf;--ds-color-brand-goldgray-200:#726e6c;--ds-color-brand-gold-100:#ccbc94;--ds-color-brand-gold-200:#7f682e;--ds-color-brand-emerald:#139142;--ds-color-brand-sapphire:#015daa;--ds-color-brand-ruby:#a41d4a;--ds-color-icon-primary-default:#626b79;--ds-color-icon-primary-inverse:#9fabbb;--ds-color-icon-emphasis-default:#222222;--ds-color-icon-emphasis-inverse:#ffffff;--ds-color-icon-accent-default:#0074c8;--ds-color-icon-disabled-default:rgba(0, 0, 0, 0.15);--ds-color-text-primary-default:#222222;--ds-color-text-primary-inverse:#ffffff;--ds-color-text-secondary-default:#626b79;--ds-color-text-secondary-inverse:#9fabbb;--ds-color-text-link-default:#0074c8;--ds-color-text-link-inverse:#00cff0;--ds-color-text-error-default:#df0b37;--ds-color-text-error-inverse:#ff999b;--ds-color-text-disabled-default:#dbdbdb;--ds-color-text-emphasis-default:#01426a;--ds-color-text-emphasis-inverse:#c1daf0;--ds-color-tier-alaska-mvp-default:#726e6c;--ds-color-tier-alaska-mvp-inverse:#c5c1bf;--ds-color-tier-alaska-mvpgold-default:#7f682e;--ds-color-tier-alaska-mvpgold-inverse:#ccbc94;--ds-color-tier-oneworld-emerald:#139142;--ds-color-tier-oneworld-sapphire:#015daa;--ds-color-tier-oneworld-ruby:#a41d4a;--ds-color-ui-default-default:#0074c8;--ds-color-ui-default-inverse:#00cff0;--ds-color-ui-hover-default:#054687;--ds-color-ui-hover-inverse:#5de3f7;--ds-color-ui-active-default:#054687;--ds-color-ui-active-inverse:#5de3f7;--ds-color-ui-disabled-default:rgba(0, 116, 200, 0.2);--ds-color-ui-bkg-default-default:rgba(0, 0, 0, 0.03);--ds-color-ui-bkg-default-inverse:rgba(255, 255, 255, 0.03);--ds-color-ui-bkg-hover-default:rgba(0, 0, 0, 0.06);--ds-color-ui-bkg-hover-inverse:rgba(255, 255, 255, 0.06)}*,*: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{display:block}.util_displayFlex{display:flex}.util_displayHidden{display:none}.util_displayHiddenVisually{position:absolute;overflow:hidden;clip:rect(1px, 1px, 1px, 1px);width:1px;height:1px;padding:0;border:0}:host{display:block;animation-duration:2s;animation-fill-mode:backwards;animation-iteration-count:infinite;animation-name:place-holder-shimmer;animation-timing-function:linear;background-color:var(--ds-color-brand-neutral-100, #f9fbfc);background-image:linear-gradient(to right, var(--ds-color-brand-neutral-100, #f9fbfc) 10%, var(--ds-color-brand-neutral-200, #e2eaef) 40%, var(--ds-color-brand-neutral-100, #f9fbfc) 60%);background-repeat:no-repeat;background-size:1000px 100%}:host([shape=circle]){width:auto;border-radius:50%}:host([shape=oval]){border-radius:9999px}:host([shape=rectangle]){border-radius:var(--ds-border-radius, 0.375rem)}@keyframes place-holder-shimmer{from{background-position:-1000px 0}to{background-position:1000px 0}}`;
|
|
28
|
+
|
|
29
|
+
// Copyright (c) 2021 Alaska Airlines. All right reserved. Licensed under the Apache-2.0 license
|
|
30
|
+
// See LICENSE in the project root for license information.
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
// See https://git.io/JJ6SJ for "How to document your components using JSDoc"
|
|
121
34
|
/**
|
|
122
|
-
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
125
|
-
* http://polymer.github.io/LICENSE.txt
|
|
126
|
-
* The complete set of authors may be found at
|
|
127
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
128
|
-
* The complete set of contributors may be found at
|
|
129
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
130
|
-
* Code distributed by Google as part of the polymer project is also
|
|
131
|
-
* subject to an additional IP rights grant found at
|
|
132
|
-
* http://polymer.github.io/PATENTS.txt
|
|
35
|
+
* The auro-skeleton element provides users a way to indicate the loading of asynchronous content on a page.
|
|
36
|
+
*
|
|
37
|
+
* @attr {String} shape - Renders a circle, oval, or rectangle loader.
|
|
133
38
|
*/
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
39
|
+
|
|
40
|
+
// build the component class
|
|
41
|
+
class AuroSkeleton extends s {
|
|
42
|
+
// constructor() {
|
|
43
|
+
// super();
|
|
44
|
+
// }
|
|
45
|
+
|
|
46
|
+
// function to define props used within the scope of this component
|
|
47
|
+
static get properties() {
|
|
48
|
+
return {
|
|
49
|
+
// ...super.properties,
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
static get styles() {
|
|
54
|
+
return [styleCss];
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
// When using auroElement, use the following attribute and function when hiding content from screen readers.
|
|
58
|
+
// aria-hidden="${this.hideAudible(this.hiddenAudible)}"
|
|
59
|
+
|
|
60
|
+
// function that renders the HTML and CSS into the scope of the component
|
|
61
|
+
render() {
|
|
62
|
+
return x`
|
|
63
|
+
<span class="util_displayHiddenVisually">Loading...</span>
|
|
64
|
+
`;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/* istanbul ignore else */
|
|
69
|
+
// define the name of the custom component
|
|
70
|
+
if (!customElements.get("auro-skeleton")) {
|
|
71
|
+
customElements.define("auro-skeleton", AuroSkeleton);
|
|
72
|
+
}
|
|
73
|
+
|
|
145
74
|
/**
|
|
146
|
-
*
|
|
147
|
-
*
|
|
148
|
-
*
|
|
149
|
-
* http://polymer.github.io/LICENSE.txt
|
|
150
|
-
* The complete set of authors may be found at
|
|
151
|
-
* http://polymer.github.io/AUTHORS.txt
|
|
152
|
-
* The complete set of contributors may be found at
|
|
153
|
-
* http://polymer.github.io/CONTRIBUTORS.txt
|
|
154
|
-
* Code distributed by Google as part of the polymer project is also
|
|
155
|
-
* subject to an additional IP rights grant found at
|
|
156
|
-
* http://polymer.github.io/PATENTS.txt
|
|
75
|
+
* Register Custom Element.
|
|
76
|
+
* @param {Object} name - Name to use for custom element.
|
|
77
|
+
* @returns {void}
|
|
157
78
|
*/
|
|
158
|
-
|
|
79
|
+
const registerComponent = (name = 'custom-skeleton') => {
|
|
80
|
+
// alias definition
|
|
81
|
+
if (!customElements.get(name)) {
|
|
82
|
+
customElements.define(name, class extends AuroSkeleton {});
|
|
83
|
+
}
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
export { registerComponent };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"style-css.d.ts","sourceRoot":"","sources":["../src/style-css.js"],"names":[],"mappings":""}
|
package/index.js
CHANGED
|
@@ -1 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
import { AuroSkeleton } from './src/auro-skeleton.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Register Custom Element.
|
|
5
|
+
* @param {Object} name - Name to use for custom element.
|
|
6
|
+
* @returns {void}
|
|
7
|
+
*/
|
|
8
|
+
const registerComponent = (name = 'custom-skeleton') => {
|
|
9
|
+
// alias definition
|
|
10
|
+
if (!customElements.get(name)) {
|
|
11
|
+
customElements.define(name, class extends AuroSkeleton {});
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export { registerComponent }
|
package/package.json
CHANGED
|
@@ -3,91 +3,84 @@
|
|
|
3
3
|
"================================================================================",
|
|
4
4
|
"# To work within the development environment, run the following tasks",
|
|
5
5
|
" 1. $ npm run dev",
|
|
6
|
-
" 2.
|
|
7
|
-
" 3. Go to http://localhost:8000",
|
|
6
|
+
" 2. Go to http://localhost:8000",
|
|
8
7
|
"================================================================================"
|
|
9
8
|
],
|
|
10
9
|
"name": "@aurodesignsystem/auro-skeleton",
|
|
11
|
-
"version": "2.
|
|
10
|
+
"version": "2.1.1",
|
|
12
11
|
"description": "auro-skeleton HTML custom element",
|
|
13
12
|
"repository": {
|
|
14
13
|
"type": "git",
|
|
15
14
|
"url": "https://github.com/AlaskaAirlines/auro-skeleton"
|
|
16
15
|
},
|
|
16
|
+
"type": "module",
|
|
17
17
|
"main": "index.js",
|
|
18
18
|
"license": "Apache-2.0",
|
|
19
|
+
"engines": {
|
|
20
|
+
"node": "^18.x || ^20.x "
|
|
21
|
+
},
|
|
19
22
|
"dependencies": {
|
|
20
|
-
"chalk": "^
|
|
21
|
-
"lit
|
|
23
|
+
"chalk": "^5.3.0",
|
|
24
|
+
"lit": "^3.1.1"
|
|
22
25
|
},
|
|
23
26
|
"peerDependencies": {
|
|
24
|
-
"@
|
|
25
|
-
"@
|
|
26
|
-
"@webcomponents/webcomponentsjs": "^2.5.0",
|
|
27
|
-
"focus-visible": "^5.2.0"
|
|
27
|
+
"@aurodesignsystem/design-tokens": "^4.3.0",
|
|
28
|
+
"@aurodesignsystem/webcorestylesheets": "^5.0.6"
|
|
28
29
|
},
|
|
29
30
|
"devDependencies": {
|
|
30
|
-
"@
|
|
31
|
-
"@
|
|
32
|
-
"@aurodesignsystem/
|
|
33
|
-
"@
|
|
34
|
-
"@
|
|
35
|
-
"@
|
|
36
|
-
"@
|
|
37
|
-
"@
|
|
38
|
-
"@
|
|
39
|
-
"@
|
|
40
|
-
"@
|
|
41
|
-
"@
|
|
42
|
-
"@
|
|
43
|
-
"
|
|
44
|
-
"@rollup/plugin-node-resolve": "^13.0.4",
|
|
45
|
-
"@semantic-release/changelog": "^5.0.1",
|
|
46
|
-
"@semantic-release/git": "^9.0.0",
|
|
47
|
-
"@semantic-release/npm": "^7.1.3",
|
|
48
|
-
"@web/dev-server": "^0.1.20",
|
|
49
|
-
"@web/test-runner": "^0.13.15",
|
|
50
|
-
"@webcomponents/webcomponentsjs": "^2.6.0",
|
|
51
|
-
"autoprefixer": "^10.3.1",
|
|
52
|
-
"babel-loader": "^8.2.2",
|
|
31
|
+
"@aurodesignsystem/auro-library": "^2.4.0",
|
|
32
|
+
"@aurodesignsystem/design-tokens": "^4.3.0",
|
|
33
|
+
"@aurodesignsystem/webcorestylesheets": "^5.0.6",
|
|
34
|
+
"@aurodesignsystem/eslint-config": "^1.3.1",
|
|
35
|
+
"@commitlint/cli": "^18.6.0",
|
|
36
|
+
"@commitlint/config-conventional": "^18.6.0",
|
|
37
|
+
"@open-wc/testing": "^4.0.0",
|
|
38
|
+
"@rollup/plugin-node-resolve": "^15.2.3",
|
|
39
|
+
"@semantic-release/changelog": "^6.0.3",
|
|
40
|
+
"@semantic-release/git": "^10.0.1",
|
|
41
|
+
"@semantic-release/npm": "^11.0.2",
|
|
42
|
+
"@web/dev-server": "^0.4.1",
|
|
43
|
+
"@web/test-runner": "^0.18.0",
|
|
44
|
+
"autoprefixer": "^10.4.17",
|
|
53
45
|
"compression": "^1.7.4",
|
|
54
46
|
"concat": "^1.0.3",
|
|
47
|
+
"concurrently": "^8.2.2",
|
|
55
48
|
"copyfiles": "^2.4.1",
|
|
56
|
-
"core-js": "^3.
|
|
57
|
-
"eslint": "^
|
|
58
|
-
"
|
|
59
|
-
"husky": "^
|
|
49
|
+
"core-js": "^3.35.1",
|
|
50
|
+
"eslint": "^8.56.0",
|
|
51
|
+
"eslint-plugin-jsdoc": "^48.0.4",
|
|
52
|
+
"husky": "^8.0.0",
|
|
60
53
|
"lodash": "^4.17.21",
|
|
61
|
-
"
|
|
62
|
-
"nodemon": "^
|
|
54
|
+
"markdown-magic": "^2.6.1",
|
|
55
|
+
"nodemon": "^3.0.3",
|
|
63
56
|
"npm-run-all": "^4.1.5",
|
|
64
|
-
"postcss": "^8.
|
|
65
|
-
"postcss-
|
|
66
|
-
"postcss-discard-comments": "^5.0.1",
|
|
67
|
-
"postcss-rem-to-pixel": "^4.1.2",
|
|
68
|
-
"postcss-remove-rules": "^1.0.0",
|
|
57
|
+
"postcss": "^8.4.33",
|
|
58
|
+
"postcss-discard-comments": "^6.0.1",
|
|
69
59
|
"postcss-selector-replace": "^1.0.2",
|
|
70
|
-
"
|
|
71
|
-
"rollup": "^
|
|
72
|
-
"
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
"stylelint": "^13.
|
|
78
|
-
"stylelint-
|
|
79
|
-
"stylelint-
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
|
|
60
|
+
"rollup": "^4.9.6",
|
|
61
|
+
"rollup-plugin-serve": "^1.1.1",
|
|
62
|
+
"sass": "^1.70.0",
|
|
63
|
+
"semantic-release": "^23.0.0",
|
|
64
|
+
"stylelint": "^16.2.0",
|
|
65
|
+
"stylelint-config-idiomatic-order": "^10.0.0",
|
|
66
|
+
"stylelint-config-standard": "^36.0.0",
|
|
67
|
+
"stylelint-config-standard-scss": "^13.0.0",
|
|
68
|
+
"stylelint-order": "^6.0.4",
|
|
69
|
+
"stylelint-scss": "^6.1.0",
|
|
70
|
+
"typescript": "^5.3.3",
|
|
71
|
+
"wc-sass-render": "^1.4.0",
|
|
72
|
+
"web-component-analyzer": "^2.0.0",
|
|
73
|
+
"whatwg-fetch": "^3.6.20",
|
|
74
|
+
"yaml-lint": "^1.7.0"
|
|
75
|
+
},
|
|
76
|
+
"overrides": {
|
|
77
|
+
"wc-sass-render": {
|
|
78
|
+
"sass": "$sass"
|
|
79
|
+
}
|
|
86
80
|
},
|
|
87
81
|
"browserslist": [
|
|
88
82
|
"last 2 Chrome versions",
|
|
89
83
|
"last 2 iOS major versions",
|
|
90
|
-
"ie 11",
|
|
91
84
|
"last 2 Firefox versions",
|
|
92
85
|
"last 2 Edge versions",
|
|
93
86
|
"last 2 Safari major versions"
|
|
@@ -117,8 +110,9 @@
|
|
|
117
110
|
"@semantic-release/git",
|
|
118
111
|
{
|
|
119
112
|
"assets": [
|
|
113
|
+
"./package.json",
|
|
120
114
|
"./CHANGELOG.md",
|
|
121
|
-
"
|
|
115
|
+
"./README.md",
|
|
122
116
|
"./docs/api.md"
|
|
123
117
|
]
|
|
124
118
|
}
|
|
@@ -136,35 +130,30 @@
|
|
|
136
130
|
"web components"
|
|
137
131
|
],
|
|
138
132
|
"scripts": {
|
|
139
|
-
"build": "npm-run-all build:sass sass:render dist:js build:api
|
|
133
|
+
"build": "npm-run-all build:sass sass:render scssLint dist:js bundler postinstall build:api types build:docs",
|
|
140
134
|
"build:ci": "npm-run-all sweep build",
|
|
141
135
|
"build:api": "wca analyze 'src/auro-skeleton.js' --outFiles docs/api.md",
|
|
142
|
-
"build:
|
|
143
|
-
"build:
|
|
144
|
-
"build:sass": "npm-run-all build:sass:
|
|
145
|
-
"build:sass:
|
|
146
|
-
"build:
|
|
147
|
-
"build:watch": "nodemon -e scss,js --watch src --exec npm run build:dev:assets",
|
|
136
|
+
"build:dev:assets": "npm-run-all build:sass:component postCss:component sass:render build:docs",
|
|
137
|
+
"build:docs": "node scripts/generateDocs.mjs",
|
|
138
|
+
"build:sass": "npm-run-all build:sass:component postCss:component sass:render",
|
|
139
|
+
"build:sass:component": "sass --no-source-map src:src",
|
|
140
|
+
"build:watch": "nodemon -e scss,js,html --watch src --watch apiExamples/**/* --exec npm run build:dev:assets",
|
|
148
141
|
"bundler": "rollup -c",
|
|
149
142
|
"bundler:test": "rollup -c -w",
|
|
150
143
|
"scssLint": "stylelint \"./src/**/*.scss\"",
|
|
151
|
-
"
|
|
152
|
-
"demo:copy:index": "copyfiles -u 1 -V './demo/index.html' ./build",
|
|
153
|
-
"demo:new:build": "mkdir ./build && mkdir ./build/css && mkdir ./build/demo",
|
|
154
|
-
"demo:rm:build": "rm -rf ./build",
|
|
155
|
-
"demo:update:index": "node ./scripts/prepForBuild",
|
|
156
|
-
"dev": "npm run build:watch",
|
|
144
|
+
"dev": "concurrently --kill-others \"npm run build:watch\" \"npm run serve\"",
|
|
157
145
|
"dist:js": "copyfiles -u 1 -V './src/**/*.js' ./dist",
|
|
158
146
|
"esLint": "./node_modules/.bin/eslint src/**/*.js",
|
|
159
147
|
"linters": "npm-run-all scssLint esLint",
|
|
160
|
-
"preCommit": "node scripts/pre-commit.
|
|
161
|
-
"postCss:component": "node
|
|
162
|
-
"postinstall": "node packageScripts/postinstall.
|
|
148
|
+
"preCommit": "node scripts/pre-commit.mjs",
|
|
149
|
+
"postCss:component": "node scripts/postCss.mjs",
|
|
150
|
+
"postinstall": "node packageScripts/postinstall.mjs",
|
|
163
151
|
"sass:render": "sass-render src/*.css -t ./scripts/staticStyles-template.js",
|
|
164
152
|
"serve": "web-dev-server --open demo/ --node-resolve --watch",
|
|
165
153
|
"sweep": "rm -rf ./demo/css ./dist | rm ./src/*.css ./src/*-css.js",
|
|
166
154
|
"test": "wtr --coverage",
|
|
167
155
|
"test:watch": "wtr --watch",
|
|
156
|
+
"types": "tsc",
|
|
168
157
|
"prepare": "husky install"
|
|
169
158
|
}
|
|
170
159
|
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
import chalk from 'chalk';
|
|
4
|
+
import { createRequire } from 'node:module';
|
|
5
|
+
const require = createRequire(import.meta.url);
|
|
4
6
|
const pjson = require('../package.json');
|
|
5
7
|
|
|
6
8
|
console.log(chalk.hex('#f26135')(`
|
|
@@ -19,7 +21,7 @@ console.log(chalk.hex('#f26135')(`
|
|
|
19
21
|
╭ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ──────────────────────────────╮
|
|
20
22
|
|
|
21
23
|
Thanks for installing the latest version
|
|
22
|
-
|
|
24
|
+
of `) + chalk.hex('#ffd200').bold(`${pjson.name} v${pjson.version}.`) + chalk.hex('#f26135')(`
|
|
23
25
|
|
|
24
26
|
╰─────────────────────────────── ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─╯
|
|
25
27
|
`)
|