-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy pathes5.min.js
2 lines (2 loc) · 25.2 KB
/
es5.min.js
1
2
/*! (c) Andrea Giammarchi - ISC */
var HyperHTMLElement=function(t){"use strict";function e(t){"@babel/helpers - typeof";return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&a(t,e)}function o(t){return(o=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function a(t,e){return(a=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function u(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function c(t,e,n){return(c=u()?Reflect.construct:function(t,e,n){var r=[null];r.push.apply(r,e);var i=new(Function.bind.apply(t,r));return n&&a(i,n.prototype),i}).apply(null,arguments)}function s(t){var e="function"==typeof Map?new Map:void 0;return(s=function(t){if(null===t||(n=t,-1===Function.toString.call(n).indexOf("[native code]")))return t;var n;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,r)}function r(){return c(t,arguments,o(this).constructor)}return r.prototype=Object.create(t.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),a(r,t)})(t)}function l(t,e){if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function f(t){var e=u();return function(){var n,r=o(t);if(e){var i=o(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return l(this,n)}}var h={};try{h.WeakMap=WeakMap}catch(t){h.WeakMap=function(t,e){var n=e.defineProperty,r=e.hasOwnProperty,i=o.prototype;return i.delete=function(t){return this.has(t)&&delete t[this._]},i.get=function(t){return this.has(t)?t[this._]:void 0},i.has=function(t){return r.call(t,this._)},i.set=function(t,e){return n(t,this._,{configurable:!0,value:e}),this},o;function o(e){n(this,"_",{value:"_@ungap/weakmap"+t++}),e&&e.forEach(a,this)}function a(t){this.set(t[0],t[1])}}(Math.random(),Object)}var d=h.WeakMap,p={};try{p.WeakSet=WeakSet}catch(t){!function(t,e){var n=r.prototype;function r(){e(this,"_",{value:"_@ungap/weakmap"+t++})}n.add=function(t){return this.has(t)||e(t,this._,{value:!0,configurable:!0}),this},n.has=function(t){return this.hasOwnProperty.call(t,this._)},n.delete=function(t){return this.has(t)&&delete t[this._]},p.WeakSet=r}(Math.random(),Object.defineProperty)}var v=p.WeakSet,y=[].indexOf,b=function(t,e,n,r,i,o){for(var a=("selectedIndex"in e),u=a;r<i;){var c=t(n[r],1);if(e.insertBefore(c,o),a&&u&&c.selected){u=!u;var s=e.selectedIndex;e.selectedIndex=s<0?r:y.call(e.querySelectorAll("option"),c)}r++}},m=function(t,e){return t==e},g=function(t){return t},w=function(t,e,n,r,i,o,a){var u=o-i;if(u<1)return-1;for(;n-e>=u;){for(var c=e,s=i;c<n&&s<o&&a(t[c],r[s]);)c++,s++;if(s===o)return e;e=c+1}return-1},E=function(t,e,n,r,i){return n<r?t(e[n],0):0<n?t(e[n-1],-0).nextSibling:i},x=function(t,e,n,r){for(;n<r;)k(t(e[n++],-1))},_=function(t,e,n){for(var r=1,i=e;r<i;){var o=(r+i)/2>>>0;n<t[o]?i=o:r=o+1}return r},N=function(t,e,n,r,i,o,a,u,c,s,l,f,h){!function(t,e,n,r,i,o,a,u,c){for(var s=[],l=t.length,f=a,h=0;h<l;)switch(t[h++]){case 0:i++,f++;break;case 1:s.push(r[i]),b(e,n,r,i++,i,f<u?e(o[f],0):c);break;case-1:f++}for(h=0;h<l;)switch(t[h++]){case 0:a++;break;case-1:-1<s.indexOf(o[a])?a++:x(e,o,a++,a)}}(function(t,e,n,r,i,o,a){var u,c,s,l,f,h,d,p=n+o,v=[];t:for(u=0;u<=p;u++){if(u>50)return null;for(d=u-1,f=u?v[u-1]:[0,0],h=v[u]=[],c=-u;c<=u;c+=2){for(s=(l=c===-u||c!==u&&f[d+c-1]<f[d+c+1]?f[d+c+1]:f[d+c-1]+1)-c;l<o&&s<n&&a(r[i+l],t[e+s]);)l++,s++;if(l===o&&s===n)break t;h[u+c]=l}}var y=Array(u/2+p/2),b=y.length-1;for(u=v.length-1;u>=0;u--){for(;l>0&&s>0&&a(r[i+l-1],t[e+s-1]);)y[b--]=0,l--,s--;if(!u)break;d=u-1,f=u?v[u-1]:[0,0],(c=l-s)==-u||c!==u&&f[d+c-1]<f[d+c+1]?(s--,y[b--]=1):(l--,y[b--]=-1)}return y}(n,r,o,a,u,s,f)||function(t,e,n,r,i,o,a,u){var c=0,s=r<u?r:u,l=Array(s++),f=Array(s);f[0]=-1;for(var h=1;h<s;h++)f[h]=a;for(var d=i.slice(o,a),p=e;p<n;p++){var v=d.indexOf(t[p]);if(-1<v){var y=v+o;-1<(c=_(f,s,y))&&(f[c]=y,l[c]={newi:p,oldi:y,prev:l[c-1]})}}for(c=--s,--a;f[c]>a;)--c;s=u+r-c;var b=Array(s),m=l[c];for(--n;m;){for(var g=m,w=g.newi,E=g.oldi;n>w;)b[--s]=1,--n;for(;a>E;)b[--s]=-1,--a;b[--s]=0,--n,--a,m=m.prev}for(;n>=e;)b[--s]=1,--n;for(;a>=o;)b[--s]=-1,--a;return b}(n,r,i,o,a,u,c,s),t,e,n,r,a,u,l,h)},k=function(t){return(t.remove||function(){var t=this.parentNode;t&&t.removeChild(this)}).call(t)};var O=function(t,e,n,r){r||(r={});for(var i=r.compare||m,o=r.node||g,a=null==r.before?null:o(r.before,0),u=e.length,c=u,s=0,l=n.length,f=0;s<c&&f<l&&i(e[s],n[f]);)s++,f++;for(;s<c&&f<l&&i(e[c-1],n[l-1]);)c--,l--;var h=s===c,d=f===l;if(h&&d)return n;if(h&&f<l)return b(o,t,n,f,l,E(o,e,s,u,a)),n;if(d&&s<c)return x(o,e,s,c),n;var p=c-s,v=l-f,y=-1;if(p<v){if(-1<(y=w(n,f,l,e,s,c,i)))return b(o,t,n,f,y,o(e[s],0)),b(o,t,n,y+p,l,E(o,e,c,u,a)),n}else if(v<p&&-1<(y=w(e,s,c,n,f,l,i)))return x(o,e,s,y),x(o,e,y+v,c),n;return p<2||v<2?(b(o,t,n,f,l,o(e[s],0)),x(o,e,s,c),n):p===v&&function(t,e,n,r,i,o){for(;r<i&&o(n[r],t[e-1]);)r++,e--;return 0===e}(n,l,e,s,c,i)?(b(o,t,n,f,l,E(o,e,c,u,a)),n):(N(o,t,n,f,l,v,e,s,c,p,u,i,a),n)},C={};C.CustomEvent="function"==typeof CustomEvent?CustomEvent:function(t){return e.prototype=new e("").constructor.prototype,e;function e(t,e){e||(e={});var n=document.createEvent("CustomEvent");return n.initCustomEvent(t,!!e.bubbles,!!e.cancelable,e.detail),n}}();var S=C.CustomEvent,A={};try{A.Map=Map}catch(t){A.Map=function(){var t=0,e=[],n=[];return{delete:function(i){var o=r(i);return o&&(e.splice(t,1),n.splice(t,1)),o},forEach:function(t,r){e.forEach(function(e,i){t.call(r,n[i],e,this)},this)},get:function(e){return r(e)?n[t]:void 0},has:function(t){return r(t)},set:function(i,o){return n[r(i)?t:e.push(i)-1]=o,this}};function r(n){return-1<(t=e.indexOf(n))}}}var $=A.Map;function j(){return this}var T=function(t,e){var n="_"+t+"$";return{get:function(){return this[n]||M(this,n,e.call(this,t))},set:function(t){M(this,n,t)}}},M=function(t,e,n){return Object.defineProperty(t,e,{configurable:!0,value:"function"==typeof n?function(){return t._wire$=n.apply(this,arguments)}:n})[e]};Object.defineProperties(j.prototype,{ELEMENT_NODE:{value:1},nodeType:{value:-1}});var P,L,R={},D={},W=[],H=D.hasOwnProperty,F=0,I={attributes:R,define:function(t,e){t.indexOf("-")<0?(t in D||(F=W.push(t)),D[t]=e):R[t]=e},invoke:function(t,e){for(var n=0;n<F;n++){var r=W[n];if(H.call(t,r))return D[r](t[r],e)}}},z=Array.isArray||(L=(P={}.toString).call([]),function(t){return P.call(t)===L}),Z=function(t){var e="fragment",n="content"in i("template")?function(t){var e=i("template");return e.innerHTML=t,e.content}:function(t){var n=i(e),o=i("template"),a=null;if(/^[^\S]*?<(col(?:group)?|t(?:head|body|foot|r|d|h))/i.test(t)){var u=RegExp.$1;o.innerHTML="<table>"+t+"</table>",a=o.querySelectorAll(u)}else o.innerHTML=t,a=o.childNodes;return r(n,a),n};return function(t,o){return("svg"===o?function(t){var n=i(e),o=i("div");return o.innerHTML='<svg xmlns="http://www.w3.org/2000/svg">'+t+"</svg>",r(n,o.firstChild.childNodes),n}:n)(t)};function r(t,e){for(var n=e.length;n--;)t.appendChild(e[0])}function i(n){return n===e?t.createDocumentFragment():t.createElementNS("http://www.w3.org/1999/xhtml",n)}}(document);var B,V=function(t,e,n,r,i){var o="importNode"in t,a=t.createDocumentFragment();return a.appendChild(t.createTextNode("g")),a.appendChild(t.createTextNode("")),(o?t.importNode(a,!0):a.cloneNode(!0)).childNodes.length<2?function t(e,n){for(var r=e.cloneNode(),i=e.childNodes||[],o=i.length,a=0;n&&a<o;a++)r.appendChild(t(i[a],n));return r}:o?t.importNode:function(t,e){return t.cloneNode(!!e)}}(document),q="".trim||function(){return String(this).replace(/^\s+|\s+/g,"")},G="-"+Math.random().toFixed(6)+"%",K=!1;try{"content"in(B=document.createElement("template"))&&(B.innerHTML='<p tabindex="'+G+'"></p>',B.content.childNodes[0].getAttribute("tabindex")==G)||(G="_dt: "+G.slice(1,-1)+";",K=!0)}catch(t){}var U="\x3c!--"+G+"--\x3e",J=8,Q=1,X=3,Y=/^(?:plaintext|script|style|textarea|title|xmp)$/i,tt=/^(?:area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)$/i;var et=" \\f\\n\\r\\t",nt="[^"+et+"\\/>\"'=]+",rt="["+et+"]+"+nt,it="<([A-Za-z]+[A-Za-z0-9:._-]*)((?:",ot="(?:\\s*=\\s*(?:'[^']*?'|\"[^\"]*?\"|<[^>]*?>|"+nt.replace("\\/","")+"))?)",at=new RegExp(it+rt+ot+"+)(["+et+"]*/?>)","g"),ut=new RegExp(it+rt+ot+"*)(["+et+"]*/>)","g"),ct=new RegExp("("+rt+"\\s*=\\s*)(['\"]?)"+U+"\\2","gi");function st(t,e,n,r){return"<"+e+n.replace(ct,lt)+r}function lt(t,e,n){return e+(n||'"')+G+(n||'"')}function ft(t,e,n){return tt.test(e)?t:"<"+e+n+"></"+e+">"}var ht=K?function(t,e){var n=e.join(" ");return e.slice.call(t,0).sort(function(t,e){return n.indexOf(t.name)<=n.indexOf(e.name)?-1:1})}:function(t,e){return e.slice.call(t,0)};function dt(t,e){for(var n=e.length,r=0;r<n;)t=t.childNodes[e[r++]];return t}function pt(t,e,n,r){for(var i=t.attributes,o=[],a=[],u=ht(i,n),c=u.length,s=0;s<c;){var l,f=u[s++],h=f.value===G;if(h||1<(l=f.value.split(U)).length){var d=f.name;if(o.indexOf(d)<0){o.push(d);var p=n.shift().replace(h?/^(?:|[\S\s]*?\s)(\S+?)\s*=\s*('|")?$/:new RegExp("^(?:|[\\S\\s]*?\\s)("+d+")\\s*=\\s*('|\")[\\S\\s]*","i"),"$1"),v=i[p]||i[p.toLowerCase()];if(h)e.push(yt(v,r,p,null));else{for(var y=l.length-2;y--;)n.shift();e.push(yt(v,r,p,l))}}a.push(f)}}s=0;for(var b=(0<(c=a.length)&&K&&!("ownerSVGElement"in t));s<c;){var m=a[s++];b&&(m.value=""),t.removeAttribute(m.name)}var g=t.nodeName;if(/^script$/i.test(g)){var w=document.createElement(g);for(c=i.length,s=0;s<c;)w.setAttributeNode(i[s++].cloneNode(!0));w.textContent=t.textContent,t.parentNode.replaceChild(w,t)}}function vt(t,e){return{type:"any",node:t,path:e}}function yt(t,e,n,r){return{type:"attr",node:t,path:e,name:n,sparse:r}}function bt(t,e){return{type:"text",node:t,path:e}}var mt,gt=(mt=new d,{get:function(t){return mt.get(t)},set:function(t,e){return mt.set(t,e),e}});function wt(t,e){var n=(t.convert||function(t){return t.join(U).replace(ut,ft).replace(at,st)})(e),r=t.transform;r&&(n=r(n));var i=Z(n,t.type);_t(i);var o=[];return function t(e,n,r,i){for(var o=e.childNodes,a=o.length,u=0;u<a;){var c=o[u];switch(c.nodeType){case Q:var s=i.concat(u);pt(c,n,r,s),t(c,n,r,s);break;case J:var l=c.textContent;if(l===G)r.shift(),n.push(Y.test(e.nodeName)?bt(e,i):vt(c,i.concat(u)));else switch(l.slice(0,2)){case"/*":if("*/"!==l.slice(-2))break;case"👻":e.removeChild(c),u--,a--}break;case X:Y.test(e.nodeName)&&q.call(c.textContent)===U&&(r.shift(),n.push(bt(e,i)))}u++}}(i,o,e.slice(0),[]),{content:i,updates:function(n){for(var r=[],i=o.length,a=0,u=0;a<i;){var c=o[a++],s=dt(n,c.path);switch(c.type){case"any":r.push({fn:t.any(s,[]),sparse:!1});break;case"attr":var l=c.sparse,f=t.attribute(s,c.name,c.node);null===l?r.push({fn:f,sparse:!1}):(u+=l.length-2,r.push({fn:f,sparse:!0,values:l}));break;case"text":r.push({fn:t.text(s),sparse:!1}),s.textContent=""}}return i+=u,function(){var t=arguments.length;if(i!==t-1)throw new Error(t-1+" values instead of "+i+"\n"+e.join("${value}"));for(var o=1,a=1;o<t;){var u=r[o-a];if(u.sparse){var c=u.values,s=c[0],l=1,f=c.length;for(a+=f-2;l<f;)s+=arguments[o++]+c[l++];u.fn(s)}else u.fn(arguments[o++])}return n}}}}var Et=[];function xt(t){var e=Et,n=_t;return function(r){return e!==r&&(n=function(t,e){var n=gt.get(e)||gt.set(e,wt(t,e));return n.updates(V.call(document,n.content,!0))}(t,e=r)),n.apply(null,arguments)}}function _t(t){for(var e=t.childNodes,n=e.length;n--;){var r=e[n];1!==r.nodeType&&0===q.call(r.textContent).length&&t.removeChild(r)}}var Nt=function(){var t=/acit|ex(?:s|g|n|p|$)|rph|ows|mnc|ntw|ine[ch]|zoo|^ord/i,n=/([^A-Z])([A-Z]+)/g;return function(t,e){return"ownerSVGElement"in t?function(t,e){var n;e?n=e.cloneNode(!0):(t.setAttribute("style","--hyper:style;"),n=t.getAttributeNode("style"));return n.value="",t.setAttributeNode(n),i(n,!0)}(t,e):i(t.style,!1)};function r(t,e,n){return e+"-"+n.toLowerCase()}function i(i,o){var a,u;return function(c){var s,l,f,h;switch(e(c)){case"object":if(c){if("object"===a){if(!o&&u!==c)for(l in u)l in c||(i[l]="")}else o?i.value="":i.cssText="";for(l in s=o?{}:i,c)f="number"!=typeof(h=c[l])||t.test(l)?h:h+"px",!o&&/^--/.test(l)?s.setProperty(l,f):s[l]=f;a="object",o?i.value=function(t){var e,i=[];for(e in t)i.push(e.replace(n,r),":",t[e],";");return i.join("")}(u=s):u=c;break}default:u!=c&&(a="string",u=c,o?i.value=c||"":i.cssText=c||"")}}}}(),kt=function(t,e){return(e=n.prototype).ELEMENT_NODE=1,e.nodeType=111,e.remove=function(t){var e=this.childNodes,n=this.firstChild,r=this.lastChild;if(this._=null,t&&2===e.length)r.parentNode.removeChild(r);else{var i=this.ownerDocument.createRange();i.setStartBefore(t?e[1]:n),i.setEndAfter(r),i.deleteContents()}return n},e.valueOf=function(t){var e=this._,n=null==e;if(n&&(e=this._=this.ownerDocument.createDocumentFragment()),n||t)for(var r=this.childNodes,i=0,o=r.length;i<o;i++)e.appendChild(r[i]);return e},n;function n(e){var n=this.childNodes=t.call(e,0);this.firstChild=n[0],this.lastChild=n[n.length-1],this.ownerDocument=n[0].ownerDocument,this._=null}}([].slice),Ot="ownerSVGElement",Ct=j.prototype.nodeType,St=kt.prototype.nodeType,At=function(t){var e=t.Event,n=t.WeakSet,r=!0,i=null;return function(t){return r&&(r=!r,i=new n,function(t){var r=new n,o=new n;try{new MutationObserver(s).observe(t,{subtree:!0,childList:!0})}catch(e){var a=0,u=[],c=function(t){u.push(t),clearTimeout(a),a=setTimeout(function(){s(u.splice(a=0,u.length))},0)};t.addEventListener("DOMNodeRemoved",function(t){c({addedNodes:[],removedNodes:[t.target]})},!0),t.addEventListener("DOMNodeInserted",function(t){c({addedNodes:[t.target],removedNodes:[]})},!0)}function s(t){for(var e,n=t.length,i=0;i<n;i++)l((e=t[i]).removedNodes,"disconnected",o,r),l(e.addedNodes,"connected",r,o)}function l(t,n,r,i){for(var o,a=new e(n),u=t.length,c=0;c<u;1===(o=t[c++]).nodeType&&f(o,a,n,r,i));}function f(t,e,n,r,o){i.has(t)&&!r.has(t)&&(o.delete(t),r.add(t),t.dispatchEvent(e));for(var a=t.children||[],u=a.length,c=0;c<u;f(a[c++],e,n,r,o));}}(t.ownerDocument)),i.add(t),t}}({Event:S,WeakSet:v}),$t=function(t){return{html:t}},jt=function t(e,n){switch(e.nodeType){case St:return 1/n<0?n?e.remove(!0):e.lastChild:n?e.valueOf(!0):e.firstChild;case Ct:return t(e.render(),n);default:return e}},Tt=function(t,e){e(t.placeholder),"text"in t?Promise.resolve(t.text).then(String).then(e):"any"in t?Promise.resolve(t.any).then(e):"html"in t?Promise.resolve(t.html).then($t).then(e):Promise.resolve(I.invoke(t,e)).then(e)},Mt=function(t){return null!=t&&"then"in t},Pt=/^(?:form|list)$/i,Lt=[].slice;function Rt(t){return this.type=t,xt(this)}Rt.prototype={attribute:function(t,e,n){var r,i=Ot in t;if("style"===e)return Nt(t,n,i);if("."===e.slice(0,1))return function(t,e,n){return n?function(n){try{t[e]=n}catch(r){t.setAttribute(e,n)}}:function(n){t[e]=n}}(t,e.slice(1),i);if("?"===e.slice(0,1))return function(t,e,n){return function(r){n!==!!r&&((n=!!r)?t.setAttribute(e,""):t.removeAttribute(e))}}(t,e.slice(1));if(/^on/.test(e)){var o=e.slice(2);return"connected"===o||"disconnected"===o?At(t):e.toLowerCase()in t&&(o=o.toLowerCase()),function(e){r!==e&&(r&&t.removeEventListener(o,r,!1),r=e,e&&t.addEventListener(o,e,!1))}}if("data"===e||!i&&e in t&&!Pt.test(e))return function(n){r!==n&&(r=n,t[e]!==n&&null==n?(t[e]="",t.removeAttribute(e)):t[e]=n)};if(e in I.attributes)return function(n){var i=I.attributes[e](t,n);r!==i&&(r=i,null==i?t.removeAttribute(e):t.setAttribute(e,i))};var a=!1,u=n.cloneNode(!0);return function(e){r!==e&&(r=e,u.value!==e&&(null==e?(a&&(a=!1,t.removeAttributeNode(u)),u.value=e):(u.value=e,a||(a=!0,t.setAttributeNode(u)))))}},any:function(t,n){var r,i={node:jt,before:t},o=Ot in t?"svg":"html",a=!1;return function u(c){switch(e(c)){case"string":case"number":case"boolean":a?r!==c&&(r=c,n[0].textContent=c):(a=!0,r=c,n=O(t.parentNode,n,[function(t,e){return t.ownerDocument.createTextNode(e)}(t,c)],i));break;case"function":u(c(t));break;case"object":case"undefined":if(null==c){a=!1,n=O(t.parentNode,n,[],i);break}default:if(a=!1,r=c,z(c))if(0===c.length)n.length&&(n=O(t.parentNode,n,[],i));else switch(e(c[0])){case"string":case"number":case"boolean":u({html:c});break;case"object":if(z(c[0])&&(c=c.concat.apply([],c)),Mt(c[0])){Promise.all(c).then(u);break}default:n=O(t.parentNode,n,c,i)}else!function(t){return"ELEMENT_NODE"in t}(c)?Mt(c)?c.then(u):"placeholder"in c?Tt(c,u):"text"in c?u(String(c.text)):"any"in c?u(c.any):"html"in c?n=O(t.parentNode,n,Lt.call(Z([].concat(c.html).join(""),o).childNodes),i):u("length"in c?Lt.call(c):I.invoke(c,u)):n=O(t.parentNode,n,11===c.nodeType?Lt.call(c.childNodes):[c],i)}}},text:function(t){var n;return function r(i){if(n!==i){n=i;var o=e(i);"object"===o&&i?Mt(i)?i.then(r):"placeholder"in i?Tt(i,r):r("text"in i?String(i.text):"any"in i?i.any:"html"in i?[].concat(i.html).join(""):"length"in i?Lt.call(i).join(""):I.invoke(i,r)):"function"===o?r(i(t)):t.textContent=null==i?"":i}}}};var Dt="object"!==("undefined"==typeof document?"undefined":e(document)),Wt=function(t){var e,n=(e=(document.defaultView.navigator||{}).userAgent,/(Firefox|Safari)\/(\d+)/.test(e)&&!/(Chrom[eium]+|Android)\/(\d+)/.test(e)),r=!("raw"in t)||t.propertyIsEnumerable("raw")||!Object.isFrozen(t.raw);if(n||r){var i={},o=function(t){for(var e=".",n=0;n<t.length;n++)e+=t[n].length+"."+t[n];return i[e]||(i[e]=t)};if(r)Wt=o;else{var a=new d;Wt=function(t){return a.get(t)||function(t,e){return a.set(t,e),e}(t,o(t))}}}else Dt=!0;return Ht(t)};function Ht(t){return Dt?t:Wt(t)}function Ft(t){for(var e=arguments.length,n=[Ht(t)],r=1;r<e;)n.push(arguments[r++]);return n}var It=new d,zt=function(t,e){return null==t?Zt(e||"html"):Bt(t,e||"html")},Zt=function(t){var e,n,r;return function(){var i=Ft.apply(null,arguments);return r!==i[0]?(r=i[0],n=new Rt(t),e=Vt(n.apply(n,i))):n.apply(n,i),e}},Bt=function(t,e){var n=e.indexOf(":"),r=It.get(t),i=e;return-1<n&&(i=e.slice(n+1),e=e.slice(0,n)||"html"),r||It.set(t,r={}),r[i]||(r[i]=Zt(e))},Vt=function(t){var e=t.childNodes,n=e.length;return 1===n?e[0]:n?new kt(e):t},qt=new d;function Gt(){var t=qt.get(this),e=Ft.apply(null,arguments);return t&&t.template===e[0]?t.tagger.apply(null,e):function(t){var e=new Rt(Ot in this?"svg":"html");qt.set(this,{tagger:e,template:t}),this.textContent="",this.appendChild(e.apply(null,arguments))}.apply(this,e),this}var Kt=function(t){return Gt.bind(t)},Ut=I.define,Jt=Rt.prototype;function Qt(t){return arguments.length<2?null==t?Zt("html"):"string"==typeof t?Qt.wire(null,t):"raw"in t?Zt("html")(t):"nodeType"in t?Qt.bind(t):Bt(t,"html"):("raw"in t?Zt("html"):Qt.wire).apply(null,arguments)}Qt.Component=j,Qt.bind=Kt,Qt.define=Ut,Qt.diff=O,Qt.hyper=Qt,Qt.observe=At,Qt.tagger=Jt,Qt.wire=zt,Qt._={WeakMap:d,WeakSet:v},function(t){var n=new d,r=Object.create,i=function(t,e){var n={w:null,p:null};return e.set(t,n),n};Object.defineProperties(j,{for:{configurable:!0,value:function(t,o){return function(t,n,o,a){var u=n.get(t)||i(t,n);switch(e(a)){case"object":case"function":var c=u.w||(u.w=new d);return c.get(a)||function(t,e,n){return t.set(e,n),n}(c,a,new t(o));default:var s=u.p||(u.p=r(null));return s[a]||(s[a]=new t(o))}}(this,n.get(t)||function(t){var e=new $;return n.set(t,e),e}(t),t,null==o?"default":o)}}}),Object.defineProperties(j.prototype,{handleEvent:{value:function(t){var e=t.currentTarget;this["getAttribute"in e&&e.getAttribute("data-call")||"on"+t.type](t)}},html:T("html",t),svg:T("svg",t),state:T("state",function(){return this.defaultState}),defaultState:{get:function(){return{}}},dispatch:{value:function(t,e){var n=this._wire$;if(n){var r=new S(t,{bubbles:!0,cancelable:!0,detail:e});return r.component=this,(n.dispatchEvent?n:n.firstChild).dispatchEvent(r)}return!1}},setState:{value:function(t,e){var n=this.state,r="function"==typeof t?t.call(this,n):t;for(var i in r)n[i]=r[i];return!1!==e&&this.render(),this}}})}(Zt);var Xt=Object,Yt=[],te=Xt.defineProperty,ee=Xt.getOwnPropertyDescriptor,ne=Xt.getOwnPropertyNames,re=Xt.getOwnPropertySymbols||function(){return[]},ie=Xt.getPrototypeOf||function(t){return t.__proto__},oe="object"===("undefined"==typeof Reflect?"undefined":e(Reflect))&&Reflect.ownKeys||function(t){return ne(t).concat(re(t))},ae=Xt.setPrototypeOf||function(t,e){return t.__proto__=e,t},ue=function(t){return t.replace(/-([a-z])/g,function(t,e){return e.toUpperCase()})},ce=HTMLElement.prototype.attachShadow,se=new WeakMap,le=function(t){i(c,s(HTMLElement));var e,o,a,u=f(c);function c(){return n(this,c),u.apply(this,arguments)}return e=c,a=[{key:"define",value:function(t,e){var r=this.prototype,o=r.attributeChangedCallback,a=!!o,u=this.booleanAttributes||[];u.forEach(function(t){var e=ue(t);e in r||te(r,e,{configurable:!0,get:function(){return this.hasAttribute(t)},set:function(e){e&&"false"!==e?this.setAttribute(t,""):this.removeAttribute(t)}})});var s=(this.observedAttributes||[]).filter(function(t){return u.indexOf(t)<0});s.forEach(function(t){var e=ue(t);e in r||te(r,e,{configurable:!0,get:function(){return this.getAttribute(t)},set:function(e){null==e?this.removeAttribute(t):this.setAttribute(t,e)}})});var l=u.concat(s);l.length&&te(this,"observedAttributes",{get:function(){return l}});var h=r.created||function(){this.render()};te(r,"_init$",{configurable:!0,writable:!0,value:!0}),te(r,"attributeChangedCallback",{configurable:!0,value:function t(e,n,r){if(this._init$&&(he.call(this,h,l,u),this._init$))return this._init$$.push(t.bind(this,e,n,r));a&&n!==r&&o.apply(this,arguments)}});var d=r.connectedCallback,p=!!d;if(te(r,"connectedCallback",{configurable:!0,value:function t(){if(this._init$&&(he.call(this,h,l,u),this._init$))return this._init$$.push(t.bind(this));p&&d.apply(this,arguments)}}),ne(r).forEach(function(t){if(/^handle[A-Z]/.test(t)){var e="_"+t+"$",n=r[t];te(r,t,{configurable:!0,get:function(){return this[e]||(this[e]=n.bind(this))}})}}),"handleEvent"in r||te(r,"handleEvent",{configurable:!0,value:function(t){this[(t.currentTarget.dataset||{}).call||"on"+t.type](t)}}),e&&e.extends){for(var v=document.createElement(e.extends).constructor,y=function(t){i(r,v);var e=f(r);function r(){return n(this,r),e.apply(this,arguments)}return r}(),b=["length","name","arguments","caller","prototype"],m=[],g=null,w=this;(g=ie(w))&&([{target:y,base:g,keys:b},{target:y.prototype,base:g.prototype,keys:m}].forEach(function(t){var e=t.target,n=t.base,r=t.keys;oe(n).filter(function(t){return r.indexOf(t)<0}).forEach(function(t){r.push(t),te(e,t,ee(n,t))})}),w=g,g!==c););ae(this,y),ae(r,y.prototype),customElements.define(t,this,e)}else customElements.define(t,this);return Yt.push(this),this}}],(o=[{key:"attachShadow",value:function(){var t=ce.apply(this,arguments);return se.set(this,t),t}},{key:"refs",get:function(){var t={};if("_html$"in this){for(var e=(se.get(this)||this).querySelectorAll("[ref]"),n=e.length,r=0;r<n;r++){var i=e[r];t[i.getAttribute("ref")]=i}return Object.defineProperty(this,"refs",{value:t}),t}return t}},{key:"html",get:function(){return this._html$||(this.html=Kt(this.shadowRoot||this._shadowRoot||se.get(this)||this))},set:function(t){te(this,"_html$",{configurable:!0,value:t})}},{key:"render",value:function(){}},{key:"defaultState",get:function(){return{}}},{key:"state",get:function(){return this._state$||(this.state=this.defaultState)},set:function(t){te(this,"_state$",{configurable:!0,value:t})}},{key:"setState",value:function(t,e){var n=this.state,r="function"==typeof t?t.call(this,n):t;for(var i in r)n[i]=r[i];return!1!==e&&this.render(),this}}])&&r(e.prototype,o),a&&r(e,a),c}();le.Component=j,le.bind=Kt,le.intent=Ut,le.wire=zt,le.hyper=Qt;try{Symbol.hasInstance&&Yt.push(te(le,Symbol.hasInstance,{enumerable:!1,configurable:!0,value:function(t){return Yt.some(pe,ie(t))}}))}catch(t){}var fe={type:"DOMContentLoaded",handleEvent:function(){fe.ready()?(document.removeEventListener(fe.type,fe,!1),fe.list.splice(0).forEach(de)):setTimeout(fe.handleEvent)},ready:function(){return"complete"===document.readyState},list:[]};function he(t,e,n){if(fe.ready()||function(t,e,n){var r=this;do{if(r.nextSibling)return!0}while(r=r.parentNode);return setTimeout(he.bind(this,t,e,n)),!1}.call(this,t,e,n)){if(this._init$){var r=this._init$$||[];delete this._init$$;var i=te(this,"_init$",{value:!1});n.forEach(function(t){"false"===i.getAttribute(t)&&i.removeAttribute(t)}),e.forEach(function(t){if(i.hasOwnProperty(t)){var e=i[t];delete i[t],r.unshift(function(){i[t]=e})}}),t.call(i),r.forEach(de)}}else this.hasOwnProperty("_init$$")||te(this,"_init$$",{configurable:!0,value:[]}),fe.list.push(he.bind(this,t,e,n))}function de(t){t()}function pe(t){return this===t.prototype}return fe.ready()||document.addEventListener(fe.type,fe,!1),t.default=le,Object.defineProperty(t,"__esModule",{value:!0}),t.default}({});