UNPKG

ce-decorators

Version:

Custom Element decorators for typescript

70 lines 66.5 kB
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("ce-decorators",[],t):"object"==typeof exports?exports["ce-decorators"]=t():e["ce-decorators"]=t()}(window,function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=35)}([function(e,t,n){"use strict";function r(e){return"class"===e.kind}function o(e){return"field"===e.kind||"method"===e.kind}function i(e){return"method"===e.kind}function a(e,t){var n=t({kind:"class",elements:[]}),r=void 0;return n.finisher&&(r=n.constructor?n.finisher(n.constructor):n.finisher(e)),r||n.constructor||e}function c(e,t,n,r){var o={key:t,initializer:n?n.initializer:void 0,initialize:n?n.initializer:void 0,kind:n&&(n.get||n.set||"function"==typeof n.value)?"method":"field",descriptor:n||{configurable:!0,enumerable:!1,value:null},placement:"own"},i=r(o);return i.extras&&i.extras.length>0&&i.extras.forEach(function(t){return Object.defineProperty(e.constructor.prototype,t.key,{configurable:!0,enumerable:!1,value:o.initialize?o.initialize():void 0,writable:!0})}),i.finisher&&i.finisher(e.constructor),i.descriptor}function u(e,t,n,r){var o=r({descriptor:n,key:t,kind:"method",placement:"prototype"});return o.extras&&o.extras.length>0&&o.extras.forEach(function(t){return Object.defineProperty(e.constructor.prototype,t.key,t.descriptor)}),o.finisher&&o.finisher(e.constructor),o.descriptor}n.d(t,"d",function(){return r}),n.d(t,"e",function(){return o}),n.d(t,"f",function(){return i}),n.d(t,"c",function(){return a}),n.d(t,"a",function(){return c}),n.d(t,"b",function(){return u})},function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n(1);function o(e){return(o="function"==typeof Symbol&&"symbol"===Object(r.a)(Symbol.iterator)?function(e){return Object(r.a)(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":Object(r.a)(e)})(e)}function i(e){return(i="function"==typeof Symbol&&"symbol"===o(Symbol.iterator)?function(e){return o(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":o(e)})(e)}},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}n.d(t,"a",function(){return r})},function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,"b",function(){return deserializeValue}),__webpack_require__.d(__webpack_exports__,"f",function(){return serializeValue}),__webpack_require__.d(__webpack_exports__,"a",function(){return camelToKebapCase}),__webpack_require__.d(__webpack_exports__,"c",function(){return kebapToCamelCase}),__webpack_require__.d(__webpack_exports__,"d",function(){return makeTemplateString}),__webpack_require__.d(__webpack_exports__,"e",function(){return needShadyDOM}),__webpack_require__.d(__webpack_exports__,"g",function(){return supportsAdoptingStyleSheets});var _babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(15);function deserializeValue(value,type){if(null==value&&type!==Boolean)return null;if(type===Boolean)return"false"!==value&&null!==value;if(type===Number)return parseFloat(value);if(type===String)return value;if(type===RegExp){var _Array$from=Array.from(/(\/(.*)\/([a-z]*))|(.+)/.exec(value)),_Array$from2=Object(_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_0__.a)(_Array$from,5),_2=_Array$from2[2],_3=_Array$from2[3],_4=_Array$from2[4];return _4?new RegExp(_4):_2?new RegExp(_2,_3||""):null}if(type===Function){var callback=eval("( function() {"+value+"} )");return callback}return type instanceof Object?JSON.parse(value):value}function serializeValue(e,t){return null==e?null:t===String?e:t instanceof Object?JSON.stringify(e):"".concat(e)}function camelToKebapCase(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function kebapToCamelCase(e){return e.toLowerCase().replace(/-([a-zA-Z])/g,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t[1].toUpperCase()})}function makeTemplateString(e,t){return Object.defineProperty(e,"raw",{value:t}),e}function needShadyDOM(){return window.ShadyCSS&&!window.ShadyCSS.nativeShadow}var supportsAdoptingStyleSheets="adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function o(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}n.d(t,"a",function(){return o})},function(e,t,n){"use strict";function r(e){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",function(){return r})},function(e,t,n){"use strict";n.d(t,"b",function(){return o}),n.d(t,"c",function(){return i}),n.d(t,"a",function(){return a});var r=new Map;function o(e){return r.get(e)}function i(e,t){r.set(e,t)}function a(){return Array.from(r.keys())}},function(e,t,n){"use strict";var r;n.d(t,"a",function(){return r}),function(e){e[e.INIT=0]="INIT",e[e.DIRTY=1]="DIRTY",e[e.UPDATE_PROPERTY=2]="UPDATE_PROPERTY",e[e.REFLECTING=3]="REFLECTING",e[e.UPDATE_FROM_ATTRIBUTE=4]="UPDATE_FROM_ATTRIBUTE",e[e.UPDATED=5]="UPDATED",e[e.EXECUTING_WATCHER=6]="EXECUTING_WATCHER"}(r||(r={}))},function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=new Map;function o(e){var t=r.get(e);return t||(t=new Map,r.set(e,t)),t}},function(e,t,n){"use strict";var r;n.d(t,"a",function(){return r}),function(e){e[e.CONNECTED=0]="CONNECTED",e[e.DISCONNECTED=1]="DISCONNECTED",e[e.INIT=2]="INIT",e[e.CONSTRUCTED=3]="CONSTRUCTED"}(r||(r={}))},function(e,t,n){"use strict";var r=n(11),o=n.n(r),i=n(18),a=n(2),c=n(16),u=n(5),s=n(4),l=n(14),f=n(22);function d(e,t,n){return(d=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(e){return!1}}()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&Object(f.a)(o,n.prototype),o}).apply(null,arguments)}function p(e){var t="function"==typeof Map?new Map:void 0;return(p=function(e){if(null===e||(n=e,-1===Function.toString.call(n).indexOf("[native code]")))return e;var n;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return d(e,arguments,Object(u.a)(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Object(f.a)(r,e)})(e)}var h=n(3),v=n(8),y=n(9),m=n(7),b=n(19),g=n(20),w=n(6),_=n(12);function O(){var e=this;this.componentWillRender(),this._renderScheduled=!1;var t=this.renderToElement();t===this.shadowRoot?function(e){if(null===this._templateCache){var t=Object(w.b)(this.constructor),n=t.cssStyles,r=t.tag,o=t.shadyCSSStyleSheetAdopted,i=t.templateCache;if(window.ShadyCSS&&!window.ShadyCSS.nativeShadow&&window.ShadyCSS.ScopingShim.prepareAdoptedCssText)o||(window.ShadyCSS.ScopingShim.prepareAdoptedCssText(n.map(function(e){return e.cssText}),r),Object(w.b)(this.constructor).shadyCSSStyleSheetAdopted=!0),this._templateCache=i||Object(h.d)(["",""],["",""]);else if(h.g)this.shadowRoot.adoptedStyleSheets=n,this._templateCache=i||Object(h.d)(["",""],["",""]);else{var a=n.map(function(e){return e.cssText}).reduce(function(e,t){return e+"\n"+t});this._templateCache=i||Object(h.d)(["<style>".concat(a,"</style>"),""],["<style>".concat(a,"</style>"),""])}i||(Object(w.b)(this.constructor).templateCache=this._templateCache)}Object(h.e)()?Object(_.G)(Object(_.u)(this._templateCache,this.render()),e,{scopeName:Object(w.b)(this.constructor).tag,eventContext:this}):Object(_.D)(Object(_.u)(this._templateCache,this.render()),e,{eventContext:this})}.apply(this,[t]):function(e){if(null===this._templateCache){var t=Object(w.b)(this.constructor),n=t.cssStyles,r=t.tag,o=t.shadyCSSStyleSheetAdopted,i=t.templateCache;if(!o){var a=document.createElement("style");a.setAttribute("scope",r);var c=n.map(function(e){return h.g?Array.from(e.rules).reduce(function(e,t){return e+t.cssText},""):e.cssText}).reduce(function(e,t){return e+t});a.textContent=c.replace(/(};?|,)\s*((\.?|#?)[a-z\-A-Z]+)/g,function(e){return"".concat(arguments.length<=1?void 0:arguments[1]," :host ").concat(arguments.length<=2?void 0:arguments[2])}).replace(/((:host\(([^\(]*)\))|(:host))/g,function(e){return"".concat(r).concat((arguments.length<=3?void 0:arguments[3])?arguments.length<=3?void 0:arguments[3]:"")}),document.querySelector("head").appendChild(a),Object(w.b)(this.constructor).shadyCSSStyleSheetAdopted=!0}this._templateCache=i||Object(h.d)(["",""],["",""]),Object(w.b)(this.constructor).templateCache=this._templateCache}Object(_.D)(this.render(),e,{eventContext:this})}.apply(this,[t]),this.componentDidRender(),this._firstRender&&(this.componentFirstRender(),this._firstRender=!1),this._propertyState=m.a.UPDATED,this._renderCompletedCallbacks.forEach(function(e){return e()}),this._renderCompletedCallbacks=[],null===this._layoutRAFReference&&(this._layoutRAFReference=window.requestAnimationFrame(function(){Promise.resolve().then(function(){e.componentDidLayout(),e._layoutRAFReference=null})}))}var S,E=[],k=null,x=1e3/60;function j(e){E.indexOf(e)<0&&E.push(e),function e(){null===k&&(k=window.requestAnimationFrame(function(){var t=x;do{var n=E.splice(0,1)[0];if(!n)break;var r=performance.now();O.apply(n);var o=performance.now()-r;t-=o}while(t>0);k=null,e()}))}()}n.d(t,"a",function(){return C}),n.d(t,"b",function(){return T}),function(e){e[e.DEFAULT=0]="DEFAULT",e[e.LAZY=1]="LAZY",e[e.PIPELINE_EXPERIMENTAL=2]="PIPELINE_EXPERIMENTAL"}(S||(S={}));var C=function(e){function t(){var e;return Object(a.a)(this,t),(e=Object(c.a)(this,Object(u.a)(t).call(this)))._renderStrategy=S.DEFAULT,e._renderCallbackResolver=null,e._componentState=y.a.INIT,e._propertyState=m.a.DIRTY,e._renderScheduled=!1,e._templateCache=null,e._firstRender=!0,e._renderCompletedCallbacks=[],e._constructedCompletedCallbacks=[],e._layoutRAFReference=null,Promise.resolve().then(function(){e._componentState===y.a.INIT&&(e._componentState=y.a.CONSTRUCTED,e._constructedCompletedCallbacks.forEach(function(e){return e()}),e._constructedCompletedCallbacks=[])}),e}return Object(l.a)(t,e),Object(s.a)(t,null,[{key:"_fromAttribute",value:function(e,t,n,r){if(r._propertyState!==m.a.REFLECTING){var o=Object(h.c)(e),i=Object(v.a)(this).get(o);(t=r[o])!==(n=i.converter?i.converter.fromAttribute?i.converter.fromAttribute(n,i.type):i.converter(n,i.type):Object(h.b)(n,i.type))&&(r._propertyState=m.a.UPDATE_FROM_ATTRIBUTE,this._fromProperty(o,t,n,r))}}},{key:"_fromProperty",value:function(e,t,n,r){if(t!==n){var o=Object(v.a)(this).get(e),i=Object(g.b)(this,e);n=i.reduce(function(e,n){return n.apply(r,[t,e])||e},n),this._reflectAttributes(o,r,n,e),r._propertyState=m.a.UPDATE_PROPERTY,r[e]=n,r._propertyState=m.a.DIRTY,Object(b.b)(this,e).forEach(function(e){return e.apply(r,[t,n])}),r.scheduleRender()}}},{key:"_reflectAttributes",value:function(e,t,n,r){!e.reflectAsAttribute&&void 0!==e.reflectAsAttribute||t._componentState===y.a.INIT||e.type!==Boolean&&e.type!==String&&e.type!==Number&&!0!==e.reflectAsAttribute||t._propertyState!==m.a.UPDATE_FROM_ATTRIBUTE&&(t._propertyState=m.a.REFLECTING,!1===n||null==n?t.removeAttribute(Object(h.a)(r)):e.converter&&e.converter.toAttribute?t.setAttribute(Object(h.a)(r),e.converter.toAttribute(n,e.type)):t.setAttribute(Object(h.a)(r),Object(h.f)(n,e.type)))}},{key:"observedAttributes",get:function(){return Array.from(Object(v.a)(this)).filter(function(e){return void 0!==e[1].type}).map(function(e){return Object(h.a)(e[0].toString())})}}]),Object(s.a)(t,[{key:"componentConnected",value:function(){}},{key:"componentDisconnected",value:function(){}},{key:"componentWillRender",value:function(){}},{key:"componentDidRender",value:function(){}},{key:"componentFirstRender",value:function(){}},{key:"componentDidLayout",value:function(){}},{key:"renderToElement",value:function(){return this.shadowRoot||this.attachShadow({mode:"open"}),this.shadowRoot}},{key:"waitForConstruction",value:function(){var e=Object(i.a)(o.a.mark(function e(){var t=this;return o.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise(function(e){t._constructedCompletedCallbacks.push(e)}));case 1:case"end":return e.stop()}},e)}));return function(){return e.apply(this,arguments)}}()},{key:"waitForRender",value:function(){var e=Object(i.a)(o.a.mark(function e(){var t=this;return o.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise(function(e){t._renderCompletedCallbacks.push(e)}));case 1:case"end":return e.stop()}},e)}));return function(){return e.apply(this,arguments)}}()},{key:"scheduleRender",value:function(){var e,t=this,n=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this._componentState!==y.a.CONNECTED||this._propertyState!==m.a.DIRTY||this._renderScheduled){if(n){if(this._renderScheduled){if(this._renderCallbackResolver)return void Promise.resolve().then(function(){t._renderCallbackResolver()});if(this._renderStrategy!==S.PIPELINE_EXPERIMENTAL)return;e=this,E.splice(E.indexOf(e),1)}Promise.resolve().then(function(){O.apply(t)})}}else switch(this._renderScheduled=!0,this._renderStrategy){case S.PIPELINE_EXPERIMENTAL:j(this);break;case S.LAZY:if(!n){new Promise(function(e){setTimeout(e),t._renderCallbackResolver=e}).then(function(){O.apply(t),t._renderCallbackResolver=null});break}default:Promise.resolve().then(function(){O.apply(t)})}}},{key:"connectedCallback",value:function(){var e=this;if(this._componentState===y.a.INIT||this._componentState===y.a.CONSTRUCTED){this._componentState=y.a.CONNECTED;var t=this._propertyState;this._propertyState=m.a.REFLECTING,Object(v.a)(this.constructor).forEach(function(t,n){var r=e[n.toString()];(r||0===r)&&e.constructor._reflectAttributes(t,e,r,n.toString())}),this._propertyState=t}else this._componentState=y.a.CONNECTED;this.componentConnected(),this.scheduleRender()}},{key:"disconnectedCallback",value:function(){this._componentState=y.a.DISCONNECTED,this.componentDisconnected()}},{key:"attributeChangedCallback",value:function(e,t,n){t!==n&&this.constructor._fromAttribute(e,t,n,this)}}]),t}(p(HTMLElement)),T=function(e){function t(){var e;return Object(a.a)(this,t),(e=Object(c.a)(this,Object(u.a)(t).call(this)))._renderStrategy=S.LAZY,e}return Object(l.a)(t,e),t}(C);"ShadyCSS"in window&&void 0===window.ShadyCSS.ScopingShim.prepareAdoptedCssText&&console.error('Please check your "@webcomponents/webcomponentsjs" polyfill, minimum version 2.2.6 required')},function(e,t,n){e.exports=n(36)},function(e,t,n){"use strict";var r=n(2),o=n(4),i=n(16),a=n(5);function c(e,t,n){return(c="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var r=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=Object(a.a)(e)););return e}(e,t);if(r){var o=Object.getOwnPropertyDescriptor(r,t);return o.get?o.get.call(n):o.value}})(e,t,n||e)}var u=n(14),s=n(1),l=new WeakMap,f=function(e){return function(){var t=e.apply(void 0,arguments);return l.set(t,!0),t}},d=function(e){return"function"==typeof e&&l.has(e)},p=void 0!==window.customElements&&void 0!==window.customElements.polyfillWrapFlushCallback,h=function(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,o=t;o!==n;){var i=o.nextSibling;e.insertBefore(o,r),o=i}},v=function(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=t;r!==n;){var o=r.nextSibling;e.removeChild(r),r=o}},y={},m={},b=n(17),g="{{lit-".concat(String(Math.random()).slice(2),"}}"),w="\x3c!--".concat(g,"--\x3e"),_=new RegExp("".concat(g,"|").concat(w)),O=function e(t,n){var o=this;Object(r.a)(this,e),this.parts=[],this.element=n;var i=-1,a=0,c=[];!function e(n){for(var r=n.content,u=document.createTreeWalker(r,133,null,!1),s=0;u.nextNode();){i++;var l=u.currentNode;if(1===l.nodeType){if(l.hasAttributes()){for(var f=l.attributes,d=0,p=0;p<f.length;p++)f[p].value.indexOf(g)>=0&&d++;for(;d-- >0;){var h=t.strings[a],v=k.exec(h)[2],y=v.toLowerCase()+"$lit$",m=l.getAttribute(y).split(_);o.parts.push({type:"attribute",index:i,name:v,strings:m}),l.removeAttribute(y),a+=m.length-1}}"TEMPLATE"===l.tagName&&e(l)}else if(3===l.nodeType){var b=l.data;if(b.indexOf(g)>=0){for(var w=l.parentNode,O=b.split(_),S=O.length-1,x=0;x<S;x++)w.insertBefore(""===O[x]?E():document.createTextNode(O[x]),l),o.parts.push({type:"node",index:++i});""===O[S]?(w.insertBefore(E(),l),c.push(l)):l.data=O[S],a+=S}}else if(8===l.nodeType)if(l.data===g){var j=l.parentNode;null!==l.previousSibling&&i!==s||(i++,j.insertBefore(E(),l)),s=i,o.parts.push({type:"node",index:i}),null===l.nextSibling?l.data="":(c.push(l),i--),a++}else for(var C=-1;-1!==(C=l.data.indexOf(g,C+1));)o.parts.push({type:"node",index:-1})}}(n);for(var u=0;u<c.length;u++){var s=c[u];s.parentNode.removeChild(s)}},S=function(e){return-1!==e.index},E=function(){return document.createComment("")},k=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F \x09\x0a\x0c\x0d"'>=\/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,x=function(){function e(t,n,o){Object(r.a)(this,e),this._parts=[],this.template=t,this.processor=n,this.options=o}return Object(o.a)(e,[{key:"update",value:function(e){var t=0,n=!0,r=!1,o=void 0;try{for(var i,a=this._parts[Symbol.iterator]();!(n=(i=a.next()).done);n=!0){var c=i.value;void 0!==c&&c.setValue(e[t]),t++}}catch(e){r=!0,o=e}finally{try{n||null==a.return||a.return()}finally{if(r)throw o}}var u=!0,s=!1,l=void 0;try{for(var f,d=this._parts[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var p=f.value;void 0!==p&&p.commit()}}catch(e){s=!0,l=e}finally{try{u||null==d.return||d.return()}finally{if(s)throw l}}}},{key:"_clone",value:function(){var e=this,t=p?this.template.element.content.cloneNode(!0):document.importNode(this.template.element.content,!0),n=this.template.parts,r=0,o=0;return function t(i){for(var a=document.createTreeWalker(i,133,null,!1),c=a.nextNode();r<n.length&&null!==c;){var u=n[r];if(S(u))if(o===u.index){if("node"===u.type){var s=e.processor.handleTextExpression(e.options);s.insertAfterNode(c.previousSibling),e._parts.push(s)}else{var l;(l=e._parts).push.apply(l,Object(b.a)(e.processor.handleAttributeExpressions(c,u.name,u.strings,e.options)))}r++}else o++,"TEMPLATE"===c.nodeName&&t(c.content),c=a.nextNode();else e._parts.push(void 0),r++}}(t),p&&(document.adoptNode(t),customElements.upgrade(t)),t}}]),e}(),j=function(){function e(t,n,o,i){Object(r.a)(this,e),this.strings=t,this.values=n,this.type=o,this.processor=i}return Object(o.a)(e,[{key:"getHTML",value:function(){for(var e=this.strings.length-1,t="",n=0;n<e;n++){var r=this.strings[n],o=k.exec(r);t+=o?r.substr(0,o.index)+o[1]+o[2]+"$lit$"+o[3]+g:r+w}return t+this.strings[e]}},{key:"getTemplateElement",value:function(){var e=document.createElement("template");return e.innerHTML=this.getHTML(),e}}]),e}(),C=function(e){function t(){return Object(r.a)(this,t),Object(i.a)(this,Object(a.a)(t).apply(this,arguments))}return Object(u.a)(t,e),Object(o.a)(t,[{key:"getHTML",value:function(){return"<svg>".concat(c(Object(a.a)(t.prototype),"getHTML",this).call(this),"</svg>")}},{key:"getTemplateElement",value:function(){var e=c(Object(a.a)(t.prototype),"getTemplateElement",this).call(this),n=e.content,r=n.firstChild;return n.removeChild(r),h(n,r.firstChild),e}}]),t}(j),T=function(e){return null===e||!("object"===Object(s.a)(e)||"function"==typeof e)},A=function(){function e(t,n,o){Object(r.a)(this,e),this.dirty=!0,this.element=t,this.name=n,this.strings=o,this.parts=[];for(var i=0;i<o.length-1;i++)this.parts[i]=this._createPart()}return Object(o.a)(e,[{key:"_createPart",value:function(){return new N(this)}},{key:"_getValue",value:function(){for(var e=this.strings,t=e.length-1,n="",r=0;r<t;r++){n+=e[r];var o=this.parts[r];if(void 0!==o){var i=o.value;if(null!=i&&(Array.isArray(i)||"string"!=typeof i&&i[Symbol.iterator])){var a=!0,c=!1,u=void 0;try{for(var s,l=i[Symbol.iterator]();!(a=(s=l.next()).done);a=!0){var f=s.value;n+="string"==typeof f?f:String(f)}}catch(e){c=!0,u=e}finally{try{a||null==l.return||l.return()}finally{if(c)throw u}}}else n+="string"==typeof i?i:String(i)}}return n+=e[t]}},{key:"commit",value:function(){this.dirty&&(this.dirty=!1,this.element.setAttribute(this.name,this._getValue()))}}]),e}(),N=function(){function e(t){Object(r.a)(this,e),this.value=void 0,this.committer=t}return Object(o.a)(e,[{key:"setValue",value:function(e){e===y||T(e)&&e===this.value||(this.value=e,d(e)||(this.committer.dirty=!0))}},{key:"commit",value:function(){for(;d(this.value);){var e=this.value;this.value=y,e(this)}this.value!==y&&this.committer.commit()}}]),e}(),P=function(){function e(t){Object(r.a)(this,e),this.value=void 0,this._pendingValue=void 0,this.options=t}return Object(o.a)(e,[{key:"appendInto",value:function(e){this.startNode=e.appendChild(E()),this.endNode=e.appendChild(E())}},{key:"insertAfterNode",value:function(e){this.startNode=e,this.endNode=e.nextSibling}},{key:"appendIntoPart",value:function(e){e._insert(this.startNode=E()),e._insert(this.endNode=E())}},{key:"insertAfterPart",value:function(e){e._insert(this.startNode=E()),this.endNode=e.endNode,e.endNode=this.startNode}},{key:"setValue",value:function(e){this._pendingValue=e}},{key:"commit",value:function(){for(;d(this._pendingValue);){var e=this._pendingValue;this._pendingValue=y,e(this)}var t=this._pendingValue;t!==y&&(T(t)?t!==this.value&&this._commitText(t):t instanceof j?this._commitTemplateResult(t):t instanceof Node?this._commitNode(t):Array.isArray(t)||t[Symbol.iterator]?this._commitIterable(t):t===m?(this.value=m,this.clear()):this._commitText(t))}},{key:"_insert",value:function(e){this.endNode.parentNode.insertBefore(e,this.endNode)}},{key:"_commitNode",value:function(e){this.value!==e&&(this.clear(),this._insert(e),this.value=e)}},{key:"_commitText",value:function(e){var t=this.startNode.nextSibling;e=null==e?"":e,t===this.endNode.previousSibling&&3===t.nodeType?t.data=e:this._commitNode(document.createTextNode("string"==typeof e?e:String(e))),this.value=e}},{key:"_commitTemplateResult",value:function(e){var t=this.options.templateFactory(e);if(this.value instanceof x&&this.value.template===t)this.value.update(e.values);else{var n=new x(t,e.processor,this.options),r=n._clone();n.update(e.values),this._commitNode(r),this.value=n}}},{key:"_commitIterable",value:function(t){Array.isArray(this.value)||(this.value=[],this.clear());var n,r=this.value,o=0,i=!0,a=!1,c=void 0;try{for(var u,s=t[Symbol.iterator]();!(i=(u=s.next()).done);i=!0){var l=u.value;void 0===(n=r[o])&&(n=new e(this.options),r.push(n),0===o?n.appendIntoPart(this):n.insertAfterPart(r[o-1])),n.setValue(l),n.commit(),o++}}catch(e){a=!0,c=e}finally{try{i||null==s.return||s.return()}finally{if(a)throw c}}o<r.length&&(r.length=o,this.clear(n&&n.endNode))}},{key:"clear",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.startNode;v(this.startNode.parentNode,e.nextSibling,this.endNode)}}]),e}(),R=function(){function e(t,n,o){if(Object(r.a)(this,e),this.value=void 0,this._pendingValue=void 0,2!==o.length||""!==o[0]||""!==o[1])throw new Error("Boolean attributes can only contain a single expression");this.element=t,this.name=n,this.strings=o}return Object(o.a)(e,[{key:"setValue",value:function(e){this._pendingValue=e}},{key:"commit",value:function(){for(;d(this._pendingValue);){var e=this._pendingValue;this._pendingValue=y,e(this)}if(this._pendingValue!==y){var t=!!this._pendingValue;this.value!==t&&(t?this.element.setAttribute(this.name,""):this.element.removeAttribute(this.name)),this.value=t,this._pendingValue=y}}}]),e}(),M=function(e){function t(e,n,o){var c;return Object(r.a)(this,t),(c=Object(i.a)(this,Object(a.a)(t).call(this,e,n,o))).single=2===o.length&&""===o[0]&&""===o[1],c}return Object(u.a)(t,e),Object(o.a)(t,[{key:"_createPart",value:function(){return new I(this)}},{key:"_getValue",value:function(){return this.single?this.parts[0].value:c(Object(a.a)(t.prototype),"_getValue",this).call(this)}},{key:"commit",value:function(){this.dirty&&(this.dirty=!1,this.element[this.name]=this._getValue())}}]),t}(A),I=function(e){function t(){return Object(r.a)(this,t),Object(i.a)(this,Object(a.a)(t).apply(this,arguments))}return Object(u.a)(t,e),t}(N),D=!1;try{var L={get capture(){return D=!0,!1}};window.addEventListener("test",L,L),window.removeEventListener("test",L,L)}catch(e){}var V=function(){function e(t,n,o){var i=this;Object(r.a)(this,e),this.value=void 0,this._pendingValue=void 0,this.element=t,this.eventName=n,this.eventContext=o,this._boundHandleEvent=function(e){return i.handleEvent(e)}}return Object(o.a)(e,[{key:"setValue",value:function(e){this._pendingValue=e}},{key:"commit",value:function(){for(;d(this._pendingValue);){var e=this._pendingValue;this._pendingValue=y,e(this)}if(this._pendingValue!==y){var t=this._pendingValue,n=this.value,r=null==t||null!=n&&(t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive),o=null!=t&&(null==n||r);r&&this.element.removeEventListener(this.eventName,this._boundHandleEvent,this._options),o&&(this._options=F(t),this.element.addEventListener(this.eventName,this._boundHandleEvent,this._options)),this.value=t,this._pendingValue=y}}},{key:"handleEvent",value:function(e){"function"==typeof this.value?this.value.call(this.eventContext||this.element,e):this.value.handleEvent(e)}}]),e}(),F=function(e){return e&&(D?{capture:e.capture,passive:e.passive,once:e.once}:e.capture)},z=function(){function e(){Object(r.a)(this,e)}return Object(o.a)(e,[{key:"handleAttributeExpressions",value:function(e,t,n,r){var o=t[0];return"."===o?new M(e,t.slice(1),n).parts:"@"===o?[new V(e,t.slice(1),r.eventContext)]:"?"===o?[new R(e,t.slice(1),n)]:new A(e,t,n).parts}},{key:"handleTextExpression",value:function(e){return new P(e)}}]),e}(),W=new z; /** * @license * Copyright (c) 2017 The Polymer Project Authors. All rights reserved. * This code may only be used under the BSD style license found at * http://polymer.github.io/LICENSE.txt * The complete set of authors may be found at * http://polymer.github.io/AUTHORS.txt * The complete set of contributors may be found at * http://polymer.github.io/CONTRIBUTORS.txt * Code distributed by Google as part of the polymer project is also * subject to an additional IP rights grant found at * http://polymer.github.io/PATENTS.txt */ function U(e){var t=B.get(e.type);void 0===t&&(t={stringsArray:new WeakMap,keyString:new Map},B.set(e.type,t));var n=t.stringsArray.get(e.strings);if(void 0!==n)return n;var r=e.strings.join(g);return void 0===(n=t.keyString.get(r))&&(n=new O(e,e.getTemplateElement()),t.keyString.set(r,n)),t.stringsArray.set(e.strings,n),n}var B=new Map,G=new WeakMap,q=function(e,t,n){var r=G.get(t);void 0===r&&(v(t,t.firstChild),G.set(t,r=new P(Object.assign({templateFactory:U},n))),r.appendInto(t)),r.setValue(e),r.commit()}; /** * @license * Copyright (c) 2017 The Polymer Project Authors. All rights reserved. * This code may only be used under the BSD style license found at * http://polymer.github.io/LICENSE.txt * The complete set of authors may be found at * http://polymer.github.io/AUTHORS.txt * The complete set of contributors may be found at * http://polymer.github.io/CONTRIBUTORS.txt * Code distributed by Google as part of the polymer project is also * subject to an additional IP rights grant found at * http://polymer.github.io/PATENTS.txt */ /** * @license * Copyright (c) 2017 The Polymer Project Authors. All rights reserved. * This code may only be used under the BSD style license found at * http://polymer.github.io/LICENSE.txt * The complete set of authors may be found at * http://polymer.github.io/AUTHORS.txt * The complete set of contributors may be found at * http://polymer.github.io/CONTRIBUTORS.txt * Code distributed by Google as part of the polymer project is also * subject to an additional IP rights grant found at * http://polymer.github.io/PATENTS.txt */ (window.litHtmlVersions||(window.litHtmlVersions=[])).push("1.0.0");var H=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new j(e,n,"html",W)},Y=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new C(e,n,"svg",W)},$=133;function Z(e,t){for(var n=e.element.content,r=e.parts,o=document.createTreeWalker(n,$,null,!1),i=X(r),a=r[i],c=-1,u=0,s=[],l=null;o.nextNode();){c++;var f=o.currentNode;for(f.previousSibling===l&&(l=null),t.has(f)&&(s.push(f),null===l&&(l=f)),null!==l&&u++;void 0!==a&&a.index===c;)a.index=null!==l?-1:a.index-u,a=r[i=X(r,i)]}s.forEach(function(e){return e.parentNode.removeChild(e)})}var K=function(e){for(var t=11===e.nodeType?0:1,n=document.createTreeWalker(e,$,null,!1);n.nextNode();)t++;return t},X=function(e){for(var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1)+1;t<e.length;t++){var n=e[t];if(S(n))return t}return-1}; /** * @license * Copyright (c) 2017 The Polymer Project Authors. All rights reserved. * This code may only be used under the BSD style license found at * http://polymer.github.io/LICENSE.txt * The complete set of authors may be found at * http://polymer.github.io/AUTHORS.txt * The complete set of contributors may be found at * http://polymer.github.io/CONTRIBUTORS.txt * Code distributed by Google as part of the polymer project is also * subject to an additional IP rights grant found at * http://polymer.github.io/PATENTS.txt */ var J=function(e,t){return"".concat(e,"--").concat(t)},Q=!0;void 0===window.ShadyCSS?Q=!1:void 0===window.ShadyCSS.prepareTemplateDom&&(console.warn("Incompatible ShadyCSS version detected.Please update to at least @webcomponents/webcomponentsjs@2.0.2 and@webcomponents/shadycss@1.3.1."),Q=!1);var ee=function(e){return function(t){var n=J(t.type,e),r=B.get(n);void 0===r&&(r={stringsArray:new WeakMap,keyString:new Map},B.set(n,r));var o=r.stringsArray.get(t.strings);if(void 0!==o)return o;var i=t.strings.join(g);if(void 0===(o=r.keyString.get(i))){var a=t.getTemplateElement();Q&&window.ShadyCSS.prepareTemplateDom(a,e),o=new O(t,a),r.keyString.set(i,o)}return r.stringsArray.set(t.strings,o),o}},te=["html","svg"],ne=new Set,re=function(e,t,n){ne.add(n);var r=e.querySelectorAll("style");if(0!==r.length){for(var o=document.createElement("style"),i=0;i<r.length;i++){var a=r[i];a.parentNode.removeChild(a),o.textContent+=a.textContent}if(function(e){te.forEach(function(t){var n=B.get(J(t,e));void 0!==n&&n.keyString.forEach(function(e){var t=e.element.content,n=new Set;Array.from(t.querySelectorAll("style")).forEach(function(e){n.add(e)}),Z(e,n)})})}(n),function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=e.element.content,o=e.parts;if(null!=n)for(var i=document.createTreeWalker(r,$,null,!1),a=X(o),c=0,u=-1;i.nextNode();)for(u++,i.currentNode===n&&(c=K(t),n.parentNode.insertBefore(t,n));-1!==a&&o[a].index===u;){if(c>0){for(;-1!==a;)o[a].index+=c,a=X(o,a);return}a=X(o,a)}else r.appendChild(t)}(t,o,t.element.content.firstChild),window.ShadyCSS.prepareTemplateStyles(t.element,n),window.ShadyCSS.nativeShadow){var c=t.element.content.querySelector("style");e.insertBefore(c.cloneNode(!0),e.firstChild)}else{t.element.content.insertBefore(o,t.element.content.firstChild);var u=new Set;u.add(o),Z(t,u)}}else window.ShadyCSS.prepareTemplateStyles(t.element,n)},oe=function(e,t,n){var r=n.scopeName,o=G.has(t),i=t instanceof ShadowRoot&&Q&&e instanceof j,a=i&&!ne.has(r),c=a?document.createDocumentFragment():t;if(q(e,c,Object.assign({templateFactory:ee(r)},n)),a){var u=G.get(c);G.delete(c),u.value instanceof x&&re(c,u.value.template,r),v(t,t.firstChild),t.appendChild(c),G.set(t,u)}!o&&i&&window.ShadyCSS.styleElement(t.host)},ie=n(11),ae=n.n(ie),ce=n(18),ue=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise(function(r,o){(function(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)})(r,o,(t=e[n](t)).done,t.value)})}}},se=f(function(e,t){return function(){var n=Object(ce.a)(ae.a.mark(function n(r){var o,i,a,c,u,s,l,f;return ae.a.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(r instanceof P){n.next=2;break}throw new Error("asyncAppend can only be used in text bindings");case 2:if(e!==r.value){n.next=4;break}return n.abrupt("return");case 4:r.value=e,c=0,n.prev=6,u=ue(e);case 8:return n.next=10,u.next();case 10:if((s=n.sent).done){n.next=26;break}if(l=s.value,r.value===e){n.next=15;break}return n.abrupt("break",26);case 15:0===c&&r.clear(),void 0!==t&&(l=t(l,c)),f=r.startNode,void 0!==a&&(f=E(),a.endNode=f,r.endNode.parentNode.insertBefore(f,r.endNode)),(a=new P(r.options)).insertAfterNode(f),a.setValue(l),a.commit(),c++;case 24:n.next=8;break;case 26:n.next=31;break;case 28:n.prev=28,n.t0=n.catch(6),o={error:n.t0};case 31:if(n.prev=31,n.prev=32,!s||s.done||!(i=u.return)){n.next=36;break}return n.next=36,i.call(u);case 36:if(n.prev=36,!o){n.next=39;break}throw o.error;case 39:return n.finish(36);case 40:return n.finish(31);case 41:case"end":return n.stop()}},n,null,[[6,28,31,41],[32,,36,40]])}));return function(e){return n.apply(this,arguments)}}()}),le=function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise(function(r,o){(function(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)})(r,o,(t=e[n](t)).done,t.value)})}}},fe=f(function(e,t){return function(){var n=Object(ce.a)(ae.a.mark(function n(r){var o,i,a,c,u,s,l;return ae.a.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(r instanceof P){n.next=2;break}throw new Error("asyncReplace can only be used in text bindings");case 2:if(e!==r.value){n.next=4;break}return n.abrupt("return");case 4:a=new P(r.options),r.value=e,c=0,n.prev=7,u=le(e);case 9:return n.next=11,u.next();case 11:if((s=n.sent).done){n.next=23;break}if(l=s.value,r.value===e){n.next=16;break}return n.abrupt("break",23);case 16:0===c&&(r.clear(),a.appendIntoPart(r)),void 0!==t&&(l=t(l,c)),a.setValue(l),a.commit(),c++;case 21:n.next=9;break;case 23:n.next=28;break;case 25:n.prev=25,n.t0=n.catch(7),o={error:n.t0};case 28:if(n.prev=28,n.prev=29,!s||s.done||!(i=u.return)){n.next=33;break}return n.next=33,i.call(u);case 33:if(n.prev=33,!o){n.next=36;break}throw o.error;case 36:return n.finish(33);case 37:return n.finish(28);case 38:case"end":return n.stop()}},n,null,[[7,25,28,38],[29,,33,37]])}));return function(e){return n.apply(this,arguments)}}()}),de=new WeakMap,pe=f(function(e){return function(t){if(!(t instanceof P))throw new Error("cache can only be used in text bindings");var n=de.get(t);void 0===n&&(n=new WeakMap,de.set(t,n));var r=t.value;if(r instanceof x){if(e instanceof j&&r.template===t.options.templateFactory(e))return void t.setValue(e);var o=n.get(r.template);void 0===o&&(o={instance:r,nodes:document.createDocumentFragment()},n.set(r.template,o)),h(o.nodes,t.startNode.nextSibling,t.endNode)}if(e instanceof j){var i=t.options.templateFactory(e),a=n.get(i);void 0!==a&&(t.setValue(a.nodes),t.commit(),t.value=a.instance)}t.setValue(e)}}); /** * @license * Copyright (c) 2018 The Polymer Project Authors. All rights reserved. * This code may only be used under the BSD style license found at * http://polymer.github.io/LICENSE.txt * The complete set of authors may be found at * http://polymer.github.io/AUTHORS.txt * The complete set of contributors may be found at * http://polymer.github.io/CONTRIBUTORS.txt * Code distributed by Google as part of the polymer project is also * subject to an additional IP rights grant found at * http://polymer.github.io/PATENTS.txt */ window.navigator.userAgent.match("Trident")&&(DOMTokenList.prototype.toggle=function(e,t){return void 0===t||t?this.add(e):this.remove(e),void 0===t||t});var he=new WeakMap,ve=new WeakMap,ye=f(function(e){return function(t){if(!(t instanceof N)||t instanceof I||"class"!==t.committer.name||t.committer.parts.length>1)throw new Error("The `classMap` directive must be used in the `class` attribute and must be the only part in the attribute.");ve.has(t)||(t.committer.element.className=t.committer.strings.join(" "),ve.set(t,!0));var n=he.get(t);for(var r in n)r in e||t.committer.element.classList.remove(r);for(var o in e)n&&n[o]===e[o]||t.committer.element.classList.toggle(o,Boolean(e[o]));he.set(t,e)}}),me=new WeakMap,be=f(function(e,t){return function(n){var r=me.get(n);if(Array.isArray(e)){if(Array.isArray(r)&&r.length===e.length&&e.every(function(e,t){return e===r[t]}))return}else if(r===e&&(void 0!==e||me.has(n)))return;n.setValue(t()),me.set(n,Array.isArray(e)?Array.from(e):e)}}),ge=f(function(e){return function(t){if(void 0===e&&t instanceof N){if(e!==t.value){var n=t.committer.name;t.committer.element.removeAttribute(n)}}else t.setValue(e)}}),we=function(e,t){var n=e.startNode.parentNode,r=void 0===t?e.endNode:t.startNode,o=n.insertBefore(E(),r);n.insertBefore(E(),r);var i=new P(e.options);return i.insertAfterNode(o),i},_e=function(e,t){return e.setValue(t),e.commit(),e},Oe=function(e,t,n){var r=e.startNode.parentNode,o=n?n.startNode:e.endNode,i=t.endNode.nextSibling;i!==o&&h(r,t.startNode,i,o)},Se=function(e){v(e.startNode.parentNode,e.startNode,e.endNode.nextSibling)},Ee=function(e,t,n){for(var r=new Map,o=t;o<=n;o++)r.set(e[o],o);return r},ke=new WeakMap,xe=new WeakMap,je=f(function(e,t,n){var r;return void 0===n?n=t:void 0!==t&&(r=t),function(t){if(!(t instanceof P))throw new Error("repeat can only be used in text bindings");var o,i,a=ke.get(t)||[],c=xe.get(t)||[],u=[],s=[],l=[],f=0,d=!0,p=!1,h=void 0;try{for(var v,y=e[Symbol.iterator]();!(d=(v=y.next()).done);d=!0){var m=v.value;l[f]=r?r(m,f):f,s[f]=n(m,f),f++}}catch(e){p=!0,h=e}finally{try{d||null==y.return||y.return()}finally{if(p)throw h}}for(var b=0,g=a.length-1,w=0,_=s.length-1;b<=g&&w<=_;)if(null===a[b])b++;else if(null===a[g])g--;else if(c[b]===l[w])u[w]=_e(a[b],s[w]),b++,w++;else if(c[g]===l[_])u[_]=_e(a[g],s[_]),g--,_--;else if(c[b]===l[_])u[_]=_e(a[b],s[_]),Oe(t,a[b],u[_+1]),b++,_--;else if(c[g]===l[w])u[w]=_e(a[g],s[w]),Oe(t,a[g],a[b]),g--,w++;else if(void 0===o&&(o=Ee(l,w,_),i=Ee(c,b,g)),o.has(c[b]))if(o.has(c[g])){var O=i.get(l[w]),S=void 0!==O?a[O]:null;if(null===S){var E=we(t,a[b]);_e(E,s[w]),u[w]=E}else u[w]=_e(S,s[w]),Oe(t,S,a[b]),a[O]=null;w++}else Se(a[g]),g--;else Se(a[b]),b++;for(;w<=_;){var k=we(t,u[_+1]);_e(k,s[w]),u[w++]=k}for(;b<=g;){var x=a[b++];null!==x&&Se(x)}ke.set(t,u),xe.set(t,l)}}),Ce=new WeakMap,Te=new WeakMap,Ae=f(function(e){return function(t){if(!(t instanceof N)||t instanceof I||"style"!==t.committer.name||t.committer.parts.length>1)throw new Error("The `styleMap` directive must be used in the style attribute and must be the only part in the attribute.");Te.has(t)||(t.committer.element.style.cssText=t.committer.strings.join(" "),Te.set(t,!0));var n=t.committer.element.style,r=Ce.get(t);for(var o in r)o in e||(-1===o.indexOf("-")?n[o]=null:n.removeProperty(o));for(var i in e)-1===i.indexOf("-")?n[i]=e[i]:n.setProperty(i,e[i]);Ce.set(t,e)}}),Ne=new WeakMap,Pe=f(function(e){return function(t){if(!(t instanceof P))throw new Error("unsafeHTML can only be used in text bindings");var n=Ne.get(t);if(void 0===n||!T(e)||e!==n.value||t.value!==n.fragment){var r=document.createElement("template");r.innerHTML=e;var o=document.importNode(r.content,!0);t.setValue(o),Ne.set(t,{value:e,fragment:o})}}}),Re=new WeakMap,Me=f(function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){var n=Re.get(e);void 0===n&&(n={values:[]},Re.set(e,n));var r=n.values;n.values=t;var o=function(o){if(void 0!==n.lastRenderedIndex&&o>n.lastRenderedIndex)return"break";var i=t[o];return T(i)||"function"!=typeof i.then?(e.setValue(i),n.lastRenderedIndex=o,"break"):void 0!==n.lastRenderedIndex&&"function"==typeof i.then&&i===r[o]?"continue":(n.lastRenderedIndex=void 0,void Promise.resolve(i).then(function(t){var r=n.values.indexOf(i);r>-1&&(void 0===n.lastRenderedIndex||r<n.lastRenderedIndex)&&(n.lastRenderedIndex=r,e.setValue(t),e.commit())}))};e:for(var i=0;i<t.length;i++){switch(o(i)){case"break":break e;case"continue":continue}}}});n.d(t,"d",function(){return z}),n.d(t,"r",function(){return W}),n.d(t,"s",function(){return f}),n.d(t,"w",function(){return d}),n.d(t,"C",function(){return v}),n.d(t,"E",function(){return h}),n.d(t,"z",function(){return y}),n.d(t,"A",function(){return m}),n.d(t,"a",function(){return A}),n.d(t,"b",function(){return N}),n.d(t,"c",function(){return R}),n.d(t,"e",function(){return V}),n.d(t,"x",function(){return T}),n.d(t,"f",function(){return P}),n.d(t,"g",function(){return M}),n.d(t,"h",function(){return I}),n.d(t,"B",function(){return G}),n.d(t,"D",function(){return q}),n.d(t,"J",function(){return B}),n.d(t,"K",function(){return U}),n.d(t,"k",function(){return x}),n.d(t,"i",function(){return C}),n.d(t,"l",function(){return j}),n.d(t,"q",function(){return E}),n.d(t,"y",function(){return S}),n.d(t,"j",function(){return O}),n.d(t,"u",function(){return H}),n.d(t,"I",function(){return Y}),n.d(t,"G",function(){return oe}),n.d(t,"m",function(){return se}),n.d(t,"n",function(){return fe}),n.d(t,"o",function(){return pe}),n.d(t,"p",function(){return ye}),n.d(t,"t",function(){return be}),n.d(t,"v",function(){return ge}),n.d(t,"F",function(){return je}),n.d(t,"H",function(){return Ae}),n.d(t,"L",function(){return Pe}),n.d(t,"M",function(){return Me})},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},o=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(o=o.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),o.forEach(function(t){r(e,t,n[t])})}return e}n.d(t,"a",function(){return o})},function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(22);function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Object(r.a)(e,t)}},function(e,t,n){"use strict";function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=[],r=!0,o=!1,i=void 0;try{for(var a,c=e[Symbol.iterator]();!(r=(a=c.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw i}}return n}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}n.d(t,"a",function(){return r})},function(e,t,n){"use strict";var r=n(1);function o(e,t){return!t||"object"!==Object(r.a)(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}n.d(t,"a",function(){return o})},function(e,t,n){"use strict";function r(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}n.d(t,"a",function(){return r})},function(e,t,n){"use strict";function r(e,t,n,r,o,i,a){try{var c=e[i](a),u=c.value}catch(e){return void n(e)}c.done?t(u):Promise.resolve(u).then(r,o)}function o(e){return function(){var t=this,n=arguments;return new Promise(function(o,i){var a=e.apply(t,n);function c(e){r(a,o,i,c,u,"next",e)}function u(e){r(a,o,i,c,u,"throw",e)}c(void 0)})}}n.d(t,"a",function(){return o})},function(e,t,n){"use strict";n.d(t,"b",function(){return o}),n.d(t,"a",function(){return i});var r=new Map;function o(e,t){var n=r.get(e);n||(n=new Map,r.set(e,n));var o=n.get(t);return o||(o=[],n.set(t,o)),o}function i(e){var t=r.get(e);return t||(t=new Map,r.set(e,t)),t}},function(e,t,n){"use strict";n.d(t,"b",function(){return o}),n.d(t,"a",function(){return i});var r=new Map;function o(e,t){var n=r.get(e);n||(n=new Map,r.set(e,n));var o=n.get(t);return o||(o=[],n.set(t,o)),o}function i(e){var t=r.get(e);return t||(t=new Map,r.set(e,t)),t}},function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=new Map;function o(e){var t=r.get(e);return t||(t=new Map,r.set(e,t)),t}},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}n.d(t,"a",function(){return r})},function(e,t,n){"use strict";var r=n(1),o=window.Reflect||{},i=new Map;function a(e,t){var n=e.get(t);return n||(n=new Map,e.set(t,n)),n}function c(e,t){var n=e.get(t);return n||(n=new Map,e.set(t,n)),n}function u(e,t,n,i){return"object"===Object(r.a)(o)&&"function"==typeof o.decorate&&o.decorate!==u&&o.decorate(e,t,n,i),e.reverse().reduce(function(e,r){return r(t,n,e)||e},i)||i}function s(e,t){return"object"===Object(r.a)(o)&&"function"==typeof o.metadata&&o.metadata!==s?o.metadata(e,t):function(n,r){r||(r=""),a(c(i,n),r).set(e,t)}}function l(e,t,n){return"object"===Object(r.a)(o)&&"function"==typeof o.getMetadata&&o.getMetadata!==l?o.getMetadata(e,t,n):a(c(i,t),n).get(e)}window.Reflect?(window.Reflect.decorate||(window.Reflect.decorate=u),window.Reflect.getMetadata||(window.Reflect.getMetadata=l),window.Reflect.metadata||(window.Reflect.metadata=s),window.ReflectPoorlyFill={decorate:u,getMetadata:l,metadata:s}):(window.Reflect={decorate:u,getMetadata:l,metadata:s},window.ReflectPoorlyFill={decorate:u,getMetadata:l,metadata:s});var f=n(10),d=n(8),p=n(7);function h(){return v({reflectAsAttribute:!1,type:void 0})}function v(e){return function(t){var n="symbol"===Object(r.a)(t.key)?Symbol():"__".concat(t.key);return"field"===t.kind?{kind:"method",descriptor:{configurable:!0,enumerable:!1,get:function(){return this[n]},set:function(e){this._propertyState===p.a.UPDATE_PROPERTY?this[n]=e:this.constructor._fromProperty(t.key.toString(),this[t.key.toString()],e,this)}},key:t.key,placement:"own",extras:[{placement:"own",initializer:t.initializer,initialize:t.initialize,key:n,descriptor:{enumerable:!1,configurable:!0,writable:!0},kind:"field"}],finisher:function(n){if(!f.a.isPrototypeOf(n))throw new Error("".concat(n.name," the property must be within a class which extends CustomElement"));e||(e={}),e.type||(e.type=Reflect.getMetadata("design:type",n.prototype,t.key.toString())),Object(d.a)(n).set(t.key,e)}}:{kind:"method",descriptor:{configurable:!0,enumerable:!1,get:function(){return t.descriptor.get.apply(this)},set:function(e){this._propertyState===p.a.UPDATE_PROPERTY?t.descriptor.set.apply(this,[e]):this.constructor._fromProperty(t.key.toString(),this[t.key.toString()],e,this)}},key:t.key,placement:"own",finisher:function(n){if(!f.a.isPrototypeOf(n))throw new Error("".concat(n.name," the property must be within a class which extends CustomElement"));e||(e={}),Object(d.a)(n).set(t.key,e)}}}}var y=n(0);function m(e){return function(t,n,r){if(Object(y.e)(t)){if(e&&!e.type)throw new Error("type not defined for property");return v(e)(t)}return e&&e.type||(e||(e={}),e.type=Reflect.getMetadata("design:type",t,n.toString())),Object(y.a)(t,n,r,v(e))}}function b(){return function(e,t,n){return Object(y.e)(e)?h()(e):Object(y.a)(e,t,n,h())}}n.d(t,"a",function(){return m}),n.d(t,"b",function(){return b})},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){"use strict";n.d(t,"a",function(){return c});var r=n(15),o=n(6),i=n(8),a=n(21);function c(){var e=Object(o.a)(),t={};return e.forEach(function(e){var n=Object(o.b)(e),c={};Array.from(Object(i.a)(e).entries()).forEach(function(e){var t=Object(r.a)(e,2),n=t[0],o=t[1];c[n.toString()]=o});var u=Array.from(Obj