| OLD | NEW |
| 1 <!DOCTYPE html><html><head><meta charset="UTF-8"> </head><body><div hidden="" by
-vulcanize=""><script>!function(){function e(){document.body.removeAttribute("un
resolved")}window.WebComponents?addEventListener("WebComponentsReady",e):"intera
ctive"===document.readyState||"complete"===document.readyState?e():addEventListe
ner("DOMContentLoaded",e)}(),window.Polymer={Settings:function(){var e=window.Po
lymer||{};if(!e.noUrlSettings)for(var t,r=location.search.slice(1).split("&"),i=
0;i<r.length&&(t=r[i]);i++)t=t.split("="),t[0]&&(e[t[0]]=t[1]||!0);return e.want
Shadow="shadow"===e.dom,e.hasShadow=Boolean(Element.prototype.createShadowRoot),
e.nativeShadow=e.hasShadow&&!window.ShadowDOMPolyfill,e.useShadow=e.wantShadow&&
e.hasShadow,e.hasNativeImports=Boolean("import"in document.createElement("link")
),e.useNativeImports=e.hasNativeImports,e.useNativeCustomElements=!window.Custom
Elements||window.CustomElements.useNative,e.useNativeShadow=e.useShadow&&e.nativ
eShadow,e.usePolyfillProto=!e.useNativeCustomElements&&!Object.__proto__,e.hasNa
tiveCSSProperties=!navigator.userAgent.match("AppleWebKit/601")&&window.CSS&&CSS
.supports&&CSS.supports("box-shadow","0 0 0 var(--foo)"),e.useNativeCSSPropertie
s=e.hasNativeCSSProperties&&e.lazyRegister&&e.useNativeCSSProperties,e}()},funct
ion(){var e=window.Polymer;window.Polymer=function(e){"function"==typeof e&&(e=e
.prototype),e||(e={});var r=t(e);e=r.prototype;var i={prototype:e};return e.exte
nds&&(i.extends=e.extends),Polymer.telemetry._registrate(e),document.registerEle
ment(e.is,i),r};var t=function(e){var t=Polymer.Base;return e.extends&&(t=Polyme
r.Base._getExtendedPrototype(e.extends)),e=Polymer.Base.chainObject(e,t),e.regis
terCallback(),e.constructor};if(e)for(var r in e)Polymer[r]=e[r];Polymer.Class=t
}(),Polymer.telemetry={registrations:[],_regLog:function(e){console.log("["+e.is
+"]: registered")},_registrate:function(e){this.registrations.push(e),Polymer.lo
g&&this._regLog(e)},dumpRegistrations:function(){this.registrations.forEach(this
._regLog)}},Object.defineProperty(window,"currentImport",{enumerable:!0,configur
able:!0,get:function(){return(document._currentScript||document.currentScript).o
wnerDocument}}),Polymer.RenderStatus={_ready:!1,_callbacks:[],whenReady:function
(e){this._ready?e():this._callbacks.push(e)},_makeReady:function(){this._ready=!
0;for(var e=0;e<this._callbacks.length;e++)this._callbacks[e]();this._callbacks=
[]},_catchFirstRender:function(){requestAnimationFrame(function(){Polymer.Render
Status._makeReady()})},_afterNextRenderQueue:[],_waitingNextRender:!1,afterNextR
ender:function(e,t,r){this._watchNextRender(),this._afterNextRenderQueue.push([e
,t,r])},hasRendered:function(){return this._ready},_watchNextRender:function(){i
f(!this._waitingNextRender){this._waitingNextRender=!0;var e=function(){Polymer.
RenderStatus._flushNextRender()};this._ready?requestAnimationFrame(e):this.whenR
eady(e)}},_flushNextRender:function(){var e=this;setTimeout(function(){e._flushR
enderCallbacks(e._afterNextRenderQueue),e._afterNextRenderQueue=[],e._waitingNex
tRender=!1})},_flushRenderCallbacks:function(e){for(var t,r=0;r<e.length;r++)t=e
[r],t[1].apply(t[0],t[2]||Polymer.nar)}},window.HTMLImports?HTMLImports.whenRead
y(function(){Polymer.RenderStatus._catchFirstRender()}):Polymer.RenderStatus._ca
tchFirstRender(),Polymer.ImportStatus=Polymer.RenderStatus,Polymer.ImportStatus.
whenLoaded=Polymer.ImportStatus.whenReady,function(){"use strict";var e=Polymer.
Settings;Polymer.Base={__isPolymerInstance__:!0,_addFeature:function(e){this.ext
end(this,e)},registerCallback:function(){"max"===e.lazyRegister?this.beforeRegis
ter&&this.beforeRegister():(this._desugarBehaviors(),this._doBehavior("beforeReg
ister")),this._registerFeatures(),e.lazyRegister||this.ensureRegisterFinished()}
,createdCallback:function(){this.__hasRegisterFinished||this._ensureRegisterFini
shed(this.__proto__),Polymer.telemetry.instanceCount++,this.root=this,this._doBe
havior("created"),this._initFeatures()},ensureRegisterFinished:function(){this._
ensureRegisterFinished(this)},_ensureRegisterFinished:function(t){t.__hasRegiste
rFinished===t.is&&t.is||("max"===e.lazyRegister&&(t._desugarBehaviors(),t._doBeh
aviorOnly("beforeRegister")),t.__hasRegisterFinished=t.is,t._finishRegisterFeatu
res&&t._finishRegisterFeatures(),t._doBehavior("registered"),e.usePolyfillProto&
&t!==this&&t.extend(this,t))},attachedCallback:function(){var e=this;Polymer.Ren
derStatus.whenReady(function(){e.isAttached=!0,e._doBehavior("attached")})},deta
chedCallback:function(){var e=this;Polymer.RenderStatus.whenReady(function(){e.i
sAttached=!1,e._doBehavior("detached")})},attributeChangedCallback:function(e,t,
r){this._attributeChangedImpl(e),this._doBehavior("attributeChanged",[e,t,r])},_
attributeChangedImpl:function(e){this._setAttributeToProperty(this,e)},extend:fu
nction(e,t){if(e&&t)for(var r,i=Object.getOwnPropertyNames(t),o=0;o<i.length&&(r
=i[o]);o++)this.copyOwnProperty(r,t,e);return e||t},mixin:function(e,t){for(var
r in t)e[r]=t[r];return e},copyOwnProperty:function(e,t,r){var i=Object.getOwnPr
opertyDescriptor(t,e);i&&Object.defineProperty(r,e,i)},_logger:function(e,t){swi
tch(1===t.length&&Array.isArray(t[0])&&(t=t[0]),e){case"log":case"warn":case"err
or":console[e].apply(console,t)}},_log:function(){var e=Array.prototype.slice.ca
ll(arguments,0);this._logger("log",e)},_warn:function(){var e=Array.prototype.sl
ice.call(arguments,0);this._logger("warn",e)},_error:function(){var e=Array.prot
otype.slice.call(arguments,0);this._logger("error",e)},_logf:function(){return t
his._logPrefix.concat(this.is).concat(Array.prototype.slice.call(arguments,0))}}
,Polymer.Base._logPrefix=function(){var e=window.chrome&&!/edge/i.test(navigator
.userAgent)||/firefox/i.test(navigator.userAgent);return e?["%c[%s::%s]:","font-
weight: bold; background-color:#EEEE00;"]:["[%s::%s]:"]}(),Polymer.Base.chainObj
ect=function(e,t){return e&&t&&e!==t&&(Object.__proto__||(e=Polymer.Base.extend(
Object.create(t),e)),e.__proto__=t),e},Polymer.Base=Polymer.Base.chainObject(Pol
ymer.Base,HTMLElement.prototype),window.CustomElements?Polymer.instanceof=Custom
Elements.instanceof:Polymer.instanceof=function(e,t){return e instanceof t},Poly
mer.isInstance=function(e){return Boolean(e&&e.__isPolymerInstance__)},Polymer.t
elemetry.instanceCount=0}(),function(){function e(){if(s)for(var e,t=document._c
urrentScript||document.currentScript,r=t&&t.ownerDocument||document,i=r.querySel
ectorAll("dom-module"),o=i.length-1;o>=0&&(e=i[o]);o--){if(e.__upgraded__)return
;CustomElements.upgrade(e)}}var t={},r={},i=function(e){return t[e]||r[e.toLower
Case()]},o=function(){return document.createElement("dom-module")};o.prototype=O
bject.create(HTMLElement.prototype),Polymer.Base.extend(o.prototype,{constructor
:o,createdCallback:function(){this.register()},register:function(e){e=e||this.id
||this.getAttribute("name")||this.getAttribute("is"),e&&(this.id=e,t[e]=this,r[e
.toLowerCase()]=this)},import:function(t,r){if(t){var o=i(t);return o||(e(),o=i(
t)),o&&r&&(o=o.querySelector(r)),o}}});var s=window.CustomElements&&!CustomEleme
nts.useNative;document.registerElement("dom-module",o)}(),Polymer.Base._addFeatu
re({_prepIs:function(){if(!this.is){var e=(document._currentScript||document.cur
rentScript).parentNode;if("dom-module"===e.localName){var t=e.id||e.getAttribute
("name")||e.getAttribute("is");this.is=t}}this.is&&(this.is=this.is.toLowerCase(
))}}),Polymer.Base._addFeature({behaviors:[],_desugarBehaviors:function(){this.b
ehaviors.length&&(this.behaviors=this._desugarSomeBehaviors(this.behaviors))},_d
esugarSomeBehaviors:function(e){var t=[];e=this._flattenBehaviorsList(e);for(var
r=e.length-1;r>=0;r--){var i=e[r];t.indexOf(i)===-1&&(this._mixinBehavior(i),t.
unshift(i))}return t},_flattenBehaviorsList:function(e){for(var t=[],r=0;r<e.len
gth;r++){var i=e[r];i instanceof Array?t=t.concat(this._flattenBehaviorsList(i))
:i?t.push(i):this._warn(this._logf("_flattenBehaviorsList","behavior is null, ch
eck for missing or 404 import"))}return t},_mixinBehavior:function(e){for(var t,
r=Object.getOwnPropertyNames(e),i=0;i<r.length&&(t=r[i]);i++)Polymer.Base._behav
iorProperties[t]||this.hasOwnProperty(t)||this.copyOwnProperty(t,e,this)},_prepB
ehaviors:function(){this._prepFlattenedBehaviors(this.behaviors)},_prepFlattened
Behaviors:function(e){for(var t=0,r=e.length;t<r;t++)this._prepBehavior(e[t]);th
is._prepBehavior(this)},_doBehavior:function(e,t){for(var r=0;r<this.behaviors.l
ength;r++)this._invokeBehavior(this.behaviors[r],e,t);this._invokeBehavior(this,
e,t)},_doBehaviorOnly:function(e,t){for(var r=0;r<this.behaviors.length;r++)this
._invokeBehavior(this.behaviors[r],e,t)},_invokeBehavior:function(e,t,r){var i=e
[t];i&&i.apply(this,r||Polymer.nar)},_marshalBehaviors:function(){for(var e=0;e<
this.behaviors.length;e++)this._marshalBehavior(this.behaviors[e]);this._marshal
Behavior(this)}}),Polymer.Base._behaviorProperties={hostAttributes:!0,beforeRegi
ster:!0,registered:!0,properties:!0,observers:!0,listeners:!0,created:!0,attache
d:!0,detached:!0,attributeChanged:!0,ready:!0},Polymer.Base._addFeature({_getExt
endedPrototype:function(e){return this._getExtendedNativePrototype(e)},_nativePr
ototypes:{},_getExtendedNativePrototype:function(e){var t=this._nativePrototypes
[e];if(!t){var r=this.getNativePrototype(e);t=this.extend(Object.create(r),Polym
er.Base),this._nativePrototypes[e]=t}return t},getNativePrototype:function(e){re
turn Object.getPrototypeOf(document.createElement(e))}}),Polymer.Base._addFeatur
e({_prepConstructor:function(){this._factoryArgs=this.extends?[this.extends,this
.is]:[this.is];var e=function(){return this._factory(arguments)};this.hasOwnProp
erty("extends")&&(e.extends=this.extends),Object.defineProperty(this,"constructo
r",{value:e,writable:!0,configurable:!0}),e.prototype=this},_factory:function(e)
{var t=document.createElement.apply(document,this._factoryArgs);return this.fact
oryImpl&&this.factoryImpl.apply(t,e),t}}),Polymer.nob=Object.create(null),Polyme
r.Base._addFeature({properties:{},getPropertyInfo:function(e){var t=this._getPro
pertyInfo(e,this.properties);if(!t)for(var r=0;r<this.behaviors.length;r++)if(t=
this._getPropertyInfo(e,this.behaviors[r].properties))return t;return t||Polymer
.nob},_getPropertyInfo:function(e,t){var r=t&&t[e];return"function"==typeof r&&(
r=t[e]={type:r}),r&&(r.defined=!0),r},_prepPropertyInfo:function(){this._propert
yInfo={};for(var e=0;e<this.behaviors.length;e++)this._addPropertyInfo(this._pro
pertyInfo,this.behaviors[e].properties);this._addPropertyInfo(this._propertyInfo
,this.properties),this._addPropertyInfo(this._propertyInfo,this._propertyEffects
)},_addPropertyInfo:function(e,t){if(t){var r,i;for(var o in t)r=e[o],i=t[o],("_
"!==o[0]||i.readOnly)&&(e[o]?(r.type||(r.type=i.type),r.readOnly||(r.readOnly=i.
readOnly)):e[o]={type:"function"==typeof i?i:i.type,readOnly:i.readOnly,attribut
e:Polymer.CaseMap.camelToDashCase(o)})}}}),Polymer.CaseMap={_caseMap:{},_rx:{das
hToCamel:/-[a-z]/g,camelToDash:/([A-Z])/g},dashToCamelCase:function(e){return th
is._caseMap[e]||(this._caseMap[e]=e.indexOf("-")<0?e:e.replace(this._rx.dashToCa
mel,function(e){return e[1].toUpperCase()}))},camelToDashCase:function(e){return
this._caseMap[e]||(this._caseMap[e]=e.replace(this._rx.camelToDash,"-$1").toLow
erCase())}},Polymer.Base._addFeature({_addHostAttributes:function(e){this._aggre
gatedAttributes||(this._aggregatedAttributes={}),e&&this.mixin(this._aggregatedA
ttributes,e)},_marshalHostAttributes:function(){this._aggregatedAttributes&&this
._applyAttributes(this,this._aggregatedAttributes)},_applyAttributes:function(e,
t){for(var r in t)if(!this.hasAttribute(r)&&"class"!==r){var i=t[r];this.seriali
zeValueToAttribute(i,r,this)}},_marshalAttributes:function(){this._takeAttribute
sToModel(this)},_takeAttributesToModel:function(e){if(this.hasAttributes())for(v
ar t in this._propertyInfo){var r=this._propertyInfo[t];this.hasAttribute(r.attr
ibute)&&this._setAttributeToProperty(e,r.attribute,t,r)}},_setAttributeToPropert
y:function(e,t,r,i){if(!this._serializing&&(r=r||Polymer.CaseMap.dashToCamelCase
(t),i=i||this._propertyInfo&&this._propertyInfo[r],i&&!i.readOnly)){var o=this.g
etAttribute(t);e[r]=this.deserialize(o,i.type)}},_serializing:!1,reflectProperty
ToAttribute:function(e,t,r){this._serializing=!0,r=void 0===r?this[e]:r,this.ser
ializeValueToAttribute(r,t||Polymer.CaseMap.camelToDashCase(e)),this._serializin
g=!1},serializeValueToAttribute:function(e,t,r){var i=this.serialize(e);r=r||thi
s,void 0===i?r.removeAttribute(t):r.setAttribute(t,i)},deserialize:function(e,t)
{switch(t){case Number:e=Number(e);break;case Boolean:e=null!=e;break;case Objec
t:try{e=JSON.parse(e)}catch(e){}break;case Array:try{e=JSON.parse(e)}catch(t){e=
null,console.warn("Polymer::Attributes: couldn`t decode Array as JSON")}break;ca
se Date:e=new Date(e);break;case String:}return e},serialize:function(e){switch(
typeof e){case"boolean":return e?"":void 0;case"object":if(e instanceof Date)ret
urn e.toString();if(e)try{return JSON.stringify(e)}catch(e){return""}default:ret
urn null!=e?e:void 0}}}),Polymer.version="1.7.0",Polymer.Base._addFeature({_regi
sterFeatures:function(){this._prepIs(),this._prepBehaviors(),this._prepConstruct
or(),this._prepPropertyInfo()},_prepBehavior:function(e){this._addHostAttributes
(e.hostAttributes)},_marshalBehavior:function(e){},_initFeatures:function(){this
._marshalHostAttributes(),this._marshalBehaviors()}})</script> <script>Polymer.B
ase._addFeature({_prepTemplate:function(){void 0===this._template&&(this._templa
te=Polymer.DomModule.import(this.is,"template")),this._template&&this._template.
hasAttribute("is")&&this._warn(this._logf("_prepTemplate","top-level Polymer tem
plate must not be a type-extension, found",this._template,"Move inside simple <t
emplate>.")),this._template&&!this._template.content&&window.HTMLTemplateElement
&&HTMLTemplateElement.decorate&&HTMLTemplateElement.decorate(this._template)},_s
tampTemplate:function(){this._template&&(this.root=this.instanceTemplate(this._t
emplate))},instanceTemplate:function(e){var t=document.importNode(e._content||e.
content,!0);return t}}),function(){var e=Polymer.Base.attachedCallback;Polymer.B
ase._addFeature({_hostStack:[],ready:function(){},_registerHost:function(e){this
.dataHost=e=e||Polymer.Base._hostStack[Polymer.Base._hostStack.length-1],e&&e._c
lients&&e._clients.push(this),this._clients=null,this._clientsReadied=!1},_begin
Hosting:function(){Polymer.Base._hostStack.push(this),this._clients||(this._clie
nts=[])},_endHosting:function(){Polymer.Base._hostStack.pop()},_tryReady:functio
n(){this._readied=!1,this._canReady()&&this._ready()},_canReady:function(){retur
n!this.dataHost||this.dataHost._clientsReadied},_ready:function(){this._beforeCl
ientsReady(),this._template&&(this._setupRoot(),this._readyClients()),this._clie
ntsReadied=!0,this._clients=null,this._afterClientsReady(),this._readySelf()},_r
eadyClients:function(){this._beginDistribute();var e=this._clients;if(e)for(var
t,o=0,i=e.length;o<i&&(t=e[o]);o++)t._ready();this._finishDistribute()},_readySe
lf:function(){this._doBehavior("ready"),this._readied=!0,this._attachedPending&&
(this._attachedPending=!1,this.attachedCallback())},_beforeClientsReady:function
(){},_afterClientsReady:function(){},_beforeAttached:function(){},attachedCallba
ck:function(){this._readied?(this._beforeAttached(),e.call(this)):this._attached
Pending=!0}})}(),Polymer.ArraySplice=function(){function e(e,t,o){return{index:e
,removed:t,addedCount:o}}function t(){}var o=0,i=1,n=2,s=3;return t.prototype={c
alcEditDistances:function(e,t,o,i,n,s){for(var r=s-n+1,d=o-t+1,a=new Array(r),l=
0;l<r;l++)a[l]=new Array(d),a[l][0]=l;for(var h=0;h<d;h++)a[0][h]=h;for(l=1;l<r;
l++)for(h=1;h<d;h++)if(this.equals(e[t+h-1],i[n+l-1]))a[l][h]=a[l-1][h-1];else{v
ar u=a[l-1][h]+1,c=a[l][h-1]+1;a[l][h]=u<c?u:c}return a},spliceOperationsFromEdi
tDistances:function(e){for(var t=e.length-1,r=e[0].length-1,d=e[t][r],a=[];t>0||
r>0;)if(0!=t)if(0!=r){var l,h=e[t-1][r-1],u=e[t-1][r],c=e[t][r-1];l=u<c?u<h?u:h:
c<h?c:h,l==h?(h==d?a.push(o):(a.push(i),d=h),t--,r--):l==u?(a.push(s),t--,d=u):(
a.push(n),r--,d=c)}else a.push(s),t--;else a.push(n),r--;return a.reverse(),a},c
alcSplices:function(t,r,d,a,l,h){var u=0,c=0,_=Math.min(d-r,h-l);if(0==r&&0==l&&
(u=this.sharedPrefix(t,a,_)),d==t.length&&h==a.length&&(c=this.sharedSuffix(t,a,
_-u)),r+=u,l+=u,d-=c,h-=c,d-r==0&&h-l==0)return[];if(r==d){for(var f=e(r,[],0);l
<h;)f.removed.push(a[l++]);return[f]}if(l==h)return[e(r,[],d-r)];var m=this.spli
ceOperationsFromEditDistances(this.calcEditDistances(t,r,d,a,l,h));f=void 0;for(
var p=[],v=r,g=l,b=0;b<m.length;b++)switch(m[b]){case o:f&&(p.push(f),f=void 0),
v++,g++;break;case i:f||(f=e(v,[],0)),f.addedCount++,v++,f.removed.push(a[g]),g+
+;break;case n:f||(f=e(v,[],0)),f.addedCount++,v++;break;case s:f||(f=e(v,[],0))
,f.removed.push(a[g]),g++}return f&&p.push(f),p},sharedPrefix:function(e,t,o){fo
r(var i=0;i<o;i++)if(!this.equals(e[i],t[i]))return i;return o},sharedSuffix:fun
ction(e,t,o){for(var i=e.length,n=t.length,s=0;s<o&&this.equals(e[--i],t[--n]);)
s++;return s},calculateSplices:function(e,t){return this.calcSplices(e,0,e.lengt
h,t,0,t.length)},equals:function(e,t){return e===t}},new t}(),Polymer.domInnerHT
ML=function(){function e(e){switch(e){case"&":return"&";case"<":return"<"
;case">":return">";case'"':return""";case" ":return" "}}function t(
t){return t.replace(r,e)}function o(t){return t.replace(d,e)}function i(e){for(v
ar t={},o=0;o<e.length;o++)t[e[o]]=!0;return t}function n(e,i,n){switch(e.nodeTy
pe){case Node.ELEMENT_NODE:for(var r,d=e.localName,h="<"+d,u=e.attributes,c=0;r=
u[c];c++)h+=" "+r.name+'="'+t(r.value)+'"';return h+=">",a[d]?h:h+s(e,n)+"</"+d+
">";case Node.TEXT_NODE:var _=e.data;return i&&l[i.localName]?_:o(_);case Node.C
OMMENT_NODE:return"\x3c!--"+e.data+"--\x3e";default:throw console.error(e),new E
rror("not implemented")}}function s(e,t){e instanceof HTMLTemplateElement&&(e=e.
content);for(var o,i="",s=Polymer.dom(e).childNodes,r=0,d=s.length;r<d&&(o=s[r])
;r++)i+=n(o,e,t);return i}var r=/[&\u00A0"]/g,d=/[&\u00A0<>]/g,a=i(["area","base
","br","col","command","embed","hr","img","input","keygen","link","meta","param"
,"source","track","wbr"]),l=i(["style","script","xmp","iframe","noembed","nofram
es","plaintext","noscript"]);return{getInnerHTML:s}}(),function(){"use strict";v
ar e=Element.prototype.insertBefore,t=Element.prototype.appendChild,o=Element.pr
ototype.removeChild;Polymer.TreeApi={arrayCopyChildNodes:function(e){for(var t=[
],o=0,i=e.firstChild;i;i=i.nextSibling)t[o++]=i;return t},arrayCopyChildren:func
tion(e){for(var t=[],o=0,i=e.firstElementChild;i;i=i.nextElementSibling)t[o++]=i
;return t},arrayCopy:function(e){for(var t=e.length,o=new Array(t),i=0;i<t;i++)o
[i]=e[i];return o}},Polymer.TreeApi.Logical={hasParentNode:function(e){return Bo
olean(e.__dom&&e.__dom.parentNode)},hasChildNodes:function(e){return Boolean(e._
_dom&&void 0!==e.__dom.childNodes)},getChildNodes:function(e){return this.hasChi
ldNodes(e)?this._getChildNodes(e):e.childNodes},_getChildNodes:function(e){if(!e
.__dom.childNodes){e.__dom.childNodes=[];for(var t=e.__dom.firstChild;t;t=t.__do
m.nextSibling)e.__dom.childNodes.push(t)}return e.__dom.childNodes},getParentNod
e:function(e){return e.__dom&&void 0!==e.__dom.parentNode?e.__dom.parentNode:e.p
arentNode},getFirstChild:function(e){return e.__dom&&void 0!==e.__dom.firstChild
?e.__dom.firstChild:e.firstChild},getLastChild:function(e){return e.__dom&&void
0!==e.__dom.lastChild?e.__dom.lastChild:e.lastChild},getNextSibling:function(e){
return e.__dom&&void 0!==e.__dom.nextSibling?e.__dom.nextSibling:e.nextSibling},
getPreviousSibling:function(e){return e.__dom&&void 0!==e.__dom.previousSibling?
e.__dom.previousSibling:e.previousSibling},getFirstElementChild:function(e){retu
rn e.__dom&&void 0!==e.__dom.firstChild?this._getFirstElementChild(e):e.firstEle
mentChild},_getFirstElementChild:function(e){for(var t=e.__dom.firstChild;t&&t.n
odeType!==Node.ELEMENT_NODE;)t=t.__dom.nextSibling;return t},getLastElementChild
:function(e){return e.__dom&&void 0!==e.__dom.lastChild?this._getLastElementChil
d(e):e.lastElementChild},_getLastElementChild:function(e){for(var t=e.__dom.last
Child;t&&t.nodeType!==Node.ELEMENT_NODE;)t=t.__dom.previousSibling;return t},get
NextElementSibling:function(e){return e.__dom&&void 0!==e.__dom.nextSibling?this
._getNextElementSibling(e):e.nextElementSibling},_getNextElementSibling:function
(e){for(var t=e.__dom.nextSibling;t&&t.nodeType!==Node.ELEMENT_NODE;)t=t.__dom.n
extSibling;return t},getPreviousElementSibling:function(e){return e.__dom&&void
0!==e.__dom.previousSibling?this._getPreviousElementSibling(e):e.previousElement
Sibling},_getPreviousElementSibling:function(e){for(var t=e.__dom.previousSiblin
g;t&&t.nodeType!==Node.ELEMENT_NODE;)t=t.__dom.previousSibling;return t},saveChi
ldNodes:function(e){if(!this.hasChildNodes(e)){e.__dom=e.__dom||{},e.__dom.first
Child=e.firstChild,e.__dom.lastChild=e.lastChild,e.__dom.childNodes=[];for(var t
=e.firstChild;t;t=t.nextSibling)t.__dom=t.__dom||{},t.__dom.parentNode=e,e.__dom
.childNodes.push(t),t.__dom.nextSibling=t.nextSibling,t.__dom.previousSibling=t.
previousSibling}},recordInsertBefore:function(e,t,o){if(t.__dom.childNodes=null,
e.nodeType===Node.DOCUMENT_FRAGMENT_NODE)for(var i=e.firstChild;i;i=i.nextSiblin
g)this._linkNode(i,t,o);else this._linkNode(e,t,o)},_linkNode:function(e,t,o){e.
__dom=e.__dom||{},t.__dom=t.__dom||{},o&&(o.__dom=o.__dom||{}),e.__dom.previousS
ibling=o?o.__dom.previousSibling:t.__dom.lastChild,e.__dom.previousSibling&&(e._
_dom.previousSibling.__dom.nextSibling=e),e.__dom.nextSibling=o||null,e.__dom.ne
xtSibling&&(e.__dom.nextSibling.__dom.previousSibling=e),e.__dom.parentNode=t,o?
o===t.__dom.firstChild&&(t.__dom.firstChild=e):(t.__dom.lastChild=e,t.__dom.firs
tChild||(t.__dom.firstChild=e)),t.__dom.childNodes=null},recordRemoveChild:funct
ion(e,t){e.__dom=e.__dom||{},t.__dom=t.__dom||{},e===t.__dom.firstChild&&(t.__do
m.firstChild=e.__dom.nextSibling),e===t.__dom.lastChild&&(t.__dom.lastChild=e.__
dom.previousSibling);var o=e.__dom.previousSibling,i=e.__dom.nextSibling;o&&(o._
_dom.nextSibling=i),i&&(i.__dom.previousSibling=o),e.__dom.parentNode=e.__dom.pr
eviousSibling=e.__dom.nextSibling=void 0,t.__dom.childNodes=null}},Polymer.TreeA
pi.Composed={getChildNodes:function(e){return Polymer.TreeApi.arrayCopyChildNode
s(e)},getParentNode:function(e){return e.parentNode},clearChildNodes:function(e)
{e.textContent=""},insertBefore:function(t,o,i){return e.call(t,o,i||null)},appe
ndChild:function(e,o){return t.call(e,o)},removeChild:function(e,t){return o.cal
l(e,t)}}}(),Polymer.DomApi=function(){"use strict";var e=Polymer.Settings,t=Poly
mer.TreeApi,o=function(e){this.node=i?o.wrap(e):e},i=e.hasShadow&&!e.nativeShado
w;o.wrap=window.wrap?window.wrap:function(e){return e},o.prototype={flush:functi
on(){Polymer.dom.flush()},deepContains:function(e){if(this.node.contains(e))retu
rn!0;for(var t=e,o=e.ownerDocument;t&&t!==o&&t!==this.node;)t=Polymer.dom(t).par
entNode||t.host;return t===this.node},queryDistributedElements:function(e){for(v
ar t,i=this.getEffectiveChildNodes(),n=[],s=0,r=i.length;s<r&&(t=i[s]);s++)t.nod
eType===Node.ELEMENT_NODE&&o.matchesSelector.call(t,e)&&n.push(t);return n},getE
ffectiveChildNodes:function(){for(var e,t=[],o=this.childNodes,i=0,r=o.length;i<
r&&(e=o[i]);i++)if(e.localName===n)for(var d=s(e).getDistributedNodes(),a=0;a<d.
length;a++)t.push(d[a]);else t.push(e);return t},observeNodes:function(e){if(e)r
eturn this.observer||(this.observer=this.node.localName===n?new o.DistributedNod
esObserver(this):new o.EffectiveNodesObserver(this)),this.observer.addListener(e
)},unobserveNodes:function(e){this.observer&&this.observer.removeListener(e)},no
tifyObserver:function(){this.observer&&this.observer.notify()},_query:function(e
,o,i){o=o||this.node;var n=[];return this._queryElements(t.Logical.getChildNodes
(o),e,i,n),n},_queryElements:function(e,t,o,i){for(var n,s=0,r=e.length;s<r&&(n=
e[s]);s++)if(n.nodeType===Node.ELEMENT_NODE&&this._queryElement(n,t,o,i))return!
0},_queryElement:function(e,o,i,n){var s=o(e);return s&&n.push(e),i&&i(s)?s:void
this._queryElements(t.Logical.getChildNodes(e),o,i,n)}};var n=o.CONTENT="conten
t",s=o.factory=function(e){return e=e||document,e.__domApi||(e.__domApi=new o.ct
or(e)),e.__domApi};o.hasApi=function(e){return Boolean(e.__domApi)},o.ctor=o,Pol
ymer.dom=function(e,t){return e instanceof Event?Polymer.EventApi.factory(e):o.f
actory(e,t)};var r=Element.prototype;return o.matchesSelector=r.matches||r.match
esSelector||r.mozMatchesSelector||r.msMatchesSelector||r.oMatchesSelector||r.web
kitMatchesSelector,o}(),function(){"use strict";var e=Polymer.Settings,t=Polymer
.DomApi,o=t.factory,i=Polymer.TreeApi,n=Polymer.domInnerHTML.getInnerHTML,s=t.CO
NTENT;if(!e.useShadow){var r=Element.prototype.cloneNode,d=Document.prototype.im
portNode;Polymer.Base.extend(t.prototype,{_lazyDistribute:function(e){e.shadyRoo
t&&e.shadyRoot._distributionClean&&(e.shadyRoot._distributionClean=!1,Polymer.do
m.addDebouncer(e.debounce("_distribute",e._distributeContent)))},appendChild:fun
ction(e){return this.insertBefore(e)},insertBefore:function(e,n){if(n&&i.Logical
.getParentNode(n)!==this.node)throw Error("The ref_node to be inserted before is
not a child of this node");if(e.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var r=i
.Logical.getParentNode(e);r?(t.hasApi(r)&&o(r).notifyObserver(),this._removeNode
(e)):this._removeOwnerShadyRoot(e)}if(!this._addNode(e,n)){n&&(n=n.localName===s
?this._firstComposedNode(n):n);var d=this.node._isShadyRoot?this.node.host:this.
node;n?i.Composed.insertBefore(d,e,n):i.Composed.appendChild(d,e)}return this.no
tifyObserver(),e},_addNode:function(e,t){var o=this.getOwnerRoot();if(o){var n=t
his._maybeAddInsertionPoint(e,this.node);o._invalidInsertionPoints||(o._invalidI
nsertionPoints=n),this._addNodeToHost(o.host,e)}i.Logical.hasChildNodes(this.nod
e)&&i.Logical.recordInsertBefore(e,this.node,t);var s=this._maybeDistribute(e)||
this.node.shadyRoot;if(s)if(e.nodeType===Node.DOCUMENT_FRAGMENT_NODE)for(;e.firs
tChild;)i.Composed.removeChild(e,e.firstChild);else{var r=i.Composed.getParentNo
de(e);r&&i.Composed.removeChild(r,e)}return s},removeChild:function(e){if(i.Logi
cal.getParentNode(e)!==this.node)throw Error("The node to be removed is not a ch
ild of this node: "+e);if(!this._removeNode(e)){var t=this.node._isShadyRoot?thi
s.node.host:this.node,o=i.Composed.getParentNode(e);t===o&&i.Composed.removeChil
d(t,e)}return this.notifyObserver(),e},_removeNode:function(e){var t,n=i.Logical
.hasParentNode(e)&&i.Logical.getParentNode(e),s=this._ownerShadyRootForNode(e);r
eturn n&&(t=o(e)._maybeDistributeParent(),i.Logical.recordRemoveChild(e,n),s&&th
is._removeDistributedChildren(s,e)&&(s._invalidInsertionPoints=!0,this._lazyDist
ribute(s.host))),this._removeOwnerShadyRoot(e),s&&this._removeNodeFromHost(s.hos
t,e),t},replaceChild:function(e,t){return this.insertBefore(e,t),this.removeChil
d(t),e},_hasCachedOwnerRoot:function(e){return Boolean(void 0!==e._ownerShadyRoo
t)},getOwnerRoot:function(){return this._ownerShadyRootForNode(this.node)},_owne
rShadyRootForNode:function(e){if(e){var t=e._ownerShadyRoot;if(void 0===t){if(e.
_isShadyRoot)t=e;else{var o=i.Logical.getParentNode(e);t=o?o._isShadyRoot?o:this
._ownerShadyRootForNode(o):null}(t||document.documentElement.contains(e))&&(e._o
wnerShadyRoot=t)}return t}},_maybeDistribute:function(e){var t=e.nodeType===Node
.DOCUMENT_FRAGMENT_NODE&&!e.__noContent&&o(e).querySelector(s),n=t&&i.Logical.ge
tParentNode(t).nodeType!==Node.DOCUMENT_FRAGMENT_NODE,r=t||e.localName===s;if(r)
{var d=this.getOwnerRoot();d&&this._lazyDistribute(d.host)}var a=this._nodeNeeds
Distribution(this.node);return a&&this._lazyDistribute(this.node),a||r&&!n},_may
beAddInsertionPoint:function(e,t){var n;if(e.nodeType!==Node.DOCUMENT_FRAGMENT_N
ODE||e.__noContent)e.localName===s&&(i.Logical.saveChildNodes(t),i.Logical.saveC
hildNodes(e),n=!0);else for(var r,d,a,l=o(e).querySelectorAll(s),h=0;h<l.length&
&(r=l[h]);h++)d=i.Logical.getParentNode(r),d===e&&(d=t),a=this._maybeAddInsertio
nPoint(r,d),n=n||a;return n},_updateInsertionPoints:function(e){for(var t,n=e.sh
adyRoot._insertionPoints=o(e.shadyRoot).querySelectorAll(s),r=0;r<n.length;r++)t
=n[r],i.Logical.saveChildNodes(t),i.Logical.saveChildNodes(i.Logical.getParentNo
de(t))},_nodeNeedsDistribution:function(e){return e&&e.shadyRoot&&t.hasInsertion
Point(e.shadyRoot)},_addNodeToHost:function(e,t){e._elementAdd&&e._elementAdd(t)
},_removeNodeFromHost:function(e,t){e._elementRemove&&e._elementRemove(t)},_remo
veDistributedChildren:function(e,t){for(var n,s=e._insertionPoints,r=0;r<s.lengt
h;r++){var d=s[r];if(this._contains(t,d))for(var a=o(d).getDistributedNodes(),l=
0;l<a.length;l++){n=!0;var h=a[l],u=i.Composed.getParentNode(h);u&&i.Composed.re
moveChild(u,h)}}return n},_contains:function(e,t){for(;t;){if(t==e)return!0;t=i.
Logical.getParentNode(t)}},_removeOwnerShadyRoot:function(e){if(this._hasCachedO
wnerRoot(e))for(var t,o=i.Logical.getChildNodes(e),n=0,s=o.length;n<s&&(t=o[n]);
n++)this._removeOwnerShadyRoot(t);e._ownerShadyRoot=void 0},_firstComposedNode:f
unction(e){for(var t,i,n=o(e).getDistributedNodes(),s=0,r=n.length;s<r&&(t=n[s])
;s++)if(i=o(t).getDestinationInsertionPoints(),i[i.length-1]===e)return t},query
Selector:function(e){var o=this._query(function(o){return t.matchesSelector.call
(o,e)},this.node,function(e){return Boolean(e)})[0];return o||null},querySelecto
rAll:function(e){return this._query(function(o){return t.matchesSelector.call(o,
e)},this.node)},getDestinationInsertionPoints:function(){return this.node._desti
nationInsertionPoints||[]},getDistributedNodes:function(){return this.node._dist
ributedNodes||[]},_clear:function(){for(;this.childNodes.length;)this.removeChil
d(this.childNodes[0])},setAttribute:function(e,t){this.node.setAttribute(e,t),th
is._maybeDistributeParent()},removeAttribute:function(e){this.node.removeAttribu
te(e),this._maybeDistributeParent()},_maybeDistributeParent:function(){if(this._
nodeNeedsDistribution(this.parentNode))return this._lazyDistribute(this.parentNo
de),!0},cloneNode:function(e){var t=r.call(this.node,!1);if(e)for(var i,n=this.c
hildNodes,s=o(t),d=0;d<n.length;d++)i=o(n[d]).cloneNode(!0),s.appendChild(i);ret
urn t},importNode:function(e,t){var n=this.node instanceof Document?this.node:th
is.node.ownerDocument,s=d.call(n,e,!1);if(t)for(var r,a=i.Logical.getChildNodes(
e),l=o(s),h=0;h<a.length;h++)r=o(n).importNode(a[h],!0),l.appendChild(r);return
s},_getComposedInnerHTML:function(){return n(this.node,!0)}}),Object.definePrope
rties(t.prototype,{activeElement:{get:function(){var e=document.activeElement;if
(!e)return null;var t=!!this.node._isShadyRoot;if(this.node!==document){if(!t)re
turn null;if(this.node.host===e||!this.node.host.contains(e))return null}for(var
i=o(e).getOwnerRoot();i&&i!==this.node;)e=i.host,i=o(e).getOwnerRoot();return t
his.node===document?i?null:e:i===this.node?e:null},configurable:!0},childNodes:{
get:function(){var e=i.Logical.getChildNodes(this.node);return Array.isArray(e)?
e:i.arrayCopyChildNodes(this.node)},configurable:!0},children:{get:function(){re
turn i.Logical.hasChildNodes(this.node)?Array.prototype.filter.call(this.childNo
des,function(e){return e.nodeType===Node.ELEMENT_NODE}):i.arrayCopyChildren(this
.node)},configurable:!0},parentNode:{get:function(){return i.Logical.getParentNo
de(this.node)},configurable:!0},firstChild:{get:function(){return i.Logical.getF
irstChild(this.node)},configurable:!0},lastChild:{get:function(){return i.Logica
l.getLastChild(this.node)},configurable:!0},nextSibling:{get:function(){return i
.Logical.getNextSibling(this.node)},configurable:!0},previousSibling:{get:functi
on(){return i.Logical.getPreviousSibling(this.node)},configurable:!0},firstEleme
ntChild:{get:function(){return i.Logical.getFirstElementChild(this.node)},config
urable:!0},lastElementChild:{get:function(){return i.Logical.getLastElementChild
(this.node)},configurable:!0},nextElementSibling:{get:function(){return i.Logica
l.getNextElementSibling(this.node)},configurable:!0},previousElementSibling:{get
:function(){return i.Logical.getPreviousElementSibling(this.node)},configurable:
!0},textContent:{get:function(){var e=this.node.nodeType;if(e===Node.TEXT_NODE||
e===Node.COMMENT_NODE)return this.node.textContent;for(var t,o=[],i=0,n=this.chi
ldNodes;t=n[i];i++)t.nodeType!==Node.COMMENT_NODE&&o.push(t.textContent);return
o.join("")},set:function(e){var t=this.node.nodeType;t===Node.TEXT_NODE||t===Nod
e.COMMENT_NODE?this.node.textContent=e:(this._clear(),e&&this.appendChild(docume
nt.createTextNode(e)))},configurable:!0},innerHTML:{get:function(){var e=this.no
de.nodeType;return e===Node.TEXT_NODE||e===Node.COMMENT_NODE?null:n(this.node)},
set:function(e){var t=this.node.nodeType;if(t!==Node.TEXT_NODE||t!==Node.COMMENT
_NODE){this._clear();var o=document.createElement("div");o.innerHTML=e;for(var n
=i.arrayCopyChildNodes(o),s=0;s<n.length;s++)this.appendChild(n[s])}},configurab
le:!0}}),t.hasInsertionPoint=function(e){return Boolean(e&&e._insertionPoints.le
ngth)}}}(),function(){"use strict";var e=Polymer.Settings,t=Polymer.TreeApi,o=Po
lymer.DomApi;if(e.useShadow){Polymer.Base.extend(o.prototype,{querySelectorAll:f
unction(e){return t.arrayCopy(this.node.querySelectorAll(e))},getOwnerRoot:funct
ion(){for(var e=this.node;e;){if(e.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&e.hos
t)return e;e=e.parentNode}},importNode:function(e,t){var o=this.node instanceof
Document?this.node:this.node.ownerDocument;return o.importNode(e,t)},getDestinat
ionInsertionPoints:function(){var e=this.node.getDestinationInsertionPoints&&thi
s.node.getDestinationInsertionPoints();return e?t.arrayCopy(e):[]},getDistribute
dNodes:function(){var e=this.node.getDistributedNodes&&this.node.getDistributedN
odes();return e?t.arrayCopy(e):[]}}),Object.defineProperties(o.prototype,{active
Element:{get:function(){var e=o.wrap(this.node),t=e.activeElement;return e.conta
ins(t)?t:null},configurable:!0},childNodes:{get:function(){return t.arrayCopyChi
ldNodes(this.node)},configurable:!0},children:{get:function(){return t.arrayCopy
Children(this.node)},configurable:!0},textContent:{get:function(){return this.no
de.textContent},set:function(e){return this.node.textContent=e},configurable:!0}
,innerHTML:{get:function(){return this.node.innerHTML},set:function(e){return th
is.node.innerHTML=e},configurable:!0}});var i=function(e){for(var t=0;t<e.length
;t++)n(e[t])},n=function(e){o.prototype[e]=function(){return this.node[e].apply(
this.node,arguments)}};i(["cloneNode","appendChild","insertBefore","removeChild"
,"replaceChild","setAttribute","removeAttribute","querySelector"]);var s=functio
n(e){for(var t=0;t<e.length;t++)r(e[t])},r=function(e){Object.defineProperty(o.p
rototype,e,{get:function(){return this.node[e]},configurable:!0})};s(["parentNod
e","firstChild","lastChild","nextSibling","previousSibling","firstElementChild",
"lastElementChild","nextElementSibling","previousElementSibling"])}}(),Polymer.B
ase.extend(Polymer.dom,{_flushGuard:0,_FLUSH_MAX:100,_needsTakeRecords:!Polymer.
Settings.useNativeCustomElements,_debouncers:[],_staticFlushList:[],_finishDebou
ncer:null,flush:function(){for(this._flushGuard=0,this._prepareFlush();this._deb
ouncers.length&&this._flushGuard<this._FLUSH_MAX;){for(;this._debouncers.length;
)this._debouncers.shift().complete();this._finishDebouncer&&this._finishDebounce
r.complete(),this._prepareFlush(),this._flushGuard++}this._flushGuard>=this._FLU
SH_MAX&&console.warn("Polymer.dom.flush aborted. Flush may not be complete.")},_
prepareFlush:function(){this._needsTakeRecords&&CustomElements.takeRecords();for
(var e=0;e<this._staticFlushList.length;e++)this._staticFlushList[e]()},addStati
cFlush:function(e){this._staticFlushList.push(e)},removeStaticFlush:function(e){
var t=this._staticFlushList.indexOf(e);t>=0&&this._staticFlushList.splice(t,1)},
addDebouncer:function(e){this._debouncers.push(e),this._finishDebouncer=Polymer.
Debounce(this._finishDebouncer,this._finishFlush)},_finishFlush:function(){Polym
er.dom._debouncers=[]}}),Polymer.EventApi=function(){"use strict";var e=Polymer.
DomApi.ctor,t=Polymer.Settings;e.Event=function(e){this.event=e},t.useShadow?e.E
vent.prototype={get rootTarget(){return this.event.path[0]},get localTarget(){re
turn this.event.target},get path(){var e=this.event.path;return Array.isArray(e)
||(e=Array.prototype.slice.call(e)),e}}:e.Event.prototype={get rootTarget(){retu
rn this.event.target},get localTarget(){for(var e=this.event.currentTarget,t=e&&
Polymer.dom(e).getOwnerRoot(),o=this.path,i=0;i<o.length;i++)if(Polymer.dom(o[i]
).getOwnerRoot()===t)return o[i]},get path(){if(!this.event._path){for(var e=[],
t=this.rootTarget;t;){e.push(t);var o=Polymer.dom(t).getDestinationInsertionPoin
ts();if(o.length){for(var i=0;i<o.length-1;i++)e.push(o[i]);t=o[o.length-1]}else
t=Polymer.dom(t).parentNode||t.host}e.push(window),this.event._path=e}return th
is.event._path}};var o=function(t){return t.__eventApi||(t.__eventApi=new e.Even
t(t)),t.__eventApi};return{factory:o}}(),function(){"use strict";var e=Polymer.D
omApi.ctor,t=Polymer.Settings.useShadow;Object.defineProperty(e.prototype,"class
List",{get:function(){return this._classList||(this._classList=new e.ClassList(t
his)),this._classList},configurable:!0}),e.ClassList=function(e){this.domApi=e,t
his.node=e.node},e.ClassList.prototype={add:function(){this.node.classList.add.a
pply(this.node.classList,arguments),this._distributeParent()},remove:function(){
this.node.classList.remove.apply(this.node.classList,arguments),this._distribute
Parent()},toggle:function(){this.node.classList.toggle.apply(this.node.classList
,arguments),this._distributeParent()},_distributeParent:function(){t||this.domAp
i._maybeDistributeParent()},contains:function(){return this.node.classList.conta
ins.apply(this.node.classList,arguments)}}}(),function(){"use strict";var e=Poly
mer.DomApi.ctor,t=Polymer.Settings;if(e.EffectiveNodesObserver=function(e){this.
domApi=e,this.node=this.domApi.node,this._listeners=[]},e.EffectiveNodesObserver
.prototype={addListener:function(e){this._isSetup||(this._setup(),this._isSetup=
!0);var t={fn:e,_nodes:[]};return this._listeners.push(t),this._scheduleNotify()
,t},removeListener:function(e){var t=this._listeners.indexOf(e);t>=0&&(this._lis
teners.splice(t,1),e._nodes=[]),this._hasListeners()||(this._cleanup(),this._isS
etup=!1)},_setup:function(){this._observeContentElements(this.domApi.childNodes)
},_cleanup:function(){this._unobserveContentElements(this.domApi.childNodes)},_h
asListeners:function(){return Boolean(this._listeners.length)},_scheduleNotify:f
unction(){this._debouncer&&this._debouncer.stop(),this._debouncer=Polymer.Deboun
ce(this._debouncer,this._notify),this._debouncer.context=this,Polymer.dom.addDeb
ouncer(this._debouncer)},notify:function(){this._hasListeners()&&this._scheduleN
otify()},_notify:function(){this._beforeCallListeners(),this._callListeners()},_
beforeCallListeners:function(){this._updateContentElements()},_updateContentElem
ents:function(){this._observeContentElements(this.domApi.childNodes)},_observeCo
ntentElements:function(e){for(var t,o=0;o<e.length&&(t=e[o]);o++)this._isContent
(t)&&(t.__observeNodesMap=t.__observeNodesMap||new WeakMap,t.__observeNodesMap.h
as(this)||t.__observeNodesMap.set(this,this._observeContent(t)))},_observeConten
t:function(e){var t=this,o=Polymer.dom(e).observeNodes(function(){t._scheduleNot
ify()});return o._avoidChangeCalculation=!0,o},_unobserveContentElements:functio
n(e){for(var t,o,i=0;i<e.length&&(t=e[i]);i++)this._isContent(t)&&(o=t.__observe
NodesMap.get(this),o&&(Polymer.dom(t).unobserveNodes(o),t.__observeNodesMap.dele
te(this)))},_isContent:function(e){return"content"===e.localName},_callListeners
:function(){for(var e,t=this._listeners,o=this._getEffectiveNodes(),i=0;i<t.leng
th&&(e=t[i]);i++){var n=this._generateListenerInfo(e,o);(n||e._alwaysNotify)&&th
is._callListener(e,n)}},_getEffectiveNodes:function(){return this.domApi.getEffe
ctiveChildNodes()},_generateListenerInfo:function(e,t){if(e._avoidChangeCalculat
ion)return!0;for(var o,i=e._nodes,n={target:this.node,addedNodes:[],removedNodes
:[]},s=Polymer.ArraySplice.calculateSplices(t,i),r=0;r<s.length&&(o=s[r]);r++)fo
r(var d,a=0;a<o.removed.length&&(d=o.removed[a]);a++)n.removedNodes.push(d);for(
r=0,o;r<s.length&&(o=s[r]);r++)for(a=o.index;a<o.index+o.addedCount;a++)n.addedN
odes.push(t[a]);return e._nodes=t,n.addedNodes.length||n.removedNodes.length?n:v
oid 0},_callListener:function(e,t){return e.fn.call(this.node,t)},enableShadowAt
tributeTracking:function(){}},t.useShadow){var o=e.EffectiveNodesObserver.protot
ype._setup,i=e.EffectiveNodesObserver.prototype._cleanup;Polymer.Base.extend(e.E
ffectiveNodesObserver.prototype,{_setup:function(){if(!this._observer){var e=thi
s;this._mutationHandler=function(t){t&&t.length&&e._scheduleNotify()},this._obse
rver=new MutationObserver(this._mutationHandler),this._boundFlush=function(){e._
flush()},Polymer.dom.addStaticFlush(this._boundFlush),this._observer.observe(thi
s.node,{childList:!0})}o.call(this)},_cleanup:function(){this._observer.disconne
ct(),this._observer=null,this._mutationHandler=null,Polymer.dom.removeStaticFlus
h(this._boundFlush),i.call(this)},_flush:function(){this._observer&&this._mutati
onHandler(this._observer.takeRecords())},enableShadowAttributeTracking:function(
){if(this._observer){this._makeContentListenersAlwaysNotify(),this._observer.dis
connect(),this._observer.observe(this.node,{childList:!0,attributes:!0,subtree:!
0});var e=this.domApi.getOwnerRoot(),t=e&&e.host;t&&Polymer.dom(t).observer&&Pol
ymer.dom(t).observer.enableShadowAttributeTracking()}},_makeContentListenersAlwa
ysNotify:function(){for(var e,t=0;t<this._listeners.length;t++)e=this._listeners
[t],e._alwaysNotify=e._isContentListener}})}}(),function(){"use strict";var e=Po
lymer.DomApi.ctor,t=Polymer.Settings;e.DistributedNodesObserver=function(t){e.Ef
fectiveNodesObserver.call(this,t)},e.DistributedNodesObserver.prototype=Object.c
reate(e.EffectiveNodesObserver.prototype),Polymer.Base.extend(e.DistributedNodes
Observer.prototype,{_setup:function(){},_cleanup:function(){},_beforeCallListene
rs:function(){},_getEffectiveNodes:function(){return this.domApi.getDistributedN
odes()}}),t.useShadow&&Polymer.Base.extend(e.DistributedNodesObserver.prototype,
{_setup:function(){if(!this._observer){var e=this.domApi.getOwnerRoot(),t=e&&e.h
ost;if(t){var o=this;this._observer=Polymer.dom(t).observeNodes(function(){o._sc
heduleNotify()}),this._observer._isContentListener=!0,this._hasAttrSelect()&&Pol
ymer.dom(t).observer.enableShadowAttributeTracking()}}},_hasAttrSelect:function(
){var e=this.node.getAttribute("select");return e&&e.match(/[[.]+/)},_cleanup:fu
nction(){var e=this.domApi.getOwnerRoot(),t=e&&e.host;t&&Polymer.dom(t).unobserv
eNodes(this._observer),this._observer=null}})}(),function(){function e(e,t){t._d
istributedNodes.push(e);var o=e._destinationInsertionPoints;o?o.push(t):e._desti
nationInsertionPoints=[t]}function t(e){var t=e._distributedNodes;if(t)for(var o
=0;o<t.length;o++){var i=t[o]._destinationInsertionPoints;i&&i.splice(i.indexOf(
e)+1,i.length)}}function o(e,t){var o=u.Logical.getParentNode(e);o&&o.shadyRoot&
&h.hasInsertionPoint(o.shadyRoot)&&o.shadyRoot._distributionClean&&(o.shadyRoot.
_distributionClean=!1,t.shadyRoot._dirtyRoots.push(o))}function i(e,t){var o=t._
destinationInsertionPoints;return o&&o[o.length-1]===e}function n(e){return"cont
ent"==e.localName}function s(e){for(;e&&r(e);)e=e.domHost;return e}function r(e)
{for(var t,o=u.Logical.getChildNodes(e),i=0;i<o.length;i++)if(t=o[i],t.localName
&&"content"===t.localName)return e.domHost}function d(e){for(var t,o=0;o<e._inse
rtionPoints.length;o++)t=e._insertionPoints[o],h.hasApi(t)&&Polymer.dom(t).notif
yObserver()}function a(e){h.hasApi(e)&&Polymer.dom(e).notifyObserver()}function
l(e){if(c&&e)for(var t=0;t<e.length;t++)CustomElements.upgrade(e[t])}var h=Polym
er.DomApi,u=Polymer.TreeApi;Polymer.Base._addFeature({_prepShady:function(){this
._useContent=this._useContent||Boolean(this._template)},_setupShady:function(){t
his.shadyRoot=null,this.__domApi||(this.__domApi=null),this.__dom||(this.__dom=n
ull),this._ownerShadyRoot||(this._ownerShadyRoot=void 0)},_poolContent:function(
){this._useContent&&u.Logical.saveChildNodes(this)},_setupRoot:function(){this._
useContent&&(this._createLocalRoot(),this.dataHost||l(u.Logical.getChildNodes(th
is)))},_createLocalRoot:function(){this.shadyRoot=this.root,this.shadyRoot._dist
ributionClean=!1,this.shadyRoot._hasDistributed=!1,this.shadyRoot._isShadyRoot=!
0,this.shadyRoot._dirtyRoots=[];var e=this.shadyRoot._insertionPoints=!this._not
es||this._notes._hasContent?this.shadyRoot.querySelectorAll("content"):[];u.Logi
cal.saveChildNodes(this.shadyRoot);for(var t,o=0;o<e.length;o++)t=e[o],u.Logical
.saveChildNodes(t),u.Logical.saveChildNodes(t.parentNode);this.shadyRoot.host=th
is},get domHost(){var e=Polymer.dom(this).getOwnerRoot();return e&&e.host},distr
ibuteContent:function(e){if(this.shadyRoot){this.shadyRoot._invalidInsertionPoin
ts=this.shadyRoot._invalidInsertionPoints||e;var t=s(this);Polymer.dom(this)._la
zyDistribute(t)}},_distributeContent:function(){this._useContent&&!this.shadyRoo
t._distributionClean&&(this.shadyRoot._invalidInsertionPoints&&(Polymer.dom(this
)._updateInsertionPoints(this),this.shadyRoot._invalidInsertionPoints=!1),this._
beginDistribute(),this._distributeDirtyRoots(),this._finishDistribute())},_begin
Distribute:function(){this._useContent&&h.hasInsertionPoint(this.shadyRoot)&&(th
is._resetDistribution(),this._distributePool(this.shadyRoot,this._collectPool())
); | 1 <!DOCTYPE html><html><head><meta charset="UTF-8"> </head><body><div hidden="" by
-vulcanize=""><script>!function(){function e(){document.body.removeAttribute("un
resolved")}window.WebComponents?addEventListener("WebComponentsReady",e):"intera
ctive"===document.readyState||"complete"===document.readyState?e():addEventListe
ner("DOMContentLoaded",e)}(),window.Polymer={Settings:function(){var e=window.Po
lymer||{};if(!e.noUrlSettings)for(var t,r=location.search.slice(1).split("&"),i=
0;i<r.length&&(t=r[i]);i++)t=t.split("="),t[0]&&(e[t[0]]=t[1]||!0);return e.want
Shadow="shadow"===e.dom,e.hasShadow=Boolean(Element.prototype.createShadowRoot),
e.nativeShadow=e.hasShadow&&!window.ShadowDOMPolyfill,e.useShadow=e.wantShadow&&
e.hasShadow,e.hasNativeImports=Boolean("import"in document.createElement("link")
),e.useNativeImports=e.hasNativeImports,e.useNativeCustomElements=!window.Custom
Elements||window.CustomElements.useNative,e.useNativeShadow=e.useShadow&&e.nativ
eShadow,e.usePolyfillProto=!e.useNativeCustomElements&&!Object.__proto__,e.hasNa
tiveCSSProperties=!navigator.userAgent.match("AppleWebKit/601")&&window.CSS&&CSS
.supports&&CSS.supports("box-shadow","0 0 0 var(--foo)"),e.useNativeCSSPropertie
s=e.hasNativeCSSProperties&&e.lazyRegister&&e.useNativeCSSProperties,e}()},funct
ion(){var e=window.Polymer;window.Polymer=function(e){"function"==typeof e&&(e=e
.prototype),e||(e={});var r=t(e);e=r.prototype;var i={prototype:e};return e.exte
nds&&(i.extends=e.extends),Polymer.telemetry._registrate(e),document.registerEle
ment(e.is,i),r};var t=function(e){var t=Polymer.Base;return e.extends&&(t=Polyme
r.Base._getExtendedPrototype(e.extends)),e=Polymer.Base.chainObject(e,t),e.regis
terCallback(),e.constructor};if(e)for(var r in e)Polymer[r]=e[r];Polymer.Class=t
}(),Polymer.telemetry={registrations:[],_regLog:function(e){console.log("["+e.is
+"]: registered")},_registrate:function(e){this.registrations.push(e),Polymer.lo
g&&this._regLog(e)},dumpRegistrations:function(){this.registrations.forEach(this
._regLog)}},Object.defineProperty(window,"currentImport",{enumerable:!0,configur
able:!0,get:function(){return(document._currentScript||document.currentScript).o
wnerDocument}}),Polymer.RenderStatus={_ready:!1,_callbacks:[],whenReady:function
(e){this._ready?e():this._callbacks.push(e)},_makeReady:function(){this._ready=!
0;for(var e=0;e<this._callbacks.length;e++)this._callbacks[e]();this._callbacks=
[]},_catchFirstRender:function(){requestAnimationFrame(function(){Polymer.Render
Status._makeReady()})},_afterNextRenderQueue:[],_waitingNextRender:!1,afterNextR
ender:function(e,t,r){this._watchNextRender(),this._afterNextRenderQueue.push([e
,t,r])},hasRendered:function(){return this._ready},_watchNextRender:function(){i
f(!this._waitingNextRender){this._waitingNextRender=!0;var e=function(){Polymer.
RenderStatus._flushNextRender()};this._ready?requestAnimationFrame(e):this.whenR
eady(e)}},_flushNextRender:function(){var e=this;setTimeout(function(){e._flushR
enderCallbacks(e._afterNextRenderQueue),e._afterNextRenderQueue=[],e._waitingNex
tRender=!1})},_flushRenderCallbacks:function(e){for(var t,r=0;r<e.length;r++)t=e
[r],t[1].apply(t[0],t[2]||Polymer.nar)}},window.HTMLImports?HTMLImports.whenRead
y(function(){Polymer.RenderStatus._catchFirstRender()}):Polymer.RenderStatus._ca
tchFirstRender(),Polymer.ImportStatus=Polymer.RenderStatus,Polymer.ImportStatus.
whenLoaded=Polymer.ImportStatus.whenReady,function(){"use strict";var e=Polymer.
Settings;Polymer.Base={__isPolymerInstance__:!0,_addFeature:function(e){this.ext
end(this,e)},registerCallback:function(){"max"===e.lazyRegister?this.beforeRegis
ter&&this.beforeRegister():(this._desugarBehaviors(),this._doBehavior("beforeReg
ister")),this._registerFeatures(),e.lazyRegister||this.ensureRegisterFinished()}
,createdCallback:function(){this.__hasRegisterFinished||this._ensureRegisterFini
shed(this.__proto__),Polymer.telemetry.instanceCount++,this.root=this,this._doBe
havior("created"),this._initFeatures()},ensureRegisterFinished:function(){this._
ensureRegisterFinished(this)},_ensureRegisterFinished:function(t){t.__hasRegiste
rFinished===t.is&&t.is||("max"===e.lazyRegister&&(t._desugarBehaviors(),t._doBeh
aviorOnly("beforeRegister")),t.__hasRegisterFinished=t.is,t._finishRegisterFeatu
res&&t._finishRegisterFeatures(),t._doBehavior("registered"),e.usePolyfillProto&
&t!==this&&t.extend(this,t))},attachedCallback:function(){var e=this;Polymer.Ren
derStatus.whenReady(function(){e.isAttached=!0,e._doBehavior("attached")})},deta
chedCallback:function(){var e=this;Polymer.RenderStatus.whenReady(function(){e.i
sAttached=!1,e._doBehavior("detached")})},attributeChangedCallback:function(e,t,
r){this._attributeChangedImpl(e),this._doBehavior("attributeChanged",[e,t,r])},_
attributeChangedImpl:function(e){this._setAttributeToProperty(this,e)},extend:fu
nction(e,t){if(e&&t)for(var r,i=Object.getOwnPropertyNames(t),o=0;o<i.length&&(r
=i[o]);o++)this.copyOwnProperty(r,t,e);return e||t},mixin:function(e,t){for(var
r in t)e[r]=t[r];return e},copyOwnProperty:function(e,t,r){var i=Object.getOwnPr
opertyDescriptor(t,e);i&&Object.defineProperty(r,e,i)},_logger:function(e,t){swi
tch(1===t.length&&Array.isArray(t[0])&&(t=t[0]),e){case"log":case"warn":case"err
or":console[e].apply(console,t)}},_log:function(){var e=Array.prototype.slice.ca
ll(arguments,0);this._logger("log",e)},_warn:function(){var e=Array.prototype.sl
ice.call(arguments,0);this._logger("warn",e)},_error:function(){var e=Array.prot
otype.slice.call(arguments,0);this._logger("error",e)},_logf:function(){return t
his._logPrefix.concat(this.is).concat(Array.prototype.slice.call(arguments,0))}}
,Polymer.Base._logPrefix=function(){var e=window.chrome&&!/edge/i.test(navigator
.userAgent)||/firefox/i.test(navigator.userAgent);return e?["%c[%s::%s]:","font-
weight: bold; background-color:#EEEE00;"]:["[%s::%s]:"]}(),Polymer.Base.chainObj
ect=function(e,t){return e&&t&&e!==t&&(Object.__proto__||(e=Polymer.Base.extend(
Object.create(t),e)),e.__proto__=t),e},Polymer.Base=Polymer.Base.chainObject(Pol
ymer.Base,HTMLElement.prototype),window.CustomElements?Polymer.instanceof=Custom
Elements.instanceof:Polymer.instanceof=function(e,t){return e instanceof t},Poly
mer.isInstance=function(e){return Boolean(e&&e.__isPolymerInstance__)},Polymer.t
elemetry.instanceCount=0}(),function(){function e(){if(s)for(var e,t=document._c
urrentScript||document.currentScript,r=t&&t.ownerDocument||document,i=r.querySel
ectorAll("dom-module"),o=i.length-1;o>=0&&(e=i[o]);o--){if(e.__upgraded__)return
;CustomElements.upgrade(e)}}var t={},r={},i=function(e){return t[e]||r[e.toLower
Case()]},o=function(){return document.createElement("dom-module")};o.prototype=O
bject.create(HTMLElement.prototype),Polymer.Base.extend(o.prototype,{constructor
:o,createdCallback:function(){this.register()},register:function(e){e=e||this.id
||this.getAttribute("name")||this.getAttribute("is"),e&&(this.id=e,t[e]=this,r[e
.toLowerCase()]=this)},import:function(t,r){if(t){var o=i(t);return o||(e(),o=i(
t)),o&&r&&(o=o.querySelector(r)),o}}});var s=window.CustomElements&&!CustomEleme
nts.useNative;document.registerElement("dom-module",o)}(),Polymer.Base._addFeatu
re({_prepIs:function(){if(!this.is){var e=(document._currentScript||document.cur
rentScript).parentNode;if("dom-module"===e.localName){var t=e.id||e.getAttribute
("name")||e.getAttribute("is");this.is=t}}this.is&&(this.is=this.is.toLowerCase(
))}}),Polymer.Base._addFeature({behaviors:[],_desugarBehaviors:function(){this.b
ehaviors.length&&(this.behaviors=this._desugarSomeBehaviors(this.behaviors))},_d
esugarSomeBehaviors:function(e){var t=[];e=this._flattenBehaviorsList(e);for(var
r=e.length-1;r>=0;r--){var i=e[r];t.indexOf(i)===-1&&(this._mixinBehavior(i),t.
unshift(i))}return t},_flattenBehaviorsList:function(e){for(var t=[],r=0;r<e.len
gth;r++){var i=e[r];i instanceof Array?t=t.concat(this._flattenBehaviorsList(i))
:i?t.push(i):this._warn(this._logf("_flattenBehaviorsList","behavior is null, ch
eck for missing or 404 import"))}return t},_mixinBehavior:function(e){for(var t,
r=Object.getOwnPropertyNames(e),i=0;i<r.length&&(t=r[i]);i++)Polymer.Base._behav
iorProperties[t]||this.hasOwnProperty(t)||this.copyOwnProperty(t,e,this)},_prepB
ehaviors:function(){this._prepFlattenedBehaviors(this.behaviors)},_prepFlattened
Behaviors:function(e){for(var t=0,r=e.length;t<r;t++)this._prepBehavior(e[t]);th
is._prepBehavior(this)},_doBehavior:function(e,t){for(var r=0;r<this.behaviors.l
ength;r++)this._invokeBehavior(this.behaviors[r],e,t);this._invokeBehavior(this,
e,t)},_doBehaviorOnly:function(e,t){for(var r=0;r<this.behaviors.length;r++)this
._invokeBehavior(this.behaviors[r],e,t)},_invokeBehavior:function(e,t,r){var i=e
[t];i&&i.apply(this,r||Polymer.nar)},_marshalBehaviors:function(){for(var e=0;e<
this.behaviors.length;e++)this._marshalBehavior(this.behaviors[e]);this._marshal
Behavior(this)}}),Polymer.Base._behaviorProperties={hostAttributes:!0,beforeRegi
ster:!0,registered:!0,properties:!0,observers:!0,listeners:!0,created:!0,attache
d:!0,detached:!0,attributeChanged:!0,ready:!0},Polymer.Base._addFeature({_getExt
endedPrototype:function(e){return this._getExtendedNativePrototype(e)},_nativePr
ototypes:{},_getExtendedNativePrototype:function(e){var t=this._nativePrototypes
[e];if(!t){var r=this.getNativePrototype(e);t=this.extend(Object.create(r),Polym
er.Base),this._nativePrototypes[e]=t}return t},getNativePrototype:function(e){re
turn Object.getPrototypeOf(document.createElement(e))}}),Polymer.Base._addFeatur
e({_prepConstructor:function(){this._factoryArgs=this.extends?[this.extends,this
.is]:[this.is];var e=function(){return this._factory(arguments)};this.hasOwnProp
erty("extends")&&(e.extends=this.extends),Object.defineProperty(this,"constructo
r",{value:e,writable:!0,configurable:!0}),e.prototype=this},_factory:function(e)
{var t=document.createElement.apply(document,this._factoryArgs);return this.fact
oryImpl&&this.factoryImpl.apply(t,e),t}}),Polymer.nob=Object.create(null),Polyme
r.Base._addFeature({properties:{},getPropertyInfo:function(e){var t=this._getPro
pertyInfo(e,this.properties);if(!t)for(var r=0;r<this.behaviors.length;r++)if(t=
this._getPropertyInfo(e,this.behaviors[r].properties))return t;return t||Polymer
.nob},_getPropertyInfo:function(e,t){var r=t&&t[e];return"function"==typeof r&&(
r=t[e]={type:r}),r&&(r.defined=!0),r},_prepPropertyInfo:function(){this._propert
yInfo={};for(var e=0;e<this.behaviors.length;e++)this._addPropertyInfo(this._pro
pertyInfo,this.behaviors[e].properties);this._addPropertyInfo(this._propertyInfo
,this.properties),this._addPropertyInfo(this._propertyInfo,this._propertyEffects
)},_addPropertyInfo:function(e,t){if(t){var r,i;for(var o in t)r=e[o],i=t[o],("_
"!==o[0]||i.readOnly)&&(e[o]?(r.type||(r.type=i.type),r.readOnly||(r.readOnly=i.
readOnly)):e[o]={type:"function"==typeof i?i:i.type,readOnly:i.readOnly,attribut
e:Polymer.CaseMap.camelToDashCase(o)})}}}),Polymer.CaseMap={_caseMap:{},_rx:{das
hToCamel:/-[a-z]/g,camelToDash:/([A-Z])/g},dashToCamelCase:function(e){return th
is._caseMap[e]||(this._caseMap[e]=e.indexOf("-")<0?e:e.replace(this._rx.dashToCa
mel,function(e){return e[1].toUpperCase()}))},camelToDashCase:function(e){return
this._caseMap[e]||(this._caseMap[e]=e.replace(this._rx.camelToDash,"-$1").toLow
erCase())}},Polymer.Base._addFeature({_addHostAttributes:function(e){this._aggre
gatedAttributes||(this._aggregatedAttributes={}),e&&this.mixin(this._aggregatedA
ttributes,e)},_marshalHostAttributes:function(){this._aggregatedAttributes&&this
._applyAttributes(this,this._aggregatedAttributes)},_applyAttributes:function(e,
t){for(var r in t)if(!this.hasAttribute(r)&&"class"!==r){var i=t[r];this.seriali
zeValueToAttribute(i,r,this)}},_marshalAttributes:function(){this._takeAttribute
sToModel(this)},_takeAttributesToModel:function(e){if(this.hasAttributes())for(v
ar t in this._propertyInfo){var r=this._propertyInfo[t];this.hasAttribute(r.attr
ibute)&&this._setAttributeToProperty(e,r.attribute,t,r)}},_setAttributeToPropert
y:function(e,t,r,i){if(!this._serializing&&(r=r||Polymer.CaseMap.dashToCamelCase
(t),i=i||this._propertyInfo&&this._propertyInfo[r],i&&!i.readOnly)){var o=this.g
etAttribute(t);e[r]=this.deserialize(o,i.type)}},_serializing:!1,reflectProperty
ToAttribute:function(e,t,r){this._serializing=!0,r=void 0===r?this[e]:r,this.ser
ializeValueToAttribute(r,t||Polymer.CaseMap.camelToDashCase(e)),this._serializin
g=!1},serializeValueToAttribute:function(e,t,r){var i=this.serialize(e);r=r||thi
s,void 0===i?r.removeAttribute(t):r.setAttribute(t,i)},deserialize:function(e,t)
{switch(t){case Number:e=Number(e);break;case Boolean:e=null!=e;break;case Objec
t:try{e=JSON.parse(e)}catch(e){}break;case Array:try{e=JSON.parse(e)}catch(t){e=
null,console.warn("Polymer::Attributes: couldn`t decode Array as JSON")}break;ca
se Date:e=new Date(e);break;case String:}return e},serialize:function(e){switch(
typeof e){case"boolean":return e?"":void 0;case"object":if(e instanceof Date)ret
urn e.toString();if(e)try{return JSON.stringify(e)}catch(e){return""}default:ret
urn null!=e?e:void 0}}}),Polymer.version="1.7.0",Polymer.Base._addFeature({_regi
sterFeatures:function(){this._prepIs(),this._prepBehaviors(),this._prepConstruct
or(),this._prepPropertyInfo()},_prepBehavior:function(e){this._addHostAttributes
(e.hostAttributes)},_marshalBehavior:function(e){},_initFeatures:function(){this
._marshalHostAttributes(),this._marshalBehaviors()}})</script> <script>Polymer.B
ase._addFeature({_prepTemplate:function(){void 0===this._template&&(this._templa
te=Polymer.DomModule.import(this.is,"template")),this._template&&this._template.
hasAttribute("is")&&this._warn(this._logf("_prepTemplate","top-level Polymer tem
plate must not be a type-extension, found",this._template,"Move inside simple <t
emplate>.")),this._template&&!this._template.content&&window.HTMLTemplateElement
&&HTMLTemplateElement.decorate&&HTMLTemplateElement.decorate(this._template)},_s
tampTemplate:function(){this._template&&(this.root=this.instanceTemplate(this._t
emplate))},instanceTemplate:function(e){var t=document.importNode(e._content||e.
content,!0);return t}}),function(){var e=Polymer.Base.attachedCallback;Polymer.B
ase._addFeature({_hostStack:[],ready:function(){},_registerHost:function(e){this
.dataHost=e=e||Polymer.Base._hostStack[Polymer.Base._hostStack.length-1],e&&e._c
lients&&e._clients.push(this),this._clients=null,this._clientsReadied=!1},_begin
Hosting:function(){Polymer.Base._hostStack.push(this),this._clients||(this._clie
nts=[])},_endHosting:function(){Polymer.Base._hostStack.pop()},_tryReady:functio
n(){this._readied=!1,this._canReady()&&this._ready()},_canReady:function(){retur
n!this.dataHost||this.dataHost._clientsReadied},_ready:function(){this._beforeCl
ientsReady(),this._template&&(this._setupRoot(),this._readyClients()),this._clie
ntsReadied=!0,this._clients=null,this._afterClientsReady(),this._readySelf()},_r
eadyClients:function(){this._beginDistribute();var e=this._clients;if(e)for(var
t,o=0,i=e.length;o<i&&(t=e[o]);o++)t._ready();this._finishDistribute()},_readySe
lf:function(){this._doBehavior("ready"),this._readied=!0,this._attachedPending&&
(this._attachedPending=!1,this.attachedCallback())},_beforeClientsReady:function
(){},_afterClientsReady:function(){},_beforeAttached:function(){},attachedCallba
ck:function(){this._readied?(this._beforeAttached(),e.call(this)):this._attached
Pending=!0}})}(),Polymer.ArraySplice=function(){function e(e,t,o){return{index:e
,removed:t,addedCount:o}}function t(){}var o=0,i=1,n=2,s=3;return t.prototype={c
alcEditDistances:function(e,t,o,i,n,s){for(var r=s-n+1,d=o-t+1,a=new Array(r),l=
0;l<r;l++)a[l]=new Array(d),a[l][0]=l;for(var h=0;h<d;h++)a[0][h]=h;for(l=1;l<r;
l++)for(h=1;h<d;h++)if(this.equals(e[t+h-1],i[n+l-1]))a[l][h]=a[l-1][h-1];else{v
ar u=a[l-1][h]+1,c=a[l][h-1]+1;a[l][h]=u<c?u:c}return a},spliceOperationsFromEdi
tDistances:function(e){for(var t=e.length-1,r=e[0].length-1,d=e[t][r],a=[];t>0||
r>0;)if(0!=t)if(0!=r){var l,h=e[t-1][r-1],u=e[t-1][r],c=e[t][r-1];l=u<c?u<h?u:h:
c<h?c:h,l==h?(h==d?a.push(o):(a.push(i),d=h),t--,r--):l==u?(a.push(s),t--,d=u):(
a.push(n),r--,d=c)}else a.push(s),t--;else a.push(n),r--;return a.reverse(),a},c
alcSplices:function(t,r,d,a,l,h){var u=0,c=0,_=Math.min(d-r,h-l);if(0==r&&0==l&&
(u=this.sharedPrefix(t,a,_)),d==t.length&&h==a.length&&(c=this.sharedSuffix(t,a,
_-u)),r+=u,l+=u,d-=c,h-=c,d-r==0&&h-l==0)return[];if(r==d){for(var f=e(r,[],0);l
<h;)f.removed.push(a[l++]);return[f]}if(l==h)return[e(r,[],d-r)];var m=this.spli
ceOperationsFromEditDistances(this.calcEditDistances(t,r,d,a,l,h));f=void 0;for(
var p=[],v=r,g=l,b=0;b<m.length;b++)switch(m[b]){case o:f&&(p.push(f),f=void 0),
v++,g++;break;case i:f||(f=e(v,[],0)),f.addedCount++,v++,f.removed.push(a[g]),g+
+;break;case n:f||(f=e(v,[],0)),f.addedCount++,v++;break;case s:f||(f=e(v,[],0))
,f.removed.push(a[g]),g++}return f&&p.push(f),p},sharedPrefix:function(e,t,o){fo
r(var i=0;i<o;i++)if(!this.equals(e[i],t[i]))return i;return o},sharedSuffix:fun
ction(e,t,o){for(var i=e.length,n=t.length,s=0;s<o&&this.equals(e[--i],t[--n]);)
s++;return s},calculateSplices:function(e,t){return this.calcSplices(e,0,e.lengt
h,t,0,t.length)},equals:function(e,t){return e===t}},new t}(),Polymer.domInnerHT
ML=function(){function e(e){switch(e){case"&":return"&";case"<":return"<"
;case">":return">";case'"':return""";case" ":return" "}}function t(
t){return t.replace(r,e)}function o(t){return t.replace(d,e)}function i(e){for(v
ar t={},o=0;o<e.length;o++)t[e[o]]=!0;return t}function n(e,i,n){switch(e.nodeTy
pe){case Node.ELEMENT_NODE:for(var r,d=e.localName,h="<"+d,u=e.attributes,c=0;r=
u[c];c++)h+=" "+r.name+'="'+t(r.value)+'"';return h+=">",a[d]?h:h+s(e,n)+"</"+d+
">";case Node.TEXT_NODE:var _=e.data;return i&&l[i.localName]?_:o(_);case Node.C
OMMENT_NODE:return"\x3c!--"+e.data+"--\x3e";default:throw console.error(e),new E
rror("not implemented")}}function s(e,t){e instanceof HTMLTemplateElement&&(e=e.
content);for(var o,i="",s=Polymer.dom(e).childNodes,r=0,d=s.length;r<d&&(o=s[r])
;r++)i+=n(o,e,t);return i}var r=/[&\u00A0"]/g,d=/[&\u00A0<>]/g,a=i(["area","base
","br","col","command","embed","hr","img","input","keygen","link","meta","param"
,"source","track","wbr"]),l=i(["style","script","xmp","iframe","noembed","nofram
es","plaintext","noscript"]);return{getInnerHTML:s}}(),function(){"use strict";v
ar e=Element.prototype.insertBefore,t=Element.prototype.appendChild,o=Element.pr
ototype.removeChild;Polymer.TreeApi={arrayCopyChildNodes:function(e){for(var t=[
],o=0,i=e.firstChild;i;i=i.nextSibling)t[o++]=i;return t},arrayCopyChildren:func
tion(e){for(var t=[],o=0,i=e.firstElementChild;i;i=i.nextElementSibling)t[o++]=i
;return t},arrayCopy:function(e){for(var t=e.length,o=new Array(t),i=0;i<t;i++)o
[i]=e[i];return o}},Polymer.TreeApi.Logical={hasParentNode:function(e){return Bo
olean(e.__dom&&e.__dom.parentNode)},hasChildNodes:function(e){return Boolean(e._
_dom&&void 0!==e.__dom.childNodes)},getChildNodes:function(e){return this.hasChi
ldNodes(e)?this._getChildNodes(e):e.childNodes},_getChildNodes:function(e){if(!e
.__dom.childNodes){e.__dom.childNodes=[];for(var t=e.__dom.firstChild;t;t=t.__do
m.nextSibling)e.__dom.childNodes.push(t)}return e.__dom.childNodes},getParentNod
e:function(e){return e.__dom&&void 0!==e.__dom.parentNode?e.__dom.parentNode:e.p
arentNode},getFirstChild:function(e){return e.__dom&&void 0!==e.__dom.firstChild
?e.__dom.firstChild:e.firstChild},getLastChild:function(e){return e.__dom&&void
0!==e.__dom.lastChild?e.__dom.lastChild:e.lastChild},getNextSibling:function(e){
return e.__dom&&void 0!==e.__dom.nextSibling?e.__dom.nextSibling:e.nextSibling},
getPreviousSibling:function(e){return e.__dom&&void 0!==e.__dom.previousSibling?
e.__dom.previousSibling:e.previousSibling},getFirstElementChild:function(e){retu
rn e.__dom&&void 0!==e.__dom.firstChild?this._getFirstElementChild(e):e.firstEle
mentChild},_getFirstElementChild:function(e){for(var t=e.__dom.firstChild;t&&t.n
odeType!==Node.ELEMENT_NODE;)t=t.__dom.nextSibling;return t},getLastElementChild
:function(e){return e.__dom&&void 0!==e.__dom.lastChild?this._getLastElementChil
d(e):e.lastElementChild},_getLastElementChild:function(e){for(var t=e.__dom.last
Child;t&&t.nodeType!==Node.ELEMENT_NODE;)t=t.__dom.previousSibling;return t},get
NextElementSibling:function(e){return e.__dom&&void 0!==e.__dom.nextSibling?this
._getNextElementSibling(e):e.nextElementSibling},_getNextElementSibling:function
(e){for(var t=e.__dom.nextSibling;t&&t.nodeType!==Node.ELEMENT_NODE;)t=t.__dom.n
extSibling;return t},getPreviousElementSibling:function(e){return e.__dom&&void
0!==e.__dom.previousSibling?this._getPreviousElementSibling(e):e.previousElement
Sibling},_getPreviousElementSibling:function(e){for(var t=e.__dom.previousSiblin
g;t&&t.nodeType!==Node.ELEMENT_NODE;)t=t.__dom.previousSibling;return t},saveChi
ldNodes:function(e){if(!this.hasChildNodes(e)){e.__dom=e.__dom||{},e.__dom.first
Child=e.firstChild,e.__dom.lastChild=e.lastChild,e.__dom.childNodes=[];for(var t
=e.firstChild;t;t=t.nextSibling)t.__dom=t.__dom||{},t.__dom.parentNode=e,e.__dom
.childNodes.push(t),t.__dom.nextSibling=t.nextSibling,t.__dom.previousSibling=t.
previousSibling}},recordInsertBefore:function(e,t,o){if(t.__dom.childNodes=null,
e.nodeType===Node.DOCUMENT_FRAGMENT_NODE)for(var i=e.firstChild;i;i=i.nextSiblin
g)this._linkNode(i,t,o);else this._linkNode(e,t,o)},_linkNode:function(e,t,o){e.
__dom=e.__dom||{},t.__dom=t.__dom||{},o&&(o.__dom=o.__dom||{}),e.__dom.previousS
ibling=o?o.__dom.previousSibling:t.__dom.lastChild,e.__dom.previousSibling&&(e._
_dom.previousSibling.__dom.nextSibling=e),e.__dom.nextSibling=o||null,e.__dom.ne
xtSibling&&(e.__dom.nextSibling.__dom.previousSibling=e),e.__dom.parentNode=t,o?
o===t.__dom.firstChild&&(t.__dom.firstChild=e):(t.__dom.lastChild=e,t.__dom.firs
tChild||(t.__dom.firstChild=e)),t.__dom.childNodes=null},recordRemoveChild:funct
ion(e,t){e.__dom=e.__dom||{},t.__dom=t.__dom||{},e===t.__dom.firstChild&&(t.__do
m.firstChild=e.__dom.nextSibling),e===t.__dom.lastChild&&(t.__dom.lastChild=e.__
dom.previousSibling);var o=e.__dom.previousSibling,i=e.__dom.nextSibling;o&&(o._
_dom.nextSibling=i),i&&(i.__dom.previousSibling=o),e.__dom.parentNode=e.__dom.pr
eviousSibling=e.__dom.nextSibling=void 0,t.__dom.childNodes=null}},Polymer.TreeA
pi.Composed={getChildNodes:function(e){return Polymer.TreeApi.arrayCopyChildNode
s(e)},getParentNode:function(e){return e.parentNode},clearChildNodes:function(e)
{e.textContent=""},insertBefore:function(t,o,i){return e.call(t,o,i||null)},appe
ndChild:function(e,o){return t.call(e,o)},removeChild:function(e,t){return o.cal
l(e,t)}}}(),Polymer.DomApi=function(){"use strict";var e=Polymer.Settings,t=Poly
mer.TreeApi,o=function(e){this.node=i?o.wrap(e):e},i=e.hasShadow&&!e.nativeShado
w;o.wrap=window.wrap?window.wrap:function(e){return e},o.prototype={flush:functi
on(){Polymer.dom.flush()},deepContains:function(e){if(this.node.contains(e))retu
rn!0;for(var t=e,o=e.ownerDocument;t&&t!==o&&t!==this.node;)t=Polymer.dom(t).par
entNode||t.host;return t===this.node},queryDistributedElements:function(e){for(v
ar t,i=this.getEffectiveChildNodes(),n=[],s=0,r=i.length;s<r&&(t=i[s]);s++)t.nod
eType===Node.ELEMENT_NODE&&o.matchesSelector.call(t,e)&&n.push(t);return n},getE
ffectiveChildNodes:function(){for(var e,t=[],o=this.childNodes,i=0,r=o.length;i<
r&&(e=o[i]);i++)if(e.localName===n)for(var d=s(e).getDistributedNodes(),a=0;a<d.
length;a++)t.push(d[a]);else t.push(e);return t},observeNodes:function(e){if(e)r
eturn this.observer||(this.observer=this.node.localName===n?new o.DistributedNod
esObserver(this):new o.EffectiveNodesObserver(this)),this.observer.addListener(e
)},unobserveNodes:function(e){this.observer&&this.observer.removeListener(e)},no
tifyObserver:function(){this.observer&&this.observer.notify()},_query:function(e
,o,i){o=o||this.node;var n=[];return this._queryElements(t.Logical.getChildNodes
(o),e,i,n),n},_queryElements:function(e,t,o,i){for(var n,s=0,r=e.length;s<r&&(n=
e[s]);s++)if(n.nodeType===Node.ELEMENT_NODE&&this._queryElement(n,t,o,i))return!
0},_queryElement:function(e,o,i,n){var s=o(e);return s&&n.push(e),i&&i(s)?s:void
this._queryElements(t.Logical.getChildNodes(e),o,i,n)}};var n=o.CONTENT="conten
t",s=o.factory=function(e){return e=e||document,e.__domApi||(e.__domApi=new o.ct
or(e)),e.__domApi};o.hasApi=function(e){return Boolean(e.__domApi)},o.ctor=o,Pol
ymer.dom=function(e,t){return e instanceof Event?Polymer.EventApi.factory(e):o.f
actory(e,t)};var r=Element.prototype;return o.matchesSelector=r.matches||r.match
esSelector||r.mozMatchesSelector||r.msMatchesSelector||r.oMatchesSelector||r.web
kitMatchesSelector,o}(),function(){"use strict";var e=Polymer.Settings,t=Polymer
.DomApi,o=t.factory,i=Polymer.TreeApi,n=Polymer.domInnerHTML.getInnerHTML,s=t.CO
NTENT;if(!e.useShadow){var r=Element.prototype.cloneNode,d=Document.prototype.im
portNode;Polymer.Base.extend(t.prototype,{_lazyDistribute:function(e){e.shadyRoo
t&&e.shadyRoot._distributionClean&&(e.shadyRoot._distributionClean=!1,Polymer.do
m.addDebouncer(e.debounce("_distribute",e._distributeContent)))},appendChild:fun
ction(e){return this.insertBefore(e)},insertBefore:function(e,n){if(n&&i.Logical
.getParentNode(n)!==this.node)throw Error("The ref_node to be inserted before is
not a child of this node");if(e.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var r=i
.Logical.getParentNode(e);r?(t.hasApi(r)&&o(r).notifyObserver(),this._removeNode
(e)):this._removeOwnerShadyRoot(e)}if(!this._addNode(e,n)){n&&(n=n.localName===s
?this._firstComposedNode(n):n);var d=this.node._isShadyRoot?this.node.host:this.
node;n?i.Composed.insertBefore(d,e,n):i.Composed.appendChild(d,e)}return this.no
tifyObserver(),e},_addNode:function(e,t){var o=this.getOwnerRoot();if(o){var n=t
his._maybeAddInsertionPoint(e,this.node);o._invalidInsertionPoints||(o._invalidI
nsertionPoints=n),this._addNodeToHost(o.host,e)}i.Logical.hasChildNodes(this.nod
e)&&i.Logical.recordInsertBefore(e,this.node,t);var s=this._maybeDistribute(e)||
this.node.shadyRoot;if(s)if(e.nodeType===Node.DOCUMENT_FRAGMENT_NODE)for(;e.firs
tChild;)i.Composed.removeChild(e,e.firstChild);else{var r=i.Composed.getParentNo
de(e);r&&i.Composed.removeChild(r,e)}return s},removeChild:function(e){if(i.Logi
cal.getParentNode(e)!==this.node)throw Error("The node to be removed is not a ch
ild of this node: "+e);if(!this._removeNode(e)){var t=this.node._isShadyRoot?thi
s.node.host:this.node,o=i.Composed.getParentNode(e);t===o&&i.Composed.removeChil
d(t,e)}return this.notifyObserver(),e},_removeNode:function(e){var t,n=i.Logical
.hasParentNode(e)&&i.Logical.getParentNode(e),s=this._ownerShadyRootForNode(e);r
eturn n&&(t=o(e)._maybeDistributeParent(),i.Logical.recordRemoveChild(e,n),s&&th
is._removeDistributedChildren(s,e)&&(s._invalidInsertionPoints=!0,this._lazyDist
ribute(s.host))),this._removeOwnerShadyRoot(e),s&&this._removeNodeFromHost(s.hos
t,e),t},replaceChild:function(e,t){return this.insertBefore(e,t),this.removeChil
d(t),e},_hasCachedOwnerRoot:function(e){return Boolean(void 0!==e._ownerShadyRoo
t)},getOwnerRoot:function(){return this._ownerShadyRootForNode(this.node)},_owne
rShadyRootForNode:function(e){if(e){var t=e._ownerShadyRoot;if(void 0===t){if(e.
_isShadyRoot)t=e;else{var o=i.Logical.getParentNode(e);t=o?o._isShadyRoot?o:this
._ownerShadyRootForNode(o):null}(t||document.documentElement.contains(e))&&(e._o
wnerShadyRoot=t)}return t}},_maybeDistribute:function(e){var t=e.nodeType===Node
.DOCUMENT_FRAGMENT_NODE&&!e.__noContent&&o(e).querySelector(s),n=t&&i.Logical.ge
tParentNode(t).nodeType!==Node.DOCUMENT_FRAGMENT_NODE,r=t||e.localName===s;if(r)
{var d=this.getOwnerRoot();d&&this._lazyDistribute(d.host)}var a=this._nodeNeeds
Distribution(this.node);return a&&this._lazyDistribute(this.node),a||r&&!n},_may
beAddInsertionPoint:function(e,t){var n;if(e.nodeType!==Node.DOCUMENT_FRAGMENT_N
ODE||e.__noContent)e.localName===s&&(i.Logical.saveChildNodes(t),i.Logical.saveC
hildNodes(e),n=!0);else for(var r,d,a,l=o(e).querySelectorAll(s),h=0;h<l.length&
&(r=l[h]);h++)d=i.Logical.getParentNode(r),d===e&&(d=t),a=this._maybeAddInsertio
nPoint(r,d),n=n||a;return n},_updateInsertionPoints:function(e){for(var t,n=e.sh
adyRoot._insertionPoints=o(e.shadyRoot).querySelectorAll(s),r=0;r<n.length;r++)t
=n[r],i.Logical.saveChildNodes(t),i.Logical.saveChildNodes(i.Logical.getParentNo
de(t))},_nodeNeedsDistribution:function(e){return e&&e.shadyRoot&&t.hasInsertion
Point(e.shadyRoot)},_addNodeToHost:function(e,t){e._elementAdd&&e._elementAdd(t)
},_removeNodeFromHost:function(e,t){e._elementRemove&&e._elementRemove(t)},_remo
veDistributedChildren:function(e,t){for(var n,s=e._insertionPoints,r=0;r<s.lengt
h;r++){var d=s[r];if(this._contains(t,d))for(var a=o(d).getDistributedNodes(),l=
0;l<a.length;l++){n=!0;var h=a[l],u=i.Composed.getParentNode(h);u&&i.Composed.re
moveChild(u,h)}}return n},_contains:function(e,t){for(;t;){if(t==e)return!0;t=i.
Logical.getParentNode(t)}},_removeOwnerShadyRoot:function(e){if(this._hasCachedO
wnerRoot(e))for(var t,o=i.Logical.getChildNodes(e),n=0,s=o.length;n<s&&(t=o[n]);
n++)this._removeOwnerShadyRoot(t);e._ownerShadyRoot=void 0},_firstComposedNode:f
unction(e){for(var t,i,n=o(e).getDistributedNodes(),s=0,r=n.length;s<r&&(t=n[s])
;s++)if(i=o(t).getDestinationInsertionPoints(),i[i.length-1]===e)return t},query
Selector:function(e){var o=this._query(function(o){return t.matchesSelector.call
(o,e)},this.node,function(e){return Boolean(e)})[0];return o||null},querySelecto
rAll:function(e){return this._query(function(o){return t.matchesSelector.call(o,
e)},this.node)},getDestinationInsertionPoints:function(){return this.node._desti
nationInsertionPoints||[]},getDistributedNodes:function(){return this.node._dist
ributedNodes||[]},_clear:function(){for(;this.childNodes.length;)this.removeChil
d(this.childNodes[0])},setAttribute:function(e,t){this.node.setAttribute(e,t),th
is._maybeDistributeParent()},removeAttribute:function(e){this.node.removeAttribu
te(e),this._maybeDistributeParent()},_maybeDistributeParent:function(){if(this._
nodeNeedsDistribution(this.parentNode))return this._lazyDistribute(this.parentNo
de),!0},cloneNode:function(e){var t=r.call(this.node,!1);if(e)for(var i,n=this.c
hildNodes,s=o(t),d=0;d<n.length;d++)i=o(n[d]).cloneNode(!0),s.appendChild(i);ret
urn t},importNode:function(e,t){var n=this.node instanceof Document?this.node:th
is.node.ownerDocument,s=d.call(n,e,!1);if(t)for(var r,a=i.Logical.getChildNodes(
e),l=o(s),h=0;h<a.length;h++)r=o(n).importNode(a[h],!0),l.appendChild(r);return
s},_getComposedInnerHTML:function(){return n(this.node,!0)}}),Object.definePrope
rties(t.prototype,{activeElement:{get:function(){var e=document.activeElement;if
(!e)return null;var t=!!this.node._isShadyRoot;if(this.node!==document){if(!t)re
turn null;if(this.node.host===e||!this.node.host.contains(e))return null}for(var
i=o(e).getOwnerRoot();i&&i!==this.node;)e=i.host,i=o(e).getOwnerRoot();return t
his.node===document?i?null:e:i===this.node?e:null},configurable:!0},childNodes:{
get:function(){var e=i.Logical.getChildNodes(this.node);return Array.isArray(e)?
e:i.arrayCopyChildNodes(this.node)},configurable:!0},children:{get:function(){re
turn i.Logical.hasChildNodes(this.node)?Array.prototype.filter.call(this.childNo
des,function(e){return e.nodeType===Node.ELEMENT_NODE}):i.arrayCopyChildren(this
.node)},configurable:!0},parentNode:{get:function(){return i.Logical.getParentNo
de(this.node)},configurable:!0},firstChild:{get:function(){return i.Logical.getF
irstChild(this.node)},configurable:!0},lastChild:{get:function(){return i.Logica
l.getLastChild(this.node)},configurable:!0},nextSibling:{get:function(){return i
.Logical.getNextSibling(this.node)},configurable:!0},previousSibling:{get:functi
on(){return i.Logical.getPreviousSibling(this.node)},configurable:!0},firstEleme
ntChild:{get:function(){return i.Logical.getFirstElementChild(this.node)},config
urable:!0},lastElementChild:{get:function(){return i.Logical.getLastElementChild
(this.node)},configurable:!0},nextElementSibling:{get:function(){return i.Logica
l.getNextElementSibling(this.node)},configurable:!0},previousElementSibling:{get
:function(){return i.Logical.getPreviousElementSibling(this.node)},configurable:
!0},textContent:{get:function(){var e=this.node.nodeType;if(e===Node.TEXT_NODE||
e===Node.COMMENT_NODE)return this.node.textContent;for(var t,o=[],i=0,n=this.chi
ldNodes;t=n[i];i++)t.nodeType!==Node.COMMENT_NODE&&o.push(t.textContent);return
o.join("")},set:function(e){var t=this.node.nodeType;t===Node.TEXT_NODE||t===Nod
e.COMMENT_NODE?this.node.textContent=e:(this._clear(),e&&this.appendChild(docume
nt.createTextNode(e)))},configurable:!0},innerHTML:{get:function(){var e=this.no
de.nodeType;return e===Node.TEXT_NODE||e===Node.COMMENT_NODE?null:n(this.node)},
set:function(e){var t=this.node.nodeType;if(t!==Node.TEXT_NODE||t!==Node.COMMENT
_NODE){this._clear();var o=document.createElement("div");o.innerHTML=e;for(var n
=i.arrayCopyChildNodes(o),s=0;s<n.length;s++)this.appendChild(n[s])}},configurab
le:!0}}),t.hasInsertionPoint=function(e){return Boolean(e&&e._insertionPoints.le
ngth)}}}(),function(){"use strict";var e=Polymer.Settings,t=Polymer.TreeApi,o=Po
lymer.DomApi;if(e.useShadow){Polymer.Base.extend(o.prototype,{querySelectorAll:f
unction(e){return t.arrayCopy(this.node.querySelectorAll(e))},getOwnerRoot:funct
ion(){for(var e=this.node;e;){if(e.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&e.hos
t)return e;e=e.parentNode}},importNode:function(e,t){var o=this.node instanceof
Document?this.node:this.node.ownerDocument;return o.importNode(e,t)},getDestinat
ionInsertionPoints:function(){var e=this.node.getDestinationInsertionPoints&&thi
s.node.getDestinationInsertionPoints();return e?t.arrayCopy(e):[]},getDistribute
dNodes:function(){var e=this.node.getDistributedNodes&&this.node.getDistributedN
odes();return e?t.arrayCopy(e):[]}}),Object.defineProperties(o.prototype,{active
Element:{get:function(){var e=o.wrap(this.node),t=e.activeElement;return e.conta
ins(t)?t:null},configurable:!0},childNodes:{get:function(){return t.arrayCopyChi
ldNodes(this.node)},configurable:!0},children:{get:function(){return t.arrayCopy
Children(this.node)},configurable:!0},textContent:{get:function(){return this.no
de.textContent},set:function(e){return this.node.textContent=e},configurable:!0}
,innerHTML:{get:function(){return this.node.innerHTML},set:function(e){return th
is.node.innerHTML=e},configurable:!0}});var i=function(e){for(var t=0;t<e.length
;t++)n(e[t])},n=function(e){o.prototype[e]=function(){return this.node[e].apply(
this.node,arguments)}};i(["cloneNode","appendChild","insertBefore","removeChild"
,"replaceChild","setAttribute","removeAttribute","querySelector"]);var s=functio
n(e){for(var t=0;t<e.length;t++)r(e[t])},r=function(e){Object.defineProperty(o.p
rototype,e,{get:function(){return this.node[e]},configurable:!0})};s(["parentNod
e","firstChild","lastChild","nextSibling","previousSibling","firstElementChild",
"lastElementChild","nextElementSibling","previousElementSibling"])}}(),Polymer.B
ase.extend(Polymer.dom,{_flushGuard:0,_FLUSH_MAX:100,_needsTakeRecords:!Polymer.
Settings.useNativeCustomElements,_debouncers:[],_staticFlushList:[],_finishDebou
ncer:null,flush:function(){for(this._flushGuard=0,this._prepareFlush();this._deb
ouncers.length&&this._flushGuard<this._FLUSH_MAX;){for(;this._debouncers.length;
)this._debouncers.shift().complete();this._finishDebouncer&&this._finishDebounce
r.complete(),this._prepareFlush(),this._flushGuard++}this._flushGuard>=this._FLU
SH_MAX&&console.warn("Polymer.dom.flush aborted. Flush may not be complete.")},_
prepareFlush:function(){this._needsTakeRecords&&CustomElements.takeRecords();for
(var e=0;e<this._staticFlushList.length;e++)this._staticFlushList[e]()},addStati
cFlush:function(e){this._staticFlushList.push(e)},removeStaticFlush:function(e){
var t=this._staticFlushList.indexOf(e);t>=0&&this._staticFlushList.splice(t,1)},
addDebouncer:function(e){this._debouncers.push(e),this._finishDebouncer=Polymer.
Debounce(this._finishDebouncer,this._finishFlush)},_finishFlush:function(){Polym
er.dom._debouncers=[]}}),Polymer.EventApi=function(){"use strict";var e=Polymer.
DomApi.ctor,t=Polymer.Settings;e.Event=function(e){this.event=e},t.useShadow?e.E
vent.prototype={get rootTarget(){return this.event.path[0]},get localTarget(){re
turn this.event.target},get path(){var e=this.event.path;return Array.isArray(e)
||(e=Array.prototype.slice.call(e)),e}}:e.Event.prototype={get rootTarget(){retu
rn this.event.target},get localTarget(){for(var e=this.event.currentTarget,t=e&&
Polymer.dom(e).getOwnerRoot(),o=this.path,i=0;i<o.length;i++)if(Polymer.dom(o[i]
).getOwnerRoot()===t)return o[i]},get path(){if(!this.event._path){for(var e=[],
t=this.rootTarget;t;){e.push(t);var o=Polymer.dom(t).getDestinationInsertionPoin
ts();if(o.length){for(var i=0;i<o.length-1;i++)e.push(o[i]);t=o[o.length-1]}else
t=Polymer.dom(t).parentNode||t.host}e.push(window),this.event._path=e}return th
is.event._path}};var o=function(t){return t.__eventApi||(t.__eventApi=new e.Even
t(t)),t.__eventApi};return{factory:o}}(),function(){"use strict";var e=Polymer.D
omApi.ctor,t=Polymer.Settings.useShadow;Object.defineProperty(e.prototype,"class
List",{get:function(){return this._classList||(this._classList=new e.ClassList(t
his)),this._classList},configurable:!0}),e.ClassList=function(e){this.domApi=e,t
his.node=e.node},e.ClassList.prototype={add:function(){this.node.classList.add.a
pply(this.node.classList,arguments),this._distributeParent()},remove:function(){
this.node.classList.remove.apply(this.node.classList,arguments),this._distribute
Parent()},toggle:function(){this.node.classList.toggle.apply(this.node.classList
,arguments),this._distributeParent()},_distributeParent:function(){t||this.domAp
i._maybeDistributeParent()},contains:function(){return this.node.classList.conta
ins.apply(this.node.classList,arguments)}}}(),function(){"use strict";var e=Poly
mer.DomApi.ctor,t=Polymer.Settings;if(e.EffectiveNodesObserver=function(e){this.
domApi=e,this.node=this.domApi.node,this._listeners=[]},e.EffectiveNodesObserver
.prototype={addListener:function(e){this._isSetup||(this._setup(),this._isSetup=
!0);var t={fn:e,_nodes:[]};return this._listeners.push(t),this._scheduleNotify()
,t},removeListener:function(e){var t=this._listeners.indexOf(e);t>=0&&(this._lis
teners.splice(t,1),e._nodes=[]),this._hasListeners()||(this._cleanup(),this._isS
etup=!1)},_setup:function(){this._observeContentElements(this.domApi.childNodes)
},_cleanup:function(){this._unobserveContentElements(this.domApi.childNodes)},_h
asListeners:function(){return Boolean(this._listeners.length)},_scheduleNotify:f
unction(){this._debouncer&&this._debouncer.stop(),this._debouncer=Polymer.Deboun
ce(this._debouncer,this._notify),this._debouncer.context=this,Polymer.dom.addDeb
ouncer(this._debouncer)},notify:function(){this._hasListeners()&&this._scheduleN
otify()},_notify:function(){this._beforeCallListeners(),this._callListeners()},_
beforeCallListeners:function(){this._updateContentElements()},_updateContentElem
ents:function(){this._observeContentElements(this.domApi.childNodes)},_observeCo
ntentElements:function(e){for(var t,o=0;o<e.length&&(t=e[o]);o++)this._isContent
(t)&&(t.__observeNodesMap=t.__observeNodesMap||new WeakMap,t.__observeNodesMap.h
as(this)||t.__observeNodesMap.set(this,this._observeContent(t)))},_observeConten
t:function(e){var t=this,o=Polymer.dom(e).observeNodes(function(){t._scheduleNot
ify()});return o._avoidChangeCalculation=!0,o},_unobserveContentElements:functio
n(e){for(var t,o,i=0;i<e.length&&(t=e[i]);i++)this._isContent(t)&&(o=t.__observe
NodesMap.get(this),o&&(Polymer.dom(t).unobserveNodes(o),t.__observeNodesMap.dele
te(this)))},_isContent:function(e){return"content"===e.localName},_callListeners
:function(){for(var e,t=this._listeners,o=this._getEffectiveNodes(),i=0;i<t.leng
th&&(e=t[i]);i++){var n=this._generateListenerInfo(e,o);(n||e._alwaysNotify)&&th
is._callListener(e,n)}},_getEffectiveNodes:function(){return this.domApi.getEffe
ctiveChildNodes()},_generateListenerInfo:function(e,t){if(e._avoidChangeCalculat
ion)return!0;for(var o,i=e._nodes,n={target:this.node,addedNodes:[],removedNodes
:[]},s=Polymer.ArraySplice.calculateSplices(t,i),r=0;r<s.length&&(o=s[r]);r++)fo
r(var d,a=0;a<o.removed.length&&(d=o.removed[a]);a++)n.removedNodes.push(d);for(
r=0,o;r<s.length&&(o=s[r]);r++)for(a=o.index;a<o.index+o.addedCount;a++)n.addedN
odes.push(t[a]);return e._nodes=t,n.addedNodes.length||n.removedNodes.length?n:v
oid 0},_callListener:function(e,t){return e.fn.call(this.node,t)},enableShadowAt
tributeTracking:function(){}},t.useShadow){var o=e.EffectiveNodesObserver.protot
ype._setup,i=e.EffectiveNodesObserver.prototype._cleanup;Polymer.Base.extend(e.E
ffectiveNodesObserver.prototype,{_setup:function(){if(!this._observer){var e=thi
s;this._mutationHandler=function(t){t&&t.length&&e._scheduleNotify()},this._obse
rver=new MutationObserver(this._mutationHandler),this._boundFlush=function(){e._
flush()},Polymer.dom.addStaticFlush(this._boundFlush),this._observer.observe(thi
s.node,{childList:!0})}o.call(this)},_cleanup:function(){this._observer.disconne
ct(),this._observer=null,this._mutationHandler=null,Polymer.dom.removeStaticFlus
h(this._boundFlush),i.call(this)},_flush:function(){this._observer&&this._mutati
onHandler(this._observer.takeRecords())},enableShadowAttributeTracking:function(
){if(this._observer){this._makeContentListenersAlwaysNotify(),this._observer.dis
connect(),this._observer.observe(this.node,{childList:!0,attributes:!0,subtree:!
0});var e=this.domApi.getOwnerRoot(),t=e&&e.host;t&&Polymer.dom(t).observer&&Pol
ymer.dom(t).observer.enableShadowAttributeTracking()}},_makeContentListenersAlwa
ysNotify:function(){for(var e,t=0;t<this._listeners.length;t++)e=this._listeners
[t],e._alwaysNotify=e._isContentListener}})}}(),function(){"use strict";var e=Po
lymer.DomApi.ctor,t=Polymer.Settings;e.DistributedNodesObserver=function(t){e.Ef
fectiveNodesObserver.call(this,t)},e.DistributedNodesObserver.prototype=Object.c
reate(e.EffectiveNodesObserver.prototype),Polymer.Base.extend(e.DistributedNodes
Observer.prototype,{_setup:function(){},_cleanup:function(){},_beforeCallListene
rs:function(){},_getEffectiveNodes:function(){return this.domApi.getDistributedN
odes()}}),t.useShadow&&Polymer.Base.extend(e.DistributedNodesObserver.prototype,
{_setup:function(){if(!this._observer){var e=this.domApi.getOwnerRoot(),t=e&&e.h
ost;if(t){var o=this;this._observer=Polymer.dom(t).observeNodes(function(){o._sc
heduleNotify()}),this._observer._isContentListener=!0,this._hasAttrSelect()&&Pol
ymer.dom(t).observer.enableShadowAttributeTracking()}}},_hasAttrSelect:function(
){var e=this.node.getAttribute("select");return e&&e.match(/[[.]+/)},_cleanup:fu
nction(){var e=this.domApi.getOwnerRoot(),t=e&&e.host;t&&Polymer.dom(t).unobserv
eNodes(this._observer),this._observer=null}})}(),function(){function e(e,t){t._d
istributedNodes.push(e);var o=e._destinationInsertionPoints;o?o.push(t):e._desti
nationInsertionPoints=[t]}function t(e){var t=e._distributedNodes;if(t)for(var o
=0;o<t.length;o++){var i=t[o]._destinationInsertionPoints;i&&i.splice(i.indexOf(
e)+1,i.length)}}function o(e,t){var o=u.Logical.getParentNode(e);o&&o.shadyRoot&
&h.hasInsertionPoint(o.shadyRoot)&&o.shadyRoot._distributionClean&&(o.shadyRoot.
_distributionClean=!1,t.shadyRoot._dirtyRoots.push(o))}function i(e,t){var o=t._
destinationInsertionPoints;return o&&o[o.length-1]===e}function n(e){return"cont
ent"==e.localName}function s(e){for(;e&&r(e);)e=e.domHost;return e}function r(e)
{for(var t,o=u.Logical.getChildNodes(e),i=0;i<o.length;i++)if(t=o[i],t.localName
&&"content"===t.localName)return e.domHost}function d(e){for(var t,o=0;o<e._inse
rtionPoints.length;o++)t=e._insertionPoints[o],h.hasApi(t)&&Polymer.dom(t).notif
yObserver()}function a(e){h.hasApi(e)&&Polymer.dom(e).notifyObserver()}function
l(e){if(c&&e)for(var t=0;t<e.length;t++)CustomElements.upgrade(e[t])}var h=Polym
er.DomApi,u=Polymer.TreeApi;Polymer.Base._addFeature({_prepShady:function(){this
._useContent=this._useContent||Boolean(this._template)},_setupShady:function(){t
his.shadyRoot=null,this.__domApi||(this.__domApi=null),this.__dom||(this.__dom=n
ull),this._ownerShadyRoot||(this._ownerShadyRoot=void 0)},_poolContent:function(
){this._useContent&&u.Logical.saveChildNodes(this)},_setupRoot:function(){this._
useContent&&(this._createLocalRoot(),this.dataHost||l(u.Logical.getChildNodes(th
is)))},_createLocalRoot:function(){this.shadyRoot=this.root,this.shadyRoot._dist
ributionClean=!1,this.shadyRoot._hasDistributed=!1,this.shadyRoot._isShadyRoot=!
0,this.shadyRoot._dirtyRoots=[];var e=this.shadyRoot._insertionPoints=!this._not
es||this._notes._hasContent?this.shadyRoot.querySelectorAll("content"):[];u.Logi
cal.saveChildNodes(this.shadyRoot);for(var t,o=0;o<e.length;o++)t=e[o],u.Logical
.saveChildNodes(t),u.Logical.saveChildNodes(t.parentNode);this.shadyRoot.host=th
is},get domHost(){var e=Polymer.dom(this).getOwnerRoot();return e&&e.host},distr
ibuteContent:function(e){if(this.shadyRoot){this.shadyRoot._invalidInsertionPoin
ts=this.shadyRoot._invalidInsertionPoints||e;var t=s(this);Polymer.dom(this)._la
zyDistribute(t)}},_distributeContent:function(){this._useContent&&!this.shadyRoo
t._distributionClean&&(this.shadyRoot._invalidInsertionPoints&&(Polymer.dom(this
)._updateInsertionPoints(this),this.shadyRoot._invalidInsertionPoints=!1),this._
beginDistribute(),this._distributeDirtyRoots(),this._finishDistribute())},_begin
Distribute:function(){this._useContent&&h.hasInsertionPoint(this.shadyRoot)&&(th
is._resetDistribution(),this._distributePool(this.shadyRoot,this._collectPool())
); |
| 2 },_distributeDirtyRoots:function(){for(var e,t=this.shadyRoot._dirtyRoots,o=0,i=
t.length;o<i&&(e=t[o]);o++)e._distributeContent();this.shadyRoot._dirtyRoots=[]}
,_finishDistribute:function(){if(this._useContent){if(this.shadyRoot._distributi
onClean=!0,h.hasInsertionPoint(this.shadyRoot))this._composeTree(),d(this.shadyR
oot);else if(this.shadyRoot._hasDistributed){var e=this._composeNode(this);this.
_updateChildNodes(this,e)}else u.Composed.clearChildNodes(this),this.appendChild
(this.shadyRoot);this.shadyRoot._hasDistributed||a(this),this.shadyRoot._hasDist
ributed=!0}},elementMatches:function(e,t){return t=t||this,h.matchesSelector.cal
l(t,e)},_resetDistribution:function(){for(var e=u.Logical.getChildNodes(this),o=
0;o<e.length;o++){var i=e[o];i._destinationInsertionPoints&&(i._destinationInser
tionPoints=void 0),n(i)&&t(i)}for(var s=this.shadyRoot,r=s._insertionPoints,d=0;
d<r.length;d++)r[d]._distributedNodes=[]},_collectPool:function(){for(var e=[],t
=u.Logical.getChildNodes(this),o=0;o<t.length;o++){var i=t[o];n(i)?e.push.apply(
e,i._distributedNodes):e.push(i)}return e},_distributePool:function(e,t){for(var
i,n=e._insertionPoints,s=0,r=n.length;s<r&&(i=n[s]);s++)this._distributeInserti
onPoint(i,t),o(i,this)},_distributeInsertionPoint:function(t,o){for(var i,n=!1,s
=0,r=o.length;s<r;s++)i=o[s],i&&this._matchesContentSelect(i,t)&&(e(i,t),o[s]=vo
id 0,n=!0);if(!n)for(var d=u.Logical.getChildNodes(t),a=0;a<d.length;a++)e(d[a],
t)},_composeTree:function(){this._updateChildNodes(this,this._composeNode(this))
;for(var e,t,o=this.shadyRoot._insertionPoints,i=0,n=o.length;i<n&&(e=o[i]);i++)
t=u.Logical.getParentNode(e),t._useContent||t===this||t===this.shadyRoot||this._
updateChildNodes(t,this._composeNode(t))},_composeNode:function(e){for(var t=[],
o=u.Logical.getChildNodes(e.shadyRoot||e),s=0;s<o.length;s++){var r=o[s];if(n(r)
)for(var d=r._distributedNodes,a=0;a<d.length;a++){var l=d[a];i(r,l)&&t.push(l)}
else t.push(r)}return t},_updateChildNodes:function(e,t){for(var o,i=u.Composed.
getChildNodes(e),n=Polymer.ArraySplice.calculateSplices(t,i),s=0,r=0;s<n.length&
&(o=n[s]);s++){for(var d,a=0;a<o.removed.length&&(d=o.removed[a]);a++)u.Composed
.getParentNode(d)===e&&u.Composed.removeChild(e,d),i.splice(o.index+r,1);r-=o.ad
dedCount}for(var o,l,s=0;s<n.length&&(o=n[s]);s++)for(l=i[o.index],a=o.index,d;a
<o.index+o.addedCount;a++)d=t[a],u.Composed.insertBefore(e,d,l),i.splice(a,0,d)}
,_matchesContentSelect:function(e,t){var o=t.getAttribute("select");if(!o)return
!0;if(o=o.trim(),!o)return!0;if(!(e instanceof Element))return!1;var i=/^(:not\(
)?[*.#[a-zA-Z_|]/;return!!i.test(o)&&this.elementMatches(o,e)},_elementAdd:funct
ion(){},_elementRemove:function(){}});var c=window.CustomElements&&!CustomElemen
ts.useNative}(),Polymer.Settings.useShadow&&Polymer.Base._addFeature({_poolConte
nt:function(){},_beginDistribute:function(){},distributeContent:function(){},_di
stributeContent:function(){},_finishDistribute:function(){},_createLocalRoot:fun
ction(){this.createShadowRoot(),this.shadowRoot.appendChild(this.root),this.root
=this.shadowRoot}}),Polymer.Async={_currVal:0,_lastVal:0,_callbacks:[],_twiddleC
ontent:0,_twiddle:document.createTextNode(""),run:function(e,t){return t>0?~setT
imeout(e,t):(this._twiddle.textContent=this._twiddleContent++,this._callbacks.pu
sh(e),this._currVal++)},cancel:function(e){if(e<0)clearTimeout(~e);else{var t=e-
this._lastVal;if(t>=0){if(!this._callbacks[t])throw"invalid async handle: "+e;th
is._callbacks[t]=null}}},_atEndOfMicrotask:function(){for(var e=this._callbacks.
length,t=0;t<e;t++){var o=this._callbacks[t];if(o)try{o()}catch(e){throw t++,thi
s._callbacks.splice(0,t),this._lastVal+=t,this._twiddle.textContent=this._twiddl
eContent++,e}}this._callbacks.splice(0,e),this._lastVal+=e}},new window.Mutation
Observer(function(){Polymer.Async._atEndOfMicrotask()}).observe(Polymer.Async._t
widdle,{characterData:!0}),Polymer.Debounce=function(){function e(e,t,i){return
e?e.stop():e=new o(this),e.go(t,i),e}var t=Polymer.Async,o=function(e){this.cont
ext=e;var t=this;this.boundComplete=function(){t.complete()}};return o.prototype
={go:function(e,o){var i;this.finish=function(){t.cancel(i)},i=t.run(this.boundC
omplete,o),this.callback=e},stop:function(){this.finish&&(this.finish(),this.fin
ish=null,this.callback=null)},complete:function(){if(this.finish){var e=this.cal
lback;this.stop(),e.call(this.context)}}},e}(),Polymer.Base._addFeature({_setupD
ebouncers:function(){this._debouncers={}},debounce:function(e,t,o){return this._
debouncers[e]=Polymer.Debounce.call(this,this._debouncers[e],t,o)},isDebouncerAc
tive:function(e){var t=this._debouncers[e];return!(!t||!t.finish)},flushDebounce
r:function(e){var t=this._debouncers[e];t&&t.complete()},cancelDebouncer:functio
n(e){var t=this._debouncers[e];t&&t.stop()}}),Polymer.DomModule=document.createE
lement("dom-module"),Polymer.Base._addFeature({_registerFeatures:function(){this
._prepIs(),this._prepBehaviors(),this._prepConstructor(),this._prepTemplate(),th
is._prepShady(),this._prepPropertyInfo()},_prepBehavior:function(e){this._addHos
tAttributes(e.hostAttributes)},_initFeatures:function(){this._registerHost(),thi
s._template&&(this._poolContent(),this._beginHosting(),this._stampTemplate(),thi
s._endHosting()),this._marshalHostAttributes(),this._setupDebouncers(),this._mar
shalBehaviors(),this._tryReady()},_marshalBehavior:function(e){}})</script> <scr
ipt>Polymer.nar=[],Polymer.Annotations={parseAnnotations:function(e){var t=[],n=
e._content||e.content;return this._parseNodeAnnotations(n,t,e.hasAttribute("stri
p-whitespace")),t},_parseNodeAnnotations:function(e,t,n){return e.nodeType===Nod
e.TEXT_NODE?this._parseTextNodeAnnotation(e,t):this._parseElementAnnotations(e,t
,n)},_bindingRegex:function(){var e="(?:[a-zA-Z_$][\\w.:$\\-*]*)",t="(?:[-+]?[0-
9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?)",n="(?:'(?:[^'\\\\]|\\\\.)*')",r='(?:"(?:[^"\
\\\]|\\\\.)*")',s="(?:"+n+"|"+r+")",i="(?:"+e+"|"+t+"|"+s+"\\s*)",o="(?:"+i+"(?:
,\\s*"+i+")*)",a="(?:\\(\\s*(?:"+o+"?)\\)\\s*)",l="("+e+"\\s*"+a+"?)",c="(\\[\\[
|{{)\\s*",h="(?:]]|}})",u="(?:(!)\\s*)?",f=c+u+l+h;return new RegExp(f,"g")}(),_
parseBindings:function(e){for(var t,n=this._bindingRegex,r=[],s=0;null!==(t=n.ex
ec(e));){t.index>s&&r.push({literal:e.slice(s,t.index)});var i,o,a,l=t[1][0],c=B
oolean(t[2]),h=t[3].trim();"{"==l&&(a=h.indexOf("::"))>0&&(o=h.substring(a+2),h=
h.substring(0,a),i=!0),r.push({compoundIndex:r.length,value:h,mode:l,negate:c,ev
ent:o,customEvent:i}),s=n.lastIndex}if(s&&s<e.length){var u=e.substring(s);u&&r.
push({literal:u})}if(r.length)return r},_literalFromParts:function(e){for(var t=
"",n=0;n<e.length;n++){var r=e[n].literal;t+=r||""}return t},_parseTextNodeAnnot
ation:function(e,t){var n=this._parseBindings(e.textContent);if(n){e.textContent
=this._literalFromParts(n)||" ";var r={bindings:[{kind:"text",name:"textContent"
,parts:n,isCompound:1!==n.length}]};return t.push(r),r}},_parseElementAnnotation
s:function(e,t,n){var r={bindings:[],events:[]};return"content"===e.localName&&(
t._hasContent=!0),this._parseChildNodesAnnotations(e,r,t,n),e.attributes&&(this.
_parseNodeAttributeAnnotations(e,r,t),this.prepElement&&this.prepElement(e)),(r.
bindings.length||r.events.length||r.id)&&t.push(r),r},_parseChildNodesAnnotation
s:function(e,t,n,r){if(e.firstChild)for(var s=e.firstChild,i=0;s;){var o=s.nextS
ibling;if("template"!==s.localName||s.hasAttribute("preserve-content")||this._pa
rseTemplate(s,i,n,t),"slot"==s.localName&&(s=this._replaceSlotWithContent(s)),s.
nodeType===Node.TEXT_NODE){for(var a=o;a&&a.nodeType===Node.TEXT_NODE;)s.textCon
tent+=a.textContent,o=a.nextSibling,e.removeChild(a),a=o;r&&!s.textContent.trim(
)&&(e.removeChild(s),i--)}if(s.parentNode){var l=this._parseNodeAnnotations(s,n,
r);l&&(l.parent=t,l.index=i)}s=o,i++}},_replaceSlotWithContent:function(e){for(v
ar t=e.ownerDocument.createElement("content");e.firstChild;)t.appendChild(e.firs
tChild);for(var n=e.attributes,r=0;r<n.length;r++){var s=n[r];t.setAttribute(s.n
ame,s.value)}var i=e.getAttribute("name"),o=i?"[slot='"+i+"']":":not([slot])";re
turn t.setAttribute("select",o),e.parentNode.replaceChild(t,e),t},_parseTemplate
:function(e,t,n,r){var s=document.createDocumentFragment();s._notes=this.parseAn
notations(e),s.appendChild(e.content),n.push({bindings:Polymer.nar,events:Polyme
r.nar,templateContent:s,parent:r,index:t})},_parseNodeAttributeAnnotations:funct
ion(e,t){for(var n,r=Array.prototype.slice.call(e.attributes),s=r.length-1;n=r[s
];s--){var i,o=n.name,a=n.value;"on-"===o.slice(0,3)?(e.removeAttribute(o),t.eve
nts.push({name:o.slice(3),value:a})):(i=this._parseNodeAttributeAnnotation(e,o,a
))?t.bindings.push(i):"id"===o&&(t.id=a)}},_parseNodeAttributeAnnotation:functio
n(e,t,n){var r=this._parseBindings(n);if(r){var s=t,i="property";"$"==t[t.length
-1]&&(t=t.slice(0,-1),i="attribute");var o=this._literalFromParts(r);o&&"attribu
te"==i&&e.setAttribute(t,o),"input"===e.localName&&"value"===s&&e.setAttribute(s
,""),e.removeAttribute(s);var a=Polymer.CaseMap.dashToCamelCase(t);return"proper
ty"===i&&(t=a),{kind:i,name:t,propertyName:a,parts:r,literal:o,isCompound:1!==r.
length}}},findAnnotatedNode:function(e,t){var n=t.parent&&Polymer.Annotations.fi
ndAnnotatedNode(e,t.parent);if(!n)return e;for(var r=n.firstChild,s=0;r;r=r.next
Sibling)if(t.index===s++)return r}},function(){function e(e,t){return e.replace(
a,function(e,r,s,i){return r+"'"+n(s.replace(/["']/g,""),t)+"'"+i})}function t(t
,r){for(var s in l)for(var i,o,a,c=l[s],u=0,f=c.length;u<f&&(i=c[u]);u++)"*"!==s
&&t.localName!==s||(o=t.attributes[i],a=o&&o.value,a&&a.search(h)<0&&(o.value="s
tyle"===i?e(a,r):n(a,r)))}function n(e,t){if(e&&c.test(e))return e;var n=s(t);re
turn n.href=e,n.href||e}function r(e,t){return i||(i=document.implementation.cre
ateHTMLDocument("temp"),o=i.createElement("base"),i.head.appendChild(o)),o.href=
t,n(e,i)}function s(e){return e.__urlResolver||(e.__urlResolver=e.createElement(
"a"))}var i,o,a=/(url\()([^)]*)(\))/g,l={"*":["href","src","style","url"],form:[
"action"]},c=/(^\/)|(^#)|(^[\w-\d]*:)/,h=/\{\{|\[\[/;Polymer.ResolveUrl={resolve
Css:e,resolveAttrs:t,resolveUrl:r}}(),Polymer.Path={root:function(e){var t=e.ind
exOf(".");return t===-1?e:e.slice(0,t)},isDeep:function(e){return e.indexOf(".")
!==-1},isAncestor:function(e,t){return 0===e.indexOf(t+".")},isDescendant:functi
on(e,t){return 0===t.indexOf(e+".")},translate:function(e,t,n){return t+n.slice(
e.length)},matches:function(e,t,n){return e===n||this.isAncestor(e,n)||Boolean(t
)&&this.isDescendant(e,n)}},Polymer.Base._addFeature({_prepAnnotations:function(
){if(this._template){var e=this;Polymer.Annotations.prepElement=function(t){e._p
repElement(t)},this._template._content&&this._template._content._notes?this._not
es=this._template._content._notes:(this._notes=Polymer.Annotations.parseAnnotati
ons(this._template),this._processAnnotations(this._notes)),Polymer.Annotations.p
repElement=null}else this._notes=[]},_processAnnotations:function(e){for(var t=0
;t<e.length;t++){for(var n=e[t],r=0;r<n.bindings.length;r++)for(var s=n.bindings
[r],i=0;i<s.parts.length;i++){var o=s.parts[i];if(!o.literal){var a=this._parseM
ethod(o.value);a?o.signature=a:o.model=Polymer.Path.root(o.value)}}if(n.template
Content){this._processAnnotations(n.templateContent._notes);var l=n.templateCont
ent._parentProps=this._discoverTemplateParentProps(n.templateContent._notes),c=[
];for(var h in l){var u="_parent_"+h;c.push({index:n.index,kind:"property",name:
u,propertyName:u,parts:[{mode:"{",model:h,value:h}]})}n.bindings=n.bindings.conc
at(c)}}},_discoverTemplateParentProps:function(e){for(var t,n={},r=0;r<e.length&
&(t=e[r]);r++){for(var s,i=0,o=t.bindings;i<o.length&&(s=o[i]);i++)for(var a,l=0
,c=s.parts;l<c.length&&(a=c[l]);l++)if(a.signature){for(var h=a.signature.args,u
=0;u<h.length;u++){var f=h[u].model;f&&(n[f]=!0)}a.signature.dynamicFn&&(n[a.sig
nature.method]=!0)}else a.model&&(n[a.model]=!0);if(t.templateContent){var p=t.t
emplateContent._parentProps;Polymer.Base.mixin(n,p)}}return n},_prepElement:func
tion(e){Polymer.ResolveUrl.resolveAttrs(e,this._template.ownerDocument)},_findAn
notatedNode:Polymer.Annotations.findAnnotatedNode,_marshalAnnotationReferences:f
unction(){this._template&&(this._marshalIdNodes(),this._marshalAnnotatedNodes(),
this._marshalAnnotatedListeners())},_configureAnnotationReferences:function(){fo
r(var e=this._notes,t=this._nodes,n=0;n<e.length;n++){var r=e[n],s=t[n];this._co
nfigureTemplateContent(r,s),this._configureCompoundBindings(r,s)}},_configureTem
plateContent:function(e,t){e.templateContent&&(t._content=e.templateContent)},_c
onfigureCompoundBindings:function(e,t){for(var n=e.bindings,r=0;r<n.length;r++){
var s=n[r];if(s.isCompound){for(var i=t.__compoundStorage__||(t.__compoundStorag
e__={}),o=s.parts,a=new Array(o.length),l=0;l<o.length;l++)a[l]=o[l].literal;var
c=s.name;i[c]=a,s.literal&&"property"==s.kind&&(t._configValue?t._configValue(c
,s.literal):t[c]=s.literal)}}},_marshalIdNodes:function(){this.$={};for(var e,t=
0,n=this._notes.length;t<n&&(e=this._notes[t]);t++)e.id&&(this.$[e.id]=this._fin
dAnnotatedNode(this.root,e))},_marshalAnnotatedNodes:function(){if(this._notes&&
this._notes.length){for(var e=new Array(this._notes.length),t=0;t<this._notes.le
ngth;t++)e[t]=this._findAnnotatedNode(this.root,this._notes[t]);this._nodes=e}},
_marshalAnnotatedListeners:function(){for(var e,t=0,n=this._notes.length;t<n&&(e
=this._notes[t]);t++)if(e.events&&e.events.length)for(var r,s=this._findAnnotate
dNode(this.root,e),i=0,o=e.events;i<o.length&&(r=o[i]);i++)this.listen(s,r.name,
r.value)}}),Polymer.Base._addFeature({listeners:{},_listenListeners:function(e){
var t,n,r;for(r in e)r.indexOf(".")<0?(t=this,n=r):(n=r.split("."),t=this.$[n[0]
],n=n[1]),this.listen(t,n,e[r])},listen:function(e,t,n){var r=this._recallEventH
andler(this,t,e,n);r||(r=this._createEventHandler(e,t,n)),r._listening||(this._l
isten(e,t,r),r._listening=!0)},_boundListenerKey:function(e,t){return e+":"+t},_
recordEventHandler:function(e,t,n,r,s){var i=e.__boundListeners;i||(i=e.__boundL
isteners=new WeakMap);var o=i.get(n);o||(o={},i.set(n,o));var a=this._boundListe
nerKey(t,r);o[a]=s},_recallEventHandler:function(e,t,n,r){var s=e.__boundListene
rs;if(s){var i=s.get(n);if(i){var o=this._boundListenerKey(t,r);return i[o]}}},_
createEventHandler:function(e,t,n){var r=this,s=function(e){r[n]?r[n](e,e.detail
):r._warn(r._logf("_createEventHandler","listener method `"+n+"` not defined"))}
;return s._listening=!1,this._recordEventHandler(r,t,e,n,s),s},unlisten:function
(e,t,n){var r=this._recallEventHandler(this,t,e,n);r&&(this._unlisten(e,t,r),r._
listening=!1)},_listen:function(e,t,n){e.addEventListener(t,n)},_unlisten:functi
on(e,t,n){e.removeEventListener(t,n)}}),function(){"use strict";function e(e){fo
r(var t,n=g?["click"]:m,r=0;r<n.length;r++)t=n[r],e?document.addEventListener(t,
P,!0):document.removeEventListener(t,P,!0)}function t(){S.mouse.mouseIgnoreJob||
e(!0);var t=function(){e(),S.mouse.target=null,S.mouse.mouseIgnoreJob=null};S.mo
use.mouseIgnoreJob=Polymer.Debounce(S.mouse.mouseIgnoreJob,t,d)}function n(e){va
r t=e.type;if(m.indexOf(t)===-1)return!1;if("mousemove"===t){var n=void 0===e.bu
ttons?1:e.buttons;return e instanceof window.MouseEvent&&!v&&(n=y[e.which]||0),B
oolean(1&n)}var r=void 0===e.button?0:e.button;return 0===r}function r(e){if("cl
ick"===e.type){if(0===e.detail)return!0;var t=C.findOriginalTarget(e),n=t.getBou
ndingClientRect(),r=e.pageX,s=e.pageY;return!(r>=n.left&&r<=n.right&&s>=n.top&&s
<=n.bottom)}return!1}function s(e){for(var t,n=Polymer.dom(e).path,r="auto",s=0;
s<n.length;s++)if(t=n[s],t[u]){r=t[u];break}return r}function i(e,t,n){e.movefn=
t,e.upfn=n,document.addEventListener("mousemove",t),document.addEventListener("m
ouseup",n)}function o(e){document.removeEventListener("mousemove",e.movefn),docu
ment.removeEventListener("mouseup",e.upfn),e.movefn=null,e.upfn=null}var a=Polym
er.DomApi.wrap,l="string"==typeof document.head.style.touchAction,c="__polymerGe
stures",h="__polymerGesturesHandled",u="__polymerGesturesTouchAction",f=25,p=5,_
=2,d=2500,m=["mousedown","mousemove","mouseup","click"],y=[0,1,4,2],v=function()
{try{return 1===new MouseEvent("test",{buttons:1}).buttons}catch(e){return!1}}()
,g=navigator.userAgent.match(/iP(?:[oa]d|hone)|Android/),P=function(e){var t=e.s
ourceCapabilities;if((!t||t.firesTouchEvents)&&(e[h]={skip:!0},"click"===e.type)
){for(var n=Polymer.dom(e).path,r=0;r<n.length;r++)if(n[r]===S.mouse.target)retu
rn;e.preventDefault(),e.stopPropagation()}},S={mouse:{target:null,mouseIgnoreJob
:null},touch:{x:0,y:0,id:-1,scrollDecided:!1}},C={gestures:{},recognizers:[],dee
pTargetFind:function(e,t){for(var n=document.elementFromPoint(e,t),r=n;r&&r.shad
owRoot;)r=r.shadowRoot.elementFromPoint(e,t),r&&(n=r);return n},findOriginalTarg
et:function(e){return e.path?e.path[0]:e.target},handleNative:function(e){var n,
r=e.type,s=a(e.currentTarget),i=s[c];if(i){var o=i[r];if(o){if(!e[h]&&(e[h]={},"
touch"===r.slice(0,5))){var u=e.changedTouches[0];if("touchstart"===r&&1===e.tou
ches.length&&(S.touch.id=u.identifier),S.touch.id!==u.identifier)return;l||"touc
hstart"!==r&&"touchmove"!==r||C.handleTouchAction(e),"touchend"===r&&(S.mouse.ta
rget=Polymer.dom(e).rootTarget,t())}if(n=e[h],!n.skip){for(var f,p=C.recognizers
,_=0;_<p.length;_++)f=p[_],o[f.name]&&!n[f.name]&&f.flow&&f.flow.start.indexOf(e
.type)>-1&&f.reset&&f.reset();for(_=0,f;_<p.length;_++)f=p[_],o[f.name]&&!n[f.na
me]&&(n[f.name]=!0,f[r](e))}}}},handleTouchAction:function(e){var t=e.changedTou
ches[0],n=e.type;if("touchstart"===n)S.touch.x=t.clientX,S.touch.y=t.clientY,S.t
ouch.scrollDecided=!1;else if("touchmove"===n){if(S.touch.scrollDecided)return;S
.touch.scrollDecided=!0;var r=s(e),i=!1,o=Math.abs(S.touch.x-t.clientX),a=Math.a
bs(S.touch.y-t.clientY);e.cancelable&&("none"===r?i=!0:"pan-x"===r?i=a>o:"pan-y"
===r&&(i=o>a)),i?e.preventDefault():C.prevent("track")}},add:function(e,t,n){e=a
(e);var r=this.gestures[t],s=r.deps,i=r.name,o=e[c];o||(e[c]=o={});for(var l,h,u
=0;u<s.length;u++)l=s[u],g&&m.indexOf(l)>-1&&"click"!==l||(h=o[l],h||(o[l]=h={_c
ount:0}),0===h._count&&e.addEventListener(l,this.handleNative),h[i]=(h[i]||0)+1,
h._count=(h._count||0)+1);e.addEventListener(t,n),r.touchAction&&this.setTouchAc
tion(e,r.touchAction)},remove:function(e,t,n){e=a(e);var r=this.gestures[t],s=r.
deps,i=r.name,o=e[c];if(o)for(var l,h,u=0;u<s.length;u++)l=s[u],h=o[l],h&&h[i]&&
(h[i]=(h[i]||1)-1,h._count=(h._count||1)-1,0===h._count&&e.removeEventListener(l
,this.handleNative));e.removeEventListener(t,n)},register:function(e){this.recog
nizers.push(e);for(var t=0;t<e.emits.length;t++)this.gestures[e.emits[t]]=e},fin
dRecognizerByEvent:function(e){for(var t,n=0;n<this.recognizers.length;n++){t=th
is.recognizers[n];for(var r,s=0;s<t.emits.length;s++)if(r=t.emits[s],r===e)retur
n t}return null},setTouchAction:function(e,t){l&&(e.style.touchAction=t),e[u]=t}
,fire:function(e,t,n){var r=Polymer.Base.fire(t,n,{node:e,bubbles:!0,cancelable:
!0});if(r.defaultPrevented){var s=n.preventer||n.sourceEvent;s&&s.preventDefault
&&s.preventDefault()}},prevent:function(e){var t=this.findRecognizerByEvent(e);t
.info&&(t.info.prevent=!0)},resetMouseCanceller:function(){S.mouse.mouseIgnoreJo
b&&S.mouse.mouseIgnoreJob.complete()}};C.register({name:"downup",deps:["mousedow
n","touchstart","touchend"],flow:{start:["mousedown","touchstart"],end:["mouseup
","touchend"]},emits:["down","up"],info:{movefn:null,upfn:null},reset:function()
{o(this.info)},mousedown:function(e){if(n(e)){var t=C.findOriginalTarget(e),r=th
is,s=function(e){n(e)||(r.fire("up",t,e),o(r.info))},a=function(e){n(e)&&r.fire(
"up",t,e),o(r.info)};i(this.info,s,a),this.fire("down",t,e)}},touchstart:functio
n(e){this.fire("down",C.findOriginalTarget(e),e.changedTouches[0],e)},touchend:f
unction(e){this.fire("up",C.findOriginalTarget(e),e.changedTouches[0],e)},fire:f
unction(e,t,n,r){C.fire(t,e,{x:n.clientX,y:n.clientY,sourceEvent:n,preventer:r,p
revent:function(e){return C.prevent(e)}})}}),C.register({name:"track",touchActio
n:"none",deps:["mousedown","touchstart","touchmove","touchend"],flow:{start:["mo
usedown","touchstart"],end:["mouseup","touchend"]},emits:["track"],info:{x:0,y:0
,state:"start",started:!1,moves:[],addMove:function(e){this.moves.length>_&&this
.moves.shift(),this.moves.push(e)},movefn:null,upfn:null,prevent:!1},reset:funct
ion(){this.info.state="start",this.info.started=!1,this.info.moves=[],this.info.
x=0,this.info.y=0,this.info.prevent=!1,o(this.info)},hasMovedEnough:function(e,t
){if(this.info.prevent)return!1;if(this.info.started)return!0;var n=Math.abs(thi
s.info.x-e),r=Math.abs(this.info.y-t);return n>=p||r>=p},mousedown:function(e){i
f(n(e)){var t=C.findOriginalTarget(e),r=this,s=function(e){var s=e.clientX,i=e.c
lientY;r.hasMovedEnough(s,i)&&(r.info.state=r.info.started?"mouseup"===e.type?"e
nd":"track":"start","start"===r.info.state&&C.prevent("tap"),r.info.addMove({x:s
,y:i}),n(e)||(r.info.state="end",o(r.info)),r.fire(t,e),r.info.started=!0)},a=fu
nction(e){r.info.started&&s(e),o(r.info)};i(this.info,s,a),this.info.x=e.clientX
,this.info.y=e.clientY}},touchstart:function(e){var t=e.changedTouches[0];this.i
nfo.x=t.clientX,this.info.y=t.clientY},touchmove:function(e){var t=C.findOrigina
lTarget(e),n=e.changedTouches[0],r=n.clientX,s=n.clientY;this.hasMovedEnough(r,s
)&&("start"===this.info.state&&C.prevent("tap"),this.info.addMove({x:r,y:s}),thi
s.fire(t,n),this.info.state="track",this.info.started=!0)},touchend:function(e){
var t=C.findOriginalTarget(e),n=e.changedTouches[0];this.info.started&&(this.inf
o.state="end",this.info.addMove({x:n.clientX,y:n.clientY}),this.fire(t,n,e))},fi
re:function(e,t,n){var r,s=this.info.moves[this.info.moves.length-2],i=this.info
.moves[this.info.moves.length-1],o=i.x-this.info.x,a=i.y-this.info.y,l=0;return
s&&(r=i.x-s.x,l=i.y-s.y),C.fire(e,"track",{state:this.info.state,x:t.clientX,y:t
.clientY,dx:o,dy:a,ddx:r,ddy:l,sourceEvent:t,preventer:n,hover:function(){return
C.deepTargetFind(t.clientX,t.clientY)}})}}),C.register({name:"tap",deps:["mouse
down","click","touchstart","touchend"],flow:{start:["mousedown","touchstart"],en
d:["click","touchend"]},emits:["tap"],info:{x:NaN,y:NaN,prevent:!1},reset:functi
on(){this.info.x=NaN,this.info.y=NaN,this.info.prevent=!1},save:function(e){this
.info.x=e.clientX,this.info.y=e.clientY},mousedown:function(e){n(e)&&this.save(e
)},click:function(e){n(e)&&this.forward(e)},touchstart:function(e){this.save(e.c
hangedTouches[0],e)},touchend:function(e){this.forward(e.changedTouches[0],e)},f
orward:function(e,t){var n=Math.abs(e.clientX-this.info.x),s=Math.abs(e.clientY-
this.info.y),i=C.findOriginalTarget(e);(isNaN(n)||isNaN(s)||n<=f&&s<=f||r(e))&&(
this.info.prevent||C.fire(i,"tap",{x:e.clientX,y:e.clientY,sourceEvent:e,prevent
er:t}))}});var E={x:"pan-x",y:"pan-y",none:"none",all:"auto"};Polymer.Base._addF
eature({_setupGestures:function(){this.__polymerGestures=null},_listen:function(
e,t,n){C.gestures[t]?C.add(e,t,n):e.addEventListener(t,n)},_unlisten:function(e,
t,n){C.gestures[t]?C.remove(e,t,n):e.removeEventListener(t,n)},setScrollDirectio
n:function(e,t){t=t||this,C.setTouchAction(t,E[e]||"auto")}}),Polymer.Gestures=C
}(),function(){"use strict";if(Polymer.Base._addFeature({$$:function(e){return P
olymer.dom(this.root).querySelector(e)},toggleClass:function(e,t,n){n=n||this,1=
=arguments.length&&(t=!n.classList.contains(e)),t?Polymer.dom(n).classList.add(e
):Polymer.dom(n).classList.remove(e)},toggleAttribute:function(e,t,n){n=n||this,
1==arguments.length&&(t=!n.hasAttribute(e)),t?Polymer.dom(n).setAttribute(e,""):
Polymer.dom(n).removeAttribute(e)},classFollows:function(e,t,n){n&&Polymer.dom(n
).classList.remove(e),t&&Polymer.dom(t).classList.add(e)},attributeFollows:funct
ion(e,t,n){n&&Polymer.dom(n).removeAttribute(e),t&&Polymer.dom(t).setAttribute(e
,"")},getEffectiveChildNodes:function(){return Polymer.dom(this).getEffectiveChi
ldNodes()},getEffectiveChildren:function(){var e=Polymer.dom(this).getEffectiveC
hildNodes();return e.filter(function(e){return e.nodeType===Node.ELEMENT_NODE})}
,getEffectiveTextContent:function(){for(var e,t=this.getEffectiveChildNodes(),n=
[],r=0;e=t[r];r++)e.nodeType!==Node.COMMENT_NODE&&n.push(Polymer.dom(e).textCont
ent);return n.join("")},queryEffectiveChildren:function(e){var t=Polymer.dom(thi
s).queryDistributedElements(e);return t&&t[0]},queryAllEffectiveChildren:functio
n(e){return Polymer.dom(this).queryDistributedElements(e)},getContentChildNodes:
function(e){var t=Polymer.dom(this.root).querySelector(e||"content");return t?Po
lymer.dom(t).getDistributedNodes():[]},getContentChildren:function(e){return thi
s.getContentChildNodes(e).filter(function(e){return e.nodeType===Node.ELEMENT_NO
DE})},fire:function(e,t,n){n=n||Polymer.nob;var r=n.node||this;t=null===t||void
0===t?{}:t;var s=void 0===n.bubbles||n.bubbles,i=Boolean(n.cancelable),o=n._useC
ache,a=this._getEvent(e,s,i,o);return a.detail=t,o&&(this.__eventCache[e]=null),
r.dispatchEvent(a),o&&(this.__eventCache[e]=a),a},__eventCache:{},_getEvent:func
tion(e,t,n,r){var s=r&&this.__eventCache[e];return s&&s.bubbles==t&&s.cancelable
==n||(s=new Event(e,{bubbles:Boolean(t),cancelable:n})),s},async:function(e,t){v
ar n=this;return Polymer.Async.run(function(){e.call(n)},t)},cancelAsync:functio
n(e){Polymer.Async.cancel(e)},arrayDelete:function(e,t){var n;if(Array.isArray(e
)){if(n=e.indexOf(t),n>=0)return e.splice(n,1)}else{var r=this._get(e);if(n=r.in
dexOf(t),n>=0)return this.splice(e,n,1)}},transform:function(e,t){t=t||this,t.st
yle.webkitTransform=e,t.style.transform=e},translate3d:function(e,t,n,r){r=r||th
is,this.transform("translate3d("+e+","+t+","+n+")",r)},importHref:function(e,t,n
,r){var s=document.createElement("link");s.rel="import",s.href=e;var i=Polymer.B
ase.importHref.imported=Polymer.Base.importHref.imported||{},o=i[s.href],a=o||s,
l=this;if(t){var c=function(e){return e.target.__firedLoad=!0,e.target.removeEve
ntListener("load",c),t.call(l,e)};a.addEventListener("load",c)}if(n){var h=funct
ion(e){return e.target.__firedError=!0,e.target.removeEventListener("error",h),n
.call(l,e)};a.addEventListener("error",h)}return o?(o.__firedLoad&&o.dispatchEve
nt(new Event("load")),o.__firedError&&o.dispatchEvent(new Event("error"))):(i[s.
href]=s,r=Boolean(r),r&&s.setAttribute("async",""),document.head.appendChild(s))
,a},create:function(e,t){var n=document.createElement(e);if(t)for(var r in t)n[r
]=t[r];return n},isLightDescendant:function(e){return this!==e&&this.contains(e)
&&Polymer.dom(this).getOwnerRoot()===Polymer.dom(e).getOwnerRoot()},isLocalDesce
ndant:function(e){return this.root===Polymer.dom(e).getOwnerRoot()}}),!Polymer.S
ettings.useNativeCustomElements){var e=Polymer.Base.importHref;Polymer.Base.impo
rtHref=function(t,n,r,s){CustomElements.ready=!1;var i=function(e){if(CustomElem
ents.upgradeDocumentTree(document),CustomElements.ready=!0,n)return n.call(this,
e)};return e.call(this,t,i,r,s)}}}(),Polymer.Bind={prepareModel:function(e){Poly
mer.Base.mixin(e,this._modelApi)},_modelApi:{_notifyChange:function(e,t,n){n=voi
d 0===n?this[e]:n,t=t||Polymer.CaseMap.camelToDashCase(e)+"-changed",this.fire(t
,{value:n},{bubbles:!1,cancelable:!1,_useCache:!0})},_propertySetter:function(e,
t,n,r){var s=this.__data__[e];return s===t||s!==s&&t!==t||(this.__data__[e]=t,"o
bject"==typeof t&&this._clearPath(e),this._propertyChanged&&this._propertyChange
d(e,t,s),n&&this._effectEffects(e,t,n,s,r)),s},__setProperty:function(e,t,n,r){r
=r||this;var s=r._propertyEffects&&r._propertyEffects[e];s?r._propertySetter(e,t
,s,n):r[e]!==t&&(r[e]=t)},_effectEffects:function(e,t,n,r,s){for(var i,o=0,a=n.l
ength;o<a&&(i=n[o]);o++)i.fn.call(this,e,this[e],i.effect,r,s)},_clearPath:funct
ion(e){for(var t in this.__data__)Polymer.Path.isDescendant(e,t)&&(this.__data__
[t]=void 0)}},ensurePropertyEffects:function(e,t){e._propertyEffects||(e._proper
tyEffects={});var n=e._propertyEffects[t];return n||(n=e._propertyEffects[t]=[])
,n},addPropertyEffect:function(e,t,n,r){var s=this.ensurePropertyEffects(e,t),i=
{kind:n,effect:r,fn:Polymer.Bind["_"+n+"Effect"]};return s.push(i),i},createBind
ings:function(e){var t=e._propertyEffects;if(t)for(var n in t){var r=t[n];r.sort
(this._sortPropertyEffects),this._createAccessors(e,n,r)}},_sortPropertyEffects:
function(){var e={compute:0,annotation:1,annotatedComputation:2,reflect:3,notify
:4,observer:5,complexObserver:6,function:7};return function(t,n){return e[t.kind
]-e[n.kind]}}(),_createAccessors:function(e,t,n){var r={get:function(){return th
is.__data__[t]}},s=function(e){this._propertySetter(t,e,n)},i=e.getPropertyInfo&
&e.getPropertyInfo(t);i&&i.readOnly?i.computed||(e["_set"+this.upper(t)]=s):r.se
t=s,Object.defineProperty(e,t,r)},upper:function(e){return e[0].toUpperCase()+e.
substring(1)},_addAnnotatedListener:function(e,t,n,r,s,i){e._bindListeners||(e._
bindListeners=[]);var o=this._notedListenerFactory(n,r,Polymer.Path.isDeep(r),i)
,a=s||Polymer.CaseMap.camelToDashCase(n)+"-changed";e._bindListeners.push({index
:t,property:n,path:r,changedFn:o,event:a})},_isEventBogus:function(e,t){return e
.path&&e.path[0]!==t},_notedListenerFactory:function(e,t,n,r){return function(s,
i,o){if(o){var a=Polymer.Path.translate(e,t,o);this._notifyPath(a,i)}else i=s[e]
,r&&(i=!i),n?this.__data__[t]!=i&&this.set(t,i):this[t]=i}},prepareInstance:func
tion(e){e.__data__=Object.create(null)},setupBindListeners:function(e){for(var t
,n=e._bindListeners,r=0,s=n.length;r<s&&(t=n[r]);r++){var i=e._nodes[t.index];th
is._addNotifyListener(i,e,t.event,t.changedFn)}},_addNotifyListener:function(e,t
,n,r){e.addEventListener(n,function(e){return t._notifyListener(r,e)})}},Polymer
.Base.extend(Polymer.Bind,{_shouldAddListener:function(e){return e.name&&"attrib
ute"!=e.kind&&"text"!=e.kind&&!e.isCompound&&"{"===e.parts[0].mode},_annotationE
ffect:function(e,t,n){e!=n.value&&(t=this._get(n.value),this.__data__[n.value]=t
),this._applyEffectValue(n,t)},_reflectEffect:function(e,t,n){this.reflectProper
tyToAttribute(e,n.attribute,t)},_notifyEffect:function(e,t,n,r,s){s||this._notif
yChange(e,n.event,t)},_functionEffect:function(e,t,n,r,s){n.call(this,e,t,r,s)},
_observerEffect:function(e,t,n,r){var s=this[n.method];s?s.call(this,t,r):this._
warn(this._logf("_observerEffect","observer method `"+n.method+"` not defined"))
},_complexObserverEffect:function(e,t,n){var r=this[n.method];if(r){var s=Polyme
r.Bind._marshalArgs(this.__data__,n,e,t);s&&r.apply(this,s)}else n.dynamicFn||th
is._warn(this._logf("_complexObserverEffect","observer method `"+n.method+"` not
defined"))},_computeEffect:function(e,t,n){var r=this[n.method];if(r){var s=Pol
ymer.Bind._marshalArgs(this.__data__,n,e,t);if(s){var i=r.apply(this,s);this.__s
etProperty(n.name,i)}}else n.dynamicFn||this._warn(this._logf("_computeEffect","
compute method `"+n.method+"` not defined"))},_annotatedComputationEffect:functi
on(e,t,n){var r=this._rootDataHost||this,s=r[n.method];if(s){var i=Polymer.Bind.
_marshalArgs(this.__data__,n,e,t);if(i){var o=s.apply(r,i);this._applyEffectValu
e(n,o)}}else n.dynamicFn||r._warn(r._logf("_annotatedComputationEffect","compute
method `"+n.method+"` not defined"))},_marshalArgs:function(e,t,n,r){for(var s=
[],i=t.args,o=i.length>1||t.dynamicFn,a=0,l=i.length;a<l;a++){var c,h=i[a],u=h.n
ame;if(h.literal?c=h.value:n===u?c=r:(c=e[u],void 0===c&&h.structured&&(c=Polyme
r.Base._get(u,e))),o&&void 0===c)return;if(h.wildcard){var f=Polymer.Path.isAnce
stor(n,u);s[a]={path:f?n:u,value:f?r:c,base:c}}else s[a]=c}return s}}),Polymer.B
ase._addFeature({_addPropertyEffect:function(e,t,n){var r=Polymer.Bind.addProper
tyEffect(this,e,t,n);r.pathFn=this["_"+r.kind+"PathEffect"]},_prepEffects:functi
on(){Polymer.Bind.prepareModel(this),this._addAnnotationEffects(this._notes)},_p
repBindings:function(){Polymer.Bind.createBindings(this)},_addPropertyEffects:fu
nction(e){if(e)for(var t in e){var n=e[t];if(n.observer&&this._addObserverEffect
(t,n.observer),n.computed&&(n.readOnly=!0,this._addComputedEffect(t,n.computed))
,n.notify&&this._addPropertyEffect(t,"notify",{event:Polymer.CaseMap.camelToDash
Case(t)+"-changed"}),n.reflectToAttribute){var r=Polymer.CaseMap.camelToDashCase
(t);"-"===r[0]?this._warn(this._logf("_addPropertyEffects","Property "+t+" canno
t be reflected to attribute "+r+' because "-" is not a valid starting attribute
name. Use a lowercase first letter for the property instead.')):this._addPropert
yEffect(t,"reflect",{attribute:r})}n.readOnly&&Polymer.Bind.ensurePropertyEffect
s(this,t)}},_addComputedEffect:function(e,t){for(var n,r=this._parseMethod(t),s=
r.dynamicFn,i=0;i<r.args.length&&(n=r.args[i]);i++)this._addPropertyEffect(n.mod
el,"compute",{method:r.method,args:r.args,trigger:n,name:e,dynamicFn:s});s&&this
._addPropertyEffect(r.method,"compute",{method:r.method,args:r.args,trigger:null
,name:e,dynamicFn:s})},_addObserverEffect:function(e,t){this._addPropertyEffect(
e,"observer",{method:t,property:e})},_addComplexObserverEffects:function(e){if(e
)for(var t,n=0;n<e.length&&(t=e[n]);n++)this._addComplexObserverEffect(t)},_addC
omplexObserverEffect:function(e){var t=this._parseMethod(e);if(!t)throw new Erro
r("Malformed observer expression '"+e+"'");for(var n,r=t.dynamicFn,s=0;s<t.args.
length&&(n=t.args[s]);s++)this._addPropertyEffect(n.model,"complexObserver",{met
hod:t.method,args:t.args,trigger:n,dynamicFn:r});r&&this._addPropertyEffect(t.me
thod,"complexObserver",{method:t.method,args:t.args,trigger:null,dynamicFn:r})},
_addAnnotationEffects:function(e){for(var t,n=0;n<e.length&&(t=e[n]);n++)for(var
r,s=t.bindings,i=0;i<s.length&&(r=s[i]);i++)this._addAnnotationEffect(r,n)},_ad
dAnnotationEffect:function(e,t){Polymer.Bind._shouldAddListener(e)&&Polymer.Bind
._addAnnotatedListener(this,t,e.name,e.parts[0].value,e.parts[0].event,e.parts[0
].negate);for(var n=0;n<e.parts.length;n++){var r=e.parts[n];r.signature?this._a
ddAnnotatedComputationEffect(e,r,t):r.literal||("attribute"===e.kind&&"-"===e.na
me[0]?this._warn(this._logf("_addAnnotationEffect","Cannot set attribute "+e.nam
e+' because "-" is not a valid attribute starting character')):this._addProperty
Effect(r.model,"annotation",{kind:e.kind,index:t,name:e.name,propertyName:e.prop
ertyName,value:r.value,isCompound:e.isCompound,compoundIndex:r.compoundIndex,eve
nt:r.event,customEvent:r.customEvent,negate:r.negate}))}},_addAnnotatedComputati
onEffect:function(e,t,n){var r=t.signature;if(r.static)this.__addAnnotatedComput
ationEffect("__static__",n,e,t,null);else{for(var s,i=0;i<r.args.length&&(s=r.ar
gs[i]);i++)s.literal||this.__addAnnotatedComputationEffect(s.model,n,e,t,s);r.dy
namicFn&&this.__addAnnotatedComputationEffect(r.method,n,e,t,null)}},__addAnnota
tedComputationEffect:function(e,t,n,r,s){this._addPropertyEffect(e,"annotatedCom
putation",{index:t,isCompound:n.isCompound,compoundIndex:r.compoundIndex,kind:n.
kind,name:n.name,negate:r.negate,method:r.signature.method,args:r.signature.args
,trigger:s,dynamicFn:r.signature.dynamicFn})},_parseMethod:function(e){var t=e.m
atch(/([^\s]+?)\(([\s\S]*)\)/);if(t){var n={method:t[1],static:!0};if(this.getPr
opertyInfo(n.method)!==Polymer.nob&&(n.static=!1,n.dynamicFn=!0),t[2].trim()){va
r r=t[2].replace(/\\,/g,",").split(",");return this._parseArgs(r,n)}return
n.args=Polymer.nar,n}},_parseArgs:function(e,t){return t.args=e.map(function(e)
{var n=this._parseArg(e);return n.literal||(t.static=!1),n},this),t},_parseArg:f
unction(e){var t=e.trim().replace(/,/g,",").replace(/\\(.)/g,"$1"),n={name
:t},r=t[0];switch("-"===r&&(r=t[1]),r>="0"&&r<="9"&&(r="#"),r){case"'":case'"':n
.value=t.slice(1,-1),n.literal=!0;break;case"#":n.value=Number(t),n.literal=!0}r
eturn n.literal||(n.model=Polymer.Path.root(t),n.structured=Polymer.Path.isDeep(
t),n.structured&&(n.wildcard=".*"==t.slice(-2),n.wildcard&&(n.name=t.slice(0,-2)
))),n},_marshalInstanceEffects:function(){Polymer.Bind.prepareInstance(this),thi
s._bindListeners&&Polymer.Bind.setupBindListeners(this)},_applyEffectValue:funct
ion(e,t){var n=this._nodes[e.index],r=e.name;if(t=this._computeFinalAnnotationVa
lue(n,r,t,e),"attribute"==e.kind)this.serializeValueToAttribute(t,r,n);else{var
s=n._propertyInfo&&n._propertyInfo[r];if(s&&s.readOnly)return;this.__setProperty
(r,t,!1,n)}},_computeFinalAnnotationValue:function(e,t,n,r){if(r.negate&&(n=!n),
r.isCompound){var s=e.__compoundStorage__[t];s[r.compoundIndex]=n,n=s.join("")}r
eturn"attribute"!==r.kind&&("className"===t&&(n=this._scopeElementClass(e,n)),("
textContent"===t||"input"==e.localName&&"value"==t)&&(n=void 0==n?"":n)),n},_exe
cuteStaticEffects:function(){this._propertyEffects&&this._propertyEffects.__stat
ic__&&this._effectEffects("__static__",null,this._propertyEffects.__static__)}})
,function(){var e=Polymer.Settings.usePolyfillProto;Polymer.Base._addFeature({_s
etupConfigure:function(e){if(this._config={},this._handlers=[],this._aboveConfig
=null,e)for(var t in e)void 0!==e[t]&&(this._config[t]=e[t])},_marshalAttributes
:function(){this._takeAttributesToModel(this._config)},_attributeChangedImpl:fun
ction(e){var t=this._clientsReadied?this:this._config;this._setAttributeToProper
ty(t,e)},_configValue:function(e,t){var n=this._propertyInfo[e];n&&n.readOnly||(
this._config[e]=t)},_beforeClientsReady:function(){this._configure()},_configure
:function(){this._configureAnnotationReferences(),this._configureInstancePropert
ies(),this._aboveConfig=this.mixin({},this._config);for(var e={},t=0;t<this.beha
viors.length;t++)this._configureProperties(this.behaviors[t].properties,e);this.
_configureProperties(this.properties,e),this.mixin(e,this._aboveConfig),this._co
nfig=e,this._clients&&this._clients.length&&this._distributeConfig(this._config)
},_configureInstanceProperties:function(){for(var t in this._propertyEffects)!e&
&this.hasOwnProperty(t)&&(this._configValue(t,this[t]), | 2 },_distributeDirtyRoots:function(){for(var e,t=this.shadyRoot._dirtyRoots,o=0,i=
t.length;o<i&&(e=t[o]);o++)e._distributeContent();this.shadyRoot._dirtyRoots=[]}
,_finishDistribute:function(){if(this._useContent){if(this.shadyRoot._distributi
onClean=!0,h.hasInsertionPoint(this.shadyRoot))this._composeTree(),d(this.shadyR
oot);else if(this.shadyRoot._hasDistributed){var e=this._composeNode(this);this.
_updateChildNodes(this,e)}else u.Composed.clearChildNodes(this),this.appendChild
(this.shadyRoot);this.shadyRoot._hasDistributed||a(this),this.shadyRoot._hasDist
ributed=!0}},elementMatches:function(e,t){return t=t||this,h.matchesSelector.cal
l(t,e)},_resetDistribution:function(){for(var e=u.Logical.getChildNodes(this),o=
0;o<e.length;o++){var i=e[o];i._destinationInsertionPoints&&(i._destinationInser
tionPoints=void 0),n(i)&&t(i)}for(var s=this.shadyRoot,r=s._insertionPoints,d=0;
d<r.length;d++)r[d]._distributedNodes=[]},_collectPool:function(){for(var e=[],t
=u.Logical.getChildNodes(this),o=0;o<t.length;o++){var i=t[o];n(i)?e.push.apply(
e,i._distributedNodes):e.push(i)}return e},_distributePool:function(e,t){for(var
i,n=e._insertionPoints,s=0,r=n.length;s<r&&(i=n[s]);s++)this._distributeInserti
onPoint(i,t),o(i,this)},_distributeInsertionPoint:function(t,o){for(var i,n=!1,s
=0,r=o.length;s<r;s++)i=o[s],i&&this._matchesContentSelect(i,t)&&(e(i,t),o[s]=vo
id 0,n=!0);if(!n)for(var d=u.Logical.getChildNodes(t),a=0;a<d.length;a++)e(d[a],
t)},_composeTree:function(){this._updateChildNodes(this,this._composeNode(this))
;for(var e,t,o=this.shadyRoot._insertionPoints,i=0,n=o.length;i<n&&(e=o[i]);i++)
t=u.Logical.getParentNode(e),t._useContent||t===this||t===this.shadyRoot||this._
updateChildNodes(t,this._composeNode(t))},_composeNode:function(e){for(var t=[],
o=u.Logical.getChildNodes(e.shadyRoot||e),s=0;s<o.length;s++){var r=o[s];if(n(r)
)for(var d=r._distributedNodes,a=0;a<d.length;a++){var l=d[a];i(r,l)&&t.push(l)}
else t.push(r)}return t},_updateChildNodes:function(e,t){for(var o,i=u.Composed.
getChildNodes(e),n=Polymer.ArraySplice.calculateSplices(t,i),s=0,r=0;s<n.length&
&(o=n[s]);s++){for(var d,a=0;a<o.removed.length&&(d=o.removed[a]);a++)u.Composed
.getParentNode(d)===e&&u.Composed.removeChild(e,d),i.splice(o.index+r,1);r-=o.ad
dedCount}for(var o,l,s=0;s<n.length&&(o=n[s]);s++)for(l=i[o.index],a=o.index,d;a
<o.index+o.addedCount;a++)d=t[a],u.Composed.insertBefore(e,d,l),i.splice(a,0,d)}
,_matchesContentSelect:function(e,t){var o=t.getAttribute("select");if(!o)return
!0;if(o=o.trim(),!o)return!0;if(!(e instanceof Element))return!1;var i=/^(:not\(
)?[*.#[a-zA-Z_|]/;return!!i.test(o)&&this.elementMatches(o,e)},_elementAdd:funct
ion(){},_elementRemove:function(){}});var c=window.CustomElements&&!CustomElemen
ts.useNative}(),Polymer.Settings.useShadow&&Polymer.Base._addFeature({_poolConte
nt:function(){},_beginDistribute:function(){},distributeContent:function(){},_di
stributeContent:function(){},_finishDistribute:function(){},_createLocalRoot:fun
ction(){this.createShadowRoot(),this.shadowRoot.appendChild(this.root),this.root
=this.shadowRoot}}),Polymer.Async={_currVal:0,_lastVal:0,_callbacks:[],_twiddleC
ontent:0,_twiddle:document.createTextNode(""),run:function(e,t){return t>0?~setT
imeout(e,t):(this._twiddle.textContent=this._twiddleContent++,this._callbacks.pu
sh(e),this._currVal++)},cancel:function(e){if(e<0)clearTimeout(~e);else{var t=e-
this._lastVal;if(t>=0){if(!this._callbacks[t])throw"invalid async handle: "+e;th
is._callbacks[t]=null}}},_atEndOfMicrotask:function(){for(var e=this._callbacks.
length,t=0;t<e;t++){var o=this._callbacks[t];if(o)try{o()}catch(e){throw t++,thi
s._callbacks.splice(0,t),this._lastVal+=t,this._twiddle.textContent=this._twiddl
eContent++,e}}this._callbacks.splice(0,e),this._lastVal+=e}},new window.Mutation
Observer(function(){Polymer.Async._atEndOfMicrotask()}).observe(Polymer.Async._t
widdle,{characterData:!0}),Polymer.Debounce=function(){function e(e,t,i){return
e?e.stop():e=new o(this),e.go(t,i),e}var t=Polymer.Async,o=function(e){this.cont
ext=e;var t=this;this.boundComplete=function(){t.complete()}};return o.prototype
={go:function(e,o){var i;this.finish=function(){t.cancel(i)},i=t.run(this.boundC
omplete,o),this.callback=e},stop:function(){this.finish&&(this.finish(),this.fin
ish=null,this.callback=null)},complete:function(){if(this.finish){var e=this.cal
lback;this.stop(),e.call(this.context)}}},e}(),Polymer.Base._addFeature({_setupD
ebouncers:function(){this._debouncers={}},debounce:function(e,t,o){return this._
debouncers[e]=Polymer.Debounce.call(this,this._debouncers[e],t,o)},isDebouncerAc
tive:function(e){var t=this._debouncers[e];return!(!t||!t.finish)},flushDebounce
r:function(e){var t=this._debouncers[e];t&&t.complete()},cancelDebouncer:functio
n(e){var t=this._debouncers[e];t&&t.stop()}}),Polymer.DomModule=document.createE
lement("dom-module"),Polymer.Base._addFeature({_registerFeatures:function(){this
._prepIs(),this._prepBehaviors(),this._prepConstructor(),this._prepTemplate(),th
is._prepShady(),this._prepPropertyInfo()},_prepBehavior:function(e){this._addHos
tAttributes(e.hostAttributes)},_initFeatures:function(){this._registerHost(),thi
s._template&&(this._poolContent(),this._beginHosting(),this._stampTemplate(),thi
s._endHosting()),this._marshalHostAttributes(),this._setupDebouncers(),this._mar
shalBehaviors(),this._tryReady()},_marshalBehavior:function(e){}})</script> <scr
ipt>Polymer.nar=[],Polymer.Annotations={parseAnnotations:function(e){var t=[],n=
e._content||e.content;return this._parseNodeAnnotations(n,t,e.hasAttribute("stri
p-whitespace")),t},_parseNodeAnnotations:function(e,t,n){return e.nodeType===Nod
e.TEXT_NODE?this._parseTextNodeAnnotation(e,t):this._parseElementAnnotations(e,t
,n)},_bindingRegex:function(){var e="(?:[a-zA-Z_$][\\w.:$\\-*]*)",t="(?:[-+]?[0-
9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?)",n="(?:'(?:[^'\\\\]|\\\\.)*')",r='(?:"(?:[^"\
\\\]|\\\\.)*")',s="(?:"+n+"|"+r+")",i="(?:"+e+"|"+t+"|"+s+"\\s*)",o="(?:"+i+"(?:
,\\s*"+i+")*)",a="(?:\\(\\s*(?:"+o+"?)\\)\\s*)",l="("+e+"\\s*"+a+"?)",c="(\\[\\[
|{{)\\s*",h="(?:]]|}})",u="(?:(!)\\s*)?",f=c+u+l+h;return new RegExp(f,"g")}(),_
parseBindings:function(e){for(var t,n=this._bindingRegex,r=[],s=0;null!==(t=n.ex
ec(e));){t.index>s&&r.push({literal:e.slice(s,t.index)});var i,o,a,l=t[1][0],c=B
oolean(t[2]),h=t[3].trim();"{"==l&&(a=h.indexOf("::"))>0&&(o=h.substring(a+2),h=
h.substring(0,a),i=!0),r.push({compoundIndex:r.length,value:h,mode:l,negate:c,ev
ent:o,customEvent:i}),s=n.lastIndex}if(s&&s<e.length){var u=e.substring(s);u&&r.
push({literal:u})}if(r.length)return r},_literalFromParts:function(e){for(var t=
"",n=0;n<e.length;n++){var r=e[n].literal;t+=r||""}return t},_parseTextNodeAnnot
ation:function(e,t){var n=this._parseBindings(e.textContent);if(n){e.textContent
=this._literalFromParts(n)||" ";var r={bindings:[{kind:"text",name:"textContent"
,parts:n,isCompound:1!==n.length}]};return t.push(r),r}},_parseElementAnnotation
s:function(e,t,n){var r={bindings:[],events:[]};return"content"===e.localName&&(
t._hasContent=!0),this._parseChildNodesAnnotations(e,r,t,n),e.attributes&&(this.
_parseNodeAttributeAnnotations(e,r,t),this.prepElement&&this.prepElement(e)),(r.
bindings.length||r.events.length||r.id)&&t.push(r),r},_parseChildNodesAnnotation
s:function(e,t,n,r){if(e.firstChild)for(var s=e.firstChild,i=0;s;){var o=s.nextS
ibling;if("template"!==s.localName||s.hasAttribute("preserve-content")||this._pa
rseTemplate(s,i,n,t),"slot"==s.localName&&(s=this._replaceSlotWithContent(s)),s.
nodeType===Node.TEXT_NODE){for(var a=o;a&&a.nodeType===Node.TEXT_NODE;)s.textCon
tent+=a.textContent,o=a.nextSibling,e.removeChild(a),a=o;r&&!s.textContent.trim(
)&&(e.removeChild(s),i--)}if(s.parentNode){var l=this._parseNodeAnnotations(s,n,
r);l&&(l.parent=t,l.index=i)}s=o,i++}},_replaceSlotWithContent:function(e){for(v
ar t=e.ownerDocument.createElement("content");e.firstChild;)t.appendChild(e.firs
tChild);for(var n=e.attributes,r=0;r<n.length;r++){var s=n[r];t.setAttribute(s.n
ame,s.value)}var i=e.getAttribute("name"),o=i?"[slot='"+i+"']":":not([slot])";re
turn t.setAttribute("select",o),e.parentNode.replaceChild(t,e),t},_parseTemplate
:function(e,t,n,r){var s=document.createDocumentFragment();s._notes=this.parseAn
notations(e),s.appendChild(e.content),n.push({bindings:Polymer.nar,events:Polyme
r.nar,templateContent:s,parent:r,index:t})},_parseNodeAttributeAnnotations:funct
ion(e,t){for(var n,r=Array.prototype.slice.call(e.attributes),s=r.length-1;n=r[s
];s--){var i,o=n.name,a=n.value;"on-"===o.slice(0,3)?(e.removeAttribute(o),t.eve
nts.push({name:o.slice(3),value:a})):(i=this._parseNodeAttributeAnnotation(e,o,a
))?t.bindings.push(i):"id"===o&&(t.id=a)}},_parseNodeAttributeAnnotation:functio
n(e,t,n){var r=this._parseBindings(n);if(r){var s=t,i="property";"$"==t[t.length
-1]&&(t=t.slice(0,-1),i="attribute");var o=this._literalFromParts(r);o&&"attribu
te"==i&&e.setAttribute(t,o),"input"===e.localName&&"value"===s&&e.setAttribute(s
,""),e.removeAttribute(s);var a=Polymer.CaseMap.dashToCamelCase(t);return"proper
ty"===i&&(t=a),{kind:i,name:t,propertyName:a,parts:r,literal:o,isCompound:1!==r.
length}}},findAnnotatedNode:function(e,t){var n=t.parent&&Polymer.Annotations.fi
ndAnnotatedNode(e,t.parent);if(!n)return e;for(var r=n.firstChild,s=0;r;r=r.next
Sibling)if(t.index===s++)return r}},function(){function e(e,t){return e.replace(
a,function(e,r,s,i){return r+"'"+n(s.replace(/["']/g,""),t)+"'"+i})}function t(t
,r){for(var s in l)for(var i,o,a,c=l[s],u=0,f=c.length;u<f&&(i=c[u]);u++)"*"!==s
&&t.localName!==s||(o=t.attributes[i],a=o&&o.value,a&&a.search(h)<0&&(o.value="s
tyle"===i?e(a,r):n(a,r)))}function n(e,t){if(e&&c.test(e))return e;var n=s(t);re
turn n.href=e,n.href||e}function r(e,t){return i||(i=document.implementation.cre
ateHTMLDocument("temp"),o=i.createElement("base"),i.head.appendChild(o)),o.href=
t,n(e,i)}function s(e){return e.__urlResolver||(e.__urlResolver=e.createElement(
"a"))}var i,o,a=/(url\()([^)]*)(\))/g,l={"*":["href","src","style","url"],form:[
"action"]},c=/(^\/)|(^#)|(^[\w-\d]*:)/,h=/\{\{|\[\[/;Polymer.ResolveUrl={resolve
Css:e,resolveAttrs:t,resolveUrl:r}}(),Polymer.Path={root:function(e){var t=e.ind
exOf(".");return t===-1?e:e.slice(0,t)},isDeep:function(e){return e.indexOf(".")
!==-1},isAncestor:function(e,t){return 0===e.indexOf(t+".")},isDescendant:functi
on(e,t){return 0===t.indexOf(e+".")},translate:function(e,t,n){return t+n.slice(
e.length)},matches:function(e,t,n){return e===n||this.isAncestor(e,n)||Boolean(t
)&&this.isDescendant(e,n)}},Polymer.Base._addFeature({_prepAnnotations:function(
){if(this._template){var e=this;Polymer.Annotations.prepElement=function(t){e._p
repElement(t)},this._template._content&&this._template._content._notes?this._not
es=this._template._content._notes:(this._notes=Polymer.Annotations.parseAnnotati
ons(this._template),this._processAnnotations(this._notes)),Polymer.Annotations.p
repElement=null}else this._notes=[]},_processAnnotations:function(e){for(var t=0
;t<e.length;t++){for(var n=e[t],r=0;r<n.bindings.length;r++)for(var s=n.bindings
[r],i=0;i<s.parts.length;i++){var o=s.parts[i];if(!o.literal){var a=this._parseM
ethod(o.value);a?o.signature=a:o.model=Polymer.Path.root(o.value)}}if(n.template
Content){this._processAnnotations(n.templateContent._notes);var l=n.templateCont
ent._parentProps=this._discoverTemplateParentProps(n.templateContent._notes),c=[
];for(var h in l){var u="_parent_"+h;c.push({index:n.index,kind:"property",name:
u,propertyName:u,parts:[{mode:"{",model:h,value:h}]})}n.bindings=n.bindings.conc
at(c)}}},_discoverTemplateParentProps:function(e){for(var t,n={},r=0;r<e.length&
&(t=e[r]);r++){for(var s,i=0,o=t.bindings;i<o.length&&(s=o[i]);i++)for(var a,l=0
,c=s.parts;l<c.length&&(a=c[l]);l++)if(a.signature){for(var h=a.signature.args,u
=0;u<h.length;u++){var f=h[u].model;f&&(n[f]=!0)}a.signature.dynamicFn&&(n[a.sig
nature.method]=!0)}else a.model&&(n[a.model]=!0);if(t.templateContent){var p=t.t
emplateContent._parentProps;Polymer.Base.mixin(n,p)}}return n},_prepElement:func
tion(e){Polymer.ResolveUrl.resolveAttrs(e,this._template.ownerDocument)},_findAn
notatedNode:Polymer.Annotations.findAnnotatedNode,_marshalAnnotationReferences:f
unction(){this._template&&(this._marshalIdNodes(),this._marshalAnnotatedNodes(),
this._marshalAnnotatedListeners())},_configureAnnotationReferences:function(){fo
r(var e=this._notes,t=this._nodes,n=0;n<e.length;n++){var r=e[n],s=t[n];this._co
nfigureTemplateContent(r,s),this._configureCompoundBindings(r,s)}},_configureTem
plateContent:function(e,t){e.templateContent&&(t._content=e.templateContent)},_c
onfigureCompoundBindings:function(e,t){for(var n=e.bindings,r=0;r<n.length;r++){
var s=n[r];if(s.isCompound){for(var i=t.__compoundStorage__||(t.__compoundStorag
e__={}),o=s.parts,a=new Array(o.length),l=0;l<o.length;l++)a[l]=o[l].literal;var
c=s.name;i[c]=a,s.literal&&"property"==s.kind&&(t._configValue?t._configValue(c
,s.literal):t[c]=s.literal)}}},_marshalIdNodes:function(){this.$={};for(var e,t=
0,n=this._notes.length;t<n&&(e=this._notes[t]);t++)e.id&&(this.$[e.id]=this._fin
dAnnotatedNode(this.root,e))},_marshalAnnotatedNodes:function(){if(this._notes&&
this._notes.length){for(var e=new Array(this._notes.length),t=0;t<this._notes.le
ngth;t++)e[t]=this._findAnnotatedNode(this.root,this._notes[t]);this._nodes=e}},
_marshalAnnotatedListeners:function(){for(var e,t=0,n=this._notes.length;t<n&&(e
=this._notes[t]);t++)if(e.events&&e.events.length)for(var r,s=this._findAnnotate
dNode(this.root,e),i=0,o=e.events;i<o.length&&(r=o[i]);i++)this.listen(s,r.name,
r.value)}}),Polymer.Base._addFeature({listeners:{},_listenListeners:function(e){
var t,n,r;for(r in e)r.indexOf(".")<0?(t=this,n=r):(n=r.split("."),t=this.$[n[0]
],n=n[1]),this.listen(t,n,e[r])},listen:function(e,t,n){var r=this._recallEventH
andler(this,t,e,n);r||(r=this._createEventHandler(e,t,n)),r._listening||(this._l
isten(e,t,r),r._listening=!0)},_boundListenerKey:function(e,t){return e+":"+t},_
recordEventHandler:function(e,t,n,r,s){var i=e.__boundListeners;i||(i=e.__boundL
isteners=new WeakMap);var o=i.get(n);o||(o={},i.set(n,o));var a=this._boundListe
nerKey(t,r);o[a]=s},_recallEventHandler:function(e,t,n,r){var s=e.__boundListene
rs;if(s){var i=s.get(n);if(i){var o=this._boundListenerKey(t,r);return i[o]}}},_
createEventHandler:function(e,t,n){var r=this,s=function(e){r[n]?r[n](e,e.detail
):r._warn(r._logf("_createEventHandler","listener method `"+n+"` not defined"))}
;return s._listening=!1,this._recordEventHandler(r,t,e,n,s),s},unlisten:function
(e,t,n){var r=this._recallEventHandler(this,t,e,n);r&&(this._unlisten(e,t,r),r._
listening=!1)},_listen:function(e,t,n){e.addEventListener(t,n)},_unlisten:functi
on(e,t,n){e.removeEventListener(t,n)}}),function(){"use strict";function e(e){fo
r(var t,n=g?["click"]:m,r=0;r<n.length;r++)t=n[r],e?document.addEventListener(t,
P,!0):document.removeEventListener(t,P,!0)}function t(){S.mouse.mouseIgnoreJob||
e(!0);var t=function(){e(),S.mouse.target=null,S.mouse.mouseIgnoreJob=null};S.mo
use.mouseIgnoreJob=Polymer.Debounce(S.mouse.mouseIgnoreJob,t,d)}function n(e){va
r t=e.type;if(m.indexOf(t)===-1)return!1;if("mousemove"===t){var n=void 0===e.bu
ttons?1:e.buttons;return e instanceof window.MouseEvent&&!v&&(n=y[e.which]||0),B
oolean(1&n)}var r=void 0===e.button?0:e.button;return 0===r}function r(e){if("cl
ick"===e.type){if(0===e.detail)return!0;var t=C.findOriginalTarget(e),n=t.getBou
ndingClientRect(),r=e.pageX,s=e.pageY;return!(r>=n.left&&r<=n.right&&s>=n.top&&s
<=n.bottom)}return!1}function s(e){for(var t,n=Polymer.dom(e).path,r="auto",s=0;
s<n.length;s++)if(t=n[s],t[u]){r=t[u];break}return r}function i(e,t,n){e.movefn=
t,e.upfn=n,document.addEventListener("mousemove",t),document.addEventListener("m
ouseup",n)}function o(e){document.removeEventListener("mousemove",e.movefn),docu
ment.removeEventListener("mouseup",e.upfn),e.movefn=null,e.upfn=null}var a=Polym
er.DomApi.wrap,l="string"==typeof document.head.style.touchAction,c="__polymerGe
stures",h="__polymerGesturesHandled",u="__polymerGesturesTouchAction",f=25,p=5,_
=2,d=2500,m=["mousedown","mousemove","mouseup","click"],y=[0,1,4,2],v=function()
{try{return 1===new MouseEvent("test",{buttons:1}).buttons}catch(e){return!1}}()
,g=navigator.userAgent.match(/iP(?:[oa]d|hone)|Android/),P=function(e){var t=e.s
ourceCapabilities;if((!t||t.firesTouchEvents)&&(e[h]={skip:!0},"click"===e.type)
){for(var n=Polymer.dom(e).path,r=0;r<n.length;r++)if(n[r]===S.mouse.target)retu
rn;e.preventDefault(),e.stopPropagation()}},S={mouse:{target:null,mouseIgnoreJob
:null},touch:{x:0,y:0,id:-1,scrollDecided:!1}},C={gestures:{},recognizers:[],dee
pTargetFind:function(e,t){for(var n=document.elementFromPoint(e,t),r=n;r&&r.shad
owRoot;)r=r.shadowRoot.elementFromPoint(e,t),r&&(n=r);return n},findOriginalTarg
et:function(e){return e.path?e.path[0]:e.target},handleNative:function(e){var n,
r=e.type,s=a(e.currentTarget),i=s[c];if(i){var o=i[r];if(o){if(!e[h]&&(e[h]={},"
touch"===r.slice(0,5))){var u=e.changedTouches[0];if("touchstart"===r&&1===e.tou
ches.length&&(S.touch.id=u.identifier),S.touch.id!==u.identifier)return;l||"touc
hstart"!==r&&"touchmove"!==r||C.handleTouchAction(e),"touchend"===r&&(S.mouse.ta
rget=Polymer.dom(e).rootTarget,t())}if(n=e[h],!n.skip){for(var f,p=C.recognizers
,_=0;_<p.length;_++)f=p[_],o[f.name]&&!n[f.name]&&f.flow&&f.flow.start.indexOf(e
.type)>-1&&f.reset&&f.reset();for(_=0,f;_<p.length;_++)f=p[_],o[f.name]&&!n[f.na
me]&&(n[f.name]=!0,f[r](e))}}}},handleTouchAction:function(e){var t=e.changedTou
ches[0],n=e.type;if("touchstart"===n)S.touch.x=t.clientX,S.touch.y=t.clientY,S.t
ouch.scrollDecided=!1;else if("touchmove"===n){if(S.touch.scrollDecided)return;S
.touch.scrollDecided=!0;var r=s(e),i=!1,o=Math.abs(S.touch.x-t.clientX),a=Math.a
bs(S.touch.y-t.clientY);e.cancelable&&("none"===r?i=!0:"pan-x"===r?i=a>o:"pan-y"
===r&&(i=o>a)),i?e.preventDefault():C.prevent("track")}},add:function(e,t,n){e=a
(e);var r=this.gestures[t],s=r.deps,i=r.name,o=e[c];o||(e[c]=o={});for(var l,h,u
=0;u<s.length;u++)l=s[u],g&&m.indexOf(l)>-1&&"click"!==l||(h=o[l],h||(o[l]=h={_c
ount:0}),0===h._count&&e.addEventListener(l,this.handleNative),h[i]=(h[i]||0)+1,
h._count=(h._count||0)+1);e.addEventListener(t,n),r.touchAction&&this.setTouchAc
tion(e,r.touchAction)},remove:function(e,t,n){e=a(e);var r=this.gestures[t],s=r.
deps,i=r.name,o=e[c];if(o)for(var l,h,u=0;u<s.length;u++)l=s[u],h=o[l],h&&h[i]&&
(h[i]=(h[i]||1)-1,h._count=(h._count||1)-1,0===h._count&&e.removeEventListener(l
,this.handleNative));e.removeEventListener(t,n)},register:function(e){this.recog
nizers.push(e);for(var t=0;t<e.emits.length;t++)this.gestures[e.emits[t]]=e},fin
dRecognizerByEvent:function(e){for(var t,n=0;n<this.recognizers.length;n++){t=th
is.recognizers[n];for(var r,s=0;s<t.emits.length;s++)if(r=t.emits[s],r===e)retur
n t}return null},setTouchAction:function(e,t){l&&(e.style.touchAction=t),e[u]=t}
,fire:function(e,t,n){var r=Polymer.Base.fire(t,n,{node:e,bubbles:!0,cancelable:
!0});if(r.defaultPrevented){var s=n.preventer||n.sourceEvent;s&&s.preventDefault
&&s.preventDefault()}},prevent:function(e){var t=this.findRecognizerByEvent(e);t
.info&&(t.info.prevent=!0)},resetMouseCanceller:function(){S.mouse.mouseIgnoreJo
b&&S.mouse.mouseIgnoreJob.complete()}};C.register({name:"downup",deps:["mousedow
n","touchstart","touchend"],flow:{start:["mousedown","touchstart"],end:["mouseup
","touchend"]},emits:["down","up"],info:{movefn:null,upfn:null},reset:function()
{o(this.info)},mousedown:function(e){if(n(e)){var t=C.findOriginalTarget(e),r=th
is,s=function(e){n(e)||(r.fire("up",t,e),o(r.info))},a=function(e){n(e)&&r.fire(
"up",t,e),o(r.info)};i(this.info,s,a),this.fire("down",t,e)}},touchstart:functio
n(e){this.fire("down",C.findOriginalTarget(e),e.changedTouches[0],e)},touchend:f
unction(e){this.fire("up",C.findOriginalTarget(e),e.changedTouches[0],e)},fire:f
unction(e,t,n,r){C.fire(t,e,{x:n.clientX,y:n.clientY,sourceEvent:n,preventer:r,p
revent:function(e){return C.prevent(e)}})}}),C.register({name:"track",touchActio
n:"none",deps:["mousedown","touchstart","touchmove","touchend"],flow:{start:["mo
usedown","touchstart"],end:["mouseup","touchend"]},emits:["track"],info:{x:0,y:0
,state:"start",started:!1,moves:[],addMove:function(e){this.moves.length>_&&this
.moves.shift(),this.moves.push(e)},movefn:null,upfn:null,prevent:!1},reset:funct
ion(){this.info.state="start",this.info.started=!1,this.info.moves=[],this.info.
x=0,this.info.y=0,this.info.prevent=!1,o(this.info)},hasMovedEnough:function(e,t
){if(this.info.prevent)return!1;if(this.info.started)return!0;var n=Math.abs(thi
s.info.x-e),r=Math.abs(this.info.y-t);return n>=p||r>=p},mousedown:function(e){i
f(n(e)){var t=C.findOriginalTarget(e),r=this,s=function(e){var s=e.clientX,i=e.c
lientY;r.hasMovedEnough(s,i)&&(r.info.state=r.info.started?"mouseup"===e.type?"e
nd":"track":"start","start"===r.info.state&&C.prevent("tap"),r.info.addMove({x:s
,y:i}),n(e)||(r.info.state="end",o(r.info)),r.fire(t,e),r.info.started=!0)},a=fu
nction(e){r.info.started&&s(e),o(r.info)};i(this.info,s,a),this.info.x=e.clientX
,this.info.y=e.clientY}},touchstart:function(e){var t=e.changedTouches[0];this.i
nfo.x=t.clientX,this.info.y=t.clientY},touchmove:function(e){var t=C.findOrigina
lTarget(e),n=e.changedTouches[0],r=n.clientX,s=n.clientY;this.hasMovedEnough(r,s
)&&("start"===this.info.state&&C.prevent("tap"),this.info.addMove({x:r,y:s}),thi
s.fire(t,n),this.info.state="track",this.info.started=!0)},touchend:function(e){
var t=C.findOriginalTarget(e),n=e.changedTouches[0];this.info.started&&(this.inf
o.state="end",this.info.addMove({x:n.clientX,y:n.clientY}),this.fire(t,n,e))},fi
re:function(e,t,n){var r,s=this.info.moves[this.info.moves.length-2],i=this.info
.moves[this.info.moves.length-1],o=i.x-this.info.x,a=i.y-this.info.y,l=0;return
s&&(r=i.x-s.x,l=i.y-s.y),C.fire(e,"track",{state:this.info.state,x:t.clientX,y:t
.clientY,dx:o,dy:a,ddx:r,ddy:l,sourceEvent:t,preventer:n,hover:function(){return
C.deepTargetFind(t.clientX,t.clientY)}})}}),C.register({name:"tap",deps:["mouse
down","click","touchstart","touchend"],flow:{start:["mousedown","touchstart"],en
d:["click","touchend"]},emits:["tap"],info:{x:NaN,y:NaN,prevent:!1},reset:functi
on(){this.info.x=NaN,this.info.y=NaN,this.info.prevent=!1},save:function(e){this
.info.x=e.clientX,this.info.y=e.clientY},mousedown:function(e){n(e)&&this.save(e
)},click:function(e){n(e)&&this.forward(e)},touchstart:function(e){this.save(e.c
hangedTouches[0],e)},touchend:function(e){this.forward(e.changedTouches[0],e)},f
orward:function(e,t){var n=Math.abs(e.clientX-this.info.x),s=Math.abs(e.clientY-
this.info.y),i=C.findOriginalTarget(e);(isNaN(n)||isNaN(s)||n<=f&&s<=f||r(e))&&(
this.info.prevent||C.fire(i,"tap",{x:e.clientX,y:e.clientY,sourceEvent:e,prevent
er:t}))}});var E={x:"pan-x",y:"pan-y",none:"none",all:"auto"};Polymer.Base._addF
eature({_setupGestures:function(){this.__polymerGestures=null},_listen:function(
e,t,n){C.gestures[t]?C.add(e,t,n):e.addEventListener(t,n)},_unlisten:function(e,
t,n){C.gestures[t]?C.remove(e,t,n):e.removeEventListener(t,n)},setScrollDirectio
n:function(e,t){t=t||this,C.setTouchAction(t,E[e]||"auto")}}),Polymer.Gestures=C
}(),function(){"use strict";if(Polymer.Base._addFeature({$$:function(e){return P
olymer.dom(this.root).querySelector(e)},toggleClass:function(e,t,n){n=n||this,1=
=arguments.length&&(t=!n.classList.contains(e)),t?Polymer.dom(n).classList.add(e
):Polymer.dom(n).classList.remove(e)},toggleAttribute:function(e,t,n){n=n||this,
1==arguments.length&&(t=!n.hasAttribute(e)),t?Polymer.dom(n).setAttribute(e,""):
Polymer.dom(n).removeAttribute(e)},classFollows:function(e,t,n){n&&Polymer.dom(n
).classList.remove(e),t&&Polymer.dom(t).classList.add(e)},attributeFollows:funct
ion(e,t,n){n&&Polymer.dom(n).removeAttribute(e),t&&Polymer.dom(t).setAttribute(e
,"")},getEffectiveChildNodes:function(){return Polymer.dom(this).getEffectiveChi
ldNodes()},getEffectiveChildren:function(){var e=Polymer.dom(this).getEffectiveC
hildNodes();return e.filter(function(e){return e.nodeType===Node.ELEMENT_NODE})}
,getEffectiveTextContent:function(){for(var e,t=this.getEffectiveChildNodes(),n=
[],r=0;e=t[r];r++)e.nodeType!==Node.COMMENT_NODE&&n.push(Polymer.dom(e).textCont
ent);return n.join("")},queryEffectiveChildren:function(e){var t=Polymer.dom(thi
s).queryDistributedElements(e);return t&&t[0]},queryAllEffectiveChildren:functio
n(e){return Polymer.dom(this).queryDistributedElements(e)},getContentChildNodes:
function(e){var t=Polymer.dom(this.root).querySelector(e||"content");return t?Po
lymer.dom(t).getDistributedNodes():[]},getContentChildren:function(e){return thi
s.getContentChildNodes(e).filter(function(e){return e.nodeType===Node.ELEMENT_NO
DE})},fire:function(e,t,n){n=n||Polymer.nob;var r=n.node||this;t=null===t||void
0===t?{}:t;var s=void 0===n.bubbles||n.bubbles,i=Boolean(n.cancelable),o=n._useC
ache,a=this._getEvent(e,s,i,o);return a.detail=t,o&&(this.__eventCache[e]=null),
r.dispatchEvent(a),o&&(this.__eventCache[e]=a),a},__eventCache:{},_getEvent:func
tion(e,t,n,r){var s=r&&this.__eventCache[e];return s&&s.bubbles==t&&s.cancelable
==n||(s=new Event(e,{bubbles:Boolean(t),cancelable:n})),s},async:function(e,t){v
ar n=this;return Polymer.Async.run(function(){e.call(n)},t)},cancelAsync:functio
n(e){Polymer.Async.cancel(e)},arrayDelete:function(e,t){var n;if(Array.isArray(e
)){if(n=e.indexOf(t),n>=0)return e.splice(n,1)}else{var r=this._get(e);if(n=r.in
dexOf(t),n>=0)return this.splice(e,n,1)}},transform:function(e,t){t=t||this,t.st
yle.webkitTransform=e,t.style.transform=e},translate3d:function(e,t,n,r){r=r||th
is,this.transform("translate3d("+e+","+t+","+n+")",r)},importHref:function(e,t,n
,r){var s=document.createElement("link");s.rel="import",s.href=e;var i=Polymer.B
ase.importHref.imported=Polymer.Base.importHref.imported||{},o=i[s.href],a=o||s,
l=this;if(t){var c=function(e){return e.target.__firedLoad=!0,e.target.removeEve
ntListener("load",c),t.call(l,e)};a.addEventListener("load",c)}if(n){var h=funct
ion(e){return e.target.__firedError=!0,e.target.removeEventListener("error",h),n
.call(l,e)};a.addEventListener("error",h)}return o?(o.__firedLoad&&o.dispatchEve
nt(new Event("load")),o.__firedError&&o.dispatchEvent(new Event("error"))):(i[s.
href]=s,r=Boolean(r),r&&s.setAttribute("async",""),document.head.appendChild(s))
,a},create:function(e,t){var n=document.createElement(e);if(t)for(var r in t)n[r
]=t[r];return n},isLightDescendant:function(e){return this!==e&&this.contains(e)
&&Polymer.dom(this).getOwnerRoot()===Polymer.dom(e).getOwnerRoot()},isLocalDesce
ndant:function(e){return this.root===Polymer.dom(e).getOwnerRoot()}}),!Polymer.S
ettings.useNativeCustomElements){var e=Polymer.Base.importHref;Polymer.Base.impo
rtHref=function(t,n,r,s){CustomElements.ready=!1;var i=function(e){if(CustomElem
ents.upgradeDocumentTree(document),CustomElements.ready=!0,n)return n.call(this,
e)};return e.call(this,t,i,r,s)}}}(),Polymer.Bind={prepareModel:function(e){Poly
mer.Base.mixin(e,this._modelApi)},_modelApi:{_notifyChange:function(e,t,n){n=voi
d 0===n?this[e]:n,t=t||Polymer.CaseMap.camelToDashCase(e)+"-changed",this.fire(t
,{value:n},{bubbles:!1,cancelable:!1,_useCache:!0})},_propertySetter:function(e,
t,n,r){var s=this.__data__[e];return s===t||s!==s&&t!==t||(this.__data__[e]=t,"o
bject"==typeof t&&this._clearPath(e),this._propertyChanged&&this._propertyChange
d(e,t,s),n&&this._effectEffects(e,t,n,s,r)),s},__setProperty:function(e,t,n,r){r
=r||this;var s=r._propertyEffects&&r._propertyEffects[e];s?r._propertySetter(e,t
,s,n):r[e]!==t&&(r[e]=t)},_effectEffects:function(e,t,n,r,s){for(var i,o=0,a=n.l
ength;o<a&&(i=n[o]);o++)i.fn.call(this,e,this[e],i.effect,r,s)},_clearPath:funct
ion(e){for(var t in this.__data__)Polymer.Path.isDescendant(e,t)&&(this.__data__
[t]=void 0)}},ensurePropertyEffects:function(e,t){e._propertyEffects||(e._proper
tyEffects={});var n=e._propertyEffects[t];return n||(n=e._propertyEffects[t]=[])
,n},addPropertyEffect:function(e,t,n,r){var s=this.ensurePropertyEffects(e,t),i=
{kind:n,effect:r,fn:Polymer.Bind["_"+n+"Effect"]};return s.push(i),i},createBind
ings:function(e){var t=e._propertyEffects;if(t)for(var n in t){var r=t[n];r.sort
(this._sortPropertyEffects),this._createAccessors(e,n,r)}},_sortPropertyEffects:
function(){var e={compute:0,annotation:1,annotatedComputation:2,reflect:3,notify
:4,observer:5,complexObserver:6,function:7};return function(t,n){return e[t.kind
]-e[n.kind]}}(),_createAccessors:function(e,t,n){var r={get:function(){return th
is.__data__[t]}},s=function(e){this._propertySetter(t,e,n)},i=e.getPropertyInfo&
&e.getPropertyInfo(t);i&&i.readOnly?i.computed||(e["_set"+this.upper(t)]=s):r.se
t=s,Object.defineProperty(e,t,r)},upper:function(e){return e[0].toUpperCase()+e.
substring(1)},_addAnnotatedListener:function(e,t,n,r,s,i){e._bindListeners||(e._
bindListeners=[]);var o=this._notedListenerFactory(n,r,Polymer.Path.isDeep(r),i)
,a=s||Polymer.CaseMap.camelToDashCase(n)+"-changed";e._bindListeners.push({index
:t,property:n,path:r,changedFn:o,event:a})},_isEventBogus:function(e,t){return e
.path&&e.path[0]!==t},_notedListenerFactory:function(e,t,n,r){return function(s,
i,o){if(o){var a=Polymer.Path.translate(e,t,o);this._notifyPath(a,i)}else i=s[e]
,r&&(i=!i),n?this.__data__[t]!=i&&this.set(t,i):this[t]=i}},prepareInstance:func
tion(e){e.__data__=Object.create(null)},setupBindListeners:function(e){for(var t
,n=e._bindListeners,r=0,s=n.length;r<s&&(t=n[r]);r++){var i=e._nodes[t.index];th
is._addNotifyListener(i,e,t.event,t.changedFn)}},_addNotifyListener:function(e,t
,n,r){e.addEventListener(n,function(e){return t._notifyListener(r,e)})}},Polymer
.Base.extend(Polymer.Bind,{_shouldAddListener:function(e){return e.name&&"attrib
ute"!=e.kind&&"text"!=e.kind&&!e.isCompound&&"{"===e.parts[0].mode},_annotationE
ffect:function(e,t,n){e!=n.value&&(t=this._get(n.value),this.__data__[n.value]=t
),this._applyEffectValue(n,t)},_reflectEffect:function(e,t,n){this.reflectProper
tyToAttribute(e,n.attribute,t)},_notifyEffect:function(e,t,n,r,s){s||this._notif
yChange(e,n.event,t)},_functionEffect:function(e,t,n,r,s){n.call(this,e,t,r,s)},
_observerEffect:function(e,t,n,r){var s=this[n.method];s?s.call(this,t,r):this._
warn(this._logf("_observerEffect","observer method `"+n.method+"` not defined"))
},_complexObserverEffect:function(e,t,n){var r=this[n.method];if(r){var s=Polyme
r.Bind._marshalArgs(this.__data__,n,e,t);s&&r.apply(this,s)}else n.dynamicFn||th
is._warn(this._logf("_complexObserverEffect","observer method `"+n.method+"` not
defined"))},_computeEffect:function(e,t,n){var r=this[n.method];if(r){var s=Pol
ymer.Bind._marshalArgs(this.__data__,n,e,t);if(s){var i=r.apply(this,s);this.__s
etProperty(n.name,i)}}else n.dynamicFn||this._warn(this._logf("_computeEffect","
compute method `"+n.method+"` not defined"))},_annotatedComputationEffect:functi
on(e,t,n){var r=this._rootDataHost||this,s=r[n.method];if(s){var i=Polymer.Bind.
_marshalArgs(this.__data__,n,e,t);if(i){var o=s.apply(r,i);this._applyEffectValu
e(n,o)}}else n.dynamicFn||r._warn(r._logf("_annotatedComputationEffect","compute
method `"+n.method+"` not defined"))},_marshalArgs:function(e,t,n,r){for(var s=
[],i=t.args,o=i.length>1||t.dynamicFn,a=0,l=i.length;a<l;a++){var c,h=i[a],u=h.n
ame;if(h.literal?c=h.value:n===u?c=r:(c=e[u],void 0===c&&h.structured&&(c=Polyme
r.Base._get(u,e))),o&&void 0===c)return;if(h.wildcard){var f=Polymer.Path.isAnce
stor(n,u);s[a]={path:f?n:u,value:f?r:c,base:c}}else s[a]=c}return s}}),Polymer.B
ase._addFeature({_addPropertyEffect:function(e,t,n){var r=Polymer.Bind.addProper
tyEffect(this,e,t,n);r.pathFn=this["_"+r.kind+"PathEffect"]},_prepEffects:functi
on(){Polymer.Bind.prepareModel(this),this._addAnnotationEffects(this._notes)},_p
repBindings:function(){Polymer.Bind.createBindings(this)},_addPropertyEffects:fu
nction(e){if(e)for(var t in e){var n=e[t];if(n.observer&&this._addObserverEffect
(t,n.observer),n.computed&&(n.readOnly=!0,this._addComputedEffect(t,n.computed))
,n.notify&&this._addPropertyEffect(t,"notify",{event:Polymer.CaseMap.camelToDash
Case(t)+"-changed"}),n.reflectToAttribute){var r=Polymer.CaseMap.camelToDashCase
(t);"-"===r[0]?this._warn(this._logf("_addPropertyEffects","Property "+t+" canno
t be reflected to attribute "+r+' because "-" is not a valid starting attribute
name. Use a lowercase first letter for the property instead.')):this._addPropert
yEffect(t,"reflect",{attribute:r})}n.readOnly&&Polymer.Bind.ensurePropertyEffect
s(this,t)}},_addComputedEffect:function(e,t){for(var n,r=this._parseMethod(t),s=
r.dynamicFn,i=0;i<r.args.length&&(n=r.args[i]);i++)this._addPropertyEffect(n.mod
el,"compute",{method:r.method,args:r.args,trigger:n,name:e,dynamicFn:s});s&&this
._addPropertyEffect(r.method,"compute",{method:r.method,args:r.args,trigger:null
,name:e,dynamicFn:s})},_addObserverEffect:function(e,t){this._addPropertyEffect(
e,"observer",{method:t,property:e})},_addComplexObserverEffects:function(e){if(e
)for(var t,n=0;n<e.length&&(t=e[n]);n++)this._addComplexObserverEffect(t)},_addC
omplexObserverEffect:function(e){var t=this._parseMethod(e);if(!t)throw new Erro
r("Malformed observer expression '"+e+"'");for(var n,r=t.dynamicFn,s=0;s<t.args.
length&&(n=t.args[s]);s++)this._addPropertyEffect(n.model,"complexObserver",{met
hod:t.method,args:t.args,trigger:n,dynamicFn:r});r&&this._addPropertyEffect(t.me
thod,"complexObserver",{method:t.method,args:t.args,trigger:null,dynamicFn:r})},
_addAnnotationEffects:function(e){for(var t,n=0;n<e.length&&(t=e[n]);n++)for(var
r,s=t.bindings,i=0;i<s.length&&(r=s[i]);i++)this._addAnnotationEffect(r,n)},_ad
dAnnotationEffect:function(e,t){Polymer.Bind._shouldAddListener(e)&&Polymer.Bind
._addAnnotatedListener(this,t,e.name,e.parts[0].value,e.parts[0].event,e.parts[0
].negate);for(var n=0;n<e.parts.length;n++){var r=e.parts[n];r.signature?this._a
ddAnnotatedComputationEffect(e,r,t):r.literal||("attribute"===e.kind&&"-"===e.na
me[0]?this._warn(this._logf("_addAnnotationEffect","Cannot set attribute "+e.nam
e+' because "-" is not a valid attribute starting character')):this._addProperty
Effect(r.model,"annotation",{kind:e.kind,index:t,name:e.name,propertyName:e.prop
ertyName,value:r.value,isCompound:e.isCompound,compoundIndex:r.compoundIndex,eve
nt:r.event,customEvent:r.customEvent,negate:r.negate}))}},_addAnnotatedComputati
onEffect:function(e,t,n){var r=t.signature;if(r.static)this.__addAnnotatedComput
ationEffect("__static__",n,e,t,null);else{for(var s,i=0;i<r.args.length&&(s=r.ar
gs[i]);i++)s.literal||this.__addAnnotatedComputationEffect(s.model,n,e,t,s);r.dy
namicFn&&this.__addAnnotatedComputationEffect(r.method,n,e,t,null)}},__addAnnota
tedComputationEffect:function(e,t,n,r,s){this._addPropertyEffect(e,"annotatedCom
putation",{index:t,isCompound:n.isCompound,compoundIndex:r.compoundIndex,kind:n.
kind,name:n.name,negate:r.negate,method:r.signature.method,args:r.signature.args
,trigger:s,dynamicFn:r.signature.dynamicFn})},_parseMethod:function(e){var t=e.m
atch(/([^\s]+?)\(([\s\S]*)\)/);if(t){var n={method:t[1],static:!0};if(this.getPr
opertyInfo(n.method)!==Polymer.nob&&(n.static=!1,n.dynamicFn=!0),t[2].trim()){va
r r=t[2].replace(/\\,/g,",").split(",");return this._parseArgs(r,n)}return
n.args=Polymer.nar,n}},_parseArgs:function(e,t){return t.args=e.map(function(e)
{var n=this._parseArg(e);return n.literal||(t.static=!1),n},this),t},_parseArg:f
unction(e){var t=e.trim().replace(/,/g,",").replace(/\\(.)/g,"$1"),n={name
:t},r=t[0];switch("-"===r&&(r=t[1]),r>="0"&&r<="9"&&(r="#"),r){case"'":case'"':n
.value=t.slice(1,-1),n.literal=!0;break;case"#":n.value=Number(t),n.literal=!0}r
eturn n.literal||(n.model=Polymer.Path.root(t),n.structured=Polymer.Path.isDeep(
t),n.structured&&(n.wildcard=".*"==t.slice(-2),n.wildcard&&(n.name=t.slice(0,-2)
))),n},_marshalInstanceEffects:function(){Polymer.Bind.prepareInstance(this),thi
s._bindListeners&&Polymer.Bind.setupBindListeners(this)},_applyEffectValue:funct
ion(e,t){var n=this._nodes[e.index],r=e.name;if(t=this._computeFinalAnnotationVa
lue(n,r,t,e),"attribute"==e.kind)this.serializeValueToAttribute(t,r,n);else{var
s=n._propertyInfo&&n._propertyInfo[r];if(s&&s.readOnly)return;this.__setProperty
(r,t,!1,n)}},_computeFinalAnnotationValue:function(e,t,n,r){if(r.negate&&(n=!n),
r.isCompound){var s=e.__compoundStorage__[t];s[r.compoundIndex]=n,n=s.join("")}r
eturn"attribute"!==r.kind&&("className"===t&&(n=this._scopeElementClass(e,n)),("
textContent"===t||"input"==e.localName&&"value"==t)&&(n=void 0==n?"":n)),n},_exe
cuteStaticEffects:function(){this._propertyEffects&&this._propertyEffects.__stat
ic__&&this._effectEffects("__static__",null,this._propertyEffects.__static__)}})
,function(){var e=Polymer.Settings.usePolyfillProto;Polymer.Base._addFeature({_s
etupConfigure:function(e){if(this._config={},this._handlers=[],this._aboveConfig
=null,e)for(var t in e)void 0!==e[t]&&(this._config[t]=e[t])},_marshalAttributes
:function(){this._takeAttributesToModel(this._config)},_attributeChangedImpl:fun
ction(e){var t=this._clientsReadied?this:this._config;this._setAttributeToProper
ty(t,e)},_configValue:function(e,t){var n=this._propertyInfo[e];n&&n.readOnly||(
this._config[e]=t)},_beforeClientsReady:function(){this._configure()},_configure
:function(){this._configureAnnotationReferences(),this._configureInstancePropert
ies(),this._aboveConfig=this.mixin({},this._config);for(var e={},t=0;t<this.beha
viors.length;t++)this._configureProperties(this.behaviors[t].properties,e);this.
_configureProperties(this.properties,e),this.mixin(e,this._aboveConfig),this._co
nfig=e,this._clients&&this._clients.length&&this._distributeConfig(this._config)
},_configureInstanceProperties:function(){for(var t in this._propertyEffects)!e&
&this.hasOwnProperty(t)&&(this._configValue(t,this[t]), |
| 3 delete this[t])},_configureProperties:function(e,t){for(var n in e){var r=e[n];i
f(void 0!==r.value){var s=r.value;"function"==typeof s&&(s=s.call(this,this._con
fig)),t[n]=s}}},_distributeConfig:function(e){var t=this._propertyEffects;if(t)f
or(var n in e){var r=t[n];if(r)for(var s,i=0,o=r.length;i<o&&(s=r[i]);i++)if("an
notation"===s.kind){var a=this._nodes[s.effect.index],l=s.effect.propertyName,c=
"attribute"==s.effect.kind,h=a._propertyEffects&&a._propertyEffects[l];if(a._con
figValue&&(h||!c)){var u=n===s.effect.value?e[n]:this._get(s.effect.value,e);u=t
his._computeFinalAnnotationValue(a,l,u,s.effect),c&&(u=a.deserialize(this.serial
ize(u),a._propertyInfo[l].type)),a._configValue(l,u)}}}},_afterClientsReady:func
tion(){this._executeStaticEffects(),this._applyConfig(this._config,this._aboveCo
nfig),this._flushHandlers()},_applyConfig:function(e,t){for(var n in e)void 0===
this[n]&&this.__setProperty(n,e[n],n in t)},_notifyListener:function(e,t){if(!Po
lymer.Bind._isEventBogus(t,t.target)){var n,r;if(t.detail&&(n=t.detail.value,r=t
.detail.path),this._clientsReadied)return e.call(this,t.target,n,r);this._queueH
andler([e,t.target,n,r])}},_queueHandler:function(e){this._handlers.push(e)},_fl
ushHandlers:function(){for(var e,t=this._handlers,n=0,r=t.length;n<r&&(e=t[n]);n
++)e[0].call(this,e[1],e[2],e[3]);this._handlers=[]}})}(),function(){"use strict
";var e=Polymer.Path;Polymer.Base._addFeature({notifyPath:function(e,t,n){var r=
{},s=this._get(e,this,r);1===arguments.length&&(t=s),r.path&&this._notifyPath(r.
path,t,n)},_notifyPath:function(e,t,n){var r=this._propertySetter(e,t);if(r!==t&
&(r===r||t===t))return this._pathEffector(e,t),n||this._notifyPathUp(e,t),!0},_g
etPathParts:function(e){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++)for
(var r=e[n].toString().split("."),s=0;s<r.length;s++)t.push(r[s]);return t}retur
n e.toString().split(".")},set:function(e,t,n){var r,s=n||this,i=this._getPathPa
rts(e),o=i[i.length-1];if(i.length>1){for(var a=0;a<i.length-1;a++){var l=i[a];i
f(r&&"#"==l[0]?s=Polymer.Collection.get(r).getItem(l):(s=s[l],r&&parseInt(l,10)=
=l&&(i[a]=Polymer.Collection.get(r).getKey(s))),!s)return;r=Array.isArray(s)?s:n
ull}if(r){var c,h,u=Polymer.Collection.get(r);"#"==o[0]?(h=o,c=u.getItem(h),o=r.
indexOf(c),u.setItem(h,t)):parseInt(o,10)==o&&(c=s[o],h=u.getKey(c),i[a]=h,u.set
Item(h,t))}s[o]=t,n||this._notifyPath(i.join("."),t)}else s[e]=t},get:function(e
,t){return this._get(e,t)},_get:function(e,t,n){for(var r,s=t||this,i=this._getP
athParts(e),o=0;o<i.length;o++){if(!s)return;var a=i[o];r&&"#"==a[0]?s=Polymer.C
ollection.get(r).getItem(a):(s=s[a],n&&r&&parseInt(a,10)==a&&(i[o]=Polymer.Colle
ction.get(r).getKey(s))),r=Array.isArray(s)?s:null}return n&&(n.path=i.join(".")
),s},_pathEffector:function(t,n){var r=e.root(t),s=this._propertyEffects&&this._
propertyEffects[r];if(s)for(var i,o=0;o<s.length&&(i=s[o]);o++){var a=i.pathFn;a
&&a.call(this,t,n,i.effect)}this._boundPaths&&this._notifyBoundPaths(t,n)},_anno
tationPathEffect:function(t,n,r){if(e.matches(r.value,!1,t))Polymer.Bind._annota
tionEffect.call(this,t,n,r);else if(!r.negate&&e.isDescendant(r.value,t)){var s=
this._nodes[r.index];if(s&&s._notifyPath){var i=e.translate(r.value,r.name,t);s.
_notifyPath(i,n,!0)}}},_complexObserverPathEffect:function(t,n,r){e.matches(r.tr
igger.name,r.trigger.wildcard,t)&&Polymer.Bind._complexObserverEffect.call(this,
t,n,r)},_computePathEffect:function(t,n,r){e.matches(r.trigger.name,r.trigger.wi
ldcard,t)&&Polymer.Bind._computeEffect.call(this,t,n,r)},_annotatedComputationPa
thEffect:function(t,n,r){e.matches(r.trigger.name,r.trigger.wildcard,t)&&Polymer
.Bind._annotatedComputationEffect.call(this,t,n,r)},linkPaths:function(e,t){this
._boundPaths=this._boundPaths||{},t?this._boundPaths[e]=t:this.unlinkPaths(e)},u
nlinkPaths:function(e){this._boundPaths&&delete this._boundPaths[e]},_notifyBoun
dPaths:function(t,n){for(var r in this._boundPaths){var s=this._boundPaths[r];e.
isDescendant(r,t)?this._notifyPath(e.translate(r,s,t),n):e.isDescendant(s,t)&&th
is._notifyPath(e.translate(s,r,t),n)}},_notifyPathUp:function(t,n){var r=e.root(
t),s=Polymer.CaseMap.camelToDashCase(r),i=s+this._EVENT_CHANGED;this.fire(i,{pat
h:t,value:n},{bubbles:!1,_useCache:!0})},_EVENT_CHANGED:"-changed",notifySplices
:function(e,t){var n={},r=this._get(e,this,n);this._notifySplices(r,n.path,t)},_
notifySplices:function(e,t,n){var r={keySplices:Polymer.Collection.applySplices(
e,n),indexSplices:n},s=t+".splices";this._notifyPath(s,r),this._notifyPath(t+".l
ength",e.length),this.__data__[s]={keySplices:null,indexSplices:null}},_notifySp
lice:function(e,t,n,r,s){this._notifySplices(e,t,[{index:n,addedCount:r,removed:
s,object:e,type:"splice"}])},push:function(e){var t={},n=this._get(e,this,t),r=A
rray.prototype.slice.call(arguments,1),s=n.length,i=n.push.apply(n,r);return r.l
ength&&this._notifySplice(n,t.path,s,r.length,[]),i},pop:function(e){var t={},n=
this._get(e,this,t),r=Boolean(n.length),s=Array.prototype.slice.call(arguments,1
),i=n.pop.apply(n,s);return r&&this._notifySplice(n,t.path,n.length,0,[i]),i},sp
lice:function(e,t){var n={},r=this._get(e,this,n);t=t<0?r.length-Math.floor(-t):
Math.floor(t),t||(t=0);var s=Array.prototype.slice.call(arguments,1),i=r.splice.
apply(r,s),o=Math.max(s.length-2,0);return(o||i.length)&&this._notifySplice(r,n.
path,t,o,i),i},shift:function(e){var t={},n=this._get(e,this,t),r=Boolean(n.leng
th),s=Array.prototype.slice.call(arguments,1),i=n.shift.apply(n,s);return r&&thi
s._notifySplice(n,t.path,0,0,[i]),i},unshift:function(e){var t={},n=this._get(e,
this,t),r=Array.prototype.slice.call(arguments,1),s=n.unshift.apply(n,r);return
r.length&&this._notifySplice(n,t.path,0,r.length,[]),s},prepareModelNotifyPath:f
unction(e){this.mixin(e,{fire:Polymer.Base.fire,_getEvent:Polymer.Base._getEvent
,__eventCache:Polymer.Base.__eventCache,notifyPath:Polymer.Base.notifyPath,_get:
Polymer.Base._get,_EVENT_CHANGED:Polymer.Base._EVENT_CHANGED,_notifyPath:Polymer
.Base._notifyPath,_notifyPathUp:Polymer.Base._notifyPathUp,_pathEffector:Polymer
.Base._pathEffector,_annotationPathEffect:Polymer.Base._annotationPathEffect,_co
mplexObserverPathEffect:Polymer.Base._complexObserverPathEffect,_annotatedComput
ationPathEffect:Polymer.Base._annotatedComputationPathEffect,_computePathEffect:
Polymer.Base._computePathEffect,_notifyBoundPaths:Polymer.Base._notifyBoundPaths
,_getPathParts:Polymer.Base._getPathParts})}})}(),Polymer.Base._addFeature({reso
lveUrl:function(e){var t=Polymer.DomModule.import(this.is),n="";if(t){var r=t.ge
tAttribute("assetpath")||"";n=Polymer.ResolveUrl.resolveUrl(r,t.ownerDocument.ba
seURI)}return Polymer.ResolveUrl.resolveUrl(e,n)}}),Polymer.CssParse=function(){
return{parse:function(e){return e=this._clean(e),this._parseCss(this._lex(e),e)}
,_clean:function(e){return e.replace(this._rx.comments,"").replace(this._rx.port
,"")},_lex:function(e){for(var t={start:0,end:e.length},n=t,r=0,s=e.length;r<s;r
++)switch(e[r]){case this.OPEN_BRACE:n.rules||(n.rules=[]);var i=n,o=i.rules[i.r
ules.length-1];n={start:r+1,parent:i,previous:o},i.rules.push(n);break;case this
.CLOSE_BRACE:n.end=r+1,n=n.parent||t}return t},_parseCss:function(e,t){var n=t.s
ubstring(e.start,e.end-1);if(e.parsedCssText=e.cssText=n.trim(),e.parent){var r=
e.previous?e.previous.end:e.parent.start;n=t.substring(r,e.start-1),n=this._expa
ndUnicodeEscapes(n),n=n.replace(this._rx.multipleSpaces," "),n=n.substring(n.las
tIndexOf(";")+1);var s=e.parsedSelector=e.selector=n.trim();e.atRule=0===s.index
Of(this.AT_START),e.atRule?0===s.indexOf(this.MEDIA_START)?e.type=this.types.MED
IA_RULE:s.match(this._rx.keyframesRule)&&(e.type=this.types.KEYFRAMES_RULE,e.key
framesName=e.selector.split(this._rx.multipleSpaces).pop()):0===s.indexOf(this.V
AR_START)?e.type=this.types.MIXIN_RULE:e.type=this.types.STYLE_RULE}var i=e.rule
s;if(i)for(var o,a=0,l=i.length;a<l&&(o=i[a]);a++)this._parseCss(o,t);return e},
_expandUnicodeEscapes:function(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,funct
ion(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return"\\"+e})},stringify
:function(e,t,n){n=n||"";var r="";if(e.cssText||e.rules){var s=e.rules;if(s&&!th
is._hasMixinRules(s))for(var i,o=0,a=s.length;o<a&&(i=s[o]);o++)r=this.stringify
(i,t,r);else r=t?e.cssText:this.removeCustomProps(e.cssText),r=r.trim(),r&&(r="
"+r+"\n")}return r&&(e.selector&&(n+=e.selector+" "+this.OPEN_BRACE+"\n"),n+=r,
e.selector&&(n+=this.CLOSE_BRACE+"\n\n")),n},_hasMixinRules:function(e){return 0
===e[0].selector.indexOf(this.VAR_START)},removeCustomProps:function(e){return e
=this.removeCustomPropAssignment(e),this.removeCustomPropApply(e)},removeCustomP
ropAssignment:function(e){return e.replace(this._rx.customProp,"").replace(this.
_rx.mixinProp,"")},removeCustomPropApply:function(e){return e.replace(this._rx.m
ixinApply,"").replace(this._rx.varApply,"")},types:{STYLE_RULE:1,KEYFRAMES_RULE:
7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE:"{",CLOSE_BRACE:"}",_rx:{comments:/\/\
*[^*]*\*+([^\/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s
}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^
{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/
gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*
keyframes/,multipleSpaces:/\s+/g},VAR_START:"--",MEDIA_START:"@media",AT_START:"
@"}}(),Polymer.StyleUtil=function(){var e=Polymer.Settings;return{NATIVE_VARIABL
ES:Polymer.Settings.useNativeCSSProperties,MODULE_STYLES_SELECTOR:"style, link[r
el=import][type~=css], template",INCLUDE_ATTR:"include",toCssText:function(e,t){
return"string"==typeof e&&(e=this.parser.parse(e)),t&&this.forEachRule(e,t),this
.parser.stringify(e,this.NATIVE_VARIABLES)},forRulesInStyles:function(e,t,n){if(
e)for(var r,s=0,i=e.length;s<i&&(r=e[s]);s++)this.forEachRuleInStyle(r,t,n)},for
ActiveRulesInStyles:function(e,t,n){if(e)for(var r,s=0,i=e.length;s<i&&(r=e[s]);
s++)this.forEachRuleInStyle(r,t,n,!0)},rulesForStyle:function(e){return!e.__cssR
ules&&e.textContent&&(e.__cssRules=this.parser.parse(e.textContent)),e.__cssRule
s},isKeyframesSelector:function(e){return e.parent&&e.parent.type===this.ruleTyp
es.KEYFRAMES_RULE},forEachRuleInStyle:function(e,t,n,r){var s,i,o=this.rulesForS
tyle(e);t&&(s=function(n){t(n,e)}),n&&(i=function(t){n(t,e)}),this.forEachRule(o
,s,i,r)},forEachRule:function(e,t,n,r){if(e){var s=!1;if(r&&e.type===this.ruleTy
pes.MEDIA_RULE){var i=e.selector.match(this.rx.MEDIA_MATCH);i&&(window.matchMedi
a(i[1]).matches||(s=!0))}e.type===this.ruleTypes.STYLE_RULE?t(e):n&&e.type===thi
s.ruleTypes.KEYFRAMES_RULE?n(e):e.type===this.ruleTypes.MIXIN_RULE&&(s=!0);var o
=e.rules;if(o&&!s)for(var a,l=0,c=o.length;l<c&&(a=o[l]);l++)this.forEachRule(a,
t,n,r)}},applyCss:function(e,t,n,r){var s=this.createScopeStyle(e,t);return this
.applyStyle(s,n,r)},applyStyle:function(e,t,n){t=t||document.head;var r=n&&n.nex
tSibling||t.firstChild;return this.__lastHeadApplyNode=e,t.insertBefore(e,r)},cr
eateScopeStyle:function(e,t){var n=document.createElement("style");return t&&n.s
etAttribute("scope",t),n.textContent=e,n},__lastHeadApplyNode:null,applyStylePla
ceHolder:function(e){var t=document.createComment(" Shady DOM styles for "+e+" "
),n=this.__lastHeadApplyNode?this.__lastHeadApplyNode.nextSibling:null,r=documen
t.head;return r.insertBefore(t,n||r.firstChild),this.__lastHeadApplyNode=t,t},cs
sFromModules:function(e,t){for(var n=e.trim().split(" "),r="",s=0;s<n.length;s++
)r+=this.cssFromModule(n[s],t);return r},cssFromModule:function(e,t){var n=Polym
er.DomModule.import(e);return n&&!n._cssText&&(n._cssText=this.cssFromElement(n)
),!n&&t&&console.warn("Could not find style data in module named",e),n&&n._cssTe
xt||""},cssFromElement:function(e){for(var t,n="",r=e.content||e,s=Polymer.TreeA
pi.arrayCopy(r.querySelectorAll(this.MODULE_STYLES_SELECTOR)),i=0;i<s.length;i++
)if(t=s[i],"template"===t.localName)t.hasAttribute("preserve-content")||(n+=this
.cssFromElement(t));else if("style"===t.localName){var o=t.getAttribute(this.INC
LUDE_ATTR);o&&(n+=this.cssFromModules(o,!0)),t=t.__appliedElement||t,t.parentNod
e.removeChild(t),n+=this.resolveCss(t.textContent,e.ownerDocument)}else t.import
&&t.import.body&&(n+=this.resolveCss(t.import.body.textContent,t.import));return
n},isTargetedBuild:function(t){return e.useNativeShadow?"shadow"===t:"shady"===
t},cssBuildTypeForModule:function(e){var t=Polymer.DomModule.import(e);if(t)retu
rn this.getCssBuildType(t)},getCssBuildType:function(e){return e.getAttribute("c
ss-build")},_findMatchingParen:function(e,t){for(var n=0,r=t,s=e.length;r<s;r++)
switch(e[r]){case"(":n++;break;case")":if(0===--n)return r}return-1},processVari
ableAndFallback:function(e,t){var n=e.indexOf("var(");if(n===-1)return t(e,"",""
,"");var r=this._findMatchingParen(e,n+3),s=e.substring(n+4,r),i=e.substring(0,n
),o=this.processVariableAndFallback(e.substring(r+1),t),a=s.indexOf(",");if(a===
-1)return t(i,s.trim(),"",o);var l=s.substring(0,a).trim(),c=s.substring(a+1).tr
im();return t(i,l,c,o)},rx:{VAR_ASSIGN:/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:([^;
{]*)|{([^}]*)})(?:(?=[;\s}])|$)/gi,MIXIN_MATCH:/(?:^|\W+)@apply\s*\(?([^);\n]*)\
)?/gi,VAR_CONSUMED:/(--[\w-]+)\s*([:,;)]|$)/gi,ANIMATION_MATCH:/(animation\s*:)|
(animation-name\s*:)/,MEDIA_MATCH:/@media[^(]*(\([^)]*\))/,IS_VAR:/^--/,BRACKETE
D:/\{[^}]*\}/g,HOST_PREFIX:"(?:^|[^.#[:])",HOST_SUFFIX:"($|[.:[\\s>+~])"},resolv
eCss:Polymer.ResolveUrl.resolveCss,parser:Polymer.CssParse,ruleTypes:Polymer.Css
Parse.types}}(),Polymer.StyleTransformer=function(){var e=Polymer.StyleUtil,t=Po
lymer.Settings,n={dom:function(e,t,n,r){this._transformDom(e,t||"",n,r)},_transf
ormDom:function(e,t,n,r){e.setAttribute&&this.element(e,t,n,r);for(var s=Polymer
.dom(e).childNodes,i=0;i<s.length;i++)this._transformDom(s[i],t,n,r)},element:fu
nction(e,t,n,s){if(n)s?e.removeAttribute(r):e.setAttribute(r,t);else if(t)if(e.c
lassList)s?(e.classList.remove(r),e.classList.remove(t)):(e.classList.add(r),e.c
lassList.add(t));else if(e.getAttribute){var i=e.getAttribute(g);s?i&&e.setAttri
bute(g,i.replace(r,"").replace(t,"")):e.setAttribute(g,(i?i+" ":"")+r+" "+t)}},e
lementStyles:function(n,r){var s,i=n._styles,o="",a=n.__cssBuild,l=t.useNativeSh
adow||"shady"===a;if(l){var h=this;s=function(e){e.selector=h._slottedToContent(
e.selector),e.selector=e.selector.replace(c,":host > *"),r&&r(e)}}for(var u,f=0,
p=i.length;f<p&&(u=i[f]);f++){var _=e.rulesForStyle(u);o+=l?e.toCssText(_,s):thi
s.css(_,n.is,n.extends,r,n._scopeCssViaAttr)+"\n\n"}return o.trim()},css:functio
n(t,n,r,s,i){var o=this._calcHostScope(n,r);n=this._calcElementScope(n,i);var a=
this;return e.toCssText(t,function(e){e.isScoped||(a.rule(e,n,o),e.isScoped=!0),
s&&s(e,n,o)})},_calcElementScope:function(e,t){return e?t?m+e+y:d+e:""},_calcHos
tScope:function(e,t){return t?"[is="+e+"]":e},rule:function(e,t,n){this._transfo
rmRule(e,this._transformComplexSelector,t,n)},_transformRule:function(e,t,n,r){e
.selector=e.transformedSelector=this._transformRuleCss(e,t,n,r)},_transformRuleC
ss:function(t,n,r,s){var o=t.selector.split(i);if(!e.isKeyframesSelector(t))for(
var a,l=0,c=o.length;l<c&&(a=o[l]);l++)o[l]=n.call(this,a,r,s);return o.join(i)}
,_transformComplexSelector:function(e,t,n){var r=!1,s=!1,a=this;return e=e.trim(
),e=this._slottedToContent(e),e=e.replace(c,":host > *"),e=e.replace(P,l+" $1"),
e=e.replace(o,function(e,i,o){if(r)o=o.replace(_," ");else{var l=a._transformCom
poundSelector(o,i,t,n);r=r||l.stop,s=s||l.hostContext,i=l.combinator,o=l.value}r
eturn i+o}),s&&(e=e.replace(f,function(e,t,r,s){return t+r+" "+n+s+i+" "+t+n+r+s
})),e},_transformCompoundSelector:function(e,t,n,r){var s=e.search(_),i=!1;e.ind
exOf(u)>=0?i=!0:e.indexOf(l)>=0?e=this._transformHostSelector(e,r):0!==s&&(e=n?t
his._transformSimpleSelector(e,n):e),e.indexOf(p)>=0&&(t="");var o;return s>=0&&
(e=e.replace(_," "),o=!0),{value:e,combinator:t,stop:o,hostContext:i}},_transfor
mSimpleSelector:function(e,t){var n=e.split(v);return n[0]+=t,n.join(v)},_transf
ormHostSelector:function(e,t){var n=e.match(h),r=n&&n[2].trim()||"";if(r){if(r[0
].match(a))return e.replace(h,function(e,n,r){return t+r});var s=r.split(a)[0];r
eturn s===t?r:S}return e.replace(l,t)},documentRule:function(e){e.selector=e.par
sedSelector,this.normalizeRootSelector(e),t.useNativeShadow||this._transformRule
(e,this._transformDocumentSelector)},normalizeRootSelector:function(e){e.selecto
r=e.selector.replace(c,"html")},_transformDocumentSelector:function(e){return e.
match(_)?this._transformComplexSelector(e,s):this._transformSimpleSelector(e.tri
m(),s)},_slottedToContent:function(e){return e.replace(C,p+"> $1")},SCOPE_NAME:"
style-scope"},r=n.SCOPE_NAME,s=":not(["+r+"]):not(."+r+")",i=",",o=/(^|[\s>+~]+)
((?:\[.+?\]|[^\s>+~=\[])+)/g,a=/[[.:#*]/,l=":host",c=":root",h=/(:host)(?:\(((?:
\([^)(]*\)|[^)(]*)+?)\))/,u=":host-context",f=/(.*)(?::host-context)(?:\(((?:\([
^)(]*\)|[^)(]*)+?)\))(.*)/,p="::content",_=/::content|::shadow|\/deep\//,d=".",m
="["+r+"~=",y="]",v=":",g="class",P=new RegExp("^("+p+")"),S="should_not_match",
C=/(?:::slotted)(?:\(((?:\([^)(]*\)|[^)(]*)+?)\))/g;return n}(),Polymer.StyleExt
ends=function(){var e=Polymer.StyleUtil;return{hasExtends:function(e){return Boo
lean(e.match(this.rx.EXTEND))},transform:function(t){var n=e.rulesForStyle(t),r=
this;return e.forEachRule(n,function(e){if(r._mapRuleOntoParent(e),e.parent)for(
var t;t=r.rx.EXTEND.exec(e.cssText);){var n=t[1],s=r._findExtendor(n,e);s&&r._ex
tendRule(e,s)}e.cssText=e.cssText.replace(r.rx.EXTEND,"")}),e.toCssText(n,functi
on(e){e.selector.match(r.rx.STRIP)&&(e.cssText="")},!0)},_mapRuleOntoParent:func
tion(e){if(e.parent){for(var t,n=e.parent.map||(e.parent.map={}),r=e.selector.sp
lit(","),s=0;s<r.length;s++)t=r[s],n[t.trim()]=e;return n}},_findExtendor:functi
on(e,t){return t.parent&&t.parent.map&&t.parent.map[e]||this._findExtendor(e,t.p
arent)},_extendRule:function(e,t){e.parent!==t.parent&&this._cloneAndAddRuleToPa
rent(t,e.parent),e.extends=e.extends||[],e.extends.push(t),t.selector=t.selector
.replace(this.rx.STRIP,""),t.selector=(t.selector&&t.selector+",\n")+e.selector,
t.extends&&t.extends.forEach(function(t){this._extendRule(e,t)},this)},_cloneAnd
AddRuleToParent:function(e,t){e=Object.create(e),e.parent=t,e.extends&&(e.extend
s=e.extends.slice()),t.rules.push(e)},rx:{EXTEND:/@extends\(([^)]*)\)\s*?;/gim,S
TRIP:/%[^,]*$/}}}(),Polymer.ApplyShim=function(){"use strict";function e(e,t){e=
e.trim(),m[e]={properties:t,dependants:{}}}function t(e){return e=e.trim(),m[e]}
function n(e,t){var n=_.exec(t);return n&&(t=n[1]?y._getInitialValueForProperty(
e):"apply-shim-inherit"),t}function r(e){for(var t,r,s,i,o=e.split(";"),a={},l=0
;l<o.length;l++)s=o[l],s&&(i=s.split(":"),i.length>1&&(t=i[0].trim(),r=n(t,i.sli
ce(1).join(":")),a[t]=r));return a}function s(e){var t=y.__currentElementProto,n
=t&&t.is;for(var r in e.dependants)r!==n&&(e.dependants[r].__applyShimInvalid=!0
)}function i(n,i,o,a){if(o&&c.processVariableAndFallback(o,function(e,n){n&&t(n)
&&(a="@apply "+n+";")}),!a)return n;var h=l(a),u=n.slice(0,n.indexOf("--")),f=r(
h),p=f,_=t(i),m=_&&_.properties;m?(p=Object.create(m),p=Polymer.Base.mixin(p,f))
:e(i,p);var y,v,g=[],P=!1;for(y in p)v=f[y],void 0===v&&(v="initial"),!m||y in m
||(P=!0),g.push(i+d+y+": "+v);return P&&s(_),_&&(_.properties=p),o&&(u=n+";"+u),
u+g.join("; ")+";"}function o(e,t,n){return"var("+t+",var("+n+"))"}function a(n,
r){n=n.replace(p,"");var s=[],i=t(n);if(i||(e(n,{}),i=t(n)),i){var o=y.__current
ElementProto;o&&(i.dependants[o.is]=o);var a,l,c;for(a in i.properties)c=r&&r[a]
,l=[a,": var(",n,d,a],c&&l.push(",",c),l.push(")"),s.push(l.join(""))}return s.j
oin("; ")}function l(e){for(var t;t=h.exec(e);){var n=t[0],s=t[1],i=t.index,o=i+
n.indexOf("@apply"),l=i+n.length,c=e.slice(0,o),u=e.slice(l),f=r(c),p=a(s,f);e=[
c,p,u].join(""),h.lastIndex=i+p.length}return e}var c=Polymer.StyleUtil,h=c.rx.M
IXIN_MATCH,u=c.rx.VAR_ASSIGN,f=/var\(\s*(--[^,]*),\s*(--[^)]*)\)/g,p=/;\s*/m,_=/
^\s*(initial)|(inherit)\s*$/,d="_-_",m={},y={_measureElement:null,_map:m,_separa
tor:d,transform:function(e,t){this.__currentElementProto=t,c.forRulesInStyles(e,
this._boundFindDefinitions),c.forRulesInStyles(e,this._boundFindApplications),t&
&(t.__applyShimInvalid=!1),this.__currentElementProto=null},_findDefinitions:fun
ction(e){var t=e.parsedCssText;t=t.replace(f,o),t=t.replace(u,i),e.cssText=t,":r
oot"===e.selector&&(e.selector=":host > *")},_findApplications:function(e){e.css
Text=l(e.cssText)},transformRule:function(e){this._findDefinitions(e),this._find
Applications(e)},_getInitialValueForProperty:function(e){return this._measureEle
ment||(this._measureElement=document.createElement("meta"),this._measureElement.
style.all="initial",document.head.appendChild(this._measureElement)),window.getC
omputedStyle(this._measureElement).getPropertyValue(e)}};return y._boundTransfor
mRule=y.transformRule.bind(y),y._boundFindDefinitions=y._findDefinitions.bind(y)
,y._boundFindApplications=y._findApplications.bind(y),y}(),function(){var e=Poly
mer.Base._prepElement,t=Polymer.Settings.useNativeShadow,n=Polymer.StyleUtil,r=P
olymer.StyleTransformer,s=Polymer.StyleExtends,i=Polymer.ApplyShim,o=Polymer.Set
tings;Polymer.Base._addFeature({_prepElement:function(t){this._encapsulateStyle&
&"shady"!==this.__cssBuild&&r.element(t,this.is,this._scopeCssViaAttr),e.call(th
is,t)},_prepStyles:function(){void 0===this._encapsulateStyle&&(this._encapsulat
eStyle=!t),t||(this._scopeStyle=n.applyStylePlaceHolder(this.is)),this.__cssBuil
d=n.cssBuildTypeForModule(this.is)},_prepShimStyles:function(){if(this._template
){var e=n.isTargetedBuild(this.__cssBuild);if(o.useNativeCSSProperties&&"shadow"
===this.__cssBuild&&e)return;this._styles=this._styles||this._collectStyles(),o.
useNativeCSSProperties&&!this.__cssBuild&&i.transform(this._styles,this);var s=o
.useNativeCSSProperties&&e?this._styles.length&&this._styles[0].textContent.trim
():r.elementStyles(this);this._prepStyleProperties(),!this._needsStyleProperties
()&&s&&n.applyCss(s,this.is,t?this._template.content:null,this._scopeStyle)}else
this._styles=[]},_collectStyles:function(){var e=[],t="",r=this.styleModules;if
(r)for(var i,o=0,a=r.length;o<a&&(i=r[o]);o++)t+=n.cssFromModule(i);t+=n.cssFrom
Module(this.is);var l=this._template&&this._template.parentNode;if(!this._templa
te||l&&l.id.toLowerCase()===this.is||(t+=n.cssFromElement(this._template)),t){va
r c=document.createElement("style");c.textContent=t,s.hasExtends(c.textContent)&
&(t=s.transform(c)),e.push(c)}return e},_elementAdd:function(e){this._encapsulat
eStyle&&(e.__styleScoped?e.__styleScoped=!1:r.dom(e,this.is,this._scopeCssViaAtt
r))},_elementRemove:function(e){this._encapsulateStyle&&r.dom(e,this.is,this._sc
opeCssViaAttr,!0)},scopeSubtree:function(e,n){if(!t){var r=this,s=function(e){if
(e.nodeType===Node.ELEMENT_NODE){var t=e.getAttribute("class");e.setAttribute("c
lass",r._scopeElementClass(e,t));for(var n,s=e.querySelectorAll("*"),i=0;i<s.len
gth&&(n=s[i]);i++)t=n.getAttribute("class"),n.setAttribute("class",r._scopeEleme
ntClass(n,t))}};if(s(e),n){var i=new MutationObserver(function(e){for(var t,n=0;
n<e.length&&(t=e[n]);n++)if(t.addedNodes)for(var r=0;r<t.addedNodes.length;r++)s
(t.addedNodes[r])});return i.observe(e,{childList:!0,subtree:!0}),i}}}})}(),Poly
mer.StyleProperties=function(){"use strict";function e(e,t){var n=parseInt(e/32)
,r=1<<e%32;t[n]=(t[n]||0)|r}var t=Polymer.DomApi.matchesSelector,n=Polymer.Style
Util,r=Polymer.StyleTransformer,s=navigator.userAgent.match("Trident"),i=Polymer
.Settings;return{decorateStyles:function(e,t){var s=this,i={},o=[],a=0,l=r._calc
HostScope(t.is,t.extends);n.forRulesInStyles(e,function(e,r){s.decorateRule(e),e
.index=a++,s.whenHostOrRootRule(t,e,r,function(r){if(e.parent.type===n.ruleTypes
.MEDIA_RULE&&(t.__notStyleScopeCacheable=!0),r.isHost){var s=r.selector.split("
").some(function(e){return 0===e.indexOf(l)&&e.length!==l.length});t.__notStyleS
copeCacheable=t.__notStyleScopeCacheable||s}}),s.collectPropertiesInCssText(e.pr
opertyInfo.cssText,i)},function(e){o.push(e)}),e._keyframes=o;var c=[];for(var h
in i)c.push(h);return c},decorateRule:function(e){if(e.propertyInfo)return e.pr
opertyInfo;var t={},n={},r=this.collectProperties(e,n);return r&&(t.properties=n
,e.rules=null),t.cssText=this.collectCssText(e),e.propertyInfo=t,t},collectPrope
rties:function(e,t){var n=e.propertyInfo;if(!n){for(var r,s,i,o=this.rx.VAR_ASSI
GN,a=e.parsedCssText;r=o.exec(a);)s=(r[2]||r[3]).trim(),"inherit"!==s&&(t[r[1].t
rim()]=s),i=!0;return i}if(n.properties)return Polymer.Base.mixin(t,n.properties
),!0},collectCssText:function(e){return this.collectConsumingCssText(e.parsedCss
Text)},collectConsumingCssText:function(e){return e.replace(this.rx.BRACKETED,""
).replace(this.rx.VAR_ASSIGN,"")},collectPropertiesInCssText:function(e,t){for(v
ar n;n=this.rx.VAR_CONSUMED.exec(e);){var r=n[1];":"!==n[2]&&(t[r]=!0)}},reify:f
unction(e){for(var t,n=Object.getOwnPropertyNames(e),r=0;r<n.length;r++)t=n[r],e
[t]=this.valueForProperty(e[t],e)},valueForProperty:function(e,t){if(e)if(e.inde
xOf(";")>=0)e=this.valueForProperties(e,t);else{var r=this,s=function(e,n,s,i){v
ar o=r.valueForProperty(t[n],t);return o&&"initial"!==o?"apply-shim-inherit"===o
&&(o="inherit"):o=r.valueForProperty(t[s]||s,t)||s,e+(o||"")+i};e=n.processVaria
bleAndFallback(e,s)}return e&&e.trim()||""},valueForProperties:function(e,t){for
(var n,r,s=e.split(";"),i=0;i<s.length;i++)if(n=s[i]){if(this.rx.MIXIN_MATCH.las
tIndex=0,r=this.rx.MIXIN_MATCH.exec(n))n=this.valueForProperty(t[r[1]],t);else{v
ar o=n.indexOf(":");if(o!==-1){var a=n.substring(o);a=a.trim(),a=this.valueForPr
operty(a,t)||a,n=n.substring(0,o)+a}}s[i]=n&&n.lastIndexOf(";")===n.length-1?n.s
lice(0,-1):n||""}return s.join(";")},applyProperties:function(e,t){var n="";e.pr
opertyInfo||this.decorateRule(e),e.propertyInfo.cssText&&(n=this.valueForPropert
ies(e.propertyInfo.cssText,t)),e.cssText=n},applyKeyframeTransforms:function(e,t
){var n=e.cssText,r=e.cssText;if(null==e.hasAnimations&&(e.hasAnimations=this.rx
.ANIMATION_MATCH.test(n)),e.hasAnimations){var s;if(null==e.keyframeNamesToTrans
form){e.keyframeNamesToTransform=[];for(var i in t)s=t[i],r=s(n),n!==r&&(n=r,e.k
eyframeNamesToTransform.push(i))}else{for(var o=0;o<e.keyframeNamesToTransform.l
ength;++o)s=t[e.keyframeNamesToTransform[o]],n=s(n);r=n}}e.cssText=r},propertyDa
taFromStyles:function(r,s){var i={},o=this,a=[];return n.forActiveRulesInStyles(
r,function(n){n.propertyInfo||o.decorateRule(n);var r=n.transformedSelector||n.p
arsedSelector;s&&n.propertyInfo.properties&&r&&t.call(s,r)&&(o.collectProperties
(n,i),e(n.index,a))}),{properties:i,key:a}},_rootSelector:/:root|:host\s*>\s*\*/
,_checkRoot:function(e,t){return Boolean(t.match(this._rootSelector))||"html"===
e&&t.indexOf("html")>-1},whenHostOrRootRule:function(e,t,n,s){if(t.propertyInfo|
|self.decorateRule(t),t.propertyInfo.properties){var o=e.is?r._calcHostScope(e.i
s,e.extends):"html",a=t.parsedSelector,l=this._checkRoot(o,a),c=!l&&0===a.indexO
f(":host"),h=e.__cssBuild||n.__cssBuild;if("shady"===h&&(l=a===o+" > *."+o||a.in
dexOf("html")>-1,c=!l&&0===a.indexOf(o)),l||c){var u=o;c&&(i.useNativeShadow&&!t
.transformedSelector&&(t.transformedSelector=r._transformRuleCss(t,r._transformC
omplexSelector,e.is,o)),u=t.transformedSelector||t.parsedSelector),l&&"html"===o
&&(u=t.transformedSelector||t.parsedSelector),s({selector:u,isHost:c,isRoot:l})}
}},hostAndRootPropertiesForScope:function(e){var r={},s={},i=this;return n.forAc
tiveRulesInStyles(e._styles,function(n,o){i.whenHostOrRootRule(e,n,o,function(o)
{var a=e._element||e;t.call(a,o.selector)&&(o.isHost?i.collectProperties(n,r):i.
collectProperties(n,s))})}),{rootProps:s,hostProps:r}},transformStyles:function(
e,t,n){var s=this,o=r._calcHostScope(e.is,e.extends),a=e.extends?"\\"+o.slice(0,
-1)+"\\]":o,l=new RegExp(this.rx.HOST_PREFIX+a+this.rx.HOST_SUFFIX),c=this._elem
entKeyframeTransforms(e,n);return r.elementStyles(e,function(r){s.applyPropertie
s(r,t),i.useNativeShadow||Polymer.StyleUtil.isKeyframesSelector(r)||!r.cssText||
(s.applyKeyframeTransforms(r,c),s._scopeSelector(r,l,o,e._scopeCssViaAttr,n))})}
,_elementKeyframeTransforms:function(e,t){var n=e._styles._keyframes,r={};if(!i.
useNativeShadow&&n)for(var s=0,o=n[s];s<n.length;o=n[++s])this._scopeKeyframes(o
,t),r[o.keyframesName]=this._keyframesRuleTransformer(o);return r},_keyframesRul
eTransformer:function(e){return function(t){return t.replace(e.keyframesNameRx,e
.transformedKeyframesName)}},_scopeKeyframes:function(e,t){e.keyframesNameRx=new
RegExp(e.keyframesName,"g"),e.transformedKeyframesName=e.keyframesName+"-"+t,e.
transformedSelector=e.transformedSelector||e.selector,e.selector=e.transformedSe
lector.replace(e.keyframesName,e.transformedKeyframesName)},_scopeSelector:funct
ion(e,t,n,s,i){e.transformedSelector=e.transformedSelector||e.selector;for(var o
,a=e.transformedSelector,l=s?"["+r.SCOPE_NAME+"~="+i+"]":"."+i,c=a.split(","),h=
0,u=c.length;h<u&&(o=c[h]);h++)c[h]=o.match(t)?o.replace(n,l):l+" "+o;e.selector
=c.join(",")},applyElementScopeSelector:function(e,t,n,s){var i=s?e.getAttribute
(r.SCOPE_NAME):e.getAttribute("class")||"",o=n?i.replace(n,t):(i?i+" ":"")+this.
XSCOPE_NAME+" "+t;i!==o&&(s?e.setAttribute(r.SCOPE_NAME,o):e.setAttribute("class
",o))},applyElementStyle:function(e,t,r,o){var a=o?o.textContent||"":this.transf
ormStyles(e,t,r),l=e._customStyle;return l&&!i.useNativeShadow&&l!==o&&(l._useCo
unt--,l._useCount<=0&&l.parentNode&&l.parentNode.removeChild(l)),i.useNativeShad
ow?e._customStyle?(e._customStyle.textContent=a,o=e._customStyle):a&&(o=n.applyC
ss(a,r,e.root,e._scopeStyle)):o?o.parentNode||(s&&a.indexOf("@media")>-1&&(o.tex
tContent=a),n.applyStyle(o,null,e._scopeStyle)):a&&(o=n.applyCss(a,r,null,e._sco
peStyle)),o&&(o._useCount=o._useCount||0,e._customStyle!=o&&o._useCount++,e._cus
tomStyle=o),o},mixinCustomStyle:function(e,t){var n;for(var r in t)n=t[r],(n||0=
==n)&&(e[r]=n)},updateNativeStyleProperties:function(e,t){var n=e.__customStyleP
roperties;if(n)for(var r=0;r<n.length;r++)e.style.removeProperty(n[r]);var s=[];
for(var i in t)null!==t[i]&&(e.style.setProperty(i,t[i]),s.push(i));e.__customSt
yleProperties=s},rx:n.rx,XSCOPE_NAME:"x-scope"}}(),function(){Polymer.StyleCache
=function(){this.cache={}},Polymer.StyleCache.prototype={MAX:100,store:function(
e,t,n,r){t.keyValues=n,t.styles=r;var s=this.cache[e]=this.cache[e]||[];s.push(t
),s.length>this.MAX&&s.shift()},retrieve:function(e,t,n){var r=this.cache[e];if(
r)for(var s,i=r.length-1;i>=0;i--)if(s=r[i],n===s.styles&&this._objectsEqual(t,s
.keyValues))return s},clear:function(){this.cache={}},_objectsEqual:function(e,t
){var n,r;for(var s in e)if(n=e[s],r=t[s],!("object"==typeof n&&n?this._objectsS
trictlyEqual(n,r):n===r))return!1;return!Array.isArray(e)||e.length===t.length},
_objectsStrictlyEqual:function(e,t){return this._objectsEqual(e,t)&&this._object
sEqual(t,e)}}}(),Polymer.StyleDefaults=function(){var e=Polymer.StyleProperties,
t=Polymer.StyleCache,n=Polymer.Settings.useNativeCSSProperties,r={_styles:[],_pr
operties:null,customStyle:{},_styleCache:new t,_element:Polymer.DomApi.wrap(docu
ment.documentElement),addStyle:function(e){this._styles.push(e),this._properties
=null},get _styleProperties(){return this._properties||(e.decorateStyles(this._s
tyles,this),this._styles._scopeStyleProperties=null,this._properties=e.hostAndRo
otPropertiesForScope(this).rootProps,e.mixinCustomStyle(this._properties,this.cu
stomStyle),e.reify(this._properties)),this._properties},hasStyleProperties:funct
ion(){return Boolean(this._properties)},_needsStyleProperties:function(){},_comp
uteStyleProperties:function(){return this._styleProperties},updateStyles:functio
n(t){this._properties=null,t&&Polymer.Base.mixin(this.customStyle,t),this._style
Cache.clear();for(var r,s=0;s<this._styles.length;s++)r=this._styles[s],r=r.__im
portElement||r,r._apply();n&&e.updateNativeStyleProperties(document.documentElem
ent,this.customStyle)}};return r}(),function(){"use strict";var e=Polymer.Base.s
erializeValueToAttribute,t=Polymer.StyleProperties,n=Polymer.StyleTransformer,r=
Polymer.StyleDefaults,s=Polymer.Settings.useNativeShadow,i=Polymer.Settings.useN
ativeCSSProperties;Polymer.Base._addFeature({_prepStyleProperties:function(){i||
(this._ownStylePropertyNames=this._styles&&this._styles.length?t.decorateStyles(
this._styles,this):null); | 3 delete this[t])},_configureProperties:function(e,t){for(var n in e){var r=e[n];i
f(void 0!==r.value){var s=r.value;"function"==typeof s&&(s=s.call(this,this._con
fig)),t[n]=s}}},_distributeConfig:function(e){var t=this._propertyEffects;if(t)f
or(var n in e){var r=t[n];if(r)for(var s,i=0,o=r.length;i<o&&(s=r[i]);i++)if("an
notation"===s.kind){var a=this._nodes[s.effect.index],l=s.effect.propertyName,c=
"attribute"==s.effect.kind,h=a._propertyEffects&&a._propertyEffects[l];if(a._con
figValue&&(h||!c)){var u=n===s.effect.value?e[n]:this._get(s.effect.value,e);u=t
his._computeFinalAnnotationValue(a,l,u,s.effect),c&&(u=a.deserialize(this.serial
ize(u),a._propertyInfo[l].type)),a._configValue(l,u)}}}},_afterClientsReady:func
tion(){this._executeStaticEffects(),this._applyConfig(this._config,this._aboveCo
nfig),this._flushHandlers()},_applyConfig:function(e,t){for(var n in e)void 0===
this[n]&&this.__setProperty(n,e[n],n in t)},_notifyListener:function(e,t){if(!Po
lymer.Bind._isEventBogus(t,t.target)){var n,r;if(t.detail&&(n=t.detail.value,r=t
.detail.path),this._clientsReadied)return e.call(this,t.target,n,r);this._queueH
andler([e,t.target,n,r])}},_queueHandler:function(e){this._handlers.push(e)},_fl
ushHandlers:function(){for(var e,t=this._handlers,n=0,r=t.length;n<r&&(e=t[n]);n
++)e[0].call(this,e[1],e[2],e[3]);this._handlers=[]}})}(),function(){"use strict
";var e=Polymer.Path;Polymer.Base._addFeature({notifyPath:function(e,t,n){var r=
{},s=this._get(e,this,r);1===arguments.length&&(t=s),r.path&&this._notifyPath(r.
path,t,n)},_notifyPath:function(e,t,n){var r=this._propertySetter(e,t);if(r!==t&
&(r===r||t===t))return this._pathEffector(e,t),n||this._notifyPathUp(e,t),!0},_g
etPathParts:function(e){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++)for
(var r=e[n].toString().split("."),s=0;s<r.length;s++)t.push(r[s]);return t}retur
n e.toString().split(".")},set:function(e,t,n){var r,s=n||this,i=this._getPathPa
rts(e),o=i[i.length-1];if(i.length>1){for(var a=0;a<i.length-1;a++){var l=i[a];i
f(r&&"#"==l[0]?s=Polymer.Collection.get(r).getItem(l):(s=s[l],r&&parseInt(l,10)=
=l&&(i[a]=Polymer.Collection.get(r).getKey(s))),!s)return;r=Array.isArray(s)?s:n
ull}if(r){var c,h,u=Polymer.Collection.get(r);"#"==o[0]?(h=o,c=u.getItem(h),o=r.
indexOf(c),u.setItem(h,t)):parseInt(o,10)==o&&(c=s[o],h=u.getKey(c),i[a]=h,u.set
Item(h,t))}s[o]=t,n||this._notifyPath(i.join("."),t)}else s[e]=t},get:function(e
,t){return this._get(e,t)},_get:function(e,t,n){for(var r,s=t||this,i=this._getP
athParts(e),o=0;o<i.length;o++){if(!s)return;var a=i[o];r&&"#"==a[0]?s=Polymer.C
ollection.get(r).getItem(a):(s=s[a],n&&r&&parseInt(a,10)==a&&(i[o]=Polymer.Colle
ction.get(r).getKey(s))),r=Array.isArray(s)?s:null}return n&&(n.path=i.join(".")
),s},_pathEffector:function(t,n){var r=e.root(t),s=this._propertyEffects&&this._
propertyEffects[r];if(s)for(var i,o=0;o<s.length&&(i=s[o]);o++){var a=i.pathFn;a
&&a.call(this,t,n,i.effect)}this._boundPaths&&this._notifyBoundPaths(t,n)},_anno
tationPathEffect:function(t,n,r){if(e.matches(r.value,!1,t))Polymer.Bind._annota
tionEffect.call(this,t,n,r);else if(!r.negate&&e.isDescendant(r.value,t)){var s=
this._nodes[r.index];if(s&&s._notifyPath){var i=e.translate(r.value,r.name,t);s.
_notifyPath(i,n,!0)}}},_complexObserverPathEffect:function(t,n,r){e.matches(r.tr
igger.name,r.trigger.wildcard,t)&&Polymer.Bind._complexObserverEffect.call(this,
t,n,r)},_computePathEffect:function(t,n,r){e.matches(r.trigger.name,r.trigger.wi
ldcard,t)&&Polymer.Bind._computeEffect.call(this,t,n,r)},_annotatedComputationPa
thEffect:function(t,n,r){e.matches(r.trigger.name,r.trigger.wildcard,t)&&Polymer
.Bind._annotatedComputationEffect.call(this,t,n,r)},linkPaths:function(e,t){this
._boundPaths=this._boundPaths||{},t?this._boundPaths[e]=t:this.unlinkPaths(e)},u
nlinkPaths:function(e){this._boundPaths&&delete this._boundPaths[e]},_notifyBoun
dPaths:function(t,n){for(var r in this._boundPaths){var s=this._boundPaths[r];e.
isDescendant(r,t)?this._notifyPath(e.translate(r,s,t),n):e.isDescendant(s,t)&&th
is._notifyPath(e.translate(s,r,t),n)}},_notifyPathUp:function(t,n){var r=e.root(
t),s=Polymer.CaseMap.camelToDashCase(r),i=s+this._EVENT_CHANGED;this.fire(i,{pat
h:t,value:n},{bubbles:!1,_useCache:!0})},_EVENT_CHANGED:"-changed",notifySplices
:function(e,t){var n={},r=this._get(e,this,n);this._notifySplices(r,n.path,t)},_
notifySplices:function(e,t,n){var r={keySplices:Polymer.Collection.applySplices(
e,n),indexSplices:n},s=t+".splices";this._notifyPath(s,r),this._notifyPath(t+".l
ength",e.length),this.__data__[s]={keySplices:null,indexSplices:null}},_notifySp
lice:function(e,t,n,r,s){this._notifySplices(e,t,[{index:n,addedCount:r,removed:
s,object:e,type:"splice"}])},push:function(e){var t={},n=this._get(e,this,t),r=A
rray.prototype.slice.call(arguments,1),s=n.length,i=n.push.apply(n,r);return r.l
ength&&this._notifySplice(n,t.path,s,r.length,[]),i},pop:function(e){var t={},n=
this._get(e,this,t),r=Boolean(n.length),s=Array.prototype.slice.call(arguments,1
),i=n.pop.apply(n,s);return r&&this._notifySplice(n,t.path,n.length,0,[i]),i},sp
lice:function(e,t){var n={},r=this._get(e,this,n);t=t<0?r.length-Math.floor(-t):
Math.floor(t),t||(t=0);var s=Array.prototype.slice.call(arguments,1),i=r.splice.
apply(r,s),o=Math.max(s.length-2,0);return(o||i.length)&&this._notifySplice(r,n.
path,t,o,i),i},shift:function(e){var t={},n=this._get(e,this,t),r=Boolean(n.leng
th),s=Array.prototype.slice.call(arguments,1),i=n.shift.apply(n,s);return r&&thi
s._notifySplice(n,t.path,0,0,[i]),i},unshift:function(e){var t={},n=this._get(e,
this,t),r=Array.prototype.slice.call(arguments,1),s=n.unshift.apply(n,r);return
r.length&&this._notifySplice(n,t.path,0,r.length,[]),s},prepareModelNotifyPath:f
unction(e){this.mixin(e,{fire:Polymer.Base.fire,_getEvent:Polymer.Base._getEvent
,__eventCache:Polymer.Base.__eventCache,notifyPath:Polymer.Base.notifyPath,_get:
Polymer.Base._get,_EVENT_CHANGED:Polymer.Base._EVENT_CHANGED,_notifyPath:Polymer
.Base._notifyPath,_notifyPathUp:Polymer.Base._notifyPathUp,_pathEffector:Polymer
.Base._pathEffector,_annotationPathEffect:Polymer.Base._annotationPathEffect,_co
mplexObserverPathEffect:Polymer.Base._complexObserverPathEffect,_annotatedComput
ationPathEffect:Polymer.Base._annotatedComputationPathEffect,_computePathEffect:
Polymer.Base._computePathEffect,_notifyBoundPaths:Polymer.Base._notifyBoundPaths
,_getPathParts:Polymer.Base._getPathParts})}})}(),Polymer.Base._addFeature({reso
lveUrl:function(e){var t=Polymer.DomModule.import(this.is),n="";if(t){var r=t.ge
tAttribute("assetpath")||"";n=Polymer.ResolveUrl.resolveUrl(r,t.ownerDocument.ba
seURI)}return Polymer.ResolveUrl.resolveUrl(e,n)}}),Polymer.CssParse=function(){
return{parse:function(e){return e=this._clean(e),this._parseCss(this._lex(e),e)}
,_clean:function(e){return e.replace(this._rx.comments,"").replace(this._rx.port
,"")},_lex:function(e){for(var t={start:0,end:e.length},n=t,r=0,s=e.length;r<s;r
++)switch(e[r]){case this.OPEN_BRACE:n.rules||(n.rules=[]);var i=n,o=i.rules[i.r
ules.length-1];n={start:r+1,parent:i,previous:o},i.rules.push(n);break;case this
.CLOSE_BRACE:n.end=r+1,n=n.parent||t}return t},_parseCss:function(e,t){var n=t.s
ubstring(e.start,e.end-1);if(e.parsedCssText=e.cssText=n.trim(),e.parent){var r=
e.previous?e.previous.end:e.parent.start;n=t.substring(r,e.start-1),n=this._expa
ndUnicodeEscapes(n),n=n.replace(this._rx.multipleSpaces," "),n=n.substring(n.las
tIndexOf(";")+1);var s=e.parsedSelector=e.selector=n.trim();e.atRule=0===s.index
Of(this.AT_START),e.atRule?0===s.indexOf(this.MEDIA_START)?e.type=this.types.MED
IA_RULE:s.match(this._rx.keyframesRule)&&(e.type=this.types.KEYFRAMES_RULE,e.key
framesName=e.selector.split(this._rx.multipleSpaces).pop()):0===s.indexOf(this.V
AR_START)?e.type=this.types.MIXIN_RULE:e.type=this.types.STYLE_RULE}var i=e.rule
s;if(i)for(var o,a=0,l=i.length;a<l&&(o=i[a]);a++)this._parseCss(o,t);return e},
_expandUnicodeEscapes:function(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,funct
ion(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return"\\"+e})},stringify
:function(e,t,n){n=n||"";var r="";if(e.cssText||e.rules){var s=e.rules;if(s&&!th
is._hasMixinRules(s))for(var i,o=0,a=s.length;o<a&&(i=s[o]);o++)r=this.stringify
(i,t,r);else r=t?e.cssText:this.removeCustomProps(e.cssText),r=r.trim(),r&&(r="
"+r+"\n")}return r&&(e.selector&&(n+=e.selector+" "+this.OPEN_BRACE+"\n"),n+=r,
e.selector&&(n+=this.CLOSE_BRACE+"\n\n")),n},_hasMixinRules:function(e){return 0
===e[0].selector.indexOf(this.VAR_START)},removeCustomProps:function(e){return e
=this.removeCustomPropAssignment(e),this.removeCustomPropApply(e)},removeCustomP
ropAssignment:function(e){return e.replace(this._rx.customProp,"").replace(this.
_rx.mixinProp,"")},removeCustomPropApply:function(e){return e.replace(this._rx.m
ixinApply,"").replace(this._rx.varApply,"")},types:{STYLE_RULE:1,KEYFRAMES_RULE:
7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE:"{",CLOSE_BRACE:"}",_rx:{comments:/\/\
*[^*]*\*+([^\/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s
}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^
{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/
gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*
keyframes/,multipleSpaces:/\s+/g},VAR_START:"--",MEDIA_START:"@media",AT_START:"
@"}}(),Polymer.StyleUtil=function(){var e=Polymer.Settings;return{NATIVE_VARIABL
ES:Polymer.Settings.useNativeCSSProperties,MODULE_STYLES_SELECTOR:"style, link[r
el=import][type~=css], template",INCLUDE_ATTR:"include",toCssText:function(e,t){
return"string"==typeof e&&(e=this.parser.parse(e)),t&&this.forEachRule(e,t),this
.parser.stringify(e,this.NATIVE_VARIABLES)},forRulesInStyles:function(e,t,n){if(
e)for(var r,s=0,i=e.length;s<i&&(r=e[s]);s++)this.forEachRuleInStyle(r,t,n)},for
ActiveRulesInStyles:function(e,t,n){if(e)for(var r,s=0,i=e.length;s<i&&(r=e[s]);
s++)this.forEachRuleInStyle(r,t,n,!0)},rulesForStyle:function(e){return!e.__cssR
ules&&e.textContent&&(e.__cssRules=this.parser.parse(e.textContent)),e.__cssRule
s},isKeyframesSelector:function(e){return e.parent&&e.parent.type===this.ruleTyp
es.KEYFRAMES_RULE},forEachRuleInStyle:function(e,t,n,r){var s,i,o=this.rulesForS
tyle(e);t&&(s=function(n){t(n,e)}),n&&(i=function(t){n(t,e)}),this.forEachRule(o
,s,i,r)},forEachRule:function(e,t,n,r){if(e){var s=!1;if(r&&e.type===this.ruleTy
pes.MEDIA_RULE){var i=e.selector.match(this.rx.MEDIA_MATCH);i&&(window.matchMedi
a(i[1]).matches||(s=!0))}e.type===this.ruleTypes.STYLE_RULE?t(e):n&&e.type===thi
s.ruleTypes.KEYFRAMES_RULE?n(e):e.type===this.ruleTypes.MIXIN_RULE&&(s=!0);var o
=e.rules;if(o&&!s)for(var a,l=0,c=o.length;l<c&&(a=o[l]);l++)this.forEachRule(a,
t,n,r)}},applyCss:function(e,t,n,r){var s=this.createScopeStyle(e,t);return this
.applyStyle(s,n,r)},applyStyle:function(e,t,n){t=t||document.head;var r=n&&n.nex
tSibling||t.firstChild;return this.__lastHeadApplyNode=e,t.insertBefore(e,r)},cr
eateScopeStyle:function(e,t){var n=document.createElement("style");return t&&n.s
etAttribute("scope",t),n.textContent=e,n},__lastHeadApplyNode:null,applyStylePla
ceHolder:function(e){var t=document.createComment(" Shady DOM styles for "+e+" "
),n=this.__lastHeadApplyNode?this.__lastHeadApplyNode.nextSibling:null,r=documen
t.head;return r.insertBefore(t,n||r.firstChild),this.__lastHeadApplyNode=t,t},cs
sFromModules:function(e,t){for(var n=e.trim().split(" "),r="",s=0;s<n.length;s++
)r+=this.cssFromModule(n[s],t);return r},cssFromModule:function(e,t){var n=Polym
er.DomModule.import(e);return n&&!n._cssText&&(n._cssText=this.cssFromElement(n)
),!n&&t&&console.warn("Could not find style data in module named",e),n&&n._cssTe
xt||""},cssFromElement:function(e){for(var t,n="",r=e.content||e,s=Polymer.TreeA
pi.arrayCopy(r.querySelectorAll(this.MODULE_STYLES_SELECTOR)),i=0;i<s.length;i++
)if(t=s[i],"template"===t.localName)t.hasAttribute("preserve-content")||(n+=this
.cssFromElement(t));else if("style"===t.localName){var o=t.getAttribute(this.INC
LUDE_ATTR);o&&(n+=this.cssFromModules(o,!0)),t=t.__appliedElement||t,t.parentNod
e.removeChild(t),n+=this.resolveCss(t.textContent,e.ownerDocument)}else t.import
&&t.import.body&&(n+=this.resolveCss(t.import.body.textContent,t.import));return
n},isTargetedBuild:function(t){return e.useNativeShadow?"shadow"===t:"shady"===
t},cssBuildTypeForModule:function(e){var t=Polymer.DomModule.import(e);if(t)retu
rn this.getCssBuildType(t)},getCssBuildType:function(e){return e.getAttribute("c
ss-build")},_findMatchingParen:function(e,t){for(var n=0,r=t,s=e.length;r<s;r++)
switch(e[r]){case"(":n++;break;case")":if(0===--n)return r}return-1},processVari
ableAndFallback:function(e,t){var n=e.indexOf("var(");if(n===-1)return t(e,"",""
,"");var r=this._findMatchingParen(e,n+3),s=e.substring(n+4,r),i=e.substring(0,n
),o=this.processVariableAndFallback(e.substring(r+1),t),a=s.indexOf(",");if(a===
-1)return t(i,s.trim(),"",o);var l=s.substring(0,a).trim(),c=s.substring(a+1).tr
im();return t(i,l,c,o)},rx:{VAR_ASSIGN:/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:([^;
{]*)|{([^}]*)})(?:(?=[;\s}])|$)/gi,MIXIN_MATCH:/(?:^|\W+)@apply\s*\(?([^);\n]*)\
)?/gi,VAR_CONSUMED:/(--[\w-]+)\s*([:,;)]|$)/gi,ANIMATION_MATCH:/(animation\s*:)|
(animation-name\s*:)/,MEDIA_MATCH:/@media[^(]*(\([^)]*\))/,IS_VAR:/^--/,BRACKETE
D:/\{[^}]*\}/g,HOST_PREFIX:"(?:^|[^.#[:])",HOST_SUFFIX:"($|[.:[\\s>+~])"},resolv
eCss:Polymer.ResolveUrl.resolveCss,parser:Polymer.CssParse,ruleTypes:Polymer.Css
Parse.types}}(),Polymer.StyleTransformer=function(){var e=Polymer.StyleUtil,t=Po
lymer.Settings,n={dom:function(e,t,n,r){this._transformDom(e,t||"",n,r)},_transf
ormDom:function(e,t,n,r){e.setAttribute&&this.element(e,t,n,r);for(var s=Polymer
.dom(e).childNodes,i=0;i<s.length;i++)this._transformDom(s[i],t,n,r)},element:fu
nction(e,t,n,s){if(n)s?e.removeAttribute(r):e.setAttribute(r,t);else if(t)if(e.c
lassList)s?(e.classList.remove(r),e.classList.remove(t)):(e.classList.add(r),e.c
lassList.add(t));else if(e.getAttribute){var i=e.getAttribute(g);s?i&&e.setAttri
bute(g,i.replace(r,"").replace(t,"")):e.setAttribute(g,(i?i+" ":"")+r+" "+t)}},e
lementStyles:function(n,r){var s,i=n._styles,o="",a=n.__cssBuild,l=t.useNativeSh
adow||"shady"===a;if(l){var h=this;s=function(e){e.selector=h._slottedToContent(
e.selector),e.selector=e.selector.replace(c,":host > *"),r&&r(e)}}for(var u,f=0,
p=i.length;f<p&&(u=i[f]);f++){var _=e.rulesForStyle(u);o+=l?e.toCssText(_,s):thi
s.css(_,n.is,n.extends,r,n._scopeCssViaAttr)+"\n\n"}return o.trim()},css:functio
n(t,n,r,s,i){var o=this._calcHostScope(n,r);n=this._calcElementScope(n,i);var a=
this;return e.toCssText(t,function(e){e.isScoped||(a.rule(e,n,o),e.isScoped=!0),
s&&s(e,n,o)})},_calcElementScope:function(e,t){return e?t?m+e+y:d+e:""},_calcHos
tScope:function(e,t){return t?"[is="+e+"]":e},rule:function(e,t,n){this._transfo
rmRule(e,this._transformComplexSelector,t,n)},_transformRule:function(e,t,n,r){e
.selector=e.transformedSelector=this._transformRuleCss(e,t,n,r)},_transformRuleC
ss:function(t,n,r,s){var o=t.selector.split(i);if(!e.isKeyframesSelector(t))for(
var a,l=0,c=o.length;l<c&&(a=o[l]);l++)o[l]=n.call(this,a,r,s);return o.join(i)}
,_transformComplexSelector:function(e,t,n){var r=!1,s=!1,a=this;return e=e.trim(
),e=this._slottedToContent(e),e=e.replace(c,":host > *"),e=e.replace(P,l+" $1"),
e=e.replace(o,function(e,i,o){if(r)o=o.replace(_," ");else{var l=a._transformCom
poundSelector(o,i,t,n);r=r||l.stop,s=s||l.hostContext,i=l.combinator,o=l.value}r
eturn i+o}),s&&(e=e.replace(f,function(e,t,r,s){return t+r+" "+n+s+i+" "+t+n+r+s
})),e},_transformCompoundSelector:function(e,t,n,r){var s=e.search(_),i=!1;e.ind
exOf(u)>=0?i=!0:e.indexOf(l)>=0?e=this._transformHostSelector(e,r):0!==s&&(e=n?t
his._transformSimpleSelector(e,n):e),e.indexOf(p)>=0&&(t="");var o;return s>=0&&
(e=e.replace(_," "),o=!0),{value:e,combinator:t,stop:o,hostContext:i}},_transfor
mSimpleSelector:function(e,t){var n=e.split(v);return n[0]+=t,n.join(v)},_transf
ormHostSelector:function(e,t){var n=e.match(h),r=n&&n[2].trim()||"";if(r){if(r[0
].match(a))return e.replace(h,function(e,n,r){return t+r});var s=r.split(a)[0];r
eturn s===t?r:S}return e.replace(l,t)},documentRule:function(e){e.selector=e.par
sedSelector,this.normalizeRootSelector(e),t.useNativeShadow||this._transformRule
(e,this._transformDocumentSelector)},normalizeRootSelector:function(e){e.selecto
r=e.selector.replace(c,"html")},_transformDocumentSelector:function(e){return e.
match(_)?this._transformComplexSelector(e,s):this._transformSimpleSelector(e.tri
m(),s)},_slottedToContent:function(e){return e.replace(C,p+"> $1")},SCOPE_NAME:"
style-scope"},r=n.SCOPE_NAME,s=":not(["+r+"]):not(."+r+")",i=",",o=/(^|[\s>+~]+)
((?:\[.+?\]|[^\s>+~=\[])+)/g,a=/[[.:#*]/,l=":host",c=":root",h=/(:host)(?:\(((?:
\([^)(]*\)|[^)(]*)+?)\))/,u=":host-context",f=/(.*)(?::host-context)(?:\(((?:\([
^)(]*\)|[^)(]*)+?)\))(.*)/,p="::content",_=/::content|::shadow|\/deep\//,d=".",m
="["+r+"~=",y="]",v=":",g="class",P=new RegExp("^("+p+")"),S="should_not_match",
C=/(?:::slotted)(?:\(((?:\([^)(]*\)|[^)(]*)+?)\))/g;return n}(),Polymer.StyleExt
ends=function(){var e=Polymer.StyleUtil;return{hasExtends:function(e){return Boo
lean(e.match(this.rx.EXTEND))},transform:function(t){var n=e.rulesForStyle(t),r=
this;return e.forEachRule(n,function(e){if(r._mapRuleOntoParent(e),e.parent)for(
var t;t=r.rx.EXTEND.exec(e.cssText);){var n=t[1],s=r._findExtendor(n,e);s&&r._ex
tendRule(e,s)}e.cssText=e.cssText.replace(r.rx.EXTEND,"")}),e.toCssText(n,functi
on(e){e.selector.match(r.rx.STRIP)&&(e.cssText="")},!0)},_mapRuleOntoParent:func
tion(e){if(e.parent){for(var t,n=e.parent.map||(e.parent.map={}),r=e.selector.sp
lit(","),s=0;s<r.length;s++)t=r[s],n[t.trim()]=e;return n}},_findExtendor:functi
on(e,t){return t.parent&&t.parent.map&&t.parent.map[e]||this._findExtendor(e,t.p
arent)},_extendRule:function(e,t){e.parent!==t.parent&&this._cloneAndAddRuleToPa
rent(t,e.parent),e.extends=e.extends||[],e.extends.push(t),t.selector=t.selector
.replace(this.rx.STRIP,""),t.selector=(t.selector&&t.selector+",\n")+e.selector,
t.extends&&t.extends.forEach(function(t){this._extendRule(e,t)},this)},_cloneAnd
AddRuleToParent:function(e,t){e=Object.create(e),e.parent=t,e.extends&&(e.extend
s=e.extends.slice()),t.rules.push(e)},rx:{EXTEND:/@extends\(([^)]*)\)\s*?;/gim,S
TRIP:/%[^,]*$/}}}(),Polymer.ApplyShim=function(){"use strict";function e(e,t){e=
e.trim(),m[e]={properties:t,dependants:{}}}function t(e){return e=e.trim(),m[e]}
function n(e,t){var n=_.exec(t);return n&&(t=n[1]?y._getInitialValueForProperty(
e):"apply-shim-inherit"),t}function r(e){for(var t,r,s,i,o=e.split(";"),a={},l=0
;l<o.length;l++)s=o[l],s&&(i=s.split(":"),i.length>1&&(t=i[0].trim(),r=n(t,i.sli
ce(1).join(":")),a[t]=r));return a}function s(e){var t=y.__currentElementProto,n
=t&&t.is;for(var r in e.dependants)r!==n&&(e.dependants[r].__applyShimInvalid=!0
)}function i(n,i,o,a){if(o&&c.processVariableAndFallback(o,function(e,n){n&&t(n)
&&(a="@apply "+n+";")}),!a)return n;var h=l(a),u=n.slice(0,n.indexOf("--")),f=r(
h),p=f,_=t(i),m=_&&_.properties;m?(p=Object.create(m),p=Polymer.Base.mixin(p,f))
:e(i,p);var y,v,g=[],P=!1;for(y in p)v=f[y],void 0===v&&(v="initial"),!m||y in m
||(P=!0),g.push(i+d+y+": "+v);return P&&s(_),_&&(_.properties=p),o&&(u=n+";"+u),
u+g.join("; ")+";"}function o(e,t,n){return"var("+t+",var("+n+"))"}function a(n,
r){n=n.replace(p,"");var s=[],i=t(n);if(i||(e(n,{}),i=t(n)),i){var o=y.__current
ElementProto;o&&(i.dependants[o.is]=o);var a,l,c;for(a in i.properties)c=r&&r[a]
,l=[a,": var(",n,d,a],c&&l.push(",",c),l.push(")"),s.push(l.join(""))}return s.j
oin("; ")}function l(e){for(var t;t=h.exec(e);){var n=t[0],s=t[1],i=t.index,o=i+
n.indexOf("@apply"),l=i+n.length,c=e.slice(0,o),u=e.slice(l),f=r(c),p=a(s,f);e=[
c,p,u].join(""),h.lastIndex=i+p.length}return e}var c=Polymer.StyleUtil,h=c.rx.M
IXIN_MATCH,u=c.rx.VAR_ASSIGN,f=/var\(\s*(--[^,]*),\s*(--[^)]*)\)/g,p=/;\s*/m,_=/
^\s*(initial)|(inherit)\s*$/,d="_-_",m={},y={_measureElement:null,_map:m,_separa
tor:d,transform:function(e,t){this.__currentElementProto=t,c.forRulesInStyles(e,
this._boundFindDefinitions),c.forRulesInStyles(e,this._boundFindApplications),t&
&(t.__applyShimInvalid=!1),this.__currentElementProto=null},_findDefinitions:fun
ction(e){var t=e.parsedCssText;t=t.replace(f,o),t=t.replace(u,i),e.cssText=t,":r
oot"===e.selector&&(e.selector=":host > *")},_findApplications:function(e){e.css
Text=l(e.cssText)},transformRule:function(e){this._findDefinitions(e),this._find
Applications(e)},_getInitialValueForProperty:function(e){return this._measureEle
ment||(this._measureElement=document.createElement("meta"),this._measureElement.
style.all="initial",document.head.appendChild(this._measureElement)),window.getC
omputedStyle(this._measureElement).getPropertyValue(e)}};return y._boundTransfor
mRule=y.transformRule.bind(y),y._boundFindDefinitions=y._findDefinitions.bind(y)
,y._boundFindApplications=y._findApplications.bind(y),y}(),function(){var e=Poly
mer.Base._prepElement,t=Polymer.Settings.useNativeShadow,n=Polymer.StyleUtil,r=P
olymer.StyleTransformer,s=Polymer.StyleExtends,i=Polymer.ApplyShim,o=Polymer.Set
tings;Polymer.Base._addFeature({_prepElement:function(t){this._encapsulateStyle&
&"shady"!==this.__cssBuild&&r.element(t,this.is,this._scopeCssViaAttr),e.call(th
is,t)},_prepStyles:function(){void 0===this._encapsulateStyle&&(this._encapsulat
eStyle=!t),t||(this._scopeStyle=n.applyStylePlaceHolder(this.is)),this.__cssBuil
d=n.cssBuildTypeForModule(this.is)},_prepShimStyles:function(){if(this._template
){var e=n.isTargetedBuild(this.__cssBuild);if(o.useNativeCSSProperties&&"shadow"
===this.__cssBuild&&e)return;this._styles=this._styles||this._collectStyles(),o.
useNativeCSSProperties&&!this.__cssBuild&&i.transform(this._styles,this);var s=o
.useNativeCSSProperties&&e?this._styles.length&&this._styles[0].textContent.trim
():r.elementStyles(this);this._prepStyleProperties(),!this._needsStyleProperties
()&&s&&n.applyCss(s,this.is,t?this._template.content:null,this._scopeStyle)}else
this._styles=[]},_collectStyles:function(){var e=[],t="",r=this.styleModules;if
(r)for(var i,o=0,a=r.length;o<a&&(i=r[o]);o++)t+=n.cssFromModule(i);t+=n.cssFrom
Module(this.is);var l=this._template&&this._template.parentNode;if(!this._templa
te||l&&l.id.toLowerCase()===this.is||(t+=n.cssFromElement(this._template)),t){va
r c=document.createElement("style");c.textContent=t,s.hasExtends(c.textContent)&
&(t=s.transform(c)),e.push(c)}return e},_elementAdd:function(e){this._encapsulat
eStyle&&(e.__styleScoped?e.__styleScoped=!1:r.dom(e,this.is,this._scopeCssViaAtt
r))},_elementRemove:function(e){this._encapsulateStyle&&r.dom(e,this.is,this._sc
opeCssViaAttr,!0)},scopeSubtree:function(e,n){if(!t){var r=this,s=function(e){if
(e.nodeType===Node.ELEMENT_NODE){var t=e.getAttribute("class");e.setAttribute("c
lass",r._scopeElementClass(e,t));for(var n,s=e.querySelectorAll("*"),i=0;i<s.len
gth&&(n=s[i]);i++)t=n.getAttribute("class"),n.setAttribute("class",r._scopeEleme
ntClass(n,t))}};if(s(e),n){var i=new MutationObserver(function(e){for(var t,n=0;
n<e.length&&(t=e[n]);n++)if(t.addedNodes)for(var r=0;r<t.addedNodes.length;r++)s
(t.addedNodes[r])});return i.observe(e,{childList:!0,subtree:!0}),i}}}})}(),Poly
mer.StyleProperties=function(){"use strict";function e(e,t){var n=parseInt(e/32)
,r=1<<e%32;t[n]=(t[n]||0)|r}var t=Polymer.DomApi.matchesSelector,n=Polymer.Style
Util,r=Polymer.StyleTransformer,s=navigator.userAgent.match("Trident"),i=Polymer
.Settings;return{decorateStyles:function(e,t){var s=this,i={},o=[],a=0,l=r._calc
HostScope(t.is,t.extends);n.forRulesInStyles(e,function(e,r){s.decorateRule(e),e
.index=a++,s.whenHostOrRootRule(t,e,r,function(r){if(e.parent.type===n.ruleTypes
.MEDIA_RULE&&(t.__notStyleScopeCacheable=!0),r.isHost){var s=r.selector.split("
").some(function(e){return 0===e.indexOf(l)&&e.length!==l.length});t.__notStyleS
copeCacheable=t.__notStyleScopeCacheable||s}}),s.collectPropertiesInCssText(e.pr
opertyInfo.cssText,i)},function(e){o.push(e)}),e._keyframes=o;var c=[];for(var h
in i)c.push(h);return c},decorateRule:function(e){if(e.propertyInfo)return e.pr
opertyInfo;var t={},n={},r=this.collectProperties(e,n);return r&&(t.properties=n
,e.rules=null),t.cssText=this.collectCssText(e),e.propertyInfo=t,t},collectPrope
rties:function(e,t){var n=e.propertyInfo;if(!n){for(var r,s,i,o=this.rx.VAR_ASSI
GN,a=e.parsedCssText;r=o.exec(a);)s=(r[2]||r[3]).trim(),"inherit"!==s&&(t[r[1].t
rim()]=s),i=!0;return i}if(n.properties)return Polymer.Base.mixin(t,n.properties
),!0},collectCssText:function(e){return this.collectConsumingCssText(e.parsedCss
Text)},collectConsumingCssText:function(e){return e.replace(this.rx.BRACKETED,""
).replace(this.rx.VAR_ASSIGN,"")},collectPropertiesInCssText:function(e,t){for(v
ar n;n=this.rx.VAR_CONSUMED.exec(e);){var r=n[1];":"!==n[2]&&(t[r]=!0)}},reify:f
unction(e){for(var t,n=Object.getOwnPropertyNames(e),r=0;r<n.length;r++)t=n[r],e
[t]=this.valueForProperty(e[t],e)},valueForProperty:function(e,t){if(e)if(e.inde
xOf(";")>=0)e=this.valueForProperties(e,t);else{var r=this,s=function(e,n,s,i){v
ar o=r.valueForProperty(t[n],t);return o&&"initial"!==o?"apply-shim-inherit"===o
&&(o="inherit"):o=r.valueForProperty(t[s]||s,t)||s,e+(o||"")+i};e=n.processVaria
bleAndFallback(e,s)}return e&&e.trim()||""},valueForProperties:function(e,t){for
(var n,r,s=e.split(";"),i=0;i<s.length;i++)if(n=s[i]){if(this.rx.MIXIN_MATCH.las
tIndex=0,r=this.rx.MIXIN_MATCH.exec(n))n=this.valueForProperty(t[r[1]],t);else{v
ar o=n.indexOf(":");if(o!==-1){var a=n.substring(o);a=a.trim(),a=this.valueForPr
operty(a,t)||a,n=n.substring(0,o)+a}}s[i]=n&&n.lastIndexOf(";")===n.length-1?n.s
lice(0,-1):n||""}return s.join(";")},applyProperties:function(e,t){var n="";e.pr
opertyInfo||this.decorateRule(e),e.propertyInfo.cssText&&(n=this.valueForPropert
ies(e.propertyInfo.cssText,t)),e.cssText=n},applyKeyframeTransforms:function(e,t
){var n=e.cssText,r=e.cssText;if(null==e.hasAnimations&&(e.hasAnimations=this.rx
.ANIMATION_MATCH.test(n)),e.hasAnimations){var s;if(null==e.keyframeNamesToTrans
form){e.keyframeNamesToTransform=[];for(var i in t)s=t[i],r=s(n),n!==r&&(n=r,e.k
eyframeNamesToTransform.push(i))}else{for(var o=0;o<e.keyframeNamesToTransform.l
ength;++o)s=t[e.keyframeNamesToTransform[o]],n=s(n);r=n}}e.cssText=r},propertyDa
taFromStyles:function(r,s){var i={},o=this,a=[];return n.forActiveRulesInStyles(
r,function(n){n.propertyInfo||o.decorateRule(n);var r=n.transformedSelector||n.p
arsedSelector;s&&n.propertyInfo.properties&&r&&t.call(s,r)&&(o.collectProperties
(n,i),e(n.index,a))}),{properties:i,key:a}},_rootSelector:/:root|:host\s*>\s*\*/
,_checkRoot:function(e,t){return Boolean(t.match(this._rootSelector))||"html"===
e&&t.indexOf("html")>-1},whenHostOrRootRule:function(e,t,n,s){if(t.propertyInfo|
|self.decorateRule(t),t.propertyInfo.properties){var o=e.is?r._calcHostScope(e.i
s,e.extends):"html",a=t.parsedSelector,l=this._checkRoot(o,a),c=!l&&0===a.indexO
f(":host"),h=e.__cssBuild||n.__cssBuild;if("shady"===h&&(l=a===o+" > *."+o||a.in
dexOf("html")>-1,c=!l&&0===a.indexOf(o)),l||c){var u=o;c&&(i.useNativeShadow&&!t
.transformedSelector&&(t.transformedSelector=r._transformRuleCss(t,r._transformC
omplexSelector,e.is,o)),u=t.transformedSelector||t.parsedSelector),l&&"html"===o
&&(u=t.transformedSelector||t.parsedSelector),s({selector:u,isHost:c,isRoot:l})}
}},hostAndRootPropertiesForScope:function(e){var r={},s={},i=this;return n.forAc
tiveRulesInStyles(e._styles,function(n,o){i.whenHostOrRootRule(e,n,o,function(o)
{var a=e._element||e;t.call(a,o.selector)&&(o.isHost?i.collectProperties(n,r):i.
collectProperties(n,s))})}),{rootProps:s,hostProps:r}},transformStyles:function(
e,t,n){var s=this,o=r._calcHostScope(e.is,e.extends),a=e.extends?"\\"+o.slice(0,
-1)+"\\]":o,l=new RegExp(this.rx.HOST_PREFIX+a+this.rx.HOST_SUFFIX),c=this._elem
entKeyframeTransforms(e,n);return r.elementStyles(e,function(r){s.applyPropertie
s(r,t),i.useNativeShadow||Polymer.StyleUtil.isKeyframesSelector(r)||!r.cssText||
(s.applyKeyframeTransforms(r,c),s._scopeSelector(r,l,o,e._scopeCssViaAttr,n))})}
,_elementKeyframeTransforms:function(e,t){var n=e._styles._keyframes,r={};if(!i.
useNativeShadow&&n)for(var s=0,o=n[s];s<n.length;o=n[++s])this._scopeKeyframes(o
,t),r[o.keyframesName]=this._keyframesRuleTransformer(o);return r},_keyframesRul
eTransformer:function(e){return function(t){return t.replace(e.keyframesNameRx,e
.transformedKeyframesName)}},_scopeKeyframes:function(e,t){e.keyframesNameRx=new
RegExp(e.keyframesName,"g"),e.transformedKeyframesName=e.keyframesName+"-"+t,e.
transformedSelector=e.transformedSelector||e.selector,e.selector=e.transformedSe
lector.replace(e.keyframesName,e.transformedKeyframesName)},_scopeSelector:funct
ion(e,t,n,s,i){e.transformedSelector=e.transformedSelector||e.selector;for(var o
,a=e.transformedSelector,l=s?"["+r.SCOPE_NAME+"~="+i+"]":"."+i,c=a.split(","),h=
0,u=c.length;h<u&&(o=c[h]);h++)c[h]=o.match(t)?o.replace(n,l):l+" "+o;e.selector
=c.join(",")},applyElementScopeSelector:function(e,t,n,s){var i=s?e.getAttribute
(r.SCOPE_NAME):e.getAttribute("class")||"",o=n?i.replace(n,t):(i?i+" ":"")+this.
XSCOPE_NAME+" "+t;i!==o&&(s?e.setAttribute(r.SCOPE_NAME,o):e.setAttribute("class
",o))},applyElementStyle:function(e,t,r,o){var a=o?o.textContent||"":this.transf
ormStyles(e,t,r),l=e._customStyle;return l&&!i.useNativeShadow&&l!==o&&(l._useCo
unt--,l._useCount<=0&&l.parentNode&&l.parentNode.removeChild(l)),i.useNativeShad
ow?e._customStyle?(e._customStyle.textContent=a,o=e._customStyle):a&&(o=n.applyC
ss(a,r,e.root,e._scopeStyle)):o?o.parentNode||(s&&a.indexOf("@media")>-1&&(o.tex
tContent=a),n.applyStyle(o,null,e._scopeStyle)):a&&(o=n.applyCss(a,r,null,e._sco
peStyle)),o&&(o._useCount=o._useCount||0,e._customStyle!=o&&o._useCount++,e._cus
tomStyle=o),o},mixinCustomStyle:function(e,t){var n;for(var r in t)n=t[r],(n||0=
==n)&&(e[r]=n)},updateNativeStyleProperties:function(e,t){var n=e.__customStyleP
roperties;if(n)for(var r=0;r<n.length;r++)e.style.removeProperty(n[r]);var s=[];
for(var i in t)null!==t[i]&&(e.style.setProperty(i,t[i]),s.push(i));e.__customSt
yleProperties=s},rx:n.rx,XSCOPE_NAME:"x-scope"}}(),function(){Polymer.StyleCache
=function(){this.cache={}},Polymer.StyleCache.prototype={MAX:100,store:function(
e,t,n,r){t.keyValues=n,t.styles=r;var s=this.cache[e]=this.cache[e]||[];s.push(t
),s.length>this.MAX&&s.shift()},retrieve:function(e,t,n){var r=this.cache[e];if(
r)for(var s,i=r.length-1;i>=0;i--)if(s=r[i],n===s.styles&&this._objectsEqual(t,s
.keyValues))return s},clear:function(){this.cache={}},_objectsEqual:function(e,t
){var n,r;for(var s in e)if(n=e[s],r=t[s],!("object"==typeof n&&n?this._objectsS
trictlyEqual(n,r):n===r))return!1;return!Array.isArray(e)||e.length===t.length},
_objectsStrictlyEqual:function(e,t){return this._objectsEqual(e,t)&&this._object
sEqual(t,e)}}}(),Polymer.StyleDefaults=function(){var e=Polymer.StyleProperties,
t=Polymer.StyleCache,n=Polymer.Settings.useNativeCSSProperties,r={_styles:[],_pr
operties:null,customStyle:{},_styleCache:new t,_element:Polymer.DomApi.wrap(docu
ment.documentElement),addStyle:function(e){this._styles.push(e),this._properties
=null},get _styleProperties(){return this._properties||(e.decorateStyles(this._s
tyles,this),this._styles._scopeStyleProperties=null,this._properties=e.hostAndRo
otPropertiesForScope(this).rootProps,e.mixinCustomStyle(this._properties,this.cu
stomStyle),e.reify(this._properties)),this._properties},hasStyleProperties:funct
ion(){return Boolean(this._properties)},_needsStyleProperties:function(){},_comp
uteStyleProperties:function(){return this._styleProperties},updateStyles:functio
n(t){this._properties=null,t&&Polymer.Base.mixin(this.customStyle,t),this._style
Cache.clear();for(var r,s=0;s<this._styles.length;s++)r=this._styles[s],r=r.__im
portElement||r,r._apply();n&&e.updateNativeStyleProperties(document.documentElem
ent,this.customStyle)}};return r}(),function(){"use strict";var e=Polymer.Base.s
erializeValueToAttribute,t=Polymer.StyleProperties,n=Polymer.StyleTransformer,r=
Polymer.StyleDefaults,s=Polymer.Settings.useNativeShadow,i=Polymer.Settings.useN
ativeCSSProperties;Polymer.Base._addFeature({_prepStyleProperties:function(){i||
(this._ownStylePropertyNames=this._styles&&this._styles.length?t.decorateStyles(
this._styles,this):null); |
| 4 },customStyle:null,getComputedStyleValue:function(e){return!i&&this._styleProper
ties&&this._styleProperties[e]||getComputedStyle(this).getPropertyValue(e)},_set
upStyleProperties:function(){this.customStyle={},this._styleCache=null,this._sty
leProperties=null,this._scopeSelector=null,this._ownStyleProperties=null,this._c
ustomStyle=null},_needsStyleProperties:function(){return Boolean(!i&&this._ownSt
ylePropertyNames&&this._ownStylePropertyNames.length)},_validateApplyShim:functi
on(){if(this.__applyShimInvalid){Polymer.ApplyShim.transform(this._styles,this._
_proto__);var e=n.elementStyles(this);if(s){var t=this._template.content.querySe
lector("style");t&&(t.textContent=e)}else{var r=this._scopeStyle&&this._scopeSty
le.nextSibling;r&&(r.textContent=e)}}},_beforeAttached:function(){this._scopeSel
ector&&!this.__stylePropertiesInvalid||!this._needsStyleProperties()||(this.__st
ylePropertiesInvalid=!1,this._updateStyleProperties())},_findStyleHost:function(
){for(var e,t=this;e=Polymer.dom(t).getOwnerRoot();){if(Polymer.isInstance(e.hos
t))return e.host;t=e.host}return r},_updateStyleProperties:function(){var e,n=th
is._findStyleHost();n._styleProperties||n._computeStyleProperties(),n._styleCach
e||(n._styleCache=new Polymer.StyleCache);var r=t.propertyDataFromStyles(n._styl
es,this),i=!this.__notStyleScopeCacheable;i&&(r.key.customStyle=this.customStyle
,e=n._styleCache.retrieve(this.is,r.key,this._styles));var a=Boolean(e);a?this._
styleProperties=e._styleProperties:this._computeStyleProperties(r.properties),th
is._computeOwnStyleProperties(),a||(e=o.retrieve(this.is,this._ownStylePropertie
s,this._styles));var l=Boolean(e)&&!a,c=this._applyStyleProperties(e);a||(c=c&&s
?c.cloneNode(!0):c,e={style:c,_scopeSelector:this._scopeSelector,_stylePropertie
s:this._styleProperties},i&&(r.key.customStyle={},this.mixin(r.key.customStyle,t
his.customStyle),n._styleCache.store(this.is,e,r.key,this._styles)),l||o.store(t
his.is,Object.create(e),this._ownStyleProperties,this._styles))},_computeStylePr
operties:function(e){var n=this._findStyleHost();n._styleProperties||n._computeS
tyleProperties();var r=Object.create(n._styleProperties),s=t.hostAndRootProperti
esForScope(this);this.mixin(r,s.hostProps),e=e||t.propertyDataFromStyles(n._styl
es,this).properties,this.mixin(r,e),this.mixin(r,s.rootProps),t.mixinCustomStyle
(r,this.customStyle),t.reify(r),this._styleProperties=r},_computeOwnStylePropert
ies:function(){for(var e,t={},n=0;n<this._ownStylePropertyNames.length;n++)e=thi
s._ownStylePropertyNames[n],t[e]=this._styleProperties[e];this._ownStyleProperti
es=t},_scopeCount:0,_applyStyleProperties:function(e){var n=this._scopeSelector;
this._scopeSelector=e?e._scopeSelector:this.is+"-"+this.__proto__._scopeCount++;
var r=t.applyElementStyle(this,this._styleProperties,this._scopeSelector,e&&e.st
yle);return s||t.applyElementScopeSelector(this,this._scopeSelector,n,this._scop
eCssViaAttr),r},serializeValueToAttribute:function(t,n,r){if(r=r||this,"class"==
=n&&!s){var i=r===this?this.domHost||this.dataHost:this;i&&(t=i._scopeElementCla
ss(r,t))}r=this.shadyRoot&&this.shadyRoot._hasDistributed?Polymer.dom(r):r,e.cal
l(this,t,n,r)},_scopeElementClass:function(e,t){return s||this._scopeCssViaAttr|
|(t=(t?t+" ":"")+a+" "+this.is+(e._scopeSelector?" "+l+" "+e._scopeSelector:""))
,t},updateStyles:function(e){e&&this.mixin(this.customStyle,e),i?t.updateNativeS
tyleProperties(this,this.customStyle):(this.isAttached?this._needsStylePropertie
s()?this._updateStyleProperties():this._styleProperties=null:this.__stylePropert
iesInvalid=!0,this._styleCache&&this._styleCache.clear(),this._updateRootStyles(
))},_updateRootStyles:function(e){e=e||this.root;for(var t,n=Polymer.dom(e)._que
ry(function(e){return e.shadyRoot||e.shadowRoot}),r=0,s=n.length;r<s&&(t=n[r]);r
++)t.updateStyles&&t.updateStyles()}}),Polymer.updateStyles=function(e){r.update
Styles(e),Polymer.Base._updateRootStyles(document)};var o=new Polymer.StyleCache
;Polymer.customStyleCache=o;var a=n.SCOPE_NAME,l=t.XSCOPE_NAME}(),Polymer.Base._
addFeature({_registerFeatures:function(){this._prepIs(),this._prepConstructor(),
this._prepStyles()},_finishRegisterFeatures:function(){this._prepTemplate(),this
._prepShimStyles(),this._prepAnnotations(),this._prepEffects(),this._prepBehavio
rs(),this._prepPropertyInfo(),this._prepBindings(),this._prepShady()},_prepBehav
ior:function(e){this._addPropertyEffects(e.properties),this._addComplexObserverE
ffects(e.observers),this._addHostAttributes(e.hostAttributes)},_initFeatures:fun
ction(){this._setupGestures(),this._setupConfigure(),this._setupStyleProperties(
),this._setupDebouncers(),this._setupShady(),this._registerHost(),this._template
&&(this._validateApplyShim(),this._poolContent(),this._beginHosting(),this._stam
pTemplate(),this._endHosting(),this._marshalAnnotationReferences()),this._marsha
lInstanceEffects(),this._marshalBehaviors(),this._marshalHostAttributes(),this._
marshalAttributes(),this._tryReady()},_marshalBehavior:function(e){e.listeners&&
this._listenListeners(e.listeners)}}),function(){var e,t=Polymer.StyleProperties
,n=Polymer.StyleUtil,r=Polymer.CssParse,s=Polymer.StyleDefaults,i=Polymer.StyleT
ransformer,o=Polymer.ApplyShim,a=Polymer.Debounce,l=Polymer.Settings;Polymer({is
:"custom-style",extends:"style",_template:null,properties:{include:String},ready
:function(){this.__appliedElement=this.__appliedElement||this,this.__cssBuild=n.
getCssBuildType(this),this.__appliedElement!==this&&(this.__appliedElement.__css
Build=this.__cssBuild),this._tryApply()},attached:function(){this._tryApply()},_
tryApply:function(){if(!this._appliesToDocument&&this.parentNode&&"dom-module"!=
=this.parentNode.localName){this._appliesToDocument=!0;var e=this.__appliedEleme
nt;if(l.useNativeCSSProperties||(this.__needsUpdateStyles=s.hasStyleProperties()
,s.addStyle(e)),e.textContent||this.include)this._apply(!0);else{var t=this,n=ne
w MutationObserver(function(){n.disconnect(),t._apply(!0)});n.observe(e,{childLi
st:!0})}}},_updateStyles:function(){Polymer.updateStyles()},_apply:function(e){v
ar t=this.__appliedElement;if(this.include&&(t.textContent=n.cssFromModules(this
.include,!0)+t.textContent),t.textContent){var r=this.__cssBuild,s=n.isTargetedB
uild(r);if(!l.useNativeCSSProperties||!s){var a=n.rulesForStyle(t);if(s||(n.forE
achRule(a,function(e){i.documentRule(e)}),l.useNativeCSSProperties&&!r&&o.transf
orm([t])),l.useNativeCSSProperties)t.textContent=n.toCssText(a);else{var c=this,
h=function(){c._flushCustomProperties()};e?Polymer.RenderStatus.whenReady(h):h()
}}}},_flushCustomProperties:function(){this.__needsUpdateStyles?(this.__needsUpd
ateStyles=!1,e=a(e,this._updateStyles)):this._applyCustomProperties()},_applyCus
tomProperties:function(){var e=this.__appliedElement;this._computeStylePropertie
s();var s=this._styleProperties,i=n.rulesForStyle(e);i&&(e.textContent=n.toCssTe
xt(i,function(e){var n=e.cssText=e.parsedCssText;e.propertyInfo&&e.propertyInfo.
cssText&&(n=r.removeCustomPropAssignment(n),e.cssText=t.valueForProperties(n,s))
}))}})}(),Polymer.Templatizer={properties:{__hideTemplateChildren__:{observer:"_
showHideChildren"}},_instanceProps:Polymer.nob,_parentPropPrefix:"_parent_",temp
latize:function(e){if(this._templatized=e,e._content||(e._content=e.content),e._
content._ctor)return this.ctor=e._content._ctor,void this._prepParentProperties(
this.ctor.prototype,e);var t=Object.create(Polymer.Base);this._customPrepAnnotat
ions(t,e),this._prepParentProperties(t,e),t._prepEffects(),this._customPrepEffec
ts(t),t._prepBehaviors(),t._prepPropertyInfo(),t._prepBindings(),t._notifyPathUp
=this._notifyPathUpImpl,t._scopeElementClass=this._scopeElementClassImpl,t.liste
n=this._listenImpl,t._showHideChildren=this._showHideChildrenImpl,t.__setPropert
yOrig=this.__setProperty,t.__setProperty=this.__setPropertyImpl;var n=this._cons
tructorImpl,r=function(e,t){n.call(this,e,t)};r.prototype=t,t.constructor=r,e._c
ontent._ctor=r,this.ctor=r},_getRootDataHost:function(){return this.dataHost&&th
is.dataHost._rootDataHost||this.dataHost},_showHideChildrenImpl:function(e){for(
var t=this._children,n=0;n<t.length;n++){var r=t[n];Boolean(e)!=Boolean(r.__hide
TemplateChildren__)&&(r.nodeType===Node.TEXT_NODE?e?(r.__polymerTextContent__=r.
textContent,r.textContent=""):r.textContent=r.__polymerTextContent__:r.style&&(e
?(r.__polymerDisplay__=r.style.display,r.style.display="none"):r.style.display=r
.__polymerDisplay__)),r.__hideTemplateChildren__=e}},__setPropertyImpl:function(
e,t,n,r){r&&r.__hideTemplateChildren__&&"textContent"==e&&(e="__polymerTextConte
nt__"),this.__setPropertyOrig(e,t,n,r)},_debounceTemplate:function(e){Polymer.do
m.addDebouncer(this.debounce("_debounceTemplate",e))},_flushTemplates:function()
{Polymer.dom.flush()},_customPrepEffects:function(e){var t=e._parentProps;for(va
r n in t)e._addPropertyEffect(n,"function",this._createHostPropEffector(n));for(
n in this._instanceProps)e._addPropertyEffect(n,"function",this._createInstanceP
ropEffector(n))},_customPrepAnnotations:function(e,t){e._template=t;var n=t._con
tent;if(!n._notes){var r=e._rootDataHost;r&&(Polymer.Annotations.prepElement=fun
ction(){r._prepElement()}),n._notes=Polymer.Annotations.parseAnnotations(t),Poly
mer.Annotations.prepElement=null,this._processAnnotations(n._notes)}e._notes=n._
notes,e._parentProps=n._parentProps},_prepParentProperties:function(e,t){var n=t
his._parentProps=e._parentProps;if(this._forwardParentProp&&n){var r,s=e._parent
PropProto;if(!s){for(r in this._instanceProps)delete n[r];s=e._parentPropProto=O
bject.create(null),t!=this&&(Polymer.Bind.prepareModel(s),Polymer.Base.prepareMo
delNotifyPath(s));for(r in n){var i=this._parentPropPrefix+r,o=[{kind:"function"
,effect:this._createForwardPropEffector(r),fn:Polymer.Bind._functionEffect},{kin
d:"notify",fn:Polymer.Bind._notifyEffect,effect:{event:Polymer.CaseMap.camelToDa
shCase(i)+"-changed"}}];Polymer.Bind._createAccessors(s,i,o)}}var a=this;t!=this
&&(Polymer.Bind.prepareInstance(t),t._forwardParentProp=function(e,t){a._forward
ParentProp(e,t)}),this._extendTemplate(t,s),t._pathEffector=function(e,t,n){retu
rn a._pathEffectorImpl(e,t,n)}}},_createForwardPropEffector:function(e){return f
unction(t,n){this._forwardParentProp(e,n)}},_createHostPropEffector:function(e){
var t=this._parentPropPrefix;return function(n,r){this.dataHost._templatized[t+e
]=r}},_createInstancePropEffector:function(e){return function(t,n,r,s){s||this.d
ataHost._forwardInstanceProp(this,e,n)}},_extendTemplate:function(e,t){var n=Obj
ect.getOwnPropertyNames(t);t._propertySetter&&(e._propertySetter=t._propertySett
er);for(var r,s=0;s<n.length&&(r=n[s]);s++){var i=e[r],o=Object.getOwnPropertyDe
scriptor(t,r);Object.defineProperty(e,r,o),void 0!==i&&e._propertySetter(r,i)}},
_showHideChildren:function(e){},_forwardInstancePath:function(e,t,n){},_forwardI
nstanceProp:function(e,t,n){},_notifyPathUpImpl:function(e,t){var n=this.dataHos
t,r=Polymer.Path.root(e);n._forwardInstancePath.call(n,this,e,t),r in n._parentP
rops&&n._templatized._notifyPath(n._parentPropPrefix+e,t)},_pathEffectorImpl:fun
ction(e,t,n){if(this._forwardParentPath&&0===e.indexOf(this._parentPropPrefix)){
var r=e.substring(this._parentPropPrefix.length),s=Polymer.Path.root(r);s in thi
s._parentProps&&this._forwardParentPath(r,t)}Polymer.Base._pathEffector.call(thi
s._templatized,e,t,n)},_constructorImpl:function(e,t){this._rootDataHost=t._getR
ootDataHost(),this._setupConfigure(e),this._registerHost(t),this._beginHosting()
,this.root=this.instanceTemplate(this._template),this.root.__noContent=!this._no
tes._hasContent,this.root.__styleScoped=!0,this._endHosting(),this._marshalAnnot
atedNodes(),this._marshalInstanceEffects(),this._marshalAnnotatedListeners();for
(var n=[],r=this.root.firstChild;r;r=r.nextSibling)n.push(r),r._templateInstance
=this;this._children=n,t.__hideTemplateChildren__&&this._showHideChildren(!0),th
is._tryReady()},_listenImpl:function(e,t,n){var r=this,s=this._rootDataHost,i=s.
_createEventHandler(e,t,n),o=function(e){e.model=r,i(e)};s._listen(e,t,o)},_scop
eElementClassImpl:function(e,t){var n=this._rootDataHost;return n?n._scopeElemen
tClass(e,t):t},stamp:function(e){if(e=e||{},this._parentProps){var t=this._templ
atized;for(var n in this._parentProps)void 0===e[n]&&(e[n]=t[this._parentPropPre
fix+n])}return new this.ctor(e,this)},modelForElement:function(e){for(var t;e;)i
f(t=e._templateInstance){if(t.dataHost==this)return t;e=t.dataHost}else e=e.pare
ntNode}},Polymer({is:"dom-template",extends:"template",_template:null,behaviors:
[Polymer.Templatizer],ready:function(){this.templatize(this)}}),Polymer._collect
ions=new WeakMap,Polymer.Collection=function(e){Polymer._collections.set(e,this)
,this.userArray=e,this.store=e.slice(),this.initMap()},Polymer.Collection.protot
ype={constructor:Polymer.Collection,initMap:function(){for(var e=this.omap=new W
eakMap,t=this.pmap={},n=this.store,r=0;r<n.length;r++){var s=n[r];s&&"object"==t
ypeof s?e.set(s,r):t[s]=r}},add:function(e){var t=this.store.push(e)-1;return e&
&"object"==typeof e?this.omap.set(e,t):this.pmap[e]=t,"#"+t},removeKey:function(
e){(e=this._parseKey(e))&&(this._removeFromMap(this.store[e]),delete this.store[
e])},_removeFromMap:function(e){e&&"object"==typeof e?this.omap.delete(e):delete
this.pmap[e]},remove:function(e){var t=this.getKey(e);return this.removeKey(t),
t},getKey:function(e){var t;if(t=e&&"object"==typeof e?this.omap.get(e):this.pma
p[e],void 0!=t)return"#"+t},getKeys:function(){return Object.keys(this.store).ma
p(function(e){return"#"+e})},_parseKey:function(e){if(e&&"#"==e[0])return e.slic
e(1)},setItem:function(e,t){if(e=this._parseKey(e)){var n=this.store[e];n&&this.
_removeFromMap(n),t&&"object"==typeof t?this.omap.set(t,e):this.pmap[t]=e,this.s
tore[e]=t}},getItem:function(e){if(e=this._parseKey(e))return this.store[e]},get
Items:function(){var e=[],t=this.store;for(var n in t)e.push(t[n]);return e},_ap
plySplices:function(e){for(var t,n,r={},s=0;s<e.length&&(n=e[s]);s++){n.addedKey
s=[];for(var i=0;i<n.removed.length;i++)t=this.getKey(n.removed[i]),r[t]=r[t]?nu
ll:-1;for(i=0;i<n.addedCount;i++){var o=this.userArray[n.index+i];t=this.getKey(
o),t=void 0===t?this.add(o):t,r[t]=r[t]?null:1,n.addedKeys.push(t)}}var a=[],l=[
];for(t in r)r[t]<0&&(this.removeKey(t),a.push(t)),r[t]>0&&l.push(t);return[{rem
oved:a,added:l}]}},Polymer.Collection.get=function(e){return Polymer._collection
s.get(e)||new Polymer.Collection(e)},Polymer.Collection.applySplices=function(e,
t){var n=Polymer._collections.get(e);return n?n._applySplices(t):null},Polymer({
is:"dom-repeat",extends:"template",_template:null,properties:{items:{type:Array}
,as:{type:String,value:"item"},indexAs:{type:String,value:"index"},sort:{type:Fu
nction,observer:"_sortChanged"},filter:{type:Function,observer:"_filterChanged"}
,observe:{type:String,observer:"_observeChanged"},delay:Number,renderedItemCount
:{type:Number,notify:!0,readOnly:!0},initialCount:{type:Number,observer:"_initia
lizeChunking"},targetFramerate:{type:Number,value:20},_targetFrameTime:{type:Num
ber,computed:"_computeFrameTime(targetFramerate)"}},behaviors:[Polymer.Templatiz
er],observers:["_itemsChanged(items.*)"],created:function(){this._instances=[],t
his._pool=[],this._limit=1/0;var e=this;this._boundRenderChunk=function(){e._ren
derChunk()}},detached:function(){this.__isDetached=!0;for(var e=0;e<this._instan
ces.length;e++)this._detachInstance(e)},attached:function(){if(this.__isDetached
){this.__isDetached=!1;for(var e=Polymer.dom(Polymer.dom(this).parentNode),t=0;t
<this._instances.length;t++)this._attachInstance(t,e)}},ready:function(){this._i
nstanceProps={__key__:!0},this._instanceProps[this.as]=!0,this._instanceProps[th
is.indexAs]=!0,this.ctor||this.templatize(this)},_sortChanged:function(e){var t=
this._getRootDataHost();this._sortFn=e&&("function"==typeof e?e:function(){retur
n t[e].apply(t,arguments)}),this._needFullRefresh=!0,this.items&&this._debounceT
emplate(this._render)},_filterChanged:function(e){var t=this._getRootDataHost();
this._filterFn=e&&("function"==typeof e?e:function(){return t[e].apply(t,argumen
ts)}),this._needFullRefresh=!0,this.items&&this._debounceTemplate(this._render)}
,_computeFrameTime:function(e){return Math.ceil(1e3/e)},_initializeChunking:func
tion(){this.initialCount&&(this._limit=this.initialCount,this._chunkCount=this.i
nitialCount,this._lastChunkTime=performance.now())},_tryRenderChunk:function(){t
his.items&&this._limit<this.items.length&&this.debounce("renderChunk",this._requ
estRenderChunk)},_requestRenderChunk:function(){requestAnimationFrame(this._boun
dRenderChunk)},_renderChunk:function(){var e=performance.now(),t=this._targetFra
meTime/(e-this._lastChunkTime);this._chunkCount=Math.round(this._chunkCount*t)||
1,this._limit+=this._chunkCount,this._lastChunkTime=e,this._debounceTemplate(thi
s._render)},_observeChanged:function(){this._observePaths=this.observe&&this.obs
erve.replace(".*",".").split(" ")},_itemsChanged:function(e){if("items"==e.path)
Array.isArray(this.items)?this.collection=Polymer.Collection.get(this.items):thi
s.items?this._error(this._logf("dom-repeat","expected array for `items`, found",
this.items)):this.collection=null,this._keySplices=[],this._indexSplices=[],this
._needFullRefresh=!0,this._initializeChunking(),this._debounceTemplate(this._ren
der);else if("items.splices"==e.path)this._keySplices=this._keySplices.concat(e.
value.keySplices),this._indexSplices=this._indexSplices.concat(e.value.indexSpli
ces),this._debounceTemplate(this._render);else{var t=e.path.slice(6);this._forwa
rdItemPath(t,e.value),this._checkObservedPaths(t)}},_checkObservedPaths:function
(e){if(this._observePaths){e=e.substring(e.indexOf(".")+1);for(var t=this._obser
vePaths,n=0;n<t.length;n++)if(0===e.indexOf(t[n]))return this._needFullRefresh=!
0,void(this.delay?this.debounce("render",this._render,this.delay):this._debounce
Template(this._render))}},render:function(){this._needFullRefresh=!0,this._debou
nceTemplate(this._render),this._flushTemplates()},_render:function(){this._needF
ullRefresh?(this._applyFullRefresh(),this._needFullRefresh=!1):this._keySplices.
length&&(this._sortFn?this._applySplicesUserSort(this._keySplices):this._filterF
n?this._applyFullRefresh():this._applySplicesArrayOrder(this._indexSplices)),thi
s._keySplices=[],this._indexSplices=[];for(var e=this._keyToInstIdx={},t=this._i
nstances.length-1;t>=0;t--){var n=this._instances[t];n.isPlaceholder&&t<this._li
mit?n=this._insertInstance(t,n.__key__):!n.isPlaceholder&&t>=this._limit&&(n=thi
s._downgradeInstance(t,n.__key__)),e[n.__key__]=t,n.isPlaceholder||n.__setProper
ty(this.indexAs,t,!0)}this._pool.length=0,this._setRenderedItemCount(this._insta
nces.length),this.fire("dom-change"),this._tryRenderChunk()},_applyFullRefresh:f
unction(){var e,t=this.collection;if(this._sortFn)e=t?t.getKeys():[];else{e=[];v
ar n=this.items;if(n)for(var r=0;r<n.length;r++)e.push(t.getKey(n[r]))}var s=thi
s;for(this._filterFn&&(e=e.filter(function(e){return s._filterFn(t.getItem(e))})
),this._sortFn&&e.sort(function(e,n){return s._sortFn(t.getItem(e),t.getItem(n))
}),r=0;r<e.length;r++){var i=e[r],o=this._instances[r];o?(o.__key__=i,!o.isPlace
holder&&r<this._limit&&o.__setProperty(this.as,t.getItem(i),!0)):r<this._limit?t
his._insertInstance(r,i):this._insertPlaceholder(r,i)}for(var a=this._instances.
length-1;a>=r;a--)this._detachAndRemoveInstance(a)},_numericSort:function(e,t){r
eturn e-t},_applySplicesUserSort:function(e){for(var t,n,r=this.collection,s={},
i=0;i<e.length&&(n=e[i]);i++){for(var o=0;o<n.removed.length;o++)t=n.removed[o],
s[t]=s[t]?null:-1;for(o=0;o<n.added.length;o++)t=n.added[o],s[t]=s[t]?null:1}var
a=[],l=[];for(t in s)s[t]===-1&&a.push(this._keyToInstIdx[t]),1===s[t]&&l.push(
t);if(a.length)for(a.sort(this._numericSort),i=a.length-1;i>=0;i--){var c=a[i];v
oid 0!==c&&this._detachAndRemoveInstance(c)}var h=this;if(l.length){this._filter
Fn&&(l=l.filter(function(e){return h._filterFn(r.getItem(e))})),l.sort(function(
e,t){return h._sortFn(r.getItem(e),r.getItem(t))});var u=0;for(i=0;i<l.length;i+
+)u=this._insertRowUserSort(u,l[i])}},_insertRowUserSort:function(e,t){for(var n
=this.collection,r=n.getItem(t),s=this._instances.length-1,i=-1;e<=s;){var o=e+s
>>1,a=this._instances[o].__key__,l=this._sortFn(n.getItem(a),r);if(l<0)e=o+1;els
e{if(!(l>0)){i=o;break}s=o-1}}return i<0&&(i=s+1),this._insertPlaceholder(i,t),i
},_applySplicesArrayOrder:function(e){for(var t,n=0;n<e.length&&(t=e[n]);n++){fo
r(var r=0;r<t.removed.length;r++)this._detachAndRemoveInstance(t.index);for(r=0;
r<t.addedKeys.length;r++)this._insertPlaceholder(t.index+r,t.addedKeys[r])}},_de
tachInstance:function(e){var t=this._instances[e];if(!t.isPlaceholder){for(var n
=0;n<t._children.length;n++){var r=t._children[n];Polymer.dom(t.root).appendChil
d(r)}return t}},_attachInstance:function(e,t){var n=this._instances[e];n.isPlace
holder||t.insertBefore(n.root,this)},_detachAndRemoveInstance:function(e){var t=
this._detachInstance(e);t&&this._pool.push(t),this._instances.splice(e,1)},_inse
rtPlaceholder:function(e,t){this._instances.splice(e,0,{isPlaceholder:!0,__key__
:t})},_stampInstance:function(e,t){var n={__key__:t};return n[this.as]=this.coll
ection.getItem(t),n[this.indexAs]=e,this.stamp(n)},_insertInstance:function(e,t)
{var n=this._pool.pop();n?(n.__setProperty(this.as,this.collection.getItem(t),!0
),n.__setProperty("__key__",t,!0)):n=this._stampInstance(e,t);var r=this._instan
ces[e+1],s=r&&!r.isPlaceholder?r._children[0]:this,i=Polymer.dom(this).parentNod
e;return Polymer.dom(i).insertBefore(n.root,s),this._instances[e]=n,n},_downgrad
eInstance:function(e,t){var n=this._detachInstance(e);return n&&this._pool.push(
n),n={isPlaceholder:!0,__key__:t},this._instances[e]=n,n},_showHideChildren:func
tion(e){for(var t=0;t<this._instances.length;t++)this._instances[t]._showHideChi
ldren(e)},_forwardInstanceProp:function(e,t,n){if(t==this.as){var r;r=this._sort
Fn||this._filterFn?this.items.indexOf(this.collection.getItem(e.__key__)):e[this
.indexAs],this.set("items."+r,n)}},_forwardInstancePath:function(e,t,n){0===t.in
dexOf(this.as+".")&&this._notifyPath("items."+e.__key__+"."+t.slice(this.as.leng
th+1),n)},_forwardParentProp:function(e,t){for(var n,r=this._instances,s=0;s<r.l
ength&&(n=r[s]);s++)n.isPlaceholder||n.__setProperty(e,t,!0)},_forwardParentPath
:function(e,t){for(var n,r=this._instances,s=0;s<r.length&&(n=r[s]);s++)n.isPlac
eholder||n._notifyPath(e,t,!0)},_forwardItemPath:function(e,t){if(this._keyToIns
tIdx){var n=e.indexOf("."),r=e.substring(0,n<0?e.length:n),s=this._keyToInstIdx[
r],i=this._instances[s];i&&!i.isPlaceholder&&(n>=0?(e=this.as+"."+e.substring(n+
1),i._notifyPath(e,t,!0)):i.__setProperty(this.as,t,!0))}},itemForElement:functi
on(e){var t=this.modelForElement(e);return t&&t[this.as]},keyForElement:function
(e){var t=this.modelForElement(e);return t&&t.__key__},indexForElement:function(
e){var t=this.modelForElement(e);return t&&t[this.indexAs]}}),Polymer({is:"array
-selector",_template:null,properties:{items:{type:Array,observer:"clearSelection
"},multi:{type:Boolean,value:!1,observer:"clearSelection"},selected:{type:Object
,notify:!0},selectedItem:{type:Object,notify:!0},toggle:{type:Boolean,value:!1}}
,clearSelection:function(){if(Array.isArray(this.selected))for(var e=0;e<this.se
lected.length;e++)this.unlinkPaths("selected."+e);else this.unlinkPaths("selecte
d"),this.unlinkPaths("selectedItem");this.multi?this.selected&&!this.selected.le
ngth||(this.selected=[],this._selectedColl=Polymer.Collection.get(this.selected)
):(this.selected=null,this._selectedColl=null),this.selectedItem=null},isSelecte
d:function(e){return this.multi?void 0!==this._selectedColl.getKey(e):this.selec
ted==e},deselect:function(e){if(this.multi){if(this.isSelected(e)){var t=this._s
electedColl.getKey(e);this.arrayDelete("selected",e),this.unlinkPaths("selected.
"+t)}}else this.selected=null,this.selectedItem=null,this.unlinkPaths("selected"
),this.unlinkPaths("selectedItem")},select:function(e){var t=Polymer.Collection.
get(this.items),n=t.getKey(e);if(this.multi)if(this.isSelected(e))this.toggle&&t
his.deselect(e);else{this.push("selected",e);var r=this._selectedColl.getKey(e);
this.linkPaths("selected."+r,"items."+n)}else this.toggle&&e==this.selected?this
.deselect():(this.selected=e,this.selectedItem=e,this.linkPaths("selected","item
s."+n),this.linkPaths("selectedItem","items."+n))}}),Polymer({is:"dom-if",extend
s:"template",_template:null,properties:{if:{type:Boolean,value:!1,observer:"_que
ueRender"},restamp:{type:Boolean,value:!1,observer:"_queueRender"}},behaviors:[P
olymer.Templatizer],_queueRender:function(){this._debounceTemplate(this._render)
},detached:function(){this.parentNode&&(this.parentNode.nodeType!=Node.DOCUMENT_
FRAGMENT_NODE||Polymer.Settings.hasShadow&&this.parentNode instanceof ShadowRoot
)||this._teardownInstance()},attached:function(){this.if&&this.ctor&&this.async(
this._ensureInstance)},render:function(){this._flushTemplates()},_render:functio
n(){this.if?(this.ctor||this.templatize(this),this._ensureInstance(),this._showH
ideChildren()):this.restamp&&this._teardownInstance(),!this.restamp&&this._insta
nce&&this._showHideChildren(),this.if!=this._lastIf&&(this.fire("dom-change"),th
is._lastIf=this.if)},_ensureInstance:function(){var e=Polymer.dom(this).parentNo
de;if(e){var t=Polymer.dom(e);if(this._instance){var n=this._instance._children;
if(n&&n.length){var r=Polymer.dom(this).previousSibling;if(r!==n[n.length-1])for
(var s,i=0;i<n.length&&(s=n[i]);i++)t.insertBefore(s,this)}}else{this._instance=
this.stamp();var o=this._instance.root;t.insertBefore(o,this)}}},_teardownInstan
ce:function(){if(this._instance){var e=this._instance._children;if(e&&e.length)f
or(var t,n=Polymer.dom(Polymer.dom(e[0]).parentNode),r=0;r<e.length&&(t=e[r]);r+
+)n.removeChild(t);this._instance=null}},_showHideChildren:function(){var e=this
.__hideTemplateChildren__||!this.if;this._instance&&this._instance._showHideChil
dren(e)},_forwardParentProp:function(e,t){this._instance&&this._instance.__setPr
operty(e,t,!0)},_forwardParentPath:function(e,t){this._instance&&this._instance.
_notifyPath(e,t,!0)}}),Polymer({is:"dom-bind",extends:"template",_template:null,
created:function(){var e=this;Polymer.RenderStatus.whenReady(function(){"loading
"==document.readyState?document.addEventListener("DOMContentLoaded",function(){e
._markImportsReady()}):e._markImportsReady()})},_ensureReady:function(){this._re
adied||this._readySelf()},_markImportsReady:function(){this._importsReady=!0,thi
s._ensureReady()},_registerFeatures:function(){this._prepConstructor()},_insertC
hildren:function(){var e=Polymer.dom(Polymer.dom(this).parentNode);e.insertBefor
e(this.root,this)},_removeChildren:function(){if(this._children)for(var e=0;e<th
is._children.length;e++)this.root.appendChild(this._children[e])},_initFeatures:
function(){},_scopeElementClass:function(e,t){return this.dataHost?this.dataHost
._scopeElementClass(e,t):t},_configureInstanceProperties:function(){},_prepConfi
gure:function(){var e={};for(var t in this._propertyEffects)e[t]=this[t];var n=t
his._setupConfigure;this._setupConfigure=function(){n.call(this,e)}},attached:fu
nction(){this._importsReady&&this.render()},detached:function(){this._removeChil
dren()},render:function(){this._ensureReady(),this._children||(this._template=th
is,this._prepAnnotations(),this._prepEffects(),this._prepBehaviors(),this._prepC
onfigure(),this._prepBindings(),this._prepPropertyInfo(),Polymer.Base._initFeatu
res.call(this),this._children=Polymer.TreeApi.arrayCopyChildNodes(this.root)),th
is._insertChildren(),this.fire("dom-change")}})</script> <script> window.Swarmin
gBehaviors = window.SwarmingBehaviors || {}; | 4 },customStyle:null,getComputedStyleValue:function(e){return!i&&this._styleProper
ties&&this._styleProperties[e]||getComputedStyle(this).getPropertyValue(e)},_set
upStyleProperties:function(){this.customStyle={},this._styleCache=null,this._sty
leProperties=null,this._scopeSelector=null,this._ownStyleProperties=null,this._c
ustomStyle=null},_needsStyleProperties:function(){return Boolean(!i&&this._ownSt
ylePropertyNames&&this._ownStylePropertyNames.length)},_validateApplyShim:functi
on(){if(this.__applyShimInvalid){Polymer.ApplyShim.transform(this._styles,this._
_proto__);var e=n.elementStyles(this);if(s){var t=this._template.content.querySe
lector("style");t&&(t.textContent=e)}else{var r=this._scopeStyle&&this._scopeSty
le.nextSibling;r&&(r.textContent=e)}}},_beforeAttached:function(){this._scopeSel
ector&&!this.__stylePropertiesInvalid||!this._needsStyleProperties()||(this.__st
ylePropertiesInvalid=!1,this._updateStyleProperties())},_findStyleHost:function(
){for(var e,t=this;e=Polymer.dom(t).getOwnerRoot();){if(Polymer.isInstance(e.hos
t))return e.host;t=e.host}return r},_updateStyleProperties:function(){var e,n=th
is._findStyleHost();n._styleProperties||n._computeStyleProperties(),n._styleCach
e||(n._styleCache=new Polymer.StyleCache);var r=t.propertyDataFromStyles(n._styl
es,this),i=!this.__notStyleScopeCacheable;i&&(r.key.customStyle=this.customStyle
,e=n._styleCache.retrieve(this.is,r.key,this._styles));var a=Boolean(e);a?this._
styleProperties=e._styleProperties:this._computeStyleProperties(r.properties),th
is._computeOwnStyleProperties(),a||(e=o.retrieve(this.is,this._ownStylePropertie
s,this._styles));var l=Boolean(e)&&!a,c=this._applyStyleProperties(e);a||(c=c&&s
?c.cloneNode(!0):c,e={style:c,_scopeSelector:this._scopeSelector,_stylePropertie
s:this._styleProperties},i&&(r.key.customStyle={},this.mixin(r.key.customStyle,t
his.customStyle),n._styleCache.store(this.is,e,r.key,this._styles)),l||o.store(t
his.is,Object.create(e),this._ownStyleProperties,this._styles))},_computeStylePr
operties:function(e){var n=this._findStyleHost();n._styleProperties||n._computeS
tyleProperties();var r=Object.create(n._styleProperties),s=t.hostAndRootProperti
esForScope(this);this.mixin(r,s.hostProps),e=e||t.propertyDataFromStyles(n._styl
es,this).properties,this.mixin(r,e),this.mixin(r,s.rootProps),t.mixinCustomStyle
(r,this.customStyle),t.reify(r),this._styleProperties=r},_computeOwnStylePropert
ies:function(){for(var e,t={},n=0;n<this._ownStylePropertyNames.length;n++)e=thi
s._ownStylePropertyNames[n],t[e]=this._styleProperties[e];this._ownStyleProperti
es=t},_scopeCount:0,_applyStyleProperties:function(e){var n=this._scopeSelector;
this._scopeSelector=e?e._scopeSelector:this.is+"-"+this.__proto__._scopeCount++;
var r=t.applyElementStyle(this,this._styleProperties,this._scopeSelector,e&&e.st
yle);return s||t.applyElementScopeSelector(this,this._scopeSelector,n,this._scop
eCssViaAttr),r},serializeValueToAttribute:function(t,n,r){if(r=r||this,"class"==
=n&&!s){var i=r===this?this.domHost||this.dataHost:this;i&&(t=i._scopeElementCla
ss(r,t))}r=this.shadyRoot&&this.shadyRoot._hasDistributed?Polymer.dom(r):r,e.cal
l(this,t,n,r)},_scopeElementClass:function(e,t){return s||this._scopeCssViaAttr|
|(t=(t?t+" ":"")+a+" "+this.is+(e._scopeSelector?" "+l+" "+e._scopeSelector:""))
,t},updateStyles:function(e){e&&this.mixin(this.customStyle,e),i?t.updateNativeS
tyleProperties(this,this.customStyle):(this.isAttached?this._needsStylePropertie
s()?this._updateStyleProperties():this._styleProperties=null:this.__stylePropert
iesInvalid=!0,this._styleCache&&this._styleCache.clear(),this._updateRootStyles(
))},_updateRootStyles:function(e){e=e||this.root;for(var t,n=Polymer.dom(e)._que
ry(function(e){return e.shadyRoot||e.shadowRoot}),r=0,s=n.length;r<s&&(t=n[r]);r
++)t.updateStyles&&t.updateStyles()}}),Polymer.updateStyles=function(e){r.update
Styles(e),Polymer.Base._updateRootStyles(document)};var o=new Polymer.StyleCache
;Polymer.customStyleCache=o;var a=n.SCOPE_NAME,l=t.XSCOPE_NAME}(),Polymer.Base._
addFeature({_registerFeatures:function(){this._prepIs(),this._prepConstructor(),
this._prepStyles()},_finishRegisterFeatures:function(){this._prepTemplate(),this
._prepShimStyles(),this._prepAnnotations(),this._prepEffects(),this._prepBehavio
rs(),this._prepPropertyInfo(),this._prepBindings(),this._prepShady()},_prepBehav
ior:function(e){this._addPropertyEffects(e.properties),this._addComplexObserverE
ffects(e.observers),this._addHostAttributes(e.hostAttributes)},_initFeatures:fun
ction(){this._setupGestures(),this._setupConfigure(),this._setupStyleProperties(
),this._setupDebouncers(),this._setupShady(),this._registerHost(),this._template
&&(this._validateApplyShim(),this._poolContent(),this._beginHosting(),this._stam
pTemplate(),this._endHosting(),this._marshalAnnotationReferences()),this._marsha
lInstanceEffects(),this._marshalBehaviors(),this._marshalHostAttributes(),this._
marshalAttributes(),this._tryReady()},_marshalBehavior:function(e){e.listeners&&
this._listenListeners(e.listeners)}}),function(){var e,t=Polymer.StyleProperties
,n=Polymer.StyleUtil,r=Polymer.CssParse,s=Polymer.StyleDefaults,i=Polymer.StyleT
ransformer,o=Polymer.ApplyShim,a=Polymer.Debounce,l=Polymer.Settings;Polymer({is
:"custom-style",extends:"style",_template:null,properties:{include:String},ready
:function(){this.__appliedElement=this.__appliedElement||this,this.__cssBuild=n.
getCssBuildType(this),this.__appliedElement!==this&&(this.__appliedElement.__css
Build=this.__cssBuild),this._tryApply()},attached:function(){this._tryApply()},_
tryApply:function(){if(!this._appliesToDocument&&this.parentNode&&"dom-module"!=
=this.parentNode.localName){this._appliesToDocument=!0;var e=this.__appliedEleme
nt;if(l.useNativeCSSProperties||(this.__needsUpdateStyles=s.hasStyleProperties()
,s.addStyle(e)),e.textContent||this.include)this._apply(!0);else{var t=this,n=ne
w MutationObserver(function(){n.disconnect(),t._apply(!0)});n.observe(e,{childLi
st:!0})}}},_updateStyles:function(){Polymer.updateStyles()},_apply:function(e){v
ar t=this.__appliedElement;if(this.include&&(t.textContent=n.cssFromModules(this
.include,!0)+t.textContent),t.textContent){var r=this.__cssBuild,s=n.isTargetedB
uild(r);if(!l.useNativeCSSProperties||!s){var a=n.rulesForStyle(t);if(s||(n.forE
achRule(a,function(e){i.documentRule(e)}),l.useNativeCSSProperties&&!r&&o.transf
orm([t])),l.useNativeCSSProperties)t.textContent=n.toCssText(a);else{var c=this,
h=function(){c._flushCustomProperties()};e?Polymer.RenderStatus.whenReady(h):h()
}}}},_flushCustomProperties:function(){this.__needsUpdateStyles?(this.__needsUpd
ateStyles=!1,e=a(e,this._updateStyles)):this._applyCustomProperties()},_applyCus
tomProperties:function(){var e=this.__appliedElement;this._computeStylePropertie
s();var s=this._styleProperties,i=n.rulesForStyle(e);i&&(e.textContent=n.toCssTe
xt(i,function(e){var n=e.cssText=e.parsedCssText;e.propertyInfo&&e.propertyInfo.
cssText&&(n=r.removeCustomPropAssignment(n),e.cssText=t.valueForProperties(n,s))
}))}})}(),Polymer.Templatizer={properties:{__hideTemplateChildren__:{observer:"_
showHideChildren"}},_instanceProps:Polymer.nob,_parentPropPrefix:"_parent_",temp
latize:function(e){if(this._templatized=e,e._content||(e._content=e.content),e._
content._ctor)return this.ctor=e._content._ctor,void this._prepParentProperties(
this.ctor.prototype,e);var t=Object.create(Polymer.Base);this._customPrepAnnotat
ions(t,e),this._prepParentProperties(t,e),t._prepEffects(),this._customPrepEffec
ts(t),t._prepBehaviors(),t._prepPropertyInfo(),t._prepBindings(),t._notifyPathUp
=this._notifyPathUpImpl,t._scopeElementClass=this._scopeElementClassImpl,t.liste
n=this._listenImpl,t._showHideChildren=this._showHideChildrenImpl,t.__setPropert
yOrig=this.__setProperty,t.__setProperty=this.__setPropertyImpl;var n=this._cons
tructorImpl,r=function(e,t){n.call(this,e,t)};r.prototype=t,t.constructor=r,e._c
ontent._ctor=r,this.ctor=r},_getRootDataHost:function(){return this.dataHost&&th
is.dataHost._rootDataHost||this.dataHost},_showHideChildrenImpl:function(e){for(
var t=this._children,n=0;n<t.length;n++){var r=t[n];Boolean(e)!=Boolean(r.__hide
TemplateChildren__)&&(r.nodeType===Node.TEXT_NODE?e?(r.__polymerTextContent__=r.
textContent,r.textContent=""):r.textContent=r.__polymerTextContent__:r.style&&(e
?(r.__polymerDisplay__=r.style.display,r.style.display="none"):r.style.display=r
.__polymerDisplay__)),r.__hideTemplateChildren__=e}},__setPropertyImpl:function(
e,t,n,r){r&&r.__hideTemplateChildren__&&"textContent"==e&&(e="__polymerTextConte
nt__"),this.__setPropertyOrig(e,t,n,r)},_debounceTemplate:function(e){Polymer.do
m.addDebouncer(this.debounce("_debounceTemplate",e))},_flushTemplates:function()
{Polymer.dom.flush()},_customPrepEffects:function(e){var t=e._parentProps;for(va
r n in t)e._addPropertyEffect(n,"function",this._createHostPropEffector(n));for(
n in this._instanceProps)e._addPropertyEffect(n,"function",this._createInstanceP
ropEffector(n))},_customPrepAnnotations:function(e,t){e._template=t;var n=t._con
tent;if(!n._notes){var r=e._rootDataHost;r&&(Polymer.Annotations.prepElement=fun
ction(){r._prepElement()}),n._notes=Polymer.Annotations.parseAnnotations(t),Poly
mer.Annotations.prepElement=null,this._processAnnotations(n._notes)}e._notes=n._
notes,e._parentProps=n._parentProps},_prepParentProperties:function(e,t){var n=t
his._parentProps=e._parentProps;if(this._forwardParentProp&&n){var r,s=e._parent
PropProto;if(!s){for(r in this._instanceProps)delete n[r];s=e._parentPropProto=O
bject.create(null),t!=this&&(Polymer.Bind.prepareModel(s),Polymer.Base.prepareMo
delNotifyPath(s));for(r in n){var i=this._parentPropPrefix+r,o=[{kind:"function"
,effect:this._createForwardPropEffector(r),fn:Polymer.Bind._functionEffect},{kin
d:"notify",fn:Polymer.Bind._notifyEffect,effect:{event:Polymer.CaseMap.camelToDa
shCase(i)+"-changed"}}];Polymer.Bind._createAccessors(s,i,o)}}var a=this;t!=this
&&(Polymer.Bind.prepareInstance(t),t._forwardParentProp=function(e,t){a._forward
ParentProp(e,t)}),this._extendTemplate(t,s),t._pathEffector=function(e,t,n){retu
rn a._pathEffectorImpl(e,t,n)}}},_createForwardPropEffector:function(e){return f
unction(t,n){this._forwardParentProp(e,n)}},_createHostPropEffector:function(e){
var t=this._parentPropPrefix;return function(n,r){this.dataHost._templatized[t+e
]=r}},_createInstancePropEffector:function(e){return function(t,n,r,s){s||this.d
ataHost._forwardInstanceProp(this,e,n)}},_extendTemplate:function(e,t){var n=Obj
ect.getOwnPropertyNames(t);t._propertySetter&&(e._propertySetter=t._propertySett
er);for(var r,s=0;s<n.length&&(r=n[s]);s++){var i=e[r],o=Object.getOwnPropertyDe
scriptor(t,r);Object.defineProperty(e,r,o),void 0!==i&&e._propertySetter(r,i)}},
_showHideChildren:function(e){},_forwardInstancePath:function(e,t,n){},_forwardI
nstanceProp:function(e,t,n){},_notifyPathUpImpl:function(e,t){var n=this.dataHos
t,r=Polymer.Path.root(e);n._forwardInstancePath.call(n,this,e,t),r in n._parentP
rops&&n._templatized._notifyPath(n._parentPropPrefix+e,t)},_pathEffectorImpl:fun
ction(e,t,n){if(this._forwardParentPath&&0===e.indexOf(this._parentPropPrefix)){
var r=e.substring(this._parentPropPrefix.length),s=Polymer.Path.root(r);s in thi
s._parentProps&&this._forwardParentPath(r,t)}Polymer.Base._pathEffector.call(thi
s._templatized,e,t,n)},_constructorImpl:function(e,t){this._rootDataHost=t._getR
ootDataHost(),this._setupConfigure(e),this._registerHost(t),this._beginHosting()
,this.root=this.instanceTemplate(this._template),this.root.__noContent=!this._no
tes._hasContent,this.root.__styleScoped=!0,this._endHosting(),this._marshalAnnot
atedNodes(),this._marshalInstanceEffects(),this._marshalAnnotatedListeners();for
(var n=[],r=this.root.firstChild;r;r=r.nextSibling)n.push(r),r._templateInstance
=this;this._children=n,t.__hideTemplateChildren__&&this._showHideChildren(!0),th
is._tryReady()},_listenImpl:function(e,t,n){var r=this,s=this._rootDataHost,i=s.
_createEventHandler(e,t,n),o=function(e){e.model=r,i(e)};s._listen(e,t,o)},_scop
eElementClassImpl:function(e,t){var n=this._rootDataHost;return n?n._scopeElemen
tClass(e,t):t},stamp:function(e){if(e=e||{},this._parentProps){var t=this._templ
atized;for(var n in this._parentProps)void 0===e[n]&&(e[n]=t[this._parentPropPre
fix+n])}return new this.ctor(e,this)},modelForElement:function(e){for(var t;e;)i
f(t=e._templateInstance){if(t.dataHost==this)return t;e=t.dataHost}else e=e.pare
ntNode}},Polymer({is:"dom-template",extends:"template",_template:null,behaviors:
[Polymer.Templatizer],ready:function(){this.templatize(this)}}),Polymer._collect
ions=new WeakMap,Polymer.Collection=function(e){Polymer._collections.set(e,this)
,this.userArray=e,this.store=e.slice(),this.initMap()},Polymer.Collection.protot
ype={constructor:Polymer.Collection,initMap:function(){for(var e=this.omap=new W
eakMap,t=this.pmap={},n=this.store,r=0;r<n.length;r++){var s=n[r];s&&"object"==t
ypeof s?e.set(s,r):t[s]=r}},add:function(e){var t=this.store.push(e)-1;return e&
&"object"==typeof e?this.omap.set(e,t):this.pmap[e]=t,"#"+t},removeKey:function(
e){(e=this._parseKey(e))&&(this._removeFromMap(this.store[e]),delete this.store[
e])},_removeFromMap:function(e){e&&"object"==typeof e?this.omap.delete(e):delete
this.pmap[e]},remove:function(e){var t=this.getKey(e);return this.removeKey(t),
t},getKey:function(e){var t;if(t=e&&"object"==typeof e?this.omap.get(e):this.pma
p[e],void 0!=t)return"#"+t},getKeys:function(){return Object.keys(this.store).ma
p(function(e){return"#"+e})},_parseKey:function(e){if(e&&"#"==e[0])return e.slic
e(1)},setItem:function(e,t){if(e=this._parseKey(e)){var n=this.store[e];n&&this.
_removeFromMap(n),t&&"object"==typeof t?this.omap.set(t,e):this.pmap[t]=e,this.s
tore[e]=t}},getItem:function(e){if(e=this._parseKey(e))return this.store[e]},get
Items:function(){var e=[],t=this.store;for(var n in t)e.push(t[n]);return e},_ap
plySplices:function(e){for(var t,n,r={},s=0;s<e.length&&(n=e[s]);s++){n.addedKey
s=[];for(var i=0;i<n.removed.length;i++)t=this.getKey(n.removed[i]),r[t]=r[t]?nu
ll:-1;for(i=0;i<n.addedCount;i++){var o=this.userArray[n.index+i];t=this.getKey(
o),t=void 0===t?this.add(o):t,r[t]=r[t]?null:1,n.addedKeys.push(t)}}var a=[],l=[
];for(t in r)r[t]<0&&(this.removeKey(t),a.push(t)),r[t]>0&&l.push(t);return[{rem
oved:a,added:l}]}},Polymer.Collection.get=function(e){return Polymer._collection
s.get(e)||new Polymer.Collection(e)},Polymer.Collection.applySplices=function(e,
t){var n=Polymer._collections.get(e);return n?n._applySplices(t):null},Polymer({
is:"dom-repeat",extends:"template",_template:null,properties:{items:{type:Array}
,as:{type:String,value:"item"},indexAs:{type:String,value:"index"},sort:{type:Fu
nction,observer:"_sortChanged"},filter:{type:Function,observer:"_filterChanged"}
,observe:{type:String,observer:"_observeChanged"},delay:Number,renderedItemCount
:{type:Number,notify:!0,readOnly:!0},initialCount:{type:Number,observer:"_initia
lizeChunking"},targetFramerate:{type:Number,value:20},_targetFrameTime:{type:Num
ber,computed:"_computeFrameTime(targetFramerate)"}},behaviors:[Polymer.Templatiz
er],observers:["_itemsChanged(items.*)"],created:function(){this._instances=[],t
his._pool=[],this._limit=1/0;var e=this;this._boundRenderChunk=function(){e._ren
derChunk()}},detached:function(){this.__isDetached=!0;for(var e=0;e<this._instan
ces.length;e++)this._detachInstance(e)},attached:function(){if(this.__isDetached
){this.__isDetached=!1;for(var e=Polymer.dom(Polymer.dom(this).parentNode),t=0;t
<this._instances.length;t++)this._attachInstance(t,e)}},ready:function(){this._i
nstanceProps={__key__:!0},this._instanceProps[this.as]=!0,this._instanceProps[th
is.indexAs]=!0,this.ctor||this.templatize(this)},_sortChanged:function(e){var t=
this._getRootDataHost();this._sortFn=e&&("function"==typeof e?e:function(){retur
n t[e].apply(t,arguments)}),this._needFullRefresh=!0,this.items&&this._debounceT
emplate(this._render)},_filterChanged:function(e){var t=this._getRootDataHost();
this._filterFn=e&&("function"==typeof e?e:function(){return t[e].apply(t,argumen
ts)}),this._needFullRefresh=!0,this.items&&this._debounceTemplate(this._render)}
,_computeFrameTime:function(e){return Math.ceil(1e3/e)},_initializeChunking:func
tion(){this.initialCount&&(this._limit=this.initialCount,this._chunkCount=this.i
nitialCount,this._lastChunkTime=performance.now())},_tryRenderChunk:function(){t
his.items&&this._limit<this.items.length&&this.debounce("renderChunk",this._requ
estRenderChunk)},_requestRenderChunk:function(){requestAnimationFrame(this._boun
dRenderChunk)},_renderChunk:function(){var e=performance.now(),t=this._targetFra
meTime/(e-this._lastChunkTime);this._chunkCount=Math.round(this._chunkCount*t)||
1,this._limit+=this._chunkCount,this._lastChunkTime=e,this._debounceTemplate(thi
s._render)},_observeChanged:function(){this._observePaths=this.observe&&this.obs
erve.replace(".*",".").split(" ")},_itemsChanged:function(e){if("items"==e.path)
Array.isArray(this.items)?this.collection=Polymer.Collection.get(this.items):thi
s.items?this._error(this._logf("dom-repeat","expected array for `items`, found",
this.items)):this.collection=null,this._keySplices=[],this._indexSplices=[],this
._needFullRefresh=!0,this._initializeChunking(),this._debounceTemplate(this._ren
der);else if("items.splices"==e.path)this._keySplices=this._keySplices.concat(e.
value.keySplices),this._indexSplices=this._indexSplices.concat(e.value.indexSpli
ces),this._debounceTemplate(this._render);else{var t=e.path.slice(6);this._forwa
rdItemPath(t,e.value),this._checkObservedPaths(t)}},_checkObservedPaths:function
(e){if(this._observePaths){e=e.substring(e.indexOf(".")+1);for(var t=this._obser
vePaths,n=0;n<t.length;n++)if(0===e.indexOf(t[n]))return this._needFullRefresh=!
0,void(this.delay?this.debounce("render",this._render,this.delay):this._debounce
Template(this._render))}},render:function(){this._needFullRefresh=!0,this._debou
nceTemplate(this._render),this._flushTemplates()},_render:function(){this._needF
ullRefresh?(this._applyFullRefresh(),this._needFullRefresh=!1):this._keySplices.
length&&(this._sortFn?this._applySplicesUserSort(this._keySplices):this._filterF
n?this._applyFullRefresh():this._applySplicesArrayOrder(this._indexSplices)),thi
s._keySplices=[],this._indexSplices=[];for(var e=this._keyToInstIdx={},t=this._i
nstances.length-1;t>=0;t--){var n=this._instances[t];n.isPlaceholder&&t<this._li
mit?n=this._insertInstance(t,n.__key__):!n.isPlaceholder&&t>=this._limit&&(n=thi
s._downgradeInstance(t,n.__key__)),e[n.__key__]=t,n.isPlaceholder||n.__setProper
ty(this.indexAs,t,!0)}this._pool.length=0,this._setRenderedItemCount(this._insta
nces.length),this.fire("dom-change"),this._tryRenderChunk()},_applyFullRefresh:f
unction(){var e,t=this.collection;if(this._sortFn)e=t?t.getKeys():[];else{e=[];v
ar n=this.items;if(n)for(var r=0;r<n.length;r++)e.push(t.getKey(n[r]))}var s=thi
s;for(this._filterFn&&(e=e.filter(function(e){return s._filterFn(t.getItem(e))})
),this._sortFn&&e.sort(function(e,n){return s._sortFn(t.getItem(e),t.getItem(n))
}),r=0;r<e.length;r++){var i=e[r],o=this._instances[r];o?(o.__key__=i,!o.isPlace
holder&&r<this._limit&&o.__setProperty(this.as,t.getItem(i),!0)):r<this._limit?t
his._insertInstance(r,i):this._insertPlaceholder(r,i)}for(var a=this._instances.
length-1;a>=r;a--)this._detachAndRemoveInstance(a)},_numericSort:function(e,t){r
eturn e-t},_applySplicesUserSort:function(e){for(var t,n,r=this.collection,s={},
i=0;i<e.length&&(n=e[i]);i++){for(var o=0;o<n.removed.length;o++)t=n.removed[o],
s[t]=s[t]?null:-1;for(o=0;o<n.added.length;o++)t=n.added[o],s[t]=s[t]?null:1}var
a=[],l=[];for(t in s)s[t]===-1&&a.push(this._keyToInstIdx[t]),1===s[t]&&l.push(
t);if(a.length)for(a.sort(this._numericSort),i=a.length-1;i>=0;i--){var c=a[i];v
oid 0!==c&&this._detachAndRemoveInstance(c)}var h=this;if(l.length){this._filter
Fn&&(l=l.filter(function(e){return h._filterFn(r.getItem(e))})),l.sort(function(
e,t){return h._sortFn(r.getItem(e),r.getItem(t))});var u=0;for(i=0;i<l.length;i+
+)u=this._insertRowUserSort(u,l[i])}},_insertRowUserSort:function(e,t){for(var n
=this.collection,r=n.getItem(t),s=this._instances.length-1,i=-1;e<=s;){var o=e+s
>>1,a=this._instances[o].__key__,l=this._sortFn(n.getItem(a),r);if(l<0)e=o+1;els
e{if(!(l>0)){i=o;break}s=o-1}}return i<0&&(i=s+1),this._insertPlaceholder(i,t),i
},_applySplicesArrayOrder:function(e){for(var t,n=0;n<e.length&&(t=e[n]);n++){fo
r(var r=0;r<t.removed.length;r++)this._detachAndRemoveInstance(t.index);for(r=0;
r<t.addedKeys.length;r++)this._insertPlaceholder(t.index+r,t.addedKeys[r])}},_de
tachInstance:function(e){var t=this._instances[e];if(!t.isPlaceholder){for(var n
=0;n<t._children.length;n++){var r=t._children[n];Polymer.dom(t.root).appendChil
d(r)}return t}},_attachInstance:function(e,t){var n=this._instances[e];n.isPlace
holder||t.insertBefore(n.root,this)},_detachAndRemoveInstance:function(e){var t=
this._detachInstance(e);t&&this._pool.push(t),this._instances.splice(e,1)},_inse
rtPlaceholder:function(e,t){this._instances.splice(e,0,{isPlaceholder:!0,__key__
:t})},_stampInstance:function(e,t){var n={__key__:t};return n[this.as]=this.coll
ection.getItem(t),n[this.indexAs]=e,this.stamp(n)},_insertInstance:function(e,t)
{var n=this._pool.pop();n?(n.__setProperty(this.as,this.collection.getItem(t),!0
),n.__setProperty("__key__",t,!0)):n=this._stampInstance(e,t);var r=this._instan
ces[e+1],s=r&&!r.isPlaceholder?r._children[0]:this,i=Polymer.dom(this).parentNod
e;return Polymer.dom(i).insertBefore(n.root,s),this._instances[e]=n,n},_downgrad
eInstance:function(e,t){var n=this._detachInstance(e);return n&&this._pool.push(
n),n={isPlaceholder:!0,__key__:t},this._instances[e]=n,n},_showHideChildren:func
tion(e){for(var t=0;t<this._instances.length;t++)this._instances[t]._showHideChi
ldren(e)},_forwardInstanceProp:function(e,t,n){if(t==this.as){var r;r=this._sort
Fn||this._filterFn?this.items.indexOf(this.collection.getItem(e.__key__)):e[this
.indexAs],this.set("items."+r,n)}},_forwardInstancePath:function(e,t,n){0===t.in
dexOf(this.as+".")&&this._notifyPath("items."+e.__key__+"."+t.slice(this.as.leng
th+1),n)},_forwardParentProp:function(e,t){for(var n,r=this._instances,s=0;s<r.l
ength&&(n=r[s]);s++)n.isPlaceholder||n.__setProperty(e,t,!0)},_forwardParentPath
:function(e,t){for(var n,r=this._instances,s=0;s<r.length&&(n=r[s]);s++)n.isPlac
eholder||n._notifyPath(e,t,!0)},_forwardItemPath:function(e,t){if(this._keyToIns
tIdx){var n=e.indexOf("."),r=e.substring(0,n<0?e.length:n),s=this._keyToInstIdx[
r],i=this._instances[s];i&&!i.isPlaceholder&&(n>=0?(e=this.as+"."+e.substring(n+
1),i._notifyPath(e,t,!0)):i.__setProperty(this.as,t,!0))}},itemForElement:functi
on(e){var t=this.modelForElement(e);return t&&t[this.as]},keyForElement:function
(e){var t=this.modelForElement(e);return t&&t.__key__},indexForElement:function(
e){var t=this.modelForElement(e);return t&&t[this.indexAs]}}),Polymer({is:"array
-selector",_template:null,properties:{items:{type:Array,observer:"clearSelection
"},multi:{type:Boolean,value:!1,observer:"clearSelection"},selected:{type:Object
,notify:!0},selectedItem:{type:Object,notify:!0},toggle:{type:Boolean,value:!1}}
,clearSelection:function(){if(Array.isArray(this.selected))for(var e=0;e<this.se
lected.length;e++)this.unlinkPaths("selected."+e);else this.unlinkPaths("selecte
d"),this.unlinkPaths("selectedItem");this.multi?this.selected&&!this.selected.le
ngth||(this.selected=[],this._selectedColl=Polymer.Collection.get(this.selected)
):(this.selected=null,this._selectedColl=null),this.selectedItem=null},isSelecte
d:function(e){return this.multi?void 0!==this._selectedColl.getKey(e):this.selec
ted==e},deselect:function(e){if(this.multi){if(this.isSelected(e)){var t=this._s
electedColl.getKey(e);this.arrayDelete("selected",e),this.unlinkPaths("selected.
"+t)}}else this.selected=null,this.selectedItem=null,this.unlinkPaths("selected"
),this.unlinkPaths("selectedItem")},select:function(e){var t=Polymer.Collection.
get(this.items),n=t.getKey(e);if(this.multi)if(this.isSelected(e))this.toggle&&t
his.deselect(e);else{this.push("selected",e);var r=this._selectedColl.getKey(e);
this.linkPaths("selected."+r,"items."+n)}else this.toggle&&e==this.selected?this
.deselect():(this.selected=e,this.selectedItem=e,this.linkPaths("selected","item
s."+n),this.linkPaths("selectedItem","items."+n))}}),Polymer({is:"dom-if",extend
s:"template",_template:null,properties:{if:{type:Boolean,value:!1,observer:"_que
ueRender"},restamp:{type:Boolean,value:!1,observer:"_queueRender"}},behaviors:[P
olymer.Templatizer],_queueRender:function(){this._debounceTemplate(this._render)
},detached:function(){this.parentNode&&(this.parentNode.nodeType!=Node.DOCUMENT_
FRAGMENT_NODE||Polymer.Settings.hasShadow&&this.parentNode instanceof ShadowRoot
)||this._teardownInstance()},attached:function(){this.if&&this.ctor&&this.async(
this._ensureInstance)},render:function(){this._flushTemplates()},_render:functio
n(){this.if?(this.ctor||this.templatize(this),this._ensureInstance(),this._showH
ideChildren()):this.restamp&&this._teardownInstance(),!this.restamp&&this._insta
nce&&this._showHideChildren(),this.if!=this._lastIf&&(this.fire("dom-change"),th
is._lastIf=this.if)},_ensureInstance:function(){var e=Polymer.dom(this).parentNo
de;if(e){var t=Polymer.dom(e);if(this._instance){var n=this._instance._children;
if(n&&n.length){var r=Polymer.dom(this).previousSibling;if(r!==n[n.length-1])for
(var s,i=0;i<n.length&&(s=n[i]);i++)t.insertBefore(s,this)}}else{this._instance=
this.stamp();var o=this._instance.root;t.insertBefore(o,this)}}},_teardownInstan
ce:function(){if(this._instance){var e=this._instance._children;if(e&&e.length)f
or(var t,n=Polymer.dom(Polymer.dom(e[0]).parentNode),r=0;r<e.length&&(t=e[r]);r+
+)n.removeChild(t);this._instance=null}},_showHideChildren:function(){var e=this
.__hideTemplateChildren__||!this.if;this._instance&&this._instance._showHideChil
dren(e)},_forwardParentProp:function(e,t){this._instance&&this._instance.__setPr
operty(e,t,!0)},_forwardParentPath:function(e,t){this._instance&&this._instance.
_notifyPath(e,t,!0)}}),Polymer({is:"dom-bind",extends:"template",_template:null,
created:function(){var e=this;Polymer.RenderStatus.whenReady(function(){"loading
"==document.readyState?document.addEventListener("DOMContentLoaded",function(){e
._markImportsReady()}):e._markImportsReady()})},_ensureReady:function(){this._re
adied||this._readySelf()},_markImportsReady:function(){this._importsReady=!0,thi
s._ensureReady()},_registerFeatures:function(){this._prepConstructor()},_insertC
hildren:function(){var e=Polymer.dom(Polymer.dom(this).parentNode);e.insertBefor
e(this.root,this)},_removeChildren:function(){if(this._children)for(var e=0;e<th
is._children.length;e++)this.root.appendChild(this._children[e])},_initFeatures:
function(){},_scopeElementClass:function(e,t){return this.dataHost?this.dataHost
._scopeElementClass(e,t):t},_configureInstanceProperties:function(){},_prepConfi
gure:function(){var e={};for(var t in this._propertyEffects)e[t]=this[t];var n=t
his._setupConfigure;this._setupConfigure=function(){n.call(this,e)}},attached:fu
nction(){this._importsReady&&this.render()},detached:function(){this._removeChil
dren()},render:function(){this._ensureReady(),this._children||(this._template=th
is,this._prepAnnotations(),this._prepEffects(),this._prepBehaviors(),this._prepC
onfigure(),this._prepBindings(),this._prepPropertyInfo(),Polymer.Base._initFeatu
res.call(this),this._children=Polymer.TreeApi.arrayCopyChildNodes(this.root)),th
is._insertChildren(),this.fire("dom-change")}})</script> <script> window.Swarmin
gBehaviors = window.SwarmingBehaviors || {}; |
| 5 (function(){ | 5 (function(){ |
| 6 // This behavior wraps up all the shared swarming functionality. | 6 // This behavior wraps up all the shared swarming functionality. |
| 7 SwarmingBehaviors.CommonBehavior = { | 7 SwarmingBehaviors.CommonBehavior = { |
| 8 | 8 |
| 9 _botLink: function(bot_id) { | 9 _botLink: function(bot_id) { |
| 10 if (!bot_id) { | 10 if (!bot_id) { |
| (...skipping 695 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 706 | 706 |
| 707 _reload: function() { | 707 _reload: function() { |
| 708 if (!this._auth_headers || !this._query_params) { | 708 if (!this._auth_headers || !this._query_params) { |
| 709 return; | 709 return; |
| 710 } | 710 } |
| 711 var url = "/api/swarming/v1/bots/list?" + sk.query.fromParamSet(this._qu
ery_params); | 711 var url = "/api/swarming/v1/bots/list?" + sk.query.fromParamSet(this._qu
ery_params); |
| 712 this.$.page_bots.load(url,this._auth_headers); | 712 this.$.page_bots.load(url,this._auth_headers); |
| 713 } | 713 } |
| 714 | 714 |
| 715 }); | 715 }); |
| 716 })(); </script> </dom-module> <dom-module id="paper-button" assetpath="/res/im
p/bower_components/paper-button/"> <template strip-whitespace=""> <style include
="paper-material-shared-styles">:host{@apply(--layout-inline);@apply(--layout-ce
nter-center);position:relative;box-sizing:border-box;min-width:5.14em;margin:0 .
29em;background:0 0;-webkit-tap-highlight-color:transparent;-webkit-tap-highligh
t-color:transparent;font:inherit;text-transform:uppercase;outline-width:0;border
-radius:3px;-moz-user-select:none;-ms-user-select:none;-webkit-user-select:none;
user-select:none;cursor:pointer;z-index:0;padding:.7em .57em;@apply(--paper-font
-common-base);@apply(--paper-button)}:host([hidden]){display:none!important}:hos
t([raised].keyboard-focus){font-weight:700;@apply(--paper-button-raised-keyboard
-focus)}:host(:not([raised]).keyboard-focus){font-weight:700;@apply(--paper-butt
on-flat-keyboard-focus)}:host([disabled]){background:#eaeaea;color:#a8a8a8;curso
r:auto;pointer-events:none;@apply(--paper-button-disabled)}:host([animated]){@ap
ply(--shadow-transition)}paper-ripple{color:var(--paper-button-ink-color)}</styl
e> <content></content> </template> <script>Polymer({is:"paper-button",behaviors:
[Polymer.PaperButtonBehavior],properties:{raised:{type:Boolean,reflectToAttribut
e:!0,value:!1,observer:"_calculateElevation"}},_calculateElevation:function(){th
is.raised?Polymer.PaperButtonBehaviorImpl._calculateElevation.apply(this):this._
setElevation(0)}})</script> </dom-module> <script>Polymer.NeonAnimatableBehavior
={properties:{animationConfig:{type:Object},entryAnimation:{observer:"_entryAnim
ationChanged",type:String},exitAnimation:{observer:"_exitAnimationChanged",type:
String}},_entryAnimationChanged:function(){this.animationConfig=this.animationCo
nfig||{},this.animationConfig.entry=[{name:this.entryAnimation,node:this}]},_exi
tAnimationChanged:function(){this.animationConfig=this.animationConfig||{},this.
animationConfig.exit=[{name:this.exitAnimation,node:this}]},_copyProperties:func
tion(i,n){for(var t in n)i[t]=n[t]},_cloneConfig:function(i){var n={isClone:!0};
return this._copyProperties(n,i),n},_getAnimationConfigRecursive:function(i,n,t)
{if(this.animationConfig){if(this.animationConfig.value&&"function"==typeof this
.animationConfig.value)return void this._warn(this._logf("playAnimation","Please
put 'animationConfig' inside of your components 'properties' object instead of
outside of it."));var o;if(o=i?this.animationConfig[i]:this.animationConfig,Arra
y.isArray(o)||(o=[o]),o)for(var e,a=0;e=o[a];a++)if(e.animatable)e.animatable._g
etAnimationConfigRecursive(e.type||i,n,t);else if(e.id){var r=n[e.id];r?(r.isClo
ne||(n[e.id]=this._cloneConfig(r),r=n[e.id]),this._copyProperties(r,e)):n[e.id]=
e}else t.push(e)}},getAnimationConfig:function(i){var n={},t=[];this._getAnimati
onConfigRecursive(i,n,t);for(var o in n)t.push(n[o]);return t}}</script> <script
>Polymer.NeonAnimationRunnerBehaviorImpl={_configureAnimations:function(n){var i
=[];if(n.length>0)for(var e,t=0;e=n[t];t++){var o=document.createElement(e.name)
;if(o.isNeonAnimation){var a=null;try{a=o.configure(e),"function"!=typeof a.canc
el&&(a=document.timeline.play(a))}catch(n){a=null,console.warn("Couldnt play","(
",e.name,").",n)}a&&i.push({neonAnimation:o,config:e,animation:a})}else console.
warn(this.is+":",e.name,"not found!")}return i},_shouldComplete:function(n){for(
var i=!0,e=0;e<n.length;e++)if("finished"!=n[e].animation.playState){i=!1;break}
return i},_complete:function(n){for(var i=0;i<n.length;i++)n[i].neonAnimation.co
mplete(n[i].config);for(var i=0;i<n.length;i++)n[i].animation.cancel()},playAnim
ation:function(n,i){var e=this.getAnimationConfig(n);if(e){this._active=this._ac
tive||{},this._active[n]&&(this._complete(this._active[n]),delete this._active[n
]);var t=this._configureAnimations(e);if(0==t.length)return void this.fire("neon
-animation-finish",i,{bubbles:!1});this._active[n]=t;for(var o=0;o<t.length;o++)
t[o].animation.onfinish=function(){this._shouldComplete(t)&&(this._complete(t),d
elete this._active[n],this.fire("neon-animation-finish",i,{bubbles:!1}))}.bind(t
his)}},cancelAnimation:function(){for(var n in this._animations)this._animations
[n].cancel();this._animations={}}},Polymer.NeonAnimationRunnerBehavior=[Polymer.
NeonAnimatableBehavior,Polymer.NeonAnimationRunnerBehaviorImpl]</script> <script
>Polymer.PaperDialogBehaviorImpl={hostAttributes:{role:"dialog",tabindex:"-1"},p
roperties:{modal:{type:Boolean,value:!1}},observers:["_modalChanged(modal, _read
ied)"],listeners:{tap:"_onDialogClick"},ready:function(){this.__prevNoCancelOnOu
tsideClick=this.noCancelOnOutsideClick,this.__prevNoCancelOnEscKey=this.noCancel
OnEscKey,this.__prevWithBackdrop=this.withBackdrop},_modalChanged:function(i,e){
e&&(i?(this.__prevNoCancelOnOutsideClick=this.noCancelOnOutsideClick,this.__prev
NoCancelOnEscKey=this.noCancelOnEscKey,this.__prevWithBackdrop=this.withBackdrop
,this.noCancelOnOutsideClick=!0,this.noCancelOnEscKey=!0,this.withBackdrop=!0):(
this.noCancelOnOutsideClick=this.noCancelOnOutsideClick&&this.__prevNoCancelOnOu
tsideClick,this.noCancelOnEscKey=this.noCancelOnEscKey&&this.__prevNoCancelOnEsc
Key,this.withBackdrop=this.withBackdrop&&this.__prevWithBackdrop))},_updateClosi
ngReasonConfirmed:function(i){this.closingReason=this.closingReason||{},this.clo
singReason.confirmed=i},_onDialogClick:function(i){for(var e=Polymer.dom(i).path
,o=0;o<e.indexOf(this);o++){var t=e[o];if(t.hasAttribute&&(t.hasAttribute("dialo
g-dismiss")||t.hasAttribute("dialog-confirm"))){this._updateClosingReasonConfirm
ed(t.hasAttribute("dialog-confirm")),this.close(),i.stopPropagation();break}}}},
Polymer.PaperDialogBehavior=[Polymer.IronOverlayBehavior,Polymer.PaperDialogBeha
viorImpl]</script> <dom-module id="paper-dialog-shared-styles" assetpath="/res/i
mp/bower_components/paper-dialog-behavior/"> <template> <style>:host{display:blo
ck;margin:24px 40px;background:var(--paper-dialog-background-color,--primary-bac
kground-color);color:var(--paper-dialog-color,--primary-text-color);@apply(--pap
er-font-body1);@apply(--shadow-elevation-16dp);@apply(--paper-dialog)}:host>::co
ntent>*{margin-top:20px;padding:0 24px}:host>::content>.no-padding{padding:0}:ho
st>::content>:first-child{margin-top:24px}:host>::content>:last-child{margin-bot
tom:24px}:host>::content h2{position:relative;margin:0;@apply(--paper-font-title
);@apply(--paper-dialog-title)}:host>::content .buttons{position:relative;paddin
g:8px 8px 8px 24px;margin:0;color:var(--paper-dialog-button-color,--primary-colo
r);@apply(--layout-horizontal);@apply(--layout-end-justified)}</style> </templat
e> </dom-module> <dom-module id="paper-dialog" assetpath="/res/imp/bower_compone
nts/paper-dialog/"> <template> <style include="paper-dialog-shared-styles"></sty
le> <content></content> </template> </dom-module> <script>!function(){Polymer({i
s:"paper-dialog",behaviors:[Polymer.PaperDialogBehavior,Polymer.NeonAnimationRun
nerBehavior],listeners:{"neon-animation-finish":"_onNeonAnimationFinish"},_rende
rOpened:function(){this.cancelAnimation(),this.playAnimation("entry")},_renderCl
osed:function(){this.cancelAnimation(),this.playAnimation("exit")},_onNeonAnimat
ionFinish:function(){this.opened?this._finishRenderOpened():this._finishRenderCl
osed()}})}()</script> <script>window.SwarmingBehaviors=window.SwarmingBehaviors|
|{},function(){SwarmingBehaviors.TaskBehavior={properties:{BOT_DIED:{type:String
,value:"BOT_DIED"},CANCELED:{type:String,value:"CANCELED"},COMPLETED:{type:Strin
g,value:"COMPLETED"},COMPLETED_DEDUPED:{type:String,value:"COMPLETED (DEDUPED)"}
,COMPLETED_FAILURE:{type:String,value:"COMPLETED (FAILURE)"},COMPLETED_SUCCESS:{
type:String,value:"COMPLETED (SUCCESS)"},EXPIRED:{type:String,value:"EXPIRED"},P
ENDING:{type:String,value:"PENDING"},RUNNING:{type:String,value:"RUNNING"},TIMED
_OUT:{type:String,value:"TIMED_OUT"}},stateClass:function(t){return t===this.CAN
CELED||t===this.TIMED_OUT||t===this.EXPIRED?"exception":t===this.BOT_DIED?"bot_d
ied":t===this.COMPLETED_FAILURE?"failed_task":t===this.RUNNING||t===this.PENDING
?"pending_task":""},state:function(t){return t?t.state===this.COMPLETED?t.failur
e?this.COMPLETED_FAILURE:"0"===t.try_number?this.COMPLETED_DEDUPED:this.COMPLETE
D_SUCCESS:t.state:""},_stateClass:function(t){return this.stateClass(this.state(
t))}}}()</script> <dom-module id="task-style" assetpath="/res/imp/common/"> <tem
plate> <style>.failed_task{background-color:#fdd}.bot_died{background-color:#ccc
}.exception{background-color:#edd2ff}.pending_task{background-color:#fffc6c}</st
yle> </template> </dom-module><dom-module id="task-filters" assetpath="/res/imp/
tasklist/"> <template> <style is="custom-style" include="iron-flex iron-flex-ali
gnment iron-positioning query-column-filter-style">.item.wide{max-width:400px}.s
elector.wide{min-width:275px}</style> <url-param name="f" value="{{_filters}}" d
efault_values="[]" multi=""> </url-param> <url-param name="c" value="{{columns}}
" default_values="["name","state","created_ts",&qu
ot;user"]" multi=""> </url-param> <url-param name="q" value="{{_query}}" de
fault_value=""> </url-param> <url-param name="l" default_value="50" value="{{_li
mit}}"> </url-param> <div class="container horizontal layout"> <div class="narro
w-down-selector"> <div> <iron-a11y-keys target="[[_filter_input]]" keys="enter"
on-keys-pressed="_manuallyAddFilter"></iron-a11y-keys> <paper-input id="filter"
label="Search columns and filters or supply a filter and press enter" placeholde
r="gpu nvidia pool:Chrome" value="{{_query::input}}"> </paper-input> </div> <div
class="wide selector side-by-side" title="This shows all task tags and other in
teresting task properties. Mark the check box to add as a column. Select the row
to see filter options."> <iron-selector attr-for-selected="label" selected="{{_
primarySelected}}"> <template is="dom-repeat" items="[[_primaryItems]]" as="item
"> <div class="selectable item horizontal layout" label="[[item]]"> <span>[[_bef
oreBold(item,_query)]]<span class="bold">[[_bold(item,_query)]]</span>[[_afterBo
ld(item,_query)]]</span> <span class="flex"></span> <paper-checkbox noink="" dis
abled$="[[_cantToggleColumn(item)]]" checked="[[_columnState(item,columns.*)]]"
on-change="_toggleColumn"> </paper-checkbox> </div> </template> </iron-selector>
</div> <div class="selector side-by-side" title="These are all options (if any)
that the task list can be filtered on."> <template is="dom-repeat" id="secondar
yList" items="[[_secondaryItems]]" as="item"> <div class="item horizontal layout
" label="[[item]]"> <span>[[_beforeBold(item,_query)]]<span class="bold">[[_bold
(item,_query)]]</span>[[_afterBold(item,_query)]]</span> <span class="flex"></sp
an> <iron-icon class="icons" icon="icons:arrow-forward" hidden="[[_cantAddFilter
(_primarySelected,item,_filters.*)]]" on-tap="_addFilter"> </iron-icon> </div> <
/template> </div> <div class="selector side-by-side" title="These tag filters ar
e AND'd together and applied to all tasks."> <template is="dom-repeat" items="[[
_filters]]" as="fil"> <div class="item horizontal layout" label="[[fil]]"> <span
>[[fil]]</span> <span class="flex"></span> <iron-icon class="icons" icon="icons:
remove-circle-outline" hidden="[[_cantRemoveFilter(fil,_filters.*)]]" on-tap="_r
emoveFilter"> </iron-icon> </div> </template> </div> <div class="side-by-side">
<paper-input id="_limit" label="Limit Results" auto-validate="" min="0" max="100
0" pattern="[0-9]+" value="{{_limit}}"> </paper-input> </div> </div> </div> </te
mplate> <script>!function(){var t={state:function(t,i){var r=this._attribute(t,"
state")[0];if(i===r||"ALL"===i)return!0;if("PENDING_RUNNING"===i)return r===this
.PENDING||r===this.RUNNING;var e=this._attribute(t,"failure",!1)[0];if("COMPLETE
D_SUCCESS"===i)return r===this.COMPLETED&&!e;if("COMPLETED_FAILURE"===i)return r
===this.COMPLETED&&e;var a=this._attribute(t,"try_number","-1")[0];return"DEDUPE
D"===i?r===this.COMPLETED&&"0"===a:void 0}};Polymer({is:"task-filters",behaviors
:[SwarmingBehaviors.QueryColumnFilter,SwarmingBehaviors.TaskBehavior],properties
:{columns:{type:Array,notify:!0},query_params:{type:Object,computed:"_extractQue
ryParams(_filters.*, _limit)",notify:!0},_filterMap:{type:Object,value:function(
){var i=this._commonFilters();for(var r in t)i[r]=t[r];return i}}},_cantToggleCo
lumn:function(t){return!t||"name"===t},_extractQueryParams:function(){var t={},i
=[];this._filters.forEach(function(r){var e=r.split(this.FILTER_SEP,1),a=e[0],s=
r.substring(a.length+this.FILTER_SEP.length);"state"===a?t.state=[s]:("user"===a
&&"none"===s&&(s=""),i.push(a+this.FILTER_SEP+swarming.alias.unapply(s)))}.bind(
this)),t.tags=i;var r=parseInt(this._limit);return Number.isInteger(r)&&(r=Math.
max(r,1),r=Math.min(1e3,r),t.limit=[r],this._limit!=r&&this.set("_limit",r)),t}}
)}()</script> </dom-module><dom-module id="task-list-data" assetpath="/res/imp/t
asklist/"> <script>!function(){var t=["abandoned_ts","completed_ts","created_ts"
,"modified_ts","started_ts"];Polymer({is:"task-list-data",behaviors:[SwarmingBeh
aviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],properties:{auth_headers:{
type:Object,observer:"signIn"},query_params:{type:Object},tasks:{type:Array},bus
y:{type:Boolean,computed:"_or(_busy2,_busy1)",notify:!0},primary_map:{type:Objec
t,computed:"_primaryMap(_tags,_dimensions,tasks.*)",notify:!0},primary_arr:{type
:Array,computed:"_primaryArr(primary_map)",notify:!0},_busy2:{type:Boolean,value
:!1},_busy1:{type:Boolean,value:!1},_dimensions:{type:Object},_list:{type:Object
},_tags:{type:Object}},signIn:function(){this._getJsonAsync("_tags","/api/swarmi
ng/v1/tasks/tags","_busy2",this.auth_headers),this._getJsonAsync("_dimensions","
/api/swarming/v1/bots/dimensions","_busy1",this.auth_headers)},_primaryArr:funct
ion(t){var a=Object.keys(t);return a.sort(),a},_primaryMap:function(a,s){a=a&&a.
tasks_tags||[],s=s&&s.bots_dimensions||[],tasks=this.tasks||[];var e={};a.forEac
h(function(t){e[t.key]||(e[t.key]={});var a=t.value||[];a.forEach(function(a){e[
t.key][a]=!0})}),s.forEach(function(t){var a=t.value;e[t.key]||(e[t.key]={}),a.f
orEach(function(a){e[t.key][a]=!0})}),tasks.forEach(function(t){Object.keys(t.ta
gMap).forEach(function(a){var s=t.tagMap[a];e[a]||(e[a]={}),e[a][s]=!0})}),e.use
r&&(delete e.user[""],e.user.none=!0);var r={};for(key in e){var i=Object.keys(e
[key]);if(swarming.alias.DIMENSIONS_WITH_ALIASES.indexOf(key)===-1)r[key]=i;else
{var n=[];i.forEach(function(t){n.push(swarming.alias.apply(t,key))}),r[key]=n}}
return r.name=[],r.state=[this.PENDING,this.RUNNING,"PENDING_RUNNING",this.COMPL
ETED,"COMPLETED_SUCCESS","COMPLETED_FAILURE",this.EXPIRED,this.TIMED_OUT,this.BO
T_DIED,this.CANCELED,"DEDUPED","ALL"],r.costs_usd=[],r.deduped_from=[],r.duratio
n=[],r.server_versions=[],r.bot=[],t.forEach(function(t){r[t]=[]}),r},parseTasks
:function(a){if(!a||!a.items)return[];var s=new Date;return a.items.forEach(func
tion(a){var e={};a.tags=a.tags||[],a.tags.forEach(function(t){var a=t.split(":",
1),s=a[0],r=t.substring(s.length+1);e[s]=r}),a.tagMap=e,t.forEach(function(t){a[
t]&&(a[t]=new Date(a[t]),a["human_"+t]=sk.human.localeTime(a[t]))}),!a.duration&
&a.state===this.RUNNING&&a.started_ts&&(a.duration=(s-a.started_ts)/1e3),a.durat
ion&&(a.human_duration=this._humanDuration(a.duration))}.bind(this)),a.items}})}
()</script> </dom-module> <dom-module id="task-list" assetpath="/res/imp/tasklis
t/"> <template> <style include="iron-flex iron-flex-alignment iron-positioning s
warming-app-style dynamic-table-style task-style">task-filters{margin-bottom:8px
;margin-right:10px}.task-list th>span{padding-right:30px}</style> <url-param nam
e="s" value="{{_sortstr}}" default_value="created_ts:desc"> </url-param> <swarmi
ng-app client_id="[[client_id]]" auth_headers="{{_auth_headers}}" permissions="{
{_permissions}}" signed_in="{{_signed_in}}" busy="[[_or(_busy1,_busy2)]]" name="
Swarming Task List"> <h2 hidden$="[[_signed_in]]">You must sign in to see anythi
ng useful.</h2> <div hidden$="[[_not(_signed_in)]]"> <task-list-data id="data" a
uth_headers="[[_auth_headers]]" query_params="[[_query_params]]" tasks="[[_items
]]" busy="{{_busy1)}}" primary_map="{{_primary_map}}" primary_arr="{{_primary_ar
r}}"> </task-list-data> <div class="horizontal layout"> <task-filters primary_ma
p="[[_primary_map]]" primary_arr="[[_primary_arr]]" columns="{{_columns}}" query
_params="{{_query_params}}" filter="{{_filter}}"> </task-filters> </div> <table
class="task-list"> <thead on-sort_change="_sortChange"> <tr> <th> <span>Task Nam
e</span> <sort-toggle name="name" current="[[_sort]]"> </sort-toggle> </th> <th
hidden$="[[_hide('state', _columns.*)]]"> <span>State</span> <sort-toggle name="
state" current="[[_sort]]"> </sort-toggle> </th> <th hidden$="[[_hide('bot', _co
lumns.*)]]"> <span>Bot Assigned</span> <sort-toggle name="bot" current="[[_sort]
]"> </sort-toggle> </th> <th hidden$="[[_hide('deduped_from', _columns.*)]]"> <s
pan>Deduped from</span> <sort-toggle name="deduped_from" current="[[_sort]]"> </
sort-toggle> </th> <th hidden$="[[_hide('source_revision', _columns.*)]]"> <span
>Source Revision</span> <sort-toggle name="source_revision" current="[[_sort]]">
</sort-toggle> </th> <template is="dom-repeat" items="[[_plainColumns]]" as="c"
> <th hidden$="[[_hide(c)]]"> <span>[[_header(c)]]</span> <sort-toggle name="[[c
]]" current="[[_sort]]"> </sort-toggle> </th> </template> </tr> </thead> <tbody>
<template id="tasks_table" is="dom-repeat" items="[[_filteredSortedItems]]" as=
"task" initial-count="50"> <tr class$="[[_taskClass(task)]]"> <td> <a class="cen
ter" href$="[[_taskLink(task.task_id)]]" target="_blank"> [[task.name]] </a> </t
d> <td hidden$="[[_hide('state', _columns.*)]]"> [[_column('state', task)]] <pap
er-button raised="" hidden$="[[_cannotCancel(task,_permissions)]]" on-tap="_prom
ptCancel"> Cancel </paper-button> </td> <td hidden$="[[_hide('bot', _columns.*)]
]"> <a class="center" href$="[[_botLink(task.bot_id)]]" target="_blank"> [[_colu
mn('bot',task)]] </a> </td> <td hidden$="[[_hide('deduped_from', _columns.*)]]">
<a class="center" href$="[[_taskLink(task.deduped_from)]]" target="_blank"> [[_
column('deduped_from',task)]] </a> </td> <td hidden$="[[_hide('source_revision',
_columns.*)]]"> <a class="center" href$="[[_sourceLink(task)]]" target="_blank"
> [[_column('source_revision',task)]] </a> </td> <template is="dom-repeat" items
="[[_plainColumns]]" as="c"> <td hidden$="[[_hide(c)]]"> [[_column(c, task)]] </
td> </template> </tr> </template> </tbody> </table> <pageable-data id="page_task
s" busy="{{_busy2}}" label="Show more tasks" output="{{_items}}" parse="[[_parse
Tasks]]"> </pageable-data> </div> </swarming-app> <paper-dialog id="prompt" moda
l="" on-iron-overlay-closed="_promptClosed"> <h2>Are you sure?</h2> <div>Are you
sure you want to [[_dialogPrompt]]?</div> <div class="buttons"> <paper-button d
ialog-dismiss="" autofocus="">No</paper-button> <paper-button dialog-confirm="">
Yes</paper-button> </div> </paper-dialog> <error-toast></error-toast> </template
> <script>!function(){function t(t){return function(e){return this._attribute(e,
"human_"+t)[0]}}function e(t){return function(e,a,s){var r=this._attribute(a,t,"
0")[0],i=this._attribute(s,t,"0")[0];return e*(r-i)}}var a=["deduped_from","name
","state","bot","source_revision"],s={abandoned_ts:t("abandoned_ts"),bot:functio
n(t){return this._attribute(t,"bot_id")[0]},completed_ts:t("completed_ts"),costs
_usd:function(t){return this._attribute(t,"costs_usd",0)[0]},created_ts:t("creat
ed_ts"),duration:t("duration"),modified_ts:t("modified_ts"),source_revision:func
tion(t){var e=this._attribute(t,"source_revision")[0];return e.substring(0,8)},s
tarted_ts:t("started_ts"),state:function(t){var e=this._attribute(t,"state")[0];
if("COMPLETED"===e){if(this._attribute(t,"failure",!1)[0])return"COMPLETED (FAIL
URE)";var a=this._attribute(t,"try_number","-1")[0];return"0"===a?"COMPLETED (DE
DUPED)":"COMPLETED (SUCCESS)"}return e}},r={user:"Requesting User"},i={abandoned
_ts:e("abandoned_ts"),completed_ts:e("completed_ts"),created_ts:e("created_ts"),
duration:e("duration"),modified_ts:e("modified_ts"),started_ts:e("started_ts")};
Polymer({is:"task-list",behaviors:[SwarmingBehaviors.DynamicTableBehavior,Swarmi
ngBehaviors.TaskBehavior],properties:{client_id:{type:String},_busy1:{type:Boole
an,value:!1},_busy2:{type:Boolean,value:!1},_parseTasks:{type:Function,value:fun
ction(){return this.$.data.parseTasks.bind(this)}},_toCancel:{type:String},_colu
mnMap:{type:Object,value:function(){var t=this._commonColumns();for(var e in s)t
[e]=s[e];return t}},_headerMap:{type:Object,value:r},_specialColumns:{type:Array
,value:a},_specialSort:{type:Object,value:i}},observers:["reload(_query_params,_
auth_headers)"],_attribute:function(t,e,a){void 0===a&&(a="none");var s=this._ta
g(t,e)||t[e]||[a];return Array.isArray(s)?s:[s]},_cannotCancel:function(t,e){ret
urn!(e&&e.cancel_task&&"PENDING"===this._column("state",t))},_cancelTask:functio
n(){var t="/api/swarming/v1/task/"+this._toCancel+"/cancel";swarming.postWithToa
st(t,"Canceling task "+this._toCancel,this._auth_headers),this.set("_toCancel","
")},_promptClosed:function(t){t.detail.confirmed&&this._cancelTask()},_promptCan
cel:function(t){var e=t.model.task;return e&&e.task_id?(this.set("_toCancel",e.t
ask_id),this.set("_dialogPrompt",'cancel task "'+e.name+'"'),void this.$.prompt.
open()):void console.log("Missing task info",e)},reload:function(){if(this._auth
_headers&&this._query_params){var t="/api/swarming/v1/tasks/list?"+sk.query.from
ParamSet(this._query_params);this.$.page_tasks.load(t,this._auth_headers)}},_sou
rceLink:function(t){var e=this._attribute(t,"source_revision")[0],a=this._attrib
ute(t,"source_repo")[0];return"none"!==e&&"none"!==a&&a.replace("%s",e)},_tag:fu
nction(t,e){if(t&&t.tagMap)return t.tagMap[e]},_taskClass:function(t){return thi
s.stateClass(this._column("state",t))}})}()</script> </dom-module> <dom-module i
d="iron-collapse" assetpath="/res/imp/bower_components/iron-collapse/"> <templat
e> <style>:host{display:block;transition-duration:var(--iron-collapse-transition
-duration,300ms);overflow:visible}:host(.iron-collapse-closed){display:none}:hos
t(:not(.iron-collapse-opened)){overflow:hidden}</style> <content></content> </te
mplate> </dom-module> <script>Polymer({is:"iron-collapse",behaviors:[Polymer.Iro
nResizableBehavior],properties:{horizontal:{type:Boolean,value:!1,observer:"_hor
izontalChanged"},opened:{type:Boolean,value:!1,notify:!0,observer:"_openedChange
d"},noAnimation:{type:Boolean},_desiredSize:{type:String,value:""}},get dimensio
n(){return this.horizontal?"width":"height"},get _dimensionMax(){return this.hor
izontal?"maxWidth":"maxHeight"},get _dimensionMaxCss(){return this.horizontal?"m
ax-width":"max-height"},hostAttributes:{role:"group","aria-hidden":"true","aria-
expanded":"false"},listeners:{transitionend:"_transitionEnd"},attached:function(
){this._transitionEnd()},toggle:function(){this.opened=!this.opened},show:functi
on(){this.opened=!0},hide:function(){this.opened=!1},updateSize:function(i,t){if
(i="auto"===i?"":i,this._desiredSize!==i){this._desiredSize=i,this._updateTransi
tion(!1);var e=t&&!this.noAnimation&&this._isDisplayed;if(e){var n=this._calcSiz
e();""===i&&(this.style[this._dimensionMax]="",i=this._calcSize()),this.style[th
is._dimensionMax]=n,this.scrollTop=this.scrollTop,this._updateTransition(!0),e=i
!==n}this.style[this._dimensionMax]=i,e||this._transitionEnd()}},enableTransitio
n:function(i){Polymer.Base._warn("`enableTransition()` is deprecated, use `noAni
mation` instead."),this.noAnimation=!i},_updateTransition:function(i){this.style
.transitionDuration=i&&!this.noAnimation?"":"0s"},_horizontalChanged:function(){
this.style.transitionProperty=this._dimensionMaxCss;var i="maxWidth"===this._dim
ensionMax?"maxHeight":"maxWidth";this.style[i]="",this.updateSize(this.opened?"a
uto":"0px",!1)},_openedChanged:function(){this.setAttribute("aria-expanded",this
.opened),this.setAttribute("aria-hidden",!this.opened),this.toggleClass("iron-co
llapse-closed",!1),this.toggleClass("iron-collapse-opened",!1),this.updateSize(t
his.opened?"auto":"0px",!0),this.opened&&this.focus()},_transitionEnd:function()
{this.style[this._dimensionMax]=this._desiredSize,this.toggleClass("iron-collaps
e-closed",!this.opened),this.toggleClass("iron-collapse-opened",this.opened),thi
s._updateTransition(!1),this.notifyResize()},get _isDisplayed(){var i=this.getBo
undingClientRect();for(var t in i)if(0!==i[t])return!0;return!1},_calcSize:funct
ion(){return this.getBoundingClientRect()[this.dimension]+"px"}})</script> <scri
pt>Polymer.IronMenubarBehaviorImpl={hostAttributes:{role:"menubar"},keyBindings:
{left:"_onLeftKey",right:"_onRightKey"},_onUpKey:function(e){this.focusedItem.cl
ick(),e.detail.keyboardEvent.preventDefault()},_onDownKey:function(e){this.focus
edItem.click(),e.detail.keyboardEvent.preventDefault()},get _isRTL(){return"rtl"
===window.getComputedStyle(this).direction},_onLeftKey:function(e){this._isRTL?t
his._focusNext():this._focusPrevious(),e.detail.keyboardEvent.preventDefault()},
_onRightKey:function(e){this._isRTL?this._focusPrevious():this._focusNext(),e.de
tail.keyboardEvent.preventDefault()},_onKeydown:function(e){this.keyboardEventMa
tchesKeys(e,"up down left right esc")||this._focusWithKeyboardEvent(e)}},Polymer
.IronMenubarBehavior=[Polymer.IronMenuBehavior,Polymer.IronMenubarBehaviorImpl]<
/script> <iron-iconset-svg name="paper-tabs" size="24"> <svg><defs> <g id="chevr
on-left"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"></path></g> <g
id="chevron-right"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"></pa
th></g> </defs></svg> </iron-iconset-svg> <dom-module id="paper-tab" assetpath="
/res/imp/bower_components/paper-tabs/"> <template> <style>:host{@apply(--layout-
inline);@apply(--layout-center);@apply(--layout-center-justified);@apply(--layou
t-flex-auto);position:relative;padding:0 12px;overflow:hidden;cursor:pointer;ver
tical-align:middle;@apply(--paper-font-common-base);@apply(--paper-tab)}:host(:f
ocus){outline:0}:host([link]){padding:0}.tab-content{height:100%;transform:trans
lateZ(0);-webkit-transform:translateZ(0);transition:opacity .1s cubic-bezier(.4,
0,1,1);@apply(--layout-horizontal);@apply(--layout-center-center);@apply(--layou
t-flex-auto);@apply(--paper-tab-content)}:host(:not(.iron-selected))>.tab-conten
t{opacity:.8;@apply(--paper-tab-content-unselected)}:host(:focus) .tab-content{o
pacity:1;font-weight:700}paper-ripple{color:var(--paper-tab-ink,--paper-yellow-a
100)}.tab-content>::content>a{@apply(--layout-flex-auto);height:100%}</style> <d
iv class="tab-content"> <content></content> </div> </template> <script>Polymer({
is:"paper-tab",behaviors:[Polymer.IronControlState,Polymer.IronButtonState,Polym
er.PaperRippleBehavior],properties:{link:{type:Boolean,value:!1,reflectToAttribu
te:!0}},hostAttributes:{role:"tab"},listeners:{down:"_updateNoink",tap:"_onTap"}
,attached:function(){this._updateNoink()},get _parentNoink(){var t=Polymer.dom(t
his).parentNode;return!!t&&!!t.noink},_updateNoink:function(){this.noink=!!this.
noink||!!this._parentNoink},_onTap:function(t){if(this.link){var e=this.queryEff
ectiveChildren("a");if(!e)return;if(t.target===e)return;e.click()}}})</script> <
/dom-module> <dom-module id="paper-tabs" assetpath="/res/imp/bower_components/pa
per-tabs/"> <template> <style>:host{@apply(--layout);@apply(--layout-center);hei
ght:48px;font-size:14px;font-weight:500;overflow:hidden;-moz-user-select:none;-m
s-user-select:none;-webkit-user-select:none;user-select:none;-webkit-tap-highlig
ht-color:transparent;-webkit-tap-highlight-color:transparent;@apply(--paper-tabs
)}:host-context([dir=rtl]){@apply(--layout-horizontal-reverse)}#tabsContainer{po
sition:relative;height:100%;white-space:nowrap;overflow:hidden;@apply(--layout-f
lex-auto)}#tabsContent{height:100%;-moz-flex-basis:auto;-ms-flex-basis:auto;flex
-basis:auto}#tabsContent.scrollable{position:absolute;white-space:nowrap}#tabsCo
ntent.scrollable.fit-container,#tabsContent:not(.scrollable){@apply(--layout-hor
izontal)}#tabsContent.scrollable.fit-container{min-width:100%}#tabsContent.scrol
lable.fit-container>::content>*{-ms-flex:1 0 auto;-webkit-flex:1 0 auto;flex:1 0
auto}.hidden{display:none}.not-visible{opacity:0;cursor:default}paper-icon-butt
on{width:48px;height:48px;padding:12px;margin:0 4px}#selectionBar{position:absol
ute;height:2px;bottom:0;left:0;right:0;background-color:var(--paper-tabs-selecti
on-bar-color,--paper-yellow-a100);-webkit-transform:scale(0);transform:scale(0);
-webkit-transform-origin:left center;transform-origin:left center;transition:-we
bkit-transform;transition:transform;@apply(--paper-tabs-selection-bar)}#selectio
nBar.align-bottom{top:0;bottom:auto}#selectionBar.expand{transition-duration:.15
s;transition-timing-function:cubic-bezier(.4,0,1,1)}#selectionBar.contract{trans
ition-duration:.18s;transition-timing-function:cubic-bezier(0,0,.2,1)}#tabsConte
nt>::content>:not(#selectionBar){height:100%}</style> <paper-icon-button icon="p
aper-tabs:chevron-left" class$="[[_computeScrollButtonClass(_leftHidden, scrolla
ble, hideScrollButtons)]]" on-up="_onScrollButtonUp" on-down="_onLeftScrollButto
nDown" tabindex="-1"></paper-icon-button> <div id="tabsContainer" on-track="_scr
oll" on-down="_down"> <div id="tabsContent" class$="[[_computeTabsContentClass(s
crollable, fitContainer)]]"> <div id="selectionBar" class$="[[_computeSelectionB
arClass(noBar, alignBottom)]]" on-transitionend="_onBarTransitionEnd"></div> <co
ntent select="*"></content> </div> </div> <paper-icon-button icon="paper-tabs:ch
evron-right" class$="[[_computeScrollButtonClass(_rightHidden, scrollable, hideS
crollButtons)]]" on-up="_onScrollButtonUp" on-down="_onRightScrollButtonDown" ta
bindex="-1"></paper-icon-button> </template> <script>Polymer({is:"paper-tabs",be
haviors:[Polymer.IronResizableBehavior,Polymer.IronMenubarBehavior],properties:{
noink:{type:Boolean,value:!1,observer:"_noinkChanged"},noBar:{type:Boolean,value
:!1},noSlide:{type:Boolean,value:!1},scrollable:{type:Boolean,value:!1},fitConta
iner:{type:Boolean,value:!1},disableDrag:{type:Boolean,value:!1},hideScrollButto
ns:{type:Boolean,value:!1},alignBottom:{type:Boolean,value:!1},selectable:{type:
String,value:"paper-tab"},autoselect:{type:Boolean,value:!1},autoselectDelay:{ty
pe:Number,value:0},_step:{type:Number,value:10},_holdDelay:{type:Number,value:1}
,_leftHidden:{type:Boolean,value:!1},_rightHidden:{type:Boolean,value:!1},_previ
ousTab:{type:Object}},hostAttributes:{role:"tablist"},listeners:{"iron-resize":"
_onTabSizingChanged","iron-items-changed":"_onTabSizingChanged","iron-select":"_
onIronSelect","iron-deselect":"_onIronDeselect"},keyBindings:{"left:keyup right:
keyup":"_onArrowKeyup"},created:function(){this._holdJob=null,this._pendingActiv
ationItem=void 0,this._pendingActivationTimeout=void 0,this._bindDelayedActivati
onHandler=this._delayedActivationHandler.bind(this),this.addEventListener("blur"
,this._onBlurCapture.bind(this),!0)},ready:function(){this.setScrollDirection("y
",this.$.tabsContainer)},detached:function(){this._cancelPendingActivation()},_n
oinkChanged:function(t){var e=Polymer.dom(this).querySelectorAll("paper-tab");e.
forEach(t?this._setNoinkAttribute:this._removeNoinkAttribute)},_setNoinkAttribut
e:function(t){t.setAttribute("noink","")},_removeNoinkAttribute:function(t){t.re
moveAttribute("noink")},_computeScrollButtonClass:function(t,e,i){return!e||i?"h
idden":t?"not-visible":""},_computeTabsContentClass:function(t,e){return t?"scro
llable"+(e?" fit-container":""):" fit-container"},_computeSelectionBarClass:func
tion(t,e){return t?"hidden":e?"align-bottom":""},_onTabSizingChanged:function(){
this.debounce("_onTabSizingChanged",function(){this._scroll(),this._tabChanged(t
his.selectedItem)},10)},_onIronSelect:function(t){this._tabChanged(t.detail.item
,this._previousTab),this._previousTab=t.detail.item,this.cancelDebouncer("tab-ch
anged")},_onIronDeselect:function(t){this.debounce("tab-changed",function(){this
._tabChanged(null,this._previousTab),this._previousTab=null},1)},_activateHandle
r:function(){this._cancelPendingActivation(),Polymer.IronMenuBehaviorImpl._activ
ateHandler.apply(this,arguments)},_scheduleActivation:function(t,e){this._pendin
gActivationItem=t,this._pendingActivationTimeout=this.async(this._bindDelayedAct
ivationHandler,e)},_delayedActivationHandler:function(){var t=this._pendingActiv
ationItem;this._pendingActivationItem=void 0,this._pendingActivationTimeout=void
0,t.fire(this.activateEvent,null,{bubbles:!0,cancelable:!0})},_cancelPendingAct
ivation:function(){void 0!==this._pendingActivationTimeout&&(this.cancelAsync(th
is._pendingActivationTimeout),this._pendingActivationItem=void 0,this._pendingAc
tivationTimeout=void 0)},_onArrowKeyup:function(t){this.autoselect&&this._schedu
leActivation(this.focusedItem,this.autoselectDelay)},_onBlurCapture:function(t){
t.target===this._pendingActivationItem&&this._cancelPendingActivation()},get _ta
bContainerScrollSize(){return Math.max(0,this.$.tabsContainer.scrollWidth-this.$
.tabsContainer.offsetWidth)},_scroll:function(t,e){if(this.scrollable){var i=e&&
-e.ddx||0;this._affectScroll(i)}},_down:function(t){this.async(function(){this._
defaultFocusAsync&&(this.cancelAsync(this._defaultFocusAsync),this._defaultFocus
Async=null)},1)},_affectScroll:function(t){this.$.tabsContainer.scrollLeft+=t;va
r e=this.$.tabsContainer.scrollLeft;this._leftHidden=0===e,this._rightHidden=e==
=this._tabContainerScrollSize},_onLeftScrollButtonDown:function(){this._scrollTo
Left(),this._holdJob=setInterval(this._scrollToLeft.bind(this),this._holdDelay)}
,_onRightScrollButtonDown:function(){this._scrollToRight(),this._holdJob=setInte
rval(this._scrollToRight.bind(this),this._holdDelay)},_onScrollButtonUp:function
(){clearInterval(this._holdJob),this._holdJob=null},_scrollToLeft:function(){thi
s._affectScroll(-this._step)},_scrollToRight:function(){this._affectScroll(this.
_step)},_tabChanged:function(t,e){if(!t)return this.$.selectionBar.classList.rem
ove("expand"),this.$.selectionBar.classList.remove("contract"),void this._positi
onBar(0,0);var i=this.$.tabsContent.getBoundingClientRect(),n=i.width,o=t.getBou
ndingClientRect(),s=o.left-i.left;if(this._pos={width:this._calcPercent(o.width,
n),left:this._calcPercent(s,n)},this.noSlide||null==e)return this.$.selectionBar
.classList.remove("expand"),this.$.selectionBar.classList.remove("contract"),voi
d this._positionBar(this._pos.width,this._pos.left);var a=e.getBoundingClientRec
t(),l=this.items.indexOf(e),c=this.items.indexOf(t),r=5;this.$.selectionBar.clas
sList.add("expand");var h=l<c,d=this._isRTL;d&&(h=!h),h?this._positionBar(this._
calcPercent(o.left+o.width-a.left,n)-r,this._left):this._positionBar(this._calcP
ercent(a.left+a.width-o.left,n)-r,this._calcPercent(s,n)+r),this.scrollable&&thi
s._scrollToSelectedIfNeeded(o.width,s)},_scrollToSelectedIfNeeded:function(t,e){
var i=e-this.$.tabsContainer.scrollLeft;i<0?this.$.tabsContainer.scrollLeft+=i:(
i+=t-this.$.tabsContainer.offsetWidth,i>0&&(this.$.tabsContainer.scrollLeft+=i))
},_calcPercent:function(t,e){return 100*t/e},_positionBar:function(t,e){t=t||0,e
=e||0,this._width=t,this._left=e,this.transform("translateX("+e+"%) scaleX("+t/1
00+")",this.$.selectionBar)},_onBarTransitionEnd:function(t){var e=this.$.select
ionBar.classList;e.contains("expand")?(e.remove("expand"),e.add("contract"),this
._positionBar(this._pos.width,this._pos.left)):e.contains("contract")&&e.remove(
"contract")}})</script> </dom-module> <dom-module id="single-page-style" assetpa
th="/res/imp/common/"> <template> <style>.header{max-width:800px}.title{font-siz
e:1.5em;font-weight:700;margin:5px}.id_input{margin-left:5px;--paper-input-conta
iner-input:{font-size:2em};}.refresh{max-width:40px;max-height:40px;width:initia
l;height:initial}button{min-width:4em;max-height:55px}table{border-collapse:coll
apse;margin-left:5px;margin-bottom:8px}td,th{border:1px solid #BBB;padding:5px}.
tabs{background-color:#1F78B4;color:#fff;max-width:600px;margin-left:5px;--paper
-checkbox-label-color:#fff}paper-tab{background-color:#A6CEE3;color:#000}paper-t
ab.iron-selected{background-color:#1F78B4;color:#fff;font-weight:700;text-decora
tion:underline}paper-tab[disabled]{background-color:#AAA;text-decoration:line-th
rough}.quarantined{background-color:#fdd}.dead{background-color:#ccc}</style> </
template> </dom-module><script>!function(){SwarmingBehaviors.BotPageBehavior=[Sw
armingBehaviors.CommonBehavior,{}]}()</script> <dom-module id="bot-page-data" as
setpath="/res/imp/botpage/"> <script>!function(){function t(t){if(!s){var e=t.to
String();s=e.substring(e.indexOf("("))}return t.toLocaleString()+" "+s}var e,s,i
=400,n=["first_seen_ts","last_seen_ts","lease_expiration_ts"],a=["started_ts","c
ompleted_ts","abandoned_ts","modified_ts"];Polymer({is:"bot-page-data",behaviors
:[SwarmingBehaviors.BotPageBehavior],properties:{auth_headers:{type:Object},bot_
id:{type:String},busy:{type:Boolean,computed:"_or(_busy1)",notify:!0},bot:{type:
Object,computed:"_parseBot(_bot)",notify:!0},bot_exists:{type:Boolean,value:!0,n
otify:!0},_busy1:{type:Boolean,value:!1},_bot:{type:Object},_events:{type:Object
},_tasks:{type:Object}},observers:["request(auth_headers,bot_id)"],request:funct
ion(){this.bot_id&&this.auth_headers&&(e&&this.cancelAsync(e),e=this.async(funct
ion(){e=void 0;var t="/api/swarming/v1/bot/"+this.bot_id,s=this._getJsonAsync("_
bot",t+"/get","_busy1",this.auth_headers);s.then(function(){this.set("bot_exists
",!0)}.bind(this)).catch(function(t){404===t.status?this.set("bot_exists",!1):sk
.errorMessage("Http response: "+(t.status||" ")+" "+t.response)}.bind(this)),thi
s.fire("reload",{id:this.bot_id})},i))},_parseBot:function(e){if(!e)return{};e.s
tate=e.state||"{}",e.state=JSON.parse(e.state)||{};var s=e.state.disks||{},i=Obj
ect.keys(s);if(i.length){e.disks=[];for(var a=0;a<i.length;a++)e.disks.push({id:
i[a],mb:s[i[a]].free_mb});e.disks.sort(function(t,e){return e.mb-t.mb})}else e.d
isks=[{id:"unknown",mb:0}];return e.dimensions=e.dimensions||[],e.dimensions.for
Each(function(t){swarming.alias.DIMENSIONS_WITH_ALIASES.indexOf(t.key)!==-1&&t.v
alue.forEach(function(e,s){t.value[s]=swarming.alias.apply(e,t.key)})}),n.forEac
h(function(s){e[s]&&(e[s]=new Date(e[s]),e["human_"+s]=t(e[s]))}),e},parseEvents
:function(e){if(!e||!e.items)return[];var e=e.items;return e.forEach(function(e)
{e.ts&&(e.ts=new Date(e.ts),e.human_ts=t(e.ts))}),e.sort(function(t,e){return e.
ts-t.ts}),e},parseTasks:function(e){if(!e||!e.items)return[];var e=e.items;retur
n e.forEach(function(e){if(a.forEach(function(s){e[s]&&(e[s]=new Date(e[s]),e["h
uman_"+s]=t(e[s]))}),e.duration)e.human_duration=this._humanDuration(e.duration)
;else{var s=e.completed_ts||e.abandoned_ts||e.modified_ts||new Date;e.human_dura
tion=this._timeDiffExact(e.started_ts,s),e.duration=(s.getTime()-e.started_ts)/1
e3}e.state=e.state||"UNKNOWN","COMPLETED"===e.state&&(e.failure?e.state="FAILURE
":e.state="SUCCESS")}.bind(this)),e.sort(function(t,e){return e.started_ts-t.sta
rted_ts}),e}})}()</script> </dom-module> <dom-module id="bot-page-summary" asset
path="/res/imp/botpage/"> <template> <style include="single-page-style">.wrapper
{display:table;margin-left:auto;margin-bottom:10px;margin-right:5px}paper-checkb
ox{margin-left:5px}.thick{border-top-style:solid}</style> <url-param name="show_
full_names" value="{{_show_full_names}}"> </url-param> <url-param name="show_all
_tasks" value="{{_show_all_tasks}}"> </url-param> <url-param name="sort_stats" v
alue="{{_sortstr}}" default_value="total:desc"> </url-param> <div class="wrapper
"> <table> <thead on-sort_change="_sortChange"> <tr> <th> <span>Name</span> <sor
t-toggle name="full_name" current="[[_sort]]"> </sort-toggle> </th> <th> <span>T
otal</span> <sort-toggle name="total" current="[[_sort]]"> </sort-toggle> </th>
<th> <span>Success</span> <sort-toggle name="success" current="[[_sort]]"> </sor
t-toggle> </th> <th> <span>Failed</span> <sort-toggle name="failed" current="[[_
sort]]"> </sort-toggle> </th> <th> <span>Died</span> <sort-toggle name="bot_died
" current="[[_sort]]"> </sort-toggle> </th> <th> <span>Average Duration</span> <
sort-toggle name="avg_duration" current="[[_sort]]"> </sort-toggle> </th> <th> <
span>Total Duration</span> <sort-toggle name="total_time" current="[[_sort]]"> <
/sort-toggle> </th> <th>Percent of Total</th> </tr> </thead> <tbody> <template i
s="dom-repeat" items="[[_tasksToShow]]" as="task"> <tr> <td hidden$="[[_truthy(_
show_full_names)]]" title="[[task.full_name]]">[[task.name]]</td> <td hidden$="[
[_not(_show_full_names)]]" title="[[task.full_name]]">[[task.full_name]]</td> <t
d>[[task.total]]</td> <td>[[task.success]]</td> <td>[[task.failed]]</td> <td>[[t
ask.bot_died]]</td> <td>[[_humanDuration(task.avg_duration)]]</td> <td>[[_humanD
uration(task.total_time)]]</td> <td>[[task.total_time_percent]]%</td> </tr> </te
mplate> </tbody> <tbody><tr class="thick"> <td>Total</td> <td>[[_totalStats.tota
l]]</td> <td>[[_totalStats.success]]</td> <td>[[_totalStats.failed]]</td> <td>[[
_totalStats.bot_died]]</td> <td>[[_humanDuration(_totalStats.avg_duration)]]</td
> <td>[[_humanDuration(_totalStats.total_time)]]</td> <td>100.0%</td> </tr> </tb
ody></table> <div> <table> <thead> <tr> <th title="How much time passed between
the oldest task fetched and now."> Total Wall Time </th> <th title="How much of
the wall time this bot was busy with a task."> Wall Time Utilization </th> </tr>
</thead> <tbody> <tr> <td>[[_humanDuration(_totalStats.wall_time)]]</td> <td>[[
_totalStats.wall_time_utilization]]%</td> </tr> </tbody> </table> <paper-checkbo
x checked="{{_show_full_names}}"> Show Full Names </paper-checkbox> <paper-check
box hidden$="[[_cannotExpand]]" checked="{{_show_all_tasks}}"> Show All Tasks </
paper-checkbox> </div> </div> </template> <script>!function(){var t=15;Polymer({
is:"bot-page-summary",behaviors:[SwarmingBehaviors.BotPageBehavior],properties:{
tasks:{type:Array},_cannotExpand:{type:Boolean,computed:"_countTasks(_taskStats.
*)"},_show_all_tasks:{type:Boolean},_show_full_names:{type:Boolean},_sortstr:{ty
pe:String},_sort:{type:Object,computed:"_makeSortObject(_sortstr)"},_taskStats:{
type:Array},_tasksToShow:{type:Array,computed:"_sortAndLimitTasks(_taskStats.*,_
sort.*,_show_all_tasks)"},_totalStats:{type:Object}},observers:["_aggregate(task
s.*)"],_aggregate:function(){if(this.tasks&&this.tasks.length){var t=new Date(1e
3*sk.now()),a={},e={total:this.tasks.length,success:0,failed:0,bot_died:0,avg_du
ration:0,total_time:0,wall_time:(t-this.tasks[this.tasks.length-1].started_ts)/1
e3};this.tasks.forEach(function(t){var s=t.name.trim(),i=s.split("/");5===i.leng
th&&(s=i[0]+"/"+i[3]),a[s]||(a[s]={full_name:s,name:s,total:0,success:0,failed:0
,bot_died:0,avg_duration:0,total_time:0}),a[s].total++,t.failure?(e.failed++,a[s
].failed++):t.internal_failure?(e.bot_died++,a[s].bot_died++):(e.success++,a[s].
success++),e.total_time+=t.duration,a[s].total_time+=t.duration}),e.avg_duration
=e.total_time/e.total,e.wall_time_utilization=(100*e.total_time/e.wall_time).toF
ixed(1),this.set("_totalStats",e);var s=Object.keys(a),i=[];s.forEach(function(t
){a[t].avg_duration=a[t].total_time/a[t].total,a[t].total_time_percent=(100*a[t]
.total_time/e.total_time).toFixed(1),i.push(a[t])});var o=new Substrings({minOcc
urrence:Math.max(2,s.length-1),minLength:6});o.build(s);var n=o.weighByAverage()
||[];n.length&&n[0].source.forEach(function(t){var a=i[t].full_name;i[t].name=a.
replace(n[0].name,"...")}),this.set("_taskStats",i)}},_compare:function(t,a){if(
!this._sort)return 0;var e=1;return"desc"===this._sort.direction&&(e=-1),e*swarm
ing.naturalCompare(t[this._sort.name],a[this._sort.name])},_countTasks:function(
){return this._taskStats.length<=t},_makeSortObject:function(t){if(t){var a=t.sp
lit(":");return 2!=a.length?{name:"full_name",direction:"asc"}:{name:a[0],direct
ion:a[1]}}},_sortAndLimitTasks:function(){swarming.stableSort(this._taskStats,th
is._compare.bind(this));var a=this._taskStats.length;return!this._show_all_tasks
&&this._taskStats.length>t&&(a=t),this._taskStats.slice(0,a)},_sortChange:functi
on(t){t&&t.detail&&t.detail.name&&(t.preventDefault(),t.stopPropagation(),this.s
et("_sortstr",t.detail.name+":"+t.detail.direction))}})}()</script> </dom-module
><dom-module id="bot-page" assetpath="/res/imp/botpage/"> <template> <style incl
ude="iron-flex iron-flex-alignment iron-positioning swarming-app-style single-pa
ge-style task-style">.message{white-space:pre-line;font-family:monospace}.bot_st
ate{white-space:pre;font-family:monospace;margin-bottom:10px}.events_table,.task
s_table{border:3px solid #1F78B4}.old_version{background-color:#ffd}.stats{min-w
idth:700px;flex-grow:2}#collapse{max-width:700px}.cloud{white-space:nowrap;margi
n-bottom:5px;margin-top:auto}paper-checkbox{--paper-checkbox-label-color:#fff;--
paper-checkbox-checked-color:#fff;--paper-checkbox-checkmark-color:#000;--paper-
checkbox-unchecked-color:#fff;padding:3px}paper-dialog{border-radius:6px}</style
> <url-param name="id" value="{{bot_id}}"> </url-param> <url-param name="show_al
l_events" value="{{_show_all}}"> </url-param> <url-param name="selected" value="
{{_selected}}"> </url-param> <url-param name="show_state" value="{{_show_state}}
"> </url-param> <swarming-app client_id="[[client_id]]" auth_headers="{{_auth_he
aders}}" permissions="{{_permissions}}" server_details="{{_server_details}}" sig
ned_in="{{_signed_in}}" busy="[[_or(_busy1,_busy2,_busy3)]]" name="Swarming Bot
Page"> <h2 hidden$="[[_signed_in]]">You must sign in to see anything useful.</h2
> <div hidden$="[[_not(_signed_in)]]"> <bot-page-data id="data" auth_headers="[[
_auth_headers]]" bot_id="[[bot_id]]" bot="{{_bot}}" bot_exists="{{_bot_exists}}"
busy="{{_busy1}}" events="{{_events}}" tasks="{{_tasks}}" on-reload="_clearAndR
eload"> </bot-page-data> <div class="header horizontal layout"> <paper-input cla
ss="id_input" label="Bot id" value="{{bot_id}}"></paper-input> <template is="dom
-if" if="[[_ccLink(_bot)]]"> <div class="vertical layout"> <a href$="[[_ccLink(_
bot)]]" class="cloud">Cloud Console</a> </div> </template> <button on-click="_re
fresh"> <iron-icon class="refresh" icon="icons:refresh"></iron-icon> </button> <
/div> </div> <h2 hidden$="[[_bot_exists]]">Bot not found.</h2> <div hidden$="[[_
not(_bot_exists)]]"> <div class="horizontal wrap layout"> <div class="flex"> <ta
ble> <tbody><tr class$="[[_isDead(_bot)]]" title="Last time the bot contacted th
e server."> <td>Last Seen</td> <td title="[[_bot.human_last_seen_ts]]"> [[_timeD
iffExact(_bot.last_seen_ts)]] ago</td> <td> <template is="dom-if" if="[[_canShut
down(_bot,_permissions)]]"> <button class="raised" on-click="_promptShutdown"> S
hut Down Gracefully </button> </template> <template is="dom-if" if="[[_canDelete
(_bot,_permissions)]]"> <button class="raised" on-click="_promptDelete"> Delete
</button> </template> </td> </tr> <template is="dom-if" if="[[_bot.quarantined]]
"> <tr class="quarantined"> <td>Quarantined</td> <td colspan="2" class="message"
>[[_quarantineMessage(_bot)]]</td> </tr> </template> <tr> <td>Current Task</td>
<td> <a target="_blank" rel="noopener" href$="[[_taskLink(_bot.task_id)]]"> [[_t
ask(_bot)]] </a> </td> <td> </td> </tr> <tr> <td rowspan$="[[_numRows(_bot.dimen
sions)]]">Dimensions</td> </tr> <template is="dom-repeat" items="[[_bot.dimensio
ns]]" as="dim"> <tr> <td>[[dim.key]]</td> <td>[[_concat(dim.value)]]</td> </tr>
</template> <tr title="IP address that the server saw the connection from."> <td
>External IP</td> <td><a href$="[[_bot.external_ip]]">[[_bot.external_ip]]</a></
td> <td></td> </tr> <tr class$="[[_classVersion(_server_details.bot_version,_bot
.version)]]" title="Version is based on the content of swarming_bot.zip which is
the swarming bot code. The bot won't update if quarantined, dead, or busy."> <t
d>Bot Version</td> <td>[[_shorten(_bot.version,'8')]]</td> <td></td> </tr> <tr t
itle="The version the server expects the bot to be using."> <td>Expected Bot Ver
sion</td> <td>[[_shorten(_server_details.bot_version,'8')]]</td> <td></td> </tr>
<tr title="First time ever a bot with this id contacted the server."> <td>First
seen</td> <td title="[[_bot.human_first_seen_ts]]"> [[_timeDiffApprox(_bot.firs
t_seen_ts)]] ago </td> <td></td> </tr> <tr title="How the bot is authenticated b
y the server."> <td>Authenticated as</td> <td colspan="2">[[_bot.authenticated_a
s]]</td> </tr> <template is="dom-if" if="[[_bot.lease_id]]"> <tr> <td>Machine Pr
ovider Lease ID</td> <td colspan="2"> <a href$="[[_mpLink(_bot,_server_details.m
achine_provider_template)]]"> [[_bot.lease_id]] </a> </td> </tr> <tr> <td>Machin
e Provider Lease Expires</td> <td colspan="2">[[_bot.human_lease_expiration_ts]]
</td> </tr> </template> </tbody></table> <span class="title">State</span> <templ
ate is="dom-if" if="[[_not(_show_state)]]"> <button on-click="_toggleState"> <ir
on-icon icon="icons:add-circle-outline"></iron-icon> </button> </template> <temp
late is="dom-if" if="[[_show_state]]"> <button on-click="_toggleState"> <iron-ic
on icon="icons:remove-circle-outline"></iron-icon> </button> </template> <iron-c
ollapse id="collapse" opened="[[_show_state]]"> <div class="bot_state">[[_pretty
Print(_bot.state)]]</div> </iron-collapse> </div> <div class="stats flex"> <bot-
page-summary tasks="[[_tasks]]"> </bot-page-summary> </div> </div> <div class="t
abs"> <paper-tabs selected="{{_selected}}" no-bar=""> <paper-tab>Tasks</paper-ta
b> <paper-tab>Events</paper-tab> </paper-tabs> <template is="dom-if" if="[[_show
Events]]"> <paper-checkbox checked="{{_show_all}}"> Show all events </paper-chec
kbox> </template> </div> <template is="dom-if" if="[[_not(_showEvents)]]"> <tabl
e class="tasks_table"> <thead> <tr> <th>Task</th> <th>Started</th> <th>Duration<
/th> <th>Result</th> </tr> </thead> <tbody> <template is="dom-repeat" items="{{_
tasks}}" as="task"> <tr class$="[[_taskClass(task)]]"> <td> <a target="_blank" r
el="noopener" href$="[[_taskLink(task.task_id)]]"> [[task.name]] </a> </td> <td>
[[task.human_started_ts]]</td> <td title="[[task.human_completed_ts]]">[[task.hu
man_duration]]</td> <td>[[task.state]]</td> </tr> </template> </tbody> </table>
</template> <template is="dom-if" if="[[_showEvents]]"> <table class="events_tab
le"> <thead> <tr> <th>Message</th> <th>Type</th> <th>Timestamp</th> <th>Task ID<
/th> <th>Version</th> </tr> </thead> <tbody> <template is="dom-repeat" items="{{
_eventList(_show_all,_events.*)}}" as="event"> <tr> <td class="message">[[event.
message]]</td> <td>[[event.event_type]]</td> <td>[[event.human_ts]]</td> <td> <a
target="_blank" rel="noopener" href$="[[_taskLink(event.task_id)]]"> [[event.ta
sk_id]] </a> </td> <td class$="[[_classVersion(_server_details.bot_version,event
.version)]]"> [[_shorten(event.version,'8')]] </td> </tr> </template> </tbody> <
/table> </template> <pageable-data id="page_tasks" hidden$="[[_showEvents]]" bus
y="{{_busy2}}" label="Show more tasks" output="{{_tasks}}" parse="[[_parseTasks]
]"> </pageable-data> <pageable-data id="page_events" hidden$="[[_not(_showEvents
)]]" busy="{{_busy3}}" label="Show more events" output="{{_events}}" parse="[[_p
arseEvents]]"> </pageable-data> </div> </swarming-app> <paper-dialog id="prompt"
modal="" on-iron-overlay-closed="_promptClosed"> <h2>Are you sure?</h2> <div>Ar
e you sure you want to [[_dialogPrompt]]?</div> <div class="buttons"> <paper-but
ton dialog-dismiss="" autofocus="">No</paper-button> <paper-button dialog-confir
m="">Yes</paper-button> </div> </paper-dialog> <error-toast></error-toast> </tem
plate> <script> (function(){ | 716 })(); </script> </dom-module> <dom-module id="paper-button" assetpath="/res/im
p/bower_components/paper-button/"> <template strip-whitespace=""> <style include
="paper-material-shared-styles">:host{@apply(--layout-inline);@apply(--layout-ce
nter-center);position:relative;box-sizing:border-box;min-width:5.14em;margin:0 .
29em;background:0 0;-webkit-tap-highlight-color:transparent;-webkit-tap-highligh
t-color:transparent;font:inherit;text-transform:uppercase;outline-width:0;border
-radius:3px;-moz-user-select:none;-ms-user-select:none;-webkit-user-select:none;
user-select:none;cursor:pointer;z-index:0;padding:.7em .57em;@apply(--paper-font
-common-base);@apply(--paper-button)}:host([hidden]){display:none!important}:hos
t([raised].keyboard-focus){font-weight:700;@apply(--paper-button-raised-keyboard
-focus)}:host(:not([raised]).keyboard-focus){font-weight:700;@apply(--paper-butt
on-flat-keyboard-focus)}:host([disabled]){background:#eaeaea;color:#a8a8a8;curso
r:auto;pointer-events:none;@apply(--paper-button-disabled)}:host([animated]){@ap
ply(--shadow-transition)}paper-ripple{color:var(--paper-button-ink-color)}</styl
e> <content></content> </template> <script>Polymer({is:"paper-button",behaviors:
[Polymer.PaperButtonBehavior],properties:{raised:{type:Boolean,reflectToAttribut
e:!0,value:!1,observer:"_calculateElevation"}},_calculateElevation:function(){th
is.raised?Polymer.PaperButtonBehaviorImpl._calculateElevation.apply(this):this._
setElevation(0)}})</script> </dom-module> <script>Polymer.NeonAnimatableBehavior
={properties:{animationConfig:{type:Object},entryAnimation:{observer:"_entryAnim
ationChanged",type:String},exitAnimation:{observer:"_exitAnimationChanged",type:
String}},_entryAnimationChanged:function(){this.animationConfig=this.animationCo
nfig||{},this.animationConfig.entry=[{name:this.entryAnimation,node:this}]},_exi
tAnimationChanged:function(){this.animationConfig=this.animationConfig||{},this.
animationConfig.exit=[{name:this.exitAnimation,node:this}]},_copyProperties:func
tion(i,n){for(var t in n)i[t]=n[t]},_cloneConfig:function(i){var n={isClone:!0};
return this._copyProperties(n,i),n},_getAnimationConfigRecursive:function(i,n,t)
{if(this.animationConfig){if(this.animationConfig.value&&"function"==typeof this
.animationConfig.value)return void this._warn(this._logf("playAnimation","Please
put 'animationConfig' inside of your components 'properties' object instead of
outside of it."));var o;if(o=i?this.animationConfig[i]:this.animationConfig,Arra
y.isArray(o)||(o=[o]),o)for(var e,a=0;e=o[a];a++)if(e.animatable)e.animatable._g
etAnimationConfigRecursive(e.type||i,n,t);else if(e.id){var r=n[e.id];r?(r.isClo
ne||(n[e.id]=this._cloneConfig(r),r=n[e.id]),this._copyProperties(r,e)):n[e.id]=
e}else t.push(e)}},getAnimationConfig:function(i){var n={},t=[];this._getAnimati
onConfigRecursive(i,n,t);for(var o in n)t.push(n[o]);return t}}</script> <script
>Polymer.NeonAnimationRunnerBehaviorImpl={_configureAnimations:function(n){var i
=[];if(n.length>0)for(var e,t=0;e=n[t];t++){var o=document.createElement(e.name)
;if(o.isNeonAnimation){var a=null;try{a=o.configure(e),"function"!=typeof a.canc
el&&(a=document.timeline.play(a))}catch(n){a=null,console.warn("Couldnt play","(
",e.name,").",n)}a&&i.push({neonAnimation:o,config:e,animation:a})}else console.
warn(this.is+":",e.name,"not found!")}return i},_shouldComplete:function(n){for(
var i=!0,e=0;e<n.length;e++)if("finished"!=n[e].animation.playState){i=!1;break}
return i},_complete:function(n){for(var i=0;i<n.length;i++)n[i].neonAnimation.co
mplete(n[i].config);for(var i=0;i<n.length;i++)n[i].animation.cancel()},playAnim
ation:function(n,i){var e=this.getAnimationConfig(n);if(e){this._active=this._ac
tive||{},this._active[n]&&(this._complete(this._active[n]),delete this._active[n
]);var t=this._configureAnimations(e);if(0==t.length)return void this.fire("neon
-animation-finish",i,{bubbles:!1});this._active[n]=t;for(var o=0;o<t.length;o++)
t[o].animation.onfinish=function(){this._shouldComplete(t)&&(this._complete(t),d
elete this._active[n],this.fire("neon-animation-finish",i,{bubbles:!1}))}.bind(t
his)}},cancelAnimation:function(){for(var n in this._animations)this._animations
[n].cancel();this._animations={}}},Polymer.NeonAnimationRunnerBehavior=[Polymer.
NeonAnimatableBehavior,Polymer.NeonAnimationRunnerBehaviorImpl]</script> <script
>Polymer.PaperDialogBehaviorImpl={hostAttributes:{role:"dialog",tabindex:"-1"},p
roperties:{modal:{type:Boolean,value:!1}},observers:["_modalChanged(modal, _read
ied)"],listeners:{tap:"_onDialogClick"},ready:function(){this.__prevNoCancelOnOu
tsideClick=this.noCancelOnOutsideClick,this.__prevNoCancelOnEscKey=this.noCancel
OnEscKey,this.__prevWithBackdrop=this.withBackdrop},_modalChanged:function(i,e){
e&&(i?(this.__prevNoCancelOnOutsideClick=this.noCancelOnOutsideClick,this.__prev
NoCancelOnEscKey=this.noCancelOnEscKey,this.__prevWithBackdrop=this.withBackdrop
,this.noCancelOnOutsideClick=!0,this.noCancelOnEscKey=!0,this.withBackdrop=!0):(
this.noCancelOnOutsideClick=this.noCancelOnOutsideClick&&this.__prevNoCancelOnOu
tsideClick,this.noCancelOnEscKey=this.noCancelOnEscKey&&this.__prevNoCancelOnEsc
Key,this.withBackdrop=this.withBackdrop&&this.__prevWithBackdrop))},_updateClosi
ngReasonConfirmed:function(i){this.closingReason=this.closingReason||{},this.clo
singReason.confirmed=i},_onDialogClick:function(i){for(var e=Polymer.dom(i).path
,o=0;o<e.indexOf(this);o++){var t=e[o];if(t.hasAttribute&&(t.hasAttribute("dialo
g-dismiss")||t.hasAttribute("dialog-confirm"))){this._updateClosingReasonConfirm
ed(t.hasAttribute("dialog-confirm")),this.close(),i.stopPropagation();break}}}},
Polymer.PaperDialogBehavior=[Polymer.IronOverlayBehavior,Polymer.PaperDialogBeha
viorImpl]</script> <dom-module id="paper-dialog-shared-styles" assetpath="/res/i
mp/bower_components/paper-dialog-behavior/"> <template> <style>:host{display:blo
ck;margin:24px 40px;background:var(--paper-dialog-background-color,--primary-bac
kground-color);color:var(--paper-dialog-color,--primary-text-color);@apply(--pap
er-font-body1);@apply(--shadow-elevation-16dp);@apply(--paper-dialog)}:host>::co
ntent>*{margin-top:20px;padding:0 24px}:host>::content>.no-padding{padding:0}:ho
st>::content>:first-child{margin-top:24px}:host>::content>:last-child{margin-bot
tom:24px}:host>::content h2{position:relative;margin:0;@apply(--paper-font-title
);@apply(--paper-dialog-title)}:host>::content .buttons{position:relative;paddin
g:8px 8px 8px 24px;margin:0;color:var(--paper-dialog-button-color,--primary-colo
r);@apply(--layout-horizontal);@apply(--layout-end-justified)}</style> </templat
e> </dom-module> <dom-module id="paper-dialog" assetpath="/res/imp/bower_compone
nts/paper-dialog/"> <template> <style include="paper-dialog-shared-styles"></sty
le> <content></content> </template> </dom-module> <script>!function(){Polymer({i
s:"paper-dialog",behaviors:[Polymer.PaperDialogBehavior,Polymer.NeonAnimationRun
nerBehavior],listeners:{"neon-animation-finish":"_onNeonAnimationFinish"},_rende
rOpened:function(){this.cancelAnimation(),this.playAnimation("entry")},_renderCl
osed:function(){this.cancelAnimation(),this.playAnimation("exit")},_onNeonAnimat
ionFinish:function(){this.opened?this._finishRenderOpened():this._finishRenderCl
osed()}})}()</script> <script>window.SwarmingBehaviors=window.SwarmingBehaviors|
|{},function(){SwarmingBehaviors.TaskBehavior={properties:{BOT_DIED:{type:String
,value:"BOT_DIED"},CANCELED:{type:String,value:"CANCELED"},COMPLETED:{type:Strin
g,value:"COMPLETED"},COMPLETED_DEDUPED:{type:String,value:"COMPLETED (DEDUPED)"}
,COMPLETED_FAILURE:{type:String,value:"COMPLETED (FAILURE)"},COMPLETED_SUCCESS:{
type:String,value:"COMPLETED (SUCCESS)"},EXPIRED:{type:String,value:"EXPIRED"},P
ENDING:{type:String,value:"PENDING"},RUNNING:{type:String,value:"RUNNING"},TIMED
_OUT:{type:String,value:"TIMED_OUT"}},stateClass:function(t){return t===this.CAN
CELED||t===this.TIMED_OUT||t===this.EXPIRED?"exception":t===this.BOT_DIED?"bot_d
ied":t===this.COMPLETED_FAILURE?"failed_task":t===this.RUNNING||t===this.PENDING
?"pending_task":""},state:function(t){return t?t.state===this.COMPLETED?t.failur
e?this.COMPLETED_FAILURE:"0"===t.try_number?this.COMPLETED_DEDUPED:this.COMPLETE
D_SUCCESS:t.state:""},_stateClass:function(t){return this.stateClass(this.state(
t))}}}()</script> <dom-module id="task-style" assetpath="/res/imp/common/"> <tem
plate> <style>.failed_task{background-color:#fdd}.bot_died{background-color:#ccc
}.exception{background-color:#edd2ff}.pending_task{background-color:#fffc6c}</st
yle> </template> </dom-module><dom-module id="task-filters" assetpath="/res/imp/
tasklist/"> <template> <style is="custom-style" include="iron-flex iron-flex-ali
gnment iron-positioning query-column-filter-style">.item.wide{max-width:400px}.s
elector.wide{min-width:275px}</style> <url-param name="f" value="{{_filters}}" d
efault_values="[]" multi=""> </url-param> <url-param name="c" value="{{columns}}
" default_values="["name","state","created_ts",&qu
ot;user"]" multi=""> </url-param> <url-param name="q" value="{{_query}}" de
fault_value=""> </url-param> <url-param name="l" default_value="50" value="{{_li
mit}}"> </url-param> <div class="container horizontal layout"> <div class="narro
w-down-selector"> <div> <iron-a11y-keys target="[[_filter_input]]" keys="enter"
on-keys-pressed="_manuallyAddFilter"></iron-a11y-keys> <paper-input id="filter"
label="Search columns and filters or supply a filter and press enter" placeholde
r="gpu nvidia pool:Chrome" value="{{_query::input}}"> </paper-input> </div> <div
class="wide selector side-by-side" title="This shows all task tags and other in
teresting task properties. Mark the check box to add as a column. Select the row
to see filter options."> <iron-selector attr-for-selected="label" selected="{{_
primarySelected}}"> <template is="dom-repeat" items="[[_primaryItems]]" as="item
"> <div class="selectable item horizontal layout" label="[[item]]"> <span>[[_bef
oreBold(item,_query)]]<span class="bold">[[_bold(item,_query)]]</span>[[_afterBo
ld(item,_query)]]</span> <span class="flex"></span> <paper-checkbox noink="" dis
abled$="[[_cantToggleColumn(item)]]" checked="[[_columnState(item,columns.*)]]"
on-change="_toggleColumn"> </paper-checkbox> </div> </template> </iron-selector>
</div> <div class="selector side-by-side" title="These are most of the options
(if any) that the task list can be filtered on. This list is all that have been
seen recently, augmented with the ones returned by the current query. There may
be others."> <template is="dom-repeat" id="secondaryList" items="[[_secondaryIte
ms]]" as="item"> <div class="item horizontal layout" label="[[item]]"> <span>[[_
beforeBold(item,_query)]]<span class="bold">[[_bold(item,_query)]]</span>[[_afte
rBold(item,_query)]]</span> <span class="flex"></span> <iron-icon class="icons"
icon="icons:arrow-forward" hidden="[[_cantAddFilter(_primarySelected,item,_filte
rs.*)]]" on-tap="_addFilter"> </iron-icon> </div> </template> </div> <div class=
"selector side-by-side" title="These tag filters are AND'd together and applied
to all tasks."> <template is="dom-repeat" items="[[_filters]]" as="fil"> <div cl
ass="item horizontal layout" label="[[fil]]"> <span>[[fil]]</span> <span class="
flex"></span> <iron-icon class="icons" icon="icons:remove-circle-outline" hidden
="[[_cantRemoveFilter(fil,_filters.*)]]" on-tap="_removeFilter"> </iron-icon> </
div> </template> </div> <div class="side-by-side"> <paper-input id="_limit" labe
l="Limit Results" auto-validate="" min="0" max="1000" pattern="[0-9]+" value="{{
_limit}}"> </paper-input> </div> </div> </div> </template> <script>!function(){v
ar t={state:function(t,i){var r=this._attribute(t,"state")[0];if(i===r||"ALL"===
i)return!0;if("PENDING_RUNNING"===i)return r===this.PENDING||r===this.RUNNING;va
r e=this._attribute(t,"failure",!1)[0];if("COMPLETED_SUCCESS"===i)return r===thi
s.COMPLETED&&!e;if("COMPLETED_FAILURE"===i)return r===this.COMPLETED&&e;var a=th
is._attribute(t,"try_number","-1")[0];return"DEDUPED"===i?r===this.COMPLETED&&"0
"===a:void 0}};Polymer({is:"task-filters",behaviors:[SwarmingBehaviors.QueryColu
mnFilter,SwarmingBehaviors.TaskBehavior],properties:{columns:{type:Array,notify:
!0},query_params:{type:Object,computed:"_extractQueryParams(_filters.*, _limit)"
,notify:!0},_filterMap:{type:Object,value:function(){var i=this._commonFilters()
;for(var r in t)i[r]=t[r];return i}}},_cantToggleColumn:function(t){return!t||"n
ame"===t},_extractQueryParams:function(){var t={},i=[];this._filters.forEach(fun
ction(r){var e=r.split(this.FILTER_SEP,1),a=e[0],s=r.substring(a.length+this.FIL
TER_SEP.length);"state"===a?t.state=[s]:("user"===a&&"none"===s&&(s=""),i.push(a
+this.FILTER_SEP+swarming.alias.unapply(s)))}.bind(this)),t.tags=i;var r=parseIn
t(this._limit);return Number.isInteger(r)&&(r=Math.max(r,1),r=Math.min(1e3,r),t.
limit=[r],this._limit!=r&&this.set("_limit",r)),t}})}()</script> </dom-module><d
om-module id="task-list-data" assetpath="/res/imp/tasklist/"> <script>!function(
){var t=["abandoned_ts","completed_ts","created_ts","modified_ts","started_ts"];
Polymer({is:"task-list-data",behaviors:[SwarmingBehaviors.CommonBehavior,Swarmin
gBehaviors.TaskBehavior],properties:{auth_headers:{type:Object,observer:"signIn"
},query_params:{type:Object},tasks:{type:Array},busy:{type:Boolean,computed:"_or
(_busy2,_busy1)",notify:!0},primary_map:{type:Object,computed:"_primaryMap(_tags
,_dimensions,tasks.*)",notify:!0},primary_arr:{type:Array,computed:"_primaryArr(
primary_map)",notify:!0},_busy2:{type:Boolean,value:!1},_busy1:{type:Boolean,val
ue:!1},_dimensions:{type:Object},_list:{type:Object},_tags:{type:Object}},signIn
:function(){this._getJsonAsync("_tags","/api/swarming/v1/tasks/tags","_busy2",th
is.auth_headers),this._getJsonAsync("_dimensions","/api/swarming/v1/bots/dimensi
ons","_busy1",this.auth_headers)},_primaryArr:function(t){var a=Object.keys(t);r
eturn a.sort(),a},_primaryMap:function(a,s){a=a&&a.tasks_tags||[],s=s&&s.bots_di
mensions||[],tasks=this.tasks||[];var e={};a.forEach(function(t){e[t.key]||(e[t.
key]={});var a=t.value||[];a.forEach(function(a){e[t.key][a]=!0})}),s.forEach(fu
nction(t){var a=t.value;e[t.key]||(e[t.key]={}),a.forEach(function(a){e[t.key][a
]=!0})}),tasks.forEach(function(t){Object.keys(t.tagMap).forEach(function(a){var
s=t.tagMap[a];e[a]||(e[a]={}),e[a][s]=!0})}),e.user&&(delete e.user[""],e.user.
none=!0);var r={};for(key in e){var i=Object.keys(e[key]);if(swarming.alias.DIME
NSIONS_WITH_ALIASES.indexOf(key)===-1)r[key]=i;else{var n=[];i.forEach(function(
t){n.push(swarming.alias.apply(t,key))}),r[key]=n}}return r.name=[],r.state=[thi
s.PENDING,this.RUNNING,"PENDING_RUNNING",this.COMPLETED,"COMPLETED_SUCCESS","COM
PLETED_FAILURE",this.EXPIRED,this.TIMED_OUT,this.BOT_DIED,this.CANCELED,"DEDUPED
","ALL"],r.costs_usd=[],r.deduped_from=[],r.duration=[],r.server_versions=[],r.b
ot=[],t.forEach(function(t){r[t]=[]}),r},parseTasks:function(a){if(!a||!a.items)
return[];var s=new Date;return a.items.forEach(function(a){var e={};a.tags=a.tag
s||[],a.tags.forEach(function(t){var a=t.split(":",1),s=a[0],r=t.substring(s.len
gth+1);e[s]=r}),a.tagMap=e,t.forEach(function(t){a[t]&&(a[t]=new Date(a[t]),a["h
uman_"+t]=sk.human.localeTime(a[t]))}),!a.duration&&a.state===this.RUNNING&&a.st
arted_ts&&(a.duration=(s-a.started_ts)/1e3),a.duration&&(a.human_duration=this._
humanDuration(a.duration))}.bind(this)),a.items}})}()</script> </dom-module> <do
m-module id="task-list" assetpath="/res/imp/tasklist/"> <template> <style includ
e="iron-flex iron-flex-alignment iron-positioning swarming-app-style dynamic-tab
le-style task-style">task-filters{margin-bottom:8px;margin-right:10px}.task-list
th>span{padding-right:30px}</style> <url-param name="s" value="{{_sortstr}}" de
fault_value="created_ts:desc"> </url-param> <swarming-app client_id="[[client_id
]]" auth_headers="{{_auth_headers}}" permissions="{{_permissions}}" signed_in="{
{_signed_in}}" busy="[[_or(_busy1,_busy2)]]" name="Swarming Task List"> <h2 hidd
en$="[[_signed_in]]">You must sign in to see anything useful.</h2> <div hidden$=
"[[_not(_signed_in)]]"> <task-list-data id="data" auth_headers="[[_auth_headers]
]" query_params="[[_query_params]]" tasks="[[_items]]" busy="{{_busy1)}}" primar
y_map="{{_primary_map}}" primary_arr="{{_primary_arr}}"> </task-list-data> <div
class="horizontal layout"> <task-filters primary_map="[[_primary_map]]" primary_
arr="[[_primary_arr]]" columns="{{_columns}}" query_params="{{_query_params}}" f
ilter="{{_filter}}"> </task-filters> </div> <table class="task-list"> <thead on-
sort_change="_sortChange"> <tr> <th> <span>Task Name</span> <sort-toggle name="n
ame" current="[[_sort]]"> </sort-toggle> </th> <th hidden$="[[_hide('state', _co
lumns.*)]]"> <span>State</span> <sort-toggle name="state" current="[[_sort]]"> <
/sort-toggle> </th> <th hidden$="[[_hide('bot', _columns.*)]]"> <span>Bot Assign
ed</span> <sort-toggle name="bot" current="[[_sort]]"> </sort-toggle> </th> <th
hidden$="[[_hide('deduped_from', _columns.*)]]"> <span>Deduped from</span> <sort
-toggle name="deduped_from" current="[[_sort]]"> </sort-toggle> </th> <th hidden
$="[[_hide('source_revision', _columns.*)]]"> <span>Source Revision</span> <sort
-toggle name="source_revision" current="[[_sort]]"> </sort-toggle> </th> <templa
te is="dom-repeat" items="[[_plainColumns]]" as="c"> <th hidden$="[[_hide(c)]]">
<span>[[_header(c)]]</span> <sort-toggle name="[[c]]" current="[[_sort]]"> </so
rt-toggle> </th> </template> </tr> </thead> <tbody> <template id="tasks_table" i
s="dom-repeat" items="[[_filteredSortedItems]]" as="task" initial-count="50"> <t
r class$="[[_taskClass(task)]]"> <td> <a class="center" href$="[[_taskLink(task.
task_id)]]" target="_blank"> [[task.name]] </a> </td> <td hidden$="[[_hide('stat
e', _columns.*)]]"> [[_column('state', task)]] <paper-button raised="" hidden$="
[[_cannotCancel(task,_permissions)]]" on-tap="_promptCancel"> Cancel </paper-but
ton> </td> <td hidden$="[[_hide('bot', _columns.*)]]"> <a class="center" href$="
[[_botLink(task.bot_id)]]" target="_blank"> [[_column('bot',task)]] </a> </td> <
td hidden$="[[_hide('deduped_from', _columns.*)]]"> <a class="center" href$="[[_
taskLink(task.deduped_from)]]" target="_blank"> [[_column('deduped_from',task)]]
</a> </td> <td hidden$="[[_hide('source_revision', _columns.*)]]"> <a class="ce
nter" href$="[[_sourceLink(task)]]" target="_blank"> [[_column('source_revision'
,task)]] </a> </td> <template is="dom-repeat" items="[[_plainColumns]]" as="c">
<td hidden$="[[_hide(c)]]"> [[_column(c, task)]] </td> </template> </tr> </templ
ate> </tbody> </table> <pageable-data id="page_tasks" busy="{{_busy2}}" label="S
how more tasks" output="{{_items}}" parse="[[_parseTasks]]"> </pageable-data> </
div> </swarming-app> <paper-dialog id="prompt" modal="" on-iron-overlay-closed="
_promptClosed"> <h2>Are you sure?</h2> <div>Are you sure you want to [[_dialogPr
ompt]]?</div> <div class="buttons"> <paper-button dialog-dismiss="" autofocus=""
>No</paper-button> <paper-button dialog-confirm="">Yes</paper-button> </div> </p
aper-dialog> <error-toast></error-toast> </template> <script>!function(){functio
n t(t){return function(e){return this._attribute(e,"human_"+t)[0]}}function e(t)
{return function(e,a,s){var r=this._attribute(a,t,"0")[0],i=this._attribute(s,t,
"0")[0];return e*(r-i)}}var a=["deduped_from","name","state","bot","source_revis
ion"],s={abandoned_ts:t("abandoned_ts"),bot:function(t){return this._attribute(t
,"bot_id")[0]},completed_ts:t("completed_ts"),costs_usd:function(t){return this.
_attribute(t,"costs_usd",0)[0]},created_ts:t("created_ts"),duration:t("duration"
),modified_ts:t("modified_ts"),source_revision:function(t){var e=this._attribute
(t,"source_revision")[0];return e.substring(0,8)},started_ts:t("started_ts"),sta
te:function(t){var e=this._attribute(t,"state")[0];if("COMPLETED"===e){if(this._
attribute(t,"failure",!1)[0])return"COMPLETED (FAILURE)";var a=this._attribute(t
,"try_number","-1")[0];return"0"===a?"COMPLETED (DEDUPED)":"COMPLETED (SUCCESS)"
}return e}},r={user:"Requesting User"},i={abandoned_ts:e("abandoned_ts"),complet
ed_ts:e("completed_ts"),created_ts:e("created_ts"),duration:e("duration"),modifi
ed_ts:e("modified_ts"),started_ts:e("started_ts")};Polymer({is:"task-list",behav
iors:[SwarmingBehaviors.DynamicTableBehavior,SwarmingBehaviors.TaskBehavior],pro
perties:{client_id:{type:String},_busy1:{type:Boolean,value:!1},_busy2:{type:Boo
lean,value:!1},_parseTasks:{type:Function,value:function(){return this.$.data.pa
rseTasks.bind(this)}},_toCancel:{type:String},_columnMap:{type:Object,value:func
tion(){var t=this._commonColumns();for(var e in s)t[e]=s[e];return t}},_headerMa
p:{type:Object,value:r},_specialColumns:{type:Array,value:a},_specialSort:{type:
Object,value:i}},observers:["reload(_query_params,_auth_headers)"],_attribute:fu
nction(t,e,a){void 0===a&&(a="none");var s=this._tag(t,e)||t[e]||[a];return Arra
y.isArray(s)?s:[s]},_cannotCancel:function(t,e){return!(e&&e.cancel_task&&"PENDI
NG"===this._column("state",t))},_cancelTask:function(){var t="/api/swarming/v1/t
ask/"+this._toCancel+"/cancel";swarming.postWithToast(t,"Canceling task "+this._
toCancel,this._auth_headers),this.set("_toCancel","")},_promptClosed:function(t)
{t.detail.confirmed&&this._cancelTask()},_promptCancel:function(t){var e=t.model
.task;return e&&e.task_id?(this.set("_toCancel",e.task_id),this.set("_dialogProm
pt",'cancel task "'+e.name+'"'),void this.$.prompt.open()):void console.log("Mis
sing task info",e)},reload:function(){if(this._auth_headers&&this._query_params)
{var t="/api/swarming/v1/tasks/list?"+sk.query.fromParamSet(this._query_params);
this.$.page_tasks.load(t,this._auth_headers)}},_sourceLink:function(t){var e=thi
s._attribute(t,"source_revision")[0],a=this._attribute(t,"source_repo")[0];retur
n"none"!==e&&"none"!==a&&a.replace("%s",e)},_tag:function(t,e){if(t&&t.tagMap)re
turn t.tagMap[e]},_taskClass:function(t){return this.stateClass(this._column("st
ate",t))}})}()</script> </dom-module> <dom-module id="iron-collapse" assetpath="
/res/imp/bower_components/iron-collapse/"> <template> <style>:host{display:block
;transition-duration:var(--iron-collapse-transition-duration,300ms);overflow:vis
ible}:host(.iron-collapse-closed){display:none}:host(:not(.iron-collapse-opened)
){overflow:hidden}</style> <content></content> </template> </dom-module> <script
>Polymer({is:"iron-collapse",behaviors:[Polymer.IronResizableBehavior],propertie
s:{horizontal:{type:Boolean,value:!1,observer:"_horizontalChanged"},opened:{type
:Boolean,value:!1,notify:!0,observer:"_openedChanged"},noAnimation:{type:Boolean
},_desiredSize:{type:String,value:""}},get dimension(){return this.horizontal?"w
idth":"height"},get _dimensionMax(){return this.horizontal?"maxWidth":"maxHeight
"},get _dimensionMaxCss(){return this.horizontal?"max-width":"max-height"},hostA
ttributes:{role:"group","aria-hidden":"true","aria-expanded":"false"},listeners:
{transitionend:"_transitionEnd"},attached:function(){this._transitionEnd()},togg
le:function(){this.opened=!this.opened},show:function(){this.opened=!0},hide:fun
ction(){this.opened=!1},updateSize:function(i,t){if(i="auto"===i?"":i,this._desi
redSize!==i){this._desiredSize=i,this._updateTransition(!1);var e=t&&!this.noAni
mation&&this._isDisplayed;if(e){var n=this._calcSize();""===i&&(this.style[this.
_dimensionMax]="",i=this._calcSize()),this.style[this._dimensionMax]=n,this.scro
llTop=this.scrollTop,this._updateTransition(!0),e=i!==n}this.style[this._dimensi
onMax]=i,e||this._transitionEnd()}},enableTransition:function(i){Polymer.Base._w
arn("`enableTransition()` is deprecated, use `noAnimation` instead."),this.noAni
mation=!i},_updateTransition:function(i){this.style.transitionDuration=i&&!this.
noAnimation?"":"0s"},_horizontalChanged:function(){this.style.transitionProperty
=this._dimensionMaxCss;var i="maxWidth"===this._dimensionMax?"maxHeight":"maxWid
th";this.style[i]="",this.updateSize(this.opened?"auto":"0px",!1)},_openedChange
d:function(){this.setAttribute("aria-expanded",this.opened),this.setAttribute("a
ria-hidden",!this.opened),this.toggleClass("iron-collapse-closed",!1),this.toggl
eClass("iron-collapse-opened",!1),this.updateSize(this.opened?"auto":"0px",!0),t
his.opened&&this.focus()},_transitionEnd:function(){this.style[this._dimensionMa
x]=this._desiredSize,this.toggleClass("iron-collapse-closed",!this.opened),this.
toggleClass("iron-collapse-opened",this.opened),this._updateTransition(!1),this.
notifyResize()},get _isDisplayed(){var i=this.getBoundingClientRect();for(var t
in i)if(0!==i[t])return!0;return!1},_calcSize:function(){return this.getBounding
ClientRect()[this.dimension]+"px"}})</script> <script>Polymer.IronMenubarBehavio
rImpl={hostAttributes:{role:"menubar"},keyBindings:{left:"_onLeftKey",right:"_on
RightKey"},_onUpKey:function(e){this.focusedItem.click(),e.detail.keyboardEvent.
preventDefault()},_onDownKey:function(e){this.focusedItem.click(),e.detail.keybo
ardEvent.preventDefault()},get _isRTL(){return"rtl"===window.getComputedStyle(th
is).direction},_onLeftKey:function(e){this._isRTL?this._focusNext():this._focusP
revious(),e.detail.keyboardEvent.preventDefault()},_onRightKey:function(e){this.
_isRTL?this._focusPrevious():this._focusNext(),e.detail.keyboardEvent.preventDef
ault()},_onKeydown:function(e){this.keyboardEventMatchesKeys(e,"up down left rig
ht esc")||this._focusWithKeyboardEvent(e)}},Polymer.IronMenubarBehavior=[Polymer
.IronMenuBehavior,Polymer.IronMenubarBehaviorImpl]</script> <iron-iconset-svg na
me="paper-tabs" size="24"> <svg><defs> <g id="chevron-left"><path d="M15.41 7.41
L14 6l-6 6 6 6 1.41-1.41L10.83 12z"></path></g> <g id="chevron-right"><path d="M
10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"></path></g> </defs></svg> </iron-
iconset-svg> <dom-module id="paper-tab" assetpath="/res/imp/bower_components/pap
er-tabs/"> <template> <style>:host{@apply(--layout-inline);@apply(--layout-cente
r);@apply(--layout-center-justified);@apply(--layout-flex-auto);position:relativ
e;padding:0 12px;overflow:hidden;cursor:pointer;vertical-align:middle;@apply(--p
aper-font-common-base);@apply(--paper-tab)}:host(:focus){outline:0}:host([link])
{padding:0}.tab-content{height:100%;transform:translateZ(0);-webkit-transform:tr
anslateZ(0);transition:opacity .1s cubic-bezier(.4,0,1,1);@apply(--layout-horizo
ntal);@apply(--layout-center-center);@apply(--layout-flex-auto);@apply(--paper-t
ab-content)}:host(:not(.iron-selected))>.tab-content{opacity:.8;@apply(--paper-t
ab-content-unselected)}:host(:focus) .tab-content{opacity:1;font-weight:700}pape
r-ripple{color:var(--paper-tab-ink,--paper-yellow-a100)}.tab-content>::content>a
{@apply(--layout-flex-auto);height:100%}</style> <div class="tab-content"> <cont
ent></content> </div> </template> <script>Polymer({is:"paper-tab",behaviors:[Pol
ymer.IronControlState,Polymer.IronButtonState,Polymer.PaperRippleBehavior],prope
rties:{link:{type:Boolean,value:!1,reflectToAttribute:!0}},hostAttributes:{role:
"tab"},listeners:{down:"_updateNoink",tap:"_onTap"},attached:function(){this._up
dateNoink()},get _parentNoink(){var t=Polymer.dom(this).parentNode;return!!t&&!!
t.noink},_updateNoink:function(){this.noink=!!this.noink||!!this._parentNoink},_
onTap:function(t){if(this.link){var e=this.queryEffectiveChildren("a");if(!e)ret
urn;if(t.target===e)return;e.click()}}})</script> </dom-module> <dom-module id="
paper-tabs" assetpath="/res/imp/bower_components/paper-tabs/"> <template> <style
>:host{@apply(--layout);@apply(--layout-center);height:48px;font-size:14px;font-
weight:500;overflow:hidden;-moz-user-select:none;-ms-user-select:none;-webkit-us
er-select:none;user-select:none;-webkit-tap-highlight-color:transparent;-webkit-
tap-highlight-color:transparent;@apply(--paper-tabs)}:host-context([dir=rtl]){@a
pply(--layout-horizontal-reverse)}#tabsContainer{position:relative;height:100%;w
hite-space:nowrap;overflow:hidden;@apply(--layout-flex-auto)}#tabsContent{height
:100%;-moz-flex-basis:auto;-ms-flex-basis:auto;flex-basis:auto}#tabsContent.scro
llable{position:absolute;white-space:nowrap}#tabsContent.scrollable.fit-containe
r,#tabsContent:not(.scrollable){@apply(--layout-horizontal)}#tabsContent.scrolla
ble.fit-container{min-width:100%}#tabsContent.scrollable.fit-container>::content
>*{-ms-flex:1 0 auto;-webkit-flex:1 0 auto;flex:1 0 auto}.hidden{display:none}.n
ot-visible{opacity:0;cursor:default}paper-icon-button{width:48px;height:48px;pad
ding:12px;margin:0 4px}#selectionBar{position:absolute;height:2px;bottom:0;left:
0;right:0;background-color:var(--paper-tabs-selection-bar-color,--paper-yellow-a
100);-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:left
center;transform-origin:left center;transition:-webkit-transform;transition:tra
nsform;@apply(--paper-tabs-selection-bar)}#selectionBar.align-bottom{top:0;botto
m:auto}#selectionBar.expand{transition-duration:.15s;transition-timing-function:
cubic-bezier(.4,0,1,1)}#selectionBar.contract{transition-duration:.18s;transitio
n-timing-function:cubic-bezier(0,0,.2,1)}#tabsContent>::content>:not(#selectionB
ar){height:100%}</style> <paper-icon-button icon="paper-tabs:chevron-left" class
$="[[_computeScrollButtonClass(_leftHidden, scrollable, hideScrollButtons)]]" on
-up="_onScrollButtonUp" on-down="_onLeftScrollButtonDown" tabindex="-1"></paper-
icon-button> <div id="tabsContainer" on-track="_scroll" on-down="_down"> <div id
="tabsContent" class$="[[_computeTabsContentClass(scrollable, fitContainer)]]">
<div id="selectionBar" class$="[[_computeSelectionBarClass(noBar, alignBottom)]]
" on-transitionend="_onBarTransitionEnd"></div> <content select="*"></content> <
/div> </div> <paper-icon-button icon="paper-tabs:chevron-right" class$="[[_compu
teScrollButtonClass(_rightHidden, scrollable, hideScrollButtons)]]" on-up="_onSc
rollButtonUp" on-down="_onRightScrollButtonDown" tabindex="-1"></paper-icon-butt
on> </template> <script>Polymer({is:"paper-tabs",behaviors:[Polymer.IronResizabl
eBehavior,Polymer.IronMenubarBehavior],properties:{noink:{type:Boolean,value:!1,
observer:"_noinkChanged"},noBar:{type:Boolean,value:!1},noSlide:{type:Boolean,va
lue:!1},scrollable:{type:Boolean,value:!1},fitContainer:{type:Boolean,value:!1},
disableDrag:{type:Boolean,value:!1},hideScrollButtons:{type:Boolean,value:!1},al
ignBottom:{type:Boolean,value:!1},selectable:{type:String,value:"paper-tab"},aut
oselect:{type:Boolean,value:!1},autoselectDelay:{type:Number,value:0},_step:{typ
e:Number,value:10},_holdDelay:{type:Number,value:1},_leftHidden:{type:Boolean,va
lue:!1},_rightHidden:{type:Boolean,value:!1},_previousTab:{type:Object}},hostAtt
ributes:{role:"tablist"},listeners:{"iron-resize":"_onTabSizingChanged","iron-it
ems-changed":"_onTabSizingChanged","iron-select":"_onIronSelect","iron-deselect"
:"_onIronDeselect"},keyBindings:{"left:keyup right:keyup":"_onArrowKeyup"},creat
ed:function(){this._holdJob=null,this._pendingActivationItem=void 0,this._pendin
gActivationTimeout=void 0,this._bindDelayedActivationHandler=this._delayedActiva
tionHandler.bind(this),this.addEventListener("blur",this._onBlurCapture.bind(thi
s),!0)},ready:function(){this.setScrollDirection("y",this.$.tabsContainer)},deta
ched:function(){this._cancelPendingActivation()},_noinkChanged:function(t){var e
=Polymer.dom(this).querySelectorAll("paper-tab");e.forEach(t?this._setNoinkAttri
bute:this._removeNoinkAttribute)},_setNoinkAttribute:function(t){t.setAttribute(
"noink","")},_removeNoinkAttribute:function(t){t.removeAttribute("noink")},_comp
uteScrollButtonClass:function(t,e,i){return!e||i?"hidden":t?"not-visible":""},_c
omputeTabsContentClass:function(t,e){return t?"scrollable"+(e?" fit-container":"
"):" fit-container"},_computeSelectionBarClass:function(t,e){return t?"hidden":e
?"align-bottom":""},_onTabSizingChanged:function(){this.debounce("_onTabSizingCh
anged",function(){this._scroll(),this._tabChanged(this.selectedItem)},10)},_onIr
onSelect:function(t){this._tabChanged(t.detail.item,this._previousTab),this._pre
viousTab=t.detail.item,this.cancelDebouncer("tab-changed")},_onIronDeselect:func
tion(t){this.debounce("tab-changed",function(){this._tabChanged(null,this._previ
ousTab),this._previousTab=null},1)},_activateHandler:function(){this._cancelPend
ingActivation(),Polymer.IronMenuBehaviorImpl._activateHandler.apply(this,argumen
ts)},_scheduleActivation:function(t,e){this._pendingActivationItem=t,this._pendi
ngActivationTimeout=this.async(this._bindDelayedActivationHandler,e)},_delayedAc
tivationHandler:function(){var t=this._pendingActivationItem;this._pendingActiva
tionItem=void 0,this._pendingActivationTimeout=void 0,t.fire(this.activateEvent,
null,{bubbles:!0,cancelable:!0})},_cancelPendingActivation:function(){void 0!==t
his._pendingActivationTimeout&&(this.cancelAsync(this._pendingActivationTimeout)
,this._pendingActivationItem=void 0,this._pendingActivationTimeout=void 0)},_onA
rrowKeyup:function(t){this.autoselect&&this._scheduleActivation(this.focusedItem
,this.autoselectDelay)},_onBlurCapture:function(t){t.target===this._pendingActiv
ationItem&&this._cancelPendingActivation()},get _tabContainerScrollSize(){return
Math.max(0,this.$.tabsContainer.scrollWidth-this.$.tabsContainer.offsetWidth)},
_scroll:function(t,e){if(this.scrollable){var i=e&&-e.ddx||0;this._affectScroll(
i)}},_down:function(t){this.async(function(){this._defaultFocusAsync&&(this.canc
elAsync(this._defaultFocusAsync),this._defaultFocusAsync=null)},1)},_affectScrol
l:function(t){this.$.tabsContainer.scrollLeft+=t;var e=this.$.tabsContainer.scro
llLeft;this._leftHidden=0===e,this._rightHidden=e===this._tabContainerScrollSize
},_onLeftScrollButtonDown:function(){this._scrollToLeft(),this._holdJob=setInter
val(this._scrollToLeft.bind(this),this._holdDelay)},_onRightScrollButtonDown:fun
ction(){this._scrollToRight(),this._holdJob=setInterval(this._scrollToRight.bind
(this),this._holdDelay)},_onScrollButtonUp:function(){clearInterval(this._holdJo
b),this._holdJob=null},_scrollToLeft:function(){this._affectScroll(-this._step)}
,_scrollToRight:function(){this._affectScroll(this._step)},_tabChanged:function(
t,e){if(!t)return this.$.selectionBar.classList.remove("expand"),this.$.selectio
nBar.classList.remove("contract"),void this._positionBar(0,0);var i=this.$.tabsC
ontent.getBoundingClientRect(),n=i.width,o=t.getBoundingClientRect(),s=o.left-i.
left;if(this._pos={width:this._calcPercent(o.width,n),left:this._calcPercent(s,n
)},this.noSlide||null==e)return this.$.selectionBar.classList.remove("expand"),t
his.$.selectionBar.classList.remove("contract"),void this._positionBar(this._pos
.width,this._pos.left);var a=e.getBoundingClientRect(),l=this.items.indexOf(e),c
=this.items.indexOf(t),r=5;this.$.selectionBar.classList.add("expand");var h=l<c
,d=this._isRTL;d&&(h=!h),h?this._positionBar(this._calcPercent(o.left+o.width-a.
left,n)-r,this._left):this._positionBar(this._calcPercent(a.left+a.width-o.left,
n)-r,this._calcPercent(s,n)+r),this.scrollable&&this._scrollToSelectedIfNeeded(o
.width,s)},_scrollToSelectedIfNeeded:function(t,e){var i=e-this.$.tabsContainer.
scrollLeft;i<0?this.$.tabsContainer.scrollLeft+=i:(i+=t-this.$.tabsContainer.off
setWidth,i>0&&(this.$.tabsContainer.scrollLeft+=i))},_calcPercent:function(t,e){
return 100*t/e},_positionBar:function(t,e){t=t||0,e=e||0,this._width=t,this._lef
t=e,this.transform("translateX("+e+"%) scaleX("+t/100+")",this.$.selectionBar)},
_onBarTransitionEnd:function(t){var e=this.$.selectionBar.classList;e.contains("
expand")?(e.remove("expand"),e.add("contract"),this._positionBar(this._pos.width
,this._pos.left)):e.contains("contract")&&e.remove("contract")}})</script> </dom
-module> <dom-module id="single-page-style" assetpath="/res/imp/common/"> <templ
ate> <style>.header{max-width:800px}.title{font-size:1.5em;font-weight:700;margi
n:5px}.id_input{margin-left:5px;--paper-input-container-input:{font-size:2em};}.
refresh{max-width:40px;max-height:40px;width:initial;height:initial}button{min-w
idth:4em;max-height:55px}table{border-collapse:collapse;margin-left:5px;margin-b
ottom:8px}td,th{border:1px solid #BBB;padding:5px}.tabs{background-color:#1F78B4
;color:#fff;max-width:600px;margin-left:5px;--paper-checkbox-label-color:#fff}pa
per-tab{background-color:#A6CEE3;color:#000}paper-tab.iron-selected{background-c
olor:#1F78B4;color:#fff;font-weight:700;text-decoration:underline}paper-tab[disa
bled]{background-color:#AAA;text-decoration:line-through}.quarantined{background
-color:#fdd}.dead{background-color:#ccc}</style> </template> </dom-module><scrip
t>!function(){SwarmingBehaviors.BotPageBehavior=[SwarmingBehaviors.CommonBehavio
r,{}]}()</script> <dom-module id="bot-page-data" assetpath="/res/imp/botpage/">
<script>!function(){function t(t){if(!s){var e=t.toString();s=e.substring(e.inde
xOf("("))}return t.toLocaleString()+" "+s}var e,s,i=400,n=["first_seen_ts","last
_seen_ts","lease_expiration_ts"],a=["started_ts","completed_ts","abandoned_ts","
modified_ts"];Polymer({is:"bot-page-data",behaviors:[SwarmingBehaviors.BotPageBe
havior],properties:{auth_headers:{type:Object},bot_id:{type:String},busy:{type:B
oolean,computed:"_or(_busy1)",notify:!0},bot:{type:Object,computed:"_parseBot(_b
ot)",notify:!0},bot_exists:{type:Boolean,value:!0,notify:!0},_busy1:{type:Boolea
n,value:!1},_bot:{type:Object},_events:{type:Object},_tasks:{type:Object}},obser
vers:["request(auth_headers,bot_id)"],request:function(){this.bot_id&&this.auth_
headers&&(e&&this.cancelAsync(e),e=this.async(function(){e=void 0;var t="/api/sw
arming/v1/bot/"+this.bot_id,s=this._getJsonAsync("_bot",t+"/get","_busy1",this.a
uth_headers);s.then(function(){this.set("bot_exists",!0)}.bind(this)).catch(func
tion(t){404===t.status?this.set("bot_exists",!1):sk.errorMessage("Http response:
"+(t.status||" ")+" "+t.response)}.bind(this)),this.fire("reload",{id:this.bot_
id})},i))},_parseBot:function(e){if(!e)return{};e.state=e.state||"{}",e.state=JS
ON.parse(e.state)||{};var s=e.state.disks||{},i=Object.keys(s);if(i.length){e.di
sks=[];for(var a=0;a<i.length;a++)e.disks.push({id:i[a],mb:s[i[a]].free_mb});e.d
isks.sort(function(t,e){return e.mb-t.mb})}else e.disks=[{id:"unknown",mb:0}];re
turn e.dimensions=e.dimensions||[],e.dimensions.forEach(function(t){swarming.ali
as.DIMENSIONS_WITH_ALIASES.indexOf(t.key)!==-1&&t.value.forEach(function(e,s){t.
value[s]=swarming.alias.apply(e,t.key)})}),n.forEach(function(s){e[s]&&(e[s]=new
Date(e[s]),e["human_"+s]=t(e[s]))}),e},parseEvents:function(e){if(!e||!e.items)
return[];var e=e.items;return e.forEach(function(e){e.ts&&(e.ts=new Date(e.ts),e
.human_ts=t(e.ts))}),e.sort(function(t,e){return e.ts-t.ts}),e},parseTasks:funct
ion(e){if(!e||!e.items)return[];var e=e.items;return e.forEach(function(e){if(a.
forEach(function(s){e[s]&&(e[s]=new Date(e[s]),e["human_"+s]=t(e[s]))}),e.durati
on)e.human_duration=this._humanDuration(e.duration);else{var s=e.completed_ts||e
.abandoned_ts||e.modified_ts||new Date;e.human_duration=this._timeDiffExact(e.st
arted_ts,s),e.duration=(s.getTime()-e.started_ts)/1e3}e.state=e.state||"UNKNOWN"
,"COMPLETED"===e.state&&(e.failure?e.state="FAILURE":e.state="SUCCESS")}.bind(th
is)),e.sort(function(t,e){return e.started_ts-t.started_ts}),e}})}()</script> </
dom-module> <dom-module id="bot-page-summary" assetpath="/res/imp/botpage/"> <te
mplate> <style include="single-page-style">.wrapper{display:table;margin-left:au
to;margin-bottom:10px;margin-right:5px}paper-checkbox{margin-left:5px}.thick{bor
der-top-style:solid}</style> <url-param name="show_full_names" value="{{_show_fu
ll_names}}"> </url-param> <url-param name="show_all_tasks" value="{{_show_all_ta
sks}}"> </url-param> <url-param name="sort_stats" value="{{_sortstr}}" default_v
alue="total:desc"> </url-param> <div class="wrapper"> <table> <thead on-sort_cha
nge="_sortChange"> <tr> <th> <span>Name</span> <sort-toggle name="full_name" cur
rent="[[_sort]]"> </sort-toggle> </th> <th> <span>Total</span> <sort-toggle name
="total" current="[[_sort]]"> </sort-toggle> </th> <th> <span>Success</span> <so
rt-toggle name="success" current="[[_sort]]"> </sort-toggle> </th> <th> <span>Fa
iled</span> <sort-toggle name="failed" current="[[_sort]]"> </sort-toggle> </th>
<th> <span>Died</span> <sort-toggle name="bot_died" current="[[_sort]]"> </sort
-toggle> </th> <th> <span>Average Duration</span> <sort-toggle name="avg_duratio
n" current="[[_sort]]"> </sort-toggle> </th> <th> <span>Total Duration</span> <s
ort-toggle name="total_time" current="[[_sort]]"> </sort-toggle> </th> <th>Perce
nt of Total</th> </tr> </thead> <tbody> <template is="dom-repeat" items="[[_task
sToShow]]" as="task"> <tr> <td hidden$="[[_truthy(_show_full_names)]]" title="[[
task.full_name]]">[[task.name]]</td> <td hidden$="[[_not(_show_full_names)]]" ti
tle="[[task.full_name]]">[[task.full_name]]</td> <td>[[task.total]]</td> <td>[[t
ask.success]]</td> <td>[[task.failed]]</td> <td>[[task.bot_died]]</td> <td>[[_hu
manDuration(task.avg_duration)]]</td> <td>[[_humanDuration(task.total_time)]]</t
d> <td>[[task.total_time_percent]]%</td> </tr> </template> </tbody> <tbody><tr c
lass="thick"> <td>Total</td> <td>[[_totalStats.total]]</td> <td>[[_totalStats.su
ccess]]</td> <td>[[_totalStats.failed]]</td> <td>[[_totalStats.bot_died]]</td> <
td>[[_humanDuration(_totalStats.avg_duration)]]</td> <td>[[_humanDuration(_total
Stats.total_time)]]</td> <td>100.0%</td> </tr> </tbody></table> <div> <table> <t
head> <tr> <th title="How much time passed between the oldest task fetched and n
ow."> Total Wall Time </th> <th title="How much of the wall time this bot was bu
sy with a task."> Wall Time Utilization </th> </tr> </thead> <tbody> <tr> <td>[[
_humanDuration(_totalStats.wall_time)]]</td> <td>[[_totalStats.wall_time_utiliza
tion]]%</td> </tr> </tbody> </table> <paper-checkbox checked="{{_show_full_names
}}"> Show Full Names </paper-checkbox> <paper-checkbox hidden$="[[_cannotExpand]
]" checked="{{_show_all_tasks}}"> Show All Tasks </paper-checkbox> </div> </div>
</template> <script>!function(){var t=15;Polymer({is:"bot-page-summary",behavio
rs:[SwarmingBehaviors.BotPageBehavior],properties:{tasks:{type:Array},_cannotExp
and:{type:Boolean,computed:"_countTasks(_taskStats.*)"},_show_all_tasks:{type:Bo
olean},_show_full_names:{type:Boolean},_sortstr:{type:String},_sort:{type:Object
,computed:"_makeSortObject(_sortstr)"},_taskStats:{type:Array},_tasksToShow:{typ
e:Array,computed:"_sortAndLimitTasks(_taskStats.*,_sort.*,_show_all_tasks)"},_to
talStats:{type:Object}},observers:["_aggregate(tasks.*)"],_aggregate:function(){
if(this.tasks&&this.tasks.length){var t=new Date(1e3*sk.now()),a={},e={total:thi
s.tasks.length,success:0,failed:0,bot_died:0,avg_duration:0,total_time:0,wall_ti
me:(t-this.tasks[this.tasks.length-1].started_ts)/1e3};this.tasks.forEach(functi
on(t){var s=t.name.trim(),i=s.split("/");5===i.length&&(s=i[0]+"/"+i[3]),a[s]||(
a[s]={full_name:s,name:s,total:0,success:0,failed:0,bot_died:0,avg_duration:0,to
tal_time:0}),a[s].total++,t.failure?(e.failed++,a[s].failed++):t.internal_failur
e?(e.bot_died++,a[s].bot_died++):(e.success++,a[s].success++),e.total_time+=t.du
ration,a[s].total_time+=t.duration}),e.avg_duration=e.total_time/e.total,e.wall_
time_utilization=(100*e.total_time/e.wall_time).toFixed(1),this.set("_totalStats
",e);var s=Object.keys(a),i=[];s.forEach(function(t){a[t].avg_duration=a[t].tota
l_time/a[t].total,a[t].total_time_percent=(100*a[t].total_time/e.total_time).toF
ixed(1),i.push(a[t])});var o=new Substrings({minOccurrence:Math.max(2,s.length-1
),minLength:6});o.build(s);var n=o.weighByAverage()||[];n.length&&n[0].source.fo
rEach(function(t){var a=i[t].full_name;i[t].name=a.replace(n[0].name,"...")}),th
is.set("_taskStats",i)}},_compare:function(t,a){if(!this._sort)return 0;var e=1;
return"desc"===this._sort.direction&&(e=-1),e*swarming.naturalCompare(t[this._so
rt.name],a[this._sort.name])},_countTasks:function(){return this._taskStats.leng
th<=t},_makeSortObject:function(t){if(t){var a=t.split(":");return 2!=a.length?{
name:"full_name",direction:"asc"}:{name:a[0],direction:a[1]}}},_sortAndLimitTask
s:function(){swarming.stableSort(this._taskStats,this._compare.bind(this));var a
=this._taskStats.length;return!this._show_all_tasks&&this._taskStats.length>t&&(
a=t),this._taskStats.slice(0,a)},_sortChange:function(t){t&&t.detail&&t.detail.n
ame&&(t.preventDefault(),t.stopPropagation(),this.set("_sortstr",t.detail.name+"
:"+t.detail.direction))}})}()</script> </dom-module><dom-module id="bot-page" as
setpath="/res/imp/botpage/"> <template> <style include="iron-flex iron-flex-alig
nment iron-positioning swarming-app-style single-page-style task-style">.message
{white-space:pre-line;font-family:monospace}.bot_state{white-space:pre;font-fami
ly:monospace;margin-bottom:10px}.events_table,.tasks_table{border:3px solid #1F7
8B4}.old_version{background-color:#ffd}.stats{min-width:700px;flex-grow:2}#colla
pse{max-width:700px}.cloud{white-space:nowrap;margin-bottom:5px;margin-top:auto}
paper-checkbox{--paper-checkbox-label-color:#fff;--paper-checkbox-checked-color:
#fff;--paper-checkbox-checkmark-color:#000;--paper-checkbox-unchecked-color:#fff
;padding:3px}paper-dialog{border-radius:6px}</style> <url-param name="id" value=
"{{bot_id}}"> </url-param> <url-param name="show_all_events" value="{{_show_all}
}"> </url-param> <url-param name="selected" value="{{_selected}}"> </url-param>
<url-param name="show_state" value="{{_show_state}}"> </url-param> <swarming-app
client_id="[[client_id]]" auth_headers="{{_auth_headers}}" permissions="{{_perm
issions}}" server_details="{{_server_details}}" signed_in="{{_signed_in}}" busy=
"[[_or(_busy1,_busy2,_busy3)]]" name="Swarming Bot Page"> <h2 hidden$="[[_signed
_in]]">You must sign in to see anything useful.</h2> <div hidden$="[[_not(_signe
d_in)]]"> <bot-page-data id="data" auth_headers="[[_auth_headers]]" bot_id="[[bo
t_id]]" bot="{{_bot}}" bot_exists="{{_bot_exists}}" busy="{{_busy1}}" events="{{
_events}}" tasks="{{_tasks}}" on-reload="_clearAndReload"> </bot-page-data> <div
class="header horizontal layout"> <paper-input class="id_input" label="Bot id"
value="{{bot_id}}"></paper-input> <template is="dom-if" if="[[_ccLink(_bot)]]">
<div class="vertical layout"> <a href$="[[_ccLink(_bot)]]" class="cloud">Cloud C
onsole</a> </div> </template> <button on-click="_refresh"> <iron-icon class="ref
resh" icon="icons:refresh"></iron-icon> </button> </div> </div> <h2 hidden$="[[_
bot_exists]]">Bot not found.</h2> <div hidden$="[[_not(_bot_exists)]]"> <div cla
ss="horizontal wrap layout"> <div class="flex"> <table> <tbody><tr class$="[[_is
Dead(_bot)]]" title="Last time the bot contacted the server."> <td>Last Seen</td
> <td title="[[_bot.human_last_seen_ts]]"> [[_timeDiffExact(_bot.last_seen_ts)]]
ago</td> <td> <template is="dom-if" if="[[_canShutdown(_bot,_permissions)]]"> <
button class="raised" on-click="_promptShutdown"> Shut Down Gracefully </button>
</template> <template is="dom-if" if="[[_canDelete(_bot,_permissions)]]"> <butt
on class="raised" on-click="_promptDelete"> Delete </button> </template> </td> <
/tr> <template is="dom-if" if="[[_bot.quarantined]]"> <tr class="quarantined"> <
td>Quarantined</td> <td colspan="2" class="message">[[_quarantineMessage(_bot)]]
</td> </tr> </template> <tr> <td>Current Task</td> <td> <a target="_blank" rel="
noopener" href$="[[_taskLink(_bot.task_id)]]"> [[_task(_bot)]] </a> </td> <td> <
/td> </tr> <tr> <td rowspan$="[[_numRows(_bot.dimensions)]]">Dimensions</td> </t
r> <template is="dom-repeat" items="[[_bot.dimensions]]" as="dim"> <tr> <td>[[di
m.key]]</td> <td>[[_concat(dim.value)]]</td> </tr> </template> <tr title="IP add
ress that the server saw the connection from."> <td>External IP</td> <td><a href
$="[[_bot.external_ip]]">[[_bot.external_ip]]</a></td> <td></td> </tr> <tr class
$="[[_classVersion(_server_details.bot_version,_bot.version)]]" title="Version i
s based on the content of swarming_bot.zip which is the swarming bot code. The b
ot won't update if quarantined, dead, or busy."> <td>Bot Version</td> <td>[[_sho
rten(_bot.version,'8')]]</td> <td></td> </tr> <tr title="The version the server
expects the bot to be using."> <td>Expected Bot Version</td> <td>[[_shorten(_ser
ver_details.bot_version,'8')]]</td> <td></td> </tr> <tr title="First time ever a
bot with this id contacted the server."> <td>First seen</td> <td title="[[_bot.
human_first_seen_ts]]"> [[_timeDiffApprox(_bot.first_seen_ts)]] ago </td> <td></
td> </tr> <tr title="How the bot is authenticated by the server."> <td>Authentic
ated as</td> <td colspan="2">[[_bot.authenticated_as]]</td> </tr> <template is="
dom-if" if="[[_bot.lease_id]]"> <tr> <td>Machine Provider Lease ID</td> <td cols
pan="2"> <a href$="[[_mpLink(_bot,_server_details.machine_provider_template)]]">
[[_bot.lease_id]] </a> </td> </tr> <tr> <td>Machine Provider Lease Expires</td>
<td colspan="2">[[_bot.human_lease_expiration_ts]]</td> </tr> </template> </tbo
dy></table> <span class="title">State</span> <template is="dom-if" if="[[_not(_s
how_state)]]"> <button on-click="_toggleState"> <iron-icon icon="icons:add-circl
e-outline"></iron-icon> </button> </template> <template is="dom-if" if="[[_show_
state]]"> <button on-click="_toggleState"> <iron-icon icon="icons:remove-circle-
outline"></iron-icon> </button> </template> <iron-collapse id="collapse" opened=
"[[_show_state]]"> <div class="bot_state">[[_prettyPrint(_bot.state)]]</div> </i
ron-collapse> </div> <div class="stats flex"> <bot-page-summary tasks="[[_tasks]
]"> </bot-page-summary> </div> </div> <div class="tabs"> <paper-tabs selected="{
{_selected}}" no-bar=""> <paper-tab>Tasks</paper-tab> <paper-tab>Events</paper-t
ab> </paper-tabs> <template is="dom-if" if="[[_showEvents]]"> <paper-checkbox ch
ecked="{{_show_all}}"> Show all events </paper-checkbox> </template> </div> <tem
plate is="dom-if" if="[[_not(_showEvents)]]"> <table class="tasks_table"> <thead
> <tr> <th>Task</th> <th>Started</th> <th>Duration</th> <th>Result</th> </tr> </
thead> <tbody> <template is="dom-repeat" items="{{_tasks}}" as="task"> <tr class
$="[[_taskClass(task)]]"> <td> <a target="_blank" rel="noopener" href$="[[_taskL
ink(task.task_id)]]"> [[task.name]] </a> </td> <td>[[task.human_started_ts]]</td
> <td title="[[task.human_completed_ts]]">[[task.human_duration]]</td> <td>[[tas
k.state]]</td> </tr> </template> </tbody> </table> </template> <template is="dom
-if" if="[[_showEvents]]"> <table class="events_table"> <thead> <tr> <th>Message
</th> <th>Type</th> <th>Timestamp</th> <th>Task ID</th> <th>Version</th> </tr> <
/thead> <tbody> <template is="dom-repeat" items="{{_eventList(_show_all,_events.
*)}}" as="event"> <tr> <td class="message">[[event.message]]</td> <td>[[event.ev
ent_type]]</td> <td>[[event.human_ts]]</td> <td> <a target="_blank" rel="noopene
r" href$="[[_taskLink(event.task_id)]]"> [[event.task_id]] </a> </td> <td class$
="[[_classVersion(_server_details.bot_version,event.version)]]"> [[_shorten(even
t.version,'8')]] </td> </tr> </template> </tbody> </table> </template> <pageable
-data id="page_tasks" hidden$="[[_showEvents]]" busy="{{_busy2}}" label="Show mo
re tasks" output="{{_tasks}}" parse="[[_parseTasks]]"> </pageable-data> <pageabl
e-data id="page_events" hidden$="[[_not(_showEvents)]]" busy="{{_busy3}}" label=
"Show more events" output="{{_events}}" parse="[[_parseEvents]]"> </pageable-dat
a> </div> </swarming-app> <paper-dialog id="prompt" modal="" on-iron-overlay-clo
sed="_promptClosed"> <h2>Are you sure?</h2> <div>Are you sure you want to [[_dia
logPrompt]]?</div> <div class="buttons"> <paper-button dialog-dismiss="" autofoc
us="">No</paper-button> <paper-button dialog-confirm="">Yes</paper-button> </div
> </paper-dialog> <error-toast></error-toast> </template> <script> (function(){ |
| 717 | 717 |
| 718 Polymer({ | 718 Polymer({ |
| 719 is: 'bot-page', | 719 is: 'bot-page', |
| 720 | 720 |
| 721 behaviors: [ | 721 behaviors: [ |
| 722 SwarmingBehaviors.BotPageBehavior, | 722 SwarmingBehaviors.BotPageBehavior, |
| 723 ], | 723 ], |
| 724 | 724 |
| 725 properties: { | 725 properties: { |
| 726 bot_id: { | 726 bot_id: { |
| (...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 934 return "failed_task"; | 934 return "failed_task"; |
| 935 } | 935 } |
| 936 return ""; | 936 return ""; |
| 937 }, | 937 }, |
| 938 | 938 |
| 939 _toggleState: function() { | 939 _toggleState: function() { |
| 940 this.set("_show_state", !this._show_state); | 940 this.set("_show_state", !this._show_state); |
| 941 } | 941 } |
| 942 | 942 |
| 943 }); | 943 }); |
| 944 })(); </script> </dom-module><dom-module id="interval-timer" assetpath="/res/i
mp/common/"> <script>!function(){Polymer({is:"interval-timer",properties:{period
:{type:Number,value:-1,observer:"_periodChanged"}},_periodChanged:function(e){th
is._timeout&&window.clearTimeout(this._timeout),e>0&&(this._timeout=window.setTi
meout(function(){this.fire("trigger"),this._periodChanged(e)}.bind(this),1e3*e))
}})}()</script> </dom-module> <dom-module id="task-page-data" assetpath="/res/im
p/taskpage/"> <script>!function(){var t,e=400,s=["abandoned_ts","completed_ts","
created_ts","modified_ts","started_ts"];Polymer({is:"task-page-data",behaviors:[
SwarmingBehaviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],properties:{aut
h_headers:{type:Object},task_id:{type:String},busy:{type:Boolean,computed:"_or(_
busy1,_busy2,_busy3)",notify:!0},request:{type:Object,computed:"_parseRequest(_r
equest)",notify:!0},result:{type:Object,computed:"_parseResult(_result)",notify:
!0},stdout:{type:String,computed:"_parseStdout(_stdout)",notify:!0},task_exists:
{type:Boolean,value:!0,notify:!0},_busy1:{type:Boolean,value:!1},_busy2:{type:Bo
olean,value:!1},_busy3:{type:Boolean,value:!1},_request:{type:Object},_result:{t
ype:Object},_stdout:{type:Object}},observers:["reload(auth_headers,task_id)"],re
load:function(){if(!this.task_id||!this.auth_headers)return void console.log("ta
sk_id and auth_headers can't be empty");t&&this.cancelAsync(t);var s="/api/swarm
ing/v1/task/"+this.task_id;t=this.async(function(){t=void 0;var e=this._getJsonA
sync("_request",s+"/request","_busy1",this.auth_headers);e.then(function(){this.
set("task_exists",!0)}.bind(this)).catch(function(t){404===t.status?this.set("ta
sk_exists",!1):sk.errorMessage("Http response: "+(t.status||" ")+" "+t.response)
}.bind(this)),this._getJsonAsync("_result",s+"/result?include_performance_stats=
true","_busy2",this.auth_headers),this.reloadStdout()},e)},_parseRequest:functio
n(t){return t?(t.tagMap={},t.tags=t.tags||[],t.tags.forEach(function(e){var s=e.
split(":",1),a=s[0],u=e.substring(a.length+1);t.tagMap[a]=u}),s.forEach(function
(e){t[e]&&(t[e]=new Date(t[e]),t["human_"+e]=sk.human.localeTime(t[e]))}),t):{}}
,_parseResult:function(t){if(!t)return{};var e=new Date;return s.forEach(functio
n(e){t[e]&&(t[e]=new Date(t[e]),t["human_"+e]=sk.human.localeTime(t[e]))}),!t.du
ration&&t.state===this.RUNNING&&t.started_ts&&(t.duration=(e-t.started_ts)/1e3),
t.duration&&(t.human_duration=this._humanDuration(t.duration)),t},_parseStdout:f
unction(t){return t&&t.output?t.output:"[No output yet]"},reloadStdout:function(
){this._getJsonAsync("_stdout","/api/swarming/v1/task/"+this.task_id+"/stdout","
_busy3",this.auth_headers)}})}()</script> </dom-module><dom-module id="task-disa
mbiguation" assetpath="/res/imp/taskpage/"> <template> <style include="swarming-
app-style single-page-style task-style"></style> <table> <thead> <tr> <th>Try ID
</th> <th>Bot ID</th> <th>Status</th> </tr> </thead> <tbody> <template id="resul
t_list" is="dom-repeat" items="[[_results]]" as="result" observe="task_id bot_id
state"> <tr> <td> <a href$="[[_taskLink(result.task_id,'true')]]"> [[result.tas
k_id]] </a> </td> <td> <a href$="[[_botLink(result.bot_id)]]"> [[result.bot_id]]
</a> </td> <td class$="[[_stateClass(result)]]">[[state(result)]]</td> </tr> </
template> </tbody> </table> </template> <script>Polymer({is:"task-disambiguation
",behaviors:[SwarmingBehaviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],pr
operties:{auth_headers:{type:Object},summary_result:{type:Object},task_id:{type:
String},busy:{type:Boolean,value:!1,notify:!0},_busyArr:{type:Array,value:functi
on(){return[]}},_results:{type:Array,value:function(){return[]}}},observers:["_f
etchRest(auth_headers,task_id,summary_result)","_computeBusy(_busyArr.*)"],_comp
uteBusy:function(){for(var s=0;s<this._busyArr.length;s++)if(this._busyArr[s].st
atus)return!0;return!1},_fetchRest:function(s,r,t){if(s&&r&&t){var e=t.try_numbe
r;this.set("_busyArr",[]),this.set("_results",[]);for(var u=r.substring(0,r.leng
th-1),i="/api/swarming/v1/task/",a=0;a<e-1;a++){var n=u+(a+1);this.splice("_busy
Arr",a,0,{}),this.splice("_results",a,0,{task_id:n}),this._getJsonAsyncArr(a,"_r
esults",i+n+"/result","_busyArr",s)}t.task_id=u+e,this.splice("_results",e-1,1,t
)}}})</script> </dom-module><dom-module id="task-page" assetpath="/res/imp/taskp
age/"> <template> <style include="iron-flex iron-flex-alignment swarming-app-sty
le single-page-style task-style">.milo{width:calc(100% - 11px);height:2000px}.le
ft{min-width:550px}.right{min-width:500px;margin-top:8px}.expand{min-width:3em;v
ertical-align:middle;padding:.5em}.code{font-family:monospace}.stdout{white-spac
e:pre-line;padding:2px}.refresh_input{padding:0 5px}.reproduce{margin-left:5px}.
tabbed{border:3px solid #1F78B4;margin-left:5px;min-height:80vh}</style> <url-pa
ram name="id" value="{{task_id}}"> </url-param> <url-param name="try_detail" val
ue="{{_try_detail}}"> </url-param> <url-param name="request_detail" value="{{_re
quest_detail}}"> </url-param> <url-param name="show_raw" value="{{_show_raw}}">
</url-param> <url-param name="refresh" value="{{_refresh_interval}}" default_val
ue="10"> </url-param> <swarming-app client_id="[[client_id]]" auth_headers="{{_a
uth_headers}}" permissions="{{_permissions}}" profile="{{_profile}}" server_deta
ils="{{_server_details}}" signed_in="{{_signed_in}}" busy="[[_or(_busy1,busy2)]]
" name="Swarming Task Page"> <h2 hidden$="[[_signed_in]]">You must sign in to se
e anything useful.</h2> <div hidden$="[[_not(_signed_in)]]"> <task-page-data id=
"data" auth_headers="[[_auth_headers]]" task_id="[[task_id]]" busy="{{_busy1}}"
request="{{_request}}" result="{{_result}}" stdout="{{_stdout}}" task_exists="{{
_task_exists}}"> </task-page-data> <div class="horizontal layout wrap"> <div cla
ss="left flex"> <div class="horizontal layout"> <paper-input class="id_input" la
bel="Task id" value="{{task_id}}"></paper-input> <button on-click="_refresh"> <i
ron-icon class="refresh" icon="icons:refresh"></iron-icon> </button> <button on-
click="_promptRetry">Retry</button> <template is="dom-if" if="[[_canCancelTask(_
result,_permissions)]]"> <button on-click="_promptCancel">Cancel</button> </temp
late> </div> <h2 hidden$="[[_task_exists]]">Task not found.</h2> <template is="d
om-if" if="[[_disambiguate(task_id,_result)]]"> <h2>Displaying a summary for a t
ask with multiple tries</h2> <task-disambiguation busy="{{busy2}}" auth_headers=
"[[_auth_headers]]" task_id="[[task_id]]" summary_result="[[_result]]"> </task-d
isambiguation> </template> <table hidden$="[[_not(_task_exists)]]"> <tbody><tr>
<td>Name</td> <td>[[_request.name]]</td> </tr> <tr> <td>State</td> <td class$="[
[_stateClass(_result)]]">[[state(_result)]]</td> </tr> <tr> <td>Created</td> <td
title$="[[_request.created_ts]]">[[_request.human_created_ts]]</td> </tr> <temp
late is="dom-if" if="[[_wasPickedUp(_result)]]"> <tr> <td>Started</td> <td title
$="[[_result.started_ts]]">[[_result.human_started_ts]]</td> </tr> </template> <
template is="dom-if" if="[[_wasNotPickedUp(_result)]]"> <tr> <td>Expires</td> <t
d>[[_expires(_request)]]</td> </tr> </template> <template is="dom-if" if="[[_res
ult.human_completed_ts]]"> <tr> <td>Completed</td> <td title$="[[_result.complet
ed_ts]]">[[_result.human_completed_ts]]</td> </tr> </template> <template is="dom
-if" if="[[_result.human_abandoned_ts]]"> <tr> <td>Abandoned</td> <td title$="[[
_result.abandoned_ts]]">[[_result.human_abandoned_ts]]</td> </tr> </template> <t
r> <td>Last Updated</td> <td title$="[[_result.modified_ts]]">[[_result.human_mo
dified_ts]]</td> </tr> <template is="dom-if" if="[[_result.deduped_from]]"> <tr>
<td><b>Deduped from</b></td> <td> <a href$="[[_taskLink(_result.deduped_from)]]
"> [[_result.deduped_from]] </a> </td> </tr> </template> <tr> <td>Pending Time</
td> <td>[[_pending(_result)]]</td> </tr> <tr> <td>Duration</td> <td>[[_result.hu
man_duration]]</td> </tr> <tr> <td>Priority</td> <td>[[_request.priority]]</td>
</tr> <tr> <td>User</td> <td>[[_request.user]]</td> </tr> <tr> <td>Authenticated
</td> <td>[[_request.authenticated]]</td> </tr> <template is="dom-if" if="[[_req
uest.service_account]]"> <tr> <td>Service Account</td> <td>[[_request.service_ac
count]]</td> </tr> </template> <template is="dom-if" if="[[_request.properties.s
ecret_bytes]]"> <tr> <td>Secret Bytes</td> <td>[[_request.properties.secret_byte
s]]</td> </tr> </template> <template is="dom-if" if="[[_request.parent_task_id]]
"> <tr> <td>Parent Task</td> <td> <a href$="[[_taskLink(_request.parent_task_id)
]]">[[_request.parent_task_id]]</a> </td> </tr> </template> <tr> <td rowspan$="[
[_rowspan(_request.properties.dimensions)]]"> <a title="The list of bots that ma
tches the list of dimensions" href$="[[_botListLink(_request.properties.dimensio
ns)]]"> Requested Dimensions </a> </td> </tr> <template is="dom-repeat" items="{
{_request.properties.dimensions}}" as="dimension"> <tr> <td><b>[[dimension.key]]
:</b> [[_alias(dimension)]]</td> </tr> </template> <tr> <td>Isolated Inputs</td>
<td> <a href$="[[_isolateLink(_request.properties.inputs_ref)]]"> [[_request.pr
operties.inputs_ref.isolated]] </a> </td> </tr> <template is="dom-if" if="[[_req
uest.properties.outputs.length]]"> <tr> <td rowspan$="[[_rowspan(_request.proper
ties.outputs)]]">Expected outputs</td> </tr> <template is="dom-repeat" items="{{
_request.properties.outputs}}" as="output"> <tr> <td>[[output]]</td> </tr> </tem
plate> </template> <template is="dom-if" if="[[_not(_request_detail)]]"> <tr> <t
d>More Details</td> <td> <button on-click="_toggleDetails"> <iron-icon icon="ico
ns:add-circle-outline"></iron-icon> </button> </td> </tr> </template> <template
is="dom-if" if="[[_request_detail]]"> <tr> <td>Hide Details</td> <td> <button on
-click="_toggleDetails"> <iron-icon icon="icons:remove-circle-outline"></iron-ic
on> </button> </td> </tr> </template> <template is="dom-if" if="[[_request_detai
l]]"> <tr> <td>Extra Args</td> <td class="code">[[_extraArgs(_request)]]</td> </
tr> <tr> <td rowspan$="[[_rowspan(_request.tags)]]">Tags</td> </tr> <template is
="dom-repeat" items="{{_request.tags}}" as="tag"> <tr> <td>[[tag]]</td> </tr> </
template> <tr> <td>Execution timeout</td> <td>[[_humanDuration(_request.properti
es.execution_timeout_secs)]]</td> </tr> <tr> <td>I/O timeout</td> <td>[[_humanDu
ration(_request.properties.io_timeout_secs)]]</td> </tr> <tr> <td>Grace period</
td> <td>[[_humanDuration(_request.properties.grace_period_secs)]]</td> </tr> <tr
> <td>CIPD server</td> <td> <a href$="[[_request.properties.cipd_input.server]]"
> [[_request.properties.cipd_input.server]] </a> </td> </tr> <tr> <td>CIPD versi
on</td> <td>[[_request.properties.cipd_input.client_package.version]]</td> </tr>
<template is="dom-if" if="[[_wasPickedUp(_result)]]"> <tr> <td>CIPD package nam
e</td> <td>[[_result.cipd_pins.client_package.package_name]]</td> </tr> </templa
te> <tr hidden$="[[_not(_request.properties.cipd_input)]]"> <td rowspan$="[[_cip
dRowspan(_request,_result)]]">CIPD packages</td> </tr> <template is="dom-repeat"
items="[[_cipdPackages(_request,_result)]]" as="cipd"> <tr> <td>[[cipd.path]]/<
/td> </tr> <tr> <td><b>Requested:</b>[[cipd.requested]]</td> </tr> <tr hidden$="
[[_wasNotPickedUp(_result)]]"> <td><b>Actual:</b>[[cipd.actual]]</td> </tr> </te
mplate> <tr hidden$="[[_empty(_request.properties.caches)]]"> <td rowspan$="[[_r
owspan(_request.properties.caches)]]">Named caches</td> </tr> <template is="dom-
repeat" items="[[_request.properties.caches]]" as="cache"> <tr> <td><span>[[cach
e.name]]</span>:<span>[[cache.path]]</span></td> </tr> </template> </template> <
/tbody></table> <div class="title" hidden$="[[_not(_task_exists)]]">Task Executi
on</div> <template is="dom-if" if="[[_wasPickedUp(_result)]]"> <table hidden$="[
[_not(_task_exists)]]"> <tbody><tr> <td>Bot assigned to task</td> <td><a href$="
[[_botLink(_result.bot_id)]]">[[_result.bot_id]]</a></td> </tr> <tr> <td rowspan
$="[[_rowspan(_result.bot_dimensions)]]"> <a>Bot Dimensions</a> </td> </tr> <tem
plate is="dom-repeat" items="[[_result.bot_dimensions]]" as="dimension"> <tr> <t
d><b>[[dimension.key]]:</b> [[_alias(dimension)]]</td> </tr> </template> <tr> <t
d>Exit code</td> <td>[[_result.exit_code]]</td> </tr> <tr> <td>Try number</td> <
td>[[_result.try_number]]</td> </tr> <tr> <td>Failure</td> <td class$="[[_failur
eClass(_result.failure)]]">[[_result.failure]]</td> </tr> <tr> <td>Internal Fail
ure</td> <td class$="[[_internalClass(_result.internal_failure)]]">[[_result.int
ernal_failure]]</td> </tr> <tr> <td>Isolated Outputs</td> <td> <a href$="[[_isol
ateLink(_result.outputs_ref)]]"> [[_result.outputs_ref.isolated]] </a> </td> </t
r> <tr> <td>Bot version</td> <td>[[_result.bot_version]]</td> </tr> <tr> <td>Ser
ver version</td> <td>[[_result.server_versions]]</td> </tr> </tbody></table> </t
emplate> <template is="dom-if" if="[[_wasNotPickedUp(_result)]]"> This space lef
t blank until a bot is assigned to the task. </template> <template is="dom-if" i
f="[[_result.performance_stats]]"> <div class="title">Performance Stats</div> <t
able> <tbody><tr> <td title="This includes time taken to download inputs, isolat
e outputs, and setup CIPD">Total Overhead</td> <td>[[_humanDuration(_result.perf
ormance_stats.bot_overhead)]]</td> </tr> <tr> <td>Downloading Inputs From Isolat
e</td> <td>[[_humanDuration(_result.performance_stats.isolated_download.duration
)]]</td> </tr> <tr> <td>Uploading Outputs To Isolate</td> <td>[[_humanDuration(_
result.performance_stats.isolated_upload.duration)]]</td> </tr> <tr> <td>Initial
bot cache</td> <td>[[_result.performance_stats.isolated_download.initial_number
_items]] items; [[_bytes(_result.performance_stats.isolated_download.initial_siz
e)]]</td> </tr> </tbody></table> </template> <div class="title">Reproducing the
task locally</div> <div class="reproduce"> <div>Download inputs files into direc
tory <i>foo</i>:</div> <div class="code"> python isolateserver.py download -I [[
_request.properties.inputs_ref.isolatedserver]] --namespace [[_request.propertie
s.inputs_ref.namespace]] -s [[_request.properties.inputs_ref.isolated]] --target
foo</div> <br> <div>Run this task locally:</div> <div class="code"> python swar
ming.py reproduce -S [[_host_url]] [[task_id]]</div> <br> <div>Download output r
esults into directory <i>foo</i>:</div> <div class="code"> python swarming.py co
llect -S [[_host_url]] --task-output-dir=foo [[task_id]]</div> <br> <div>Looking
for <i>swarming.py</i>?</div> <div class="code"> git clone https://github.com/l
uci/client-py</div> </div> </div> <div class="flex right" hidden$="[[_not(_task_
exists)]]"> <div class="horizontal layout"> <div class="tabs"> <paper-tabs selec
ted="{{_show_raw}}" no-bar=""> <paper-tab disabled$="[[_noMilo(_request)]]">Milo
Output</paper-tab> <paper-tab>Raw Output</paper-tab> </paper-tabs> </div> <pape
r-input class="refresh_input" label="Refresh Interval (seconds)" value="{{_refre
sh_interval}}" title="How often to refresh all information about the task" auto-
validate="" min="1" max="1000" pattern="[0-9]+"> </paper-input> </div> <template
is="dom-if" if="[[_supportsMilo(_request,_show_raw)]]"> <div class="milo tabbed
" hidden$="[[_isSummaryLink(task_id)]]"> Milo results are only generated for tas
k summaires, that is, tasks whose ids end in 0. Tasks ending in 1 or 2 represent
possible retries of tasks. See <a href="//goo.gl/LE4rwV">the docs</a> for more.
</div> <iframe id="miloFrame" class="milo tabbed" src$="[[_getDisplayServerLink
(_server_details.display_server_url_template,task_id)]]"></iframe> </template> <
template is="dom-if" if="[[_show_raw]]"> <div class="code stdout tabbed">[[_stdo
ut]]</div> </template> </div> </div> </div> </swarming-app> <paper-dialog id="pr
ompt" modal="" on-iron-overlay-closed="_promptClosed"> <h2>Are you sure?</h2> <d
iv>Are you sure you want to [[_dialog_prompt]]?</div> <div class="buttons"> <pap
er-button dialog-dismiss="" autofocus="">No</paper-button> <paper-button dialog-
confirm="">Yes</paper-button> </div> </paper-dialog> <error-toast></error-toast>
<interval-timer period="[[_refresh_interval]]" on-trigger="_softRefresh"> </int
erval-timer> </template> <script>!function(){Polymer({is:"task-page",behaviors:[
SwarmingBehaviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],properties:{tas
k_id:{type:String},client_id:{type:String},_dialog_prompt:{type:String,value:""}
,_host_url:{type:String,value:function(){return window.location.hostname}},_refr
esh_interval:{type:Number},_request:{type:Object,observer:"_requestUpdated"},_re
quest_detail:{type:Boolean},_result:{type:Object},_server_details:{type:Object},
_stdout:{type:String}},_alias:function(t){var e=t.value;return Array.isArray(e)|
|(e=[e]),swarming.alias.has(t.key)&&e.forEach(function(i,s){e[s]=swarming.alias.
apply(i,t.key)}),e.join(" | ")},_bytes:function(t){return sk.human.bytes(t)},_ca
nCancelTask:function(t,e){return t&&"PENDING"===t.state&&e.cancel_task},_cancelT
ask:function(){var t="/api/swarming/v1/task/"+this.task_id+"/cancel";swarming.po
stWithToast(t,"Canceling task "+this.task_id,this._auth_headers)},_cipdRowspan:f
unction(t,e){if(!t||!t.properties||!t.properties.cipd_input)return 0;var i=(t.pr
operties.cipd_input.packages||[]).length;return i*=e&&e.cipd_pins&&e.cipd_pins.p
ackages?3:2,i+1},_cipdPackages:function(t,e){if(!t||!t.properties||!t.properties
.cipd_input)return[];var i=t.properties.cipd_input.packages||[],s=e&&e.cipd_pins
&&e.cipd_pins.packages||[];return i.forEach(function(t){t.requested=t.package_na
me+":"+t.version,s.forEach(function(e){e.path===t.path&&(t.actual=e.package_name
+":"+e.version)})}),i},_disambiguate:function(t,e){return!(!t.endsWith("0")||!e)
&&e.try_number>1},_expires:function(t){var e=parseInt(t.expiration_secs);return
e?sk.human.localeTime(new Date(t.created_ts.getTime()+1e3*e)):t.expiration_secs+
" seconds from created time"},_extraArgs:function(t){if(!t||!t.properties)return
"";var e=t.properties.extra_args||[];return e.join(" ")},_failureClass:function(
t){return t?"failed_task":""},_getDisplayServerLink:function(t,e){if(t)return t.
replace("%s",e)},_internalClass:function(t){return t?"exception":""},_isolateLin
k:function(t){if(t&&t.isolatedserver)return t.isolatedserver+"/browse?namespace=
"+t.namespace+"&hash="+t.isolated},_isSummaryLink:function(t){return t&&t.endsWi
th(0)},_noMilo:function(t){return!this._tag(t,"allow_milo")},_pending:function(t
){if(!t.created_ts)return"";var e=t.started_ts||t.abandoned_ts||new Date;return
e<=t.created_ts?"0s":this._timeDiffExact(t.created_ts,e)},_promptClosed:function
(t){t.detail.confirmed&&(this._dialog_prompt.startsWith("cancel")?this._cancelTa
sk():this._retryTask())},_promptCancel:function(){this.set("_dialog_prompt","can
cel task "+this.task_id),this.$.prompt.open()},_promptRetry:function(){this.set(
"_dialog_prompt","retry task "+this.task_id),this.$.prompt.open()},_refresh:func
tion(){this.$.data.reload()},_requestUpdated:function(t){this._noMilo(t)&&this.s
et("_show_raw",1)},_softRefresh:function(){if(!this._result||"RUNNING"===this._r
esult.state||"PENDING"===this._result.state){this.$.data.reload();var t=this.$$(
"iframe");t&&(t.src=this._getDisplayServerLink(this._server_details.display_serv
er_url_template,this.task_id))}},_retryTask:function(){if(!this._request)return
void sk.errorMessage("Task not yet loaded",3e3);var t={expiration_secs:this._req
uest.expiration_secs,name:this._request.name+" (retry)",parent_task_id:this._req
uest.parent_task_id,priority:this._request.priority,properties:this._request.pro
perties,tags:this._request.tags,user:this._profile.email,service_account:this._r
equest.service_account};swarming.postWithToast("/api/swarming/v1/tasks/new","Ret
rying task "+this.task_id,this._auth_headers,t).then(function(t){t=JSON.parse(t)
,t&&t.task_id&&this.set("task_id",t.task_id)}.bind(this),function(t){console.log
("Task could not be retried",t)})},_rowspan:function(t){return t=t||[],t.length+
1},_empty:function(t){return!t||0==t.length},_supportsMilo:function(t,e){return!
e&&t&&this._tag(t,"allow_milo")},_toggleDetails:function(){this.set("_request_de
tail",!this._request_detail)},_tag:function(t,e){if(t&&t.tagMap)return t.tagMap[
e]},_wasPickedUp:function(t){return t&&t.state!==this.PENDING&&t.state!==this.CA
NCELED&&t.state!=this.EXPIRED},_wasNotPickedUp:function(t){return t&&!this._wasP
ickedUp(t)}})}()</script> </dom-module> </div></body></html> | 944 })(); </script> </dom-module><dom-module id="interval-timer" assetpath="/res/i
mp/common/"> <script>!function(){Polymer({is:"interval-timer",properties:{period
:{type:Number,value:-1,observer:"_periodChanged"}},_periodChanged:function(e){th
is._timeout&&window.clearTimeout(this._timeout),e>0&&(this._timeout=window.setTi
meout(function(){this.fire("trigger"),this._periodChanged(e)}.bind(this),1e3*e))
}})}()</script> </dom-module> <dom-module id="task-page-data" assetpath="/res/im
p/taskpage/"> <script>!function(){var t,e=400,s=["abandoned_ts","completed_ts","
created_ts","modified_ts","started_ts"];Polymer({is:"task-page-data",behaviors:[
SwarmingBehaviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],properties:{aut
h_headers:{type:Object},task_id:{type:String},busy:{type:Boolean,computed:"_or(_
busy1,_busy2,_busy3)",notify:!0},request:{type:Object,computed:"_parseRequest(_r
equest)",notify:!0},result:{type:Object,computed:"_parseResult(_result)",notify:
!0},stdout:{type:String,computed:"_parseStdout(_stdout)",notify:!0},task_exists:
{type:Boolean,value:!0,notify:!0},_busy1:{type:Boolean,value:!1},_busy2:{type:Bo
olean,value:!1},_busy3:{type:Boolean,value:!1},_request:{type:Object},_result:{t
ype:Object},_stdout:{type:Object}},observers:["reload(auth_headers,task_id)"],re
load:function(){if(!this.task_id||!this.auth_headers)return void console.log("ta
sk_id and auth_headers can't be empty");t&&this.cancelAsync(t);var s="/api/swarm
ing/v1/task/"+this.task_id;t=this.async(function(){t=void 0;var e=this._getJsonA
sync("_request",s+"/request","_busy1",this.auth_headers);e.then(function(){this.
set("task_exists",!0)}.bind(this)).catch(function(t){404===t.status?this.set("ta
sk_exists",!1):sk.errorMessage("Http response: "+(t.status||" ")+" "+t.response)
}.bind(this)),this._getJsonAsync("_result",s+"/result?include_performance_stats=
true","_busy2",this.auth_headers),this.reloadStdout()},e)},_parseRequest:functio
n(t){return t?(t.tagMap={},t.tags=t.tags||[],t.tags.forEach(function(e){var s=e.
split(":",1),a=s[0],u=e.substring(a.length+1);t.tagMap[a]=u}),s.forEach(function
(e){t[e]&&(t[e]=new Date(t[e]),t["human_"+e]=sk.human.localeTime(t[e]))}),t):{}}
,_parseResult:function(t){if(!t)return{};var e=new Date;return s.forEach(functio
n(e){t[e]&&(t[e]=new Date(t[e]),t["human_"+e]=sk.human.localeTime(t[e]))}),!t.du
ration&&t.state===this.RUNNING&&t.started_ts&&(t.duration=(e-t.started_ts)/1e3),
t.duration&&(t.human_duration=this._humanDuration(t.duration)),t},_parseStdout:f
unction(t){return t&&t.output?t.output:""},reloadStdout:function(){this._getJson
Async("_stdout","/api/swarming/v1/task/"+this.task_id+"/stdout","_busy3",this.au
th_headers)}})}()</script> </dom-module><dom-module id="task-disambiguation" ass
etpath="/res/imp/taskpage/"> <template> <style include="swarming-app-style singl
e-page-style task-style"></style> <table> <thead> <tr> <th>Try ID</th> <th>Bot I
D</th> <th>Status</th> </tr> </thead> <tbody> <template id="result_list" is="dom
-repeat" items="[[_results]]" as="result" observe="task_id bot_id state"> <tr> <
td> <a href$="[[_taskLink(result.task_id,'true')]]"> [[result.task_id]] </a> </t
d> <td> <a href$="[[_botLink(result.bot_id)]]"> [[result.bot_id]] </a> </td> <td
class$="[[_stateClass(result)]]">[[state(result)]]</td> </tr> </template> </tbo
dy> </table> </template> <script>Polymer({is:"task-disambiguation",behaviors:[Sw
armingBehaviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],properties:{auth_
headers:{type:Object},summary_result:{type:Object},task_id:{type:String},busy:{t
ype:Boolean,value:!1,notify:!0},_busyArr:{type:Array,value:function(){return[]}}
,_results:{type:Array,value:function(){return[]}}},observers:["_fetchRest(auth_h
eaders,task_id,summary_result)","_computeBusy(_busyArr.*)"],_computeBusy:functio
n(){for(var s=0;s<this._busyArr.length;s++)if(this._busyArr[s].status)return!0;r
eturn!1},_fetchRest:function(s,r,t){if(s&&r&&t){var e=t.try_number;this.set("_bu
syArr",[]),this.set("_results",[]);for(var u=r.substring(0,r.length-1),i="/api/s
warming/v1/task/",a=0;a<e-1;a++){var n=u+(a+1);this.splice("_busyArr",a,0,{}),th
is.splice("_results",a,0,{task_id:n}),this._getJsonAsyncArr(a,"_results",i+n+"/r
esult","_busyArr",s)}t.task_id=u+e,this.splice("_results",e-1,1,t)}}})</script>
</dom-module><dom-module id="task-page" assetpath="/res/imp/taskpage/"> <templat
e> <style include="iron-flex iron-flex-alignment swarming-app-style single-page-
style task-style">.milo{width:calc(100% - 11px);height:2000px}.left{min-width:55
0px}.right{min-width:500px;margin-top:8px}.expand{min-width:3em;vertical-align:m
iddle;padding:.5em}.code{font-family:monospace}.stdout{white-space:pre-line;padd
ing:2px}.refresh_input{padding:0 5px}.reproduce{margin-left:5px}.tabbed{border:3
px solid #1F78B4;margin-left:5px;min-height:80vh}</style> <url-param name="id" v
alue="{{task_id}}"> </url-param> <url-param name="try_detail" value="{{_try_deta
il}}"> </url-param> <url-param name="request_detail" value="{{_request_detail}}"
> </url-param> <url-param name="show_raw" value="{{_show_raw}}"> </url-param> <u
rl-param name="refresh" value="{{_refresh_interval}}" default_value="10"> </url-
param> <swarming-app client_id="[[client_id]]" auth_headers="{{_auth_headers}}"
permissions="{{_permissions}}" profile="{{_profile}}" server_details="{{_server_
details}}" signed_in="{{_signed_in}}" busy="[[_or(_busy1,busy2)]]" name="Swarmin
g Task Page"> <h2 hidden$="[[_signed_in]]">You must sign in to see anything usef
ul.</h2> <div hidden$="[[_not(_signed_in)]]"> <task-page-data id="data" auth_hea
ders="[[_auth_headers]]" task_id="[[task_id]]" busy="{{_busy1}}" request="{{_req
uest}}" result="{{_result}}" stdout="{{_stdout}}" task_exists="{{_task_exists}}"
> </task-page-data> <div class="horizontal layout wrap"> <div class="left flex">
<div class="horizontal layout"> <paper-input class="id_input" label="Task id" v
alue="{{task_id}}"></paper-input> <button on-click="_refresh"> <iron-icon class=
"refresh" icon="icons:refresh"></iron-icon> </button> <button on-click="_promptR
etry">Retry</button> <template is="dom-if" if="[[_canCancelTask(_result,_permiss
ions)]]"> <button on-click="_promptCancel">Cancel</button> </template> </div> <h
2 hidden$="[[_task_exists]]">Task not found.</h2> <template is="dom-if" if="[[_d
isambiguate(task_id,_result)]]"> <h2>Displaying a summary for a task with multip
le tries</h2> <task-disambiguation busy="{{busy2}}" auth_headers="[[_auth_header
s]]" task_id="[[task_id]]" summary_result="[[_result]]"> </task-disambiguation>
</template> <table hidden$="[[_not(_task_exists)]]"> <tbody><tr> <td>Name</td> <
td>[[_request.name]]</td> </tr> <tr> <td>State</td> <td class$="[[_stateClass(_r
esult)]]">[[state(_result)]]</td> </tr> <tr> <td>Created</td> <td title$="[[_req
uest.created_ts]]">[[_request.human_created_ts]]</td> </tr> <template is="dom-if
" if="[[_wasPickedUp(_result)]]"> <tr> <td>Started</td> <td title$="[[_result.st
arted_ts]]">[[_result.human_started_ts]]</td> </tr> </template> <template is="do
m-if" if="[[_wasNotPickedUp(_result)]]"> <tr> <td>Expires</td> <td>[[_expires(_r
equest)]]</td> </tr> </template> <template is="dom-if" if="[[_result.human_compl
eted_ts]]"> <tr> <td>Completed</td> <td title$="[[_result.completed_ts]]">[[_res
ult.human_completed_ts]]</td> </tr> </template> <template is="dom-if" if="[[_res
ult.human_abandoned_ts]]"> <tr> <td>Abandoned</td> <td title$="[[_result.abandon
ed_ts]]">[[_result.human_abandoned_ts]]</td> </tr> </template> <tr> <td>Last Upd
ated</td> <td title$="[[_result.modified_ts]]">[[_result.human_modified_ts]]</td
> </tr> <template is="dom-if" if="[[_result.deduped_from]]"> <tr> <td><b>Deduped
from</b></td> <td> <a href$="[[_taskLink(_result.deduped_from)]]"> [[_result.de
duped_from]] </a> </td> </tr> </template> <tr> <td>Pending Time</td> <td>[[_pend
ing(_result)]]</td> </tr> <tr> <td>Duration</td> <td>[[_result.human_duration]]<
/td> </tr> <tr> <td>Priority</td> <td>[[_request.priority]]</td> </tr> <tr> <td>
User</td> <td>[[_request.user]]</td> </tr> <tr> <td>Authenticated</td> <td>[[_re
quest.authenticated]]</td> </tr> <template is="dom-if" if="[[_request.service_ac
count]]"> <tr> <td>Service Account</td> <td>[[_request.service_account]]</td> </
tr> </template> <template is="dom-if" if="[[_request.properties.secret_bytes]]">
<tr> <td>Secret Bytes</td> <td>[[_request.properties.secret_bytes]]</td> </tr>
</template> <template is="dom-if" if="[[_request.parent_task_id]]"> <tr> <td>Par
ent Task</td> <td> <a href$="[[_taskLink(_request.parent_task_id)]]">[[_request.
parent_task_id]]</a> </td> </tr> </template> <tr> <td rowspan$="[[_rowspan(_requ
est.properties.dimensions)]]"> <a title="The list of bots that matches the list
of dimensions" href$="[[_botListLink(_request.properties.dimensions)]]"> Request
ed Dimensions </a> </td> </tr> <template is="dom-repeat" items="{{_request.prope
rties.dimensions}}" as="dimension"> <tr> <td><b>[[dimension.key]]:</b> [[_alias(
dimension)]]</td> </tr> </template> <tr> <td>Isolated Inputs</td> <td> <a href$=
"[[_isolateLink(_request.properties.inputs_ref)]]"> [[_request.properties.inputs
_ref.isolated]] </a> </td> </tr> <template is="dom-if" if="[[_request.properties
.outputs.length]]"> <tr> <td rowspan$="[[_rowspan(_request.properties.outputs)]]
">Expected outputs</td> </tr> <template is="dom-repeat" items="{{_request.proper
ties.outputs}}" as="output"> <tr> <td>[[output]]</td> </tr> </template> </templa
te> <template is="dom-if" if="[[_not(_request_detail)]]"> <tr> <td>More Details<
/td> <td> <button on-click="_toggleDetails"> <iron-icon icon="icons:add-circle-o
utline"></iron-icon> </button> </td> </tr> </template> <template is="dom-if" if=
"[[_request_detail]]"> <tr> <td>Hide Details</td> <td> <button on-click="_toggle
Details"> <iron-icon icon="icons:remove-circle-outline"></iron-icon> </button> <
/td> </tr> </template> <template is="dom-if" if="[[_request_detail]]"> <tr> <td>
Extra Args</td> <td class="code">[[_extraArgs(_request)]]</td> </tr> <tr> <td ro
wspan$="[[_rowspan(_request.tags)]]">Tags</td> </tr> <template is="dom-repeat" i
tems="{{_request.tags}}" as="tag"> <tr> <td>[[tag]]</td> </tr> </template> <tr>
<td>Execution timeout</td> <td>[[_humanDuration(_request.properties.execution_ti
meout_secs)]]</td> </tr> <tr> <td>I/O timeout</td> <td>[[_humanDuration(_request
.properties.io_timeout_secs)]]</td> </tr> <tr> <td>Grace period</td> <td>[[_huma
nDuration(_request.properties.grace_period_secs)]]</td> </tr> <tr> <td>CIPD serv
er</td> <td> <a href$="[[_request.properties.cipd_input.server]]"> [[_request.pr
operties.cipd_input.server]] </a> </td> </tr> <tr> <td>CIPD version</td> <td>[[_
request.properties.cipd_input.client_package.version]]</td> </tr> <template is="
dom-if" if="[[_wasPickedUp(_result)]]"> <tr> <td>CIPD package name</td> <td>[[_r
esult.cipd_pins.client_package.package_name]]</td> </tr> </template> <tr hidden$
="[[_not(_request.properties.cipd_input)]]"> <td rowspan$="[[_cipdRowspan(_reque
st,_result)]]">CIPD packages</td> </tr> <template is="dom-repeat" items="[[_cipd
Packages(_request,_result)]]" as="cipd"> <tr> <td>[[cipd.path]]/</td> </tr> <tr>
<td><b>Requested:</b>[[cipd.requested]]</td> </tr> <tr hidden$="[[_wasNotPicked
Up(_result)]]"> <td><b>Actual:</b>[[cipd.actual]]</td> </tr> </template> <tr hid
den$="[[_empty(_request.properties.caches)]]"> <td rowspan$="[[_rowspan(_request
.properties.caches)]]">Named caches</td> </tr> <template is="dom-repeat" items="
[[_request.properties.caches]]" as="cache"> <tr> <td><span>[[cache.name]]</span>
:<span>[[cache.path]]</span></td> </tr> </template> </template> </tbody></table>
<div class="title" hidden$="[[_not(_task_exists)]]">Task Execution</div> <templ
ate is="dom-if" if="[[_wasPickedUp(_result)]]"> <table hidden$="[[_not(_task_exi
sts)]]"> <tbody><tr> <td>Bot assigned to task</td> <td><a href$="[[_botLink(_res
ult.bot_id)]]">[[_result.bot_id]]</a></td> </tr> <tr> <td rowspan$="[[_rowspan(_
result.bot_dimensions)]]"> <a>Bot Dimensions</a> </td> </tr> <template is="dom-r
epeat" items="[[_result.bot_dimensions]]" as="dimension"> <tr> <td><b>[[dimensio
n.key]]:</b> [[_alias(dimension)]]</td> </tr> </template> <tr> <td>Exit code</td
> <td>[[_result.exit_code]]</td> </tr> <tr> <td>Try number</td> <td>[[_result.tr
y_number]]</td> </tr> <tr> <td>Failure</td> <td class$="[[_failureClass(_result.
failure)]]">[[_result.failure]]</td> </tr> <tr> <td>Internal Failure</td> <td cl
ass$="[[_internalClass(_result.internal_failure)]]">[[_result.internal_failure]]
</td> </tr> <tr> <td>Isolated Outputs</td> <td> <a href$="[[_isolateLink(_result
.outputs_ref)]]"> [[_result.outputs_ref.isolated]] </a> </td> </tr> <tr> <td>Bot
version</td> <td>[[_result.bot_version]]</td> </tr> <tr> <td>Server version</td
> <td>[[_result.server_versions]]</td> </tr> </tbody></table> </template> <templ
ate is="dom-if" if="[[_wasNotPickedUp(_result)]]"> This space left blank until a
bot is assigned to the task. </template> <template is="dom-if" if="[[_result.pe
rformance_stats]]"> <div class="title">Performance Stats</div> <table> <tbody><t
r> <td title="This includes time taken to download inputs, isolate outputs, and
setup CIPD">Total Overhead</td> <td>[[_humanDuration(_result.performance_stats.b
ot_overhead)]]</td> </tr> <tr> <td>Downloading Inputs From Isolate</td> <td>[[_h
umanDuration(_result.performance_stats.isolated_download.duration)]]</td> </tr>
<tr> <td>Uploading Outputs To Isolate</td> <td>[[_humanDuration(_result.performa
nce_stats.isolated_upload.duration)]]</td> </tr> <tr> <td>Initial bot cache</td>
<td>[[_result.performance_stats.isolated_download.initial_number_items]] items;
[[_bytes(_result.performance_stats.isolated_download.initial_size)]]</td> </tr>
</tbody></table> </template> <div class="title">Reproducing the task locally</d
iv> <div class="reproduce"> <div>Download inputs files into directory <i>foo</i>
:</div> <div class="code"> python isolateserver.py download -I [[_request.proper
ties.inputs_ref.isolatedserver]] --namespace [[_request.properties.inputs_ref.na
mespace]] -s [[_request.properties.inputs_ref.isolated]] --target foo</div> <br>
<div>Run this task locally:</div> <div class="code"> python swarming.py reprodu
ce -S [[_host_url]] [[task_id]]</div> <br> <div>Download output results into dir
ectory <i>foo</i>:</div> <div class="code"> python swarming.py collect -S [[_hos
t_url]] --task-output-dir=foo [[task_id]]</div> <br> <div>Looking for <i>swarmin
g.py</i>?</div> <div class="code"> git clone https://github.com/luci/client-py</
div> </div> </div> <div class="flex right" hidden$="[[_not(_task_exists)]]"> <di
v class="horizontal layout"> <div class="tabs"> <paper-tabs selected="{{_show_ra
w}}" no-bar=""> <paper-tab disabled$="[[_noMilo(_request)]]">Milo Output</paper-
tab> <paper-tab>Raw Output</paper-tab> </paper-tabs> </div> <paper-input class="
refresh_input" label="Refresh Interval (seconds)" value="{{_refresh_interval}}"
title="How often to refresh all information about the task" auto-validate="" min
="1" max="1000" pattern="[0-9]+"> </paper-input> </div> <template is="dom-if" if
="[[_supportsMilo(_request,_show_raw)]]"> <div class="milo tabbed" hidden$="[[_i
sSummaryLink(task_id)]]"> Milo results are only generated for task summaires, th
at is, tasks whose ids end in 0. Tasks ending in 1 or 2 represent possible retri
es of tasks. See <a href="//goo.gl/LE4rwV">the docs</a> for more. </div> <iframe
id="miloFrame" class="milo tabbed" src$="[[_getDisplayServerLink(_server_detail
s.display_server_url_template,task_id)]]"></iframe> </template> <template is="do
m-if" if="[[_show_raw]]"> <div class="code stdout tabbed">[[_rawOutput(_stdout,_
result)]]</div> </template> </div> </div> </div> </swarming-app> <paper-dialog i
d="prompt" modal="" on-iron-overlay-closed="_promptClosed"> <h2>Are you sure?</h
2> <div>Are you sure you want to [[_dialog_prompt]]?</div> <div class="buttons">
<paper-button dialog-dismiss="" autofocus="">No</paper-button> <paper-button di
alog-confirm="">Yes</paper-button> </div> </paper-dialog> <error-toast></error-t
oast> <interval-timer period="[[_refresh_interval]]" on-trigger="_softRefresh">
</interval-timer> </template> <script>!function(){Polymer({is:"task-page",behavi
ors:[SwarmingBehaviors.CommonBehavior,SwarmingBehaviors.TaskBehavior],properties
:{task_id:{type:String},client_id:{type:String},_dialog_prompt:{type:String,valu
e:""},_host_url:{type:String,value:function(){return window.location.hostname}},
_refresh_interval:{type:Number},_request:{type:Object,observer:"_requestUpdated"
},_request_detail:{type:Boolean},_result:{type:Object},_server_details:{type:Obj
ect},_stdout:{type:String}},_alias:function(t){var e=t.value;return Array.isArra
y(e)||(e=[e]),swarming.alias.has(t.key)&&e.forEach(function(i,s){e[s]=swarming.a
lias.apply(i,t.key)}),e.join(" | ")},_bytes:function(t){return sk.human.bytes(t)
},_canCancelTask:function(t,e){return t&&"PENDING"===t.state&&e.cancel_task},_ca
ncelTask:function(){var t="/api/swarming/v1/task/"+this.task_id+"/cancel";swarmi
ng.postWithToast(t,"Canceling task "+this.task_id,this._auth_headers)},_cipdRows
pan:function(t,e){if(!t||!t.properties||!t.properties.cipd_input)return 0;var i=
(t.properties.cipd_input.packages||[]).length;return i*=e&&e.cipd_pins&&e.cipd_p
ins.packages?3:2,i+1},_cipdPackages:function(t,e){if(!t||!t.properties||!t.prope
rties.cipd_input)return[];var i=t.properties.cipd_input.packages||[],s=e&&e.cipd
_pins&&e.cipd_pins.packages||[];return i.forEach(function(t){t.requested=t.packa
ge_name+":"+t.version,s.forEach(function(e){e.path===t.path&&(t.actual=e.package
_name+":"+e.version)})}),i},_disambiguate:function(t,e){return!(!t.endsWith("0")
||!e)&&e.try_number>1},_empty:function(t){return!t||0==t.length},_expires:functi
on(t){var e=parseInt(t.expiration_secs);return e?sk.human.localeTime(new Date(t.
created_ts.getTime()+1e3*e)):t.expiration_secs+" seconds from created time"},_ex
traArgs:function(t){if(!t||!t.properties)return"";var e=t.properties.extra_args|
|[];return e.join(" ")},_failureClass:function(t){return t?"failed_task":""},_ge
tDisplayServerLink:function(t,e){if(t)return t.replace("%s",e)},_internalClass:f
unction(t){return t?"exception":""},_isolateLink:function(t){if(t&&t.isolatedser
ver)return t.isolatedserver+"/browse?namespace="+t.namespace+"&hash="+t.isolated
},_isSummaryLink:function(t){return t&&t.endsWith(0)},_noMilo:function(t){return
!this._tag(t,"allow_milo")},_pending:function(t){if(!t.created_ts)return"";var e
=t.started_ts||t.abandoned_ts||new Date;return e<=t.created_ts?"0s":this._timeDi
ffExact(t.created_ts,e)},_promptClosed:function(t){t.detail.confirmed&&(this._di
alog_prompt.startsWith("cancel")?this._cancelTask():this._retryTask())},_promptC
ancel:function(){this.set("_dialog_prompt","cancel task "+this.task_id),this.$.p
rompt.open()},_promptRetry:function(){this.set("_dialog_prompt","retry task "+th
is.task_id),this.$.prompt.open()},_rawOutput:function(t,e){return t?t:"PENDING"=
==e.state||"RUNNING"===e.state?"[No output yet]":"[No output received]"},_refres
h:function(){this.$.data.reload()},_requestUpdated:function(t){this._noMilo(t)&&
this.set("_show_raw",1)},_softRefresh:function(){if(!this._result||"RUNNING"===t
his._result.state||"PENDING"===this._result.state){this.$.data.reload();var t=th
is.$$("iframe");t&&(t.src=this._getDisplayServerLink(this._server_details.displa
y_server_url_template,this.task_id))}},_retryTask:function(){if(!this._request)r
eturn void sk.errorMessage("Task not yet loaded",3e3);var t={expiration_secs:thi
s._request.expiration_secs,name:this._request.name+" (retry)",parent_task_id:thi
s._request.parent_task_id,priority:this._request.priority,properties:this._reque
st.properties,tags:this._request.tags,user:this._profile.email,service_account:t
his._request.service_account};swarming.postWithToast("/api/swarming/v1/tasks/new
","Retrying task "+this.task_id,this._auth_headers,t).then(function(t){t=JSON.pa
rse(t),t&&t.task_id&&this.set("task_id",t.task_id)}.bind(this),function(t){conso
le.log("Task could not be retried",t)})},_rowspan:function(t){return t=t||[],t.l
ength+1},_supportsMilo:function(t,e){return!e&&t&&this._tag(t,"allow_milo")},_to
ggleDetails:function(){this.set("_request_detail",!this._request_detail)},_tag:f
unction(t,e){if(t&&t.tagMap)return t.tagMap[e]},_wasPickedUp:function(t){return
t&&t.state!==this.PENDING&&t.state!==this.CANCELED&&t.state!=this.EXPIRED},_wasN
otPickedUp:function(t){return t&&!this._wasPickedUp(t)}})}()</script> </dom-modu
le> </div></body></html> |
| OLD | NEW |