@e280/sly 0.3.0-8 → 0.3.0-9

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/README.md CHANGED
@@ -23,12 +23,13 @@ npm install lit @e280/sly @e280/strata @e280/stz
23
23
  <a id="views"></a>
24
24
 
25
25
  ## 🎭 views
26
- > *"flourish in the light.. or thrive in the darkness"*
26
+ > *reactive lit-html views*
27
27
 
28
+ - ðŸ”Ū [**see codepen demo,**](https://codepen.io/editor/ChaseMoskal/pen/019cd681-722b-7f51-a961-bc16e3d524a9) plain html (no build!)
28
29
  - 🌗 **light or shadow,** render nakedly on the page, or within a cozy shadow bubble
29
30
  - 🊝 **hooks-based,** familiar react-style [hooks](#hooks)
30
31
  - ⚡ **auto-reactive,** views magically rerender on [strata](https://github.com/e280/strata)-compatible state changes
31
- - ðŸŠķ **no compile step,** just god's honest javascript via [lit](https://lit.dev/)-html tagged-template-literals
32
+ - ðŸŠķ **no compile step,** just god's honest javascript via [lit](https://lit.dev/)-html tagged-templates
32
33
  - ðŸ§Đ **not web components,** no dom registration needed, just vibes and good typings
33
34
 
34
35
  ```ts
@@ -41,7 +42,7 @@ export const MyShadowView = shadow(() => html`<p>shrouded in darkness</p>`)
41
42
  ```
42
43
 
43
44
  ### 🌞 light views
44
- > *"just pretend it's react, without jsx"*
45
+ > *just pretend it's like react!*
45
46
 
46
47
  - **define a light view**
47
48
  ```ts
@@ -64,12 +65,9 @@ export const MyShadowView = shadow(() => html`<p>shrouded in darkness</p>`)
64
65
  ${MyCounter(123)}
65
66
  `)
66
67
  ```
67
- - light views have no host element, rendered output looks like:
68
- ```html
69
- <h1>my cool counter demo</h1>
70
- <button>123</button>
71
- ```
72
- - **light views are naked,** they don't have a containing host element
68
+ - **remember, light views are naked.**
69
+ so they don't have a containing host element,
70
+ and they can't have their own styles.
73
71
 
74
72
  ### 🌚 shadow views
75
73
  > *each shadow view gets its own cozy [shadow-dom](https://developer.mozilla.org/en-US/docs/Web/API/Web_components/Using_shadow_DOM) bubble and supports [slotting](https://developer.mozilla.org/en-US/docs/Web/API/Web_components/Using_templates_and_slots)*
@@ -182,6 +180,16 @@ you must not call these hooks under if-conditionals, or for-loops, or inside cal
182
180
  ```ts
183
181
  const shadow = useShadow()
184
182
  ```
183
+ - **useAttrs,** access host element attributes (and rerender on attr changes)
184
+ ```ts
185
+ const attrs = useAttrs({
186
+ name: String,
187
+ count: Number,
188
+ active: Boolean,
189
+ })
190
+
191
+ attrs.count = 123 // set the attr
192
+ ```
185
193
 
186
194
  ### 🌞 universal hooks
187
195
  - **useState,** react-like hook to create some reactive state (we prefer signals)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@e280/sly",
3
- "version": "0.3.0-8",
3
+ "version": "0.3.0-9",
4
4
  "description": "web shadow views",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -0,0 +1,14 @@
1
+
2
+ import {dom} from "../../dom/dom.js"
3
+ import {useOnce} from "./use-once.js"
4
+ import {useMount} from "./use-mount.js"
5
+ import {AttrSpec} from "../../dom/types.js"
6
+ import {useHost, useRender} from "./use-cx.js"
7
+
8
+ export function useAttrs<A extends AttrSpec>(spec: A) {
9
+ const host = useHost()
10
+ const rerender = useRender()
11
+ useMount(() => dom.attrs(host).on(rerender))
12
+ return useOnce(() => dom.attrs(host).spec(spec))
13
+ }
14
+
package/s/view/index.ts CHANGED
@@ -5,6 +5,7 @@ export * from "./common/sly-shadow.js"
5
5
  export * from "./elements/light.js"
6
6
  export * from "./elements/shadow.js"
7
7
 
8
+ export * from "./hooks/use-attrs.js"
8
9
  export * from "./hooks/use-css.js"
9
10
  export * from "./hooks/use-cx.js"
10
11
  export * from "./hooks/use-life.js"
@@ -1,6 +1,6 @@
1
- var pr=Object.defineProperty;var ne=(r,t)=>{for(var e in t)pr(r,e,{get:t[e],enumerable:!0})};var kt=globalThis,Pt=kt.ShadowRoot&&(kt.ShadyCSS===void 0||kt.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ie=Symbol(),Ae=new WeakMap,lt=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==ie)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(Pt&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=Ae.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&Ae.set(e,t))}return t}toString(){return this.cssText}},ve=r=>new lt(typeof r=="string"?r:r+"",void 0,ie),x=(r,...t)=>{let e=r.length===1?r[0]:t.reduce(((s,o,n)=>s+(i=>{if(i._$cssResult$===!0)return i.cssText;if(typeof i=="number")return i;throw Error("Value passed to 'css' function must be a 'css' function result: "+i+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(o)+r[n+1]),r[0]);return new lt(e,r,ie)},Rt=(r,t)=>{if(Pt)r.adoptedStyleSheets=t.map((e=>e instanceof CSSStyleSheet?e:e.styleSheet));else for(let e of t){let s=document.createElement("style"),o=kt.litNonce;o!==void 0&&s.setAttribute("nonce",o),s.textContent=e.cssText,r.appendChild(s)}},et=Pt?r=>r:r=>r instanceof CSSStyleSheet?(t=>{let e="";for(let s of t.cssRules)e+=s.cssText;return ve(e)})(r):r;var{is:hr,defineProperty:lr,getOwnPropertyDescriptor:mr,getOwnPropertyNames:fr,getOwnPropertySymbols:dr,getPrototypeOf:yr}=Object,Ot=globalThis,Se=Ot.trustedTypes,gr=Se?Se.emptyScript:"",br=Ot.reactiveElementPolyfillSupport,mt=(r,t)=>r,ae={toAttribute(r,t){switch(t){case Boolean:r=r?gr:null;break;case Object:case Array:r=r==null?r:JSON.stringify(r)}return r},fromAttribute(r,t){let e=r;switch(t){case Boolean:e=r!==null;break;case Number:e=r===null?null:Number(r);break;case Object:case Array:try{e=JSON.parse(r)}catch{e=null}}return e}},Ce=(r,t)=>!hr(r,t),Ee={attribute:!0,type:String,converter:ae,reflect:!1,useDefault:!1,hasChanged:Ce};Symbol.metadata??=Symbol("metadata"),Ot.litPropertyMetadata??=new WeakMap;var O=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=Ee){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){let s=Symbol(),o=this.getPropertyDescriptor(t,s,e);o!==void 0&&lr(this.prototype,t,o)}}static getPropertyDescriptor(t,e,s){let{get:o,set:n}=mr(this.prototype,t)??{get(){return this[e]},set(i){this[e]=i}};return{get:o,set(i){let c=o?.call(this);n?.call(this,i),this.requestUpdate(t,c,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??Ee}static _$Ei(){if(this.hasOwnProperty(mt("elementProperties")))return;let t=yr(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(mt("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(mt("properties"))){let e=this.properties,s=[...fr(e),...dr(e)];for(let o of s)this.createProperty(o,e[o])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[s,o]of e)this.elementProperties.set(s,o)}this._$Eh=new Map;for(let[e,s]of this.elementProperties){let o=this._$Eu(e,s);o!==void 0&&this._$Eh.set(o,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let s=new Set(t.flat(1/0).reverse());for(let o of s)e.unshift(et(o))}else t!==void 0&&e.push(et(t));return e}static _$Eu(t,e){let s=e.attribute;return s===!1?void 0:typeof s=="string"?s:typeof t=="string"?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),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Rt(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){let s=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,s);if(o!==void 0&&s.reflect===!0){let n=(s.converter?.toAttribute!==void 0?s.converter:ae).toAttribute(e,s.type);this._$Em=t,n==null?this.removeAttribute(o):this.setAttribute(o,n),this._$Em=null}}_$AK(t,e){let s=this.constructor,o=s._$Eh.get(t);if(o!==void 0&&this._$Em!==o){let n=s.getPropertyOptions(o),i=typeof n.converter=="function"?{fromAttribute:n.converter}:n.converter?.fromAttribute!==void 0?n.converter:ae;this._$Em=o;let c=i.fromAttribute(e,n.type);this[o]=c??this._$Ej?.get(o)??c,this._$Em=null}}requestUpdate(t,e,s){if(t!==void 0){let o=this.constructor,n=this[t];if(s??=o.getPropertyOptions(t),!((s.hasChanged??Ce)(n,e)||s.useDefault&&s.reflect&&n===this._$Ej?.get(t)&&!this.hasAttribute(o._$Eu(t,s))))return;this.C(t,e,s)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(t,e,{useDefault:s,reflect:o,wrapped:n},i){s&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,i??e??this[t]),n!==!0||i!==void 0)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),o===!0&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(let[o,n]of this._$Ep)this[o]=n;this._$Ep=void 0}let s=this.constructor.elementProperties;if(s.size>0)for(let[o,n]of s){let{wrapped:i}=n,c=this[o];i!==!0||this._$AL.has(o)||c===void 0||this.C(o,void 0,n,c)}}let t=!1,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach((s=>s.hostUpdate?.())),this.update(e)):this._$EM()}catch(s){throw t=!1,this._$EM(),s}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach((e=>e.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((e=>this._$ET(e,this[e]))),this._$EM()}updated(t){}firstUpdated(t){}};O.elementStyles=[],O.shadowRootOptions={mode:"open"},O[mt("elementProperties")]=new Map,O[mt("finalized")]=new Map,br?.({ReactiveElement:O}),(Ot.reactiveElementVersions??=[]).push("2.1.1");var ue=globalThis,Mt=ue.trustedTypes,ke=Mt?Mt.createPolicy("lit-html",{createHTML:r=>r}):void 0,pe="$lit$",M=`lit$${Math.random().toFixed(9).slice(2)}$`,he="?"+M,xr=`<${he}>`,Z=document,dt=()=>Z.createComment(""),yt=r=>r===null||typeof r!="object"&&typeof r!="function",le=Array.isArray,Ne=r=>le(r)||typeof r?.[Symbol.iterator]=="function",ce=`[
2
- \f\r]`,ft=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Pe=/-->/g,Re=/>/g,V=RegExp(`>|${ce}(?:([^\\s"'>=/]+)(${ce}*=${ce}*(?:[^
3
- \f\r"'\`<>=]|("|')|))|$)`,"g"),Oe=/'/g,Me=/"/g,Le=/^(?:script|style|textarea|title)$/i,me=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),$=me(1),_s=me(2),As=me(3),F=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),Te=new WeakMap,G=Z.createTreeWalker(Z,129);function He(r,t){if(!le(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return ke!==void 0?ke.createHTML(t):t}var je=(r,t)=>{let e=r.length-1,s=[],o,n=t===2?"<svg>":t===3?"<math>":"",i=ft;for(let c=0;c<e;c++){let a=r[c],p,f,h=-1,_=0;for(;_<a.length&&(i.lastIndex=_,f=i.exec(a),f!==null);)_=i.lastIndex,i===ft?f[1]==="!--"?i=Pe:f[1]!==void 0?i=Re:f[2]!==void 0?(Le.test(f[2])&&(o=RegExp("</"+f[2],"g")),i=V):f[3]!==void 0&&(i=V):i===V?f[0]===">"?(i=o??ft,h=-1):f[1]===void 0?h=-2:(h=i.lastIndex-f[2].length,p=f[1],i=f[3]===void 0?V:f[3]==='"'?Me:Oe):i===Me||i===Oe?i=V:i===Pe||i===Re?i=ft:(i=V,o=void 0);let L=i===V&&r[c+1].startsWith("/>")?" ":"";n+=i===ft?a+xr:h>=0?(s.push(p),a.slice(0,h)+pe+a.slice(h)+M+L):a+M+(h===-2?c:L)}return[He(r,n+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},gt=class r{constructor({strings:t,_$litType$:e},s){let o;this.parts=[];let n=0,i=0,c=t.length-1,a=this.parts,[p,f]=je(t,e);if(this.el=r.createElement(p,s),G.currentNode=this.el.content,e===2||e===3){let h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(o=G.nextNode())!==null&&a.length<c;){if(o.nodeType===1){if(o.hasAttributes())for(let h of o.getAttributeNames())if(h.endsWith(pe)){let _=f[i++],L=o.getAttribute(h).split(M),Ct=/([.?@])?(.*)/.exec(_);a.push({type:1,index:n,name:Ct[2],strings:L,ctor:Ct[1]==="."?Nt:Ct[1]==="?"?Lt:Ct[1]==="@"?Ht:K}),o.removeAttribute(h)}else h.startsWith(M)&&(a.push({type:6,index:n}),o.removeAttribute(h));if(Le.test(o.tagName)){let h=o.textContent.split(M),_=h.length-1;if(_>0){o.textContent=Mt?Mt.emptyScript:"";for(let L=0;L<_;L++)o.append(h[L],dt()),G.nextNode(),a.push({type:2,index:++n});o.append(h[_],dt())}}}else if(o.nodeType===8)if(o.data===he)a.push({type:2,index:n});else{let h=-1;for(;(h=o.data.indexOf(M,h+1))!==-1;)a.push({type:7,index:n}),h+=M.length-1}n++}}static createElement(t,e){let s=Z.createElement("template");return s.innerHTML=t,s}};function J(r,t,e=r,s){if(t===F)return t;let o=s!==void 0?e._$Co?.[s]:e._$Cl,n=yt(t)?void 0:t._$litDirective$;return o?.constructor!==n&&(o?._$AO?.(!1),n===void 0?o=void 0:(o=new n(r),o._$AT(r,e,s)),s!==void 0?(e._$Co??=[])[s]=o:e._$Cl=o),o!==void 0&&(t=J(r,o._$AS(r,t.values),o,s)),t}var Tt=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){let{el:{content:e},parts:s}=this._$AD,o=(t?.creationScope??Z).importNode(e,!0);G.currentNode=o;let n=G.nextNode(),i=0,c=0,a=s[0];for(;a!==void 0;){if(i===a.index){let p;a.type===2?p=new rt(n,n.nextSibling,this,t):a.type===1?p=new a.ctor(n,a.name,a.strings,this,t):a.type===6&&(p=new jt(n,this,t)),this._$AV.push(p),a=s[++c]}i!==a?.index&&(n=G.nextNode(),i++)}return G.currentNode=Z,o}p(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++}},rt=class r{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,o){this.type=2,this._$AH=d,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=o,this._$Cv=o?.isConnected??!0}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=J(this,t,e),yt(t)?t===d||t==null||t===""?(this._$AH!==d&&this._$AR(),this._$AH=d):t!==this._$AH&&t!==F&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Ne(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!==d&&yt(this._$AH)?this._$AA.nextSibling.data=t:this.T(Z.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:s}=t,o=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=gt.createElement(He(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===o)this._$AH.p(e);else{let n=new Tt(o,this),i=n.u(this.options);n.p(e),this.T(i),this._$AH=n}}_$AC(t){let e=Te.get(t.strings);return e===void 0&&Te.set(t.strings,e=new gt(t)),e}k(t){le(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,o=0;for(let n of t)o===e.length?e.push(s=new r(this.O(dt()),this.O(dt()),this,this.options)):s=e[o],s._$AI(n),o++;o<e.length&&(this._$AR(s&&s._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){let s=t.nextSibling;t.remove(),t=s}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},K=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,o,n){this.type=1,this._$AH=d,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=n,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=d}_$AI(t,e=this,s,o){let n=this.strings,i=!1;if(n===void 0)t=J(this,t,e,0),i=!yt(t)||t!==this._$AH&&t!==F,i&&(this._$AH=t);else{let c=t,a,p;for(t=n[0],a=0;a<n.length-1;a++)p=J(this,c[s+a],e,a),p===F&&(p=this._$AH[a]),i||=!yt(p)||p!==this._$AH[a],p===d?t=d:t!==d&&(t+=(p??"")+n[a+1]),this._$AH[a]=p}i&&!o&&this.j(t)}j(t){t===d?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},Nt=class extends K{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===d?void 0:t}},Lt=class extends K{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==d)}},Ht=class extends K{constructor(t,e,s,o,n){super(t,e,s,o,n),this.type=5}_$AI(t,e=this){if((t=J(this,t,e,0)??d)===F)return;let s=this._$AH,o=t===d&&s!==d||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==d&&(s===d||o);o&&this.element.removeEventListener(this.name,this,s),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},jt=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){J(this,t)}},Ue={M:pe,P:M,A:he,C:1,L:je,R:Tt,D:Ne,V:J,I:rt,H:K,N:Lt,U:Ht,B:Nt,F:jt},$r=ue.litHtmlPolyfillSupport;$r?.(gt,rt),(ue.litHtmlVersions??=[]).push("3.3.1");var y=(r,t,e)=>{let s=e?.renderBefore??t,o=s._$litPart$;if(o===void 0){let n=e?.renderBefore??null;s._$litPart$=o=new rt(t.insertBefore(dt(),n),n,void 0,e??{})}return o._$AI(r),o};var fe=globalThis,st=class extends O{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=y(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return F}};st._$litElement$=!0,st.finalized=!0,fe.litElementHydrateSupport?.({LitElement:st});var wr=fe.litElementPolyfillSupport;wr?.({LitElement:st});(fe.litElementVersions??=[]).push("4.2.1");var E={string:(r,t)=>r.getAttribute(t)??void 0,number:(r,t)=>{let e=r.getAttribute(t);return e===null||!e?void 0:Number(e)},boolean:(r,t)=>r.getAttribute(t)!==null},b={string:(r,t,e)=>(e===void 0?r.removeAttribute(t):r.setAttribute(t,e),!0),number:(r,t,e)=>(e===void 0?r.removeAttribute(t):r.setAttribute(t,e.toString()),!0),boolean:(r,t,e)=>(e?r.setAttribute(t,""):r.removeAttribute(t),!0),any:(r,t,e)=>{e==null?r.removeAttribute(t):typeof e=="string"?r.setAttribute(t,e):typeof e=="number"?r.setAttribute(t,e.toString()):typeof e=="boolean"?e===!0?r.setAttribute(t,""):r.removeAttribute(t):console.warn(`invalid attribute "${t}" type is "${typeof e}"`)},entries:(r,t)=>{for(let[e,s]of t)b.any(r,e,s)},record:(r,t)=>b.entries(r,Object.entries(t))};function De(r,t={}){let e=document.createElement(r);return b.record(e,t),e}function ze(r){let t=document.createDocumentFragment();return y(r,t),t.firstElementChild}function Ut(r,t){let e=[];for(let[s,o]of Object.entries(t))if(typeof o=="function")r.addEventListener(s,o),e.push(()=>r.removeEventListener(s,o));else{let[n,i]=o;r.addEventListener(s,i,n),e.push(()=>r.removeEventListener(s,i))}return()=>e.forEach(s=>s())}function qe(r,t){let e=new MutationObserver(t);return e.observe(r,{attributes:!0}),()=>e.disconnect()}var Be=(r,t)=>new Proxy(t,{get:(e,s)=>{switch(t[s]){case String:return E.string(r,s);case Number:return E.number(r,s);case Boolean:return E.boolean(r,s);default:throw new Error(`invalid attribute type for "${s}"`)}},set:(e,s,o)=>{switch(t[s]){case String:return b.string(r,s,o);case Number:return b.number(r,s,o);case Boolean:return b.boolean(r,s,o);default:throw new Error(`invalid attribute type for "${s}"`)}}});var Dt=class{element;constructor(t){this.element=t}strings=new Proxy({},{get:(t,e)=>E.string(this.element,e),set:(t,e,s)=>b.string(this.element,e,s)});numbers=new Proxy({},{get:(t,e)=>E.number(this.element,e),set:(t,e,s)=>b.number(this.element,e,s)});booleans=new Proxy({},{get:(t,e)=>E.boolean(this.element,e),set:(t,e,s)=>b.boolean(this.element,e,s)})};function ot(r){let t=new Dt(r);return{strings:t.strings,numbers:t.numbers,booleans:t.booleans,on:e=>qe(r,e),spec:e=>Be(r,e)}}ot.get=E;ot.set=b;function Ie(r){return new de(r)}var de=class{tagName;#t=new Map;#e=[];constructor(t){this.tagName=t}attr(t,e=!0){return this.#t.set(t,e),this}attrs(t){for(let[e,s]of Object.entries(t))this.attr(e,s);return this}children(...t){return this.#e.push(...t),this}done(){let t=document.createElement(this.tagName);return b.entries(t,this.#t),t.append(...this.#e),t}};function nt(r,t=document){let e=t.querySelector(r);if(!e)throw new Error(`element not found (${r})`);return e}function zt(r,t=document){return t.querySelector(r)}function qt(r,t=document){return Array.from(t.querySelectorAll(r))}var Bt=class r{element;#t;constructor(t){this.element=t}in(t){return new r(typeof t=="string"?nt(t,this.element):t)}require(t){return nt(t,this.element)}maybe(t){return zt(t,this.element)}all(t){return qt(t,this.element)}render(...t){return y(t,this.element)}get attrs(){return this.#t??=ot(this.element)}events(t){return Ut(this.element,t)}};function We(r){return r.replace(/([a-zA-Z])(?=[A-Z])/g,"$1-").toLowerCase()}function Ve(r,t={}){let{soft:e=!1,upgrade:s=!0}=t;for(let[o,n]of Object.entries(r)){let i=We(o),c=customElements.get(i);e&&c||(customElements.define(i,n),s&&document.querySelectorAll(i).forEach(a=>{a.constructor===HTMLElement&&customElements.upgrade(a)}))}}function g(r,t=document){return nt(r,t)}g.in=(r,t=document)=>new Bt(t).in(r);g.require=nt;g.maybe=zt;g.all=qt;g.el=De;g.elmer=Ie;g.mk=ze;g.events=Ut;g.attrs=ot;g.register=Ve;g.render=(r,...t)=>y(t,r);function Q(){let r,t,e=new Promise((o,n)=>{r=o,t=n});function s(o){return o.then(r).catch(t),e}return{promise:e,resolve:r,reject:t,entangle:s}}function C(r){let t=null;return((...e)=>(t?t.params=e:(t={params:e,deferred:Q()},queueMicrotask(()=>{let{params:s,deferred:o}=t;t=null,Promise.resolve(r(...s)).then(o.resolve).catch(o.reject)})),t.deferred.promise))}var T={};ne(T,{clone:()=>bt,equal:()=>_r,freeze:()=>Ar});function bt(r,t=new Set){if(t.has(r))throw new Error("cannot clone circular reference");let e;return typeof r=="function"||r!==null&&typeof r=="object"?(t.add(r),Array.isArray(r)?e=r.map(s=>bt(s,new Set(t))):r.constructor===Object?e=Object.fromEntries(Object.entries(r).map(([s,o])=>[s,bt(o,new Set(t))])):r instanceof Map?e=new Map(Array.from(r,([s,o])=>[s,bt(o,new Set(t))])):r instanceof Set?e=new Set(Array.from(r,s=>bt(s,new Set(t)))):r instanceof Date?e=new Date(r.getTime()):e=r,t.delete(r)):e=r,e}var xt=Object.freeze({happy:r=>r!=null,sad:r=>r==null,boolean:r=>typeof r=="boolean",number:r=>typeof r=="number",string:r=>typeof r=="string",bigint:r=>typeof r=="bigint",object:r=>typeof r=="object"&&r!==null,array:r=>Array.isArray(r),fn:r=>typeof r=="function",symbol:r=>typeof r=="symbol"});var _r=(r,t)=>{function e(s,o,n){if(!xt.object(s)||!xt.object(o))return s===o;if(n.includes(s))throw new Error("forbidden circularity detected in deep equal comparison");let i=[...n,s];if(s instanceof Map&&o instanceof Map){if(s.size!==o.size)return!1;for(let[c,a]of s)if(!o.has(c)||!e(a,o.get(c),i))return!1}else if(s instanceof Set&&o instanceof Set){if(s.size!==o.size)return!1;for(let c of s)if(!Array.from(o).some(a=>e(c,a,i)))return!1}else{let c=Object.keys(s),a=Object.keys(o);if(c.length!==a.length)return!1;for(let p of c)if(!a.includes(p)||!e(s[p],o[p],i))return!1}return!0}return e(r,t,[])};function Ar(r){function t(e,s){if(!xt.object(e)||s.includes(e))return e;let o=[...s,e];if(e instanceof Map)for(let n of e.entries())for(let i of n)t(i,o);else if(e instanceof Set)for(let n of e)t(n,o);else if(Array.isArray(e))for(let n of e)t(n,o);else for(let n of Object.values(e))t(n,o);return Object.freeze(e)}return t(r,[])}var It=class r extends Map{static require(t,e){if(t.has(e))return t.get(e);throw new Error(`required key not found: "${e}"`)}static guarantee(t,e,s){if(t.has(e))return t.get(e);{let o=s();return t.set(e,o),o}}array(){return[...this]}require(t){return r.require(this,t)}guarantee(t,e){return r.guarantee(this,t,e)}};function it(r){let t,e=!1,s=()=>{e=!0,clearTimeout(t)},o=async()=>{e||(await r(s),!e&&(t=setTimeout(o,0)))};return o(),s}var at=(r=0)=>new Promise(t=>setTimeout(t,r));function Ge(){let r=new Set;async function t(...a){await Promise.all([...r].map(p=>p(...a)))}function e(a){return r.add(a),()=>{r.delete(a)}}async function s(...a){return t(...a)}function o(a){return e(a)}async function n(a){let{promise:p,resolve:f}=Q(),h=o(async(..._)=>{a&&await a(..._),f(_),h()});return p}function i(){r.clear()}let c={pub:s,sub:o,publish:t,subscribe:e,on:e,next:n,clear:i};return Object.assign(o,c),Object.assign(s,c),c}function H(r){let t=Ge();return r&&t.sub(r),t.sub}function ye(r){let t=Ge();return r&&t.sub(r),t.pub}var ge=class{#t=[];#e=new WeakMap;#r=[];#s=new Set;notifyRead(t){this.#t.at(-1)?.add(t)}async notifyWrite(t){if(this.#s.has(t))throw new Error("circularity forbidden");let e=this.#o(t).pub();return this.#r.at(-1)?.add(e),e}observe(t){this.#t.push(new Set);let e=t();return{seen:this.#t.pop(),result:e}}subscribe(t,e){return this.#o(t)(async()=>{let s=new Set;this.#r.push(s),this.#s.add(t),s.add(e()),this.#s.delete(t),await Promise.all(s),this.#r.pop()})}#o(t){let e=this.#e.get(t);return e||(e=H(),this.#e.set(t,e)),e}},l=globalThis[Symbol.for("e280.tracker")]??=new ge;var Wt=class r{sneak;on;dispose;constructor(t,e){if(new.target!==r)throw new Error("Derived cannot be subclassed");return Vt(t,e)}get value(){return this.get()}get(){return l.notifyRead(this),this.sneak}toString(){return`(derived "${String(this.get())}")`}};function be(r,t){let e=[],s=()=>{for(let i of e)i();e=[]},o=()=>{let{seen:i,result:c}=l.observe(r);for(let a of i)e.push(l.subscribe(a,n));return c},n=C(()=>{s(),t?t(o()):o()});return{result:o(),dispose:s}}function ct(r,t){return Object.is(r,t)}function Vt(r,t){function e(){return e.get()}let s=t?.compare??ct;Object.setPrototypeOf(e,Wt.prototype),e.on=H();let{result:o,dispose:n}=be(r,async i=>{!s(e.sneak,i)&&(e.sneak=i,await Promise.all([l.notifyWrite(e),e.on.pub(i)]))});return e.sneak=o,e.dispose=n,e}var Y=Symbol(),j=Symbol(),U=Symbol(),Gt=Symbol(),k=Symbol(),$t=Symbol(),N=Symbol();var Zt=class r{sneak;[$t];[j];[N];[U];[k];constructor(t,e){if(new.target!==r)throw new Error("Lazy cannot be subclassed");return Ft(t,e)}get value(){return this.get()}[Gt](){for(let o of this[N])o();this[N]=[];let{seen:t,result:e}=l.observe(this[$t]),s=async()=>{this[j]=!0};for(let o of t)this[N].push(l.subscribe(o,s));return this[U]=()=>{for(let o of this[N])o();this[N]=[]},e}get(){if(!this[U])this.sneak=this[Gt](),this[j]=!1;else if(this[j]){this[j]=!1;let t=this[Gt]();!this[k](this.sneak,t)&&(this.sneak=t,l.notifyWrite(this))}return l.notifyRead(this),this.sneak}dispose(){this[U]&&this[U]()}toString(){return`($lazy "${String(this.get())}")`}};function Ft(r,t){function e(){return e.get()}return Object.setPrototypeOf(e,Zt.prototype),e.sneak=void 0,e[$t]=r,e[j]=!1,e[U]=void 0,e[N]=[],e[k]=t?.compare??ct,e}var Jt=class r{sneak;on;[Y];[k];constructor(t,e){if(new.target!==r)throw new Error("Signal cannot be subclassed");return D(t,e)}get value(){return this.get()}set value(t){this.set(t)}get(){return l.notifyRead(this),this.sneak}async set(t,e=!1){let s=this.sneak;return this.sneak=t,(e||!this[k](s,t))&&await this.publish(),t}async publish(){if(this[Y])throw new Error("forbid circularity");let t=this.sneak,e=Promise.resolve();try{this[Y]=!0,e=Promise.all([l.notifyWrite(this),this.on.pub(t)])}finally{this[Y]=!1}return await e,t}toString(){return`($signal "${String(this.get())}")`}};function D(r,t){function e(s){let o=e;return arguments.length===0?o.get():o.set(arguments[0])}return Object.setPrototypeOf(e,Jt.prototype),e.sneak=r,e.on=H(),e[Y]=!1,e[k]=t?.compare??ct,e}D.derived=Vt;D.lazy=Ft;var X={status:r=>r[0],value:r=>r[0]==="ready"?r[1]:void 0,error:r=>r[0]==="error"?r[1]:void 0,select:(r,t)=>{switch(r[0]){case"loading":return t.loading();case"error":return t.error(r[1]);case"ready":return t.ready(r[1]);default:throw new Error("unknown op status")}},morph:(r,t)=>X.select(r,{loading:()=>["loading"],error:e=>["error",e],ready:e=>["ready",t(e)]}),all:(...r)=>{let t=[],e=[],s=0;for(let o of r)switch(o[0]){case"loading":s++;break;case"ready":t.push(o[1]);break;case"error":e.push(o[1]);break}return e.length>0?["error",e]:s===0?["ready",t]:["loading"]}};var wt=class{static loading(){return new this}static ready(t){return new this(["ready",t])}static error(t){return new this(["error",t])}static promise(t){let e=new this;return e.promise(t),e}static load(t){return this.promise(t())}static all(...t){let e=t.map(s=>s.pod);return X.all(...e)}signal;#t=0;#e=ye();#r=ye();constructor(t=["loading"]){this.signal=D(t)}get wait(){return new Promise((t,e)=>{this.#e.next().then(([s])=>t(s)),this.#r.next().then(([s])=>e(s))})}get then(){return this.wait.then.bind(this.wait)}get catch(){return this.wait.catch.bind(this.wait)}get finally(){return this.wait.finally.bind(this.wait)}async setLoading(){await this.signal.set(["loading"])}async setReady(t){await this.signal.set(["ready",t]),await this.#e(t)}async setError(t){await this.signal.set(["error",t]),await this.#r(t)}async promise(t){let e=++this.#t;await this.setLoading();try{let s=await t;return e===this.#t&&await this.setReady(s),s}catch(s){console.error(s),e===this.#t&&await this.setError(s)}}async load(t){return this.promise(t())}get pod(){return this.signal.get()}set pod(t){this.signal.set(t)}get status(){return this.signal.get()[0]}get value(){return X.value(this.signal.get())}get error(){return X.error(this.signal.get())}get isLoading(){return this.status==="loading"}get isReady(){return this.status==="ready"}get isError(){return this.status==="error"}require(){let t=this.signal.get();if(t[0]!=="ready")throw new Error("required value not ready");return t[1]}select(t){return X.select(this.signal.get(),t)}morph(t){return X.morph(this.pod,t)}};var _t=class{render;count=0;rendered=Q();constructor(t){this.render=t}doneRender(){this.count++,this.rendered.resolve(),this.rendered=Q()}},z=class extends _t{host;shadow;constructor(t,e,s){super(t),this.host=e,this.shadow=s}};var xe=class{#t=[];get scope(){let t=this.#t.at(-1);if(!t)throw new Error("hooks must be called within a render fn");return t}increment(){let t=this.scope,e=t.position++;return{scope:t,position:e}}wrap(t,e){t.position=0,this.#t.push(t);try{return e()}finally{this.#t.pop()}}},A=globalThis[Symbol.for("e280.hooks")]??=new xe;var Kt=class r extends HTMLElement{static register(){g.register({SlyShadow:r},{soft:!0})}connectedCallback(){this.hasAttribute("view")||this.setAttribute("view","")}};function Ze(r){return T.freeze(T.clone(r))}var P=Symbol("optic");var Qt=class{calculate;#t=!1;#e;constructor(t){this.calculate=t,this.#e=t()}get(){return this.#t&&(this.#t=!1,this.#e=this.calculate()),this.#e}invalidate(){this.#t=!0}};var Yt=class r{on=H();[P];#t;#e;#r=C(()=>this.on.publish(this.state));constructor(t){this[P]=t,this.#t=T.clone(t.getState()),this.#e=new Qt(()=>Ze(t.getState()))}async update(){let t=this[P].getState();!T.equal(t,this.#t)&&(this.#e.invalidate(),this.#t=T.clone(t),this.#r(),await l.notifyWrite(this))}get state(){return l.notifyRead(this),this.#e.get()}async mutate(t){return this[P].mutate(t)}lens(t){let e=new r({getState:()=>t(this[P].getState()),mutate:s=>this[P].mutate(o=>s(t(o))),registerLens:this[P].registerLens});return this[P].registerLens(e),e}};var q=class{#t=[];clear(){this.#t.forEach(t=>t()),this.#t=[]}observe(t,e){let{seen:s,result:o}=l.observe(t);this.clear();for(let n of s){let i=l.subscribe(n,e);this.#t.push(i)}return o}};function Fe(r,t){for(let[e,s]of Object.entries(t))vr(r,e,s)}function vr(r,t,e){let s=r.getAttribute(t),o=Sr(e);o!==s&&(o===null?r.removeAttribute(t):r.setAttribute(t,o))}function Sr(r){return typeof r=="string"?r:typeof r=="number"?r.toString():r?"":null}function w(r){let{scope:t,position:e}=A.increment();return t.values.guarantee(e,r)}function tt(r){let{scope:t}=A.increment();return w(()=>t.mounts.mount(r))}var Xt=class{#t=[];#e=[];mount(t){this.#t.push(t),this.#e.push(t())}unmountAll(){for(let t of this.#e)t();this.#e=[]}remountAll(){for(let t of this.#t)this.#e.push(t())}};var B=class{cx;position=0;values=new It;mounts=new Xt;constructor(t){this.cx=t}};var{I:Wi}=Ue;var Je=r=>r.strings===void 0;var Ke={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},At=r=>(...t)=>({_$litDirective$:r,values:t}),te=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,s){this._$Ct=t,this._$AM=e,this._$Ci=s}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var vt=(r,t)=>{let e=r._$AN;if(e===void 0)return!1;for(let s of e)s._$AO?.(t,!1),vt(s,t);return!0},ee=r=>{let t,e;do{if((t=r._$AM)===void 0)break;e=t._$AN,e.delete(r),r=t}while(e?.size===0)},Qe=r=>{for(let t;t=r._$AM;r=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(r))break;e.add(r),kr(t)}};function Er(r){this._$AN!==void 0?(ee(this),this._$AM=r,Qe(this)):this._$AM=r}function Cr(r,t=!1,e=0){let s=this._$AH,o=this._$AN;if(o!==void 0&&o.size!==0)if(t)if(Array.isArray(s))for(let n=e;n<s.length;n++)vt(s[n],!1),ee(s[n]);else s!=null&&(vt(s,!1),ee(s));else vt(this,r)}var kr=r=>{r.type==Ke.CHILD&&(r._$AP??=Cr,r._$AQ??=Er)},ut=class extends te{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,s){super._$AT(t,e,s),Qe(this),this.isConnected=t._$AU}_$AO(t,e=!0){t!==this.isConnected&&(this.isConnected=t,t?this.reconnected?.():this.disconnected?.()),e&&(vt(this,t),ee(this))}setValue(t){if(Je(this._$Ct))this._$Ct._$AI(t,this);else{let e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}};function Pr(){Kt.register();let r=document.createElement("sly-shadow"),t=r.attachShadow({mode:"open"});return{host:r,shadow:t}}function S(r){return Ye(Pr,r)}S.setup=r=>(t=>Ye(r,t));function Ye(r,t){let e=At(class extends ut{#t;#e;#r;#s=new q;constructor(o){super(o);let{host:n,shadow:i}=r(),c=C(()=>{if(!this.#r)throw new Error("cannot render before props");if(!this.isConnected)return;let a=this.#o(this.#r);y(a,this.#t.shadow),this.#t.doneRender()});this.#t=new z(c,n,i),this.#e=new B(this.#t)}#o(o){return this.#r=o,this.#s.observe(()=>A.wrap(this.#e,()=>t(...this.#r)),this.#t.render)}render({props:o,children:n,attrs:i}){let{host:c}=this.#t;return this.isConnected&&(i&&Fe(c,i),y(n,this.#t.host),y(this.#o(o),this.#t.shadow),this.#t.doneRender()),c}disconnected(){this.#e.mounts.unmountAll(),this.#s.clear()}reconnected(){this.#e.mounts.remountAll(),this.#t.render()}});function s(...o){return e({props:o})}return s.with=e,s}var Et={};ne(Et,{AsciiAnim:()=>nr,ErrorDisplay:()=>_e,anims:()=>we,make:()=>ms,makeAsciiAnim:()=>u,mock:()=>fs});var we={};ne(we,{arrow:()=>Hr,bar:()=>jr,bar2:()=>Ur,bar3:()=>Dr,bar4:()=>zr,bin:()=>es,binary:()=>rs,binary2:()=>ss,block:()=>qr,block2:()=>Br,brackets:()=>Zr,brackets2:()=>Fr,braille:()=>Lr,bright:()=>us,clock:()=>is,cylon:()=>Vr,dots:()=>Jr,dots2:()=>Kr,earth:()=>$e,fistbump:()=>as,kiss:()=>ns,lock:()=>cs,moon:()=>hs,pie:()=>Wr,pulseblue:()=>os,runner:()=>Ir,slider:()=>Gr,speaker:()=>ps,spinner:()=>Nr,wave:()=>Qr,wavepulse:()=>Xr,wavepulse2:()=>ts,wavescrub:()=>Yr});var I=x`
1
+ var pr=Object.defineProperty;var ne=(r,t)=>{for(var e in t)pr(r,e,{get:t[e],enumerable:!0})};var kt=globalThis,Rt=kt.ShadowRoot&&(kt.ShadyCSS===void 0||kt.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ie=Symbol(),ve=new WeakMap,lt=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==ie)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(Rt&&t===void 0){let s=e!==void 0&&e.length===1;s&&(t=ve.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&ve.set(e,t))}return t}toString(){return this.cssText}},Se=r=>new lt(typeof r=="string"?r:r+"",void 0,ie),x=(r,...t)=>{let e=r.length===1?r[0]:t.reduce(((s,o,n)=>s+(i=>{if(i._$cssResult$===!0)return i.cssText;if(typeof i=="number")return i;throw Error("Value passed to 'css' function must be a 'css' function result: "+i+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(o)+r[n+1]),r[0]);return new lt(e,r,ie)},Pt=(r,t)=>{if(Rt)r.adoptedStyleSheets=t.map((e=>e instanceof CSSStyleSheet?e:e.styleSheet));else for(let e of t){let s=document.createElement("style"),o=kt.litNonce;o!==void 0&&s.setAttribute("nonce",o),s.textContent=e.cssText,r.appendChild(s)}},et=Rt?r=>r:r=>r instanceof CSSStyleSheet?(t=>{let e="";for(let s of t.cssRules)e+=s.cssText;return Se(e)})(r):r;var{is:hr,defineProperty:lr,getOwnPropertyDescriptor:mr,getOwnPropertyNames:fr,getOwnPropertySymbols:dr,getPrototypeOf:yr}=Object,Ot=globalThis,Ee=Ot.trustedTypes,gr=Ee?Ee.emptyScript:"",br=Ot.reactiveElementPolyfillSupport,mt=(r,t)=>r,ae={toAttribute(r,t){switch(t){case Boolean:r=r?gr:null;break;case Object:case Array:r=r==null?r:JSON.stringify(r)}return r},fromAttribute(r,t){let e=r;switch(t){case Boolean:e=r!==null;break;case Number:e=r===null?null:Number(r);break;case Object:case Array:try{e=JSON.parse(r)}catch{e=null}}return e}},ke=(r,t)=>!hr(r,t),Ce={attribute:!0,type:String,converter:ae,reflect:!1,useDefault:!1,hasChanged:ke};Symbol.metadata??=Symbol("metadata"),Ot.litPropertyMetadata??=new WeakMap;var O=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=Ce){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){let s=Symbol(),o=this.getPropertyDescriptor(t,s,e);o!==void 0&&lr(this.prototype,t,o)}}static getPropertyDescriptor(t,e,s){let{get:o,set:n}=mr(this.prototype,t)??{get(){return this[e]},set(i){this[e]=i}};return{get:o,set(i){let c=o?.call(this);n?.call(this,i),this.requestUpdate(t,c,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??Ce}static _$Ei(){if(this.hasOwnProperty(mt("elementProperties")))return;let t=yr(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(mt("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(mt("properties"))){let e=this.properties,s=[...fr(e),...dr(e)];for(let o of s)this.createProperty(o,e[o])}let t=this[Symbol.metadata];if(t!==null){let e=litPropertyMetadata.get(t);if(e!==void 0)for(let[s,o]of e)this.elementProperties.set(s,o)}this._$Eh=new Map;for(let[e,s]of this.elementProperties){let o=this._$Eu(e,s);o!==void 0&&this._$Eh.set(o,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let e=[];if(Array.isArray(t)){let s=new Set(t.flat(1/0).reverse());for(let o of s)e.unshift(et(o))}else t!==void 0&&e.push(et(t));return e}static _$Eu(t,e){let s=e.attribute;return s===!1?void 0:typeof s=="string"?s:typeof t=="string"?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),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,e=this.constructor.elementProperties;for(let s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Pt(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){let s=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,s);if(o!==void 0&&s.reflect===!0){let n=(s.converter?.toAttribute!==void 0?s.converter:ae).toAttribute(e,s.type);this._$Em=t,n==null?this.removeAttribute(o):this.setAttribute(o,n),this._$Em=null}}_$AK(t,e){let s=this.constructor,o=s._$Eh.get(t);if(o!==void 0&&this._$Em!==o){let n=s.getPropertyOptions(o),i=typeof n.converter=="function"?{fromAttribute:n.converter}:n.converter?.fromAttribute!==void 0?n.converter:ae;this._$Em=o;let c=i.fromAttribute(e,n.type);this[o]=c??this._$Ej?.get(o)??c,this._$Em=null}}requestUpdate(t,e,s){if(t!==void 0){let o=this.constructor,n=this[t];if(s??=o.getPropertyOptions(t),!((s.hasChanged??ke)(n,e)||s.useDefault&&s.reflect&&n===this._$Ej?.get(t)&&!this.hasAttribute(o._$Eu(t,s))))return;this.C(t,e,s)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(t,e,{useDefault:s,reflect:o,wrapped:n},i){s&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,i??e??this[t]),n!==!0||i!==void 0)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),o===!0&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(let[o,n]of this._$Ep)this[o]=n;this._$Ep=void 0}let s=this.constructor.elementProperties;if(s.size>0)for(let[o,n]of s){let{wrapped:i}=n,c=this[o];i!==!0||this._$AL.has(o)||c===void 0||this.C(o,void 0,n,c)}}let t=!1,e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach((s=>s.hostUpdate?.())),this.update(e)):this._$EM()}catch(s){throw t=!1,this._$EM(),s}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach((e=>e.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((e=>this._$ET(e,this[e]))),this._$EM()}updated(t){}firstUpdated(t){}};O.elementStyles=[],O.shadowRootOptions={mode:"open"},O[mt("elementProperties")]=new Map,O[mt("finalized")]=new Map,br?.({ReactiveElement:O}),(Ot.reactiveElementVersions??=[]).push("2.1.1");var ue=globalThis,Mt=ue.trustedTypes,Re=Mt?Mt.createPolicy("lit-html",{createHTML:r=>r}):void 0,pe="$lit$",M=`lit$${Math.random().toFixed(9).slice(2)}$`,he="?"+M,xr=`<${he}>`,F=document,dt=()=>F.createComment(""),yt=r=>r===null||typeof r!="object"&&typeof r!="function",le=Array.isArray,Le=r=>le(r)||typeof r?.[Symbol.iterator]=="function",ce=`[
2
+ \f\r]`,ft=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Pe=/-->/g,Oe=/>/g,G=RegExp(`>|${ce}(?:([^\\s"'>=/]+)(${ce}*=${ce}*(?:[^
3
+ \f\r"'\`<>=]|("|')|))|$)`,"g"),Me=/'/g,Te=/"/g,He=/^(?:script|style|textarea|title)$/i,me=r=>(t,...e)=>({_$litType$:r,strings:t,values:e}),$=me(1),As=me(2),vs=me(3),J=Symbol.for("lit-noChange"),d=Symbol.for("lit-nothing"),Ne=new WeakMap,Z=F.createTreeWalker(F,129);function je(r,t){if(!le(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return Re!==void 0?Re.createHTML(t):t}var Ue=(r,t)=>{let e=r.length-1,s=[],o,n=t===2?"<svg>":t===3?"<math>":"",i=ft;for(let c=0;c<e;c++){let a=r[c],p,f,h=-1,_=0;for(;_<a.length&&(i.lastIndex=_,f=i.exec(a),f!==null);)_=i.lastIndex,i===ft?f[1]==="!--"?i=Pe:f[1]!==void 0?i=Oe:f[2]!==void 0?(He.test(f[2])&&(o=RegExp("</"+f[2],"g")),i=G):f[3]!==void 0&&(i=G):i===G?f[0]===">"?(i=o??ft,h=-1):f[1]===void 0?h=-2:(h=i.lastIndex-f[2].length,p=f[1],i=f[3]===void 0?G:f[3]==='"'?Te:Me):i===Te||i===Me?i=G:i===Pe||i===Oe?i=ft:(i=G,o=void 0);let L=i===G&&r[c+1].startsWith("/>")?" ":"";n+=i===ft?a+xr:h>=0?(s.push(p),a.slice(0,h)+pe+a.slice(h)+M+L):a+M+(h===-2?c:L)}return[je(r,n+(r[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),s]},gt=class r{constructor({strings:t,_$litType$:e},s){let o;this.parts=[];let n=0,i=0,c=t.length-1,a=this.parts,[p,f]=Ue(t,e);if(this.el=r.createElement(p,s),Z.currentNode=this.el.content,e===2||e===3){let h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(o=Z.nextNode())!==null&&a.length<c;){if(o.nodeType===1){if(o.hasAttributes())for(let h of o.getAttributeNames())if(h.endsWith(pe)){let _=f[i++],L=o.getAttribute(h).split(M),Ct=/([.?@])?(.*)/.exec(_);a.push({type:1,index:n,name:Ct[2],strings:L,ctor:Ct[1]==="."?Nt:Ct[1]==="?"?Lt:Ct[1]==="@"?Ht:Q}),o.removeAttribute(h)}else h.startsWith(M)&&(a.push({type:6,index:n}),o.removeAttribute(h));if(He.test(o.tagName)){let h=o.textContent.split(M),_=h.length-1;if(_>0){o.textContent=Mt?Mt.emptyScript:"";for(let L=0;L<_;L++)o.append(h[L],dt()),Z.nextNode(),a.push({type:2,index:++n});o.append(h[_],dt())}}}else if(o.nodeType===8)if(o.data===he)a.push({type:2,index:n});else{let h=-1;for(;(h=o.data.indexOf(M,h+1))!==-1;)a.push({type:7,index:n}),h+=M.length-1}n++}}static createElement(t,e){let s=F.createElement("template");return s.innerHTML=t,s}};function K(r,t,e=r,s){if(t===J)return t;let o=s!==void 0?e._$Co?.[s]:e._$Cl,n=yt(t)?void 0:t._$litDirective$;return o?.constructor!==n&&(o?._$AO?.(!1),n===void 0?o=void 0:(o=new n(r),o._$AT(r,e,s)),s!==void 0?(e._$Co??=[])[s]=o:e._$Cl=o),o!==void 0&&(t=K(r,o._$AS(r,t.values),o,s)),t}var Tt=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){let{el:{content:e},parts:s}=this._$AD,o=(t?.creationScope??F).importNode(e,!0);Z.currentNode=o;let n=Z.nextNode(),i=0,c=0,a=s[0];for(;a!==void 0;){if(i===a.index){let p;a.type===2?p=new rt(n,n.nextSibling,this,t):a.type===1?p=new a.ctor(n,a.name,a.strings,this,t):a.type===6&&(p=new jt(n,this,t)),this._$AV.push(p),a=s[++c]}i!==a?.index&&(n=Z.nextNode(),i++)}return Z.currentNode=F,o}p(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++}},rt=class r{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,o){this.type=2,this._$AH=d,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=o,this._$Cv=o?.isConnected??!0}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=K(this,t,e),yt(t)?t===d||t==null||t===""?(this._$AH!==d&&this._$AR(),this._$AH=d):t!==this._$AH&&t!==J&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Le(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!==d&&yt(this._$AH)?this._$AA.nextSibling.data=t:this.T(F.createTextNode(t)),this._$AH=t}$(t){let{values:e,_$litType$:s}=t,o=typeof s=="number"?this._$AC(t):(s.el===void 0&&(s.el=gt.createElement(je(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===o)this._$AH.p(e);else{let n=new Tt(o,this),i=n.u(this.options);n.p(e),this.T(i),this._$AH=n}}_$AC(t){let e=Ne.get(t.strings);return e===void 0&&Ne.set(t.strings,e=new gt(t)),e}k(t){le(this._$AH)||(this._$AH=[],this._$AR());let e=this._$AH,s,o=0;for(let n of t)o===e.length?e.push(s=new r(this.O(dt()),this.O(dt()),this,this.options)):s=e[o],s._$AI(n),o++;o<e.length&&(this._$AR(s&&s._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){let s=t.nextSibling;t.remove(),t=s}}setConnected(t){this._$AM===void 0&&(this._$Cv=t,this._$AP?.(t))}},Q=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,o,n){this.type=1,this._$AH=d,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=n,s.length>2||s[0]!==""||s[1]!==""?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=d}_$AI(t,e=this,s,o){let n=this.strings,i=!1;if(n===void 0)t=K(this,t,e,0),i=!yt(t)||t!==this._$AH&&t!==J,i&&(this._$AH=t);else{let c=t,a,p;for(t=n[0],a=0;a<n.length-1;a++)p=K(this,c[s+a],e,a),p===J&&(p=this._$AH[a]),i||=!yt(p)||p!==this._$AH[a],p===d?t=d:t!==d&&(t+=(p??"")+n[a+1]),this._$AH[a]=p}i&&!o&&this.j(t)}j(t){t===d?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}},Nt=class extends Q{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===d?void 0:t}},Lt=class extends Q{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==d)}},Ht=class extends Q{constructor(t,e,s,o,n){super(t,e,s,o,n),this.type=5}_$AI(t,e=this){if((t=K(this,t,e,0)??d)===J)return;let s=this._$AH,o=t===d&&s!==d||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,n=t!==d&&(s===d||o);o&&this.element.removeEventListener(this.name,this,s),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){typeof this._$AH=="function"?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}},jt=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){K(this,t)}},De={M:pe,P:M,A:he,C:1,L:Ue,R:Tt,D:Le,V:K,I:rt,H:Q,N:Lt,U:Ht,B:Nt,F:jt},$r=ue.litHtmlPolyfillSupport;$r?.(gt,rt),(ue.litHtmlVersions??=[]).push("3.3.1");var y=(r,t,e)=>{let s=e?.renderBefore??t,o=s._$litPart$;if(o===void 0){let n=e?.renderBefore??null;s._$litPart$=o=new rt(t.insertBefore(dt(),n),n,void 0,e??{})}return o._$AI(r),o};var fe=globalThis,st=class extends O{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){let t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){let e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=y(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return J}};st._$litElement$=!0,st.finalized=!0,fe.litElementHydrateSupport?.({LitElement:st});var wr=fe.litElementPolyfillSupport;wr?.({LitElement:st});(fe.litElementVersions??=[]).push("4.2.1");var E={string:(r,t)=>r.getAttribute(t)??void 0,number:(r,t)=>{let e=r.getAttribute(t);return e===null||!e?void 0:Number(e)},boolean:(r,t)=>r.getAttribute(t)!==null},b={string:(r,t,e)=>(e===void 0?r.removeAttribute(t):r.setAttribute(t,e),!0),number:(r,t,e)=>(e===void 0?r.removeAttribute(t):r.setAttribute(t,e.toString()),!0),boolean:(r,t,e)=>(e?r.setAttribute(t,""):r.removeAttribute(t),!0),any:(r,t,e)=>{e==null?r.removeAttribute(t):typeof e=="string"?r.setAttribute(t,e):typeof e=="number"?r.setAttribute(t,e.toString()):typeof e=="boolean"?e===!0?r.setAttribute(t,""):r.removeAttribute(t):console.warn(`invalid attribute "${t}" type is "${typeof e}"`)},entries:(r,t)=>{for(let[e,s]of t)b.any(r,e,s)},record:(r,t)=>b.entries(r,Object.entries(t))};function ze(r,t={}){let e=document.createElement(r);return b.record(e,t),e}function qe(r){let t=document.createDocumentFragment();return y(r,t),t.firstElementChild}function Ut(r,t){let e=[];for(let[s,o]of Object.entries(t))if(typeof o=="function")r.addEventListener(s,o),e.push(()=>r.removeEventListener(s,o));else{let[n,i]=o;r.addEventListener(s,i,n),e.push(()=>r.removeEventListener(s,i))}return()=>e.forEach(s=>s())}function Be(r,t){let e=new MutationObserver(t);return e.observe(r,{attributes:!0}),()=>e.disconnect()}var Ie=(r,t)=>new Proxy(t,{get:(e,s)=>{switch(t[s]){case String:return E.string(r,s);case Number:return E.number(r,s);case Boolean:return E.boolean(r,s);default:throw new Error(`invalid attribute type for "${s}"`)}},set:(e,s,o)=>{switch(t[s]){case String:return b.string(r,s,o);case Number:return b.number(r,s,o);case Boolean:return b.boolean(r,s,o);default:throw new Error(`invalid attribute type for "${s}"`)}}});var Dt=class{element;constructor(t){this.element=t}strings=new Proxy({},{get:(t,e)=>E.string(this.element,e),set:(t,e,s)=>b.string(this.element,e,s)});numbers=new Proxy({},{get:(t,e)=>E.number(this.element,e),set:(t,e,s)=>b.number(this.element,e,s)});booleans=new Proxy({},{get:(t,e)=>E.boolean(this.element,e),set:(t,e,s)=>b.boolean(this.element,e,s)})};function ot(r){let t=new Dt(r);return{strings:t.strings,numbers:t.numbers,booleans:t.booleans,on:e=>Be(r,e),spec:e=>Ie(r,e)}}ot.get=E;ot.set=b;function We(r){return new de(r)}var de=class{tagName;#t=new Map;#e=[];constructor(t){this.tagName=t}attr(t,e=!0){return this.#t.set(t,e),this}attrs(t){for(let[e,s]of Object.entries(t))this.attr(e,s);return this}children(...t){return this.#e.push(...t),this}done(){let t=document.createElement(this.tagName);return b.entries(t,this.#t),t.append(...this.#e),t}};function nt(r,t=document){let e=t.querySelector(r);if(!e)throw new Error(`element not found (${r})`);return e}function zt(r,t=document){return t.querySelector(r)}function qt(r,t=document){return Array.from(t.querySelectorAll(r))}var Bt=class r{element;#t;constructor(t){this.element=t}in(t){return new r(typeof t=="string"?nt(t,this.element):t)}require(t){return nt(t,this.element)}maybe(t){return zt(t,this.element)}all(t){return qt(t,this.element)}render(...t){return y(t,this.element)}get attrs(){return this.#t??=ot(this.element)}events(t){return Ut(this.element,t)}};function Ve(r){return r.replace(/([a-zA-Z])(?=[A-Z])/g,"$1-").toLowerCase()}function Ge(r,t={}){let{soft:e=!1,upgrade:s=!0}=t;for(let[o,n]of Object.entries(r)){let i=Ve(o),c=customElements.get(i);e&&c||(customElements.define(i,n),s&&document.querySelectorAll(i).forEach(a=>{a.constructor===HTMLElement&&customElements.upgrade(a)}))}}function g(r,t=document){return nt(r,t)}g.in=(r,t=document)=>new Bt(t).in(r);g.require=nt;g.maybe=zt;g.all=qt;g.el=ze;g.elmer=We;g.mk=qe;g.events=Ut;g.attrs=ot;g.register=Ge;g.render=(r,...t)=>y(t,r);function Y(){let r,t,e=new Promise((o,n)=>{r=o,t=n});function s(o){return o.then(r).catch(t),e}return{promise:e,resolve:r,reject:t,entangle:s}}function C(r){let t=null;return((...e)=>(t?t.params=e:(t={params:e,deferred:Y()},queueMicrotask(()=>{let{params:s,deferred:o}=t;t=null,Promise.resolve(r(...s)).then(o.resolve).catch(o.reject)})),t.deferred.promise))}var T={};ne(T,{clone:()=>bt,equal:()=>_r,freeze:()=>Ar});function bt(r,t=new Set){if(t.has(r))throw new Error("cannot clone circular reference");let e;return typeof r=="function"||r!==null&&typeof r=="object"?(t.add(r),Array.isArray(r)?e=r.map(s=>bt(s,new Set(t))):r.constructor===Object?e=Object.fromEntries(Object.entries(r).map(([s,o])=>[s,bt(o,new Set(t))])):r instanceof Map?e=new Map(Array.from(r,([s,o])=>[s,bt(o,new Set(t))])):r instanceof Set?e=new Set(Array.from(r,s=>bt(s,new Set(t)))):r instanceof Date?e=new Date(r.getTime()):e=r,t.delete(r)):e=r,e}var xt=Object.freeze({happy:r=>r!=null,sad:r=>r==null,boolean:r=>typeof r=="boolean",number:r=>typeof r=="number",string:r=>typeof r=="string",bigint:r=>typeof r=="bigint",object:r=>typeof r=="object"&&r!==null,array:r=>Array.isArray(r),fn:r=>typeof r=="function",symbol:r=>typeof r=="symbol"});var _r=(r,t)=>{function e(s,o,n){if(!xt.object(s)||!xt.object(o))return s===o;if(n.includes(s))throw new Error("forbidden circularity detected in deep equal comparison");let i=[...n,s];if(s instanceof Map&&o instanceof Map){if(s.size!==o.size)return!1;for(let[c,a]of s)if(!o.has(c)||!e(a,o.get(c),i))return!1}else if(s instanceof Set&&o instanceof Set){if(s.size!==o.size)return!1;for(let c of s)if(!Array.from(o).some(a=>e(c,a,i)))return!1}else{let c=Object.keys(s),a=Object.keys(o);if(c.length!==a.length)return!1;for(let p of c)if(!a.includes(p)||!e(s[p],o[p],i))return!1}return!0}return e(r,t,[])};function Ar(r){function t(e,s){if(!xt.object(e)||s.includes(e))return e;let o=[...s,e];if(e instanceof Map)for(let n of e.entries())for(let i of n)t(i,o);else if(e instanceof Set)for(let n of e)t(n,o);else if(Array.isArray(e))for(let n of e)t(n,o);else for(let n of Object.values(e))t(n,o);return Object.freeze(e)}return t(r,[])}var It=class r extends Map{static require(t,e){if(t.has(e))return t.get(e);throw new Error(`required key not found: "${e}"`)}static guarantee(t,e,s){if(t.has(e))return t.get(e);{let o=s();return t.set(e,o),o}}array(){return[...this]}require(t){return r.require(this,t)}guarantee(t,e){return r.guarantee(this,t,e)}};function it(r){let t,e=!1,s=()=>{e=!0,clearTimeout(t)},o=async()=>{e||(await r(s),!e&&(t=setTimeout(o,0)))};return o(),s}var at=(r=0)=>new Promise(t=>setTimeout(t,r));function Ze(){let r=new Set;async function t(...a){await Promise.all([...r].map(p=>p(...a)))}function e(a){return r.add(a),()=>{r.delete(a)}}async function s(...a){return t(...a)}function o(a){return e(a)}async function n(a){let{promise:p,resolve:f}=Y(),h=o(async(..._)=>{a&&await a(..._),f(_),h()});return p}function i(){r.clear()}let c={pub:s,sub:o,publish:t,subscribe:e,on:e,next:n,clear:i};return Object.assign(o,c),Object.assign(s,c),c}function H(r){let t=Ze();return r&&t.sub(r),t.sub}function ye(r){let t=Ze();return r&&t.sub(r),t.pub}var ge=class{#t=[];#e=new WeakMap;#r=[];#s=new Set;notifyRead(t){this.#t.at(-1)?.add(t)}async notifyWrite(t){if(this.#s.has(t))throw new Error("circularity forbidden");let e=this.#o(t).pub();return this.#r.at(-1)?.add(e),e}observe(t){this.#t.push(new Set);let e=t();return{seen:this.#t.pop(),result:e}}subscribe(t,e){return this.#o(t)(async()=>{let s=new Set;this.#r.push(s),this.#s.add(t),s.add(e()),this.#s.delete(t),await Promise.all(s),this.#r.pop()})}#o(t){let e=this.#e.get(t);return e||(e=H(),this.#e.set(t,e)),e}},l=globalThis[Symbol.for("e280.tracker")]??=new ge;var Wt=class r{sneak;on;dispose;constructor(t,e){if(new.target!==r)throw new Error("Derived cannot be subclassed");return Vt(t,e)}get value(){return this.get()}get(){return l.notifyRead(this),this.sneak}toString(){return`(derived "${String(this.get())}")`}};function be(r,t){let e=[],s=()=>{for(let i of e)i();e=[]},o=()=>{let{seen:i,result:c}=l.observe(r);for(let a of i)e.push(l.subscribe(a,n));return c},n=C(()=>{s(),t?t(o()):o()});return{result:o(),dispose:s}}function ct(r,t){return Object.is(r,t)}function Vt(r,t){function e(){return e.get()}let s=t?.compare??ct;Object.setPrototypeOf(e,Wt.prototype),e.on=H();let{result:o,dispose:n}=be(r,async i=>{!s(e.sneak,i)&&(e.sneak=i,await Promise.all([l.notifyWrite(e),e.on.pub(i)]))});return e.sneak=o,e.dispose=n,e}var X=Symbol(),j=Symbol(),U=Symbol(),Gt=Symbol(),k=Symbol(),$t=Symbol(),N=Symbol();var Zt=class r{sneak;[$t];[j];[N];[U];[k];constructor(t,e){if(new.target!==r)throw new Error("Lazy cannot be subclassed");return Ft(t,e)}get value(){return this.get()}[Gt](){for(let o of this[N])o();this[N]=[];let{seen:t,result:e}=l.observe(this[$t]),s=async()=>{this[j]=!0};for(let o of t)this[N].push(l.subscribe(o,s));return this[U]=()=>{for(let o of this[N])o();this[N]=[]},e}get(){if(!this[U])this.sneak=this[Gt](),this[j]=!1;else if(this[j]){this[j]=!1;let t=this[Gt]();!this[k](this.sneak,t)&&(this.sneak=t,l.notifyWrite(this))}return l.notifyRead(this),this.sneak}dispose(){this[U]&&this[U]()}toString(){return`($lazy "${String(this.get())}")`}};function Ft(r,t){function e(){return e.get()}return Object.setPrototypeOf(e,Zt.prototype),e.sneak=void 0,e[$t]=r,e[j]=!1,e[U]=void 0,e[N]=[],e[k]=t?.compare??ct,e}var Jt=class r{sneak;on;[X];[k];constructor(t,e){if(new.target!==r)throw new Error("Signal cannot be subclassed");return D(t,e)}get value(){return this.get()}set value(t){this.set(t)}get(){return l.notifyRead(this),this.sneak}async set(t,e=!1){let s=this.sneak;return this.sneak=t,(e||!this[k](s,t))&&await this.publish(),t}async publish(){if(this[X])throw new Error("forbid circularity");let t=this.sneak,e=Promise.resolve();try{this[X]=!0,e=Promise.all([l.notifyWrite(this),this.on.pub(t)])}finally{this[X]=!1}return await e,t}toString(){return`($signal "${String(this.get())}")`}};function D(r,t){function e(s){let o=e;return arguments.length===0?o.get():o.set(arguments[0])}return Object.setPrototypeOf(e,Jt.prototype),e.sneak=r,e.on=H(),e[X]=!1,e[k]=t?.compare??ct,e}D.derived=Vt;D.lazy=Ft;var tt={status:r=>r[0],value:r=>r[0]==="ready"?r[1]:void 0,error:r=>r[0]==="error"?r[1]:void 0,select:(r,t)=>{switch(r[0]){case"loading":return t.loading();case"error":return t.error(r[1]);case"ready":return t.ready(r[1]);default:throw new Error("unknown op status")}},morph:(r,t)=>tt.select(r,{loading:()=>["loading"],error:e=>["error",e],ready:e=>["ready",t(e)]}),all:(...r)=>{let t=[],e=[],s=0;for(let o of r)switch(o[0]){case"loading":s++;break;case"ready":t.push(o[1]);break;case"error":e.push(o[1]);break}return e.length>0?["error",e]:s===0?["ready",t]:["loading"]}};var wt=class{static loading(){return new this}static ready(t){return new this(["ready",t])}static error(t){return new this(["error",t])}static promise(t){let e=new this;return e.promise(t),e}static load(t){return this.promise(t())}static all(...t){let e=t.map(s=>s.pod);return tt.all(...e)}signal;#t=0;#e=ye();#r=ye();constructor(t=["loading"]){this.signal=D(t)}get wait(){return new Promise((t,e)=>{this.#e.next().then(([s])=>t(s)),this.#r.next().then(([s])=>e(s))})}get then(){return this.wait.then.bind(this.wait)}get catch(){return this.wait.catch.bind(this.wait)}get finally(){return this.wait.finally.bind(this.wait)}async setLoading(){await this.signal.set(["loading"])}async setReady(t){await this.signal.set(["ready",t]),await this.#e(t)}async setError(t){await this.signal.set(["error",t]),await this.#r(t)}async promise(t){let e=++this.#t;await this.setLoading();try{let s=await t;return e===this.#t&&await this.setReady(s),s}catch(s){console.error(s),e===this.#t&&await this.setError(s)}}async load(t){return this.promise(t())}get pod(){return this.signal.get()}set pod(t){this.signal.set(t)}get status(){return this.signal.get()[0]}get value(){return tt.value(this.signal.get())}get error(){return tt.error(this.signal.get())}get isLoading(){return this.status==="loading"}get isReady(){return this.status==="ready"}get isError(){return this.status==="error"}require(){let t=this.signal.get();if(t[0]!=="ready")throw new Error("required value not ready");return t[1]}select(t){return tt.select(this.signal.get(),t)}morph(t){return tt.morph(this.pod,t)}};var _t=class{render;count=0;rendered=Y();constructor(t){this.render=t}doneRender(){this.count++,this.rendered.resolve(),this.rendered=Y()}},z=class extends _t{host;shadow;constructor(t,e,s){super(t),this.host=e,this.shadow=s}};var xe=class{#t=[];get scope(){let t=this.#t.at(-1);if(!t)throw new Error("hooks must be called within a render fn");return t}increment(){let t=this.scope,e=t.position++;return{scope:t,position:e}}wrap(t,e){t.position=0,this.#t.push(t);try{return e()}finally{this.#t.pop()}}},A=globalThis[Symbol.for("e280.hooks")]??=new xe;var Kt=class r extends HTMLElement{static register(){g.register({SlyShadow:r},{soft:!0})}connectedCallback(){this.hasAttribute("view")||this.setAttribute("view","")}};function Fe(r){return T.freeze(T.clone(r))}var R=Symbol("optic");var Qt=class{calculate;#t=!1;#e;constructor(t){this.calculate=t,this.#e=t()}get(){return this.#t&&(this.#t=!1,this.#e=this.calculate()),this.#e}invalidate(){this.#t=!0}};var Yt=class r{on=H();[R];#t;#e;#r=C(()=>this.on.publish(this.state));constructor(t){this[R]=t,this.#t=T.clone(t.getState()),this.#e=new Qt(()=>Fe(t.getState()))}async update(){let t=this[R].getState();!T.equal(t,this.#t)&&(this.#e.invalidate(),this.#t=T.clone(t),this.#r(),await l.notifyWrite(this))}get state(){return l.notifyRead(this),this.#e.get()}async mutate(t){return this[R].mutate(t)}lens(t){let e=new r({getState:()=>t(this[R].getState()),mutate:s=>this[R].mutate(o=>s(t(o))),registerLens:this[R].registerLens});return this[R].registerLens(e),e}};var q=class{#t=[];clear(){this.#t.forEach(t=>t()),this.#t=[]}observe(t,e){let{seen:s,result:o}=l.observe(t);this.clear();for(let n of s){let i=l.subscribe(n,e);this.#t.push(i)}return o}};function Je(r,t){for(let[e,s]of Object.entries(t))vr(r,e,s)}function vr(r,t,e){let s=r.getAttribute(t),o=Sr(e);o!==s&&(o===null?r.removeAttribute(t):r.setAttribute(t,o))}function Sr(r){return typeof r=="string"?r:typeof r=="number"?r.toString():r?"":null}function w(r){let{scope:t,position:e}=A.increment();return t.values.guarantee(e,r)}function B(r){let{scope:t}=A.increment();return w(()=>t.mounts.mount(r))}var Xt=class{#t=[];#e=[];mount(t){this.#t.push(t),this.#e.push(t())}unmountAll(){for(let t of this.#e)t();this.#e=[]}remountAll(){for(let t of this.#t)this.#e.push(t())}};var I=class{cx;position=0;values=new It;mounts=new Xt;constructor(t){this.cx=t}};var{I:Vi}=De;var Ke=r=>r.strings===void 0;var Qe={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},At=r=>(...t)=>({_$litDirective$:r,values:t}),te=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,s){this._$Ct=t,this._$AM=e,this._$Ci=s}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};var vt=(r,t)=>{let e=r._$AN;if(e===void 0)return!1;for(let s of e)s._$AO?.(t,!1),vt(s,t);return!0},ee=r=>{let t,e;do{if((t=r._$AM)===void 0)break;e=t._$AN,e.delete(r),r=t}while(e?.size===0)},Ye=r=>{for(let t;t=r._$AM;r=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(r))break;e.add(r),kr(t)}};function Er(r){this._$AN!==void 0?(ee(this),this._$AM=r,Ye(this)):this._$AM=r}function Cr(r,t=!1,e=0){let s=this._$AH,o=this._$AN;if(o!==void 0&&o.size!==0)if(t)if(Array.isArray(s))for(let n=e;n<s.length;n++)vt(s[n],!1),ee(s[n]);else s!=null&&(vt(s,!1),ee(s));else vt(this,r)}var kr=r=>{r.type==Qe.CHILD&&(r._$AP??=Cr,r._$AQ??=Er)},ut=class extends te{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,s){super._$AT(t,e,s),Ye(this),this.isConnected=t._$AU}_$AO(t,e=!0){t!==this.isConnected&&(this.isConnected=t,t?this.reconnected?.():this.disconnected?.()),e&&(vt(this,t),ee(this))}setValue(t){if(Ke(this._$Ct))this._$Ct._$AI(t,this);else{let e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}};function Rr(){Kt.register();let r=document.createElement("sly-shadow"),t=r.attachShadow({mode:"open"});return{host:r,shadow:t}}function S(r){return Xe(Rr,r)}S.setup=r=>(t=>Xe(r,t));function Xe(r,t){let e=At(class extends ut{#t;#e;#r;#s=new q;constructor(o){super(o);let{host:n,shadow:i}=r(),c=C(()=>{if(!this.#r)throw new Error("cannot render before props");if(!this.isConnected)return;let a=this.#o(this.#r);y(a,this.#t.shadow),this.#t.doneRender()});this.#t=new z(c,n,i),this.#e=new I(this.#t)}#o(o){return this.#r=o,this.#s.observe(()=>A.wrap(this.#e,()=>t(...this.#r)),this.#t.render)}render({props:o,children:n,attrs:i}){let{host:c}=this.#t;return this.isConnected&&(i&&Je(c,i),y(n,this.#t.host),y(this.#o(o),this.#t.shadow),this.#t.doneRender()),c}disconnected(){this.#e.mounts.unmountAll(),this.#s.clear()}reconnected(){this.#e.mounts.remountAll(),this.#t.render()}});function s(...o){return e({props:o})}return s.with=e,s}var Et={};ne(Et,{AsciiAnim:()=>nr,ErrorDisplay:()=>Ae,anims:()=>_e,make:()=>fs,makeAsciiAnim:()=>u,mock:()=>ds});var _e={};ne(_e,{arrow:()=>jr,bar:()=>Ur,bar2:()=>Dr,bar3:()=>zr,bar4:()=>qr,bin:()=>rs,binary:()=>ss,binary2:()=>os,block:()=>Br,block2:()=>Ir,brackets:()=>Fr,brackets2:()=>Jr,braille:()=>Hr,bright:()=>ps,clock:()=>as,cylon:()=>Gr,dots:()=>Kr,dots2:()=>Qr,earth:()=>we,fistbump:()=>cs,kiss:()=>is,lock:()=>us,moon:()=>ls,pie:()=>Vr,pulseblue:()=>ns,runner:()=>Wr,slider:()=>Zr,speaker:()=>hs,spinner:()=>Lr,wave:()=>Yr,wavepulse:()=>ts,wavepulse2:()=>es,wavescrub:()=>Xr});var W=x`
4
4
  * {
5
5
  margin: 0;
6
6
  padding: 0;
@@ -14,23 +14,23 @@ var pr=Object.defineProperty;var ne=(r,t)=>{for(var e in t)pr(r,e,{get:t[e],enum
14
14
  ::-webkit-scrollbar-track { background: transparent; }
15
15
  ::-webkit-scrollbar-thumb { background: #888; border-radius: 1em; }
16
16
  ::-webkit-scrollbar-thumb:hover { background: #999; }
17
- `;function re(r){return At(class extends ut{#t;#e=new _t(C(()=>{if(!this.#t)throw new Error("cannot render before props");if(this.isConnected){let e=this.render(...this.#t);this.setValue(e),this.#e.doneRender()}}));#r=new B(this.#e);#s=new q;update(e,s){let o=super.update(e,s);return this.isConnected&&this.#e.doneRender(),o}render(...e){return this.#t=e,this.#s.observe(()=>A.wrap(this.#r,()=>r(...this.#t)),this.#e.render)}disconnected(){this.#r.mounts.unmountAll(),this.#s.clear()}reconnected(){this.#r.mounts.remountAll(),this.#e.render()}})}function Xe(r){let t=re(r);return class extends HTMLElement{connectedCallback(){y(t(),this)}disconnectedCallback(){y(null,this)}}}function tr(r){return class extends HTMLElement{#t;#e;#r=new q;#s=this.attachShadow({mode:"open"});constructor(){super();let t=C(()=>{if(!this.isConnected)return;let e=this.#o();y(e,this.#t.shadow),this.#t.doneRender()});this.#t=new z(t,this,this.#s),this.#e=new B(this.#t)}#o(){return this.#r.observe(()=>A.wrap(this.#e,()=>r()),this.#t.render)}render(){y(this.#o(),this.#t.shadow),this.#t.doneRender()}connectedCallback(){this.#e.mounts.remountAll(),this.#t.render()}disconnectedCallback(){this.#e.mounts.unmountAll(),this.#r.clear()}}}function Rr(){let{scope:r}=A.increment();return r.cx}function er(){let r=Rr();if(!(r instanceof z))throw new Error("this hook only works on shadow views (but was called in a light view)");return r}function rr(){return er().host}function sr(){return er().shadow}function or(r,t){Rt(r,Or(t))}function Or(r){let t=[];if(Array.isArray(r)){let e=new Set(r.flat(1/0).reverse());for(let s of e)t.unshift(et(s))}else r!==void 0&&t.push(et(r));return t}function St(...r){let t=sr();w(()=>or(t,r))}var W=St;function v(r=""){let t=rr();w(()=>t.setAttribute("view",r))}function R(r){return w(()=>D(r))}function u(r,t){return()=>nr({hz:r,frames:t})}var nr=S(({hz:r,frames:t})=>{v("loading"),W(I,Tr);let e=R(0);return tt(()=>it(async()=>{await at(1e3/r);let s=e.get()+1;e.set(s>=t.length?0:s)})),t.at(e.get())}),Tr=x`
17
+ `;function re(r){return At(class extends ut{#t;#e=new _t(C(()=>{if(!this.#t)throw new Error("cannot render before props");if(this.isConnected){let e=this.render(...this.#t);this.setValue(e),this.#e.doneRender()}}));#r=new I(this.#e);#s=new q;update(e,s){let o=super.update(e,s);return this.isConnected&&this.#e.doneRender(),o}render(...e){return this.#t=e,this.#s.observe(()=>A.wrap(this.#r,()=>r(...this.#t)),this.#e.render)}disconnected(){this.#r.mounts.unmountAll(),this.#s.clear()}reconnected(){this.#r.mounts.remountAll(),this.#e.render()}})}function tr(r){let t=re(r);return class extends HTMLElement{connectedCallback(){y(t(),this)}disconnectedCallback(){y(null,this)}}}function er(r){return class extends HTMLElement{#t;#e;#r=new q;#s=this.attachShadow({mode:"open"});constructor(){super();let t=C(()=>{if(!this.isConnected)return;let e=this.#o();y(e,this.#t.shadow),this.#t.doneRender()});this.#t=new z(t,this,this.#s),this.#e=new I(this.#t)}#o(){return this.#r.observe(()=>A.wrap(this.#e,()=>r()),this.#t.render)}render(){y(this.#o(),this.#t.shadow),this.#t.doneRender()}connectedCallback(){this.#e.mounts.remountAll(),this.#t.render()}disconnectedCallback(){this.#e.mounts.unmountAll(),this.#r.clear()}}}function Pr(){let{scope:r}=A.increment();return r.cx}function rr(){let r=Pr();if(!(r instanceof z))throw new Error("this hook only works on shadow views (but was called in a light view)");return r}function $e(){return rr().host}function sr(){return rr().shadow}function or(r,t){Pt(r,Mr(t))}function Mr(r){let t=[];if(Array.isArray(r)){let e=new Set(r.flat(1/0).reverse());for(let s of e)t.unshift(et(s))}else r!==void 0&&t.push(et(r));return t}function St(...r){let t=sr();w(()=>or(t,r))}var V=St;function v(r=""){let t=$e();w(()=>t.setAttribute("view",r))}function P(r){return w(()=>D(r))}function u(r,t){return()=>nr({hz:r,frames:t})}var nr=S(({hz:r,frames:t})=>{v("loading"),V(W,Nr);let e=P(0);return B(()=>it(async()=>{await at(1e3/r);let s=e.get()+1;e.set(s>=t.length?0:s)})),t.at(e.get())}),Nr=x`
18
18
  :host {
19
19
  font-family: monospace;
20
20
  white-space: pre;
21
21
  user-select: none;
22
22
  }
23
- `;var m=20,pt=10,ht=4,Nr=u(m,["|","/","-","\\"]),Lr=u(m,["\u2808","\u2810","\u2820","\u2880","\u2840","\u2804","\u2802","\u2801"]),Hr=u(m,["\u2B06\uFE0F","\u2197\uFE0F","\u27A1\uFE0F","\u2198\uFE0F","\u2B07\uFE0F","\u2199\uFE0F","\u2B05\uFE0F","\u2196\uFE0F"]),jr=u(m,["\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1","\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1"]),Ur=u(m,["\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1"]),Dr=u(m,["\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B0\u25B1\u25B1","\u25B1\u25B0\u25B0\u25B0\u25B1","\u25B1\u25B1\u25B0\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B0\u25B0\u25B0","\u25B1\u25B0\u25B0\u25B0\u25B1","\u25B0\u25B0\u25B0\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1"]),zr=u(m,["\u25B1\u25B1\u25B1\u25B1\u25B1","\u25B1\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B0\u25B1\u25B1","\u25B0\u25B0\u25B0\u25B0\u25B1","\u25B0\u25B0\u25B0\u25B0\u25B0","\u25B0\u25B0\u25B0\u25B0\u25B0","\u25B1\u25B0\u25B0\u25B0\u25B0","\u25B1\u25B1\u25B0\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0"]),qr=u(m,["\u2581\u2581\u2581\u2581\u2581","\u2581\u2581\u2581\u2581\u2581","\u2588\u2581\u2581\u2581\u2581","\u2588\u2588\u2581\u2581\u2581","\u2588\u2588\u2588\u2581\u2581","\u2588\u2588\u2588\u2588\u2581","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2581\u2588\u2588\u2588\u2588","\u2581\u2581\u2588\u2588\u2588","\u2581\u2581\u2581\u2588\u2588","\u2581\u2581\u2581\u2581\u2588"]),Br=u(m,["\u2588\u2581\u2581\u2581\u2581","\u2588\u2581\u2581\u2581\u2581","\u2588\u2588\u2581\u2581\u2581","\u2588\u2588\u2588\u2581\u2581","\u2588\u2588\u2588\u2588\u2581","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2581\u2588\u2588\u2588\u2588","\u2581\u2581\u2588\u2588\u2588","\u2581\u2581\u2581\u2588\u2588","\u2581\u2581\u2581\u2581\u2588","\u2581\u2581\u2581\u2581\u2588","\u2581\u2581\u2581\u2588\u2588","\u2581\u2581\u2588\u2588\u2588","\u2581\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2581","\u2588\u2588\u2588\u2581\u2581","\u2588\u2588\u2581\u2581\u2581"]),Ir=u(ht,["\u{1F6B6}","\u{1F3C3}"]),Wr=u(pt,["\u25F7","\u25F6","\u25F5","\u25F4"]),Vr=u(m,["=----","-=---","--=--","---=-","----=","----=","---=-","--=--","-=---","=----"]),Gr=u(m,["o----","-o---","--o--","---o-","----o","----o","---o-","--o--","-o---","o----"]),Zr=u(pt,["[ ]","[ ]","[= ]","[== ]","[===]","[ ==]","[ =]"]),Fr=u(pt,["[ ]","[ ]","[= ]","[== ]","[===]","[ ==]","[ =]","[ ]","[ ]","[ =]","[ ==]","[===]","[== ]","[= ]"]),Jr=u(pt,[" "," ",". ",".. ","..."," .."," ."]),Kr=u(m,[". ",". ",".. ","..."," .."," ."," ."," ..","...",".. "]),Qr=u(m,[".....",".....",":....","::...",":::..","::::.",":::::",":::::",".::::","..:::","...::","....:"]),Yr=u(m,[":....",":....","::...",".::..","..::.","...::","....:","....:","...::","..::.",".::..","::..."]),Xr=u(m,[".....",".....","..:..",".:::.",".:::.",":::::",":::::","::.::",":...:"]),ts=u(m,[".....",".....","..:..",".:::.",".:::.",":::::",":::::","::.::",":...:",".....",".....",":...:","::.::",":::::",":::::",".:::.",".:::.","..:.."]),es=u(m,["000","100","110","111","011","001"]),rs=u(m,["11111","01111","00111","10011","11001","01100","00110","10011","11001","11100","11110"]),ss=u(m,["11111","01111","10111","11011","11101","11110","11111","11110","11101","11011","10111","01111"]),os=u(ht,["\u{1F539}","\u{1F535}"]),ns=u(pt,["\u{1F642}","\u{1F642}","\u{1F617}","\u{1F619}","\u{1F618}","\u{1F618}","\u{1F619}"]),is=u(m,["\u{1F550}","\u{1F551}","\u{1F552}","\u{1F553}","\u{1F554}","\u{1F555}","\u{1F556}","\u{1F557}","\u{1F558}","\u{1F559}","\u{1F55A}","\u{1F55B}"]),as=u(m,["\u{1F91C} \u{1F91B}","\u{1F91C} \u{1F91B}","\u{1F91C} \u{1F91B}"," \u{1F91C} \u{1F91B} "," \u{1F91C}\u{1F91B} "," \u{1F91C}\u{1F91B} "," \u{1F91C}\u{1F4A5}\u{1F91B} ","\u{1F91C} \u{1F4A5} \u{1F91B}","\u{1F91C} \u2728 \u{1F91B}","\u{1F91C} \u2728 \u{1F91B}"]),$e=u(ht,["\u{1F30E}","\u{1F30F}","\u{1F30D}"]),cs=u(ht,["\u{1F513}","\u{1F512}"]),us=u(ht,["\u{1F505}","\u{1F506}"]),ps=u(ht,["\u{1F508}","\u{1F508}","\u{1F509}","\u{1F50A}","\u{1F50A}","\u{1F509}"]),hs=u(pt,["\u{1F311}","\u{1F311}","\u{1F311}","\u{1F318}","\u{1F317}","\u{1F316}","\u{1F315}","\u{1F314}","\u{1F313}","\u{1F312}"]);var _e=S(r=>(v("error"),W(I,ls),typeof r=="string"?r:r instanceof Error?$`<strong>${r.name}:</strong> <span>${r.message}</span>`:"error")),ls=x`
23
+ `;var m=20,pt=10,ht=4,Lr=u(m,["|","/","-","\\"]),Hr=u(m,["\u2808","\u2810","\u2820","\u2880","\u2840","\u2804","\u2802","\u2801"]),jr=u(m,["\u2B06\uFE0F","\u2197\uFE0F","\u27A1\uFE0F","\u2198\uFE0F","\u2B07\uFE0F","\u2199\uFE0F","\u2B05\uFE0F","\u2196\uFE0F"]),Ur=u(m,["\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1","\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1"]),Dr=u(m,["\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B1","\u25B1\u25B1\u25B0\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B1\u25B0\u25B1\u25B1\u25B1"]),zr=u(m,["\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B0\u25B1\u25B1","\u25B1\u25B0\u25B0\u25B0\u25B1","\u25B1\u25B1\u25B0\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B0\u25B0\u25B0","\u25B1\u25B0\u25B0\u25B0\u25B1","\u25B0\u25B0\u25B0\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1"]),qr=u(m,["\u25B1\u25B1\u25B1\u25B1\u25B1","\u25B1\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B1\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B1\u25B1\u25B1","\u25B0\u25B0\u25B0\u25B1\u25B1","\u25B0\u25B0\u25B0\u25B0\u25B1","\u25B0\u25B0\u25B0\u25B0\u25B0","\u25B0\u25B0\u25B0\u25B0\u25B0","\u25B1\u25B0\u25B0\u25B0\u25B0","\u25B1\u25B1\u25B0\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B0\u25B0","\u25B1\u25B1\u25B1\u25B1\u25B0"]),Br=u(m,["\u2581\u2581\u2581\u2581\u2581","\u2581\u2581\u2581\u2581\u2581","\u2588\u2581\u2581\u2581\u2581","\u2588\u2588\u2581\u2581\u2581","\u2588\u2588\u2588\u2581\u2581","\u2588\u2588\u2588\u2588\u2581","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2581\u2588\u2588\u2588\u2588","\u2581\u2581\u2588\u2588\u2588","\u2581\u2581\u2581\u2588\u2588","\u2581\u2581\u2581\u2581\u2588"]),Ir=u(m,["\u2588\u2581\u2581\u2581\u2581","\u2588\u2581\u2581\u2581\u2581","\u2588\u2588\u2581\u2581\u2581","\u2588\u2588\u2588\u2581\u2581","\u2588\u2588\u2588\u2588\u2581","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2581\u2588\u2588\u2588\u2588","\u2581\u2581\u2588\u2588\u2588","\u2581\u2581\u2581\u2588\u2588","\u2581\u2581\u2581\u2581\u2588","\u2581\u2581\u2581\u2581\u2588","\u2581\u2581\u2581\u2588\u2588","\u2581\u2581\u2588\u2588\u2588","\u2581\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2588","\u2588\u2588\u2588\u2588\u2581","\u2588\u2588\u2588\u2581\u2581","\u2588\u2588\u2581\u2581\u2581"]),Wr=u(ht,["\u{1F6B6}","\u{1F3C3}"]),Vr=u(pt,["\u25F7","\u25F6","\u25F5","\u25F4"]),Gr=u(m,["=----","-=---","--=--","---=-","----=","----=","---=-","--=--","-=---","=----"]),Zr=u(m,["o----","-o---","--o--","---o-","----o","----o","---o-","--o--","-o---","o----"]),Fr=u(pt,["[ ]","[ ]","[= ]","[== ]","[===]","[ ==]","[ =]"]),Jr=u(pt,["[ ]","[ ]","[= ]","[== ]","[===]","[ ==]","[ =]","[ ]","[ ]","[ =]","[ ==]","[===]","[== ]","[= ]"]),Kr=u(pt,[" "," ",". ",".. ","..."," .."," ."]),Qr=u(m,[". ",". ",".. ","..."," .."," ."," ."," ..","...",".. "]),Yr=u(m,[".....",".....",":....","::...",":::..","::::.",":::::",":::::",".::::","..:::","...::","....:"]),Xr=u(m,[":....",":....","::...",".::..","..::.","...::","....:","....:","...::","..::.",".::..","::..."]),ts=u(m,[".....",".....","..:..",".:::.",".:::.",":::::",":::::","::.::",":...:"]),es=u(m,[".....",".....","..:..",".:::.",".:::.",":::::",":::::","::.::",":...:",".....",".....",":...:","::.::",":::::",":::::",".:::.",".:::.","..:.."]),rs=u(m,["000","100","110","111","011","001"]),ss=u(m,["11111","01111","00111","10011","11001","01100","00110","10011","11001","11100","11110"]),os=u(m,["11111","01111","10111","11011","11101","11110","11111","11110","11101","11011","10111","01111"]),ns=u(ht,["\u{1F539}","\u{1F535}"]),is=u(pt,["\u{1F642}","\u{1F642}","\u{1F617}","\u{1F619}","\u{1F618}","\u{1F618}","\u{1F619}"]),as=u(m,["\u{1F550}","\u{1F551}","\u{1F552}","\u{1F553}","\u{1F554}","\u{1F555}","\u{1F556}","\u{1F557}","\u{1F558}","\u{1F559}","\u{1F55A}","\u{1F55B}"]),cs=u(m,["\u{1F91C} \u{1F91B}","\u{1F91C} \u{1F91B}","\u{1F91C} \u{1F91B}"," \u{1F91C} \u{1F91B} "," \u{1F91C}\u{1F91B} "," \u{1F91C}\u{1F91B} "," \u{1F91C}\u{1F4A5}\u{1F91B} ","\u{1F91C} \u{1F4A5} \u{1F91B}","\u{1F91C} \u2728 \u{1F91B}","\u{1F91C} \u2728 \u{1F91B}"]),we=u(ht,["\u{1F30E}","\u{1F30F}","\u{1F30D}"]),us=u(ht,["\u{1F513}","\u{1F512}"]),ps=u(ht,["\u{1F505}","\u{1F506}"]),hs=u(ht,["\u{1F508}","\u{1F508}","\u{1F509}","\u{1F50A}","\u{1F50A}","\u{1F509}"]),ls=u(pt,["\u{1F311}","\u{1F311}","\u{1F311}","\u{1F318}","\u{1F317}","\u{1F316}","\u{1F315}","\u{1F314}","\u{1F313}","\u{1F312}"]);var Ae=S(r=>(v("error"),V(W,ms),typeof r=="string"?r:r instanceof Error?$`<strong>${r.name}:</strong> <span>${r.message}</span>`:"error")),ms=x`
24
24
  :host {
25
25
  font-family: monospace;
26
26
  color: red;
27
27
  }
28
- `;function ms(r=$e,t=e=>_e(e)){return(e,s)=>e.select({loading:r,ready:s,error:t})}function fs(){return(r,t)=>r.select({ready:t,loading:()=>"[loading]",error:()=>"[error]"})}var ir=S(()=>{v("loaders"),W(I,ds);let r=w(()=>wt.loading());return w(()=>Object.entries(Et.anims).map(([e,s])=>({key:e,loader:Et.make(s)}))).map(({key:e,loader:s})=>$`
28
+ `;function fs(r=we,t=e=>Ae(e)){return(e,s)=>e.select({loading:r,ready:s,error:t})}function ds(){return(r,t)=>r.select({ready:t,loading:()=>"[loading]",error:()=>"[error]"})}var ir=S(()=>{v("loaders"),V(W,ys);let r=w(()=>wt.loading());return w(()=>Object.entries(Et.anims).map(([e,s])=>({key:e,loader:Et.make(s)}))).map(({key:e,loader:s})=>$`
29
29
  <div data-anim="${e}">
30
30
  <span>${e}</span>
31
31
  <span>${s(r,()=>null)}</span>
32
32
  </div>
33
- `)}),ds=x`
33
+ `)}),ys=x`
34
34
  :host {
35
35
  display: flex;
36
36
  flex-direction: row;
@@ -71,11 +71,11 @@ div {
71
71
  min-height: 2.5em;
72
72
  }
73
73
  }
74
- `;var ar=re(r=>{let t=R(r);return $`
74
+ `;var ar=re(r=>{let t=P(r);return $`
75
75
  <button @click="${()=>t.value++}">${t()}</button>
76
- `});var cr=S(r=>{v("counter-shadow"),St(x`:host{display:inline-block} button{color:cyan}`);let t=R(r);return $`
76
+ `});var cr=S(r=>{v("counter-shadow"),St(x`:host{display:inline-block} button{color:cyan}`);let t=P(r);return $`
77
77
  <button @click="${()=>t.value++}">${t()}</button>
78
- `});var ur=S(()=>(v("demo"),W(I,ys),$`
78
+ `});var ur=S(()=>(v("demo"),V(W,gs),$`
79
79
  <p>light ${ar(123)}</p>
80
80
 
81
81
  <p>
@@ -86,16 +86,16 @@ div {
86
86
  <time-light></time-light>
87
87
 
88
88
  ${ir()}
89
- `)),ys=x`
89
+ `)),gs=x`
90
90
  :host {
91
91
  display: flex;
92
92
  flex-direction: column;
93
93
  align-items: center;
94
94
  gap: 1em;
95
95
  }
96
- `;var se=class extends Xe(()=>{let t=R(Date.now());return tt(()=>it(async()=>{await at(100),t(Date.now())})),$`
96
+ `;var se=class extends tr(()=>{let t=P(Date.now());return B(()=>it(async()=>{await at(100),t(Date.now())})),$`
97
97
  <p>${t()}</p>
98
- `}){};var oe=class extends tr(()=>{v("time-shadow"),St(x`:host{display:inline-block} button{color:cyan}`);let t=R(Date.now());return tt(()=>it(async()=>{await at(100),t(Date.now())})),$`
98
+ `}){};var oe=class extends er(()=>{v("time-shadow"),St(x`:host{display:inline-block} button{color:cyan}`);let t=P(Date.now());return B(()=>it(async()=>{await at(100),t(Date.now())})),$`
99
99
  <p>${t()}</p>
100
100
  `}){};g.register({TimeShadow:oe,TimeLight:se});g.render(g(".demo"),ur());console.log("\u{1F99D} sly");
101
101
  /*! Bundled license information: