import{l as e,v as t,w as s,b as n,x as r,y as i,G as o,z as l,B as a,H as h,J as c,s as d,M as _,N as u,O as p,Q as m,R as f,U as y,W as b,u as g,P as C,X as S,Y as w,Z as P,_ as v,$ as E,a0 as x,a1 as I,a2 as A}from"./vaadin-grid-7fc2c91c.js";
/**
@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
*/const O=!(window.ShadyDOM&&window.ShadyDOM.inUse);let T,D;function N(e){T=(!e||!e.shimcssproperties)&&(O||Boolean(!navigator.userAgent.match(/AppleWebKit\/601|Edge\/15/)&&window.CSS&&CSS.supports&&CSS.supports("box-shadow","0 0 0 var(--foo)")))}window.ShadyCSS&&void 0!==window.ShadyCSS.cssBuild&&(D=window.ShadyCSS.cssBuild);const M=Boolean(window.ShadyCSS&&window.ShadyCSS.disableRuntime);window.ShadyCSS&&void 0!==window.ShadyCSS.nativeCss?T=window.ShadyCSS.nativeCss:window.ShadyCSS?(N(window.ShadyCSS),window.ShadyCSS=void 0):N(window.WebComponents&&window.WebComponents.flags);const R=T;
/**
@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
*/class k{constructor(){this.start=0,this.end=0,this.previous=null,this.parent=null,this.rules=null,this.parsedCssText="",this.cssText="",this.atRule=!1,this.type=0,this.keyframesName="",this.selector="",this.parsedSelector=""}}function F(e){return H(function(e){let t=new k;t.start=0,t.end=e.length;let s=t;for(let n=0,r=e.length;n<r;n++)if(e[n]===$){s.rules||(s.rules=[]);let e=s,t=e.rules[e.rules.length-1]||null;s=new k,s.start=n+1,s.parent=e,s.previous=t,e.rules.push(s)}else e[n]===j&&(s.end=n+1,s=s.parent||t);return t}(e=e.replace(q.comments,"").replace(q.port,"")),e)}function H(e,t){let s=t.substring(e.start,e.end-1);if(e.parsedCssText=e.cssText=s.trim(),e.parent){let n=e.previous?e.previous.end:e.parent.start;s=t.substring(n,e.start-1),s=function(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,(function(){let e=arguments[1],t=6-e.length;for(;t--;)e="0"+e;return"\\"+e}))}(s),s=s.replace(q.multipleSpaces," "),s=s.substring(s.lastIndexOf(";")+1);let r=e.parsedSelector=e.selector=s.trim();e.atRule=0===r.indexOf(V),e.atRule?0===r.indexOf(U)?e.type=B.MEDIA_RULE:r.match(q.keyframesRule)&&(e.type=B.KEYFRAMES_RULE,e.keyframesName=e.selector.split(q.multipleSpaces).pop()):0===r.indexOf(z)?e.type=B.MIXIN_RULE:e.type=B.STYLE_RULE}let n=e.rules;if(n)for(let e,s=0,r=n.length;s<r&&(e=n[s]);s++)H(e,t);return e}function L(e,t,s=""){let n="";if(e.cssText||e.rules){let s=e.rules;if(s&&!function(e){let t=e[0];return Boolean(t)&&Boolean(t.selector)&&0===t.selector.indexOf(z)}(s))for(let e,r=0,i=s.length;r<i&&(e=s[r]);r++)n=L(e,t,n);else n=t?e.cssText:function(e){return function(e){return e.replace(q.mixinApply,"").replace(q.varApply,"")}(e=function(e){return e.replace(q.customProp,"").replace(q.mixinProp,"")}(e))}(e.cssText),n=n.trim(),n&&(n="  "+n+"\n")}return n&&(e.selector&&(s+=e.selector+" "+$+"\n"),s+=n,e.selector&&(s+=j+"\n\n")),s}const B={STYLE_RULE:1,KEYFRAMES_RULE:7,MEDIA_RULE:4,MIXIN_RULE:1e3},$="{",j="}",q={comments:/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*keyframes/,multipleSpaces:/\s+/g},z="--",U="@media",V="@",J=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gi,Y=/(?:^|\W+)@apply\s*\(?([^);\n]*)\)?/gi,W=/@media\s(.*)/,X=new Set;function K(e){const t=e.textContent;if(!X.has(t)){X.add(t);const e=document.createElement("style");e.setAttribute("shady-unscoped",""),e.textContent=t,document.head.appendChild(e)}}function G(e){return e.hasAttribute("shady-unscoped")}
/**
@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 Q(e,t){return e?("string"==typeof e&&(e=F(e)),t&&ee(e,t),L(e,R)):""}function Z(e){return!e.__cssRules&&e.textContent&&(e.__cssRules=F(e.textContent)),e.__cssRules||null}function ee(e,t,s,n){if(!e)return;let r=!1,i=e.type;if(n&&i===B.MEDIA_RULE){let t=e.selector.match(W);t&&(window.matchMedia(t[1]).matches||(r=!0))}i===B.STYLE_RULE?t(e):s&&i===B.KEYFRAMES_RULE?s(e):i===B.MIXIN_RULE&&(r=!0);let o=e.rules;if(o&&!r)for(let e,r=0,i=o.length;r<i&&(e=o[r]);r++)ee(e,t,s,n)}function te(e,t){let s=e.indexOf("var(");if(-1===s)return t(e,"","","");let n=function(e,t){let s=0;for(let n=t,r=e.length;n<r;n++)if("("===e[n])s++;else if(")"===e[n]&&0==--s)return n;return-1}(e,s+3),r=e.substring(s+4,n),i=e.substring(0,s),o=te(e.substring(n+1),t),l=r.indexOf(",");return-1===l?t(i,r.trim(),"",o):t(i,r.substring(0,l).trim(),r.substring(l+1).trim(),o)}window.ShadyDOM&&window.ShadyDOM.wrap;function se(e){if(void 0!==D)return D;if(void 0===e.__cssBuild){const t=e.getAttribute("css-build");if(t)e.__cssBuild=t;else{const t=function(e){const t="template"===e.localName?e.content.firstChild:e.firstChild;if(t instanceof Comment){const e=t.textContent.trim().split(":");if("css-build"===e[0])return e[1]}return""}(e);""!==t&&function(e){const t="template"===e.localName?e.content.firstChild:e.firstChild;t.parentNode.removeChild(t)}
/**
@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
*/(e),e.__cssBuild=t}}return e.__cssBuild||""}function ne(e){return""!==se(e)}function re(e,t){for(let s in t)null===s?e.style.removeProperty(s):e.style.setProperty(s,t[s])}function ie(e,t){const s=window.getComputedStyle(e).getPropertyValue(t);return s?s.trim():""}
/**
@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
*/
const oe=/;\s*/m,le=/^\s*(initial)|(inherit)\s*$/,ae=/\s*!important/;class he{constructor(){this._map={}}set(e,t){e=e.trim(),this._map[e]={properties:t,dependants:{}}}get(e){return e=e.trim(),this._map[e]||null}}let ce=null;class de{constructor(){this._currentElement=null,this._measureElement=null,this._map=new he}detectMixin(e){return function(e){const t=Y.test(e)||J.test(e);return Y.lastIndex=0,J.lastIndex=0,t}(e)}gatherStyles(e){const t=function(e){const t=[],s=e.querySelectorAll("style");for(let e=0;e<s.length;e++){const n=s[e];G(n)?O||(K(n),n.parentNode.removeChild(n)):(t.push(n.textContent),n.parentNode.removeChild(n))}return t.join("").trim()}(e.content);if(t){const s=document.createElement("style");return s.textContent=t,e.content.insertBefore(s,e.content.firstChild),s}return null}transformTemplate(e,t){void 0===e._gatheredStyle&&(e._gatheredStyle=this.gatherStyles(e));const s=e._gatheredStyle;return s?this.transformStyle(s,t):null}transformStyle(e,t=""){let s=Z(e);return this.transformRules(s,t),e.textContent=Q(s),s}transformCustomStyle(e){let t=Z(e);return ee(t,(e=>{":root"===e.selector&&(e.selector="html"),this.transformRule(e)})),e.textContent=Q(t),t}transformRules(e,t){this._currentElement=t,ee(e,(e=>{this.transformRule(e)})),this._currentElement=null}transformRule(e){e.cssText=this.transformCssText(e.parsedCssText,e),":root"===e.selector&&(e.selector=":host > *")}transformCssText(e,t){return e=e.replace(J,((e,s,n,r)=>this._produceCssProperties(e,s,n,r,t))),this._consumeCssProperties(e,t)}_getInitialValueForProperty(e){return this._measureElement||(this._measureElement=document.createElement("meta"),this._measureElement.setAttribute("apply-shim-measure",""),this._measureElement.style.all="initial",document.head.appendChild(this._measureElement)),window.getComputedStyle(this._measureElement).getPropertyValue(e)}_fallbacksFromPreviousRules(e){let t=e;for(;t.parent;)t=t.parent;const s={};let n=!1;return ee(t,(t=>{n=n||t===e,n||t.selector===e.selector&&Object.assign(s,this._cssTextToMap(t.parsedCssText))})),s}_consumeCssProperties(e,t){let s=null;for(;s=Y.exec(e);){let n=s[0],r=s[1],i=s.index,o=i+n.indexOf("@apply"),l=i+n.length,a=e.slice(0,o),h=e.slice(l),c=t?this._fallbacksFromPreviousRules(t):{};Object.assign(c,this._cssTextToMap(a));let d=this._atApplyToCssProperties(r,c);e=`${a}${d}${h}`,Y.lastIndex=i+d.length}return e}_atApplyToCssProperties(e,t){e=e.replace(oe,"");let s=[],n=this._map.get(e);if(n||(this._map.set(e,{}),n=this._map.get(e)),n){let r,i,o;this._currentElement&&(n.dependants[this._currentElement]=!0);const l=n.properties;for(r in l)o=t&&t[r],i=[r,": var(",e,"_-_",r],o&&i.push(",",o.replace(ae,"")),i.push(")"),ae.test(l[r])&&i.push(" !important"),s.push(i.join(""))}return s.join("; ")}_replaceInitialOrInherit(e,t){let s=le.exec(t);return s&&(t=s[1]?this._getInitialValueForProperty(e):"apply-shim-inherit"),t}_cssTextToMap(e,t=!1){let s,n,r=e.split(";"),i={};for(let e,o,l=0;l<r.length;l++)e=r[l],e&&(o=e.split(":"),o.length>1&&(s=o[0].trim(),n=o.slice(1).join(":"),t&&(n=this._replaceInitialOrInherit(s,n)),i[s]=n));return i}_invalidateMixinEntry(e){if(ce)for(let t in e.dependants)t!==this._currentElement&&ce(t)}_produceCssProperties(e,t,s,n,r){if(s&&te(s,((e,t)=>{t&&this._map.get(t)&&(n=`@apply ${t};`)})),!n)return e;let i=this._consumeCssProperties(""+n,r),o=e.slice(0,e.indexOf("--")),l=this._cssTextToMap(i,!0),a=l,h=this._map.get(t),c=h&&h.properties;c?a=Object.assign(Object.create(c),l):this._map.set(t,a);let d,_,u=[],p=!1;for(d in a)_=l[d],void 0===_&&(_="initial"),c&&!(d in c)&&(p=!0),u.push(`${t}_-_${d}: ${_}`);return p&&this._invalidateMixinEntry(h),h&&(h.properties=a),s&&(o=`${e};${o}`),`${o}${u.join("; ")};`}}de.prototype.detectMixin=de.prototype.detectMixin,de.prototype.transformStyle=de.prototype.transformStyle,de.prototype.transformCustomStyle=de.prototype.transformCustomStyle,de.prototype.transformRules=de.prototype.transformRules,de.prototype.transformRule=de.prototype.transformRule,de.prototype.transformTemplate=de.prototype.transformTemplate,de.prototype._separator="_-_",Object.defineProperty(de.prototype,"invalidCallback",{get:()=>ce,set(e){ce=e}});
/**
@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
*/
const _e={},ue="_applyShimCurrentVersion",pe="_applyShimNextVersion",me="_applyShimValidatingVersion",fe=Promise.resolve();
/**
@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 ye(e){let t=_e[e];t&&function(e){e[ue]=e[ue]||0,e[me]=e[me]||0,e[pe]=(e[pe]||0)+1}(t)}function be(e){return e[ue]===e[pe]}
/**
@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
*/
let ge,Ce=null,Se=window.HTMLImports&&window.HTMLImports.whenReady||null;function we(e){requestAnimationFrame((function(){Se?Se(e):(Ce||(Ce=new Promise((e=>{ge=e})),"complete"===document.readyState?ge():document.addEventListener("readystatechange",(()=>{"complete"===document.readyState&&ge()}))),Ce.then((function(){e&&e()})))}))}
/**
@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
*/const Pe="__shadyCSSCachedStyle";let ve=null,Ee=null;class xe{constructor(){this.customStyles=[],this.enqueued=!1,we((()=>{window.ShadyCSS.flushCustomStyles&&window.ShadyCSS.flushCustomStyles()}))}enqueueDocumentValidation(){!this.enqueued&&Ee&&(this.enqueued=!0,we(Ee))}addCustomStyle(e){e.__seenByShadyCSS||(e.__seenByShadyCSS=!0,this.customStyles.push(e),this.enqueueDocumentValidation())}getStyleForCustomStyle(e){if(e[Pe])return e[Pe];let t;return t=e.getStyle?e.getStyle():e,t}processStyles(){const e=this.customStyles;for(let t=0;t<e.length;t++){const s=e[t];if(s[Pe])continue;const n=this.getStyleForCustomStyle(s);if(n){const e=n.__appliedElement||n;ve&&ve(e),s[Pe]=e}}return e}}xe.prototype.addCustomStyle=xe.prototype.addCustomStyle,xe.prototype.getStyleForCustomStyle=xe.prototype.getStyleForCustomStyle,xe.prototype.processStyles=xe.prototype.processStyles,Object.defineProperties(xe.prototype,{transformCallback:{get:()=>ve,set(e){ve=e}},validateCallback:{get:()=>Ee,set(e){let t=!1;Ee||(t=!0),Ee=e,t&&this.enqueueDocumentValidation()}}});
/**
@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
*/
const Ie=new de;class Ae{constructor(){this.customStyleInterface=null,Ie.invalidCallback=ye}ensure(){this.customStyleInterface||window.ShadyCSS.CustomStyleInterface&&(this.customStyleInterface=window.ShadyCSS.CustomStyleInterface,this.customStyleInterface.transformCallback=e=>{Ie.transformCustomStyle(e)},this.customStyleInterface.validateCallback=()=>{requestAnimationFrame((()=>{this.customStyleInterface.enqueued&&this.flushCustomStyles()}))})}prepareTemplate(e,t){if(this.ensure(),ne(e))return;_e[t]=e;let s=Ie.transformTemplate(e,t);e._styleAst=s}flushCustomStyles(){if(this.ensure(),!this.customStyleInterface)return;let e=this.customStyleInterface.processStyles();if(this.customStyleInterface.enqueued){for(let t=0;t<e.length;t++){let s=e[t],n=this.customStyleInterface.getStyleForCustomStyle(s);n&&Ie.transformCustomStyle(n)}this.customStyleInterface.enqueued=!1}}styleSubtree(e,t){if(this.ensure(),t&&re(e,t),e.shadowRoot){this.styleElement(e);let t=e.shadowRoot.children||e.shadowRoot.childNodes;for(let e=0;e<t.length;e++)this.styleSubtree(t[e])}else{let t=e.children||e.childNodes;for(let e=0;e<t.length;e++)this.styleSubtree(t[e])}}styleElement(e){this.ensure();let{is:t}=function(e){let t=e.localName,s="",n="";return t?t.indexOf("-")>-1?s=t:(n=t,s=e.getAttribute&&e.getAttribute("is")||""):(s=e.is,n=e.extends),{is:s,typeExtension:n}}(e),s=_e[t];if((!s||!ne(s))&&s&&!be(s)){(function(e){return!be(e)&&e[me]===e[pe]})(s)||(this.prepareTemplate(s,t),function(e){e[me]=e[pe],e._validating||(e._validating=!0,fe.then((function(){e[ue]=e[pe],e._validating=!1})))}(s));let n=e.shadowRoot;if(n){let e=n.querySelector("style");e&&(e.__cssRules=s._styleAst,e.textContent=Q(s._styleAst))}}}styleDocument(e){this.ensure(),this.styleSubtree(document.body,e)}}if(!window.ShadyCSS||!window.ShadyCSS.ScopingShim){const e=new Ae;let t=window.ShadyCSS&&window.ShadyCSS.CustomStyleInterface;window.ShadyCSS={prepareTemplate(t,s,n){e.flushCustomStyles(),e.prepareTemplate(t,s)},prepareTemplateStyles(e,t,s){window.ShadyCSS.prepareTemplate(e,t,s)},prepareTemplateDom(e,t){},styleSubtree(t,s){e.flushCustomStyles(),e.styleSubtree(t,s)},styleElement(t){e.flushCustomStyles(),e.styleElement(t)},styleDocument(t){e.flushCustomStyles(),e.styleDocument(t)},getComputedStyleValue:(e,t)=>ie(e,t),flushCustomStyles(){e.flushCustomStyles()},nativeCss:R,nativeShadow:O,cssBuild:D,disableRuntime:M},t&&(window.ShadyCSS.CustomStyleInterface=t)}window.ShadyCSS.ApplyShim=Ie;
/**
 * @fileoverview
 * @suppress {checkPrototypalTypes}
 * @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
 */
const Oe=/:host\(:dir\((ltr|rtl)\)\)/g,Te=/([\s\w-#\.\[\]\*]*):dir\((ltr|rtl)\)/g,De=/:dir\((?:ltr|rtl)\)/,Ne=Boolean(window.ShadyDOM&&window.ShadyDOM.inUse),Me=[];let Re=null,ke="";function Fe(){ke=document.documentElement.getAttribute("dir")}function He(e){if(!e.__autoDirOptOut){e.setAttribute("dir",ke)}}function Le(){Fe(),ke=document.documentElement.getAttribute("dir");for(let e=0;e<Me.length;e++)He(Me[e])}const Be=e((e=>{Ne||Re||(Fe(),Re=new MutationObserver(Le),Re.observe(document.documentElement,{attributes:!0,attributeFilter:["dir"]}));const s=t(e);class n extends s{static _processStyleText(e,t){return e=s._processStyleText.call(this,e,t),!Ne&&De.test(e)&&(e=this._replaceDirInCssText(e),this.__activateDir=!0),e}static _replaceDirInCssText(e){let t=e;return t=t.replace(Oe,':host([dir="$1"])'),t=t.replace(Te,':host([dir="$2"]) $1'),t}constructor(){super(),this.__autoDirOptOut=!1}ready(){super.ready(),this.__autoDirOptOut=this.hasAttribute("dir")}connectedCallback(){s.prototype.connectedCallback&&super.connectedCallback(),this.constructor.__activateDir&&(Re&&Re.takeRecords().length&&Le(),Me.push(this),He(this))}disconnectedCallback(){if(s.prototype.disconnectedCallback&&super.disconnectedCallback(),this.constructor.__activateDir){const e=Me.indexOf(this);e>-1&&Me.splice(e,1)}}}return n.__activateDir=!1,n}));
/**
@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 $e(){document.body.removeAttribute("unresolved")}"interactive"===document.readyState||"complete"===document.readyState?$e():window.addEventListener("DOMContentLoaded",$e)
/**
@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
*/;const je=function(){let e,t;do{e=window.ShadyDOM&&ShadyDOM.flush(),window.ShadyCSS&&window.ShadyCSS.ScopingShim&&window.ShadyCSS.ScopingShim.flush(),t=s()}while(e||t)},qe=Element.prototype,ze=qe.matches||qe.matchesSelector||qe.mozMatchesSelector||qe.msMatchesSelector||qe.oMatchesSelector||qe.webkitMatchesSelector,Ue=function(e,t){return ze.call(e,t)};
/**
@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
*/class Ve{constructor(e){window.ShadyDOM&&window.ShadyDOM.inUse&&window.ShadyDOM.patch(e),this.node=e}observeNodes(e){return new n(this.node,e)}unobserveNodes(e){e.disconnect()}notifyObserver(){}deepContains(e){if(r(this.node).contains(e))return!0;let t=e,s=e.ownerDocument;for(;t&&t!==s&&t!==this.node;)t=r(t).parentNode||r(t).host;return t===this.node}getOwnerRoot(){return r(this.node).getRootNode()}getDistributedNodes(){return"slot"===this.node.localName?r(this.node).assignedNodes({flatten:!0}):[]}getDestinationInsertionPoints(){let e=[],t=r(this.node).assignedSlot;for(;t;)e.push(t),t=r(t).assignedSlot;return e}importNode(e,t){let s=this.node instanceof Document?this.node:this.node.ownerDocument;return r(s).importNode(e,t)}getEffectiveChildNodes(){return n.getFlattenedNodes(this.node)}queryDistributedElements(e){let t=this.getEffectiveChildNodes(),s=[];for(let n,r=0,i=t.length;r<i&&(n=t[r]);r++)n.nodeType===Node.ELEMENT_NODE&&Ue(n,e)&&s.push(n);return s}get activeElement(){let e=this.node;return void 0!==e._activeElement?e._activeElement:e.activeElement}}function Je(e,t){for(let s=0;s<t.length;s++){let n=t[s];Object.defineProperty(e,n,{get:function(){return this.node[n]},configurable:!0})}}class Ye{constructor(e){this.event=e}get rootTarget(){return this.path[0]}get localTarget(){return this.event.target}get path(){return this.event.composedPath()}}Ve.prototype.cloneNode,Ve.prototype.appendChild,Ve.prototype.insertBefore,Ve.prototype.removeChild,Ve.prototype.replaceChild,Ve.prototype.setAttribute,Ve.prototype.removeAttribute,Ve.prototype.querySelector,Ve.prototype.querySelectorAll,Ve.prototype.parentNode,Ve.prototype.firstChild,Ve.prototype.lastChild,Ve.prototype.nextSibling,Ve.prototype.previousSibling,Ve.prototype.firstElementChild,Ve.prototype.lastElementChild,Ve.prototype.nextElementSibling,Ve.prototype.previousElementSibling,Ve.prototype.childNodes,Ve.prototype.children,Ve.prototype.classList,Ve.prototype.textContent,Ve.prototype.innerHTML;let We=Ve;if(window.ShadyDOM&&window.ShadyDOM.inUse&&window.ShadyDOM.noPatch&&window.ShadyDOM.Wrapper){class e extends window.ShadyDOM.Wrapper{}Object.getOwnPropertyNames(Ve.prototype).forEach((t=>{"activeElement"!=t&&(e.prototype[t]=Ve.prototype[t])})),Je(e.prototype,["classList"]),We=e,Object.defineProperties(Ye.prototype,{localTarget:{get(){const e=this.event.currentTarget,t=e&&Xe(e).getOwnerRoot(),s=this.path;for(let e=0;e<s.length;e++){const n=s[e];if(Xe(n).getOwnerRoot()===t)return n}},configurable:!0},path:{get(){return window.ShadyDOM.composedPath(this.event)},configurable:!0}})}else!function(e,t){for(let s=0;s<t.length;s++){let n=t[s];e[n]=function(){return this.node[n].apply(this.node,arguments)}}}(Ve.prototype,["cloneNode","appendChild","insertBefore","removeChild","replaceChild","setAttribute","removeAttribute","querySelector","querySelectorAll"]),Je(Ve.prototype,["parentNode","firstChild","lastChild","nextSibling","previousSibling","firstElementChild","lastElementChild","nextElementSibling","previousElementSibling","childNodes","children","classList"]),function(e,t){for(let s=0;s<t.length;s++){let n=t[s];Object.defineProperty(e,n,{get:function(){return this.node[n]},set:function(e){this.node[n]=e},configurable:!0})}}(Ve.prototype,["textContent","innerHTML","className"]);const Xe=function(e){if((e=e||document)instanceof We)return e;if(e instanceof Ye)return e;let t=e.__domApi;return t||(t=e instanceof Event?new Ye(e):new We(e),e.__domApi=t),t},Ke=window.ShadyDOM,Ge=window.ShadyCSS;
/**
@license
Copyright (c) 2019 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 Qe(e,t){return r(e).getRootNode()===t}
/**
 * @fileoverview
 * @suppress {checkPrototypalTypes}
 * @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
 */
const Ze=e=>{for(;e;){const t=Object.getOwnPropertyDescriptor(e,"observedAttributes");if(t)return t.get;e=Object.getPrototypeOf(e.prototype).constructor}return()=>[]},et=e((e=>{const t=i(e);let s=Ze(t);return class extends t{constructor(){super(),this.__isUpgradeDisabled}static get observedAttributes(){return s.call(this).concat("disable-upgrade")}_initializeProperties(){this.hasAttribute("disable-upgrade")?this.__isUpgradeDisabled=!0:super._initializeProperties()}_enableProperties(){this.__isUpgradeDisabled||super._enableProperties()}_canApplyPropertyDefault(e){return super._canApplyPropertyDefault(e)&&!(this.__isUpgradeDisabled&&this._isPropertyPending(e))}attributeChangedCallback(e,t,s,n){"disable-upgrade"==e?this.__isUpgradeDisabled&&null==s&&(super._initializeProperties(),this.__isUpgradeDisabled=!1,r(this).isConnected&&super.connectedCallback()):super.attributeChangedCallback(e,t,s,n)}connectedCallback(){this.__isUpgradeDisabled||super.connectedCallback()}disconnectedCallback(){this.__isUpgradeDisabled||super.disconnectedCallback()}}}));let tt=window.ShadyCSS;const st=e((e=>{const t=o(i(e)),s=l?t:Be(t),n=Ze(s),f={x:"pan-x",y:"pan-y",none:"none",all:"auto"};class y extends s{constructor(){super(),this.isAttached,this.__boundListeners,this._debouncers,this.__isUpgradeDisabled,this.__needsAttributesAtConnected,this._legacyForceObservedAttributes}static get importMeta(){return this.prototype.importMeta}created(){}__attributeReaction(e,t,s){(this.__dataAttributes&&this.__dataAttributes[e]||"disable-upgrade"===e)&&this.attributeChangedCallback(e,t,s,null)}setAttribute(e,t){if(a&&!this._legacyForceObservedAttributes){const s=this.getAttribute(e);super.setAttribute(e,t),this.__attributeReaction(e,s,String(t))}else super.setAttribute(e,t)}removeAttribute(e){if(a&&!this._legacyForceObservedAttributes){const t=this.getAttribute(e);super.removeAttribute(e),this.__attributeReaction(e,t,null)}else super.removeAttribute(e)}static get observedAttributes(){return a&&!this.prototype._legacyForceObservedAttributes?(this.hasOwnProperty(JSCompiler_renameProperty("__observedAttributes",this))||(this.__observedAttributes=[],h(this.prototype)),this.__observedAttributes):n.call(this).concat("disable-upgrade")}_enableProperties(){this.__isUpgradeDisabled||super._enableProperties()}_canApplyPropertyDefault(e){return super._canApplyPropertyDefault(e)&&!(this.__isUpgradeDisabled&&this._isPropertyPending(e))}connectedCallback(){this.__needsAttributesAtConnected&&this._takeAttributes(),this.__isUpgradeDisabled||(super.connectedCallback(),this.isAttached=!0,this.attached())}attached(){}disconnectedCallback(){this.__isUpgradeDisabled||(super.disconnectedCallback(),this.isAttached=!1,this.detached())}detached(){}attributeChangedCallback(e,t,s,n){t!==s&&("disable-upgrade"==e?this.__isUpgradeDisabled&&null==s&&(this._initializeProperties(),this.__isUpgradeDisabled=!1,r(this).isConnected&&this.connectedCallback()):(super.attributeChangedCallback(e,t,s,n),this.attributeChanged(e,t,s)))}attributeChanged(e,t,s){}_initializeProperties(){if(c&&this.hasAttribute("disable-upgrade"))this.__isUpgradeDisabled=!0;else{let e=Object.getPrototypeOf(this);e.hasOwnProperty(JSCompiler_renameProperty("__hasRegisterFinished",e))||(this._registered(),e.__hasRegisterFinished=!0),super._initializeProperties(),this.root=this,this.created(),a&&!this._legacyForceObservedAttributes&&(this.hasAttributes()?this._takeAttributes():this.parentNode||(this.__needsAttributesAtConnected=!0)),this._applyListeners()}}_takeAttributes(){const e=this.attributes;for(let t=0,s=e.length;t<s;t++){const s=e[t];this.__attributeReaction(s.name,null,s.value)}}_registered(){}ready(){this._ensureAttributes(),super.ready()}_ensureAttributes(){}_applyListeners(){}serialize(e){return this._serializeValue(e)}deserialize(e,t){return this._deserializeValue(e,t)}reflectPropertyToAttribute(e,t,s){this._propertyToAttribute(e,t,s)}serializeValueToAttribute(e,t,s){this._valueToNodeAttribute(s||this,e,t)}extend(e,t){if(!e||!t)return e||t;let s=Object.getOwnPropertyNames(t);for(let n,r=0;r<s.length&&(n=s[r]);r++){let s=Object.getOwnPropertyDescriptor(t,n);s&&Object.defineProperty(e,n,s)}return e}mixin(e,t){for(let s in t)e[s]=t[s];return e}chainObject(e,t){return e&&t&&e!==t&&(e.__proto__=t),e}instanceTemplate(e){let t=this.constructor._contentForTemplate(e);return document.importNode(t,!0)}fire(e,t,s){s=s||{},t=null==t?{}:t;let n=new Event(e,{bubbles:void 0===s.bubbles||s.bubbles,cancelable:Boolean(s.cancelable),composed:void 0===s.composed||s.composed});n.detail=t;let i=s.node||this;return r(i).dispatchEvent(n),n}listen(e,t,s){e=e||this;let n=this.__boundListeners||(this.__boundListeners=new WeakMap),r=n.get(e);r||(r={},n.set(e,r));let i=t+s;r[i]||(r[i]=this._addMethodEventListenerToNode(e,t,s,this))}unlisten(e,t,s){e=e||this;let n=this.__boundListeners&&this.__boundListeners.get(e),r=t+s,i=n&&n[r];i&&(this._removeEventListenerFromNode(e,t,i),n[r]=null)}setScrollDirection(e,t){d(t||this,f[e]||"auto")}$$(e){return this.root.querySelector(e)}get domHost(){let e=r(this).getRootNode();return e instanceof DocumentFragment?e.host:e}distributeContent(){const e=Xe(this);window.ShadyDOM&&e.shadowRoot&&ShadyDOM.flush()}getEffectiveChildNodes(){return Xe(this).getEffectiveChildNodes()}queryDistributedElements(e){return Xe(this).queryDistributedElements(e)}getEffectiveChildren(){return this.getEffectiveChildNodes().filter((function(e){return e.nodeType===Node.ELEMENT_NODE}))}getEffectiveTextContent(){let e=this.getEffectiveChildNodes(),t=[];for(let s,n=0;s=e[n];n++)s.nodeType!==Node.COMMENT_NODE&&t.push(s.textContent);return t.join("")}queryEffectiveChildren(e){let t=this.queryDistributedElements(e);return t&&t[0]}queryAllEffectiveChildren(e){return this.queryDistributedElements(e)}getContentChildNodes(e){let t=this.root.querySelector(e||"slot");return t?Xe(t).getDistributedNodes():[]}getContentChildren(e){return this.getContentChildNodes(e).filter((function(e){return e.nodeType===Node.ELEMENT_NODE}))}isLightDescendant(e){const t=this;return t!==e&&r(t).contains(e)&&r(t).getRootNode()===r(e).getRootNode()}isLocalDescendant(e){return this.root===r(e).getRootNode()}scopeSubtree(e,t=!1){return function(e,t=!1){if(!Ke||!Ge)return null;if(!Ke.handlesDynamicScoping)return null;const s=Ge.ScopingShim;if(!s)return null;const n=s.scopeForNode(e),i=r(e).getRootNode(),o=e=>{if(!Qe(e,i))return;const t=Array.from(Ke.nativeMethods.querySelectorAll.call(e,"*"));t.push(e);for(let e=0;e<t.length;e++){const r=t[e];if(!Qe(r,i))continue;const o=s.currentScopeForNode(r);o!==n&&(""!==o&&s.unscopeNode(r,o),s.scopeNode(r,n))}};if(o(e),t){const t=new MutationObserver((e=>{for(let t=0;t<e.length;t++){const s=e[t];for(let e=0;e<s.addedNodes.length;e++){const t=s.addedNodes[e];t.nodeType===Node.ELEMENT_NODE&&o(t)}}}));return t.observe(e,{childList:!0,subtree:!0}),t}return null}(e,t)}getComputedStyleValue(e){return tt.getComputedStyleValue(this,e)}debounce(e,t,s){return this._debouncers=this._debouncers||{},this._debouncers[e]=_.debounce(this._debouncers[e],s>0?u.after(s):p,t.bind(this))}isDebouncerActive(e){this._debouncers=this._debouncers||{};let t=this._debouncers[e];return!(!t||!t.isActive())}flushDebouncer(e){this._debouncers=this._debouncers||{};let t=this._debouncers[e];t&&t.flush()}cancelDebouncer(e){this._debouncers=this._debouncers||{};let t=this._debouncers[e];t&&t.cancel()}async(e,t){return t>0?u.run(e.bind(this),t):~p.run(e.bind(this))}cancelAsync(e){e<0?p.cancel(~e):u.cancel(e)}create(e,t){let s=document.createElement(e);if(t)if(s.setProperties)s.setProperties(t);else for(let e in t)s[e]=t[e];return s}elementMatches(e,t){return Ue(t||this,e)}toggleAttribute(e,t){let s=this;return 3===arguments.length&&(s=arguments[2]),1==arguments.length&&(t=!s.hasAttribute(e)),t?(r(s).setAttribute(e,""),!0):(r(s).removeAttribute(e),!1)}toggleClass(e,t,s){s=s||this,1==arguments.length&&(t=!s.classList.contains(e)),t?s.classList.add(e):s.classList.remove(e)}transform(e,t){(t=t||this).style.webkitTransform=e,t.style.transform=e}translate3d(e,t,s,n){n=n||this,this.transform("translate3d("+e+","+t+","+s+")",n)}arrayDelete(e,t){let s;if(Array.isArray(e)){if(s=e.indexOf(t),s>=0)return e.splice(s,1)}else{if(s=m(this,e).indexOf(t),s>=0)return this.splice(e,s,1)}return null}_logger(e,t){switch(Array.isArray(t)&&1===t.length&&Array.isArray(t[0])&&(t=t[0]),e){case"log":case"warn":case"error":console[e](...t)}}_log(...e){this._logger("log",e)}_warn(...e){this._logger("warn",e)}_error(...e){this._logger("error",e)}_logf(e,...t){return["[%s::%s]",this.is,e,...t]}}return y.prototype.is="",y})),nt={attached:!0,detached:!0,ready:!0,created:!0,beforeRegister:!0,registered:!0,attributeChanged:!0,listeners:!0,hostAttributes:!0},rt={attached:!0,detached:!0,ready:!0,created:!0,beforeRegister:!0,registered:!0,attributeChanged:!0,behaviors:!0,_noAccessors:!0},it=Object.assign({listeners:!0,hostAttributes:!0,properties:!0,observers:!0},rt);
/**
@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 ot(e,t){return dt({},st(t),e)}function lt(e,t,s,n){!function(e,t,s){const n=e._noAccessors,r=Object.getOwnPropertyNames(e);for(let i=0;i<r.length;i++){let o=r[i];if(!(o in s))if(n)t[o]=e[o];else{let s=Object.getOwnPropertyDescriptor(e,o);s&&(s.configurable=!0,Object.defineProperty(t,o,s))}}}(t,e,n);for(let e in nt)t[e]&&(s[e]=s[e]||[],s[e].push(t[e]))}function at(e,t,s){t=t||[];for(let n=e.length-1;n>=0;n--){let r=e[n];r?Array.isArray(r)?at(r,t):t.indexOf(r)<0&&(!s||s.indexOf(r)<0)&&t.unshift(r):console.warn("behavior is null, check for missing or 404 import")}return t}function ht(e,t){for(const s in t){const n=e[s],r=t[s];e[s]=!("value"in r)&&n&&"value"in n?Object.assign({value:n.value},r):r}}const ct=st(HTMLElement);function dt(e,t,s){let n;const r={};class i extends t{static _finalizeClass(){if(this.hasOwnProperty(JSCompiler_renameProperty("generatedFrom",this))){if(n)for(let e,t=0;t<n.length;t++)e=n[t],e.properties&&this.createProperties(e.properties),e.observers&&this.createObservers(e.observers,e.properties);e.properties&&this.createProperties(e.properties),e.observers&&this.createObservers(e.observers,e.properties),this._prepareTemplate()}else t._finalizeClass.call(this)}static get properties(){const t={};if(n)for(let e=0;e<n.length;e++)ht(t,n[e].properties);return ht(t,e.properties),t}static get observers(){let t=[];if(n)for(let e,s=0;s<n.length;s++)e=n[s],e.observers&&(t=t.concat(e.observers));return e.observers&&(t=t.concat(e.observers)),t}created(){super.created();const e=r.created;if(e)for(let t=0;t<e.length;t++)e[t].call(this)}_registered(){const e=i.prototype;if(!e.hasOwnProperty(JSCompiler_renameProperty("__hasRegisterFinished",e))){e.__hasRegisterFinished=!0,super._registered(),c&&o(e);const t=Object.getPrototypeOf(this);let s=r.beforeRegister;if(s)for(let e=0;e<s.length;e++)s[e].call(t);if(s=r.registered,s)for(let e=0;e<s.length;e++)s[e].call(t)}}_applyListeners(){super._applyListeners();const e=r.listeners;if(e)for(let t=0;t<e.length;t++){const s=e[t];if(s)for(let e in s)this._addMethodEventListenerToNode(this,e,s[e])}}_ensureAttributes(){const e=r.hostAttributes;if(e)for(let t=e.length-1;t>=0;t--){const s=e[t];for(let e in s)this._ensureAttribute(e,s[e])}super._ensureAttributes()}ready(){super.ready();let e=r.ready;if(e)for(let t=0;t<e.length;t++)e[t].call(this)}attached(){super.attached();let e=r.attached;if(e)for(let t=0;t<e.length;t++)e[t].call(this)}detached(){super.detached();let e=r.detached;if(e)for(let t=0;t<e.length;t++)e[t].call(this)}attributeChanged(e,t,s){super.attributeChanged();let n=r.attributeChanged;if(n)for(let r=0;r<n.length;r++)n[r].call(this,e,t,s)}}if(s){Array.isArray(s)||(s=[s]);let e=t.prototype.behaviors;n=at(s,null,e),i.prototype.behaviors=e?e.concat(s):n}const o=t=>{n&&function(e,t,s){for(let n=0;n<t.length;n++)lt(e,t[n],s,it)}(t,n,r),lt(t,e,r,rt)};return c||o(i.prototype),i.generatedFrom=e,i}const _t=function(e){let t;return t="function"==typeof e?e:_t.Class(e),e._legacyForceObservedAttributes&&(t.prototype._legacyForceObservedAttributes=e._legacyForceObservedAttributes),customElements.define(t.is,t),t};
/**
@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
*/
function ut(e,t,s,n,r){let i;r&&(i="object"==typeof s&&null!==s,i&&(n=e.__dataTemp[t]));let o=n!==s&&(n==n||s==s);return i&&o&&(e.__dataTemp[t]=s),o}_t.Class=function(e,t){e||console.warn("Polymer.Class requires `info` argument");let s=t?t(ct):ct;return s=dt(e,s,e.behaviors),s.is=s.prototype.is=e.is,s};const pt=e((e=>class extends e{_shouldPropertyChange(e,t,s){return ut(this,e,t,s,!0)}})),mt=e((e=>class extends e{static get properties(){return{mutableData:Boolean}}_shouldPropertyChange(e,t,s){return ut(this,e,t,s,this.mutableData)}}));pt._mutablePropertyChange=ut;
/**
@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
*/
let ft=null;function yt(){return ft}yt.prototype=Object.create(HTMLTemplateElement.prototype,{constructor:{value:yt,writable:!0}});const bt=f(yt),gt=pt(bt);const Ct=f(class{});function St(e,t){for(let s=0;s<t.length;s++){let n=t[s];if(Boolean(e)!=Boolean(n.__hideTemplateChildren__))if(n.nodeType===Node.TEXT_NODE)e?(n.__polymerTextContent__=n.textContent,n.textContent=""):n.textContent=n.__polymerTextContent__;else if("slot"===n.localName)if(e)n.__polymerReplaced__=document.createComment("hidden-slot"),r(r(n).parentNode).replaceChild(n.__polymerReplaced__,n);else{const e=n.__polymerReplaced__;e&&r(r(e).parentNode).replaceChild(n,e)}else n.style&&(e?(n.__polymerDisplay__=n.style.display,n.style.display="none"):n.style.display=n.__polymerDisplay__);n.__hideTemplateChildren__=e,n._showHideChildren&&n._showHideChildren(e)}}class wt extends Ct{constructor(e){super(),this._configureProperties(e),this.root=this._stampTemplate(this.__dataHost);let t=[];this.children=t;for(let e=this.root.firstChild;e;e=e.nextSibling)t.push(e),e.__templatizeInstance=this;this.__templatizeOwner&&this.__templatizeOwner.__hideTemplateChildren__&&this._showHideChildren(!0);let s=this.__templatizeOptions;(e&&s.instanceProps||!s.instanceProps)&&this._enableProperties()}_configureProperties(e){if(this.__templatizeOptions.forwardHostProp)for(let e in this.__hostProps)this._setPendingProperty(e,this.__dataHost["_host_"+e]);for(let t in e)this._setPendingProperty(t,e[t])}forwardHostProp(e,t){this._setPendingPropertyOrPath(e,t,!1,!0)&&this.__dataHost._enqueueClient(this)}_addEventListenerToNode(e,t,s){if(this._methodHost&&this.__templatizeOptions.parentModel)this._methodHost._addEventListenerToNode(e,t,(e=>{e.model=this,s(e)}));else{let n=this.__dataHost.__dataHost;n&&n._addEventListenerToNode(e,t,s)}}_showHideChildren(e){St(e,this.children)}_setUnmanagedPropertyToNode(e,t,s){e.__hideTemplateChildren__&&e.nodeType==Node.TEXT_NODE&&"textContent"==t?e.__polymerTextContent__=s:super._setUnmanagedPropertyToNode(e,t,s)}get parentModel(){let e=this.__parentModel;if(!e){let t;e=this;do{e=e.__dataHost.__dataHost}while((t=e.__templatizeOptions)&&!t.parentModel);this.__parentModel=e}return e}dispatchEvent(e){return!0}}wt.prototype.__dataHost,wt.prototype.__templatizeOptions,wt.prototype._methodHost,wt.prototype.__templatizeOwner,wt.prototype.__hostProps;const Pt=pt(wt);function vt(e){let t=e.__dataHost;return t&&t._methodHost||t}function Et(e,t,s){let n=s.mutableData?Pt:wt;Ot.mixin&&(n=Ot.mixin(n));let r=class extends n{};return r.prototype.__templatizeOptions=s,r.prototype._bindTemplate(e),function(e,t,s,n){let r=s.hostProps||{};for(let t in n.instanceProps){delete r[t];let s=n.notifyInstanceProp;s&&e.prototype._addPropertyEffect(t,e.prototype.PROPERTY_EFFECT_TYPES.NOTIFY,{fn:At(t,s)})}if(n.forwardHostProp&&t.__dataHost)for(let t in r)s.hasHostProps||(s.hasHostProps=!0),e.prototype._addPropertyEffect(t,e.prototype.PROPERTY_EFFECT_TYPES.NOTIFY,{fn:function(e,t,s){e.__dataHost._setPendingPropertyOrPath("_host_"+t,s[t],!0,!0)}})}(r,e,t,s),r}function xt(e,t,s,n){let r=s.forwardHostProp;if(r&&t.hasHostProps){const l="template"==e.localName;let a=t.templatizeTemplateClass;if(!a){if(l){let e=s.mutableData?gt:bt;class n extends e{}a=t.templatizeTemplateClass=n}else{const s=e.constructor;class n extends s{}a=t.templatizeTemplateClass=n}let i=t.hostProps;for(let e in i)a.prototype._addPropertyEffect("_host_"+e,a.prototype.PROPERTY_EFFECT_TYPES.PROPAGATE,{fn:It(e,r)}),a.prototype._createNotifyingProperty("_host_"+e);b&&n&&function(e,t,s){const n=s.constructor._properties,{propertyEffects:r}=e,{instanceProps:i}=t;for(let e in r)if(!(n[e]||i&&i[e])){const t=r[e];for(let s=0;s<t.length;s++){const{part:n}=t[s].info;if(!n.signature||!n.signature.static){console.warn(`Property '${e}' used in template but not declared in 'properties'; attribute will not be observed.`);break}}}}(t,s,n)}if(e.__dataProto&&Object.assign(e.__data,e.__dataProto),l)o=a,ft=i=e,Object.setPrototypeOf(i,o.prototype),new o,ft=null,e.__dataTemp={},e.__dataPending=null,e.__dataOld=null,e._enableProperties();else{Object.setPrototypeOf(e,a.prototype);const s=t.hostProps;for(let t in s)if(t="_host_"+t,t in e){const s=e[t];delete e[t],e.__data[t]=s}}}var i,o}function It(e,t){return function(e,s,n){t.call(e.__templatizeOwner,s.substring("_host_".length),n[s])}}function At(e,t){return function(e,s,n){t.call(e.__templatizeOwner,e,s,n[s])}}function Ot(e,t,s){if(y&&!vt(e))throw new Error("strictTemplatePolicy: template owner not trusted");if(s=s||{},e.__templatizeOwner)throw new Error("A <template> can only be templatized once");e.__templatizeOwner=t;let n=(t?t.constructor:wt)._parseTemplate(e),r=n.templatizeInstanceClass;r||(r=Et(e,n,s),n.templatizeInstanceClass=r);const i=vt(e);xt(e,n,s,i);let o=class extends r{};return o.prototype._methodHost=i,o.prototype.__dataHost=e,o.prototype.__templatizeOwner=t,o.prototype.__hostProps=n.hostProps,o=o,o}
/**
@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
*/
let Tt=!1;function Dt(){if(c&&!g){if(!Tt){Tt=!0;const e=document.createElement("style");e.textContent="dom-bind,dom-if,dom-repeat{display:none;}",document.head.appendChild(e)}return!0}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
*/const Nt=o(mt(f(HTMLElement)));customElements.define("dom-bind",class extends Nt{static get observedAttributes(){return["mutable-data"]}constructor(){if(super(),y)throw new Error("strictTemplatePolicy: dom-bind not allowed");this.root=null,this.$=null,this.__children=null}attributeChangedCallback(e,t,s,n){this.mutableData=!0}connectedCallback(){Dt()||(this.style.display="none"),this.render()}disconnectedCallback(){this.__removeChildren()}__insertChildren(){r(r(this).parentNode).insertBefore(this.root,this)}__removeChildren(){if(this.__children)for(let e=0;e<this.__children.length;e++)this.root.appendChild(this.__children[e])}render(){let e;if(!this.__children){if(e=e||this.querySelector("template"),!e){let t=new MutationObserver((()=>{if(e=this.querySelector("template"),!e)throw new Error("dom-bind requires a <template> child");t.disconnect(),this.render()}));return void t.observe(this,{childList:!0})}this.root=this._stampTemplate(e),this.$=this.root.$,this.__children=[];for(let e=this.root.firstChild;e;e=e.nextSibling)this.__children[this.__children.length]=e;this._enableProperties()}this.__insertChildren(),this.dispatchEvent(new CustomEvent("dom-change",{bubbles:!0,composed:!0}))}});
/**
@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
*/
const Mt=mt(C);class Rt extends Mt{static get is(){return"dom-repeat"}static get template(){return null}static get properties(){return{items:{type:Array},as:{type:String,value:"item"},indexAs:{type:String,value:"index"},itemsIndexAs:{type:String,value:"itemsIndex"},sort:{type:Function,observer:"__sortChanged"},filter:{type:Function,observer:"__filterChanged"},observe:{type:String,observer:"__observeChanged"},delay:Number,renderedItemCount:{type:Number,notify:!S,readOnly:!0},initialCount:{type:Number},targetFramerate:{type:Number,value:20},_targetFrameTime:{type:Number,computed:"__computeFrameTime(targetFramerate)"},notifyDomChange:{type:Boolean},reuseChunkedInstances:{type:Boolean}}}static get observers(){return["__itemsChanged(items.*)"]}constructor(){super(),this.__instances=[],this.__renderDebouncer=null,this.__itemsIdxToInstIdx={},this.__chunkCount=null,this.__renderStartTime=null,this.__itemsArrayChanged=!1,this.__shouldMeasureChunk=!1,this.__shouldContinueChunking=!1,this.__chunkingId=0,this.__sortFn=null,this.__filterFn=null,this.__observePaths=null,this.__ctor=null,this.__isDetached=!0,this.template=null,this._templateInfo}disconnectedCallback(){super.disconnectedCallback(),this.__isDetached=!0;for(let e=0;e<this.__instances.length;e++)this.__detachInstance(e)}connectedCallback(){if(super.connectedCallback(),Dt()||(this.style.display="none"),this.__isDetached){this.__isDetached=!1;let e=r(r(this).parentNode);for(let t=0;t<this.__instances.length;t++)this.__attachInstance(t,e)}}__ensureTemplatized(){if(!this.__ctor){const e=this;let t=this.template=e._templateInfo?e:this.querySelector("template");if(!t){let e=new MutationObserver((()=>{if(!this.querySelector("template"))throw new Error("dom-repeat requires a <template> child");e.disconnect(),this.__render()}));return e.observe(this,{childList:!0}),!1}let s={};s[this.as]=!0,s[this.indexAs]=!0,s[this.itemsIndexAs]=!0,this.__ctor=Ot(t,this,{mutableData:this.mutableData,parentModel:!0,instanceProps:s,forwardHostProp:function(e,t){let s=this.__instances;for(let n,r=0;r<s.length&&(n=s[r]);r++)n.forwardHostProp(e,t)},notifyInstanceProp:function(e,t,s){if(w(this.as,t)){let n=e[this.itemsIndexAs];t==this.as&&(this.items[n]=s);let r=P(this.as,`${JSCompiler_renameProperty("items",this)}.${n}`,t);this.notifyPath(r,s)}}})}return!0}__getMethodHost(){return this.__dataHost._methodHost||this.__dataHost}__functionFromPropertyValue(e){if("string"==typeof e){let t=e,s=this.__getMethodHost();return function(){return s[t].apply(s,arguments)}}return e}__sortChanged(e){this.__sortFn=this.__functionFromPropertyValue(e),this.items&&this.__debounceRender(this.__render)}__filterChanged(e){this.__filterFn=this.__functionFromPropertyValue(e),this.items&&this.__debounceRender(this.__render)}__computeFrameTime(e){return Math.ceil(1e3/e)}__observeChanged(){this.__observePaths=this.observe&&this.observe.replace(".*",".").split(" ")}__handleObservedPaths(e){if(this.__sortFn||this.__filterFn)if(e){if(this.__observePaths){let t=this.__observePaths;for(let s=0;s<t.length;s++)0===e.indexOf(t[s])&&this.__debounceRender(this.__render,this.delay)}}else this.__debounceRender(this.__render,this.delay)}__itemsChanged(e){this.items&&!Array.isArray(this.items)&&console.warn("dom-repeat expected array for `items`, found",this.items),this.__handleItemPath(e.path,e.value)||("items"===e.path&&(this.__itemsArrayChanged=!0),this.__debounceRender(this.__render))}__debounceRender(e,t=0){this.__renderDebouncer=_.debounce(this.__renderDebouncer,t>0?u.after(t):p,e.bind(this)),v(this.__renderDebouncer)}render(){this.__debounceRender(this.__render),je()}__render(){if(!this.__ensureTemplatized())return;let e=this.items||[];const t=this.__sortAndFilterItems(e),s=this.__calculateLimit(t.length);this.__updateInstances(e,s,t),this.initialCount&&(this.__shouldMeasureChunk||this.__shouldContinueChunking)&&(cancelAnimationFrame(this.__chunkingId),this.__chunkingId=requestAnimationFrame((()=>this.__continueChunking()))),this._setRenderedItemCount(this.__instances.length),S&&!this.notifyDomChange||this.dispatchEvent(new CustomEvent("dom-change",{bubbles:!0,composed:!0}))}__sortAndFilterItems(e){let t=new Array(e.length);for(let s=0;s<e.length;s++)t[s]=s;return this.__filterFn&&(t=t.filter(((t,s,n)=>this.__filterFn(e[t],s,n)))),this.__sortFn&&t.sort(((t,s)=>this.__sortFn(e[t],e[s]))),t}__calculateLimit(e){let t=e;const s=this.__instances.length;if(this.initialCount){let n;!this.__chunkCount||this.__itemsArrayChanged&&!this.reuseChunkedInstances?(t=Math.min(e,this.initialCount),n=Math.max(t-s,0),this.__chunkCount=n||1):(n=Math.min(Math.max(e-s,0),this.__chunkCount),t=Math.min(s+n,e)),this.__shouldMeasureChunk=n===this.__chunkCount,this.__shouldContinueChunking=t<e,this.__renderStartTime=performance.now()}return this.__itemsArrayChanged=!1,t}__continueChunking(){if(this.__shouldMeasureChunk){const e=performance.now()-this.__renderStartTime,t=this._targetFrameTime/e;this.__chunkCount=Math.round(this.__chunkCount*t)||1}this.__shouldContinueChunking&&this.__debounceRender(this.__render)}__updateInstances(e,t,s){const n=this.__itemsIdxToInstIdx={};let r;for(r=0;r<t;r++){let t=this.__instances[r],i=s[r],o=e[i];n[i]=r,t?(t._setPendingProperty(this.as,o),t._setPendingProperty(this.indexAs,r),t._setPendingProperty(this.itemsIndexAs,i),t._flushProperties()):this.__insertInstance(o,r,i)}for(let e=this.__instances.length-1;e>=r;e--)this.__detachAndRemoveInstance(e)}__detachInstance(e){let t=this.__instances[e];const s=r(t.root);for(let e=0;e<t.children.length;e++){let n=t.children[e];s.appendChild(n)}return t}__attachInstance(e,t){let s=this.__instances[e];t.insertBefore(s.root,this)}__detachAndRemoveInstance(e){this.__detachInstance(e),this.__instances.splice(e,1)}__stampInstance(e,t,s){let n={};return n[this.as]=e,n[this.indexAs]=t,n[this.itemsIndexAs]=s,new this.__ctor(n)}__insertInstance(e,t,s){const n=this.__stampInstance(e,t,s);let i=this.__instances[t+1],o=i?i.children[0]:this;return r(r(this).parentNode).insertBefore(n.root,o),this.__instances[t]=n,n}_showHideChildren(e){for(let t=0;t<this.__instances.length;t++)this.__instances[t]._showHideChildren(e)}__handleItemPath(e,t){let s=e.slice(6),n=s.indexOf("."),r=n<0?s:s.substring(0,n);if(r==parseInt(r,10)){let e=n<0?"":s.substring(n+1);this.__handleObservedPaths(e);let i=this.__itemsIdxToInstIdx[r],o=this.__instances[i];if(o){let s=this.as+(e?"."+e:"");o._setPendingPropertyOrPath(s,t,!1,!0),o._flushProperties()}return!0}}itemForElement(e){let t=this.modelForElement(e);return t&&t[this.as]}indexForElement(e){let t=this.modelForElement(e);return t&&t[this.indexAs]}modelForElement(e){return function(e,t){let s;for(;t;)if(s=t.__dataHost?t:t.__templatizeInstance){if(s.__dataHost==e)return s;t=s.__dataHost}else t=r(t).parentNode;return null}(this.template,e)}}customElements.define(Rt.is,Rt);
/**
@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
*/
class kt extends C{static get is(){return"dom-if"}static get template(){return null}static get properties(){return{if:{type:Boolean,observer:"__debounceRender"},restamp:{type:Boolean,observer:"__debounceRender"},notifyDomChange:{type:Boolean}}}constructor(){super(),this.__renderDebouncer=null,this._lastIf=!1,this.__hideTemplateChildren__=!1,this.__template,this._templateInfo}__debounceRender(){this.__renderDebouncer=_.debounce(this.__renderDebouncer,p,(()=>this.__render())),v(this.__renderDebouncer)}disconnectedCallback(){super.disconnectedCallback();const e=r(this).parentNode;e&&(e.nodeType!=Node.DOCUMENT_FRAGMENT_NODE||r(e).host)||this.__teardownInstance()}connectedCallback(){super.connectedCallback(),Dt()||(this.style.display="none"),this.if&&this.__debounceRender()}__ensureTemplate(){if(!this.__template){const e=this;let t=e._templateInfo?e:r(e).querySelector("template");if(!t){let e=new MutationObserver((()=>{if(!r(this).querySelector("template"))throw new Error("dom-if requires a <template> child");e.disconnect(),this.__render()}));return e.observe(this,{childList:!0}),!1}this.__template=t}return!0}__ensureInstance(){let e=r(this).parentNode;if(this.__hasInstance()){let t=this.__getInstanceNodes();if(t&&t.length){if(r(this).previousSibling!==t[t.length-1])for(let s,n=0;n<t.length&&(s=t[n]);n++)r(e).insertBefore(s,this)}}else{if(!e)return!1;if(!this.__ensureTemplate())return!1;this.__createAndInsertInstance(e)}return!0}render(){je()}__render(){if(this.if){if(!this.__ensureInstance())return}else this.restamp&&this.__teardownInstance();this._showHideChildren(),S&&!this.notifyDomChange||this.if==this._lastIf||(this.dispatchEvent(new CustomEvent("dom-change",{bubbles:!0,composed:!0})),this._lastIf=this.if)}__hasInstance(){}__getInstanceNodes(){}__createAndInsertInstance(e){}__teardownInstance(){}_showHideChildren(){}}const Ft=E?class extends kt{constructor(){super(),this.__instance=null,this.__syncInfo=null}__hasInstance(){return Boolean(this.__instance)}__getInstanceNodes(){return this.__instance.templateInfo.childNodes}__createAndInsertInstance(e){const t=this.__dataHost||this;if(y&&!this.__dataHost)throw new Error("strictTemplatePolicy: template owner not trusted");const s=t._bindTemplate(this.__template,!0);s.runEffects=(e,t,s)=>{let n=this.__syncInfo;if(this.if)n&&(this.__syncInfo=null,this._showHideChildren(),t=Object.assign(n.changedProps,t)),e(t,s);else if(this.__instance)if(n||(n=this.__syncInfo={runEffects:e,changedProps:{}}),s)for(const e in t){const t=x(e);n.changedProps[t]=this.__dataHost[t]}else Object.assign(n.changedProps,t)},this.__instance=t._stampTemplate(this.__template,s),r(e).insertBefore(this.__instance,this)}__syncHostProperties(){const e=this.__syncInfo;e&&(this.__syncInfo=null,e.runEffects(e.changedProps,!1))}__teardownInstance(){const e=this.__dataHost||this;this.__instance&&(e._removeBoundDom(this.__instance),this.__instance=null,this.__syncInfo=null)}_showHideChildren(){const e=this.__hideTemplateChildren__||!this.if;this.__instance&&Boolean(this.__instance.__hidden)!==e&&(this.__instance.__hidden=e,St(e,this.__instance.templateInfo.childNodes)),e||this.__syncHostProperties()}}:class extends kt{constructor(){super(),this.__ctor=null,this.__instance=null,this.__invalidProps=null}__hasInstance(){return Boolean(this.__instance)}__getInstanceNodes(){return this.__instance.children}__createAndInsertInstance(e){this.__ctor||(this.__ctor=Ot(this.__template,this,{mutableData:!0,forwardHostProp:function(e,t){this.__instance&&(this.if?this.__instance.forwardHostProp(e,t):(this.__invalidProps=this.__invalidProps||Object.create(null),this.__invalidProps[x(e)]=!0))}})),this.__instance=new this.__ctor,r(e).insertBefore(this.__instance.root,this)}__teardownInstance(){if(this.__instance){let e=this.__instance.children;if(e&&e.length){let t=r(e[0]).parentNode;if(t){t=r(t);for(let s,n=0;n<e.length&&(s=e[n]);n++)t.removeChild(s)}}this.__invalidProps=null,this.__instance=null}}__syncHostProperties(){let e=this.__invalidProps;if(e){this.__invalidProps=null;for(let t in e)this.__instance._setPendingProperty(t,this.__dataHost[t]);this.__instance._flushProperties()}}_showHideChildren(){const e=this.__hideTemplateChildren__||!this.if;this.__instance&&Boolean(this.__instance.__hidden)!==e&&(this.__instance.__hidden=e,this.__instance._showHideChildren(e)),e||this.__syncHostProperties()}};customElements.define(Ft.is,Ft);
/**
@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
*/
let Ht=e((e=>{let t=i(e);return class extends t{static get properties(){return{items:{type:Array},multi:{type:Boolean,value:!1},selected:{type:Object,notify:!0},selectedItem:{type:Object,notify:!0},toggle:{type:Boolean,value:!1}}}static get observers(){return["__updateSelection(multi, items.*)"]}constructor(){super(),this.__lastItems=null,this.__lastMulti=null,this.__selectedMap=null}__updateSelection(e,t){let s=t.path;if(s==JSCompiler_renameProperty("items",this)){let s=t.base||[],n=this.__lastItems;if(e!==this.__lastMulti&&this.clearSelection(),n){let e=I(s,n);this.__applySplices(e)}this.__lastItems=s,this.__lastMulti=e}else if(t.path==`${JSCompiler_renameProperty("items",this)}.splices`)this.__applySplices(t.value.indexSplices);else{let e=s.slice(`${JSCompiler_renameProperty("items",this)}.`.length),t=parseInt(e,10);e.indexOf(".")<0&&e==t&&this.__deselectChangedIdx(t)}}__applySplices(e){let t=this.__selectedMap;for(let s=0;s<e.length;s++){let n=e[s];t.forEach(((e,s)=>{e<n.index||(e>=n.index+n.removed.length?t.set(s,e+n.addedCount-n.removed.length):t.set(s,-1))}));for(let e=0;e<n.addedCount;e++){let s=n.index+e;t.has(this.items[s])&&t.set(this.items[s],s)}}this.__updateLinks();let s=0;t.forEach(((e,n)=>{e<0?(this.multi?this.splice(JSCompiler_renameProperty("selected",this),s,1):this.selected=this.selectedItem=null,t.delete(n)):s++}))}__updateLinks(){if(this.__dataLinkedPaths={},this.multi){let e=0;this.__selectedMap.forEach((t=>{t>=0&&this.linkPaths(`${JSCompiler_renameProperty("items",this)}.${t}`,`${JSCompiler_renameProperty("selected",this)}.${e++}`)}))}else this.__selectedMap.forEach((e=>{this.linkPaths(JSCompiler_renameProperty("selected",this),`${JSCompiler_renameProperty("items",this)}.${e}`),this.linkPaths(JSCompiler_renameProperty("selectedItem",this),`${JSCompiler_renameProperty("items",this)}.${e}`)}))}clearSelection(){this.__dataLinkedPaths={},this.__selectedMap=new Map,this.selected=this.multi?[]:null,this.selectedItem=null}isSelected(e){return this.__selectedMap.has(e)}isIndexSelected(e){return this.isSelected(this.items[e])}__deselectChangedIdx(e){let t=this.__selectedIndexForItemIndex(e);if(t>=0){let e=0;this.__selectedMap.forEach(((s,n)=>{t==e++&&this.deselect(n)}))}}__selectedIndexForItemIndex(e){let t=this.__dataLinkedPaths[`${JSCompiler_renameProperty("items",this)}.${e}`];if(t)return parseInt(t.slice(`${JSCompiler_renameProperty("selected",this)}.`.length),10)}deselect(e){let t=this.__selectedMap.get(e);if(t>=0){let s;this.__selectedMap.delete(e),this.multi&&(s=this.__selectedIndexForItemIndex(t)),this.__updateLinks(),this.multi?this.splice(JSCompiler_renameProperty("selected",this),s,1):this.selected=this.selectedItem=null}}deselectIndex(e){this.deselect(this.items[e])}select(e){this.selectIndex(this.items.indexOf(e))}selectIndex(e){let t=this.items[e];this.isSelected(t)?this.toggle&&this.deselectIndex(e):(this.multi||this.__selectedMap.clear(),this.__selectedMap.set(t,e),this.__updateLinks(),this.multi?this.push(JSCompiler_renameProperty("selected",this),t):this.selected=this.selectedItem=t)}}}))(C);class Lt extends Ht{static get is(){return"array-selector"}static get template(){return null}}customElements.define(Lt.is,Lt);
/**
@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
*/
const Bt=new xe;window.ShadyCSS||(window.ShadyCSS={prepareTemplate(e,t,s){},prepareTemplateDom(e,t){},prepareTemplateStyles(e,t,s){},styleSubtree(e,t){Bt.processStyles(),re(e,t)},styleElement(e){Bt.processStyles()},styleDocument(e){Bt.processStyles(),re(document.body,e)},getComputedStyleValue:(e,t)=>ie(e,t),flushCustomStyles(){},nativeCss:R,nativeShadow:O,cssBuild:D,disableRuntime:M}),window.ShadyCSS.CustomStyleInterface=Bt;
/**
@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
*/
const $t=window.ShadyCSS.CustomStyleInterface;class jt extends HTMLElement{constructor(){super(),this._style=null,$t.addCustomStyle(this)}getStyle(){if(this._style)return this._style;const e=this.querySelector("style");if(!e)return null;this._style=e;const t=e.getAttribute("include");return t&&(e.removeAttribute("include"),e.textContent=A(t)+e.textContent),this.ownerDocument!==window.document&&window.document.head.appendChild(this),this._style}}window.customElements.define("custom-style",jt);
/**
@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
*/
const qt=st(HTMLElement).prototype;export{qt as B,et as D,_t as P,Xe as d,ot as m,Ot as t};
