@telperion/elements 8.1.1 → 9.0.0
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/.build-manifest.json +22 -1
- package/README.md +34 -0
- package/_chunks/mermaid-cdn-element-0CeuzHyG.d.cts +149 -0
- package/_chunks/mermaid-cdn-element-0CeuzHyG.d.ts +149 -0
- package/button/button.element.cjs +3 -3
- package/button/button.element.js +3 -3
- package/button/index.d.cts +1 -1
- package/button/index.d.ts +1 -1
- package/custom-elements.json +778 -3
- package/fesm/elements.mjs +7 -7
- package/iife/button/index.js +8 -8
- package/iife/elements.js +17 -17
- package/iife/mermaid/cdn.js +114 -0
- package/iife/mermaid/cdn.js.map +1 -0
- package/iife/router/index.js +2 -2
- package/iife/select/index.js +16 -16
- package/mermaid/bundled-mermaid-loader.cjs +7 -0
- package/mermaid/bundled-mermaid-loader.cjs.map +1 -0
- package/mermaid/bundled-mermaid-loader.js +5 -0
- package/mermaid/bundled-mermaid-loader.js.map +1 -0
- package/mermaid/cdn-mermaid-loader.cjs +34 -0
- package/mermaid/cdn-mermaid-loader.cjs.map +1 -0
- package/mermaid/cdn-mermaid-loader.js +29 -0
- package/mermaid/cdn-mermaid-loader.js.map +1 -0
- package/mermaid/cdn.cjs +21 -0
- package/mermaid/cdn.cjs.map +1 -0
- package/mermaid/cdn.d.cts +3 -0
- package/mermaid/cdn.d.ts +3 -0
- package/mermaid/cdn.js +16 -0
- package/mermaid/cdn.js.map +1 -0
- package/mermaid/index.cjs +19 -0
- package/mermaid/index.cjs.map +1 -0
- package/mermaid/index.d.cts +9 -0
- package/mermaid/index.d.ts +9 -0
- package/mermaid/index.js +6 -0
- package/mermaid/index.js.map +1 -0
- package/mermaid/loader.cjs +28 -0
- package/mermaid/loader.cjs.map +1 -0
- package/mermaid/loader.js +24 -0
- package/mermaid/loader.js.map +1 -0
- package/mermaid/mermaid-element-base.cjs +195 -0
- package/mermaid/mermaid-element-base.cjs.map +1 -0
- package/mermaid/mermaid-element-base.js +193 -0
- package/mermaid/mermaid-element-base.js.map +1 -0
- package/mermaid/mermaid-element.cjs +16 -0
- package/mermaid/mermaid-element.cjs.map +1 -0
- package/mermaid/mermaid-element.js +14 -0
- package/mermaid/mermaid-element.js.map +1 -0
- package/mermaid/render.cjs +42 -0
- package/mermaid/render.cjs.map +1 -0
- package/mermaid/render.js +39 -0
- package/mermaid/render.js.map +1 -0
- package/mermaid/source.cjs +27 -0
- package/mermaid/source.cjs.map +1 -0
- package/mermaid/source.js +24 -0
- package/mermaid/source.js.map +1 -0
- package/mermaid/styles.cjs +73 -0
- package/mermaid/styles.cjs.map +1 -0
- package/mermaid/styles.js +71 -0
- package/mermaid/styles.js.map +1 -0
- package/mermaid/theme.cjs +78 -0
- package/mermaid/theme.cjs.map +1 -0
- package/mermaid/theme.js +75 -0
- package/mermaid/theme.js.map +1 -0
- package/package.json +40 -3
- package/select/option.element.cjs +2 -2
- package/select/option.element.js +2 -2
- package/utils/shade-mixer-lit-element.cjs +2 -2
- package/utils/shade-mixer-lit-element.js +2 -2
package/fesm/elements.mjs
CHANGED
|
@@ -448,7 +448,7 @@ class ShadeMixerLitElement extends LitElement {
|
|
|
448
448
|
--tp-color-success: hsl(140 70% 40%);
|
|
449
449
|
--tp-color-danger: hsl(0 70% 50%);
|
|
450
450
|
--tp-color-warning: hsl(45 100% 50%);
|
|
451
|
-
--tp-color-neutral: color-mix(in
|
|
451
|
+
--tp-color-neutral: color-mix(in oklab, var(--tp-color-white) 50%, var(--tp-color-black) 50%);
|
|
452
452
|
}
|
|
453
453
|
}
|
|
454
454
|
`;
|
|
@@ -467,7 +467,7 @@ class ShadeMixerLitElement extends LitElement {
|
|
|
467
467
|
style(--tp-shade-mixer-type: black): calc(100% - ((var(--tp-shade-attr) - 500) / 500 * 100%));
|
|
468
468
|
else: calc(100% - ((500 - var(--tp-shade-attr)) / 500 * 100%))
|
|
469
469
|
);
|
|
470
|
-
--tp-calc-element-color: color-mix(in
|
|
470
|
+
--tp-calc-element-color: color-mix(in oklab, var(--tp-element-color) var(--tp-shade-mixer-percent), var(--tp-shade-mixer-color) calc(100% - var(--tp-shade-mixer-percent)));
|
|
471
471
|
--tp-calc-contrast-color: contrast-color(var(--tp-calc-element-color));
|
|
472
472
|
--tp-contrast-color: if(
|
|
473
473
|
style(--tp-calc-contrast-color: white): var(--tp-color-white);
|
|
@@ -3238,7 +3238,7 @@ let OptionElement = class OptionElement extends SignalWatcherLitElement {
|
|
|
3238
3238
|
background: var(--tp-select-option-color, white);
|
|
3239
3239
|
|
|
3240
3240
|
&:hover {
|
|
3241
|
-
background: color-mix(in
|
|
3241
|
+
background: color-mix(in oklab, var(--tp-select-option-color, white) calc(100% - var(--tp-select-highlight-percent, 20%)), black var(--tp-select-highlight-percent, 20%));
|
|
3242
3242
|
}
|
|
3243
3243
|
|
|
3244
3244
|
&[selected] {
|
|
@@ -3246,7 +3246,7 @@ let OptionElement = class OptionElement extends SignalWatcherLitElement {
|
|
|
3246
3246
|
color: var(--tp-select-selection-contrast-color, white);
|
|
3247
3247
|
|
|
3248
3248
|
&:hover {
|
|
3249
|
-
background: color-mix(in
|
|
3249
|
+
background: color-mix(in oklab, var(--tp-select-selection-color, #0078d4) calc(100% - var(--tp-select-highlight-percent, 20%)), black var(--tp-select-highlight-percent, 20%));
|
|
3250
3250
|
}
|
|
3251
3251
|
}
|
|
3252
3252
|
}
|
|
@@ -3873,7 +3873,7 @@ SelectElement = SelectElement_1 = __decorate([
|
|
|
3873
3873
|
* @cssprop --tp-button-contrast-color - Resolved contrast color used for `solid` text.
|
|
3874
3874
|
* @cssprop --tp-button-active-mixer-color - Color blended into `--tp-button-color` to compute the hover/active color. Defaults to `transparent` for `outline` / `ghost` (subtle tint) and `var(--tp-color-black)` for `solid` / `text` (slight darken).
|
|
3875
3875
|
* @cssprop --tp-button-active-mixer-percentage - Amount of `--tp-button-color` retained when blending against the mixer color. Defaults to `10%` for `outline` / `ghost` and `80%` for `solid` / `text`. Lower values produce a stronger hover effect.
|
|
3876
|
-
* @cssprop --tp-button-active-color - Final hover/active color, computed as `color-mix(in
|
|
3876
|
+
* @cssprop --tp-button-active-color - Final hover/active color, computed as `color-mix(in oklab, var(--tp-button-color) var(--tp-button-active-mixer-percentage), var(--tp-button-active-mixer-color) calc(100% - var(--tp-button-active-mixer-percentage)))`. Override directly to fully customize the hover color.
|
|
3877
3877
|
*
|
|
3878
3878
|
* @example
|
|
3879
3879
|
* ```html
|
|
@@ -3899,7 +3899,7 @@ let ButtonElement = class ButtonElement extends ShadeMixerLitElement {
|
|
|
3899
3899
|
--tp-button-contrast-color: var(--tp-calc-contrast-color);
|
|
3900
3900
|
--tp-button-active-mixer-color: transparent;
|
|
3901
3901
|
--tp-button-active-mixer-percentage: 10%;
|
|
3902
|
-
--tp-button-active-color: color-mix(in
|
|
3902
|
+
--tp-button-active-color: color-mix(in oklab, var(--tp-button-color) var(--tp-button-active-mixer-percentage), var(--tp-button-active-mixer-color) calc(100% - var(--tp-button-active-mixer-percentage)));
|
|
3903
3903
|
display: inline-block;
|
|
3904
3904
|
border: 1px solid transparent;
|
|
3905
3905
|
cursor: pointer;
|
|
@@ -3919,7 +3919,7 @@ let ButtonElement = class ButtonElement extends ShadeMixerLitElement {
|
|
|
3919
3919
|
}
|
|
3920
3920
|
|
|
3921
3921
|
&[disabled] {
|
|
3922
|
-
--tp-button-color: color-mix(in
|
|
3922
|
+
--tp-button-color: color-mix(in oklab, var(--tp-calc-element-color) 50%, var(--tp-color-white) 50%);
|
|
3923
3923
|
--tp-button-contrast-color: rgb(from var(--tp-calc-contrast-color) r g b / 50%);
|
|
3924
3924
|
pointer-events: none;
|
|
3925
3925
|
user-select: none;
|
package/iife/button/index.js
CHANGED
|
@@ -4,18 +4,18 @@ this.TelperionElements=this.TelperionElements||{},function(t){"use strict";funct
|
|
|
4
4
|
* Copyright 2019 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
6
6
|
*/
|
|
7
|
-
const r=globalThis,o=r.ShadowRoot&&(void 0===r.ShadyCSS||r.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),n=new WeakMap;let a=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(o&&void 0===t){const s=void 0!==e&&1===e.length;s&&(t=n.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&n.set(e,t))}return t}toString(){return this.cssText}};const l=(t,...e)=>{const s=1===t.length?t[0]:e.reduce((e,s,r)=>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[r+1],t[0]);return new a(s,t,i)},c=o?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return(t=>new a("string"==typeof t?t:t+"",void 0,i))(e)})(t):t,{is:h,defineProperty:p,getOwnPropertyDescriptor:d,getOwnPropertyNames:u,getOwnPropertySymbols:m,getPrototypeOf:f}=Object,$=globalThis,y=$.trustedTypes,v=y?y.emptyScript:"",_=$.reactiveElementPolyfillSupport,
|
|
7
|
+
const r=globalThis,o=r.ShadowRoot&&(void 0===r.ShadyCSS||r.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),n=new WeakMap;let a=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(o&&void 0===t){const s=void 0!==e&&1===e.length;s&&(t=n.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&n.set(e,t))}return t}toString(){return this.cssText}};const l=(t,...e)=>{const s=1===t.length?t[0]:e.reduce((e,s,r)=>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[r+1],t[0]);return new a(s,t,i)},c=o?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return(t=>new a("string"==typeof t?t:t+"",void 0,i))(e)})(t):t,{is:h,defineProperty:p,getOwnPropertyDescriptor:d,getOwnPropertyNames:u,getOwnPropertySymbols:m,getPrototypeOf:f}=Object,$=globalThis,y=$.trustedTypes,v=y?y.emptyScript:"",_=$.reactiveElementPolyfillSupport,b=(t,e)=>t,g={toAttribute(t,e){switch(e){case Boolean:t=t?v:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let s=t;switch(e){case Boolean:s=null!==t;break;case Number:s=null===t?null:Number(t);break;case Object:case Array:try{s=JSON.parse(t)}catch(t){s=null}}return s}},A=(t,e)=>!h(t,e),E={attribute:!0,type:String,converter:g,reflect:!1,useDefault:!1,hasChanged:A};
|
|
8
8
|
/**
|
|
9
9
|
* @license
|
|
10
10
|
* Copyright 2017 Google LLC
|
|
11
11
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
12
|
-
*/Symbol.metadata??=Symbol("metadata"),$.litPropertyMetadata??=new WeakMap;let S=class 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,e=E){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const s=Symbol(),r=this.getPropertyDescriptor(t,s,e);void 0!==r&&p(this.prototype,t,r)}}static getPropertyDescriptor(t,e,s){const{get:r,set:o}=d(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:r,set(e){const i=r?.call(this);o?.call(this,e),this.requestUpdate(t,i,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??E}static _$Ei(){if(this.hasOwnProperty(
|
|
12
|
+
*/Symbol.metadata??=Symbol("metadata"),$.litPropertyMetadata??=new WeakMap;let S=class 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,e=E){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const s=Symbol(),r=this.getPropertyDescriptor(t,s,e);void 0!==r&&p(this.prototype,t,r)}}static getPropertyDescriptor(t,e,s){const{get:r,set:o}=d(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:r,set(e){const i=r?.call(this);o?.call(this,e),this.requestUpdate(t,i,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??E}static _$Ei(){if(this.hasOwnProperty(b("elementProperties")))return;const t=f(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(b("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(b("properties"))){const t=this.properties,e=[...u(t),...m(t)];for(const s of e)this.createProperty(s,t[s])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,s]of e)this.elementProperties.set(t,s)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const s=this._$Eu(t,e);void 0!==s&&this._$Eh.set(s,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const s=new Set(t.flat(1/0).reverse());for(const t of s)e.unshift(c(t))}else void 0!==t&&e.push(c(t));return e}static _$Eu(t,e){const s=e.attribute;return!1===s?void 0:"string"==typeof s?s:"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._$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,e=this.constructor.elementProperties;for(const s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,e)=>{if(o)t.adoptedStyleSheets=e.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const s of e){const e=document.createElement("style"),o=r.litNonce;void 0!==o&&e.setAttribute("nonce",o),e.textContent=s.cssText,t.appendChild(e)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$ET(t,e){const s=this.constructor.elementProperties.get(t),r=this.constructor._$Eu(t,s);if(void 0!==r&&!0===s.reflect){const o=(void 0!==s.converter?.toAttribute?s.converter:g).toAttribute(e,s.type);this._$Em=t,null==o?this.removeAttribute(r):this.setAttribute(r,o),this._$Em=null}}_$AK(t,e){const s=this.constructor,r=s._$Eh.get(t);if(void 0!==r&&this._$Em!==r){const t=s.getPropertyOptions(r),o="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:g;this._$Em=r;const i=o.fromAttribute(e,t.type);this[r]=i??this._$Ej?.get(r)??i,this._$Em=null}}requestUpdate(t,e,s){if(void 0!==t){const r=this.constructor,o=this[t];if(s??=r.getPropertyOptions(t),!((s.hasChanged??A)(o,e)||s.useDefault&&s.reflect&&o===this._$Ej?.get(t)&&!this.hasAttribute(r._$Eu(t,s))))return;this.C(t,e,s)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:s,reflect:r,wrapped:o},i){s&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,i??e??this[t]),!0!==o||void 0!==i)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),!0===r&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;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,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,s]of t){const{wrapped:t}=s,r=this[e];!0!==t||this._$AL.has(e)||void 0===r||this.C(e,void 0,s,r)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(t=>t.hostUpdate?.()),this.update(e)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(t=>t.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach(t=>this._$ET(t,this[t])),this._$EM()}updated(t){}firstUpdated(t){}};S.elementStyles=[],S.shadowRootOptions={mode:"open"},S[b("elementProperties")]=new Map,S[b("finalized")]=new Map,_?.({ReactiveElement:S}),($.reactiveElementVersions??=[]).push("2.1.1");
|
|
13
13
|
/**
|
|
14
14
|
* @license
|
|
15
15
|
* Copyright 2017 Google LLC
|
|
16
16
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
17
17
|
*/
|
|
18
|
-
const w=globalThis,x=w.trustedTypes,C=x?x.createPolicy("lit-html",{createHTML:t=>t}):void 0,P="$lit$",k=`lit$${Math.random().toFixed(9).slice(2)}$`,U="?"+k,O=`<${U}>`,T=document,M=()=>T.createComment(""),R=t=>null===t||"object"!=typeof t&&"function"!=typeof t,N=Array.isArray,H="[ \t\n\f\r]",j=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,B=/-->/g,D=/>/g,
|
|
18
|
+
const w=globalThis,x=w.trustedTypes,C=x?x.createPolicy("lit-html",{createHTML:t=>t}):void 0,P="$lit$",k=`lit$${Math.random().toFixed(9).slice(2)}$`,U="?"+k,O=`<${U}>`,T=document,M=()=>T.createComment(""),R=t=>null===t||"object"!=typeof t&&"function"!=typeof t,N=Array.isArray,H="[ \t\n\f\r]",j=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,B=/-->/g,D=/>/g,L=RegExp(`>|${H}(?:([^\\s"'>=/]+)(${H}*=${H}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),z=/'/g,I=/"/g,q=/^(?:script|style|textarea|title)$/i,W=(t=>(e,...s)=>({_$litType$:t,strings:e,values:s}))(1),V=Symbol.for("lit-noChange"),K=Symbol.for("lit-nothing"),J=new WeakMap,Z=T.createTreeWalker(T,129);function F(t,e){if(!N(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==C?C.createHTML(e):e}const G=(t,e)=>{const s=t.length-1,r=[];let o,i=2===e?"<svg>":3===e?"<math>":"",n=j;for(let e=0;e<s;e++){const s=t[e];let a,l,c=-1,h=0;for(;h<s.length&&(n.lastIndex=h,l=n.exec(s),null!==l);)h=n.lastIndex,n===j?"!--"===l[1]?n=B:void 0!==l[1]?n=D:void 0!==l[2]?(q.test(l[2])&&(o=RegExp("</"+l[2],"g")),n=L):void 0!==l[3]&&(n=L):n===L?">"===l[0]?(n=o??j,c=-1):void 0===l[1]?c=-2:(c=n.lastIndex-l[2].length,a=l[1],n=void 0===l[3]?L:'"'===l[3]?I:z):n===I||n===z?n=L:n===B||n===D?n=j:(n=L,o=void 0);const p=n===L&&t[e+1].startsWith("/>")?" ":"";i+=n===j?s+O:c>=0?(r.push(a),s.slice(0,c)+P+s.slice(c)+k+p):s+k+(-2===c?e:p)}return[F(t,i+(t[s]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),r]};class Q{constructor({strings:t,_$litType$:e},s){let r;this.parts=[];let o=0,i=0;const n=t.length-1,a=this.parts,[l,c]=G(t,e);if(this.el=Q.createElement(l,s),Z.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(r=Z.nextNode())&&a.length<n;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(P)){const e=c[i++],s=r.getAttribute(t).split(k),n=/([.?@])?(.*)/.exec(e);a.push({type:1,index:o,name:n[2],strings:s,ctor:"."===n[1]?st:"?"===n[1]?rt:"@"===n[1]?ot:et}),r.removeAttribute(t)}else t.startsWith(k)&&(a.push({type:6,index:o}),r.removeAttribute(t));if(q.test(r.tagName)){const t=r.textContent.split(k),e=t.length-1;if(e>0){r.textContent=x?x.emptyScript:"";for(let s=0;s<e;s++)r.append(t[s],M()),Z.nextNode(),a.push({type:2,index:++o});r.append(t[e],M())}}}else if(8===r.nodeType)if(r.data===U)a.push({type:2,index:o});else{let t=-1;for(;-1!==(t=r.data.indexOf(k,t+1));)a.push({type:7,index:o}),t+=k.length-1}o++}}static createElement(t,e){const s=T.createElement("template");return s.innerHTML=t,s}}function X(t,e,s=t,r){if(e===V)return e;let o=void 0!==r?s._$Co?.[r]:s._$Cl;const i=R(e)?void 0:e._$litDirective$;return o?.constructor!==i&&(o?._$AO?.(!1),void 0===i?o=void 0:(o=new i(t),o._$AT(t,s,r)),void 0!==r?(s._$Co??=[])[r]=o:s._$Cl=o),void 0!==o&&(e=X(t,o._$AS(t,e.values),o,r)),e}class Y{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:s}=this._$AD,r=(t?.creationScope??T).importNode(e,!0);Z.currentNode=r;let o=Z.nextNode(),i=0,n=0,a=s[0];for(;void 0!==a;){if(i===a.index){let e;2===a.type?e=new tt(o,o.nextSibling,this,t):1===a.type?e=new a.ctor(o,a.name,a.strings,this,t):6===a.type&&(e=new it(o,this,t)),this._$AV.push(e),a=s[++n]}i!==a?.index&&(o=Z.nextNode(),i++)}return Z.currentNode=T,r}p(t){let e=0;for(const s of this._$AV)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}}class tt{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,r){this.type=2,this._$AH=K,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=r,this._$Cv=r?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=X(this,t,e),R(t)?t===K||null==t||""===t?(this._$AH!==K&&this._$AR(),this._$AH=K):t!==this._$AH&&t!==V&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>N(t)||"function"==typeof t?.[Symbol.iterator])(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!==K&&R(this._$AH)?this._$AA.nextSibling.data=t:this.T(T.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:s}=t,r="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=Q.createElement(F(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===r)this._$AH.p(e);else{const t=new Y(r,this),s=t.u(this.options);t.p(e),this.T(s),this._$AH=t}}_$AC(t){let e=J.get(t.strings);return void 0===e&&J.set(t.strings,e=new Q(t)),e}k(t){N(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let s,r=0;for(const o of t)r===e.length?e.push(s=new tt(this.O(M()),this.O(M()),this,this.options)):s=e[r],s._$AI(o),r++;r<e.length&&(this._$AR(s&&s._$AB.nextSibling,r),e.length=r)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class et{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,r,o){this.type=1,this._$AH=K,this._$AN=void 0,this.element=t,this.name=e,this._$AM=r,this.options=o,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=K}_$AI(t,e=this,s,r){const o=this.strings;let i=!1;if(void 0===o)t=X(this,t,e,0),i=!R(t)||t!==this._$AH&&t!==V,i&&(this._$AH=t);else{const r=t;let n,a;for(t=o[0],n=0;n<o.length-1;n++)a=X(this,r[s+n],e,n),a===V&&(a=this._$AH[n]),i||=!R(a)||a!==this._$AH[n],a===K?t=K:t!==K&&(t+=(a??"")+o[n+1]),this._$AH[n]=a}i&&!r&&this.j(t)}j(t){t===K?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class st extends et{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===K?void 0:t}}class rt extends et{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==K)}}class ot extends et{constructor(t,e,s,r,o){super(t,e,s,r,o),this.type=5}_$AI(t,e=this){if((t=X(this,t,e,0)??K)===V)return;const s=this._$AH,r=t===K&&s!==K||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,o=t!==K&&(s===K||r);r&&this.element.removeEventListener(this.name,this,s),o&&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 it{constructor(t,e,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){X(this,t)}}const nt=w.litHtmlPolyfillSupport;nt?.(Q,tt),(w.litHtmlVersions??=[]).push("3.3.1");const at=globalThis;
|
|
19
19
|
/**
|
|
20
20
|
* @license
|
|
21
21
|
* Copyright 2017 Google LLC
|
|
@@ -26,7 +26,7 @@ const w=globalThis,x=w.trustedTypes,C=x?x.createPolicy("lit-html",{createHTML:t=
|
|
|
26
26
|
* Copyright 2017 Google LLC
|
|
27
27
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
28
28
|
*/
|
|
29
|
-
const ht={attribute:!0,type:String,converter:
|
|
29
|
+
const ht={attribute:!0,type:String,converter:g,reflect:!1,hasChanged:A},pt=(t=ht,e,s)=>{const{kind:r,metadata:o}=s;let i=globalThis.litPropertyMetadata.get(o);if(void 0===i&&globalThis.litPropertyMetadata.set(o,i=new Map),"setter"===r&&((t=Object.create(t)).wrapped=!0),i.set(s.name,t),"accessor"===r){const{name:r}=s;return{set(s){const o=e.get.call(this);e.set.call(this,s),this.requestUpdate(r,o,t)},init(e){return void 0!==e&&this.C(r,void 0,t,e),e}}}if("setter"===r){const{name:r}=s;return function(s){const o=this[r];e.call(this,s),this.requestUpdate(r,o,t)}}throw Error("Unsupported decorator location: "+r)};
|
|
30
30
|
/**
|
|
31
31
|
* @license
|
|
32
32
|
* Copyright 2017 Google LLC
|
|
@@ -44,7 +44,7 @@ const ht={attribute:!0,type:String,converter:b,reflect:!1,hasChanged:A},pt=(t=ht
|
|
|
44
44
|
--tp-color-success: hsl(140 70% 40%);
|
|
45
45
|
--tp-color-danger: hsl(0 70% 50%);
|
|
46
46
|
--tp-color-warning: hsl(45 100% 50%);
|
|
47
|
-
--tp-color-neutral: color-mix(in
|
|
47
|
+
--tp-color-neutral: color-mix(in oklab, var(--tp-color-white) 50%, var(--tp-color-black) 50%);
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
50
|
`;var e;return document.adoptedStyleSheets=(e=[...document.adoptedStyleSheets,t.styleSheet],[...new Set(e)]),t})()}static{this.shadedElementStyles=l`
|
|
@@ -59,7 +59,7 @@ const ht={attribute:!0,type:String,converter:b,reflect:!1,hasChanged:A},pt=(t=ht
|
|
|
59
59
|
style(--tp-shade-mixer-type: black): calc(100% - ((var(--tp-shade-attr) - 500) / 500 * 100%));
|
|
60
60
|
else: calc(100% - ((500 - var(--tp-shade-attr)) / 500 * 100%))
|
|
61
61
|
);
|
|
62
|
-
--tp-calc-element-color: color-mix(in
|
|
62
|
+
--tp-calc-element-color: color-mix(in oklab, var(--tp-element-color) var(--tp-shade-mixer-percent), var(--tp-shade-mixer-color) calc(100% - var(--tp-shade-mixer-percent)));
|
|
63
63
|
--tp-calc-contrast-color: contrast-color(var(--tp-calc-element-color));
|
|
64
64
|
--tp-contrast-color: if(
|
|
65
65
|
style(--tp-calc-contrast-color: white): var(--tp-color-white);
|
|
@@ -83,7 +83,7 @@ const ht={attribute:!0,type:String,converter:b,reflect:!1,hasChanged:A},pt=(t=ht
|
|
|
83
83
|
--tp-button-contrast-color: var(--tp-calc-contrast-color);
|
|
84
84
|
--tp-button-active-mixer-color: transparent;
|
|
85
85
|
--tp-button-active-mixer-percentage: 10%;
|
|
86
|
-
--tp-button-active-color: color-mix(in
|
|
86
|
+
--tp-button-active-color: color-mix(in oklab, var(--tp-button-color) var(--tp-button-active-mixer-percentage), var(--tp-button-active-mixer-color) calc(100% - var(--tp-button-active-mixer-percentage)));
|
|
87
87
|
display: inline-block;
|
|
88
88
|
border: 1px solid transparent;
|
|
89
89
|
cursor: pointer;
|
|
@@ -103,7 +103,7 @@ const ht={attribute:!0,type:String,converter:b,reflect:!1,hasChanged:A},pt=(t=ht
|
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
&[disabled] {
|
|
106
|
-
--tp-button-color: color-mix(in
|
|
106
|
+
--tp-button-color: color-mix(in oklab, var(--tp-calc-element-color) 50%, var(--tp-color-white) 50%);
|
|
107
107
|
--tp-button-contrast-color: rgb(from var(--tp-calc-contrast-color) r g b / 50%);
|
|
108
108
|
pointer-events: none;
|
|
109
109
|
user-select: none;
|