Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@phase2/outline-controller-light-dom-styles-controller

Package Overview
Dependencies
Maintainers
9
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@phase2/outline-controller-light-dom-styles-controller - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

12

dist/index.js

@@ -1,7 +0,5 @@

"use strict";(()=>{var I=window,z=I.ShadowRoot&&(I.ShadyCSS===void 0||I.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,$t=Symbol(),ft=new WeakMap,w=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==$t)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(z&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=ft.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&ft.set(e,t))}return t}toString(){return this.cssText}},vt=i=>new w(typeof i=="string"?i:i+"",void 0,$t);var J=(i,t)=>{z?i.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet):t.forEach(e=>{let s=document.createElement("style"),n=I.litNonce;n!==void 0&&s.setAttribute("nonce",n),s.textContent=e.cssText,i.appendChild(s)})},B=z?i=>i:i=>i instanceof CSSStyleSheet?(t=>{let e="";for(let s of t.cssRules)e+=s.cssText;return vt(e)})(i):i;var Q,G=window,yt=G.trustedTypes,ie=yt?yt.emptyScript:"",gt=G.reactiveElementPolyfillSupport,Y={toAttribute(i,t){switch(t){case Boolean:i=i?ie:null;break;case Object:case Array:i=i==null?i:JSON.stringify(i)}return i},fromAttribute(i,t){let e=i;switch(t){case Boolean:e=i!==null;break;case Number:e=i===null?null:Number(i);break;case Object:case Array:try{e=JSON.parse(i)}catch{e=null}}return e}},_t=(i,t)=>t!==i&&(t==t||i==i),X={attribute:!0,type:String,converter:Y,reflect:!1,hasChanged:_t},E=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(t){var e;(e=this.h)!==null&&e!==void 0||(this.h=[]),this.h.push(t)}static get observedAttributes(){this.finalize();let t=[];return this.elementProperties.forEach((e,s)=>{let n=this._$Ep(s,e);n!==void 0&&(this._$Ev.set(n,s),t.push(n))}),t}static createProperty(t,e=X){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){let s=typeof t=="symbol"?Symbol():"__"+t,n=this.getPropertyDescriptor(t,s,e);n!==void 0&&Object.defineProperty(this.prototype,t,n)}}static getPropertyDescriptor(t,e,s){return{get(){return this[e]},set(n){let r=this[t];this[e]=n,this.requestUpdate(t,r,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||X}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;let t=Object.getPrototypeOf(this);if(t.finalize(),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){let e=this.properties,s=[...Object.getOwnPropertyNames(e),...Object.getOwnPropertySymbols(e)];for(let n of s)this.createProperty(n,e[n])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let s=new Set(t.flat(1/0).reverse());for(let n of s)e.unshift(B(n))}else t!==void 0&&e.push(B(t));return e}static _$Ep(t,e){let s=e.attribute;return s===!1?void 0:typeof s=="string"?s:typeof t=="string"?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$Eg(),this.requestUpdate(),(t=this.constructor.h)===null||t===void 0||t.forEach(e=>e(this))}addController(t){var e,s;((e=this._$ES)!==null&&e!==void 0?e:this._$ES=[]).push(t),this.renderRoot!==void 0&&this.isConnected&&((s=t.hostConnected)===null||s===void 0||s.call(t))}removeController(t){var e;(e=this._$ES)===null||e===void 0||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])})}createRenderRoot(){var t;let e=(t=this.shadowRoot)!==null&&t!==void 0?t:this.attachShadow(this.constructor.shadowRootOptions);return J(e,this.constructor.elementStyles),e}connectedCallback(){var t;this.renderRoot===void 0&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(t=this._$ES)===null||t===void 0||t.forEach(e=>{var s;return(s=e.hostConnected)===null||s===void 0?void 0:s.call(e)})}enableUpdating(t){}disconnectedCallback(){var t;(t=this._$ES)===null||t===void 0||t.forEach(e=>{var s;return(s=e.hostDisconnected)===null||s===void 0?void 0:s.call(e)})}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$EO(t,e,s=X){var n;let r=this.constructor._$Ep(t,s);if(r!==void 0&&s.reflect===!0){let a=(((n=s.converter)===null||n===void 0?void 0:n.toAttribute)!==void 0?s.converter:Y).toAttribute(e,s.type);this._$El=t,a==null?this.removeAttribute(r):this.setAttribute(r,a),this._$El=null}}_$AK(t,e){var s;let n=this.constructor,r=n._$Ev.get(t);if(r!==void 0&&this._$El!==r){let a=n.getPropertyOptions(r),u=typeof a.converter=="function"?{fromAttribute:a.converter}:((s=a.converter)===null||s===void 0?void 0:s.fromAttribute)!==void 0?a.converter:Y;this._$El=r,this[r]=u.fromAttribute(e,a.type),this._$El=null}}requestUpdate(t,e,s){let n=!0;t!==void 0&&(((s=s||this.constructor.getPropertyOptions(t)).hasChanged||_t)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),s.reflect===!0&&this._$El!==t&&(this._$EC===void 0&&(this._$EC=new Map),this._$EC.set(t,s))):n=!1),!this.isUpdatePending&&n&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach((n,r)=>this[r]=n),this._$Ei=void 0);let e=!1,s=this._$AL;try{e=this.shouldUpdate(s),e?(this.willUpdate(s),(t=this._$ES)===null||t===void 0||t.forEach(n=>{var r;return(r=n.hostUpdate)===null||r===void 0?void 0:r.call(n)}),this.update(s)):this._$Ek()}catch(n){throw e=!1,this._$Ek(),n}e&&this._$AE(s)}willUpdate(t){}_$AE(t){var e;(e=this._$ES)===null||e===void 0||e.forEach(s=>{var n;return(n=s.hostUpdated)===null||n===void 0?void 0:n.call(s)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){this._$EC!==void 0&&(this._$EC.forEach((e,s)=>this._$EO(s,this[s],e)),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}};E.finalized=!0,E.elementProperties=new Map,E.elementStyles=[],E.shadowRootOptions={mode:"open"},gt?.({ReactiveElement:E}),((Q=G.reactiveElementVersions)!==null&&Q!==void 0?Q:G.reactiveElementVersions=[]).push("1.4.1");var tt,F=window,H=F.trustedTypes,At=H?H.createPolicy("lit-html",{createHTML:i=>i}):void 0,b=`lit$${(Math.random()+"").slice(9)}$`,Rt="?"+b,ne=`<${Rt}>`,O=document,T=(i="")=>O.createComment(i),j=i=>i===null||typeof i!="object"&&typeof i!="function",Pt=Array.isArray,re=i=>Pt(i)||typeof i?.[Symbol.iterator]=="function",V=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,St=/-->/g,Et=/>/g,x=RegExp(`>|[
\f\r](?:([^\\s"'>=/]+)([
\f\r]*=[
\f\r]*(?:[^
\f\r"'\`<>=]|("|')|))|$)`,"g"),bt=/'/g,wt=/"/g,kt=/^(?:script|style|textarea|title)$/i,Ut=i=>(t,...e)=>({_$litType$:i,strings:t,values:e}),Ae=Ut(1),Se=Ut(2),C=Symbol.for("lit-noChange"),g=Symbol.for("lit-nothing"),xt=new WeakMap,U=O.createTreeWalker(O,129,null,!1),oe=(i,t)=>{let e=i.length-1,s=[],n,r=t===2?"<svg>":"",a=V;for(let p=0;p<e;p++){let h=i[p],y,f,c=-1,_=0;for(;_<h.length&&(a.lastIndex=_,f=a.exec(h),f!==null);)_=a.lastIndex,a===V?f[1]==="!--"?a=St:f[1]!==void 0?a=Et:f[2]!==void 0?(kt.test(f[2])&&(n=RegExp("</"+f[2],"g")),a=x):f[3]!==void 0&&(a=x):a===x?f[0]===">"?(a=n??V,c=-1):f[1]===void 0?c=-2:(c=a.lastIndex-f[2].length,y=f[1],a=f[3]===void 0?x:f[3]==='"'?wt:bt):a===wt||a===bt?a=x:a===St||a===Et?a=V:(a=x,n=void 0);let v=a===x&&i[p+1].startsWith("/>")?" ":"";r+=a===V?h+ne:c>=0?(s.push(y),h.slice(0,c)+"$lit$"+h.slice(c)+b+v):h+b+(c===-2?(s.push(void 0),p):v)}let u=r+(i[e]||"<?>")+(t===2?"</svg>":"");if(!Array.isArray(i)||!i.hasOwnProperty("raw"))throw Error("invalid template strings array");return[At!==void 0?At.createHTML(u):u,s]},R=class{constructor({strings:t,_$litType$:e},s){let n;this.parts=[];let r=0,a=0,u=t.length-1,p=this.parts,[h,y]=oe(t,e);if(this.el=R.createElement(h,s),U.currentNode=this.el.content,e===2){let f=this.el.content,c=f.firstChild;c.remove(),f.append(...c.childNodes)}for(;(n=U.nextNode())!==null&&p.length<u;){if(n.nodeType===1){if(n.hasAttributes()){let f=[];for(let c of n.getAttributeNames())if(c.endsWith("$lit$")||c.startsWith(b)){let _=y[a++];if(f.push(c),_!==void 0){let v=n.getAttribute(_.toLowerCase()+"$lit$").split(b),k=/([.?@])?(.*)/.exec(_);p.push({type:1,index:r,name:k[2],strings:v,ctor:k[1]==="."?st:k[1]==="?"?it:k[1]==="@"?nt:M})}else p.push({type:6,index:r})}for(let c of f)n.removeAttribute(c)}if(kt.test(n.tagName)){let f=n.textContent.split(b),c=f.length-1;if(c>0){n.textContent=H?H.emptyScript:"";for(let _=0;_<c;_++)n.append(f[_],T()),U.nextNode(),p.push({type:2,index:++r});n.append(f[c],T())}}}else if(n.nodeType===8)if(n.data===Rt)p.push({type:2,index:r});else{let f=-1;for(;(f=n.data.indexOf(b,f+1))!==-1;)p.push({type:7,index:r}),f+=b.length-1}r++}}static createElement(t,e){let s=O.createElement("template");return s.innerHTML=t,s}};function N(i,t,e=i,s){var n,r,a,u;if(t===C)return t;let p=s!==void 0?(n=e._$Co)===null||n===void 0?void 0:n[s]:e._$Cl,h=j(t)?void 0:t._$litDirective$;return p?.constructor!==h&&((r=p?._$AO)===null||r===void 0||r.call(p,!1),h===void 0?p=void 0:(p=new h(i),p._$AT(i,e,s)),s!==void 0?((a=(u=e)._$Co)!==null&&a!==void 0?a:u._$Co=[])[s]=p:e._$Cl=p),p!==void 0&&(t=N(i,p._$AS(i,t.values),p,s)),t}var et=class{constructor(t,e){this.u=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}v(t){var e;let{el:{content:s},parts:n}=this._$AD,r=((e=t?.creationScope)!==null&&e!==void 0?e:O).importNode(s,!0);U.currentNode=r;let a=U.nextNode(),u=0,p=0,h=n[0];for(;h!==void 0;){if(u===h.index){let y;h.type===2?y=new P(a,a.nextSibling,this,t):h.type===1?y=new h.ctor(a,h.name,h.strings,this,t):h.type===6&&(y=new rt(a,this,t)),this.u.push(y),h=n[++p]}u!==h?.index&&(a=U.nextNode(),u++)}return r}p(t){let e=0;for(let s of this.u)s!==void 0&&(s.strings!==void 0?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}},P=class{constructor(t,e,s,n){var r;this.type=2,this._$AH=g,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=n,this._$Cm=(r=n?.isConnected)===null||r===void 0||r}get _$AU(){var t,e;return(e=(t=this._$AM)===null||t===void 0?void 0:t._$AU)!==null&&e!==void 0?e:this._$Cm}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=N(this,t,e),j(t)?t===g||t==null||t===""?(this._$AH!==g&&this._$AR(),this._$AH=g):t!==this._$AH&&t!==C&&this.g(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):re(t)?this.k(t):this.g(t)}O(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}g(t){this._$AH!==g&&j(this._$AH)?this._$AA.nextSibling.data=t:this.T(O.createTextNode(t)),this._$AH=t}$(t){var e;let{values:s,_$litType$:n}=t,r=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=R.createElement(n.h,this.options)),n);if(((e=this._$AH)===null||e===void 0?void 0:e._$AD)===r)this._$AH.p(s);else{let a=new et(r,this),u=a.v(this.options);a.p(s),this.T(u),this._$AH=a}}_$AC(t){let e=xt.get(t.strings);return e===void 0&&xt.set(t.strings,e=new R(t)),e}k(t){Pt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,n=0;for(let r of t)n===e.length?e.push(s=new P(this.O(T()),this.O(T()),this,this.options)):s=e[n],s._$AI(r),n++;n<e.length&&(this._$AR(s&&s._$AB.nextSibling,n),e.length=n)}_$AR(t=this._$AA.nextSibling,e){var s;for((s=this._$AP)===null||s===void 0||s.call(this,!1,!0,e);t&&t!==this._$AB;){let n=t.nextSibling;t.remove(),t=n}}setConnected(t){var e;this._$AM===void 0&&(this._$Cm=t,(e=this._$AP)===null||e===void 0||e.call(this,t))}},M=class{constructor(t,e,s,n,r){this.type=1,this._$AH=g,this._$AN=void 0,this.element=t,this.name=e,this._$AM=n,this.options=r,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=g}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,s,n){let r=this.strings,a=!1;if(r===void 0)t=N(this,t,e,0),a=!j(t)||t!==this._$AH&&t!==C,a&&(this._$AH=t);else{let u=t,p,h;for(t=r[0],p=0;p<r.length-1;p++)h=N(this,u[s+p],e,p),h===C&&(h=this._$AH[p]),a||(a=!j(h)||h!==this._$AH[p]),h===g?t=g:t!==g&&(t+=(h??"")+r[p+1]),this._$AH[p]=h}a&&!n&&this.j(t)}j(t){t===g?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},st=class extends M{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===g?void 0:t}},ae=H?H.emptyScript:"",it=class extends M{constructor(){super(...arguments),this.type=4}j(t){t&&t!==g?this.element.setAttribute(this.name,ae):this.element.removeAttribute(this.name)}},nt=class extends M{constructor(t,e,s,n,r){super(t,e,s,n,r),this.type=5}_$AI(t,e=this){var s;if((t=(s=N(this,t,e,0))!==null&&s!==void 0?s:g)===C)return;let n=this._$AH,r=t===g&&n!==g||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,a=t!==g&&(n===g||r);r&&this.element.removeEventListener(this.name,this,n),a&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,s;typeof this._$AH=="function"?this._$AH.call((s=(e=this.options)===null||e===void 0?void 0:e.host)!==null&&s!==void 0?s:this.element,t):this._$AH.handleEvent(t)}},rt=class{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){N(this,t)}};var Ct=F.litHtmlPolyfillSupport;Ct?.(R,P),((tt=F.litHtmlVersions)!==null&&tt!==void 0?tt:F.litHtmlVersions=[]).push("2.4.0");var Ht=(i,t,e)=>{var s,n;let r=(s=e?.renderBefore)!==null&&s!==void 0?s:t,a=r._$litPart$;if(a===void 0){let u=(n=e?.renderBefore)!==null&&n!==void 0?n:null;r._$litPart$=a=new P(t.insertBefore(T(),u),u,void 0,e??{})}return a._$AI(i),a};var ot,at;var L=class extends E{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,e;let s=super.createRenderRoot();return(t=(e=this.renderOptions).renderBefore)!==null&&t!==void 0||(e.renderBefore=s.firstChild),s}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=Ht(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),(t=this._$Do)===null||t===void 0||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this._$Do)===null||t===void 0||t.setConnected(!1)}render(){return C}};L.finalized=!0,L._$litElement$=!0,(ot=globalThis.litElementHydrateSupport)===null||ot===void 0||ot.call(globalThis,{LitElement:L});var Ot=globalThis.litElementPolyfillSupport;Ot?.({LitElement:L});((at=globalThis.litElementVersions)!==null&&at!==void 0?at:globalThis.litElementVersions=[]).push("3.2.2");function Mt(i){Object.defineProperty(i,"__esModule",{value:!0,configurable:!0})}function ct(i,t,e,s){Object.defineProperty(i,t,{get:e,set:s,enumerable:!0,configurable:!0})}var Lt={};Mt(Lt);ct(Lt,"default",()=>W);var W=class extends Error{constructor(t,e,s,n,r){super(t+":"+s+":"+n+": "+e),this.reason=e,this.filename=t,this.line=s,this.column=n,this.source=r}},Vt={};Mt(Vt);ct(Vt,"default",()=>q);var q=class{constructor(t,e,s){this.start=t,this.end=e,this.source=s}},le={};ct(le,"CssTypes",()=>d);var d;(function(i){i.stylesheet="stylesheet",i.rule="rule",i.declaration="declaration",i.comment="comment",i.container="container",i.charset="charset",i.document="document",i.customMedia="custom-media",i.fontFace="font-face",i.host="host",i.import="import",i.keyframes="keyframes",i.keyframe="keyframe",i.layer="layer",i.media="media",i.namespace="namespace",i.page="page",i.supports="supports"})(d||(d={}));var Nt=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,he=(i,t)=>{t=t||{};let e=1,s=1;function n(l){let o=l.match(/\n/g);o&&(e+=o.length);let m=l.lastIndexOf(`
`);s=~m?l.length-m:s+l.length}function r(){let l={line:e,column:s};return function(o){return o.position=new q(l,{line:e,column:s},t?.source||""),_(),o}}let a=[];function u(l){let o=new W(t?.source||"",l,e,s,i);if(t?.silent)a.push(o);else throw o}function p(){let l=f();return{type:d.stylesheet,stylesheet:{source:t?.source,rules:l,parsingErrors:a}}}function h(){return c(/^{\s*/)}function y(){return c(/^}/)}function f(){let l,o=[];for(_(),v(o);i.length&&i.charAt(0)!=="}"&&(l=ee()||se());)l&&(o.push(l),v(o));return o}function c(l){let o=l.exec(i);if(!o)return;let m=o[0];return n(m),i=i.slice(m.length),o}function _(){c(/^\s*/)}function v(l){let o;for(l=l||[];o=k();)o&&l.push(o);return l}function k(){let l=r();if(i.charAt(0)!=="/"||i.charAt(1)!=="*")return;let o=c(/^\/\*[^]*?\*\//);return o?l({type:d.comment,comment:o[0].slice(2,-2)}):u("End of comment missing")}function pt(){let l=c(/^([^{]+)/);if(!l)return;let o=A(l[0]).replace(/\/\*[^]*?\*\//gm,"");return o.indexOf(",")===-1?[o]:o.replace(/("|')(?:\\\1|.)*?\1|\(.*?\)/g,m=>m.replace(/,/g,"\u200C")).split(",").map(m=>A(m.replace(/\u200C/g,",")))}function K(){let l=r(),o=c(/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/);if(!o)return;let m=A(o[0]);if(!c(/^:\s*/))return u("property missing ':'");let $=c(/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/),S=l({type:d.declaration,property:m.replace(Nt,""),value:$?A($[0]).replace(Nt,""):""});return c(/^[;\s]*/),S}function mt(){let l=[];if(!h())return u("missing '{'");v(l);let o;for(;o=K();)o&&(l.push(o),v(l));return y()?l:u("missing '}'")}function It(){let l,o=[],m=r();for(;l=c(/^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/);)o.push(l[1]),c(/^,\s*/);if(!!o.length)return m({type:d.keyframe,values:o,declarations:mt()||[]})}function zt(){let l=r(),o=c(/^@([-\w]+)?keyframes\s*/);if(!o)return;let m=o[1],$=c(/^([-\w]+)\s*/);if(!$)return u("@keyframes missing name");let S=$[1];if(!h())return u("@keyframes missing '{'");let dt,D=v();for(;dt=It();)D.push(dt),D=D.concat(v());return y()?l({type:d.keyframes,name:S,vendor:m,keyframes:D}):u("@keyframes missing '}'")}function Bt(){let l=r(),o=c(/^@supports *([^{]+)/);if(!o)return;let m=A(o[1]);if(!h())return u("@supports missing '{'");let $=v().concat(f());return y()?l({type:d.supports,supports:m,rules:$}):u("@supports missing '}'")}function Gt(){let l=r();if(!c(/^@host\s*/))return;if(!h())return u("@host missing '{'");let m=v().concat(f());return y()?l({type:d.host,rules:m}):u("@host missing '}'")}function Ft(){let l=r(),o=c(/^@container *([^{]+)/);if(!o)return;let m=A(o[1]);if(!h())return u("@container missing '{'");let $=v().concat(f());return y()?l({type:d.container,container:m,rules:$}):u("@container missing '}'")}function Wt(){let l=r(),o=c(/^@layer *([^{;@]+)/);if(!o)return;let m=A(o[1]);if(!h())return c(/^[;\s]*/),l({type:d.layer,layer:m});let $=v().concat(f());return y()?l({type:d.layer,layer:m,rules:$}):u("@layer missing '}'")}function qt(){let l=r(),o=c(/^@media *([^{]+)/);if(!o)return;let m=A(o[1]);if(!h())return u("@media missing '{'");let $=v().concat(f());return y()?l({type:d.media,media:m,rules:$}):u("@media missing '}'")}function Kt(){let l=r(),o=c(/^@custom-media\s+(--[^\s]+)\s*([^{;]+);/);if(!!o)return l({type:d.customMedia,name:A(o[1]),media:A(o[2])})}function Zt(){let l=r();if(!c(/^@page */))return;let m=pt()||[];if(!h())return u("@page missing '{'");let $=v(),S;for(;S=K();)$.push(S),$=$.concat(v());return y()?l({type:d.page,selectors:m,declarations:$}):u("@page missing '}'")}function Jt(){let l=r(),o=c(/^@([-\w]+)?document *([^{]+)/);if(!o)return;let m=A(o[1]),$=A(o[2]);if(!h())return u("@document missing '{'");let S=v().concat(f());return y()?l({type:d.document,document:$,vendor:m,rules:S}):u("@document missing '}'")}function Qt(){let l=r();if(!c(/^@font-face\s*/))return;if(!h())return u("@font-face missing '{'");let m=v(),$;for(;$=K();)m.push($),m=m.concat(v());return y()?l({type:d.fontFace,declarations:m}):u("@font-face missing '}'")}let Xt=Z("import"),Yt=Z("charset"),te=Z("namespace");function Z(l){let o=new RegExp("^@"+l+`\\s*((:?[^;'"]|"(?:\\\\"|[^"])*?"|'(?:\\\\'|[^'])*?')+);`);return function(){let m=r(),$=c(o);if(!$)return;let S={type:l};return S[l]=$[1].trim(),m(S)}}function ee(){if(i[0]==="@")return zt()||qt()||Kt()||Bt()||Xt()||Yt()||te()||Jt()||Zt()||Gt()||Qt()||Ft()||Wt()}function se(){let l=r(),o=pt();return o?(v(),l({type:d.rule,selectors:o,declarations:mt()||[]})):u("selector missing")}return lt(p())};function A(i){return i?i.trim():""}function lt(i,t){let e=i&&typeof i.type=="string",s=e?i:t;for(let n in i){let r=i[n];Array.isArray(r)?r.forEach(a=>{lt(a,s)}):r&&typeof r=="object"&&lt(r,s)}return e&&Object.defineProperty(i,"parent",{configurable:!0,writable:!0,enumerable:!1,value:t||null}),i}var ce=he,ht=class{constructor(t){this.level=0,this.indentation=" ",this.compress=!1,typeof t?.indent=="string"&&(this.indentation=t?.indent),t?.compress&&(this.compress=!0)}emit(t,e){return t}indent(t){return this.level=this.level||1,t?(this.level+=t,""):Array(this.level).join(this.indentation)}visit(t){switch(t.type){case d.stylesheet:return this.stylesheet(t);case d.rule:return this.rule(t);case d.declaration:return this.declaration(t);case d.comment:return this.comment(t);case d.container:return this.container(t);case d.charset:return this.charset(t);case d.document:return this.document(t);case d.customMedia:return this.customMedia(t);case d.fontFace:return this.fontFace(t);case d.host:return this.host(t);case d.import:return this.import(t);case d.keyframes:return this.keyframes(t);case d.keyframe:return this.keyframe(t);case d.layer:return this.layer(t);case d.media:return this.media(t);case d.namespace:return this.namespace(t);case d.page:return this.page(t);case d.supports:return this.supports(t)}}mapVisit(t,e){let s="";e=e||"";for(let n=0,r=t.length;n<r;n++)s+=this.visit(t[n]),e&&n<r-1&&(s+=this.emit(e));return s}compile(t){return this.compress?t.stylesheet.rules.map(this.visit,this).join(""):this.stylesheet(t)}stylesheet(t){return this.mapVisit(t.stylesheet.rules,`
"use strict";(()=>{var D=window,B=D.ShadowRoot&&(D.ShadyCSS===void 0||D.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,_t=Symbol(),gt=new WeakMap,w=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==_t)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o,e=this.t;if(B&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=gt.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&gt.set(e,t))}return t}toString(){return this.cssText}},At=i=>new w(typeof i=="string"?i:i+"",void 0,_t);var Z=(i,t)=>{B?i.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet):t.forEach(e=>{let s=document.createElement("style"),n=D.litNonce;n!==void 0&&s.setAttribute("nonce",n),s.textContent=e.cssText,i.appendChild(s)})},z=B?i=>i:i=>i instanceof CSSStyleSheet?(t=>{let e="";for(let s of t.cssRules)e+=s.cssText;return At(e)})(i):i;var Q,G=window,St=G.trustedTypes,ae=St?St.emptyScript:"",Et=G.reactiveElementPolyfillSupport,Y={toAttribute(i,t){switch(t){case Boolean:i=i?ae:null;break;case Object:case Array:i=i==null?i:JSON.stringify(i)}return i},fromAttribute(i,t){let e=i;switch(t){case Boolean:e=i!==null;break;case Number:e=i===null?null:Number(i);break;case Object:case Array:try{e=JSON.parse(i)}catch{e=null}}return e}},bt=(i,t)=>t!==i&&(t==t||i==i),X={attribute:!0,type:String,converter:Y,reflect:!1,hasChanged:bt},tt="finalized",E=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(t){var e;this.finalize(),((e=this.h)!==null&&e!==void 0?e:this.h=[]).push(t)}static get observedAttributes(){this.finalize();let t=[];return this.elementProperties.forEach((e,s)=>{let n=this._$Ep(s,e);n!==void 0&&(this._$Ev.set(n,s),t.push(n))}),t}static createProperty(t,e=X){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){let s=typeof t=="symbol"?Symbol():"__"+t,n=this.getPropertyDescriptor(t,s,e);n!==void 0&&Object.defineProperty(this.prototype,t,n)}}static getPropertyDescriptor(t,e,s){return{get(){return this[e]},set(n){let r=this[t];this[e]=n,this.requestUpdate(t,r,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||X}static finalize(){if(this.hasOwnProperty(tt))return!1;this[tt]=!0;let t=Object.getPrototypeOf(this);if(t.finalize(),t.h!==void 0&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){let e=this.properties,s=[...Object.getOwnPropertyNames(e),...Object.getOwnPropertySymbols(e)];for(let n of s)this.createProperty(n,e[n])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let s=new Set(t.flat(1/0).reverse());for(let n of s)e.unshift(z(n))}else t!==void 0&&e.push(z(t));return e}static _$Ep(t,e){let s=e.attribute;return s===!1?void 0:typeof s=="string"?s:typeof t=="string"?t.toLowerCase():void 0}_$Eu(){var t;this._$E_=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$Eg(),this.requestUpdate(),(t=this.constructor.h)===null||t===void 0||t.forEach(e=>e(this))}addController(t){var e,s;((e=this._$ES)!==null&&e!==void 0?e:this._$ES=[]).push(t),this.renderRoot!==void 0&&this.isConnected&&((s=t.hostConnected)===null||s===void 0||s.call(t))}removeController(t){var e;(e=this._$ES)===null||e===void 0||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])})}createRenderRoot(){var t;let e=(t=this.shadowRoot)!==null&&t!==void 0?t:this.attachShadow(this.constructor.shadowRootOptions);return Z(e,this.constructor.elementStyles),e}connectedCallback(){var t;this.renderRoot===void 0&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(t=this._$ES)===null||t===void 0||t.forEach(e=>{var s;return(s=e.hostConnected)===null||s===void 0?void 0:s.call(e)})}enableUpdating(t){}disconnectedCallback(){var t;(t=this._$ES)===null||t===void 0||t.forEach(e=>{var s;return(s=e.hostDisconnected)===null||s===void 0?void 0:s.call(e)})}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$EO(t,e,s=X){var n;let r=this.constructor._$Ep(t,s);if(r!==void 0&&s.reflect===!0){let a=(((n=s.converter)===null||n===void 0?void 0:n.toAttribute)!==void 0?s.converter:Y).toAttribute(e,s.type);this._$El=t,a==null?this.removeAttribute(r):this.setAttribute(r,a),this._$El=null}}_$AK(t,e){var s;let n=this.constructor,r=n._$Ev.get(t);if(r!==void 0&&this._$El!==r){let a=n.getPropertyOptions(r),h=typeof a.converter=="function"?{fromAttribute:a.converter}:((s=a.converter)===null||s===void 0?void 0:s.fromAttribute)!==void 0?a.converter:Y;this._$El=r,this[r]=h.fromAttribute(e,a.type),this._$El=null}}requestUpdate(t,e,s){let n=!0;t!==void 0&&(((s=s||this.constructor.getPropertyOptions(t)).hasChanged||bt)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),s.reflect===!0&&this._$El!==t&&(this._$EC===void 0&&(this._$EC=new Map),this._$EC.set(t,s))):n=!1),!this.isUpdatePending&&n&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach((n,r)=>this[r]=n),this._$Ei=void 0);let e=!1,s=this._$AL;try{e=this.shouldUpdate(s),e?(this.willUpdate(s),(t=this._$ES)===null||t===void 0||t.forEach(n=>{var r;return(r=n.hostUpdate)===null||r===void 0?void 0:r.call(n)}),this.update(s)):this._$Ek()}catch(n){throw e=!1,this._$Ek(),n}e&&this._$AE(s)}willUpdate(t){}_$AE(t){var e;(e=this._$ES)===null||e===void 0||e.forEach(s=>{var n;return(n=s.hostUpdated)===null||n===void 0?void 0:n.call(s)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){this._$EC!==void 0&&(this._$EC.forEach((e,s)=>this._$EO(s,this[s],e)),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}};E[tt]=!0,E.elementProperties=new Map,E.elementStyles=[],E.shadowRootOptions={mode:"open"},Et?.({ReactiveElement:E}),((Q=G.reactiveElementVersions)!==null&&Q!==void 0?Q:G.reactiveElementVersions=[]).push("1.6.3");var et,F=window,N=F.trustedTypes,wt=N?N.createPolicy("lit-html",{createHTML:i=>i}):void 0,it="$lit$",b=`lit$${(Math.random()+"").slice(9)}$`,Ht="?"+b,le=`<${Ht}>`,P=document,T=()=>P.createComment(""),j=i=>i===null||typeof i!="object"&&typeof i!="function",Nt=Array.isArray,he=i=>Nt(i)||typeof i?.[Symbol.iterator]=="function",st=`[
\f\r]`,L=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Ct=/-->/g,xt=/>/g,C=RegExp(`>|${st}(?:([^\\s"'>=/]+)(${st}*=${st}*(?:[^
\f\r"'\`<>=]|("|')|))|$)`,"g"),Pt=/'/g,Rt=/"/g,Ot=/^(?:script|style|textarea|title)$/i,Vt=i=>(t,...e)=>({_$litType$:i,strings:t,values:e}),we=Vt(1),Ce=Vt(2),R=Symbol.for("lit-noChange"),g=Symbol.for("lit-nothing"),kt=new WeakMap,x=P.createTreeWalker(P,129,null,!1);function Mt(i,t){if(!Array.isArray(i)||!i.hasOwnProperty("raw"))throw Error("invalid template strings array");return wt!==void 0?wt.createHTML(t):t}var ce=(i,t)=>{let e=i.length-1,s=[],n,r=t===2?"<svg>":"",a=L;for(let h=0;h<e;h++){let c=i[h],u,f,$=-1,p=0;for(;p<c.length&&(a.lastIndex=p,f=a.exec(c),f!==null);)p=a.lastIndex,a===L?f[1]==="!--"?a=Ct:f[1]!==void 0?a=xt:f[2]!==void 0?(Ot.test(f[2])&&(n=RegExp("</"+f[2],"g")),a=C):f[3]!==void 0&&(a=C):a===C?f[0]===">"?(a=n??L,$=-1):f[1]===void 0?$=-2:($=a.lastIndex-f[2].length,u=f[1],a=f[3]===void 0?C:f[3]==='"'?Rt:Pt):a===Rt||a===Pt?a=C:a===Ct||a===xt?a=L:(a=C,n=void 0);let _=a===C&&i[h+1].startsWith("/>")?" ":"";r+=a===L?c+le:$>=0?(s.push(u),c.slice(0,$)+it+c.slice($)+b+_):c+b+($===-2?(s.push(void 0),h):_)}return[Mt(i,r+(i[e]||"<?>")+(t===2?"</svg>":"")),s]},k=class{constructor({strings:t,_$litType$:e},s){let n;this.parts=[];let r=0,a=0,h=t.length-1,c=this.parts,[u,f]=ce(t,e);if(this.el=k.createElement(u,s),x.currentNode=this.el.content,e===2){let $=this.el.content,p=$.firstChild;p.remove(),$.append(...p.childNodes)}for(;(n=x.nextNode())!==null&&c.length<h;){if(n.nodeType===1){if(n.hasAttributes()){let $=[];for(let p of n.getAttributeNames())if(p.endsWith(it)||p.startsWith(b)){let _=f[a++];if($.push(p),_!==void 0){let y=n.getAttribute(_.toLowerCase()+it).split(b),H=/([.?@])?(.*)/.exec(_);c.push({type:1,index:r,name:H[2],strings:y,ctor:H[1]==="."?rt:H[1]==="?"?ot:H[1]==="@"?at:V})}else c.push({type:6,index:r})}for(let p of $)n.removeAttribute(p)}if(Ot.test(n.tagName)){let $=n.textContent.split(b),p=$.length-1;if(p>0){n.textContent=N?N.emptyScript:"";for(let _=0;_<p;_++)n.append($[_],T()),x.nextNode(),c.push({type:2,index:++r});n.append($[p],T())}}}else if(n.nodeType===8)if(n.data===Ht)c.push({type:2,index:r});else{let $=-1;for(;($=n.data.indexOf(b,$+1))!==-1;)c.push({type:7,index:r}),$+=b.length-1}r++}}static createElement(t,e){let s=P.createElement("template");return s.innerHTML=t,s}};function O(i,t,e=i,s){var n,r,a,h;if(t===R)return t;let c=s!==void 0?(n=e._$Co)===null||n===void 0?void 0:n[s]:e._$Cl,u=j(t)?void 0:t._$litDirective$;return c?.constructor!==u&&((r=c?._$AO)===null||r===void 0||r.call(c,!1),u===void 0?c=void 0:(c=new u(i),c._$AT(i,e,s)),s!==void 0?((a=(h=e)._$Co)!==null&&a!==void 0?a:h._$Co=[])[s]=c:e._$Cl=c),c!==void 0&&(t=O(i,c._$AS(i,t.values),c,s)),t}var nt=class{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){var e;let{el:{content:s},parts:n}=this._$AD,r=((e=t?.creationScope)!==null&&e!==void 0?e:P).importNode(s,!0);x.currentNode=r;let a=x.nextNode(),h=0,c=0,u=n[0];for(;u!==void 0;){if(h===u.index){let f;u.type===2?f=new U(a,a.nextSibling,this,t):u.type===1?f=new u.ctor(a,u.name,u.strings,this,t):u.type===6&&(f=new lt(a,this,t)),this._$AV.push(f),u=n[++c]}h!==u?.index&&(a=x.nextNode(),h++)}return x.currentNode=P,r}v(t){let e=0;for(let s of this._$AV)s!==void 0&&(s.strings!==void 0?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}},U=class{constructor(t,e,s,n){var r;this.type=2,this._$AH=g,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=n,this._$Cp=(r=n?.isConnected)===null||r===void 0||r}get _$AU(){var t,e;return(e=(t=this._$AM)===null||t===void 0?void 0:t._$AU)!==null&&e!==void 0?e:this._$Cp}get parentNode(){let t=this._$AA.parentNode,e=this._$AM;return e!==void 0&&t?.nodeType===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=O(this,t,e),j(t)?t===g||t==null||t===""?(this._$AH!==g&&this._$AR(),this._$AH=g):t!==this._$AH&&t!==R&&this._(t):t._$litType$!==void 0?this.g(t):t.nodeType!==void 0?this.$(t):he(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!==g&&j(this._$AH)?this._$AA.nextSibling.data=t:this.$(P.createTextNode(t)),this._$AH=t}g(t){var e;let{values:s,_$litType$:n}=t,r=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=k.createElement(Mt(n.h,n.h[0]),this.options)),n);if(((e=this._$AH)===null||e===void 0?void 0:e._$AD)===r)this._$AH.v(s);else{let a=new nt(r,this),h=a.u(this.options);a.v(s),this.$(h),this._$AH=a}}_$AC(t){let e=kt.get(t.strings);return e===void 0&&kt.set(t.strings,e=new k(t)),e}T(t){Nt(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,n=0;for(let r of t)n===e.length?e.push(s=new U(this.k(T()),this.k(T()),this,this.options)):s=e[n],s._$AI(r),n++;n<e.length&&(this._$AR(s&&s._$AB.nextSibling,n),e.length=n)}_$AR(t=this._$AA.nextSibling,e){var s;for((s=this._$AP)===null||s===void 0||s.call(this,!1,!0,e);t&&t!==this._$AB;){let n=t.nextSibling;t.remove(),t=n}}setConnected(t){var e;this._$AM===void 0&&(this._$Cp=t,(e=this._$AP)===null||e===void 0||e.call(this,t))}},V=class{constructor(t,e,s,n,r){this.type=1,this._$AH=g,this._$AN=void 0,this.element=t,this.name=e,this._$AM=n,this.options=r,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=g}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,s,n){let r=this.strings,a=!1;if(r===void 0)t=O(this,t,e,0),a=!j(t)||t!==this._$AH&&t!==R,a&&(this._$AH=t);else{let h=t,c,u;for(t=r[0],c=0;c<r.length-1;c++)u=O(this,h[s+c],e,c),u===R&&(u=this._$AH[c]),a||(a=!j(u)||u!==this._$AH[c]),u===g?t=g:t!==g&&(t+=(u??"")+r[c+1]),this._$AH[c]=u}a&&!n&&this.j(t)}j(t){t===g?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},rt=class extends V{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===g?void 0:t}},ue=N?N.emptyScript:"",ot=class extends V{constructor(){super(...arguments),this.type=4}j(t){t&&t!==g?this.element.setAttribute(this.name,ue):this.element.removeAttribute(this.name)}},at=class extends V{constructor(t,e,s,n,r){super(t,e,s,n,r),this.type=5}_$AI(t,e=this){var s;if((t=(s=O(this,t,e,0))!==null&&s!==void 0?s:g)===R)return;let n=this._$AH,r=t===g&&n!==g||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,a=t!==g&&(n===g||r);r&&this.element.removeEventListener(this.name,this,n),a&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,s;typeof this._$AH=="function"?this._$AH.call((s=(e=this.options)===null||e===void 0?void 0:e.host)!==null&&s!==void 0?s:this.element,t):this._$AH.handleEvent(t)}},lt=class{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){O(this,t)}};var Ut=F.litHtmlPolyfillSupport;Ut?.(k,U),((et=F.litHtmlVersions)!==null&&et!==void 0?et:F.litHtmlVersions=[]).push("2.8.0");var Lt=(i,t,e)=>{var s,n;let r=(s=e?.renderBefore)!==null&&s!==void 0?s:t,a=r._$litPart$;if(a===void 0){let h=(n=e?.renderBefore)!==null&&n!==void 0?n:null;r._$litPart$=a=new U(t.insertBefore(T(),h),h,void 0,e??{})}return a._$AI(i),a};var ht,ct;var M=class extends E{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,e;let s=super.createRenderRoot();return(t=(e=this.renderOptions).renderBefore)!==null&&t!==void 0||(e.renderBefore=s.firstChild),s}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=Lt(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),(t=this._$Do)===null||t===void 0||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this._$Do)===null||t===void 0||t.setConnected(!1)}render(){return R}};M.finalized=!0,M._$litElement$=!0,(ht=globalThis.litElementHydrateSupport)===null||ht===void 0||ht.call(globalThis,{LitElement:M});var Tt=globalThis.litElementPolyfillSupport;Tt?.({LitElement:M});((ct=globalThis.litElementVersions)!==null&&ct!==void 0?ct:globalThis.litElementVersions=[]).push("3.3.3");function jt(i){Object.defineProperty(i,"__esModule",{value:!0,configurable:!0})}function dt(i,t,e,s){Object.defineProperty(i,t,{get:e,set:s,enumerable:!0,configurable:!0})}var It={};jt(It);dt(It,"default",()=>W);var W=class extends Error{constructor(t,e,s,n,r){super(t+":"+s+":"+n+": "+e),this.reason=e,this.filename=t,this.line=s,this.column=n,this.source=r}},Dt={};jt(Dt);dt(Dt,"default",()=>q);var q=class{constructor(t,e,s){this.start=t,this.end=e,this.source=s}},pe={};dt(pe,"CssTypes",()=>d);var d;(function(i){i.stylesheet="stylesheet",i.rule="rule",i.declaration="declaration",i.comment="comment",i.container="container",i.charset="charset",i.document="document",i.customMedia="custom-media",i.fontFace="font-face",i.host="host",i.import="import",i.keyframes="keyframes",i.keyframe="keyframe",i.layer="layer",i.media="media",i.namespace="namespace",i.page="page",i.supports="supports"})(d||(d={}));var ut=/\/\*[^]*?(?:\*\/|$)/g,me=(i,t)=>{t=t||{};let e=1,s=1;function n(l){let o=l.match(/\n/g);o&&(e+=o.length);let m=l.lastIndexOf(`
`);s=~m?l.length-m:s+l.length}function r(){let l={line:e,column:s};return function(o){return o.position=new q(l,{line:e,column:s},t?.source||""),_(),o}}let a=[];function h(l){let o=new W(t?.source||"",l,e,s,i);if(t?.silent)a.push(o);else throw o}function c(){let l=$();return{type:d.stylesheet,stylesheet:{source:t?.source,rules:l,parsingErrors:a}}}function u(){return p(/^{\s*/)}function f(){return p(/^}/)}function $(){let l,o=[];for(_(),y(o);i.length&&i.charAt(0)!=="}"&&(l=re()||oe());)l&&(o.push(l),y(o));return o}function p(l){let o=l.exec(i);if(!o)return;let m=o[0];return n(m),i=i.slice(m.length),o}function _(){p(/^\s*/)}function y(l){let o;for(l=l||[];o=H();)o&&l.push(o);return l}function H(){let l=r();if(i.charAt(0)!=="/"||i.charAt(1)!=="*")return;let o=p(/^\/\*[^]*?\*\//);return o?l({type:d.comment,comment:o[0].slice(2,-2)}):h("End of comment missing")}function $t(){let l=p(/^([^{]+)/);if(!l)return;let o=A(l[0]).replace(ut,"");return o.indexOf(",")===-1?[o]:o.replace(/("|')(?:\\\1|.)*?\1|\(.*?\)/g,m=>m.replace(/,/g,"\u200C")).split(",").map(m=>A(m.replace(/\u200C/g,",")))}function K(){let l=r(),o=p(/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/);if(!o)return;let m=A(o[0]);if(!p(/^:\s*/))return h("property missing ':'");let v=p(/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/),S=l({type:d.declaration,property:m.replace(ut,""),value:v?A(v[0]).replace(ut,""):""});return p(/^[;\s]*/),S}function vt(){let l=[];if(!u())return h("missing '{'");y(l);let o;for(;o=K();)o&&(l.push(o),y(l));return f()?l:h("missing '}'")}function Ft(){let l,o=[],m=r();for(;l=p(/^((\d+\.\d+|\.\d+|\d+)%?|[a-z]+)\s*/);)o.push(l[1]),p(/^,\s*/);if(!!o.length)return m({type:d.keyframe,values:o,declarations:vt()||[]})}function Wt(){let l=r(),o=p(/^@([-\w]+)?keyframes\s*/);if(!o)return;let m=o[1],v=p(/^([-\w]+)\s*/);if(!v)return h("@keyframes missing name");let S=v[1];if(!u())return h("@keyframes missing '{'");let yt,I=y();for(;yt=Ft();)I.push(yt),I=I.concat(y());return f()?l({type:d.keyframes,name:S,vendor:m,keyframes:I}):h("@keyframes missing '}'")}function qt(){let l=r(),o=p(/^@supports *([^{]+)/);if(!o)return;let m=A(o[1]);if(!u())return h("@supports missing '{'");let v=y().concat($());return f()?l({type:d.supports,supports:m,rules:v}):h("@supports missing '}'")}function Kt(){let l=r();if(!p(/^@host\s*/))return;if(!u())return h("@host missing '{'");let m=y().concat($());return f()?l({type:d.host,rules:m}):h("@host missing '}'")}function Jt(){let l=r(),o=p(/^@container *([^{]+)/);if(!o)return;let m=A(o[1]);if(!u())return h("@container missing '{'");let v=y().concat($());return f()?l({type:d.container,container:m,rules:v}):h("@container missing '}'")}function Zt(){let l=r(),o=p(/^@layer *([^{;@]+)/);if(!o)return;let m=A(o[1]);if(!u())return p(/^[;\s]*/),l({type:d.layer,layer:m});let v=y().concat($());return f()?l({type:d.layer,layer:m,rules:v}):h("@layer missing '}'")}function Qt(){let l=r(),o=p(/^@media *([^{]+)/);if(!o)return;let m=A(o[1]);if(!u())return h("@media missing '{'");let v=y().concat($());return f()?l({type:d.media,media:m,rules:v}):h("@media missing '}'")}function Xt(){let l=r(),o=p(/^@custom-media\s+(--[^\s]+)\s*([^{;]+);/);if(!!o)return l({type:d.customMedia,name:A(o[1]),media:A(o[2])})}function Yt(){let l=r();if(!p(/^@page */))return;let m=$t()||[];if(!u())return h("@page missing '{'");let v=y(),S;for(;S=K();)v.push(S),v=v.concat(y());return f()?l({type:d.page,selectors:m,declarations:v}):h("@page missing '}'")}function te(){let l=r(),o=p(/^@([-\w]+)?document *([^{]+)/);if(!o)return;let m=A(o[1]),v=A(o[2]);if(!u())return h("@document missing '{'");let S=y().concat($());return f()?l({type:d.document,document:v,vendor:m,rules:S}):h("@document missing '}'")}function ee(){let l=r();if(!p(/^@font-face\s*/))return;if(!u())return h("@font-face missing '{'");let m=y(),v;for(;v=K();)m.push(v),m=m.concat(y());return f()?l({type:d.fontFace,declarations:m}):h("@font-face missing '}'")}let se=J("import"),ie=J("charset"),ne=J("namespace");function J(l){let o=new RegExp("^@"+l+`\\s*((?::?[^;'"]|"(?:\\\\"|[^"])*?"|'(?:\\\\'|[^'])*?')+)(?:;|$)`);return function(){let m=r(),v=p(o);if(!v)return;let S={type:l};return S[l]=v[1].trim(),m(S)}}function re(){if(i[0]==="@")return Wt()||Qt()||Xt()||qt()||se()||ie()||ne()||te()||Yt()||Kt()||ee()||Jt()||Zt()}function oe(){let l=r(),o=$t();return o?(y(),l({type:d.rule,selectors:o,declarations:vt()||[]})):h("selector missing")}return pt(c())};function A(i){return i?i.trim():""}function pt(i,t){let e=i&&typeof i.type=="string",s=e?i:t;for(let n in i){let r=i[n];Array.isArray(r)?r.forEach(a=>{pt(a,s)}):r&&typeof r=="object"&&pt(r,s)}return e&&Object.defineProperty(i,"parent",{configurable:!0,writable:!0,enumerable:!1,value:t||null}),i}var de=me,mt=class{constructor(t){this.level=0,this.indentation=" ",this.compress=!1,typeof t?.indent=="string"&&(this.indentation=t?.indent),t?.compress&&(this.compress=!0)}emit(t,e){return t}indent(t){return this.level=this.level||1,t?(this.level+=t,""):Array(this.level).join(this.indentation)}visit(t){switch(t.type){case d.stylesheet:return this.stylesheet(t);case d.rule:return this.rule(t);case d.declaration:return this.declaration(t);case d.comment:return this.comment(t);case d.container:return this.container(t);case d.charset:return this.charset(t);case d.document:return this.document(t);case d.customMedia:return this.customMedia(t);case d.fontFace:return this.fontFace(t);case d.host:return this.host(t);case d.import:return this.import(t);case d.keyframes:return this.keyframes(t);case d.keyframe:return this.keyframe(t);case d.layer:return this.layer(t);case d.media:return this.media(t);case d.namespace:return this.namespace(t);case d.page:return this.page(t);case d.supports:return this.supports(t)}}mapVisit(t,e){let s="";e=e||"";for(let n=0,r=t.length;n<r;n++)s+=this.visit(t[n]),e&&n<r-1&&(s+=this.emit(e));return s}compile(t){return this.compress?t.stylesheet.rules.map(this.visit,this).join(""):this.stylesheet(t)}stylesheet(t){return this.mapVisit(t.stylesheet.rules,`

@@ -48,3 +46,3 @@ `)}comment(t){return this.compress?this.emit("",t.position):this.emit(this.indent()+"/*"+t.comment+"*/",t.position)}container(t){return this.compress?this.emit("@container "+t.container,t.position)+this.emit("{")+this.mapVisit(t.rules)+this.emit("}"):this.emit(this.indent()+"@container "+t.container,t.position)+this.emit(` {

`)+this.emit(this.indent(-1))+this.emit(`
`+this.indent()+"}")}declaration(t){return this.compress?this.emit(t.property+":"+t.value,t.position)+this.emit(";"):this.emit(this.indent())+this.emit(t.property+": "+t.value,t.position)+this.emit(";")}},ue=ht,pe=(i,t)=>new ue(t||{}).compile(i),Tt=ce,jt=pe;var de=(i,t)=>i.startsWith(t)||i.includes(":root")?i:i.includes(":host(")?i.replace(/:host\((.+?)\)/,t+"$1"):i.includes(":host")?i.replace(":host",t):i.includes("::slotted(")?i.replace(/::slotted\((.+?)\)/,t+" $1"):t+" "+i,Dt=(i,t)=>{var e;if("selectors"in i&&i.selectors.length>0)for(let s=0;s<i.selectors.length;s++)i.selectors[s]=de(i.selectors[s],t);else"rules"in i&&((e=i.rules)==null||e.forEach(s=>{Dt(s,t)}))},fe=(i,t)=>{let e=Tt(i);return e&&e.stylesheet&&e.stylesheet.rules.length>0&&e.stylesheet.rules.forEach(function(s){Dt(s,t)}),jt(e,{compress:!0})},ut=class{constructor(t,e,s=""){this.ruleIndex=0;this.host=t,this.componentName=t.tagName.toLowerCase(),this.cssStyles=e,this.scopeId=s,t.addController(this)}hostConnected(){let t=`'${this.componentName}' using light DOM styles injected into <head>`;this.host.before(document.createComment(t)),document.getElementById(this.componentName)||(this.ruleIndex=0,this._addLightDomGroup(this.cssStyles))}_addLightDomStyle(t){let e=this.ruleIndex!==0?this.componentName+"-"+this.ruleIndex:this.componentName;if(!document.getElementById(e)){let s=document.createElement("style");s.id=e;let n=`${t}`;this.scopeId!==""&&(n=fe(n,this.scopeId)),s.innerHTML=n,document.head.prepend(s);let r=`styles injected into DOM by '${this.componentName}'`;s.before(document.createComment(r))}this.ruleIndex++}_addLightDomGroup(t,e=0){if(t instanceof Array)for(let s=t.length-1;s>=0;s--){let n=t[s];n instanceof Array?this._addLightDomGroup(n,e+1):n instanceof w&&this._addLightDomStyle(n)}else t instanceof w&&this._addLightDomStyle(t)}};})();
`+this.indent()+"}")}declaration(t){return this.compress?this.emit(t.property+":"+t.value,t.position)+this.emit(";"):this.emit(this.indent())+this.emit(t.property+": "+t.value,t.position)+this.emit(";")}},fe=mt,$e=(i,t)=>new fe(t||{}).compile(i),Bt=de,zt=$e;var ye=(i,t)=>i.startsWith(t)||i.includes(":root")?i:i.includes(":host(")?i.replace(/:host\((.+?)\)/,t+"$1"):i.includes(":host")?i.replace(":host",t):i.includes("::slotted(")?i.replace(/::slotted\((.+?)\)/,t+" $1"):t+" "+i,Gt=(i,t)=>{var e;if("selectors"in i&&i.selectors.length>0)for(let s=0;s<i.selectors.length;s++)i.selectors[s]=ye(i.selectors[s],t);else"rules"in i&&((e=i.rules)==null||e.forEach(s=>{Gt(s,t)}))},ge=(i,t)=>{let e=Bt(i);return e&&e.stylesheet&&e.stylesheet.rules.length>0&&e.stylesheet.rules.forEach(function(s){Gt(s,t)}),zt(e,{compress:!0})},ft=class{constructor(t,e,s=""){this.ruleIndex=0;this.host=t,this.componentName=t.tagName.toLowerCase(),this.cssStyles=e,this.scopeId=s,t.addController(this)}hostConnected(){let t=`'${this.componentName}' using light DOM styles injected into <head>`;this.host.before(document.createComment(t)),document.getElementById(this.componentName)||(this.ruleIndex=0,this._addLightDomGroup(this.cssStyles))}_addLightDomStyle(t){let e=this.ruleIndex!==0?this.componentName+"-"+this.ruleIndex:this.componentName;if(!document.getElementById(e)){let s=document.createElement("style");s.id=e;let n=`${t}`;this.scopeId!==""&&(n=ge(n,this.scopeId)),s.innerHTML=n,document.head.prepend(s);let r=`styles injected into DOM by '${this.componentName}'`;s.before(document.createComment(r))}this.ruleIndex++}_addLightDomGroup(t,e=0){if(t instanceof Array)for(let s=t.length-1;s>=0;s--){let n=t[s];n instanceof Array?this._addLightDomGroup(n,e+1):n instanceof w&&this._addLightDomStyle(n)}else t instanceof w&&this._addLightDomStyle(t)}};})();
/**

@@ -51,0 +49,0 @@ * @license

{
"name": "@phase2/outline-controller-light-dom-styles-controller",
"version": "0.0.1",
"version": "0.0.2",
"description": "Deprecated controller to manage styles via Light DOM.",

@@ -25,2 +25,3 @@ "keywords": [

},
"homepage": "https://github.com/phase2/outline/tree/next/packages/controllers/@deprecated/light-dom-styles",
"license": "BSD-3-Clause",

@@ -27,0 +28,0 @@ "scripts": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc