You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
19 KiB

/*! For license information please see demo-386.js.LICENSE.txt */
!function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=0)}([function(t,e,n){t.exports=n(1)},function(t,e,n){"use strict";function r(t){return t.replace(/-(\w)/g,(t,e)=>e.toUpperCase())}function o(t){Array.from(t).forEach(s)}function s(t){const{parentNode:e}=t;t.remove?t.remove():e&&e.removeChild(t)}n.r(e);var i={EACH:0,IF:1,SIMPLE:2,TAG:3,SLOT:4};var u={ATTRIBUTE:0,EVENT:1,TEXT:2,VALUE:3};const{indexOf:a,slice:c}=[],l=(t,e,n,r,o,s)=>{const i="selectedIndex"in e;let u=i;for(;r<o;){const o=t(n[r],1);if(e.insertBefore(o,s),i&&u&&o.selected){u=!u;let{selectedIndex:t}=e;e.selectedIndex=t<0?r:a.call(e.querySelectorAll("option"),o)}r++}},h=(t,e)=>t==e,d=t=>t,p=(t,e,n,r,o,s,i)=>{const u=s-o;if(u<1)return-1;for(;n-e>=u;){let u=e,a=o;for(;u<n&&a<s&&i(t[u],r[a]);)u++,a++;if(a===s)return e;e=u+1}return-1},f=(t,e,n,r,o)=>n<r?t(e[n],0):0<n?t(e[n-1],-0).nextSibling:o,m=(t,e,n,r)=>{for(;n<r;)g(t(e[n++],-1))},b=(t,e,n)=>{let r=1,o=e;for(;r<o;){const e=(r+o)/2>>>0;n<t[e]?o=e:r=e+1}return r},O=(t,e,n,r,o,s,i,u,a,c,h,d,p)=>{((t,e,n,r,o,s,i,u,a)=>{const c=[],h=t.length;let d=i,p=0;for(;p<h;)switch(t[p++]){case 0:o++,d++;break;case 1:c.push(r[o]),l(e,n,r,o++,o,d<u?e(s[d],0):a);break;case-1:d++}for(p=0;p<h;)switch(t[p++]){case 0:i++;break;case-1:-1<c.indexOf(s[i])?i++:m(e,s,i++,i)}})(((t,e,n,r,o,s,i)=>{const u=n+s,a=[];let c,l,h,d,p,f,m;t:for(c=0;c<=u;c++){if(c>50)return null;for(m=c-1,p=c?a[c-1]:[0,0],f=a[c]=[],l=-c;l<=c;l+=2){for(d=l===-c||l!==c&&p[m+l-1]<p[m+l+1]?p[m+l+1]:p[m+l-1]+1,h=d-l;d<s&&h<n&&i(r[o+d],t[e+h]);)d++,h++;if(d===s&&h===n)break t;f[c+l]=d}}const b=Array(c/2+u/2);let O=b.length-1;for(c=a.length-1;c>=0;c--){for(;d>0&&h>0&&i(r[o+d-1],t[e+h-1]);)b[O--]=0,d--,h--;if(!c)break;m=c-1,p=c?a[c-1]:[0,0],l=d-h,l===-c||l!==c&&p[m+l-1]<p[m+l+1]?(h--,b[O--]=1):(d--,b[O--]=-1)}return b})(n,r,s,i,u,c,d)||((t,e,n,r,o,s,i,u)=>{let a=0,c=r<u?r:u;const l=Array(c++),h=Array(c);h[0]=-1;for(let t=1;t<c;t++)h[t]=i;const d=o.slice(s,i);for(let r=e;r<n;r++){const e=d.indexOf(t[r]);if(-1<e){const t=e+s;a=b(h,c,t),-1<a&&(h[a]=t,l[a]={newi:r,oldi:t,prev:l[a-1]})}}for(a=--c,--i;h[a]>i;)--a;c=u+r-a;const p=Array(c);let f=l[a];for(--n;f;){const{newi:t,oldi:e}=f;for(;n>t;)p[--c]=1,--n;for(;i>e;)p[--c]=-1,--i;p[--c]=0,--n,--i,f=f.prev}for(;n>=e;)p[--c]=1,--n;for(;i>=s;)p[--c]=-1,--i;return p})(n,r,o,s,i,u,a,c),t,e,n,r,i,u,h,p)},g=t=>(t.remove||v).call(t);function v(){const{parentNode:t}=this;t&&t.removeChild(this)}function y(t,e){return typeof t===e}function E(t){const e=t.ownerSVGElement;return!!e||null===e}function N(t){return!j(t.content)}function T(t){return y(t,"function")}function M(t){return!j(t)&&y(t,"object")}function j(t){return null==t}const _=Symbol("unmount"),A=Object.seal({nodes:[],mount(t,e){return this.update(t,e)},update(t,e){const{placeholder:n,nodes:r,childrenMap:o}=this,s=t===_?null:this.evaluate(t),i=s?Array.from(s):[],u=n.parentNode,{newChildrenMap:a,batches:c,futureNodes:b}=function(t,e,n,r){const{condition:o,template:s,childrenMap:i,itemName:u,getKey:a,indexName:c,root:l,isTemplateTag:h}=r,d=new Map,p=[],f=[];return t.forEach((t,r)=>{const m=function(t,e){let{itemName:n,indexName:r,index:o,item:s}=e;t[n]=s,r&&(t[r]=o);return t}(Object.create(e),{itemName:u,indexName:c,index:r,item:t}),b=a?a(m):r,O=i.get(b);if(function(t,e){return!!t&&!1===Boolean(t(e))}(o,m))return;const g=O?O.template:s.clone(),v=O?g.el:l.cloneNode(),y=!O,E=h&&y?function(t){const e=t.dom.cloneNode(!0);return{avoidDOMInjection:!0,fragment:e,children:Array.from(e.childNodes)}}(g):{};if(y?p.push(()=>g.mount(v,m,n,E)):p.push(()=>g.update(m,n)),h){const t=E.children||g.children;f.push(...t)}else f.push(v);i.delete(b),d.set(b,{template:g,context:m,index:r})}),{newChildrenMap:d,batches:p,futureNodes:f}}(i,t,e,this);return((t,e,n,r)=>{r||(r={});const o=r.compare||h,s=r.node||d,i=null==r.before?null:s(r.before,0),u=e.length;let a=u,c=0,b=n.length,g=0;for(;c<a&&g<b&&o(e[c],n[g]);)c++,g++;for(;c<a&&g<b&&o(e[a-1],n[b-1]);)a--,b--;const v=c===a,y=g===b;if(v&&y)return n;if(v&&g<b)return l(s,t,n,g,b,f(s,e,c,u,i)),n;if(y&&c<a)return m(s,e,c,a),n;const E=a-c,N=b-g;let T=-1;if(E<N){if(T=p(n,g,b,e,c,a,o),-1<T)return l(s,t,n,g,T,s(e[c],0)),l(s,t,n,T+E,b,f(s,e,a,u,i)),n}else if(N<E&&(T=p(e,c,a,n,g,b,o),-1<T))return m(s,e,c,T),m(s,e,T+N,a),n;E<2||N<2?(l(s,t,n,g,b,s(e[c],0)),m(s,e,c,a)):E===N&&((t,e,n,r,o,s)=>{for(;r<o&&s(n[r],t[e-1]);)r++,e--;return 0===e})(n,b,e,c,a,o)?l(s,t,n,g,b,f(s,e,a,u,i)):O(s,t,n,g,b,N,e,c,a,E,u,o,i)})(u,r,b,{before:n,node:x(Array.from(o.values()),e)}),c.forEach(t=>t()),this.childrenMap=a,this.nodes=b,this},unmount(t,e){return this.update(_,e),this}});function x(t,e){return(n,r)=>{if(r<0){const n=t.pop();if(n){const{template:t,context:r}=n;t.unmount(r,e,null)}}return n}}const w=Object.seal({mount(t,e){return this.update(t,e)},update(t,e){const n=!!this.evaluate(t),r=!this.value&&n,o=this.value&&!n,s=()=>{const n=this.node.cloneNode();this.placeholder.parentNode.insertBefore(n,this.placeholder),this.template=this.template.clone(),this.template.mount(n,t,e)};switch(!0){case r:s();break;case o:this.unmount(t);break;default:n&&this.template.update(t,e)}return this.value=n,this},unmount(t,e){return this.template.unmount(t,e,!0),this}});function S(t){throw new Error(t)}function P(t){return t.reduce((t,e)=>{const{value:n,type:o}=e;switch(!0){case!e.name&&0===o:return Object.assign({},t,n);case 3===o:t.value=e.value;break;default:t[r(e.name)]=e.value}return t},{})}const U="undefined"==typeof Element?{}:Element.prototype,C=function(t){const e=new Map,n=n=>(e.has(n)||e.set(n,t.call(this,n)))&&e.get(n);return n.cache=e,n}(t=>U.hasOwnProperty(t));function D(t,e,n,r){let{name:o}=e;if(!o)return r&&function(t,e,n){const r=e?Object.keys(e):[];Object.keys(n).filter(t=>!r.includes(t)).forEach(e=>t.removeAttribute(e))}(t,n,r),void(n&&function(t,e){Object.entries(e).forEach(e=>{let[n,r]=e;return D(t,{name:n},r)})}(t,n));!C(o)&&(function(t){return y(t,"boolean")}(n)||M(n)||T(n))&&(t[o]=n),t[function(t){return j(t)||!1===t||""===t||M(t)||T(t)?"removeAttribute":"setAttribute"}(n)](o,function(t,e){return!0===e?t:e}(o,n))}const B=/^on/,I={handleEvent(t){this[t.type](t)}},L=new WeakMap;function Y(t){return j(t)?"":t}const K=(t,e)=>{const n=t.childNodes[e];if(n.nodeType===Node.COMMENT_NODE){const e=document.createTextNode("");return t.replaceChild(e,n),e}return n};var k={0:D,1:function(t,e,n){let{name:r}=e;const o=r.replace(B,""),s=L.get(t)||(t=>{const e=Object.create(I);return L.set(t,e),e})(t),[i,u]=(t=>Array.isArray(t)?t:[t,!1])(n),a=s[o],c=i&&!a;a&&!i&&t.removeEventListener(o,s),c&&t.addEventListener(o,s,u),s[o]=i},2:function(t,e,n){t.data=Y(n)},3:function(t,e,n){t.value=Y(n)}};const R=Object.seal({mount(t){return this.value=this.evaluate(t),$(this,this.value),this},update(t){const e=this.evaluate(t);return this.value!==e&&($(this,e),this.value=e),this},unmount(){return 1===this.type&&$(this,null),this}});function $(t,e){return k[t.type](t.node,t,e,t.value)}function H(t,e){return Object.assign({},R,e,{node:2===e.type?K(t,e.childNodeIndex):t})}const z=new Map,F=Symbol("riot-component"),G=new Set,V="mount",q="update",W="unmount",X=Symbol.for("pure"),Z=Symbol("parent"),J=Symbol("attributes"),Q=Symbol("template");var tt=Object.freeze({__proto__:null,COMPONENTS_IMPLEMENTATION_MAP:z,DOM_COMPONENT_INSTANCE_PROPERTY:F,PLUGINS_SET:G,IS_DIRECTIVE:"is",VALUE_ATTRIBUTE:"value",MOUNT_METHOD_KEY:V,UPDATE_METHOD_KEY:q,UNMOUNT_METHOD_KEY:W,SHOULD_UPDATE_KEY:"shouldUpdate",ON_BEFORE_MOUNT_KEY:"onBeforeMount",ON_MOUNTED_KEY:"onMounted",ON_BEFORE_UPDATE_KEY:"onBeforeUpdate",ON_UPDATED_KEY:"onUpdated",ON_BEFORE_UNMOUNT_KEY:"onBeforeUnmount",ON_UNMOUNTED_KEY:"onUnmounted",PROPS_KEY:"props",STATE_KEY:"state",SLOTS_KEY:"slots",ROOT_KEY:"root",IS_PURE_SYMBOL:X,PARENT_KEY_SYMBOL:Z,ATTRIBUTES_KEY_SYMBOL:J,TEMPLATE_KEY_SYMBOL:Q});const et=(t,e)=>e?e===t?t[Z]:e:void 0,nt=Object.seal({attributes:[],getTemplateScope(t,e){return function(t,e,n){if(!t||!t.length)return n;const r=t.map(t=>Object.assign({},t,{value:t.evaluate(e)}));return Object.assign(Object.create(n||null),P(r))}(this.attributes,t,e)},mount(t,e){const n=!!t.slots&&t.slots.find(t=>{let{id:e}=t;return e===this.name}),{parentNode:r}=this.node,o=et(t,e);return this.template=n&&ht(n.html,n.bindings).createDOM(r),this.template&&(this.template.mount(this.node,this.getTemplateScope(t,o),o),this.template.children=function t(e,n){void 0===n&&(n=[]);const r=e.firstChild;if(r)return e.parentNode.insertBefore(r,e),[r,...t(e)];return n}(this.node)),s(this.node),this},update(t,e){if(this.template){const n=et(t,e);this.template.update(this.getTemplateScope(t,n),n)}return this},unmount(t,e,n){return this.template&&this.template.unmount(this.getTemplateScope(t,e),null,n),this}});function rt(t){return t.reduce((t,e)=>{let{bindings:n}=e;return t.concat(n)},[])}const ot=Object.seal({mount(t){return this.update(t)},update(t,e){const n=this.evaluate(t);return n===this.name?this.tag.update(t):(this.unmount(t,e,!0),this.name=n,this.tag=function(t,e,n){return void 0===e&&(e=[]),void 0===n&&(n=[]),t?t({slots:e,attributes:n}):ht(function(t){return t.reduce((t,e)=>t+e.html,"")}(e),[...rt(e),{expressions:n.map(t=>Object.assign({type:0},t))}])}(this.getComponent(n),this.slots,this.attributes),this.tag.mount(this.node,t)),this},unmount(t,e,n){return this.tag&&this.tag.unmount(n),this}});var st={1:function(t,e){let{evaluate:n,template:r}=e;const o=t.parentNode,i=document.createTextNode("");return o.insertBefore(i,t),s(t),Object.assign({},w,{node:t,evaluate:n,placeholder:i,template:r.createDOM(t)})},2:function(t,e){let{expressions:n}=e;return Object.assign({},(r=n.map(e=>H(t,e)),["mount","update","unmount"].reduce((t,e)=>Object.assign({},t,{[e]:t=>r.map(n=>n[e](t))&&o}),{})));var r,o},0:function(t,e){let{evaluate:n,condition:r,itemName:o,indexName:i,getKey:u,template:a}=e;const c=document.createTextNode(""),l=t.parentNode,h=t.cloneNode();return l.insertBefore(c,t),s(t),Object.assign({},A,{childrenMap:new Map,node:t,root:h,condition:r,evaluate:n,isTemplateTag:N(h),template:a.createDOM(t),getKey:u,indexName:i,itemName:o,placeholder:c})},3:function(t,e){let{evaluate:n,getComponent:r,slots:o,attributes:s}=e;return Object.assign({},ot,{node:t,evaluate:n,slots:o,attributes:s,getComponent:r})},4:function(t,e){let{name:n,attributes:r}=e;return Object.assign({},nt,{attributes:r,node:t,name:n})}};function it(t,e){return t.map(t=>2===t.type?Object.assign({},t,{childNodeIndex:t.childNodeIndex+e}):t)}function ut(t,e,n){const{selector:r,type:o,redundantAttribute:s,expressions:i}=e,u=r?t.querySelector(r):t;s&&u.removeAttribute(s);const a=i||[];return(st[o]||st[2])(u,Object.assign({},e,{expressions:n&&!r?it(a,n):a}))}function at(t,e){return E(t)?function(t,e){return e.ownerDocument.importNode((new window.DOMParser).parseFromString(`<svg xmlns="http://www.w3.org/2000/svg">${t}</svg>`,"application/xml").documentElement,!0)}(e,t):function(t,e){const n=N(e)?e:document.createElement("template");return n.innerHTML=t,n.content}(e,t)}function ct(t,e){switch(!0){case E(t):!function t(e,n){e.firstChild&&(n.appendChild(e.firstChild),t(e,n))}(e,t);break;case N(t):t.parentNode.replaceChild(e,t);break;default:t.appendChild(e)}}const lt=Object.freeze({createDOM(t){return this.dom=this.dom||function(t,e){return e&&("string"==typeof e?at(t,e):e)}(t,this.html),this},mount(t,e,n,r){if(void 0===r&&(r={}),!t)throw new Error("Please provide DOM node to mount properly your template");this.el&&this.unmount(e);const{fragment:o,children:s,avoidDOMInjection:i}=r,{parentNode:u}=s?s[0]:t,a=N(t),c=a?Math.max(Array.from(u.childNodes).indexOf(t),0):null;return this.isTemplateTag=a,this.createDOM(t),this.dom&&(this.fragment=o||this.dom.cloneNode(!0)),this.el=this.isTemplateTag?u:t,this.children=this.isTemplateTag?s||Array.from(this.fragment.childNodes):null,!i&&this.fragment&&ct(t,this.fragment),this.bindings=this.bindingsData.map(t=>ut(this.el,t,c)),this.bindings.forEach(t=>t.mount(e,n)),this},update(t,e){return this.bindings.forEach(n=>n.update(t,e)),this},unmount(t,e,n){if(this.el){switch(this.bindings.forEach(r=>r.unmount(t,e,n)),!0){case this.children&&null!==n:o(this.children);break;case!0===n:s(this.el);break;case null!==n:o(this.el.childNodes)}this.el=null}return this},clone(){return Object.assign({},this,{el:null})}});function ht(t,e){return void 0===e&&(e=[]),Object.assign({},lt,{html:t,bindingsData:e})}function dt(){return this}function pt(t){return T(t)?t.prototype&&t.prototype.constructor?new t:t():t}function ft(t,e,n,r){return void 0===r&&(r={}),Object.defineProperty(t,e,Object.assign({value:n,enumerable:!1,writable:!1,configurable:!0},r)),t}function mt(t,e,n){return Object.entries(e).forEach(e=>{let[r,o]=e;ft(t,r,o,n)}),t}function bt(t,e){return Object.entries(e).forEach(e=>{let[n,r]=e;t[n]||(t[n]=r)}),t}function Ot(t){return Array.isArray(t)?t:/^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(t))&&"number"==typeof t.length?Array.from(t):[t]}function gt(t,e){return Ot("string"==typeof t?(e||document).querySelectorAll(t):t)}const vt=t=>1===t.length?t[0]:t;function yt(t,e,n){const r="object"==typeof e?e:{[e]:n},o=Object.keys(r);return Ot(t).forEach(t=>{o.forEach(e=>t.setAttribute(e,r[e]))}),t}function Et(t,e){return function(t,e,n){const r="string"==typeof e?[e]:e;return vt(Ot(t).map(t=>vt(r.map(e=>t[n](e)))))}(t,e,"getAttribute")}const Nt=new Map,Tt=()=>Mt||(yt(Mt=gt("style[riot]")[0]||document.createElement("style"),"type","text/css"),Mt.parentNode||document.head.appendChild(Mt),Mt);var Mt,jt={CSS_BY_NAME:Nt,add(t,e){return Nt.has(t)||(Nt.set(t,e),this.inject()),this},inject(){return Tt().innerHTML=[...Nt.values()].join("\n"),this},remove(t){return Nt.has(t)&&(Nt.delete(t),this.inject()),this}};function _t(t){return Et(t,"is")||t.tagName.toLowerCase()}const At=Object.freeze({$(t){return gt(t,this.root)[0]},$$(t){return gt(t,this.root)}}),xt=Object.freeze({[V]:dt,[q]:dt,[W]:dt}),wt=Object.freeze({shouldUpdate:dt,onBeforeMount:dt,onMounted:dt,onBeforeUpdate:dt,onUpdated:dt,onBeforeUnmount:dt,onUnmounted:dt}),St=Object.assign({},xt,{clone:dt,createDOM:dt});function Pt(t,e){return void 0===e&&(e={}),Object.assign({},function(t){return Array.from(t.attributes).reduce((t,e)=>(t[r(e.name)]=e.value,t),{})}(t),pt(e))}const Ut=(t,e)=>t[F]=e;function Ct(t){return[V,q,W].reduce((e,n)=>(e[n]=t(n),e),{})}function Dt(t){let{css:e,template:n,exports:r,name:o}=t;const s=n?function(t,e){return t(ht,u,i,t=>e[t]||z.get(t))}(n,r?function(t){void 0===t&&(t={});return Object.entries(pt(t)).reduce((t,e)=>{let[n,r]=e;var o;return t[(o=n,o.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase())]=Dt(r),t},{})}(r.components):{}):St;return t=>{let{slots:i,attributes:u,props:a}=t;if(r&&r[X])return function(t,e){let{slots:n,attributes:r,props:o,css:s,template:i}=e;i&&S("Pure components can not have html"),s&&S("Pure components do not have css");const u=bt(t({slots:n,attributes:r,props:o}),xt);return Ct(t=>function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];if(t===V){const[t]=n;Ut(t,u)}return u[t](...n),u})}(r,{slots:i,attributes:u,props:a,css:e,template:n});const c=pt(r)||{},l=Bt({css:e,template:s,componentAPI:c,name:o})({slots:i,attributes:u,props:a});return{mount:(t,e,n)=>l.mount(t,n,e),update:(t,e)=>l.update(e,t),unmount:t=>l.unmount(t)}}}function Bt(t){let{css:e,template:n,componentAPI:r,name:o}=t;return e&&o&&jt.add(o,e),function t(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return function(){for(var n=arguments.length,o=new Array(n),s=0;s<n;s++)o[s]=arguments[s];return(o=[...r,...o]).length<e.length?t(e,...o):e(...o)}}(Lt)(mt(bt(r,Object.assign({},wt,{state:{}})),Object.assign({slots:null,root:null},At,{name:o,css:e,template:n})))}function It(t,e){return Object.assign({},t,pt(e))}function Lt(t,e){let{slots:n,attributes:r,props:o}=e;return s=function(t){return[...G].reduce((t,e)=>e(t)||t,t)}(mt(Object.create(t),{mount(e,s,i){return void 0===s&&(s={}),this[J]=function(t,e){void 0===e&&(e=[]);const n=e.map(e=>H(t,e)),r={};return Object.assign(r,Object.assign({expressions:n},Ct(t=>e=>(n.forEach(n=>n[t](e)),r))))}(e,r).mount(i),ft(this,"props",Object.freeze(Object.assign({},Pt(e,o),P(this[J].expressions)))),this.state=It(this.state,s),this[Q]=this.template.createDOM(e).clone(),Ut(e,this),t.name&&function(t,e){_t(t)!==e&&yt(t,"is",e)}(e,t.name),ft(this,"root",e),ft(this,"slots",n),this.onBeforeMount(this.props,this.state),this[Z]=i,this[Q].mount(e,this,i),this.onMounted(this.props,this.state),this},update(t,e){void 0===t&&(t={}),e&&this[J].update(e);const n=P(this[J].expressions);if(!1!==this.shouldUpdate(n,this.props))return ft(this,"props",Object.freeze(Object.assign({},this.props,n))),this.state=It(this.state,t),this.onBeforeUpdate(this.props,this.state),this[Q].update(this,this[Z]),this.onUpdated(this.props,this.state),this},unmount(t){return this.onBeforeUnmount(this.props,this.state),this[J].unmount(),this[Q].unmount(this,this[Z],null===t?null:!t),this.onUnmounted(this.props,this.state),this}})),Object.keys(t).filter(e=>T(t[e])).forEach(t=>{s[t]=s[t].bind(s)}),s;var s}const{DOM_COMPONENT_INSTANCE_PROPERTY:Yt,COMPONENTS_IMPLEMENTATION_MAP:Kt,PLUGINS_SET:kt}=tt;var Rt,$t,Ht,zt={css:null,exports:{state:{show:2,interval:1e3},onMounted(){this.$$(".tiny-fade > *").forEach((t,e)=>{t.classList.add("tiny-fade__item"),this.state.show>e&&t.classList.add("tiny-fade__item--active")});setInterval(()=>{this.toggle()},this.state.interval)},toggle(){const t=this.$(".tiny-fade__item--active:last-child");console.log(t)}},template:function(t,e,n,r){return t('<div class="tiny-fade"><slot-html expr0="expr0"></slot-html></div>',[{type:n.TAG,getComponent:r,evaluate:function(t){return"slot-html"},slots:[],attributes:[],redundantAttribute:"expr0",selector:"[expr0]"}])},name:"tiny-fade"};T(Rt=function(t){var e=t.onBeforeMount,n=t.onMounted;return t.onBeforeMount=function(){var n=t.root.innerHTML;n&&(t.root.innerHTML="",Object.defineProperty(t,"slot-html",{value:n,enumerable:!1,writable:!1,configurable:!0}));for(var r=arguments.length,o=new Array(r),s=0;s<r;s++)o[s]=arguments[s];e.apply.apply(e,[t].concat(o))},t.onMounted=function(){t.$("slot-html").outerHTML=t["slot-html"];for(var e=arguments.length,r=new Array(e),o=0;o<e;o++)r[o]=arguments[o];n.apply.apply(n,[t].concat(r))},t})||S("Plugins must be of type function"),kt.has(Rt)&&S("This plugin was already installed"),kt.add(Rt),function(t,e){let{css:n,template:r,exports:o}=e;Kt.has(t)&&S(`The component "${t}" was already registered`),Kt.set(t,Dt({name:t,css:n,template:r,exports:o}))}("tiny-fade",zt),gt("tiny-fade").map(t=>function(t,e,n){const r=n||_t(t);return z.has(r)||S(`The component named "${r}" was never registered`),z.get(r)({props:e}).mount(t)}(t,$t,Ht))}]);