| 1 {"version":3,"file":"polymer.js","sources":["src/polymer.js","src/boot.js","src/
lib/lang.js","src/lib/job.js","src/lib/dom.js","src/lib/super.js","src/lib/deser
ialize.js","src/api.js","src/instance/utils.js","src/instance/events.js","src/in
stance/attributes.js","src/instance/properties.js","src/instance/mdv.js","src/in
stance/base.js","src/instance/styles.js","src/declaration/polymer.js","src/decla
ration/path.js","src/declaration/styles.js","src/declaration/events.js","src/dec
laration/properties.js","src/declaration/attributes.js","src/declaration/prototy
pe.js","src/declaration/queue.js","src/declaration/import.js","src/declaration/p
olymer-element.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,W
CIA,kBAAA,QAAA,UACA,YCLA,SAAA,GAGA,QAAA,GAAA,EAAA,GAiBA,MAhBA,IAAA,GAEA,OAAA,oBA
AA,GAAA,QAAA,SAAA,GAEA,GAAA,GAAA,OAAA,yBAAA,EAAA,EACA,KAEA,OAAA,eAAA,EAAA,EAAA,G
AEA,kBAAA,GAAA,QAEA,EAAA,MAAA,IAAA,MAKA,EAKA,EAAA,OAAA,GAEA,SC1BA,SAAA,GA6CA,QAA
A,GAAA,EAAA,EAAA,GAOA,MANA,GACA,EAAA,OAEA,EAAA,GAAA,GAAA,MAEA,EAAA,GAAA,EAAA,GAC
A,EAzCA,GAAA,GAAA,SAAA,GACA,KAAA,QAAA,EACA,KAAA,cAAA,KAAA,SAAA,KAAA,MAEA,GAAA,WA
CA,GAAA,SAAA,EAAA,GACA,KAAA,SAAA,CACA,IAAA,EACA,IAMA,EAAA,WAAA,KAAA,cAAA,GACA,KA
AA,OAAA,WACA,aAAA,MAPA,EAAA,sBAAA,KAAA,eACA,KAAA,OAAA,WACA,qBAAA,MASA,KAAA,WACA,
KAAA,SACA,KAAA,SACA,KAAA,OAAA,OAGA,SAAA,WACA,KAAA,SACA,KAAA,OACA,KAAA,SAAA,KAAA,
KAAA,YAiBA,EAAA,IAAA,GAEA,SC5DA,WAEA,GAAA,KAEA,aAAA,S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,KAAA,KAAA,KAAA,aAAA,QACA,K
AAA,QAAA,KAAA,aAAA,WAEA,KAAA,gBAEA,KAAA,qBAGA,kBAAA,WACA,KAAA,YACA,KAAA,oBAAA,KA
AA,OACA,KAAA,mBACA,KAAA,uBAGA,EAAA,GAAA,OAMA,UAAA,WAIA,EAAA,KAAA,WAAA,EAAA,KAAA,
UACA,QAAA,KAAA,sGACA,KAAA,KACA,KAAA,SAEA,KAAA,SAAA,KAAA,KAAA,KAAA,SACA,KAAA,YAAA
,GAIA,oBAAA,SAAA,GACA,MAAA,GAAA,GAAA,QAEA,EAAA,EAAA,MAEA,KAAA,eAAA,IAEA,IAIA,eAA
A,SAAA,GAEA,GAAA,KAAA,aAAA,cAAA,KAAA,SAQA,GAPA,KAAA,UAAA,EAOA,OAAA,iBAAA,eAAA,UA
CA,QAAA,OACA,CACA,GAAA,GAAA,SAAA,cAAA,SACA,GAAA,YAAA,YAAA,EAAA,MACA,KAAA,YAAA,KA
KA,oBAAA,WACA,MAAA,MAAA,iBAMA,gBAAA,WACA,MAAA,GAAA,KAAA,KAAA,KAAA,kBAAA,KAAA,YAG
A,cAAA,WACA,KAAA,iBAAA,EACA,KAAA,WAAA,WACA,KAAA,iBAAA,EACA,KAAA,qBACA,KAAA,SASA,
GAAA,QAAA,EAAA,YAAA,GAcA,EAAA,uBAAA,EAIA,EAAA,WACA,SAAA,KAAA,gBAAA,cACA,SAAA,cAC
A,GAAA,aAAA,iBAAA,SAAA,OAMA,SAAA,gBAAA,mBAAA,UAAA,KAEA","sourcesContent":["/*\n
* Copyright 2013 The Polymer Authors. All rights reserved.\n * Use of this sourc
e code is governed by a BSD-style\n * license that can be found in the LICENSE f
ile.\n */\nPolymer = {};\n","/*\n * Copyright 2013 The Polymer Authors. All righ
ts reserved.\n * Use of this source code is governed by a BSD-style\n * license
that can be found in the LICENSE file.\n */\n\n// TODO(sorvell): this ensures Po
lymer is an object and not a function\n// Platform is currently defining it as a
function to allow for async loading\n// of polymer; once we refine the loading
process this likely goes away.\nif (typeof window.Polymer === 'function') {\n P
olymer = {};\n}\n\n","/*\n * Copyright 2013 The Polymer Authors. All rights rese
rved.\n * Use of this source code is governed by a BSD-style\n * license that ca
n be found in the LICENSE file.\n */\n(function(scope) {\n\n // copy own proper
ties from 'api' to 'prototype, with name hinting for 'super'\n function extend(
prototype, api) {\n if (prototype && api) {\n // use only own properties
of 'api'\n Object.getOwnPropertyNames(api).forEach(function(n) {\n
// acquire property descriptor\n var pd = Object.getOwnPropertyDescriptor
(api, n);\n if (pd) {\n // clone property via descriptor\n
Object.defineProperty(prototype, n, pd);\n // cache name-of-method
for 'super' engine\n if (typeof pd.value == 'function') {\n
// hint the 'super' engine\n pd.value.nom = n;\n }\n
}\n });\n }\n return prototype;\n }\n \n // exports\n\n scope.ext
end = extend;\n\n})(Polymer);\n","/* \n * Copyright 2013 The Polymer Authors. Al
l rights reserved.\n * Use of this source code is governed by a BSD-style\n * li
cense that can be found in the LICENSE file.\n */\n\n(function(scope) {\n \n /
/ usage\n \n // invoke cb.call(this) in 100ms, unless the job is re-registered
,\n // which resets the timer\n // \n // this.myJob = this.job(this.myJob, cb
, 100)\n //\n // returns a job handle which can be used to re-register a job\n
\n var Job = function(inContext) {\n this.context = inContext;\n this.bou
ndComplete = this.complete.bind(this)\n };\n Job.prototype = {\n go: functi
on(callback, wait) {\n this.callback = callback;\n var h;\n if (!
wait) {\n h = requestAnimationFrame(this.boundComplete);\n this.ha
ndle = function() {\n cancelAnimationFrame(h);\n }\n } else
{\n h = setTimeout(this.boundComplete, wait);\n this.handle = fun
ction() {\n clearTimeout(h);\n }\n }\n },\n stop: fun
ction() {\n if (this.handle) {\n this.handle();\n this.handle
= null;\n }\n },\n complete: function() {\n if (this.handle) {\
n this.stop();\n this.callback.call(this.context);\n }\n }
\n };\n \n function job(job, callback, wait) {\n if (job) {\n job.sto
p();\n } else {\n job = new Job(this);\n }\n job.go(callback, wait
);\n return job;\n }\n \n // exports \n\n scope.job = job;\n \n})(Polyme
r);\n","/*\n * Copyright 2013 The Polymer Authors. All rights reserved.\n * Use
of this source code is governed by a BSD-style\n * license that can be found in
the LICENSE file.\n */\n(function(scope) {\n\n var registry = {};\n\n HTMLElem
ent.register = function(tag, prototype) {\n registry[tag] = prototype;\n }\n
\n // get prototype mapped to node <tag>\n HTMLElement.getPrototypeForTag = fu
nction(tag) {\n var prototype = !tag ? HTMLElement.prototype : registry[tag];
\n // TODO(sjmiles): creating <tag> is likely to have wasteful side-effects\n
return prototype || Object.getPrototypeOf(document.createElement(tag));\n }
;\n\n // we have to flag propagation stoppage for the event dispatcher\n var o
riginalStopPropagation = Event.prototype.stopPropagation;\n Event.prototype.sto
pPropagation = function() {\n this.cancelBubble = true;\n originalStopProp
agation.apply(this, arguments);\n };\n \n // TODO(sorvell): remove when we're
sure imports does not need\n // to load stylesheets\n /*\n HTMLImports.impor
ter.preloadSelectors += \n ', polymer-element link[rel=stylesheet]';\n */\
n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Authors. All rights reserved
.\n * Use of this source code is governed by a BSD-style\n * license that can be
found in the LICENSE file.\n */\n (function(scope) {\n // super\n\n // `a
rrayOfArgs` is an optional array of args like one might pass\n // to `Functio
n.apply`\n\n // TODO(sjmiles):\n // $super must be installed on an inst
ance or prototype chain\n // as `super`, and invoked via `this`, e.g.\n
// `this.super();`\n\n // will not work if function objects are not
unique, for example,\n // when using mixins.\n // The memoization st
rategy assumes each function exists on only one \n // prototype chain i.e.
we use the function object for memoizing)\n // perhaps we can bookkeep on
the prototype itself instead\n function $super(arrayOfArgs) {\n // sinc
e we are thunking a method call, performance is important here: \n // memoi
ze all lookups, once memoized the fast path calls no other \n // functions\
n //\n // find the caller (cannot be `strict` because of 'caller')\n
var caller = $super.caller;\n // memoized 'name of method' \n var
nom = caller.nom;\n // memoized next implementation prototype\n var _s
uper = caller._super;\n if (!_super) {\n if (!nom) {\n nom
= caller.nom = nameInThis.call(this, caller);\n }\n if (!nom) {\n
console.warn('called super() on a method not installed declaratively (h
as no .nom property)');\n }\n // super prototype is either cached
or we have to find it\n // by searching __proto__ (at the 'top')\n
_super = memoizeSuper(caller, nom, getPrototypeOf(this));\n }\n if (!
_super) {\n // if _super is falsey, there is no super implementation\n
//console.warn('called $super(' + nom + ') where there is no super implemen
tation');\n } else {\n // our super function\n var fn = _supe
r[nom];\n // memoize information so 'fn' can call 'super'\n if (!f
n._super) {\n memoizeSuper(fn, nom, _super);\n }\n // inv
oke the inherited method\n // if 'fn' is not function valued, this will t
hrow\n return fn.apply(this, arrayOfArgs || []);\n }\n }\n\n f
unction nextSuper(proto, name, caller) {\n // look for an inherited prototy
pe that implements name\n while (proto) {\n if ((proto[name] !== cal
ler) && proto[name]) {\n return proto;\n }\n proto = getP
rototypeOf(proto);\n }\n }\n\n function memoizeSuper(method, name, pr
oto) {\n // find and cache next prototype containing `name`\n // we ne
ed the prototype so we can do another lookup\n // from here\n method._
super = nextSuper(proto, name, method);\n if (method._super) {\n //
_super is a prototype, the actual method is _super[name]\n // tag super m
ethod with it's name for further lookups\n method._super[name].nom = name
;\n }\n return method._super;\n }\n\n function nameInThis(value)
{\n var p = this.__proto__;\n while (p && p !== HTMLElement.prototype
) {\n // TODO(sjmiles): getOwnPropertyNames is absurdly expensive\n
var n$ = Object.getOwnPropertyNames(p);\n for (var i=0, l=n$.length, n;
i<l && (n=n$[i]); i++) {\n var d = Object.getOwnPropertyDescriptor(p,
n);\n if (typeof d.value === 'function' && d.value === value) {\n
return n;\n }\n }\n p = p.__proto__;\n }\n
}\n\n // NOTE: In some platforms (IE10) the prototype chain is faked via \n
// __proto__. Therefore, always get prototype via __proto__ instead of\n //
the more standard Object.getPrototypeOf.\n function getPrototypeOf(prototype
) {\n return prototype.__proto__;\n }\n\n // utility function to prec
ompute name tags for functions\n // in a (unchained) prototype\n function
hintSuper(prototype) {\n // tag functions with their prototype name to opti
mize\n // super call invocations\n for (var n in prototype) {\n
var pd = Object.getOwnPropertyDescriptor(prototype, n);\n if (pd && type
of pd.value === 'function') {\n pd.value.nom = n;\n }\n }\n
}\n\n // exports\n\n scope.super = $super;\n\n})(Polymer);\n","/* \n *
Copyright 2013 The Polymer Authors. All rights reserved.\n * Use of this source
code is governed by a BSD-style\n * license that can be found in the LICENSE fi
le.\n */\n\n(function(scope) {\n\n var typeHandlers = {\n string: function(v
alue) {\n return value;\n },\n date: function(value) {\n return
new Date(Date.parse(value) || Date.now());\n },\n boolean: function(value)
{\n if (value === '') {\n return true;\n }\n return value
=== 'false' ? false : !!value;\n },\n number: function(value) {\n va
r n = parseFloat(value);\n // hex values like \"0xFFFF\" parseFloat as 0\n
if (n === 0) {\n n = parseInt(value);\n }\n return isNaN(n
) ? value : n;\n // this code disabled because encoded values (like \"0xFFF
F\")\n // do not round trip to their original format\n //return (Strin
g(floatVal) === value) ? floatVal : value;\n },\n object: function(value,
currentValue) {\n if (currentValue === null) {\n return value;\n
}\n try {\n // If the string is an object, we can parse is with th
e JSON library.\n // include convenience replace for single-quotes. If th
e author omits\n // quotes altogether, parse will fail.\n return J
SON.parse(value.replace(/'/g, '\"'));\n } catch(e) {\n // The object
isn't valid JSON, return the raw value\n return value;\n }\n },\
n // avoid deserialization of functions\n 'function': function(value, curr
entValue) {\n return currentValue;\n }\n };\n\n function deserializeVa
lue(value, currentValue) {\n // attempt to infer type from default value\n
var inferredType = typeof currentValue;\n // invent 'date' type value for Da
te\n if (currentValue instanceof Date) {\n inferredType = 'date';\n }
\n // delegate deserialization via type string\n return typeHandlers[infer
redType](value, currentValue);\n }\n\n // exports\n\n scope.deserializeValue
= deserializeValue;\n\n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Author
s. All rights reserved.\n * Use of this source code is governed by a BSD-style\n
* license that can be found in the LICENSE file.\n */\n(function(scope) {\n\n
// imports\n\n var extend = scope.extend;\n\n // module\n\n var api = {};\n\n
api.declaration = {};\n api.instance = {};\n\n api.publish = function(apis,
prototype) {\n for (var n in apis) {\n extend(prototype, apis[n]);\n
}\n }\n\n // exports\n\n scope.api = api;\n\n})(Polymer);\n","/*\n * Copyrigh
t 2013 The Polymer Authors. All rights reserved.\n * Use of this source code is
governed by a BSD-style\n * license that can be found in the LICENSE file.\n */\
n(function(scope) {\n\n var utils = {\n /**\n * Invokes a function asyn
chronously. The context of the callback\n * function is bound to 'this' aut
omatically.\n * @method async\n * @param {Function|String} method\n
* @param {any|Array} args\n * @param {number} timeout\n */\n asy
nc: function(method, args, timeout) {\n // when polyfilling Object.observe,
ensure changes \n // propagate before executing the async method\n Pl
atform.flush();\n // second argument to `apply` must be an array\n arg
s = (args && args.length) ? args : [args];\n // function to invoke\n v
ar fn = function() {\n (this[method] || method).apply(this, args);\n
}.bind(this);\n // execute `fn` sooner or later\n var handle = timeou
t ? setTimeout(fn, timeout) :\n requestAnimationFrame(fn);\n // NO
TE: switch on inverting handle to determine which time is used.\n return ti
meout ? handle : 1 / handle;\n },\n cancelAsync: function(handle) {\n
if (handle < 1) {\n cancelAnimationFrame(Math.round(1 / handle));\n
} else {\n clearTimeout(handle);\n }\n },\n /**\n * Fire
an event.\n * @method fire\n * @returns {Object} event\n * @para
m {string} type An event name.\n * @param {any} detail\n * @param {Nod
e} onNode Target node.\n */\n fire: function(type, detail, onNode, bubbl
es, cancelable) {\n var node = onNode || this;\n var detail = detail |
| {};\n var event = new CustomEvent(type, {\n bubbles: (bubbles !==
undefined ? bubbles : true), \n cancelable: (cancelable !== undefined ? c
ancelable : true), \n detail: detail\n });\n node.dispatchEvent
(event);\n return event;\n },\n /**\n * Fire an event asynchrono
usly.\n * @method asyncFire\n * @param {string} type An event name.\n
* @param detail\n * @param {Node} toNode Target node.\n */\n a
syncFire: function(/*inType, inDetail*/) {\n this.async(\"fire\", arguments
);\n },\n /**\n * Remove class from old, add class to anew, if they e
xist\n * @param classFollows\n * @param anew A node.\n * @param o
ld A node\n * @param className\n */\n classFollows: function(anew,
old, className) {\n if (old) {\n old.classList.remove(className);\n
}\n if (anew) {\n anew.classList.add(className);\n }\n
}\n };\n\n // no-operation function for handy stubs\n var nop = function() {}
;\n\n // null-object for handy stubs\n var nob = {};\n\n // deprecated\n\n u
tils.asyncMethod = utils.async;\n\n // exports\n\n scope.api.instance.utils =
utils;\n scope.nop = nop;\n scope.nob = nob;\n\n})(Polymer);\n","/*\n * Copyri
ght 2013 The Polymer Authors. All rights reserved.\n * Use of this source code i
s governed by a BSD-style\n * license that can be found in the LICENSE file.\n *
/\n\n(function(scope) {\n\n // imports\n\n var log = window.logFlags || {};\n
var EVENT_PREFIX = 'on-';\n\n // instance events api\n var events = {\n //
read-only\n EVENT_PREFIX: EVENT_PREFIX,\n // event listeners on host\n
addHostListeners: function() {\n var events = this.eventDelegates;\n
log.events && (Object.keys(events).length > 0) && console.log('[%s] addHostListe
ners:', this.localName, events);\n // NOTE: host events look like bindings
but really are not;\n // (1) we don't want the attribute to be set and (2)
we want to support\n // multiple event listeners ('host' and 'instance') an
d Node.bind\n // by default supports 1 thing being bound.\n // We do,
however, leverage the event hookup code in PolymerExpressions\n // so that
we have a common code path for handling declarative events.\n var self = th
is, bindable, eventName;\n for (var n in events) {\n eventName = EVE
NT_PREFIX + n;\n bindable = PolymerExpressions.prepareEventBinding(\n
Path.get(events[n]),\n eventName, \n {\n reso
lveEventHandler: function(model, path, node) {\n var fn = path.getV
alueFrom(self);\n if (fn) {\n return fn.bind(self);\
n }\n }\n }\n );\n bindable(this,
this, false);\n }\n },\n // call 'method' or function method on 'obj
' with 'args', if the method exists\n dispatchMethod: function(obj, method, a
rgs) {\n if (obj) {\n log.events && console.group('[%s] dispatch [%s
]', obj.localName, method);\n var fn = typeof method === 'function' ? met
hod : obj[method];\n if (fn) {\n fn[args ? 'apply' : 'call'](obj
, args);\n }\n log.events && console.groupEnd();\n Platform
.flush();\n }\n }\n };\n\n // exports\n\n scope.api.instance.events =
events;\n\n})(Polymer);\n","/*\r\n * Copyright 2013 The Polymer Authors. All ri
ghts reserved.\r\n * Use of this source code is governed by a BSD-style\r\n * li
cense that can be found in the LICENSE file.\r\n */\r\n(function(scope) {\r\n\r\
n // instance api for attributes\r\n\r\n var attributes = {\r\n copyInstanc
eAttributes: function () {\r\n var a$ = this._instanceAttributes;\r\n
for (var k in a$) {\r\n if (!this.hasAttribute(k)) {\r\n this.se
tAttribute(k, a$[k]);\r\n }\r\n }\r\n },\r\n // for each attri
bute on this, deserialize value to property as needed\r\n takeAttributes: fun
ction() {\r\n // if we have no publish lookup table, we have no attributes
to take\r\n // TODO(sjmiles): ad hoc\r\n if (this._publishLC) {\r\n
for (var i=0, a$=this.attributes, l=a$.length, a; (a=a$[i]) && i<l; i++) {\
r\n this.attributeToProperty(a.name, a.value);\r\n }\r\n }\
r\n },\r\n // if attribute 'name' is mapped to a property, deserialize\r\n
// 'value' into that property\r\n attributeToProperty: function(name, val
ue) {\r\n // try to match this attribute to a property (attributes are\r\n
// all lower-case, so this is case-insensitive search)\r\n var name =
this.propertyForAttribute(name);\r\n if (name) {\r\n // filter out '
mustached' values, these are to be\r\n // replaced with bound-data and ar
e not yet values\r\n // themselves\r\n if (value && value.search(s
cope.bindPattern) >= 0) {\r\n return;\r\n }\r\n // get or
iginal value\r\n var currentValue = this[name];\r\n // deserialize
Boolean or Number values from attribute\r\n var value = this.deserialize
Value(value, currentValue);\r\n // only act if the value has changed\r\n
if (value !== currentValue) {\r\n // install new value (has side
-effects)\r\n this[name] = value;\r\n }\r\n }\r\n },\r\n
// return the published property matching name, or undefined\r\n property
ForAttribute: function(name) {\r\n var match = this._publishLC && this._pub
lishLC[name];\r\n //console.log('propertyForAttribute:', name, 'matches', m
atch);\r\n return match;\r\n },\r\n // convert representation of 'str
ingValue' based on type of 'currentValue'\r\n deserializeValue: function(stri
ngValue, currentValue) {\r\n return scope.deserializeValue(stringValue, cur
rentValue);\r\n },\r\n serializeValue: function(value, inferredType) {\r\n
if (inferredType === 'boolean') {\r\n return value ? '' : undefined
;\r\n } else if (inferredType !== 'object' && inferredType !== 'function'\r
\n && value !== undefined) {\r\n return value;\r\n }\r\n
},\r\n reflectPropertyToAttribute: function(name) {\r\n var inferredTyp
e = typeof this[name];\r\n // try to intelligently serialize property value
\r\n var serializedValue = this.serializeValue(this[name], inferredType);\r
\n // boolean properties must reflect as boolean attributes\r\n if (se
rializedValue !== undefined) {\r\n this.setAttribute(name, serializedValu
e);\r\n // TODO(sorvell): we should remove attr for all properties\r\n
// that have undefined serialization; however, we will need to\r\n /
/ refine the attr reflection system to achieve this; pica, for example,\r\n
// relies on having inferredType object properties not removed as\r\n
// attrs.\r\n } else if (inferredType === 'boolean') {\r\n this.remo
veAttribute(name);\r\n }\r\n }\r\n };\r\n\r\n // exports\r\n\r\n scop
e.api.instance.attributes = attributes;\r\n\r\n})(Polymer);\r\n","/*\n * Copyrig
ht 2013 The Polymer Authors. All rights reserved.\n * Use of this source code is
governed by a BSD-style\n * license that can be found in the LICENSE file.\n */
\n(function(scope) {\n\n // imports\n\n var log = window.logFlags || {};\n\n
// magic words\n\n var OBSERVE_SUFFIX = 'Changed';\n\n // element api\n\n var
empty = [];\n\n var properties = {\n observeProperties: function() {\n
var n$ = this._observeNames, pn$ = this._publishNames;\n if ((n$ && n$.len
gth) || (pn$ && pn$.length)) {\n var self = this;\n var o = this._
propertyObserver = new CompoundObserver();\n for (var i=0, l=n$.length, n
; (i<l) && (n=n$[i]); i++) {\n o.addPath(this, n);\n // observ
er array properties\n var pd = Object.getOwnPropertyDescriptor(this.__p
roto__, n);\n if (pd && pd.value) {\n this.observeArrayValue
(n, pd.value, null);\n }\n }\n for (var i=0, l=pn$.length
, n; (i<l) && (n=pn$[i]); i++) {\n if (!this.observe || (this.observe[n
] === undefined)) {\n o.addPath(this, n);\n }\n }\n
o.open(this.notifyPropertyChanges, this);\n }\n },\n notifyProp
ertyChanges: function(newValues, oldValues, paths) {\n var name, method, ca
lled = {};\n for (var i in oldValues) {\n // note: paths is of form
[object, path, object, path]\n name = paths[2 * i + 1];\n if (this
.publish[name] !== undefined) {\n this.reflectPropertyToAttribute(name)
;\n }\n method = this.observe[name];\n if (method) {\n
this.observeArrayValue(name, newValues[i], oldValues[i]);\n if (!c
alled[method]) {\n called[method] = true;\n // observes th
e value if it is an array\n this.invokeMethod(method, [oldValues[i],
newValues[i], arguments]);\n }\n }\n }\n },\n observe
ArrayValue: function(name, value, old) {\n // we only care if there are reg
istered side-effects\n var callbackName = this.observe[name];\n if (ca
llbackName) {\n // if we are observing the previous value, stop\n
if (Array.isArray(old)) {\n log.observe && console.log('[%s] observeArr
ayValue: unregister observer [%s]', this.localName, name);\n this.unreg
isterObserver(name + '__array');\n }\n // if the new value is an a
rray, being observing it\n if (Array.isArray(value)) {\n log.obs
erve && console.log('[%s] observeArrayValue: register observer [%s]', this.local
Name, name, value);\n var observer = new ArrayObserver(value);\n
observer.open(function(value, old) {\n this.invokeMethod(callbackN
ame, [old]);\n }, this);\n this.registerObserver(name + '__arr
ay', observer);\n }\n }\n },\n bindProperty: function(property
, observable) {\n // apply Polymer two-way reference binding\n return
bindProperties(this, property, observable);\n },\n unbindAllProperties: fu
nction() {\n if (this._propertyObserver) {\n this._propertyObserver.
close();\n }\n this.unregisterObservers();\n },\n unbindProperty
: function(name) {\n return this.unregisterObserver(name);\n },\n inv
okeMethod: function(method, args) {\n var fn = this[method] || method;\n
if (typeof fn === 'function') {\n fn.apply(this, args);\n }\n
},\n // bookkeeping observers for memory management\n registerObserver: fu
nction(name, observer) {\n var o$ = this._observers || (this._observers = {
});\n o$[name] = observer;\n },\n unregisterObserver: function(name)
{\n var o$ = this._observers;\n if (o$ && o$[name]) {\n o$[name
].close();\n o$[name] = null;\n return true;\n }\n },\n
unregisterObservers: function() {\n if (this._observers) {\n var ke
ys=Object.keys(this._observers);\n for (var i=0, l=keys.length, k, o; (i
< l) && (k=keys[i]); i++) {\n o = this._observers[k];\n o.clos
e();\n }\n this._observers = {};\n }\n }\n };\n\n // pro
perty binding\n // bind a property in A to a path in B by converting A[property
] to a\n // getter/setter pair that accesses B[...path...]\n function bindProp
erties(inA, inProperty, observable) {\n log.bind && console.log(LOG_BIND_PROP
S, inB.localName || 'object', inPath, inA.localName, inProperty);\n // captur
e A's value if B's value is null or undefined,\n // otherwise use B's value\n
// TODO(sorvell): need to review, can do with ObserverTransform\n var v =
observable.discardChanges();\n if (v === null || v === undefined) {\n o
bservable.setValue(inA[inProperty]);\n }\n return Observer.defineComputedP
roperty(inA, inProperty, observable);\n }\n\n // logging\n var LOG_OBSERVE =
'[%s] watching [%s]';\n var LOG_OBSERVED = '[%s#%s] watch: [%s] now [%s] was [%
s]';\n var LOG_CHANGED = '[%s#%s] propertyChanged: [%s] now [%s] was [%s]';\n
var LOG_BIND_PROPS = \"[%s]: bindProperties: [%s] to [%s].[%s]\";\n\n // export
s\n\n scope.api.instance.properties = properties;\n\n})(Polymer);\n","/*\n * Co
pyright 2013 The Polymer Authors. All rights reserved.\n * Use of this source co
de is governed by a BSD-style\n * license that can be found in the LICENSE file.
\n */\n(function(scope) {\n\n // imports\n\n var log = window.logFlags || 0;\n
var events = scope.api.instance.events;\n\n var syntax = new PolymerExpressio
ns();\n syntax.resolveEventHandler = function(model, path, node) {\n var ctl
r = findEventController(node);\n if (ctlr) {\n var fn = path.getValueFro
m(ctlr);\n if (fn) {\n return fn.bind(ctlr);\n }\n }\n }\n\
n // An event controller is the host element for the shadowRoot in which \n //
the node exists, or the first ancestor with a 'lightDomController'\n // proper
ty.\n function findEventController(node) {\n while (node.parentNode) {\n
if (node.lightDomController) {\n return node;\n }\n node = no
de.parentNode;\n }\n return node.host;\n };\n\n // element api supportin
g mdv\n\n var mdv = {\n syntax: syntax,\n instanceTemplate: function(temp
late) {\n return template.createInstance(this, this.syntax);\n },\n b
ind: function(name, observable, oneTime) {\n // note: binding is a prepare
signal. This allows us to be sure that any\n // property changes that occur
as a result of binding will be observed.\n if (!this._elementPrepared) {\n
this.prepareElement();\n }\n var property = this.propertyForAt
tribute(name);\n if (!property) {\n // TODO(sjmiles): this mixin met
hod must use the special form\n // of `super` installed by `mixinMethod`
in declaration/prototype.js\n return this.mixinSuper(arguments);\n }
else {\n // clean out the closets\n this.unbind(name);\n /
/ use n-way Polymer binding\n var observer = this.bindProperty(property,
observable);\n // stick path on observer so it's available via this.bindi
ngs\n observer.path = observable.path_;\n // reflect bound propert
y to attribute when binding\n // to ensure binding is not left on attribu
te if property\n // does not update due to not changing.\n this.re
flectPropertyToAttribute(property);\n return this.bindings[name] = observ
er;\n }\n },\n asyncUnbindAll: function() {\n if (!this._unbound
) {\n log.unbind && console.log('[%s] asyncUnbindAll', this.localName);\n
this._unbindAllJob = this.job(this._unbindAllJob, this.unbindAll, 0);\n
}\n },\n unbindAll: function() {\n if (!this._unbound) {\n
this.unbindAllProperties();\n this.super();\n // unbind shadowRo
ot\n var root = this.shadowRoot;\n while (root) {\n unbin
dNodeTree(root);\n root = root.olderShadowRoot;\n }\n thi
s._unbound = true;\n }\n },\n cancelUnbindAll: function(preventCascad
e) {\n if (this._unbound) {\n log.unbind && console.warn('[%s] alrea
dy unbound, cannot cancel unbindAll', this.localName);\n return;\n }
\n log.unbind && console.log('[%s] cancelUnbindAll', this.localName);\n
if (this._unbindAllJob) {\n this._unbindAllJob = this._unbindAllJob.sto
p();\n }\n // cancel unbinding our shadow tree iff we're not in the pr
ocess of\n // cascading our tree (as we do, for example, when the element i
s inserted).\n if (!preventCascade) {\n forNodeTree(this.shadowRoot,
function(n) {\n if (n.cancelUnbindAll) {\n n.cancelUnbindAl
l();\n }\n });\n }\n }\n };\n\n function unbindNodeTre
e(node) {\n forNodeTree(node, _nodeUnbindAll);\n }\n\n function _nodeUnbind
All(node) {\n node.unbindAll();\n }\n\n function forNodeTree(node, callback
) {\n if (node) {\n callback(node);\n for (var child = node.firstCh
ild; child; child = child.nextSibling) {\n forNodeTree(child, callback);\
n }\n }\n }\n\n var mustachePattern = /\\{\\{([^{}]*)}}/;\n\n // expo
rts\n\n scope.bindPattern = mustachePattern;\n scope.api.instance.mdv = mdv;\n
\n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Authors. All rights reserve
d.\n * Use of this source code is governed by a BSD-style\n * license that can b
e found in the LICENSE file.\n */\n(function(scope) {\n var preparingElements =
0;\n\n var base = {\n PolymerBase: true,\n job: Polymer.job,\n super:
Polymer.super,\n // user entry point for element has had its createdCallback
called\n created: function() {\n },\n // user entry point for element
has shadowRoot and is ready for\n // api interaction\n ready: function() {
\n },\n createdCallback: function() {\n this.created();\n if (th
is.ownerDocument.defaultView || this.alwaysPrepare ||\n preparingElemen
ts > 0) {\n this.prepareElement();\n }\n },\n // system entry
point, do not override\n prepareElement: function() {\n this._elementPre
pared = true;\n // install shadowRoots storage\n this.shadowRoots = {}
;\n // install property observers\n this.observeProperties();\n /
/ install boilerplate attributes\n this.copyInstanceAttributes();\n //
process input attributes\n this.takeAttributes();\n // add event list
eners\n this.addHostListeners();\n // guarantees that while preparing,
any\n // sub-elements are also prepared\n preparingElements++;\n
// process declarative resources\n this.parseDeclarations(this.__proto__);
\n // decrement semaphore\n preparingElements--;\n // TODO(sorvel
l): CE polyfill uses unresolved attribute to simulate\n // :unresolved; rem
ove this attribute to be compatible with native\n // CE.\n this.remove
Attribute('unresolved');\n // user entry point\n this.ready();\n },
\n attachedCallback: function() {\n if (!this._elementPrepared) {\n
this.prepareElement();\n }\n this.cancelUnbindAll(true);\n //
invoke user action\n if (this.attached) {\n this.attached();\n
}\n // TODO(sorvell): bc\n if (this.enteredView) {\n this.enter
edView();\n }\n // NOTE: domReady can be used to access elements in do
m (descendants, \n // ancestors, siblings) such that the developer is enure
d to upgrade\n // ordering. If the element definitions have loaded, domRead
y\n // can be used to access upgraded elements.\n if (!this.hasBeenAtt
ached) {\n this.hasBeenAttached = true;\n if (this.domReady) {\n
this.async('domReady');\n }\n }\n },\n detachedCallbac
k: function() {\n if (!this.preventDispose) {\n this.asyncUnbindAll(
);\n }\n // invoke user action\n if (this.detached) {\n th
is.detached();\n }\n // TODO(sorvell): bc\n if (this.leftView) {\
n this.leftView();\n }\n },\n // TODO(sorvell): bc\n entere
dViewCallback: function() {\n this.attachedCallback();\n },\n // TODO
(sorvell): bc\n leftViewCallback: function() {\n this.detachedCallback()
;\n },\n // TODO(sorvell): bc\n enteredDocumentCallback: function() {\n
this.attachedCallback();\n },\n // TODO(sorvell): bc\n leftDocume
ntCallback: function() {\n this.detachedCallback();\n },\n // recursi
ve ancestral <element> initialization, oldest first\n parseDeclarations: func
tion(p) {\n if (p && p.element) {\n this.parseDeclarations(p.__proto
__);\n p.parseDeclaration.call(this, p.element);\n }\n },\n //
parse input <element> as needed, override for custom behavior\n parseDeclara
tion: function(elementElement) {\n var template = this.fetchTemplate(elemen
tElement);\n if (template) {\n var root = this.shadowFromTemplate(te
mplate);\n this.shadowRoots[elementElement.name] = root; \n }
\n },\n // return a shadow-root template (if desired), override for custom
behavior\n fetchTemplate: function(elementElement) {\n return elementEl
ement.querySelector('template');\n },\n // utility function that creates a
shadow root from a <template>\n shadowFromTemplate: function(template) {\n
if (template) {\n // make a shadow root\n var root = this.crea
teShadowRoot();\n // migrate flag(s)\n root.resetStyleInheritance
= this.resetStyleInheritance;\n // stamp template\n // which inclu
des parsing and applying MDV bindings before being \n // inserted (to avo
id {{}} in attribute values)\n // e.g. to prevent <img src=\"images/{{ico
n}}\"> from generating a 404.\n var dom = this.instanceTemplate(template)
;\n // append to shadow dom\n root.appendChild(dom);\n // p
erform post-construction initialization tasks on shadow root\n this.shado
wRootReady(root, template);\n // return the created shadow root\n
return root;\n }\n },\n // utility function that stamps a <template>
into light-dom\n lightFromTemplate: function(template) {\n if (template)
{\n // TODO(sorvell): mark this element as a lightDOMController so that\
n // event listeners on bound nodes inside it will be called on it.\n
// Note, the expectation here is that events on all descendants \n //
should be handled by this element.\n this.lightDomController = true;\n
// stamp template\n // which includes parsing and applying MDV bind
ings before being \n // inserted (to avoid {{}} in attribute values)\n
// e.g. to prevent <img src=\"images/{{icon}}\"> from generating a 404.\n
var dom = this.instanceTemplate(template);\n // append to shadow do
m\n this.appendChild(dom);\n // perform post-construction initiali
zation tasks on ahem, light root\n this.shadowRootReady(this, template);\
n // return the created shadow root\n return dom;\n }\n },
\n shadowRootReady: function(root, template) {\n // locate nodes with id
and store references to them in this.$ hash\n this.marshalNodeReferences(r
oot);\n // set up pointer gestures\n PointerGestures.register(root);\n
},\n // locate nodes with id and store references to them in this.$ hash\
n marshalNodeReferences: function(root) {\n // establish $ instance vari
able\n var $ = this.$ = this.$ || {};\n // populate $ from nodes with
ID from the LOCAL tree\n if (root) {\n var n$ = root.querySelectorAl
l(\"[id]\");\n for (var i=0, l=n$.length, n; (i<l) && (n=n$[i]); i++) {\n
$[n.id] = n;\n };\n }\n },\n attributeChangedCallbac
k: function(name, oldValue) {\n // TODO(sjmiles): adhoc filter\n if (n
ame !== 'class' && name !== 'style') {\n this.attributeToProperty(name, t
his.getAttribute(name));\n }\n if (this.attributeChanged) {\n t
his.attributeChanged.apply(this, arguments);\n }\n },\n onMutation: f
unction(node, listener) {\n var observer = new MutationObserver(function(mu
tations) {\n listener.call(this, observer, mutations);\n observer.
disconnect();\n }.bind(this));\n observer.observe(node, {childList: tr
ue, subtree: true});\n }\n };\n\n // true if object has own PolymerBase api
\n function isBase(object) {\n return object.hasOwnProperty('PolymerBase') \
n }\n\n // name a base constructor for dev tools\n\n function PolymerBase() {
};\n PolymerBase.prototype = base;\n base.constructor = PolymerBase;\n \n //
exports\n\n scope.Base = PolymerBase;\n scope.isBase = isBase;\n scope.api.i
nstance.base = base;\n \n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Aut
hors. All rights reserved.\n * Use of this source code is governed by a BSD-styl
e\n * license that can be found in the LICENSE file.\n */\n(function(scope) {\n\
n // imports\n\n var log = window.logFlags || {};\n \n // magic words\n \n
var STYLE_SCOPE_ATTRIBUTE = 'element';\n var STYLE_CONTROLLER_SCOPE = 'control
ler';\n \n var styles = {\n STYLE_SCOPE_ATTRIBUTE: STYLE_SCOPE_ATTRIBUTE,\n
/**\n * Installs external stylesheets and <style> elements with the attr
ibute \n * polymer-scope='controller' into the scope of element. This is int
ended\n * to be a called during custom element construction. Note, this incu
rs a \n * per instance cost and should be used sparingly.\n *\n * Th
e need for this type of styling should go away when the shadowDOM spec\n * a
ddresses these issues:\n * \n * https://www.w3.org/Bugs/Public/show_bug.
cgi?id=21391\n * https://www.w3.org/Bugs/Public/show_bug.cgi?id=21390\n
* https://www.w3.org/Bugs/Public/show_bug.cgi?id=21389\n * \n * @param e
lement The custom element instance into whose controller (parent)\n * scope
styles will be installed.\n * @param elementElement The <element> containing
controller styles.\n */\n // TODO(sorvell): remove when spec issues are a
ddressed\n installControllerStyles: function() {\n // apply controller s
tyles, but only if they are not yet applied\n var scope = this.findStyleCon
troller();\n if (scope && !this.scopeHasElementStyle(scope, STYLE_CONTROLLE
R_SCOPE)) {\n // allow inherited controller styles\n var proto = g
etPrototypeOf(this), cssText = '';\n while (proto && proto.element) {\n
cssText += proto.element.cssTextForScope(STYLE_CONTROLLER_SCOPE);\n
proto = getPrototypeOf(proto);\n }\n if (cssText) {\n
var style = this.element.cssTextToScopeStyle(cssText,\n STYLE_CON
TROLLER_SCOPE);\n // TODO(sorvell): for now these styles are not shimme
d\n // but we may need to shim them\n Polymer.applyStyleToScop
e(style, scope);\n }\n }\n },\n findStyleController: function(
) {\n if (window.ShadowDOMPolyfill) {\n return wrap(document.head);\
n } else {\n // find the shadow root that contains this element\n
var n = this;\n while (n.parentNode) {\n n = n.parentNode;\
n }\n return n === document ? document.head : n;\n }\n },\
n scopeHasElementStyle: function(scope, descriptor) {\n var rule = STYLE
_SCOPE_ATTRIBUTE + '=' + this.localName + '-' + descriptor;\n return scope.
querySelector('style[' + rule + ']');\n }\n };\n \n // NOTE: use raw proto
type traversal so that we ensure correct traversal\n // on platforms where the
protoype chain is simulated via __proto__ (IE10)\n function getPrototypeOf(prot
otype) {\n return prototype.__proto__;\n }\n\n // exports\n\n scope.api.in
stance.styles = styles;\n \n})(Polymer);\n","/*\n * Copyright 2013 The Polymer
Authors. All rights reserved.\n * Use of this source code is governed by a BSD-s
tyle\n * license that can be found in the LICENSE file.\n */\n(function(scope) {
\n\n // imports\n\n var extend = scope.extend;\n var api = scope.api;\n\n //
imperative implementation: Polymer()\n\n // specify an 'own' prototype for tag
`name`\n function element(name, prototype) {\n if (getRegisteredPrototype[n
ame]) {\n throw 'Already registered (Polymer) prototype for element ' + nam
e;\n }\n // cache the prototype\n registerPrototype(name, prototype);\n
// notify the registrar waiting for 'name', if any\n notifyPrototype(name
);\n }\n\n // async prototype source\n\n function waitingForPrototype(name, c
lient) {\n waitPrototype[name] = client;\n }\n\n var waitPrototype = {};\n\
n function notifyPrototype(name) {\n if (waitPrototype[name]) {\n waitP
rototype[name].registerWhenReady();\n delete waitPrototype[name];\n }\n
}\n\n // utility and bookkeeping\n\n // maps tag names to prototypes, as regi
stered with\n // Polymer. Prototypes associated with a tag name\n // using doc
ument.registerElement are available from\n // HTMLElement.getPrototypeForTag().
\n // If an element was fully registered by Polymer, then\n // Polymer.getRegi
steredPrototype(name) === \n // HTMLElement.getPrototypeForTag(name)\n\n var
prototypesByName = {};\n\n function registerPrototype(name, prototype) {\n
return prototypesByName[name] = prototype || {};\n }\n\n function getRegistere
dPrototype(name) {\n return prototypesByName[name];\n }\n\n // exports\n\n
scope.getRegisteredPrototype = getRegisteredPrototype;\n scope.waitingForProto
type = waitingForPrototype;\n\n // namespace shenanigans so we can expose our s
cope on the registration \n // function\n\n // make window.Polymer reference `
element()`\n\n window.Polymer = element;\n\n // TODO(sjmiles): find a way to d
o this that is less terrible\n // copy window.Polymer properties onto `element(
)`\n\n extend(Polymer, scope);\n\n // Under the HTMLImports polyfill, scripts
in the main document\n // do not block on imports; we want to allow calls to Po
lymer in the main\n // document. Platform collects those calls until we can pro
cess them, which\n // we do here.\n\n var declarations = Platform.deliverDecla
rations();\n if (declarations) {\n for (var i=0, l=declarations.length, d; (
i<l) && (d=declarations[i]); i++) {\n element.apply(null, d);\n }\n }\n
\n})(Polymer);\n","/* \n * Copyright 2013 The Polymer Authors. All rights reserv
ed.\n * Use of this source code is governed by a BSD-style\n * license that can
be found in the LICENSE file.\n */\n\n(function(scope) {\n\nvar path = {\n reso
lveElementPaths: function(node) {\n Platform.urlResolver.resolveDom(node);\n
},\n addResolvePathApi: function() {\n // let assetpath attribute modify th
e resolve path\n var assetPath = this.getAttribute('assetpath') || '';\n v
ar root = new URL(assetPath, this.ownerDocument.baseURI);\n this.prototype.re
solvePath = function(urlPath, base) {\n var u = new URL(urlPath, base || ro
ot);\n return u.href;\n };\n }\n};\n\n// exports\nscope.api.declaration
.path = path;\n\n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Authors. All
rights reserved.\n * Use of this source code is governed by a BSD-style\n * lic
ense that can be found in the LICENSE file.\n */\n(function(scope) {\n\n // imp
orts\n\n var log = window.logFlags || {};\n var api = scope.api.instance.style
s;\n var STYLE_SCOPE_ATTRIBUTE = api.STYLE_SCOPE_ATTRIBUTE;\n\n // magic words
\n\n var STYLE_SELECTOR = 'style';\n var STYLE_LOADABLE_MATCH = '@import';\n
var SHEET_SELECTOR = 'link[rel=stylesheet]';\n var STYLE_GLOBAL_SCOPE = 'global
';\n var SCOPE_ATTR = 'polymer-scope';\n\n var styles = {\n // returns true
if resources are loading\n loadStyles: function(callback) {\n var conte
nt = this.templateContent();\n if (content) {\n this.convertSheetsTo
Styles(content);\n }\n var styles = this.findLoadableStyles(content);\
n if (styles.length) {\n Platform.styleResolver.loadStyles(styles, c
allback);\n } else if (callback) {\n callback();\n }\n },\n
convertSheetsToStyles: function(root) {\n var s$ = root.querySelectorAll
(SHEET_SELECTOR);\n for (var i=0, l=s$.length, s, c; (i<l) && (s=s$[i]); i+
+) {\n c = createStyleElement(importRuleForSheet(s, this.ownerDocument.ba
seURI),\n this.ownerDocument);\n this.copySheetAttributes(c, s
);\n s.parentNode.replaceChild(c, s);\n }\n },\n copySheetAttr
ibutes: function(style, link) {\n for (var i=0, a$=link.attributes, l=a$.le
ngth, a; (a=a$[i]) && i<l; i++) {\n if (a.name !== 'rel' && a.name !== 's
rc') {\n style.setAttribute(a.name, a.value);\n }\n }\n
},\n findLoadableStyles: function(root) {\n var loadables = [];\n i
f (root) {\n var s$ = root.querySelectorAll(STYLE_SELECTOR);\n for
(var i=0, l=s$.length, s; (i<l) && (s=s$[i]); i++) {\n if (s.textConte
nt.match(STYLE_LOADABLE_MATCH)) {\n loadables.push(s);\n }\n
}\n }\n return loadables;\n },\n /**\n * Install ext
ernal stylesheets loaded in <polymer-element> elements into the \n * element
's template.\n * @param elementElement The <element> element to style.\n
*/\n // TODO(sorvell): wip... caching and styles handling can probably be re
moved\n // We need a scheme to ensure stylesheets are eagerly loaded without
\n // the creation of an element instance. Here are 2 options for handling th
is:\n // 1. create a dummy element with ShadowDOM in dom that includes ALL st
yles\n // processed here.\n // 2. place stylesheets outside the element te
mplate. This will allow \n // imports to naturally load the sheets. Then at l
oad time, we can remove\n // the stylesheet from dom.\n installSheets: fun
ction() {\n this.cacheSheets();\n this.cacheStyles();\n this.inst
allLocalSheets();\n this.installGlobalStyles();\n },\n /**\n * Re
move all sheets from element and store for later use.\n */\n cacheSheets:
function() {\n this.sheets = this.findNodes(SHEET_SELECTOR);\n this.s
heets.forEach(function(s) {\n if (s.parentNode) {\n s.parentNode
.removeChild(s);\n }\n });\n },\n cacheStyles: function() {\n
this.styles = this.findNodes(STYLE_SELECTOR + '[' + SCOPE_ATTR + ']');\n
this.styles.forEach(function(s) {\n if (s.parentNode) {\n s.p
arentNode.removeChild(s);\n }\n });\n },\n /**\n * Takes e
xternal stylesheets loaded in an <element> element and moves\n * their conte
nt into a <style> element inside the <element>'s template.\n * The sheet is
then removed from the <element>. This is done only so \n * that if the eleme
nt is loaded in the main document, the sheet does\n * not become active.\n
* Note, ignores sheets with the attribute 'polymer-scope'.\n * @param ele
mentElement The <element> element to style.\n */\n installLocalSheets: fu
nction () {\n var sheets = this.sheets.filter(function(s) {\n return
!s.hasAttribute(SCOPE_ATTR);\n });\n var content = this.templateConte
nt();\n if (content) {\n var cssText = '';\n sheets.forEach(f
unction(sheet) {\n cssText += cssTextFromSheet(sheet) + '\\n';\n
});\n if (cssText) {\n var style = createStyleElement(cssText,
this.ownerDocument);\n content.insertBefore(style, content.firstChild);
\n }\n }\n },\n findNodes: function(selector, matcher) {\n
var nodes = this.querySelectorAll(selector).array();\n var content = this
.templateContent();\n if (content) {\n var templateNodes = content.q
uerySelectorAll(selector).array();\n nodes = nodes.concat(templateNodes);
\n }\n return matcher ? nodes.filter(matcher) : nodes;\n },\n te
mplateContent: function() {\n var template = this.querySelector('template')
;\n return template && templateContent(template);\n },\n /**\n *
Promotes external stylesheets and <style> elements with the attribute \n * p
olymer-scope='global' into global scope.\n * This is particularly useful for
defining @keyframe rules which \n * currently do not function in scoped or
shadow style elements.\n * (See wkb.ug/72462)\n * @param elementElement
The <element> element to style.\n */\n // TODO(sorvell): remove when wkb.u
g/72462 is addressed.\n installGlobalStyles: function() {\n var style =
this.styleForScope(STYLE_GLOBAL_SCOPE);\n applyStyleToScope(style, document
.head);\n },\n cssTextForScope: function(scopeDescriptor) {\n var css
Text = '';\n // handle stylesheets\n var selector = '[' + SCOPE_ATTR +
'=' + scopeDescriptor + ']';\n var matcher = function(s) {\n return
matchesSelector(s, selector);\n };\n var sheets = this.sheets.filter(
matcher);\n sheets.forEach(function(sheet) {\n cssText += cssTextFro
mSheet(sheet) + '\\n\\n';\n });\n // handle cached style elements\n
var styles = this.styles.filter(matcher);\n styles.forEach(function(styl
e) {\n cssText += style.textContent + '\\n\\n';\n });\n return
cssText;\n },\n styleForScope: function(scopeDescriptor) {\n var cssT
ext = this.cssTextForScope(scopeDescriptor);\n return this.cssTextToScopeSt
yle(cssText, scopeDescriptor);\n },\n cssTextToScopeStyle: function(cssTex
t, scopeDescriptor) {\n if (cssText) {\n var style = createStyleElem
ent(cssText);\n style.setAttribute(STYLE_SCOPE_ATTRIBUTE, this.getAttribu
te('name') +\n '-' + scopeDescriptor);\n return style;\n
}\n }\n };\n\n function importRuleForSheet(sheet, baseUrl) {\n var href
= new URL(sheet.getAttribute('href'), baseUrl).href;\n return '@import \\'' +
href + '\\';'\n }\n\n function applyStyleToScope(style, scope) {\n if (sty
le) {\n // TODO(sorvell): necessary for IE\n // see https://connect.mi
crosoft.com/IE/feedback/details/790212/\n // cloning-a-style-element-and-ad
ding-to-document-produces\n // -unexpected-result#details\n // var clo
ne = style.cloneNode(true);\n var clone = createStyleElement(style.textCont
ent);\n var attr = style.getAttribute(STYLE_SCOPE_ATTRIBUTE);\n if (at
tr) {\n clone.setAttribute(STYLE_SCOPE_ATTRIBUTE, attr);\n }\n
scope.appendChild(clone);\n }\n }\n\n function createStyleElement(cssText,
scope) {\n scope = scope || document;\n scope = scope.createElement ? scop
e : scope.ownerDocument;\n var style = scope.createElement('style');\n sty
le.textContent = cssText;\n return style;\n }\n\n function cssTextFromSheet
(sheet) {\n return (sheet && sheet.__resource) || '';\n }\n\n function matc
hesSelector(node, inSelector) {\n if (matches) {\n return matches.call(n
ode, inSelector);\n }\n }\n var p = HTMLElement.prototype;\n var matches =
p.matches || p.matchesSelector || p.webkitMatchesSelector \n || p.mozMatch
esSelector;\n \n // exports\n\n scope.api.declaration.styles = styles;\n sco
pe.applyStyleToScope = applyStyleToScope;\n \n})(Polymer);\n","/*\n * Copyright
2013 The Polymer Authors. All rights reserved.\n * Use of this source code is g
overned by a BSD-style\n * license that can be found in the LICENSE file.\n */\n
\n(function(scope) {\n\n // imports\n\n var log = window.logFlags || {};\n va
r api = scope.api.instance.events;\n var EVENT_PREFIX = api.EVENT_PREFIX;\n //
polymer-element declarative api: events feature\n\n var events = { \n parse
HostEvents: function() {\n // our delegates map\n var delegates = this
.prototype.eventDelegates;\n // extract data from attributes into delegates
\n this.addAttributeDelegates(delegates);\n },\n addAttributeDelegate
s: function(delegates) {\n // for each attribute\n for (var i=0, a; a=
this.attributes[i]; i++) {\n // does it have magic marker identifying it
as an event delegate?\n if (this.hasEventPrefix(a.name)) {\n //
if so, add the info to delegates\n delegates[this.removeEventPrefix(a.n
ame)] = a.value.replace('{{', '')\n .replace('}}', '').trim();\n
}\n }\n },\n // starts with 'on-'\n hasEventPrefix: function
(n) {\n return n && (n[0] === 'o') && (n[1] === 'n') && (n[2] === '-');\n
},\n removeEventPrefix: function(n) {\n return n.slice(prefixLength);\
n }\n };\n\n var prefixLength = EVENT_PREFIX.length;\n\n // exports\n sco
pe.api.declaration.events = events;\n\n})(Polymer);","/*\n * Copyright 2013 The
Polymer Authors. All rights reserved.\n * Use of this source code is governed by
a BSD-style\n * license that can be found in the LICENSE file.\n */\n(function(
scope) {\n\n // element api\n\n var properties = {\n inferObservers: functi
on(prototype) {\n // called before prototype.observe is chained to inherite
d object\n var observe = prototype.observe, property;\n for (var n in
prototype) {\n if (n.slice(-7) === 'Changed') {\n if (!observe)
{\n observe = (prototype.observe = {});\n }\n prop
erty = n.slice(0, -7)\n observe[property] = observe[property] || n;\n
}\n }\n },\n explodeObservers: function(prototype) {\n //
called before prototype.observe is chained to inherited object\n var o = pr
ototype.observe;\n if (o) {\n var exploded = {};\n for (var n
in o) {\n var names = n.split(' ');\n for (var i=0, ni; ni=na
mes[i]; i++) {\n exploded[ni] = o[n];\n }\n }\n
prototype.observe = exploded;\n }\n },\n optimizePropertyMaps: func
tion(prototype) {\n if (prototype.observe) {\n // construct name lis
t\n var a = prototype._observeNames = [];\n for (var n in prototyp
e.observe) {\n var names = n.split(' ');\n for (var i=0, ni; n
i=names[i]; i++) {\n a.push(ni);\n }\n //a.push(n);
\n }\n }\n if (prototype.publish) {\n // construct name
list\n var a = prototype._publishNames = [];\n for (var n in proto
type.publish) {\n a.push(n);\n }\n }\n },\n publishPr
operties: function(prototype, base) {\n // if we have any properties to pub
lish\n var publish = prototype.publish;\n if (publish) {\n // t
ranscribe `publish` entries onto own prototype\n this.requireProperties(p
ublish, prototype, base);\n // construct map of lower-cased property name
s\n prototype._publishLC = this.lowerCaseMap(publish);\n }\n },\n
requireProperties: function(properties, prototype, base) {\n // ensure
a prototype value for each property\n for (var n in properties) {\n
if (prototype[n] === undefined && base[n] === undefined) {\n prototype[
n] = properties[n];\n }\n }\n },\n lowerCaseMap: function(prop
erties) {\n var map = {};\n for (var n in properties) {\n map[n
.toLowerCase()] = n;\n }\n return map;\n }\n };\n\n // exports\n\
n scope.api.declaration.properties = properties;\n\n})(Polymer);\n","/*\n * Cop
yright 2013 The Polymer Authors. All rights reserved.\n * Use of this source cod
e is governed by a BSD-style\n * license that can be found in the LICENSE file.\
n */\n(function(scope) {\n\n // magic words\n\n var ATTRIBUTES_ATTRIBUTE = 'at
tributes';\n var ATTRIBUTES_REGEX = /\\s|,/;\n\n // attributes api\n\n var at
tributes = {\n inheritAttributesObjects: function(prototype) {\n // chai
n our lower-cased publish map to the inherited version\n this.inheritObject
(prototype, 'publishLC');\n // chain our instance attributes map to the inh
erited version\n this.inheritObject(prototype, '_instanceAttributes');\n
},\n publishAttributes: function(prototype, base) {\n // merge names fr
om 'attributes' attribute\n var attributes = this.getAttribute(ATTRIBUTES_A
TTRIBUTE);\n if (attributes) {\n // get properties to publish\n
var publish = prototype.publish || (prototype.publish = {});\n // name
s='a b c' or names='a,b,c'\n var names = attributes.split(ATTRIBUTES_REGE
X);\n // record each name for publishing\n for (var i=0, l=names.l
ength, n; i<l; i++) {\n // remove excess ws\n n = names[i].tri
m();\n // do not override explicit entries\n if (n && publish[
n] === undefined && base[n] === undefined) {\n publish[n] = null;\n
}\n }\n }\n },\n // record clonable attributes from <e
lement>\n accumulateInstanceAttributes: function() {\n // inherit instan
ce attributes\n var clonable = this.prototype._instanceAttributes;\n /
/ merge attributes from element\n var a$ = this.attributes;\n for (var
i=0, l=a$.length, a; (i<l) && (a=a$[i]); i++) { \n if (this.isInstanceA
ttribute(a.name)) {\n clonable[a.name] = a.value;\n }\n }\n
},\n isInstanceAttribute: function(name) {\n return !this.blackList[
name] && name.slice(0,3) !== 'on-';\n },\n // do not clone these attribute
s onto instances\n blackList: {\n name: 1,\n 'extends': 1,\n c
onstructor: 1,\n noscript: 1,\n assetpath: 1,\n 'cache-csstext':
1\n }\n };\n\n // add ATTRIBUTES_ATTRIBUTE to the blacklist\n attributes.b
lackList[ATTRIBUTES_ATTRIBUTE] = 1;\n\n // exports\n\n scope.api.declaration.a
ttributes = attributes;\n\n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Au
thors. All rights reserved.\n * Use of this source code is governed by a BSD-sty
le\n * license that can be found in the LICENSE file.\n */\n(function(scope) {\n
\n // imports\n \n var api = scope.api;\n var isBase = scope.isBase;\n var
extend = scope.extend;\n\n // prototype api\n\n var prototype = {\n\n regis
ter: function(name, extendeeName) {\n // build prototype combining extendee
, Polymer base, and named api\n this.buildPrototype(name, extendeeName);\n
// register our custom element with the platform\n this.registerProtot
ype(name, extendeeName);\n // reference constructor in a global named by 'c
onstructor' attribute\n this.publishConstructor();\n },\n\n buildProt
otype: function(name, extendeeName) {\n // get our custom prototype (before
chaining)\n var extension = scope.getRegisteredPrototype(name);\n //
get basal prototype\n var base = this.generateBasePrototype(extendeeName);\
n // implement declarative features\n this.desugarBeforeChaining(exten
sion, base);\n // join prototypes\n this.prototype = this.chainPrototy
pes(extension, base);\n // more declarative features\n this.desugarAft
erChaining(name, extendeeName);\n },\n\n desugarBeforeChaining: function(p
rototype, base) {\n // back reference declaration element\n // TODO(sj
miles): replace `element` with `elementElement` or `declaration`\n prototyp
e.element = this;\n // transcribe `attributes` declarations onto own protot
ype's `publish`\n this.publishAttributes(prototype, base);\n // `publi
sh` properties to the prototype and to attribute watch\n this.publishProper
ties(prototype, base);\n // infer observers for `observe` list based on met
hod names\n this.inferObservers(prototype);\n // desugar compound obse
rver syntax, e.g. 'a b c' \n this.explodeObservers(prototype);\n },\n\n
chainPrototypes: function(prototype, base) {\n // chain various meta-dat
a objects to inherited versions\n this.inheritMetaData(prototype, base);\n
// chain custom api to inherited\n var chained = this.chainObject(prot
otype, base);\n // x-platform fixup\n ensurePrototypeTraversal(chained
);\n return chained;\n },\n\n inheritMetaData: function(prototype, ba
se) {\n // chain observe object to inherited\n this.inheritObject('obs
erve', prototype, base);\n // chain publish object to inherited\n this
.inheritObject('publish', prototype, base);\n // chain our lower-cased publ
ish map to the inherited version\n this.inheritObject('_publishLC', prototy
pe, base);\n // chain our instance attributes map to the inherited version\
n this.inheritObject('_instanceAttributes', prototype, base);\n // cha
in our event delegates map to the inherited version\n this.inheritObject('e
ventDelegates', prototype, base);\n },\n\n // implement various declarativ
e features\n desugarAfterChaining: function(name, extendee) {\n // build
side-chained lists to optimize iterations\n this.optimizePropertyMaps(this
.prototype);\n // install external stylesheets as if they are inline\n
this.installSheets();\n // adjust any paths in dom from imports\n thi
s.resolveElementPaths(this);\n // compile list of attributes to copy to ins
tances\n this.accumulateInstanceAttributes();\n // parse on-* delegate
s declared on `this` element\n this.parseHostEvents();\n //\n //
install a helper method this.resolvePath to aid in \n // setting resource u
rls. e.g.\n // this.$.image.src = this.resolvePath('images/foo.png')\n
this.addResolvePathApi();\n // under ShadowDOMPolyfill, transforms to appr
oximate missing CSS features\n if (window.ShadowDOMPolyfill) {\n Pla
tform.ShadowCSS.shimStyling(this.templateContent(), name, extendee);\n }\n
// allow custom element access to the declarative context\n if (this.p
rototype.registerCallback) {\n this.prototype.registerCallback(this);\n
}\n },\n\n // if a named constructor is requested in element, map a re
ference\n // to the constructor to the given symbol\n publishConstructor:
function() {\n var symbol = this.getAttribute('constructor');\n if (sy
mbol) {\n window[symbol] = this.ctor;\n }\n },\n\n // build pr
ototype combining extendee, Polymer base, and named api\n generateBasePrototy
pe: function(extnds) {\n var prototype = this.findBasePrototype(extnds);\n
if (!prototype) {\n // create a prototype based on tag-name extensio
n\n var prototype = HTMLElement.getPrototypeForTag(extnds);\n // i
nsert base api in inheritance chain (if needed)\n prototype = this.ensure
BaseApi(prototype);\n // memoize this base\n memoizedBases[extnds]
= prototype;\n }\n return prototype;\n },\n\n findBasePrototype
: function(name) {\n return memoizedBases[name];\n },\n\n // install
Polymer instance api into prototype chain, as needed \n ensureBaseApi: functi
on(prototype) {\n if (prototype.PolymerBase) {\n return prototype;\n
}\n var extended = Object.create(prototype);\n // we need a uniq
ue copy of base api for each base prototype\n // therefore we 'extend' here
instead of simply chaining\n api.publish(api.instance, extended);\n /
/ TODO(sjmiles): sharing methods across prototype chains is\n // not suppor
ted by 'super' implementation which optimizes\n // by memoizing prototype r
elationships.\n // Probably we should have a version of 'extend' that is \n
// share-aware: it could study the text of each function,\n // look f
or usage of 'super', and wrap those functions in\n // closures.\n // A
s of now, there is only one problematic method, so \n // we just patch it m
anually.\n // To avoid re-entrancy problems, the special super method\n
// installed is called `mixinSuper` and the mixin method\n // must use th
is method instead of the default `super`.\n this.mixinMethod(extended, prot
otype, api.instance.mdv, 'bind');\n // return buffed-up prototype\n re
turn extended;\n },\n\n mixinMethod: function(extended, prototype, api, na
me) {\n var $super = function(args) {\n return prototype[name].apply
(this, args);\n };\n extended[name] = function() {\n this.mixin
Super = $super;\n return api[name].apply(this, arguments);\n }\n
},\n\n // ensure prototype[name] inherits from a prototype.prototype[name]\n
inheritObject: function(name, prototype, base) {\n // require an object\
n var source = prototype[name] || {};\n // chain inherited properties
onto a new object\n prototype[name] = this.chainObject(source, base[name]);
\n },\n\n // register 'prototype' to custom element 'name', store construc
tor \n registerPrototype: function(name, extendee) { \n var info = {\n
prototype: this.prototype\n }\n // native element must be specif
ied in extends\n var typeExtension = this.findTypeExtension(extendee);\n
if (typeExtension) {\n info.extends = typeExtension;\n }\n /
/ register the prototype with HTMLElement for name lookup\n HTMLElement.reg
ister(name, this.prototype);\n // register the custom type\n this.ctor
= document.registerElement(name, info);\n },\n\n findTypeExtension: funct
ion(name) {\n if (name && name.indexOf('-') < 0) {\n return name;\n
} else {\n var p = this.findBasePrototype(name);\n if (p.elem
ent) {\n return this.findTypeExtension(p.element.extends);\n }\n
}\n }\n\n };\n\n // memoize base prototypes\n var memoizedBases = {}
;\n\n // implementation of 'chainObject' depends on support for __proto__\n if
(Object.__proto__) {\n prototype.chainObject = function(object, inherited) {
\n if (object && inherited && object !== inherited) {\n object.__pro
to__ = inherited;\n }\n return object;\n }\n } else {\n prototy
pe.chainObject = function(object, inherited) {\n if (object && inherited &&
object !== inherited) {\n var chained = Object.create(inherited);\n
object = extend(chained, object);\n }\n return object;\n }\n }\
n\n // On platforms that do not support __proto__ (versions of IE), the prototy
pe\n // chain of a custom element is simulated via installation of __proto__.\n
// Although custom elements manages this, we install it here so it's\n // ava
ilable during desugaring.\n function ensurePrototypeTraversal(prototype) {\n
if (!Object.__proto__) {\n var ancestor = Object.getPrototypeOf(prototype)
;\n prototype.__proto__ = ancestor;\n if (isBase(ancestor)) {\n
ancestor.__proto__ = Object.getPrototypeOf(ancestor);\n }\n }\n }\n\n
// exports\n\n api.declaration.prototype = prototype;\n\n})(Polymer);\n","/*\n
* Copyright 2013 The Polymer Authors. All rights reserved.\n * Use of this sour
ce code is governed by a BSD-style\n * license that can be found in the LICENSE
file.\n */\n(function(scope) {\n\n var queue = {\n // tell the queue to wait
for an element to be ready\n wait: function(element, check, go) {\n if
(this.indexOf(element) === -1) {\n this.add(element);\n element.__
check = check;\n element.__go = go;\n }\n return (this.indexOf(
element) !== 0);\n },\n add: function(element) {\n //console.log('que
ueing', element.name);\n queueForElement(element).push(element);\n },\n
indexOf: function(element) {\n var i = queueForElement(element).indexOf(
element);\n if (i >= 0 && document.contains(element)) {\n i += (HTML
Imports.useNative || HTMLImports.ready) ? importQueue.length :\n 1e9;
\n }\n return i; \n },\n // tell the queue an element is ready
to be registered\n go: function(element) {\n var readied = this.remove(e
lement);\n if (readied) {\n readied.__go.call(readied);\n rea
died.__check = readied.__go = null;\n this.check();\n }\n },\n
remove: function(element) {\n var i = this.indexOf(element);\n if (i
!== 0) {\n //console.warn('queue order wrong', i);\n return;\n
}\n return queueForElement(element).shift(); \n },\n check: functi
on() {\n // next\n var element = this.nextElement();\n if (elemen
t) {\n element.__check.call(element);\n }\n if (this.canReady()
) {\n this.ready();\n return true;\n }\n },\n nextEleme
nt: function() {\n return nextQueued();\n },\n canReady: function() {
\n return !this.waitToReady && this.isEmpty();\n },\n isEmpty: functi
on() {\n return !importQueue.length && !mainQueue.length;\n },\n read
y: function() {\n // TODO(sorvell): As an optimization, turn off CE polyfil
l upgrading\n // while registering. This way we avoid having to upgrade eac
h document\n // piecemeal per registration and can instead register all ele
ments\n // and upgrade once in a batch. Without this optimization, upgrade
time\n // degrades significantly when SD polyfill is used. This is mainly b
ecause\n // querying the document tree for elements is slow under the SD po
lyfill.\n if (CustomElements.ready === false) {\n CustomElements.upg
radeDocumentTree(document);\n CustomElements.ready = true;\n }\n
if (readyCallbacks) {\n var fn;\n while (readyCallbacks.length)
{\n fn = readyCallbacks.shift();\n fn();\n }\n }\n
},\n addReadyCallback: function(callback) {\n if (callback) {\n
readyCallbacks.push(callback);\n }\n },\n waitToReady: true\n };\
n\n var importQueue = [];\n var mainQueue = [];\n var readyCallbacks = [];\n\
n function queueForElement(element) {\n return document.contains(element) ?
mainQueue : importQueue;\n }\n\n function nextQueued() {\n return importQue
ue.length ? importQueue[0] : mainQueue[0];\n }\n\n var polymerReadied = false;
\n\n document.addEventListener('WebComponentsReady', function() {\n CustomE
lements.ready = false;\n });\n \n function whenPolymerReady(callback) {\n
queue.waitToReady = true;\n CustomElements.ready = false;\n HTMLImports.wh
enImportsReady(function() {\n queue.addReadyCallback(callback);\n queu
e.waitToReady = false;\n queue.check();\n });\n }\n\n // exports\n sc
ope.queue = queue;\n scope.whenPolymerReady = whenPolymerReady;\n})(Polymer);\n
","/*\n * Copyright 2013 The Polymer Authors. All rights reserved.\n * Use of th
is source code is governed by a BSD-style\n * license that can be found in the L
ICENSE file.\n */\n(function(scope) {\n\n var whenPolymerReady = scope.whenPoly
merReady;\n\n function importElements(elementOrFragment, callback) {\n if (e
lementOrFragment) {\n document.head.appendChild(elementOrFragment);\n
whenPolymerReady(callback);\n } else if (callback) {\n callback();\n
}\n }\n\n function importUrls(urls, callback) {\n if (urls && urls.length)
{\n var frag = document.createDocumentFragment();\n for (var i=0,
l=urls.length, url, link; (i<l) && (url=urls[i]); i++) {\n link = docum
ent.createElement('link');\n link.rel = 'import';\n link.href
= url;\n frag.appendChild(link);\n }\n importElements(fra
g, callback);\n } else if (callback) {\n callback();\n }\n }\n\n //
exports\n scope.import = importUrls;\n scope.importElements = importElements;
\n\n})(Polymer);\n","/*\n * Copyright 2013 The Polymer Authors. All rights reser
ved.\n * Use of this source code is governed by a BSD-style\n * license that can
be found in the LICENSE file.\n */\n(function(scope) {\n\n // imports\n\n var
extend = scope.extend;\n var api = scope.api;\n var queue = scope.queue;\n v
ar whenPolymerReady = scope.whenPolymerReady;\n var getRegisteredPrototype = sc
ope.getRegisteredPrototype;\n var waitingForPrototype = scope.waitingForPrototy
pe;\n\n // declarative implementation: <polymer-element>\n\n var prototype = e
xtend(Object.create(HTMLElement.prototype), {\n\n createdCallback: function()
{\n if (this.getAttribute('name')) {\n this.init();\n }\n }
,\n\n init: function() {\n // fetch declared values\n this.name = t
his.getAttribute('name');\n this.extends = this.getAttribute('extends');\n
// initiate any async resource fetches\n this.loadResources();\n
// register when all constraints are met\n this.registerWhenReady();\n }
,\n\n registerWhenReady: function() {\n if (this.registered\n || th
is.waitingForPrototype(this.name)\n || this.waitingForQueue()\n || t
his.waitingForResources()) {\n return;\n }\n queue.go(this);\
n },\n\n\n // TODO(sorvell): refactor, this method is private-ish, but it'
s being\n // called by the queue object.\n _register: function() {\n
//console.log('registering', this.name);\n //console.group('registering', t
his.name);\n // warn if extending from a custom element not registered via
Polymer\n if (isCustomTag(this.extends) && !isRegistered(this.extends)) {\n
console.warn('%s is attempting to extend %s, an unregistered element ' +
\n 'or one that was not registered with Polymer.', this.name,\n
this.extends);\n }\n this.register(this.name, this.extends);\n
this.registered = true;\n //console.groupEnd();\n },\n\n waitingF
orPrototype: function(name) {\n if (!getRegisteredPrototype(name)) {\n
// then wait for a prototype\n waitingForPrototype(name, this);\n
// emulate script if user is not supplying one\n this.handleNoScript(n
ame);\n // prototype not ready yet\n return true;\n }\n },
\n\n handleNoScript: function(name) {\n // if explicitly marked as 'nosc
ript'\n if (this.hasAttribute('noscript') && !this.noscript) {\n thi
s.noscript = true;\n // TODO(sorvell): CustomElements polyfill awareness:
\n // noscript elements should upgrade in logical order\n // scrip
t injection ensures this under native custom elements;\n // under imports
+ ce polyfills, scripts run before upgrades.\n // dependencies should be
ready at upgrade time so register\n // prototype at this time.\n
if (window.CustomElements && !CustomElements.useNative) {\n Polymer(nam
e);\n } else {\n var script = document.createElement('script');\
n script.textContent = 'Polymer(\\'' + name + '\\');';\n this.
appendChild(script);\n }\n }\n },\n\n waitingForResources: fun
ction() {\n return this._needsResources;\n },\n\n // NOTE: Elements m
ust be queued in proper order for inheritance/composition\n // dependency res
olution. Previously this was enforced for inheritance,\n // and by rule for c
omposition. It's now entirely by rule.\n waitingForQueue: function() {\n
return queue.wait(this, this.registerWhenReady, this._register);\n },\n\n
loadResources: function() {\n this._needsResources = true;\n this.loa
dStyles(function() {\n this._needsResources = false;\n this.regist
erWhenReady();\n }.bind(this));\n }\n\n });\n\n // semi-pluggable APIs
\n\n // TODO(sjmiles): should be fully pluggable (aka decoupled, currently\n
// the various plugins are allowed to depend on each other directly)\n api.publ
ish(api.declaration, prototype);\n\n // utility and bookkeeping\n\n function i
sRegistered(name) {\n return Boolean(HTMLElement.getPrototypeForTag(name));\n
}\n\n function isCustomTag(name) {\n return (name && name.indexOf('-') >=
0);\n }\n\n // exports\n\n scope.getRegisteredPrototype = getRegisteredProtot
ype;\n \n // boot tasks\n\n whenPolymerReady(function() {\n document.body.
removeAttribute('unresolved');\n document.dispatchEvent(\n new CustomEve
nt('polymer-ready', {bubbles: true})\n );\n });\n\n // register polymer-ele
ment with document\n\n document.registerElement('polymer-element', {prototype:
prototype});\n\n})(Polymer);\n"]} |