UNPKG

11.8 kBJavaScriptView Raw
1let t,e,n,l=0,o=!1,s=!1,r=!1,c=!1,i=!1;const a=window,u=document,f={t:0,l:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,l)=>t.addEventListener(e,n,l),rel:(t,e,n,l)=>t.removeEventListener(e,n,l)},d=(()=>{try{return new CSSStyleSheet,!0}catch(t){}return!1})(),p=new WeakMap,m=t=>p.get(t),$=(t,e)=>p.set(e.o=t,e),w=(t,e)=>e in t,h=t=>console.error(t),y=new Map,b=new Map,g=[],j=[],_=[],v=(t,e)=>n=>{t.push(n),o||(o=!0,e&&4&f.t?k(S):f.raf(S))},O=(t,e)=>{let n=0,l=0;for(;n<t.length&&(l=performance.now())<e;)try{t[n++](l)}catch(o){h(o)}n===t.length?t.length=0:0!==n&&t.splice(0,n)},S=()=>{l++,(t=>{for(let n=0;n<t.length;n++)try{t[n](performance.now())}catch(e){h(e)}t.length=0})(g);const t=2==(6&f.t)?performance.now()+10*Math.ceil(l*(1/22)):1/0;O(j,t),O(_,t),j.length>0&&(_.push(...j),j.length=0),(o=g.length+j.length+_.length>0)?f.raf(S):l=0},k=t=>Promise.resolve().then(t),M=v(j,!0),R={},U=t=>"object"==(t=typeof t)||"function"===t,L=()=>a.CSS&&a.CSS.supports&&a.CSS.supports("color","var(--c)")?Promise.resolve():__sc_import_anjuna_docs("./p-d8631f0b.js").then(()=>{f.s=a.__stencil_cssshim}),P=async()=>{f.s=a.__stencil_cssshim;const t=new RegExp("/anjuna-docs(\\.esm)?\\.js($|\\?|#)"),e=Array.from(u.querySelectorAll("script")).find(e=>t.test(e.src)||"anjuna-docs"===e.getAttribute("data-stencil-namespace")),n=e["data-opts"];{const t=new URL(".",new URL(e.getAttribute("data-resources-url")||e.src,a.location.href));return x(t.href),window.customElements||await __sc_import_anjuna_docs("./p-d0882b30.js"),Object.assign(Object.assign({},n),{resourcesUrl:t.href})}},x=t=>{const e=(()=>`__sc_import_${"anjuna-docs".replace(/\s|-/g,"_")}`)();try{a[e]=new Function("w",`return import(w);//${Math.random()}`)}catch(n){const l=new Map;a[e]=n=>{const o=new URL(n,t).href;let s=l.get(o);if(!s){const t=u.createElement("script");t.type="module",t.src=URL.createObjectURL(new Blob([`import * as m from '${o}'; window.${e}.m = m;`],{type:"application/javascript"})),s=new Promise(n=>{t.onload=()=>{n(a[e].m),t.remove()}}),l.set(o,s),u.head.appendChild(t)}return s}}},C=new WeakMap,T=t=>"sc-"+t,A=(t,e,...n)=>{let l=null,o=null,s=!1,r=!1,c=[];const i=e=>{for(let n=0;n<e.length;n++)l=e[n],Array.isArray(l)?i(l):null!=l&&"boolean"!=typeof l&&((s="function"!=typeof t&&!U(l))&&(l=String(l)),s&&r?c[c.length-1].i+=l:c.push(s?E(null,l):l),r=s)};if(i(n),e){e.name&&(o=e.name);{const t=e.className||e.class;t&&(e.class="object"!=typeof t?t:Object.keys(t).filter(e=>t[e]).join(" "))}}const a=E(t,null);return a.u=e,c.length>0&&(a.p=c),a.$=o,a},E=(t,e)=>({t:0,h:t,i:e,g:null,p:null,u:null,$:null}),F={},N=(t,e,n,l,o,s)=>{if(n===l)return;let r=w(t,e),c=e.toLowerCase();if("class"===e){const e=t.classList,o=q(n),s=q(l);e.remove(...o.filter(t=>t&&!s.includes(t))),e.add(...s.filter(t=>t&&!o.includes(t)))}else if("style"===e){for(const e in n)l&&null!=l[e]||(e.includes("-")?t.style.removeProperty(e):t.style[e]="");for(const e in l)n&&l[e]===n[e]||(e.includes("-")?t.style.setProperty(e,l[e]):t.style[e]=l[e])}else if(r||"o"!==e[0]||"n"!==e[1]){const c=U(l);if((r||c&&null!==l)&&!o)try{if(t.tagName.includes("-"))t[e]=l;else{let o=null==l?"":l;"list"===e?r=!1:null!=n&&t[e]==o||(t[e]=o)}}catch(i){}null==l||!1===l?t.removeAttribute(e):(!r||4&s||o)&&!c&&t.setAttribute(e,l=!0===l?"":l)}else e="-"===e[2]?e.slice(3):w(a,c)?c.slice(2):c[2]+e.slice(3),n&&f.rel(t,e,n,!1),l&&f.ael(t,e,l,!1)},W=/\s/,q=t=>t?t.split(W):[],B=(t,e,n,l)=>{const o=11===e.g.nodeType&&e.g.host?e.g.host:e.g,s=t&&t.u||R,r=e.u||R;for(l in s)l in r||N(o,l,s[l],void 0,n,e.t);for(l in r)N(o,l,s[l],r[l],n,e.t)},D=(l,o,r,a)=>{let f,d,p,m=o.p[r],$=0;if(s||(c=!0,"slot"===m.h&&(t&&a.classList.add(t+"-s"),m.t|=m.p?2:1)),null!==m.i)f=m.g=u.createTextNode(m.i);else if(1&m.t)f=m.g=u.createTextNode("");else{if(i||(i="svg"===m.h),f=m.g=u.createElementNS(i?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",2&m.t?"slot-fb":m.h),i&&"foreignObject"===m.h&&(i=!1),B(null,m,i),(t=>null!=t)(t)&&f["s-si"]!==t&&f.classList.add(f["s-si"]=t),m.p)for($=0;$<m.p.length;++$)(d=D(l,m,$,f))&&f.appendChild(d);"svg"===m.h?i=!1:"foreignObject"===f.tagName&&(i=!0)}return f["s-hn"]=n,3&m.t&&(f["s-sr"]=!0,f["s-cr"]=e,f["s-sn"]=m.$||"",(p=l&&l.p&&l.p[r])&&p.h===m.h&&l.g&&H(l.g,!1)),f},H=(t,e)=>{f.t|=1;const l=t.childNodes;for(let o=l.length-1;o>=0;o--){const t=l[o];t["s-hn"]!==n&&t["s-ol"]&&(J(t).insertBefore(t,I(t)),t["s-ol"].remove(),t["s-ol"]=void 0,c=!0),e&&H(t,e)}f.t&=-2},V=(t,e,n,l,o,s)=>{let r,c=t["s-cr"]&&t["s-cr"].parentNode||t;for(;o<=s;++o)l[o]&&(r=D(null,n,o,t))&&(l[o].g=r,c.insertBefore(r,I(e)))},z=(t,e,n,l,o)=>{for(;e<=n;++e)(l=t[e])&&(r=!0,(o=l.g)["s-ol"]?o["s-ol"].remove():H(o,!0),o.remove())},G=(t,e)=>t.h===e.h&&("slot"!==t.h||t.$===e.$),I=t=>t&&t["s-ol"]||t,J=t=>(t["s-ol"]?t["s-ol"]:t).parentNode,K=(t,e)=>{const n=e.g=t.g,l=t.p,o=e.p;let s;i=n&&n.parentNode&&void 0!==n.ownerSVGElement,i="svg"===e.h||"foreignObject"!==e.h&&i,null===e.i?("slot"===e.h||B(t,e,i),null!==l&&null!==o?((t,e,n,l)=>{let o,s=0,r=0,c=e.length-1,i=e[0],a=e[c],u=l.length-1,f=l[0],d=l[u];for(;s<=c&&r<=u;)null==i?i=e[++s]:null==a?a=e[--c]:null==f?f=l[++r]:null==d?d=l[--u]:G(i,f)?(K(i,f),i=e[++s],f=l[++r]):G(a,d)?(K(a,d),a=e[--c],d=l[--u]):G(i,d)?("slot"!==i.h&&"slot"!==d.h||H(i.g.parentNode,!1),K(i,d),t.insertBefore(i.g,a.g.nextSibling),i=e[++s],d=l[--u]):G(a,f)?("slot"!==i.h&&"slot"!==d.h||H(a.g.parentNode,!1),K(a,f),t.insertBefore(a.g,i.g),a=e[--c],f=l[++r]):(o=D(e&&e[r],n,r,t),f=l[++r],o&&J(i.g).insertBefore(o,I(i.g)));s>c?V(t,null==l[u+1]?null:l[u+1].g,n,l,r,u):r>u&&z(e,s,c)})(n,l,e,o):null!==o?(null!==t.i&&(n.textContent=""),V(n,null,e,o,0,o.length-1)):null!==l&&z(l,0,l.length-1)):(s=n["s-cr"])?s.parentNode.textContent=e.i:t.i!==e.i&&(n.data=e.i),i&&"svg"===e.h&&(i=!1)},Q=t=>{let e,n,l,o,s,r,c=t.childNodes;for(n=0,l=c.length;n<l;n++)if(1===(e=c[n]).nodeType){if(e["s-sr"])for(s=e["s-sn"],e.hidden=!1,o=0;o<l;o++)if(c[o]["s-hn"]!==e["s-hn"])if(r=c[o].nodeType,""!==s){if(1===r&&s===c[o].getAttribute("slot")){e.hidden=!0;break}}else if(1===r||3===r&&""!==c[o].textContent.trim()){e.hidden=!0;break}Q(e)}},X=[],Y=t=>{let e,n,l,o,s=t.childNodes,c=s.length,i=0,a=0,u=0;for(c=s.length;i<c;i++){if((e=s[i])["s-sr"]&&(n=e["s-cr"]))for(o=e["s-sn"],a=(l=n.parentNode.childNodes).length-1;a>=0;a--)(n=l[a])["s-cn"]||n["s-nr"]||n["s-hn"]===e["s-hn"]||((3===(u=n.nodeType)||8===u)&&""===o||1===u&&null===n.getAttribute("slot")&&""===o||1===u&&n.getAttribute("slot")===o)&&(X.some(t=>t.j===n)||(r=!0,n["s-sn"]=o,X.push({_:e,j:n})));1===e.nodeType&&Y(e)}},Z=(t,e)=>{e&&!t.v&&e["s-p"].push(new Promise(e=>t.v=e))},tt=(t,e,n,l)=>{if(e.t|=16,4&e.t)return void(e.t|=512);const o=e.o,s=()=>et(t,e,n,o,l);return Z(e,e.O),l&&(e.t|=256,e.S&&(e.S.forEach(([t,e])=>ot(o,t,e)),e.S=null)),st(void 0,()=>M(s))},et=(l,o,i,a,d)=>{const p=l["s-rc"];d&&((t,e)=>{const n=((t,e)=>{let n=T(e.k),l=b.get(n);if(t=11===t.nodeType?t:u,l)if("string"==typeof l){let e,o=C.get(t=t.head||t);o||C.set(t,o=new Set),o.has(n)||((e=u.createElement("style")).innerHTML=l,t.insertBefore(e,t.querySelector("link")),o&&o.add(n))}else t.adoptedStyleSheets.includes(l)||(t.adoptedStyleSheets=[...t.adoptedStyleSheets,l]);return n})(t.getRootNode(),e);10&e.t&&(t["s-sc"]=n,t.classList.add(n+"-h"),2&e.t&&t.classList.add(n+"-s"))})(l,i);try{((l,o,i,a)=>{n=l.tagName;const d=o.M||E(null,null),p=(t=>t&&t.h===F)(a)?a:A(null,null,a);if(i.R&&(p.u=p.u||{},i.R.forEach(([t,e])=>p.u[e]=l[t])),p.h=null,p.t|=4,o.M=p,p.g=d.g=l,t=l["s-sc"],e=l["s-cr"],s=!1,r=!1,K(d,p),c){Y(p.g);for(let t=0;t<X.length;t++){const e=X[t];if(!e.j["s-ol"]){const t=u.createTextNode("");t["s-nr"]=e.j,e.j.parentNode.insertBefore(e.j["s-ol"]=t,e.j)}}f.t|=1;for(let t=0;t<X.length;t++){const e=X[t],n=e._.parentNode;let l=e._.nextSibling,o=e.j["s-ol"];for(;o=o.previousSibling;){let t=o["s-nr"];if(t&&t["s-sn"]===e.j["s-sn"]&&n===t.parentNode&&(!(t=t.nextSibling)||!t["s-nr"])){l=t;break}}(!l&&n!==e.j.parentNode||e.j.nextSibling!==l)&&e.j!==l&&n.insertBefore(e.j,l)}f.t&=-2}r&&Q(p.g),X.length=0})(l,o,i,a.render&&a.render())}catch(m){h(m)}o.t&=-17,o.t|=2,p&&(p.forEach(t=>t()),l["s-rc"]=void 0);{const t=l["s-p"],e=()=>nt(l,o,i);0===t.length?e():(Promise.all(t).then(e),o.t|=4,t.length=0)}},nt=(t,e,n)=>{const l=e.O;ot(e.o,"componentDidRender"),64&e.t||(e.t|=64,t.classList.add("hydrated"),e.U(t),l||lt()),e.v&&(e.v(),e.v=void 0),512&e.t&&k(()=>tt(t,e,n,!1)),e.t&=-517},lt=()=>{u.documentElement.classList.add("hydrated"),f.t|=2},ot=(t,e,n)=>{if(t&&t[e])try{return t[e](n)}catch(l){h(l)}},st=(t,e)=>t&&t.then?t.then(e):e(),rt=(t,e,n)=>{if(e.L){t.watchers&&(e.P=t.watchers);const l=Object.entries(e.L),o=t.prototype;if(l.forEach(([t,[l]])=>{(31&l||2&n&&32&l)&&Object.defineProperty(o,t,{get(){return((t,e)=>m(t).C.get(e))(this,t)},set(n){((t,e,n,l)=>{const o=m(this),s=o.T,r=o.C.get(e),c=o.t,i=o.o;if(!((n=((t,e)=>null==t||U(t)?t:4&e?"false"!==t&&(""===t||!!t):1&e?String(t):t)(n,l.L[e][0]))===r||8&c&&void 0!==r)&&(o.C.set(e,n),i)){if(l.P&&128&c){const t=l.P[e];t&&t.forEach(t=>{try{i[t](n,r,e)}catch(l){h(l)}})}2==(18&c)&&tt(s,o,l,!1)}})(0,t,n,e)},configurable:!0,enumerable:!0})}),1&n){const n=new Map;o.attributeChangedCallback=function(t,e,l){f.jmp(()=>{const e=n.get(t);this[e]=(null!==l||"boolean"!=typeof this[e])&&l})},t.observedAttributes=l.filter(([t,e])=>15&e[0]).map(([t,l])=>{const o=l[1]||t;return n.set(o,t),512&l[0]&&e.R.push([t,o]),o})}}return t},ct=t=>{ot(t,"connectedCallback")},it=t=>{const e=t["s-cr"]=u.createComment("");e["s-cn"]=!0,t.insertBefore(e,t.firstChild)},at=(t,e={})=>{const n=[],l=e.exclude||[],o=u.head,s=a.customElements,r=o.querySelector("meta[charset]"),c=u.createElement("style"),i=[];let $,w=!0;Object.assign(f,e),f.l=new URL(e.resourcesUrl||"./",u.baseURI).href,e.syncQueue&&(f.t|=4),t.forEach(t=>t[1].forEach(e=>{const o={t:e[0],k:e[1],L:e[2],A:e[3]};o.L=e[2],o.A=e[3],o.R=[],o.P={};const r=o.k,c=class extends HTMLElement{constructor(t){super(t),(t=>{const e={t:0,T:t,C:new Map};e.F=new Promise(t=>e.U=t),t["s-p"]=[],t["s-rc"]=[],p.set(t,e)})(t=this)}connectedCallback(){$&&(clearTimeout($),$=null),w?i.push(this):f.jmp(()=>((t,e)=>{if(0==(1&f.t)){const n=()=>{},l=m(t);if(e.A&&(l.N=((t,e,n)=>{e.S=e.S||[];const l=n.map(([n,l,o])=>{const s=((t,e)=>8&e?a:t)(t,n),r=((t,e)=>n=>{256&t.t?t.o[e](n):t.S.push([e,n])})(e,o),c=(t=>({passive:0!=(1&t),capture:0!=(2&t)}))(n);return f.ael(s,l,r,c),()=>f.rel(s,l,r,c)});return()=>l.forEach(t=>t())})(t,l,e.A)),!(1&l.t)){let n;l.t|=1,n||4&e.t&&it(t);{let e=t;for(;e=e.parentNode||e.host;)if(e["s-p"]){Z(l,l.O=e);break}}e.L&&Object.entries(e.L).forEach(([e,[n]])=>{if(31&n&&t.hasOwnProperty(e)){const n=t[e];delete t[e],t[e]=n}}),k(()=>(async(t,e,n,l,o)=>{if(0==(32&e.t)){e.t|=32;{if((o=(t=>{const e=t.k.replace(/-/g,"_"),n=t.W,l=y.get(n);return l?l[e]:__sc_import_anjuna_docs(`./${n}.entry.js`).then(t=>(y.set(n,t),t[e]),h)})(n)).then){const t=()=>{};o=await o,t()}o.isProxied||(n.P=o.watchers,rt(o,n,2),o.isProxied=!0);const t=()=>{};e.t|=8;try{new o(e)}catch(c){h(c)}e.t&=-9,e.t|=128,t(),ct(e.o)}const t=T(n.k);if(!b.has(t)&&o.style){const e=()=>{};((t,e,n)=>{let l=b.get(t);d&&n?(l=l||new CSSStyleSheet).replace(e):l=e,b.set(t,l)})(t,o.style,!!(1&n.t)),e()}}const s=e.O,r=()=>tt(t,e,n,!0);s&&s["s-rc"]?s["s-rc"].push(r):r()})(t,l,e))}ct(l.o),n()}})(this,o))}disconnectedCallback(){f.jmp(()=>(()=>{if(0==(1&f.t)){const t=m(this);t.N&&(t.N(),t.N=void 0)}})())}"s-hmr"(t){}forceUpdate(){((t,e)=>{{const n=m(t);2==(18&n.t)&&tt(t,n,e,!1)}})(this,o)}componentOnReady(){return m(this).F}};o.W=t[0],l.includes(r)||s.get(r)||(n.push(r),s.define(r,rt(c,o,1)))})),c.innerHTML=n+"{visibility:hidden}.hydrated{visibility:inherit}",c.setAttribute("data-styles",""),o.insertBefore(c,r?r.nextSibling:o.firstChild),w=!1,i.length>0?i.forEach(t=>t.connectedCallback()):f.jmp(()=>$=setTimeout(lt,30,"timeout"))},ut=t=>m(t).T;export{L as a,at as b,ut as g,A as h,P as p,$ as r};
\No newline at end of file