forked from webcomponents/webcomponentsjs
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwebcomponents-sd-ce.js
More file actions
149 lines (145 loc) · 61.7 KB
/
webcomponents-sd-ce.js
File metadata and controls
149 lines (145 loc) · 61.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
(function(){/*
Copyright (c) 2016 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
*/
'use strict';var n,p="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)};function ba(){ba=function(){};p.Symbol||(p.Symbol=ca)}var ca=function(){var a=0;return function(b){return"jscomp_symbol_"+(b||"")+a++}}();
function da(){ba();var a=p.Symbol.iterator;a||(a=p.Symbol.iterator=p.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ea(this)}});da=function(){}}function ea(a){var b=0;return fa(function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}})}function fa(a){da();a={next:a};a[p.Symbol.iterator]=function(){return this};return a}function ha(a){da();var b=a[Symbol.iterator];return b?b.call(a):ea(a)}
function ia(a){for(var b,c=[];!(b=a.next()).done;)c.push(b.value);return c}var r=window.ShadyDOM||{};r.va=!(!Element.prototype.attachShadow||!Node.prototype.getRootNode);var ja=Object.getOwnPropertyDescriptor(Node.prototype,"firstChild");r.F=!!(ja&&ja.configurable&&ja.get);r.ga=r.force||!r.va;function t(a){return a.__shady&&void 0!==a.__shady.firstChild}function u(a){return"ShadyRoot"===a.ma}function ka(a){a=a.getRootNode();if(u(a))return a}
var v=Element.prototype,la=v.matches||v.matchesSelector||v.mozMatchesSelector||v.msMatchesSelector||v.oMatchesSelector||v.webkitMatchesSelector;function ma(a,b){if(a&&b)for(var c=Object.getOwnPropertyNames(b),d=0,e;d<c.length&&(e=c[d]);d++){var f=Object.getOwnPropertyDescriptor(b,e);f&&Object.defineProperty(a,e,f)}}function na(a,b){for(var c=[],d=1;d<arguments.length;++d)c[d-1]=arguments[d];for(d=0;d<c.length;d++)ma(a,c[d]);return a}function oa(a,b){for(var c in b)a[c]=b[c]}
var pa=document.createTextNode(""),qa=0,ra=[];(new MutationObserver(function(){for(;ra.length;)try{ra.shift()()}catch(a){throw pa.textContent=qa++,a;}})).observe(pa,{characterData:!0});function sa(a){ra.push(a);pa.textContent=qa++}var ta=!!document.contains;function ua(a,b){for(;b;){if(b==a)return!0;b=b.parentNode}return!1};var va=[],wa;function xa(a){wa||(wa=!0,sa(ya));va.push(a)}function ya(){wa=!1;for(var a=!!va.length;va.length;)va.shift()();return a}ya.list=va;function za(){this.a=!1;this.addedNodes=[];this.removedNodes=[];this.M=new Set}function Aa(a){a.a||(a.a=!0,sa(function(){Ba(a)}))}function Ba(a){if(a.a){a.a=!1;var b=a.takeRecords();b.length&&a.M.forEach(function(a){a(b)})}}za.prototype.takeRecords=function(){if(this.addedNodes.length||this.removedNodes.length){var a=[{addedNodes:this.addedNodes,removedNodes:this.removedNodes}];this.addedNodes=[];this.removedNodes=[];return a}return[]};
function Ca(a,b){a.__shady=a.__shady||{};a.__shady.G||(a.__shady.G=new za);a.__shady.G.M.add(b);var c=a.__shady.G;return{pa:b,w:c,ra:a,takeRecords:function(){return c.takeRecords()}}}function Da(a){var b=a&&a.w;b&&(b.M.delete(a.pa),b.M.size||(a.ra.__shady.G=null))}
function Ea(a,b){var c=b.getRootNode();return a.map(function(a){var b=c===a.target.getRootNode();if(b&&a.addedNodes){if(b=Array.from(a.addedNodes).filter(function(a){return c===a.getRootNode()}),b.length)return a=Object.create(a),Object.defineProperty(a,"addedNodes",{value:b,configurable:!0}),a}else if(b)return a}).filter(function(a){return a})};var w={},Fa=Element.prototype.insertBefore,Ga=Element.prototype.removeChild,Ha=Element.prototype.setAttribute,Ia=Element.prototype.removeAttribute,Ja=Element.prototype.cloneNode,Ka=Document.prototype.importNode,La=Element.prototype.addEventListener,Ma=Element.prototype.removeEventListener,Na=Window.prototype.addEventListener,Oa=Window.prototype.removeEventListener,Pa=Element.prototype.dispatchEvent,Qa=Element.prototype.querySelector,Ra=Element.prototype.querySelectorAll,Sa=Node.prototype.contains||
HTMLElement.prototype.contains;w.appendChild=Element.prototype.appendChild;w.insertBefore=Fa;w.removeChild=Ga;w.setAttribute=Ha;w.removeAttribute=Ia;w.cloneNode=Ja;w.importNode=Ka;w.addEventListener=La;w.removeEventListener=Ma;w.Fa=Na;w.Ga=Oa;w.dispatchEvent=Pa;w.querySelector=Qa;w.querySelectorAll=Ra;w.contains=Sa;var Ta=/[&\u00A0"]/g,Ua=/[&\u00A0<>]/g;function Va(a){switch(a){case "&":return"&";case "<":return"<";case ">":return">";case '"':return""";case "\u00a0":return" "}}function Wa(a){for(var b={},c=0;c<a.length;c++)b[a[c]]=!0;return b}var Xa=Wa("area base br col command embed hr img input keygen link meta param source track wbr".split(" ")),Ya=Wa("style script xmp iframe noembed noframes plaintext noscript".split(" "));
function Za(a,b){"template"===a.localName&&(a=a.content);for(var c="",d=b?b(a):a.childNodes,e=0,f=d.length,g;e<f&&(g=d[e]);e++){a:{var h=g;var k=a;var l=b;switch(h.nodeType){case Node.ELEMENT_NODE:for(var m=h.localName,q="<"+m,H=h.attributes,N=0;k=H[N];N++)q+=" "+k.name+'="'+k.value.replace(Ta,Va)+'"';q+=">";h=Xa[m]?q:q+Za(h,l)+"</"+m+">";break a;case Node.TEXT_NODE:h=h.data;h=k&&Ya[k.localName]?h:h.replace(Ua,Va);break a;case Node.COMMENT_NODE:h="\x3c!--"+h.data+"--\x3e";break a;default:throw window.console.error(h),
Error("not implemented");}}c+=h}return c};var x={},y=document.createTreeWalker(document,NodeFilter.SHOW_ALL,null,!1),z=document.createTreeWalker(document,NodeFilter.SHOW_ELEMENT,null,!1);function $a(a){var b=[];y.currentNode=a;for(a=y.firstChild();a;)b.push(a),a=y.nextSibling();return b}x.parentNode=function(a){y.currentNode=a;return y.parentNode()};x.firstChild=function(a){y.currentNode=a;return y.firstChild()};x.lastChild=function(a){y.currentNode=a;return y.lastChild()};x.previousSibling=function(a){y.currentNode=a;return y.previousSibling()};
x.nextSibling=function(a){y.currentNode=a;return y.nextSibling()};x.childNodes=$a;x.parentElement=function(a){z.currentNode=a;return z.parentNode()};x.firstElementChild=function(a){z.currentNode=a;return z.firstChild()};x.lastElementChild=function(a){z.currentNode=a;return z.lastChild()};x.previousElementSibling=function(a){z.currentNode=a;return z.previousSibling()};x.nextElementSibling=function(a){z.currentNode=a;return z.nextSibling()};
x.children=function(a){var b=[];z.currentNode=a;for(a=z.firstChild();a;)b.push(a),a=z.nextSibling();return b};x.innerHTML=function(a){return Za(a,function(a){return $a(a)})};x.textContent=function(a){switch(a.nodeType){case Node.ELEMENT_NODE:case Node.DOCUMENT_FRAGMENT_NODE:a=document.createTreeWalker(a,NodeFilter.SHOW_TEXT,null,!1);for(var b="",c;c=a.nextNode();)b+=c.nodeValue;return b;default:return a.nodeValue}};var ab=Object.getOwnPropertyDescriptor(Element.prototype,"innerHTML")||Object.getOwnPropertyDescriptor(HTMLElement.prototype,"innerHTML"),bb=document.implementation.createHTMLDocument("inert").createElement("div"),cb=Object.getOwnPropertyDescriptor(Document.prototype,"activeElement"),db={parentElement:{get:function(){var a=this.__shady&&this.__shady.parentNode;a&&a.nodeType!==Node.ELEMENT_NODE&&(a=null);return void 0!==a?a:x.parentElement(this)},configurable:!0},parentNode:{get:function(){var a=this.__shady&&
this.__shady.parentNode;return void 0!==a?a:x.parentNode(this)},configurable:!0},nextSibling:{get:function(){var a=this.__shady&&this.__shady.nextSibling;return void 0!==a?a:x.nextSibling(this)},configurable:!0},previousSibling:{get:function(){var a=this.__shady&&this.__shady.previousSibling;return void 0!==a?a:x.previousSibling(this)},configurable:!0},className:{get:function(){return this.getAttribute("class")||""},set:function(a){this.setAttribute("class",a)},configurable:!0},nextElementSibling:{get:function(){if(this.__shady&&
void 0!==this.__shady.nextSibling){for(var a=this.nextSibling;a&&a.nodeType!==Node.ELEMENT_NODE;)a=a.nextSibling;return a}return x.nextElementSibling(this)},configurable:!0},previousElementSibling:{get:function(){if(this.__shady&&void 0!==this.__shady.previousSibling){for(var a=this.previousSibling;a&&a.nodeType!==Node.ELEMENT_NODE;)a=a.previousSibling;return a}return x.previousElementSibling(this)},configurable:!0}},eb={childNodes:{get:function(){if(t(this)){if(!this.__shady.childNodes){this.__shady.childNodes=
[];for(var a=this.firstChild;a;a=a.nextSibling)this.__shady.childNodes.push(a)}var b=this.__shady.childNodes}else b=x.childNodes(this);b.item=function(a){return b[a]};return b},configurable:!0},childElementCount:{get:function(){return this.children.length},configurable:!0},firstChild:{get:function(){var a=this.__shady&&this.__shady.firstChild;return void 0!==a?a:x.firstChild(this)},configurable:!0},lastChild:{get:function(){var a=this.__shady&&this.__shady.lastChild;return void 0!==a?a:x.lastChild(this)},
configurable:!0},textContent:{get:function(){if(t(this)){for(var a=[],b=0,c=this.childNodes,d;d=c[b];b++)d.nodeType!==Node.COMMENT_NODE&&a.push(d.textContent);return a.join("")}return x.textContent(this)},set:function(a){switch(this.nodeType){case Node.ELEMENT_NODE:case Node.DOCUMENT_FRAGMENT_NODE:for(;this.firstChild;)this.removeChild(this.firstChild);(0<a.length||this.nodeType===Node.ELEMENT_NODE)&&this.appendChild(document.createTextNode(a));break;default:this.nodeValue=a}},configurable:!0},firstElementChild:{get:function(){if(this.__shady&&
void 0!==this.__shady.firstChild){for(var a=this.firstChild;a&&a.nodeType!==Node.ELEMENT_NODE;)a=a.nextSibling;return a}return x.firstElementChild(this)},configurable:!0},lastElementChild:{get:function(){if(this.__shady&&void 0!==this.__shady.lastChild){for(var a=this.lastChild;a&&a.nodeType!==Node.ELEMENT_NODE;)a=a.previousSibling;return a}return x.lastElementChild(this)},configurable:!0},children:{get:function(){var a;t(this)?a=Array.prototype.filter.call(this.childNodes,function(a){return a.nodeType===
Node.ELEMENT_NODE}):a=x.children(this);a.item=function(b){return a[b]};return a},configurable:!0},innerHTML:{get:function(){var a="template"===this.localName?this.content:this;return t(this)?Za(a):x.innerHTML(a)},set:function(a){for(var b="template"===this.localName?this.content:this;b.firstChild;)b.removeChild(b.firstChild);for(ab&&ab.set?ab.set.call(bb,a):bb.innerHTML=a;bb.firstChild;)b.appendChild(bb.firstChild)},configurable:!0}},fb={shadowRoot:{get:function(){return this.__shady&&this.__shady.za||
null},configurable:!0}},gb={activeElement:{get:function(){var a=cb&&cb.get?cb.get.call(document):r.F?void 0:document.activeElement;if(a&&a.nodeType){var b=!!u(this);if(this===document||b&&this.host!==a&&w.contains.call(this.host,a)){for(b=ka(a);b&&b!==this;)a=b.host,b=ka(a);a=this===document?b?null:a:b===this?a:null}else a=null}else a=null;return a},set:function(){},configurable:!0}};
function A(a,b,c){for(var d in b){var e=Object.getOwnPropertyDescriptor(a,d);e&&e.configurable||!e&&c?Object.defineProperty(a,d,b[d]):c&&console.warn("Could not define",d,"on",a)}}function B(a){A(a,db);A(a,eb);A(a,gb)}var hb=r.F?function(){}:function(a){a.__shady&&a.__shady.na||(a.__shady=a.__shady||{},a.__shady.na=!0,A(a,db,!0))},ib=r.F?function(){}:function(a){a.__shady&&a.__shady.la||(a.__shady=a.__shady||{},a.__shady.la=!0,A(a,eb,!0),A(a,fb,!0))};function jb(a,b,c){hb(a);c=c||null;a.__shady=a.__shady||{};b.__shady=b.__shady||{};c&&(c.__shady=c.__shady||{});a.__shady.previousSibling=c?c.__shady.previousSibling:b.lastChild;var d=a.__shady.previousSibling;d&&d.__shady&&(d.__shady.nextSibling=a);(d=a.__shady.nextSibling=c)&&d.__shady&&(d.__shady.previousSibling=a);a.__shady.parentNode=b;c?c===b.__shady.firstChild&&(b.__shady.firstChild=a):(b.__shady.lastChild=a,b.__shady.firstChild||(b.__shady.firstChild=a));b.__shady.childNodes=null}
function kb(a){if(!a.__shady||void 0===a.__shady.firstChild){a.__shady=a.__shady||{};a.__shady.firstChild=x.firstChild(a);a.__shady.lastChild=x.lastChild(a);ib(a);for(var b=a.__shady.childNodes=x.childNodes(a),c=0,d;c<b.length&&(d=b[c]);c++)d.__shady=d.__shady||{},d.__shady.parentNode=a,d.__shady.nextSibling=b[c+1]||null,d.__shady.previousSibling=b[c-1]||null,hb(d)}};function lb(a,b,c){if(b===a)throw Error("Failed to execute 'appendChild' on 'Node': The new child element contains the parent.");if(c){var d=c.__shady&&c.__shady.parentNode;if(void 0!==d&&d!==a||void 0===d&&x.parentNode(c)!==a)throw Error("Failed to execute 'insertBefore' on 'Node': The node before which the new node is to be inserted is not a child of this node.");}if(c===b)return b;b.parentNode&&mb(b.parentNode,b);d=ka(a);var e;if(e=d)a:{if(!b.__noInsertionPoint){var f;"slot"===b.localName?f=[b]:
b.querySelectorAll&&(f=b.querySelectorAll("slot"));if(f&&f.length){e=f;break a}}e=void 0}(f=e)&&d.C.push.apply(d.C,[].concat(f instanceof Array?f:ia(ha(f))));d&&("slot"===a.localName||f)&&C(d);if(t(a)){d=c;ib(a);a.__shady=a.__shady||{};void 0!==a.__shady.firstChild&&(a.__shady.childNodes=null);if(b.nodeType===Node.DOCUMENT_FRAGMENT_NODE){f=b.childNodes;for(e=0;e<f.length;e++)jb(f[e],a,d);b.__shady=b.__shady||{};d=void 0!==b.__shady.firstChild?null:void 0;b.__shady.firstChild=b.__shady.lastChild=d;
b.__shady.childNodes=d}else jb(b,a,d);if(nb(a)){C(a.__shady.root);var g=!0}else a.__shady.root&&(g=!0)}g||(g=u(a)?a.host:a,c?(c=ob(c),w.insertBefore.call(g,b,c)):w.appendChild.call(g,b));pb(a,b);return b}
function mb(a,b){if(b.parentNode!==a)throw Error("The node to be removed is not a child of this node: "+b);var c=ka(b);if(t(a)){b.__shady=b.__shady||{};a.__shady=a.__shady||{};b===a.__shady.firstChild&&(a.__shady.firstChild=b.__shady.nextSibling);b===a.__shady.lastChild&&(a.__shady.lastChild=b.__shady.previousSibling);var d=b.__shady.previousSibling,e=b.__shady.nextSibling;d&&(d.__shady=d.__shady||{},d.__shady.nextSibling=e);e&&(e.__shady=e.__shady||{},e.__shady.previousSibling=d);b.__shady.parentNode=
b.__shady.previousSibling=b.__shady.nextSibling=void 0;void 0!==a.__shady.childNodes&&(a.__shady.childNodes=null);if(nb(a)){C(a.__shady.root);var f=!0}}qb(b);if(c){(d=a&&"slot"===a.localName)&&(f=!0);rb(c);e=c.h;for(var g in e)for(var h=e[g],k=0;k<h.length;k++){var l=h[k];if(ua(b,l)){h.splice(k,1);var m=c.l.indexOf(l);0<=m&&c.l.splice(m,1);k--;if(m=l.__shady.D)for(l=0;l<m.length;l++){var q=m[l],H=x.parentNode(q);H&&w.removeChild.call(H,q)}m=!0}}(m||d)&&C(c)}f||(f=u(a)?a.host:a,(!a.__shady.root&&"slot"!==
b.localName||f===x.parentNode(b))&&w.removeChild.call(f,b));pb(a,null,b);return b}function qb(a){if(a.__shady&&void 0!==a.__shady.$)for(var b=a.childNodes,c=0,d=b.length,e;c<d&&(e=b[c]);c++)qb(e);a.__shady&&(a.__shady.$=void 0)}function ob(a){var b=a;a&&"slot"===a.localName&&(b=(b=a.__shady&&a.__shady.D)&&b.length?b[0]:ob(a.nextSibling));return b}function nb(a){return(a=a&&a.__shady&&a.__shady.root)&&sb(a)}
function tb(a,b){if("slot"===b)a=a.parentNode,nb(a)&&C(a.__shady.root);else if("slot"===a.localName&&"name"===b&&(b=ka(a))){var c=a.oa,d=ub(a);if(d!==c){c=b.h[c];var e=c.indexOf(a);0<=e&&c.splice(e,1);c=b.h[d]||(b.h[d]=[]);c.push(a);1<c.length&&(b.h[d]=vb(c))}C(b)}}function pb(a,b,c){if(a=a.__shady&&a.__shady.G)b&&a.addedNodes.push(b),c&&a.removedNodes.push(c),Aa(a)}
function wb(a){if(a&&a.nodeType){a.__shady=a.__shady||{};var b=a.__shady.$;void 0===b&&(u(a)?b=a:b=(b=a.parentNode)?wb(b):a,w.contains.call(document.documentElement,a)&&(a.__shady.$=b));return b}}function xb(a,b,c){var d=[];yb(a.childNodes,b,c,d);return d}function yb(a,b,c,d){for(var e=0,f=a.length,g;e<f&&(g=a[e]);e++){var h;if(h=g.nodeType===Node.ELEMENT_NODE){h=g;var k=b,l=c,m=d,q=k(h);q&&m.push(h);l&&l(q)?h=q:(yb(h.childNodes,k,l,m),h=void 0)}if(h)break}}var zb=null;
function Ab(a,b,c){zb||(zb=window.ShadyCSS&&window.ShadyCSS.ScopingShim);zb&&"class"===b?zb.setElementClass(a,c):(w.setAttribute.call(a,b,c),tb(a,b))}function Bb(a,b){if(a.ownerDocument!==document)return w.importNode.call(document,a,b);var c=w.importNode.call(document,a,!1);if(b){a=a.childNodes;b=0;for(var d;b<a.length;b++)d=Bb(a[b],!0),c.appendChild(d)}return c};var Cb="__eventWrappers"+Date.now(),Db={blur:!0,focus:!0,focusin:!0,focusout:!0,click:!0,dblclick:!0,mousedown:!0,mouseenter:!0,mouseleave:!0,mousemove:!0,mouseout:!0,mouseover:!0,mouseup:!0,wheel:!0,beforeinput:!0,input:!0,keydown:!0,keyup:!0,compositionstart:!0,compositionupdate:!0,compositionend:!0,touchstart:!0,touchend:!0,touchmove:!0,touchcancel:!0,pointerover:!0,pointerenter:!0,pointerdown:!0,pointermove:!0,pointerup:!0,pointercancel:!0,pointerout:!0,pointerleave:!0,gotpointercapture:!0,lostpointercapture:!0,
dragstart:!0,drag:!0,dragenter:!0,dragleave:!0,dragover:!0,drop:!0,dragend:!0,DOMActivate:!0,DOMFocusIn:!0,DOMFocusOut:!0,keypress:!0};function Eb(a,b){var c=[],d=a;for(a=a===window?window:a.getRootNode();d;)c.push(d),d=d.assignedSlot?d.assignedSlot:d.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&d.host&&(b||d!==a)?d.host:d.parentNode;c[c.length-1]===document&&c.push(window);return c}
function Fb(a,b){if(!u)return a;a=Eb(a,!0);for(var c=0,d,e,f,g;c<b.length;c++)if(d=b[c],f=d===window?window:d.getRootNode(),f!==e&&(g=a.indexOf(f),e=f),!u(f)||-1<g)return d}
var Gb={get composed(){!1!==this.isTrusted&&void 0===this.P&&(this.P=Db[this.type]);return this.P||!1},composedPath:function(){this.aa||(this.aa=Eb(this.__target,this.composed));return this.aa},get target(){return Fb(this.currentTarget,this.composedPath())},get relatedTarget(){if(!this.ba)return null;this.ca||(this.ca=Eb(this.ba,!0));return Fb(this.currentTarget,this.ca)},stopPropagation:function(){Event.prototype.stopPropagation.call(this);this.R=!0},stopImmediatePropagation:function(){Event.prototype.stopImmediatePropagation.call(this);
this.R=this.ka=!0}};function Hb(a){function b(b,d){b=new a(b,d);b.P=d&&!!d.composed;return b}oa(b,a);b.prototype=a.prototype;return b}var Ib={focus:!0,blur:!0};function Jb(a,b,c){if(c=b.__handlers&&b.__handlers[a.type]&&b.__handlers[a.type][c])for(var d=0,e;(e=c[d])&&a.target!==a.relatedTarget&&(e.call(b,a),!a.ka);d++);}
function Kb(a){var b=a.composedPath();Object.defineProperty(a,"currentTarget",{get:function(){return d},configurable:!0});for(var c=b.length-1;0<=c;c--){var d=b[c];Jb(a,d,"capture");if(a.R)return}Object.defineProperty(a,"eventPhase",{get:function(){return Event.AT_TARGET}});var e;for(c=0;c<b.length;c++){d=b[c];var f=d.__shady&&d.__shady.root;if(0===c||f&&f===e)if(Jb(a,d,"bubble"),d!==window&&(e=d.getRootNode()),a.R)break}}
function Lb(a,b,c,d,e,f){for(var g=0;g<a.length;g++){var h=a[g],k=h.type,l=h.capture,m=h.once,q=h.passive;if(b===h.node&&c===k&&d===l&&e===m&&f===q)return g}return-1}
function Mb(a,b,c){if(b){if("object"===typeof c){var d=!!c.capture;var e=!!c.once;var f=!!c.passive}else d=!!c,f=e=!1;var g=c&&c.S||this,h=b[Cb];if(h){if(-1<Lb(h,g,a,d,e,f))return}else b[Cb]=[];h=function(d){e&&this.removeEventListener(a,b,c);d.__target||Nb(d);if(g!==this){var f=Object.getOwnPropertyDescriptor(d,"currentTarget");Object.defineProperty(d,"currentTarget",{get:function(){return g},configurable:!0})}if(d.composed||-1<d.composedPath().indexOf(g))if(d.target===d.relatedTarget)d.eventPhase===
Event.BUBBLING_PHASE&&d.stopImmediatePropagation();else if(d.eventPhase===Event.CAPTURING_PHASE||d.bubbles||d.target===g){var h="object"===typeof b&&b.handleEvent?b.handleEvent(d):b.call(g,d);g!==this&&(f?(Object.defineProperty(d,"currentTarget",f),f=null):delete d.currentTarget);return h}};b[Cb].push({node:this,type:a,capture:d,once:e,passive:f,Ha:h});Ib[a]?(this.__handlers=this.__handlers||{},this.__handlers[a]=this.__handlers[a]||{capture:[],bubble:[]},this.__handlers[a][d?"capture":"bubble"].push(h)):
(this instanceof Window?w.Fa:w.addEventListener).call(this,a,h,c)}}
function Ob(a,b,c){if(b){if("object"===typeof c){var d=!!c.capture;var e=!!c.once;var f=!!c.passive}else d=!!c,f=e=!1;var g=c&&c.S||this,h=void 0;var k=null;try{k=b[Cb]}catch(l){}k&&(e=Lb(k,g,a,d,e,f),-1<e&&(h=k.splice(e,1)[0].Ha,k.length||(b[Cb]=void 0)));(this instanceof Window?w.Ga:w.removeEventListener).call(this,a,h||b,c);h&&Ib[a]&&this.__handlers&&this.__handlers[a]&&(a=this.__handlers[a][d?"capture":"bubble"],h=a.indexOf(h),-1<h&&a.splice(h,1))}}
function Pb(){for(var a in Ib)window.addEventListener(a,function(a){a.__target||(Nb(a),Kb(a))},!0)}function Nb(a){a.__target=a.target;a.ba=a.relatedTarget;if(r.F){var b=Object.getPrototypeOf(a);if(!b.hasOwnProperty("__patchProto")){var c=Object.create(b);c.Ja=b;ma(c,Gb);b.__patchProto=c}a.__proto__=b.__patchProto}else ma(a,Gb)}var Qb=Hb(window.Event),Rb=Hb(window.CustomEvent),Sb=Hb(window.MouseEvent);function Tb(a,b){return{index:a,H:[],L:b}}
function Ub(a,b,c,d){var e=0,f=0,g=0,h=0,k=Math.min(b-e,d-f);if(0==e&&0==f)a:{for(g=0;g<k;g++)if(a[g]!==c[g])break a;g=k}if(b==a.length&&d==c.length){h=a.length;for(var l=c.length,m=0;m<k-g&&Vb(a[--h],c[--l]);)m++;h=m}e+=g;f+=g;b-=h;d-=h;if(0==b-e&&0==d-f)return[];if(e==b){for(b=Tb(e,0);f<d;)b.H.push(c[f++]);return[b]}if(f==d)return[Tb(e,b-e)];k=e;g=f;d=d-g+1;h=b-k+1;b=Array(d);for(l=0;l<d;l++)b[l]=Array(h),b[l][0]=l;for(l=0;l<h;l++)b[0][l]=l;for(l=1;l<d;l++)for(m=1;m<h;m++)if(a[k+m-1]===c[g+l-1])b[l][m]=
b[l-1][m-1];else{var q=b[l-1][m]+1,H=b[l][m-1]+1;b[l][m]=q<H?q:H}k=b.length-1;g=b[0].length-1;d=b[k][g];for(a=[];0<k||0<g;)0==k?(a.push(2),g--):0==g?(a.push(3),k--):(h=b[k-1][g-1],l=b[k-1][g],m=b[k][g-1],q=l<m?l<h?l:h:m<h?m:h,q==h?(h==d?a.push(0):(a.push(1),d=h),k--,g--):q==l?(a.push(3),k--,d=l):(a.push(2),g--,d=m));a.reverse();b=void 0;k=[];for(g=0;g<a.length;g++)switch(a[g]){case 0:b&&(k.push(b),b=void 0);e++;f++;break;case 1:b||(b=Tb(e,0));b.L++;e++;b.H.push(c[f]);f++;break;case 2:b||(b=Tb(e,0));
b.L++;e++;break;case 3:b||(b=Tb(e,0)),b.H.push(c[f]),f++}b&&k.push(b);return k}function Vb(a,b){return a===b};var Wb={};function D(a,b,c){if(a!==Wb)throw new TypeError("Illegal constructor");a=document.createDocumentFragment();a.__proto__=D.prototype;a.ma="ShadyRoot";kb(b);kb(a);a.host=b;a.a=c&&c.mode;b.__shady=b.__shady||{};b.__shady.root=a;b.__shady.za="closed"!==a.a?a:null;a.K=!1;a.l=[];a.h={};a.C=[];c=x.childNodes(b);for(var d=0,e=c.length;d<e;d++)w.removeChild.call(b,c[d]);return a}D.prototype=Object.create(DocumentFragment.prototype);function C(a){a.K||(a.K=!0,xa(function(){return Xb(a)}))}
function Xb(a){for(var b;a;){a.K&&(b=a);a:{var c=a;a=c.host.getRootNode();if(u(a))for(var d=c.host.childNodes,e=0;e<d.length;e++)if(c=d[e],"slot"==c.localName)break a;a=void 0}}b&&b._renderRoot()}
D.prototype._renderRoot=function(){this.K=!1;rb(this);for(var a=0,b;a<this.l.length;a++){b=this.l[a];var c=b.__shady.assignedNodes;b.__shady.assignedNodes=[];b.__shady.D=[];if(b.__shady.da=c)for(var d=0;d<c.length;d++){var e=c[d];e.__shady.W=e.__shady.assignedSlot;e.__shady.assignedSlot===b&&(e.__shady.assignedSlot=null)}}for(b=this.host.firstChild;b;b=b.nextSibling)Yb(this,b);for(a=0;a<this.l.length;a++){b=this.l[a];if(!b.__shady.assignedNodes.length)for(c=b.firstChild;c;c=c.nextSibling)Yb(this,
c,b);c=b.parentNode;(c=c.__shady&&c.__shady.root)&&sb(c)&&c._renderRoot();Zb(this,b.__shady.D,b.__shady.assignedNodes);if(c=b.__shady.da){for(d=0;d<c.length;d++)c[d].__shady.W=null;b.__shady.da=null;c.length>b.__shady.assignedNodes.length&&(b.__shady.Y=!0)}b.__shady.Y&&(b.__shady.Y=!1,$b(this,b))}a=this.l;b=[];for(c=0;c<a.length;c++)d=a[c].parentNode,d.__shady&&d.__shady.root||!(0>b.indexOf(d))||b.push(d);for(a=0;a<b.length;a++){c=b[a];d=c===this?this.host:c;e=[];c=c.childNodes;for(var f=0;f<c.length;f++){var g=
c[f];if("slot"==g.localName){g=g.__shady.D;for(var h=0;h<g.length;h++)e.push(g[h])}else e.push(g)}c=void 0;f=x.childNodes(d);g=Ub(e,e.length,f,f.length);for(var k=h=0;h<g.length&&(c=g[h]);h++){for(var l=0,m;l<c.H.length&&(m=c.H[l]);l++)x.parentNode(m)===d&&w.removeChild.call(d,m),f.splice(c.index+k,1);k-=c.L}for(k=0;k<g.length&&(c=g[k]);k++)for(h=f[c.index],l=c.index;l<c.index+c.L;l++)m=e[l],w.insertBefore.call(d,m,h),f.splice(l,0,m)}};
function Yb(a,b,c){b.__shady=b.__shady||{};var d=b.__shady.W;b.__shady.W=null;c||(c=(a=a.h[b.slot||"__catchall"])&&a[0]);c?(c.__shady.assignedNodes.push(b),b.__shady.assignedSlot=c):b.__shady.assignedSlot=void 0;d!==b.__shady.assignedSlot&&b.__shady.assignedSlot&&(b.__shady.assignedSlot.__shady.Y=!0)}function Zb(a,b,c){for(var d=0,e;d<c.length&&(e=c[d]);d++)if("slot"==e.localName){var f=e.__shady.assignedNodes;f&&f.length&&Zb(a,b,f)}else b.push(c[d])}
function $b(a,b){w.dispatchEvent.call(b,new Event("slotchange"));b.__shady.assignedSlot&&$b(a,b.__shady.assignedSlot)}function rb(a){if(a.C.length){for(var b=a.C,c,d=0;d<b.length;d++){var e=b[d];e.__shady=e.__shady||{};kb(e);kb(e.parentNode);var f=ub(e);a.h[f]?(c=c||{},c[f]=!0,a.h[f].push(e)):a.h[f]=[e];a.l.push(e)}if(c)for(var g in c)a.h[g]=vb(a.h[g]);a.C=[]}}function ub(a){var b=a.name||a.getAttribute("name")||"__catchall";return a.oa=b}
function vb(a){return a.sort(function(a,c){a=ac(a);for(var b=ac(c),e=0;e<a.length;e++){c=a[e];var f=b[e];if(c!==f)return a=Array.from(c.parentNode.childNodes),a.indexOf(c)-a.indexOf(f)}})}function ac(a){var b=[];do b.unshift(a);while(a=a.parentNode);return b}function sb(a){rb(a);return!!a.l.length}D.prototype.addEventListener=function(a,b,c){"object"!==typeof c&&(c={capture:!!c});c.S=this;this.host.addEventListener(a,b,c)};
D.prototype.removeEventListener=function(a,b,c){"object"!==typeof c&&(c={capture:!!c});c.S=this;this.host.removeEventListener(a,b,c)};D.prototype.getElementById=function(a){return xb(this,function(b){return b.id==a},function(a){return!!a})[0]||null};var bc=D.prototype;A(bc,eb,!0);A(bc,gb,!0);function cc(a){var b=a.getRootNode();u(b)&&Xb(b);return a.__shady&&a.__shady.assignedSlot||null}
var dc={addEventListener:Mb.bind(window),removeEventListener:Ob.bind(window)},ec={addEventListener:Mb,removeEventListener:Ob,appendChild:function(a){return lb(this,a)},insertBefore:function(a,b){return lb(this,a,b)},removeChild:function(a){return mb(this,a)},replaceChild:function(a,b){lb(this,a,b);mb(this,b);return a},cloneNode:function(a){if("template"==this.localName)var b=w.cloneNode.call(this,a);else if(b=w.cloneNode.call(this,!1),a){a=this.childNodes;for(var c=0,d;c<a.length;c++)d=a[c].cloneNode(!0),
b.appendChild(d)}return b},getRootNode:function(){return wb(this)},contains:function(a){return ua(this,a)},get isConnected(){var a=this.ownerDocument;if(ta&&w.contains.call(a,this)||a.documentElement&&w.contains.call(a.documentElement,this))return!0;for(a=this;a&&!(a instanceof Document);)a=a.parentNode||(a instanceof D?a.host:void 0);return!!(a&&a instanceof Document)},dispatchEvent:function(a){ya();return w.dispatchEvent.call(this,a)}},fc={get assignedSlot(){return cc(this)}},gc={querySelector:function(a){return xb(this,
function(b){return la.call(b,a)},function(a){return!!a})[0]||null},querySelectorAll:function(a){return xb(this,function(b){return la.call(b,a)})}},hc={assignedNodes:function(a){if("slot"===this.localName){var b=this.getRootNode();u(b)&&Xb(b);return this.__shady?(a&&a.flatten?this.__shady.D:this.__shady.assignedNodes)||[]:[]}}},ic=na({setAttribute:function(a,b){Ab(this,a,b)},removeAttribute:function(a){w.removeAttribute.call(this,a);tb(this,a)},attachShadow:function(a){if(!this)throw"Must provide a host.";
if(!a)throw"Not enough arguments.";return new D(Wb,this,a)},get slot(){return this.getAttribute("slot")},set slot(a){Ab(this,"slot",a)},get assignedSlot(){return cc(this)}},gc,hc);Object.defineProperties(ic,fb);var jc=na({importNode:function(a,b){return Bb(a,b)},getElementById:function(a){return xb(this,function(b){return b.id==a},function(a){return!!a})[0]||null}},gc);Object.defineProperties(jc,{_activeElement:gb.activeElement});
var kc=HTMLElement.prototype.blur,lc=na({blur:function(){var a=this.__shady&&this.__shady.root;(a=a&&a.activeElement)?a.blur():kc.call(this)}});function E(a,b){for(var c=Object.getOwnPropertyNames(b),d=0;d<c.length;d++){var e=c[d],f=Object.getOwnPropertyDescriptor(b,e);f.value?a[e]=f.value:Object.defineProperty(a,e,f)}};if(r.ga){var ShadyDOM={inUse:r.ga,patch:function(a){return a},isShadyRoot:u,enqueue:xa,flush:ya,settings:r,filterMutations:Ea,observeChildren:Ca,unobserveChildren:Da,nativeMethods:w,nativeTree:x};window.ShadyDOM=ShadyDOM;window.Event=Qb;window.CustomEvent=Rb;window.MouseEvent=Sb;Pb();var mc=window.customElements&&window.customElements.nativeHTMLElement||HTMLElement;E(window.Node.prototype,ec);E(window.Window.prototype,dc);E(window.Text.prototype,fc);E(window.DocumentFragment.prototype,gc);E(window.Element.prototype,
ic);E(window.Document.prototype,jc);window.HTMLSlotElement&&E(window.HTMLSlotElement.prototype,hc);E(mc.prototype,lc);r.F&&(B(window.Node.prototype),B(window.Text.prototype),B(window.DocumentFragment.prototype),B(window.Element.prototype),B(mc.prototype),B(window.Document.prototype),window.HTMLSlotElement&&B(window.HTMLSlotElement.prototype));window.ShadowRoot=D};var nc=new Set("annotation-xml color-profile font-face font-face-src font-face-uri font-face-format font-face-name missing-glyph".split(" "));function oc(a){var b=nc.has(a);a=/^[a-z][.0-9_a-z]*-[\-.0-9_a-z]*$/.test(a);return!b&&a}function F(a){var b=a.isConnected;if(void 0!==b)return b;for(;a&&!(a.__CE_isImportDocument||a instanceof Document);)a=a.parentNode||(window.ShadowRoot&&a instanceof ShadowRoot?a.host:void 0);return!(!a||!(a.__CE_isImportDocument||a instanceof Document))}
function pc(a,b){for(;b&&b!==a&&!b.nextSibling;)b=b.parentNode;return b&&b!==a?b.nextSibling:null}
function G(a,b,c){c=void 0===c?new Set:c;for(var d=a;d;){if(d.nodeType===Node.ELEMENT_NODE){var e=d;b(e);var f=e.localName;if("link"===f&&"import"===e.getAttribute("rel")){d=e.import;if(d instanceof Node&&!c.has(d))for(c.add(d),d=d.firstChild;d;d=d.nextSibling)G(d,b,c);d=pc(a,e);continue}else if("template"===f){d=pc(a,e);continue}if(e=e.__CE_shadowRoot)for(e=e.firstChild;e;e=e.nextSibling)G(e,b,c)}d=d.firstChild?d.firstChild:pc(a,d)}}function I(a,b,c){a[b]=c};function qc(){this.a=new Map;this.u=new Map;this.i=[];this.c=!1}function rc(a,b,c){a.a.set(b,c);a.u.set(c.constructor,c)}function sc(a,b){a.c=!0;a.i.push(b)}function tc(a,b){a.c&&G(b,function(b){return a.b(b)})}qc.prototype.b=function(a){if(this.c&&!a.__CE_patched){a.__CE_patched=!0;for(var b=0;b<this.i.length;b++)this.i[b](a)}};function J(a,b){var c=[];G(b,function(a){return c.push(a)});for(b=0;b<c.length;b++){var d=c[b];1===d.__CE_state?a.connectedCallback(d):uc(a,d)}}
function K(a,b){var c=[];G(b,function(a){return c.push(a)});for(b=0;b<c.length;b++){var d=c[b];1===d.__CE_state&&a.disconnectedCallback(d)}}
function L(a,b,c){c=void 0===c?{}:c;var d=c.Ea||new Set,e=c.ia||function(b){return uc(a,b)},f=[];G(b,function(b){if("link"===b.localName&&"import"===b.getAttribute("rel")){var c=b.import;c instanceof Node&&"complete"===c.readyState?(c.__CE_isImportDocument=!0,c.__CE_hasRegistry=!0):b.addEventListener("load",function(){var c=b.import;if(!c.__CE_documentLoadHandled){c.__CE_documentLoadHandled=!0;c.__CE_isImportDocument=!0;c.__CE_hasRegistry=!0;var f=new Set(d);f.delete(c);L(a,c,{Ea:f,ia:e})}})}else f.push(b)},
d);if(a.c)for(b=0;b<f.length;b++)a.b(f[b]);for(b=0;b<f.length;b++)e(f[b])}
function uc(a,b){if(void 0===b.__CE_state){var c=a.a.get(b.localName);if(c){c.constructionStack.push(b);var d=c.constructor;try{try{if(new d!==b)throw Error("The custom element constructor did not produce the element being upgraded.");}finally{c.constructionStack.pop()}}catch(g){throw b.__CE_state=2,g;}b.__CE_state=1;b.__CE_definition=c;if(c.attributeChangedCallback)for(c=c.observedAttributes,d=0;d<c.length;d++){var e=c[d],f=b.getAttribute(e);null!==f&&a.attributeChangedCallback(b,e,null,f,null)}F(b)&&
a.connectedCallback(b)}}}qc.prototype.connectedCallback=function(a){var b=a.__CE_definition;b.connectedCallback&&b.connectedCallback.call(a)};qc.prototype.disconnectedCallback=function(a){var b=a.__CE_definition;b.disconnectedCallback&&b.disconnectedCallback.call(a)};qc.prototype.attributeChangedCallback=function(a,b,c,d,e){var f=a.__CE_definition;f.attributeChangedCallback&&-1<f.observedAttributes.indexOf(b)&&f.attributeChangedCallback.call(a,b,c,d,e)};function vc(a,b){this.g=a;this.a=b;this.w=void 0;L(this.g,this.a);"loading"===this.a.readyState&&(this.w=new MutationObserver(this.b.bind(this)),this.w.observe(this.a,{childList:!0,subtree:!0}))}function wc(a){a.w&&a.w.disconnect()}vc.prototype.b=function(a){var b=this.a.readyState;"interactive"!==b&&"complete"!==b||wc(this);for(b=0;b<a.length;b++)for(var c=a[b].addedNodes,d=0;d<c.length;d++)L(this.g,c[d])};function xc(){var a=this;this.b=this.a=void 0;this.c=new Promise(function(b){a.b=b;a.a&&b(a.a)})}function yc(a){if(a.a)throw Error("Already resolved.");a.a=void 0;a.b&&a.b(void 0)};function M(a){this.T=!1;this.g=a;this.X=new Map;this.U=function(a){return a()};this.J=!1;this.V=[];this.qa=new vc(a,document)}
M.prototype.define=function(a,b){var c=this;if(!(b instanceof Function))throw new TypeError("Custom element constructors must be functions.");if(!oc(a))throw new SyntaxError("The element name '"+a+"' is not valid.");if(this.g.a.get(a))throw Error("A custom element with name '"+a+"' has already been defined.");if(this.T)throw Error("A custom element is already being defined.");this.T=!0;try{var d=function(a){var b=e[a];if(void 0!==b&&!(b instanceof Function))throw Error("The '"+a+"' callback must be a function.");
return b},e=b.prototype;if(!(e instanceof Object))throw new TypeError("The custom element constructor's prototype is not an object.");var f=d("connectedCallback");var g=d("disconnectedCallback");var h=d("adoptedCallback");var k=d("attributeChangedCallback");var l=b.observedAttributes||[]}catch(m){return}finally{this.T=!1}b={localName:a,constructor:b,connectedCallback:f,disconnectedCallback:g,adoptedCallback:h,attributeChangedCallback:k,observedAttributes:l,constructionStack:[]};rc(this.g,a,b);this.V.push(b);
this.J||(this.J=!0,this.U(function(){return zc(c)}))};function zc(a){if(!1!==a.J){a.J=!1;for(var b=a.V,c=[],d=new Map,e=0;e<b.length;e++)d.set(b[e].localName,[]);L(a.g,document,{ia:function(b){if(void 0===b.__CE_state){var e=b.localName,f=d.get(e);f?f.push(b):a.g.a.get(e)&&c.push(b)}}});for(e=0;e<c.length;e++)uc(a.g,c[e]);for(;0<b.length;){var f=b.shift();e=f.localName;f=d.get(f.localName);for(var g=0;g<f.length;g++)uc(a.g,f[g]);(e=a.X.get(e))&&yc(e)}}}M.prototype.get=function(a){if(a=this.g.a.get(a))return a.constructor};
M.prototype.whenDefined=function(a){if(!oc(a))return Promise.reject(new SyntaxError("'"+a+"' is not a valid custom element name."));var b=this.X.get(a);if(b)return b.c;b=new xc;this.X.set(a,b);this.g.a.get(a)&&!this.V.some(function(b){return b.localName===a})&&yc(b);return b.c};M.prototype.ya=function(a){wc(this.qa);var b=this.U;this.U=function(c){return a(function(){return b(c)})}};window.CustomElementRegistry=M;M.prototype.define=M.prototype.define;M.prototype.get=M.prototype.get;
M.prototype.whenDefined=M.prototype.whenDefined;M.prototype.polyfillWrapFlushCallback=M.prototype.ya;var Ac=window.Document.prototype.createElement,Bc=window.Document.prototype.createElementNS,Cc=window.Document.prototype.importNode,Dc=window.Document.prototype.prepend,Ec=window.Document.prototype.append,Fc=window.DocumentFragment.prototype.prepend,Gc=window.DocumentFragment.prototype.append,Hc=window.Node.prototype.cloneNode,Ic=window.Node.prototype.appendChild,Jc=window.Node.prototype.insertBefore,Kc=window.Node.prototype.removeChild,Lc=window.Node.prototype.replaceChild,Mc=Object.getOwnPropertyDescriptor(window.Node.prototype,
"textContent"),Nc=window.Element.prototype.attachShadow,Oc=Object.getOwnPropertyDescriptor(window.Element.prototype,"innerHTML"),Pc=window.Element.prototype.getAttribute,Qc=window.Element.prototype.setAttribute,Rc=window.Element.prototype.removeAttribute,Sc=window.Element.prototype.getAttributeNS,Tc=window.Element.prototype.setAttributeNS,Uc=window.Element.prototype.removeAttributeNS,Vc=window.Element.prototype.insertAdjacentElement,Wc=window.Element.prototype.prepend,Xc=window.Element.prototype.append,
Yc=window.Element.prototype.before,Zc=window.Element.prototype.after,$c=window.Element.prototype.replaceWith,ad=window.Element.prototype.remove,bd=window.HTMLElement,cd=Object.getOwnPropertyDescriptor(window.HTMLElement.prototype,"innerHTML"),dd=window.HTMLElement.prototype.insertAdjacentElement;var ed=new function(){};function fd(){var a=O;window.HTMLElement=function(){function b(){var b=this.constructor,d=a.u.get(b);if(!d)throw Error("The custom element being constructed was not registered with `customElements`.");var e=d.constructionStack;if(0===e.length)return e=Ac.call(document,d.localName),Object.setPrototypeOf(e,b.prototype),e.__CE_state=1,e.__CE_definition=d,a.b(e),e;d=e.length-1;var f=e[d];if(f===ed)throw Error("The HTMLElement constructor was either called reentrantly for this constructor or called multiple times.");
e[d]=ed;Object.setPrototypeOf(f,b.prototype);a.b(f);return f}b.prototype=bd.prototype;return b}()};function gd(a,b,c){function d(b){return function(c){for(var d=[],e=0;e<arguments.length;++e)d[e-0]=arguments[e];e=[];for(var f=[],l=0;l<d.length;l++){var m=d[l];m instanceof Element&&F(m)&&f.push(m);if(m instanceof DocumentFragment)for(m=m.firstChild;m;m=m.nextSibling)e.push(m);else e.push(m)}b.apply(this,d);for(d=0;d<f.length;d++)K(a,f[d]);if(F(this))for(d=0;d<e.length;d++)f=e[d],f instanceof Element&&J(a,f)}}void 0!==c.O&&(b.prepend=d(c.O));void 0!==c.append&&(b.append=d(c.append))};function hd(){var a=O;I(Document.prototype,"createElement",function(b){if(this.__CE_hasRegistry){var c=a.a.get(b);if(c)return new c.constructor}b=Ac.call(this,b);a.b(b);return b});I(Document.prototype,"importNode",function(b,c){b=Cc.call(this,b,c);this.__CE_hasRegistry?L(a,b):tc(a,b);return b});I(Document.prototype,"createElementNS",function(b,c){if(this.__CE_hasRegistry&&(null===b||"http://www.w3.org/1999/xhtml"===b)){var d=a.a.get(c);if(d)return new d.constructor}b=Bc.call(this,b,c);a.b(b);return b});
gd(a,Document.prototype,{O:Dc,append:Ec})};function id(){var a=O;function b(b,d){Object.defineProperty(b,"textContent",{enumerable:d.enumerable,configurable:!0,get:d.get,set:function(b){if(this.nodeType===Node.TEXT_NODE)d.set.call(this,b);else{var c=void 0;if(this.firstChild){var e=this.childNodes,h=e.length;if(0<h&&F(this)){c=Array(h);for(var k=0;k<h;k++)c[k]=e[k]}}d.set.call(this,b);if(c)for(b=0;b<c.length;b++)K(a,c[b])}}})}I(Node.prototype,"insertBefore",function(b,d){if(b instanceof DocumentFragment){var c=Array.prototype.slice.apply(b.childNodes);
b=Jc.call(this,b,d);if(F(this))for(d=0;d<c.length;d++)J(a,c[d]);return b}c=F(b);d=Jc.call(this,b,d);c&&K(a,b);F(this)&&J(a,b);return d});I(Node.prototype,"appendChild",function(b){if(b instanceof DocumentFragment){var c=Array.prototype.slice.apply(b.childNodes);b=Ic.call(this,b);if(F(this))for(var e=0;e<c.length;e++)J(a,c[e]);return b}c=F(b);e=Ic.call(this,b);c&&K(a,b);F(this)&&J(a,b);return e});I(Node.prototype,"cloneNode",function(b){b=Hc.call(this,b);this.ownerDocument.__CE_hasRegistry?L(a,b):
tc(a,b);return b});I(Node.prototype,"removeChild",function(b){var c=F(b),e=Kc.call(this,b);c&&K(a,b);return e});I(Node.prototype,"replaceChild",function(b,d){if(b instanceof DocumentFragment){var c=Array.prototype.slice.apply(b.childNodes);b=Lc.call(this,b,d);if(F(this))for(K(a,d),d=0;d<c.length;d++)J(a,c[d]);return b}c=F(b);var f=Lc.call(this,b,d),g=F(this);g&&K(a,d);c&&K(a,b);g&&J(a,b);return f});Mc&&Mc.get?b(Node.prototype,Mc):sc(a,function(a){b(a,{enumerable:!0,configurable:!0,get:function(){for(var a=
[],b=0;b<this.childNodes.length;b++)a.push(this.childNodes[b].textContent);return a.join("")},set:function(a){for(;this.firstChild;)Kc.call(this,this.firstChild);Ic.call(this,document.createTextNode(a))}})})};function jd(a){var b=Element.prototype;function c(b){return function(c){for(var d=[],e=0;e<arguments.length;++e)d[e-0]=arguments[e];e=[];for(var h=[],k=0;k<d.length;k++){var l=d[k];l instanceof Element&&F(l)&&h.push(l);if(l instanceof DocumentFragment)for(l=l.firstChild;l;l=l.nextSibling)e.push(l);else e.push(l)}b.apply(this,d);for(d=0;d<h.length;d++)K(a,h[d]);if(F(this))for(d=0;d<e.length;d++)h=e[d],h instanceof Element&&J(a,h)}}void 0!==Yc&&(b.before=c(Yc));void 0!==Yc&&(b.after=c(Zc));void 0!==
$c&&I(b,"replaceWith",function(b){for(var c=[],d=0;d<arguments.length;++d)c[d-0]=arguments[d];d=[];for(var g=[],h=0;h<c.length;h++){var k=c[h];k instanceof Element&&F(k)&&g.push(k);if(k instanceof DocumentFragment)for(k=k.firstChild;k;k=k.nextSibling)d.push(k);else d.push(k)}h=F(this);$c.apply(this,c);for(c=0;c<g.length;c++)K(a,g[c]);if(h)for(K(a,this),c=0;c<d.length;c++)g=d[c],g instanceof Element&&J(a,g)});void 0!==ad&&I(b,"remove",function(){var b=F(this);ad.call(this);b&&K(a,this)})};function kd(){var a=O;function b(b,c){Object.defineProperty(b,"innerHTML",{enumerable:c.enumerable,configurable:!0,get:c.get,set:function(b){var d=this,e=void 0;F(this)&&(e=[],G(this,function(a){a!==d&&e.push(a)}));c.set.call(this,b);if(e)for(var f=0;f<e.length;f++){var g=e[f];1===g.__CE_state&&a.disconnectedCallback(g)}this.ownerDocument.__CE_hasRegistry?L(a,this):tc(a,this);return b}})}function c(b,c){I(b,"insertAdjacentElement",function(b,d){var e=F(d);b=c.call(this,b,d);e&&K(a,d);F(b)&&J(a,d);
return b})}Nc&&I(Element.prototype,"attachShadow",function(a){return this.__CE_shadowRoot=a=Nc.call(this,a)});if(Oc&&Oc.get)b(Element.prototype,Oc);else if(cd&&cd.get)b(HTMLElement.prototype,cd);else{var d=Ac.call(document,"div");sc(a,function(a){b(a,{enumerable:!0,configurable:!0,get:function(){return Hc.call(this,!0).innerHTML},set:function(a){var b="template"===this.localName?this.content:this;for(d.innerHTML=a;0<b.childNodes.length;)Kc.call(b,b.childNodes[0]);for(;0<d.childNodes.length;)Ic.call(b,
d.childNodes[0])}})})}I(Element.prototype,"setAttribute",function(b,c){if(1!==this.__CE_state)return Qc.call(this,b,c);var d=Pc.call(this,b);Qc.call(this,b,c);c=Pc.call(this,b);a.attributeChangedCallback(this,b,d,c,null)});I(Element.prototype,"setAttributeNS",function(b,c,d){if(1!==this.__CE_state)return Tc.call(this,b,c,d);var e=Sc.call(this,b,c);Tc.call(this,b,c,d);d=Sc.call(this,b,c);a.attributeChangedCallback(this,c,e,d,b)});I(Element.prototype,"removeAttribute",function(b){if(1!==this.__CE_state)return Rc.call(this,
b);var c=Pc.call(this,b);Rc.call(this,b);null!==c&&a.attributeChangedCallback(this,b,c,null,null)});I(Element.prototype,"removeAttributeNS",function(b,c){if(1!==this.__CE_state)return Uc.call(this,b,c);var d=Sc.call(this,b,c);Uc.call(this,b,c);var e=Sc.call(this,b,c);d!==e&&a.attributeChangedCallback(this,c,d,e,b)});dd?c(HTMLElement.prototype,dd):Vc?c(Element.prototype,Vc):console.warn("Custom Elements: `Element#insertAdjacentElement` was not patched.");gd(a,Element.prototype,{O:Wc,append:Xc});jd(a)}
;/*
Copyright (c) 2016 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 ld=window.customElements;if(!ld||ld.forcePolyfill||"function"!=typeof ld.define||"function"!=typeof ld.get){var O=new qc;fd();hd();gd(O,DocumentFragment.prototype,{O:Fc,append:Gc});id();kd();document.__CE_hasRegistry=!0;var customElements=new M(O);Object.defineProperty(window,"customElements",{configurable:!0,enumerable:!0,value:customElements})};/*
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 md(){this.end=this.start=0;this.rules=this.parent=this.previous=null;this.cssText=this.parsedCssText="";this.atRule=!1;this.type=0;this.parsedSelector=this.selector=this.keyframesName=""}
function nd(a){a=a.replace(od,"").replace(pd,"");var b=qd,c=a,d=new md;d.start=0;d.end=c.length;for(var e=d,f=0,g=c.length;f<g;f++)if("{"===c[f]){e.rules||(e.rules=[]);var h=e,k=h.rules[h.rules.length-1]||null;e=new md;e.start=f+1;e.parent=h;e.previous=k;h.rules.push(e)}else"}"===c[f]&&(e.end=f+1,e=e.parent||d);return b(d,a)}
function qd(a,b){var c=b.substring(a.start,a.end-1);a.parsedCssText=a.cssText=c.trim();a.parent&&(c=b.substring(a.previous?a.previous.end:a.parent.start,a.start-1),c=rd(c),c=c.replace(sd," "),c=c.substring(c.lastIndexOf(";")+1),c=a.parsedSelector=a.selector=c.trim(),a.atRule=0===c.indexOf("@"),a.atRule?0===c.indexOf("@media")?a.type=td:c.match(ud)&&(a.type=vd,a.keyframesName=a.selector.split(sd).pop()):a.type=0===c.indexOf("--")?wd:xd);if(c=a.rules)for(var d=0,e=c.length,f;d<e&&(f=c[d]);d++)qd(f,
b);return a}function rd(a){return a.replace(/\\([0-9a-f]{1,6})\s/gi,function(a,c){a=c;for(c=6-a.length;c--;)a="0"+a;return"\\"+a})}
function yd(a,b,c){c=void 0===c?"":c;var d="";if(a.cssText||a.rules){var e=a.rules,f;if(f=e)f=e[0],f=!(f&&f.selector&&0===f.selector.indexOf("--"));if(f){f=0;for(var g=e.length,h;f<g&&(h=e[f]);f++)d=yd(h,b,d)}else b?b=a.cssText:(b=a.cssText,b=b.replace(zd,"").replace(Ad,""),b=b.replace(Bd,"").replace(Cd,"")),(d=b.trim())&&(d=" "+d+"\n")}d&&(a.selector&&(c+=a.selector+" {\n"),c+=d,a.selector&&(c+="}\n\n"));return c}
var xd=1,vd=7,td=4,wd=1E3,od=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,pd=/@import[^;]*;/gim,zd=/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,Ad=/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,Bd=/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,Cd=/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,ud=/^@[^\s]*keyframes/,sd=/\s+/g;var P=!(window.ShadyDOM&&window.ShadyDOM.inUse),Dd;function Ed(a){Dd=a&&a.shimcssproperties?!1:P||!(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.nativeCss?Dd=window.ShadyCSS.nativeCss:window.ShadyCSS?(Ed(window.ShadyCSS),window.ShadyCSS=void 0):Ed(window.WebComponents&&window.WebComponents.flags);var Q=Dd;var Fd=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gi,Gd=/(?:^|\W+)@apply\s*\(?([^);\n]*)\)?/gi,Hd=/(--[\w-]+)\s*([:,;)]|$)/gi,Id=/(animation\s*:)|(animation-name\s*:)/,Jd=/@media\s(.*)/,Kd=/\{[^}]*\}/g;function R(a,b){if(!a)return"";"string"===typeof a&&(a=nd(a));b&&S(a,b);return yd(a,Q)}function Ld(a){!a.__cssRules&&a.textContent&&(a.__cssRules=nd(a.textContent));return a.__cssRules||null}function Md(a){return!!a.parent&&a.parent.type===vd}function S(a,b,c,d){if(a){var e=!1,f=a.type;if(d&&f===td){var g=a.selector.match(Jd);g&&(window.matchMedia(g[1]).matches||(e=!0))}f===xd?b(a):c&&f===vd?c(a):f===wd&&(e=!0);if((a=a.rules)&&!e){e=0;f=a.length;for(var h;e<f&&(h=a[e]);e++)S(h,b,c,d)}}}
function Nd(a,b,c,d){var e=document.createElement("style");b&&e.setAttribute("scope",b);e.textContent=a;Od(e,c,d);return e}var T=null;function Od(a,b,c){b=b||document.head;b.insertBefore(a,c&&c.nextSibling||b.firstChild);T?a.compareDocumentPosition(T)===Node.DOCUMENT_POSITION_PRECEDING&&(T=a):T=a}
function Pd(a,b){var c=a.indexOf("var(");if(-1===c)return b(a,"","","");a:{var d=0;var e=c+3;for(var f=a.length;e<f;e++)if("("===a[e])d++;else if(")"===a[e]&&0===--d)break a;e=-1}d=a.substring(c+4,e);c=a.substring(0,c);a=Pd(a.substring(e+1),b);e=d.indexOf(",");return-1===e?b(c,d.trim(),"",a):b(c,d.substring(0,e).trim(),d.substring(e+1).trim(),a)}function Qd(a,b){P?a.setAttribute("class",b):window.ShadyDOM.nativeMethods.setAttribute.call(a,"class",b)}
function U(a){var b=a.localName,c="";b?-1<b.indexOf("-")||(c=b,b=a.getAttribute&&a.getAttribute("is")||""):(b=a.is,c=a.extends);return{is:b,I:c}};function Rd(){}function Sd(a,b,c){var d=V;a.__styleScoped?a.__styleScoped=null:Td(d,a,b||"",c)}function Td(a,b,c,d){b.nodeType===Node.ELEMENT_NODE&&Ud(b,c,d);if(b="template"===b.localName?(b.content||b.Ka).childNodes:b.children||b.childNodes)for(var e=0;e<b.length;e++)Td(a,b[e],c,d)}
function Ud(a,b,c){if(b)if(a.classList)c?(a.classList.remove("style-scope"),a.classList.remove(b)):(a.classList.add("style-scope"),a.classList.add(b));else if(a.getAttribute){var d=a.getAttribute(Vd);c?d&&(b=d.replace("style-scope","").replace(b,""),Qd(a,b)):Qd(a,(d?d+" ":"")+"style-scope "+b)}}function Wd(a,b,c){var d=V,e=a.__cssBuild;P||"shady"===e?b=R(b,c):(a=U(a),b=Xd(d,b,a.is,a.I,c)+"\n\n");return b.trim()}
function Xd(a,b,c,d,e){var f=Yd(c,d);c=c?Zd+c:"";return R(b,function(b){b.c||(b.selector=b.j=$d(a,b,a.b,c,f),b.c=!0);e&&e(b,c,f)})}function Yd(a,b){return b?"[is="+a+"]":a}function $d(a,b,c,d,e){var f=b.selector.split(ae);if(!Md(b)){b=0;for(var g=f.length,h;b<g&&(h=f[b]);b++)f[b]=c.call(a,h,d,e)}return f.join(ae)}function be(a){return a.replace(ce,function(a,c,d){-1<d.indexOf("+")?d=d.replace(/\+/g,"___"):-1<d.indexOf("___")&&(d=d.replace(/___/g,"+"));return":"+c+"("+d+")"})}
Rd.prototype.b=function(a,b,c){var d=!1;a=a.trim();var e=ce.test(a);e&&(a=a.replace(ce,function(a,b,c){return":"+b+"("+c.replace(/\s/g,"")+")"}),a=be(a));a=a.replace(de,ee+" $1");a=a.replace(fe,function(a,e,h){d||(a=ge(h,e,b,c),d=d||a.stop,e=a.ta,h=a.value);return e+h});e&&(a=be(a));return a};
function ge(a,b,c,d){var e=a.indexOf(he);0<=a.indexOf(ee)?a=ie(a,d):0!==e&&(a=c?je(a,c):a);c=!1;0<=e&&(b="",c=!0);if(c){var f=!0;c&&(a=a.replace(ke,function(a,b){return" > "+b}))}a=a.replace(le,function(a,b,c){return'[dir="'+c+'"] '+b+", "+b+'[dir="'+c+'"]'});return{value:a,ta:b,stop:f}}function je(a,b){a=a.split(me);a[0]+=b;return a.join(me)}
function ie(a,b){var c=a.match(ne);return(c=c&&c[2].trim()||"")?c[0].match(oe)?a.replace(ne,function(a,c,f){return b+f}):c.split(oe)[0]===b?c:pe:a.replace(ee,b)}function qe(a){a.selector===re&&(a.selector="html")}Rd.prototype.c=function(a){return a.match(he)?this.b(a,se):je(a.trim(),se)};p.Object.defineProperties(Rd.prototype,{a:{configurable:!0,enumerable:!0,get:function(){return"style-scope"}}});
var ce=/:(nth[-\w]+)\(([^)]+)\)/,se=":not(.style-scope)",ae=",",fe=/(^|[\s>+~]+)((?:\[.+?\]|[^\s>+~=[])+)/g,oe=/[[.:#*]/,ee=":host",re=":root",he="::slotted",de=new RegExp("^("+he+")"),ne=/(:host)(?:\(((?:\([^)(]*\)|[^)(]*)+?)\))/,ke=/(?:::slotted)(?:\(((?:\([^)(]*\)|[^)(]*)+?)\))/,le=/(.*):dir\((?:(ltr|rtl))\)/,Zd=".",me=":",Vd="class",pe="should_not_match",V=new Rd;function te(a,b,c,d,e){this.s=a||null;this.b=b||null;this.Z=c||[];this.B=null;this.I=e||"";this.a=this.m=this.v=null}function W(a){return a?a.__styleInfo:null}function ue(a,b){return a.__styleInfo=b}te.prototype.c=function(){return this.s};te.prototype._getStyleRules=te.prototype.c;var ve,X=window.Element.prototype;ve=X.matches||X.matchesSelector||X.mozMatchesSelector||X.msMatchesSelector||X.oMatchesSelector||X.webkitMatchesSelector;var we=navigator.userAgent.match("Trident");function xe(){}function ye(a){var b={},c=[],d=0;S(a,function(a){ze(a);a.index=d++;a=a.f.cssText;for(var c;c=Hd.exec(a);){var e=c[1];":"!==c[2]&&(b[e]=!0)}},function(a){c.push(a)});a.b=c;a=[];for(var e in b)a.push(e);return a}
function ze(a){if(!a.f){var b={},c={};Ae(a,c)&&(b.o=c,a.rules=null);b.cssText=a.parsedCssText.replace(Kd,"").replace(Fd,"");a.f=b}}function Ae(a,b){var c=a.f;if(c){if(c.o)return Object.assign(b,c.o),!0}else{c=a.parsedCssText;for(var d;a=Fd.exec(c);){d=(a[2]||a[3]).trim();if("inherit"!==d||"unset"!==d)b[a[1].trim()]=d;d=!0}return d}}
function Be(a,b,c){b&&(b=0<=b.indexOf(";")?Ce(a,b,c):Pd(b,function(b,e,f,g){if(!e)return b+g;(e=Be(a,c[e],c))&&"initial"!==e?"apply-shim-inherit"===e&&(e="inherit"):e=Be(a,c[f]||f,c)||f;return b+(e||"")+g}));return b&&b.trim()||""}
function Ce(a,b,c){b=b.split(";");for(var d=0,e,f;d<b.length;d++)if(e=b[d]){Gd.lastIndex=0;if(f=Gd.exec(e))e=Be(a,c[f[1]],c);else if(f=e.indexOf(":"),-1!==f){var g=e.substring(f);g=g.trim();g=Be(a,g,c)||g;e=e.substring(0,f)+g}b[d]=e&&e.lastIndexOf(";")===e.length-1?e.slice(0,-1):e||""}return b.join(";")}
function De(a,b){var c={},d=[];S(a,function(a){a.f||ze(a);var e=a.j||a.parsedSelector;b&&a.f.o&&e&&ve.call(b,e)&&(Ae(a,c),a=a.index,e=parseInt(a/32,10),d[e]=(d[e]||0)|1<<a%32)},null,!0);return{o:c,key:d}}
function Ee(a,b,c,d,e){c.f||ze(c);if(c.f.o){b=U(b);a=b.is;b=b.I;b=a?Yd(a,b):"html";var f=c.parsedSelector,g=":host > *"===f||"html"===f,h=0===f.indexOf(":host")&&!g;"shady"===d&&(g=f===b+" > *."+b||-1!==f.indexOf("html"),h=!g&&0===f.indexOf(b));"shadow"===d&&(g=":host > *"===f||"html"===f,h=h&&!g);if(g||h)d=b,h&&(P&&!c.j&&(c.j=$d(V,c,V.b,a?Zd+a:"",b)),d=c.j||b),e({Ba:d,xa:h,Ma:g})}}
function Fe(a,b){var c={},d={},e=Ge,f=b&&b.__cssBuild;S(b,function(b){Ee(e,a,b,f,function(e){ve.call(a.La||a,e.Ba)&&(e.xa?Ae(b,c):Ae(b,d))})},null,!0);return{Aa:d,wa:c}}
function He(a,b,c,d){var e=U(b),f=Yd(e.is,e.I),g=new RegExp("(?:^|[^.#[:])"+(b.extends?"\\"+f.slice(0,-1)+"\\]":f)+"($|[.:[\\s>+~])");e=W(b).s;var h=Ie(e,d);return Wd(b,e,function(b){var e="";b.f||ze(b);b.f.cssText&&(e=Ce(a,b.f.cssText,c));b.cssText=e;if(!P&&!Md(b)&&b.cssText){var k=e=b.cssText;null==b.fa&&(b.fa=Id.test(e));if(b.fa)if(null==b.N){b.N=[];for(var q in h)k=h[q],k=k(e),e!==k&&(e=k,b.N.push(q))}else{for(q=0;q<b.N.length;++q)k=h[b.N[q]],e=k(e);k=e}b.cssText=k;b.j=b.j||b.selector;e="."+d;
q=b.j.split(",");k=0;for(var H=q.length,N;k<H&&(N=q[k]);k++)q[k]=N.match(g)?N.replace(f,e):e+" "+N;b.selector=q.join(",")}})}function Ie(a,b){a=a.b;var c={};if(!P&&a)for(var d=0,e=a[d];d<a.length;e=a[++d]){var f=e,g=b;f.i=new RegExp(f.keyframesName,"g");f.a=f.keyframesName+"-"+g;f.j=f.j||f.selector;f.selector=f.j.replace(f.keyframesName,f.a);c[e.keyframesName]=Je(e)}return c}function Je(a){return function(b){return b.replace(a.i,a.a)}}
function Ke(a,b){var c=Ge,d=Ld(a);a.textContent=R(d,function(a){var d=a.cssText=a.parsedCssText;a.f&&a.f.cssText&&(d=d.replace(zd,"").replace(Ad,""),a.cssText=Ce(c,d,b))})}p.Object.defineProperties(xe.prototype,{a:{configurable:!0,enumerable:!0,get:function(){return"x-scope"}}});var Ge=new xe;var Le={},Me=window.customElements;if(Me&&!P){var Ne=Me.define;Me.define=function(a,b,c){var d=document.createComment(" Shady DOM styles for "+a+" "),e=document.head;e.insertBefore(d,(T?T.nextSibling:null)||e.firstChild);T=d;Le[a]=d;return Ne.call(Me,a,b,c)}};function Oe(a){this.cache={};this.a=void 0===a?100:a}Oe.prototype.store=function(a,b,c,d){var e=this.cache[a]||[];e.push({o:b,styleElement:c,m:d});e.length>this.a&&e.shift();this.cache[a]=e};Oe.prototype.fetch=function(a,b,c){if(a=this.cache[a])for(var d=a.length-1;0<=d;d--){var e=a[d],f;a:{for(f=0;f<c.length;f++){var g=c[f];if(e.o[g]!==b[g]){f=!1;break a}}f=!0}if(f)return e}};function Pe(){}
function Qe(a){for(var b=0;b<a.length;b++){var c=a[b];if(c.target!==document.documentElement&&c.target!==document.head)for(var d=0;d<c.addedNodes.length;d++){var e=c.addedNodes[d];if(e.nodeType===Node.ELEMENT_NODE){var f=e.getRootNode();var g=e;var h=[];g.classList?h=Array.from(g.classList):g instanceof window.SVGElement&&g.hasAttribute("class")&&(h=g.getAttribute("class").split(/\s+/));g=h;h=g.indexOf(V.a);if((g=-1<h?g[h+1]:"")&&f===e.ownerDocument)Sd(e,g,!0);else if(f.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&
(f=f.host))if(f=U(f).is,g===f)for(e=window.ShadyDOM.nativeMethods.querySelectorAll.call(e,":not(."+V.a+")"),f=0;f<e.length;f++)Ud(e[f],g);else g&&Sd(e,g,!0),Sd(e,f)}}}}
if(!P){var Re=new MutationObserver(Qe),Se=function(a){Re.observe(a,{childList:!0,subtree:!0})};if(window.customElements&&!window.customElements.polyfillWrapFlushCallback)Se(document);else{var Te=function(){Se(document.body)};window.HTMLImports?window.HTMLImports.whenReady(Te):requestAnimationFrame(function(){if("loading"===document.readyState){var a=function(){Te();document.removeEventListener("readystatechange",a)};document.addEventListener("readystatechange",a)}else Te()})}Pe=function(){Qe(Re.takeRecords())}}
var Ue=Pe;var Ve={};var We=Promise.resolve();function Xe(a){if(a=Ve[a])a._applyShimCurrentVersion=a._applyShimCurrentVersion||0,a._applyShimValidatingVersion=a._applyShimValidatingVersion||0,a._applyShimNextVersion=(a._applyShimNextVersion||0)+1}function Ye(a){return a._applyShimCurrentVersion===a._applyShimNextVersion}function Ze(a){a._applyShimValidatingVersion=a._applyShimNextVersion;a.b||(a.b=!0,We.then(function(){a._applyShimCurrentVersion=a._applyShimNextVersion;a.b=!1}))};var $e=null,af=window.HTMLImports&&window.HTMLImports.whenReady||null,bf;function cf(a){requestAnimationFrame(function(){af?af(a):($e||($e=new Promise(function(a){bf=a}),"complete"===document.readyState?bf():document.addEventListener("readystatechange",function(){"complete"===document.readyState&&bf()})),$e.then(function(){a&&a()}))})};var df=new Oe;function Y(){var a=this;this.ea={};this.c=document.documentElement;var b=new md;b.rules=[];this.i=ue(this.c,new te(b));this.u=!1;this.b=this.a=null;cf(function(){ef(a)})}n=Y.prototype;n.ja=function(){Ue()};n.ua=function(a){return Ld(a)};n.Da=function(a){return R(a)};
n.prepareTemplate=function(a,b,c){if(!a.i){a.i=!0;a.name=b;a.extends=c;Ve[b]=a;var d=(d=a.content.querySelector("style"))?d.getAttribute("css-build")||"":"";var e=a.content.querySelectorAll("style");for(var f=[],g=0;g<e.length;g++){var h=e[g];f.push(h.textContent);h.parentNode.removeChild(h)}e=f.join("").trim();c={is:b,extends:c,Ia:d};P||Sd(a.content,b);ef(this);f=Gd.test(e)||Fd.test(e);Gd.lastIndex=0;Fd.lastIndex=0;e=nd(e);f&&Q&&this.a&&this.a.transformRules(e,b);a._styleAst=e;a.u=d;d=[];Q||(d=ye(a._styleAst));
if(!d.length||Q)e=P?a.content:null,b=Le[b],f=Wd(c,a._styleAst),b=f.length?Nd(f,c.is,e,b):void 0,a.a=b;a.c=d}};function ff(a){!a.b&&window.ShadyCSS&&window.ShadyCSS.CustomStyleInterface&&(a.b=window.ShadyCSS.CustomStyleInterface,a.b.transformCallback=function(b){a.ha(b)},a.b.validateCallback=function(){requestAnimationFrame(function(){(a.b.enqueued||a.u)&&a.A()})})}function ef(a){!a.a&&window.ShadyCSS&&window.ShadyCSS.ApplyShim&&(a.a=window.ShadyCSS.ApplyShim,a.a.invalidCallback=Xe);ff(a)}
n.A=function(){ef(this);if(this.b){var a=this.b.processStyles();if(this.b.enqueued){if(Q)for(var b=0;b<a.length;b++){var c=this.b.getStyleForCustomStyle(a[b]);if(c&&Q&&this.a){var d=Ld(c);ef(this);this.a.transformRules(d);c.textContent=R(d)}}else for(gf(this,this.c,this.i),b=0;b<a.length;b++)(c=this.b.getStyleForCustomStyle(a[b]))&&Ke(c,this.i.v);this.b.enqueued=!1;this.u&&!Q&&this.styleDocument()}}};
n.styleElement=function(a,b){var c=U(a).is,d=W(a);if(!d){var e=U(a);d=e.is;e=e.I;var f=Le[d];d=Ve[d];if(d){var g=d._styleAst;var h=d.c}d=ue(a,new te(g,f,h,0,e))}a!==this.c&&(this.u=!0);b&&(d.B=d.B||{},Object.assign(d.B,b));if(Q){if(d.B){b=d.B;for(var k in b)null===k?a.style.removeProperty(k):a.style.setProperty(k,b[k])}if(((k=Ve[c])||a===this.c)&&k&&k.a&&!Ye(k)){if(Ye(k)||k._applyShimValidatingVersion!==k._applyShimNextVersion)ef(this),this.a&&this.a.transformRules(k._styleAst,c),k.a.textContent=
Wd(a,d.s),Ze(k);P&&(c=a.shadowRoot)&&(c.querySelector("style").textContent=Wd(a,d.s));d.s=k._styleAst}}else if(gf(this,a,d),d.Z&&d.Z.length){c=d;k=U(a).is;d=(b=df.fetch(k,c.v,c.Z))?b.styleElement:null;g=c.m;(h=b&&b.m)||(h=this.ea[k]=(this.ea[k]||0)+1,h=k+"-"+h);c.m=h;h=c.m;e=Ge;e=d?d.textContent||"":He(e,a,c.v,h);f=W(a);var l=f.a;l&&!P&&l!==d&&(l._useCount--,0>=l._useCount&&l.parentNode&&l.parentNode.removeChild(l));P?f.a?(f.a.textContent=e,d=f.a):e&&(d=Nd(e,h,a.shadowRoot,f.b)):d?d.parentNode||(we&&
-1<e.indexOf("@media")&&(d.textContent=e),Od(d,null,f.b)):e&&(d=Nd(e,h,null,f.b));d&&(d._useCount=d._useCount||0,f.a!=d&&d._useCount++,f.a=d);h=d;P||(d=c.m,f=e=a.getAttribute("class")||"",g&&(f=e.replace(new RegExp("\\s*x-scope\\s*"+g+"\\s*","g")," ")),f+=(f?" ":"")+"x-scope "+d,e!==f&&Qd(a,f));b||df.store(k,c.v,h,c.m)}};function hf(a,b){return(b=b.getRootNode().host)?W(b)?b:hf(a,b):a.c}
function gf(a,b,c){a=hf(a,b);var d=W(a);a=Object.create(d.v||null);var e=Fe(b,c.s);b=De(d.s,b).o;Object.assign(a,e.wa,b,e.Aa);b=c.B;for(var f in b)if((e=b[f])||0===e)a[f]=e;f=Ge;b=Object.getOwnPropertyNames(a);for(e=0;e<b.length;e++)d=b[e],a[d]=Be(f,a[d],a);c.v=a}n.styleDocument=function(a){this.styleSubtree(this.c,a)};
n.styleSubtree=function(a,b){var c=a.shadowRoot;(c||a===this.c)&&this.styleElement(a,b);if(b=c&&(c.children||c.childNodes))for(a=0;a<b.length;a++)this.styleSubtree(b[a]);else if(a=a.children||a.childNodes)for(b=0;b<a.length;b++)this.styleSubtree(a[b])};n.ha=function(a){var b=this,c=Ld(a);S(c,function(a){if(P)qe(a);else{var c=V;a.selector=a.parsedSelector;qe(a);a.selector=a.j=$d(c,a,c.c,void 0,void 0)}Q&&(ef(b),b.a&&b.a.transformRule(a))});Q?a.textContent=R(c):this.i.s.rules.push(c)};
n.getComputedStyleValue=function(a,b){var c;Q||(c=(W(a)||W(hf(this,a))).v[b]);return(c=c||window.getComputedStyle(a).getPropertyValue(b))?c.trim():""};n.Ca=function(a,b){var c=a.getRootNode();b=b?b.split(/\s/):[];c=c.host&&c.host.localName;if(!c){var d=a.getAttribute("class");if(d){d=d.split(/\s/);for(var e=0;e<d.length;e++)if(d[e]===V.a){c=d[e+1];break}}}c&&b.push(V.a,c);Q||(c=W(a))&&c.m&&b.push(Ge.a,c.m);Qd(a,b.join(" "))};n.sa=function(a){return W(a)};Y.prototype.flush=Y.prototype.ja;
Y.prototype.prepareTemplate=Y.prototype.prepareTemplate;Y.prototype.styleElement=Y.prototype.styleElement;Y.prototype.styleDocument=Y.prototype.styleDocument;Y.prototype.styleSubtree=Y.prototype.styleSubtree;Y.prototype.getComputedStyleValue=Y.prototype.getComputedStyleValue;Y.prototype.setElementClass=Y.prototype.Ca;Y.prototype._styleInfoForNode=Y.prototype.sa;Y.prototype.transformCustomStyleForDocument=Y.prototype.ha;Y.prototype.getStyleAst=Y.prototype.ua;Y.prototype.styleAstToString=Y.prototype.Da;
Y.prototype.flushCustomStyles=Y.prototype.A;Object.defineProperties(Y.prototype,{nativeShadow:{get:function(){return P}},nativeCss:{get:function(){return Q}}});var Z=new Y,jf,kf;window.ShadyCSS&&(jf=window.ShadyCSS.ApplyShim,kf=window.ShadyCSS.CustomStyleInterface);window.ShadyCSS={ScopingShim:Z,prepareTemplate:function(a,b,c){Z.A();Z.prepareTemplate(a,b,c)},styleSubtree:function(a,b){Z.A();Z.styleSubtree(a,b)},styleElement:function(a){Z.A();Z.styleElement(a)},styleDocument:function(a){Z.A();Z.styleDocument(a)},getComputedStyleValue:function(a,b){return Z.getComputedStyleValue(a,b)},nativeCss:Q,nativeShadow:P};jf&&(window.ShadyCSS.ApplyShim=jf);
kf&&(window.ShadyCSS.CustomStyleInterface=kf);var lf=window.document;window.WebComponents=window.WebComponents||{};function mf(){requestAnimationFrame(function(){window.WebComponents.ready=!0;window.document.dispatchEvent(new CustomEvent("WebComponentsReady",{bubbles:!0}))})}function nf(){mf();lf.removeEventListener("readystatechange",nf)}"loading"!==lf.readyState?mf():lf.addEventListener("readystatechange",nf);}).call(this);
//# sourceMappingURL=webcomponents-sd-ce.js.map