| 1 !function(){window.WebComponents=window.WebComponents||{flags:{}};var e="webcomp
onents-lite.js",t=document.querySelector('script[src*="'+e+'"]'),n={};if(!n.noOp
ts){if(location.search.slice(1).split("&").forEach(function(e){var t,o=e.split("
=");o[0]&&(t=o[0].match(/wc-(.+)/))&&(n[t[1]]=o[1]||!0)}),t)for(var o,r=0;o=t.at
tributes[r];r++)"src"!==o.name&&(n[o.name]=o.value||!0);if(n.log&&n.log.split){v
ar i=n.log.split(",");n.log={},i.forEach(function(e){n.log[e]=!0})}else n.log={}
}n.register&&(window.CustomElements=window.CustomElements||{flags:{}},window.Cus
tomElements.flags.register=n.register),WebComponents.flags=n}(),function(e){"use
strict";function t(e){return void 0!==h[e]}function n(){s.call(this),this._isIn
valid=!0}function o(e){return""==e&&n.call(this),e.toLowerCase()}function r(e){v
ar t=e.charCodeAt(0);return t>32&&t<127&&[34,35,60,62,63,96].indexOf(t)==-1?e:en
codeURIComponent(e)}function i(e){var t=e.charCodeAt(0);return t>32&&t<127&&[34,
35,60,62,96].indexOf(t)==-1?e:encodeURIComponent(e)}function a(e,a,s){function c
(e){g.push(e)}var d=a||"scheme start",l=0,u="",w=!1,_=!1,g=[];e:for(;(e[l-1]!=p|
|0==l)&&!this._isInvalid;){var b=e[l];switch(d){case"scheme start":if(!b||!m.tes
t(b)){if(a){c("Invalid scheme.");break e}u="",d="no scheme";continue}u+=b.toLowe
rCase(),d="scheme";break;case"scheme":if(b&&v.test(b))u+=b.toLowerCase();else{if
(":"!=b){if(a){if(p==b)break e;c("Code point not allowed in scheme: "+b);break e
}u="",l=0,d="no scheme";continue}if(this._scheme=u,u="",a)break e;t(this._scheme
)&&(this._isRelative=!0),d="file"==this._scheme?"relative":this._isRelative&&s&&
s._scheme==this._scheme?"relative or authority":this._isRelative?"authority firs
t slash":"scheme data"}break;case"scheme data":"?"==b?(this._query="?",d="query"
):"#"==b?(this._fragment="#",d="fragment"):p!=b&&"\t"!=b&&"\n"!=b&&"\r"!=b&&(thi
s._schemeData+=r(b));break;case"no scheme":if(s&&t(s._scheme)){d="relative";cont
inue}c("Missing scheme."),n.call(this);break;case"relative or authority":if("/"!
=b||"/"!=e[l+1]){c("Expected /, got: "+b),d="relative";continue}d="authority ign
ore slashes";break;case"relative":if(this._isRelative=!0,"file"!=this._scheme&&(
this._scheme=s._scheme),p==b){this._host=s._host,this._port=s._port,this._path=s
._path.slice(),this._query=s._query,this._username=s._username,this._password=s.
_password;break e}if("/"==b||"\\"==b)"\\"==b&&c("\\ is an invalid code point."),
d="relative slash";else if("?"==b)this._host=s._host,this._port=s._port,this._pa
th=s._path.slice(),this._query="?",this._username=s._username,this._password=s._
password,d="query";else{if("#"!=b){var y=e[l+1],E=e[l+2];("file"!=this._scheme||
!m.test(b)||":"!=y&&"|"!=y||p!=E&&"/"!=E&&"\\"!=E&&"?"!=E&&"#"!=E)&&(this._host=
s._host,this._port=s._port,this._username=s._username,this._password=s._password
,this._path=s._path.slice(),this._path.pop()),d="relative path";continue}this._h
ost=s._host,this._port=s._port,this._path=s._path.slice(),this._query=s._query,t
his._fragment="#",this._username=s._username,this._password=s._password,d="fragm
ent"}break;case"relative slash":if("/"!=b&&"\\"!=b){"file"!=this._scheme&&(this.
_host=s._host,this._port=s._port,this._username=s._username,this._password=s._pa
ssword),d="relative path";continue}"\\"==b&&c("\\ is an invalid code point."),d=
"file"==this._scheme?"file host":"authority ignore slashes";break;case"authority
first slash":if("/"!=b){c("Expected '/', got: "+b),d="authority ignore slashes"
;continue}d="authority second slash";break;case"authority second slash":if(d="au
thority ignore slashes","/"!=b){c("Expected '/', got: "+b);continue}break;case"a
uthority ignore slashes":if("/"!=b&&"\\"!=b){d="authority";continue}c("Expected
authority, got: "+b);break;case"authority":if("@"==b){w&&(c("@ already seen."),u
+="%40"),w=!0;for(var L=0;L<u.length;L++){var N=u[L];if("\t"!=N&&"\n"!=N&&"\r"!=
N)if(":"!=N||null!==this._password){var M=r(N);null!==this._password?this._passw
ord+=M:this._username+=M}else this._password="";else c("Invalid whitespace in au
thority.")}u=""}else{if(p==b||"/"==b||"\\"==b||"?"==b||"#"==b){l-=u.length,u="",
d="host";continue}u+=b}break;case"file host":if(p==b||"/"==b||"\\"==b||"?"==b||"
#"==b){2!=u.length||!m.test(u[0])||":"!=u[1]&&"|"!=u[1]?0==u.length?d="relative
path start":(this._host=o.call(this,u),u="",d="relative path start"):d="relative
path";continue}"\t"==b||"\n"==b||"\r"==b?c("Invalid whitespace in file host."):
u+=b;break;case"host":case"hostname":if(":"!=b||_){if(p==b||"/"==b||"\\"==b||"?"
==b||"#"==b){if(this._host=o.call(this,u),u="",d="relative path start",a)break e
;continue}"\t"!=b&&"\n"!=b&&"\r"!=b?("["==b?_=!0:"]"==b&&(_=!1),u+=b):c("Invalid
code point in host/hostname: "+b)}else if(this._host=o.call(this,u),u="",d="por
t","hostname"==a)break e;break;case"port":if(/[0-9]/.test(b))u+=b;else{if(p==b||
"/"==b||"\\"==b||"?"==b||"#"==b||a){if(""!=u){var T=parseInt(u,10);T!=h[this._sc
heme]&&(this._port=T+""),u=""}if(a)break e;d="relative path start";continue}"\t"
==b||"\n"==b||"\r"==b?c("Invalid code point in port: "+b):n.call(this)}break;cas
e"relative path start":if("\\"==b&&c("'\\' not allowed in path."),d="relative pa
th","/"!=b&&"\\"!=b)continue;break;case"relative path":if(p!=b&&"/"!=b&&"\\"!=b&
&(a||"?"!=b&&"#"!=b))"\t"!=b&&"\n"!=b&&"\r"!=b&&(u+=r(b));else{"\\"==b&&c("\\ no
t allowed in relative path.");var O;(O=f[u.toLowerCase()])&&(u=O),".."==u?(this.
_path.pop(),"/"!=b&&"\\"!=b&&this._path.push("")):"."==u&&"/"!=b&&"\\"!=b?this._
path.push(""):"."!=u&&("file"==this._scheme&&0==this._path.length&&2==u.length&&
m.test(u[0])&&"|"==u[1]&&(u=u[0]+":"),this._path.push(u)),u="","?"==b?(this._que
ry="?",d="query"):"#"==b&&(this._fragment="#",d="fragment")}break;case"query":a|
|"#"!=b?p!=b&&"\t"!=b&&"\n"!=b&&"\r"!=b&&(this._query+=i(b)):(this._fragment="#"
,d="fragment");break;case"fragment":p!=b&&"\t"!=b&&"\n"!=b&&"\r"!=b&&(this._frag
ment+=b)}l++}}function s(){this._scheme="",this._schemeData="",this._username=""
,this._password=null,this._host="",this._port="",this._path=[],this._query="",th
is._fragment="",this._isInvalid=!1,this._isRelative=!1}function c(e,t){void 0===
t||t instanceof c||(t=new c(String(t))),this._url=e,s.call(this);var n=e.replace
(/^[ \t\r\n\f]+|[ \t\r\n\f]+$/g,"");a.call(this,n,null,t)}var d=!1;if(!e.forceJU
RL)try{var l=new URL("b","http://a");l.pathname="c%20d",d="http://a/c%20d"===l.h
ref}catch(u){}if(!d){var h=Object.create(null);h.ftp=21,h.file=0,h.gopher=70,h.h
ttp=80,h.https=443,h.ws=80,h.wss=443;var f=Object.create(null);f["%2e"]=".",f[".
%2e"]="..",f["%2e."]="..",f["%2e%2e"]="..";var p=void 0,m=/[a-zA-Z]/,v=/[a-zA-Z0
-9\+\-\.]/;c.prototype={toString:function(){return this.href},get href(){if(this
._isInvalid)return this._url;var e="";return""==this._username&&null==this._pass
word||(e=this._username+(null!=this._password?":"+this._password:"")+"@"),this.p
rotocol+(this._isRelative?"//"+e+this.host:"")+this.pathname+this._query+this._f
ragment},set href(e){s.call(this),a.call(this,e)},get protocol(){return this._sc
heme+":"},set protocol(e){this._isInvalid||a.call(this,e+":","scheme start")},ge
t host(){return this._isInvalid?"":this._port?this._host+":"+this._port:this._ho
st},set host(e){!this._isInvalid&&this._isRelative&&a.call(this,e,"host")},get h
ostname(){return this._host},set hostname(e){!this._isInvalid&&this._isRelative&
&a.call(this,e,"hostname")},get port(){return this._port},set port(e){!this._isI
nvalid&&this._isRelative&&a.call(this,e,"port")},get pathname(){return this._isI
nvalid?"":this._isRelative?"/"+this._path.join("/"):this._schemeData},set pathna
me(e){!this._isInvalid&&this._isRelative&&(this._path=[],a.call(this,e,"relative
path start"))},get search(){return this._isInvalid||!this._query||"?"==this._qu
ery?"":this._query},set search(e){!this._isInvalid&&this._isRelative&&(this._que
ry="?","?"==e[0]&&(e=e.slice(1)),a.call(this,e,"query"))},get hash(){return this
._isInvalid||!this._fragment||"#"==this._fragment?"":this._fragment},set hash(e)
{this._isInvalid||(this._fragment="#","#"==e[0]&&(e=e.slice(1)),a.call(this,e,"f
ragment"))},get origin(){var e;if(this._isInvalid||!this._scheme)return"";switch
(this._scheme){case"data":case"file":case"javascript":case"mailto":return"null"}
return e=this.host,e?this._scheme+"://"+e:""}};var w=e.URL;w&&(c.createObjectURL
=function(e){return w.createObjectURL.apply(w,arguments)},c.revokeObjectURL=func
tion(e){w.revokeObjectURL(e)}),e.URL=c}}(self),"undefined"==typeof WeakMap&&!fun
ction(){var e=Object.defineProperty,t=Date.now()%1e9,n=function(){this.name="__s
t"+(1e9*Math.random()>>>0)+(t++ +"__")};n.prototype={set:function(t,n){var o=t[t
his.name];return o&&o[0]===t?o[1]=n:e(t,this.name,{value:[t,n],writable:!0}),thi
s},get:function(e){var t;return(t=e[this.name])&&t[0]===e?t[1]:void 0},delete:fu
nction(e){var t=e[this.name];return!(!t||t[0]!==e)&&(t[0]=t[1]=void 0,!0)},has:f
unction(e){var t=e[this.name];return!!t&&t[0]===e}},window.WeakMap=n}(),function
(e){function t(e){b.push(e),g||(g=!0,m(o))}function n(e){return window.ShadowDOM
Polyfill&&window.ShadowDOMPolyfill.wrapIfNeeded(e)||e}function o(){g=!1;var e=b;
b=[],e.sort(function(e,t){return e.uid_-t.uid_});var t=!1;e.forEach(function(e){
var n=e.takeRecords();r(e),n.length&&(e.callback_(n,e),t=!0)}),t&&o()}function r
(e){e.nodes_.forEach(function(t){var n=v.get(t);n&&n.forEach(function(t){t.obser
ver===e&&t.removeTransientObservers()})})}function i(e,t){for(var n=e;n;n=n.pare
ntNode){var o=v.get(n);if(o)for(var r=0;r<o.length;r++){var i=o[r],a=i.options;i
f(n===e||a.subtree){var s=t(a);s&&i.enqueue(s)}}}}function a(e){this.callback_=e
,this.nodes_=[],this.records_=[],this.uid_=++y}function s(e,t){this.type=e,this.
target=t,this.addedNodes=[],this.removedNodes=[],this.previousSibling=null,this.
nextSibling=null,this.attributeName=null,this.attributeNamespace=null,this.oldVa
lue=null}function c(e){var t=new s(e.type,e.target);return t.addedNodes=e.addedN
odes.slice(),t.removedNodes=e.removedNodes.slice(),t.previousSibling=e.previousS
ibling,t.nextSibling=e.nextSibling,t.attributeName=e.attributeName,t.attributeNa
mespace=e.attributeNamespace,t.oldValue=e.oldValue,t}function d(e,t){return E=ne
w s(e,t)}function l(e){return L?L:(L=c(E),L.oldValue=e,L)}function u(){E=L=void
0}function h(e){return e===L||e===E}function f(e,t){return e===t?e:L&&h(e)?L:nul
l}function p(e,t,n){this.observer=e,this.target=t,this.options=n,this.transientO
bservedNodes=[]}if(!e.JsMutationObserver){var m,v=new WeakMap;if(/Trident|Edge/.
test(navigator.userAgent))m=setTimeout;else if(window.setImmediate)m=window.setI
mmediate;else{var w=[],_=String(Math.random());window.addEventListener("message"
,function(e){if(e.data===_){var t=w;w=[],t.forEach(function(e){e()})}}),m=functi
on(e){w.push(e),window.postMessage(_,"*")}}var g=!1,b=[],y=0;a.prototype={observ
e:function(e,t){if(e=n(e),!t.childList&&!t.attributes&&!t.characterData||t.attri
buteOldValue&&!t.attributes||t.attributeFilter&&t.attributeFilter.length&&!t.att
ributes||t.characterDataOldValue&&!t.characterData)throw new SyntaxError;var o=v
.get(e);o||v.set(e,o=[]);for(var r,i=0;i<o.length;i++)if(o[i].observer===this){r
=o[i],r.removeListeners(),r.options=t;break}r||(r=new p(this,e,t),o.push(r),this
.nodes_.push(e)),r.addListeners()},disconnect:function(){this.nodes_.forEach(fun
ction(e){for(var t=v.get(e),n=0;n<t.length;n++){var o=t[n];if(o.observer===this)
{o.removeListeners(),t.splice(n,1);break}}},this),this.records_=[]},takeRecords:
function(){var e=this.records_;return this.records_=[],e}};var E,L;p.prototype={
enqueue:function(e){var n=this.observer.records_,o=n.length;if(n.length>0){var r
=n[o-1],i=f(r,e);if(i)return void(n[o-1]=i)}else t(this.observer);n[o]=e},addLis
teners:function(){this.addListeners_(this.target)},addListeners_:function(e){var
t=this.options;t.attributes&&e.addEventListener("DOMAttrModified",this,!0),t.ch
aracterData&&e.addEventListener("DOMCharacterDataModified",this,!0),t.childList&
&e.addEventListener("DOMNodeInserted",this,!0),(t.childList||t.subtree)&&e.addEv
entListener("DOMNodeRemoved",this,!0)},removeListeners:function(){this.removeLis
teners_(this.target)},removeListeners_:function(e){var t=this.options;t.attribut
es&&e.removeEventListener("DOMAttrModified",this,!0),t.characterData&&e.removeEv
entListener("DOMCharacterDataModified",this,!0),t.childList&&e.removeEventListen
er("DOMNodeInserted",this,!0),(t.childList||t.subtree)&&e.removeEventListener("D
OMNodeRemoved",this,!0)},addTransientObserver:function(e){if(e!==this.target){th
is.addListeners_(e),this.transientObservedNodes.push(e);var t=v.get(e);t||v.set(
e,t=[]),t.push(this)}},removeTransientObservers:function(){var e=this.transientO
bservedNodes;this.transientObservedNodes=[],e.forEach(function(e){this.removeLis
teners_(e);for(var t=v.get(e),n=0;n<t.length;n++)if(t[n]===this){t.splice(n,1);b
reak}},this)},handleEvent:function(e){switch(e.stopImmediatePropagation(),e.type
){case"DOMAttrModified":var t=e.attrName,n=e.relatedNode.namespaceURI,o=e.target
,r=new d("attributes",o);r.attributeName=t,r.attributeNamespace=n;var a=e.attrCh
ange===MutationEvent.ADDITION?null:e.prevValue;i(o,function(e){if(e.attributes&&
(!e.attributeFilter||!e.attributeFilter.length||e.attributeFilter.indexOf(t)!==-
1||e.attributeFilter.indexOf(n)!==-1))return e.attributeOldValue?l(a):r});break;
case"DOMCharacterDataModified":var o=e.target,r=d("characterData",o),a=e.prevVal
ue;i(o,function(e){if(e.characterData)return e.characterDataOldValue?l(a):r});br
eak;case"DOMNodeRemoved":this.addTransientObserver(e.target);case"DOMNodeInserte
d":var s,c,h=e.target;"DOMNodeInserted"===e.type?(s=[h],c=[]):(s=[],c=[h]);var f
=h.previousSibling,p=h.nextSibling,r=d("childList",e.target.parentNode);r.addedN
odes=s,r.removedNodes=c,r.previousSibling=f,r.nextSibling=p,i(e.relatedNode,func
tion(e){if(e.childList)return r})}u()}},e.JsMutationObserver=a,e.MutationObserve
r||(e.MutationObserver=a,a._isPolyfilled=!0)}}(self),function(){function e(e){sw
itch(e){case"&":return"&";case"<":return"<";case">":return">";case" ":
return" "}}function t(t){return t.replace(u,e)}var n="undefined"==typeof HT
MLTemplateElement;/Trident/.test(navigator.userAgent)&&!function(){var e=documen
t.importNode;document.importNode=function(){var t=e.apply(document,arguments);if
(t.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var n=document.createDocumentFragment
();return n.appendChild(t),n}return t}}();var o=function(){if(!n){var e=document
.createElement("template"),t=document.createElement("template");t.content.append
Child(document.createElement("div")),e.content.appendChild(t);var o=e.cloneNode(
!0);return 0===o.content.childNodes.length||0===o.content.firstChild.content.chi
ldNodes.length}}(),r="template",i=function(){};if(n){var a=document.implementati
on.createHTMLDocument("template"),s=!0,c=document.createElement("style");c.textC
ontent=r+"{display:none;}";var d=document.head;d.insertBefore(c,d.firstElementCh
ild),i.prototype=Object.create(HTMLElement.prototype),i.decorate=function(e){if(
!e.content){e.content=a.createDocumentFragment();for(var n;n=e.firstChild;)e.con
tent.appendChild(n);if(e.cloneNode=function(e){return i.cloneNode(this,e)},s)try
{Object.defineProperty(e,"innerHTML",{get:function(){for(var e="",n=this.content
.firstChild;n;n=n.nextSibling)e+=n.outerHTML||t(n.data);return e},set:function(e
){for(a.body.innerHTML=e,i.bootstrap(a);this.content.firstChild;)this.content.re
moveChild(this.content.firstChild);for(;a.body.firstChild;)this.content.appendCh
ild(a.body.firstChild)},configurable:!0})}catch(o){s=!1}i.bootstrap(e.content)}}
,i.bootstrap=function(e){for(var t,n=e.querySelectorAll(r),o=0,a=n.length;o<a&&(
t=n[o]);o++)i.decorate(t)},document.addEventListener("DOMContentLoaded",function
(){i.bootstrap(document)});var l=document.createElement;document.createElement=f
unction(){"use strict";var e=l.apply(document,arguments);return"template"===e.lo
calName&&i.decorate(e),e};var u=/[&\u00A0<>]/g}if(n||o){var h=Node.prototype.clo
neNode;i.cloneNode=function(e,t){var n=h.call(e,!1);return this.decorate&&this.d
ecorate(n),t&&(n.content.appendChild(h.call(e.content,!0)),this.fixClonedDom(n.c
ontent,e.content)),n},i.fixClonedDom=function(e,t){if(t.querySelectorAll)for(var
n,o,i=t.querySelectorAll(r),a=e.querySelectorAll(r),s=0,c=a.length;s<c;s++)o=i[
s],n=a[s],this.decorate&&this.decorate(o),n.parentNode.replaceChild(o.cloneNode(
!0),n)};var f=document.importNode;Node.prototype.cloneNode=function(e){var t=h.c
all(this,e);return e&&i.fixClonedDom(t,this),t},document.importNode=function(e,t
){if(e.localName===r)return i.cloneNode(e,t);var n=f.call(document,e,t);return t
&&i.fixClonedDom(n,e),n},o&&(HTMLTemplateElement.prototype.cloneNode=function(e)
{return i.cloneNode(this,e)})}n&&(window.HTMLTemplateElement=i)}(),function(e){"
use strict";if(!window.performance||!window.performance.now){var t=Date.now();wi
ndow.performance={now:function(){return Date.now()-t}}}window.requestAnimationFr
ame||(window.requestAnimationFrame=function(){var e=window.webkitRequestAnimatio
nFrame||window.mozRequestAnimationFrame;return e?function(t){return e(function()
{t(performance.now())})}:function(e){return window.setTimeout(e,1e3/60)}}()),win
dow.cancelAnimationFrame||(window.cancelAnimationFrame=function(){return window.
webkitCancelAnimationFrame||window.mozCancelAnimationFrame||function(e){clearTim
eout(e)}}());var n=function(){var e=document.createEvent("Event");return e.initE
vent("foo",!0,!0),e.preventDefault(),e.defaultPrevented}();if(!n){var o=Event.pr
ototype.preventDefault;Event.prototype.preventDefault=function(){this.cancelable
&&(o.call(this),Object.defineProperty(this,"defaultPrevented",{get:function(){re
turn!0},configurable:!0}))}}var r=/Trident/.test(navigator.userAgent);if((!windo
w.CustomEvent||r&&"function"!=typeof window.CustomEvent)&&(window.CustomEvent=fu
nction(e,t){t=t||{};var n=document.createEvent("CustomEvent");return n.initCusto
mEvent(e,Boolean(t.bubbles),Boolean(t.cancelable),t.detail),n},window.CustomEven
t.prototype=window.Event.prototype),!window.Event||r&&"function"!=typeof window.
Event){var i=window.Event;window.Event=function(e,t){t=t||{};var n=document.crea
teEvent("Event");return n.initEvent(e,Boolean(t.bubbles),Boolean(t.cancelable)),
n},window.Event.prototype=i.prototype}}(window.WebComponents),window.HTMLImports
=window.HTMLImports||{flags:{}},function(e){function t(e,t){t=t||p,o(function(){
i(e,t)},t)}function n(e){return"complete"===e.readyState||e.readyState===w}funct
ion o(e,t){if(n(t))e&&e();else{var r=function(){"complete"!==t.readyState&&t.rea
dyState!==w||(t.removeEventListener(_,r),o(e,t))};t.addEventListener(_,r)}}funct
ion r(e){e.target.__loaded=!0}function i(e,t){function n(){c==d&&e&&e({allImport
s:s,loadedImports:l,errorImports:u})}function o(e){r(e),l.push(this),c++,n()}fun
ction i(e){u.push(this),c++,n()}var s=t.querySelectorAll("link[rel=import]"),c=0
,d=s.length,l=[],u=[];if(d)for(var h,f=0;f<d&&(h=s[f]);f++)a(h)?(l.push(this),c+
+,n()):(h.addEventListener("load",o),h.addEventListener("error",i));else n()}fun
ction a(e){return u?e.__loaded||e["import"]&&"loading"!==e["import"].readyState:
e.__importParsed}function s(e){for(var t,n=0,o=e.length;n<o&&(t=e[n]);n++)c(t)&&
d(t)}function c(e){return"link"===e.localName&&"import"===e.rel}function d(e){va
r t=e["import"];t?r({target:e}):(e.addEventListener("load",r),e.addEventListener
("error",r))}var l="import",u=Boolean(l in document.createElement("link")),h=Boo
lean(window.ShadowDOMPolyfill),f=function(e){return h?window.ShadowDOMPolyfill.w
rapIfNeeded(e):e},p=f(document),m={get:function(){var e=window.HTMLImports.curre
ntScript||document.currentScript||("complete"!==document.readyState?document.scr
ipts[document.scripts.length-1]:null);return f(e)},configurable:!0};Object.defin
eProperty(document,"_currentScript",m),Object.defineProperty(p,"_currentScript",
m);var v=/Trident/.test(navigator.userAgent),w=v?"complete":"interactive",_="rea
dystatechange";u&&(new MutationObserver(function(e){for(var t,n=0,o=e.length;n<o
&&(t=e[n]);n++)t.addedNodes&&s(t.addedNodes)}).observe(document.head,{childList:
!0}),function(){if("loading"===document.readyState)for(var e,t=document.querySel
ectorAll("link[rel=import]"),n=0,o=t.length;n<o&&(e=t[n]);n++)d(e)}()),t(functio
n(e){window.HTMLImports.ready=!0,window.HTMLImports.readyTime=(new Date).getTime
();var t=p.createEvent("CustomEvent");t.initCustomEvent("HTMLImportsLoaded",!0,!
0,e),p.dispatchEvent(t)}),e.IMPORT_LINK_TYPE=l,e.useNative=u,e.rootDocument=p,e.
whenReady=t,e.isIE=v}(window.HTMLImports),function(e){var t=[],n=function(e){t.p
ush(e)},o=function(){t.forEach(function(t){t(e)})};e.addModule=n,e.initializeMod
ules=o}(window.HTMLImports),window.HTMLImports.addModule(function(e){var t=/(url
\()([^)]*)(\))/g,n=/(@import[\s]+(?!url\())([^;]*)(;)/g,o={resolveUrlsInStyle:fu
nction(e,t){var n=e.ownerDocument,o=n.createElement("a");return e.textContent=th
is.resolveUrlsInCssText(e.textContent,t,o),e},resolveUrlsInCssText:function(e,o,
r){var i=this.replaceUrls(e,r,o,t);return i=this.replaceUrls(i,r,o,n)},replaceUr
ls:function(e,t,n,o){return e.replace(o,function(e,o,r,i){var a=r.replace(/["']/
g,"");return n&&(a=new URL(a,n).href),t.href=a,a=t.href,o+"'"+a+"'"+i})}};e.path
=o}),window.HTMLImports.addModule(function(e){var t={async:!0,ok:function(e){ret
urn e.status>=200&&e.status<300||304===e.status||0===e.status},load:function(n,o
,r){var i=new XMLHttpRequest;return(e.flags.debug||e.flags.bust)&&(n+="?"+Math.r
andom()),i.open("GET",n,t.async),i.addEventListener("readystatechange",function(
e){if(4===i.readyState){var n=null;try{var a=i.getResponseHeader("Location");a&&
(n="/"===a.substr(0,1)?location.origin+a:a)}catch(e){console.error(e.message)}o.
call(r,!t.ok(i)&&i,i.response||i.responseText,n)}}),i.send(),i},loadDocument:fun
ction(e,t,n){this.load(e,t,n).responseType="document"}};e.xhr=t}),window.HTMLImp
orts.addModule(function(e){var t=e.xhr,n=e.flags,o=function(e,t){this.cache={},t
his.onload=e,this.oncomplete=t,this.inflight=0,this.pending={}};o.prototype={add
Nodes:function(e){this.inflight+=e.length;for(var t,n=0,o=e.length;n<o&&(t=e[n])
;n++)this.require(t);this.checkDone()},addNode:function(e){this.inflight++,this.
require(e),this.checkDone()},require:function(e){var t=e.src||e.href;e.__nodeUrl
=t,this.dedupe(t,e)||this.fetch(t,e)},dedupe:function(e,t){if(this.pending[e])re
turn this.pending[e].push(t),!0;return this.cache[e]?(this.onload(e,t,this.cache
[e]),this.tail(),!0):(this.pending[e]=[t],!1)},fetch:function(e,o){if(n.load&&co
nsole.log("fetch",e,o),e)if(e.match(/^data:/)){var r=e.split(","),i=r[0],a=r[1];
a=i.indexOf(";base64")>-1?atob(a):decodeURIComponent(a),setTimeout(function(){th
is.receive(e,o,null,a)}.bind(this),0)}else{var s=function(t,n,r){this.receive(e,
o,t,n,r)}.bind(this);t.load(e,s)}else setTimeout(function(){this.receive(e,o,{er
ror:"href must be specified"},null)}.bind(this),0)},receive:function(e,t,n,o,r){
this.cache[e]=o;for(var i,a=this.pending[e],s=0,c=a.length;s<c&&(i=a[s]);s++)thi
s.onload(e,i,o,n,r),this.tail();this.pending[e]=null},tail:function(){--this.inf
light,this.checkDone()},checkDone:function(){this.inflight||this.oncomplete()}},
e.Loader=o}),window.HTMLImports.addModule(function(e){var t=function(e){this.add
Callback=e,this.mo=new MutationObserver(this.handler.bind(this))};t.prototype={h
andler:function(e){for(var t,n=0,o=e.length;n<o&&(t=e[n]);n++)"childList"===t.ty
pe&&t.addedNodes.length&&this.addedNodes(t.addedNodes)},addedNodes:function(e){t
his.addCallback&&this.addCallback(e);for(var t,n=0,o=e.length;n<o&&(t=e[n]);n++)
t.children&&t.children.length&&this.addedNodes(t.children)},observe:function(e){
this.mo.observe(e,{childList:!0,subtree:!0})}},e.Observer=t}),window.HTMLImports
.addModule(function(e){function t(e){return"link"===e.localName&&e.rel===l}funct
ion n(e){var t=o(e);return"data:text/javascript;charset=utf-8,"+encodeURICompone
nt(t)}function o(e){return e.textContent+r(e)}function r(e){var t=e.ownerDocumen
t;t.__importedScripts=t.__importedScripts||0;var n=e.ownerDocument.baseURI,o=t._
_importedScripts?"-"+t.__importedScripts:"";return t.__importedScripts++,"\n//#
sourceURL="+n+o+".js\n"}function i(e){var t=e.ownerDocument.createElement("style
");return t.textContent=e.textContent,a.resolveUrlsInStyle(t),t}var a=e.path,s=e
.rootDocument,c=e.flags,d=e.isIE,l=e.IMPORT_LINK_TYPE,u="link[rel="+l+"]",h={doc
umentSelectors:u,importsSelectors:[u,"link[rel=stylesheet]:not([type])","style:n
ot([type])","script:not([type])",'script[type="application/javascript"]','script
[type="text/javascript"]'].join(","),map:{link:"parseLink",script:"parseScript",
style:"parseStyle"},dynamicElements:[],parseNext:function(){var e=this.nextToPar
se();e&&this.parse(e)},parse:function(e){if(this.isParsed(e))return void(c.parse
&&console.log("[%s] is already parsed",e.localName));var t=this[this.map[e.local
Name]];t&&(this.markParsing(e),t.call(this,e))},parseDynamic:function(e,t){this.
dynamicElements.push(e),t||this.parseNext()},markParsing:function(e){c.parse&&co
nsole.log("parsing",e),this.parsingElement=e},markParsingComplete:function(e){e.
__importParsed=!0,this.markDynamicParsingComplete(e),e.__importElement&&(e.__imp
ortElement.__importParsed=!0,this.markDynamicParsingComplete(e.__importElement))
,this.parsingElement=null,c.parse&&console.log("completed",e)},markDynamicParsin
gComplete:function(e){var t=this.dynamicElements.indexOf(e);t>=0&&this.dynamicEl
ements.splice(t,1)},parseImport:function(e){if(e["import"]=e.__doc,window.HTMLIm
ports.__importsParsingHook&&window.HTMLImports.__importsParsingHook(e),e["import
"]&&(e["import"].__importParsed=!0),this.markParsingComplete(e),e.__resource&&!e
.__error?e.dispatchEvent(new CustomEvent("load",{bubbles:!1})):e.dispatchEvent(n
ew CustomEvent("error",{bubbles:!1})),e.__pending)for(var t;e.__pending.length;)
t=e.__pending.shift(),t&&t({target:e});this.parseNext()},parseLink:function(e){t
(e)?this.parseImport(e):(e.href=e.href,this.parseGeneric(e))},parseStyle:functio
n(e){var t=e;e=i(e),t.__appliedElement=e,e.__importElement=t,this.parseGeneric(e
)},parseGeneric:function(e){this.trackElement(e),this.addElementToDocument(e)},r
ootImportForElement:function(e){for(var t=e;t.ownerDocument.__importLink;)t=t.ow
nerDocument.__importLink;return t},addElementToDocument:function(e){var t=this.r
ootImportForElement(e.__importElement||e);t.parentNode.insertBefore(e,t)},trackE
lement:function(e,t){var n=this,o=function(r){e.removeEventListener("load",o),e.
removeEventListener("error",o),t&&t(r),n.markParsingComplete(e),n.parseNext()};i
f(e.addEventListener("load",o),e.addEventListener("error",o),d&&"style"===e.loca
lName){var r=!1;if(e.textContent.indexOf("@import")==-1)r=!0;else if(e.sheet){r=
!0;for(var i,a=e.sheet.cssRules,s=a?a.length:0,c=0;c<s&&(i=a[c]);c++)i.type===CS
SRule.IMPORT_RULE&&(r=r&&Boolean(i.styleSheet))}r&&setTimeout(function(){e.dispa
tchEvent(new CustomEvent("load",{bubbles:!1}))})}},parseScript:function(t){var o
=document.createElement("script");o.__importElement=t,o.src=t.src?t.src:n(t),e.c
urrentScript=t,this.trackElement(o,function(t){o.parentNode&&o.parentNode.remove
Child(o),e.currentScript=null}),this.addElementToDocument(o)},nextToParse:functi
on(){return this._mayParse=[],!this.parsingElement&&(this.nextToParseInDoc(s)||t
his.nextToParseDynamic())},nextToParseInDoc:function(e,n){if(e&&this._mayParse.i
ndexOf(e)<0){this._mayParse.push(e);for(var o,r=e.querySelectorAll(this.parseSel
ectorsForNode(e)),i=0,a=r.length;i<a&&(o=r[i]);i++)if(!this.isParsed(o))return t
his.hasResource(o)?t(o)?this.nextToParseInDoc(o.__doc,o):o:void 0}return n},next
ToParseDynamic:function(){return this.dynamicElements[0]},parseSelectorsForNode:
function(e){var t=e.ownerDocument||e;return t===s?this.documentSelectors:this.im
portsSelectors},isParsed:function(e){return e.__importParsed},needsDynamicParsin
g:function(e){return this.dynamicElements.indexOf(e)>=0},hasResource:function(e)
{return!t(e)||void 0!==e.__doc}};e.parser=h,e.IMPORT_SELECTOR=u}),window.HTMLImp
orts.addModule(function(e){function t(e){return n(e,a)}function n(e,t){return"li
nk"===e.localName&&e.getAttribute("rel")===t}function o(e){return!!Object.getOwn
PropertyDescriptor(e,"baseURI")}function r(e,t){var n=document.implementation.cr
eateHTMLDocument(a);n._URL=t;var r=n.createElement("base");r.setAttribute("href"
,t),n.baseURI||o(n)||Object.defineProperty(n,"baseURI",{value:t});var i=n.create
Element("meta");return i.setAttribute("charset","utf-8"),n.head.appendChild(i),n
.head.appendChild(r),n.body.innerHTML=e,window.HTMLTemplateElement&&HTMLTemplate
Element.bootstrap&&HTMLTemplateElement.bootstrap(n),n}var i=e.flags,a=e.IMPORT_L
INK_TYPE,s=e.IMPORT_SELECTOR,c=e.rootDocument,d=e.Loader,l=e.Observer,u=e.parser
,h={documents:{},documentPreloadSelectors:s,importsPreloadSelectors:[s].join(","
),loadNode:function(e){f.addNode(e)},loadSubtree:function(e){var t=this.marshalN
odes(e);f.addNodes(t)},marshalNodes:function(e){return e.querySelectorAll(this.l
oadSelectorsForNode(e))},loadSelectorsForNode:function(e){var t=e.ownerDocument|
|e;return t===c?this.documentPreloadSelectors:this.importsPreloadSelectors},load
ed:function(e,n,o,a,s){if(i.load&&console.log("loaded",e,n),n.__resource=o,n.__e
rror=a,t(n)){var c=this.documents[e];void 0===c&&(c=a?null:r(o,s||e),c&&(c.__imp
ortLink=n,this.bootDocument(c)),this.documents[e]=c),n.__doc=c}u.parseNext()},bo
otDocument:function(e){this.loadSubtree(e),this.observer.observe(e),u.parseNext(
)},loadedAll:function(){u.parseNext()}},f=new d(h.loaded.bind(h),h.loadedAll.bin
d(h));if(h.observer=new l,!document.baseURI){var p={get:function(){var e=documen
t.querySelector("base");return e?e.href:window.location.href},configurable:!0};O
bject.defineProperty(document,"baseURI",p),Object.defineProperty(c,"baseURI",p)}
e.importer=h,e.importLoader=f}),window.HTMLImports.addModule(function(e){var t=e
.parser,n=e.importer,o={added:function(e){for(var o,r,i,a,s=0,c=e.length;s<c&&(a
=e[s]);s++)o||(o=a.ownerDocument,r=t.isParsed(o)),i=this.shouldLoadNode(a),i&&n.
loadNode(a),this.shouldParseNode(a)&&r&&t.parseDynamic(a,i)},shouldLoadNode:func
tion(e){return 1===e.nodeType&&r.call(e,n.loadSelectorsForNode(e))},shouldParseN
ode:function(e){return 1===e.nodeType&&r.call(e,t.parseSelectorsForNode(e))}};n.
observer.addCallback=o.added.bind(o);var r=HTMLElement.prototype.matches||HTMLEl
ement.prototype.matchesSelector||HTMLElement.prototype.webkitMatchesSelector||HT
MLElement.prototype.mozMatchesSelector||HTMLElement.prototype.msMatchesSelector}
),function(e){function t(){window.HTMLImports.importer.bootDocument(o)}var n=e.i
nitializeModules;e.isIE;if(!e.useNative){n();var o=e.rootDocument;"complete"===d
ocument.readyState||"interactive"===document.readyState&&!window.attachEvent?t()
:document.addEventListener("DOMContentLoaded",t)}}(window.HTMLImports),window.Cu
stomElements=window.CustomElements||{flags:{}},function(e){var t=e.flags,n=[],o=
function(e){n.push(e)},r=function(){n.forEach(function(t){t(e)})};e.addModule=o,
e.initializeModules=r,e.hasNative=Boolean(document.registerElement),e.isIE=/Trid
ent/.test(navigator.userAgent),e.useNative=!t.register&&e.hasNative&&!window.Sha
dowDOMPolyfill&&(!window.HTMLImports||window.HTMLImports.useNative)}(window.Cust
omElements),window.CustomElements.addModule(function(e){function t(e,t){n(e,func
tion(e){return!!t(e)||void o(e,t)}),o(e,t)}function n(e,t,o){var r=e.firstElemen
tChild;if(!r)for(r=e.firstChild;r&&r.nodeType!==Node.ELEMENT_NODE;)r=r.nextSibli
ng;for(;r;)t(r,o)!==!0&&n(r,t,o),r=r.nextElementSibling;return null}function o(e
,n){for(var o=e.shadowRoot;o;)t(o,n),o=o.olderShadowRoot}function r(e,t){i(e,t,[
])}function i(e,t,n){if(e=window.wrap(e),!(n.indexOf(e)>=0)){n.push(e);for(var o
,r=e.querySelectorAll("link[rel="+a+"]"),s=0,c=r.length;s<c&&(o=r[s]);s++)o["imp
ort"]&&i(o["import"],t,n);t(e)}}var a=window.HTMLImports?window.HTMLImports.IMPO
RT_LINK_TYPE:"none";e.forDocumentTree=r,e.forSubtree=t}),window.CustomElements.a
ddModule(function(e){function t(e,t){return n(e,t)||o(e,t)}function n(t,n){retur
n!!e.upgrade(t,n)||void(n&&a(t))}function o(e,t){g(e,function(e){if(n(e,t))retur
n!0})}function r(e){L.push(e),E||(E=!0,setTimeout(i))}function i(){E=!1;for(var
e,t=L,n=0,o=t.length;n<o&&(e=t[n]);n++)e();L=[]}function a(e){y?r(function(){s(e
); | 1 !function(){window.WebComponents=window.WebComponents||{flags:{}};var e="webcomp
onents-lite.js",t=document.querySelector('script[src*="'+e+'"]'),n={};if(!n.noOp
ts){if(location.search.slice(1).split("&").forEach(function(e){var t,o=e.split("
=");o[0]&&(t=o[0].match(/wc-(.+)/))&&(n[t[1]]=o[1]||!0)}),t)for(var o,r=0;o=t.at
tributes[r];r++)"src"!==o.name&&(n[o.name]=o.value||!0);if(n.log&&n.log.split){v
ar i=n.log.split(",");n.log={},i.forEach(function(e){n.log[e]=!0})}else n.log={}
}n.register&&(window.CustomElements=window.CustomElements||{flags:{}},window.Cus
tomElements.flags.register=n.register),WebComponents.flags=n}(),function(e){"use
strict";function t(e){return void 0!==h[e]}function n(){s.call(this),this._isIn
valid=!0}function o(e){return""==e&&n.call(this),e.toLowerCase()}function r(e){v
ar t=e.charCodeAt(0);return t>32&&t<127&&[34,35,60,62,63,96].indexOf(t)==-1?e:en
codeURIComponent(e)}function i(e){var t=e.charCodeAt(0);return t>32&&t<127&&[34,
35,60,62,96].indexOf(t)==-1?e:encodeURIComponent(e)}function a(e,a,s){function c
(e){g.push(e)}var d=a||"scheme start",l=0,u="",w=!1,_=!1,g=[];e:for(;(e[l-1]!=p|
|0==l)&&!this._isInvalid;){var b=e[l];switch(d){case"scheme start":if(!b||!m.tes
t(b)){if(a){c("Invalid scheme.");break e}u="",d="no scheme";continue}u+=b.toLowe
rCase(),d="scheme";break;case"scheme":if(b&&v.test(b))u+=b.toLowerCase();else{if
(":"!=b){if(a){if(p==b)break e;c("Code point not allowed in scheme: "+b);break e
}u="",l=0,d="no scheme";continue}if(this._scheme=u,u="",a)break e;t(this._scheme
)&&(this._isRelative=!0),d="file"==this._scheme?"relative":this._isRelative&&s&&
s._scheme==this._scheme?"relative or authority":this._isRelative?"authority firs
t slash":"scheme data"}break;case"scheme data":"?"==b?(this._query="?",d="query"
):"#"==b?(this._fragment="#",d="fragment"):p!=b&&"\t"!=b&&"\n"!=b&&"\r"!=b&&(thi
s._schemeData+=r(b));break;case"no scheme":if(s&&t(s._scheme)){d="relative";cont
inue}c("Missing scheme."),n.call(this);break;case"relative or authority":if("/"!
=b||"/"!=e[l+1]){c("Expected /, got: "+b),d="relative";continue}d="authority ign
ore slashes";break;case"relative":if(this._isRelative=!0,"file"!=this._scheme&&(
this._scheme=s._scheme),p==b){this._host=s._host,this._port=s._port,this._path=s
._path.slice(),this._query=s._query,this._username=s._username,this._password=s.
_password;break e}if("/"==b||"\\"==b)"\\"==b&&c("\\ is an invalid code point."),
d="relative slash";else if("?"==b)this._host=s._host,this._port=s._port,this._pa
th=s._path.slice(),this._query="?",this._username=s._username,this._password=s._
password,d="query";else{if("#"!=b){var y=e[l+1],E=e[l+2];("file"!=this._scheme||
!m.test(b)||":"!=y&&"|"!=y||p!=E&&"/"!=E&&"\\"!=E&&"?"!=E&&"#"!=E)&&(this._host=
s._host,this._port=s._port,this._username=s._username,this._password=s._password
,this._path=s._path.slice(),this._path.pop()),d="relative path";continue}this._h
ost=s._host,this._port=s._port,this._path=s._path.slice(),this._query=s._query,t
his._fragment="#",this._username=s._username,this._password=s._password,d="fragm
ent"}break;case"relative slash":if("/"!=b&&"\\"!=b){"file"!=this._scheme&&(this.
_host=s._host,this._port=s._port,this._username=s._username,this._password=s._pa
ssword),d="relative path";continue}"\\"==b&&c("\\ is an invalid code point."),d=
"file"==this._scheme?"file host":"authority ignore slashes";break;case"authority
first slash":if("/"!=b){c("Expected '/', got: "+b),d="authority ignore slashes"
;continue}d="authority second slash";break;case"authority second slash":if(d="au
thority ignore slashes","/"!=b){c("Expected '/', got: "+b);continue}break;case"a
uthority ignore slashes":if("/"!=b&&"\\"!=b){d="authority";continue}c("Expected
authority, got: "+b);break;case"authority":if("@"==b){w&&(c("@ already seen."),u
+="%40"),w=!0;for(var L=0;L<u.length;L++){var N=u[L];if("\t"!=N&&"\n"!=N&&"\r"!=
N)if(":"!=N||null!==this._password){var M=r(N);null!==this._password?this._passw
ord+=M:this._username+=M}else this._password="";else c("Invalid whitespace in au
thority.")}u=""}else{if(p==b||"/"==b||"\\"==b||"?"==b||"#"==b){l-=u.length,u="",
d="host";continue}u+=b}break;case"file host":if(p==b||"/"==b||"\\"==b||"?"==b||"
#"==b){2!=u.length||!m.test(u[0])||":"!=u[1]&&"|"!=u[1]?0==u.length?d="relative
path start":(this._host=o.call(this,u),u="",d="relative path start"):d="relative
path";continue}"\t"==b||"\n"==b||"\r"==b?c("Invalid whitespace in file host."):
u+=b;break;case"host":case"hostname":if(":"!=b||_){if(p==b||"/"==b||"\\"==b||"?"
==b||"#"==b){if(this._host=o.call(this,u),u="",d="relative path start",a)break e
;continue}"\t"!=b&&"\n"!=b&&"\r"!=b?("["==b?_=!0:"]"==b&&(_=!1),u+=b):c("Invalid
code point in host/hostname: "+b)}else if(this._host=o.call(this,u),u="",d="por
t","hostname"==a)break e;break;case"port":if(/[0-9]/.test(b))u+=b;else{if(p==b||
"/"==b||"\\"==b||"?"==b||"#"==b||a){if(""!=u){var T=parseInt(u,10);T!=h[this._sc
heme]&&(this._port=T+""),u=""}if(a)break e;d="relative path start";continue}"\t"
==b||"\n"==b||"\r"==b?c("Invalid code point in port: "+b):n.call(this)}break;cas
e"relative path start":if("\\"==b&&c("'\\' not allowed in path."),d="relative pa
th","/"!=b&&"\\"!=b)continue;break;case"relative path":if(p!=b&&"/"!=b&&"\\"!=b&
&(a||"?"!=b&&"#"!=b))"\t"!=b&&"\n"!=b&&"\r"!=b&&(u+=r(b));else{"\\"==b&&c("\\ no
t allowed in relative path.");var O;(O=f[u.toLowerCase()])&&(u=O),".."==u?(this.
_path.pop(),"/"!=b&&"\\"!=b&&this._path.push("")):"."==u&&"/"!=b&&"\\"!=b?this._
path.push(""):"."!=u&&("file"==this._scheme&&0==this._path.length&&2==u.length&&
m.test(u[0])&&"|"==u[1]&&(u=u[0]+":"),this._path.push(u)),u="","?"==b?(this._que
ry="?",d="query"):"#"==b&&(this._fragment="#",d="fragment")}break;case"query":a|
|"#"!=b?p!=b&&"\t"!=b&&"\n"!=b&&"\r"!=b&&(this._query+=i(b)):(this._fragment="#"
,d="fragment");break;case"fragment":p!=b&&"\t"!=b&&"\n"!=b&&"\r"!=b&&(this._frag
ment+=b)}l++}}function s(){this._scheme="",this._schemeData="",this._username=""
,this._password=null,this._host="",this._port="",this._path=[],this._query="",th
is._fragment="",this._isInvalid=!1,this._isRelative=!1}function c(e,t){void 0===
t||t instanceof c||(t=new c(String(t))),this._url=e,s.call(this);var n=e.replace
(/^[ \t\r\n\f]+|[ \t\r\n\f]+$/g,"");a.call(this,n,null,t)}var d=!1;if(!e.forceJU
RL)try{var l=new URL("b","http://a");l.pathname="c%20d",d="http://a/c%20d"===l.h
ref}catch(u){}if(!d){var h=Object.create(null);h.ftp=21,h.file=0,h.gopher=70,h.h
ttp=80,h.https=443,h.ws=80,h.wss=443;var f=Object.create(null);f["%2e"]=".",f[".
%2e"]="..",f["%2e."]="..",f["%2e%2e"]="..";var p=void 0,m=/[a-zA-Z]/,v=/[a-zA-Z0
-9\+\-\.]/;c.prototype={toString:function(){return this.href},get href(){if(this
._isInvalid)return this._url;var e="";return""==this._username&&null==this._pass
word||(e=this._username+(null!=this._password?":"+this._password:"")+"@"),this.p
rotocol+(this._isRelative?"//"+e+this.host:"")+this.pathname+this._query+this._f
ragment},set href(e){s.call(this),a.call(this,e)},get protocol(){return this._sc
heme+":"},set protocol(e){this._isInvalid||a.call(this,e+":","scheme start")},ge
t host(){return this._isInvalid?"":this._port?this._host+":"+this._port:this._ho
st},set host(e){!this._isInvalid&&this._isRelative&&a.call(this,e,"host")},get h
ostname(){return this._host},set hostname(e){!this._isInvalid&&this._isRelative&
&a.call(this,e,"hostname")},get port(){return this._port},set port(e){!this._isI
nvalid&&this._isRelative&&a.call(this,e,"port")},get pathname(){return this._isI
nvalid?"":this._isRelative?"/"+this._path.join("/"):this._schemeData},set pathna
me(e){!this._isInvalid&&this._isRelative&&(this._path=[],a.call(this,e,"relative
path start"))},get search(){return this._isInvalid||!this._query||"?"==this._qu
ery?"":this._query},set search(e){!this._isInvalid&&this._isRelative&&(this._que
ry="?","?"==e[0]&&(e=e.slice(1)),a.call(this,e,"query"))},get hash(){return this
._isInvalid||!this._fragment||"#"==this._fragment?"":this._fragment},set hash(e)
{this._isInvalid||(this._fragment="#","#"==e[0]&&(e=e.slice(1)),a.call(this,e,"f
ragment"))},get origin(){var e;if(this._isInvalid||!this._scheme)return"";switch
(this._scheme){case"data":case"file":case"javascript":case"mailto":return"null"}
return e=this.host,e?this._scheme+"://"+e:""}};var w=e.URL;w&&(c.createObjectURL
=function(e){return w.createObjectURL.apply(w,arguments)},c.revokeObjectURL=func
tion(e){w.revokeObjectURL(e)}),e.URL=c}}(self),"undefined"==typeof WeakMap&&!fun
ction(){var e=Object.defineProperty,t=Date.now()%1e9,n=function(){this.name="__s
t"+(1e9*Math.random()>>>0)+(t+++"__")};n.prototype={set:function(t,n){var o=t[th
is.name];return o&&o[0]===t?o[1]=n:e(t,this.name,{value:[t,n],writable:!0}),this
},get:function(e){var t;return(t=e[this.name])&&t[0]===e?t[1]:void 0},delete:fun
ction(e){var t=e[this.name];return!(!t||t[0]!==e)&&(t[0]=t[1]=void 0,!0)},has:fu
nction(e){var t=e[this.name];return!!t&&t[0]===e}},window.WeakMap=n}(),function(
e){function t(e){b.push(e),g||(g=!0,m(o))}function n(e){return window.ShadowDOMP
olyfill&&window.ShadowDOMPolyfill.wrapIfNeeded(e)||e}function o(){g=!1;var e=b;b
=[],e.sort(function(e,t){return e.uid_-t.uid_});var t=!1;e.forEach(function(e){v
ar n=e.takeRecords();r(e),n.length&&(e.callback_(n,e),t=!0)}),t&&o()}function r(
e){e.nodes_.forEach(function(t){var n=v.get(t);n&&n.forEach(function(t){t.observ
er===e&&t.removeTransientObservers()})})}function i(e,t){for(var n=e;n;n=n.paren
tNode){var o=v.get(n);if(o)for(var r=0;r<o.length;r++){var i=o[r],a=i.options;if
(n===e||a.subtree){var s=t(a);s&&i.enqueue(s)}}}}function a(e){this.callback_=e,
this.nodes_=[],this.records_=[],this.uid_=++y}function s(e,t){this.type=e,this.t
arget=t,this.addedNodes=[],this.removedNodes=[],this.previousSibling=null,this.n
extSibling=null,this.attributeName=null,this.attributeNamespace=null,this.oldVal
ue=null}function c(e){var t=new s(e.type,e.target);return t.addedNodes=e.addedNo
des.slice(),t.removedNodes=e.removedNodes.slice(),t.previousSibling=e.previousSi
bling,t.nextSibling=e.nextSibling,t.attributeName=e.attributeName,t.attributeNam
espace=e.attributeNamespace,t.oldValue=e.oldValue,t}function d(e,t){return E=new
s(e,t)}function l(e){return L?L:(L=c(E),L.oldValue=e,L)}function u(){E=L=void 0
}function h(e){return e===L||e===E}function f(e,t){return e===t?e:L&&h(e)?L:null
}function p(e,t,n){this.observer=e,this.target=t,this.options=n,this.transientOb
servedNodes=[]}if(!e.JsMutationObserver){var m,v=new WeakMap;if(/Trident|Edge/.t
est(navigator.userAgent))m=setTimeout;else if(window.setImmediate)m=window.setIm
mediate;else{var w=[],_=String(Math.random());window.addEventListener("message",
function(e){if(e.data===_){var t=w;w=[],t.forEach(function(e){e()})}}),m=functio
n(e){w.push(e),window.postMessage(_,"*")}}var g=!1,b=[],y=0;a.prototype={observe
:function(e,t){if(e=n(e),!t.childList&&!t.attributes&&!t.characterData||t.attrib
uteOldValue&&!t.attributes||t.attributeFilter&&t.attributeFilter.length&&!t.attr
ibutes||t.characterDataOldValue&&!t.characterData)throw new SyntaxError;var o=v.
get(e);o||v.set(e,o=[]);for(var r,i=0;i<o.length;i++)if(o[i].observer===this){r=
o[i],r.removeListeners(),r.options=t;break}r||(r=new p(this,e,t),o.push(r),this.
nodes_.push(e)),r.addListeners()},disconnect:function(){this.nodes_.forEach(func
tion(e){for(var t=v.get(e),n=0;n<t.length;n++){var o=t[n];if(o.observer===this){
o.removeListeners(),t.splice(n,1);break}}},this),this.records_=[]},takeRecords:f
unction(){var e=this.records_;return this.records_=[],e}};var E,L;p.prototype={e
nqueue:function(e){var n=this.observer.records_,o=n.length;if(n.length>0){var r=
n[o-1],i=f(r,e);if(i)return void(n[o-1]=i)}else t(this.observer);n[o]=e},addList
eners:function(){this.addListeners_(this.target)},addListeners_:function(e){var
t=this.options;t.attributes&&e.addEventListener("DOMAttrModified",this,!0),t.cha
racterData&&e.addEventListener("DOMCharacterDataModified",this,!0),t.childList&&
e.addEventListener("DOMNodeInserted",this,!0),(t.childList||t.subtree)&&e.addEve
ntListener("DOMNodeRemoved",this,!0)},removeListeners:function(){this.removeList
eners_(this.target)},removeListeners_:function(e){var t=this.options;t.attribute
s&&e.removeEventListener("DOMAttrModified",this,!0),t.characterData&&e.removeEve
ntListener("DOMCharacterDataModified",this,!0),t.childList&&e.removeEventListene
r("DOMNodeInserted",this,!0),(t.childList||t.subtree)&&e.removeEventListener("DO
MNodeRemoved",this,!0)},addTransientObserver:function(e){if(e!==this.target){thi
s.addListeners_(e),this.transientObservedNodes.push(e);var t=v.get(e);t||v.set(e
,t=[]),t.push(this)}},removeTransientObservers:function(){var e=this.transientOb
servedNodes;this.transientObservedNodes=[],e.forEach(function(e){this.removeList
eners_(e);for(var t=v.get(e),n=0;n<t.length;n++)if(t[n]===this){t.splice(n,1);br
eak}},this)},handleEvent:function(e){switch(e.stopImmediatePropagation(),e.type)
{case"DOMAttrModified":var t=e.attrName,n=e.relatedNode.namespaceURI,o=e.target,
r=new d("attributes",o);r.attributeName=t,r.attributeNamespace=n;var a=e.attrCha
nge===MutationEvent.ADDITION?null:e.prevValue;i(o,function(e){if(e.attributes&&(
!e.attributeFilter||!e.attributeFilter.length||e.attributeFilter.indexOf(t)!==-1
||e.attributeFilter.indexOf(n)!==-1))return e.attributeOldValue?l(a):r});break;c
ase"DOMCharacterDataModified":var o=e.target,r=d("characterData",o),a=e.prevValu
e;i(o,function(e){if(e.characterData)return e.characterDataOldValue?l(a):r});bre
ak;case"DOMNodeRemoved":this.addTransientObserver(e.target);case"DOMNodeInserted
":var s,c,h=e.target;"DOMNodeInserted"===e.type?(s=[h],c=[]):(s=[],c=[h]);var f=
h.previousSibling,p=h.nextSibling,r=d("childList",e.target.parentNode);r.addedNo
des=s,r.removedNodes=c,r.previousSibling=f,r.nextSibling=p,i(e.relatedNode,funct
ion(e){if(e.childList)return r})}u()}},e.JsMutationObserver=a,e.MutationObserver
||(e.MutationObserver=a,a._isPolyfilled=!0)}}(self),function(){function e(e){swi
tch(e){case"&":return"&";case"<":return"<";case">":return">";case" ":r
eturn" "}}function t(t){return t.replace(u,e)}var n="undefined"==typeof HTM
LTemplateElement;/Trident/.test(navigator.userAgent)&&!function(){var e=document
.importNode;document.importNode=function(){var t=e.apply(document,arguments);if(
t.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var n=document.createDocumentFragment(
);return n.appendChild(t),n}return t}}();var o=function(){if(!n){var e=document.
createElement("template"),t=document.createElement("template");t.content.appendC
hild(document.createElement("div")),e.content.appendChild(t);var o=e.cloneNode(!
0);return 0===o.content.childNodes.length||0===o.content.firstChild.content.chil
dNodes.length}}(),r="template",i=function(){};if(n){var a=document.implementatio
n.createHTMLDocument("template"),s=!0,c=document.createElement("style");c.textCo
ntent=r+"{display:none;}";var d=document.head;d.insertBefore(c,d.firstElementChi
ld),i.prototype=Object.create(HTMLElement.prototype),i.decorate=function(e){if(!
e.content){e.content=a.createDocumentFragment();for(var n;n=e.firstChild;)e.cont
ent.appendChild(n);if(e.cloneNode=function(e){return i.cloneNode(this,e)},s)try{
Object.defineProperty(e,"innerHTML",{get:function(){for(var e="",n=this.content.
firstChild;n;n=n.nextSibling)e+=n.outerHTML||t(n.data);return e},set:function(e)
{for(a.body.innerHTML=e,i.bootstrap(a);this.content.firstChild;)this.content.rem
oveChild(this.content.firstChild);for(;a.body.firstChild;)this.content.appendChi
ld(a.body.firstChild)},configurable:!0})}catch(o){s=!1}i.bootstrap(e.content)}},
i.bootstrap=function(e){for(var t,n=e.querySelectorAll(r),o=0,a=n.length;o<a&&(t
=n[o]);o++)i.decorate(t)},document.addEventListener("DOMContentLoaded",function(
){i.bootstrap(document)});var l=document.createElement;document.createElement=fu
nction(){"use strict";var e=l.apply(document,arguments);return"template"===e.loc
alName&&i.decorate(e),e};var u=/[&\u00A0<>]/g}if(n||o){var h=Node.prototype.clon
eNode;i.cloneNode=function(e,t){var n=h.call(e,!1);return this.decorate&&this.de
corate(n),t&&(n.content.appendChild(h.call(e.content,!0)),this.fixClonedDom(n.co
ntent,e.content)),n},i.fixClonedDom=function(e,t){if(t.querySelectorAll)for(var
n,o,i=t.querySelectorAll(r),a=e.querySelectorAll(r),s=0,c=a.length;s<c;s++)o=i[s
],n=a[s],this.decorate&&this.decorate(o),n.parentNode.replaceChild(o.cloneNode(!
0),n)};var f=document.importNode;Node.prototype.cloneNode=function(e){var t=h.ca
ll(this,e);return e&&i.fixClonedDom(t,this),t},document.importNode=function(e,t)
{if(e.localName===r)return i.cloneNode(e,t);var n=f.call(document,e,t);return t&
&i.fixClonedDom(n,e),n},o&&(HTMLTemplateElement.prototype.cloneNode=function(e){
return i.cloneNode(this,e)})}n&&(window.HTMLTemplateElement=i)}(),function(e){"u
se strict";if(!window.performance||!window.performance.now){var t=Date.now();win
dow.performance={now:function(){return Date.now()-t}}}window.requestAnimationFra
me||(window.requestAnimationFrame=function(){var e=window.webkitRequestAnimation
Frame||window.mozRequestAnimationFrame;return e?function(t){return e(function(){
t(performance.now())})}:function(e){return window.setTimeout(e,1e3/60)}}()),wind
ow.cancelAnimationFrame||(window.cancelAnimationFrame=function(){return window.w
ebkitCancelAnimationFrame||window.mozCancelAnimationFrame||function(e){clearTime
out(e)}}());var n=function(){var e=document.createEvent("Event");return e.initEv
ent("foo",!0,!0),e.preventDefault(),e.defaultPrevented}();if(!n){var o=Event.pro
totype.preventDefault;Event.prototype.preventDefault=function(){this.cancelable&
&(o.call(this),Object.defineProperty(this,"defaultPrevented",{get:function(){ret
urn!0},configurable:!0}))}}var r=/Trident/.test(navigator.userAgent);if((!window
.CustomEvent||r&&"function"!=typeof window.CustomEvent)&&(window.CustomEvent=fun
ction(e,t){t=t||{};var n=document.createEvent("CustomEvent");return n.initCustom
Event(e,Boolean(t.bubbles),Boolean(t.cancelable),t.detail),n},window.CustomEvent
.prototype=window.Event.prototype),!window.Event||r&&"function"!=typeof window.E
vent){var i=window.Event;window.Event=function(e,t){t=t||{};var n=document.creat
eEvent("Event");return n.initEvent(e,Boolean(t.bubbles),Boolean(t.cancelable)),n
},window.Event.prototype=i.prototype}}(window.WebComponents),window.HTMLImports=
window.HTMLImports||{flags:{}},function(e){function t(e,t){t=t||p,o(function(){i
(e,t)},t)}function n(e){return"complete"===e.readyState||e.readyState===w}functi
on o(e,t){if(n(t))e&&e();else{var r=function(){"complete"!==t.readyState&&t.read
yState!==w||(t.removeEventListener(_,r),o(e,t))};t.addEventListener(_,r)}}functi
on r(e){e.target.__loaded=!0}function i(e,t){function n(){c==d&&e&&e({allImports
:s,loadedImports:l,errorImports:u})}function o(e){r(e),l.push(this),c++,n()}func
tion i(e){u.push(this),c++,n()}var s=t.querySelectorAll("link[rel=import]"),c=0,
d=s.length,l=[],u=[];if(d)for(var h,f=0;f<d&&(h=s[f]);f++)a(h)?(l.push(this),c++
,n()):(h.addEventListener("load",o),h.addEventListener("error",i));else n()}func
tion a(e){return u?e.__loaded||e["import"]&&"loading"!==e["import"].readyState:e
.__importParsed}function s(e){for(var t,n=0,o=e.length;n<o&&(t=e[n]);n++)c(t)&&d
(t)}function c(e){return"link"===e.localName&&"import"===e.rel}function d(e){var
t=e["import"];t?r({target:e}):(e.addEventListener("load",r),e.addEventListener(
"error",r))}var l="import",u=Boolean(l in document.createElement("link")),h=Bool
ean(window.ShadowDOMPolyfill),f=function(e){return h?window.ShadowDOMPolyfill.wr
apIfNeeded(e):e},p=f(document),m={get:function(){var e=window.HTMLImports.curren
tScript||document.currentScript||("complete"!==document.readyState?document.scri
pts[document.scripts.length-1]:null);return f(e)},configurable:!0};Object.define
Property(document,"_currentScript",m),Object.defineProperty(p,"_currentScript",m
);var v=/Trident/.test(navigator.userAgent),w=v?"complete":"interactive",_="read
ystatechange";u&&(new MutationObserver(function(e){for(var t,n=0,o=e.length;n<o&
&(t=e[n]);n++)t.addedNodes&&s(t.addedNodes)}).observe(document.head,{childList:!
0}),function(){if("loading"===document.readyState)for(var e,t=document.querySele
ctorAll("link[rel=import]"),n=0,o=t.length;n<o&&(e=t[n]);n++)d(e)}()),t(function
(e){window.HTMLImports.ready=!0,window.HTMLImports.readyTime=(new Date).getTime(
);var t=p.createEvent("CustomEvent");t.initCustomEvent("HTMLImportsLoaded",!0,!0
,e),p.dispatchEvent(t)}),e.IMPORT_LINK_TYPE=l,e.useNative=u,e.rootDocument=p,e.w
henReady=t,e.isIE=v}(window.HTMLImports),function(e){var t=[],n=function(e){t.pu
sh(e)},o=function(){t.forEach(function(t){t(e)})};e.addModule=n,e.initializeModu
les=o}(window.HTMLImports),window.HTMLImports.addModule(function(e){var t=/(url\
()([^)]*)(\))/g,n=/(@import[\s]+(?!url\())([^;]*)(;)/g,o={resolveUrlsInStyle:fun
ction(e,t){var n=e.ownerDocument,o=n.createElement("a");return e.textContent=thi
s.resolveUrlsInCssText(e.textContent,t,o),e},resolveUrlsInCssText:function(e,o,r
){var i=this.replaceUrls(e,r,o,t);return i=this.replaceUrls(i,r,o,n)},replaceUrl
s:function(e,t,n,o){return e.replace(o,function(e,o,r,i){var a=r.replace(/["']/g
,"");return n&&(a=new URL(a,n).href),t.href=a,a=t.href,o+"'"+a+"'"+i})}};e.path=
o}),window.HTMLImports.addModule(function(e){var t={async:!0,ok:function(e){retu
rn e.status>=200&&e.status<300||304===e.status||0===e.status},load:function(n,o,
r){var i=new XMLHttpRequest;return(e.flags.debug||e.flags.bust)&&(n+="?"+Math.ra
ndom()),i.open("GET",n,t.async),i.addEventListener("readystatechange",function(e
){if(4===i.readyState){var n=null;try{var a=i.getResponseHeader("Location");a&&(
n="/"===a.substr(0,1)?location.origin+a:a)}catch(e){console.error(e.message)}o.c
all(r,!t.ok(i)&&i,i.response||i.responseText,n)}}),i.send(),i},loadDocument:func
tion(e,t,n){this.load(e,t,n).responseType="document"}};e.xhr=t}),window.HTMLImpo
rts.addModule(function(e){var t=e.xhr,n=e.flags,o=function(e,t){this.cache={},th
is.onload=e,this.oncomplete=t,this.inflight=0,this.pending={}};o.prototype={addN
odes:function(e){this.inflight+=e.length;for(var t,n=0,o=e.length;n<o&&(t=e[n]);
n++)this.require(t);this.checkDone()},addNode:function(e){this.inflight++,this.r
equire(e),this.checkDone()},require:function(e){var t=e.src||e.href;e.__nodeUrl=
t,this.dedupe(t,e)||this.fetch(t,e)},dedupe:function(e,t){if(this.pending[e])ret
urn this.pending[e].push(t),!0;return this.cache[e]?(this.onload(e,t,this.cache[
e]),this.tail(),!0):(this.pending[e]=[t],!1)},fetch:function(e,o){if(n.load&&con
sole.log("fetch",e,o),e)if(e.match(/^data:/)){var r=e.split(","),i=r[0],a=r[1];a
=i.indexOf(";base64")>-1?atob(a):decodeURIComponent(a),setTimeout(function(){thi
s.receive(e,o,null,a)}.bind(this),0)}else{var s=function(t,n,r){this.receive(e,o
,t,n,r)}.bind(this);t.load(e,s)}else setTimeout(function(){this.receive(e,o,{err
or:"href must be specified"},null)}.bind(this),0)},receive:function(e,t,n,o,r){t
his.cache[e]=o;for(var i,a=this.pending[e],s=0,c=a.length;s<c&&(i=a[s]);s++)this
.onload(e,i,o,n,r),this.tail();this.pending[e]=null},tail:function(){--this.infl
ight,this.checkDone()},checkDone:function(){this.inflight||this.oncomplete()}},e
.Loader=o}),window.HTMLImports.addModule(function(e){var t=function(e){this.addC
allback=e,this.mo=new MutationObserver(this.handler.bind(this))};t.prototype={ha
ndler:function(e){for(var t,n=0,o=e.length;n<o&&(t=e[n]);n++)"childList"===t.typ
e&&t.addedNodes.length&&this.addedNodes(t.addedNodes)},addedNodes:function(e){th
is.addCallback&&this.addCallback(e);for(var t,n=0,o=e.length;n<o&&(t=e[n]);n++)t
.children&&t.children.length&&this.addedNodes(t.children)},observe:function(e){t
his.mo.observe(e,{childList:!0,subtree:!0})}},e.Observer=t}),window.HTMLImports.
addModule(function(e){function t(e){return"link"===e.localName&&e.rel===l}functi
on n(e){var t=o(e);return"data:text/javascript;charset=utf-8,"+encodeURIComponen
t(t)}function o(e){return e.textContent+r(e)}function r(e){var t=e.ownerDocument
;t.__importedScripts=t.__importedScripts||0;var n=e.ownerDocument.baseURI,o=t.__
importedScripts?"-"+t.__importedScripts:"";return t.__importedScripts++,"\n//# s
ourceURL="+n+o+".js\n"}function i(e){var t=e.ownerDocument.createElement("style"
);return t.textContent=e.textContent,a.resolveUrlsInStyle(t),t}var a=e.path,s=e.
rootDocument,c=e.flags,d=e.isIE,l=e.IMPORT_LINK_TYPE,u="link[rel="+l+"]",h={docu
mentSelectors:u,importsSelectors:[u,"link[rel=stylesheet]:not([type])","style:no
t([type])","script:not([type])",'script[type="application/javascript"]','script[
type="text/javascript"]'].join(","),map:{link:"parseLink",script:"parseScript",s
tyle:"parseStyle"},dynamicElements:[],parseNext:function(){var e=this.nextToPars
e();e&&this.parse(e)},parse:function(e){if(this.isParsed(e))return void(c.parse&
&console.log("[%s] is already parsed",e.localName));var t=this[this.map[e.localN
ame]];t&&(this.markParsing(e),t.call(this,e))},parseDynamic:function(e,t){this.d
ynamicElements.push(e),t||this.parseNext()},markParsing:function(e){c.parse&&con
sole.log("parsing",e),this.parsingElement=e},markParsingComplete:function(e){e._
_importParsed=!0,this.markDynamicParsingComplete(e),e.__importElement&&(e.__impo
rtElement.__importParsed=!0,this.markDynamicParsingComplete(e.__importElement)),
this.parsingElement=null,c.parse&&console.log("completed",e)},markDynamicParsing
Complete:function(e){var t=this.dynamicElements.indexOf(e);t>=0&&this.dynamicEle
ments.splice(t,1)},parseImport:function(e){if(e["import"]=e.__doc,window.HTMLImp
orts.__importsParsingHook&&window.HTMLImports.__importsParsingHook(e),e["import"
]&&(e["import"].__importParsed=!0),this.markParsingComplete(e),e.__resource&&!e.
__error?e.dispatchEvent(new CustomEvent("load",{bubbles:!1})):e.dispatchEvent(ne
w CustomEvent("error",{bubbles:!1})),e.__pending)for(var t;e.__pending.length;)t
=e.__pending.shift(),t&&t({target:e});this.parseNext()},parseLink:function(e){t(
e)?this.parseImport(e):(e.href=e.href,this.parseGeneric(e))},parseStyle:function
(e){var t=e;e=i(e),t.__appliedElement=e,e.__importElement=t,this.parseGeneric(e)
},parseGeneric:function(e){this.trackElement(e),this.addElementToDocument(e)},ro
otImportForElement:function(e){for(var t=e;t.ownerDocument.__importLink;)t=t.own
erDocument.__importLink;return t},addElementToDocument:function(e){var t=this.ro
otImportForElement(e.__importElement||e);t.parentNode.insertBefore(e,t)},trackEl
ement:function(e,t){var n=this,o=function(r){e.removeEventListener("load",o),e.r
emoveEventListener("error",o),t&&t(r),n.markParsingComplete(e),n.parseNext()};if
(e.addEventListener("load",o),e.addEventListener("error",o),d&&"style"===e.local
Name){var r=!1;if(e.textContent.indexOf("@import")==-1)r=!0;else if(e.sheet){r=!
0;for(var i,a=e.sheet.cssRules,s=a?a.length:0,c=0;c<s&&(i=a[c]);c++)i.type===CSS
Rule.IMPORT_RULE&&(r=r&&Boolean(i.styleSheet))}r&&setTimeout(function(){e.dispat
chEvent(new CustomEvent("load",{bubbles:!1}))})}},parseScript:function(t){var o=
document.createElement("script");o.__importElement=t,o.src=t.src?t.src:n(t),e.cu
rrentScript=t,this.trackElement(o,function(t){o.parentNode&&o.parentNode.removeC
hild(o),e.currentScript=null}),this.addElementToDocument(o)},nextToParse:functio
n(){return this._mayParse=[],!this.parsingElement&&(this.nextToParseInDoc(s)||th
is.nextToParseDynamic())},nextToParseInDoc:function(e,n){if(e&&this._mayParse.in
dexOf(e)<0){this._mayParse.push(e);for(var o,r=e.querySelectorAll(this.parseSele
ctorsForNode(e)),i=0,a=r.length;i<a&&(o=r[i]);i++)if(!this.isParsed(o))return th
is.hasResource(o)?t(o)?this.nextToParseInDoc(o.__doc,o):o:void 0}return n},nextT
oParseDynamic:function(){return this.dynamicElements[0]},parseSelectorsForNode:f
unction(e){var t=e.ownerDocument||e;return t===s?this.documentSelectors:this.imp
ortsSelectors},isParsed:function(e){return e.__importParsed},needsDynamicParsing
:function(e){return this.dynamicElements.indexOf(e)>=0},hasResource:function(e){
return!t(e)||void 0!==e.__doc}};e.parser=h,e.IMPORT_SELECTOR=u}),window.HTMLImpo
rts.addModule(function(e){function t(e){return n(e,a)}function n(e,t){return"lin
k"===e.localName&&e.getAttribute("rel")===t}function o(e){return!!Object.getOwnP
ropertyDescriptor(e,"baseURI")}function r(e,t){var n=document.implementation.cre
ateHTMLDocument(a);n._URL=t;var r=n.createElement("base");r.setAttribute("href",
t),n.baseURI||o(n)||Object.defineProperty(n,"baseURI",{value:t});var i=n.createE
lement("meta");return i.setAttribute("charset","utf-8"),n.head.appendChild(i),n.
head.appendChild(r),n.body.innerHTML=e,window.HTMLTemplateElement&&HTMLTemplateE
lement.bootstrap&&HTMLTemplateElement.bootstrap(n),n}var i=e.flags,a=e.IMPORT_LI
NK_TYPE,s=e.IMPORT_SELECTOR,c=e.rootDocument,d=e.Loader,l=e.Observer,u=e.parser,
h={documents:{},documentPreloadSelectors:s,importsPreloadSelectors:[s].join(",")
,loadNode:function(e){f.addNode(e)},loadSubtree:function(e){var t=this.marshalNo
des(e);f.addNodes(t)},marshalNodes:function(e){return e.querySelectorAll(this.lo
adSelectorsForNode(e))},loadSelectorsForNode:function(e){var t=e.ownerDocument||
e;return t===c?this.documentPreloadSelectors:this.importsPreloadSelectors},loade
d:function(e,n,o,a,s){if(i.load&&console.log("loaded",e,n),n.__resource=o,n.__er
ror=a,t(n)){var c=this.documents[e];void 0===c&&(c=a?null:r(o,s||e),c&&(c.__impo
rtLink=n,this.bootDocument(c)),this.documents[e]=c),n.__doc=c}u.parseNext()},boo
tDocument:function(e){this.loadSubtree(e),this.observer.observe(e),u.parseNext()
},loadedAll:function(){u.parseNext()}},f=new d(h.loaded.bind(h),h.loadedAll.bind
(h));if(h.observer=new l,!document.baseURI){var p={get:function(){var e=document
.querySelector("base");return e?e.href:window.location.href},configurable:!0};Ob
ject.defineProperty(document,"baseURI",p),Object.defineProperty(c,"baseURI",p)}e
.importer=h,e.importLoader=f}),window.HTMLImports.addModule(function(e){var t=e.
parser,n=e.importer,o={added:function(e){for(var o,r,i,a,s=0,c=e.length;s<c&&(a=
e[s]);s++)o||(o=a.ownerDocument,r=t.isParsed(o)),i=this.shouldLoadNode(a),i&&n.l
oadNode(a),this.shouldParseNode(a)&&r&&t.parseDynamic(a,i)},shouldLoadNode:funct
ion(e){return 1===e.nodeType&&r.call(e,n.loadSelectorsForNode(e))},shouldParseNo
de:function(e){return 1===e.nodeType&&r.call(e,t.parseSelectorsForNode(e))}};n.o
bserver.addCallback=o.added.bind(o);var r=HTMLElement.prototype.matches||HTMLEle
ment.prototype.matchesSelector||HTMLElement.prototype.webkitMatchesSelector||HTM
LElement.prototype.mozMatchesSelector||HTMLElement.prototype.msMatchesSelector})
,function(e){function t(){window.HTMLImports.importer.bootDocument(o)}var n=e.in
itializeModules;e.isIE;if(!e.useNative){n();var o=e.rootDocument;"complete"===do
cument.readyState||"interactive"===document.readyState&&!window.attachEvent?t():
document.addEventListener("DOMContentLoaded",t)}}(window.HTMLImports),window.Cus
tomElements=window.CustomElements||{flags:{}},function(e){var t=e.flags,n=[],o=f
unction(e){n.push(e)},r=function(){n.forEach(function(t){t(e)})};e.addModule=o,e
.initializeModules=r,e.hasNative=Boolean(document.registerElement),e.isIE=/Tride
nt/.test(navigator.userAgent),e.useNative=!t.register&&e.hasNative&&!window.Shad
owDOMPolyfill&&(!window.HTMLImports||window.HTMLImports.useNative)}(window.Custo
mElements),window.CustomElements.addModule(function(e){function t(e,t){n(e,funct
ion(e){return!!t(e)||void o(e,t)}),o(e,t)}function n(e,t,o){var r=e.firstElement
Child;if(!r)for(r=e.firstChild;r&&r.nodeType!==Node.ELEMENT_NODE;)r=r.nextSiblin
g;for(;r;)t(r,o)!==!0&&n(r,t,o),r=r.nextElementSibling;return null}function o(e,
n){for(var o=e.shadowRoot;o;)t(o,n),o=o.olderShadowRoot}function r(e,t){i(e,t,[]
)}function i(e,t,n){if(e=window.wrap(e),!(n.indexOf(e)>=0)){n.push(e);for(var o,
r=e.querySelectorAll("link[rel="+a+"]"),s=0,c=r.length;s<c&&(o=r[s]);s++)o["impo
rt"]&&i(o["import"],t,n);t(e)}}var a=window.HTMLImports?window.HTMLImports.IMPOR
T_LINK_TYPE:"none";e.forDocumentTree=r,e.forSubtree=t}),window.CustomElements.ad
dModule(function(e){function t(e,t){return n(e,t)||o(e,t)}function n(t,n){return
!!e.upgrade(t,n)||void(n&&a(t))}function o(e,t){g(e,function(e){if(n(e,t))return
!0})}function r(e){L.push(e),E||(E=!0,setTimeout(i))}function i(){E=!1;for(var e
,t=L,n=0,o=t.length;n<o&&(e=t[n]);n++)e();L=[]}function a(e){y?r(function(){s(e) |
| 2 }):s(e)}function s(e){e.__upgraded__&&!e.__attached&&(e.__attached=!0,e.attached
Callback&&e.attachedCallback())}function c(e){d(e),g(e,function(e){d(e)})}functi
on d(e){y?r(function(){l(e)}):l(e)}function l(e){e.__upgraded__&&e.__attached&&(
e.__attached=!1,e.detachedCallback&&e.detachedCallback())}function u(e){for(var
t=e,n=window.wrap(document);t;){if(t==n)return!0;t=t.parentNode||t.nodeType===No
de.DOCUMENT_FRAGMENT_NODE&&t.host}}function h(e){if(e.shadowRoot&&!e.shadowRoot.
__watched){_.dom&&console.log("watching shadow-root for: ",e.localName);for(var
t=e.shadowRoot;t;)m(t),t=t.olderShadowRoot}}function f(e,n){if(_.dom){var o=n[0]
;if(o&&"childList"===o.type&&o.addedNodes&&o.addedNodes){for(var r=o.addedNodes[
0];r&&r!==document&&!r.host;)r=r.parentNode;var i=r&&(r.URL||r._URL||r.host&&r.h
ost.localName)||"";i=i.split("/?").shift().split("/").pop()}console.group("mutat
ions (%d) [%s]",n.length,i||"")}var a=u(e);n.forEach(function(e){"childList"===e
.type&&(N(e.addedNodes,function(e){e.localName&&t(e,a)}),N(e.removedNodes,functi
on(e){e.localName&&c(e)}))}),_.dom&&console.groupEnd()}function p(e){for(e=windo
w.wrap(e),e||(e=window.wrap(document));e.parentNode;)e=e.parentNode;var t=e.__ob
server;t&&(f(e,t.takeRecords()),i())}function m(e){if(!e.__observer){var t=new M
utationObserver(f.bind(this,e));t.observe(e,{childList:!0,subtree:!0}),e.__obser
ver=t}}function v(e){e=window.wrap(e),_.dom&&console.group("upgradeDocument: ",e
.baseURI.split("/").pop());var n=e===window.wrap(document);t(e,n),m(e),_.dom&&co
nsole.groupEnd()}function w(e){b(e,v)}var _=e.flags,g=e.forSubtree,b=e.forDocume
ntTree,y=window.MutationObserver._isPolyfilled&&_["throttle-attached"];e.hasPoly
fillMutations=y,e.hasThrottledAttached=y;var E=!1,L=[],N=Array.prototype.forEach
.call.bind(Array.prototype.forEach),M=Element.prototype.createShadowRoot;M&&(Ele
ment.prototype.createShadowRoot=function(){var e=M.call(this);return window.Cust
omElements.watchShadow(this),e}),e.watchShadow=h,e.upgradeDocumentTree=w,e.upgra
deDocument=v,e.upgradeSubtree=o,e.upgradeAll=t,e.attached=a,e.takeRecords=p}),wi
ndow.CustomElements.addModule(function(e){function t(t,o){if("template"===t.loca
lName&&window.HTMLTemplateElement&&HTMLTemplateElement.decorate&&HTMLTemplateEle
ment.decorate(t),!t.__upgraded__&&t.nodeType===Node.ELEMENT_NODE){var r=t.getAtt
ribute("is"),i=e.getRegisteredDefinition(t.localName)||e.getRegisteredDefinition
(r);if(i&&(r&&i.tag==t.localName||!r&&!i["extends"]))return n(t,i,o)}}function n
(t,n,r){return a.upgrade&&console.group("upgrade:",t.localName),n.is&&t.setAttri
bute("is",n.is),o(t,n),t.__upgraded__=!0,i(t),r&&e.attached(t),e.upgradeSubtree(
t,r),a.upgrade&&console.groupEnd(),t}function o(e,t){Object.__proto__?e.__proto_
_=t.prototype:(r(e,t.prototype,t["native"]),e.__proto__=t.prototype)}function r(
e,t,n){for(var o={},r=t;r!==n&&r!==HTMLElement.prototype;){for(var i,a=Object.ge
tOwnPropertyNames(r),s=0;i=a[s];s++)o[i]||(Object.defineProperty(e,i,Object.getO
wnPropertyDescriptor(r,i)),o[i]=1);r=Object.getPrototypeOf(r)}}function i(e){e.c
reatedCallback&&e.createdCallback()}var a=e.flags;e.upgrade=t,e.upgradeWithDefin
ition=n,e.implementPrototype=o}),window.CustomElements.addModule(function(e){fun
ction t(t,o){var c=o||{};if(!t)throw new Error("document.registerElement: first
argument `name` must not be empty");if(t.indexOf("-")<0)throw new Error("documen
t.registerElement: first argument ('name') must contain a dash ('-'). Argument p
rovided was '"+String(t)+"'.");if(r(t))throw new Error("Failed to execute 'regis
terElement' on 'Document': Registration failed for type '"+String(t)+"'. The typ
e name is invalid.");if(d(t))throw new Error("DuplicateDefinitionError: a type w
ith name '"+String(t)+"' is already registered");return c.prototype||(c.prototyp
e=Object.create(HTMLElement.prototype)),c.__name=t.toLowerCase(),c["extends"]&&(
c["extends"]=c["extends"].toLowerCase()),c.lifecycle=c.lifecycle||{},c.ancestry=
i(c["extends"]),a(c),s(c),n(c.prototype),l(c.__name,c),c.ctor=u(c),c.ctor.protot
ype=c.prototype,c.prototype.constructor=c.ctor,e.ready&&v(document),c.ctor}funct
ion n(e){if(!e.setAttribute._polyfilled){var t=e.setAttribute;e.setAttribute=fun
ction(e,n){o.call(this,e,n,t)};var n=e.removeAttribute;e.removeAttribute=functio
n(e){o.call(this,e,null,n)},e.setAttribute._polyfilled=!0}}function o(e,t,n){e=e
.toLowerCase();var o=this.getAttribute(e);n.apply(this,arguments);var r=this.get
Attribute(e);this.attributeChangedCallback&&r!==o&&this.attributeChangedCallback
(e,o,r)}function r(e){for(var t=0;t<y.length;t++)if(e===y[t])return!0}function i
(e){var t=d(e);return t?i(t["extends"]).concat([t]):[]}function a(e){for(var t,n
=e["extends"],o=0;t=e.ancestry[o];o++)n=t.is&&t.tag;e.tag=n||e.__name,n&&(e.is=e
.__name)}function s(e){if(!Object.__proto__){var t=HTMLElement.prototype;if(e.is
){var n=document.createElement(e.tag);t=Object.getPrototypeOf(n)}for(var o,r=e.p
rototype,i=!1;r;)r==t&&(i=!0),o=Object.getPrototypeOf(r),o&&(r.__proto__=o),r=o;
i||console.warn(e.tag+" prototype not found in prototype chain for "+e.is),e["na
tive"]=t}}function c(e){return _(N(e.tag),e)}function d(e){if(e)return E[e.toLow
erCase()]}function l(e,t){E[e]=t}function u(e){return function(){return c(e)}}fu
nction h(e,t,n){return e===L?f(t,n):M(e,t)}function f(e,t){e&&(e=e.toLowerCase()
),t&&(t=t.toLowerCase());var n=d(t||e);if(n){if(e==n.tag&&t==n.is)return new n.c
tor;if(!t&&!n.is)return new n.ctor}var o;return t?(o=f(e),o.setAttribute("is",t)
,o):(o=N(e),e.indexOf("-")>=0&&g(o,HTMLElement),o)}function p(e,t){var n=e[t];e[
t]=function(){var e=n.apply(this,arguments);return w(e),e}}var m,v=(e.isIE,e.upg
radeDocumentTree),w=e.upgradeAll,_=e.upgradeWithDefinition,g=e.implementPrototyp
e,b=e.useNative,y=["annotation-xml","color-profile","font-face","font-face-src",
"font-face-uri","font-face-format","font-face-name","missing-glyph"],E={},L="htt
p://www.w3.org/1999/xhtml",N=document.createElement.bind(document),M=document.cr
eateElementNS.bind(document);m=Object.__proto__||b?function(e,t){return e instan
ceof t}:function(e,t){if(e instanceof t)return!0;for(var n=e;n;){if(n===t.protot
ype)return!0;n=n.__proto__}return!1},p(Node.prototype,"cloneNode"),p(document,"i
mportNode"),document.registerElement=t,document.createElement=f,document.createE
lementNS=h,e.registry=E,e["instanceof"]=m,e.reservedTagList=y,e.getRegisteredDef
inition=d,document.register=document.registerElement}),function(e){function t(){
i(window.wrap(document)),window.CustomElements.ready=!0;var e=window.requestAnim
ationFrame||function(e){setTimeout(e,16)};e(function(){setTimeout(function(){win
dow.CustomElements.readyTime=Date.now(),window.HTMLImports&&(window.CustomElemen
ts.elapsed=window.CustomElements.readyTime-window.HTMLImports.readyTime),documen
t.dispatchEvent(new CustomEvent("WebComponentsReady",{bubbles:!0}))})})}var n=e.
useNative,o=e.initializeModules;e.isIE;if(n){var r=function(){};e.watchShadow=r,
e.upgrade=r,e.upgradeAll=r,e.upgradeDocumentTree=r,e.upgradeSubtree=r,e.takeReco
rds=r,e["instanceof"]=function(e,t){return e instanceof t}}else o();var i=e.upgr
adeDocumentTree,a=e.upgradeDocument;if(window.wrap||(window.ShadowDOMPolyfill?(w
indow.wrap=window.ShadowDOMPolyfill.wrapIfNeeded,window.unwrap=window.ShadowDOMP
olyfill.unwrapIfNeeded):window.wrap=window.unwrap=function(e){return e}),window.
HTMLImports&&(window.HTMLImports.__importsParsingHook=function(e){e["import"]&&a
(wrap(e["import"]))}),"complete"===document.readyState||e.flags.eager)t();else i
f("interactive"!==document.readyState||window.attachEvent||window.HTMLImports&&!
window.HTMLImports.ready){var s=window.HTMLImports&&!window.HTMLImports.ready?"H
TMLImportsLoaded":"DOMContentLoaded";window.addEventListener(s,t)}else t()}(wind
ow.CustomElements),function(e){var t=document.createElement("style");t.textConte
nt="body {transition: opacity ease-in 0.2s; } \nbody[unresolved] {opacity: 0; di
splay: block; overflow: hidden; position: relative; } \n";var n=document.querySe
lector("head");n.insertBefore(t,n.firstChild)}(window.WebComponents);(function()
{var customUtils={};function getRandomArray(n){var res,next;if(n===0){return[]}i
f(n===1){return[0]}res=getRandomArray(n-1);next=Math.floor(Math.random()*n);res.
splice(next,0,n-1);return res}customUtils.getRandomArray=getRandomArray;function
defaultCompareKeysFunction(a,b){if(a<b){return-1}if(a>b){return 1}if(a===b){ret
urn 0}throw{message:"Couldn't compare elements",a:a,b:b}}customUtils.defaultComp
areKeysFunction=defaultCompareKeysFunction;function defaultCheckValueEquality(a,
b){return a===b}customUtils.defaultCheckValueEquality=defaultCheckValueEquality;
function BinarySearchTree(options){options=options||{};this.left=null;this.right
=null;this.parent=options.parent!==undefined?options.parent:null;if(options.hasO
wnProperty("key")){this.key=options.key}this.data=options.hasOwnProperty("value"
)?[options.value]:[];this.unique=options.unique||false;this.compareKeys=options.
compareKeys||customUtils.defaultCompareKeysFunction;this.checkValueEquality=opti
ons.checkValueEquality||customUtils.defaultCheckValueEquality}BinarySearchTree.p
rototype.getMaxKeyDescendant=function(){if(this.right){return this.right.getMaxK
eyDescendant()}else{return this}};BinarySearchTree.prototype.getMaxKey=function(
){return this.getMaxKeyDescendant().key};BinarySearchTree.prototype.getMinKeyDes
cendant=function(){if(this.left){return this.left.getMinKeyDescendant()}else{ret
urn this}};BinarySearchTree.prototype.getMinKey=function(){return this.getMinKey
Descendant().key};BinarySearchTree.prototype.checkAllNodesFullfillCondition=func
tion(test){if(!this.hasOwnProperty("key")){return}test(this.key,this.data);if(th
is.left){this.left.checkAllNodesFullfillCondition(test)}if(this.right){this.righ
t.checkAllNodesFullfillCondition(test)}};BinarySearchTree.prototype.checkNodeOrd
ering=function(){var self=this;if(!this.hasOwnProperty("key")){return}if(this.le
ft){this.left.checkAllNodesFullfillCondition(function(k){if(self.compareKeys(k,s
elf.key)>=0){throw"Tree with root "+self.key+" is not a binary search tree"}});t
his.left.checkNodeOrdering()}if(this.right){this.right.checkAllNodesFullfillCond
ition(function(k){if(self.compareKeys(k,self.key)<=0){throw"Tree with root "+sel
f.key+" is not a binary search tree"}});this.right.checkNodeOrdering()}};BinaryS
earchTree.prototype.checkInternalPointers=function(){if(this.left){if(this.left.
parent!==this){throw"Parent pointer broken for key "+this.key}this.left.checkInt
ernalPointers()}if(this.right){if(this.right.parent!==this){throw"Parent pointer
broken for key "+this.key}this.right.checkInternalPointers()}};BinarySearchTree
.prototype.checkIsBST=function(){this.checkNodeOrdering();this.checkInternalPoin
ters();if(this.parent){throw"The root shouldn't have a parent"}};BinarySearchTre
e.prototype.getNumberOfKeys=function(){var res;if(!this.hasOwnProperty("key")){r
eturn 0}res=1;if(this.left){res+=this.left.getNumberOfKeys()}if(this.right){res+
=this.right.getNumberOfKeys()}return res};BinarySearchTree.prototype.createSimil
ar=function(options){options=options||{};options.unique=this.unique;options.comp
areKeys=this.compareKeys;options.checkValueEquality=this.checkValueEquality;retu
rn new this.constructor(options)};BinarySearchTree.prototype.createLeftChild=fun
ction(options){var leftChild=this.createSimilar(options);leftChild.parent=this;t
his.left=leftChild;return leftChild};BinarySearchTree.prototype.createRightChild
=function(options){var rightChild=this.createSimilar(options);rightChild.parent=
this;this.right=rightChild;return rightChild};BinarySearchTree.prototype.insert=
function(key,value){if(!this.hasOwnProperty("key")){this.key=key;this.data.push(
value);return}if(this.compareKeys(this.key,key)===0){if(this.unique){throw{messa
ge:"Can't insert key "+key+", it violates the unique constraint",key:key,errorTy
pe:"uniqueViolated"}}else{this.data.push(value)}return}if(this.compareKeys(key,t
his.key)<0){if(this.left){this.left.insert(key,value)}else{this.createLeftChild(
{key:key,value:value})}}else{if(this.right){this.right.insert(key,value)}else{th
is.createRightChild({key:key,value:value})}}};BinarySearchTree.prototype.search=
function(key){if(!this.hasOwnProperty("key")){return[]}if(this.compareKeys(this.
key,key)===0){return this.data}if(this.compareKeys(key,this.key)<0){if(this.left
){return this.left.search(key)}else{return[]}}else{if(this.right){return this.ri
ght.search(key)}else{return[]}}};BinarySearchTree.prototype.getLowerBoundMatcher
=function(query){var self=this;if(!query.hasOwnProperty("$gt")&&!query.hasOwnPro
perty("$gte")){return function(){return true}}if(query.hasOwnProperty("$gt")&&qu
ery.hasOwnProperty("$gte")){if(self.compareKeys(query.$gte,query.$gt)===0){retur
n function(key){return self.compareKeys(key,query.$gt)>0}}if(self.compareKeys(qu
ery.$gte,query.$gt)>0){return function(key){return self.compareKeys(key,query.$g
te)>=0}}else{return function(key){return self.compareKeys(key,query.$gt)>0}}}if(
query.hasOwnProperty("$gt")){return function(key){return self.compareKeys(key,qu
ery.$gt)>0}}else{return function(key){return self.compareKeys(key,query.$gte)>=0
}}};BinarySearchTree.prototype.getUpperBoundMatcher=function(query){var self=thi
s;if(!query.hasOwnProperty("$lt")&&!query.hasOwnProperty("$lte")){return functio
n(){return true}}if(query.hasOwnProperty("$lt")&&query.hasOwnProperty("$lte")){i
f(self.compareKeys(query.$lte,query.$lt)===0){return function(key){return self.c
ompareKeys(key,query.$lt)<0}}if(self.compareKeys(query.$lte,query.$lt)<0){return
function(key){return self.compareKeys(key,query.$lte)<=0}}else{return function(
key){return self.compareKeys(key,query.$lt)<0}}}if(query.hasOwnProperty("$lt")){
return function(key){return self.compareKeys(key,query.$lt)<0}}else{return funct
ion(key){return self.compareKeys(key,query.$lte)<=0}}};function append(array,toA
ppend){var i;for(i=0;i<toAppend.length;i+=1){array.push(toAppend[i])}}BinarySear
chTree.prototype.betweenBounds=function(query,lbm,ubm){var res=[];if(!this.hasOw
nProperty("key")){return[]}lbm=lbm||this.getLowerBoundMatcher(query);ubm=ubm||th
is.getUpperBoundMatcher(query);if(lbm(this.key)&&this.left){append(res,this.left
.betweenBounds(query,lbm,ubm))}if(lbm(this.key)&&ubm(this.key)){append(res,this.
data)}if(ubm(this.key)&&this.right){append(res,this.right.betweenBounds(query,lb
m,ubm))}return res};BinarySearchTree.prototype.deleteIfLeaf=function(){if(this.l
eft||this.right){return false}if(!this.parent){delete this.key;this.data=[];retu
rn true}if(this.parent.left===this){this.parent.left=null}else{this.parent.right
=null}return true};BinarySearchTree.prototype.deleteIfOnlyOneChild=function(){va
r child;if(this.left&&!this.right){child=this.left}if(!this.left&&this.right){ch
ild=this.right}if(!child){return false}if(!this.parent){this.key=child.key;this.
data=child.data;this.left=null;if(child.left){this.left=child.left;child.left.pa
rent=this}this.right=null;if(child.right){this.right=child.right;child.right.par
ent=this}return true}if(this.parent.left===this){this.parent.left=child;child.pa
rent=this.parent}else{this.parent.right=child;child.parent=this.parent}return tr
ue};BinarySearchTree.prototype.delete=function(key,value){var newData=[],replace
With,self=this;if(!this.hasOwnProperty("key")){return}if(this.compareKeys(key,th
is.key)<0){if(this.left){this.left.delete(key,value)}return}if(this.compareKeys(
key,this.key)>0){if(this.right){this.right.delete(key,value)}return}if(!this.com
pareKeys(key,this.key)===0){return}if(this.data.length>1&&value!==undefined){thi
s.data.forEach(function(d){if(!self.checkValueEquality(d,value)){newData.push(d)
}});self.data=newData;return}if(this.deleteIfLeaf()){return}if(this.deleteIfOnly
OneChild()){return}if(Math.random()>=.5){replaceWith=this.left.getMaxKeyDescenda
nt();this.key=replaceWith.key;this.data=replaceWith.data;if(this===replaceWith.p
arent){this.left=replaceWith.left;if(replaceWith.left){replaceWith.left.parent=r
eplaceWith.parent}}else{replaceWith.parent.right=replaceWith.left;if(replaceWith
.left){replaceWith.left.parent=replaceWith.parent}}}else{replaceWith=this.right.
getMinKeyDescendant();this.key=replaceWith.key;this.data=replaceWith.data;if(thi
s===replaceWith.parent){this.right=replaceWith.right;if(replaceWith.right){repla
ceWith.right.parent=replaceWith.parent}}else{replaceWith.parent.left=replaceWith
.right;if(replaceWith.right){replaceWith.right.parent=replaceWith.parent}}}};Bin
arySearchTree.prototype.executeOnEveryNode=function(fn){if(this.left){this.left.
executeOnEveryNode(fn)}fn(this);if(this.right){this.right.executeOnEveryNode(fn)
}};BinarySearchTree.prototype.prettyPrint=function(printData,spacing){spacing=sp
acing||"";console.log(spacing+"* "+this.key);if(printData){console.log(spacing+"
* "+this.data)}if(!this.left&&!this.right){return}if(this.left){this.left.pretty
Print(printData,spacing+" ")}else{console.log(spacing+" *")}if(this.right){thi
s.right.prettyPrint(printData,spacing+" ")}else{console.log(spacing+" *")}};fu
nction SuffixTrie(options){this.options=options||{};this.structure={};this.debug
=this.options.debug===undefined?false:options.debug;this.minLENGTH=this.options.
minLength===undefined?3:options.minLength;this.minOccurrence=this.options.minOcc
urrence===undefined?2:options.minOccurrence;this.isByLength=this.options.byLengt
h===undefined?false:options.byLength;this.save=[];this.array=null;this.labelArra
y=null;this.fragmentsArray=null;this.fragmentTrie={};this.rebuildArray}SuffixTri
e.prototype.refresh=function(){this.structure={};this.save=[];this.array=null;th
is.labelArray=null;this.fragmentsArray=null;this.fragmentTrie={};this.rebuildArr
ay};SuffixTrie.prototype.weigh=function(){if(this.isByLength){return this.weighB
yMax()}else{return this.weighByAverage()}};SuffixTrie.prototype.build=function(a
rray){var debug=this.debug;this.buildLabelTrie(array);this.optimize(this.structu
re);if(debug)console.log("after optimization our label trie of array length "+th
is.array.length+" is ",this.structure);this.listLabel();if(debug)console.log("ge
t the compressed label array (without duplicate fragments ) of array length "+th
is.array.length+" is ",this.labelArray);if(debug)console.log("and fragments arra
y of length "+this.fragmentsArray.length+" is ",this.fragmentsArray);this.clearR
edundantFragment();if(debug)console.log("get the cleared label array (without du
plicate fragments ) of array length "+this.array.length+" is ",this.labelArray);
if(debug)console.log("and cleared fragments array of length "+this.fragmentsArra
y.length+" is ",this.fragmentsArray);this.rebuild();if(debug)console.log("rebuil
d ended",this.rebuildArray)};SuffixTrie.prototype.buildLabelTrie=function(array)
{this.array=array;var root=this.structure;var LENGTH=this.minLENGTH;array.forEac
h(function(word,index){var first=true;var last={};for(var i=0,l=word.length;i<=l
-LENGTH;i++){var cur=root;var suffix=word.substring(i);var letters=suffix.split(
"");for(var j=0;j<letters.length;j++){var letter=letters[j],pos=cur[letter];if(j
===letters.length-1){if(pos==null){cur[letter]={source:[index],listed:false}}els
e if(pos.hasOwnProperty("source")){pos["source"].push(index)}else{cur[letter]["s
ource"]=[index];cur[letter]["listed"]=false}cur=cur[letter];if(!first){last["nex
t"]=suffix}else{first=false}last=cur}else if(pos==null){cur=cur[letter]={}}else{
cur=cur[letter]}}}})};SuffixTrie.prototype.optimize=function(root,rootLevel){var
occurrence=this.minOccurrence;var self_save=[];rootLevel=rootLevel===undefined?
-1:rootLevel;rootLevel++;var is_allowed=rootLevel>=this.minLENGTH;for(var child
in root){if(root.hasOwnProperty(child)){if(child.length===1){var children_save=t
his.optimize(root[child],rootLevel);if(is_allowed){self_save=self_save.concat(ch
ildren_save)}}else if(child==="source"&&is_allowed){self_save=self_save.concat(r
oot["source"])}}}self_save=uniqueArray(self_save);var isEnoughOccurred=self_save
.length>=occurrence;is_allowed=is_allowed&&isEnoughOccurred;if(is_allowed){var i
s_SoleNode=Object.keys(root).length===1;if(!is_SoleNode){root["source"]=self_sav
e;root["level"]=rootLevel;root["listed"]=false;root["weight"]=self_save.length*r
ootLevel;self_save=[]}else{}}else{delete root["source"]}return self_save};Suffix
Trie.prototype.listLabel=function(start){var array=this.array;var root=this.stru
cture;var label_array=[];var fragments_array=[];var length=this.minLENGTH;var oc
currence=this.minOccurrence;start=start===undefined?1:start;for(var index=start-
1,i=0;i<array.length;index++,index=index%array.length,i++){var word=array[index]
;var fragments={};if(word.length<length){label_array.push(fragments);continue}fi
ndFragments(word,fragments,root,length,occurrence,false);for(var fragment in fra
gments){if(fragments.hasOwnProperty(fragment)){var fragmentsArrayIndex=fragments
_array.push(fragments[fragment])-1;fragments_array[fragmentsArrayIndex]["name"]=
fragment}}label_array.push(fragments)}this.labelArray=label_array;this.fragments
Array=fragments_array;return label_array};SuffixTrie.prototype.rebuild=function(
){var rebuildArray=JSON.parse(JSON.stringify(this.labelArray));rebuildArray.forE
ach(function(object,index){for(var fragment in object){if(object.hasOwnProperty(
fragment)){object[fragment]["source"].forEach(function(labelIndex){if(labelIndex
>index){rebuildArray[labelIndex][fragment]=object[fragment]}})}}});this.rebuildA
rray=rebuildArray};SuffixTrie.prototype.weighByAverage=function(){var debug=this
.debug;var fragmentsArray=this.fragmentsArray;var fragments_Num=this.fragmentsAr
ray.length;fragmentsArray.sort(function(f1,f2){return f2["weight"]-f1["weight"]}
);if(debug)console.log("weigh by average: result of length "+fragments_Num+" is
",fragmentsArray);if(typeof this.options.limit=="number")fragments_Num=this.opti
ons.limit<fragments_Num?this.options.limit:fragments_Num;return fragmentsArray.s
lice(0,fragments_Num)};SuffixTrie.prototype.weighByMax=function(){var debug=this
.debug;buildFragmentTrie(this.fragmentTrie,this.fragmentsArray);var rebuildArray
=JSON.parse(JSON.stringify(this.rebuildArray));var fragmentsArray=[];var fragmen
tsTrie=this.fragmentTrie;var fragments_Num=this.fragmentsArray.length;var label_
Lengths=this.array.map(function(s){return s.length});var label_Tree=new BinarySe
archTree;label_Lengths.forEach(function(length,index){label_Tree.insert(length,i
ndex)});if(typeof this.options.limit=="number")fragments_Num=this.options.limit<
fragments_Num?this.options.limit:fragments_Num;while(fragmentsArray.length<fragm
ents_Num){var maxKey=label_Tree.getMaxKey();var labels_In_Key=label_Tree.search(
maxKey);if(labels_In_Key.length===0){label_Tree.delete(maxKey);continue}var long
est_Label=labels_In_Key[0];var fragments=Object.keys(rebuildArray[longest_Label]
);if(fragments.length>0){fragments.sort(function(f1,f2){return f2.length-f1.leng
th});removeTrie(fragments[0],fragmentsTrie,fragmentsArray,label_Lengths,rebuildA
rray,label_Tree)}label_Tree.delete(maxKey,longest_Label)}this.fragmentsArray=fra
gmentsArray;if(debug)console.log("weigh by max: result of length "+fragmentsArr
ay.length+" is",fragmentsArray);return fragmentsArray.slice(0,fragments_Num)};Su
ffixTrie.prototype.clearRedundantFragment=function(){var fragments=this.fragment
sArray;var occurrence=this.minOccurrence;var newFragmentArray=[];var labelArray=
this.labelArray;fragments.sort(function(a,b){return a.name.length-b.name.length}
);fragments.forEach(function(fragment,index){var backupsource=fragment.source.sl
ice();for(var i=index+1;i<fragments.length;i++){var longerFragment=fragments[i];
if(longerFragment.name.indexOf(fragment.name)!==-1){fragment.source=fragment.sou
rce.filter(function(i){return this.indexOf(i)===-1},longerFragment.source)}}if(f
ragment.source.length>=occurrence){newFragmentArray.push(fragment)}else{if(backu
psource.length!==fragment.source.length){deleteFragmentInLabelArray(backupsource
,fragment.name,labelArray)}}});this.fragmentsArray=newFragmentArray};function fi
ndFragments(word,fragments,root,length,occurrence,iterate){var cur=root;var lett
ers=word.split("");for(var j=0;j<letters.length;j++){var letter=letters[j],pos=c
ur[letter];if(j+1>=length){var fragment=word.substring(0,j+1);if(pos.hasOwnPrope
rty("listed")){if(!pos["listed"]){if(pos.hasOwnProperty("source")){fragments[fra
gment]={};fragments[fragment]["source"]=pos.source;fragments[fragment]["weight"]
=pos["weight"];if(pos["weight"]==null){console.warn("escape case! fragment does
not has weight property, node is ",fragments[fragment])}if(fragments.hasOwnPrope
rty(fragment)){if(iterate){for(var property in fragments){if(property!==fragment
&&fragments.hasOwnProperty(property)&&fragments.hasOwnProperty(fragment)){if(pro
perty.indexOf(fragment)!==-1){fragments[fragment]["source"]=fragments[fragment][
"source"].filter(function(i){return this.indexOf(i)<0},fragments[property].sourc
e)}}}if(fragments[fragment]["source"].length<occurrence){delete fragments[fragme
nt]}}}pos["listed"]=true}if(pos.hasOwnProperty("next")){findFragments(pos["next"
],fragments,root,length,occurrence,true)}}}}cur=pos}}function deleteFragmentInLa
belArray(source,name,labelArray){var label=labelArray[source[0]];if(label.hasOwn
Property(name)){delete label[name]}}function buildFragmentTrie(trie,array){for(v
ar i=0;i<array.length;i++){var word=array[i]["name"],letters=word.split(""),cur=
trie;for(var j=0;j<letters.length;j++){var letter=letters[j];if(!cur.hasOwnPrope
rty(letter)){cur[letter]={}}cur=cur[letter];if(j===letters.length-1){cur["source
"]=array[i]["source"];cur["name"]=array[i]["name"];cur["weight"]=array[i]["weigh
t"];cur["list"]=false}}}}function removeTrie(word,cur,array,labelLengthArray,reb
uildArray,label_trie){for(var node in cur){if(cur.hasOwnProperty(node)&&node.len
gth===1){if(word.indexOf(node)===0){if(word.length===1){if(cur[node].hasOwnPrope
rty("list")){var fragment={};fragment["source"]=cur[node]["source"];var fragment
Name=cur[node]["name"];fragment["name"]=fragmentName;fragment["weight"]=cur[node
]["weight"];delete cur[node]["list"];array.push(fragment);cur[node]["source"].fo
rEach(function(indexLabel){delete rebuildArray[indexLabel][fragmentName];var lab
elLength=labelLengthArray[indexLabel];label_trie.delete(labelLength,indexLabel);
labelLength-=fragmentName.length;label_trie.insert(labelLength,indexLabel)})}}el
se{removeTrie(word.slice(1),cur[node],array,labelLengthArray,rebuildArray,label_
trie)}}}}}function uniqueArray(array){var a=array.concat();for(var i=0;i<a.lengt
h;++i){for(var j=i+1;j<a.length;++j){if(a[i]===a[j])a.splice(j--,1)}}return a}wi
ndow.Substrings=SuffixTrie})();function $$(query,ele){if(!ele){ele=document}retu
rn Array.prototype.map.call(ele.querySelectorAll(query),function(e){return e})}f
unction $$$(query,ele){if(!ele){ele=document}return ele.querySelector(query)}thi
s.sk=this.sk||function(){"use strict";var sk={};sk.clearChildren=function(ele){w
hile(ele.firstChild){ele.removeChild(ele.firstChild)}};sk.findParent=function(el
e,nodeName){while(ele!=null){if(ele.nodeName==nodeName){return ele}ele=ele.paren
tElement}return null};sk.errorMessage=function(message,duration){if(typeof messa
ge==="object"){message=message.response||JSON.stringify(message)}var detail={mes
sage:message};detail.duration=duration;document.dispatchEvent(new CustomEvent("e
rror-sk",{detail:detail,bubbles:true}))};sk.Importer=function(){if("currentScrip
t"in document){this.importDoc_=document.currentScript.ownerDocument}else{this.im
portDoc_=document._currentScript.ownerDocument}};sk.Importer.prototype.import=fu
nction(id){return document.importNode($$$(id,this.importDoc_).content,true)};sk.
elePos=function(ele){var bounds=ele.getBoundingClientRect();return{x:bounds.left
,y:bounds.top}};sk.request=function(method,url,body,headers){return new Promise(
function(resolve,reject){var req=new XMLHttpRequest;req.open(method,url);if(head
ers){for(var k in headers){req.setRequestHeader(k,headers[k])}}req.onload=functi
on(){if(req.status==200){resolve(req.response)}else{reject({response:req.respons
e,status:req.status})}};req.onerror=function(){reject({response:Error("Network E
rror")})};req.send(body)})};sk.get=function(url){return sk.request("GET",url)};s
k.post=function(url,body,content_type){if(!content_type){content_type="applicati
on/json"}return sk.request("POST",url,body,{"Content-Type":content_type})};sk.de
lete=function(url,body){return sk.request("DELETE",url,body)};sk.DomReady=new Pr
omise(function(resolve,reject){if(document.readyState!="loading"){resolve()}else
{document.addEventListener("DOMContentLoaded",resolve)}});sk.WebComponentsReady=
new Promise(function(resolve,reject){window.addEventListener("polymer-ready",res
olve)});var _Mailbox=function(){this.boxes={}};_Mailbox.prototype.subscribe=func
tion(addr,cb){var box=this.boxes[addr]||{callbacks:[],value:null};box.callbacks.
push(cb);cb(box.value);this.boxes[addr]=box};_Mailbox.prototype.unsubscribe=func
tion(addr,cb){var box=this.boxes[addr]||{callbacks:[],value:null};for(var i=box.
callbacks.length-1;i>=0;i--){if(box.callbacks[i]==cb){box.callbacks.splice(i,1)}
}};_Mailbox.prototype.send=function(addr,value){var box=this.boxes[addr]||{callb
acks:[],value:null};box.value=value;this.boxes[addr]=box;box.callbacks.forEach(f
unction(cb){cb(value)})};sk.Mailbox=new _Mailbox;sk.human={};var TIME_DELTAS=[{u
nits:"w",delta:7*24*60*60},{units:"d",delta:24*60*60},{units:"h",delta:60*60},{u
nits:"m",delta:60},{units:"s",delta:1}];sk.KB=1024;sk.MB=sk.KB*1024;sk.GB=sk.MB*
1024;sk.TB=sk.GB*1024;sk.PB=sk.TB*1024;var BYTES_DELTAS=[{units:" PB",delta:sk.P
B},{units:" TB",delta:sk.TB},{units:" GB",delta:sk.GB},{units:" MB",delta:sk.MB}
,{units:" KB",delta:sk.KB},{units:" B",delta:1}];sk.human.pad=function(num,size)
{var str=num+"";while(str.length<size)str="0"+str;return str};sk.human.strDurati
on=function(seconds){if(seconds<0){seconds=-seconds}if(seconds==0){return" 0s"}
var rv="";for(var i=0;i<TIME_DELTAS.length;i++){if(TIME_DELTAS[i].delta<=seconds
){var s=Math.floor(seconds/TIME_DELTAS[i].delta)+TIME_DELTAS[i].units;while(s.le
ngth<4){s=" "+s}rv+=s;seconds=seconds%TIME_DELTAS[i].delta}}return rv};sk.human.
diffDate=function(s){var ms=typeof s=="number"?s:Date.parse(s);var diff=(ms-Date
.now())/1e3;if(diff<0){diff=-1*diff}return humanize(diff,TIME_DELTAS)};sk.human.
bytes=function(b,unit){if(Number.isInteger(unit)){b=b*unit}return humanize(b,BYT
ES_DELTAS)};function humanize(n,deltas){for(var i=0;i<deltas.length-1;i++){var n
extDeltaRounded=Math.round(n/deltas[i+1].delta)*deltas[i+1].delta;if(nextDeltaRo
unded/deltas[i].delta>=1){return Math.round(n/deltas[i].delta)+deltas[i].units}}
var i=deltas.length-1;return Math.round(n/deltas[i].delta)+deltas[i].units}sk.hu
man.localeTime=function(date){var str=date.toString();var timezone=str.substring
(str.indexOf("("));return date.toLocaleString()+" "+timezone};sk.now=function(){
return Math.round((new Date).getTime()/1e3)};sk.array={};sk.array.equal=function
(a,b){if(a.length!=b.length){return false}for(var i=0,len=a.length;i<len;i++){if
(a[i]!==b[i]){return false}}return true};sk.formatHTML=function(s,linksInNewWind
ow){var sub='<a href="$&">$&</a>';if(linksInNewWindow){sub='<a href="$&" target=
"_blank">$&</a>'}s=s.replace(/https?:(\/\/|//)[^ \t\n<]*/g,sub).replac
e(/(?:\r\n|\n|\r)/g,"<br/>");return sk.linkifyBugs(s)};var PROJECTS_TO_ISSUETRAC
KERS={chromium:"http://crbug.com/",skia:"http://skbug.com/"};sk.linkifyBugs=func
tion(s){for(var project in PROJECTS_TO_ISSUETRACKERS){var re=new RegExp(project+
":[0-9]+","g");var found_bugs=s.match(re);if(found_bugs){found_bugs.forEach(func
tion(found_bug){var bug_number=found_bug.split(":")[1];var bug_link='<a href="'+
PROJECTS_TO_ISSUETRACKERS[project]+bug_number+'" target="_blank">'+found_bug+"</
a>";s=s.replace(found_bug,bug_link)})}}return s};sk.isGoogler=function(email){re
turn email&&email.endsWith("@google.com")};sk.query={};sk.query.fromParamSet=fun
ction(o){if(!o){return""}var ret=[];var keys=Object.keys(o).sort();keys.forEach(
function(key){o[key].forEach(function(value){ret.push(encodeURIComponent(key)+"=
"+encodeURIComponent(value))})});return ret.join("&")};sk.query.toParamSet=funct
ion(s){s=s||"";var ret={};var vars=s.split("&");for(var i=0;i<vars.length;i++){v
ar pair=vars[i].split("=",2);if(pair.length==2){var key=decodeURIComponent(pair[
0]); | 2 }):s(e)}function s(e){e.__upgraded__&&!e.__attached&&(e.__attached=!0,e.attached
Callback&&e.attachedCallback())}function c(e){d(e),g(e,function(e){d(e)})}functi
on d(e){y?r(function(){l(e)}):l(e)}function l(e){e.__upgraded__&&e.__attached&&(
e.__attached=!1,e.detachedCallback&&e.detachedCallback())}function u(e){for(var
t=e,n=window.wrap(document);t;){if(t==n)return!0;t=t.parentNode||t.nodeType===No
de.DOCUMENT_FRAGMENT_NODE&&t.host}}function h(e){if(e.shadowRoot&&!e.shadowRoot.
__watched){_.dom&&console.log("watching shadow-root for: ",e.localName);for(var
t=e.shadowRoot;t;)m(t),t=t.olderShadowRoot}}function f(e,n){if(_.dom){var o=n[0]
;if(o&&"childList"===o.type&&o.addedNodes&&o.addedNodes){for(var r=o.addedNodes[
0];r&&r!==document&&!r.host;)r=r.parentNode;var i=r&&(r.URL||r._URL||r.host&&r.h
ost.localName)||"";i=i.split("/?").shift().split("/").pop()}console.group("mutat
ions (%d) [%s]",n.length,i||"")}var a=u(e);n.forEach(function(e){"childList"===e
.type&&(N(e.addedNodes,function(e){e.localName&&t(e,a)}),N(e.removedNodes,functi
on(e){e.localName&&c(e)}))}),_.dom&&console.groupEnd()}function p(e){for(e=windo
w.wrap(e),e||(e=window.wrap(document));e.parentNode;)e=e.parentNode;var t=e.__ob
server;t&&(f(e,t.takeRecords()),i())}function m(e){if(!e.__observer){var t=new M
utationObserver(f.bind(this,e));t.observe(e,{childList:!0,subtree:!0}),e.__obser
ver=t}}function v(e){e=window.wrap(e),_.dom&&console.group("upgradeDocument: ",e
.baseURI.split("/").pop());var n=e===window.wrap(document);t(e,n),m(e),_.dom&&co
nsole.groupEnd()}function w(e){b(e,v)}var _=e.flags,g=e.forSubtree,b=e.forDocume
ntTree,y=window.MutationObserver._isPolyfilled&&_["throttle-attached"];e.hasPoly
fillMutations=y,e.hasThrottledAttached=y;var E=!1,L=[],N=Array.prototype.forEach
.call.bind(Array.prototype.forEach),M=Element.prototype.createShadowRoot;M&&(Ele
ment.prototype.createShadowRoot=function(){var e=M.call(this);return window.Cust
omElements.watchShadow(this),e}),e.watchShadow=h,e.upgradeDocumentTree=w,e.upgra
deDocument=v,e.upgradeSubtree=o,e.upgradeAll=t,e.attached=a,e.takeRecords=p}),wi
ndow.CustomElements.addModule(function(e){function t(t,o){if("template"===t.loca
lName&&window.HTMLTemplateElement&&HTMLTemplateElement.decorate&&HTMLTemplateEle
ment.decorate(t),!t.__upgraded__&&t.nodeType===Node.ELEMENT_NODE){var r=t.getAtt
ribute("is"),i=e.getRegisteredDefinition(t.localName)||e.getRegisteredDefinition
(r);if(i&&(r&&i.tag==t.localName||!r&&!i["extends"]))return n(t,i,o)}}function n
(t,n,r){return a.upgrade&&console.group("upgrade:",t.localName),n.is&&t.setAttri
bute("is",n.is),o(t,n),t.__upgraded__=!0,i(t),r&&e.attached(t),e.upgradeSubtree(
t,r),a.upgrade&&console.groupEnd(),t}function o(e,t){Object.__proto__?e.__proto_
_=t.prototype:(r(e,t.prototype,t["native"]),e.__proto__=t.prototype)}function r(
e,t,n){for(var o={},r=t;r!==n&&r!==HTMLElement.prototype;){for(var i,a=Object.ge
tOwnPropertyNames(r),s=0;i=a[s];s++)o[i]||(Object.defineProperty(e,i,Object.getO
wnPropertyDescriptor(r,i)),o[i]=1);r=Object.getPrototypeOf(r)}}function i(e){e.c
reatedCallback&&e.createdCallback()}var a=e.flags;e.upgrade=t,e.upgradeWithDefin
ition=n,e.implementPrototype=o}),window.CustomElements.addModule(function(e){fun
ction t(t,o){var c=o||{};if(!t)throw new Error("document.registerElement: first
argument `name` must not be empty");if(t.indexOf("-")<0)throw new Error("documen
t.registerElement: first argument ('name') must contain a dash ('-'). Argument p
rovided was '"+String(t)+"'.");if(r(t))throw new Error("Failed to execute 'regis
terElement' on 'Document': Registration failed for type '"+String(t)+"'. The typ
e name is invalid.");if(d(t))throw new Error("DuplicateDefinitionError: a type w
ith name '"+String(t)+"' is already registered");return c.prototype||(c.prototyp
e=Object.create(HTMLElement.prototype)),c.__name=t.toLowerCase(),c["extends"]&&(
c["extends"]=c["extends"].toLowerCase()),c.lifecycle=c.lifecycle||{},c.ancestry=
i(c["extends"]),a(c),s(c),n(c.prototype),l(c.__name,c),c.ctor=u(c),c.ctor.protot
ype=c.prototype,c.prototype.constructor=c.ctor,e.ready&&v(document),c.ctor}funct
ion n(e){if(!e.setAttribute._polyfilled){var t=e.setAttribute;e.setAttribute=fun
ction(e,n){o.call(this,e,n,t)};var n=e.removeAttribute;e.removeAttribute=functio
n(e){o.call(this,e,null,n)},e.setAttribute._polyfilled=!0}}function o(e,t,n){e=e
.toLowerCase();var o=this.getAttribute(e);n.apply(this,arguments);var r=this.get
Attribute(e);this.attributeChangedCallback&&r!==o&&this.attributeChangedCallback
(e,o,r)}function r(e){for(var t=0;t<y.length;t++)if(e===y[t])return!0}function i
(e){var t=d(e);return t?i(t["extends"]).concat([t]):[]}function a(e){for(var t,n
=e["extends"],o=0;t=e.ancestry[o];o++)n=t.is&&t.tag;e.tag=n||e.__name,n&&(e.is=e
.__name)}function s(e){if(!Object.__proto__){var t=HTMLElement.prototype;if(e.is
){var n=document.createElement(e.tag);t=Object.getPrototypeOf(n)}for(var o,r=e.p
rototype,i=!1;r;)r==t&&(i=!0),o=Object.getPrototypeOf(r),o&&(r.__proto__=o),r=o;
i||console.warn(e.tag+" prototype not found in prototype chain for "+e.is),e["na
tive"]=t}}function c(e){return _(N(e.tag),e)}function d(e){if(e)return E[e.toLow
erCase()]}function l(e,t){E[e]=t}function u(e){return function(){return c(e)}}fu
nction h(e,t,n){return e===L?f(t,n):M(e,t)}function f(e,t){e&&(e=e.toLowerCase()
),t&&(t=t.toLowerCase());var n=d(t||e);if(n){if(e==n.tag&&t==n.is)return new n.c
tor;if(!t&&!n.is)return new n.ctor}var o;return t?(o=f(e),o.setAttribute("is",t)
,o):(o=N(e),e.indexOf("-")>=0&&g(o,HTMLElement),o)}function p(e,t){var n=e[t];e[
t]=function(){var e=n.apply(this,arguments);return w(e),e}}var m,v=(e.isIE,e.upg
radeDocumentTree),w=e.upgradeAll,_=e.upgradeWithDefinition,g=e.implementPrototyp
e,b=e.useNative,y=["annotation-xml","color-profile","font-face","font-face-src",
"font-face-uri","font-face-format","font-face-name","missing-glyph"],E={},L="htt
p://www.w3.org/1999/xhtml",N=document.createElement.bind(document),M=document.cr
eateElementNS.bind(document);m=Object.__proto__||b?function(e,t){return e instan
ceof t}:function(e,t){if(e instanceof t)return!0;for(var n=e;n;){if(n===t.protot
ype)return!0;n=n.__proto__}return!1},p(Node.prototype,"cloneNode"),p(document,"i
mportNode"),document.registerElement=t,document.createElement=f,document.createE
lementNS=h,e.registry=E,e["instanceof"]=m,e.reservedTagList=y,e.getRegisteredDef
inition=d,document.register=document.registerElement}),function(e){function t(){
i(window.wrap(document)),window.CustomElements.ready=!0;var e=window.requestAnim
ationFrame||function(e){setTimeout(e,16)};e(function(){setTimeout(function(){win
dow.CustomElements.readyTime=Date.now(),window.HTMLImports&&(window.CustomElemen
ts.elapsed=window.CustomElements.readyTime-window.HTMLImports.readyTime),documen
t.dispatchEvent(new CustomEvent("WebComponentsReady",{bubbles:!0}))})})}var n=e.
useNative,o=e.initializeModules;e.isIE;if(n){var r=function(){};e.watchShadow=r,
e.upgrade=r,e.upgradeAll=r,e.upgradeDocumentTree=r,e.upgradeSubtree=r,e.takeReco
rds=r,e["instanceof"]=function(e,t){return e instanceof t}}else o();var i=e.upgr
adeDocumentTree,a=e.upgradeDocument;if(window.wrap||(window.ShadowDOMPolyfill?(w
indow.wrap=window.ShadowDOMPolyfill.wrapIfNeeded,window.unwrap=window.ShadowDOMP
olyfill.unwrapIfNeeded):window.wrap=window.unwrap=function(e){return e}),window.
HTMLImports&&(window.HTMLImports.__importsParsingHook=function(e){e["import"]&&a
(wrap(e["import"]))}),"complete"===document.readyState||e.flags.eager)t();else i
f("interactive"!==document.readyState||window.attachEvent||window.HTMLImports&&!
window.HTMLImports.ready){var s=window.HTMLImports&&!window.HTMLImports.ready?"H
TMLImportsLoaded":"DOMContentLoaded";window.addEventListener(s,t)}else t()}(wind
ow.CustomElements),function(e){var t=document.createElement("style");t.textConte
nt="body {transition: opacity ease-in 0.2s; } \nbody[unresolved] {opacity: 0; di
splay: block; overflow: hidden; position: relative; } \n";var n=document.querySe
lector("head");n.insertBefore(t,n.firstChild)}(window.WebComponents);(function()
{var customUtils={};function getRandomArray(n){var res,next;if(n===0){return[]}i
f(n===1){return[0]}res=getRandomArray(n-1);next=Math.floor(Math.random()*n);res.
splice(next,0,n-1);return res}customUtils.getRandomArray=getRandomArray;function
defaultCompareKeysFunction(a,b){if(a<b){return-1}if(a>b){return 1}if(a===b){ret
urn 0}throw{message:"Couldn't compare elements",a:a,b:b}}customUtils.defaultComp
areKeysFunction=defaultCompareKeysFunction;function defaultCheckValueEquality(a,
b){return a===b}customUtils.defaultCheckValueEquality=defaultCheckValueEquality;
function BinarySearchTree(options){options=options||{};this.left=null;this.right
=null;this.parent=options.parent!==undefined?options.parent:null;if(options.hasO
wnProperty("key")){this.key=options.key}this.data=options.hasOwnProperty("value"
)?[options.value]:[];this.unique=options.unique||false;this.compareKeys=options.
compareKeys||customUtils.defaultCompareKeysFunction;this.checkValueEquality=opti
ons.checkValueEquality||customUtils.defaultCheckValueEquality}BinarySearchTree.p
rototype.getMaxKeyDescendant=function(){if(this.right){return this.right.getMaxK
eyDescendant()}else{return this}};BinarySearchTree.prototype.getMaxKey=function(
){return this.getMaxKeyDescendant().key};BinarySearchTree.prototype.getMinKeyDes
cendant=function(){if(this.left){return this.left.getMinKeyDescendant()}else{ret
urn this}};BinarySearchTree.prototype.getMinKey=function(){return this.getMinKey
Descendant().key};BinarySearchTree.prototype.checkAllNodesFullfillCondition=func
tion(test){if(!this.hasOwnProperty("key")){return}test(this.key,this.data);if(th
is.left){this.left.checkAllNodesFullfillCondition(test)}if(this.right){this.righ
t.checkAllNodesFullfillCondition(test)}};BinarySearchTree.prototype.checkNodeOrd
ering=function(){var self=this;if(!this.hasOwnProperty("key")){return}if(this.le
ft){this.left.checkAllNodesFullfillCondition(function(k){if(self.compareKeys(k,s
elf.key)>=0){throw"Tree with root "+self.key+" is not a binary search tree"}});t
his.left.checkNodeOrdering()}if(this.right){this.right.checkAllNodesFullfillCond
ition(function(k){if(self.compareKeys(k,self.key)<=0){throw"Tree with root "+sel
f.key+" is not a binary search tree"}});this.right.checkNodeOrdering()}};BinaryS
earchTree.prototype.checkInternalPointers=function(){if(this.left){if(this.left.
parent!==this){throw"Parent pointer broken for key "+this.key}this.left.checkInt
ernalPointers()}if(this.right){if(this.right.parent!==this){throw"Parent pointer
broken for key "+this.key}this.right.checkInternalPointers()}};BinarySearchTree
.prototype.checkIsBST=function(){this.checkNodeOrdering();this.checkInternalPoin
ters();if(this.parent){throw"The root shouldn't have a parent"}};BinarySearchTre
e.prototype.getNumberOfKeys=function(){var res;if(!this.hasOwnProperty("key")){r
eturn 0}res=1;if(this.left){res+=this.left.getNumberOfKeys()}if(this.right){res+
=this.right.getNumberOfKeys()}return res};BinarySearchTree.prototype.createSimil
ar=function(options){options=options||{};options.unique=this.unique;options.comp
areKeys=this.compareKeys;options.checkValueEquality=this.checkValueEquality;retu
rn new this.constructor(options)};BinarySearchTree.prototype.createLeftChild=fun
ction(options){var leftChild=this.createSimilar(options);leftChild.parent=this;t
his.left=leftChild;return leftChild};BinarySearchTree.prototype.createRightChild
=function(options){var rightChild=this.createSimilar(options);rightChild.parent=
this;this.right=rightChild;return rightChild};BinarySearchTree.prototype.insert=
function(key,value){if(!this.hasOwnProperty("key")){this.key=key;this.data.push(
value);return}if(this.compareKeys(this.key,key)===0){if(this.unique){throw{messa
ge:"Can't insert key "+key+", it violates the unique constraint",key:key,errorTy
pe:"uniqueViolated"}}else{this.data.push(value)}return}if(this.compareKeys(key,t
his.key)<0){if(this.left){this.left.insert(key,value)}else{this.createLeftChild(
{key:key,value:value})}}else{if(this.right){this.right.insert(key,value)}else{th
is.createRightChild({key:key,value:value})}}};BinarySearchTree.prototype.search=
function(key){if(!this.hasOwnProperty("key")){return[]}if(this.compareKeys(this.
key,key)===0){return this.data}if(this.compareKeys(key,this.key)<0){if(this.left
){return this.left.search(key)}else{return[]}}else{if(this.right){return this.ri
ght.search(key)}else{return[]}}};BinarySearchTree.prototype.getLowerBoundMatcher
=function(query){var self=this;if(!query.hasOwnProperty("$gt")&&!query.hasOwnPro
perty("$gte")){return function(){return true}}if(query.hasOwnProperty("$gt")&&qu
ery.hasOwnProperty("$gte")){if(self.compareKeys(query.$gte,query.$gt)===0){retur
n function(key){return self.compareKeys(key,query.$gt)>0}}if(self.compareKeys(qu
ery.$gte,query.$gt)>0){return function(key){return self.compareKeys(key,query.$g
te)>=0}}else{return function(key){return self.compareKeys(key,query.$gt)>0}}}if(
query.hasOwnProperty("$gt")){return function(key){return self.compareKeys(key,qu
ery.$gt)>0}}else{return function(key){return self.compareKeys(key,query.$gte)>=0
}}};BinarySearchTree.prototype.getUpperBoundMatcher=function(query){var self=thi
s;if(!query.hasOwnProperty("$lt")&&!query.hasOwnProperty("$lte")){return functio
n(){return true}}if(query.hasOwnProperty("$lt")&&query.hasOwnProperty("$lte")){i
f(self.compareKeys(query.$lte,query.$lt)===0){return function(key){return self.c
ompareKeys(key,query.$lt)<0}}if(self.compareKeys(query.$lte,query.$lt)<0){return
function(key){return self.compareKeys(key,query.$lte)<=0}}else{return function(
key){return self.compareKeys(key,query.$lt)<0}}}if(query.hasOwnProperty("$lt")){
return function(key){return self.compareKeys(key,query.$lt)<0}}else{return funct
ion(key){return self.compareKeys(key,query.$lte)<=0}}};function append(array,toA
ppend){var i;for(i=0;i<toAppend.length;i+=1){array.push(toAppend[i])}}BinarySear
chTree.prototype.betweenBounds=function(query,lbm,ubm){var res=[];if(!this.hasOw
nProperty("key")){return[]}lbm=lbm||this.getLowerBoundMatcher(query);ubm=ubm||th
is.getUpperBoundMatcher(query);if(lbm(this.key)&&this.left){append(res,this.left
.betweenBounds(query,lbm,ubm))}if(lbm(this.key)&&ubm(this.key)){append(res,this.
data)}if(ubm(this.key)&&this.right){append(res,this.right.betweenBounds(query,lb
m,ubm))}return res};BinarySearchTree.prototype.deleteIfLeaf=function(){if(this.l
eft||this.right){return false}if(!this.parent){delete this.key;this.data=[];retu
rn true}if(this.parent.left===this){this.parent.left=null}else{this.parent.right
=null}return true};BinarySearchTree.prototype.deleteIfOnlyOneChild=function(){va
r child;if(this.left&&!this.right){child=this.left}if(!this.left&&this.right){ch
ild=this.right}if(!child){return false}if(!this.parent){this.key=child.key;this.
data=child.data;this.left=null;if(child.left){this.left=child.left;child.left.pa
rent=this}this.right=null;if(child.right){this.right=child.right;child.right.par
ent=this}return true}if(this.parent.left===this){this.parent.left=child;child.pa
rent=this.parent}else{this.parent.right=child;child.parent=this.parent}return tr
ue};BinarySearchTree.prototype.delete=function(key,value){var newData=[],replace
With,self=this;if(!this.hasOwnProperty("key")){return}if(this.compareKeys(key,th
is.key)<0){if(this.left){this.left.delete(key,value)}return}if(this.compareKeys(
key,this.key)>0){if(this.right){this.right.delete(key,value)}return}if(!this.com
pareKeys(key,this.key)===0){return}if(this.data.length>1&&value!==undefined){thi
s.data.forEach(function(d){if(!self.checkValueEquality(d,value)){newData.push(d)
}});self.data=newData;return}if(this.deleteIfLeaf()){return}if(this.deleteIfOnly
OneChild()){return}if(Math.random()>=.5){replaceWith=this.left.getMaxKeyDescenda
nt();this.key=replaceWith.key;this.data=replaceWith.data;if(this===replaceWith.p
arent){this.left=replaceWith.left;if(replaceWith.left){replaceWith.left.parent=r
eplaceWith.parent}}else{replaceWith.parent.right=replaceWith.left;if(replaceWith
.left){replaceWith.left.parent=replaceWith.parent}}}else{replaceWith=this.right.
getMinKeyDescendant();this.key=replaceWith.key;this.data=replaceWith.data;if(thi
s===replaceWith.parent){this.right=replaceWith.right;if(replaceWith.right){repla
ceWith.right.parent=replaceWith.parent}}else{replaceWith.parent.left=replaceWith
.right;if(replaceWith.right){replaceWith.right.parent=replaceWith.parent}}}};Bin
arySearchTree.prototype.executeOnEveryNode=function(fn){if(this.left){this.left.
executeOnEveryNode(fn)}fn(this);if(this.right){this.right.executeOnEveryNode(fn)
}};BinarySearchTree.prototype.prettyPrint=function(printData,spacing){spacing=sp
acing||"";console.log(spacing+"* "+this.key);if(printData){console.log(spacing+"
* "+this.data)}if(!this.left&&!this.right){return}if(this.left){this.left.pretty
Print(printData,spacing+" ")}else{console.log(spacing+" *")}if(this.right){thi
s.right.prettyPrint(printData,spacing+" ")}else{console.log(spacing+" *")}};fu
nction SuffixTrie(options){this.options=options||{};this.structure={};this.debug
=this.options.debug===undefined?false:options.debug;this.minLENGTH=this.options.
minLength===undefined?3:options.minLength;this.minOccurrence=this.options.minOcc
urrence===undefined?2:options.minOccurrence;this.isByLength=this.options.byLengt
h===undefined?false:options.byLength;this.save=[];this.array=null;this.labelArra
y=null;this.fragmentsArray=null;this.fragmentTrie={};this.rebuildArray}SuffixTri
e.prototype.refresh=function(){this.structure={};this.save=[];this.array=null;th
is.labelArray=null;this.fragmentsArray=null;this.fragmentTrie={};this.rebuildArr
ay};SuffixTrie.prototype.weigh=function(){if(this.isByLength){return this.weighB
yMax()}else{return this.weighByAverage()}};SuffixTrie.prototype.build=function(a
rray){var debug=this.debug;this.buildLabelTrie(array);this.optimize(this.structu
re);if(debug)console.log("after optimization our label trie of array length "+th
is.array.length+" is ",this.structure);this.listLabel();if(debug)console.log("ge
t the compressed label array (without duplicate fragments ) of array length "+th
is.array.length+" is ",this.labelArray);if(debug)console.log("and fragments arra
y of length "+this.fragmentsArray.length+" is ",this.fragmentsArray);this.clearR
edundantFragment();if(debug)console.log("get the cleared label array (without du
plicate fragments ) of array length "+this.array.length+" is ",this.labelArray);
if(debug)console.log("and cleared fragments array of length "+this.fragmentsArra
y.length+" is ",this.fragmentsArray);this.rebuild();if(debug)console.log("rebuil
d ended",this.rebuildArray)};SuffixTrie.prototype.buildLabelTrie=function(array)
{this.array=array;var root=this.structure;var LENGTH=this.minLENGTH;array.forEac
h(function(word,index){var first=true;var last={};for(var i=0,l=word.length;i<=l
-LENGTH;i++){var cur=root;var suffix=word.substring(i);var letters=suffix.split(
"");for(var j=0;j<letters.length;j++){var letter=letters[j],pos=cur[letter];if(j
===letters.length-1){if(pos==null){cur[letter]={source:[index],listed:false}}els
e if(pos.hasOwnProperty("source")){pos["source"].push(index)}else{cur[letter]["s
ource"]=[index];cur[letter]["listed"]=false}cur=cur[letter];if(!first){last["nex
t"]=suffix}else{first=false}last=cur}else if(pos==null){cur=cur[letter]={}}else{
cur=cur[letter]}}}})};SuffixTrie.prototype.optimize=function(root,rootLevel){var
occurrence=this.minOccurrence;var self_save=[];rootLevel=rootLevel===undefined?
-1:rootLevel;rootLevel++;var is_allowed=rootLevel>=this.minLENGTH;for(var child
in root){if(root.hasOwnProperty(child)){if(child.length===1){var children_save=t
his.optimize(root[child],rootLevel);if(is_allowed){self_save=self_save.concat(ch
ildren_save)}}else if(child==="source"&&is_allowed){self_save=self_save.concat(r
oot["source"])}}}self_save=uniqueArray(self_save);var isEnoughOccurred=self_save
.length>=occurrence;is_allowed=is_allowed&&isEnoughOccurred;if(is_allowed){var i
s_SoleNode=Object.keys(root).length===1;if(!is_SoleNode){root["source"]=self_sav
e;root["level"]=rootLevel;root["listed"]=false;root["weight"]=self_save.length*r
ootLevel;self_save=[]}else{}}else{delete root["source"]}return self_save};Suffix
Trie.prototype.listLabel=function(start){var array=this.array;var root=this.stru
cture;var label_array=[];var fragments_array=[];var length=this.minLENGTH;var oc
currence=this.minOccurrence;start=start===undefined?1:start;for(var index=start-
1,i=0;i<array.length;index++,index=index%array.length,i++){var word=array[index]
;var fragments={};if(word.length<length){label_array.push(fragments);continue}fi
ndFragments(word,fragments,root,length,occurrence,false);for(var fragment in fra
gments){if(fragments.hasOwnProperty(fragment)){var fragmentsArrayIndex=fragments
_array.push(fragments[fragment])-1;fragments_array[fragmentsArrayIndex]["name"]=
fragment}}label_array.push(fragments)}this.labelArray=label_array;this.fragments
Array=fragments_array;return label_array};SuffixTrie.prototype.rebuild=function(
){var rebuildArray=JSON.parse(JSON.stringify(this.labelArray));rebuildArray.forE
ach(function(object,index){for(var fragment in object){if(object.hasOwnProperty(
fragment)){object[fragment]["source"].forEach(function(labelIndex){if(labelIndex
>index){rebuildArray[labelIndex][fragment]=object[fragment]}})}}});this.rebuildA
rray=rebuildArray};SuffixTrie.prototype.weighByAverage=function(){var debug=this
.debug;var fragmentsArray=this.fragmentsArray;var fragments_Num=this.fragmentsAr
ray.length;fragmentsArray.sort(function(f1,f2){return f2["weight"]-f1["weight"]}
);if(debug)console.log("weigh by average: result of length "+fragments_Num+" is
",fragmentsArray);if(typeof this.options.limit=="number")fragments_Num=this.opti
ons.limit<fragments_Num?this.options.limit:fragments_Num;return fragmentsArray.s
lice(0,fragments_Num)};SuffixTrie.prototype.weighByMax=function(){var debug=this
.debug;buildFragmentTrie(this.fragmentTrie,this.fragmentsArray);var rebuildArray
=JSON.parse(JSON.stringify(this.rebuildArray));var fragmentsArray=[];var fragmen
tsTrie=this.fragmentTrie;var fragments_Num=this.fragmentsArray.length;var label_
Lengths=this.array.map(function(s){return s.length});var label_Tree=new BinarySe
archTree;label_Lengths.forEach(function(length,index){label_Tree.insert(length,i
ndex)});if(typeof this.options.limit=="number")fragments_Num=this.options.limit<
fragments_Num?this.options.limit:fragments_Num;while(fragmentsArray.length<fragm
ents_Num){var maxKey=label_Tree.getMaxKey();var labels_In_Key=label_Tree.search(
maxKey);if(labels_In_Key.length===0){label_Tree.delete(maxKey);continue}var long
est_Label=labels_In_Key[0];var fragments=Object.keys(rebuildArray[longest_Label]
);if(fragments.length>0){fragments.sort(function(f1,f2){return f2.length-f1.leng
th});removeTrie(fragments[0],fragmentsTrie,fragmentsArray,label_Lengths,rebuildA
rray,label_Tree)}label_Tree.delete(maxKey,longest_Label)}this.fragmentsArray=fra
gmentsArray;if(debug)console.log("weigh by max: result of length "+fragmentsArr
ay.length+" is",fragmentsArray);return fragmentsArray.slice(0,fragments_Num)};Su
ffixTrie.prototype.clearRedundantFragment=function(){var fragments=this.fragment
sArray;var occurrence=this.minOccurrence;var newFragmentArray=[];var labelArray=
this.labelArray;fragments.sort(function(a,b){return a.name.length-b.name.length}
);fragments.forEach(function(fragment,index){var backupsource=fragment.source.sl
ice();for(var i=index+1;i<fragments.length;i++){var longerFragment=fragments[i];
if(longerFragment.name.indexOf(fragment.name)!==-1){fragment.source=fragment.sou
rce.filter(function(i){return this.indexOf(i)===-1},longerFragment.source)}}if(f
ragment.source.length>=occurrence){newFragmentArray.push(fragment)}else{if(backu
psource.length!==fragment.source.length){deleteFragmentInLabelArray(backupsource
,fragment.name,labelArray)}}});this.fragmentsArray=newFragmentArray};function fi
ndFragments(word,fragments,root,length,occurrence,iterate){var cur=root;var lett
ers=word.split("");for(var j=0;j<letters.length;j++){var letter=letters[j],pos=c
ur[letter];if(j+1>=length){var fragment=word.substring(0,j+1);if(pos.hasOwnPrope
rty("listed")){if(!pos["listed"]){if(pos.hasOwnProperty("source")){fragments[fra
gment]={};fragments[fragment]["source"]=pos.source;fragments[fragment]["weight"]
=pos["weight"];if(pos["weight"]==null){console.warn("escape case! fragment does
not has weight property, node is ",fragments[fragment])}if(fragments.hasOwnPrope
rty(fragment)){if(iterate){for(var property in fragments){if(property!==fragment
&&fragments.hasOwnProperty(property)&&fragments.hasOwnProperty(fragment)){if(pro
perty.indexOf(fragment)!==-1){fragments[fragment]["source"]=fragments[fragment][
"source"].filter(function(i){return this.indexOf(i)<0},fragments[property].sourc
e)}}}if(fragments[fragment]["source"].length<occurrence){delete fragments[fragme
nt]}}}pos["listed"]=true}if(pos.hasOwnProperty("next")){findFragments(pos["next"
],fragments,root,length,occurrence,true)}}}}cur=pos}}function deleteFragmentInLa
belArray(source,name,labelArray){var label=labelArray[source[0]];if(label.hasOwn
Property(name)){delete label[name]}}function buildFragmentTrie(trie,array){for(v
ar i=0;i<array.length;i++){var word=array[i]["name"],letters=word.split(""),cur=
trie;for(var j=0;j<letters.length;j++){var letter=letters[j];if(!cur.hasOwnPrope
rty(letter)){cur[letter]={}}cur=cur[letter];if(j===letters.length-1){cur["source
"]=array[i]["source"];cur["name"]=array[i]["name"];cur["weight"]=array[i]["weigh
t"];cur["list"]=false}}}}function removeTrie(word,cur,array,labelLengthArray,reb
uildArray,label_trie){for(var node in cur){if(cur.hasOwnProperty(node)&&node.len
gth===1){if(word.indexOf(node)===0){if(word.length===1){if(cur[node].hasOwnPrope
rty("list")){var fragment={};fragment["source"]=cur[node]["source"];var fragment
Name=cur[node]["name"];fragment["name"]=fragmentName;fragment["weight"]=cur[node
]["weight"];delete cur[node]["list"];array.push(fragment);cur[node]["source"].fo
rEach(function(indexLabel){delete rebuildArray[indexLabel][fragmentName];var lab
elLength=labelLengthArray[indexLabel];label_trie.delete(labelLength,indexLabel);
labelLength-=fragmentName.length;label_trie.insert(labelLength,indexLabel)})}}el
se{removeTrie(word.slice(1),cur[node],array,labelLengthArray,rebuildArray,label_
trie)}}}}}function uniqueArray(array){var a=array.concat();for(var i=0;i<a.lengt
h;++i){for(var j=i+1;j<a.length;++j){if(a[i]===a[j])a.splice(j--,1)}}return a}wi
ndow.Substrings=SuffixTrie})();function $$(query,ele){if(!ele){ele=document}retu
rn Array.prototype.map.call(ele.querySelectorAll(query),function(e){return e})}f
unction $$$(query,ele){if(!ele){ele=document}return ele.querySelector(query)}thi
s.sk=this.sk||function(){"use strict";var sk={};sk.clearChildren=function(ele){w
hile(ele.firstChild){ele.removeChild(ele.firstChild)}};sk.findParent=function(el
e,nodeName){while(ele!=null){if(ele.nodeName==nodeName){return ele}ele=ele.paren
tElement}return null};sk.errorMessage=function(message,duration){if(typeof messa
ge==="object"){message=message.response||JSON.stringify(message)}var detail={mes
sage:message};detail.duration=duration;document.dispatchEvent(new CustomEvent("e
rror-sk",{detail:detail,bubbles:true}))};sk.Importer=function(){if("currentScrip
t"in document){this.importDoc_=document.currentScript.ownerDocument}else{this.im
portDoc_=document._currentScript.ownerDocument}};sk.Importer.prototype.import=fu
nction(id){return document.importNode($$$(id,this.importDoc_).content,true)};sk.
elePos=function(ele){var bounds=ele.getBoundingClientRect();return{x:bounds.left
,y:bounds.top}};sk.request=function(method,url,body,headers){return new Promise(
function(resolve,reject){var req=new XMLHttpRequest;req.open(method,url);if(head
ers){for(var k in headers){req.setRequestHeader(k,headers[k])}}req.onload=functi
on(){if(req.status==200){resolve(req.response)}else{reject({response:req.respons
e,status:req.status})}};req.onerror=function(){reject({response:Error("Network E
rror")})};req.send(body)})};sk.get=function(url){return sk.request("GET",url)};s
k.post=function(url,body,content_type){if(!content_type){content_type="applicati
on/json"}return sk.request("POST",url,body,{"Content-Type":content_type})};sk.de
lete=function(url,body){return sk.request("DELETE",url,body)};sk.DomReady=new Pr
omise(function(resolve,reject){if(document.readyState!="loading"){resolve()}else
{document.addEventListener("DOMContentLoaded",resolve)}});sk.WebComponentsReady=
new Promise(function(resolve,reject){window.addEventListener("polymer-ready",res
olve)});var _Mailbox=function(){this.boxes={}};_Mailbox.prototype.subscribe=func
tion(addr,cb){var box=this.boxes[addr]||{callbacks:[],value:null};box.callbacks.
push(cb);cb(box.value);this.boxes[addr]=box};_Mailbox.prototype.unsubscribe=func
tion(addr,cb){var box=this.boxes[addr]||{callbacks:[],value:null};for(var i=box.
callbacks.length-1;i>=0;i--){if(box.callbacks[i]==cb){box.callbacks.splice(i,1)}
}};_Mailbox.prototype.send=function(addr,value){var box=this.boxes[addr]||{callb
acks:[],value:null};box.value=value;this.boxes[addr]=box;box.callbacks.forEach(f
unction(cb){cb(value)})};sk.Mailbox=new _Mailbox;sk.human={};var TIME_DELTAS=[{u
nits:"w",delta:7*24*60*60},{units:"d",delta:24*60*60},{units:"h",delta:60*60},{u
nits:"m",delta:60},{units:"s",delta:1}];sk.KB=1024;sk.MB=sk.KB*1024;sk.GB=sk.MB*
1024;sk.TB=sk.GB*1024;sk.PB=sk.TB*1024;var BYTES_DELTAS=[{units:" PB",delta:sk.P
B},{units:" TB",delta:sk.TB},{units:" GB",delta:sk.GB},{units:" MB",delta:sk.MB}
,{units:" KB",delta:sk.KB},{units:" B",delta:1}];sk.human.pad=function(num,size)
{var str=num+"";while(str.length<size)str="0"+str;return str};sk.human.strDurati
on=function(seconds){if(seconds<0){seconds=-seconds}if(seconds==0){return" 0s"}
var rv="";for(var i=0;i<TIME_DELTAS.length;i++){if(TIME_DELTAS[i].delta<=seconds
){var s=Math.floor(seconds/TIME_DELTAS[i].delta)+TIME_DELTAS[i].units;while(s.le
ngth<4){s=" "+s}rv+=s;seconds=seconds%TIME_DELTAS[i].delta}}return rv};sk.human.
diffDate=function(s){var ms=typeof s=="number"?s:Date.parse(s);var diff=(ms-Date
.now())/1e3;if(diff<0){diff=-1*diff}return humanize(diff,TIME_DELTAS)};sk.human.
bytes=function(b,unit){if(Number.isInteger(unit)){b=b*unit}return humanize(b,BYT
ES_DELTAS)};function humanize(n,deltas){for(var i=0;i<deltas.length-1;i++){var n
extDeltaRounded=Math.round(n/deltas[i+1].delta)*deltas[i+1].delta;if(nextDeltaRo
unded/deltas[i].delta>=1){return Math.round(n/deltas[i].delta)+deltas[i].units}}
var i=deltas.length-1;return Math.round(n/deltas[i].delta)+deltas[i].units}sk.hu
man.localeTime=function(date){var str=date.toString();var timezone=str.substring
(str.indexOf("("));return date.toLocaleString()+" "+timezone};sk.now=function(){
return Math.round((new Date).getTime()/1e3)};sk.array={};sk.array.equal=function
(a,b){if(a.length!=b.length){return false}for(var i=0,len=a.length;i<len;i++){if
(a[i]!==b[i]){return false}}return true};sk.formatHTML=function(s,linksInNewWind
ow){var sub='<a href="$&">$&</a>';if(linksInNewWindow){sub='<a href="$&" target=
"_blank">$&</a>'}s=s.replace(/https?:(\/\/|//)[^ \t\n<]*/g,sub).replac
e(/(?:\r\n|\n|\r)/g,"<br/>");return sk.linkifyBugs(s)};var PROJECTS_TO_ISSUETRAC
KERS={chromium:"http://crbug.com/",skia:"http://skbug.com/"};sk.linkifyBugs=func
tion(s){for(var project in PROJECTS_TO_ISSUETRACKERS){var re=new RegExp(project+
":[0-9]+","g");var found_bugs=s.match(re);if(found_bugs){found_bugs.forEach(func
tion(found_bug){var bug_number=found_bug.split(":")[1];var bug_link='<a href="'+
PROJECTS_TO_ISSUETRACKERS[project]+bug_number+'" target="_blank">'+found_bug+"</
a>";s=s.replace(found_bug,bug_link)})}}return s};sk.isGoogler=function(email){re
turn email&&email.endsWith("@google.com")};sk.query={};sk.query.fromParamSet=fun
ction(o){if(!o){return""}var ret=[];var keys=Object.keys(o).sort();keys.forEach(
function(key){o[key].forEach(function(value){ret.push(encodeURIComponent(key)+"=
"+encodeURIComponent(value))})});return ret.join("&")};sk.query.toParamSet=funct
ion(s){s=s||"";var ret={};var vars=s.split("&");for(var i=0;i<vars.length;i++){v
ar pair=vars[i].split("=",2);if(pair.length==2){ |
| 3 var value=decodeURIComponent(pair[1]);if(ret.hasOwnProperty(key)){ret[key].push(
value)}else{ret[key]=[value]}}}return ret};sk.query.fromObject=function(o){var r
et=[];Object.keys(o).sort().forEach(function(key){if(Array.isArray(o[key])){o[ke
y].forEach(function(value){ret.push(encodeURIComponent(key)+"="+encodeURICompone
nt(value))})}else if(typeof o[key]=="object"){ret.push(encodeURIComponent(key)+"
="+encodeURIComponent(sk.query.fromObject(o[key])))}else{ret.push(encodeURICompo
nent(key)+"="+encodeURIComponent(o[key]))}});return ret.join("&")};sk.query.toOb
ject=function(s,target){var target=target||{};var ret={};var vars=s.split("&");f
or(var i=0;i<vars.length;i++){var pair=vars[i].split("=",2);if(pair.length==2){v
ar key=decodeURIComponent(pair[0]);var value=decodeURIComponent(pair[1]);if(targ
et.hasOwnProperty(key)){switch(typeof target[key]){case"boolean":ret[key]=value=
="true";break;case"number":ret[key]=Number(value);break;case"object":if(Array.is
Array(target[key])){var r=ret[key]||[];r.push(value);ret[key]=r}else{ret[key]=sk
.query.toObject(value,target[key])}break;case"string":ret[key]=value;break;defau
lt:ret[key]=value}}else{ret[key]=value}}}return ret};sk.query.splitAmp=function(
queryStr){queryStr=queryStr||"";return queryStr.split("&").join("\n")};sk.object
={};sk.object.equals=function(a,b){if(typeof a!=typeof b){return false}var ta=ty
peof a;if(ta=="string"||ta=="boolean"||ta=="number"){return a===b}if(ta=="object
"){if(Array.isArray(ta)){return JSON.stringify(a)==JSON.stringify(b)}else{return
sk.query.fromObject(a)==sk.query.fromObject(b)}}};sk.object.getDelta=function(o
,d){var ret={};Object.keys(o).forEach(function(key){if(!sk.object.equals(o[key],
d[key])){ret[key]=o[key]}});return ret};sk.object.applyDelta=function(delta,o){v
ar ret={};Object.keys(o).forEach(function(key){if(delta.hasOwnProperty(key)){ret
[key]=JSON.parse(JSON.stringify(delta[key]))}else{ret[key]=JSON.parse(JSON.strin
gify(o[key]))}});return ret};sk.object.shallowCopy=function(o){var ret={};for(va
r k in o){if(o.hasOwnProperty(k)){ret[k]=o[k]}}return ret};sk.key={};sk.key.matc
hes=function(key,paramName,paramValue){return key.indexOf(","+paramName+"="+para
mValue+",")>=0};sk.key.toObject=function(key){var ret={};key.split(",").forEach(
function(s,i){if(i==0){return}if(s===""){return}var parts=s.split("=");if(parts.
length!=2){return}ret[parts[0]]=parts[1]});return ret};sk.stateReflector=functio
n(page,cb){var defaultState=JSON.parse(JSON.stringify(page.state));var lastState
=JSON.parse(JSON.stringify(page.state));setInterval(function(){if(Object.keys(sk
.object.getDelta(lastState,page.state)).length>0){lastState=JSON.parse(JSON.stri
ngify(page.state));var q=sk.query.fromObject(sk.object.getDelta(page.state,defau
ltState));history.pushState(null,"",window.location.origin+window.location.pathn
ame+"?"+q)}},100);var stateFromURL=function(){var delta=sk.query.toObject(window
.location.search.slice(1),defaultState);page.state=sk.object.applyDelta(delta,de
faultState);lastState=JSON.parse(JSON.stringify(page.state));cb()};if(window["Po
lymer"]&&Polymer.version[0]=="0"){sk.WebComponentsReady.then(stateFromURL)}else{
sk.DomReady.then(stateFromURL)}window.addEventListener("popstate",stateFromURL)}
;sk.getRoundNumber=function(min,max,base){if(min>max){throw"sk.getRoundNumber: m
in > max! ("+min+" > "+max+")"}var multipleOf=[5,2,1];var val=(max+min)/2;if(!ba
se){base=10}var digits=Math.floor(Math.log(Math.abs(val))/Math.log(base))+1;for(
var shift=0;;shift++){var shiftDiv=Math.pow(base,digits-shift);for(var i=0;i<mul
tipleOf.length;i++){var f=shiftDiv*multipleOf[i];var newVal=Math.round(val/f)*10
*f/10;if(newVal>=min&&newVal<=max){return newVal}}}console.error("sk.getRoundNum
ber Couldn't find appropriate rounding "+"value. Returning midpoint.");return va
l};sk.sortStrings=function(s){return s.sort(function(a,b){return a.localeCompare
(b,"en",{sensitivity:"base"})})};sk.toCapWords=function(s){return s.replace(/\b\
w/g,function(firstLetter){return firstLetter.toUpperCase()})};sk.truncate=functi
on(str,len){if(str.length>len){var ellipsis="...";return str.substring(0,len-ell
ipsis.length)+ellipsis}return str};sk.hashString=function(s){var hash=0;for(var
i=s.length-1;i>=0;i--){hash=(hash<<5)-hash+s.charCodeAt(i);hash|=0}return Math.a
bs(hash)};sk.escapeHTML=function(s){return s.replace(/&/g,"&").replace(/</g,
"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").repla
ce(/\//g,"/")};sk.sharesElement=function(a,b){var i=0;var j=0;while(i<a.len
gth&&j<b.length){if(a[i]<b[j]){i++}else if(b[j]<a[i]){j++}else{return true}}retu
rn false};sk.robust_get=function(obj,idx){if(!idx||!obj){return}for(var i=0,len=
idx.length;i<len;i++){if(typeof obj==="undefined"||typeof idx[i]==="undefined"){
return}obj=obj[idx[i]]}return obj};function _hexify(i){var s=i.toString(16).toUp
perCase();if(s.length<2){s="0"+s}return s}sk.colorHex=function(colors,offset){re
turn"#"+_hexify(colors[offset+0])+_hexify(colors[offset+1])+_hexify(colors[offse
t+2])+_hexify(colors[offset+3])};sk.colorRGB=function(colors,offset,rawAlpha){va
r scaleAlpha=rawAlpha?1:255;return"rgba("+colors[offset]+", "+colors[offset+1]+"
, "+colors[offset+2]+", "+colors[offset+3]/scaleAlpha+")"};if(!String.prototype.
startsWith){String.prototype.startsWith=function(searchString,position){position
=position||0;return this.indexOf(searchString,position)===position}}return sk}()
;window.naturalSort=function(a,b){"use strict";var re=/(^([+\-]?(?:0|[1-9]\d*)(?
:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,sre=/(^[ ]*|[ ]*$)/g,dre=/(^
([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\
d{1,4}|^\w+, \w+ \d+, \d{4})/,hre=/^0x[0-9a-f]+$/i,ore=/^0/,i=function(s){return
naturalSort.insensitive&&(""+s).toLowerCase()||""+s},x=i(a).replace(sre,"")||""
,y=i(b).replace(sre,"")||"",xN=x.replace(re,"\0$1\0").replace(/\0$/,"").replace(
/^\0/,"").split("\0"),yN=y.replace(re,"\0$1\0").replace(/\0$/,"").replace(/^\0/,
"").split("\0"),xD=parseInt(x.match(hre),16)||xN.length!==1&&x.match(dre)&&Date.
parse(x),yD=parseInt(y.match(hre),16)||xD&&y.match(dre)&&Date.parse(y)||null,oFx
NcL,oFyNcL;if(yD){if(xD<yD){return-1}else if(xD>yD){return 1}}for(var cLoc=0,num
S=Math.max(xN.length,yN.length);cLoc<numS;cLoc++){oFxNcL=!(xN[cLoc]||"").match(o
re)&&parseFloat(xN[cLoc])||xN[cLoc]||0;oFyNcL=!(yN[cLoc]||"").match(ore)&&parseF
loat(yN[cLoc])||yN[cLoc]||0;if(isNaN(oFxNcL)!==isNaN(oFyNcL)){return isNaN(oFxNc
L)?1:-1}else if(typeof oFxNcL!==typeof oFyNcL){oFxNcL+="";oFyNcL+=""}if(oFxNcL<o
FyNcL){return-1}if(oFxNcL>oFyNcL){return 1}}return 0};this.swarming=this.swarmin
g||function(){var swarming={};swarming.longest=function(arr){var most="";for(var
i=0;i<arr.length;i++){if(arr[i]&&arr[i].length>most.length){most=arr[i]}}return
most};swarming.stableSort=function(arr,comp){if(!arr||!comp){console.log("missi
ng arguments to stableSort",arr,comp);return}arr.forEach(function(e,i){if(e!==un
defined&&e!==null){e.__sortIdx=i}});arr.sort(function(a,b){if(a===undefined||a==
=null){if(b===undefined||b===null){return 0}return 1}if(b===undefined||b===null)
{return-1}var c=comp(a,b);if(c===0){return a.__sortIdx-b.__sortIdx}return c})};s
warming.postWithToast=function(url,msg,auth_headers,body){sk.errorMessage(msg,0)
;auth_headers["content-type"]="application/json; charset=UTF-8";if(body){body=JS
ON.stringify(body)}return sk.request("POST",url,body,auth_headers).then(function
(response){sk.errorMessage("Request sent. Response: "+response,3e3);return resp
onse}).catch(function(reason){console.log("Request failed",reason);sk.errorMessa
ge("Request failed. Reason: "+reason,5e3);return Promise.reject(reason)})};swar
ming.sanitizeAndHumanizeTime=function(obj,key){if(obj[key]){if(obj[key].endsWith
&&!obj[key].endsWith("Z")){obj[key]+="Z"}obj[key]=new Date(obj[key]);obj["human_
"+key]=sk.human.localeTime(obj[key])}};return swarming}();this.swarming=this.swa
rming||{};this.swarming.alias=this.swarming.alias||function(){var ANDROID_ALIASE
S={angler:"Nexus 6p",athene:"Moto G4",bullhead:"Nexus 5X",dragon:"Pixel C",flo:"
Nexus 7 [2013]",flounder:"Nexus 9",foster:"NVIDIA Shield",fugu:"Nexus Player",gc
e_x86:"Android on GCE",goyawifi:"Galaxy Tab 3",grouper:"Nexus 7 [2012]",hammerhe
ad:"Nexus 5",herolte:"Galaxy S7 [Global]",heroqlteatt:"Galaxy S7 [AT&T]",j5xnlte
:"Galaxy J5",m0:"Galaxy S3",mako:"Nexus 4",manta:"Nexus 10",marlin:"Pixel XL",sa
ilfish:"Pixel",shamu:"Nexus 6",sprout:"Android One",zerofltetmo:"Galaxy S6"};var
UNKNOWN="unknown";var GPU_ALIASES={1002:"AMD","1002:6613":"AMD Radeon R7 240","
1002:6646":"AMD Radeon R9 M280X","1002:6779":"AMD Radeon HD 6450/7450/8450","100
2:6821":"AMD Radeon HD 8870M","1002:683d":"AMD Radeon HD 7770/8760","1002:9830":
"AMD Radeon HD 8400","1002:9874":"AMD Carrizo","102b":"Matrox","102b:0522":"Matr
ox MGA G200e","102b:0532":"Matrox MGA G200eW","102b:0534":"Matrox G200eR2","10de
":"NVIDIA","10de:08a4":"NVIDIA GeForce 320M","10de:08aa":"NVIDIA GeForce 320M","
10de:0a65":"NVIDIA GeForce 210","10de:0fe9":"NVIDIA GeForce GT 750M Mac Edition"
,"10de:0ffa":"NVIDIA Quadro K600","10de:104a":"NVIDIA GeForce GT 610","10de:11c0
":"NVIDIA GeForce GTX 660","10de:1244":"NVIDIA GeForce GTX 550 Ti","10de:1401":"
NVIDIA GeForce GTX 960","10de:1ba1":"NVIDIA GeForce GTX 1070",8086:"Intel","8086
:0046":"Intel Ironlake HD Graphics","8086:0166":"Intel Ivy Bridge HD Graphics 40
00","8086:0412":"Intel Haswell HD Graphics 4600","8086:041a":"Intel Haswell HD G
raphics","8086:0a26":"Intel Haswell HD Graphics 5000","8086:0a2e":"Intel Haswell
Iris Graphics 5100","8086:0d26":"Intel Haswell Iris Pro Graphics 5200","8086:0f
31":"Intel Bay Trail HD Graphics","8086:1616":"Intel Broadwell HD Graphics 5500"
,"8086:161e":"Intel Broadwell HD Graphics 5300","8086:1626":"Intel Broadwell HD
Graphics 6000","8086:162b":"Intel Broadwell Iris Graphics 6100","8086:1912":"Int
el Skylake HD Graphics 530","8086:1926":"Intel Skylake Iris 540/550","8086:193b"
:"Intel Skylake Iris Pro 580","8086:22b1":"Intel Braswell HD Graphics"};var BATT
ERY_HEALTH_ALIASES={1:"Unknown",2:"Good",3:"Overheated",4:"Dead",5:"Over Voltage
",6:"Unspecified Failure",7:"Too Cold"};var BATTERY_STATUS_ALIASES={1:"Unknown",
2:"Charging",3:"Discharging",4:"Not Charging",5:"Full"};var DEVICE_ALIASES={"iPa
d4,1":"iPad Air","iPad5,1":"iPad mini 4","iPad6,3":"iPad Pro [9.7 in]","iPhone7,
2":"iPhone 6","iPhone9,1":"iPhone 7"};var ALIAS_REGEXP=/.+ \((.*)\)/;var alias={
};alias.DIMENSIONS_WITH_ALIASES=["device_type","gpu","battery_health","battery_s
tatus","device"];alias.android=function(dt){return ANDROID_ALIASES[dt]||UNKNOWN}
;alias.battery_health=function(bh){return BATTERY_HEALTH_ALIASES[bh]||UNKNOWN};a
lias.battery_status=function(bs){return BATTERY_STATUS_ALIASES[bs]||UNKNOWN};ali
as.device=function(dt){return DEVICE_ALIASES[dt]||UNKNOWN};alias.gpu=function(gp
u){return GPU_ALIASES[gpu]||UNKNOWN};alias.apply=function(orig,type){var aliaser
=aliasMap[type];if(!aliaser){return type+" ("+orig+")"}var alias=aliaser(orig);i
f(alias!==UNKNOWN){return alias+" ("+orig+")"}return orig};alias.has=function(ty
pe){return!!aliasMap[type]};alias.unapply=function(str){var match=ALIAS_REGEXP.e
xec(str);if(match){return match[1]}return str};var aliasMap={battery_health:alia
s.battery_health,battery_status:alias.battery_status,device:alias.device,device_
type:alias.android,gpu:alias.gpu};return alias}(); | 3 var key=decodeURIComponent(pair[0]);var value=decodeURIComponent(pair[1]);if(ret
.hasOwnProperty(key)){ret[key].push(value)}else{ret[key]=[value]}}}return ret};s
k.query.fromObject=function(o){var ret=[];Object.keys(o).sort().forEach(function
(key){if(Array.isArray(o[key])){o[key].forEach(function(value){ret.push(encodeUR
IComponent(key)+"="+encodeURIComponent(value))})}else if(typeof o[key]=="object"
){ret.push(encodeURIComponent(key)+"="+encodeURIComponent(sk.query.fromObject(o[
key])))}else{ret.push(encodeURIComponent(key)+"="+encodeURIComponent(o[key]))}})
;return ret.join("&")};sk.query.toObject=function(s,target){var target=target||{
};var ret={};var vars=s.split("&");for(var i=0;i<vars.length;i++){var pair=vars[
i].split("=",2);if(pair.length==2){var key=decodeURIComponent(pair[0]);var value
=decodeURIComponent(pair[1]);if(target.hasOwnProperty(key)){switch(typeof target
[key]){case"boolean":ret[key]=value=="true";break;case"number":ret[key]=Number(v
alue);break;case"object":if(Array.isArray(target[key])){var r=ret[key]||[];r.pus
h(value);ret[key]=r}else{ret[key]=sk.query.toObject(value,target[key])}break;cas
e"string":ret[key]=value;break;default:ret[key]=value}}else{ret[key]=value}}}ret
urn ret};sk.query.splitAmp=function(queryStr){queryStr=queryStr||"";return query
Str.split("&").join("\n")};sk.object={};sk.object.equals=function(a,b){if(typeof
a!=typeof b){return false}var ta=typeof a;if(ta=="string"||ta=="boolean"||ta=="
number"){return a===b}if(ta=="object"){if(Array.isArray(ta)){return JSON.stringi
fy(a)==JSON.stringify(b)}else{return sk.query.fromObject(a)==sk.query.fromObject
(b)}}};sk.object.getDelta=function(o,d){var ret={};Object.keys(o).forEach(functi
on(key){if(!sk.object.equals(o[key],d[key])){ret[key]=o[key]}});return ret};sk.o
bject.applyDelta=function(delta,o){var ret={};Object.keys(o).forEach(function(ke
y){if(delta.hasOwnProperty(key)){ret[key]=JSON.parse(JSON.stringify(delta[key]))
}else{ret[key]=JSON.parse(JSON.stringify(o[key]))}});return ret};sk.object.shall
owCopy=function(o){var ret={};for(var k in o){if(o.hasOwnProperty(k)){ret[k]=o[k
]}}return ret};sk.key={};sk.key.matches=function(key,paramName,paramValue){retur
n key.indexOf(","+paramName+"="+paramValue+",")>=0};sk.key.toObject=function(key
){var ret={};key.split(",").forEach(function(s,i){if(i==0){return}if(s===""){ret
urn}var parts=s.split("=");if(parts.length!=2){return}ret[parts[0]]=parts[1]});r
eturn ret};sk.stateReflector=function(page,cb){var defaultState=JSON.parse(JSON.
stringify(page.state));var lastState=JSON.parse(JSON.stringify(page.state));setI
nterval(function(){if(Object.keys(sk.object.getDelta(lastState,page.state)).leng
th>0){lastState=JSON.parse(JSON.stringify(page.state));var q=sk.query.fromObject
(sk.object.getDelta(page.state,defaultState));history.pushState(null,"",window.l
ocation.origin+window.location.pathname+"?"+q)}},100);var stateFromURL=function(
){var delta=sk.query.toObject(window.location.search.slice(1),defaultState);page
.state=sk.object.applyDelta(delta,defaultState);lastState=JSON.parse(JSON.string
ify(page.state));cb()};if(window["Polymer"]&&Polymer.version[0]=="0"){sk.WebComp
onentsReady.then(stateFromURL)}else{sk.DomReady.then(stateFromURL)}window.addEve
ntListener("popstate",stateFromURL)};sk.getRoundNumber=function(min,max,base){if
(min>max){throw"sk.getRoundNumber: min > max! ("+min+" > "+max+")"}var multipleO
f=[5,2,1];var val=(max+min)/2;if(!base){base=10}var digits=Math.floor(Math.log(M
ath.abs(val))/Math.log(base))+1;for(var shift=0;;shift++){var shiftDiv=Math.pow(
base,digits-shift);for(var i=0;i<multipleOf.length;i++){var f=shiftDiv*multipleO
f[i];var newVal=Math.round(val/f)*10*f/10;if(newVal>=min&&newVal<=max){return ne
wVal}}}console.error("sk.getRoundNumber Couldn't find appropriate rounding "+"va
lue. Returning midpoint.");return val};sk.sortStrings=function(s){return s.sort(
function(a,b){return a.localeCompare(b,"en",{sensitivity:"base"})})};sk.toCapWor
ds=function(s){return s.replace(/\b\w/g,function(firstLetter){return firstLetter
.toUpperCase()})};sk.truncate=function(str,len){if(str.length>len){var ellipsis=
"...";return str.substring(0,len-ellipsis.length)+ellipsis}return str};sk.hashSt
ring=function(s){var hash=0;for(var i=s.length-1;i>=0;i--){hash=(hash<<5)-hash+s
.charCodeAt(i);hash|=0}return Math.abs(hash)};sk.escapeHTML=function(s){return s
.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,"&
quot;").replace(/'/g,"'").replace(/\//g,"/")};sk.sharesElement=functio
n(a,b){var i=0;var j=0;while(i<a.length&&j<b.length){if(a[i]<b[j]){i++}else if(b
[j]<a[i]){j++}else{return true}}return false};sk.robust_get=function(obj,idx){if
(!idx||!obj){return}for(var i=0,len=idx.length;i<len;i++){if(typeof obj==="undef
ined"||typeof idx[i]==="undefined"){return}obj=obj[idx[i]]}return obj};function
_hexify(i){var s=i.toString(16).toUpperCase();if(s.length<2){s="0"+s}return s}sk
.colorHex=function(colors,offset){return"#"+_hexify(colors[offset+0])+_hexify(co
lors[offset+1])+_hexify(colors[offset+2])+_hexify(colors[offset+3])};sk.colorRGB
=function(colors,offset,rawAlpha){var scaleAlpha=rawAlpha?1:255;return"rgba("+co
lors[offset]+", "+colors[offset+1]+", "+colors[offset+2]+", "+colors[offset+3]/s
caleAlpha+")"};if(!String.prototype.startsWith){String.prototype.startsWith=func
tion(searchString,position){position=position||0;return this.indexOf(searchStrin
g,position)===position}}return sk}();window.naturalSort=function(a,b){"use stric
t";var re=/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|
\d+)/gi,sre=/(^[ ]*|[ ]*$)/g,dre=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)
?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,hre=/^0x[0-9a-
f]+$/i,ore=/^0/,i=function(s){return naturalSort.insensitive&&(""+s).toLowerCase
()||""+s},x=i(a).replace(sre,"")||"",y=i(b).replace(sre,"")||"",xN=x.replace(re,
"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),yN=y.replace(re,"\0$1\
0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),xD=parseInt(x.match(hre),16)
||xN.length!==1&&x.match(dre)&&Date.parse(x),yD=parseInt(y.match(hre),16)||xD&&y
.match(dre)&&Date.parse(y)||null,oFxNcL,oFyNcL;if(yD){if(xD<yD){return-1}else if
(xD>yD){return 1}}for(var cLoc=0,numS=Math.max(xN.length,yN.length);cLoc<numS;cL
oc++){oFxNcL=!(xN[cLoc]||"").match(ore)&&parseFloat(xN[cLoc])||xN[cLoc]||0;oFyNc
L=!(yN[cLoc]||"").match(ore)&&parseFloat(yN[cLoc])||yN[cLoc]||0;if(isNaN(oFxNcL)
!==isNaN(oFyNcL)){return isNaN(oFxNcL)?1:-1}else if(typeof oFxNcL!==typeof oFyNc
L){oFxNcL+="";oFyNcL+=""}if(oFxNcL<oFyNcL){return-1}if(oFxNcL>oFyNcL){return 1}}
return 0};this.swarming=this.swarming||function(){var swarming={};swarming.longe
st=function(arr){var most="";for(var i=0;i<arr.length;i++){if(arr[i]&&arr[i].len
gth>most.length){most=arr[i]}}return most};swarming.stableSort=function(arr,comp
){if(!arr||!comp){console.log("missing arguments to stableSort",arr,comp);return
}arr.forEach(function(e,i){if(e!==undefined&&e!==null){e.__sortIdx=i}});arr.sort
(function(a,b){if(a===undefined||a===null){if(b===undefined||b===null){return 0}
return 1}if(b===undefined||b===null){return-1}var c=comp(a,b);if(c===0){return a
.__sortIdx-b.__sortIdx}return c})};swarming.postWithToast=function(url,msg,auth_
headers,body){sk.errorMessage(msg,0);auth_headers["content-type"]="application/j
son; charset=UTF-8";if(body){body=JSON.stringify(body)}return sk.request("POST",
url,body,auth_headers).then(function(response){sk.errorMessage("Request sent. R
esponse: "+response,3e3);return response}).catch(function(reason){console.log("R
equest failed",reason);sk.errorMessage("Request failed. Reason: "+reason,5e3);r
eturn Promise.reject(reason)})};swarming.sanitizeAndHumanizeTime=function(obj,ke
y){if(obj[key]){if(obj[key].endsWith&&!obj[key].endsWith("Z")){obj[key]+="Z"}obj
[key]=new Date(obj[key]);obj["human_"+key]=sk.human.localeTime(obj[key])}};retur
n swarming}();this.swarming=this.swarming||{};this.swarming.alias=this.swarming.
alias||function(){var ANDROID_ALIASES={angler:"Nexus 6p",athene:"Moto G4",bullhe
ad:"Nexus 5X",dragon:"Pixel C",flo:"Nexus 7 [2013]",flounder:"Nexus 9",foster:"N
VIDIA Shield",fugu:"Nexus Player",gce_x86:"Android on GCE",goyawifi:"Galaxy Tab
3",grouper:"Nexus 7 [2012]",hammerhead:"Nexus 5",herolte:"Galaxy S7 [Global]",he
roqlteatt:"Galaxy S7 [AT&T]",j5xnlte:"Galaxy J5",m0:"Galaxy S3",mako:"Nexus 4",m
anta:"Nexus 10",marlin:"Pixel XL",sailfish:"Pixel",shamu:"Nexus 6",sprout:"Andro
id One",zerofltetmo:"Galaxy S6"};var UNKNOWN="unknown";var GPU_ALIASES={1002:"AM
D","1002:6613":"AMD Radeon R7 240","1002:6646":"AMD Radeon R9 M280X","1002:6779"
:"AMD Radeon HD 6450/7450/8450","1002:6821":"AMD Radeon HD 8870M","1002:683d":"A
MD Radeon HD 7770/8760","1002:9830":"AMD Radeon HD 8400","1002:9874":"AMD Carriz
o","102b":"Matrox","102b:0522":"Matrox MGA G200e","102b:0532":"Matrox MGA G200eW
","102b:0534":"Matrox G200eR2","10de":"NVIDIA","10de:08a4":"NVIDIA GeForce 320M"
,"10de:08aa":"NVIDIA GeForce 320M","10de:0a65":"NVIDIA GeForce 210","10de:0fe9":
"NVIDIA GeForce GT 750M Mac Edition","10de:0ffa":"NVIDIA Quadro K600","10de:104a
":"NVIDIA GeForce GT 610","10de:11c0":"NVIDIA GeForce GTX 660","10de:1244":"NVID
IA GeForce GTX 550 Ti","10de:1401":"NVIDIA GeForce GTX 960","10de:1ba1":"NVIDIA
GeForce GTX 1070",8086:"Intel","8086:0046":"Intel Ironlake HD Graphics","8086:01
66":"Intel Ivy Bridge HD Graphics 4000","8086:0412":"Intel Haswell HD Graphics 4
600","8086:041a":"Intel Haswell HD Graphics","8086:0a26":"Intel Haswell HD Graph
ics 5000","8086:0a2e":"Intel Haswell Iris Graphics 5100","8086:0d26":"Intel Hasw
ell Iris Pro Graphics 5200","8086:0f31":"Intel Bay Trail HD Graphics","8086:1616
":"Intel Broadwell HD Graphics 5500","8086:161e":"Intel Broadwell HD Graphics 53
00","8086:1626":"Intel Broadwell HD Graphics 6000","8086:162b":"Intel Broadwell
Iris Graphics 6100","8086:1912":"Intel Skylake HD Graphics 530","8086:1926":"Int
el Skylake Iris 540/550","8086:193b":"Intel Skylake Iris Pro 580","8086:22b1":"I
ntel Braswell HD Graphics"};var BATTERY_HEALTH_ALIASES={1:"Unknown",2:"Good",3:"
Overheated",4:"Dead",5:"Over Voltage",6:"Unspecified Failure",7:"Too Cold"};var
BATTERY_STATUS_ALIASES={1:"Unknown",2:"Charging",3:"Discharging",4:"Not Charging
",5:"Full"};var DEVICE_ALIASES={"iPad4,1":"iPad Air","iPad5,1":"iPad mini 4","iP
ad6,3":"iPad Pro [9.7 in]","iPhone7,2":"iPhone 6","iPhone9,1":"iPhone 7"};var AL
IAS_REGEXP=/.+ \((.*)\)/;var alias={};alias.DIMENSIONS_WITH_ALIASES=["device_typ
e","gpu","battery_health","battery_status","device"];alias.android=function(dt){
return ANDROID_ALIASES[dt]||UNKNOWN};alias.battery_health=function(bh){return BA
TTERY_HEALTH_ALIASES[bh]||UNKNOWN};alias.battery_status=function(bs){return BATT
ERY_STATUS_ALIASES[bs]||UNKNOWN};alias.device=function(dt){return DEVICE_ALIASES
[dt]||UNKNOWN};alias.gpu=function(gpu){return GPU_ALIASES[gpu]||UNKNOWN};alias.a
pply=function(orig,type){var aliaser=aliasMap[type];if(!aliaser){return type+" (
"+orig+")"}var alias=aliaser(orig);if(alias!==UNKNOWN){return alias+" ("+orig+")
"}return orig};alias.has=function(type){return!!aliasMap[type]};alias.unapply=fu
nction(str){var match=ALIAS_REGEXP.exec(str);if(match){return match[1]}return st
r};var aliasMap={battery_health:alias.battery_health,battery_status:alias.batter
y_status,device:alias.device,device_type:alias.android,gpu:alias.gpu};return ali
as}(); |