diff options
author | jlklein <jlklein@chromium.org> | 2015-06-02 03:56:19 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-06-02 10:56:50 +0000 |
commit | 1a35e51b496b63547fc08de98cfbd2e0d53cc9bc (patch) | |
tree | b4247ffecb7e82bff957ed04868bd91012e56fa6 /third_party/polymer/v1_0 | |
parent | 2c94134f61123cd6298394d05d5f39717334f348 (diff) | |
download | chromium_src-1a35e51b496b63547fc08de98cfbd2e0d53cc9bc.zip chromium_src-1a35e51b496b63547fc08de98cfbd2e0d53cc9bc.tar.gz chromium_src-1a35e51b496b63547fc08de98cfbd2e0d53cc9bc.tar.bz2 |
Rename polymer and cr_elements v0_8 to v1_0
BUG=489785
Review URL: https://codereview.chromium.org/1155683008
Cr-Commit-Position: refs/heads/master@{#332364}
Diffstat (limited to 'third_party/polymer/v1_0')
1124 files changed, 78430 insertions, 0 deletions
diff --git a/third_party/polymer/v1_0/README.chromium b/third_party/polymer/v1_0/README.chromium new file mode 100644 index 0000000..2b846bf --- /dev/null +++ b/third_party/polymer/v1_0/README.chromium @@ -0,0 +1,54 @@ +Name: Polymer +Short Name: polymer +URL: http://www.polymer-project.org +Version: 1.0 +Revision: (See components/<component>/.bower.json) +License: BSD +License File: ../LICENSE.polymer +Security Critical: no + +Description: +This directory contains a copy of the following components which are a part of +the Polymer project: +-polymer core + externs +-Iron elements and their dependencies +-Paper elements and their dependencies +-more-routing +See bower.json for a full list of components. + +The version can be found in header of polymer/polymer.js. The license can +be found in polymer/LICENSE. + +The source git repositories can be found at: +Core Library - https://github.com/Polymer/polymer +Elements - https://github.com/PolymerElements/<element name> + +Polymer is comprised of two efforts: +1. A set of core platform features (Shadow DOM, Custom Elements, MDV). +Initially, these core features will be enabled with a set of polyfills. As +browsers begin to implement these new primitives, the polyfill platform layer +becomes smaller and better over time. +2. A next-generation web application framework built upon these core +technologies called the Polymer. + +Local Modifications: +- Removed executable bit from the files in 'components/iron-selector'. +- Created a copy 'components-chromium' of the 'components' directory with the +only difference that all inline JavaScript blocks are extracted from Polymer +HTML elements to external JS files. This version of the Polymer is used in a web +UI, where CSP forbids an execution of inline scripts. The extraction was made +with the help of the Vulcanize tool (https://github.com/Polymer/vulcanize). +- Replaced CRLF line endings with LF line endings in text files. + +To restore a content of the 'components', 'components-chromium' directorires +from scratch, run ./reproduce.sh (requires bower and vulcanize >= 1.2). + +Note on Bower: +The directory can be updated by running "bower update". A new component can be +installed by running "bower install -S Polymer/<component>#version". Be sure to +add the .bower.json file to the repository as it includes the revision +information of the polymer component. +Also be sure that you listed all the added packages and **all their +dependencies** in bower.json, and specified **exact** versions of every package +explicitly. That is needed because Bower can't handle recursive dependencies +correctly (see http://stackoverflow.com/q/25899532). diff --git a/third_party/polymer/v1_0/bower.json b/third_party/polymer/v1_0/bower.json new file mode 100644 index 0000000..df03403 --- /dev/null +++ b/third_party/polymer/v1_0/bower.json @@ -0,0 +1,12 @@ +{ + "name": "chromium", + "private": true, + "dependencies": { + "polymer": "Polymer/polymer#~v1.0.0", + "polymer-externs": "PolymerLabs/polymer-externs#~1.0.0", + + "iron-elements": "PolymerElements/iron-elements#~1.0.0", + "paper-elements": "PolymerElements/paper-elements#~1.0.0", + "more-routing": "PolymerLabs/more-routing#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/.bower.json new file mode 100644 index 0000000..54806db --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/.bower.json @@ -0,0 +1,38 @@ +{ + "name": "iron-a11y-announcer", + "version": "1.0.0", + "description": "A singleton element that simplifies announcing text to screen readers.", + "keywords": [ + "web-components", + "polymer", + "a11y", + "live" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-announcer.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + }, + "homepage": "https://github.com/PolymerElements/iron-a11y-announcer", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "c809efbb3fd27a25eef515acd2f46f07a5f5c6a2" + }, + "_source": "git://github.com/PolymerElements/iron-a11y-announcer.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-a11y-announcer" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/README.md b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/README.md new file mode 100644 index 0000000..5988d8c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/README.md @@ -0,0 +1,29 @@ +iron-a11y-announcer +=================== + +`iron-a11y-announcer` is a singleton element that is intended to add a11y +to features that require on-demand announcement from screen readers. In +order to make use of the announcer, it is best to request its availability +in the announcing element. + +Example: + + Polymer({ + is: 'x-chatty', + attached: function() { + // This will create the singlton element if it has not + // been created yet: + Polymer.IronA11yAnnouncer.requestAvailability(); + } + }); + +After the `iron-a11y-announcer` has been made available, elements can +make announces by firing bubbling `iron-announce` events. + +Example: + + this.fire('iron-announce', { + text: 'This is an announcement!' + }, { bubbles: true }); + +Note: announcements are only audible if you have a screen reader enabled. diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/bower.json b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/bower.json new file mode 100644 index 0000000..ce802c1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-a11y-announcer", + "version": "1.0.0", + "description": "A singleton element that simplifies announcing text to screen readers.", + "keywords": [ + "web-components", + "polymer", + "a11y", + "live" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-announcer.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/index.html b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/index.html new file mode 100644 index 0000000..1f8889a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + + <title>iron-a11y-announcer</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/iron-a11y-announcer-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/iron-a11y-announcer-extracted.js new file mode 100644 index 0000000..28063d2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/iron-a11y-announcer-extracted.js @@ -0,0 +1,65 @@ + + + (function() { + 'use strict'; + + Polymer.IronA11yAnnouncer = Polymer({ + is: 'iron-a11y-announcer', + + properties: { + + /** + * The value of mode is used to set the `aria-live` attribute + * for the element that will be announced. Valid values are: `off`, + * `polite` and `assertive`. + */ + mode: { + type: String, + value: 'polite' + }, + + _text: { + type: String, + value: '' + } + }, + + created: function() { + if (!Polymer.IronA11yAnnouncer.instance) { + Polymer.IronA11yAnnouncer.instance = this; + } + + document.body.addEventListener('iron-announce', this._onIronAnnounce.bind(this)); + }, + + /** + * Cause a text string to be announced by screen readers. + * + * @param {string} text The text that should be announced. + */ + announce: function(text) { + this._text = ''; + this.async(function() { + this._text = text; + }, 100); + }, + + _onIronAnnounce: function(event) { + if (event.detail && event.detail.text) { + this.announce(event.detail.text); + } + } + }); + + Polymer.IronA11yAnnouncer.instance = null; + + Polymer.IronA11yAnnouncer.requestAvailability = function() { + if (!Polymer.IronA11yAnnouncer.instance) { + document.createElement('iron-a11y-announcer'); + } + + document.body.appendChild(Polymer.IronA11yAnnouncer.instance); + }; + })(); + +
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/iron-a11y-announcer.html b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/iron-a11y-announcer.html new file mode 100644 index 0000000..85ce8c6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-announcer/iron-a11y-announcer.html @@ -0,0 +1,59 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-a11y-announcer` is a singleton element that is intended to add a11y +to features that require on-demand announcement from screen readers. In +order to make use of the announcer, it is best to request its availability +in the announcing element. + +Example: + + Polymer({ + + is: 'x-chatty', + + attached: function() { + // This will create the singlton element if it has not + // been created yet: + Polymer.IronA11yAnnouncer.requestAvailability(); + } + }); + +After the `iron-a11y-announcer` has been made available, elements can +make announces by firing bubbling `iron-announce` events. + +Example: + + this.fire('iron-announce', { + text: 'This is an announcement!' + }, { bubbles: true }); + +Note: announcements are only audible if you have a screen reader enabled. + +@group Iron Elements +@demo demo/index.html +--> + +</head><body><dom-module id="iron-a11y-announcer"> + <style> + :host { + display: inline-block; + position: fixed; + clip: rect(0px,0px,0px,0px); + } + </style> + + <template> + <span aria-live$="[[mode]]">[[_text]]</span> + </template> + + </dom-module> +<script src="iron-a11y-announcer-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/.bower.json new file mode 100644 index 0000000..7a68cd2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-a11y-keys-behavior", + "version": "1.0.1", + "description": "A behavior that enables keybindings for greater a11y.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys-behavior.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-a11y-keys-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "443f7fc3947aa1d2bb4817588da4bb67fcbbc09d" + }, + "_source": "git://github.com/PolymerElements/iron-a11y-keys-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-a11y-keys-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/README.md new file mode 100644 index 0000000..2d16daa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/README.md @@ -0,0 +1,15 @@ +iron-a11y-keys-behavior +======================= + +`Polymer.IronA11yKeysBehavior` provides a normalized interface for processing +keyboard commands that pertain to [WAI-ARIA best practices](http://www.w3.org/TR/wai-aria-practices/#kbd_general_binding). +The element takes care of browser differences with respect to Keyboard events +and uses an expressive syntax to filter key presses. + +Use the `keyBindings` prototype property to express what combination of keys +will trigger the event to fire. + +Use the `key-event-target` attribute to set up event handlers on a specific +node. +The `keys-pressed` event will fire when one of the key combinations set with the +`keys` property is pressed. diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/bower.json new file mode 100644 index 0000000..87e2f64 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/bower.json @@ -0,0 +1,27 @@ +{ + "name": "iron-a11y-keys-behavior", + "version": "1.0.0", + "description": "A behavior that enables keybindings for greater a11y.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys-behavior.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/index.html new file mode 100644 index 0000000..e533e79 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-a11y-keys-behavior</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/iron-a11y-keys-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/iron-a11y-keys-behavior-extracted.js new file mode 100644 index 0000000..8cddd21 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/iron-a11y-keys-behavior-extracted.js @@ -0,0 +1,405 @@ + + (function() { + 'use strict'; + + /** + * Chrome uses an older version of DOM Level 3 Keyboard Events + * + * Most keys are labeled as text, but some are Unicode codepoints. + * Values taken from: http://www.w3.org/TR/2007/WD-DOM-Level-3-Events-20071221/keyset.html#KeySet-Set + */ + var KEY_IDENTIFIER = { + 'U+0009': 'tab', + 'U+001B': 'esc', + 'U+0020': 'space', + 'U+002A': '*', + 'U+0030': '0', + 'U+0031': '1', + 'U+0032': '2', + 'U+0033': '3', + 'U+0034': '4', + 'U+0035': '5', + 'U+0036': '6', + 'U+0037': '7', + 'U+0038': '8', + 'U+0039': '9', + 'U+0041': 'a', + 'U+0042': 'b', + 'U+0043': 'c', + 'U+0044': 'd', + 'U+0045': 'e', + 'U+0046': 'f', + 'U+0047': 'g', + 'U+0048': 'h', + 'U+0049': 'i', + 'U+004A': 'j', + 'U+004B': 'k', + 'U+004C': 'l', + 'U+004D': 'm', + 'U+004E': 'n', + 'U+004F': 'o', + 'U+0050': 'p', + 'U+0051': 'q', + 'U+0052': 'r', + 'U+0053': 's', + 'U+0054': 't', + 'U+0055': 'u', + 'U+0056': 'v', + 'U+0057': 'w', + 'U+0058': 'x', + 'U+0059': 'y', + 'U+005A': 'z', + 'U+007F': 'del' + }; + + /** + * Special table for KeyboardEvent.keyCode. + * KeyboardEvent.keyIdentifier is better, and KeyBoardEvent.key is even better + * than that. + * + * Values from: https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent.keyCode#Value_of_keyCode + */ + var KEY_CODE = { + 9: 'tab', + 13: 'enter', + 27: 'esc', + 33: 'pageup', + 34: 'pagedown', + 35: 'end', + 36: 'home', + 32: 'space', + 37: 'left', + 38: 'up', + 39: 'right', + 40: 'down', + 46: 'del', + 106: '*' + }; + + /** + * MODIFIER_KEYS maps the short name for modifier keys used in a key + * combo string to the property name that references those same keys + * in a KeyboardEvent instance. + */ + var MODIFIER_KEYS = { + shift: 'shiftKey', + ctrl: 'ctrlKey', + alt: 'altKey', + meta: 'metaKey' + }; + + /** + * KeyboardEvent.key is mostly represented by printable character made by + * the keyboard, with unprintable keys labeled nicely. + * + * However, on OS X, Alt+char can make a Unicode character that follows an + * Apple-specific mapping. In this case, we + * fall back to .keyCode. + */ + var KEY_CHAR = /[a-z0-9*]/; + + /** + * Matches a keyIdentifier string. + */ + var IDENT_CHAR = /U\+/; + + /** + * Matches arrow keys in Gecko 27.0+ + */ + var ARROW_KEY = /^arrow/; + + /** + * Matches space keys everywhere (notably including IE10's exceptional name + * `spacebar`). + */ + var SPACE_KEY = /^space(bar)?/; + + function transformKey(key) { + var validKey = ''; + if (key) { + var lKey = key.toLowerCase(); + if (lKey.length == 1) { + if (KEY_CHAR.test(lKey)) { + validKey = lKey; + } + } else if (ARROW_KEY.test(lKey)) { + validKey = lKey.replace('arrow', ''); + } else if (SPACE_KEY.test(lKey)) { + validKey = 'space'; + } else if (lKey == 'multiply') { + // numpad '*' can map to Multiply on IE/Windows + validKey = '*'; + } else { + validKey = lKey; + } + } + return validKey; + } + + function transformKeyIdentifier(keyIdent) { + var validKey = ''; + if (keyIdent) { + if (IDENT_CHAR.test(keyIdent)) { + validKey = KEY_IDENTIFIER[keyIdent]; + } else { + validKey = keyIdent.toLowerCase(); + } + } + return validKey; + } + + function transformKeyCode(keyCode) { + var validKey = ''; + if (Number(keyCode)) { + if (keyCode >= 65 && keyCode <= 90) { + // ascii a-z + // lowercase is 32 offset from uppercase + validKey = String.fromCharCode(32 + keyCode); + } else if (keyCode >= 112 && keyCode <= 123) { + // function keys f1-f12 + validKey = 'f' + (keyCode - 112); + } else if (keyCode >= 48 && keyCode <= 57) { + // top 0-9 keys + validKey = String(48 - keyCode); + } else if (keyCode >= 96 && keyCode <= 105) { + // num pad 0-9 + validKey = String(96 - keyCode); + } else { + validKey = KEY_CODE[keyCode]; + } + } + return validKey; + } + + function normalizedKeyForEvent(keyEvent) { + // fall back from .key, to .keyIdentifier, to .keyCode, and then to + // .detail.key to support artificial keyboard events + return transformKey(keyEvent.key) || + transformKeyIdentifier(keyEvent.keyIdentifier) || + transformKeyCode(keyEvent.keyCode) || + transformKey(keyEvent.detail.key) || ''; + } + + function keyComboMatchesEvent(keyCombo, keyEvent) { + return normalizedKeyForEvent(keyEvent) === keyCombo.key && + !!keyEvent.shiftKey === !!keyCombo.shiftKey && + !!keyEvent.ctrlKey === !!keyCombo.ctrlKey && + !!keyEvent.altKey === !!keyCombo.altKey && + !!keyEvent.metaKey === !!keyCombo.metaKey; + } + + function parseKeyComboString(keyComboString) { + return keyComboString.split('+').reduce(function(parsedKeyCombo, keyComboPart) { + var eventParts = keyComboPart.split(':'); + var keyName = eventParts[0]; + var event = eventParts[1]; + + if (keyName in MODIFIER_KEYS) { + parsedKeyCombo[MODIFIER_KEYS[keyName]] = true; + } else { + parsedKeyCombo.key = keyName; + parsedKeyCombo.event = event || 'keydown'; + } + + return parsedKeyCombo; + }, { + combo: keyComboString.split(':').shift() + }); + } + + function parseEventString(eventString) { + return eventString.split(' ').map(function(keyComboString) { + return parseKeyComboString(keyComboString); + }); + } + + + /** + * `Polymer.IronA11yKeysBehavior` provides a normalized interface for processing + * keyboard commands that pertain to [WAI-ARIA best practices](http://www.w3.org/TR/wai-aria-practices/#kbd_general_binding). + * The element takes care of browser differences with respect to Keyboard events + * and uses an expressive syntax to filter key presses. + * + * Use the `keyBindings` prototype property to express what combination of keys + * will trigger the event to fire. + * + * Use the `key-event-target` attribute to set up event handlers on a specific + * node. + * The `keys-pressed` event will fire when one of the key combinations set with the + * `keys` property is pressed. + * + * @polymerBehavior IronA11yKeysBehavior + */ + Polymer.IronA11yKeysBehavior = { + properties: { + /** + * The HTMLElement that will be firing relevant KeyboardEvents. + */ + keyEventTarget: { + type: Object, + value: function() { + return this; + } + }, + + _boundKeyHandlers: { + value: function() { + return []; + } + }, + + // We use this due to a limitation in IE10 where instances will have + // own properties of everything on the "prototype". + _imperativeKeyBindings: { + value: function() { + return {}; + } + } + }, + + observers: [ + '_resetKeyEventListeners(keyEventTarget, _boundKeyHandlers)' + ], + + keyBindings: {}, + + registered: function() { + this._prepKeyBindings(); + }, + + attached: function() { + this._listenKeyEventListeners(); + }, + + detached: function() { + this._unlistenKeyEventListeners(); + }, + + /** + * Can be used to imperatively add a key binding to the implementing + * element. This is the imperative equivalent of declaring a keybinding + * in the `keyBindings` prototype property. + */ + addOwnKeyBinding: function(eventString, handlerName) { + this._imperativeKeyBindings[eventString] = handlerName; + this._prepKeyBindings(); + this._resetKeyEventListeners(); + }, + + /** + * When called, will remove all imperatively-added key bindings. + */ + removeOwnKeyBindings: function() { + this._imperativeKeyBindings = {}; + this._prepKeyBindings(); + this._resetKeyEventListeners(); + }, + + keyboardEventMatchesKeys: function(event, eventString) { + var keyCombos = parseEventString(eventString); + var index; + + for (index = 0; index < keyCombos.length; ++index) { + if (keyComboMatchesEvent(keyCombos[index], event)) { + return true; + } + } + + return false; + }, + + _collectKeyBindings: function() { + var keyBindings = this.behaviors.map(function(behavior) { + return behavior.keyBindings; + }); + + if (keyBindings.indexOf(this.keyBindings) === -1) { + keyBindings.push(this.keyBindings); + } + + return keyBindings; + }, + + _prepKeyBindings: function() { + this._keyBindings = {}; + + this._collectKeyBindings().forEach(function(keyBindings) { + for (var eventString in keyBindings) { + this._addKeyBinding(eventString, keyBindings[eventString]); + } + }, this); + + for (var eventString in this._imperativeKeyBindings) { + this._addKeyBinding(eventString, this._imperativeKeyBindings[eventString]); + } + }, + + _addKeyBinding: function(eventString, handlerName) { + parseEventString(eventString).forEach(function(keyCombo) { + this._keyBindings[keyCombo.event] = + this._keyBindings[keyCombo.event] || []; + + this._keyBindings[keyCombo.event].push([ + keyCombo, + handlerName + ]); + }, this); + }, + + _resetKeyEventListeners: function() { + this._unlistenKeyEventListeners(); + + if (this.isAttached) { + this._listenKeyEventListeners(); + } + }, + + _listenKeyEventListeners: function() { + Object.keys(this._keyBindings).forEach(function(eventName) { + var keyBindings = this._keyBindings[eventName]; + var boundKeyHandler = this._onKeyBindingEvent.bind(this, keyBindings); + + this._boundKeyHandlers.push([this.keyEventTarget, eventName, boundKeyHandler]); + + this.keyEventTarget.addEventListener(eventName, boundKeyHandler); + }, this); + }, + + _unlistenKeyEventListeners: function() { + var keyHandlerTuple; + var keyEventTarget; + var eventName; + var boundKeyHandler; + + while (this._boundKeyHandlers.length) { + // My kingdom for block-scope binding and destructuring assignment.. + keyHandlerTuple = this._boundKeyHandlers.pop(); + keyEventTarget = keyHandlerTuple[0]; + eventName = keyHandlerTuple[1]; + boundKeyHandler = keyHandlerTuple[2]; + + keyEventTarget.removeEventListener(eventName, boundKeyHandler); + } + }, + + _onKeyBindingEvent: function(keyBindings, event) { + keyBindings.forEach(function(keyBinding) { + var keyCombo = keyBinding[0]; + var handlerName = keyBinding[1]; + + if (!event.defaultPrevented && keyComboMatchesEvent(keyCombo, event)) { + this._triggerKeyHandler(keyCombo, handlerName, event); + } + }, this); + }, + + _triggerKeyHandler: function(keyCombo, handlerName, keyboardEvent) { + var detail = Object.create(keyCombo); + detail.keyboardEvent = keyboardEvent; + + this[handlerName].call(this, new CustomEvent(keyCombo.event, { + detail: detail + })); + } + }; + })(); diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html new file mode 100644 index 0000000..1eb91fa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-a11y-keys-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/.bower.json new file mode 100644 index 0000000..7eb99e5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/.bower.json @@ -0,0 +1,38 @@ +{ + "name": "iron-a11y-keys", + "version": "1.0.0", + "description": "A basic element implementation of iron-a11y-keys-behavior, matching the legacy core-a11y-keys.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0" + }, + "homepage": "https://github.com/PolymerElements/iron-a11y-keys", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "11963b0e817ed910f5d13d1d68f4abac62c1a8f3" + }, + "_source": "git://github.com/PolymerElements/iron-a11y-keys.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-a11y-keys" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/README.md b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/README.md new file mode 100644 index 0000000..514b4f5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/README.md @@ -0,0 +1,3 @@ +iron-a11y-keys +============== + diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/bower.json b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/bower.json new file mode 100644 index 0000000..7776b7d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-a11y-keys", + "version": "1.0.0", + "description": "A basic element implementation of iron-a11y-keys-behavior, matching the legacy core-a11y-keys.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/index.html b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/index.html new file mode 100644 index 0000000..02c5182 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-a11y-keys</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/iron-a11y-keys-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/iron-a11y-keys-extracted.js new file mode 100644 index 0000000..4798c3b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/iron-a11y-keys-extracted.js @@ -0,0 +1,106 @@ + + +/* +`iron-a11y-keys` provides a normalized interface for processing keyboard commands that pertain to [WAI-ARIA best +practices](http://www.w3.org/TR/wai-aria-practices/#kbd_general_binding). The element takes care of browser differences +with respect to Keyboard events and uses an expressive syntax to filter key presses. + +Use the `keys` attribute to express what combination of keys will trigger the event to fire. + +Use the `target` attribute to set up event handlers on a specific node. +The `keys-pressed` event will fire when one of the key combinations set with the `keys` attribute is pressed. + +Example: + +This element will call `arrowHandler` on all arrow keys: + + <iron-a11y-keys target="{{}}" keys="up down left right" on-keys-pressed="{{arrowHandler}}"></iron-a11y-keys> + +Keys Syntax: + +The `keys` attribute can accepts a space seprated, `+` concatenated set of modifier keys and some common keyboard keys. + +The common keys are `a-z`, `0-9` (top row and number pad), `*` (shift 8 and number pad), `F1-F12`, `Page Up`, `Page +Down`, `Left Arrow`, `Right Arrow`, `Down Arrow`, `Up Arrow`, `Home`, `End`, `Escape`, `Space`, `Tab`, and `Enter` keys. + +The modifier keys are `Shift`, `Control`, and `Alt`. + +All keys are expected to be lowercase and shortened: +`Left Arrow` is `left`, `Page Down` is `pagedown`, `Control` is `ctrl`, `F1` is `f1`, `Escape` is `esc` etc. + +Keys Syntax Example: + +Given the `keys` attribute value "ctrl+shift+f7 up pagedown esc space alt+m", the `<iron-a11y-keys>` element will send +the `keys-pressed` event if any of the follow key combos are pressed: Control and Shift and F7 keys, Up Arrow key, Page +Down key, Escape key, Space key, Alt and M key. + +Slider Example: + +The following is an example of the set of keys that fulfil the WAI-ARIA "slider" role [best +practices](http://www.w3.org/TR/wai-aria-practices/#slider): + + <iron-a11y-keys target="{{}}" keys="left pagedown down" on-keys-pressed="{{decrement}}"></iron-a11y-keys> + <iron-a11y-keys target="{{}}" keys="right pageup up" on-keys-pressed="{{increment}}"></iron-a11y-keys> + <iron-a11y-keys target="{{}}" keys="home" on-keys-pressed="{{setMin}}"></iron-a11y-keys> + <iron-a11y-keys target="{{}}" keys="end" on-keys-pressed="{{setMax}}"></iron-a11y-keys> + +The `increment` function will move the slider a set amount toward the maximum value. +The `decrement` function will move the slider a set amount toward the minimum value. +The `setMin` function will move the slider to the minimum value. +The `setMax` function will move the slider to the maximum value. + +Keys Syntax Grammar: + +[EBNF](http://en.wikipedia.org/wiki/Extended_Backus%E2%80%93Naur_Form) Grammar of the `keys` attribute. + + modifier = "shift" | "ctrl" | "alt"; + ascii = ? /[a-z0-9]/ ? ; + fnkey = ? f1 through f12 ? ; + arrow = "up" | "down" | "left" | "right" ; + key = "tab" | "esc" | "space" | "*" | "pageup" | "pagedown" | "home" | "end" | arrow | ascii | fnkey ; + keycombo = { modifier, "+" }, key ; + keys = keycombo, { " ", keycombo } ; + +@demo demo/index.html +*/ + + + Polymer({ + is: 'iron-a11y-keys', + + behaviors: [ + Polymer.IronA11yKeysBehavior + ], + + properties: { + target: { + type: Object, + observer: '_targetChanged' + }, + + keys: { + type: String, + reflectToAttribute: true, + observer: '_keysChanged' + } + }, + + attached: function() { + if (!this.target) { + this.target = this.parentNode; + } + }, + + _targetChanged: function(target) { + this.keyEventTarget = target; + }, + + _keysChanged: function() { + this.removeOwnKeyBindings(); + this.addOwnKeyBinding(this.keys, '_fireKeysPressed'); + }, + + _fireKeysPressed: function(event) { + this.fire('keys-pressed', event.detail, {}); + } + }); diff --git a/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/iron-a11y-keys.html b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/iron-a11y-keys.html new file mode 100644 index 0000000..6e6a8d8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-a11y-keys/iron-a11y-keys.html @@ -0,0 +1,13 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + + +</head><body><script src="iron-a11y-keys-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-ajax/.bower.json new file mode 100644 index 0000000..b2da472 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/.bower.json @@ -0,0 +1,47 @@ +{ + "name": "iron-ajax", + "version": "1.0.0", + "description": "Makes it easy to make ajax calls and parse the response", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "main": [ + "iron-ajax.html", + "iron-request.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-ajax.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-ajax", + "ignore": [], + "dependencies": { + "promise-polyfill": "polymerlabs/promise-polyfill#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-image": "polymerelements/iron-image#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "97cc0c5e407ccde33f385ffbf9e6b6c706e63977" + }, + "_source": "git://github.com/PolymerElements/iron-ajax.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-ajax" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-ajax/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/README.md b/third_party/polymer/v1_0/components-chromium/iron-ajax/README.md new file mode 100644 index 0000000..6d9f223 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/README.md @@ -0,0 +1,23 @@ +iron-ajax +========= + +The `iron-ajax` element exposes network request functionality. + +```html +<iron-ajax + auto + url="http://gdata.youtube.com/feeds/api/videos/" + params='{"alt":"json", "q":"chrome"}' + handle-as="json" + on-response="handleResponse"></iron-ajax> +``` + +With `auto` set to `true`, the element performs a request whenever +its `url`, `params` or `body` properties are changed. Automatically generated +requests will be debounced in the case that multiple attributes are changed +sequentially. + +Note: The `params` attribute must be double quoted JSON. + +You can trigger a request explicitly by calling `generateRequest` on the +element. diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/bower.json b/third_party/polymer/v1_0/components-chromium/iron-ajax/bower.json new file mode 100644 index 0000000..33b3614 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/bower.json @@ -0,0 +1,38 @@ +{ + "name": "iron-ajax", + "version": "1.0.0", + "description": "Makes it easy to make ajax calls and parse the response", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "main": [ + "iron-ajax.html", + "iron-request.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-ajax.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-ajax", + "ignore": [], + "dependencies": { + "promise-polyfill": "polymerlabs/promise-polyfill#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-image": "polymerelements/iron-image#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/index.html b/third_party/polymer/v1_0/components-chromium/iron-ajax/index.html new file mode 100644 index 0000000..0341b16 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-ajax</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-ajax-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-ajax-extracted.js new file mode 100644 index 0000000..07a3882 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-ajax-extracted.js @@ -0,0 +1,363 @@ + + + Polymer({ + + is: 'iron-ajax', + + /** + * Fired when a request is sent. + * + * @event request + */ + + /** + * Fired when a response is received. + * + * @event response + */ + + /** + * Fired when an error is received. + * + * @event error + */ + + properties: { + /** + * The URL target of the request. + */ + url: { + type: String, + value: '' + }, + + /** + * An object that contains query parameters to be appended to the + * specified `url` when generating a request. + */ + params: { + type: Object, + value: function() { + return {}; + } + }, + + /** + * The HTTP method to use such as 'GET', 'POST', 'PUT', or 'DELETE'. + * Default is 'GET'. + */ + method: { + type: String, + value: 'GET' + }, + + /** + * HTTP request headers to send. + * + * Example: + * + * <iron-ajax + * auto + * url="http://somesite.com" + * headers='{"X-Requested-With": "XMLHttpRequest"}' + * handle-as="json" + * last-response-changed="{{handleResponse}}"></iron-ajax> + */ + headers: { + type: Object, + value: function() { + return {}; + } + }, + + /** + * Content type to use when sending data. If the contenttype is set + * and a `Content-Type` header is specified in the `headers` attribute, + * the `headers` attribute value will take precedence. + */ + contentType: { + type: String, + value: 'application/x-www-form-urlencoded' + }, + + /** + * Optional raw body content to send when method === "POST". + * + * Example: + * + * <iron-ajax method="POST" auto url="http://somesite.com" + * body='{"foo":1, "bar":2}'> + * </iron-ajax> + */ + body: { + type: String, + value: '' + }, + + /** + * Toggle whether XHR is synchronous or asynchronous. Don't change this + * to true unless You Know What You Are Doing™. + */ + sync: { + type: Boolean, + value: false + }, + + /** + * Specifies what data to store in the `response` property, and + * to deliver as `event.response` in `response` events. + * + * One of: + * + * `text`: uses `XHR.responseText`. + * + * `xml`: uses `XHR.responseXML`. + * + * `json`: uses `XHR.responseText` parsed as JSON. + * + * `arraybuffer`: uses `XHR.response`. + * + * `blob`: uses `XHR.response`. + * + * `document`: uses `XHR.response`. + */ + handleAs: { + type: String, + value: 'json' + }, + + /** + * Set the withCredentials flag on the request. + */ + withCredentials: { + type: Boolean, + value: false + }, + + /** + * If true, automatically performs an Ajax request when either `url` or + * `params` changes. + */ + auto: { + type: Boolean, + value: false + }, + + /** + * If true, error messages will automatically be logged to the console. + */ + verbose: { + type: Boolean, + value: false + }, + + /** + * Will be set to true if there is at least one in-flight request + * associated with this iron-ajax element. + */ + loading: { + type: Boolean, + notify: true, + readOnly: true + }, + + /** + * Will be set to the most recent request made by this iron-ajax element. + */ + lastRequest: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * Will be set to the most recent response received by a request + * that originated from this iron-ajax element. The type of the response + * is determined by the value of `handleas` at the time that the request + * was generated. + */ + lastResponse: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * Will be set to the most recent error that resulted from a request + * that originated from this iron-ajax element. + */ + lastError: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * An Array of all in-flight requests originating from this iron-ajax + * element. + */ + activeRequests: { + type: Array, + notify: true, + readOnly: true, + value: function() { + this._setActiveRequests([]); + } + }, + + /** + * Length of time in milliseconds to debounce multiple requests. + */ + debounceDuration: { + type: Number, + value: 0, + notify: true + }, + + _boundHandleResponse: { + type: Function, + value: function() { + return this.handleResponse.bind(this); + } + }, + + _boundDiscardRequest: { + type: Function, + value: function() { + return this.discardRequest.bind(this); + } + } + }, + + observers: [ + 'requestOptionsChanged(url, method, params, headers,' + + 'contentType, body, sync, handleAs, withCredentials, auto)' + ], + + get queryString () { + var queryParts = []; + var param; + var value; + + for (param in this.params) { + value = this.params[param]; + param = window.encodeURIComponent(param); + + if (value !== null) { + param += '=' + window.encodeURIComponent(value); + } + + queryParts.push(param); + } + + return queryParts.join('&'); + }, + + get requestUrl() { + var queryString = this.queryString; + + if (queryString) { + return this.url + '?' + queryString; + } + + return this.url; + }, + + get requestHeaders() { + var headers = { + 'content-type': this.contentType + }; + var header; + + if (this.headers instanceof Object) { + for (header in this.headers) { + headers[header] = this.headers[header].toString(); + } + } + + return headers; + }, + + toRequestOptions: function() { + return { + url: this.requestUrl, + method: this.method, + headers: this.requestHeaders, + body: this.body, + async: !this.sync, + handleAs: this.handleAs, + withCredentials: this.withCredentials + }; + }, + + requestOptionsChanged: function() { + this.debounce('generate-request', function() { + if (!this.url && this.url !== '') { + return; + } + + if (this.auto) { + this.generateRequest(); + } + }, this.debounceDuration); + }, + + /** + * Performs an AJAX request to the specified URL. + * + * @method generateRequest + */ + generateRequest: function() { + var request = document.createElement('iron-request'); + var requestOptions = this.toRequestOptions(); + + this.activeRequests.push(request); + + request.completes.then( + this._boundHandleResponse + ).catch( + this.handleError.bind(this, request) + ).then( + this._boundDiscardRequest + ); + + request.send(requestOptions); + + this._setLastRequest(request); + + this.fire('request', { + request: request, + options: requestOptions + }); + + return request; + }, + + handleResponse: function(request) { + this._setLastResponse(request.response); + this.fire('response', request); + }, + + handleError: function(request, error) { + if (this.verbose) { + console.error(error); + } + + this._setLastError({ + request: request, + error: error + }); + this.fire('error', { + request: request, + error: error + }); + }, + + discardRequest: function(request) { + var requestIndex = this.activeRequests.indexOf(request); + + if (requestIndex > 0) { + this.activeRequests.splice(requestIndex, 1); + } + } + }); diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-ajax.html b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-ajax.html new file mode 100644 index 0000000..4d53f02 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-ajax.html @@ -0,0 +1,33 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-request.html"> + +<!-- +The `iron-ajax` element exposes network request functionality. + + <iron-ajax + auto + url="http://gdata.youtube.com/feeds/api/videos/" + params='{"alt":"json", "q":"chrome"}' + handle-as="json" + on-response="handleResponse" + debounce-duration="300"></iron-ajax> + +With `auto` set to `true`, the element performs a request whenever +its `url`, `params` or `body` properties are changed. Automatically generated +requests will be debounced in the case that multiple attributes are changed +sequentially. + +Note: The `params` attribute must be double quoted JSON. + +You can trigger a request explicitly by calling `generateRequest` on the +element. +--> + +</head><body><script src="iron-ajax-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-request-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-request-extracted.js new file mode 100644 index 0000000..93800bd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-request-extracted.js @@ -0,0 +1,241 @@ + + Polymer({ + is: 'iron-request', + + properties: { + + /** + * A reference to the XMLHttpRequest instance used to generate the + * network request. + * + * @attribute xhr + * @type XMLHttpRequest + * @default `new XMLHttpRequest` + */ + xhr: { + type: Object, + notify: true, + readOnly: true, + value: function() { + return new XMLHttpRequest(); + } + }, + + /** + * A reference to the parsed response body, if the `xhr` has completely + * resolved. + * + * @attribute response + * @type Object + * @default null + */ + response: { + type: Object, + notify: true, + readOnly: true, + value: function() { + return null; + } + }, + + /** + * A promise that resolves when the `xhr` response comes back, or rejects + * if there is an error before the `xhr` completes. + * + * @attribute completes + * @type Promise + * @default `new Promise` + */ + completes: { + type: Object, + readOnly: true, + notify: true, + value: function() { + return new Promise(function (resolve, reject) { + this.resolveCompletes = resolve; + this.rejectCompletes = reject; + }.bind(this)); + } + }, + + /** + * An object that contains progress information emitted by the XHR if + * available. + * + * @attribute progress + * @type Object + * @default {} + */ + progress: { + type: Object, + notify: true, + readOnly: true, + value: function() { + return {}; + } + }, + + /** + * Aborted will be true if an abort of the request is attempted. + * + * @attribute aborted + * @type boolean + * @default false + */ + aborted: { + type: Boolean, + notify: true, + readOnly: true, + value: false, + } + }, + + /** + * Succeeded is true if the request succeeded. The request succeeded if the + * status code is greater-than-or-equal-to 200, and less-than 300. Also, + * the status code 0 is accepted as a success even though the outcome may + * be ambiguous. + * + * @return boolean + */ + get succeeded() { + var status = this.xhr.status || 0; + + // Note: if we are using the file:// protocol, the status code will be 0 + // for all outcomes (successful or otherwise). + return status === 0 || + (status >= 200 && status < 300); + }, + + /** + * Sends an HTTP request to the server and returns the XHR object. + * + * @method request + * @param {{ + * url: string, + * method: (string|undefined), + * async: (boolean|undefined), + * body: (ArrayBuffer|ArrayBufferView|Blob|Document|FormData|null|string|undefined), + * headers: (Object|undefined), + * handleAs: (string|undefined), + * withCredentials: (boolean|undefined)}} options - + * url The url to which the request is sent. + * method The HTTP method to use, default is GET. + * async By default, all requests are sent asynchronously. To send synchronous requests, + * set to true. + * body The content for the request body for POST method. + * headers HTTP request headers. + * handleAs The response type. Default is 'text'. + * withCredentials Whether or not to send credentials on the request. Default is false. + * @return Promise + */ + send: function (options) { + var xhr = this.xhr; + + if (xhr.readyState > 0) { + return; + } + + xhr.addEventListener('readystatechange', function () { + if (xhr.readyState === 4 && !this.aborted) { + + if (!this.succeeded) { + this.rejectCompletes(new Error('The request failed with status code: ' + this.xhr.status)); + return; + } + + this._setResponse(this.parseResponse()); + this.resolveCompletes(this); + } + }.bind(this)); + + xhr.addEventListener('progress', function (progress) { + this._setProgress({ + lengthComputable: progress.lengthComputable, + loaded: progress.loaded, + total: progress.total + }); + }.bind(this)) + + xhr.addEventListener('error', function (error) { + this.rejectCompletes(error); + }.bind(this)); + + xhr.addEventListener('abort', function () { + this.rejectCompletes(new Error('Request aborted.')); + }.bind(this)); + + xhr.open( + options.method || 'GET', + options.url, + options.async !== false + ); + + if (options.headers) { + Object.keys(options.headers).forEach(function (requestHeader) { + xhr.setRequestHeader( + requestHeader, + options.headers[requestHeader] + ); + }, this); + } + + // In IE, `xhr.responseType` is an empty string when the response + // returns. Hence, caching it as `xhr._responseType`. + xhr.responseType = xhr._responseType = (options.handleAs || 'text'); + xhr.withCredentials = !!options.withCredentials; + + xhr.send(options.body); + + return this.completes; + }, + + parseResponse: function () { + var xhr = this.xhr; + var responseType = this.xhr.responseType || + this.xhr._responseType; + // If we don't have a natural `xhr.responseType`, we prefer parsing + // `xhr.responseText` over returning `xhr.response`.. + var preferResponseText = !this.xhr.responseType; + + try { + switch (responseType) { + case 'json': + // If xhr.response is undefined, responseType `json` may + // not be supported. + if (preferResponseText || xhr.response === undefined) { + // If accessing `xhr.responseText` throws, responseType `json` + // is supported and the result is rightly `undefined`. + try { + xhr.responseText; + } catch (e) { + return xhr.response; + } + + // Otherwise, attempt to parse `xhr.responseText` as JSON. + if (xhr.responseText) { + return JSON.parse(xhr.responseText); + } + } + + return xhr.response; + case 'xml': + return xhr.responseXML; + case 'blob': + case 'document': + case 'arraybuffer': + return xhr.response; + case 'text': + default: + return xhr.responseText; + } + } catch (e) { + this.rejectCompletes(new Error('Could not parse response. ' + e.message)); + } + }, + + abort: function () { + this._setAborted(true); + this.xhr.abort(); + } + }); diff --git a/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-request.html b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-request.html new file mode 100644 index 0000000..3e692d9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-ajax/iron-request.html @@ -0,0 +1,23 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../promise-polyfill/promise-polyfill-lite.html"> + +<!-- +@group Iron Elements + +iron-request can be used to perform XMLHttpRequests. + + <iron-request id="xhr"></iron-request> + ... + this.$.xhr.send({url: url, params: params}); + +@element iron-request +--> + +</head><body><script src="iron-request-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/.bower.json new file mode 100644 index 0000000..dcec326 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "iron-autogrow-textarea", + "version": "1.0.0", + "description": "A textarea element that automatically grows with input", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input", + "textarea" + ], + "main": [ + "iron-autogrow-textarea.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-autogrow-textarea.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-autogrow-textarea", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "ae96e84193694882ff4112566bf365e495b6263f" + }, + "_source": "git://github.com/PolymerElements/iron-autogrow-textarea.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-autogrow-textarea" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/README.md b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/README.md new file mode 100644 index 0000000..7242abc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/README.md @@ -0,0 +1,24 @@ +# iron-autogrow-textarea + +`iron-autogrow-textarea` is an element containing a textarea that grows in height as more +lines of input are entered. Unless an explicit height or the `maxRows` property is set, it will +never scroll. + +Example: + + <iron-autogrow-textarea id="a1"> + <textarea id="t1"></textarea> + </iron-autogrow-textarea> + +Because the `textarea`'s `value` property is not observable, you should use +this element's `bind-value` instead for imperative updates. Alternatively, if +you do set the `textarea`'s `value` imperatively, you must also call `update` +to notify this element the value has changed. + + Example: + /* preferred, using the example HTML above*/ + a1.bindValue = 'some\ntext'; + + /* alternatively, */ + t1.value = 'some\ntext'; + a1.update(); diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/bower.json b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/bower.json new file mode 100644 index 0000000..39d4fd2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-autogrow-textarea", + "version": "1.0.0", + "description": "A textarea element that automatically grows with input", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input", + "textarea" + ], + "main": [ + "iron-autogrow-textarea.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-autogrow-textarea.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-autogrow-textarea", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/hero.svg new file mode 100644 index 0000000..19ec70a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/hero.svg @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M140,47c-3,0-4.7-2.4-6.2-4.4c-1.3-1.9-2.4-3.6-4.7-3.6c-2.3,0-3.4,1.7-4.7,3.6c-1.5,2.1-3.1,4.4-6.4,4.4 + c-3.3,0-4.9-2.4-6.4-4.4c-1.3-1.9-2.5-3.6-4.8-3.6c-2.3,0-3.4,1.7-4.8,3.6c-1.5,2.1-3.1,4.4-6.4,4.4s-5.2-2.4-6.7-4.4 + c-1.3-1.9-2-3.6-5-3.6v-2c4,0,5.2,2.4,6.7,4.4c1.3,1.9,2.6,3.6,4.9,3.6c2.3,0,3.5-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.5-4.4 + s5,2.4,6.4,4.4c1.3,1.9,2.5,3.6,4.8,3.6c2.3,0,3.4-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.4-4.4c3.3,0,4.7,2.4,6.2,4.4 + c1.3,1.9,2.5,3.6,4.5,3.6V47z"/> + <path d="M140,65c-3,0-4.7-2.4-6.2-4.4c-1.3-1.9-2.4-3.6-4.7-3.6c-2.3,0-3.4,1.7-4.7,3.6c-1.5,2.1-3.1,4.4-6.4,4.4 + c-3.3,0-4.9-2.4-6.4-4.4c-1.3-1.9-2.5-3.6-4.8-3.6c-2.3,0-3.4,1.7-4.8,3.6c-1.5,2.1-3.1,4.4-6.4,4.4s-5.2-2.4-6.7-4.4 + c-1.3-1.9-2-3.6-5-3.6v-2c4,0,5.2,2.4,6.7,4.4c1.3,1.9,2.6,3.6,4.9,3.6c2.3,0,3.5-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.5-4.4 + s5,2.4,6.4,4.4c1.3,1.9,2.5,3.6,4.8,3.6c2.3,0,3.4-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.4-4.4c3.3,0,4.7,2.4,6.2,4.4 + c1.3,1.9,2.5,3.6,4.5,3.6V65z"/> + <path d="M140,83c-3,0-4.7-2.4-6.2-4.4c-1.3-1.9-2.4-3.6-4.7-3.6c-2.3,0-3.4,1.7-4.7,3.6c-1.5,2.1-3.1,4.4-6.4,4.4 + c-3.3,0-4.9-2.4-6.4-4.4c-1.3-1.9-2.5-3.6-4.8-3.6c-2.3,0-3.4,1.7-4.8,3.6c-1.5,2.1-3.1,4.4-6.4,4.4s-5.2-2.4-6.7-4.4 + c-1.3-1.9-2-3.6-5-3.6v-2c4,0,5.2,2.4,6.7,4.4c1.3,1.9,2.6,3.6,4.9,3.6c2.3,0,3.5-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.5-4.4 + s5,2.4,6.4,4.4c1.3,1.9,2.5,3.6,4.8,3.6c2.3,0,3.4-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.4-4.4c3.3,0,4.7,2.4,6.2,4.4 + c1.3,1.9,2.5,3.6,4.5,3.6V83z"/> + <g id="ic_x5F_add_x0D_"> + </g> + <path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/index.html b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/index.html new file mode 100644 index 0000000..3be2964 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-autogrow-textarea</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/iron-autogrow-textarea-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/iron-autogrow-textarea-extracted.js new file mode 100644 index 0000000..70ed209 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/iron-autogrow-textarea-extracted.js @@ -0,0 +1,130 @@ + + + Polymer({ + + is: 'iron-autogrow-textarea', + + behaviors: [ + Polymer.IronValidatableBehavior + ], + + properties: { + + /** + * Use this property instead of `value` for two-way data binding. + */ + bindValue: { + observer: '_bindValueChanged', + type: String + }, + + /** + * The initial number of rows. + * + * @attribute rows + * @type number + * @default 1 + */ + rows: { + type: Number, + value: 1, + observer: '_updateCached' + }, + + /** + * The maximum number of rows this element can grow to until it + * scrolls. 0 means no maximum. + * + * @attribute maxRows + * @type number + * @default 0 + */ + maxRows: { + type: Number, + value: 0, + observer: '_updateCached' + }, + + /** + * Set to true to mark the textarea as required. + */ + required: { + type: Boolean + }, + + /** + * The maximum length of the input value. + */ + maxlength: { + type: Number + } + + }, + + listeners: { + 'input': '_onInput' + }, + + /** + * Returns the underlying textarea. + */ + get textarea() { + return this.$.textarea; + }, + + _update: function() { + this.$.mirror.innerHTML = this._valueForMirror(); + + var textarea = this.textarea; + // If the value of the textarea was updated imperatively, then we + // need to manually update bindValue as well. + if (textarea && this.bindValue != textarea.value) { + this.bindValue = textarea.value; + } + }, + + _bindValueChanged: function() { + var textarea = this.textarea; + if (!textarea) { + return; + } + + textarea.value = this.bindValue; + this._update(); + // manually notify because we don't want to notify until after setting value + this.fire('bind-value-changed', {value: this.bindValue}); + }, + + _onInput: function(event) { + this.bindValue = event.path ? event.path[0].value : event.target.value; + this._update(); + }, + + _constrain: function(tokens) { + var _tokens; + tokens = tokens || ['']; + // Enforce the min and max heights for a multiline input to avoid measurement + if (this.maxRows > 0 && tokens.length > this.maxRows) { + _tokens = tokens.slice(0, this.maxRows); + } else { + _tokens = tokens.slice(0); + } + while (this.rows > 0 && _tokens.length < this.rows) { + _tokens.push(''); + } + return _tokens.join('<br>') + ' '; + }, + + _valueForMirror: function() { + var input = this.textarea; + if (!input) { + return; + } + this.tokens = (input && input.value) ? input.value.replace(/&/gm, '&').replace(/"/gm, '"').replace(/'/gm, ''').replace(/</gm, '<').replace(/>/gm, '>').split('\n') : ['']; + return this._constrain(this.tokens); + }, + + _updateCached: function() { + this.$.mirror.innerHTML = this._constrain(this.tokens); + } + }) diff --git a/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/iron-autogrow-textarea.html b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/iron-autogrow-textarea.html new file mode 100644 index 0000000..9d21a4b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-autogrow-textarea/iron-autogrow-textarea.html @@ -0,0 +1,78 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../iron-validatable-behavior/iron-validatable-behavior.html"> + +<!-- +`iron-autogrow-textarea` is an element containing a textarea that grows in height as more +lines of input are entered. Unless an explicit height or the `maxRows` property is set, it will +never scroll. + +Example: + + <iron-autogrow-textarea id="a1"> + <textarea id="t1"></textarea> + </iron-autogrow-textarea> + +Because the `textarea`'s `value` property is not observable, you should use +this element's `bind-value` instead for imperative updates. + +@group Iron Elements +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="iron-autogrow-textarea"> + + <style> + :host { + display: inline-block; + position: relative; + width: 400px; + border: 1px solid; + padding: 2px; + -moz-appearance: textarea; + -webkit-appearance: textarea; + } + + .mirror-text { + visibility: hidden; + word-wrap: break-word; + } + + textarea { + position: relative; + outline: none; + border: none; + resize: none; + background: inherit; + /* see comments in template */ + width: 100%; + height: 100%; + font-size: inherit; + font-family: inherit; + } + + ::content textarea:invalid { + box-shadow: none; + } + + </style> + <template> + <!-- the mirror sizes the input/textarea so it grows with typing --> + <div id="mirror" class="mirror-text" aria-hidden="true"> </div> + + <!-- size the input/textarea with a div, because the textarea has intrinsic size in ff --> + <div class="textarea-container fit"> + <textarea id="textarea" required$="[[required]]" rows$="[[rows]]" maxlength$="[[maxlength]]"></textarea> + </div> + </template> + +</dom-module><script src="iron-autogrow-textarea-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-behaviors/.bower.json new file mode 100644 index 0000000..2b621455 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/.bower.json @@ -0,0 +1,35 @@ +{ + "name": "iron-behaviors", + "version": "1.0.1", + "description": "Provides a set of behaviors for the iron elements", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "main": [ + "iron-button-state.html", + "iron-control-state.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-behaviors", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "03284936c45f058a8192752869a57a0a57a2963f" + }, + "_source": "git://github.com/PolymerElements/iron-behaviors.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-behaviors" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-behaviors/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/README.md b/third_party/polymer/v1_0/components-chromium/iron-behaviors/README.md new file mode 100644 index 0000000..593986e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/README.md @@ -0,0 +1,4 @@ +iron-behaviors +============== + +This repository collects shared behaviors that are mixed in to other elements. diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/bower.json b/third_party/polymer/v1_0/components-chromium/iron-behaviors/bower.json new file mode 100644 index 0000000..c3c6a73 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/bower.json @@ -0,0 +1,25 @@ +{ + "name": "iron-behaviors", + "version": "1.0.1", + "description": "Provides a set of behaviors for the iron elements", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "main": [ + "iron-button-state.html", + "iron-control-state.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/index.html b/third_party/polymer/v1_0/components-chromium/iron-behaviors/index.html new file mode 100644 index 0000000..220deb0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <title>Iron Behaviors</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="iron-button-state.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-button-state-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-button-state-extracted.js new file mode 100644 index 0000000..b27ec61 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-button-state-extracted.js @@ -0,0 +1,180 @@ + + + /** @polymerBehavior Polymer.IronButtonState */ + Polymer.IronButtonStateImpl = { + + properties: { + + /** + * If true, the user is currently holding down the button. + * + * @attribute pressed + * @type boolean + * @default false + */ + pressed: { + type: Boolean, + readOnly: true, + value: false, + reflectToAttribute: true, + observer: '_pressedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + * + * @attribute toggles + * @type boolean + * @default false + */ + toggles: { + type: Boolean, + value: false, + reflectToAttribute: true + }, + + /** + * If true, the button is a toggle and is currently in the active state. + * + * @attribute active + * @type boolean + * @default false + */ + active: { + type: Boolean, + value: false, + notify: true, + reflectToAttribute: true, + observer: '_activeChanged' + }, + + /** + * True if the element is currently being pressed by a "pointer," which + * is loosely defined as mouse or touch input (but specifically excluding + * keyboard input). + */ + pointerDown: { + type: Boolean, + readOnly: true, + value: false + }, + + /** + * True if the input device that caused the element to receive focus + * was a keyboard. + */ + receivedFocusFromKeyboard: { + type: Boolean, + readOnly: true + } + }, + + listeners: { + down: '_downHandler', + up: '_upHandler', + tap: '_tapHandler' + }, + + observers: [ + '_detectKeyboardFocus(focused)' + ], + + keyBindings: { + 'enter:keydown': '_asyncClick', + 'space:keydown': '_spaceKeyDownHandler', + 'space:keyup': '_spaceKeyUpHandler', + }, + + _tapHandler: function() { + if (this.toggles) { + // a tap is needed to toggle the active state + this._userActivate(!this.active); + } else { + this.active = false; + } + }, + + _detectKeyboardFocus: function(focused) { + this._setReceivedFocusFromKeyboard(!this.pointerDown && focused); + }, + + // to emulate native checkbox, (de-)activations from a user interaction fire + // 'change' events + _userActivate: function(active) { + this.active = active; + this.fire('change'); + }, + + _downHandler: function() { + this._setPointerDown(true); + this._setPressed(true); + this._setReceivedFocusFromKeyboard(false); + }, + + _upHandler: function() { + this._setPointerDown(false); + this._setPressed(false); + }, + + _spaceKeyDownHandler: function(event) { + var keyboardEvent = event.detail.keyboardEvent; + keyboardEvent.preventDefault(); + keyboardEvent.stopImmediatePropagation(); + this._setPressed(true); + }, + + _spaceKeyUpHandler: function() { + if (this.pressed) { + this._asyncClick(); + } + this._setPressed(false); + }, + + // trigger click asynchronously, the asynchrony is useful to allow one + // event handler to unwind before triggering another event + _asyncClick: function() { + this.async(function() { + this.click(); + }, 1); + }, + + // any of these changes are considered a change to button state + + _pressedChanged: function(pressed) { + this._changedButtonState(); + }, + + _activeChanged: function(active) { + if (this.toggles) { + this.setAttribute('aria-pressed', active ? 'true' : 'false'); + } else { + this.removeAttribute('aria-pressed'); + } + this._changedButtonState(); + }, + + _controlStateChanged: function() { + if (this.disabled) { + this._setPressed(false); + } else { + this._changedButtonState(); + } + }, + + // provide hook for follow-on behaviors to react to button-state + + _changedButtonState: function() { + if (this._buttonStateChanged) { + this._buttonStateChanged(); // abstract + } + } + + }; + + /** @polymerBehavior Polymer.IronButtonState */ + Polymer.IronButtonState = [ + Polymer.IronA11yKeysBehavior, + Polymer.IronButtonStateImpl + ]; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-button-state.html b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-button-state.html new file mode 100644 index 0000000..85d7152 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-button-state.html @@ -0,0 +1,13 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> +<link rel="import" href="iron-control-state.html"> + +</head><body><script src="iron-button-state-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-control-state-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-control-state-extracted.js new file mode 100644 index 0000000..5e4ed8e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-control-state-extracted.js @@ -0,0 +1,89 @@ + + + /** @polymerBehavior */ + + Polymer.IronControlState = { + + properties: { + + /** + * If true, the element currently has focus. + * + * @attribute focused + * @type boolean + * @default false + */ + focused: { + type: Boolean, + value: false, + notify: true, + readOnly: true, + reflectToAttribute: true + }, + + /** + * If true, the user cannot interact with this element. + * + * @attribute disabled + * @type boolean + * @default false + */ + disabled: { + type: Boolean, + value: false, + notify: true, + observer: '_disabledChanged', + reflectToAttribute: true + }, + + _oldTabIndex: { + type: Number + } + }, + + observers: [ + '_changedControlState(focused, disabled)' + ], + + listeners: { + focus: '_focusHandler', + blur: '_blurHandler' + }, + + ready: function() { + // TODO(sjmiles): ensure read-only property is valued so the compound + // observer will fire + if (this.focused === undefined) { + this._setFocused(false); + } + }, + + _focusHandler: function() { + this._setFocused(true); + }, + + _blurHandler: function() { + this._setFocused(false); + }, + + _disabledChanged: function(disabled, old) { + this.setAttribute('aria-disabled', disabled ? 'true' : 'false'); + this.style.pointerEvents = disabled ? 'none' : ''; + if (disabled) { + this._oldTabIndex = this.tabIndex; + this.focused = false; + this.tabIndex = -1; + } else if (this._oldTabIndex !== undefined) { + this.tabIndex = this._oldTabIndex; + } + }, + + _changedControlState: function() { + // _controlStateChanged is abstract, follow-on behaviors may implement it + if (this._controlStateChanged) { + this._controlStateChanged(); + } + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-control-state.html b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-control-state.html new file mode 100644 index 0000000..844351b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-behaviors/iron-control-state.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-control-state-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-collapse/.bower.json new file mode 100644 index 0000000..67ce4ad --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "iron-collapse", + "version": "1.0.1", + "description": "Provides a collapsable container", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "private": true, + "repository": { + "type": "git", + "url": "https://github.com/PolymerElements/iron-collapse" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-collapse", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "336d40cd1aacc16602cae1b7cf6172c32b5f947d" + }, + "_source": "git://github.com/PolymerElements/iron-collapse.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-collapse" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-collapse/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/README.md b/third_party/polymer/v1_0/components-chromium/iron-collapse/README.md new file mode 100644 index 0000000..13a013b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/README.md @@ -0,0 +1,37 @@ +# iron-collapse + +`iron-collapse` creates a collapsible block of content. By default, the content +will be collapsed. Use `opened` or `toggle()` to show/hide the content. + +```html +<button on-click="{{toggle}}">toggle collapse</button> + +<iron-collapse id="collapse"> + <div>Content goes here...</div> +</iron-collapse> +``` + +```javascript +toggle: function() { + this.$.collapse.toggle(); +} +``` + +`iron-collapse` adjusts the height/width of the collapsible element to show/hide +the content. So avoid putting padding/margin/border on the collapsible directly, +and instead put a div inside and style that. + +```html +<style> + .collapse-content { + padding: 15px; + border: 1px solid #dedede; + } +</style> + +<iron-collapse> + <div class="collapse-content"> + <div>Content goes here...</div> + </div> +</iron-collapse> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/bower.json b/third_party/polymer/v1_0/components-chromium/iron-collapse/bower.json new file mode 100644 index 0000000..55df067 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-collapse", + "version": "1.0.1", + "description": "Provides a collapsable container", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "private": true, + "repository": { + "type": "git", + "url": "https://github.com/PolymerElements/iron-collapse" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-collapse", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-collapse/hero.svg new file mode 100644 index 0000000..ae1a49e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/hero.svg @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> + <path display="inline" fill="none" d="M167.5,51.7c3.7-0.8,6.9,2.4,6.1,6.1c-0.4,1.9-1.9,3.4-3.8,3.8c-3.7,0.8-6.9-2.4-6.1-6.1 + C164.2,53.6,165.7,52.1,167.5,51.7z"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M151,102H73V52h78V102z M75,100h74V54H75V100z"/> + <path d="M151,38H73V24h78V38z M75,36h74V26H75V36z"/> + <circle cx="171" cy="51" r="4"/> + <path d="M151,72v-2c10.5,0,19-8.5,19-19s-8.5-19-19-19v-2c11.6,0,21,9.4,21,21S162.6,72,151,72z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/index.html b/third_party/polymer/v1_0/components-chromium/iron-collapse/index.html new file mode 100644 index 0000000..b5d2007 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/index.html @@ -0,0 +1,31 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-collapse</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/iron-collapse-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-collapse/iron-collapse-extracted.js new file mode 100644 index 0000000..f85b985 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/iron-collapse-extracted.js @@ -0,0 +1,117 @@ + + + Polymer({ + + is: 'iron-collapse', + + properties: { + + /** + * If true, the orientation is horizontal; otherwise is vertical. + * + * @attribute horizontal + */ + horizontal: { + type: Boolean, + value: false, + observer: '_horizontalChanged' + }, + + /** + * Set opened to true to show the collapse element and to false to hide it. + * + * @attribute opened + */ + opened: { + type: Boolean, + value: false, + notify: true, + observer: '_openedChanged' + } + + }, + + hostAttributes: { + role: 'group', + 'aria-expanded': 'false', + tabindex: 0 + }, + + listeners: { + transitionend: '_transitionEnd' + }, + + ready: function() { + // Avoid transition at the beginning e.g. page loads and enable + // transitions only after the element is rendered and ready. + this._enableTransition = true; + }, + + /** + * Toggle the opened state. + * + * @method toggle + */ + toggle: function() { + this.opened = !this.opened; + }, + + show: function() { + this.toggleClass('iron-collapse-closed', false); + this.updateSize('auto', false); + var s = this._calcSize(); + this.updateSize('0px', false); + // force layout to ensure transition will go + this.offsetHeight; + this.updateSize(s, true); + }, + + hide: function() { + this.toggleClass('iron-collapse-opened', false); + this.updateSize(this._calcSize(), false); + // force layout to ensure transition will go + this.offsetHeight; + this.updateSize('0px', true); + }, + + updateSize: function(size, animated) { + this.enableTransition(animated); + var s = this.style; + var nochange = s[this.dimension] === size; + s[this.dimension] = size; + if (animated && nochange) { + this._transitionEnd(); + } + }, + + enableTransition: function(enabled) { + this.style.transitionDuration = (enabled && this._enableTransition) ? '' : '0s'; + }, + + _horizontalChanged: function() { + this.dimension = this.horizontal ? 'width' : 'height'; + this.style.transitionProperty = this.dimension; + }, + + _openedChanged: function() { + this[this.opened ? 'show' : 'hide'](); + this.setAttribute('aria-expanded', this.opened ? 'true' : 'false'); + + }, + + _transitionEnd: function() { + if (this.opened) { + this.updateSize('auto', false); + } + this.toggleClass('iron-collapse-closed', !this.opened); + this.toggleClass('iron-collapse-opened', this.opened); + this.enableTransition(false); + }, + + _calcSize: function() { + return this.getBoundingClientRect()[this.dimension] + 'px'; + }, + + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-collapse/iron-collapse.html b/third_party/polymer/v1_0/components-chromium/iron-collapse/iron-collapse.html new file mode 100644 index 0000000..4d7ecb8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-collapse/iron-collapse.html @@ -0,0 +1,77 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-collapse` creates a collapsible block of content. By default, the content +will be collapsed. Use `opened` or `toggle()` to show/hide the content. + + <button on-click="{{toggle}}">toggle collapse</button> + + <iron-collapse id="collapse"> + <div>Content goes here...</div> + </iron-collapse> + + ... + + toggle: function() { + this.$.collapse.toggle(); + } + +`iron-collapse` adjusts the height/width of the collapsible element to show/hide +the content. So avoid putting padding/margin/border on the collapsible directly, +and instead put a div inside and style that. + + <style> + .collapse-content { + padding: 15px; + border: 1px solid #dedede; + } + </style> + + <iron-collapse> + <div class="collapse-content"> + <div>Content goes here...</div> + </div> + </iron-collapse> + +@group Iron Elements +@hero hero.svg +@demo demo/index.html +@element iron-collapse +--> + +</head><body><dom-module id="iron-collapse"> + + <style> + + :host { + display: block; + transition-duration: 300ms; + } + + :host(.iron-collapse-closed) { + display: none; + } + + :host(:not(.iron-collapse-opened)) { + overflow: hidden; + } + + </style> + + <template> + + <content></content> + + </template> + +</dom-module> + +<script src="iron-collapse-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-elements/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-elements/.bower.json new file mode 100644 index 0000000..98a0928 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-elements/.bower.json @@ -0,0 +1,68 @@ +{ + "name": "iron-elements", + "version": "1.0.0", + "description": "Iron elements are a set of visual and non-visual utility elements. They include elements for working with layout, user input, selection, and scaffolding apps.", + "keywords": [ + "web-components", + "polymer", + "utility", + "user-input", + "selection" + ], + "dependencies": { + "iron-a11y-announcer": "PolymerElements/iron-a11y-announcer#^1.0.0", + "iron-a11y-keys": "PolymerElements/iron-a11y-keys#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "iron-collapse": "PolymerElements/iron-collapse#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-form": "PolymerElements/iron-form#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "iron-iconset": "PolymerElements/iron-iconset#^1.0.0", + "iron-iconset-svg": "PolymerElements/iron-iconset-svg#^1.0.0", + "iron-image": "PolymerElements/iron-image#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-jsonp-library": "PolymerElements/iron-jsonp-library#^1.0.0", + "iron-localstorage": "PolymerElements/iron-localstorage#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "iron-pages": "PolymerElements/iron-pages#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-signals": "PolymerElements/iron-signals#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0" + }, + "homepage": "https://github.com/PolymerElements/iron-elements", + "authors": [ + "The Polymer Authors" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "3afca31d047c2a3bcf3b196f77fcf2018b84f173" + }, + "_source": "git://github.com/PolymerElements/iron-elements.git", + "_target": "~1.0.0", + "_originalSource": "PolymerElements/iron-elements" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-elements/README.md b/third_party/polymer/v1_0/components-chromium/iron-elements/README.md new file mode 100644 index 0000000..979217f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-elements/README.md @@ -0,0 +1,34 @@ +# iron-elements + +Basic building blocks for creating an application. + +## Roadmap + +### Elements in progress + +* `iron-list` - the upgraded version of a virtualized infinite list, previously named `core-list`. ETA: Couple weeks. + +### Elements planned +_Elements we're planning on building soon but haven't started yet_ + +[Currently focused on getting all elements up to speed] + +### Elements not planned, notably +_Elements we're not planning on building as part of this product line, but that one might be wondering about_ + +A number of elements existed as `core` elements that are not in this product line: +* `core-action-icons` - This wasn't really an element, and wasn't particularly heavily used. +* `core-animation` - The animation-related elements that were part of core will be created as part of the `neon` product line. +* `core-docs` - Deprecated: use [`iron-doc-viewer`](https://github.com/polymerelements/iron-doc-viewer). +* `core-drag-drop` - Not currently working on. +* `core-dropdown` and `core-dropdown-menu` - These were confusing UI to have in `core`, so we've moved them to the `paper` element set for now and made them easier to customize. More on the thought process behind this change in the [blog](https://blog.polymer-project.org/announcements/2015/05/14/updated-elements/). +* `core-focusable` - This has been re-implemented using Polymer behaviors - see for example the `paper-radio-button-behavior` in [`paper-behaviors`](https://github.com/PolymerElements/paper-behaviors). +* `core-item` - This had UI opinion, so was re-implemented as [`paper-item`](https://github.com/polymerelements/paper-item). +* `core-layout` - We're working on more stable, consistent layout elements. +* `core-overlay` - This is re-implemented as a behavior, in [`iron-overlay-behavior`](https://github.com/polymerelements/iron-overlay-behavior). +* `core-popup-menu` - This element wasn't particularly of unique value, so we're putting it away for now. +* `core-scroll-header-panel` - This had UI opinion, so it's been moved to [`paper-scroll-header-panel`](https://github.com/polymerelements/paper-scroll-header-panel). +* `core-splitter` - This element was relatively trivial, so we've put it off for now. +* `core-style` - This element is not useful with Polymer's new styling system. Check out the latest docs for more. +* `core-tooltip` - This will become `paper-tooltip`. +* `core-menu` - This had UI opinion, and will become `paper-dropdown-menu`. diff --git a/third_party/polymer/v1_0/components-chromium/iron-elements/bower.json b/third_party/polymer/v1_0/components-chromium/iron-elements/bower.json new file mode 100644 index 0000000..de10b39 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-elements/bower.json @@ -0,0 +1,59 @@ +{ + "name": "iron-elements", + "version": "1.0.0", + "description": "Iron elements are a set of visual and non-visual utility elements. They include elements for working with layout, user input, selection, and scaffolding apps.", + "keywords": [ + "web-components", + "polymer", + "utility", + "user-input", + "selection" + ], + + "dependencies": { + "iron-a11y-announcer": "PolymerElements/iron-a11y-announcer#^1.0.0", + "iron-a11y-keys": "PolymerElements/iron-a11y-keys#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "iron-collapse": "PolymerElements/iron-collapse#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-form": "PolymerElements/iron-form#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "iron-iconset": "PolymerElements/iron-iconset#^1.0.0", + "iron-iconset-svg": "PolymerElements/iron-iconset-svg#^1.0.0", + "iron-image": "PolymerElements/iron-image#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-jsonp-library": "PolymerElements/iron-jsonp-library#^1.0.0", + "iron-localstorage": "PolymerElements/iron-localstorage#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "iron-pages": "PolymerElements/iron-pages#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-signals": "PolymerElements/iron-signals#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0" + }, + + "homepage": "https://github.com/PolymerElements/iron-elements", + "authors": ["The Polymer Authors"], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ] +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/.bower.json new file mode 100644 index 0000000..2ab1f93 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "iron-fit-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Fits an element inside another element", + "private": true, + "main": [ + "iron-fit-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-fit-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-fit-behavior", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "971104a539e356fc9f8d5c640fced7f1af653c15" + }, + "_source": "git://github.com/PolymerElements/iron-fit-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-fit-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/README.md new file mode 100644 index 0000000..8f4fc76 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/README.md @@ -0,0 +1,3 @@ +# iron-fit-behavior + +Fits an element in the window, or another element. diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/bower.json new file mode 100644 index 0000000..c8f7dc8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-fit-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Fits an element inside another element", + "private": true, + "main": [ + "iron-fit-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-fit-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/index.html new file mode 100644 index 0000000..5ffa7d6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-fit-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/iron-fit-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/iron-fit-behavior-extracted.js new file mode 100644 index 0000000..c418059 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/iron-fit-behavior-extracted.js @@ -0,0 +1,217 @@ + + +/** +Polymer.IronFitBehavior fits an element in another element using `max-height` and `max-width`, and +optionally centers it in the window or another element. + +The element will only be sized and/or positioned if it has not already been sized and/or positioned +by CSS. + +CSS properties | Action +-----------------------------|------------------------------------------- +`position` set | Element is not centered horizontally or vertically +`top` or `bottom` set | Element is not vertically centered +`left` or `right` set | Element is not horizontally centered +`max-height` or `height` set | Element respects `max-height` or `height` +`max-width` or `width` set | Element respects `max-width` or `width` + +@demo demo/index.html +@polymerBehavior +*/ + + Polymer.IronFitBehavior = { + + properties: { + + /** + * The element that will receive a `max-height`/`width`. By default it is the same as `this`, + * but it can be set to a child element. This is useful, for example, for implementing a + * scrolling region inside the element. + */ + sizingTarget: { + type: Object, + value: function() { + return this; + } + }, + + /** + * The element to fit `this` into. + */ + fitInto: { + type: Object, + value: window + }, + + /** + * Set to true to auto-fit on attach. + */ + autoFitOnAttach: { + type: Boolean, + value: false + }, + + _fitInfo: { + type: Object + } + + }, + + get _fitWidth() { + var fitWidth; + if (this.fitInto === window) { + fitWidth = this.fitInto.innerWidth; + } else { + fitWidth = this.fitInto.getBoundingClientRect().width; + } + return fitWidth; + }, + + get _fitHeight() { + var fitHeight; + if (this.fitInto === window) { + fitHeight = this.fitInto.innerHeight; + } else { + fitHeight = this.fitInto.getBoundingClientRect().height; + } + return fitHeight; + }, + + attached: function() { + if (this.autoFitOnAttach) { + if (window.getComputedStyle(this).display === 'none') { + setTimeout(function() { + this.fit(); + }.bind(this)); + } else { + this.fit(); + } + } + }, + + /** + * Fits and optionally centers the element into the window, or `fitInfo` if specified. + */ + fit: function() { + this._discoverInfo(); + this.constrain(); + this.center(); + }, + + /** + * Memoize information needed to position and size the target element. + */ + _discoverInfo: function() { + if (this._fitInfo) { + return; + } + var target = window.getComputedStyle(this); + var sizer = window.getComputedStyle(this.sizingTarget); + this._fitInfo = { + positionedBy: { + vertically: target.top !== 'auto' ? 'top' : (target.bottom !== 'auto' ? + 'bottom' : null), + horizontally: target.left !== 'auto' ? 'left' : (target.right !== 'auto' ? + 'right' : null), + css: target.position + }, + sizedBy: { + height: sizer.maxHeight !== 'none', + width: sizer.maxWidth !== 'none' + }, + margin: { + top: parseInt(target.marginTop, 10) || 0, + right: parseInt(target.marginRight, 10) || 0, + bottom: parseInt(target.marginBottom, 10) || 0, + left: parseInt(target.marginLeft, 10) || 0 + } + }; + }, + + /** + * Resets the target element's position and size constraints, and clear + * the memoized data. + */ + resetFit: function() { + if (!this._fitInfo || !this._fitInfo.sizedBy.height) { + this.sizingTarget.style.maxHeight = ''; + this.style.top = ''; + } + if (!this._fitInfo || !this._fitInfo.sizedBy.width) { + this.sizingTarget.style.maxWidth = ''; + this.style.left = ''; + } + if (this._fitInfo) { + this.style.position = this._fitInfo.positionedBy.css; + } + this._fitInfo = null; + }, + + /** + * Equivalent to calling `resetFit()` and `fit()`. Useful to call this after the element, + * the window, or the `fitInfo` element has been resized. + */ + refit: function() { + this.resetFit(); + this.fit(); + }, + + /** + * Constrains the size of the element to the window or `fitInfo` by setting `max-height` + * and/or `max-width`. + */ + constrain: function() { + var info = this._fitInfo; + // position at (0px, 0px) if not already positioned, so we can measure the natural size. + if (!this._fitInfo.positionedBy.vertically) { + this.style.top = '0px'; + } + if (!this._fitInfo.positionedBy.horizontally) { + this.style.left = '0px'; + } + // need border-box for margin/padding + this.sizingTarget.style.boxSizing = 'border-box'; + // constrain the width and height if not already set + var rect = this.getBoundingClientRect(); + if (!info.sizedBy.height) { + this._sizeDimension(rect, info.positionedBy.vertically, 'top', 'bottom', 'Height'); + } + if (!info.sizedBy.width) { + this._sizeDimension(rect, info.positionedBy.horizontally, 'left', 'right', 'Width'); + } + }, + + _sizeDimension: function(rect, positionedBy, start, end, extent) { + var info = this._fitInfo; + var max = extent === 'Width' ? this._fitWidth : this._fitHeight; + var flip = (positionedBy === end); + var offset = flip ? max - rect[end] : rect[start]; + var margin = info.margin[flip ? start : end]; + var offsetExtent = 'offset' + extent; + var sizingOffset = this[offsetExtent] - this.sizingTarget[offsetExtent]; + this.sizingTarget.style['max' + extent] = (max - margin - offset - sizingOffset) + 'px'; + }, + + /** + * Centers horizontally and vertically if not already positioned. This also sets + * `position:fixed`. + */ + center: function() { + if (!this._fitInfo.positionedBy.vertically || !this._fitInfo.positionedBy.horizontally) { + // need position:fixed to center + this.style.position = 'fixed'; + } + if (!this._fitInfo.positionedBy.vertically) { + var top = (this._fitHeight - this.offsetHeight) / 2; + top -= this._fitInfo.margin.top; + this.style.top = top + 'px'; + } + if (!this._fitInfo.positionedBy.horizontally) { + var left = (this._fitWidth - this.offsetWidth) / 2; + left -= this._fitInfo.margin.left; + this.style.left = left + 'px'; + } + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/iron-fit-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/iron-fit-behavior.html new file mode 100644 index 0000000..f66971b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-fit-behavior/iron-fit-behavior.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-fit-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-flex-layout/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/.bower.json new file mode 100644 index 0000000..dff0707 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/.bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-flex-layout", + "version": "1.0.1", + "description": "Provide flexbox-based layouts", + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-flex-layout", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "8828cc6ad1bb70d6a99aa1ecabc070b30256da06" + }, + "_source": "git://github.com/PolymerElements/iron-flex-layout.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-flex-layout" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-flex-layout/README.md b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/README.md new file mode 100644 index 0000000..895ed0f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/README.md @@ -0,0 +1,4 @@ +iron-flex-layout +================ + +Layout styles for the iron elements. diff --git a/third_party/polymer/v1_0/components-chromium/iron-flex-layout/bower.json b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/bower.json new file mode 100644 index 0000000..46dcdb8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/bower.json @@ -0,0 +1,21 @@ +{ + "name": "iron-flex-layout", + "version": "1.0.1", + "description": "Provide flexbox-based layouts", + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-flex-layout/classes/iron-flex-layout.html b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/classes/iron-flex-layout.html new file mode 100644 index 0000000..283c2a8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/classes/iron-flex-layout.html @@ -0,0 +1,307 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="iron-shadow-flex-layout.html"> + +<style> + + /******************************* + Flex Layout + *******************************/ + + .layout.horizontal, + .layout.horizontal-reverse, + .layout.vertical, + .layout.vertical-reverse { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + } + + .layout.inline { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + } + + .layout.horizontal { + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + } + + .layout.horizontal-reverse { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + } + + .layout.vertical { + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + } + + .layout.vertical-reverse { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + } + + .layout.wrap { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + } + + .layout.wrap-reverse { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + } + + .flex-auto { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + } + + .flex-none { + -ms-flex: none; + -webkit-flex: none; + flex: none; + } + + .flex, + .flex-1 { + -ms-flex: 1; + -webkit-flex: 1; + flex: 1; + } + + .flex-2 { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + } + + .flex-3 { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + } + + .flex-4 { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + } + + .flex-5 { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + } + + .flex-6 { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + } + + .flex-7 { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + } + + .flex-8 { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + } + + .flex-9 { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + } + + .flex-10 { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + } + + .flex-11 { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + } + + .flex-12 { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + } + + /* alignment in cross axis */ + + .layout.start { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + } + + .layout.center, + .layout.center-center { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + } + + .layout.end { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + } + + /* alignment in main axis */ + + .layout.start-justified { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + } + + .layout.center-justified, + .layout.center-center { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + } + + .layout.end-justified { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + } + + .layout.around-justified { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + } + + .layout.justified { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + } + + /* self alignment */ + + .self-start { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + } + + .self-center { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + } + + .self-end { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + } + + .self-stretch { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + } + + /******************************* + Other Layout + *******************************/ + + .block { + display: block; + } + + /* IE 10 support for HTML5 hidden attr */ + [hidden] { + display: none !important; + } + + .invisible { + visibility: hidden !important; + } + + .relative { + position: relative; + } + + .fit { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + body.fullbleed { + margin: 0; + height: 100vh; + } + + .scroll { + -webkit-overflow-scrolling: touch; + overflow: auto; + } + + /* fixed position */ + + .fixed-bottom, + .fixed-left, + .fixed-right, + .fixed-top { + position: fixed; + } + + .fixed-top { + top: 0; + left: 0; + right: 0; + } + + .fixed-right { + top: 0; + right: 0; + bottom: 0; + } + + .fixed-bottom { + right: 0; + bottom: 0; + left: 0; + } + + .fixed-left { + top: 0; + bottom: 0; + left: 0; + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/iron-flex-layout/classes/iron-shadow-flex-layout.html b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/classes/iron-shadow-flex-layout.html new file mode 100644 index 0000000..c42067a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/classes/iron-shadow-flex-layout.html @@ -0,0 +1,302 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<style> + + /******************************* + Flex Layout + *******************************/ + + html /deep/ .layout.horizontal, + html /deep/ .layout.horizontal-reverse, + html /deep/ .layout.vertical, + html /deep/ .layout.vertical-reverse { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + } + + html /deep/ .layout.inline { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + } + + html /deep/ .layout.horizontal { + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + } + + html /deep/ .layout.horizontal-reverse { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + } + + html /deep/ .layout.vertical { + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + } + + html /deep/ .layout.vertical-reverse { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + } + + html /deep/ .layout.wrap { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + } + + html /deep/ .layout.wrap-reverse { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + } + + html /deep/ .flex-auto { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + } + + html /deep/ .flex-none { + -ms-flex: none; + -webkit-flex: none; + flex: none; + } + + html /deep/ .flex, + html /deep/ .flex-1 { + -ms-flex: 1; + -webkit-flex: 1; + flex: 1; + } + + html /deep/ .flex-2 { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + } + + html /deep/ .flex-3 { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + } + + html /deep/ .flex-4 { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + } + + html /deep/ .flex-5 { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + } + + html /deep/ .flex-6 { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + } + + html /deep/ .flex-7 { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + } + + html /deep/ .flex-8 { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + } + + html /deep/ .flex-9 { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + } + + html /deep/ .flex-10 { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + } + + html /deep/ .flex-11 { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + } + + html /deep/ .flex-12 { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + } + + /* alignment in cross axis */ + + html /deep/ .layout.start { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + } + + html /deep/ .layout.center, + html /deep/ .layout.center-center { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + } + + html /deep/ .layout.end { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + } + + /* alignment in main axis */ + + html /deep/ .layout.start-justified { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + } + + html /deep/ .layout.center-justified, + html /deep/ .layout.center-center { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + } + + html /deep/ .layout.end-justified { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + } + + html /deep/ .layout.around-justified { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + } + + html /deep/ .layout.justified { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + } + + /* self alignment */ + + html /deep/ .self-start { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + } + + html /deep/ .self-center { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + } + + html /deep/ .self-end { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + } + + html /deep/ .self-stretch { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + } + + /******************************* + Other Layout + *******************************/ + + html /deep/ .block { + display: block; + } + + /* IE 10 support for HTML5 hidden attr */ + html /deep/ [hidden] { + display: none !important; + } + + html /deep/ .invisible { + visibility: hidden !important; + } + + html /deep/ .relative { + position: relative; + } + + html /deep/ .fit { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + body.fullbleed { + margin: 0; + height: 100vh; + } + + html /deep/ .scroll { + -webkit-overflow-scrolling: touch; + overflow: auto; + } + + .fixed-bottom, + .fixed-left, + .fixed-right, + .fixed-top { + position: fixed; + } + + html /deep/ .fixed-top { + top: 0; + left: 0; + right: 0; + } + + html /deep/ .fixed-right { + top: 0; + right: 0; + botttom: 0; + } + + html /deep/ .fixed-bottom { + right: 0; + bottom: 0; + left: 0; + } + + html /deep/ .fixed-left { + top: 0; + botttom: 0; + left: 0; + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/iron-flex-layout/iron-flex-layout.html b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/iron-flex-layout.html new file mode 100644 index 0000000..ed9cd7b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-flex-layout/iron-flex-layout.html @@ -0,0 +1,313 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + --layout: { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + }; + + --layout-inline: { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + }; + + --layout-horizontal: { + /* @apply(--layout); */ + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + }; + + --layout-horizontal-reverse: { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + }; + + --layout-vertical: { + /* @apply(--layout); */ + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + }; + + --layout-vertical-reverse: { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + }; + + --layout-wrap: { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + }; + + --layout-wrap-reverse: { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + }; + + --layout-flex-auto: { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + }; + + --layout-flex-none: { + -ms-flex: none; + -webkit-flex: none; + flex: none; + }; + + --layout-flex: { + -ms-flex: 1 1 0.000000001px; + -webkit-flex: 1; + flex: 1; + -webkit-flex-basis: 0.000000001px; + flex-basis: 0.000000001px; + }; + + --layout-flex-2: { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + }; + + --layout-flex-3: { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + }; + + --layout-flex-4: { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + }; + + --layout-flex-5: { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + }; + + --layout-flex-6: { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + }; + + --layout-flex-7: { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + }; + + --layout-flex-8: { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + }; + + --layout-flex-9: { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + }; + + --layout-flex-10: { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + }; + + --layout-flex-11: { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + }; + + --layout-flex-12: { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + }; + + /* alignment in cross axis */ + + --layout-start: { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + }; + + --layout-center: { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + }; + + --layout-end: { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + }; + + /* alignment in main axis */ + + --layout-start-justified: { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + }; + + --layout-center-justified: { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + }; + + --layout-end-justified: { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + }; + + --layout-around-justified: { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + }; + + --layout-justified: { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + }; + + --layout-center-center: { + /* @apply(--layout-center --layout-center-justified); */ + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + }; + + /* self alignment */ + + --layout-self-start: { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + }; + + --layout-self-center: { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + }; + + --layout-self-end: { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + }; + + --layout-self-stretch: { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + }; + + /******************************* + Other Layout + *******************************/ + + --layout-block: { + display: block; + }; + + --layout-invisible: { + visibility: hidden !important; + }; + + --layout-relative: { + position: relative; + }; + + --layout-fit: { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + }; + + --layout-scroll: { + -webkit-overflow-scrolling: touch; + overflow: auto; + }; + + /* fixed position */ + + --layout-fixed-bottom:, + --layout-fixed-left:, + --layout-fixed-right:, + --layout-fixed-top: { + position: fixed; + }; + + --layout-fixed-top: { + top: 0; + left: 0; + right: 0; + }; + + --layout-fixed-right: { + top: 0; + right: 0; + bottom: 0; + }; + + --layout-fixed-bottom: { + right: 0; + bottom: 0; + left: 0; + }; + + --layout-fixed-left: { + top: 0; + bottom: 0; + left: 0; + }; + + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/.bower.json new file mode 100644 index 0000000..f1369b1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-form-element-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "main": "iron-form-element-behavior", + "authors": "The Polymer Authors", + "description": "Enables a custom element to be included in an iron-form", + "keywords": [ + "web-components", + "polymer", + "form" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form-element-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-form-element-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "f386143e866c320025589f3d79798c12103377a4" + }, + "_source": "git://github.com/PolymerElements/iron-form-element-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-form-element-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/README.md new file mode 100644 index 0000000..555063f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/README.md @@ -0,0 +1,2 @@ +# iron-form-element-behavior +Behavior that allows an element to be tracked by an iron-form diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/bower.json new file mode 100644 index 0000000..1e141f2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/bower.json @@ -0,0 +1,27 @@ +{ + "name": "iron-form-element-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "main": "iron-form-element-behavior", + "authors": "The Polymer Authors", + "description": "Enables a custom element to be included in an iron-form", + "keywords": [ + "web-components", + "polymer", + "form" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form-element-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/index.html new file mode 100644 index 0000000..8d748c0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-form-element-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/iron-form-element-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/iron-form-element-behavior-extracted.js new file mode 100644 index 0000000..c8ae235 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/iron-form-element-behavior-extracted.js @@ -0,0 +1,34 @@ + + + /** + + @demo demo/index.html + @polymerBehavior + + */ + Polymer.IronFormElementBehavior = { + + properties: { + + /** + * The name of this element. + */ + name: { + type: String + }, + + /** + * The value for this element. + */ + value: { + notify: true, + type: String + }, + }, + + attached: function() { + this.fire('iron-form-element-register'); + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/iron-form-element-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/iron-form-element-behavior.html new file mode 100644 index 0000000..706becc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form-element-behavior/iron-form-element-behavior.html @@ -0,0 +1,14 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- +Enables a custom element to be included in an `iron-form`. +--> +</head><body><script src="iron-form-element-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-form/.bower.json new file mode 100644 index 0000000..fad4679 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/.bower.json @@ -0,0 +1,47 @@ +{ + "name": "iron-form", + "version": "1.0.1", + "description": "Makes it easier to manage forms", + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "authors": [ + "The Polymer Authors" + ], + "main": [ + "iron-form.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-form", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "^0.7.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "b884414ee5d9c9e1484554cd1e644e4cfa562153" + }, + "_source": "git://github.com/PolymerElements/iron-form.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-form" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-form/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/README.md b/third_party/polymer/v1_0/components-chromium/iron-form/README.md new file mode 100644 index 0000000..424b29f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/README.md @@ -0,0 +1,2 @@ +# iron-form +Custom form element diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/bower.json b/third_party/polymer/v1_0/components-chromium/iron-form/bower.json new file mode 100644 index 0000000..8abd458 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/bower.json @@ -0,0 +1,43 @@ +{ + "name": "iron-form", + "version": "1.0.1", + "description": "Makes it easier to manage forms", + "keywords": [ + "web-components", + "polymer", + "form" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "main": [ + "iron-form.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-form", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "^0.7.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/index.html b/third_party/polymer/v1_0/components-chromium/iron-form/index.html new file mode 100644 index 0000000..acd7140 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-form</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/iron-form-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-form/iron-form-extracted.js new file mode 100644 index 0000000..ae8d3a7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/iron-form-extracted.js @@ -0,0 +1,177 @@ + +/* +``<iron-form>` is an HTML `<form>` element that can validate and submit any custom +elements that implement `Polymer.IronFormElementBehavior`, as well as any +native HTML elements. + +It supports both `get` and `post` methods, and uses an `iron-ajax` element to +submit the form data to the action URL. + + Example: + + <form is="iron-form" id="form" method="post" action="/form/handler"> + <paper-input name="name" label="name"></paper-input> + <input name="address"> + ... + </form> + +By default, a native `<button>` element will submit this form. However, if you +want to submit it from a custom element's click handler, you need to explicitly +call the form's `submit` method. + + Example: + + <paper-button raised onclick="submitForm()">Submit</paper-button> + + function submitForm() { + document.getElementById('form').submit(); + } + +@demo demo/index.html +*/ + + Polymer({ + + is: 'iron-form', + + extends: 'form', + + /** + * Fired after the form is submitted. + * + * @event iron-form-submit + */ + + /** + * Fired after the form is submitted and a response is received. + * + * @event iron-form-response + */ + + /** + * Fired after the form is submitted and an error is received. + * + * @event iron-form-error + */ + + listeners: { + 'iron-form-element-register': '_registerElement', + 'submit': 'submit' + }, + + ready: function() { + // Object that handles the ajax form submission request. + this._requestBot = document.createElement('iron-ajax'); + this._requestBot.addEventListener('response', this._handleFormResponse.bind(this)); + this._requestBot.addEventListener('error', this._handleFormError.bind(this)); + + // Holds all the custom elements registered with this form. + this._customElements = []; + }, + + /** + * Called to submit the form. + */ + submit: function(event) { + if (!this._validate()) { + return false; + } + + var json = this.serialize(); + + this._requestBot.url = this.action; + this._requestBot.method = this.method; + this._requestBot.params = json; + + if (this.method == 'POST') { + this._requestBot.body = JSON.stringify(json); + } + + this._requestBot.generateRequest(); + this.fire('iron-form-submit', json); + + // Don't perform a page refresh. + if (event) { + event.preventDefault(); + } + + return false; + }, + + /** + * Returns a json object containing name/value pairs for all the registered + * custom components and native elements of the form. If there are elements + * with duplicate names, then their values will get aggregated into an + * array of values. + */ + serialize: function() { + var json = {}; + + function addSerializedElement(el) { + // If the name doesn't exist, add it. Otherwise, serialize it to + // an array, + if (!json[el.name]) { + json[el.name] = el.value; + } else { + if (!Array.isArray(json[el.name])) { + json[el.name] = [json[el.name]]; + } + json[el.name].push(el.value); + } + } + + // Go through all of the registered custom components. + for (var el, i = 0; el = this._customElements[i], i < this._customElements.length; i++) { + if (el.name) { + addSerializedElement(el); + } + } + + // Also go through the form's native elements. + for (var el, i = 0; el = this.elements[i], i < this.elements.length; i++) { + // Checkboxes and radio buttons should only use their value if they're checked. + // Also, custom elements that extend native elements (like an + // `<input is="fancy-input">`) will appear in both lists. Since they + // were already added as a custom element, they don't need + // to be re-added. + if (!el.name || !this._useValue(el) || + (el.hasAttribute('is') && json[el.name])) { + continue; + } + addSerializedElement(el); + } + + return json; + }, + + _handleFormResponse: function (event) { + this.fire('iron-form-response', event.detail.response); + }, + + _handleFormError: function (event) { + this.fire('iron-form-error', event.detail); + }, + + _registerElement: function(e) { + this._customElements.push(e.target); + }, + + _validate: function() { + var valid = true; + for (var el, i = 0; el = this._customElements[i], i < this._customElements.length; i++) { + valid = el.validate() && valid; + } + return valid; + }, + + _useValue: function(el) { + // Checkboxes and radio buttons should only use their value if they're checked. + if (el.type !== 'checkbox' && el.type !== 'radio') { + return true; + } else { + return el.checked; + } + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-form/iron-form.html b/third_party/polymer/v1_0/components-chromium/iron-form/iron-form.html new file mode 100644 index 0000000..c516e54 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-form/iron-form.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-ajax/iron-ajax.html"> + +</head><body><script src="iron-form-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-icon/.bower.json new file mode 100644 index 0000000..4f44f2e8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/.bower.json @@ -0,0 +1,39 @@ +{ + "name": "iron-icon", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An element that supports displaying an icon", + "main": "iron-icon.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-iconset": "polymerelements/iron-iconset#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-icon", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "b6c36359baf7dff86cc4174012296555512ce0c1" + }, + "_source": "git://github.com/PolymerElements/iron-icon.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-icon" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-icon/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/README.md b/third_party/polymer/v1_0/components-chromium/iron-icon/README.md new file mode 100644 index 0000000..27b65c0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/README.md @@ -0,0 +1,56 @@ +iron-icon +========= + +The `iron-icon` element displays an icon. By default an icon renders as a 24px square. + +Example using src: + +```html +<iron-icon src="star.png"></iron-icon> +``` + +Example setting size to 32px x 32px: + +```html +<iron-icon class="big" src="big_star.png"></iron-icon> + +<style> + .big { + height: 32px; + width: 32px; + } +</style> +``` + +The iron elements include several sets of icons. +To use the default set of icons, import `iron-icons.html` and use the `icon` attribute to specify an icon: + +```html +<!-- import default iconset and iron-icon --> +<link rel="import" href="/components/iron-icons/iron-icons.html"> + +<iron-icon icon="menu"></iron-icon> +``` + +To use a different built-in set of icons, import `iron-icons/<iconset>-icons.html`, and +specify the icon as `<iconset>:<icon>`. For example: + +```html +<!-- import communication iconset and iron-icon --> +<link rel="import" href="/components/iron-icons/communication-icons.html"> + +<iron-icon icon="communication:email"></iron-icon> +``` + +You can also create custom icon sets of bitmap or SVG icons. + +Example of using an icon named `cherry` from a custom iconset with the ID `fruit`: + +```html +<iron-icon icon="fruit:cherry"></iron-icon> +``` + +See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for more information about +how to create a custom iconset. + +See [iron-icons](http://www.polymer-project.org/components/iron-icons/demo.html) for the default set of icons. diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/bower.json b/third_party/polymer/v1_0/components-chromium/iron-icon/bower.json new file mode 100644 index 0000000..e5ebedb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/bower.json @@ -0,0 +1,29 @@ +{ + "name": "iron-icon", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An element that supports displaying an icon", + "main": "iron-icon.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-iconset": "polymerelements/iron-iconset#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-icon/hero.svg new file mode 100644 index 0000000..f0f5853 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/hero.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="112" cy="61" r="8"/> + <path d="M129,78H95V44h34V78z M97,76h30V46H97V76z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/index.html b/third_party/polymer/v1_0/components-chromium/iron-icon/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/iron-icon-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-icon/iron-icon-extracted.js new file mode 100644 index 0000000..0f1add2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/iron-icon-extracted.js @@ -0,0 +1,79 @@ + + + Polymer({ + + is: 'iron-icon', + + properties: { + + /** + * The name of the icon to use. The name should be of the form: + * `iconset_name:icon_name`. + */ + icon: { + type: String, + observer: '_iconChanged' + }, + + /** + * The name of the theme to used, if one is specified by the + * iconset. + */ + theme: { + type: String, + observer: '_updateIcon' + }, + + /** + * If using iron-icon without an iconset, you can set the src to be + * the URL of an individual icon image file. Note that this will take + * precedence over a given icon attribute. + */ + src: { + type: String, + observer: '_srcChanged' + } + }, + + _DEFAULT_ICONSET: 'icons', + + _iconChanged: function(icon) { + var parts = (icon || '').split(':'); + this._iconName = parts.pop(); + this._iconsetName = parts.pop() || this._DEFAULT_ICONSET; + this._updateIcon(); + }, + + _srcChanged: function(src) { + this._updateIcon(); + }, + + _usesIconset: function() { + return this.icon || !this.src; + }, + + _updateIcon: function() { + if (this._usesIconset()) { + if (this._iconsetName) { + this._iconset = this.$.meta.byKey(this._iconsetName); + if (this._iconset) { + this._iconset.applyIcon(this, this._iconName, this.theme); + } else { + this._warn(this._logf('_updateIcon', 'could not find iconset `' + + this._iconsetName + '`, did you import the iconset?')); + } + } + } else { + if (!this._img) { + this._img = document.createElement('img'); + this._img.style.width = '100%'; + this._img.style.height = '100%'; + } + this._img.src = this.src; + Polymer.dom(this.root).appendChild(this._img); + } + } + + }); + +
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-icon/iron-icon.html b/third_party/polymer/v1_0/components-chromium/iron-icon/iron-icon.html new file mode 100644 index 0000000..5cb1c4ed --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icon/iron-icon.html @@ -0,0 +1,106 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> + +<!-- + +The `iron-icon` element displays an icon. By default an icon renders as a 24px square. + +Example using src: + + <iron-icon src="star.png"></iron-icon> + +Example setting size to 32px x 32px: + + <iron-icon class="big" src="big_star.png"></iron-icon> + + <style> + .big { + height: 32px; + width: 32px; + } + </style> + +The iron elements include several sets of icons. +To use the default set of icons, import `iron-icons.html` and use the `icon` attribute to specify an icon: + + <!-- import default iconset and iron-icon --> + <link rel="import" href="/components/iron-icons/iron-icons.html"> + + <iron-icon icon="menu"></iron-icon> + +To use a different built-in set of icons, import `iron-icons/<iconset>-icons.html`, and +specify the icon as `<iconset>:<icon>`. For example: + + <!-- import communication iconset and iron-icon --> + <link rel="import" href="/components/iron-icons/communication-icons.html"> + + <iron-icon icon="communication:email"></iron-icon> + +You can also create custom icon sets of bitmap or SVG icons. + +Example of using an icon named `cherry` from a custom iconset with the ID `fruit`: + + <iron-icon icon="fruit:cherry"></iron-icon> + +See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for more information about +how to create a custom iconset. + +See [iron-icons](http://www.polymer-project.org/components/iron-icons/demo.html) for the default set of icons. + + +### Styling + +The following custom properties are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--iron-icon-width` | Width of the icon | `24px` +`--iron-icon-height` | Height of the icon | `24px` + +@group Iron Elements +@element iron-icon +@demo demo/index.html +@hero hero.svg +@homepage polymer.github.io +--> + +<style is="custom-style"> + :root { + --iron-icon-width: 24px; + --iron-icon-height: 24px; + } +</style> + +</head><body><dom-module id="iron-icon"> + + <style> + :host { + @apply(--layout-inline); + @apply(--layout-center-center); + position: relative; + + vertical-align: middle; + + fill: currentcolor; + + width: var(--iron-icon-width); + height: var(--iron-icon-height); + } + </style> + + <template> + <iron-meta id="meta" type="iconset"></iron-meta> + </template> + + </dom-module> + +<script src="iron-icon-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-icons/.bower.json new file mode 100644 index 0000000..f7e7900 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "iron-icons", + "version": "1.0.1", + "description": "A set of icons for use with iron-icon", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "main": "iron-icons.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-icons" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-icons", + "dependencies": { + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "ignore": [ + "util", + "update-icons.sh" + ], + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "a1727591f312fe6cd2e065cab6490232716a646a" + }, + "_source": "git://github.com/PolymerElements/iron-icons.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-icons" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-icons/.gitignore new file mode 100644 index 0000000..bb1944e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/.gitignore @@ -0,0 +1,3 @@ +util/node_modules +material-design-icons +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/README.md b/third_party/polymer/v1_0/components-chromium/iron-icons/README.md new file mode 100644 index 0000000..ed473f7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/README.md @@ -0,0 +1,8 @@ +iron-icons +========= + +See the [component page](http://polymer-project.org/docs/elements/iron-elements.html#iron-icons) for more information. + +## Building +Running `update-icons.sh` will checkout [material-design-icons](https://github.com/google/material-design-icons), reduce +the fileset to 24px svgs, and compile the iconsets. diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/av-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/av-icons.html new file mode 100644 index 0000000..0d6ff37 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/av-icons.html @@ -0,0 +1,73 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="av" size="24"> +<svg><defs> +<g id="airplay"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><defs><path id="c" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><clipPath id="d" clip-path="url(#b)"><use xlink:href="#c" overflow="visible"/></clipPath><path d="M6 22h12l-6-6zM21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h4v-2H3V5h18v12h-4v2h4c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z" clip-path="url(#d)"/></g> +<g id="album"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 14.5c-2.49 0-4.5-2.01-4.5-4.5S9.51 7.5 12 7.5s4.5 2.01 4.5 4.5-2.01 4.5-4.5 4.5zm0-5.5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1z"/></g> +<g id="av-timer"><path d="M11 17c0 .55.45 1 1 1s1-.45 1-1-.45-1-1-1-1 .45-1 1zm0-14v4h2V5.08c3.39.49 6 3.39 6 6.92 0 3.87-3.13 7-7 7s-7-3.13-7-7c0-1.68.59-3.22 1.58-4.42L12 13l1.41-1.41-6.8-6.8v.02C4.42 6.45 3 9.05 3 12c0 4.97 4.02 9 9 9 4.97 0 9-4.03 9-9s-4.03-9-9-9h-1zm7 9c0-.55-.45-1-1-1s-1 .45-1 1 .45 1 1 1 1-.45 1-1zM6 12c0 .55.45 1 1 1s1-.45 1-1-.45-1-1-1-1 .45-1 1z"/></g> +<g id="closed-caption"><path d="M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 7H9.5v-.5h-2v3h2V13H11v1c0 .55-.45 1-1 1H7c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1h3c.55 0 1 .45 1 1v1zm7 0h-1.5v-.5h-2v3h2V13H18v1c0 .55-.45 1-1 1h-3c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1h3c.55 0 1 .45 1 1v1z"/></g> +<g id="equalizer"><path d="M10 20h4V4h-4v16zm-6 0h4v-8H4v8zM16 9v11h4V9h-4z"/></g> +<g id="explicit"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 6h-4v2h4v2h-4v2h4v2H9V7h6v2z"/></g> +<g id="fast-forward"><path d="M4 18l8.5-6L4 6v12zm9-12v12l8.5-6L13 6z"/></g> +<g id="fast-rewind"><path d="M11 18V6l-8.5 6 8.5 6zm.5-6l8.5 6V6l-8.5 6z"/></g> +<g id="forward-10"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M4 13c0 4.4 3.6 8 8 8s8-3.6 8-8h-2c0 3.3-2.7 6-6 6s-6-2.7-6-6 2.7-6 6-6v4l5-5-5-5v4c-4.4 0-8 3.6-8 8zm6.8 3H10v-3.3L9 13v-.7l1.8-.6h.1V16zm4.3-1.8c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1.3.2.5.3.2.3.3.6.1.5.1.8v.7zm-.8-.8v-.5s-.1-.2-.1-.3-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5z" clip-path="url(#b)"/></g> +<g id="forward-30"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M9.6 13.5h.4c.2 0 .4-.1.5-.2s.2-.2.2-.4v-.2s-.1-.1-.1-.2-.1-.1-.2-.1h-.5s-.1.1-.2.1-.1.1-.1.2v.2h-1c0-.2 0-.3.1-.5s.2-.3.3-.4.3-.2.4-.2.4-.1.5-.1c.2 0 .4 0 .6.1s.3.1.5.2.2.2.3.4.1.3.1.5v.3s-.1.2-.1.3-.1.2-.2.2-.2.1-.3.2c.2.1.4.2.5.4s.2.4.2.6c0 .2 0 .4-.1.5s-.2.3-.3.4-.3.2-.5.2-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.4-.1-.6h.8v.2s.1.1.1.2.1.1.2.1h.5s.1-.1.2-.1.1-.1.1-.2v-.5s-.1-.1-.1-.2-.1-.1-.2-.1h-.6v-.7zm5.7.7c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1.3.2.5.3.2.3.3.6.1.5.1.8v.7zm-.9-.8v-.5s-.1-.2-.1-.3-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5zM4 13c0 4.4 3.6 8 8 8s8-3.6 8-8h-2c0 3.3-2.7 6-6 6s-6-2.7-6-6 2.7-6 6-6v4l5-5-5-5v4c-4.4 0-8 3.6-8 8z" clip-path="url(#b)"/></g> +<g id="forward-5"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M4 13c0 4.4 3.6 8 8 8s8-3.6 8-8h-2c0 3.3-2.7 6-6 6s-6-2.7-6-6 2.7-6 6-6v4l5-5-5-5v4c-4.4 0-8 3.6-8 8zm6.7.9l.2-2.2h2.4v.7h-1.7l-.1.9s.1 0 .1-.1.1 0 .1-.1.1 0 .2 0h.2c.2 0 .4 0 .5.1s.3.2.4.3.2.3.3.5.1.4.1.6c0 .2 0 .4-.1.5s-.1.3-.3.5-.3.2-.5.3-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.3-.1-.5h.8c0 .2.1.3.2.4s.2.1.4.1c.1 0 .2 0 .3-.1l.2-.2s.1-.2.1-.3v-.6l-.1-.2-.2-.2s-.2-.1-.3-.1h-.2s-.1 0-.2.1-.1 0-.1.1-.1.1-.1.1h-.6z" clip-path="url(#b)"/></g> +<g id="games"><path d="M15 7.5V2H9v5.5l3 3 3-3zM7.5 9H2v6h5.5l3-3-3-3zM9 16.5V22h6v-5.5l-3-3-3 3zM16.5 9l-3 3 3 3H22V9h-5.5z"/></g> +<g id="hd"><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-8 12H9.5v-2h-2v2H6V9h1.5v2.5h2V9H11v6zm2-6h4c.55 0 1 .45 1 1v4c0 .55-.45 1-1 1h-4V9zm1.5 4.5h2v-3h-2v3z"/></g> +<g id="hearing"><path d="M17 20c-.29 0-.56-.06-.76-.15-.71-.37-1.21-.88-1.71-2.38-.51-1.56-1.47-2.29-2.39-3-.79-.61-1.61-1.24-2.32-2.53C9.29 10.98 9 9.93 9 9c0-2.8 2.2-5 5-5s5 2.2 5 5h2c0-3.93-3.07-7-7-7S7 5.07 7 9c0 1.26.38 2.65 1.07 3.9.91 1.65 1.98 2.48 2.85 3.15.81.62 1.39 1.07 1.71 2.05.6 1.82 1.37 2.84 2.73 3.55.51.23 1.07.35 1.64.35 2.21 0 4-1.79 4-4h-2c0 1.1-.9 2-2 2zM7.64 2.64L6.22 1.22C4.23 3.21 3 5.96 3 9s1.23 5.79 3.22 7.78l1.41-1.41C6.01 13.74 5 11.49 5 9s1.01-4.74 2.64-6.36zM11.5 9c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5-1.12-2.5-2.5-2.5-2.5 1.12-2.5 2.5z"/></g> +<g id="high-quality"><path d="M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 11H9.5v-2h-2v2H6V9h1.5v2.5h2V9H11v6zm7-1c0 .55-.45 1-1 1h-.75v1.5h-1.5V15H14c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1h3c.55 0 1 .45 1 1v4zm-3.5-.5h2v-3h-2v3z"/></g> +<g id="library-add"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/></g> +<g id="library-books"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9H9V9h10v2zm-4 4H9v-2h6v2zm4-8H9V5h10v2z"/></g> +<g id="library-music"><path d="M20 2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-2 5h-3v5.5c0 1.38-1.12 2.5-2.5 2.5S10 13.88 10 12.5s1.12-2.5 2.5-2.5c.57 0 1.08.19 1.5.51V5h4v2zM4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6z"/></g> +<g id="loop"><path d="M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"/></g> +<g id="mic"><path d="M12 14c1.66 0 2.99-1.34 2.99-3L15 5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm5.3-3c0 3-2.54 5.1-5.3 5.1S6.7 14 6.7 11H5c0 3.41 2.72 6.23 6 6.72V21h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"/></g> +<g id="mic-none"><path d="M12 14c1.66 0 2.99-1.34 2.99-3L15 5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm-1.2-9.1c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2l-.01 6.2c0 .66-.53 1.2-1.19 1.2-.66 0-1.2-.54-1.2-1.2V4.9zm6.5 6.1c0 3-2.54 5.1-5.3 5.1S6.7 14 6.7 11H5c0 3.41 2.72 6.23 6 6.72V21h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"/></g> +<g id="mic-off"><path d="M19 11h-1.7c0 .74-.16 1.43-.43 2.05l1.23 1.23c.56-.98.9-2.09.9-3.28zm-4.02.17c0-.06.02-.11.02-.17V5c0-1.66-1.34-3-3-3S9 3.34 9 5v.18l5.98 5.99zM4.27 3L3 4.27l6.01 6.01V11c0 1.66 1.33 3 2.99 3 .22 0 .44-.03.65-.08l1.66 1.66c-.71.33-1.5.52-2.31.52-2.76 0-5.3-2.1-5.3-5.1H5c0 3.41 2.72 6.23 6 6.72V21h2v-3.28c.91-.13 1.77-.45 2.54-.9L19.73 21 21 19.73 4.27 3z"/></g> +<g id="movie"><path d="M18 4l2 4h-3l-2-4h-2l2 4h-3l-2-4H8l2 4H7L5 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4h-4z"/></g> +<g id="new-releases"><path d="M23 12l-2.44-2.78.34-3.68-3.61-.82-1.89-3.18L12 3 8.6 1.54 6.71 4.72l-3.61.81.34 3.68L1 12l2.44 2.78-.34 3.69 3.61.82 1.89 3.18L12 21l3.4 1.46 1.89-3.18 3.61-.82-.34-3.68L23 12zm-10 5h-2v-2h2v2zm0-4h-2V7h2v6z"/></g> +<g id="not-interested"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8 0-1.85.63-3.55 1.69-4.9L16.9 18.31C15.55 19.37 13.85 20 12 20zm6.31-3.1L7.1 5.69C8.45 4.63 10.15 4 12 4c4.42 0 8 3.58 8 8 0 1.85-.63 3.55-1.69 4.9z"/></g> +<g id="pause"><path d="M6 19h4V5H6v14zm8-14v14h4V5h-4z"/></g> +<g id="pause-circle-filled"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 14H9V8h2v8zm4 0h-2V8h2v8z"/></g> +<g id="pause-circle-outline"><path d="M9 16h2V8H9v8zm3-14C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm1-4h2V8h-2v8z"/></g> +<g id="play-arrow"><path d="M8 5v14l11-7z"/></g> +<g id="play-circle-filled"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 14.5v-9l6 4.5-6 4.5z"/></g> +<g id="play-circle-outline"><path d="M10 16.5l6-4.5-6-4.5v9zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="playlist-add"><path d="M14 10H2v2h12v-2zm0-4H2v2h12V6zm4 8v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zM2 16h8v-2H2v2z"/></g> +<g id="queue"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/></g> +<g id="queue-music"><path d="M15 6H3v2h12V6zm0 4H3v2h12v-2zM3 16h8v-2H3v2zM17 6v8.18c-.31-.11-.65-.18-1-.18-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3V8h3V6h-5z"/></g> +<g id="radio"><path d="M3.24 6.15C2.51 6.43 2 7.17 2 8v12c0 1.1.89 2 2 2h16c1.11 0 2-.9 2-2V8c0-1.11-.89-2-2-2H8.3l8.26-3.34L15.88 1 3.24 6.15zM7 20c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm13-8h-2v-2h-2v2H4V8h16v4z"/></g> +<g id="recent-actors"><path d="M21 5v14h2V5h-2zm-4 14h2V5h-2v14zM14 5H2c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h12c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zM8 7.75c1.24 0 2.25 1.01 2.25 2.25S9.24 12.25 8 12.25 5.75 11.24 5.75 10 6.76 7.75 8 7.75zM12.5 17h-9v-.75c0-1.5 3-2.25 4.5-2.25s4.5.75 4.5 2.25V17z"/></g> +<g id="repeat"><path d="M7 7h10v3l4-4-4-4v3H5v6h2V7zm10 10H7v-3l-4 4 4 4v-3h12v-6h-2v4z"/></g> +<g id="repeat-one"><path d="M7 7h10v3l4-4-4-4v3H5v6h2V7zm10 10H7v-3l-4 4 4 4v-3h12v-6h-2v4zm-4-2V9h-1l-2 1v1h1.5v4H13z"/></g> +<g id="replay"><path d="M12 5V1L7 6l5 5V7c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6H4c0 4.42 3.58 8 8 8s8-3.58 8-8-3.58-8-8-8z"/></g> +<g id="replay-10"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M12 5V1L7 6l5 5V7c3.3 0 6 2.7 6 6s-2.7 6-6 6-6-2.7-6-6H4c0 4.4 3.6 8 8 8s8-3.6 8-8-3.6-8-8-8zm-1.1 11H10v-3.3L9 13v-.7l1.8-.6h.1V16zm4.3-1.8c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1c.2.1.3.2.5.3s.2.3.3.6.1.5.1.8v.7zm-.9-.8v-.5s-.1-.2-.1-.3-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5z" clip-path="url(#b)"/></g> +<g id="replay-30"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M12 5V1L7 6l5 5V7c3.3 0 6 2.7 6 6s-2.7 6-6 6-6-2.7-6-6H4c0 4.4 3.6 8 8 8s8-3.6 8-8-3.6-8-8-8zm-2.4 8.5h.4c.2 0 .4-.1.5-.2s.2-.2.2-.4v-.2s-.1-.1-.1-.2-.1-.1-.2-.1h-.5s-.1.1-.2.1-.1.1-.1.2v.2h-1c0-.2 0-.3.1-.5s.2-.3.3-.4.3-.2.4-.2.4-.1.5-.1c.2 0 .4 0 .6.1s.3.1.5.2.2.2.3.4.1.3.1.5v.3s-.1.2-.1.3-.1.2-.2.2-.2.1-.3.2c.2.1.4.2.5.4s.2.4.2.6c0 .2 0 .4-.1.5s-.2.3-.3.4-.3.2-.5.2-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.4-.1-.6h.8v.2s.1.1.1.2.1.1.2.1h.5s.1-.1.2-.1.1-.1.1-.2v-.5s-.1-.1-.1-.2-.1-.1-.2-.1h-.6v-.7zm5.7.7c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1.3.2.5.3.2.3.3.6.1.5.1.8v.7zm-.8-.8v-.5c0-.1-.1-.2-.1-.3s-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5z" clip-path="url(#b)"/></g> +<g id="replay-5"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M12 5V1L7 6l5 5V7c3.3 0 6 2.7 6 6s-2.7 6-6 6-6-2.7-6-6H4c0 4.4 3.6 8 8 8s8-3.6 8-8-3.6-8-8-8zm-1.3 8.9l.2-2.2h2.4v.7h-1.7l-.1.9s.1 0 .1-.1.1 0 .1-.1.1 0 .2 0h.2c.2 0 .4 0 .5.1s.3.2.4.3.2.3.3.5.1.4.1.6c0 .2 0 .4-.1.5s-.1.3-.3.5-.3.2-.4.3-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.3-.1-.5h.8c0 .2.1.3.2.4s.2.1.4.1c.1 0 .2 0 .3-.1l.2-.2s.1-.2.1-.3v-.6l-.1-.2-.2-.2s-.2-.1-.3-.1h-.2s-.1 0-.2.1-.1 0-.1.1-.1.1-.1.1h-.7z" clip-path="url(#b)"/></g> +<g id="shuffle"><path d="M10.59 9.17L5.41 4 4 5.41l5.17 5.17 1.42-1.41zM14.5 4l2.04 2.04L4 18.59 5.41 20 17.96 7.46 20 9.5V4h-5.5zm.33 9.41l-1.41 1.41 3.13 3.13L14.5 20H20v-5.5l-2.04 2.04-3.13-3.13z"/></g> +<g id="skip-next"><path d="M6 18l8.5-6L6 6v12zM16 6v12h2V6h-2z"/></g> +<g id="skip-previous"><path d="M6 6h2v12H6zm3.5 6l8.5 6V6z"/></g> +<g id="snooze"><path d="M7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm-3-9h3.63L9 15.2V17h6v-2h-3.63L15 10.8V9H9v2z"/></g> +<g id="sort-by-alpha"><path d="M14.94 4.66h-4.72l2.36-2.36zm-4.69 14.71h4.66l-2.33 2.33zM6.1 6.27L1.6 17.73h1.84l.92-2.45h5.11l.92 2.45h1.84L7.74 6.27H6.1zm-1.13 7.37l1.94-5.18 1.94 5.18H4.97zm10.76 2.5h6.12v1.59h-8.53v-1.29l5.92-8.56h-5.88v-1.6h8.3v1.26l-5.93 8.6z"/></g> +<g id="stop"><path d="M6 6h12v12H6z"/></g> +<g id="subtitles"><path d="M20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM4 12h4v2H4v-2zm10 6H4v-2h10v2zm6 0h-4v-2h4v2zm0-4H10v-2h10v2z"/></g> +<g id="surround-sound"><path d="M20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM7.76 16.24l-1.41 1.41C4.78 16.1 4 14.05 4 12c0-2.05.78-4.1 2.34-5.66l1.41 1.41C6.59 8.93 6 10.46 6 12s.59 3.07 1.76 4.24zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm5.66 1.66l-1.41-1.41C17.41 15.07 18 13.54 18 12s-.59-3.07-1.76-4.24l1.41-1.41C19.22 7.9 20 9.95 20 12c0 2.05-.78 4.1-2.34 5.66zM12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="video-library"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-8 12.5v-9l6 4.5-6 4.5z"/></g> +<g id="videocam"><path d="M17 10.5V7c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.55 0 1-.45 1-1v-3.5l4 4v-11l-4 4z"/></g> +<g id="videocam-off"><path d="M21 6.5l-4 4V7c0-.55-.45-1-1-1H9.82L21 17.18V6.5zM3.27 2L2 3.27 4.73 6H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.21 0 .39-.08.54-.18L19.73 21 21 19.73 3.27 2z"/></g> +<g id="volume-down"><path d="M18.5 12c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM5 9v6h4l5 5V4L9 9H5z"/></g> +<g id="volume-mute"><path d="M7 9v6h4l5 5V4l-5 5H7z"/></g> +<g id="volume-off"><path d="M16.5 12c0-1.77-1.02-3.29-2.5-4.03v2.21l2.45 2.45c.03-.2.05-.41.05-.63zm2.5 0c0 .94-.2 1.82-.54 2.64l1.51 1.51C20.63 14.91 21 13.5 21 12c0-4.28-2.99-7.86-7-8.77v2.06c2.89.86 5 3.54 5 6.71zM4.27 3L3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25c-.67.52-1.42.93-2.25 1.18v2.06c1.38-.31 2.63-.95 3.69-1.81L19.73 21 21 19.73l-9-9L4.27 3zM12 4L9.91 6.09 12 8.18V4z"/></g> +<g id="volume-up"><path d="M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"/></g> +<g id="web"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 14H4v-4h11v4zm0-5H4V9h11v4zm5 5h-4V9h4v9z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/bower.json b/third_party/polymer/v1_0/components-chromium/iron-icons/bower.json new file mode 100644 index 0000000..1ba69fb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-icons", + "version": "1.0.1", + "description": "A set of icons for use with iron-icon", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "main": "iron-icons.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-icons" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-icons", + "dependencies": { + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "ignore": [ + "util", + "update-icons.sh" + ] +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/communication-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/communication-icons.html new file mode 100644 index 0000000..ec72704 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/communication-icons.html @@ -0,0 +1,59 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="communication" size="24"> +<svg><defs> +<g id="business"><path d="M12 7V3H2v18h20V7H12zM6 19H4v-2h2v2zm0-4H4v-2h2v2zm0-4H4V9h2v2zm0-4H4V5h2v2zm4 12H8v-2h2v2zm0-4H8v-2h2v2zm0-4H8V9h2v2zm0-4H8V5h2v2zm10 12h-8v-2h2v-2h-2v-2h2v-2h-2V9h8v10zm-2-8h-2v2h2v-2zm0 4h-2v2h2v-2z"/></g> +<g id="call"><path d="M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z"/></g> +<g id="call-end"><path d="M12 9c-1.6 0-3.15.25-4.6.72v3.1c0 .39-.23.74-.56.9-.98.49-1.87 1.12-2.66 1.85-.18.18-.43.28-.7.28-.28 0-.53-.11-.71-.29L.29 13.08c-.18-.17-.29-.42-.29-.7 0-.28.11-.53.29-.71C3.34 8.78 7.46 7 12 7s8.66 1.78 11.71 4.67c.18.18.29.43.29.71 0 .28-.11.53-.29.71l-2.48 2.48c-.18.18-.43.29-.71.29-.27 0-.52-.11-.7-.28-.79-.74-1.69-1.36-2.67-1.85-.33-.16-.56-.5-.56-.9v-3.1C15.15 9.25 13.6 9 12 9z"/></g> +<g id="call-made"><path d="M9 5v2h6.59L4 18.59 5.41 20 17 8.41V15h2V5z"/></g> +<g id="call-merge"><path d="M17 20.41L18.41 19 15 15.59 13.59 17 17 20.41zM7.5 8H11v5.59L5.59 19 7 20.41l6-6V8h3.5L12 3.5 7.5 8z"/></g> +<g id="call-missed"><path d="M19.59 7L12 14.59 6.41 9H11V7H3v8h2v-4.59l7 7 9-9z"/></g> +<g id="call-received"><path d="M20 5.41L18.59 4 7 15.59V9H5v10h10v-2H8.41z"/></g> +<g id="call-split"><path d="M14 4l2.29 2.29-2.88 2.88 1.42 1.42 2.88-2.88L20 10V4zm-4 0H4v6l2.29-2.29 4.71 4.7V20h2v-8.41l-5.29-5.3z"/></g> +<g id="chat"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 9h12v2H6V9zm8 5H6v-2h8v2zm4-6H6V6h12v2z"/></g> +<g id="chat-bubble"><path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2z"/></g> +<g id="chat-bubble-outline"><path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H6l-2 2V4h16v12z"/></g> +<g id="clear-all"><path d="M5 13h14v-2H5v2zm-2 4h14v-2H3v2zM7 7v2h14V7H7z"/></g> +<g id="comment"><path d="M21.99 4c0-1.1-.89-2-1.99-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4-.01-18zM18 14H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z"/></g> +<g id="contact-phone"><path d="M22 3H2C.9 3 0 3.9 0 5v14c0 1.1.9 2 2 2h20c1.1 0 1.99-.9 1.99-2L24 5c0-1.1-.9-2-2-2zM8 6c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H2v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1zm3.85-4h1.64L21 16l-1.99 1.99c-1.31-.98-2.28-2.38-2.73-3.99-.18-.64-.28-1.31-.28-2s.1-1.36.28-2c.45-1.62 1.42-3.01 2.73-3.99L21 8l-1.51 2h-1.64c-.22.63-.35 1.3-.35 2s.13 1.37.35 2z"/></g> +<g id="contacts"><path d="M20 0H4v2h16V0zM4 24h16v-2H4v2zM20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 2.75c1.24 0 2.25 1.01 2.25 2.25s-1.01 2.25-2.25 2.25S9.75 10.24 9.75 9 10.76 6.75 12 6.75zM17 17H7v-1.5c0-1.67 3.33-2.5 5-2.5s5 .83 5 2.5V17z"/></g> +<g id="dialer-sip"><path d="M17 3h-1v5h1V3zm-2 2h-2V4h2V3h-3v3h2v1h-2v1h3V5zm3-2v5h1V6h2V3h-3zm2 2h-1V4h1v1zm0 10.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.01.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.27-.26.35-.65.24-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1z"/></g> +<g id="dialpad"><path d="M12 19c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 1c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12-8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-6 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="email"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="forum"><path d="M21 6h-2v9H6v2c0 .55.45 1 1 1h11l4 4V7c0-.55-.45-1-1-1zm-4 6V3c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v14l4-4h10c.55 0 1-.45 1-1z"/></g> +<g id="import-export"><path d="M9 3L5 6.99h3V14h2V6.99h3L9 3zm7 14.01V10h-2v7.01h-3L15 21l4-3.99h-3z"/></g> +<g id="invert-colors-off"><path d="M20.65 20.87l-2.35-2.35-6.3-6.29-3.56-3.57-1.42-1.41L4.27 4.5 3 5.77l2.78 2.78c-2.55 3.14-2.36 7.76.56 10.69C7.9 20.8 9.95 21.58 12 21.58c1.79 0 3.57-.59 5.03-1.78l2.7 2.7L21 21.23l-.35-.36zM12 19.59c-1.6 0-3.11-.62-4.24-1.76C6.62 16.69 6 15.19 6 13.59c0-1.32.43-2.57 1.21-3.6L12 14.77v4.82zM12 5.1v4.58l7.25 7.26c1.37-2.96.84-6.57-1.6-9.01L12 2.27l-3.7 3.7 1.41 1.41L12 5.1z"/></g> +<g id="live-help"><path d="M19 2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h4l3 3 3-3h4c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6 16h-2v-2h2v2zm2.07-7.75l-.9.92C13.45 11.9 13 12.5 13 14h-2v-.5c0-1.1.45-2.1 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41 0-1.1-.9-2-2-2s-2 .9-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 .88-.36 1.68-.93 2.25z"/></g> +<g id="location-off"><path d="M12 6.5c1.38 0 2.5 1.12 2.5 2.5 0 .74-.33 1.39-.83 1.85l3.63 3.63c.98-1.86 1.7-3.8 1.7-5.48 0-3.87-3.13-7-7-7-1.98 0-3.76.83-5.04 2.15l3.19 3.19c.46-.52 1.11-.84 1.85-.84zm4.37 9.6l-4.63-4.63-.11-.11L3.27 3 2 4.27l3.18 3.18C5.07 7.95 5 8.47 5 9c0 5.25 7 13 7 13s1.67-1.85 3.38-4.35L18.73 21 20 19.73l-3.63-3.63z"/></g> +<g id="location-on"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="mail"><path d="M21 8V7l-3 2-3-2v1l3 2 3-2zm1-5H2C.9 3 0 3.9 0 5v14c0 1.1.9 2 2 2h20c1.1 0 1.99-.9 1.99-2L24 5c0-1.1-.9-2-2-2zM8 6c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H2v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1zm8-6h-8V6h8v6z"/></g> +<g id="message"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-2 12H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z"/></g> +<g id="no-sim"><path d="M18.99 5c0-1.1-.89-2-1.99-2h-7L7.66 5.34 19 16.68 18.99 5zM3.65 3.88L2.38 5.15 5 7.77V19c0 1.1.9 2 2 2h10.01c.35 0 .67-.1.96-.26l1.88 1.88 1.27-1.27L3.65 3.88z"/></g> +<g id="phone"><path d="M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z"/></g> +<g id="phonelink-erase"><path d="M13 8.2l-1-1-4 4-4-4-1 1 4 4-4 4 1 1 4-4 4 4 1-1-4-4 4-4zM19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2z"/></g> +<g id="phonelink-lock"><path d="M19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm-8.2 10V9.5C10.8 8.1 9.4 7 8 7S5.2 8.1 5.2 9.5V11c-.6 0-1.2.6-1.2 1.2v3.5c0 .7.6 1.3 1.2 1.3h5.5c.7 0 1.3-.6 1.3-1.2v-3.5c0-.7-.6-1.3-1.2-1.3zm-1.3 0h-3V9.5c0-.8.7-1.3 1.5-1.3s1.5.5 1.5 1.3V11z"/></g> +<g id="phonelink-ring"><path d="M20.1 7.7l-1 1c1.8 1.8 1.8 4.6 0 6.5l1 1c2.5-2.3 2.5-6.1 0-8.5zM18 9.8l-1 1c.5.7.5 1.6 0 2.3l1 1c1.2-1.2 1.2-3 0-4.3zM14 1H4c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 19H4V4h10v16z"/></g> +<g id="phonelink-setup"><path d="M11.8 12.5v-1l1.1-.8c.1-.1.1-.2.1-.3l-1-1.7c-.1-.1-.2-.2-.3-.1l-1.3.4c-.3-.2-.6-.4-.9-.5l-.2-1.3c0-.1-.1-.2-.3-.2H7c-.1 0-.2.1-.3.2l-.2 1.3c-.3.1-.6.3-.9.5l-1.3-.5c-.1 0-.2 0-.3.1l-1 1.7c-.1.1 0 .2.1.3l1.1.8v1l-1.1.8c-.1.2-.1.3-.1.4l1 1.7c.1.1.2.2.3.1l1.4-.4c.3.2.6.4.9.5l.2 1.3c-.1.1.1.2.2.2h2c.1 0 .2-.1.3-.2l.2-1.3c.3-.1.6-.3.9-.5l1.3.5c.1 0 .2 0 .3-.1l1-1.7c.1-.1 0-.2-.1-.3l-1.1-.9zM8 14c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2z"/></g> +<g id="portable-wifi-off"><path d="M17.56 14.24c.28-.69.44-1.45.44-2.24 0-3.31-2.69-6-6-6-.79 0-1.55.16-2.24.44l1.62 1.62c.2-.03.41-.06.62-.06 2.21 0 4 1.79 4 4 0 .21-.02.42-.05.63l1.61 1.61zM12 4c4.42 0 8 3.58 8 8 0 1.35-.35 2.62-.95 3.74l1.47 1.47C21.46 15.69 22 13.91 22 12c0-5.52-4.48-10-10-10-1.91 0-3.69.55-5.21 1.47l1.46 1.46C9.37 4.34 10.65 4 12 4zM3.27 2.5L2 3.77l2.1 2.1C2.79 7.57 2 9.69 2 12c0 3.7 2.01 6.92 4.99 8.65l1-1.73C5.61 17.53 4 14.96 4 12c0-1.76.57-3.38 1.53-4.69l1.43 1.44C6.36 9.68 6 10.8 6 12c0 2.22 1.21 4.15 3 5.19l1-1.74c-1.19-.7-2-1.97-2-3.45 0-.65.17-1.25.44-1.79l1.58 1.58L10 12c0 1.1.9 2 2 2l.21-.02.01.01 7.51 7.51L21 20.23 4.27 3.5l-1-1z"/></g> +<g id="present-to-all"><path d="M21 3H3c-1.11 0-2 .89-2 2v14c0 1.11.89 2 2 2h18c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2zm0 16.02H3V4.98h18v14.04zM10 12H8l4-4 4 4h-2v4h-4v-4z"/></g> +<g id="ring-volume"><path d="M23.71 16.67C20.66 13.78 16.54 12 12 12 7.46 12 3.34 13.78.29 16.67c-.18.18-.29.43-.29.71 0 .28.11.53.29.71l2.48 2.48c.18.18.43.29.71.29.27 0 .52-.11.7-.28.79-.74 1.69-1.36 2.66-1.85.33-.16.56-.5.56-.9v-3.1c1.45-.48 3-.73 4.6-.73s3.15.25 4.6.72v3.1c0 .39.23.74.56.9.98.49 1.87 1.12 2.66 1.85.18.18.43.28.7.28.28 0 .53-.11.71-.29l2.48-2.48c.18-.18.29-.43.29-.71 0-.27-.11-.52-.29-.7zM21.16 6.26l-1.41-1.41-3.56 3.55 1.41 1.41s3.45-3.52 3.56-3.55zM13 2h-2v5h2V2zM6.4 9.81L7.81 8.4 4.26 4.84 2.84 6.26c.11.03 3.56 3.55 3.56 3.55z"/></g> +<g id="speaker-phone"><path d="M7 7.07L8.43 8.5c.91-.91 2.18-1.48 3.57-1.48s2.66.57 3.57 1.48L17 7.07C15.72 5.79 13.95 5 12 5s-3.72.79-5 2.07zM12 1C8.98 1 6.24 2.23 4.25 4.21l1.41 1.41C7.28 4 9.53 3 12 3s4.72 1 6.34 2.62l1.41-1.41C17.76 2.23 15.02 1 12 1zm2.86 9.01L9.14 10C8.51 10 8 10.51 8 11.14v9.71c0 .63.51 1.14 1.14 1.14h5.71c.63 0 1.14-.51 1.14-1.14v-9.71c.01-.63-.5-1.13-1.13-1.13zM15 20H9v-8h6v8z"/></g> +<g id="stay-current-landscape"><path d="M1.01 7L1 17c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2H3c-1.1 0-1.99.9-1.99 2zM19 7v10H5V7h14z"/></g> +<g id="stay-current-portrait"><path d="M17 1.01L7 1c-1.1 0-1.99.9-1.99 2v18c0 1.1.89 2 1.99 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="stay-primary-landscape"><path d="M1.01 7L1 17c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2H3c-1.1 0-1.99.9-1.99 2zM19 7v10H5V7h14z"/></g> +<g id="stay-primary-portrait"><path d="M17 1.01L7 1c-1.1 0-1.99.9-1.99 2v18c0 1.1.89 2 1.99 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="swap-calls"><path d="M18 4l-4 4h3v7c0 1.1-.9 2-2 2s-2-.9-2-2V8c0-2.21-1.79-4-4-4S5 5.79 5 8v7H2l4 4 4-4H7V8c0-1.1.9-2 2-2s2 .9 2 2v7c0 2.21 1.79 4 4 4s4-1.79 4-4V8h3l-4-4z"/></g> +<g id="textsms"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM9 11H7V9h2v2zm4 0h-2V9h2v2zm4 0h-2V9h2v2z"/></g> +<g id="voicemail"><path d="M18.5 6C15.46 6 13 8.46 13 11.5c0 1.33.47 2.55 1.26 3.5H9.74c.79-.95 1.26-2.17 1.26-3.5C11 8.46 8.54 6 5.5 6S0 8.46 0 11.5 2.46 17 5.5 17h13c3.04 0 5.5-2.46 5.5-5.5S21.54 6 18.5 6zm-13 9C3.57 15 2 13.43 2 11.5S3.57 8 5.5 8 9 9.57 9 11.5 7.43 15 5.5 15zm13 0c-1.93 0-3.5-1.57-3.5-3.5S16.57 8 18.5 8 22 9.57 22 11.5 20.43 15 18.5 15z"/></g> +<g id="vpn-key"><path d="M12.65 10C11.83 7.67 9.61 6 7 6c-3.31 0-6 2.69-6 6s2.69 6 6 6c2.61 0 4.83-1.67 5.65-4H17v4h4v-4h2v-4H12.65zM7 14c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/device-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/device-icons.html new file mode 100644 index 0000000..e875a05 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/device-icons.html @@ -0,0 +1,94 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="device" size="24"> +<svg><defs> +<g id="access-alarm"><path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="access-alarms"><path d="M22 5.7l-4.6-3.9-1.3 1.5 4.6 3.9L22 5.7zM7.9 3.4L6.6 1.9 2 5.7l1.3 1.5 4.6-3.8zM12.5 8H11v6l4.7 2.9.8-1.2-4-2.4V8zM12 4c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7z"/></g> +<g id="access-time"><path fill-opacity=".9" d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zM12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></g> +<g id="add-alarm"><path d="M7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm1-11h-2v3H8v2h3v3h2v-3h3v-2h-3V9z"/></g> +<g id="airplanemode-active"><path d="M10.18 9"/><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/></g> +<g id="airplanemode-inactive"><path d="M13 9V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v3.68l7.83 7.83L21 16v-2l-8-5zM3 5.27l4.99 4.99L2 14v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-3.73L18.73 21 20 19.73 4.27 4 3 5.27z"/></g> +<g id="battery-20"><path d="M7 17v3.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V17H7z"/><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V17h10V5.33z"/></g> +<g id="battery-30"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V15h10V5.33z"/><path d="M7 15v5.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V15H7z"/></g> +<g id="battery-50"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V13h10V5.33z"/><path d="M7 13v7.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V13H7z"/></g> +<g id="battery-60"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V11h10V5.33z"/><path d="M7 11v9.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V11H7z"/></g> +<g id="battery-80"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V9h10V5.33z"/><path d="M7 9v11.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V9H7z"/></g> +<g id="battery-90"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V8h10V5.33z"/><path d="M7 8v12.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V8H7z"/></g> +<g id="battery-alert"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4zM13 18h-2v-2h2v2zm0-4h-2V9h2v5z"/></g> +<g id="battery-charging-20"><path d="M11 20v-3H7v3.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V17h-4.4L11 20z"/><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V17h4v-2.5H9L13 7v5.5h2L12.6 17H17V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-charging-30"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v9.17h2L13 7v5.5h2l-1.07 2H17V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M11 20v-5.5H7v6.17C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V14.5h-3.07L11 20z"/></g> +<g id="battery-charging-50"><path d="M14.47 13.5L11 20v-5.5H9l.53-1H7v7.17C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V13.5h-2.53z"/><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v8.17h2.53L13 7v5.5h2l-.53 1H17V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-charging-60"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V11h3.87L13 7v4h4V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M13 12.5h2L11 20v-5.5H9l1.87-3.5H7v9.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V11h-4v1.5z"/></g> +<g id="battery-charging-80"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V9h4.93L13 7v2h4V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M13 12.5h2L11 20v-5.5H9L11.93 9H7v11.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V9h-4v3.5z"/></g> +<g id="battery-charging-90"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V8h5.47L13 7v1h4V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M13 12.5h2L11 20v-5.5H9L12.47 8H7v12.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V8h-4v4.5z"/></g> +<g id="battery-charging-full"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4zM11 20v-5.5H9L13 7v5.5h2L11 20z"/></g> +<g id="battery-full"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-std"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-unknown"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4zm-2.72 13.95h-1.9v-1.9h1.9v1.9zm1.35-5.26s-.38.42-.67.71c-.48.48-.83 1.15-.83 1.6h-1.6c0-.83.46-1.52.93-2l.93-.94c.27-.27.44-.65.44-1.06 0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5H9c0-1.66 1.34-3 3-3s3 1.34 3 3c0 .66-.27 1.26-.7 1.69z"/></g> +<g id="bluetooth"><path d="M17.71 7.71L12 2h-1v7.59L6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 5.83l1.88 1.88L13 9.59V5.83zm1.88 10.46L13 18.17v-3.76l1.88 1.88z"/></g> +<g id="bluetooth-connected"><path d="M7 12l-2-2-2 2 2 2 2-2zm10.71-4.29L12 2h-1v7.59L6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 5.83l1.88 1.88L13 9.59V5.83zm1.88 10.46L13 18.17v-3.76l1.88 1.88zM19 10l-2 2 2 2 2-2-2-2z"/></g> +<g id="bluetooth-disabled"><path d="M13 5.83l1.88 1.88-1.6 1.6 1.41 1.41 3.02-3.02L12 2h-1v5.03l2 2v-3.2zM5.41 4L4 5.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l4.29-4.29 2.3 2.29L20 18.59 5.41 4zM13 18.17v-3.76l1.88 1.88L13 18.17z"/></g> +<g id="bluetooth-searching"><path d="M14.24 12.01l2.32 2.32c.28-.72.44-1.51.44-2.33 0-.82-.16-1.59-.43-2.31l-2.33 2.32zm5.29-5.3l-1.26 1.26c.63 1.21.98 2.57.98 4.02s-.36 2.82-.98 4.02l1.2 1.2c.97-1.54 1.54-3.36 1.54-5.31-.01-1.89-.55-3.67-1.48-5.19zm-3.82 1L10 2H9v7.59L4.41 5 3 6.41 8.59 12 3 17.59 4.41 19 9 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM11 5.83l1.88 1.88L11 9.59V5.83zm1.88 10.46L11 18.17v-3.76l1.88 1.88z"/></g> +<g id="brightness-auto"><path d="M10.85 12.65h2.3L12 9l-1.15 3.65zM20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM14.3 16l-.7-2h-3.2l-.7 2H7.8L11 7h2l3.2 9h-1.9z"/></g> +<g id="brightness-high"><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6zm0-10c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4z"/></g> +<g id="brightness-low"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6z"/></g> +<g id="brightness-medium"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18V6c3.31 0 6 2.69 6 6s-2.69 6-6 6z"/></g> +<g id="data-usage"><path d="M13 2.05v3.03c3.39.49 6 3.39 6 6.92 0 .9-.18 1.75-.48 2.54l2.6 1.53c.56-1.24.88-2.62.88-4.07 0-5.18-3.95-9.45-9-9.95zM12 19c-3.87 0-7-3.13-7-7 0-3.53 2.61-6.43 6-6.92V2.05c-5.06.5-9 4.76-9 9.95 0 5.52 4.47 10 9.99 10 3.31 0 6.24-1.61 8.06-4.09l-2.6-1.53C16.17 17.98 14.21 19 12 19z"/></g> +<g id="developer-mode"><path d="M7 5h10v2h2V3c0-1.1-.9-1.99-2-1.99L7 1c-1.1 0-2 .9-2 2v4h2V5zm8.41 11.59L20 12l-4.59-4.59L14 8.83 17.17 12 14 15.17l1.41 1.42zM10 15.17L6.83 12 10 8.83 8.59 7.41 4 12l4.59 4.59L10 15.17zM17 19H7v-2H5v4c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2v-4h-2v2z"/></g> +<g id="devices"><path d="M4 6h18V4H4c-1.1 0-2 .9-2 2v11H0v3h14v-3H4V6zm19 2h-6c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zm-1 9h-4v-7h4v7z"/></g> +<g id="dvr"><path d="M21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.1-.9-2-2-2zm0 14H3V5h18v12zm-2-9H8v2h11V8zm0 4H8v2h11v-2zM7 8H5v2h2V8zm0 4H5v2h2v-2z"/></g> +<g id="gps-fixed"><path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm8.94 3c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="gps-not-fixed"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="gps-off"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06c-1.13.12-2.19.46-3.16.97l1.5 1.5C10.16 5.19 11.06 5 12 5c3.87 0 7 3.13 7 7 0 .94-.19 1.84-.52 2.65l1.5 1.5c.5-.96.84-2.02.97-3.15H23v-2h-2.06zM3 4.27l2.04 2.04C3.97 7.62 3.25 9.23 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c1.77-.2 3.38-.91 4.69-1.98L19.73 21 21 19.73 4.27 3 3 4.27zm13.27 13.27C15.09 18.45 13.61 19 12 19c-3.87 0-7-3.13-7-7 0-1.61.55-3.09 1.46-4.27l9.81 9.81z"/></g> +<g id="graphic-eq"><path d="M7 18h2V6H7v12zm4 4h2V2h-2v20zm-8-8h2v-4H3v4zm12 4h2V6h-2v12zm4-8v4h2v-4h-2z"/></g> +<g id="location-disabled"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06c-1.13.12-2.19.46-3.16.97l1.5 1.5C10.16 5.19 11.06 5 12 5c3.87 0 7 3.13 7 7 0 .94-.19 1.84-.52 2.65l1.5 1.5c.5-.96.84-2.02.97-3.15H23v-2h-2.06zM3 4.27l2.04 2.04C3.97 7.62 3.25 9.23 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c1.77-.2 3.38-.91 4.69-1.98L19.73 21 21 19.73 4.27 3 3 4.27zm13.27 13.27C15.09 18.45 13.61 19 12 19c-3.87 0-7-3.13-7-7 0-1.61.55-3.09 1.46-4.27l9.81 9.81z"/></g> +<g id="location-searching"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="network-cell"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M17 7L2 22h15z"/></g> +<g id="network-wifi"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M3.53 10.95l8.46 10.54.01.01.01-.01 8.46-10.54C20.04 10.62 16.81 8 12 8c-4.81 0-8.04 2.62-8.47 2.95z"/></g> +<g id="nfc"><path d="M20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 18H4V4h16v16zM18 6h-5c-1.1 0-2 .9-2 2v2.28c-.6.35-1 .98-1 1.72 0 1.1.9 2 2 2s2-.9 2-2c0-.74-.4-1.38-1-1.72V8h3v8H8V8h2V6H6v12h12V6z"/></g> +<g id="screen-lock-landscape"><path d="M21 5H3c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-2 12H5V7h14v10zm-9-1h4c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1v-1c0-1.11-.9-2-2-2-1.11 0-2 .9-2 2v1c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1zm.8-6c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2v1h-2.4v-1z"/></g> +<g id="screen-lock-portrait"><path d="M10 16h4c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1v-1c0-1.11-.9-2-2-2-1.11 0-2 .9-2 2v1c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1zm.8-6c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2v1h-2.4v-1zM17 1H7c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 18H7V5h10v14z"/></g> +<g id="screen-lock-rotation"><path d="M23.25 12.77l-2.57-2.57-1.41 1.41 2.22 2.22-5.66 5.66L4.51 8.17l5.66-5.66 2.1 2.1 1.41-1.41L11.23.75c-.59-.59-1.54-.59-2.12 0L2.75 7.11c-.59.59-.59 1.54 0 2.12l12.02 12.02c.59.59 1.54.59 2.12 0l6.36-6.36c.59-.59.59-1.54 0-2.12zM8.47 20.48C5.2 18.94 2.86 15.76 2.5 12H1c.51 6.16 5.66 11 11.95 11l.66-.03-3.81-3.82-1.33 1.33zM16 9h5c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1v-.5C21 1.12 19.88 0 18.5 0S16 1.12 16 2.5V3c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1zm.8-6.5c0-.94.76-1.7 1.7-1.7s1.7.76 1.7 1.7V3h-3.4v-.5z"/></g> +<g id="screen-rotation"><path d="M16.48 2.52c3.27 1.55 5.61 4.72 5.97 8.48h1.5C23.44 4.84 18.29 0 12 0l-.66.03 3.81 3.81 1.33-1.32zm-6.25-.77c-.59-.59-1.54-.59-2.12 0L1.75 8.11c-.59.59-.59 1.54 0 2.12l12.02 12.02c.59.59 1.54.59 2.12 0l6.36-6.36c.59-.59.59-1.54 0-2.12L10.23 1.75zm4.6 19.44L2.81 9.17l6.36-6.36 12.02 12.02-6.36 6.36zm-7.31.29C4.25 19.94 1.91 16.76 1.55 13H.05C.56 19.16 5.71 24 12 24l.66-.03-3.81-3.81-1.33 1.32z"/></g> +<g id="sd-storage"><path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6 6h-2V4h2v4zm3 0h-2V4h2v4zm3 0h-2V4h2v4z"/></g> +<g id="settings-system-daydream"><path d="M9 16h6.5c1.38 0 2.5-1.12 2.5-2.5S16.88 11 15.5 11h-.05c-.24-1.69-1.69-3-3.45-3-1.4 0-2.6.83-3.16 2.02h-.16C7.17 10.18 6 11.45 6 13c0 1.66 1.34 3 3 3zM21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/></g> +<g id="signal-cellular-0-bar"><path fill-opacity=".3" d="M2 22h20V2z"/></g> +<g id="signal-cellular-1-bar"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M12 12L2 22h10z"/></g> +<g id="signal-cellular-2-bar"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M14 10L2 22h12z"/></g> +<g id="signal-cellular-3-bar"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M17 7L2 22h15z"/></g> +<g id="signal-cellular-4-bar"><path d="M2 22h20V2z"/></g> +<g id="signal-cellular-connected-no-internet-0-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M20 22h2v-2h-2v2zm0-12v8h2v-8h-2z"/></g> +<g id="signal-cellular-connected-no-internet-1-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M20 10v8h2v-8h-2zm-8 12V12L2 22h10zm8 0h2v-2h-2v2z"/></g> +<g id="signal-cellular-connected-no-internet-2-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M14 22V10L2 22h12zm6-12v8h2v-8h-2zm0 12h2v-2h-2v2z"/></g> +<g id="signal-cellular-connected-no-internet-3-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M17 22V7L2 22h15zm3-12v8h2v-8h-2zm0 12h2v-2h-2v2z"/></g> +<g id="signal-cellular-connected-no-internet-4-bar"><path d="M20 18h2v-8h-2v8zm0 4h2v-2h-2v2zM2 22h16V8h4V2L2 22z"/></g> +<g id="signal-cellular-no-sim"><path d="M18.99 5c0-1.1-.89-2-1.99-2h-7L7.66 5.34 19 16.68 18.99 5zM3.65 3.88L2.38 5.15 5 7.77V19c0 1.1.9 2 2 2h10.01c.35 0 .67-.1.96-.26l1.88 1.88 1.27-1.27L3.65 3.88z"/></g> +<g id="signal-cellular-null"><path d="M20 6.83V20H6.83L20 6.83M22 2L2 22h20V2z"/></g> +<g id="signal-cellular-off"><path d="M21 1l-8.59 8.59L21 18.18V1zM4.77 4.5L3.5 5.77l6.36 6.36L1 21h17.73l2 2L22 21.73 4.77 4.5z"/></g> +<g id="signal-wifi-0-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/></g> +<g id="signal-wifi-1-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M6.67 14.86L12 21.49v.01l.01-.01 5.33-6.63C17.06 14.65 15.03 13 12 13s-5.06 1.65-5.33 1.86z"/></g> +<g id="signal-wifi-1-bar-lock"><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16z"/><path d="M15.5 14.5c0-2.8 2.2-5 5-5 .4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4C5.3 3 .8 6.7.4 7L12 21.5l3.5-4.3v-2.7z" opacity=".3"/><path d="M6.7 14.9l5.3 6.6 3.5-4.3v-2.6c0-.2 0-.5.1-.7-.9-.5-2.2-.9-3.6-.9-3 0-5.1 1.7-5.3 1.9z"/></g> +<g id="signal-wifi-2-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M4.79 12.52l7.2 8.98H12l.01-.01 7.2-8.98C18.85 12.24 16.1 10 12 10s-6.85 2.24-7.21 2.52z"/></g> +<g id="signal-wifi-2-bar-lock"><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16z"/><path d="M15.5 14.5c0-2.8 2.2-5 5-5 .4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4C5.3 3 .8 6.7.4 7L12 21.5l3.5-4.3v-2.7z" opacity=".3"/><path d="M4.8 12.5l7.2 9 3.5-4.4v-2.6c0-1.3.5-2.5 1.4-3.4C15.6 10.5 14 10 12 10c-4.1 0-6.8 2.2-7.2 2.5z"/></g> +<g id="signal-wifi-3-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M3.53 10.95l8.46 10.54.01.01.01-.01 8.46-10.54C20.04 10.62 16.81 8 12 8c-4.81 0-8.04 2.62-8.47 2.95z"/></g> +<g id="signal-wifi-3-bar-lock"><path opacity=".3" d="M12 3C5.3 3 .8 6.7.4 7l3.2 3.9L12 21.5l3.5-4.3v-2.6c0-2.2 1.4-4 3.3-4.7.3-.1.5-.2.8-.2.3-.1.6-.1.9-.1.4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4z"/><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16zm-10 5.5l3.5-4.3v-2.6c0-2.2 1.4-4 3.3-4.7C17.3 9 14.9 8 12 8c-4.8 0-8 2.6-8.5 2.9"/></g> +<g id="signal-wifi-4-bar"><path d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/></g> +<g id="signal-wifi-4-bar-lock"><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16zm-6.5-1.5c0-2.8 2.2-5 5-5 .4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4C5.3 3 .8 6.7.4 7L12 21.5l3.5-4.4v-2.6z"/></g> +<g id="signal-wifi-off"><path d="M23.64 7c-.45-.34-4.93-4-11.64-4-1.5 0-2.89.19-4.15.48L18.18 13.8 23.64 7zm-6.6 8.22L3.27 1.44 2 2.72l2.05 2.06C1.91 5.76.59 6.82.36 7l11.63 14.49.01.01.01-.01 3.9-4.86 3.32 3.32 1.27-1.27-3.46-3.46z"/></g> +<g id="storage"><path d="M2 20h20v-4H2v4zm2-3h2v2H4v-2zM2 4v4h20V4H2zm4 3H4V5h2v2zm-4 7h20v-4H2v4zm2-3h2v2H4v-2z"/></g> +<g id="usb"><path d="M15 7v4h1v2h-3V5h2l-3-4-3 4h2v8H8v-2.07c.7-.37 1.2-1.08 1.2-1.93 0-1.21-.99-2.2-2.2-2.2-1.21 0-2.2.99-2.2 2.2 0 .85.5 1.56 1.2 1.93V13c0 1.11.89 2 2 2h3v3.05c-.71.37-1.2 1.1-1.2 1.95 0 1.22.99 2.2 2.2 2.2 1.21 0 2.2-.98 2.2-2.2 0-.85-.49-1.58-1.2-1.95V15h3c1.11 0 2-.89 2-2v-2h1V7h-4z"/></g> +<g id="wallpaper"><path d="M4 4h7V2H4c-1.1 0-2 .9-2 2v7h2V4zm6 9l-4 5h12l-3-4-2.03 2.71L10 13zm7-4.5c0-.83-.67-1.5-1.5-1.5S14 7.67 14 8.5s.67 1.5 1.5 1.5S17 9.33 17 8.5zM20 2h-7v2h7v7h2V4c0-1.1-.9-2-2-2zm0 18h-7v2h7c1.1 0 2-.9 2-2v-7h-2v7zM4 13H2v7c0 1.1.9 2 2 2h7v-2H4v-7z"/></g> +<g id="widgets"><path d="M13 13v8h8v-8h-8zM3 21h8v-8H3v8zM3 3v8h8V3H3zm13.66-1.31L11 7.34 16.66 13l5.66-5.66-5.66-5.65z"/></g> +<g id="wifi-lock"><path d="M20.5 9.5c.28 0 .55.04.81.08L24 6c-3.34-2.51-7.5-4-12-4S3.34 3.49 0 6l12 16 3.5-4.67V14.5c0-2.76 2.24-5 5-5zM23 16v-1.5c0-1.38-1.12-2.5-2.5-2.5S18 13.12 18 14.5V16c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1v-4c0-.55-.45-1-1-1zm-1 0h-3v-1.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V16z"/></g> +<g id="wifi-tethering"><path d="M12 11c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 2c0-3.31-2.69-6-6-6s-6 2.69-6 6c0 2.22 1.21 4.15 3 5.19l1-1.74c-1.19-.7-2-1.97-2-3.45 0-2.21 1.79-4 4-4s4 1.79 4 4c0 1.48-.81 2.75-2 3.45l1 1.74c1.79-1.04 3-2.97 3-5.19zM12 3C6.48 3 2 7.48 2 13c0 3.7 2.01 6.92 4.99 8.65l1-1.73C5.61 18.53 4 15.96 4 13c0-4.42 3.58-8 8-8s8 3.58 8 8c0 2.96-1.61 5.53-4 6.92l1 1.73c2.99-1.73 5-4.95 5-8.65 0-5.52-4.48-10-10-10z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/editor-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/editor-icons.html new file mode 100644 index 0000000..7fabfe0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/editor-icons.html @@ -0,0 +1,70 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="editor" size="24"> +<svg><defs> +<g id="attach-file"><path d="M16.5 6v11.5c0 2.21-1.79 4-4 4s-4-1.79-4-4V5c0-1.38 1.12-2.5 2.5-2.5s2.5 1.12 2.5 2.5v10.5c0 .55-.45 1-1 1s-1-.45-1-1V6H10v9.5c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5V5c0-2.21-1.79-4-4-4S7 2.79 7 5v12.5c0 3.04 2.46 5.5 5.5 5.5s5.5-2.46 5.5-5.5V6h-1.5z"/></g> +<g id="attach-money"><path d="M11.8 10.9c-2.27-.59-3-1.2-3-2.15 0-1.09 1.01-1.85 2.7-1.85 1.78 0 2.44.85 2.5 2.1h2.21c-.07-1.72-1.12-3.3-3.21-3.81V3h-3v2.16c-1.94.42-3.5 1.68-3.5 3.61 0 2.31 1.91 3.46 4.7 4.13 2.5.6 3 1.48 3 2.41 0 .69-.49 1.79-2.7 1.79-2.06 0-2.87-.92-2.98-2.1h-2.2c.12 2.19 1.76 3.42 3.68 3.83V21h3v-2.15c1.95-.37 3.5-1.5 3.5-3.55 0-2.84-2.43-3.81-4.7-4.4z"/></g> +<g id="border-all"><path d="M3 3v18h18V3H3zm8 16H5v-6h6v6zm0-8H5V5h6v6zm8 8h-6v-6h6v6zm0-8h-6V5h6v6z"/></g> +<g id="border-bottom"><path d="M9 11H7v2h2v-2zm4 4h-2v2h2v-2zM9 3H7v2h2V3zm4 8h-2v2h2v-2zM5 3H3v2h2V3zm8 4h-2v2h2V7zm4 4h-2v2h2v-2zm-4-8h-2v2h2V3zm4 0h-2v2h2V3zm2 10h2v-2h-2v2zm0 4h2v-2h-2v2zM5 7H3v2h2V7zm14-4v2h2V3h-2zm0 6h2V7h-2v2zM5 11H3v2h2v-2zM3 21h18v-2H3v2zm2-6H3v2h2v-2z"/></g> +<g id="border-clear"><path d="M7 5h2V3H7v2zm0 8h2v-2H7v2zm0 8h2v-2H7v2zm4-4h2v-2h-2v2zm0 4h2v-2h-2v2zm-8 0h2v-2H3v2zm0-4h2v-2H3v2zm0-4h2v-2H3v2zm0-4h2V7H3v2zm0-4h2V3H3v2zm8 8h2v-2h-2v2zm8 4h2v-2h-2v2zm0-4h2v-2h-2v2zm0 8h2v-2h-2v2zm0-12h2V7h-2v2zm-8 0h2V7h-2v2zm8-6v2h2V3h-2zm-8 2h2V3h-2v2zm4 16h2v-2h-2v2zm0-8h2v-2h-2v2zm0-8h2V3h-2v2z"/></g> +<g id="border-color"><path d="M17.75 7L14 3.25l-10 10V17h3.75l10-10zm2.96-2.96c.39-.39.39-1.02 0-1.41L18.37.29c-.39-.39-1.02-.39-1.41 0L15 2.25 18.75 6l1.96-1.96z"/><path fill-opacity=".36" d="M0 20h24v4H0z"/></g> +<g id="border-horizontal"><path d="M3 21h2v-2H3v2zM5 7H3v2h2V7zM3 17h2v-2H3v2zm4 4h2v-2H7v2zM5 3H3v2h2V3zm4 0H7v2h2V3zm8 0h-2v2h2V3zm-4 4h-2v2h2V7zm0-4h-2v2h2V3zm6 14h2v-2h-2v2zm-8 4h2v-2h-2v2zm-8-8h18v-2H3v2zM19 3v2h2V3h-2zm0 6h2V7h-2v2zm-8 8h2v-2h-2v2zm4 4h2v-2h-2v2zm4 0h2v-2h-2v2z"/></g> +<g id="border-inner"><path d="M3 21h2v-2H3v2zm4 0h2v-2H7v2zM5 7H3v2h2V7zM3 17h2v-2H3v2zM9 3H7v2h2V3zM5 3H3v2h2V3zm12 0h-2v2h2V3zm2 6h2V7h-2v2zm0-6v2h2V3h-2zm-4 18h2v-2h-2v2zM13 3h-2v8H3v2h8v8h2v-8h8v-2h-8V3zm6 18h2v-2h-2v2zm0-4h2v-2h-2v2z"/></g> +<g id="border-left"><path d="M11 21h2v-2h-2v2zm0-4h2v-2h-2v2zm0-12h2V3h-2v2zm0 4h2V7h-2v2zm0 4h2v-2h-2v2zm-4 8h2v-2H7v2zM7 5h2V3H7v2zm0 8h2v-2H7v2zm-4 8h2V3H3v18zM19 9h2V7h-2v2zm-4 12h2v-2h-2v2zm4-4h2v-2h-2v2zm0-14v2h2V3h-2zm0 10h2v-2h-2v2zm0 8h2v-2h-2v2zm-4-8h2v-2h-2v2zm0-8h2V3h-2v2z"/></g> +<g id="border-outer"><path d="M13 7h-2v2h2V7zm0 4h-2v2h2v-2zm4 0h-2v2h2v-2zM3 3v18h18V3H3zm16 16H5V5h14v14zm-6-4h-2v2h2v-2zm-4-4H7v2h2v-2z"/></g> +<g id="border-right"><path d="M7 21h2v-2H7v2zM3 5h2V3H3v2zm4 0h2V3H7v2zm0 8h2v-2H7v2zm-4 8h2v-2H3v2zm8 0h2v-2h-2v2zm-8-8h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2V7H3v2zm8 8h2v-2h-2v2zm4-4h2v-2h-2v2zm4-10v18h2V3h-2zm-4 18h2v-2h-2v2zm0-16h2V3h-2v2zm-4 8h2v-2h-2v2zm0-8h2V3h-2v2zm0 4h2V7h-2v2z"/></g> +<g id="border-style"><path d="M15 21h2v-2h-2v2zm4 0h2v-2h-2v2zM7 21h2v-2H7v2zm4 0h2v-2h-2v2zm8-4h2v-2h-2v2zm0-4h2v-2h-2v2zM3 3v18h2V5h16V3H3zm16 6h2V7h-2v2z"/></g> +<g id="border-top"><path d="M7 21h2v-2H7v2zm0-8h2v-2H7v2zm4 0h2v-2h-2v2zm0 8h2v-2h-2v2zm-8-4h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2v-2H3v2zm0-4h2V7H3v2zm8 8h2v-2h-2v2zm8-8h2V7h-2v2zm0 4h2v-2h-2v2zM3 3v2h18V3H3zm16 14h2v-2h-2v2zm-4 4h2v-2h-2v2zM11 9h2V7h-2v2zm8 12h2v-2h-2v2zm-4-8h2v-2h-2v2z"/></g> +<g id="border-vertical"><path d="M3 9h2V7H3v2zm0-4h2V3H3v2zm4 16h2v-2H7v2zm0-8h2v-2H7v2zm-4 0h2v-2H3v2zm0 8h2v-2H3v2zm0-4h2v-2H3v2zM7 5h2V3H7v2zm12 12h2v-2h-2v2zm-8 4h2V3h-2v18zm8 0h2v-2h-2v2zm0-8h2v-2h-2v2zm0-10v2h2V3h-2zm0 6h2V7h-2v2zm-4-4h2V3h-2v2zm0 16h2v-2h-2v2zm0-8h2v-2h-2v2z"/></g> +<g id="format-align-center"><path d="M7 15v2h10v-2H7zm-4 6h18v-2H3v2zm0-8h18v-2H3v2zm4-6v2h10V7H7zM3 3v2h18V3H3z"/></g> +<g id="format-align-justify"><path d="M3 21h18v-2H3v2zm0-4h18v-2H3v2zm0-4h18v-2H3v2zm0-4h18V7H3v2zm0-6v2h18V3H3z"/></g> +<g id="format-align-left"><path d="M15 15H3v2h12v-2zm0-8H3v2h12V7zM3 13h18v-2H3v2zm0 8h18v-2H3v2zM3 3v2h18V3H3z"/></g> +<g id="format-align-right"><path d="M3 21h18v-2H3v2zm6-4h12v-2H9v2zm-6-4h18v-2H3v2zm6-4h12V7H9v2zM3 3v2h18V3H3z"/></g> +<g id="format-bold"><path d="M15.6 10.79c.97-.67 1.65-1.77 1.65-2.79 0-2.26-1.75-4-4-4H7v14h7.04c2.09 0 3.71-1.7 3.71-3.79 0-1.52-.86-2.82-2.15-3.42zM10 6.5h3c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5h-3v-3zm3.5 9H10v-3h3.5c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5z"/></g> +<g id="format-clear"><path d="M3.27 5L2 6.27l6.97 6.97L6.5 19h3l1.57-3.66L16.73 21 18 19.73 3.55 5.27 3.27 5zM6 5v.18L8.82 8h2.4l-.72 1.68 2.1 2.1L14.21 8H20V5H6z"/></g> +<g id="format-color-fill"><path d="M16.56 8.94L7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.59-.59 1.54 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.58.59-1.53 0-2.12zM5.21 10L10 5.21 14.79 10H5.21zM19 11.5s-2 2.17-2 3.5c0 1.1.9 2 2 2s2-.9 2-2c0-1.33-2-3.5-2-3.5z"/><path fill-opacity=".36" d="M0 20h24v4H0z"/></g> +<g id="format-color-reset"><path d="M18 14c0-4-6-10.8-6-10.8s-1.33 1.51-2.73 3.52l8.59 8.59c.09-.42.14-.86.14-1.31zm-.88 3.12L12.5 12.5 5.27 5.27 4 6.55l3.32 3.32C6.55 11.32 6 12.79 6 14c0 3.31 2.69 6 6 6 1.52 0 2.9-.57 3.96-1.5l2.63 2.63 1.27-1.27-2.74-2.74z"/></g> +<g id="format-color-text"><path fill-opacity=".36" d="M0 20h24v4H0z"/><path d="M11 3L5.5 17h2.25l1.12-3h6.25l1.12 3h2.25L13 3h-2zm-1.38 9L12 5.67 14.38 12H9.62z"/></g> +<g id="format-indent-decrease"><path d="M11 17h10v-2H11v2zm-8-5l4 4V8l-4 4zm0 9h18v-2H3v2zM3 3v2h18V3H3zm8 6h10V7H11v2zm0 4h10v-2H11v2z"/></g> +<g id="format-indent-increase"><path d="M3 21h18v-2H3v2zM3 8v8l4-4-4-4zm8 9h10v-2H11v2zM3 3v2h18V3H3zm8 6h10V7H11v2zm0 4h10v-2H11v2z"/></g> +<g id="format-italic"><path d="M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4z"/></g> +<g id="format-line-spacing"><path d="M6 7h2.5L5 3.5 1.5 7H4v10H1.5L5 20.5 8.5 17H6V7zm4-2v2h12V5H10zm0 14h12v-2H10v2zm0-6h12v-2H10v2z"/></g> +<g id="format-list-bulleted"><path d="M4 10.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm0-6c-.83 0-1.5.67-1.5 1.5S3.17 7.5 4 7.5 5.5 6.83 5.5 6 4.83 4.5 4 4.5zm0 12.17c-.74 0-1.33.6-1.33 1.33s.6 1.33 1.33 1.33 1.33-.6 1.33-1.33-.59-1.33-1.33-1.33zM7 19h14v-2H7v2zm0-6h14v-2H7v2zm0-8v2h14V5H7z"/></g> +<g id="format-list-numbered"><path d="M2 17h2v.5H3v1h1v.5H2v1h3v-4H2v1zm1-9h1V4H2v1h1v3zm-1 3h1.8L2 13.1v.9h3v-1H3.2L5 10.9V10H2v1zm5-6v2h14V5H7zm0 14h14v-2H7v2zm0-6h14v-2H7v2z"/></g> +<g id="format-paint"><path d="M18 4V3c0-.55-.45-1-1-1H5c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h12c.55 0 1-.45 1-1V6h1v4H9v11c0 .55.45 1 1 1h2c.55 0 1-.45 1-1v-9h8V4h-3z"/></g> +<g id="format-quote"><path d="M6 17h3l2-4V7H5v6h3zm8 0h3l2-4V7h-6v6h3z"/></g> +<g id="format-size"><path d="M9 4v3h5v12h3V7h5V4H9zm-6 8h3v7h3v-7h3V9H3v3z"/></g> +<g id="format-strikethrough"><path d="M10 19h4v-3h-4v3zM5 4v3h5v3h4V7h5V4H5zM3 14h18v-2H3v2z"/></g> +<g id="format-textdirection-l-to-r"><path d="M9 10v5h2V4h2v11h2V4h2V2H9C6.79 2 5 3.79 5 6s1.79 4 4 4zm12 8l-4-4v3H5v2h12v3l4-4z"/></g> +<g id="format-textdirection-r-to-l"><path d="M10 10v5h2V4h2v11h2V4h2V2h-8C7.79 2 6 3.79 6 6s1.79 4 4 4zm-2 7v-3l-4 4 4 4v-3h12v-2H8z"/></g> +<g id="format-underlined"><path d="M12 17c3.31 0 6-2.69 6-6V3h-2.5v8c0 1.93-1.57 3.5-3.5 3.5S8.5 12.93 8.5 11V3H6v8c0 3.31 2.69 6 6 6zm-7 2v2h14v-2H5z"/></g> +<g id="functions"><path d="M18 4H6v2l6.5 6L6 18v2h12v-3h-7l5-5-5-5h7z"/></g> +<g id="insert-chart"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/></g> +<g id="insert-comment"><path d="M20 2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4V4c0-1.1-.9-2-2-2zm-2 12H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z"/></g> +<g id="insert-drive-file"><path d="M6 2c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6H6zm7 7V3.5L18.5 9H13z"/></g> +<g id="insert-emoticon"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 6.5c2.33 0 4.31-1.46 5.11-3.5H6.89c.8 2.04 2.78 3.5 5.11 3.5z"/></g> +<g id="insert-invitation"><path d="M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"/></g> +<g id="insert-link"><path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/></g> +<g id="insert-photo"><path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/></g> +<g id="merge-type"><path d="M17 20.41L18.41 19 15 15.59 13.59 17 17 20.41zM7.5 8H11v5.59L5.59 19 7 20.41l6-6V8h3.5L12 3.5 7.5 8z"/></g> +<g id="mode-comment"><path d="M21.99 4c0-1.1-.89-2-1.99-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4-.01-18z"/></g> +<g id="mode-edit"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"/></g> +<g id="money-off"><path d="M12.5 6.9c1.78 0 2.44.85 2.5 2.1h2.21c-.07-1.72-1.12-3.3-3.21-3.81V3h-3v2.16c-.53.12-1.03.3-1.48.54l1.47 1.47c.41-.17.91-.27 1.51-.27zM5.33 4.06L4.06 5.33 7.5 8.77c0 2.08 1.56 3.21 3.91 3.91l3.51 3.51c-.34.48-1.05.91-2.42.91-2.06 0-2.87-.92-2.98-2.1h-2.2c.12 2.19 1.76 3.42 3.68 3.83V21h3v-2.15c.96-.18 1.82-.55 2.45-1.12l2.22 2.22 1.27-1.27L5.33 4.06z"/></g> +<g id="publish"><path d="M5 4v2h14V4H5zm0 10h4v6h6v-6h4l-7-7-7 7z"/></g> +<g id="space-bar"><path d="M18 9v4H6V9H4v6h16V9z"/></g> +<g id="strikethrough-s"><path d="M5.9 10h6.3c-.8-.3-1.5-.6-2-.9-.7-.4-1-1-1-1.6 0-.3.1-.6.2-.9.1-.3.3-.5.6-.7.3-.2.6-.4 1-.5.4-.1.8-.2 1.4-.2.5 0 1 .1 1.4.2.4.1.7.3 1 .6.3.2.5.5.6.9.1.3.2.7.2 1.1h4c0-.9-.2-1.7-.5-2.4s-.8-1.4-1.4-1.9c-.6-.5-1.4-1-2.3-1.2-1-.4-2-.5-3.1-.5s-2 .1-2.9.4c-.9.3-1.6.6-2.3 1.1-.6.5-1.1 1-1.4 1.7-.4.7-.6 1.4-.6 2.2 0 .8.2 1.6.5 2.2.1.2.2.3.3.4zM23 12H1v2h11.9c.2.1.5.2.7.3.5.2.9.5 1.2.7.3.2.5.5.6.8.1.3.1.6.1.9 0 .3-.1.6-.2.9-.1.3-.3.5-.6.7-.2.2-.6.3-.9.5-.4.1-.8.2-1.4.2-.6 0-1.1-.1-1.6-.2s-.9-.3-1.2-.6c-.3-.3-.6-.6-.8-1-.2-.4-.3-1-.3-1.6h-4c0 .7.1 1.5.3 2.1.2.6.5 1.1.9 1.6s.8.9 1.3 1.2c.5.3 1 .6 1.6.9.6.2 1.2.4 1.8.5.6.1 1.3.2 1.9.2 1.1 0 2-.1 2.9-.4.9-.2 1.6-.6 2.2-1.1.6-.5 1.1-1 1.4-1.7.3-.7.5-1.4.5-2.3 0-.8-.1-1.5-.4-2.2-.1-.2-.1-.3-.2-.4H23v-2z"/></g> +<g id="vertical-align-bottom"><path d="M16 13h-3V3h-2v10H8l4 4 4-4zM4 19v2h16v-2H4z"/></g> +<g id="vertical-align-center"><path d="M8 19h3v4h2v-4h3l-4-4-4 4zm8-14h-3V1h-2v4H8l4 4 4-4zM4 11v2h16v-2H4z"/></g> +<g id="vertical-align-top"><path d="M8 11h3v10h2V11h3l-4-4-4 4zM4 3v2h16V3H4z"/></g> +<g id="wrap-text"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/hardware-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/hardware-icons.html new file mode 100644 index 0000000..670cb07 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/hardware-icons.html @@ -0,0 +1,61 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="hardware" size="24"> +<svg><defs> +<g id="cast"><path d="M21 3H3c-1.1 0-2 .9-2 2v3h2V5h18v14h-7v2h7c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM1 18v3h3c0-1.66-1.34-3-3-3zm0-4v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm0-4v2c4.97 0 9 4.03 9 9h2c0-6.08-4.93-11-11-11z"/></g> +<g id="cast-connected"><path d="M1 18v3h3c0-1.66-1.34-3-3-3zm0-4v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm18-7H5v1.63c3.96 1.28 7.09 4.41 8.37 8.37H19V7zM1 10v2c4.97 0 9 4.03 9 9h2c0-6.08-4.93-11-11-11zm20-7H3c-1.1 0-2 .9-2 2v3h2V5h18v14h-7v2h7c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="computer"><path d="M20 18c1.1 0 1.99-.9 1.99-2L22 6c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2H0v2h24v-2h-4zM4 6h16v10H4V6z"/></g> +<g id="desktop-mac"><path d="M21 2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7l-2 3v1h8v-1l-2-3h7c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 12H3V4h18v10z"/></g> +<g id="desktop-windows"><path d="M21 2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7v2H8v2h8v-2h-2v-2h7c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H3V4h18v12z"/></g> +<g id="developer-board"><path d="M22 9V7h-2V5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-2h2v-2h-2v-2h2v-2h-2V9h2zm-4 10H4V5h14v14zM6 13h5v4H6zm6-6h4v3h-4zM6 7h5v5H6zm6 4h4v6h-4z"/></g> +<g id="device-hub"><path d="M17 16l-4-4V8.82C14.16 8.4 15 7.3 15 6c0-1.66-1.34-3-3-3S9 4.34 9 6c0 1.3.84 2.4 2 2.82V12l-4 4H3v5h5v-3.05l4-4.2 4 4.2V21h5v-5h-4z"/></g> +<g id="dock"><path d="M8 23h8v-2H8v2zm8-21.99L8 1c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM16 15H8V5h8v10z"/></g> +<g id="gamepad"><path d="M15 7.5V2H9v5.5l3 3 3-3zM7.5 9H2v6h5.5l3-3-3-3zM9 16.5V22h6v-5.5l-3-3-3 3zM16.5 9l-3 3 3 3H22V9h-5.5z"/></g> +<g id="headset"><path d="M12 1c-4.97 0-9 4.03-9 9v7c0 1.66 1.34 3 3 3h3v-8H5v-2c0-3.87 3.13-7 7-7s7 3.13 7 7v2h-4v8h3c1.66 0 3-1.34 3-3v-7c0-4.97-4.03-9-9-9z"/></g> +<g id="headset-mic"><path d="M12 1c-4.97 0-9 4.03-9 9v7c0 1.66 1.34 3 3 3h3v-8H5v-2c0-3.87 3.13-7 7-7s7 3.13 7 7v2h-4v8h4v1h-7v2h6c1.66 0 3-1.34 3-3V10c0-4.97-4.03-9-9-9z"/></g> +<g id="keyboard"><path d="M20 5H4c-1.1 0-1.99.9-1.99 2L2 17c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-9 3h2v2h-2V8zm0 3h2v2h-2v-2zM8 8h2v2H8V8zm0 3h2v2H8v-2zm-1 2H5v-2h2v2zm0-3H5V8h2v2zm9 7H8v-2h8v2zm0-4h-2v-2h2v2zm0-3h-2V8h2v2zm3 3h-2v-2h2v2zm0-3h-2V8h2v2z"/></g> +<g id="keyboard-arrow-down"><path d="M7.41 7.84L12 12.42l4.59-4.58L18 9.25l-6 6-6-6z"/></g> +<g id="keyboard-arrow-left"><path d="M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"/></g> +<g id="keyboard-arrow-right"><path d="M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"/></g> +<g id="keyboard-arrow-up"><path d="M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6-6 6z"/></g> +<g id="keyboard-backspace"><path d="M21 11H6.83l3.58-3.59L9 6l-6 6 6 6 1.41-1.41L6.83 13H21z"/></g> +<g id="keyboard-capslock"><path d="M12 8.41L16.59 13 18 11.59l-6-6-6 6L7.41 13 12 8.41zM6 18h12v-2H6v2z"/></g> +<g id="keyboard-hide"><path d="M20 3H4c-1.1 0-1.99.9-1.99 2L2 15c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-9 3h2v2h-2V6zm0 3h2v2h-2V9zM8 6h2v2H8V6zm0 3h2v2H8V9zm-1 2H5V9h2v2zm0-3H5V6h2v2zm9 7H8v-2h8v2zm0-4h-2V9h2v2zm0-3h-2V6h2v2zm3 3h-2V9h2v2zm0-3h-2V6h2v2zm-7 15l4-4H8l4 4z"/></g> +<g id="keyboard-return"><path d="M19 7v4H5.83l3.58-3.59L8 6l-6 6 6 6 1.41-1.41L5.83 13H21V7z"/></g> +<g id="keyboard-tab"><path d="M11.59 7.41L15.17 11H1v2h14.17l-3.59 3.59L13 18l6-6-6-6-1.41 1.41zM20 6v12h2V6h-2z"/></g> +<g id="keyboard-voice"><path d="M12 15c1.66 0 2.99-1.34 2.99-3L15 6c0-1.66-1.34-3-3-3S9 4.34 9 6v6c0 1.66 1.34 3 3 3zm5.3-3c0 3-2.54 5.1-5.3 5.1S6.7 15 6.7 12H5c0 3.42 2.72 6.23 6 6.72V22h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"/></g> +<g id="laptop"><path d="M20 18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2H0v2h24v-2h-4zM4 6h16v10H4V6z"/></g> +<g id="laptop-chromebook"><path d="M22 18V3H2v15H0v2h24v-2h-2zm-8 0h-4v-1h4v1zm6-3H4V5h16v10z"/></g> +<g id="laptop-mac"><path d="M20 18c1.1 0 1.99-.9 1.99-2L22 5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v11c0 1.1.9 2 2 2H0c0 1.1.9 2 2 2h20c1.1 0 2-.9 2-2h-4zM4 5h16v11H4V5zm8 14c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="laptop-windows"><path d="M20 18v-1c1.1 0 1.99-.9 1.99-2L22 5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2v1H0v2h24v-2h-4zM4 5h16v10H4V5z"/></g> +<g id="memory"><path d="M15 9H9v6h6V9zm-2 4h-2v-2h2v2zm8-2V9h-2V7c0-1.1-.9-2-2-2h-2V3h-2v2h-2V3H9v2H7c-1.1 0-2 .9-2 2v2H3v2h2v2H3v2h2v2c0 1.1.9 2 2 2h2v2h2v-2h2v2h2v-2h2c1.1 0 2-.9 2-2v-2h2v-2h-2v-2h2zm-4 6H7V7h10v10z"/></g> +<g id="mouse"><path d="M13 1.07V9h7c0-4.08-3.05-7.44-7-7.93zM4 15c0 4.42 3.58 8 8 8s8-3.58 8-8v-4H4v4zm7-13.93C7.05 1.56 4 4.92 4 9h7V1.07z"/></g> +<g id="phone-android"><path d="M16 1H8C6.34 1 5 2.34 5 4v16c0 1.66 1.34 3 3 3h8c1.66 0 3-1.34 3-3V4c0-1.66-1.34-3-3-3zm-2 20h-4v-1h4v1zm3.25-3H6.75V4h10.5v14z"/></g> +<g id="phone-iphone"><path d="M15.5 1h-8C6.12 1 5 2.12 5 3.5v17C5 21.88 6.12 23 7.5 23h8c1.38 0 2.5-1.12 2.5-2.5v-17C18 2.12 16.88 1 15.5 1zm-4 21c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm4.5-4H7V4h9v14z"/></g> +<g id="phonelink"><path d="M4 6h18V4H4c-1.1 0-2 .9-2 2v11H0v3h14v-3H4V6zm19 2h-6c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zm-1 9h-4v-7h4v7z"/></g> +<g id="phonelink-off"><path d="M22 6V4H6.82l2 2H22zM1.92 1.65L.65 2.92l1.82 1.82C2.18 5.08 2 5.52 2 6v11H0v3h17.73l2.35 2.35 1.27-1.27L3.89 3.62 1.92 1.65zM4 6.27L14.73 17H4V6.27zM23 8h-6c-.55 0-1 .45-1 1v4.18l2 2V10h4v7h-2.18l3 3H23c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1z"/></g> +<g id="power-input"><path d="M2 9v2h19V9H2zm0 6h5v-2H2v2zm7 0h5v-2H9v2zm7 0h5v-2h-5v2z"/></g> +<g id="router"><path d="M20.2 5.9l.8-.8C19.6 3.7 17.8 3 16 3s-3.6.7-5 2.1l.8.8C13 4.8 14.5 4.2 16 4.2s3 .6 4.2 1.7zm-.9.8c-.9-.9-2.1-1.4-3.3-1.4s-2.4.5-3.3 1.4l.8.8c.7-.7 1.6-1 2.5-1 .9 0 1.8.3 2.5 1l.8-.8zM19 13h-2V9h-2v4H5c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-4c0-1.1-.9-2-2-2zM8 18H6v-2h2v2zm3.5 0h-2v-2h2v2zm3.5 0h-2v-2h2v2z"/></g> +<g id="scanner"><path d="M19.8 10.7L4.2 5l-.7 1.9L17.6 12H5c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-5.5c0-.8-.5-1.6-1.2-1.8zM7 17H5v-2h2v2zm12 0H9v-2h10v2z"/></g> +<g id="security"><path d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 10.99h7c-.53 4.12-3.28 7.79-7 8.94V12H5V6.3l7-3.11v8.8z"/></g> +<g id="sim-card"><path d="M19.99 4c0-1.1-.89-2-1.99-2h-8L4 8v12c0 1.1.9 2 2 2h12.01c1.1 0 1.99-.9 1.99-2l-.01-16zM9 19H7v-2h2v2zm8 0h-2v-2h2v2zm-8-4H7v-4h2v4zm4 4h-2v-4h2v4zm0-6h-2v-2h2v2zm4 2h-2v-4h2v4z"/></g> +<g id="smartphone"><path d="M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="speaker"><path d="M17 2H7c-1.1 0-2 .9-2 2v16c0 1.1.9 1.99 2 1.99L17 22c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5 2c1.1 0 2 .9 2 2s-.9 2-2 2c-1.11 0-2-.9-2-2s.89-2 2-2zm0 16c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="speaker-group"><path d="M18.2 1H9.8C8.81 1 8 1.81 8 2.8v14.4c0 .99.81 1.79 1.8 1.79l8.4.01c.99 0 1.8-.81 1.8-1.8V2.8c0-.99-.81-1.8-1.8-1.8zM14 3c1.1 0 2 .89 2 2s-.9 2-2 2-2-.89-2-2 .9-2 2-2zm0 13.5c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"/><circle cx="14" cy="12.5" r="2.5"/><path d="M6 5H4v16c0 1.1.89 2 2 2h10v-2H6V5z"/></g> +<g id="tablet"><path d="M21 4H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h18c1.1 0 1.99-.9 1.99-2L23 6c0-1.1-.9-2-2-2zm-2 14H5V6h14v12z"/></g> +<g id="tablet-android"><path d="M18 0H6C4.34 0 3 1.34 3 3v18c0 1.66 1.34 3 3 3h12c1.66 0 3-1.34 3-3V3c0-1.66-1.34-3-3-3zm-4 22h-4v-1h4v1zm5.25-3H4.75V3h14.5v16z"/></g> +<g id="tablet-mac"><path d="M18.5 0h-14C3.12 0 2 1.12 2 2.5v19C2 22.88 3.12 24 4.5 24h14c1.38 0 2.5-1.12 2.5-2.5v-19C21 1.12 19.88 0 18.5 0zm-7 23c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm7.5-4H4V3h15v16z"/></g> +<g id="toys"><path d="M12 12c0-3 2.5-5.5 5.5-5.5S23 9 23 12H12zm0 0c0 3-2.5 5.5-5.5 5.5S1 15 1 12h11zm0 0c-3 0-5.5-2.5-5.5-5.5S9 1 12 1v11zm0 0c3 0 5.5 2.5 5.5 5.5S15 23 12 23V12z"/></g> +<g id="tv"><path d="M21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.1-.9-2-2-2zm0 14H3V5h18v12z"/></g> +<g id="watch"><path d="M20 12c0-2.54-1.19-4.81-3.04-6.27L16 0H8l-.95 5.73C5.19 7.19 4 9.45 4 12s1.19 4.81 3.05 6.27L8 24h8l.96-5.73C18.81 16.81 20 14.54 20 12zM6 12c0-3.31 2.69-6 6-6s6 2.69 6 6-2.69 6-6 6-6-2.69-6-6z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-icons/hero.svg new file mode 100644 index 0000000..167321c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/hero.svg @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="73" cy="24" r="4"/> + <path d="M82,33H64V15h18V33z M66,31h14V17H66V31z"/> + <circle cx="112.5" cy="24" r="4"/> + <circle cx="151" cy="24" r="4"/> + <path d="M121,33h-18V15h18V33z M105,31h14V17h-14V31z"/> + <path d="M160,33h-18V15h18V33z M144,31h14V17h-14V31z"/> + <circle cx="73" cy="62" r="4"/> + <path d="M82,71H64V53h18V71z M66,69h14V55H66V69z"/> + <circle cx="112.5" cy="62" r="4"/> + <path d="M121,71h-18V53h18V71z M105,69h14V55h-14V69z"/> + <circle cx="151" cy="62" r="4"/> + <path d="M160,71h-18V53h18V71z M144,69h14V55h-14V69z"/> + <circle cx="73" cy="102" r="4"/> + <path d="M82,111H64V93h18V111z M66,109h14V95H66V109z"/> + <circle cx="112.5" cy="102" r="4"/> + <path d="M121,111h-18V93h18V111z M105,109h14V95h-14V109z"/> + <circle cx="151" cy="102" r="4"/> + <path d="M160,111h-18V93h18V111z M144,109h14V95h-14V109z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/image-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/image-icons.html new file mode 100644 index 0000000..f6c45f5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/image-icons.html @@ -0,0 +1,164 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="image" size="24"> +<svg><defs> +<g id="add-to-photos"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/></g> +<g id="adjust"><path d="M12 2C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm3-8c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3z"/></g> +<g id="assistant"><path d="M19 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h4l3 3 3-3h4c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5.12 10.88L12 17l-1.88-4.12L6 11l4.12-1.88L12 5l1.88 4.12L18 11l-4.12 1.88z"/></g> +<g id="assistant-photo"><path d="M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6z"/></g> +<g id="audiotrack"><path d="M12 3v9.28c-.47-.17-.97-.28-1.5-.28C8.01 12 6 14.01 6 16.5S8.01 21 10.5 21c2.31 0 4.2-1.75 4.45-4H15V6h4V3h-7z"/></g> +<g id="blur-circular"><path d="M10 9c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zM7 9.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm3 7c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm-3-3c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm3-6c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM14 9c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-1.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm3 6c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm0-4c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm2-3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm0-3.5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1z"/></g> +<g id="blur-linear"><path d="M5 17.5c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5-1.5.67-1.5 1.5.67 1.5 1.5 1.5zM9 13c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zM3 21h18v-2H3v2zM5 9.5c.83 0 1.5-.67 1.5-1.5S5.83 6.5 5 6.5 3.5 7.17 3.5 8 4.17 9.5 5 9.5zm0 4c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5-1.5.67-1.5 1.5.67 1.5 1.5 1.5zM9 17c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm8-.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM3 3v2h18V3H3zm14 5.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm0 4c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM13 9c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0 4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0 4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1z"/></g> +<g id="blur-off"><path d="M14 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm-.2 4.48l.2.02c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5-1.5.67-1.5 1.5l.02.2c.09.67.61 1.19 1.28 1.28zM14 3.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm-4 0c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm11 7c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM10 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm8 8c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm-4 13.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM2.5 5.27l3.78 3.78L6 9c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1c0-.1-.03-.19-.06-.28l2.81 2.81c-.71.11-1.25.73-1.25 1.47 0 .83.67 1.5 1.5 1.5.74 0 1.36-.54 1.47-1.25l2.81 2.81c-.09-.03-.18-.06-.28-.06-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1c0-.1-.03-.19-.06-.28l3.78 3.78L20 20.23 3.77 4 2.5 5.27zM10 17c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm11-3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM6 13c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zM3 9.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm7 11c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM6 17c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm-3-3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5z"/></g> +<g id="blur-on"><path d="M6 13c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-8c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm-3 .5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM6 5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm15 5.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM14 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-3.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm-11 10c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm7 7c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm0-17c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM10 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0 5.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm8 .5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-8c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm3 8.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM14 17c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm-4-12c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm0 8.5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm4-4.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm0-4c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5z"/></g> +<g id="brightness-1"><circle cx="12" cy="12" r="10"/></g> +<g id="brightness-2"><path d="M10 2c-1.82 0-3.53.5-5 1.35C7.99 5.08 10 8.3 10 12s-2.01 6.92-5 8.65C6.47 21.5 8.18 22 10 22c5.52 0 10-4.48 10-10S15.52 2 10 2z"/></g> +<g id="brightness-3"><path d="M9 2c-1.05 0-2.05.16-3 .46 4.06 1.27 7 5.06 7 9.54 0 4.48-2.94 8.27-7 9.54.95.3 1.95.46 3 .46 5.52 0 10-4.48 10-10S14.52 2 9 2z"/></g> +<g id="brightness-4"><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-.89 0-1.74-.2-2.5-.55C11.56 16.5 13 14.42 13 12s-1.44-4.5-3.5-5.45C10.26 6.2 11.11 6 12 6c3.31 0 6 2.69 6 6s-2.69 6-6 6z"/></g> +<g id="brightness-5"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6z"/></g> +<g id="brightness-6"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18V6c3.31 0 6 2.69 6 6s-2.69 6-6 6z"/></g> +<g id="brightness-7"><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6zm0-10c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4z"/></g> +<g id="broken-image"><path d="M21 5v6.59l-3-3.01-4 4.01-4-4-4 4-3-3.01V5c0-1.1.9-2 2-2h14c1.1 0 2 .9 2 2zm-3 6.42l3 3.01V19c0 1.1-.9 2-2 2H5c-1.1 0-2-.9-2-2v-6.58l3 2.99 4-4 4 4 4-3.99z"/></g> +<g id="brush"><path d="M7 14c-1.66 0-3 1.34-3 3 0 1.31-1.16 2-2 2 .92 1.22 2.49 2 4 2 2.21 0 4-1.79 4-4 0-1.66-1.34-3-3-3zm13.71-9.37l-1.34-1.34c-.39-.39-1.02-.39-1.41 0L9 12.25 11.75 15l8.96-8.96c.39-.39.39-1.02 0-1.41z"/></g> +<g id="camera"><path d="M9.4 10.5l4.77-8.26C13.47 2.09 12.75 2 12 2c-2.4 0-4.6.85-6.32 2.25l3.66 6.35.06-.1zM21.54 9c-.92-2.92-3.15-5.26-6-6.34L11.88 9h9.66zm.26 1h-7.49l.29.5 4.76 8.25C21 16.97 22 14.61 22 12c0-.69-.07-1.35-.2-2zM8.54 12l-3.9-6.75C3.01 7.03 2 9.39 2 12c0 .69.07 1.35.2 2h7.49l-1.15-2zm-6.08 3c.92 2.92 3.15 5.26 6 6.34L12.12 15H2.46zm11.27 0l-3.9 6.76c.7.15 1.42.24 2.17.24 2.4 0 4.6-.85 6.32-2.25l-3.66-6.35-.93 1.6z"/></g> +<g id="camera-alt"><circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"/></g> +<g id="camera-front"><path d="M10 20H5v2h5v2l3-3-3-3v2zm4 0v2h5v-2h-5zM12 8c1.1 0 2-.9 2-2s-.9-2-2-2-1.99.9-1.99 2S10.9 8 12 8zm5-8H7C5.9 0 5 .9 5 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V2c0-1.1-.9-2-2-2zM7 2h10v10.5c0-1.67-3.33-2.5-5-2.5s-5 .83-5 2.5V2z"/></g> +<g id="camera-rear"><path d="M10 20H5v2h5v2l3-3-3-3v2zm4 0v2h5v-2h-5zm3-20H7C5.9 0 5 .9 5 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V2c0-1.1-.9-2-2-2zm-5 6c-1.11 0-2-.9-2-2s.89-2 1.99-2 2 .9 2 2C14 5.1 13.1 6 12 6z"/></g> +<g id="camera-roll"><path d="M14 5c0-1.1-.9-2-2-2h-1V2c0-.55-.45-1-1-1H6c-.55 0-1 .45-1 1v1H4c-1.1 0-2 .9-2 2v15c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2h8V5h-8zm-2 13h-2v-2h2v2zm0-9h-2V7h2v2zm4 9h-2v-2h2v2zm0-9h-2V7h2v2zm4 9h-2v-2h2v2zm0-9h-2V7h2v2z"/></g> +<g id="center-focus-strong"><path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm-7 7H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4z"/></g> +<g id="center-focus-weak"><path d="M5 15H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zM12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="collections"><path d="M22 16V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2zm-11-4l2.03 2.71L16 11l4 5H8l3-4zM2 6v14c0 1.1.9 2 2 2h14v-2H4V6H2z"/></g> +<g id="collections-bookmark"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zM20 2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 10l-2.5-1.5L15 12V4h5v8z"/></g> +<g id="color-lens"><path d="M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9c.83 0 1.5-.67 1.5-1.5 0-.39-.15-.74-.39-1.01-.23-.26-.38-.61-.38-.99 0-.83.67-1.5 1.5-1.5H16c2.76 0 5-2.24 5-5 0-4.42-4.03-8-9-8zm-5.5 9c-.83 0-1.5-.67-1.5-1.5S5.67 9 6.5 9 8 9.67 8 10.5 7.33 12 6.5 12zm3-4C8.67 8 8 7.33 8 6.5S8.67 5 9.5 5s1.5.67 1.5 1.5S10.33 8 9.5 8zm5 0c-.83 0-1.5-.67-1.5-1.5S13.67 5 14.5 5s1.5.67 1.5 1.5S15.33 8 14.5 8zm3 4c-.83 0-1.5-.67-1.5-1.5S16.67 9 17.5 9s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="colorize"><path d="M20.71 5.63l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-3.12 3.12-1.93-1.91-1.41 1.41 1.42 1.42L3 16.25V21h4.75l8.92-8.92 1.42 1.42 1.41-1.41-1.92-1.92 3.12-3.12c.4-.4.4-1.03.01-1.42zM6.92 19L5 17.08l8.06-8.06 1.92 1.92L6.92 19z"/></g> +<g id="compare"><path d="M10 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h5v2h2V1h-2v2zm0 15H5l5-6v6zm9-15h-5v2h5v13l-5-6v9h5c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="control-point"><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="control-point-duplicate"><path d="M16 8h-2v3h-3v2h3v3h2v-3h3v-2h-3zM2 12c0-2.79 1.64-5.2 4.01-6.32V3.52C2.52 4.76 0 8.09 0 12s2.52 7.24 6.01 8.48v-2.16C3.64 17.2 2 14.79 2 12zm13-9c-4.96 0-9 4.04-9 9s4.04 9 9 9 9-4.04 9-9-4.04-9-9-9zm0 16c-3.86 0-7-3.14-7-7s3.14-7 7-7 7 3.14 7 7-3.14 7-7 7z"/></g> +<g id="crop"><path d="M17 15h2V7c0-1.1-.9-2-2-2H9v2h8v8zM7 17V1H5v4H1v2h4v10c0 1.1.9 2 2 2h10v4h2v-4h4v-2H7z"/></g> +<g id="crop-16-9"><path d="M19 6H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 10H5V8h14v8z"/></g> +<g id="crop-3-2"><path d="M19 4H5c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H5V6h14v12z"/></g> +<g id="crop-5-4"><path d="M19 5H5c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 12H5V7h14v10z"/></g> +<g id="crop-7-5"><path d="M19 7H5c-1.1 0-2 .9-2 2v6c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2zm0 8H5V9h14v6z"/></g> +<g id="crop-din"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/></g> +<g id="crop-free"><path d="M3 5v4h2V5h4V3H5c-1.1 0-2 .9-2 2zm2 10H3v4c0 1.1.9 2 2 2h4v-2H5v-4zm14 4h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zm0-16h-4v2h4v4h2V5c0-1.1-.9-2-2-2z"/></g> +<g id="crop-landscape"><path d="M19 5H5c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 12H5V7h14v10z"/></g> +<g id="crop-original"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14zm-5.04-6.71l-2.75 3.54-1.96-2.36L6.5 17h11l-3.54-4.71z"/></g> +<g id="crop-portrait"><path d="M17 3H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H7V5h10v14z"/></g> +<g id="crop-square"><path d="M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H6V6h12v12z"/></g> +<g id="dehaze"><path d="M2 15.5v2h20v-2H2zm0-5v2h20v-2H2zm0-5v2h20v-2H2z"/></g> +<g id="details"><path d="M3 4l9 16 9-16H3zm3.38 2h11.25L12 16 6.38 6z"/></g> +<g id="edit"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"/></g> +<g id="exposure"><path d="M15 17v2h2v-2h2v-2h-2v-2h-2v2h-2v2h2zm5-15H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM5 5h6v2H5V5zm15 15H4L20 4v16z"/></g> +<g id="exposure-neg-1"><path d="M4 11v2h8v-2H4zm15 7h-2V7.38L14 8.4V6.7L18.7 5h.3v13z"/></g> +<g id="exposure-neg-2"><path d="M15.05 16.29l2.86-3.07c.38-.39.72-.79 1.04-1.18.32-.39.59-.78.82-1.17.23-.39.41-.78.54-1.17s.19-.79.19-1.18c0-.53-.09-1.02-.27-1.46-.18-.44-.44-.81-.78-1.11-.34-.31-.77-.54-1.26-.71-.51-.16-1.08-.24-1.72-.24-.69 0-1.31.11-1.85.32-.54.21-1 .51-1.36.88-.37.37-.65.8-.84 1.3-.18.47-.27.97-.28 1.5h2.14c.01-.31.05-.6.13-.87.09-.29.23-.54.4-.75.18-.21.41-.37.68-.49.27-.12.6-.18.96-.18.31 0 .58.05.81.15.23.1.43.25.59.43.16.18.28.4.37.65.08.25.13.52.13.81 0 .22-.03.43-.08.65-.06.22-.15.45-.29.7-.14.25-.32.53-.56.83-.23.3-.52.65-.88 1.03l-4.17 4.55V18H21v-1.71h-5.95zM2 11v2h8v-2H2z"/></g> +<g id="exposure-plus-1"><path d="M10 7H8v4H4v2h4v4h2v-4h4v-2h-4V7zm10 11h-2V7.38L15 8.4V6.7L19.7 5h.3v13z"/></g> +<g id="exposure-plus-2"><path d="M16.05 16.29l2.86-3.07c.38-.39.72-.79 1.04-1.18.32-.39.59-.78.82-1.17.23-.39.41-.78.54-1.17.13-.39.19-.79.19-1.18 0-.53-.09-1.02-.27-1.46-.18-.44-.44-.81-.78-1.11-.34-.31-.77-.54-1.26-.71-.51-.16-1.08-.24-1.72-.24-.69 0-1.31.11-1.85.32-.54.21-1 .51-1.36.88-.37.37-.65.8-.84 1.3-.18.47-.27.97-.28 1.5h2.14c.01-.31.05-.6.13-.87.09-.29.23-.54.4-.75.18-.21.41-.37.68-.49.27-.12.6-.18.96-.18.31 0 .58.05.81.15.23.1.43.25.59.43.16.18.28.4.37.65.08.25.13.52.13.81 0 .22-.03.43-.08.65-.06.22-.15.45-.29.7-.14.25-.32.53-.56.83-.23.3-.52.65-.88 1.03l-4.17 4.55V18H22v-1.71h-5.95zM8 7H6v4H2v2h4v4h2v-4h4v-2H8V7z"/></g> +<g id="exposure-zero"><path d="M16.14 12.5c0 1-.1 1.85-.3 2.55-.2.7-.48 1.27-.83 1.7-.36.44-.79.75-1.3.95-.51.2-1.07.3-1.7.3-.62 0-1.18-.1-1.69-.3-.51-.2-.95-.51-1.31-.95-.36-.44-.65-1.01-.85-1.7-.2-.7-.3-1.55-.3-2.55v-2.04c0-1 .1-1.85.3-2.55.2-.7.48-1.26.84-1.69.36-.43.8-.74 1.31-.93C10.81 5.1 11.38 5 12 5c.63 0 1.19.1 1.7.29.51.19.95.5 1.31.93.36.43.64.99.84 1.69.2.7.3 1.54.3 2.55v2.04zm-2.11-2.36c0-.64-.05-1.18-.13-1.62-.09-.44-.22-.79-.4-1.06-.17-.27-.39-.46-.64-.58-.25-.13-.54-.19-.86-.19-.32 0-.61.06-.86.18s-.47.31-.64.58c-.17.27-.31.62-.4 1.06s-.13.98-.13 1.62v2.67c0 .64.05 1.18.14 1.62.09.45.23.81.4 1.09s.39.48.64.61.54.19.87.19c.33 0 .62-.06.87-.19s.46-.33.63-.61c.17-.28.3-.64.39-1.09.09-.45.13-.99.13-1.62v-2.66z"/></g> +<g id="filter"><path d="M15.96 10.29l-2.75 3.54-1.96-2.36L8.5 15h11l-3.54-4.71zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-1"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 10h2V5h-4v2h2v8zm7-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-2"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-4-4h-4v-2h2c1.1 0 2-.89 2-2V7c0-1.11-.9-2-2-2h-4v2h4v2h-2c-1.1 0-2 .89-2 2v4h6v-2z"/></g> +<g id="filter-3"><path d="M21 1H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm14 8v-1.5c0-.83-.67-1.5-1.5-1.5.83 0 1.5-.67 1.5-1.5V7c0-1.11-.9-2-2-2h-4v2h4v2h-2v2h2v2h-4v2h4c1.1 0 2-.89 2-2z"/></g> +<g id="filter-4"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm12 10h2V5h-2v4h-2V5h-2v6h4v4zm6-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-5"><path d="M21 1H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm14 8v-2c0-1.11-.9-2-2-2h-2V7h4V5h-6v6h4v2h-4v2h4c1.1 0 2-.89 2-2z"/></g> +<g id="filter-6"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-8-2h2c1.1 0 2-.89 2-2v-2c0-1.11-.9-2-2-2h-2V7h4V5h-4c-1.1 0-2 .89-2 2v6c0 1.11.9 2 2 2zm0-4h2v2h-2v-2z"/></g> +<g id="filter-7"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-8-2l4-8V5h-6v2h4l-4 8h2z"/></g> +<g id="filter-8"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-8-2h2c1.1 0 2-.89 2-2v-1.5c0-.83-.67-1.5-1.5-1.5.83 0 1.5-.67 1.5-1.5V7c0-1.11-.9-2-2-2h-2c-1.1 0-2 .89-2 2v1.5c0 .83.67 1.5 1.5 1.5-.83 0-1.5.67-1.5 1.5V13c0 1.11.9 2 2 2zm0-8h2v2h-2V7zm0 4h2v2h-2v-2z"/></g> +<g id="filter-9"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM15 5h-2c-1.1 0-2 .89-2 2v2c0 1.11.9 2 2 2h2v2h-4v2h4c1.1 0 2-.89 2-2V7c0-1.11-.9-2-2-2zm0 4h-2V7h2v2z"/></g> +<g id="filter-9-plus"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 7V8c0-1.11-.9-2-2-2h-1c-1.1 0-2 .89-2 2v1c0 1.11.9 2 2 2h1v1H9v2h3c1.1 0 2-.89 2-2zm-3-3V8h1v1h-1zm10-8H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 8h-2V7h-2v2h-2v2h2v2h2v-2h2v6H7V3h14v6z"/></g> +<g id="filter-b-and-w"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16l-7-8v8H5l7-8V5h7v14z"/></g> +<g id="filter-center-focus"><path d="M5 15H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zM12 9c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="filter-drama"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.61 5.64 5.36 8.04 2.35 8.36 0 10.9 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4h2c0-2.76-1.86-5.08-4.4-5.78C8.61 6.88 10.2 6 12 6c3.03 0 5.5 2.47 5.5 5.5v.5H19c1.65 0 3 1.35 3 3s-1.35 3-3 3z"/></g> +<g id="filter-frames"><path d="M20 4h-4l-4-4-4 4H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H4V6h4.52l3.52-3.5L15.52 6H20v14zM18 8H6v10h12"/></g> +<g id="filter-hdr"><path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z"/></g> +<g id="filter-none"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-tilt-shift"><path d="M11 4.07V2.05c-2.01.2-3.84 1-5.32 2.21L7.1 5.69c1.11-.86 2.44-1.44 3.9-1.62zm7.32.19C16.84 3.05 15.01 2.25 13 2.05v2.02c1.46.18 2.79.76 3.9 1.62l1.42-1.43zM19.93 11h2.02c-.2-2.01-1-3.84-2.21-5.32L18.31 7.1c.86 1.11 1.44 2.44 1.62 3.9zM5.69 7.1L4.26 5.68C3.05 7.16 2.25 8.99 2.05 11h2.02c.18-1.46.76-2.79 1.62-3.9zM4.07 13H2.05c.2 2.01 1 3.84 2.21 5.32l1.43-1.43c-.86-1.1-1.44-2.43-1.62-3.89zM15 12c0-1.66-1.34-3-3-3s-3 1.34-3 3 1.34 3 3 3 3-1.34 3-3zm3.31 4.9l1.43 1.43c1.21-1.48 2.01-3.32 2.21-5.32h-2.02c-.18 1.45-.76 2.78-1.62 3.89zM13 19.93v2.02c2.01-.2 3.84-1 5.32-2.21l-1.43-1.43c-1.1.86-2.43 1.44-3.89 1.62zm-7.32-.19C7.16 20.95 9 21.75 11 21.95v-2.02c-1.46-.18-2.79-.76-3.9-1.62l-1.42 1.43z"/></g> +<g id="filter-vintage"><path d="M18.7 12.4c-.28-.16-.57-.29-.86-.4.29-.11.58-.24.86-.4 1.92-1.11 2.99-3.12 3-5.19-1.79-1.03-4.07-1.11-6 0-.28.16-.54.35-.78.54.05-.31.08-.63.08-.95 0-2.22-1.21-4.15-3-5.19C10.21 1.85 9 3.78 9 6c0 .32.03.64.08.95-.24-.2-.5-.39-.78-.55-1.92-1.11-4.2-1.03-6 0 0 2.07 1.07 4.08 3 5.19.28.16.57.29.86.4-.29.11-.58.24-.86.4-1.92 1.11-2.99 3.12-3 5.19 1.79 1.03 4.07 1.11 6 0 .28-.16.54-.35.78-.54-.05.32-.08.64-.08.96 0 2.22 1.21 4.15 3 5.19 1.79-1.04 3-2.97 3-5.19 0-.32-.03-.64-.08-.95.24.2.5.38.78.54 1.92 1.11 4.2 1.03 6 0-.01-2.07-1.08-4.08-3-5.19zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"/></g> +<g id="flare"><path d="M7 11H1v2h6v-2zm2.17-3.24L7.05 5.64 5.64 7.05l2.12 2.12 1.41-1.41zM13 1h-2v6h2V1zm5.36 6.05l-1.41-1.41-2.12 2.12 1.41 1.41 2.12-2.12zM17 11v2h6v-2h-6zm-5-2c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3zm2.83 7.24l2.12 2.12 1.41-1.41-2.12-2.12-1.41 1.41zm-9.19.71l1.41 1.41 2.12-2.12-1.41-1.41-2.12 2.12zM11 23h2v-6h-2v6z"/></g> +<g id="flash-auto"><path d="M3 2v12h3v9l7-12H9l4-9H3zm16 0h-2l-3.2 9h1.9l.7-2h3.2l.7 2h1.9L19 2zm-2.15 5.65L18 4l1.15 3.65h-2.3z"/></g> +<g id="flash-off"><path d="M3.27 3L2 4.27l5 5V13h3v9l3.58-6.14L17.73 20 19 18.73 3.27 3zM17 10h-4l4-8H7v2.18l8.46 8.46L17 10z"/></g> +<g id="flash-on"><path d="M7 2v11h3v9l7-12h-4l4-8z"/></g> +<g id="flip"><path d="M15 21h2v-2h-2v2zm4-12h2V7h-2v2zM3 5v14c0 1.1.9 2 2 2h4v-2H5V5h4V3H5c-1.1 0-2 .9-2 2zm16-2v2h2c0-1.1-.9-2-2-2zm-8 20h2V1h-2v22zm8-6h2v-2h-2v2zM15 5h2V3h-2v2zm4 8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2z"/></g> +<g id="gradient"><path d="M11 9h2v2h-2zm-2 2h2v2H9zm4 0h2v2h-2zm2-2h2v2h-2zM7 9h2v2H7zm12-6H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 18H7v-2h2v2zm4 0h-2v-2h2v2zm4 0h-2v-2h2v2zm2-7h-2v2h2v2h-2v-2h-2v2h-2v-2h-2v2H9v-2H7v2H5v-2h2v-2H5V5h14v6z"/></g> +<g id="grain"><path d="M10 12c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12-8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-4 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm4-4c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-4-4c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-4-4c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="grid-off"><path d="M8 4v1.45l2 2V4h4v4h-3.45l2 2H14v1.45l2 2V10h4v4h-3.45l2 2H20v1.45l2 2V4c0-1.1-.9-2-2-2H4.55l2 2H8zm8 0h4v4h-4V4zM1.27 1.27L0 2.55l2 2V20c0 1.1.9 2 2 2h15.46l2 2 1.27-1.27L1.27 1.27zM10 12.55L11.45 14H10v-1.45zm-6-6L5.45 8H4V6.55zM8 20H4v-4h4v4zm0-6H4v-4h3.45l.55.55V14zm6 6h-4v-4h3.45l.55.54V20zm2 0v-1.46L17.46 20H16z"/></g> +<g id="grid-on"><path d="M20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM8 20H4v-4h4v4zm0-6H4v-4h4v4zm0-6H4V4h4v4zm6 12h-4v-4h4v4zm0-6h-4v-4h4v4zm0-6h-4V4h4v4zm6 12h-4v-4h4v4zm0-6h-4v-4h4v4zm0-6h-4V4h4v4z"/></g> +<g id="hdr-off"><path d="M17.5 15v-2h1.1l.9 2H21l-.9-2.1c.5-.2.9-.8.9-1.4v-1c0-.8-.7-1.5-1.5-1.5H16v4.9l1.1 1.1h.4zm0-4.5h2v1h-2v-1zm-4.5 0v.4l1.5 1.5v-1.9c0-.8-.7-1.5-1.5-1.5h-1.9l1.5 1.5h.4zm-3.5-1l-7-7-1.1 1L6.9 9h-.4v2h-2V9H3v6h1.5v-2.5h2V15H8v-4.9l1.5 1.5V15h3.4l7.6 7.6 1.1-1.1-12.1-12z"/></g> +<g id="hdr-on"><path d="M21 11.5v-1c0-.8-.7-1.5-1.5-1.5H16v6h1.5v-2h1.1l.9 2H21l-.9-2.1c.5-.3.9-.8.9-1.4zm-1.5 0h-2v-1h2v1zm-13-.5h-2V9H3v6h1.5v-2.5h2V15H8V9H6.5v2zM13 9H9.5v6H13c.8 0 1.5-.7 1.5-1.5v-3c0-.8-.7-1.5-1.5-1.5zm0 4.5h-2v-3h2v3z"/></g> +<g id="hdr-strong"><path d="M17 6c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zM5 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="hdr-weak"><path d="M5 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm12-2c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm0 10c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"/></g> +<g id="healing"><path d="M17.73 12.02l3.98-3.98c.39-.39.39-1.02 0-1.41l-4.34-4.34c-.39-.39-1.02-.39-1.41 0l-3.98 3.98L8 2.29C7.8 2.1 7.55 2 7.29 2c-.25 0-.51.1-.7.29L2.25 6.63c-.39.39-.39 1.02 0 1.41l3.98 3.98L2.25 16c-.39.39-.39 1.02 0 1.41l4.34 4.34c.39.39 1.02.39 1.41 0l3.98-3.98 3.98 3.98c.2.2.45.29.71.29.26 0 .51-.1.71-.29l4.34-4.34c.39-.39.39-1.02 0-1.41l-3.99-3.98zM12 9c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm-4.71 1.96L3.66 7.34l3.63-3.63 3.62 3.62-3.62 3.63zM10 13c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm2 2c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm2-4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm2.66 9.34l-3.63-3.62 3.63-3.63 3.62 3.62-3.62 3.63z"/></g> +<g id="image"><path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/></g> +<g id="image-aspect-ratio"><path d="M16 10h-2v2h2v-2zm0 4h-2v2h2v-2zm-8-4H6v2h2v-2zm4 0h-2v2h2v-2zm8-6H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H4V6h16v12z"/></g> +<g id="iso"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5.5 7.5h2v-2H9v2h2V9H9v2H7.5V9h-2V7.5zM19 19H5L19 5v14zm-2-2v-1.5h-5V17h5z"/></g> +<g id="landscape"><path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z"/></g> +<g id="leak-add"><path d="M6 3H3v3c1.66 0 3-1.34 3-3zm8 0h-2c0 4.97-4.03 9-9 9v2c6.08 0 11-4.93 11-11zm-4 0H8c0 2.76-2.24 5-5 5v2c3.87 0 7-3.13 7-7zm0 18h2c0-4.97 4.03-9 9-9v-2c-6.07 0-11 4.93-11 11zm8 0h3v-3c-1.66 0-3 1.34-3 3zm-4 0h2c0-2.76 2.24-5 5-5v-2c-3.87 0-7 3.13-7 7z"/></g> +<g id="leak-remove"><path d="M10 3H8c0 .37-.04.72-.12 1.06l1.59 1.59C9.81 4.84 10 3.94 10 3zM3 4.27l2.84 2.84C5.03 7.67 4.06 8 3 8v2c1.61 0 3.09-.55 4.27-1.46L8.7 9.97C7.14 11.24 5.16 12 3 12v2c2.71 0 5.19-.99 7.11-2.62l2.5 2.5C10.99 15.81 10 18.29 10 21h2c0-2.16.76-4.14 2.03-5.69l1.43 1.43C14.55 17.91 14 19.39 14 21h2c0-1.06.33-2.03.89-2.84L19.73 21 21 19.73 4.27 3 3 4.27zM14 3h-2c0 1.5-.37 2.91-1.02 4.16l1.46 1.46C13.42 6.98 14 5.06 14 3zm5.94 13.12c.34-.08.69-.12 1.06-.12v-2c-.94 0-1.84.19-2.66.52l1.6 1.6zm-4.56-4.56l1.46 1.46C18.09 12.37 19.5 12 21 12v-2c-2.06 0-3.98.58-5.62 1.56z"/></g> +<g id="lens"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2z"/></g> +<g id="looks"><path d="M12 10c-3.86 0-7 3.14-7 7h2c0-2.76 2.24-5 5-5s5 2.24 5 5h2c0-3.86-3.14-7-7-7zm0-4C5.93 6 1 10.93 1 17h2c0-4.96 4.04-9 9-9s9 4.04 9 9h2c0-6.07-4.93-11-11-11z"/></g> +<g id="looks-3"><path d="M19.01 3h-14c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 7.5c0 .83-.67 1.5-1.5 1.5.83 0 1.5.67 1.5 1.5V15c0 1.11-.9 2-2 2h-4v-2h4v-2h-2v-2h2V9h-4V7h4c1.1 0 2 .89 2 2v1.5z"/></g> +<g id="looks-4"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 14h-2v-4H9V7h2v4h2V7h2v10z"/></g> +<g id="looks-5"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 6h-4v2h2c1.1 0 2 .89 2 2v2c0 1.11-.9 2-2 2H9v-2h4v-2H9V7h6v2z"/></g> +<g id="looks-6"><path d="M11 15h2v-2h-2v2zm8-12H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 6h-4v2h2c1.1 0 2 .89 2 2v2c0 1.11-.9 2-2 2h-2c-1.1 0-2-.89-2-2V9c0-1.11.9-2 2-2h4v2z"/></g> +<g id="looks-one"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-5 14h-2V9h-2V7h4v10z"/></g> +<g id="looks-two"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 8c0 1.11-.9 2-2 2h-2v2h4v2H9v-4c0-1.11.9-2 2-2h2V9H9V7h4c1.1 0 2 .89 2 2v2z"/></g> +<g id="loupe"><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.49 2 2 6.49 2 12s4.49 10 10 10h8c1.1 0 2-.9 2-2v-8c0-5.51-4.49-10-10-10zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="monochrome-photos"><path d="M20 5h-3.2L15 3H9L7.2 5H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 14h-8v-1c-2.8 0-5-2.2-5-5s2.2-5 5-5V7h8v12zm-3-6c0-2.8-2.2-5-5-5v1.8c1.8 0 3.2 1.4 3.2 3.2s-1.4 3.2-3.2 3.2V18c2.8 0 5-2.2 5-5zm-8.2 0c0 1.8 1.4 3.2 3.2 3.2V9.8c-1.8 0-3.2 1.4-3.2 3.2z"/></g> +<g id="movie-creation"><path d="M18 4l2 4h-3l-2-4h-2l2 4h-3l-2-4H8l2 4H7L5 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4h-4z"/></g> +<g id="music-note"><path d="M12 3v10.55c-.59-.34-1.27-.55-2-.55-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4V7h4V3h-6z"/></g> +<g id="nature"><path d="M13 16.12c3.47-.41 6.17-3.36 6.17-6.95 0-3.87-3.13-7-7-7s-7 3.13-7 7c0 3.47 2.52 6.34 5.83 6.89V20H5v2h14v-2h-6v-3.88z"/></g> +<g id="nature-people"><path d="M22.17 9.17c0-3.87-3.13-7-7-7s-7 3.13-7 7c0 3.47 2.52 6.34 5.83 6.89V20H6v-3h1v-4c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v4h1v5h16v-2h-3v-3.88c3.47-.41 6.17-3.36 6.17-6.95zM4.5 11c.83 0 1.5-.67 1.5-1.5S5.33 8 4.5 8 3 8.67 3 9.5 3.67 11 4.5 11z"/></g> +<g id="navigate-before"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></g> +<g id="navigate-next"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></g> +<g id="palette"><path d="M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9c.83 0 1.5-.67 1.5-1.5 0-.39-.15-.74-.39-1.01-.23-.26-.38-.61-.38-.99 0-.83.67-1.5 1.5-1.5H16c2.76 0 5-2.24 5-5 0-4.42-4.03-8-9-8zm-5.5 9c-.83 0-1.5-.67-1.5-1.5S5.67 9 6.5 9 8 9.67 8 10.5 7.33 12 6.5 12zm3-4C8.67 8 8 7.33 8 6.5S8.67 5 9.5 5s1.5.67 1.5 1.5S10.33 8 9.5 8zm5 0c-.83 0-1.5-.67-1.5-1.5S13.67 5 14.5 5s1.5.67 1.5 1.5S15.33 8 14.5 8zm3 4c-.83 0-1.5-.67-1.5-1.5S16.67 9 17.5 9s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="panorama"><path d="M23 18V6c0-1.1-.9-2-2-2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zM8.5 12.5l2.5 3.01L14.5 11l4.5 6H5l3.5-4.5z"/></g> +<g id="panorama-fish-eye"><path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="panorama-horizontal"><path d="M20 6.54v10.91c-2.6-.77-5.28-1.16-8-1.16-2.72 0-5.4.39-8 1.16V6.54c2.6.77 5.28 1.16 8 1.16 2.72.01 5.4-.38 8-1.16M21.43 4c-.1 0-.2.02-.31.06C18.18 5.16 15.09 5.7 12 5.7c-3.09 0-6.18-.55-9.12-1.64-.11-.04-.22-.06-.31-.06-.34 0-.57.23-.57.63v14.75c0 .39.23.62.57.62.1 0 .2-.02.31-.06 2.94-1.1 6.03-1.64 9.12-1.64 3.09 0 6.18.55 9.12 1.64.11.04.21.06.31.06.33 0 .57-.23.57-.63V4.63c0-.4-.24-.63-.57-.63z"/></g> +<g id="panorama-vertical"><path d="M19.94 21.12c-1.1-2.94-1.64-6.03-1.64-9.12 0-3.09.55-6.18 1.64-9.12.04-.11.06-.22.06-.31 0-.34-.23-.57-.63-.57H4.63c-.4 0-.63.23-.63.57 0 .1.02.2.06.31C5.16 5.82 5.71 8.91 5.71 12c0 3.09-.55 6.18-1.64 9.12-.05.11-.07.22-.07.31 0 .33.23.57.63.57h14.75c.39 0 .63-.24.63-.57-.01-.1-.03-.2-.07-.31zM6.54 20c.77-2.6 1.16-5.28 1.16-8 0-2.72-.39-5.4-1.16-8h10.91c-.77 2.6-1.16 5.28-1.16 8 0 2.72.39 5.4 1.16 8H6.54z"/></g> +<g id="panorama-wide-angle"><path d="M12 6c2.45 0 4.71.2 7.29.64.47 1.78.71 3.58.71 5.36 0 1.78-.24 3.58-.71 5.36-2.58.44-4.84.64-7.29.64s-4.71-.2-7.29-.64C4.24 15.58 4 13.78 4 12c0-1.78.24-3.58.71-5.36C7.29 6.2 9.55 6 12 6m0-2c-2.73 0-5.22.24-7.95.72l-.93.16-.25.9C2.29 7.85 2 9.93 2 12s.29 4.15.87 6.22l.25.89.93.16c2.73.49 5.22.73 7.95.73s5.22-.24 7.95-.72l.93-.16.25-.89c.58-2.08.87-4.16.87-6.23s-.29-4.15-.87-6.22l-.25-.89-.93-.16C17.22 4.24 14.73 4 12 4z"/></g> +<g id="photo"><path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/></g> +<g id="photo-album"><path d="M18 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 4h5v8l-2.5-1.5L6 12V4zm0 15l3-3.86 2.14 2.58 3-3.86L18 19H6z"/></g> +<g id="photo-camera"><circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"/></g> +<g id="photo-library"><path d="M22 16V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2zm-11-4l2.03 2.71L16 11l4 5H8l3-4zM2 6v14c0 1.1.9 2 2 2h14v-2H4V6H2z"/></g> +<g id="photo-size-select-actual"><path d="M21 3H3C2 3 1 4 1 5v14c0 1.1.9 2 2 2h18c1 0 2-1 2-2V5c0-1-1-2-2-2zM5 17l3.5-4.5 2.5 3.01L14.5 11l4.5 6H5z"/></g> +<g id="photo-size-select-large"><path d="M21 15h2v2h-2v-2zm0-4h2v2h-2v-2zm2 8h-2v2c1 0 2-1 2-2zM13 3h2v2h-2V3zm8 4h2v2h-2V7zm0-4v2h2c0-1-1-2-2-2zM1 7h2v2H1V7zm16-4h2v2h-2V3zm0 16h2v2h-2v-2zM3 3C2 3 1 4 1 5h2V3zm6 0h2v2H9V3zM5 3h2v2H5V3zm-4 8v8c0 1.1.9 2 2 2h12V11H1zm2 8l2.5-3.21 1.79 2.15 2.5-3.22L13 19H3z"/></g> +<g id="photo-size-select-small"><path d="M23 15h-2v2h2v-2zm0-4h-2v2h2v-2zm0 8h-2v2c1 0 2-1 2-2zM15 3h-2v2h2V3zm8 4h-2v2h2V7zm-2-4v2h2c0-1-1-2-2-2zM3 21h8v-6H1v4c0 1.1.9 2 2 2zM3 7H1v2h2V7zm12 12h-2v2h2v-2zm4-16h-2v2h2V3zm0 16h-2v2h2v-2zM3 3C2 3 1 4 1 5h2V3zm0 8H1v2h2v-2zm8-8H9v2h2V3zM7 3H5v2h2V3z"/></g> +<g id="picture-as-pdf"><path d="M20 2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-8.5 7.5c0 .83-.67 1.5-1.5 1.5H9v2H7.5V7H10c.83 0 1.5.67 1.5 1.5v1zm5 2c0 .83-.67 1.5-1.5 1.5h-2.5V7H15c.83 0 1.5.67 1.5 1.5v3zm4-3H19v1h1.5V11H19v2h-1.5V7h3v1.5zM9 9.5h1v-1H9v1zM4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm10 5.5h1v-3h-1v3z"/></g> +<g id="portrait"><path d="M12 12.25c1.24 0 2.25-1.01 2.25-2.25S13.24 7.75 12 7.75 9.75 8.76 9.75 10s1.01 2.25 2.25 2.25zm4.5 4c0-1.5-3-2.25-4.5-2.25s-4.5.75-4.5 2.25V17h9v-.75zM19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/></g> +<g id="remove-red-eye"><path d="M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="rotate-90-degrees-ccw"><path d="M7.34 6.41L.86 12.9l6.49 6.48 6.49-6.48-6.5-6.49zM3.69 12.9l3.66-3.66L11 12.9l-3.66 3.66-3.65-3.66zm15.67-6.26C17.61 4.88 15.3 4 13 4V.76L8.76 5 13 9.24V6c1.79 0 3.58.68 4.95 2.05 2.73 2.73 2.73 7.17 0 9.9C16.58 19.32 14.79 20 13 20c-.97 0-1.94-.21-2.84-.61l-1.49 1.49C10.02 21.62 11.51 22 13 22c2.3 0 4.61-.88 6.36-2.64 3.52-3.51 3.52-9.21 0-12.72z"/></g> +<g id="rotate-left"><path d="M7.11 8.53L5.7 7.11C4.8 8.27 4.24 9.61 4.07 11h2.02c.14-.87.49-1.72 1.02-2.47zM6.09 13H4.07c.17 1.39.72 2.73 1.62 3.89l1.41-1.42c-.52-.75-.87-1.59-1.01-2.47zm1.01 5.32c1.16.9 2.51 1.44 3.9 1.61V17.9c-.87-.15-1.71-.49-2.46-1.03L7.1 18.32zM13 4.07V1L8.45 5.55 13 10V6.09c2.84.48 5 2.94 5 5.91s-2.16 5.43-5 5.91v2.02c3.95-.49 7-3.85 7-7.93s-3.05-7.44-7-7.93z"/></g> +<g id="rotate-right"><path d="M15.55 5.55L11 1v3.07C7.06 4.56 4 7.92 4 12s3.05 7.44 7 7.93v-2.02c-2.84-.48-5-2.94-5-5.91s2.16-5.43 5-5.91V10l4.55-4.45zM19.93 11c-.17-1.39-.72-2.73-1.62-3.89l-1.42 1.42c.54.75.88 1.6 1.02 2.47h2.02zM13 17.9v2.02c1.39-.17 2.74-.71 3.9-1.61l-1.44-1.44c-.75.54-1.59.89-2.46 1.03zm3.89-2.42l1.42 1.41c.9-1.16 1.45-2.5 1.62-3.89h-2.02c-.14.87-.48 1.72-1.02 2.48z"/></g> +<g id="slideshow"><path d="M10 8v8l5-4-5-4zm9-5H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/></g> +<g id="straighten"><path d="M21 6H3c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 10H3V8h2v4h2V8h2v4h2V8h2v4h2V8h2v4h2V8h2v8z"/></g> +<g id="style"><path d="M2.53 19.65l1.34.56v-9.03l-2.43 5.86c-.41 1.02.08 2.19 1.09 2.61zm19.5-3.7L17.07 3.98c-.31-.75-1.04-1.21-1.81-1.23-.26 0-.53.04-.79.15L7.1 5.95c-.75.31-1.21 1.03-1.23 1.8-.01.27.04.54.15.8l4.96 11.97c.31.76 1.05 1.22 1.83 1.23.26 0 .52-.05.77-.15l7.36-3.05c1.02-.42 1.51-1.59 1.09-2.6zM7.88 8.75c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-2 11c0 1.1.9 2 2 2h1.45l-3.45-8.34v6.34z"/></g> +<g id="switch-camera"><path d="M20 4h-3.17L15 2H9L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 11.5V13H9v2.5L5.5 12 9 8.5V11h6V8.5l3.5 3.5-3.5 3.5z"/></g> +<g id="switch-video"><path d="M18 9.5V6c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h14c.55 0 1-.45 1-1v-3.5l4 4v-13l-4 4zm-5 6V13H7v2.5L3.5 12 7 8.5V11h6V8.5l3.5 3.5-3.5 3.5z"/></g> +<g id="tag-faces"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 6.5c2.33 0 4.31-1.46 5.11-3.5H6.89c.8 2.04 2.78 3.5 5.11 3.5z"/></g> +<g id="texture"><path d="M19.51 3.08L3.08 19.51c.09.34.27.65.51.9.25.24.56.42.9.51L20.93 4.49c-.19-.69-.73-1.23-1.42-1.41zM11.88 3L3 11.88v2.83L14.71 3h-2.83zM5 3c-1.1 0-2 .9-2 2v2l4-4H5zm14 18c.55 0 1.05-.22 1.41-.59.37-.36.59-.86.59-1.41v-2l-4 4h2zm-9.71 0h2.83L21 12.12V9.29L9.29 21z"/></g> +<g id="timelapse"><path d="M16.24 7.76C15.07 6.59 13.54 6 12 6v6l-4.24 4.24c2.34 2.34 6.14 2.34 8.49 0 2.34-2.34 2.34-6.14-.01-8.48zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="timer"><path d="M15 1H9v2h6V1zm-4 13h2V8h-2v6zm8.03-6.61l1.42-1.42c-.43-.51-.9-.99-1.41-1.41l-1.42 1.42C16.07 4.74 14.12 4 12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9 9-4.03 9-9c0-2.12-.74-4.07-1.97-5.61zM12 20c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="timer-10"><path d="M0 7.72V9.4l3-1V18h2V6h-.25L0 7.72zm23.78 6.65c-.14-.28-.35-.53-.63-.74-.28-.21-.61-.39-1.01-.53s-.85-.27-1.35-.38c-.35-.07-.64-.15-.87-.23-.23-.08-.41-.16-.55-.25-.14-.09-.23-.19-.28-.3-.05-.11-.08-.24-.08-.39 0-.14.03-.28.09-.41.06-.13.15-.25.27-.34.12-.1.27-.18.45-.24s.4-.09.64-.09c.25 0 .47.04.66.11.19.07.35.17.48.29.13.12.22.26.29.42.06.16.1.32.1.49h1.95c0-.39-.08-.75-.24-1.09-.16-.34-.39-.63-.69-.88-.3-.25-.66-.44-1.09-.59C21.49 9.07 21 9 20.46 9c-.51 0-.98.07-1.39.21-.41.14-.77.33-1.06.57-.29.24-.51.52-.67.84-.16.32-.23.65-.23 1.01s.08.69.23.96c.15.28.36.52.64.73.27.21.6.38.98.53.38.14.81.26 1.27.36.39.08.71.17.95.26s.43.19.57.29c.13.1.22.22.27.34.05.12.07.25.07.39 0 .32-.13.57-.4.77-.27.2-.66.29-1.17.29-.22 0-.43-.02-.64-.08-.21-.05-.4-.13-.56-.24-.17-.11-.3-.26-.41-.44-.11-.18-.17-.41-.18-.67h-1.89c0 .36.08.71.24 1.05.16.34.39.65.7.93.31.27.69.49 1.15.66.46.17.98.25 1.58.25.53 0 1.01-.06 1.44-.19.43-.13.8-.31 1.11-.54.31-.23.54-.51.71-.83.17-.32.25-.67.25-1.06-.02-.4-.09-.74-.24-1.02zm-9.96-7.32c-.34-.4-.75-.7-1.23-.88-.47-.18-1.01-.27-1.59-.27-.58 0-1.11.09-1.59.27-.48.18-.89.47-1.23.88-.34.41-.6.93-.79 1.59-.18.65-.28 1.45-.28 2.39v1.92c0 .94.09 1.74.28 2.39.19.66.45 1.19.8 1.6.34.41.75.71 1.23.89.48.18 1.01.28 1.59.28.59 0 1.12-.09 1.59-.28.48-.18.88-.48 1.22-.89.34-.41.6-.94.78-1.6.18-.65.28-1.45.28-2.39v-1.92c0-.94-.09-1.74-.28-2.39-.18-.66-.44-1.19-.78-1.59zm-.92 6.17c0 .6-.04 1.11-.12 1.53-.08.42-.2.76-.36 1.02-.16.26-.36.45-.59.57-.23.12-.51.18-.82.18-.3 0-.58-.06-.82-.18s-.44-.31-.6-.57c-.16-.26-.29-.6-.38-1.02-.09-.42-.13-.93-.13-1.53v-2.5c0-.6.04-1.11.13-1.52.09-.41.21-.74.38-1 .16-.25.36-.43.6-.55.24-.11.51-.17.81-.17.31 0 .58.06.81.17.24.11.44.29.6.55.16.25.29.58.37.99.08.41.13.92.13 1.52v2.51z"/></g> +<g id="timer-3"><path d="M11.61 12.97c-.16-.24-.36-.46-.62-.65-.25-.19-.56-.35-.93-.48.3-.14.57-.3.8-.5.23-.2.42-.41.57-.64.15-.23.27-.46.34-.71.08-.24.11-.49.11-.73 0-.55-.09-1.04-.28-1.46-.18-.42-.44-.77-.78-1.06-.33-.28-.73-.5-1.2-.64-.45-.13-.97-.2-1.53-.2-.55 0-1.06.08-1.52.24-.47.17-.87.4-1.2.69-.33.29-.6.63-.78 1.03-.2.39-.29.83-.29 1.29h1.98c0-.26.05-.49.14-.69.09-.2.22-.38.38-.52.17-.14.36-.25.58-.33.22-.08.46-.12.73-.12.61 0 1.06.16 1.36.47.3.31.44.75.44 1.32 0 .27-.04.52-.12.74-.08.22-.21.41-.38.57-.17.16-.38.28-.63.37-.25.09-.55.13-.89.13H6.72v1.57H7.9c.34 0 .64.04.91.11.27.08.5.19.69.35.19.16.34.36.44.61.1.24.16.54.16.87 0 .62-.18 1.09-.53 1.42-.35.33-.84.49-1.45.49-.29 0-.56-.04-.8-.13-.24-.08-.44-.2-.61-.36-.17-.16-.3-.34-.39-.56-.09-.22-.14-.46-.14-.72H4.19c0 .55.11 1.03.32 1.45.21.42.5.77.86 1.05s.77.49 1.24.63.96.21 1.48.21c.57 0 1.09-.08 1.58-.23.49-.15.91-.38 1.26-.68.36-.3.64-.66.84-1.1.2-.43.3-.93.3-1.48 0-.29-.04-.58-.11-.86-.08-.25-.19-.51-.35-.76zm9.26 1.4c-.14-.28-.35-.53-.63-.74-.28-.21-.61-.39-1.01-.53s-.85-.27-1.35-.38c-.35-.07-.64-.15-.87-.23-.23-.08-.41-.16-.55-.25-.14-.09-.23-.19-.28-.3-.05-.11-.08-.24-.08-.39s.03-.28.09-.41c.06-.13.15-.25.27-.34.12-.1.27-.18.45-.24s.4-.09.64-.09c.25 0 .47.04.66.11.19.07.35.17.48.29.13.12.22.26.29.42.06.16.1.32.1.49h1.95c0-.39-.08-.75-.24-1.09-.16-.34-.39-.63-.69-.88-.3-.25-.66-.44-1.09-.59-.43-.15-.92-.22-1.46-.22-.51 0-.98.07-1.39.21-.41.14-.77.33-1.06.57-.29.24-.51.52-.67.84-.16.32-.23.65-.23 1.01s.08.68.23.96c.15.28.37.52.64.73.27.21.6.38.98.53.38.14.81.26 1.27.36.39.08.71.17.95.26s.43.19.57.29c.13.1.22.22.27.34.05.12.07.25.07.39 0 .32-.13.57-.4.77-.27.2-.66.29-1.17.29-.22 0-.43-.02-.64-.08-.21-.05-.4-.13-.56-.24-.17-.11-.3-.26-.41-.44-.11-.18-.17-.41-.18-.67h-1.89c0 .36.08.71.24 1.05.16.34.39.65.7.93.31.27.69.49 1.15.66.46.17.98.25 1.58.25.53 0 1.01-.06 1.44-.19.43-.13.8-.31 1.11-.54.31-.23.54-.51.71-.83.17-.32.25-.67.25-1.06-.02-.4-.09-.74-.24-1.02z"/></g> +<g id="timer-off"><path d="M19.04 4.55l-1.42 1.42C16.07 4.74 14.12 4 12 4c-1.83 0-3.53.55-4.95 1.48l1.46 1.46C9.53 6.35 10.73 6 12 6c3.87 0 7 3.13 7 7 0 1.27-.35 2.47-.94 3.49l1.45 1.45C20.45 16.53 21 14.83 21 13c0-2.12-.74-4.07-1.97-5.61l1.42-1.42-1.41-1.42zM15 1H9v2h6V1zm-4 8.44l2 2V8h-2v1.44zM3.02 4L1.75 5.27 4.5 8.03C3.55 9.45 3 11.16 3 13c0 4.97 4.02 9 9 9 1.84 0 3.55-.55 4.98-1.5l2.5 2.5 1.27-1.27-7.71-7.71L3.02 4zM12 20c-3.87 0-7-3.13-7-7 0-1.28.35-2.48.95-3.52l9.56 9.56c-1.03.61-2.23.96-3.51.96z"/></g> +<g id="tonality"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.94-.49-7-3.85-7-7.93s3.05-7.44 7-7.93v15.86zm2-15.86c1.03.13 2 .45 2.87.93H13v-.93zM13 7h5.24c.25.31.48.65.68 1H13V7zm0 3h6.74c.08.33.15.66.19 1H13v-1zm0 9.93V19h2.87c-.87.48-1.84.8-2.87.93zM18.24 17H13v-1h5.92c-.2.35-.43.69-.68 1zm1.5-3H13v-1h6.93c-.04.34-.11.67-.19 1z"/></g> +<g id="transform"><path d="M22 18v-2H8V4h2L7 1 4 4h2v2H2v2h4v8c0 1.1.9 2 2 2h8v2h-2l3 3 3-3h-2v-2h4zM10 8h6v6h2V8c0-1.1-.9-2-2-2h-6v2z"/></g> +<g id="tune"><path d="M3 17v2h6v-2H3zM3 5v2h10V5H3zm10 16v-2h8v-2h-8v-2h-2v6h2zM7 9v2H3v2h4v2h2V9H7zm14 4v-2H11v2h10zm-6-4h2V7h4V5h-4V3h-2v6z"/></g> +<g id="view-comfy"><path d="M3 9h4V5H3v4zm0 5h4v-4H3v4zm5 0h4v-4H8v4zm5 0h4v-4h-4v4zM8 9h4V5H8v4zm5-4v4h4V5h-4zm5 9h4v-4h-4v4zM3 19h4v-4H3v4zm5 0h4v-4H8v4zm5 0h4v-4h-4v4zm5 0h4v-4h-4v4zm0-14v4h4V5h-4z"/></g> +<g id="view-compact"><path d="M3 19h6v-7H3v7zm7 0h12v-7H10v7zM3 5v6h19V5H3z"/></g> +<g id="vignette"><path d="M21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-9 15c-4.42 0-8-2.69-8-6s3.58-6 8-6 8 2.69 8 6-3.58 6-8 6z"/></g> +<g id="wb-auto"><path d="M6.85 12.65h2.3L8 9l-1.15 3.65zM22 7l-1.2 6.29L19.3 7h-1.6l-1.49 6.29L15 7h-.76C12.77 5.17 10.53 4 8 4c-4.42 0-8 3.58-8 8s3.58 8 8 8c3.13 0 5.84-1.81 7.15-4.43l.1.43H17l1.5-6.1L20 16h1.75l2.05-9H22zm-11.7 9l-.7-2H6.4l-.7 2H3.8L7 7h2l3.2 9h-1.9z"/></g> +<g id="wb-cloudy"><path d="M19.36 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.64-4.96z"/></g> +<g id="wb-incandescent"><path d="M3.55 18.54l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8zM11 22.45h2V19.5h-2v2.95zM4 10.5H1v2h3v-2zm11-4.19V1.5H9v4.81C7.21 7.35 6 9.28 6 11.5c0 3.31 2.69 6 6 6s6-2.69 6-6c0-2.22-1.21-4.15-3-5.19zm5 4.19v2h3v-2h-3zm-2.76 7.66l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4z"/></g> +<g id="wb-iridescent"><path d="M5 14.5h14v-6H5v6zM11 .55V3.5h2V.55h-2zm8.04 2.5l-1.79 1.79 1.41 1.41 1.8-1.79-1.42-1.41zM13 22.45V19.5h-2v2.95h2zm7.45-3.91l-1.8-1.79-1.41 1.41 1.79 1.8 1.42-1.42zM3.55 4.46l1.79 1.79 1.41-1.41-1.79-1.79-1.41 1.41zm1.41 15.49l1.79-1.8-1.41-1.41-1.79 1.79 1.41 1.42z"/></g> +<g id="wb-sunny"><path d="M6.76 4.84l-1.8-1.79-1.41 1.41 1.79 1.79 1.42-1.41zM4 10.5H1v2h3v-2zm9-9.95h-2V3.5h2V.55zm7.45 3.91l-1.41-1.41-1.79 1.79 1.41 1.41 1.79-1.79zm-3.21 13.7l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4zM20 10.5v2h3v-2h-3zm-8-5c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm-1 16.95h2V19.5h-2v2.95zm-7.45-3.91l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/index.html b/third_party/polymer/v1_0/components-chromium/iron-icons/index.html new file mode 100644 index 0000000..95d1991 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/iron-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/iron-icons.html new file mode 100644 index 0000000..c0cf1e9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/iron-icons.html @@ -0,0 +1,303 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!-- +`iron-icons` is a utitliy import that includes the definition for the `iron-icon` element, `iron-iconset-svg` element, as well as an import for the default icon set. + +The `iron-icons` directory also includes imports for additional icon sets that can be loaded into your project. + +Example loading icon set: + + <link rel="import" href="../iron-icons/maps-icons.html"> + +To use an icon from one of these sets, first prefix your `iron-icon` with the icon set name, followed by a colon, ":", and then the icon id. + +Example using the directions-bus icon from the maps icon set: + + <iron-icon icon="maps:directions-bus"></iron-icon> + + +See [iron-icon](#iron-icon) for more information about working with icons. + +See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for more information about how to create a custom iconset. + +@group Iron Elements +@element iron-icons +@demo demo/index.html +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="icons" size="24"> +<svg><defs> +<g id="3d-rotation"><path d="M7.52 21.48C4.25 19.94 1.91 16.76 1.55 13H.05C.56 19.16 5.71 24 12 24l.66-.03-3.81-3.81-1.33 1.32zm.89-6.52c-.19 0-.37-.03-.52-.08-.16-.06-.29-.13-.4-.24-.11-.1-.2-.22-.26-.37-.06-.14-.09-.3-.09-.47h-1.3c0 .36.07.68.21.95.14.27.33.5.56.69.24.18.51.32.82.41.3.1.62.15.96.15.37 0 .72-.05 1.03-.15.32-.1.6-.25.83-.44s.42-.43.55-.72c.13-.29.2-.61.2-.97 0-.19-.02-.38-.07-.56-.05-.18-.12-.35-.23-.51-.1-.16-.24-.3-.4-.43-.17-.13-.37-.23-.61-.31.2-.09.37-.2.52-.33.15-.13.27-.27.37-.42.1-.15.17-.3.22-.46.05-.16.07-.32.07-.48 0-.36-.06-.68-.18-.96-.12-.28-.29-.51-.51-.69-.2-.19-.47-.33-.77-.43C9.1 8.05 8.76 8 8.39 8c-.36 0-.69.05-1 .16-.3.11-.57.26-.79.45-.21.19-.38.41-.51.67-.12.26-.18.54-.18.85h1.3c0-.17.03-.32.09-.45s.14-.25.25-.34c.11-.09.23-.17.38-.22.15-.05.3-.08.48-.08.4 0 .7.1.89.31.19.2.29.49.29.86 0 .18-.03.34-.08.49-.05.15-.14.27-.25.37-.11.1-.25.18-.41.24-.16.06-.36.09-.58.09H7.5v1.03h.77c.22 0 .42.02.6.07s.33.13.45.23c.12.11.22.24.29.4.07.16.1.35.1.57 0 .41-.12.72-.35.93-.23.23-.55.33-.95.33zm8.55-5.92c-.32-.33-.7-.59-1.14-.77-.43-.18-.92-.27-1.46-.27H12v8h2.3c.55 0 1.06-.09 1.51-.27.45-.18.84-.43 1.16-.76.32-.33.57-.73.74-1.19.17-.47.26-.99.26-1.57v-.4c0-.58-.09-1.1-.26-1.57-.18-.47-.43-.87-.75-1.2zm-.39 3.16c0 .42-.05.79-.14 1.13-.1.33-.24.62-.43.85-.19.23-.43.41-.71.53-.29.12-.62.18-.99.18h-.91V9.12h.97c.72 0 1.27.23 1.64.69.38.46.57 1.12.57 1.99v.4zM12 0l-.66.03 3.81 3.81 1.33-1.33c3.27 1.55 5.61 4.72 5.96 8.48h1.5C23.44 4.84 18.29 0 12 0z"/></g> +<g id="accessibility"><path d="M12 2c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm9 7h-6v13h-2v-6h-2v6H9V9H3V7h18v2z"/></g> +<g id="account-balance"><path d="M4 10v7h3v-7H4zm6 0v7h3v-7h-3zM2 22h19v-3H2v3zm14-12v7h3v-7h-3zm-4.5-9L2 6v2h19V6l-9.5-5z"/></g> +<g id="account-balance-wallet"><path d="M21 18v1c0 1.1-.9 2-2 2H5c-1.11 0-2-.9-2-2V5c0-1.1.89-2 2-2h14c1.1 0 2 .9 2 2v1h-9c-1.11 0-2 .9-2 2v8c0 1.1.89 2 2 2h9zm-9-2h10V8H12v8zm4-2.5c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="account-box"><path d="M3 5v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2H5c-1.11 0-2 .9-2 2zm12 4c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3zm-9 8c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1H6v-1z"/></g> +<g id="account-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm0 14.2c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08 1.99 0 5.97 1.09 6 3.08-1.29 1.94-3.5 3.22-6 3.22z"/></g> +<g id="add"><path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/></g> +<g id="add-alert"><path d="M10.01 21.01c0 1.1.89 1.99 1.99 1.99s1.99-.89 1.99-1.99h-3.98zm8.87-4.19V11c0-3.25-2.25-5.97-5.29-6.69v-.72C13.59 2.71 12.88 2 12 2s-1.59.71-1.59 1.59v.72C7.37 5.03 5.12 7.75 5.12 11v5.82L3 18.94V20h18v-1.06l-2.12-2.12zM16 13.01h-3v3h-2v-3H8V11h3V8h2v3h3v2.01z"/></g> +<g id="add-box"><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"/></g> +<g id="add-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm5 11h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"/></g> +<g id="add-circle-outline"><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="add-shopping-cart"><path d="M11 9h2V6h3V4h-3V1h-2v3H8v2h3v3zm-4 9c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zm10 0c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2zm-9.83-3.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.86-7.01L19.42 4h-.01l-1.1 2-2.76 5H8.53l-.13-.27L6.16 6l-.95-2-.94-2H1v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.13 0-.25-.11-.25-.25z"/></g> +<g id="alarm"><path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="alarm-add"><path d="M7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm1-11h-2v3H8v2h3v3h2v-3h3v-2h-3V9z"/></g> +<g id="alarm-off"><path d="M12 6c3.87 0 7 3.13 7 7 0 .84-.16 1.65-.43 2.4l1.52 1.52c.58-1.19.91-2.51.91-3.92 0-4.97-4.03-9-9-9-1.41 0-2.73.33-3.92.91L9.6 6.43C10.35 6.16 11.16 6 12 6zm10-.28l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM2.92 2.29L1.65 3.57 2.98 4.9l-1.11.93 1.42 1.42 1.11-.94.8.8C3.83 8.69 3 10.75 3 13c0 4.97 4.02 9 9 9 2.25 0 4.31-.83 5.89-2.2l2.2 2.2 1.27-1.27L3.89 3.27l-.97-.98zm13.55 16.1C15.26 19.39 13.7 20 12 20c-3.87 0-7-3.13-7-7 0-1.7.61-3.26 1.61-4.47l9.86 9.86zM8.02 3.28L6.6 1.86l-.86.71 1.42 1.42.86-.71z"/></g> +<g id="alarm-on"><path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm-1.46-5.47L8.41 12.4l-1.06 1.06 3.18 3.18 6-6-1.06-1.06-4.93 4.95z"/></g> +<g id="android"><path d="M6 18c0 .55.45 1 1 1h1v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h2v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h1c.55 0 1-.45 1-1V8H6v10zM3.5 8C2.67 8 2 8.67 2 9.5v7c0 .83.67 1.5 1.5 1.5S5 17.33 5 16.5v-7C5 8.67 4.33 8 3.5 8zm17 0c-.83 0-1.5.67-1.5 1.5v7c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5v-7c0-.83-.67-1.5-1.5-1.5zm-4.97-5.84l1.3-1.3c.2-.2.2-.51 0-.71-.2-.2-.51-.2-.71 0l-1.48 1.48C13.85 1.23 12.95 1 12 1c-.96 0-1.86.23-2.66.63L7.85.15c-.2-.2-.51-.2-.71 0-.2.2-.2.51 0 .71l1.31 1.31C6.97 3.26 6 5.01 6 7h12c0-1.99-.97-3.75-2.47-4.84zM10 5H9V4h1v1zm5 0h-1V4h1v1z"/></g> +<g id="announcement"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 9h-2V5h2v6zm0 4h-2v-2h2v2z"/></g> +<g id="apps"><path d="M4 8h4V4H4v4zm6 12h4v-4h-4v4zm-6 0h4v-4H4v4zm0-6h4v-4H4v4zm6 0h4v-4h-4v4zm6-10v4h4V4h-4zm-6 4h4V4h-4v4zm6 6h4v-4h-4v4zm0 6h4v-4h-4v4z"/></g> +<g id="archive"><path d="M20.54 5.23l-1.39-1.68C18.88 3.21 18.47 3 18 3H6c-.47 0-.88.21-1.16.55L3.46 5.23C3.17 5.57 3 6.02 3 6.5V19c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6.5c0-.48-.17-.93-.46-1.27zM12 17.5L6.5 12H10v-2h4v2h3.5L12 17.5zM5.12 5l.81-1h12l.94 1H5.12z"/></g> +<g id="arrow-back"><path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z"/></g> +<g id="arrow-drop-down"><path d="M7 10l5 5 5-5z"/></g> +<g id="arrow-drop-down-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 12l-4-4h8l-4 4z"/></g> +<g id="arrow-drop-up"><path d="M7 14l5-5 5 5z"/></g> +<g id="arrow-forward"><path d="M12 4l-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8z"/></g> +<g id="aspect-ratio"><path d="M19 12h-2v3h-3v2h5v-5zM7 9h3V7H5v5h2V9zm14-6H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/></g> +<g id="assessment"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/></g> +<g id="assignment"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm2 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z"/></g> +<g id="assignment-ind"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm0 4c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H6v-1.4c0-2 4-3.1 6-3.1s6 1.1 6 3.1V19z"/></g> +<g id="assignment-late"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-6 15h-2v-2h2v2zm0-4h-2V8h2v6zm-1-9c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="assignment-return"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm4 12h-4v3l-5-5 5-5v3h4v4z"/></g> +<g id="assignment-returned"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm0 15l-5-5h3V9h4v4h3l-5 5z"/></g> +<g id="assignment-turned-in"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm-2 14l-4-4 1.41-1.41L10 14.17l6.59-6.59L18 9l-8 8z"/></g> +<g id="attachment"><path d="M7.5 18C4.46 18 2 15.54 2 12.5S4.46 7 7.5 7H18c2.21 0 4 1.79 4 4s-1.79 4-4 4H9.5C8.12 15 7 13.88 7 12.5S8.12 10 9.5 10H17v1.5H9.5c-.55 0-1 .45-1 1s.45 1 1 1H18c1.38 0 2.5-1.12 2.5-2.5S19.38 8.5 18 8.5H7.5c-2.21 0-4 1.79-4 4s1.79 4 4 4H17V18H7.5z"/></g> +<g id="autorenew"><path d="M12 6v3l4-4-4-4v3c-4.42 0-8 3.58-8 8 0 1.57.46 3.03 1.24 4.26L6.7 14.8c-.45-.83-.7-1.79-.7-2.8 0-3.31 2.69-6 6-6zm6.76 1.74L17.3 9.2c.44.84.7 1.79.7 2.8 0 3.31-2.69 6-6 6v-3l-4 4 4 4v-3c4.42 0 8-3.58 8-8 0-1.57-.46-3.03-1.24-4.26z"/></g> +<g id="backspace"><path d="M22 3H7c-.69 0-1.23.35-1.59.88L0 12l5.41 8.11c.36.53.9.89 1.59.89h15c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-3 12.59L17.59 17 14 13.41 10.41 17 9 15.59 12.59 12 9 8.41 10.41 7 14 10.59 17.59 7 19 8.41 15.41 12 19 15.59z"/></g> +<g id="backup"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM14 13v4h-4v-4H7l5-5 5 5h-3z"/></g> +<g id="block"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM4 12c0-4.42 3.58-8 8-8 1.85 0 3.55.63 4.9 1.69L5.69 16.9C4.63 15.55 4 13.85 4 12zm8 8c-1.85 0-3.55-.63-4.9-1.69L18.31 7.1C19.37 8.45 20 10.15 20 12c0 4.42-3.58 8-8 8z"/></g> +<g id="book"><path d="M18 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 4h5v8l-2.5-1.5L6 12V4z"/></g> +<g id="bookmark"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2z"/></g> +<g id="bookmark-border"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2zm0 15l-5-2.18L7 18V5h10v13z"/></g> +<g id="bug-report"><path d="M20 8h-2.81c-.45-.78-1.07-1.45-1.82-1.96L17 4.41 15.59 3l-2.17 2.17C12.96 5.06 12.49 5 12 5c-.49 0-.96.06-1.41.17L8.41 3 7 4.41l1.62 1.63C7.88 6.55 7.26 7.22 6.81 8H4v2h2.09c-.05.33-.09.66-.09 1v1H4v2h2v1c0 .34.04.67.09 1H4v2h2.81c1.04 1.79 2.97 3 5.19 3s4.15-1.21 5.19-3H20v-2h-2.09c.05-.33.09-.66.09-1v-1h2v-2h-2v-1c0-.34-.04-.67-.09-1H20V8zm-6 8h-4v-2h4v2zm0-4h-4v-2h4v2z"/></g> +<g id="build"><path d="M22.7 19l-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z"/></g> +<g id="cached"><path d="M19 8l-4 4h3c0 3.31-2.69 6-6 6-1.01 0-1.97-.25-2.8-.7l-1.46 1.46C8.97 19.54 10.43 20 12 20c4.42 0 8-3.58 8-8h3l-4-4zM6 12c0-3.31 2.69-6 6-6 1.01 0 1.97.25 2.8.7l1.46-1.46C15.03 4.46 13.57 4 12 4c-4.42 0-8 3.58-8 8H1l4 4 4-4H6z"/></g> +<g id="camera-enhance"><path d="M9 3L7.17 5H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2h-3.17L15 3H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zM12 17l1.25-2.75L16 13l-2.75-1.25L12 9l-1.25 2.75L8 13l2.75 1.25z"/></g> +<g id="cancel"><path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"/></g> +<g id="card-giftcard"><path d="M20 6h-2.18c.11-.31.18-.65.18-1 0-1.66-1.34-3-3-3-1.05 0-1.96.54-2.5 1.35l-.5.67-.5-.68C10.96 2.54 10.05 2 9 2 7.34 2 6 3.34 6 5c0 .35.07.69.18 1H4c-1.11 0-1.99.89-1.99 2L2 19c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zm-5-2c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zM9 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm11 15H4v-2h16v2zm0-5H4V8h5.08L7 10.83 8.62 12 11 8.76l1-1.36 1 1.36L15.38 12 17 10.83 14.92 8H20v6z"/></g> +<g id="card-membership"><path d="M20 2H4c-1.11 0-2 .89-2 2v11c0 1.11.89 2 2 2h4v5l4-2 4 2v-5h4c1.11 0 2-.89 2-2V4c0-1.11-.89-2-2-2zm0 13H4v-2h16v2zm0-5H4V4h16v6z"/></g> +<g id="card-travel"><path d="M20 6h-3V4c0-1.11-.89-2-2-2H9c-1.11 0-2 .89-2 2v2H4c-1.11 0-2 .89-2 2v11c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zM9 4h6v2H9V4zm11 15H4v-2h16v2zm0-5H4V8h3v2h2V8h6v2h2V8h3v6z"/></g> +<g id="change-history"><path d="M12 7.77L18.39 18H5.61L12 7.77M12 4L2 20h20L12 4z"/></g> +<g id="check"><path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></g> +<g id="check-box"><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></g> +<g id="check-box-outline-blank"><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="check-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></g> +<g id="chevron-left"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></g> +<g id="chevron-right"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></g> +<g id="chrome-reader-mode"><path d="M13 12h7v1.5h-7zm0-2.5h7V11h-7zm0 5h7V16h-7zM21 4H3c-1.1 0-2 .9-2 2v13c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 15h-9V6h9v13z"/></g> +<g id="class"><path d="M18 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 4h5v8l-2.5-1.5L6 12V4z"/></g> +<g id="clear"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></g> +<g id="close"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></g> +<g id="cloud"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96z"/></g> +<g id="cloud-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4.5 14H8c-1.66 0-3-1.34-3-3s1.34-3 3-3l.14.01C8.58 8.28 10.13 7 12 7c2.21 0 4 1.79 4 4h.5c1.38 0 2.5 1.12 2.5 2.5S17.88 16 16.5 16z"/></g> +<g id="cloud-done"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM10 17l-3.5-3.5 1.41-1.41L10 14.17 15.18 9l1.41 1.41L10 17z"/></g> +<g id="cloud-download"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM17 13l-5 5-5-5h3V9h4v4h3z"/></g> +<g id="cloud-off"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.48 0-2.85.43-4.01 1.17l1.46 1.46C10.21 6.23 11.08 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 1.13-.64 2.11-1.56 2.62l1.45 1.45C23.16 18.16 24 16.68 24 15c0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.75 2.74C2.56 8.15 0 10.77 0 14c0 3.31 2.69 6 6 6h11.73l2 2L21 20.73 4.27 4 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"/></g> +<g id="cloud-queue"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h.71C7.37 7.69 9.48 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3s-1.34 3-3 3z"/></g> +<g id="cloud-upload"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM14 13v4h-4v-4H7l5-5 5 5h-3z"/></g> +<g id="code"><path d="M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z"/></g> +<g id="content-copy"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></g> +<g id="content-cut"><path d="M9.64 7.64c.23-.5.36-1.05.36-1.64 0-2.21-1.79-4-4-4S2 3.79 2 6s1.79 4 4 4c.59 0 1.14-.13 1.64-.36L10 12l-2.36 2.36C7.14 14.13 6.59 14 6 14c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4c0-.59-.13-1.14-.36-1.64L12 14l7 7h3v-1L9.64 7.64zM6 8c-1.1 0-2-.89-2-2s.9-2 2-2 2 .89 2 2-.9 2-2 2zm0 12c-1.1 0-2-.89-2-2s.9-2 2-2 2 .89 2 2-.9 2-2 2zm6-7.5c-.28 0-.5-.22-.5-.5s.22-.5.5-.5.5.22.5.5-.22.5-.5.5zM19 3l-6 6 2 2 7-7V3z"/></g> +<g id="content-paste"><path d="M19 2h-4.18C14.4.84 13.3 0 12 0c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm7 18H5V4h2v3h10V4h2v16z"/></g> +<g id="create"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"/></g> +<g id="credit-card"><path d="M20 4H4c-1.11 0-1.99.89-1.99 2L2 18c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6c0-1.11-.89-2-2-2zm0 14H4v-6h16v6zm0-10H4V6h16v2z"/></g> +<g id="dashboard"><path d="M3 13h8V3H3v10zm0 8h8v-6H3v6zm10 0h8V11h-8v10zm0-18v6h8V3h-8z"/></g> +<g id="delete"><path d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"/></g> +<g id="description"><path d="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z"/></g> +<g id="dns"><path d="M20 13H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zM7 19c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM20 3H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1zM7 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="done"><path d="M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z"/></g> +<g id="done-all"><path d="M18 7l-1.41-1.41-6.34 6.34 1.41 1.41L18 7zm4.24-1.41L11.66 16.17 7.48 12l-1.41 1.41L11.66 19l12-12-1.42-1.41zM.41 13.41L6 19l1.41-1.41L1.83 12 .41 13.41z"/></g> +<g id="drafts"><path d="M21.99 8c0-.72-.37-1.35-.94-1.7L12 1 2.95 6.3C2.38 6.65 2 7.28 2 8v10c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2l-.01-10zM12 13L3.74 7.84 12 3l8.26 4.84L12 13z"/></g> +<g id="eject"><path d="M5 17h14v2H5zm7-12L5.33 15h13.34z"/></g> +<g id="error"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></g> +<g id="error-outline"><path d="M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="event"><path d="M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"/></g> +<g id="event-seat"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M4 18v3h3v-3h10v3h3v-6H4zm15-8h3v3h-3zM2 10h3v3H2zm15 3H7V5c0-1.1.9-2 2-2h6c1.1 0 2 .9 2 2v8z" clip-path="url(#b)"/></g> +<g id="exit-to-app"><path d="M10.09 15.59L11.5 17l5-5-5-5-1.41 1.41L12.67 11H3v2h9.67l-2.58 2.59zM19 3H5c-1.11 0-2 .9-2 2v4h2V5h14v14H5v-4H3v4c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="expand-less"><path d="M12 8l-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"/></g> +<g id="expand-more"><path d="M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"/></g> +<g id="explore"><path d="M12 10.9c-.61 0-1.1.49-1.1 1.1s.49 1.1 1.1 1.1c.61 0 1.1-.49 1.1-1.1s-.49-1.1-1.1-1.1zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm2.19 12.19L6 18l3.81-8.19L18 6l-3.81 8.19z"/></g> +<g id="extension"><path d="M20.5 11H19V7c0-1.1-.9-2-2-2h-4V3.5C13 2.12 11.88 1 10.5 1S8 2.12 8 3.5V5H4c-1.1 0-1.99.9-1.99 2v3.8H3.5c1.49 0 2.7 1.21 2.7 2.7s-1.21 2.7-2.7 2.7H2V20c0 1.1.9 2 2 2h3.8v-1.5c0-1.49 1.21-2.7 2.7-2.7 1.49 0 2.7 1.21 2.7 2.7V22H17c1.1 0 2-.9 2-2v-4h1.5c1.38 0 2.5-1.12 2.5-2.5S21.88 11 20.5 11z"/></g> +<g id="face"><path d="M9 11.75c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zm6 0c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8 0-.29.02-.58.05-.86 2.36-1.05 4.23-2.98 5.21-5.37C11.07 8.33 14.05 10 17.42 10c.78 0 1.53-.09 2.25-.26.21.71.33 1.47.33 2.26 0 4.41-3.59 8-8 8z"/></g> +<g id="favorite"><path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"/></g> +<g id="favorite-border"><path d="M16.5 3c-1.74 0-3.41.81-4.5 2.09C10.91 3.81 9.24 3 7.5 3 4.42 3 2 5.42 2 8.5c0 3.78 3.4 6.86 8.55 11.54L12 21.35l1.45-1.32C18.6 15.36 22 12.28 22 8.5 22 5.42 19.58 3 16.5 3zm-4.4 15.55l-.1.1-.1-.1C7.14 14.24 4 11.39 4 8.5 4 6.5 5.5 5 7.5 5c1.54 0 3.04.99 3.57 2.36h1.87C13.46 5.99 14.96 5 16.5 5c2 0 3.5 1.5 3.5 3.5 0 2.89-3.14 5.74-7.9 10.05z"/></g> +<g id="feedback"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 12h-2v-2h2v2zm0-4h-2V6h2v4z"/></g> +<g id="file-download"><path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/></g> +<g id="file-upload"><path d="M9 16h6v-6h4l-7-7-7 7h4zm-4 2h14v2H5z"/></g> +<g id="filter-list"><path d="M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"/></g> +<g id="find-in-page"><path d="M20 19.59V8l-6-6H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c.45 0 .85-.15 1.19-.4l-4.43-4.43c-.8.52-1.74.83-2.76.83-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5c0 1.02-.31 1.96-.83 2.75L20 19.59zM9 13c0 1.66 1.34 3 3 3s3-1.34 3-3-1.34-3-3-3-3 1.34-3 3z"/></g> +<g id="find-replace"><path d="M11 6c1.38 0 2.63.56 3.54 1.46L12 10h6V4l-2.05 2.05C14.68 4.78 12.93 4 11 4c-3.53 0-6.43 2.61-6.92 6H6.1c.46-2.28 2.48-4 4.9-4zm5.64 9.14c.66-.9 1.12-1.97 1.28-3.14H15.9c-.46 2.28-2.48 4-4.9 4-1.38 0-2.63-.56-3.54-1.46L10 12H4v6l2.05-2.05C7.32 17.22 9.07 18 11 18c1.55 0 2.98-.51 4.14-1.36L20 21.49 21.49 20l-4.85-4.86z"/></g> +<g id="flag"><path d="M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6z"/></g> +<g id="flight-land"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><defs><path id="c" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><clipPath id="d" clip-path="url(#b)"><use xlink:href="#c" overflow="visible"/></clipPath><path d="M2.5 19h19v2h-19zm7.18-5.73l4.35 1.16 5.31 1.42c.8.21 1.62-.26 1.84-1.06.21-.8-.26-1.62-1.06-1.84l-5.31-1.42-2.76-9.02L10.12 2v8.28L5.15 8.95l-.93-2.32-1.45-.39v5.17l1.6.43 5.31 1.43z" clip-path="url(#d)"/></g> +<g id="flight-takeoff"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M2.5 19h19v2h-19zm19.57-9.36c-.21-.8-1.04-1.28-1.84-1.06L14.92 10l-6.9-6.43-1.93.51 4.14 7.17-4.97 1.33-1.97-1.54-1.45.39 1.82 3.16.77 1.33 1.6-.43 5.31-1.42 4.35-1.16L21 11.49c.81-.23 1.28-1.05 1.07-1.85z" clip-path="url(#b)"/></g> +<g id="flip-to-back"><path d="M9 7H7v2h2V7zm0 4H7v2h2v-2zm0-8c-1.11 0-2 .9-2 2h2V3zm4 12h-2v2h2v-2zm6-12v2h2c0-1.1-.9-2-2-2zm-6 0h-2v2h2V3zM9 17v-2H7c0 1.1.89 2 2 2zm10-4h2v-2h-2v2zm0-4h2V7h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zM5 7H3v12c0 1.1.89 2 2 2h12v-2H5V7zm10-2h2V3h-2v2zm0 12h2v-2h-2v2z"/></g> +<g id="flip-to-front"><path d="M3 13h2v-2H3v2zm0 4h2v-2H3v2zm2 4v-2H3c0 1.1.89 2 2 2zM3 9h2V7H3v2zm12 12h2v-2h-2v2zm4-18H9c-1.11 0-2 .9-2 2v10c0 1.1.89 2 2 2h10c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 12H9V5h10v10zm-8 6h2v-2h-2v2zm-4 0h2v-2H7v2z"/></g> +<g id="folder"><path d="M10 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2h-8l-2-2z"/></g> +<g id="folder-open"><path d="M20 6h-8l-2-2H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 12H4V8h16v10z"/></g> +<g id="folder-shared"><path d="M20 6h-8l-2-2H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-5 3c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm4 8h-8v-1c0-1.33 2.67-2 4-2s4 .67 4 2v1z"/></g> +<g id="font-download"><path d="M9.93 13.5h4.14L12 7.98zM20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-4.05 16.5l-1.14-3H9.17l-1.12 3H5.96l5.11-13h1.86l5.11 13h-2.09z"/></g> +<g id="forward"><path d="M12 8V4l8 8-8 8v-4H4V8z"/></g> +<g id="fullscreen"><path d="M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"/></g> +<g id="fullscreen-exit"><path d="M5 16h3v3h2v-5H5v2zm3-8H5v2h5V5H8v3zm6 11h2v-3h3v-2h-5v5zm2-11V5h-2v5h5V8h-3z"/></g> +<g id="gesture"><path d="M4.59 6.89c.7-.71 1.4-1.35 1.71-1.22.5.2 0 1.03-.3 1.52-.25.42-2.86 3.89-2.86 6.31 0 1.28.48 2.34 1.34 2.98.75.56 1.74.73 2.64.46 1.07-.31 1.95-1.4 3.06-2.77 1.21-1.49 2.83-3.44 4.08-3.44 1.63 0 1.65 1.01 1.76 1.79-3.78.64-5.38 3.67-5.38 5.37 0 1.7 1.44 3.09 3.21 3.09 1.63 0 4.29-1.33 4.69-6.1H21v-2.5h-2.47c-.15-1.65-1.09-4.2-4.03-4.2-2.25 0-4.18 1.91-4.94 2.84-.58.73-2.06 2.48-2.29 2.72-.25.3-.68.84-1.11.84-.45 0-.72-.83-.36-1.92.35-1.09 1.4-2.86 1.85-3.52.78-1.14 1.3-1.92 1.3-3.28C8.95 3.69 7.31 3 6.44 3 5.12 3 3.97 4 3.72 4.25c-.36.36-.66.66-.88.93l1.75 1.71zm9.29 11.66c-.31 0-.74-.26-.74-.72 0-.6.73-2.2 2.87-2.76-.3 2.69-1.43 3.48-2.13 3.48z"/></g> +<g id="get-app"><path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/></g> +<g id="gif"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M11.5 9H13v6h-1.5zM9 9H6c-.6 0-1 .5-1 1v4c0 .5.4 1 1 1h3c.6 0 1-.5 1-1v-2H8.5v1.5h-2v-3H10V10c0-.5-.4-1-1-1zm10 1.5V9h-4.5v6H16v-2h2v-1.5h-2v-1z" clip-path="url(#b)"/></g> +<g id="grade"><path d="M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"/></g> +<g id="group-work"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM8 17.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5zM9.5 8c0-1.38 1.12-2.5 2.5-2.5s2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5S9.5 9.38 9.5 8zm6.5 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="help"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 17h-2v-2h2v2zm2.07-7.75l-.9.92C13.45 12.9 13 13.5 13 15h-2v-.5c0-1.1.45-2.1 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41 0-1.1-.9-2-2-2s-2 .9-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 .88-.36 1.68-.93 2.25z"/></g> +<g id="help-outline"><path d="M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4z"/></g> +<g id="highlight-off"><path d="M14.59 8L12 10.59 9.41 8 8 9.41 10.59 12 8 14.59 9.41 16 12 13.41 14.59 16 16 14.59 13.41 12 16 9.41 14.59 8zM12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="history"><path opacity=".9" d="M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9zm-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8H12z"/></g> +<g id="home"><path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/></g> +<g id="hourglass-empty"><path d="M6 2v6h.01L6 8.01 10 12l-4 4 .01.01H6V22h12v-5.99h-.01L18 16l-4-4 4-3.99-.01-.01H18V2H6zm10 14.5V20H8v-3.5l4-4 4 4zm-4-5l-4-4V4h8v3.5l-4 4z"/></g> +<g id="hourglass-full"><path d="M6 2v6h.01L6 8.01 10 12l-4 4 .01.01H6V22h12v-5.99h-.01L18 16l-4-4 4-3.99-.01-.01H18V2H6z"/></g> +<g id="http"><path d="M4.5 11h-2V9H1v6h1.5v-2.5h2V15H6V9H4.5v2zm2.5-.5h1.5V15H10v-4.5h1.5V9H7v1.5zm5.5 0H14V15h1.5v-4.5H17V9h-4.5v1.5zm9-1.5H18v6h1.5v-2h2c.8 0 1.5-.7 1.5-1.5v-1c0-.8-.7-1.5-1.5-1.5zm0 2.5h-2v-1h2v1z"/></g> +<g id="https"><path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"/></g> +<g id="inbox"><path d="M19 3H4.99c-1.1 0-1.98.9-1.98 2L3 19c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 12h-4c0 1.66-1.34 3-3 3s-3-1.34-3-3H4.99V5H19v10zm-3-5h-2V7h-4v3H8l4 4 4-4z"/></g> +<g id="indeterminate-check-box"><defs><path id="a" d="M0 0h24v24H0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path clip-path="url(#b)" d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"/></g> +<g id="info"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/></g> +<g id="info-outline"><path d="M11 17h2v-6h-2v6zm1-15C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zM11 9h2V7h-2v2z"/></g> +<g id="input"><path d="M21 3.01H3c-1.1 0-2 .9-2 2V9h2V4.99h18v14.03H3V15H1v4.01c0 1.1.9 1.98 2 1.98h18c1.1 0 2-.88 2-1.98v-14c0-1.11-.9-2-2-2zM11 16l4-4-4-4v3H1v2h10v3z"/></g> +<g id="invert-colors"><path d="M17.66 7.93L12 2.27 6.34 7.93c-3.12 3.12-3.12 8.19 0 11.31C7.9 20.8 9.95 21.58 12 21.58c2.05 0 4.1-.78 5.66-2.34 3.12-3.12 3.12-8.19 0-11.31zM12 19.59c-1.6 0-3.11-.62-4.24-1.76C6.62 16.69 6 15.19 6 13.59s.62-3.11 1.76-4.24L12 5.1v14.49z"/></g> +<g id="label"><path d="M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16z"/></g> +<g id="label-outline"><path d="M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16zM16 17H5V7h11l3.55 5L16 17z"/></g> +<g id="language"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z"/></g> +<g id="launch"><path d="M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/></g> +<g id="link"><path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/></g> +<g id="list"><path d="M3 13h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2V7H3v2zm4 4h14v-2H7v2zm0 4h14v-2H7v2zM7 7v2h14V7H7z"/></g> +<g id="lock"><path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"/></g> +<g id="lock-open"><path d="M12 17c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm6-9h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6h1.9c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm0 12H6V10h12v10z"/></g> +<g id="lock-outline"><path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6-5.1c1.71 0 3.1 1.39 3.1 3.1v2H9V6h-.1c0-1.71 1.39-3.1 3.1-3.1zM18 20H6V10h12v10zm-6-3c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2z"/></g> +<g id="loyalty"><path d="M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58.55 0 1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41 0-.55-.23-1.06-.59-1.42zM5.5 7C4.67 7 4 6.33 4 5.5S4.67 4 5.5 4 7 4.67 7 5.5 6.33 7 5.5 7zm11.77 8.27L13 19.54l-4.27-4.27C8.28 14.81 8 14.19 8 13.5c0-1.38 1.12-2.5 2.5-2.5.69 0 1.32.28 1.77.74l.73.72.73-.73c.45-.45 1.08-.73 1.77-.73 1.38 0 2.5 1.12 2.5 2.5 0 .69-.28 1.32-.73 1.77z"/></g> +<g id="mail"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="markunread"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="markunread-mailbox"><path d="M20 6H10v6H8V4h6V0H6v6H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2z"/></g> +<g id="menu"><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/></g> +<g id="more-horiz"><path d="M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="more-vert"><path d="M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="note-add"><path d="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 14h-3v3h-2v-3H8v-2h3v-3h2v3h3v2zm-3-7V3.5L18.5 9H13z"/></g> +<g id="offline-pin"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path clip-path="url(#b)" d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zm5 16H7v-2h10v2zm-6.7-4L7 10.7l1.4-1.4 1.9 1.9 5.3-5.3L17 7.3 10.3 14z"/></g> +<g id="open-in-browser"><path d="M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h4v-2H5V8h14v10h-4v2h4c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm-7 6l-4 4h3v6h2v-6h3l-4-4z"/></g> +<g id="open-in-new"><path d="M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/></g> +<g id="open-with"><path d="M10 9h4V6h3l-5-5-5 5h3v3zm-1 1H6V7l-5 5 5 5v-3h3v-4zm14 2l-5-5v3h-3v4h3v3l5-5zm-9 3h-4v3H7l5 5 5-5h-3v-3z"/></g> +<g id="pageview"><path d="M11.5 9C10.12 9 9 10.12 9 11.5s1.12 2.5 2.5 2.5 2.5-1.12 2.5-2.5S12.88 9 11.5 9zM20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-3.21 14.21l-2.91-2.91c-.69.44-1.51.7-2.39.7C9.01 16 7 13.99 7 11.5S9.01 7 11.5 7 16 9.01 16 11.5c0 .88-.26 1.69-.7 2.39l2.91 2.9-1.42 1.42z"/></g> +<g id="payment"><path d="M20 4H4c-1.11 0-1.99.89-1.99 2L2 18c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6c0-1.11-.89-2-2-2zm0 14H4v-6h16v6zm0-10H4V6h16v2z"/></g> +<g id="perm-camera-mic"><path d="M20 5h-3.17L15 3H9L7.17 5H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7v-2.09c-2.83-.48-5-2.94-5-5.91h2c0 2.21 1.79 4 4 4s4-1.79 4-4h2c0 2.97-2.17 5.43-5 5.91V21h7c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-6 8c0 1.1-.9 2-2 2s-2-.9-2-2V9c0-1.1.9-2 2-2s2 .9 2 2v4z"/></g> +<g id="perm-contact-calendar"><path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H6v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1z"/></g> +<g id="perm-data-setting"><path d="M18.99 11.5c.34 0 .67.03 1 .07L20 0 0 20h11.56c-.04-.33-.07-.66-.07-1 0-4.14 3.36-7.5 7.5-7.5zm3.71 7.99c.02-.16.04-.32.04-.49 0-.17-.01-.33-.04-.49l1.06-.83c.09-.08.12-.21.06-.32l-1-1.73c-.06-.11-.19-.15-.31-.11l-1.24.5c-.26-.2-.54-.37-.85-.49l-.19-1.32c-.01-.12-.12-.21-.24-.21h-2c-.12 0-.23.09-.25.21l-.19 1.32c-.3.13-.59.29-.85.49l-1.24-.5c-.11-.04-.24 0-.31.11l-1 1.73c-.06.11-.04.24.06.32l1.06.83c-.02.16-.03.32-.03.49 0 .17.01.33.03.49l-1.06.83c-.09.08-.12.21-.06.32l1 1.73c.06.11.19.15.31.11l1.24-.5c.26.2.54.37.85.49l.19 1.32c.02.12.12.21.25.21h2c.12 0 .23-.09.25-.21l.19-1.32c.3-.13.59-.29.84-.49l1.25.5c.11.04.24 0 .31-.11l1-1.73c.06-.11.03-.24-.06-.32l-1.07-.83zm-3.71 1.01c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="perm-device-information"><path d="M13 7h-2v2h2V7zm0 4h-2v6h2v-6zm4-9.99L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="perm-identity"><path d="M12 5.9c1.16 0 2.1.94 2.1 2.1s-.94 2.1-2.1 2.1S9.9 9.16 9.9 8s.94-2.1 2.1-2.1m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z"/></g> +<g id="perm-media"><path d="M2 6H0v5h.01L0 20c0 1.1.9 2 2 2h18v-2H2V6zm20-2h-8l-2-2H6c-1.1 0-1.99.9-1.99 2L4 16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM7 15l4.5-6 3.5 4.51 2.5-3.01L21 15H7z"/></g> +<g id="perm-phone-msg"><path d="M20 15.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.58l2.2-2.21c.28-.27.36-.66.25-1.01C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM12 3v10l3-3h6V3h-9z"/></g> +<g id="perm-scan-wifi"><path d="M12 3C6.95 3 3.15 4.85 0 7.23L12 22 24 7.25C20.85 4.87 17.05 3 12 3zm1 13h-2v-6h2v6zm-2-8V6h2v2h-2z"/></g> +<g id="picture-in-picture"><path d="M19 7h-8v6h8V7zm2-4H3c-1.1 0-2 .9-2 2v14c0 1.1.9 1.98 2 1.98h18c1.1 0 2-.88 2-1.98V5c0-1.1-.9-2-2-2zm0 16.01H3V4.98h18v14.03z"/></g> +<g id="play-for-work"><path fill="#010101" d="M11 5v5.59H7.5l4.5 4.5 4.5-4.5H13V5h-2zm-5 9c0 3.31 2.69 6 6 6s6-2.69 6-6h-2c0 2.21-1.79 4-4 4s-4-1.79-4-4H6z"/></g> +<g id="polymer"><path d="M19 4h-4L7.11 16.63 4.5 12 9 4H5L.5 12 5 20h4l7.89-12.63L19.5 12 15 20h4l4.5-8z"/></g> +<g id="power-settings-new"><path d="M13 3h-2v10h2V3zm4.83 2.17l-1.42 1.42C17.99 7.86 19 9.81 19 12c0 3.87-3.13 7-7 7s-7-3.13-7-7c0-2.19 1.01-4.14 2.58-5.42L6.17 5.17C4.23 6.82 3 9.26 3 12c0 4.97 4.03 9 9 9s9-4.03 9-9c0-2.74-1.23-5.18-3.17-6.83z"/></g> +<g id="print"><path d="M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"/></g> +<g id="query-builder"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zM12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></g> +<g id="question-answer"><path d="M21 6h-2v9H6v2c0 .55.45 1 1 1h11l4 4V7c0-.55-.45-1-1-1zm-4 6V3c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v14l4-4h10c.55 0 1-.45 1-1z"/></g> +<g id="radio-button-checked"><path d="M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="radio-button-unchecked"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="receipt"><path d="M18 17H6v-2h12v2zm0-4H6v-2h12v2zm0-4H6V7h12v2zM3 22l1.5-1.5L6 22l1.5-1.5L9 22l1.5-1.5L12 22l1.5-1.5L15 22l1.5-1.5L18 22l1.5-1.5L21 22V2l-1.5 1.5L18 2l-1.5 1.5L15 2l-1.5 1.5L12 2l-1.5 1.5L9 2 7.5 3.5 6 2 4.5 3.5 3 2v20z"/></g> +<g id="redeem"><path d="M20 6h-2.18c.11-.31.18-.65.18-1 0-1.66-1.34-3-3-3-1.05 0-1.96.54-2.5 1.35l-.5.67-.5-.68C10.96 2.54 10.05 2 9 2 7.34 2 6 3.34 6 5c0 .35.07.69.18 1H4c-1.11 0-1.99.89-1.99 2L2 19c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zm-5-2c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zM9 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm11 15H4v-2h16v2zm0-5H4V8h5.08L7 10.83 8.62 12 11 8.76l1-1.36 1 1.36L15.38 12 17 10.83 14.92 8H20v6z"/></g> +<g id="redo"><path d="M18.4 10.6C16.55 8.99 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16c1.05-3.19 4.05-5.5 7.6-5.5 1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"/></g> +<g id="refresh"><path d="M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z"/></g> +<g id="remove"><path d="M19 13H5v-2h14v2z"/></g> +<g id="remove-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm5 11H7v-2h10v2z"/></g> +<g id="remove-circle-outline"><path d="M7 11v2h10v-2H7zm5-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="reorder"><path d="M3 15h18v-2H3v2zm0 4h18v-2H3v2zm0-8h18V9H3v2zm0-6v2h18V5H3z"/></g> +<g id="reply"><path d="M10 9V5l-7 7 7 7v-4.1c5 0 8.5 1.6 11 5.1-1-5-4-10-11-11z"/></g> +<g id="reply-all"><path d="M7 8V5l-7 7 7 7v-3l-4-4 4-4zm6 1V5l-7 7 7 7v-4.1c5 0 8.5 1.6 11 5.1-1-5-4-10-11-11z"/></g> +<g id="report"><path d="M15.73 3H8.27L3 8.27v7.46L8.27 21h7.46L21 15.73V8.27L15.73 3zM12 17.3c-.72 0-1.3-.58-1.3-1.3 0-.72.58-1.3 1.3-1.3.72 0 1.3.58 1.3 1.3 0 .72-.58 1.3-1.3 1.3zm1-4.3h-2V7h2v6z"/></g> +<g id="report-problem"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></g> +<g id="restore"><path d="M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9zm-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8H12z"/></g> +<g id="room"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="save"><path d="M17 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V7l-4-4zm-5 16c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm3-10H5V5h10v4z"/></g> +<g id="schedule"><path fill-opacity=".9" d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zM12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></g> +<g id="search"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"/></g> +<g id="select-all"><path d="M3 5h2V3c-1.1 0-2 .9-2 2zm0 8h2v-2H3v2zm4 8h2v-2H7v2zM3 9h2V7H3v2zm10-6h-2v2h2V3zm6 0v2h2c0-1.1-.9-2-2-2zM5 21v-2H3c0 1.1.9 2 2 2zm-2-4h2v-2H3v2zM9 3H7v2h2V3zm2 18h2v-2h-2v2zm8-8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zm0-12h2V7h-2v2zm0 8h2v-2h-2v2zm-4 4h2v-2h-2v2zm0-16h2V3h-2v2zM7 17h10V7H7v10zm2-8h6v6H9V9z"/></g> +<g id="send"><path d="M2.01 21L23 12 2.01 3 2 10l15 2-15 2z"/></g> +<g id="settings"><path d="M19.43 12.98c.04-.32.07-.64.07-.98s-.03-.66-.07-.98l2.11-1.65c.19-.15.24-.42.12-.64l-2-3.46c-.12-.22-.39-.3-.61-.22l-2.49 1c-.52-.4-1.08-.73-1.69-.98l-.38-2.65C14.46 2.18 14.25 2 14 2h-4c-.25 0-.46.18-.49.42l-.38 2.65c-.61.25-1.17.59-1.69.98l-2.49-1c-.23-.09-.49 0-.61.22l-2 3.46c-.13.22-.07.49.12.64l2.11 1.65c-.04.32-.07.65-.07.98s.03.66.07.98l-2.11 1.65c-.19.15-.24.42-.12.64l2 3.46c.12.22.39.3.61.22l2.49-1c.52.4 1.08.73 1.69.98l.38 2.65c.03.24.24.42.49.42h4c.25 0 .46-.18.49-.42l.38-2.65c.61-.25 1.17-.59 1.69-.98l2.49 1c.23.09.49 0 .61-.22l2-3.46c.12-.22.07-.49-.12-.64l-2.11-1.65zM12 15.5c-1.93 0-3.5-1.57-3.5-3.5s1.57-3.5 3.5-3.5 3.5 1.57 3.5 3.5-1.57 3.5-3.5 3.5z"/></g> +<g id="settings-applications"><path d="M12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm7-7H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-1.75 9c0 .23-.02.46-.05.68l1.48 1.16c.13.11.17.3.08.45l-1.4 2.42c-.09.15-.27.21-.43.15l-1.74-.7c-.36.28-.76.51-1.18.69l-.26 1.85c-.03.17-.18.3-.35.3h-2.8c-.17 0-.32-.13-.35-.29l-.26-1.85c-.43-.18-.82-.41-1.18-.69l-1.74.7c-.16.06-.34 0-.43-.15l-1.4-2.42c-.09-.15-.05-.34.08-.45l1.48-1.16c-.03-.23-.05-.46-.05-.69 0-.23.02-.46.05-.68l-1.48-1.16c-.13-.11-.17-.3-.08-.45l1.4-2.42c.09-.15.27-.21.43-.15l1.74.7c.36-.28.76-.51 1.18-.69l.26-1.85c.03-.17.18-.3.35-.3h2.8c.17 0 .32.13.35.29l.26 1.85c.43.18.82.41 1.18.69l1.74-.7c.16-.06.34 0 .43.15l1.4 2.42c.09.15.05.34-.08.45l-1.48 1.16c.03.23.05.46.05.69z"/></g> +<g id="settings-backup-restore"><path d="M14 12c0-1.1-.9-2-2-2s-2 .9-2 2 .9 2 2 2 2-.9 2-2zm-2-9c-4.97 0-9 4.03-9 9H0l4 4 4-4H5c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.51 0-2.91-.49-4.06-1.3l-1.42 1.44C8.04 20.3 9.94 21 12 21c4.97 0 9-4.03 9-9s-4.03-9-9-9z"/></g> +<g id="settings-bluetooth"><path d="M11 24h2v-2h-2v2zm-4 0h2v-2H7v2zm8 0h2v-2h-2v2zm2.71-18.29L12 0h-1v7.59L6.41 3 5 4.41 10.59 10 5 15.59 6.41 17 11 12.41V20h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 3.83l1.88 1.88L13 7.59V3.83zm1.88 10.46L13 16.17v-3.76l1.88 1.88z"/></g> +<g id="settings-brightness"><path d="M21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02zM8 16h2.5l1.5 1.5 1.5-1.5H16v-2.5l1.5-1.5-1.5-1.5V8h-2.5L12 6.5 10.5 8H8v2.5L6.5 12 8 13.5V16zm4-7c1.66 0 3 1.34 3 3s-1.34 3-3 3V9z"/></g> +<g id="settings-cell"><path d="M7 24h2v-2H7v2zm4 0h2v-2h-2v2zm4 0h2v-2h-2v2zM16 .01L8 0C6.9 0 6 .9 6 2v16c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V2c0-1.1-.9-1.99-2-1.99zM16 16H8V4h8v12z"/></g> +<g id="settings-ethernet"><path d="M7.77 6.76L6.23 5.48.82 12l5.41 6.52 1.54-1.28L3.42 12l4.35-5.24zM7 13h2v-2H7v2zm10-2h-2v2h2v-2zm-6 2h2v-2h-2v2zm6.77-7.52l-1.54 1.28L20.58 12l-4.35 5.24 1.54 1.28L23.18 12l-5.41-6.52z"/></g> +<g id="settings-input-antenna"><path d="M12 5c-3.87 0-7 3.13-7 7h2c0-2.76 2.24-5 5-5s5 2.24 5 5h2c0-3.87-3.13-7-7-7zm1 9.29c.88-.39 1.5-1.26 1.5-2.29 0-1.38-1.12-2.5-2.5-2.5S9.5 10.62 9.5 12c0 1.02.62 1.9 1.5 2.29v3.3L7.59 21 9 22.41l3-3 3 3L16.41 21 13 17.59v-3.3zM12 1C5.93 1 1 5.93 1 12h2c0-4.97 4.03-9 9-9s9 4.03 9 9h2c0-6.07-4.93-11-11-11z"/></g> +<g id="settings-input-component"><path d="M5 2c0-.55-.45-1-1-1s-1 .45-1 1v4H1v6h6V6H5V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2H9v2zm-8 0c0 1.3.84 2.4 2 2.82V23h2v-4.18C6.16 18.4 7 17.3 7 16v-2H1v2zM21 6V2c0-.55-.45-1-1-1s-1 .45-1 1v4h-2v6h6V6h-2zm-8-4c0-.55-.45-1-1-1s-1 .45-1 1v4H9v6h6V6h-2V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2h-6v2z"/></g> +<g id="settings-input-composite"><path d="M5 2c0-.55-.45-1-1-1s-1 .45-1 1v4H1v6h6V6H5V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2H9v2zm-8 0c0 1.3.84 2.4 2 2.82V23h2v-4.18C6.16 18.4 7 17.3 7 16v-2H1v2zM21 6V2c0-.55-.45-1-1-1s-1 .45-1 1v4h-2v6h6V6h-2zm-8-4c0-.55-.45-1-1-1s-1 .45-1 1v4H9v6h6V6h-2V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2h-6v2z"/></g> +<g id="settings-input-hdmi"><path d="M18 7V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v3H5v6l3 6v3h8v-3l3-6V7h-1zM8 4h8v3h-2V5h-1v2h-2V5h-1v2H8V4z"/></g> +<g id="settings-input-svideo"><path d="M8 11.5c0-.83-.67-1.5-1.5-1.5S5 10.67 5 11.5 5.67 13 6.5 13 8 12.33 8 11.5zm7-5c0-.83-.67-1.5-1.5-1.5h-3C9.67 5 9 5.67 9 6.5S9.67 8 10.5 8h3c.83 0 1.5-.67 1.5-1.5zM8.5 15c-.83 0-1.5.67-1.5 1.5S7.67 18 8.5 18s1.5-.67 1.5-1.5S9.33 15 8.5 15zM12 1C5.93 1 1 5.93 1 12s4.93 11 11 11 11-4.93 11-11S18.07 1 12 1zm0 20c-4.96 0-9-4.04-9-9s4.04-9 9-9 9 4.04 9 9-4.04 9-9 9zm5.5-11c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm-2 5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5z"/></g> +<g id="settings-overscan"><path d="M12.01 5.5L10 8h4l-1.99-2.5zM18 10v4l2.5-1.99L18 10zM6 10l-2.5 2.01L6 14v-4zm8 6h-4l2.01 2.5L14 16zm7-13H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/></g> +<g id="settings-phone"><path d="M13 9h-2v2h2V9zm4 0h-2v2h2V9zm3 6.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.58l2.2-2.21c.28-.27.36-.66.25-1.01C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM19 9v2h2V9h-2z"/></g> +<g id="settings-power"><path d="M7 24h2v-2H7v2zm4 0h2v-2h-2v2zm2-22h-2v10h2V2zm3.56 2.44l-1.45 1.45C16.84 6.94 18 8.83 18 11c0 3.31-2.69 6-6 6s-6-2.69-6-6c0-2.17 1.16-4.06 2.88-5.12L7.44 4.44C5.36 5.88 4 8.28 4 11c0 4.42 3.58 8 8 8s8-3.58 8-8c0-2.72-1.36-5.12-3.44-6.56zM15 24h2v-2h-2v2z"/></g> +<g id="settings-remote"><path d="M15 9H9c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V10c0-.55-.45-1-1-1zm-3 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM7.05 6.05l1.41 1.41C9.37 6.56 10.62 6 12 6s2.63.56 3.54 1.46l1.41-1.41C15.68 4.78 13.93 4 12 4s-3.68.78-4.95 2.05zM12 0C8.96 0 6.21 1.23 4.22 3.22l1.41 1.41C7.26 3.01 9.51 2 12 2s4.74 1.01 6.36 2.64l1.41-1.41C17.79 1.23 15.04 0 12 0z"/></g> +<g id="settings-voice"><path d="M7 24h2v-2H7v2zm5-11c1.66 0 2.99-1.34 2.99-3L15 4c0-1.66-1.34-3-3-3S9 2.34 9 4v6c0 1.66 1.34 3 3 3zm-1 11h2v-2h-2v2zm4 0h2v-2h-2v2zm4-14h-1.7c0 3-2.54 5.1-5.3 5.1S6.7 13 6.7 10H5c0 3.41 2.72 6.23 6 6.72V20h2v-3.28c3.28-.49 6-3.31 6-6.72z"/></g> +<g id="shop"><path d="M16 6V4c0-1.11-.89-2-2-2h-4c-1.11 0-2 .89-2 2v2H2v13c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6h-6zm-6-2h4v2h-4V4zM9 18V9l7.5 4L9 18z"/></g> +<g id="shop-two"><path d="M3 9H1v11c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2H3V9zm15-4V3c0-1.11-.89-2-2-2h-4c-1.11 0-2 .89-2 2v2H5v11c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2V5h-5zm-6-2h4v2h-4V3zm0 12V8l5.5 3-5.5 4z"/></g> +<g id="shopping-basket"><path d="M17.21 9l-4.38-6.56c-.19-.28-.51-.42-.83-.42-.32 0-.64.14-.83.43L6.79 9H2c-.55 0-1 .45-1 1 0 .09.01.18.04.27l2.54 9.27c.23.84 1 1.46 1.92 1.46h13c.92 0 1.69-.62 1.93-1.46l2.54-9.27L23 10c0-.55-.45-1-1-1h-4.79zM9 9l3-4.4L15 9H9zm3 8c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="shopping-cart"><path d="M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="sort"><path d="M3 18h6v-2H3v2zM3 6v2h18V6H3zm0 7h12v-2H3v2z"/></g> +<g id="speaker-notes"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM8 14H6v-2h2v2zm0-3H6V9h2v2zm0-3H6V6h2v2zm7 6h-5v-2h5v2zm3-3h-8V9h8v2zm0-3h-8V6h8v2z"/></g> +<g id="spellcheck"><path d="M12.45 16h2.09L9.43 3H7.57L2.46 16h2.09l1.12-3h5.64l1.14 3zm-6.02-5L8.5 5.48 10.57 11H6.43zm15.16.59l-8.09 8.09L9.83 16l-1.41 1.41 5.09 5.09L23 13l-1.41-1.41z"/></g> +<g id="star"><path d="M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"/></g> +<g id="star-border"><path d="M22 9.24l-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4l-3.76 2.27 1-4.28-3.32-2.88 4.38-.38L12 6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"/></g> +<g id="star-half"><path d="M22 9.74l-7.19-.62L12 2.5 9.19 9.13 2 9.74l5.46 4.73-1.64 7.03L12 17.77l6.18 3.73-1.63-7.03L22 9.74zM12 15.9V6.6l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.9z"/></g> +<g id="stars"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm4.24 16L12 15.45 7.77 18l1.12-4.81-3.73-3.23 4.92-.42L12 5l1.92 4.53 4.92.42-3.73 3.23L16.23 18z"/></g> +<g id="store"><path d="M20 4H4v2h16V4zm1 10v-2l-1-5H4l-1 5v2h1v6h10v-6h4v6h2v-6h1zm-9 4H6v-4h6v4z"/></g> +<g id="subject"><path d="M14 17H4v2h10v-2zm6-8H4v2h16V9zM4 15h16v-2H4v2zM4 5v2h16V5H4z"/></g> +<g id="supervisor-account"><path d="M16.5 12c1.38 0 2.49-1.12 2.49-2.5S17.88 7 16.5 7C15.12 7 14 8.12 14 9.5s1.12 2.5 2.5 2.5zM9 11c1.66 0 2.99-1.34 2.99-3S10.66 5 9 5C7.34 5 6 6.34 6 8s1.34 3 3 3zm7.5 3c-1.83 0-5.5.92-5.5 2.75V19h11v-2.25c0-1.83-3.67-2.75-5.5-2.75zM9 13c-2.33 0-7 1.17-7 3.5V19h7v-2.25c0-.85.33-2.34 2.37-3.47C10.5 13.1 9.66 13 9 13z"/></g> +<g id="swap-horiz"><path d="M6.99 11L3 15l3.99 4v-3H14v-2H6.99v-3zM21 9l-3.99-4v3H10v2h7.01v3L21 9z"/></g> +<g id="swap-vert"><path d="M16 17.01V10h-2v7.01h-3L15 21l4-3.99h-3zM9 3L5 6.99h3V14h2V6.99h3L9 3z"/></g> +<g id="swap-vertical-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM6.5 9L10 5.5 13.5 9H11v4H9V9H6.5zm11 6L14 18.5 10.5 15H13v-4h2v4h2.5z"/></g> +<g id="system-update-alt"><path d="M12 16.5l4-4h-3v-9h-2v9H8l4 4zm9-13h-6v1.99h6v14.03H3V5.49h6V3.5H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2v-14c0-1.1-.9-2-2-2z"/></g> +<g id="tab"><path d="M21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H3V5h10v4h8v10z"/></g> +<g id="tab-unselected"><path d="M1 9h2V7H1v2zm0 4h2v-2H1v2zm0-8h2V3c-1.1 0-2 .9-2 2zm8 16h2v-2H9v2zm-8-4h2v-2H1v2zm2 4v-2H1c0 1.1.9 2 2 2zM21 3h-8v6h10V5c0-1.1-.9-2-2-2zm0 14h2v-2h-2v2zM9 5h2V3H9v2zM5 21h2v-2H5v2zM5 5h2V3H5v2zm16 16c1.1 0 2-.9 2-2h-2v2zm0-8h2v-2h-2v2zm-8 8h2v-2h-2v2zm4 0h2v-2h-2v2z"/></g> +<g id="text-format"><path d="M5 17v2h14v-2H5zm4.5-4.2h5l.9 2.2h2.1L12.75 4h-1.5L6.5 15h2.1l.9-2.2zM12 5.98L13.87 11h-3.74L12 5.98z"/></g> +<g id="theaters"><path d="M18 3v2h-2V3H8v2H6V3H4v18h2v-2h2v2h8v-2h2v2h2V3h-2zM8 17H6v-2h2v2zm0-4H6v-2h2v2zm0-4H6V7h2v2zm10 8h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V7h2v2z"/></g> +<g id="thumb-down"><path d="M15 3H6c-.83 0-1.54.5-1.84 1.22l-3.02 7.05c-.09.23-.14.47-.14.73v1.91l.01.01L1 14c0 1.1.9 2 2 2h6.31l-.95 4.57-.03.32c0 .41.17.79.44 1.06L9.83 23l6.59-6.59c.36-.36.58-.86.58-1.41V5c0-1.1-.9-2-2-2zm4 0v12h4V3h-4z"/></g> +<g id="thumb-up"><path d="M1 21h4V9H1v12zm22-11c0-1.1-.9-2-2-2h-6.31l.95-4.57.03-.32c0-.41-.17-.79-.44-1.06L14.17 1 7.59 7.59C7.22 7.95 7 8.45 7 9v10c0 1.1.9 2 2 2h9c.83 0 1.54-.5 1.84-1.22l3.02-7.05c.09-.23.14-.47.14-.73v-1.91l-.01-.01L23 10z"/></g> +<g id="thumbs-up-down"><path d="M12 6c0-.55-.45-1-1-1H5.82l.66-3.18.02-.23c0-.31-.13-.59-.33-.8L5.38 0 .44 4.94C.17 5.21 0 5.59 0 6v6.5c0 .83.67 1.5 1.5 1.5h6.75c.62 0 1.15-.38 1.38-.91l2.26-5.29c.07-.17.11-.36.11-.55V6zm10.5 4h-6.75c-.62 0-1.15.38-1.38.91l-2.26 5.29c-.07.17-.11.36-.11.55V18c0 .55.45 1 1 1h5.18l-.66 3.18-.02.24c0 .31.13.59.33.8l.79.78 4.94-4.94c.27-.27.44-.65.44-1.06v-6.5c0-.83-.67-1.5-1.5-1.5z"/></g> +<g id="toc"><path d="M3 9h14V7H3v2zm0 4h14v-2H3v2zm0 4h14v-2H3v2zm16 0h2v-2h-2v2zm0-10v2h2V7h-2zm0 6h2v-2h-2v2z"/></g> +<g id="today"><path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z"/></g> +<g id="toll"><path d="M15 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6zM3 12c0-2.61 1.67-4.83 4-5.65V4.26C3.55 5.15 1 8.27 1 12s2.55 6.85 6 7.74v-2.09c-2.33-.82-4-3.04-4-5.65z"/></g> +<g id="track-changes"><path fill="#231F20" d="M19.07 4.93l-1.41 1.41C19.1 7.79 20 9.79 20 12c0 4.42-3.58 8-8 8s-8-3.58-8-8c0-4.08 3.05-7.44 7-7.93v2.02C8.16 6.57 6 9.03 6 12c0 3.31 2.69 6 6 6s6-2.69 6-6c0-1.66-.67-3.16-1.76-4.24l-1.41 1.41C15.55 9.9 16 10.9 16 12c0 2.21-1.79 4-4 4s-4-1.79-4-4c0-1.86 1.28-3.41 3-3.86v2.14c-.6.35-1 .98-1 1.72 0 1.1.9 2 2 2s2-.9 2-2c0-.74-.4-1.38-1-1.72V2h-1C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10c0-2.76-1.12-5.26-2.93-7.07z"/></g> +<g id="translate"><path d="M12.87 15.07l-2.54-2.51.03-.03c1.74-1.94 2.98-4.17 3.71-6.53H17V4h-7V2H8v2H1v1.99h11.17C11.5 7.92 10.44 9.75 9 11.35 8.07 10.32 7.3 9.19 6.69 8h-2c.73 1.63 1.73 3.17 2.98 4.56l-5.09 5.02L4 19l5-5 3.11 3.11.76-2.04zM18.5 10h-2L12 22h2l1.12-3h4.75L21 22h2l-4.5-12zm-2.62 7l1.62-4.33L19.12 17h-3.24z"/></g> +<g id="trending-down"><path d="M16 18l2.29-2.29-4.88-4.88-4 4L2 7.41 3.41 6l6 6 4-4 6.3 6.29L22 12v6z"/></g> +<g id="trending-flat"><path d="M22 12l-4-4v3H3v2h15v3z"/></g> +<g id="trending-up"><path d="M16 6l2.29 2.29-4.88 4.88-4-4L2 16.59 3.41 18l6-6 4 4 6.3-6.29L22 12V6z"/></g> +<g id="turned-in"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2z"/></g> +<g id="turned-in-not"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2zm0 15l-5-2.18L7 18V5h10v13z"/></g> +<g id="undo"><path d="M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"/></g> +<g id="unfold-less"><path d="M7.41 18.59L8.83 20 12 16.83 15.17 20l1.41-1.41L12 14l-4.59 4.59zm9.18-13.18L15.17 4 12 7.17 8.83 4 7.41 5.41 12 10l4.59-4.59z"/></g> +<g id="unfold-more"><path d="M12 5.83L15.17 9l1.41-1.41L12 3 7.41 7.59 8.83 9 12 5.83zm0 12.34L8.83 15l-1.41 1.41L12 21l4.59-4.59L15.17 15 12 18.17z"/></g> +<g id="verified-user"><path d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm-2 16l-4-4 1.41-1.41L10 14.17l6.59-6.59L18 9l-8 8z"/></g> +<g id="view-agenda"><path d="M20 13H3c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h17c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zm0-10H3c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h17c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1z"/></g> +<g id="view-array"><path d="M4 18h3V5H4v13zM18 5v13h3V5h-3zM8 18h9V5H8v13z"/></g> +<g id="view-carousel"><path d="M7 19h10V4H7v15zm-5-2h4V6H2v11zM18 6v11h4V6h-4z"/></g> +<g id="view-column"><path d="M10 18h5V5h-5v13zm-6 0h5V5H4v13zM16 5v13h5V5h-5z"/></g> +<g id="view-day"><path d="M2 21h19v-3H2v3zM20 8H3c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h17c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zM2 3v3h19V3H2z"/></g> +<g id="view-headline"><path d="M4 15h16v-2H4v2zm0 4h16v-2H4v2zm0-8h16V9H4v2zm0-6v2h16V5H4z"/></g> +<g id="view-list"><path d="M4 14h4v-4H4v4zm0 5h4v-4H4v4zM4 9h4V5H4v4zm5 5h12v-4H9v4zm0 5h12v-4H9v4zM9 5v4h12V5H9z"/></g> +<g id="view-module"><path d="M4 11h5V5H4v6zm0 7h5v-6H4v6zm6 0h5v-6h-5v6zm6 0h5v-6h-5v6zm-6-7h5V5h-5v6zm6-6v6h5V5h-5z"/></g> +<g id="view-quilt"><path d="M10 18h5v-6h-5v6zm-6 0h5V5H4v13zm12 0h5v-6h-5v6zM10 5v6h11V5H10z"/></g> +<g id="view-stream"><path d="M4 18h17v-6H4v6zM4 5v6h17V5H4z"/></g> +<g id="view-week"><path d="M6 5H3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h3c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zm14 0h-3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h3c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zm-7 0h-3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h3c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1z"/></g> +<g id="visibility"><path d="M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="visibility-off"><path d="M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"/></g> +<g id="warning"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></g> +<g id="work"><path d="M20 6h-4V4c0-1.11-.89-2-2-2h-4c-1.11 0-2 .89-2 2v2H4c-1.11 0-1.99.89-1.99 2L2 19c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zm-6 0h-4V4h4v2z"/></g> +<g id="youtube-searched-for"><path d="M17.01 14h-.8l-.27-.27c.98-1.14 1.57-2.61 1.57-4.23 0-3.59-2.91-6.5-6.5-6.5s-6.5 3-6.5 6.5H2l3.84 4 4.16-4H6.51C6.51 7 8.53 5 11.01 5s4.5 2.01 4.5 4.5c0 2.48-2.02 4.5-4.5 4.5-.65 0-1.26-.14-1.82-.38L7.71 15.1c.97.57 2.09.9 3.3.9 1.61 0 3.08-.59 4.22-1.57l.27.27v.79l5.01 4.99L22 19l-4.99-5z"/></g> +<g id="zoom-in"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14zM12 10h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></g> +<g id="zoom-out"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14zM7 9h5v1H7z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/maps-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/maps-icons.html new file mode 100644 index 0000000..008a0ef --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/maps-icons.html @@ -0,0 +1,71 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="maps" size="24"> +<svg><defs> +<g id="beenhere"><path d="M19 1H5c-1.1 0-1.99.9-1.99 2L3 15.93c0 .69.35 1.3.88 1.66L12 23l8.11-5.41c.53-.36.88-.97.88-1.66L21 3c0-1.1-.9-2-2-2zm-9 15l-5-5 1.41-1.41L10 13.17l7.59-7.59L19 7l-9 9z"/></g> +<g id="directions"><path d="M21.71 11.29l-9-9c-.39-.39-1.02-.39-1.41 0l-9 9c-.39.39-.39 1.02 0 1.41l9 9c.39.39 1.02.39 1.41 0l9-9c.39-.38.39-1.01 0-1.41zM14 14.5V12h-4v3H8v-4c0-.55.45-1 1-1h5V7.5l3.5 3.5-3.5 3.5z"/></g> +<g id="directions-bike"><path d="M15.5 5.5c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zM5 12c-2.8 0-5 2.2-5 5s2.2 5 5 5 5-2.2 5-5-2.2-5-5-5zm0 8.5c-1.9 0-3.5-1.6-3.5-3.5s1.6-3.5 3.5-3.5 3.5 1.6 3.5 3.5-1.6 3.5-3.5 3.5zm5.8-10l2.4-2.4.8.8c1.3 1.3 3 2.1 5.1 2.1V9c-1.5 0-2.7-.6-3.6-1.5l-1.9-1.9c-.5-.4-1-.6-1.6-.6s-1.1.2-1.4.6L7.8 8.4c-.4.4-.6.9-.6 1.4 0 .6.2 1.1.6 1.4L11 14v5h2v-6.2l-2.2-2.3zM19 12c-2.8 0-5 2.2-5 5s2.2 5 5 5 5-2.2 5-5-2.2-5-5-5zm0 8.5c-1.9 0-3.5-1.6-3.5-3.5s1.6-3.5 3.5-3.5 3.5 1.6 3.5 3.5-1.6 3.5-3.5 3.5z"/></g> +<g id="directions-boat"><path d="M20 21c-1.39 0-2.78-.47-4-1.32-2.44 1.71-5.56 1.71-8 0C6.78 20.53 5.39 21 4 21H2v2h2c1.38 0 2.74-.35 4-.99 2.52 1.29 5.48 1.29 8 0 1.26.65 2.62.99 4 .99h2v-2h-2zM3.95 19H4c1.6 0 3.02-.88 4-2 .98 1.12 2.4 2 4 2s3.02-.88 4-2c.98 1.12 2.4 2 4 2h.05l1.89-6.68c.08-.26.06-.54-.06-.78s-.34-.42-.6-.5L20 10.62V6c0-1.1-.9-2-2-2h-3V1H9v3H6c-1.1 0-2 .9-2 2v4.62l-1.29.42c-.26.08-.48.26-.6.5s-.15.52-.06.78L3.95 19zM6 6h12v3.97L12 8 6 9.97V6z"/></g> +<g id="directions-bus"><path d="M4 16c0 .88.39 1.67 1 2.22V20c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h8v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1.78c.61-.55 1-1.34 1-2.22V6c0-3.5-3.58-4-8-4s-8 .5-8 4v10zm3.5 1c-.83 0-1.5-.67-1.5-1.5S6.67 14 7.5 14s1.5.67 1.5 1.5S8.33 17 7.5 17zm9 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm1.5-6H6V6h12v5z"/></g> +<g id="directions-car"><path d="M18.92 6.01C18.72 5.42 18.16 5 17.5 5h-11c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 16c-.83 0-1.5-.67-1.5-1.5S5.67 13 6.5 13s1.5.67 1.5 1.5S7.33 16 6.5 16zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 11l1.5-4.5h11L19 11H5z"/></g> +<g id="directions-railway"><path d="M4 15.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V5c0-3.5-3.58-4-8-4s-8 .5-8 4v10.5zm8 1.5c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm6-7H6V5h12v5z"/></g> +<g id="directions-run"><path d="M13.49 5.48c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-3.6 13.9l1-4.4 2.1 2v6h2v-7.5l-2.1-2 .6-3c1.3 1.5 3.3 2.5 5.5 2.5v-2c-1.9 0-3.5-1-4.3-2.4l-1-1.6c-.4-.6-1-1-1.7-1-.3 0-.5.1-.8.1l-5.2 2.2v4.7h2v-3.4l1.8-.7-1.6 8.1-4.9-1-.4 2 7 1.4z"/></g> +<g id="directions-subway"><path d="M12 2c-4.42 0-8 .5-8 4v9.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V6c0-3.5-3.58-4-8-4zM7.5 17c-.83 0-1.5-.67-1.5-1.5S6.67 14 7.5 14s1.5.67 1.5 1.5S8.33 17 7.5 17zm3.5-6H6V6h5v5zm5.5 6c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm1.5-6h-5V6h5v5z"/></g> +<g id="directions-transit"><path d="M12 2c-4.42 0-8 .5-8 4v9.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V6c0-3.5-3.58-4-8-4zM7.5 17c-.83 0-1.5-.67-1.5-1.5S6.67 14 7.5 14s1.5.67 1.5 1.5S8.33 17 7.5 17zm3.5-6H6V6h5v5zm5.5 6c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm1.5-6h-5V6h5v5z"/></g> +<g id="directions-walk"><path d="M13.5 5.5c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zM9.8 8.9L7 23h2.1l1.8-8 2.1 2v6h2v-7.5l-2.1-2 .6-3C14.8 12 16.8 13 19 13v-2c-1.9 0-3.5-1-4.3-2.4l-1-1.6c-.4-.6-1-1-1.7-1-.3 0-.5.1-.8.1L6 8.3V13h2V9.6l1.8-.7"/></g> +<g id="flight"><path d="M10.18 9"/><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/></g> +<g id="hotel"><path d="M7 13c1.66 0 3-1.34 3-3S8.66 7 7 7s-3 1.34-3 3 1.34 3 3 3zm12-6h-8v7H3V5H1v15h2v-3h18v3h2v-9c0-2.21-1.79-4-4-4z"/></g> +<g id="layers"><path d="M11.99 18.54l-7.37-5.73L3 14.07l9 7 9-7-1.63-1.27-7.38 5.74zM12 16l7.36-5.73L21 9l-9-7-9 7 1.63 1.27L12 16z"/></g> +<g id="layers-clear"><path d="M19.81 14.99l1.19-.92-1.43-1.43-1.19.92 1.43 1.43zm-.45-4.72L21 9l-9-7-2.91 2.27 7.87 7.88 2.4-1.88zM3.27 1L2 2.27l4.22 4.22L3 9l1.63 1.27L12 16l2.1-1.63 1.43 1.43L12 18.54l-7.37-5.73L3 14.07l9 7 4.95-3.85L20.73 21 22 19.73 3.27 1z"/></g> +<g id="local-activity"><path d="M20 12c0-1.1.9-2 2-2V6c0-1.1-.9-2-2-2H4c-1.1 0-1.99.9-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2zm-4.42 4.8L12 14.5l-3.58 2.3 1.08-4.12-3.29-2.69 4.24-.25L12 5.8l1.54 3.95 4.24.25-3.29 2.69 1.09 4.11z"/></g> +<g id="local-airport"><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/></g> +<g id="local-atm"><path d="M11 17h2v-1h1c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1h-3v-1h4V8h-2V7h-2v1h-1c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1h3v1H9v2h2v1zm9-13H4c-1.11 0-1.99.89-1.99 2L2 18c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6c0-1.11-.89-2-2-2zm0 14H4V6h16v12z"/></g> +<g id="local-bar"><path d="M11 13v6H6v2h12v-2h-5v-6l8-8V3H3v2l8 8zM7.5 7l-2-2h13l-2 2h-9z"/></g> +<g id="local-cafe"><path d="M20 3H4v10c0 2.21 1.79 4 4 4h6c2.21 0 4-1.79 4-4v-3h2c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2zm0 5h-2V5h2v3zM2 21h18v-2H2v2z"/></g> +<g id="local-car-wash"><path d="M17 5c.83 0 1.5-.67 1.5-1.5 0-1-1.5-2.7-1.5-2.7s-1.5 1.7-1.5 2.7c0 .83.67 1.5 1.5 1.5zm-5 0c.83 0 1.5-.67 1.5-1.5 0-1-1.5-2.7-1.5-2.7s-1.5 1.7-1.5 2.7c0 .83.67 1.5 1.5 1.5zM7 5c.83 0 1.5-.67 1.5-1.5C8.5 2.5 7 .8 7 .8S5.5 2.5 5.5 3.5C5.5 4.33 6.17 5 7 5zm11.92 3.01C18.72 7.42 18.16 7 17.5 7h-11c-.66 0-1.21.42-1.42 1.01L3 14v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 18c-.83 0-1.5-.67-1.5-1.5S5.67 15 6.5 15s1.5.67 1.5 1.5S7.33 18 6.5 18zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 13l1.5-4.5h11L19 13H5z"/></g> +<g id="local-convenience-store"><path d="M19 7V4H5v3H2v13h8v-4h4v4h8V7h-3zm-8 3H9v1h2v1H8V9h2V8H8V7h3v3zm5 2h-1v-2h-2V7h1v2h1V7h1v5z"/></g> +<g id="local-dining"><path d="M8.1 13.34l2.83-2.83L3.91 3.5c-1.56 1.56-1.56 4.09 0 5.66l4.19 4.18zm6.78-1.81c1.53.71 3.68.21 5.27-1.38 1.91-1.91 2.28-4.65.81-6.12-1.46-1.46-4.2-1.1-6.12.81-1.59 1.59-2.09 3.74-1.38 5.27L3.7 19.87l1.41 1.41L12 14.41l6.88 6.88 1.41-1.41L13.41 13l1.47-1.47z"/></g> +<g id="local-drink"><path d="M3 2l2.01 18.23C5.13 21.23 5.97 22 7 22h10c1.03 0 1.87-.77 1.99-1.77L21 2H3zm9 17c-1.66 0-3-1.34-3-3 0-2 3-5.4 3-5.4s3 3.4 3 5.4c0 1.66-1.34 3-3 3zm6.33-11H5.67l-.44-4h13.53l-.43 4z"/></g> +<g id="local-florist"><path d="M12 22c4.97 0 9-4.03 9-9-4.97 0-9 4.03-9 9zM5.6 10.25c0 1.38 1.12 2.5 2.5 2.5.53 0 1.01-.16 1.42-.44l-.02.19c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5l-.02-.19c.4.28.89.44 1.42.44 1.38 0 2.5-1.12 2.5-2.5 0-1-.59-1.85-1.43-2.25.84-.4 1.43-1.25 1.43-2.25 0-1.38-1.12-2.5-2.5-2.5-.53 0-1.01.16-1.42.44l.02-.19C14.5 2.12 13.38 1 12 1S9.5 2.12 9.5 3.5l.02.19c-.4-.28-.89-.44-1.42-.44-1.38 0-2.5 1.12-2.5 2.5 0 1 .59 1.85 1.43 2.25-.84.4-1.43 1.25-1.43 2.25zM12 5.5c1.38 0 2.5 1.12 2.5 2.5s-1.12 2.5-2.5 2.5S9.5 9.38 9.5 8s1.12-2.5 2.5-2.5zM3 13c0 4.97 4.03 9 9 9 0-4.97-4.03-9-9-9z"/></g> +<g id="local-gas-station"><path d="M19.77 7.23l.01-.01-3.72-3.72L15 4.56l2.11 2.11c-.94.36-1.61 1.26-1.61 2.33 0 1.38 1.12 2.5 2.5 2.5.36 0 .69-.08 1-.21v7.21c0 .55-.45 1-1 1s-1-.45-1-1V14c0-1.1-.9-2-2-2h-1V5c0-1.1-.9-2-2-2H6c-1.1 0-2 .9-2 2v16h10v-7.5h1.5v5c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5V9c0-.69-.28-1.32-.73-1.77zM12 10H6V5h6v5zm6 0c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="local-grocery-store"><path d="M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="local-hospital"><path d="M19 3H5c-1.1 0-1.99.9-1.99 2L3 19c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-1 11h-4v4h-4v-4H6v-4h4V6h4v4h4v4z"/></g> +<g id="local-hotel"><path d="M7 13c1.66 0 3-1.34 3-3S8.66 7 7 7s-3 1.34-3 3 1.34 3 3 3zm12-6h-8v7H3V5H1v15h2v-3h18v3h2v-9c0-2.21-1.79-4-4-4z"/></g> +<g id="local-laundry-service"><path d="M9.17 16.83c1.56 1.56 4.1 1.56 5.66 0 1.56-1.56 1.56-4.1 0-5.66l-5.66 5.66zM18 2.01L6 2c-1.11 0-2 .89-2 2v16c0 1.11.89 2 2 2h12c1.11 0 2-.89 2-2V4c0-1.11-.89-1.99-2-1.99zM10 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zM7 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm5 16c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6z"/></g> +<g id="local-library"><path d="M12 11.55C9.64 9.35 6.48 8 3 8v11c3.48 0 6.64 1.35 9 3.55 2.36-2.19 5.52-3.55 9-3.55V8c-3.48 0-6.64 1.35-9 3.55zM12 8c1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3 1.34 3 3 3z"/></g> +<g id="local-mall"><path d="M19 6h-2c0-2.76-2.24-5-5-5S7 3.24 7 6H5c-1.1 0-1.99.9-1.99 2L3 20c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-7-3c1.66 0 3 1.34 3 3H9c0-1.66 1.34-3 3-3zm0 10c-2.76 0-5-2.24-5-5h2c0 1.66 1.34 3 3 3s3-1.34 3-3h2c0 2.76-2.24 5-5 5z"/></g> +<g id="local-movies"><path d="M18 3v2h-2V3H8v2H6V3H4v18h2v-2h2v2h8v-2h2v2h2V3h-2zM8 17H6v-2h2v2zm0-4H6v-2h2v2zm0-4H6V7h2v2zm10 8h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V7h2v2z"/></g> +<g id="local-offer"><path d="M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58.55 0 1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41 0-.55-.23-1.06-.59-1.42zM5.5 7C4.67 7 4 6.33 4 5.5S4.67 4 5.5 4 7 4.67 7 5.5 6.33 7 5.5 7z"/></g> +<g id="local-parking"><path d="M13 3H6v18h4v-6h3c3.31 0 6-2.69 6-6s-2.69-6-6-6zm.2 8H10V7h3.2c1.1 0 2 .9 2 2s-.9 2-2 2z"/></g> +<g id="local-pharmacy"><path d="M21 5h-2.64l1.14-3.14L17.15 1l-1.46 4H3v2l2 6-2 6v2h18v-2l-2-6 2-6V5zm-5 9h-3v3h-2v-3H8v-2h3V9h2v3h3v2z"/></g> +<g id="local-phone"><path d="M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z"/></g> +<g id="local-pizza"><path d="M12 2C8.43 2 5.23 3.54 3.01 6L12 22l8.99-16C18.78 3.55 15.57 2 12 2zM7 7c0-1.1.9-2 2-2s2 .9 2 2-.9 2-2 2-2-.9-2-2zm5 8c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="local-play"><path d="M20 12c0-1.1.9-2 2-2V6c0-1.1-.9-2-2-2H4c-1.1 0-1.99.9-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2zm-4.42 4.8L12 14.5l-3.58 2.3 1.08-4.12-3.29-2.69 4.24-.25L12 5.8l1.54 3.95 4.24.25-3.29 2.69 1.09 4.11z"/></g> +<g id="local-post-office"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="local-printshop"><path d="M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"/></g> +<g id="local-see"><circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"/></g> +<g id="local-shipping"><path d="M20 8h-3V4H3c-1.1 0-2 .9-2 2v11h2c0 1.66 1.34 3 3 3s3-1.34 3-3h6c0 1.66 1.34 3 3 3s3-1.34 3-3h2v-5l-3-4zM6 18.5c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm13.5-9l1.96 2.5H17V9.5h2.5zm-1.5 9c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="local-taxi"><path d="M18.92 6.01C18.72 5.42 18.16 5 17.5 5H15V3H9v2H6.5c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 16c-.83 0-1.5-.67-1.5-1.5S5.67 13 6.5 13s1.5.67 1.5 1.5S7.33 16 6.5 16zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 11l1.5-4.5h11L19 11H5z"/></g> +<g id="map"><path d="M20.5 3l-.16.03L15 5.1 9 3 3.36 4.9c-.21.07-.36.25-.36.48V20.5c0 .28.22.5.5.5l.16-.03L9 18.9l6 2.1 5.64-1.9c.21-.07.36-.25.36-.48V3.5c0-.28-.22-.5-.5-.5zM15 19l-6-2.11V5l6 2.11V19z"/></g> +<g id="my-location"><path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm8.94 3c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="navigation"><path d="M12 2L4.5 20.29l.71.71L12 18l6.79 3 .71-.71z"/></g> +<g id="person-pin"><path d="M19 2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h4l3 3 3-3h4c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 3.3c1.49 0 2.7 1.21 2.7 2.7 0 1.49-1.21 2.7-2.7 2.7-1.49 0-2.7-1.21-2.7-2.7 0-1.49 1.21-2.7 2.7-2.7zM18 16H6v-.9c0-2 4-3.1 6-3.1s6 1.1 6 3.1v.9z"/></g> +<g id="pin-drop"><path d="M18 8c0-3.31-2.69-6-6-6S6 4.69 6 8c0 4.5 6 11 6 11s6-6.5 6-11zm-8 0c0-1.1.9-2 2-2s2 .9 2 2-.89 2-2 2c-1.1 0-2-.9-2-2zM5 20v2h14v-2H5z"/></g> +<g id="place"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="rate-review"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 14v-2.47l6.88-6.88c.2-.2.51-.2.71 0l1.77 1.77c.2.2.2.51 0 .71L8.47 14H6zm12 0h-7.5l2-2H18v2z"/></g> +<g id="restaurant-menu"><path d="M8.1 13.34l2.83-2.83L3.91 3.5c-1.56 1.56-1.56 4.09 0 5.66l4.19 4.18zm6.78-1.81c1.53.71 3.68.21 5.27-1.38 1.91-1.91 2.28-4.65.81-6.12-1.46-1.46-4.2-1.1-6.12.81-1.59 1.59-2.09 3.74-1.38 5.27L3.7 19.87l1.41 1.41L12 14.41l6.88 6.88 1.41-1.41L13.41 13l1.47-1.47z"/></g> +<g id="satellite"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5 4.99h3C8 6.65 6.66 8 5 8V4.99zM5 12v-2c2.76 0 5-2.25 5-5.01h2C12 8.86 8.87 12 5 12zm0 6l3.5-4.5 2.5 3.01L14.5 12l4.5 6H5z"/></g> +<g id="store-mall-directory"><path d="M20 4H4v2h16V4zm1 10v-2l-1-5H4l-1 5v2h1v6h10v-6h4v6h2v-6h1zm-9 4H6v-4h6v4z"/></g> +<g id="terrain"><path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z"/></g> +<g id="traffic"><path d="M20 10h-3V8.86c1.72-.45 3-2 3-3.86h-3V4c0-.55-.45-1-1-1H8c-.55 0-1 .45-1 1v1H4c0 1.86 1.28 3.41 3 3.86V10H4c0 1.86 1.28 3.41 3 3.86V15H4c0 1.86 1.28 3.41 3 3.86V20c0 .55.45 1 1 1h8c.55 0 1-.45 1-1v-1.14c1.72-.45 3-2 3-3.86h-3v-1.14c1.72-.45 3-2 3-3.86zm-8 9c-1.11 0-2-.9-2-2s.89-2 2-2c1.1 0 2 .9 2 2s-.89 2-2 2zm0-5c-1.11 0-2-.9-2-2s.89-2 2-2c1.1 0 2 .9 2 2s-.89 2-2 2zm0-5c-1.11 0-2-.9-2-2 0-1.11.89-2 2-2 1.1 0 2 .89 2 2 0 1.1-.89 2-2 2z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/notification-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/notification-icons.html new file mode 100644 index 0000000..39db434 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/notification-icons.html @@ -0,0 +1,62 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="notification" size="24"> +<svg><defs> +<g id="adb"><path d="M5 16c0 3.87 3.13 7 7 7s7-3.13 7-7v-4H5v4zM16.12 4.37l2.1-2.1-.82-.83-2.3 2.31C14.16 3.28 13.12 3 12 3s-2.16.28-3.09.75L6.6 1.44l-.82.83 2.1 2.1C6.14 5.64 5 7.68 5 10v1h14v-1c0-2.32-1.14-4.36-2.88-5.63zM9 9c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm6 0c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="airline-seat-flat"><path d="M22 11v2H9V7h9c2.21 0 4 1.79 4 4zM2 14v2h6v2h8v-2h6v-2H2zm5.14-1.9c1.16-1.19 1.14-3.08-.04-4.24-1.19-1.16-3.08-1.14-4.24.04-1.16 1.19-1.14 3.08.04 4.24 1.19 1.16 3.08 1.14 4.24-.04z"/></g> +<g id="airline-seat-flat-angled"><path d="M22.25 14.29l-.69 1.89L9.2 11.71l2.08-5.66 8.56 3.09c2.1.76 3.18 3.06 2.41 5.15zM1.5 12.14L8 14.48V19h8v-1.63L20.52 19l.69-1.89-19.02-6.86-.69 1.89zm5.8-1.94c1.49-.72 2.12-2.51 1.41-4C7.99 4.71 6.2 4.08 4.7 4.8c-1.49.71-2.12 2.5-1.4 4 .71 1.49 2.5 2.12 4 1.4z"/></g> +<g id="airline-seat-individual-suite"><path d="M7 13c1.65 0 3-1.35 3-3S8.65 7 7 7s-3 1.35-3 3 1.35 3 3 3zm12-6h-8v7H3V7H1v10h22v-6c0-2.21-1.79-4-4-4z"/></g> +<g id="airline-seat-legroom-extra"><path d="M4 12V3H2v9c0 2.76 2.24 5 5 5h6v-2H7c-1.66 0-3-1.34-3-3zm18.83 5.24c-.38-.72-1.29-.97-2.03-.63l-1.09.5-3.41-6.98c-.34-.68-1.03-1.12-1.79-1.12L11 9V3H5v8c0 1.66 1.34 3 3 3h7l3.41 7 3.72-1.7c.77-.36 1.1-1.3.7-2.06z"/></g> +<g id="airline-seat-legroom-normal"><path d="M5 12V3H3v9c0 2.76 2.24 5 5 5h6v-2H8c-1.66 0-3-1.34-3-3zm15.5 6H19v-7c0-1.1-.9-2-2-2h-5V3H6v8c0 1.65 1.35 3 3 3h7v7h4.5c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5z"/></g> +<g id="airline-seat-legroom-reduced"><path d="M19.97 19.2c.18.96-.55 1.8-1.47 1.8H14v-3l1-4H9c-1.65 0-3-1.35-3-3V3h6v6h5c1.1 0 2 .9 2 2l-2 7h1.44c.73 0 1.39.49 1.53 1.2zM5 12V3H3v9c0 2.76 2.24 5 5 5h4v-2H8c-1.66 0-3-1.34-3-3z"/></g> +<g id="airline-seat-recline-extra"><path d="M5.35 5.64c-.9-.64-1.12-1.88-.49-2.79.63-.9 1.88-1.12 2.79-.49.9.64 1.12 1.88.49 2.79-.64.9-1.88 1.12-2.79.49zM16 19H8.93c-1.48 0-2.74-1.08-2.96-2.54L4 7H2l1.99 9.76C4.37 19.2 6.47 21 8.94 21H16v-2zm.23-4h-4.88l-1.03-4.1c1.58.89 3.28 1.54 5.15 1.22V9.99c-1.63.31-3.44-.27-4.69-1.25L9.14 7.47c-.23-.18-.49-.3-.76-.38-.32-.09-.66-.12-.99-.06h-.02c-1.23.22-2.05 1.39-1.84 2.61l1.35 5.92C7.16 16.98 8.39 18 9.83 18h6.85l3.82 3 1.5-1.5-5.77-4.5z"/></g> +<g id="airline-seat-recline-normal"><path d="M7.59 5.41c-.78-.78-.78-2.05 0-2.83.78-.78 2.05-.78 2.83 0 .78.78.78 2.05 0 2.83-.79.79-2.05.79-2.83 0zM6 16V7H4v9c0 2.76 2.24 5 5 5h6v-2H9c-1.66 0-3-1.34-3-3zm14 4.07L14.93 15H11.5v-3.68c1.4 1.15 3.6 2.16 5.5 2.16v-2.16c-1.66.02-3.61-.87-4.67-2.04l-1.4-1.55c-.19-.21-.43-.38-.69-.5-.29-.14-.62-.23-.96-.23h-.03C8.01 7 7 8.01 7 9.25V15c0 1.66 1.34 3 3 3h5.07l3.5 3.5L20 20.07z"/></g> +<g id="bluetooth-audio"><path d="M14.24 12.01l2.32 2.32c.28-.72.44-1.51.44-2.33 0-.82-.16-1.59-.43-2.31l-2.33 2.32zm5.29-5.3l-1.26 1.26c.63 1.21.98 2.57.98 4.02s-.36 2.82-.98 4.02l1.2 1.2c.97-1.54 1.54-3.36 1.54-5.31-.01-1.89-.55-3.67-1.48-5.19zm-3.82 1L10 2H9v7.59L4.41 5 3 6.41 8.59 12 3 17.59 4.41 19 9 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM11 5.83l1.88 1.88L11 9.59V5.83zm1.88 10.46L11 18.17v-3.76l1.88 1.88z"/></g> +<g id="confirmation-number"><defs><path id="a" d="M0 0h24v24H0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M22 10V6c0-1.11-.9-2-2-2H4c-1.1 0-1.99.89-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2s.9-2 2-2zm-9 7.5h-2v-2h2v2zm0-4.5h-2v-2h2v2zm0-4.5h-2v-2h2v2z" clip-path="url(#b)"/></g> +<g id="disc-full"><path d="M20 16h2v-2h-2v2zm0-9v5h2V7h-2zM10 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm0 10c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="do-not-disturb"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8 0-1.85.63-3.55 1.69-4.9L16.9 18.31C15.55 19.37 13.85 20 12 20zm6.31-3.1L7.1 5.69C8.45 4.63 10.15 4 12 4c4.42 0 8 3.58 8 8 0 1.85-.63 3.55-1.69 4.9z"/></g> +<g id="do-not-disturb-alt"><path d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zM4 12c0-4.4 3.6-8 8-8 1.8 0 3.5.6 4.9 1.7L5.7 16.9C4.6 15.5 4 13.8 4 12zm8 8c-1.8 0-3.5-.6-4.9-1.7L18.3 7.1C19.4 8.5 20 10.2 20 12c0 4.4-3.6 8-8 8z"/></g> +<g id="drive-eta"><path d="M18.92 5.01C18.72 4.42 18.16 4 17.5 4h-11c-.66 0-1.21.42-1.42 1.01L3 11v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 15c-.83 0-1.5-.67-1.5-1.5S5.67 12 6.5 12s1.5.67 1.5 1.5S7.33 15 6.5 15zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 10l1.5-4.5h11L19 10H5z"/></g> +<g id="event-available"><path d="M16.53 11.06L15.47 10l-4.88 4.88-2.12-2.12-1.06 1.06L10.59 17l5.94-5.94zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11z"/></g> +<g id="event-busy"><path d="M9.31 17l2.44-2.44L14.19 17l1.06-1.06-2.44-2.44 2.44-2.44L14.19 10l-2.44 2.44L9.31 10l-1.06 1.06 2.44 2.44-2.44 2.44L9.31 17zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11z"/></g> +<g id="event-note"><path d="M17 10H7v2h10v-2zm2-7h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zm-5-5H7v2h7v-2z"/></g> +<g id="folder-special"><path d="M20 6h-8l-2-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-6.42 12L10 15.9 6.42 18l.95-4.07-3.16-2.74 4.16-.36L10 7l1.63 3.84 4.16.36-3.16 2.74.95 4.06z"/></g> +<g id="live-tv"><path d="M21 6h-7.59l3.29-3.29L16 2l-4 4-4-4-.71.71L10.59 6H3c-1.1 0-2 .89-2 2v12c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.11-.9-2-2-2zm0 14H3V8h18v12zM9 10v8l7-4z"/></g> +<g id="mms"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM5 14l3.5-4.5 2.5 3.01L14.5 8l4.5 6H5z"/></g> +<g id="more"><path d="M22 3H7c-.69 0-1.23.35-1.59.88L0 12l5.41 8.11c.36.53.97.89 1.66.89H22c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 13.5c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm5 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm5 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="network-locked"><path d="M19.5 10c.17 0 .33.03.5.05V1L1 20h13v-3c0-.89.39-1.68 1-2.23v-.27c0-2.48 2.02-4.5 4.5-4.5zm2.5 6v-1.5c0-1.38-1.12-2.5-2.5-2.5S17 13.12 17 14.5V16c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1v-4c0-.55-.45-1-1-1zm-1 0h-3v-1.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V16z"/></g> +<g id="ondemand-video"><path d="M21 3H3c-1.11 0-2 .89-2 2v12c0 1.1.89 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.11-.9-2-2-2zm0 14H3V5h18v12zm-5-6l-7 4V7z"/></g> +<g id="personal-video"><path d="M21 3H3c-1.11 0-2 .89-2 2v12c0 1.1.89 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.11-.9-2-2-2zm0 14H3V5h18v12z"/></g> +<g id="phone-bluetooth-speaker"><path d="M14.71 9.5L17 7.21V11h.5l2.85-2.85L18.21 6l2.15-2.15L17.5 1H17v3.79L14.71 2.5l-.71.71L16.79 6 14 8.79l.71.71zM18 2.91l.94.94-.94.94V2.91zm0 4.3l.94.94-.94.94V7.21zm2 8.29c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1z"/></g> +<g id="phone-forwarded"><path d="M18 11l5-5-5-5v3h-4v4h4v3zm2 4.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1z"/></g> +<g id="phone-in-talk"><path d="M20 15.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM19 12h2c0-4.97-4.03-9-9-9v2c3.87 0 7 3.13 7 7zm-4 0h2c0-2.76-2.24-5-5-5v2c1.66 0 3 1.34 3 3z"/></g> +<g id="phone-locked"><path d="M20 15.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM20 4v-.5C20 2.12 18.88 1 17.5 1S15 2.12 15 3.5V4c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1V5c0-.55-.45-1-1-1zm-.8 0h-3.4v-.5c0-.94.76-1.7 1.7-1.7s1.7.76 1.7 1.7V4z"/></g> +<g id="phone-missed"><path d="M6.5 5.5L12 11l7-7-1-1-6 6-4.5-4.5H11V3H5v6h1.5V5.5zm17.21 11.17C20.66 13.78 16.54 12 12 12 7.46 12 3.34 13.78.29 16.67c-.18.18-.29.43-.29.71s.11.53.29.71l2.48 2.48c.18.18.43.29.71.29.27 0 .52-.11.7-.28.79-.74 1.69-1.36 2.66-1.85.33-.16.56-.5.56-.9v-3.1c1.45-.48 3-.73 4.6-.73 1.6 0 3.15.25 4.6.72v3.1c0 .39.23.74.56.9.98.49 1.87 1.12 2.67 1.85.18.18.43.28.7.28.28 0 .53-.11.71-.29l2.48-2.48c.18-.18.29-.43.29-.71s-.12-.52-.3-.7z"/></g> +<g id="phone-paused"><path d="M17 3h-2v7h2V3zm3 12.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM19 3v7h2V3h-2z"/></g> +<g id="power"><path d="M16.01 7L16 3h-2v4h-4V3H8v4h-.01C7 6.99 6 7.99 6 8.99v5.49L9.5 18v3h5v-3l3.5-3.51v-5.5c0-1-1-2-1.99-1.99z"/></g> +<g id="sd-card"><path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6 6h-2V4h2v4zm3 0h-2V4h2v4zm3 0h-2V4h2v4z"/></g> +<g id="sim-card-alert"><path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5 15h-2v-2h2v2zm0-4h-2V8h2v5z"/></g> +<g id="sms"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM9 11H7V9h2v2zm4 0h-2V9h2v2zm4 0h-2V9h2v2z"/></g> +<g id="sms-failed"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 12h-2v-2h2v2zm0-4h-2V6h2v4z"/></g> +<g id="sync"><path d="M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"/></g> +<g id="sync-disabled"><path d="M10 6.35V4.26c-.8.21-1.55.54-2.23.96l1.46 1.46c.25-.12.5-.24.77-.33zm-7.14-.94l2.36 2.36C4.45 8.99 4 10.44 4 12c0 2.21.91 4.2 2.36 5.64L4 20h6v-6l-2.24 2.24C6.68 15.15 6 13.66 6 12c0-1 .25-1.94.68-2.77l8.08 8.08c-.25.13-.5.25-.77.34v2.09c.8-.21 1.55-.54 2.23-.96l2.36 2.36 1.27-1.27L4.14 4.14 2.86 5.41zM20 4h-6v6l2.24-2.24C17.32 8.85 18 10.34 18 12c0 1-.25 1.94-.68 2.77l1.46 1.46C19.55 15.01 20 13.56 20 12c0-2.21-.91-4.2-2.36-5.64L20 4z"/></g> +<g id="sync-problem"><path d="M3 12c0 2.21.91 4.2 2.36 5.64L3 20h6v-6l-2.24 2.24C5.68 15.15 5 13.66 5 12c0-2.61 1.67-4.83 4-5.65V4.26C5.55 5.15 3 8.27 3 12zm8 5h2v-2h-2v2zM21 4h-6v6l2.24-2.24C18.32 8.85 19 10.34 19 12c0 2.61-1.67 4.83-4 5.65v2.09c3.45-.89 6-4.01 6-7.74 0-2.21-.91-4.2-2.36-5.64L21 4zm-10 9h2V7h-2v6z"/></g> +<g id="system-update"><path d="M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14zm-1-6h-3V8h-2v5H8l4 4 4-4z"/></g> +<g id="tap-and-play"><path d="M2 16v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm0 4v3h3c0-1.66-1.34-3-3-3zm0-8v2c4.97 0 9 4.03 9 9h2c0-6.08-4.92-11-11-11zM17 1.01L7 1c-1.1 0-2 .9-2 2v7.37c.69.16 1.36.37 2 .64V5h10v13h-3.03c.52 1.25.84 2.59.95 4H17c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99z"/></g> +<g id="time-to-leave"><path d="M18.92 5.01C18.72 4.42 18.16 4 17.5 4h-11c-.66 0-1.21.42-1.42 1.01L3 11v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 15c-.83 0-1.5-.67-1.5-1.5S5.67 12 6.5 12s1.5.67 1.5 1.5S7.33 15 6.5 15zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 10l1.5-4.5h11L19 10H5z"/></g> +<g id="vibration"><path d="M0 15h2V9H0v6zm3 2h2V7H3v10zm19-8v6h2V9h-2zm-3 8h2V7h-2v10zM16.5 3h-9C6.67 3 6 3.67 6 4.5v15c0 .83.67 1.5 1.5 1.5h9c.83 0 1.5-.67 1.5-1.5v-15c0-.83-.67-1.5-1.5-1.5zM16 19H8V5h8v14z"/></g> +<g id="voice-chat"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-2 12l-4-3.2V14H6V6h8v3.2L18 6v8z"/></g> +<g id="vpn-lock"><path d="M22 4v-.5C22 2.12 20.88 1 19.5 1S17 2.12 17 3.5V4c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1V5c0-.55-.45-1-1-1zm-.8 0h-3.4v-.5c0-.94.76-1.7 1.7-1.7s1.7.76 1.7 1.7V4zm-2.28 8c.04.33.08.66.08 1 0 2.08-.8 3.97-2.1 5.39-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H7v-2h2c.55 0 1-.45 1-1V8h2c1.1 0 2-.9 2-2V3.46c-.95-.3-1.95-.46-3-.46C5.48 3 1 7.48 1 13s4.48 10 10 10 10-4.48 10-10c0-.34-.02-.67-.05-1h-2.03zM10 20.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L8 16v1c0 1.1.9 2 2 2v1.93z"/></g> +<g id="wc"><path d="M5.5 22v-7.5H4V9c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2v5.5H9.5V22h-4zM18 22v-6h3l-2.54-7.63C18.18 7.55 17.42 7 16.56 7h-.12c-.86 0-1.63.55-1.9 1.37L12 16h3v6h3zM7.5 6c1.11 0 2-.89 2-2s-.89-2-2-2-2 .89-2 2 .89 2 2 2zm9 0c1.11 0 2-.89 2-2s-.89-2-2-2-2 .89-2 2 .89 2 2 2z"/></g> +<g id="wifi"><path d="M1 9l2 2c4.97-4.97 13.03-4.97 18 0l2-2C16.93 2.93 7.08 2.93 1 9zm8 8l3 3 3-3c-1.65-1.66-4.34-1.66-6 0zm-4-4l2 2c2.76-2.76 7.24-2.76 10 0l2-2C15.14 9.14 8.87 9.14 5 13z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-icons/social-icons.html b/third_party/polymer/v1_0/components-chromium/iron-icons/social-icons.html new file mode 100644 index 0000000..5553caa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-icons/social-icons.html @@ -0,0 +1,40 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="social" size="24"> +<svg><defs> +<g id="cake"><path d="M12 6c1.11 0 2-.9 2-2 0-.38-.1-.73-.29-1.03L12 0l-1.71 2.97c-.19.3-.29.65-.29 1.03 0 1.1.9 2 2 2zm4.6 9.99l-1.07-1.07-1.08 1.07c-1.3 1.3-3.58 1.31-4.89 0l-1.07-1.07-1.09 1.07C6.75 16.64 5.88 17 4.96 17c-.73 0-1.4-.23-1.96-.61V21c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-4.61c-.56.38-1.23.61-1.96.61-.92 0-1.79-.36-2.44-1.01zM18 9h-5V7h-2v2H6c-1.66 0-3 1.34-3 3v1.54c0 1.08.88 1.96 1.96 1.96.52 0 1.02-.2 1.38-.57l2.14-2.13 2.13 2.13c.74.74 2.03.74 2.77 0l2.14-2.13 2.13 2.13c.37.37.86.57 1.38.57 1.08 0 1.96-.88 1.96-1.96V12C21 10.34 19.66 9 18 9z"/></g> +<g id="domain"><path d="M12 7V3H2v18h20V7H12zM6 19H4v-2h2v2zm0-4H4v-2h2v2zm0-4H4V9h2v2zm0-4H4V5h2v2zm4 12H8v-2h2v2zm0-4H8v-2h2v2zm0-4H8V9h2v2zm0-4H8V5h2v2zm10 12h-8v-2h2v-2h-2v-2h2v-2h-2V9h8v10zm-2-8h-2v2h2v-2zm0 4h-2v2h2v-2z"/></g> +<g id="group"><path d="M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"/></g> +<g id="group-add"><path d="M8 10H5V7H3v3H0v2h3v3h2v-3h3v-2zm10 1c1.66 0 2.99-1.34 2.99-3S19.66 5 18 5c-.32 0-.63.05-.91.14.57.81.9 1.79.9 2.86s-.34 2.04-.9 2.86c.28.09.59.14.91.14zm-5 0c1.66 0 2.99-1.34 2.99-3S14.66 5 13 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm6.62 2.16c.83.73 1.38 1.66 1.38 2.84v2h3v-2c0-1.54-2.37-2.49-4.38-2.84zM13 13c-2 0-6 1-6 3v2h12v-2c0-2-4-3-6-3z"/></g> +<g id="location-city"><path d="M15 11V5l-3-3-3 3v2H3v14h18V11h-6zm-8 8H5v-2h2v2zm0-4H5v-2h2v2zm0-4H5V9h2v2zm6 8h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V9h2v2zm0-4h-2V5h2v2zm6 12h-2v-2h2v2zm0-4h-2v-2h2v2z"/></g> +<g id="mood"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 6.5c2.33 0 4.31-1.46 5.11-3.5H6.89c.8 2.04 2.78 3.5 5.11 3.5z"/></g> +<g id="mood-bad"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 3c-2.33 0-4.31 1.46-5.11 3.5h10.22c-.8-2.04-2.78-3.5-5.11-3.5z"/></g> +<g id="notifications"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6.5-6v-5.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2z"/></g> +<g id="notifications-active"><path d="M6.58 3.58L5.15 2.15C2.76 3.97 1.18 6.8 1.03 10h2c.15-2.65 1.51-4.97 3.55-6.42zM19.97 10h2c-.15-3.2-1.73-6.03-4.13-7.85l-1.43 1.43c2.05 1.45 3.41 3.77 3.56 6.42zm-1.97.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2v-5.5zM11.5 22c.14 0 .27-.01.4-.04.65-.13 1.19-.58 1.44-1.18.1-.24.16-.5.16-.78h-4c0 1.1.9 2 2 2z"/></g> +<g id="notifications-none"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6.5-6v-5.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2zm-2 1H7v-6.5C7 8.01 9.01 6 11.5 6S16 8.01 16 10.5V17z"/></g> +<g id="notifications-off"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zM18 10.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-.51.12-.99.32-1.45.56L18 14.18V10.5zm-.27 8.5l2 2L21 19.73 4.27 3 3 4.27l2.92 2.92C5.34 8.16 5 9.29 5 10.5V16l-2 2v1h14.73z"/></g> +<g id="notifications-paused"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6.5-6v-5.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2zm-4-6.2l-2.8 3.4H14V15H9v-1.8l2.8-3.4H9V8h5v1.8z"/></g> +<g id="pages"><path d="M3 5v6h5L7 7l4 1V3H5c-1.1 0-2 .9-2 2zm5 8H3v6c0 1.1.9 2 2 2h6v-5l-4 1 1-4zm9 4l-4-1v5h6c1.1 0 2-.9 2-2v-6h-5l1 4zm2-14h-6v5l4-1-1 4h5V5c0-1.1-.9-2-2-2z"/></g> +<g id="party-mode"><path d="M20 4h-3.17L15 2H9L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 3c1.63 0 3.06.79 3.98 2H12c-1.66 0-3 1.34-3 3 0 .35.07.69.18 1H7.1c-.06-.32-.1-.66-.1-1 0-2.76 2.24-5 5-5zm0 10c-1.63 0-3.06-.79-3.98-2H12c1.66 0 3-1.34 3-3 0-.35-.07-.69-.18-1h2.08c.07.32.1.66.1 1 0 2.76-2.24 5-5 5z"/></g> +<g id="people"><path d="M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"/></g> +<g id="people-outline"><path d="M16.5 13c-1.2 0-3.07.34-4.5 1-1.43-.67-3.3-1-4.5-1C5.33 13 1 14.08 1 16.25V19h22v-2.75c0-2.17-4.33-3.25-6.5-3.25zm-4 4.5h-10v-1.25c0-.54 2.56-1.75 5-1.75s5 1.21 5 1.75v1.25zm9 0H14v-1.25c0-.46-.2-.86-.52-1.22.88-.3 1.96-.53 3.02-.53 2.44 0 5 1.21 5 1.75v1.25zM7.5 12c1.93 0 3.5-1.57 3.5-3.5S9.43 5 7.5 5 4 6.57 4 8.5 5.57 12 7.5 12zm0-5.5c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm9 5.5c1.93 0 3.5-1.57 3.5-3.5S18.43 5 16.5 5 13 6.57 13 8.5s1.57 3.5 3.5 3.5zm0-5.5c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2z"/></g> +<g id="person"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></g> +<g id="person-add"><path d="M15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm-9-2V7H4v3H1v2h3v3h2v-3h3v-2H6zm9 4c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></g> +<g id="person-outline"><path d="M12 5.9c1.16 0 2.1.94 2.1 2.1s-.94 2.1-2.1 2.1S9.9 9.16 9.9 8s.94-2.1 2.1-2.1m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z"/></g> +<g id="plus-one"><path d="M10 8H8v4H4v2h4v4h2v-4h4v-2h-4zm4.5-1.92V7.9l2.5-.5V18h2V5z"/></g> +<g id="poll"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/></g> +<g id="public"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z"/></g> +<g id="school"><path d="M5 13.18v4L12 21l7-3.82v-4L12 17l-7-3.82zM12 3L1 9l11 6 9-4.91V17h2V9L12 3z"/></g> +<g id="share"><path d="M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92 1.61 0 2.92-1.31 2.92-2.92s-1.31-2.92-2.92-2.92z"/></g> +<g id="whatshot"><path d="M13.5.67s.74 2.65.74 4.8c0 2.06-1.35 3.73-3.41 3.73-2.07 0-3.63-1.67-3.63-3.73l.03-.36C5.21 7.51 4 10.62 4 14c0 4.42 3.58 8 8 8s8-3.58 8-8C20 8.61 17.41 3.8 13.5.67zM11.71 19c-1.78 0-3.22-1.4-3.22-3.14 0-1.62 1.05-2.76 2.81-3.12 1.77-.36 3.6-1.21 4.62-2.58.39 1.29.59 2.65.59 4.04 0 2.65-2.15 4.8-4.8 4.8z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/.bower.json new file mode 100644 index 0000000..33c74b8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-iconset-svg", + "description": "Manages a set of svg icons", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + }, + "homepage": "https://github.com/PolymerElements/iron-iconset-svg", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "ce54b944d6f1f67a254ea9c99585e553eba76b6d" + }, + "_source": "git://github.com/PolymerElements/iron-iconset-svg.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-iconset-svg" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/README.md b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/README.md new file mode 100644 index 0000000..37d603a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/README.md @@ -0,0 +1,4 @@ +iron-iconset-svg +========= + +See the [component page](http://polymer-project.org/docs/elements/iron-elements.html#iron-iconset-svg) for more information. diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/bower.json b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/bower.json new file mode 100644 index 0000000..64e7d83 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/bower.json @@ -0,0 +1,26 @@ +{ + "name": "iron-iconset-svg", + "description": "Manages a set of svg icons", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/index.html b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/iron-iconset-svg-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/iron-iconset-svg-extracted.js new file mode 100644 index 0000000..3f461e2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/iron-iconset-svg-extracted.js @@ -0,0 +1,185 @@ + + /** + * The `iron-iconset-svg` element allows users to define their own icon sets + * that contain svg icons. The svg icon elements should be children of the + * `iron-iconset-svg` element. Multiple icons should be given distinct id's. + * + * Using svg elements to create icons has a few advantages over traditional + * bitmap graphics like jpg or png. Icons that use svg are vector based so they + * are resolution independent and should look good on any device. They are + * stylable via css. Icons can be themed, colorized, and even animated. + * + * Example: + * + * <iron-iconset-svg id="my-svg-icons" iconSize="24"> + * <svg> + * <defs> + * <g id="shape"> + * <rect x="50" y="50" width="50" height="50" /> + * <circle cx="50" cy="50" r="50" /> + * </g> + * </defs> + * </svg> + * </iron-iconset-svg> + * + * This will automatically register the icon set "my-svg-icons" to the iconset + * database. To use these icons from within another element, make a + * `iron-iconset` element and call the `byId` method + * to retrieve a given iconset. To apply a particular icon inside an + * element use the `applyIcon` method. For example: + * + * iconset.applyIcon(iconNode, 'car'); + * + * @element iron-iconset-svg + */ + Polymer({ + + is: 'iron-iconset-svg', + + properties: { + + /** + * The name of the iconset. + * + * @attribute name + * @type string + */ + name: { + type: String, + observer: '_nameChanged' + }, + + /** + * Array of fully-qualitifed icon names in the iconset. + */ + iconNames: { + type: Array, + notify: true + }, + + /** + * The size of an individual icon. Note that icons must be square. + * + * @attribute iconSize + * @type number + * @default 24 + */ + size: { + type: Number, + value: 24 + } + + }, + + /** + * Applies an icon to the given element. + * + * An svg icon is prepended to the element's shadowRoot if it exists, + * otherwise to the element itself. + * + * @method applyIcon + * @param {Element} element Element to which the icon is applied. + * @param {string} iconName Name of the icon to apply. + * @return {Element} The svg element which renders the icon. + */ + applyIcon: function(element, iconName) { + // insert svg element into shadow root, if it exists + element = element.root || element; + // Remove old svg element + this.removeIcon(element); + // install new svg element + var svg = this._cloneIcon(iconName); + if (svg) { + var pde = Polymer.dom(element); + pde.insertBefore(svg, pde.childNodes[0]); + return element._svgIcon = svg; + } + return null; + }, + + /** + * Remove an icon from the given element by undoing the changes effected + * by `applyIcon`. + * + * @param {Element} element The element from which the icon is removed. + */ + removeIcon: function(element) { + // Remove old svg element + if (element._svgIcon) { + Polymer.dom(element).removeChild(element._svgIcon); + element._svgIcon = null; + } + }, + + /** + * + * When name is changed, either register a new iconset with the included + * icons, or if there are no children, set up a meta-iconset. + * + */ + _nameChanged: function() { + new Polymer.IronMeta({type: 'iconset', key: this.name, value: this}); + // icons (descendents) must exist a-priori + this._icons = this._createIconMap(); + this.iconNames = this._getIconNames(); + }, + + /** + * Array of all icon names in this iconset. + * + * @return {!Array} Array of icon names. + */ + _getIconNames: function() { + return Object.keys(this._icons).map(function(n) { + return this.name + ':' + n; + }, this); + }, + + /** + * Create a map of child SVG elements by id. + * + * @return {Object} Map of id's to SVG elements. + */ + _createIconMap: function() { + // Objects chained to Object.prototype (`{}`) have members. Specifically, + // on FF there is a `watch` method that confuses the icon map, so we + // need to use a null-based object here. + var icons = Object.create(null); + Polymer.dom(this).querySelectorAll('[id]') + .forEach(function(icon) { + icons[icon.id] = icon; + }); + return icons; + }, + + /** + * Produce installable clone of the SVG element matching `id` in this + * iconset, or `undefined` if there is no matching element. + * + * @return {Element} Returns an installable clone of the SVG element + * matching `id`. + */ + _cloneIcon: function(id) { + return this._prepareSvgClone(this._icons[id], this.size); + }, + + /** + * @param {Element} sourceSvg + * @param {number} size + * @return {Element} + */ + _prepareSvgClone: function(sourceSvg, size) { + if (sourceSvg) { + var svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg'); + svg.setAttribute('viewBox', ['0', '0', size, size].join(' ')); + svg.setAttribute('preserveAspectRatio', 'xMidYMid meet'); + // TODO(dfreedm): `pointer-events: none` works around https://crbug.com/370136 + // TODO(sjmiles): inline style may not be ideal, but avoids requiring a shadow-root + svg.style.cssText = 'pointer-events: none; display: block; width: 100%; height: 100%;'; + svg.appendChild(sourceSvg.cloneNode(true)).removeAttribute('id'); + return svg; + } + return null; + } + + }); diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/iron-iconset-svg.html b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/iron-iconset-svg.html new file mode 100644 index 0000000..777f355 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset-svg/iron-iconset-svg.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +</head><body><script src="iron-iconset-svg-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-iconset/.bower.json new file mode 100644 index 0000000..e4ecbfa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/.bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-iconset", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Represents a set of icons", + "authors": [ + "The Polymer Authors" + ], + "private": true, + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-iconset", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "3ce6be6b689dd8e309410b0c30d7be23a493a880" + }, + "_source": "git://github.com/PolymerElements/iron-iconset.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-iconset" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-iconset/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/README.md b/third_party/polymer/v1_0/components-chromium/iron-iconset/README.md new file mode 100644 index 0000000..53a245b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/README.md @@ -0,0 +1,51 @@ +iron-iconset +============ + +The `iron-iconset` element allows users to define their own icon sets. +The `src` property specifies the url of the icon image. Multiple icons may +be included in this image and they may be organized into rows. +The `icons` property is a space separated list of names corresponding to the +icons. The names must be ordered as the icons are ordered in the icon image. +Icons are expected to be square and are the size specified by the `size` +property. The `width` property corresponds to the width of the icon image +and must be specified if icons are arranged into multiple rows in the image. + +All `iron-iconset` elements are available for use by other `iron-iconset` +elements via a database keyed by id. Typically, an element author that wants +to support a set of custom icons uses a `iron-iconset` to retrieve +and use another, user-defined iconset. + +Example: + +```html +<iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> +</iron-iconset> +``` + +This will automatically register the icon set "my-icons" to the iconset +database. To use these icons from within another element, make a +`iron-iconset` element and call the `byId` method to retrieve a +given iconset. To apply a particular icon to an element, use the +`applyIcon` method. For example: + +```javascript +iconset.applyIcon(iconNode, 'car'); +``` + +Themed icon sets are also supported. The `iron-iconset` can contain child +`property` elements that specify a theme with an offsetX and offsetY of the +theme within the icon resource. For example. + +```html +<iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> + <property theme="special" offsetX="256" offsetY="24"></property> +</iron-iconset> +``` + +Then a themed icon can be applied like this: + +```javascript +iconset.applyIcon(iconNode, 'car', 'special'); +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/bower.json b/third_party/polymer/v1_0/components-chromium/iron-iconset/bower.json new file mode 100644 index 0000000..8766bf3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/bower.json @@ -0,0 +1,21 @@ +{ + "name": "iron-iconset", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Represents a set of icons", + "authors": [ + "The Polymer Authors" + ], + "private": true, + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/index.html b/third_party/polymer/v1_0/components-chromium/iron-iconset/index.html new file mode 100644 index 0000000..64e80d5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-iconset</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/iron-iconset-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-iconset/iron-iconset-extracted.js new file mode 100644 index 0000000..de3dbec --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/iron-iconset-extracted.js @@ -0,0 +1,277 @@ + + + Polymer({ + + is: 'iron-iconset', + + properties: { + + /** + * The URL of the iconset image. + * + * @attribute src + * @type string + * @default '' + */ + src: { + type: String, + observer: '_srcChanged' + }, + + /** + * The name of the iconset. + * + * @attribute name + * @type string + * @default 'no-name' + */ + name: { + type: String, + observer: '_nameChanged' + }, + + /** + * The width of the iconset image. This must only be specified if the + * icons are arranged into separate rows inside the image. + * + * @attribute width + * @type number + * @default 0 + */ + width: { + type: Number, + value: 0 + }, + + /** + * A space separated list of names corresponding to icons in the iconset + * image file. This list must be ordered the same as the icon images + * in the image file. + * + * @attribute icons + * @type string + * @default '' + */ + icons: { + type: String + }, + + /** + * The size of an individual icon. Note that icons must be square. + * + * @attribute size + * @type number + * @default 24 + */ + size: { + type: Number, + value: 24 + }, + + /** + * The horizontal offset of the icon images in the inconset src image. + * This is typically used if the image resource contains additional images + * beside those intended for the iconset. + * + * @attribute offset-x + * @type number + * @default 0 + */ + _offsetX: { + type: Number, + value: 0 + }, + + /** + * The vertical offset of the icon images in the inconset src image. + * This is typically used if the image resource contains additional images + * beside those intended for the iconset. + * + * @attribute offset-y + * @type number + * @default 0 + */ + _offsetY: { + type: Number, + value: 0 + }, + + /** + * Array of fully-qualified names of icons in this set. + */ + iconNames: { + type: Array, + notify: true + } + + }, + + hostAttributes: { + // non-visual + style: 'display: none;' + }, + + ready: function() { + // theme data must exist at ready-time + this._themes = this._mapThemes(); + }, + + /** + * Applies an icon to the given element as a css background image. This + * method does not size the element, and it's usually necessary to set + * the element's height and width so that the background image is visible. + * + * @method applyIcon + * @param {Element} element The element to which the icon is applied. + * @param {String|Number} icon The name or index of the icon to apply. + * @param {String} theme (optional) The name or index of the icon to apply. + * @param {Number} scale (optional, defaults to 1) Icon scaling factor. + * @return {Element} The applied icon element. + */ + applyIcon: function(element, icon, theme, scale) { + this._validateIconMap(); + var offset = this._getThemedOffset(icon, theme); + if (element && offset) { + this._addIconStyles(element, this._srcUrl, offset, scale || 1, + this.size, this.width); + } + }, + + /** + * Remove an icon from the given element by undoing the changes effected + * by `applyIcon`. + * + * @param {Element} element The element from which the icon is removed. + */ + removeIcon: function(element) { + this._removeIconStyles(element.style); + }, + + _mapThemes: function() { + var themes = Object.create(null); + Polymer.dom(this).querySelectorAll('property[theme]') + .forEach(function(property) { + var offsetX = window.parseInt( + property.getAttribute('offset-x'), 10 + ) || 0; + var offsetY = window.parseInt( + property.getAttribute('offset-y'), 10 + ) || 0; + themes[property.getAttribute('theme')] = { + offsetX: offsetX, + offsetY: offsetY + }; + }); + return themes; + }, + + _srcChanged: function(src) { + // ensure `srcUrl` is always relative to the main document + this._srcUrl = this.ownerDocument !== document + ? this.resolveUrl(src) : src; + this._prepareIconset(); + }, + + _nameChanged: function(name) { + this._prepareIconset(); + }, + + _prepareIconset: function() { + new Polymer.IronMeta({type: 'iconset', key: this.name, value: this}); + }, + + _invalidateIconMap: function() { + this._iconMapValid = false; + }, + + _validateIconMap: function() { + if (!this._iconMapValid) { + this._recomputeIconMap(); + this._iconMapValid = true; + } + }, + + _recomputeIconMap: function() { + this.iconNames = this._computeIconNames(this.icons); + this.iconMap = this._computeIconMap(this._offsetX, this._offsetY, + this.size, this.width, this.iconNames); + }, + + _computeIconNames: function(icons) { + return icons.split(/\s+/g); + }, + + _computeIconMap: function(offsetX, offsetY, size, width, iconNames) { + var iconMap = {}; + if (offsetX !== undefined && offsetY !== undefined) { + var x0 = offsetX; + iconNames.forEach(function(iconName) { + iconMap[iconName] = { + offsetX: offsetX, + offsetY: offsetY + }; + if ((offsetX + size) < width) { + offsetX += size; + } else { + offsetX = x0; + offsetY += size; + } + }, this); + } + return iconMap; + }, + + /** + * Returns an object containing `offsetX` and `offsetY` properties which + * specify the pixel location in the iconset's src file for the given + * `icon` and `theme`. It's uncommon to call this method. It is useful, + * for example, to manually position a css backgroundImage to the proper + * offset. It's more common to use the `applyIcon` method. + * + * @method getThemedOffset + * @param {String|Number} identifier The name of the icon or the index of + * the icon within in the icon image. + * @param {String} theme The name of the theme. + * @returns {Object} An object specifying the offset of the given icon + * within the icon resource file; `offsetX` is the horizontal offset and + * `offsetY` is the vertical offset. Both values are in pixel units. + */ + _getThemedOffset: function(identifier, theme) { + var iconOffset = this._getIconOffset(identifier); + var themeOffset = this._themes[theme]; + if (iconOffset && themeOffset) { + return { + offsetX: iconOffset.offsetX + themeOffset.offsetX, + offsetY: iconOffset.offsetY + themeOffset.offsetY + }; + } + return iconOffset; + }, + + _getIconOffset: function(identifier) { + // TODO(sjmiles): consider creating offsetArray (indexed by Number) + // and having iconMap map names to indices, then and index is just + // iconMap[identifier] || identifier (be careful of zero, store indices + // as 1-based) + return this.iconMap[identifier] || + this.iconMap[this.iconNames[Number(identifier)]]; + }, + + _addIconStyles: function(element, url, offset, scale, size, width) { + var style = element.style; + style.backgroundImage = 'url(' + url + ')'; + style.backgroundPosition = + (-offset.offsetX * scale + 'px') + ' ' + + (-offset.offsetY * scale + 'px'); + style.backgroundSize = (scale === 1) ? 'auto' : width * scale + 'px'; + style.width = size + 'px'; + style.height = size + 'px'; + element.setAttribute('role', 'img'); + }, + + _removeIconStyles: function(style) { + style.background = ''; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-iconset/iron-iconset.html b/third_party/polymer/v1_0/components-chromium/iron-iconset/iron-iconset.html new file mode 100644 index 0000000..8e1dc83 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-iconset/iron-iconset.html @@ -0,0 +1,57 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +<!-- +The `iron-iconset` element allows users to define their own icon sets. +The `src` property specifies the url of the icon image. Multiple icons may +be included in this image and they may be organized into rows. +The `icons` property is a space separated list of names corresponding to the +icons. The names must be ordered as the icons are ordered in the icon image. +Icons are expected to be square and are the size specified by the `size` +property. The `width` property corresponds to the width of the icon image +and must be specified if icons are arranged into multiple rows in the image. + +All `iron-iconset` elements are available for use by other `iron-iconset` +elements via a database keyed by id. Typically, an element author that wants +to support a set of custom icons uses a `iron-iconset` to retrieve +and use another, user-defined iconset. + +Example: + + <iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> + </iron-iconset> + +This will automatically register the icon set "my-icons" to the iconset +database. To use these icons from within another element, make a +`iron-iconset` element and call the `byId` method to retrieve a +given iconset. To apply a particular icon to an element, use the +`applyIcon` method. For example: + + iconset.applyIcon(iconNode, 'car'); + +Themed icon sets are also supported. The `iron-iconset` can contain child +`property` elements that specify a theme with an offsetX and offsetY of the +theme within the icon resource. For example. + + <iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> + <property theme="special" offsetX="256" offsetY="24"></property> + </iron-iconset> + +Then a themed icon can be applied like this: + + iconset.applyIcon(iconNode, 'car', 'special'); + +@element iron-iconset +--> + +</head><body><script src="iron-iconset-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-image/.bower.json new file mode 100644 index 0000000..3e2ce06 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/.bower.json @@ -0,0 +1,35 @@ +{ + "name": "iron-image", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An image-displaying element with lots of convenient features", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-image", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "b2a3ef4c558b91a3f9a897f2d0b4c961a220a325" + }, + "_source": "git://github.com/PolymerElements/iron-image.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-image" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-image/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/README.md b/third_party/polymer/v1_0/components-chromium/iron-image/README.md new file mode 100644 index 0000000..04fda7a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/README.md @@ -0,0 +1,60 @@ +iron-image +========== + +`iron-image` is an element for displaying an image that provides useful sizing and +preloading options not found on the standard `<img>` tag. + +The `sizing` option allows the image to be either cropped (`cover`) or +letterboxed (`contain`) to fill a fixed user-size placed on the element. + +The `preload` option prevents the browser from rendering the image until the +image is fully loaded. In the interim, either the element's CSS `background-color` +can be be used as the placeholder, or the `placeholder` property can be +set to a URL (preferably a data-URI, for instant rendering) for an +placeholder image. + +The `fade` option (only valid when `preload` is set) will cause the placeholder +image/color to be faded out once the image is rendered. + +Examples: + +Basically identical to `<img src="...">` tag: + +```html +<iron-image src="http://lorempixel.com/400/400"></iron-image> +``` + +Will letterbox the image to fit: + +```html +<iron-image style="width:400px; height:400px;" sizing="contain" + src="http://lorempixel.com/600/400"></iron-image> +``` + +Will crop the image to fit: + +```html +<iron-image style="width:400px; height:400px;" sizing="cover" + src="http://lorempixel.com/600/400"></iron-image> +``` + +Will show light-gray background until the image loads: + +```html +<iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> +``` + +Will show a base-64 encoded placeholder image until the image loads: + +```html +<iron-image style="width:400px; height:400px;" placeholder="data:image/gif;base64,..." + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> +``` + +Will fade the light-gray background out once the image is loaded: + +```html +<iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload fade src="http://lorempixel.com/600/400"></iron-image> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/bower.json b/third_party/polymer/v1_0/components-chromium/iron-image/bower.json new file mode 100644 index 0000000..6e1d418 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/bower.json @@ -0,0 +1,25 @@ +{ + "name": "iron-image", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An image-displaying element with lots of convenient features", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/index.html b/third_party/polymer/v1_0/components-chromium/iron-image/index.html new file mode 100644 index 0000000..b12d417 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-image</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/iron-image-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-image/iron-image-extracted.js new file mode 100644 index 0000000..c9db9e1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/iron-image-extracted.js @@ -0,0 +1,291 @@ + + + Polymer({ + + is: 'iron-image', + + properties: { + /** + * The URL of an image. + * + * @attribute src + * @type string + * @default '' + */ + src: { + observer: '_srcChanged', + type: String, + value: '' + }, + + /** + * When true, the image is prevented from loading and any placeholder is + * shown. This may be useful when a binding to the src property is known to + * be invalid, to prevent 404 requests. + * + * @attribute preventLoad + * @type boolean + * @default false + */ + preventLoad: { + type: Boolean, + value: false + }, + + /** + * Sets a sizing option for the image. Valid values are `contain` (full + * aspect ratio of the image is contained within the element and + * letterboxed) or `cover` (image is cropped in order to fully cover the + * bounds of the element), or `null` (default: image takes natural size). + * + * @attribute sizing + * @type string + * @default null + */ + sizing: { + type: String, + value: null + }, + + /** + * When a sizing option is uzed (`cover` or `contain`), this determines + * how the image is aligned within the element bounds. + * + * @attribute position + * @type string + * @default 'center' + */ + position: { + type: String, + value: 'center' + }, + + /** + * When `true`, any change to the `src` property will cause the `placeholder` + * image to be shown until the + * + * @attribute preload + * @type boolean + * @default false + */ + preload: { + type: Boolean, + value: false + }, + + /** + * This image will be used as a background/placeholder until the src image has + * loaded. Use of a data-URI for placeholder is encouraged for instant rendering. + * + * @attribute placeholder + * @type string + * @default null + */ + placeholder: { + type: String, + value: null + }, + + /** + * When `preload` is true, setting `fade` to true will cause the image to + * fade into place. + * + * @attribute fade + * @type boolean + * @default false + */ + fade: { + type: Boolean, + value: false + }, + + /** + * Read-only value that is true when the image is loaded. + * + * @attribute preloaded + * @type boolean + * @default false + */ + loaded: { + notify: true, + type: Boolean, + value: false + }, + + /** + * Read-only value that tracks the loading state of the image when the `preload` + * option is used. + * + * @attribute loading + * @type boolean + * @default false + */ + loading: { + notify: true, + type: Boolean, + value: false + }, + + /** + * Can be used to set the width of image (e.g. via binding); size may also be + * set via CSS. + * + * @attribute width + * @type number + * @default null + */ + width: { + observer: '_widthChanged', + type: Number, + value: null + }, + + /** + * Can be used to set the height of image (e.g. via binding); size may also be + * set via CSS. + * + * @attribute height + * @type number + * @default null + */ + height: { + observer: '_heightChanged', + type: Number, + value: null + }, + + _placeholderBackgroundUrl: { + type: String, + computed: '_computePlaceholderBackgroundUrl(preload,placeholder)', + observer: '_placeholderBackgroundUrlChanged' + }, + + requiresPreload: { + type: Boolean, + computed: '_computeRequiresPreload(preload,loaded)' + }, + + canLoad: { + type: Boolean, + computed: '_computeCanLoad(preventLoad, src)' + } + + }, + + observers: [ + '_transformChanged(sizing, position)', + '_loadBehaviorChanged(canLoad, preload, loaded)', + '_loadStateChanged(src, preload, loaded)', + ], + + ready: function() { + if (!this.hasAttribute('role')) { + this.setAttribute('role', 'img'); + } + }, + + _computeImageVisibility: function() { + return !!this.sizing; + }, + + _computePlaceholderVisibility: function() { + return !this.preload || (this.loaded && !this.fade); + }, + + _computePlaceholderClassName: function() { + if (!this.preload) { + return ''; + } + + var className = 'fit'; + if (this.loaded && this.fade) { + className += ' faded-out'; + } + return className; + }, + + _computePlaceholderBackgroundUrl: function() { + if (this.preload && this.placeholder) { + return 'url(' + this.placeholder + ')'; + } + + return null; + }, + + _computeRequiresPreload: function() { + return this.preload && !this.loaded; + }, + + _computeCanLoad: function() { + return Boolean(!this.preventLoad && this.src); + }, + + _widthChanged: function() { + this.style.width = isNaN(this.width) ? this.width : this.width + 'px'; + }, + + _heightChanged: function() { + this.style.height = isNaN(this.height) ? this.height : this.height + 'px'; + }, + + _srcChanged: function(newSrc, oldSrc) { + if (newSrc !== oldSrc) { + this.loaded = false; + } + }, + + _placeholderBackgroundUrlChanged: function() { + this.$.placeholder.style.backgroundImage = + this._placeholderBackgroundUrl; + }, + + _transformChanged: function() { + var placeholderStyle = this.$.placeholder.style; + + this.style.backgroundSize = + placeholderStyle.backgroundSize = this.sizing; + + this.style.backgroundPosition = + placeholderStyle.backgroundPosition = + this.sizing ? this.position : null; + + this.style.backgroundRepeat = + placeholderStyle.backgroundRepeat = + this.sizing ? 'no-repeat' : null; + }, + + _loadBehaviorChanged: function() { + var img; + + if (!this.canLoad) { + return; + } + + if (this.requiresPreload) { + img = new Image(); + img.src = this.src; + + this.loading = true; + + img.onload = function() { + this.loading = false; + this.loaded = true; + }.bind(this); + } else { + this.loaded = true; + } + }, + + _loadStateChanged: function() { + if (this.requiresPreload) { + return; + } + + if (this.sizing) { + this.style.backgroundImage = this.src ? 'url(' + this.src + ')': ''; + } else { + this.$.img.src = this.src || ''; + } + } + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-image/iron-image.html b/third_party/polymer/v1_0/components-chromium/iron-image/iron-image.html new file mode 100644 index 0000000..b284ed0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-image/iron-image.html @@ -0,0 +1,101 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<!-- +`iron-image` is an element for displaying an image that provides useful sizing and +preloading options not found on the standard `<img>` tag. + +The `sizing` option allows the image to be either cropped (`cover`) or +letterboxed (`contain`) to fill a fixed user-size placed on the element. + +The `preload` option prevents the browser from rendering the image until the +image is fully loaded. In the interim, either the element's CSS `background-color` +can be be used as the placeholder, or the `placeholder` property can be +set to a URL (preferably a data-URI, for instant rendering) for an +placeholder image. + +The `fade` option (only valid when `preload` is set) will cause the placeholder +image/color to be faded out once the image is rendered. + +Examples: + + Basically identical to <img src="..."> tag: + + <iron-image src="http://lorempixel.com/400/400"></iron-image> + + Will letterbox the image to fit: + + <iron-image style="width:400px; height:400px;" sizing="contain" + src="http://lorempixel.com/600/400"></iron-image> + + Will crop the image to fit: + + <iron-image style="width:400px; height:400px;" sizing="cover" + src="http://lorempixel.com/600/400"></iron-image> + + Will show light-gray background until the image loads: + + <iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> + + Will show a base-64 encoded placeholder image until the image loads: + + <iron-image style="width:400px; height:400px;" placeholder="data:image/gif;base64,..." + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> + + Will fade the light-gray background out once the image is loaded: + + <iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload fade src="http://lorempixel.com/600/400"></iron-image> + + +@group Iron Elements +@element iron-image +@demo demo/index.html +--> + +</head><body><dom-module id="iron-image"> + + <style> + + :host { + display: inline-block; + overflow: hidden; + position: relative; + } + + :host([sizing]) #img { + display: none; + } + + #placeholder { + background-color: inherit; + opacity: 1; + } + + #placeholder.faded-out { + transition: opacity 0.5s linear; + opacity: 0; + } + + </style> + + <template> + + <img id="img" role="none" hidden$="[[_computeImageVisibility(sizing)]]"> + <div id="placeholder" hidden$="[[_computePlaceholderVisibility(fade,loaded,preload)]]" class$="[[_computePlaceholderClassName(fade,loaded,preload)]]"></div> + <content></content> + + </template> + +</dom-module> + +<script src="iron-image-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-input/.bower.json new file mode 100644 index 0000000..5120860c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "iron-input", + "version": "1.0.1", + "description": "An input element with data binding", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "iron-input.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-input", + "ignore": [], + "dependencies": { + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "f54d4945cf96ede414904055547fd4c46dc0c053" + }, + "_source": "git://github.com/PolymerElements/iron-input.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-input" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-input/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/README.md b/third_party/polymer/v1_0/components-chromium/iron-input/README.md new file mode 100644 index 0000000..05a74b7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/README.md @@ -0,0 +1,16 @@ +# iron-input + +An input with data binding. + +By default you can only get notified of changes to an `input`'s `value` due to user input: + +```html +<input value="{{myValue::input}}"> +``` + +`iron-input` adds the `bind-value` property that mirrors the `value` property, and can be used +for two-way data binding. `bind-value` will notify if it is changed either by user input or by script. + +```html +<input is="iron-input" bind-value="{{myValue}}"> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/bower.json b/third_party/polymer/v1_0/components-chromium/iron-input/bower.json new file mode 100644 index 0000000..15142ba --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/bower.json @@ -0,0 +1,35 @@ +{ + "name": "iron-input", + "version": "1.0.1", + "description": "An input element with data binding", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "iron-input.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-input", + "ignore": [], + "dependencies": { + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-input/hero.svg new file mode 100644 index 0000000..146ffea --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/hero.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <rect x="49" y="53" width="2" height="18"/> + <path d="M188,78H37V44h151V78z M39,76h147V46H39V76z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/index.html b/third_party/polymer/v1_0/components-chromium/iron-input/index.html new file mode 100644 index 0000000..ca0dac0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-input</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/iron-input-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-input/iron-input-extracted.js new file mode 100644 index 0000000..4e9067a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/iron-input-extracted.js @@ -0,0 +1,174 @@ + + +/* +`<iron-input>` adds two-way binding and custom validators using `Polymer.IronValidatorBehavior` +to `<input>`. + +### Two-way binding + +By default you can only get notified of changes to an `input`'s `value` due to user input: + + <input value="{{myValue::input}}"> + +`iron-input` adds the `bind-value` property that mirrors the `value` property, and can be used +for two-way data binding. `bind-value` will notify if it is changed either by user input or by script. + + <input is="iron-input" bind-value="{{myValue}}"> + +### Custom validators + +You can use custom validators that implement `Polymer.IronValidatorBehavior` with `<iron-input>`. + + <input is="iron-input" validator="my-custom-validator"> + +### Stopping invalid input + +It may be desirable to only allow users to enter certain characters. You can use the +`prevent-invalid-input` and `allowed-pattern` attributes together to accomplish this. This feature +is separate from validation, and `allowed-pattern` does not affect how the input is validated. + + <!-- only allow characters that match [0-9] --> + <input is="iron-input" prevent-invaild-input allowed-pattern="[0-9]"> + +@hero hero.svg +@demo demo/index.html +*/ + + Polymer({ + + is: 'iron-input', + + extends: 'input', + + behaviors: [ + Polymer.IronValidatableBehavior + ], + + properties: { + + /** + * Use this property instead of `value` for two-way data binding. + */ + bindValue: { + observer: '_bindValueChanged', + type: String + }, + + /** + * Set to true to prevent the user from entering invalid input. The new input characters are + * matched with `allowedPattern` if it is set, otherwise it will use the `pattern` attribute if + * set, or the `type` attribute (only supported for `type=number`). + */ + preventInvalidInput: { + type: Boolean + }, + + /** + * Regular expression to match valid input characters. + */ + allowedPattern: { + type: String + }, + + _previousValidInput: { + type: String, + value: '' + } + + }, + + listeners: { + 'input': '_onInput', + 'keydown': '_onKeydown' + }, + + get _patternRegExp() { + var pattern; + if (this.allowedPattern) { + pattern = new RegExp(this.allowedPattern); + } else if (this.pattern) { + pattern = new RegExp(this.pattern); + } else { + switch (this.type) { + case 'number': + pattern = /[0-9.,e-]/; + break; + } + } + return pattern; + }, + + ready: function() { + this.bindValue = this.value; + }, + + _bindValueChanged: function() { + if (this.value !== this.bindValue) { + this.value = this.bindValue; + } + // manually notify because we don't want to notify until after setting value + this.fire('bind-value-changed', {value: this.bindValue}); + }, + + _onInput: function() { + this.bindValue = this.value; + }, + + _isPrintable: function(keyCode) { + var printable = + (keyCode > 47 && keyCode < 58) || // number keys + keyCode == 32 || keyCode == 13 || // spacebar & return key + (keyCode > 64 && keyCode < 91) || // letter keys + (keyCode > 95 && keyCode < 112) || // numpad keys + (keyCode > 185 && keyCode < 193) || // ;=,-./` (in order) + (keyCode > 218 && keyCode < 223); // [\]' (in order) + return printable; + }, + + // convert printable numpad keys to number keys + _correctNumpadKeys: function(keyCode) { + return (keyCode > 95 && keyCode < 112) ? keyCode - 48 : keyCode; + }, + + _onKeydown: function(event) { + if (!this.preventInvalidInput && this.type !== 'number') { + return; + } + var regexp = this._patternRegExp; + if (!regexp) { + return; + } + var thisChar = String.fromCharCode(this._correctNumpadKeys(event.keyCode)); + if (this._isPrintable(event.keyCode) && !regexp.test(thisChar)) { + event.preventDefault(); + } + }, + + /** + * Returns true if `value` is valid. The validator provided in `validator` will be used first, + * then any constraints. + * @return {Boolean} True if the value is valid. + */ + validate: function() { + // Empty, non-required input is valid. + if (!this.required && this.value == '') + return true; + + var valid; + if (this.hasValidator()) { + valid = Polymer.IronValidatableBehavior.validate.call(this, this.value); + } else { + this.invalid = !this.validity.valid; + valid = this.validity.valid; + } + this.fire('iron-input-validate'); + return valid; + } + + }); + + /* + The `iron-input-validate` event is fired whenever `validate()` is called. + @event iron-input-validate + */ + diff --git a/third_party/polymer/v1_0/components-chromium/iron-input/iron-input.html b/third_party/polymer/v1_0/components-chromium/iron-input/iron-input.html new file mode 100644 index 0000000..52cead0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-input/iron-input.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-validatable-behavior/iron-validatable-behavior.html"> + +</head><body><script src="iron-input-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/.bower.json new file mode 100644 index 0000000..31660e4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "iron-jsonp-library", + "version": "1.0.0", + "description": "Loads jsonp libraries", + "authors": [ + "Aleks Totic <a@totic.org>", + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "behavior" + ], + "main": "iron-jsonp-library.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-jsonp-library/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "2957a77f8797e59f2cd97a61b9844c4f7a716f19" + }, + "_source": "git://github.com/PolymerElements/iron-jsonp-library.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-jsonp-library" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/README.md b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/README.md new file mode 100644 index 0000000..d1b3206 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/README.md @@ -0,0 +1,10 @@ +# iron-jsonp-library + +`Polymer.IronJsonpLibraryBehavior` loads a jsonp library. +Multiple components can request same library, only one copy will load. + +Some libraries require a specific global function be defined. +If this is the case, specify the `callbackName` property. + +You should use an HTML Import to load library dependencies +when possible instead of using this element. diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/bower.json b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/bower.json new file mode 100644 index 0000000..7f865fe --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-jsonp-library", + "version": "1.0.0", + "description": "Loads jsonp libraries", + "authors": [ + "Aleks Totic <a@totic.org>", + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "behavior" + ], + "main": "iron-jsonp-library.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-jsonp-library/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/hero.svg new file mode 100644 index 0000000..d6c1c13 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/hero.svg @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="112" cy="36" r="4"/> + <circle cx="112" cy="90" r="4"/> + <circle cx="91" cy="98" r="4"/> + <circle cx="91" cy="29" r="4"/> + <circle cx="133" cy="29" r="4"/> + <circle cx="133" cy="97" r="4"/> + <circle cx="56" cy="63" r="4"/> + <circle cx="168" cy="63" r="4"/> + <circle cx="99" cy="63" r="4"/> + <circle cx="125" cy="63" r="4"/> + <path d="M90.8,98.5c-19.6,0-35.5-15.9-35.5-35.5s15.9-35.5,35.5-35.5s35.5,15.9,35.5,35.5S110.3,98.5,90.8,98.5z M90.8,29.5 + c-18.5,0-33.5,15-33.5,33.5s15,33.5,33.5,33.5s33.5-15,33.5-33.5S109.2,29.5,90.8,29.5z"/> + <path d="M133.2,98.5c-19.6,0-35.5-15.9-35.5-35.5s15.9-35.5,35.5-35.5s35.5,15.9,35.5,35.5S152.8,98.5,133.2,98.5z M133.2,29.5 + c-18.5,0-33.5,15-33.5,33.5s15,33.5,33.5,33.5s33.5-15,33.5-33.5S151.7,29.5,133.2,29.5z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/index.html b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/index.html new file mode 100644 index 0000000..487bb5c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/iron-jsonp-library-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/iron-jsonp-library-extracted.js new file mode 100644 index 0000000..210f6a3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/iron-jsonp-library-extracted.js @@ -0,0 +1,227 @@ + +(function() { + "use strict"; + /** + `Polymer.IronJsonpLibraryBehavior` loads a jsonp library. + Multiple components can request same library, only one copy will load. + + Some libraries require a specific global function be defined. + If this is the case, specify the `callbackName` property. + + You should use an HTML Import to load library dependencies + when possible instead of using this element. + + @hero hero.svg + @polymerBehavior + */ + Polymer.IronJsonpLibraryBehavior = { + + properties: { + /** + * True if library has been successfully loaded + */ + libraryLoaded: { + type: Boolean, + value: false, + notify: true, + readOnly: true + }, + /** + * Not null if library has failed to load + */ + libraryErrorMessage: { + type: String, + value: null, + notify: true, + readOnly: true + } + // Following properties are to be set by behavior users + /** + * Library url. Must contain string `%%callback_name%%`. + * + * `%%callback_name%%` is a placeholder for jsonp wrapper function name + * + * Ex: https://maps.googleapis.com/maps/api/js?callback=%%callback%% + * @property libraryUrl + */ + /** + * Set if library requires specific callback name. + * Name will be automatically generated if not set. + * @property callbackName + */ + /** + * name of event to be emitted when library loads. Standard is `api-load` + * @property notifyEvent + */ + /** + * event with name specified in `notifyEvent` attribute + * will fire upon successful load2 + * @event `notifyEvent` + */ + }, + + _libraryLoadCallback: function(err, result) { + if (err) { + console.warn("Library load failed:", err.message); + this._setLibraryErrorMessage(err.message); + } + else { + this._setLibraryErrorMessage(null); + this._setLibraryLoaded(true); + if (this.notifyEvent) + this.fire( this.notifyEvent, result); + } + }, + + /** loads the library, and fires this.notifyEvent upon completion */ + _loadLibrary: function() { + LoaderMap.require( + this.libraryUrl, + this._libraryLoadCallback.bind(this), + this.callbackName + ); + }, + + ready: function() { + this._loadLibrary(); + } + }; + + /* + * LoaderMap keeps track of all Loaders + */ + var LoaderMap = { + apiMap: {}, // { hash -> Loader } + + /* + * @param {function} notifyCallback loaded callback fn(result) + * @param {string} jsonpCallbackName name of jsonpcallback. If API does not provide it, leave empty. Optional. + */ + require: function(url, notifyCallback, jsonpCallbackName) { + + // make hashable string form url + var name = this.nameFromUrl(url); + + // create a loader as needed + if (!this.apiMap[name]) + this.apiMap[name] = new Loader(name, url, jsonpCallbackName); + + // ask for notification + this.apiMap[name].requestNotify(notifyCallback); + }, + + nameFromUrl: function(url) { + return url.replace(/[\:\/\%\?\&\.\=\-\,]/g, '_') + '_api'; + } + }; + + var Loader = function(name, url, callbackName) { + this.notifiers = []; // array of notifyFn [ notifyFn* ] + + // callback is specified either as callback name + // or computed dynamically if url has callbackMacro in it + if (!callbackName) { + if (url.indexOf(this.callbackMacro) >= 0) { + callbackName = name + '_loaded'; + url = url.replace(this.callbackMacro, callbackName); + } else { + this.error = new Error('IronJsonpLibraryBehavior a %%callback_name%% parameter is required in libraryUrl'); + // TODO(sjmiles): we should probably fallback to listening to script.load + return; + } + } + this.callbackName = callbackName; + window[this.callbackName] = this.success.bind(this); + this.addScript(url); + }; + + Loader.prototype = { + + callbackMacro: '%%callback%%', + loaded: false, + + addScript: function(src) { + var script = document.createElement('script'); + script.src = src; + script.onerror = this.handleError.bind(this); + var s = document.querySelector('script') || document.body; + s.parentNode.insertBefore(script, s); + this.script = script; + }, + + removeScript: function() { + if (this.script.parentNode) { + this.script.parentNode.removeChild(this.script); + } + this.script = null; + }, + + handleError: function(ev) { + this.error = new Error("Library failed to load"); + this.notifyAll(); + this.cleanup(); + }, + + success: function() { + this.loaded = true; + this.result = Array.prototype.slice.call(arguments); + this.notifyAll(); + this.cleanup(); + }, + + cleanup: function() { + delete window[this.callbackName]; + }, + + notifyAll: function(notifyCallback) { + this.notifiers.forEach( function(notifyCallback) { + notifyCallback(this.error, this.result); + }.bind(this)); + this.notifiers = []; + }, + + requestNotify: function(notifyCallback) { + if (this.loaded || this.error) { + notifyCallback( this.error, this.result); + } else { + this.notifiers.push(notifyCallback); + } + } + }; +})(); + +; + Polymer({ + + is: 'iron-jsonp-library', + + behaviors: [ Polymer.IronJsonpLibraryBehavior ], + + properties: { + /** + * Library url. Must contain string `%%callback_name%%`. + * + * `%%callback_name%%` is a placeholder for jsonp wrapper function name + * + * Ex: https://maps.googleapis.com/maps/api/js?callback=%%callback%% + */ + libraryUrl: String, + /** + * Set if library requires specific callback name. + * Name will be automatically generated if not set. + */ + callbackName: String, + /** + * event with name specified in 'notifyEvent' attribute + * will fire upon successful load + */ + notifyEvent: String + /** + * event with name specified in 'notifyEvent' attribute + * will fire upon successful load + * @event `notifyEvent` + */ + + } + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/iron-jsonp-library.html b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/iron-jsonp-library.html new file mode 100644 index 0000000..7a734b6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-jsonp-library/iron-jsonp-library.html @@ -0,0 +1,28 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- + Loads specified jsonp library. + + Example: + + <iron-jsonp-library + library-url="https://apis.google.com/js/plusone.js?onload=%%callback%%" + notify-event="api-load" + library-loaded="{{loaded}}"></iron-jsonp-library> + + Will emit 'api-load' event when loaded, and set 'loaded' to true + + Implemented by Polymer.IronJsonpLibraryBehavior. Use it + to create specific library loader elements. + + @demo +--> +</head><body><script src="iron-jsonp-library-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-localstorage/.bower.json new file mode 100644 index 0000000..4e59d72 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/.bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-localstorage", + "version": "1.0.0", + "description": "Provides access to local storage", + "keywords": [ + "web-component", + "polymer", + "storage" + ], + "main": "iron-localstorage.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-localstorage/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "cecc6c2578287e779ffd76056cf5cf023799fc21" + }, + "_source": "git://github.com/PolymerElements/iron-localstorage.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-localstorage" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-localstorage/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/README.md b/third_party/polymer/v1_0/components-chromium/iron-localstorage/README.md new file mode 100644 index 0000000..f3e1acd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/README.md @@ -0,0 +1,13 @@ +iron-localstorage +================= + +Element access to localStorage. The "name" property +is the key to the data ("value" property) stored in localStorage. + +`iron-localstorage` automatically saves the value to localStorage when +value is changed. Note that if value is an object auto-save will be +triggered only when value is a different instance. + +```html +<iron-localstorage name="my-app-storage" value="{{value}}"></iron-localstorage> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/bower.json b/third_party/polymer/v1_0/components-chromium/iron-localstorage/bower.json new file mode 100644 index 0000000..95784b64a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/bower.json @@ -0,0 +1,22 @@ +{ + "name": "iron-localstorage", + "version": "1.0.0", + "description": "Provides access to local storage", + "keywords": [ + "web-component", + "polymer", + "storage" + ], + "main": "iron-localstorage.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-localstorage/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-localstorage/hero.svg new file mode 100644 index 0000000..0c0ec6b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/hero.svg @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M124,45.3c-0.5-0.6-4.7-1.6-12-1.6s-11.5,1.1-12,1.6c0,0,0.1-0.3,0.1-0.3h-2c0-3,10.7-3.4,14-3.4s14,0.4,14,3.4h-2 + C124,45,124,45.3,124,45.3z"/> + <path d="M112,83c-3.3,0-14-0.2-14-3.4l0-7.6l0-1.6l2,0c0-0.2-0.1-0.3-0.1-0.3c0.5,0.6,4.7,1.6,12,1.6s11.5-1.1,12-1.6 + c0,0-0.1,0.1-0.1,0.3l2,0l0,1.5l0,7.7C126,82.8,115.3,83,112,83z M100,79.4c0.8,0.6,4.9,1.6,12,1.6s11.2-1,12-1.6l0-7 + c-3.2,1.3-9.6,1.4-12,1.4c-2.4,0-8.8-0.1-12-1.4L100,79.4z"/> + <path d="M112,70c-3.3,0-14-0.2-14-3.4l0-7.6l0-1.6l2,0c0-0.2-0.1-0.3-0.1-0.3c0.5,0.6,4.7,1.6,12,1.6s11.5-1.1,12-1.6 + c0,0-0.1,0.1-0.1,0.3l2,0l0,1.5l0,7.7C126,69.8,115.3,70,112,70z M100,66.4c0.8,0.6,4.9,1.6,12,1.6s11.2-1,12-1.6l0-7 + c-3.2,1.3-9.6,1.4-12,1.4c-2.4,0-8.8-0.1-12-1.4L100,66.4z"/> + <path d="M112,57c-3.3,0-14-0.2-14-3.4l0-7.6l0-1.6l2,0c0-0.2-0.1-0.3-0.1-0.3c0.5,0.6,4.7,1.6,12,1.6s11.5-1.1,12-1.6 + c0,0-0.1,0.1-0.1,0.3l2,0l0,1.5l0,7.7C126,56.8,115.3,57,112,57z M100,53.4c0.8,0.6,4.9,1.6,12,1.6s11.2-1,12-1.6l0-7 + c-3.2,1.3-9.6,1.4-12,1.4c-2.4,0-8.8-0.1-12-1.4L100,53.4z"/> + <path d="M151,99H73V27h78V99z M75,97h74V29H75V97z"/> + <circle cx="74" cy="28" r="4"/> + <circle cx="150" cy="28" r="4"/> + <circle cx="150" cy="98" r="4"/> + <circle cx="74" cy="98" r="4"/> + <circle cx="113" cy="98" r="4"/> + <circle cx="113" cy="28" r="4"/> + <circle cx="74" cy="63" r="4"/> + <circle cx="150" cy="63" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/index.html b/third_party/polymer/v1_0/components-chromium/iron-localstorage/index.html new file mode 100644 index 0000000..246af10 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/index.html @@ -0,0 +1,23 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/iron-localstorage-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-localstorage/iron-localstorage-extracted.js new file mode 100644 index 0000000..86b5c50 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/iron-localstorage-extracted.js @@ -0,0 +1,155 @@ + + + Polymer({ + is: 'iron-localstorage', + + /** + * Fired when value loads from localStorage. + * + * @param {Object} detail + * @param {Boolean} detail.externalChange true if change occured in different window + * @event iron-localstorage-load + */ + + /** + * Fired when loaded value is null. + * You can use event handler to initialize default value. + * + * @event iron-localstorage-load-empty + */ + properties: { + /** + * The key to the data stored in localStorage. + */ + name: { + type: String, + value: '' + }, + /** + * The data associated with this storage. + * If value is set to null, and storage is in useRaw mode, item will be deleted + */ + value: { + type: Object, + notify: true + }, + + /** + * Value is stored and retrieved without JSON parse if true + */ + useRaw: { + type: Boolean, + value: false + }, + + /** + * Auto save is disabled if true. Default to false. + */ + autoSaveDisabled: { + type: Boolean, + value: false + }, + /** + * Last error encountered while saving/loading items. Null otherwise + */ + errorMessage: { + type: String, + notify: true + }, + /* + * True if value was loaded + */ + _loaded: { + type: Boolean, + value: false + } + }, + + observers: [ + 'reload(name,useRaw)', + '_trySaveValue(value, _loaded, autoSaveDisabled)' + ], + + ready: function() { + this._boundHandleStorage = this._handleStorage.bind(this); + }, + + attached: function() { + window.addEventListener('storage', this._boundHandleStorage); + }, + + detached: function() { + window.removeEventListener('storage', this._boundHandleStorage); + }, + + _handleStorage: function(ev) { + if (ev.key == this.name) { + this._load(true); + } + }, + + _trySaveValue: function(value, _loaded, autoSaveDisabled) { + if (this._justLoaded) { // guard against saving after _load() + this._justLoaded = false; + return; + } + if (_loaded && !autoSaveDisabled) { + this.save(); + } + }, + + /** + * Loads the value again. Use if you modify + * localStorage using DOM calls, and want to + * keep this element in sync. + */ + reload: function() { + this._load(); + }, + + /** + * loads value from local storage + * @param {Boolean} externalChange true if loading changes from a different window + */ + _load: function(externalChange) { + var v = localStorage.getItem(this.name); + + if (v === null) { + this.fire('iron-localstorage-load-empty'); + } else if (!this.useRaw) { + try { + v = JSON.parse(v); + } catch(x) { + this.errorMessage = "Could not parse local storage value"; + console.error("could not parse local storage value", v); + } + } + + this._justLoaded = true; + this._loaded = true; + this.value = v; + this.fire('iron-localstorage-load', { externalChange: externalChange}); + }, + + /** + * Saves the value to localStorage. Call to save if autoSaveDisabled is set. + * If `value` is null, deletes localStorage. + */ + save: function() { + var v = this.useRaw ? this.value : JSON.stringify(this.value); + try { + if (this.value === null) { + localStorage.removeItem(this.name); + } else { + localStorage.setItem(this.name, v); + } + } + catch(ex) { + // Happens in Safari incognito mode, + this.errorMessage = ex.message; + console.error("localStorage could not be saved. Safari incoginito mode?", ex); + } + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-localstorage/iron-localstorage.html b/third_party/polymer/v1_0/components-chromium/iron-localstorage/iron-localstorage.html new file mode 100644 index 0000000..c38d814 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-localstorage/iron-localstorage.html @@ -0,0 +1,39 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- +Element access to Web Storage API (window.localStorage). + +Keeps `value` is sync with a localStorage key. + +Direct assignments to `value` are automatically detected and saved. +Subproperty assignments are not (ex: `value.bar='foo'`). +Call `save()` manually to commit your changes after modifying subproperties. + +Value is saved in localStorage as JSON by default. + +If you set the value to null, storage key will be deleted. + + <iron-localstorage name="my-app-storage" value="{{value}}"> + </iron-localstorage> + + +<b>Warning</b>: do not pass subproperty bindings to iron-localstorage until Polymer +[bug 1550](https://github.com/Polymer/polymer/issues/1550) +is resolved. Local storage will be blown away. +No `<iron-localstorage value="{{foo.bar}}"`. + +@group Iron Elements +@demo demo/index.html +@hero hero.svg +@element iron-localstorage +--> +</head><body><dom-module id="iron-localstorage"></dom-module> +<script src="iron-localstorage-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-media-query/.bower.json new file mode 100644 index 0000000..7bc9132 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/.bower.json @@ -0,0 +1,39 @@ +{ + "name": "iron-media-query", + "version": "1.0.1", + "description": "Lets you bind to a CSS media query", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-media-query" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-media-query", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "655ba5a1b8f2d8c3e5d0c4053a4f18d6c4c6ac69" + }, + "_source": "git://github.com/PolymerElements/iron-media-query.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-media-query" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-media-query/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/README.md b/third_party/polymer/v1_0/components-chromium/iron-media-query/README.md new file mode 100644 index 0000000..3f1b91c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/README.md @@ -0,0 +1,11 @@ +# iron-media-query + +`iron-media-query` can be used to data bind to a CSS media query. +The `query` property is a bare CSS media query. +The `queryMatches` property is a boolean representing if the page matches that media query. + +Example: + +```html +<iron-media-query query="(min-width: 600px)" queryMatches="{{queryMatches}}"></iron-media-query> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/bower.json b/third_party/polymer/v1_0/components-chromium/iron-media-query/bower.json new file mode 100644 index 0000000..1c692e7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/bower.json @@ -0,0 +1,30 @@ +{ + "name": "iron-media-query", + "version": "1.0.1", + "description": "Lets you bind to a CSS media query", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-media-query" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-media-query", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-media-query/hero.svg new file mode 100644 index 0000000..9b5e2a6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/hero.svg @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M173,99H91V41h82V99z M93,97h78V43H93V97z"/> + <path d="M77,89H51V42h26V89z M53,87h22V44H53V87z"/> + <rect x="52" y="56" width="24" height="2"/> + <rect x="92" y="58" width="80" height="2"/> + <path d="M65.3,42h-2c0-10,8.7-18.7,18.7-18.7v2C73,25.3,65.3,33,65.3,42z"/> + <path d="M105.3,42h-2c0-9-7.3-16.7-16.3-16.7v-2C97,23.3,105.3,32,105.3,42z"/> + <circle cx="84.3" cy="24.3" r="4"/> + <circle cx="69.3" cy="80.3" r="4"/> + <circle cx="160.3" cy="59.3" r="4"/> + <path d="M49,41v49c0,1.1,0.9,2,2,2h26c1.1,0,2-0.9,2-2V41c0-1.1-0.9-2-2-2H51C49.9,39,49,39.9,49,41z M76,88H52V43h24V88z"/> + <path d="M88.9,40.7v59c0,1.1,0.9,2,2,2h82c1.1,0,2-0.9,2-2v-59c0-1.1-0.9-2-2-2h-82C89.8,38.7,88.9,39.6,88.9,40.7z M172,98H93V42 + h79V98z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/index.html b/third_party/polymer/v1_0/components-chromium/iron-media-query/index.html new file mode 100644 index 0000000..7aee5c1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-media-query</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/iron-media-query-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-media-query/iron-media-query-extracted.js new file mode 100644 index 0000000..6439d3a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/iron-media-query-extracted.js @@ -0,0 +1,57 @@ + + + Polymer({ + + is: 'iron-media-query', + + properties: { + + /** + * The Boolean return value of the media query. + * + * @attribute queryMatches + * @type Boolean + * @default false + */ + queryMatches: { + type: Boolean, + value: false, + readOnly: true, + notify: true + }, + + /** + * The CSS media query to evaluate. + * + * @attribute query + * @type String + */ + query: { + type: String, + observer: 'queryChanged' + } + + }, + + created: function() { + this._mqHandler = this.queryHandler.bind(this); + }, + + queryChanged: function(query) { + if (this._mq) { + this._mq.removeListener(this._mqHandler); + } + if (query[0] !== '(') { + query = '(' + query + ')'; + } + this._mq = window.matchMedia(query); + this._mq.addListener(this._mqHandler); + this.queryHandler(this._mq); + }, + + queryHandler: function(mq) { + this._setQueryMatches(mq.matches); + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-media-query/iron-media-query.html b/third_party/polymer/v1_0/components-chromium/iron-media-query/iron-media-query.html new file mode 100644 index 0000000..b3cd952 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-media-query/iron-media-query.html @@ -0,0 +1,25 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-media-query` can be used to data bind to a CSS media query. +The `query` property is a bare CSS media query. +The `queryMatches` property is a boolean representing if the page matches that media query. + +Example: + + <iron-media-query query="(min-width: 600px)" queryMatches="{{queryMatches}}"></iron-media-query> + +@group Iron Elements +@demo demo/index.html +@hero hero.svg +@element iron-media-query +--> + +</head><body><script src="iron-media-query-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/.bower.json new file mode 100644 index 0000000..7ca24d4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "iron-menu-behavior", + "version": "1.0.1", + "description": "Provides accessible menu behavior", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior", + "menu" + ], + "main": "iron-menu-behavior.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-menu-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-menu-behavior", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "3809f0eb7461c8ca63640aaa238775b3a25aa578" + }, + "_source": "git://github.com/PolymerElements/iron-menu-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-menu-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/README.md new file mode 100644 index 0000000..42ab7fa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/README.md @@ -0,0 +1,3 @@ +# iron-menu-behavior + +`Polymer.IronMenuBehavior` implements accessible menu behavior. diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/bower.json new file mode 100644 index 0000000..f0d453c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/bower.json @@ -0,0 +1,32 @@ +{ + "name": "iron-menu-behavior", + "version": "1.0.1", + "description": "Provides accessible menu behavior", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior", + "menu" + ], + "main": "iron-menu-behavior.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-menu-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-menu-behavior", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/index.html new file mode 100644 index 0000000..2c643c4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-menu-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="iron-menubar-behavior.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menu-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menu-behavior-extracted.js new file mode 100644 index 0000000..178de15 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menu-behavior-extracted.js @@ -0,0 +1,199 @@ + + + /** + * `Polymer.IronMenuBehavior` implements accessible menu behavior. + * + * @demo demo/index.html + * @polymerBehavior Polymer.IronMenuBehavior + */ + Polymer.IronMenuBehaviorImpl = { + + properties: { + + /** + * Returns the currently focused item. + * + * @attribute focusedItem + * @type Object + */ + focusedItem: { + observer: '_focusedItemChanged', + readOnly: true, + type: Object + }, + + /** + * The attribute to use on menu items to look up the item title. Typing the first + * letter of an item when the menu is open focuses that item. If unset, `textContent` + * will be used. + * + * @attribute attrForItemTitle + * @type String + */ + attrForItemTitle: { + type: String + } + }, + + hostAttributes: { + 'role': 'menu', + 'tabindex': '0' + }, + + observers: [ + '_updateMultiselectable(multi)' + ], + + listeners: { + 'focus': '_onFocus', + 'keydown': '_onKeydown' + }, + + keyBindings: { + 'up': '_onUpKey', + 'down': '_onDownKey', + 'esc': '_onEscKey', + 'enter': '_onEnterKey', + 'shift+tab:keydown': '_onShiftTabDown' + }, + + _updateMultiselectable: function(multi) { + if (multi) { + this.setAttribute('aria-multiselectable', 'true'); + } else { + this.removeAttribute('aria-multiselectable'); + } + }, + + _onShiftTabDown: function() { + var oldTabIndex; + + Polymer.IronMenuBehaviorImpl._shiftTabPressed = true; + + oldTabIndex = this.getAttribute('tabindex'); + + this.setAttribute('tabindex', '-1'); + + this.async(function() { + this.setAttribute('tabindex', oldTabIndex); + Polymer.IronMenuBehaviorImpl._shiftTabPressed = false; + // Note: polymer/polymer#1305 + }, 1); + }, + + _applySelection: function(item, isSelected) { + if (isSelected) { + item.setAttribute('aria-selected', 'true'); + } else { + item.removeAttribute('aria-selected'); + } + + Polymer.IronSelectableBehavior._applySelection.apply(this, arguments); + }, + + _focusedItemChanged: function(focusedItem, old) { + old && old.setAttribute('tabindex', '-1'); + if (focusedItem) { + focusedItem.setAttribute('tabindex', '0'); + focusedItem.focus(); + } + }, + + select: function(value) { + if (this._defaultFocusAsync) { + this.cancelAsync(this._defaultFocusAsync); + this._defaultFocusAsync = null; + } + var item = this._valueToItem(value); + this._setFocusedItem(item); + Polymer.IronMultiSelectableBehaviorImpl.select.apply(this, arguments); + }, + + _onFocus: function(event) { + if (Polymer.IronMenuBehaviorImpl._shiftTabPressed) { + return; + } + // do not focus the menu itself + this.blur(); + // clear the cached focus item + this._setFocusedItem(null); + this._defaultFocusAsync = this.async(function() { + // focus the selected item when the menu receives focus, or the first item + // if no item is selected + var selectedItem = this.multi ? (this.selectedItems && this.selectedItems[0]) : this.selectedItem; + if (selectedItem) { + this._setFocusedItem(selectedItem); + } else { + this._setFocusedItem(this.items[0]); + } + // async 100ms to wait for `select` to get called from `_itemActivate` + }, 100); + }, + + _onUpKey: function() { + // up and down arrows moves the focus + this._focusPrevious(); + }, + + _onDownKey: function() { + this._focusNext(); + }, + + _onEscKey: function() { + // esc blurs the control + this.focusedItem.blur(); + }, + + _onEnterKey: function(event) { + // enter activates the item unless it is disabled + this._activateFocused(event.detail.keyboardEvent); + }, + + _onKeydown: function(event) { + if (this.keyboardEventMatchesKeys(event, 'up down esc enter')) { + return; + } + + // all other keys focus the menu item starting with that character + this._focusWithKeyboardEvent(event); + }, + + _focusWithKeyboardEvent: function(event) { + for (var i = 0, item; item = this.items[i]; i++) { + var attr = this.attrForItemTitle || 'textContent'; + var title = item[attr] || item.getAttribute(attr); + if (title && title.trim().charAt(0).toLowerCase() === String.fromCharCode(event.keyCode).toLowerCase()) { + this._setFocusedItem(item); + break; + } + } + }, + + _activateFocused: function(event) { + if (!this.focusedItem.hasAttribute('disabled')) { + this._activateHandler(event); + } + }, + + _focusPrevious: function() { + var length = this.items.length; + var index = (Number(this.indexOf(this.focusedItem)) - 1 + length) % length; + this._setFocusedItem(this.items[index]); + }, + + _focusNext: function() { + var index = (Number(this.indexOf(this.focusedItem)) + 1) % this.items.length; + this._setFocusedItem(this.items[index]); + } + + }; + + Polymer.IronMenuBehaviorImpl._shiftTabPressed = false; + + /** @polymerBehavior Polymer.IronMenuBehavior */ + Polymer.IronMenuBehavior = [ + Polymer.IronMultiSelectableBehavior, + Polymer.IronA11yKeysBehavior, + Polymer.IronMenuBehaviorImpl + ]; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menu-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menu-behavior.html new file mode 100644 index 0000000..2d010f0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menu-behavior.html @@ -0,0 +1,13 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-selector/iron-multi-selectable.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + +</head><body><script src="iron-menu-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menubar-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menubar-behavior-extracted.js new file mode 100644 index 0000000..744a158 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menubar-behavior-extracted.js @@ -0,0 +1,51 @@ + + + /** + * `Polymer.IronMenubarBehavior` implements accessible menubar behavior. + * + * @polymerBehavior Polymer.IronMenubarBehavior + */ + Polymer.IronMenubarBehaviorImpl = { + + hostAttributes: { + 'role': 'menubar' + }, + + keyBindings: { + 'left': '_onLeftKey', + 'right': '_onRightKey' + }, + + _onUpKey: function(event) { + this._activateFocused(event.detail.keyboardEvent); + }, + + _onDownKey: function(event) { + this._activateFocused(event.detail.keyboardEvent); + }, + + _onLeftKey: function() { + this._focusPrevious(); + }, + + _onRightKey: function() { + this._focusNext(); + }, + + _onKeydown: function(event) { + if (this.keyboardEventMatchesKeys(event, 'up down left right esc enter')) { + return; + } + + // all other keys focus the menu item starting with that character + this._focusWithKeyboardEvent(event); + } + + }; + + /** @polymerBehavior Polymer.IronMenubarBehavior */ + Polymer.IronMenubarBehavior = [ + Polymer.IronMenuBehavior, + Polymer.IronMenubarBehaviorImpl + ]; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menubar-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menubar-behavior.html new file mode 100644 index 0000000..0bb0062 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-menu-behavior/iron-menubar-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-menu-behavior.html"> + +</head><body><script src="iron-menubar-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-meta/.bower.json new file mode 100644 index 0000000..0336c02 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/.bower.json @@ -0,0 +1,33 @@ +{ + "name": "iron-meta", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Useful for sharing information across a DOM tree", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-meta", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "74e95dc020cfebfbf4343fb952f0f224ccd47f8e" + }, + "_source": "git://github.com/PolymerElements/iron-meta.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-meta" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-meta/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/README.md b/third_party/polymer/v1_0/components-chromium/iron-meta/README.md new file mode 100644 index 0000000..b3b0f27 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/README.md @@ -0,0 +1,46 @@ +iron-meta +========= + +`iron-meta` is a generic element you can use for sharing information across the DOM tree. +It uses [monostate pattern](http://c2.com/cgi/wiki?MonostatePattern) such that any +instance of iron-meta has access to the shared +information. You can use `iron-meta` to share whatever you want (or create an extension +[like x-meta] for enhancements). + +The `iron-meta` instances containing your actual data can be loaded in an import, +or constructed in any way you see fit. The only requirement is that you create them +before you try to access them. + +Examples: + +If I create an instance like this: + +```html +<iron-meta key="info" keyUrl="foo/bar"></iron-meta> +``` + +Note that keyUrl="foo/bar" is the metadata I've defined. I could define more +attributes or use child nodes to define additional metadata. + +Now I can access that element (and it's metadata) from any iron-meta instance +via the byKey method, e.g. + +```javascript +meta.byKey('info').getAttribute('keyUrl'). +``` + +Pure imperative form would be like: + +```javascript +document.createElement('iron-meta').byKey('info').getAttribute('keyUrl'); +``` + +Or, in a Polymer element, you can include a meta in your template: + +```html +<iron-meta id="meta"></iron-meta> +``` + +```javascript +this.$.meta.byKey('info').getAttribute('keyUrl'); +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/bower.json b/third_party/polymer/v1_0/components-chromium/iron-meta/bower.json new file mode 100644 index 0000000..6e7e3f3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-meta", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer", + "meta" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Useful for sharing information across a DOM tree", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-meta/hero.svg new file mode 100644 index 0000000..ea8548d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/hero.svg @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="22" cy="85" r="4"/> + <circle cx="88" cy="98" r="4"/> + <path d="M87.5,100c-3.8-0.3-5.5-2.8-7-5c-1.4-2.1-2.7-3.9-5.5-4.2c-2.8-0.3-4.4,1.3-6.2,3.1c-1.9,1.9-4,4-7.8,3.7 + c-3.8-0.3-5.5-2.8-7-5c-1.4-2.1-2.7-3.9-5.5-4.2c-2.8-0.3-4.4,1.3-6.2,3.1c-1.9,1.9-4,4-7.8,3.7c-3.8-0.3-5.5-2.8-7-5 + c-1.4-2.1-2.7-3.9-5.5-4.2l0.2-2c3.8,0.3,5.5,2.8,7,5c1.4,2.1,2.7,3.9,5.5,4.2c2.8,0.3,4.4-1.3,6.2-3.1c1.9-1.9,4-4,7.8-3.7 + c3.8,0.3,5.5,2.8,7,5c1.4,2.1,2.7,3.9,5.5,4.2c2.8,0.3,4.4-1.3,6.2-3.1c1.9-1.9,4-4,7.8-3.7c3.8,0.3,5.5,2.8,7,5 + c1.4,2.1,2.7,3.9,5.5,4.2L87.5,100z"/> + <circle cx="96" cy="86" r="4"/> + <circle cx="162" cy="98" r="4"/> + <rect x="95.5" y="91" transform="matrix(0.9839 0.1789 -0.1789 0.9839 18.5382 -21.5923)" width="67.1" height="2"/> + <g> + <path d="M27,41.5l4.5,13.4l4.9-13.4h5.4v32h-4.4V61l0.4-13.4l-5.4,14.5h-2L25.6,48L26,61v12.5h-4.4v-32H27z"/> + <path d="M67.5,58.7H53.4V70h16.4v3.5H49v-32h20.6V45H53.4v10.2h14.2V58.7z"/> + <path d="M98.5,45H88.3v28.5h-4.4V45H73.6v-3.5h24.9V45z"/> + <path d="M116.2,65.3H105l-2.6,8.2h-4.5l10.9-32h3.8l10.6,32h-4.5L116.2,65.3z M106.2,61.6h8.9l-4.4-14.2L106.2,61.6z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/index.html b/third_party/polymer/v1_0/components-chromium/iron-meta/index.html new file mode 100644 index 0000000..c70dc6e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <title>iron-meta</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/iron-meta-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-meta/iron-meta-extracted.js new file mode 100644 index 0000000..579f9c0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/iron-meta-extracted.js @@ -0,0 +1,298 @@ + + + (function() { + + // monostate data + var metaDatas = {}; + var metaArrays = {}; + + Polymer.IronMeta = Polymer({ + + is: 'iron-meta', + + properties: { + + /** + * The type of meta-data. All meta-data of the same type is stored + * together. + * + * @attribute type + * @type String + * @default 'default' + */ + type: { + type: String, + value: 'default', + observer: '_typeChanged' + }, + + /** + * The key used to store `value` under the `type` namespace. + * + * @attribute key + * @type String + * @default '' + */ + key: { + type: String, + observer: '_keyChanged' + }, + + /** + * The meta-data to store or retrieve. + * + * @attribute value + * @type * + * @default this + */ + value: { + type: Object, + notify: true, + observer: '_valueChanged' + }, + + /** + * If true, `value` is set to the iron-meta instance itself. + * + * @attribute self + * @type Boolean + * @default false + */ + self: { + type: Boolean, + observer: '_selfChanged' + }, + + /** + * Array of all meta-data values for the given type. + * + * @property list + * @type Array + */ + list: { + type: Array, + notify: true + } + + }, + + /** + * Only runs if someone invokes the factory/constructor directly + * e.g. `new Polymer.IronMeta()` + */ + factoryImpl: function(config) { + if (config) { + for (var n in config) { + switch(n) { + case 'type': + case 'key': + case 'value': + this[n] = config[n]; + break; + } + } + } + }, + + created: function() { + // TODO(sjmiles): good for debugging? + this._metaDatas = metaDatas; + this._metaArrays = metaArrays; + }, + + _keyChanged: function(key, old) { + this._resetRegistration(old); + }, + + _valueChanged: function(value) { + this._resetRegistration(this.key); + }, + + _selfChanged: function(self) { + if (self) { + this.value = this; + } + }, + + _typeChanged: function(type) { + this._unregisterKey(this.key); + if (!metaDatas[type]) { + metaDatas[type] = {}; + } + this._metaData = metaDatas[type]; + if (!metaArrays[type]) { + metaArrays[type] = []; + } + this.list = metaArrays[type]; + this._registerKeyValue(this.key, this.value); + }, + + /** + * Retrieves meta data value by key. + * + * @method byKey + * @param {String} key The key of the meta-data to be returned. + * @returns * + */ + byKey: function(key) { + return this._metaData && this._metaData[key]; + }, + + _resetRegistration: function(oldKey) { + this._unregisterKey(oldKey); + this._registerKeyValue(this.key, this.value); + }, + + _unregisterKey: function(key) { + this._unregister(key, this._metaData, this.list); + }, + + _registerKeyValue: function(key, value) { + this._register(key, value, this._metaData, this.list); + }, + + _register: function(key, value, data, list) { + if (key && data && value !== undefined) { + data[key] = value; + list.push(value); + } + }, + + _unregister: function(key, data, list) { + if (key && data) { + if (key in data) { + var value = data[key]; + delete data[key]; + this.arrayDelete(list, value); + } + } + } + + }); + + /** + `iron-meta-query` can be used to access infomation stored in `iron-meta`. + + Examples: + + If I create an instance like this: + + <iron-meta key="info" value="foo/bar"></iron-meta> + + Note that keyUrl="foo/bar" is the metadata I've defined. I could define more + attributes or use child nodes to define additional metadata. + + Now I can access that element (and it's metadata) from any `iron-meta-query` instance: + + var value = new Polymer.IronMetaQuery({key: 'info'}).value; + + @group Polymer Iron Elements + @element iron-meta-query + */ + Polymer.IronMetaQuery = Polymer({ + + is: 'iron-meta-query', + + properties: { + + /** + * The type of meta-data. All meta-data of the same type is stored + * together. + * + * @attribute type + * @type String + * @default 'default' + */ + type: { + type: String, + value: 'default', + observer: '_typeChanged' + }, + + /** + * Specifies a key to use for retrieving `value` from the `type` + * namespace. + * + * @attribute key + * @type String + */ + key: { + type: String, + observer: '_keyChanged' + }, + + /** + * The meta-data to store or retrieve. + * + * @attribute value + * @type * + * @default this + */ + value: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * Array of all meta-data values for the given type. + * + * @property list + * @type Array + */ + list: { + type: Array, + notify: true + } + + }, + + /** + * Actually a factory method, not a true constructor. Only runs if + * someone invokes it directly (via `new Polymer.IronMeta()`); + */ + constructor: function(config) { + if (config) { + for (var n in config) { + switch(n) { + case 'type': + case 'key': + this[n] = config[n]; + break; + } + } + } + }, + + created: function() { + // TODO(sjmiles): good for debugging? + this._metaDatas = metaDatas; + this._metaArrays = metaArrays; + }, + + _keyChanged: function(key) { + this._setValue(this._metaData && this._metaData[key]); + }, + + _typeChanged: function(type) { + this._metaData = metaDatas[type]; + this.list = metaArrays[type]; + if (this.key) { + this._keyChanged(this.key); + } + }, + + /** + * Retrieves meta data value by key. + * + * @method byKey + * @param {String} key The key of the meta-data to be returned. + * @returns * + */ + byKey: function(key) { + return this._metaData && this._metaData[key]; + } + + }); + + })(); diff --git a/third_party/polymer/v1_0/components-chromium/iron-meta/iron-meta.html b/third_party/polymer/v1_0/components-chromium/iron-meta/iron-meta.html new file mode 100644 index 0000000..2ca804b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-meta/iron-meta.html @@ -0,0 +1,52 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-meta` is a generic element you can use for sharing information across the DOM tree. +It uses [monostate pattern](http://c2.com/cgi/wiki?MonostatePattern) such that any +instance of iron-meta has access to the shared +information. You can use `iron-meta` to share whatever you want (or create an extension +[like x-meta] for enhancements). + +The `iron-meta` instances containing your actual data can be loaded in an import, +or constructed in any way you see fit. The only requirement is that you create them +before you try to access them. + +Examples: + +If I create an instance like this: + + <iron-meta key="info" keyUrl="foo/bar"></iron-meta> + +Note that keyUrl="foo/bar" is the metadata I've defined. I could define more +attributes or use child nodes to define additional metadata. + +Now I can access that element (and it's metadata) from any iron-meta instance +via the byKey method, e.g. + + meta.byKey('info').getAttribute('keyUrl'). + +Pure imperative form would be like: + + document.createElement('iron-meta').byKey('info').getAttribute('keyUrl'); + +Or, in a Polymer element, you can include a meta in your template: + + <iron-meta id="meta"></iron-meta> + ... + this.$.meta.byKey('info').getAttribute('keyUrl'); + +@group Iron Elements +@demo demo/index.html +@hero hero.svg +@element iron-meta +--> + +</head><body><script src="iron-meta-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/.bower.json new file mode 100644 index 0000000..dd439c4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "iron-overlay-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for making an element an overlay", + "private": true, + "main": [ + "iron-overlay-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior", + "overlay" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-overlay-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-overlay-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "03debac2eb637f2b3e68edb05d8f1e5902e81ebc" + }, + "_source": "git://github.com/PolymerElements/iron-overlay-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-overlay-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/README.md new file mode 100644 index 0000000..17df695 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/README.md @@ -0,0 +1,11 @@ +# iron-overlay-behavior +Makes an element an overlay with an optional backdrop. + +`iron-overlay-behavior` displays an element on top of other content. It starts out hidden and is +displayed by calling `open()` or setting the `opened` property to `true`. It may be closed by +calling `close()` or `cancel()`, or by setting the `opened` property to `true`. + +The difference between `close()` and `cancel()` is user intent. `close()` generally implies that +the user acknowledged the content of the overlay. By default, it will cancel whenever the user taps +outside it or presses the escape key. This behavior can be turned off via the `no-cancel-on-esc-key` +and the `no-cancel-on-outside-click` properties. diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/bower.json new file mode 100644 index 0000000..7d4dead --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-overlay-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for making an element an overlay", + "private": true, + "main": [ + "iron-overlay-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior", + "overlay" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-overlay-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/index.html new file mode 100644 index 0000000..d69e304 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-overlay-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-backdrop-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-backdrop-extracted.js new file mode 100644 index 0000000..f3fd930 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-backdrop-extracted.js @@ -0,0 +1,71 @@ + + +(function() { + + Polymer({ + + is: 'iron-overlay-backdrop', + + properties: { + + /** + * Returns true if the backdrop is opened. + */ + opened: { + readOnly: true, + reflectToAttribute: true, + type: Boolean, + value: false + }, + + _manager: { + type: Object, + value: Polymer.IronOverlayManager + } + + }, + + /** + * Appends the backdrop to document body and sets its `z-index` to be below the latest overlay. + */ + prepare: function() { + if (!this.parentNode) { + Polymer.dom(document.body).appendChild(this); + this.style.zIndex = this._manager.currentOverlayZ() - 1; + } + }, + + /** + * Shows the backdrop if needed. + */ + open: function() { + // only need to make the backdrop visible if this is called by the first overlay with a backdrop + if (this._manager.getBackdrops().length < 2) { + this._setOpened(true); + } + }, + + /** + * Hides the backdrop if needed. + */ + close: function() { + // only need to make the backdrop invisible if this is called by the last overlay with a backdrop + if (this._manager.getBackdrops().length < 2) { + this._setOpened(false); + } + }, + + /** + * Removes the backdrop from document body if needed. + */ + complete: function() { + // only remove the backdrop if there are no more overlays with backdrops + if (this._manager.getBackdrops().length === 0 && this.parentNode) { + Polymer.dom(this.parentNode).removeChild(this); + } + } + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-backdrop.html b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-backdrop.html new file mode 100644 index 0000000..1e50d0e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-backdrop.html @@ -0,0 +1,59 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-overlay-manager.html"> + +<!-- +`iron-overlay-backdrop` is a backdrop used by `Polymer.IronOverlayBehavior`. It should be a +singleton. + +### Styling + +The following custom properties and mixins are available for styling. + +Custom property | Description | Default +-------------------------------------------|------------------------|--------- +`--iron-overlay-backdrop-background-color` | Backdrop background color | #000 +`--iron-overlay-backdrop-opacity` | Backdrop opacity | 0.6 +`--iron-overlay-backdrop` | Mixin applied to `iron-overlay-backdrop`. | {} +`--iron-overlay-backdrop-opened` | Mixin applied to `iron-overlay-backdrop` when it is displayed | {} +--> + +</head><body><dom-module id="iron-overlay-backdrop"> + + <style> + + :host { + position: fixed; + top: 0; + left: 0; + width: 100vw; + height: 100vh; + background-color: var(--iron-overlay-backdrop-background-color, #000); + opacity: 0; + transition: opacity 0.2s; + + @apply(--iron-overlay-backdrop); + } + + :host([opened]) { + opacity: var(--iron-overlay-backdrop-opacity, 0.6); + + @apply(--iron-overlay-backdrop-opened); + } + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script src="iron-overlay-backdrop-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-behavior-extracted.js new file mode 100644 index 0000000..171e421 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-behavior-extracted.js @@ -0,0 +1,415 @@ + + +/* +Use `Polymer.IronOverlayBehavior` to implement an element that can be hidden or shown, and displays +on top of other content. It includes an optional backdrop, and can be used to implement a variety +of UI controls including dialogs and drop downs. Multiple overlays may be displayed at once. + +### Closing and canceling + +A dialog may be hidden by closing or canceling. The difference between close and cancel is user +intent. Closing generally implies that the user acknowledged the content on the overlay. By default, +it will cancel whenever the user taps outside it or presses the escape key. This behavior is +configurable with the `no-cancel-on-esc-key` and the `no-cancel-on-outside-click` properties. +`close()` should be called explicitly by the implementer when the user interacts with a control +in the overlay element. + +### Positioning + +By default the element is sized and positioned to fit and centered inside the window. You can +position and size it manually using CSS. See `Polymer.IronFitBehavior`. + +### Backdrop + +Set the `with-backdrop` attribute to display a backdrop behind the overlay. The backdrop is +appended to `<body>` and is of type `<iron-overlay-backdrop>`. See its doc page for styling +options. + +### Limitations + +The element is styled to appear on top of other content by setting its `z-index` property. You +must ensure no element has a stacking context with a higher `z-index` than its parent stacking +context. You should place this element as a child of `<body>` whenever possible. + +@demo demo/index.html +@polymerBehavior Polymer.IronOverlayBehavior +*/ + + Polymer.IronOverlayBehaviorImpl = { + + properties: { + + /** + * True if the overlay is currently displayed. + */ + opened: { + observer: '_openedChanged', + type: Boolean, + value: false + }, + + /** + * True if the overlay was canceled when it was last closed. + */ + canceled: { + observer: '_canceledChanged', + readOnly: true, + type: Boolean, + value: false + }, + + /** + * Set to true to display a backdrop behind the overlay. + */ + withBackdrop: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable auto-focusing the overlay or child nodes with + * the `autofocus` attribute` when the overlay is opened. + */ + noAutoFocus: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable canceling the overlay with the ESC key. + */ + noCancelOnEscKey: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable canceling the overlay by clicking outside it. + */ + noCancelOnOutsideClick: { + type: Boolean, + value: false + }, + + /** + * Returns the reason this dialog was last closed. + */ + closingReason: { + // was a getter before, but needs to be a property so other + // behaviors can override this. + type: Object + }, + + _manager: { + type: Object, + value: Polymer.IronOverlayManager + }, + + _boundOnCaptureClick: { + type: Function, + value: function() { + return this._onCaptureClick.bind(this); + } + }, + + _boundOnCaptureKeydown: { + type: Function, + value: function() { + return this._onCaptureKeydown.bind(this); + } + } + + }, + + listeners: { + 'click': '_onClick', + 'iron-resize': '_onIronResize' + }, + + /** + * The backdrop element. + * @type Node + */ + get backdropElement() { + return this._backdrop; + }, + + get _focusNode() { + return Polymer.dom(this).querySelector('[autofocus]') || this; + }, + + registered: function() { + this._backdrop = document.createElement('iron-overlay-backdrop'); + }, + + ready: function() { + this._ensureSetup(); + if (this._callOpenedWhenReady) { + this._openedChanged(); + } + }, + + detached: function() { + this.opened = false; + this._completeBackdrop(); + this._manager.removeOverlay(this); + }, + + /** + * Toggle the opened state of the overlay. + */ + toggle: function() { + this.opened = !this.opened; + }, + + /** + * Open the overlay. + */ + open: function() { + this.opened = true; + this.closingReason = {canceled: false}; + }, + + /** + * Close the overlay. + */ + close: function() { + this.opened = false; + this._setCanceled(false); + }, + + /** + * Cancels the overlay. + */ + cancel: function() { + this.opened = false, + this._setCanceled(true); + }, + + _ensureSetup: function() { + if (this._overlaySetup) { + return; + } + this._overlaySetup = true; + this.style.outline = 'none'; + this.style.display = 'none'; + }, + + _openedChanged: function() { + if (this.opened) { + this.removeAttribute('aria-hidden'); + } else { + this.setAttribute('aria-hidden', 'true'); + } + + // wait to call after ready only if we're initially open + if (!this._overlaySetup) { + this._callOpenedWhenReady = this.opened; + return; + } + if (this._openChangedAsync) { + this.cancelAsync(this._openChangedAsync); + } + + this._toggleListeners(); + + if (this.opened) { + this._prepareRenderOpened(); + } + + // async here to allow overlay layer to become visible. + this._openChangedAsync = this.async(function() { + // overlay becomes visible here + this.style.display = ''; + // force layout to ensure transitions will go + this.offsetWidth; + if (this.opened) { + this._renderOpened(); + } else { + this._renderClosed(); + } + this._openChangedAsync = null; + }); + + }, + + _canceledChanged: function() { + this.closingReason = this.closingReason || {}; + this.closingReason.canceled = this.canceled; + }, + + _toggleListener: function(enable, node, event, boundListener, capture) { + if (enable) { + node.addEventListener(event, boundListener, capture); + } else { + node.removeEventListener(event, boundListener, capture); + } + }, + + _toggleListeners: function() { + if (this._toggleListenersAsync) { + this.cancelAsync(this._toggleListenersAsync); + } + // async so we don't auto-close immediately via a click. + this._toggleListenersAsync = this.async(function() { + this._toggleListener(this.opened, document, 'click', this._boundOnCaptureClick, true); + this._toggleListener(this.opened, document, 'keydown', this._boundOnCaptureKeydown, true); + this._toggleListenersAsync = null; + }); + }, + + // tasks which must occur before opening; e.g. making the element visible + _prepareRenderOpened: function() { + this._manager.addOverlay(this); + + if (this.withBackdrop) { + this.backdropElement.prepare(); + this._manager.trackBackdrop(this); + } + + this._preparePositioning(); + this.fit(); + this._finishPositioning(); + }, + + // tasks which cause the overlay to actually open; typically play an + // animation + _renderOpened: function() { + if (this.withBackdrop) { + this.backdropElement.open(); + } + this._finishRenderOpened(); + }, + + _renderClosed: function() { + if (this.withBackdrop) { + this.backdropElement.close(); + } + this._finishRenderClosed(); + }, + + _onTransitionend: function(event) { + // make sure this is our transition event. + if (event && event.target !== this) { + return; + } + if (this.opened) { + this._finishRenderOpened(); + } else { + this._finishRenderClosed(); + } + }, + + _finishRenderOpened: function() { + // focus the child node with [autofocus] + if (!this.noAutoFocus) { + this._focusNode.focus(); + } + + this.fire('iron-overlay-opened'); + + this._squelchNextResize = true; + this.async(this.notifyResize); + }, + + _finishRenderClosed: function() { + // hide the overlay and remove the backdrop + this.resetFit(); + this.style.display = 'none'; + this._completeBackdrop(); + this._manager.removeOverlay(this); + + this._focusNode.blur(); + // focus the next overlay, if there is one + this._manager.focusOverlay(); + + this.fire('iron-overlay-closed', this.closingReason); + + this._squelchNextResize = true; + this.async(this.notifyResize); + }, + + _completeBackdrop: function() { + if (this.withBackdrop) { + this._manager.trackBackdrop(this); + this.backdropElement.complete(); + } + }, + + _preparePositioning: function() { + this.style.transition = this.style.webkitTransition = 'none'; + this.style.transform = this.style.webkitTransform = 'none'; + this.style.display = ''; + }, + + _finishPositioning: function(target) { + this.style.display = 'none'; + this.style.transform = this.style.webkitTransform = ''; + // force layout to avoid application of transform + this.offsetWidth; + this.style.transition = this.style.webkitTransition = ''; + }, + + _applyFocus: function() { + if (this.opened) { + if (!this.noAutoFocus) { + this._focusNode.focus(); + } + } else { + this._focusNode.blur(); + this._manager.focusOverlay(); + } + }, + + _onCaptureClick: function(event) { + // attempt to close asynchronously and prevent the close of a tap event is immediately heard + // on target. This is because in shadow dom due to event retargetting event.target is not + // useful. + if (!this.noCancelOnOutsideClick && (this._manager.currentOverlay() == this)) { + this._cancelJob = this.async(function() { + this.cancel(); + }, 10); + } + }, + + _onClick: function(event) { + if (this._cancelJob) { + this.cancelAsync(this._cancelJob); + this._cancelJob = null; + } + }, + + _onCaptureKeydown: function(event) { + var ESC = 27; + if (!this.noCancelOnEscKey && (event.keyCode === ESC)) { + this.cancel(); + event.stopPropagation(); + } + }, + + _onIronResize: function() { + if (this._squelchNextResize) { + this._squelchNextResize = false; + return; + } + if (this.opened) { + this.refit(); + } + } + + }; + + /** @polymerBehavior */ + Polymer.IronOverlayBehavior = [Polymer.IronFitBehavior, Polymer.IronResizableBehavior, Polymer.IronOverlayBehaviorImpl]; + +/* + * Fired after the `iron-overlay` opens. + * @event iron-overlay-opened + */ + +/* + * Fired after the `iron-overlay` closes. + * @event iron-overlay-closed {{canceled: boolean}} detail - + * canceled: True if the overlay was canceled. + */ + diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-behavior.html new file mode 100644 index 0000000..1a3179e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-behavior.html @@ -0,0 +1,15 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-fit-behavior/iron-fit-behavior.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="iron-overlay-backdrop.html"> +<link rel="import" href="iron-overlay-manager.html"> + +</head><body><script src="iron-overlay-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-manager-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-manager-extracted.js new file mode 100644 index 0000000..1a6f7dc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-manager-extracted.js @@ -0,0 +1,94 @@ + + + Polymer.IronOverlayManager = (function() { + + var overlays = []; + var DEFAULT_Z = 10; + var backdrops = []; + + // track overlays for z-index and focus managemant + function addOverlay(overlay) { + var z0 = currentOverlayZ(); + overlays.push(overlay); + var z1 = currentOverlayZ(); + if (z1 <= z0) { + applyOverlayZ(overlay, z0); + } + } + + function removeOverlay(overlay) { + var i = overlays.indexOf(overlay); + if (i >= 0) { + overlays.splice(i, 1); + setZ(overlay, ''); + } + } + + function applyOverlayZ(overlay, aboveZ) { + setZ(overlay, aboveZ + 2); + } + + function setZ(element, z) { + element.style.zIndex = z; + } + + function currentOverlay() { + return overlays[overlays.length-1]; + } + + function currentOverlayZ() { + var z; + var current = currentOverlay(); + if (current) { + var z1 = window.getComputedStyle(current).zIndex; + if (!isNaN(z1)) { + z = Number(z1); + } + } + return z || DEFAULT_Z; + } + + function focusOverlay() { + var current = currentOverlay(); + // We have to be careful to focus the next overlay _after_ any current + // transitions are complete (due to the state being toggled prior to the + // transition). Otherwise, we risk infinite recursion when a transitioning + // (closed) overlay becomes the current overlay. + // + // NOTE: We make the assumption that any overlay that completes a transition + // will call into focusOverlay to kick the process back off. Currently: + // transitionend -> _applyFocus -> focusOverlay. + if (current && !current.transitioning) { + current._applyFocus(); + } + } + + function trackBackdrop(element) { + // backdrops contains the overlays with a backdrop that are currently + // visible + if (element.opened) { + backdrops.push(element); + } else { + var index = backdrops.indexOf(element); + if (index >= 0) { + backdrops.splice(index, 1); + } + } + } + + function getBackdrops() { + return backdrops; + } + + return { + addOverlay: addOverlay, + removeOverlay: removeOverlay, + currentOverlay: currentOverlay, + currentOverlayZ: currentOverlayZ, + focusOverlay: focusOverlay, + trackBackdrop: trackBackdrop, + getBackdrops: getBackdrops + }; + + })(); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-manager.html b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-manager.html new file mode 100644 index 0000000..571a3a7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-overlay-behavior/iron-overlay-manager.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-overlay-manager-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-pages/.bower.json new file mode 100644 index 0000000..46d3ac1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-pages", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Organizes a set of pages and shows one at a time", + "main": "iron-pages.html", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "dependencies": { + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "iron-selector": "polymerelements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-pages", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "5450f62ac96fb0b21237efb58b9847cd2ce9a27c" + }, + "_source": "git://github.com/PolymerElements/iron-pages.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-pages" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-pages/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/README.md b/third_party/polymer/v1_0/components-chromium/iron-pages/README.md new file mode 100644 index 0000000..716ccc3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/README.md @@ -0,0 +1,22 @@ +iron-pages +========== + +`iron-pages` is used to select one of its children to show. One use is to cycle through a list of +children "pages". + +Example: + +```html +<iron-pages selected="0"> + <div>One</div> + <div>Two</div> + <div>Three</div> +</iron-pages> + +<script> + document.addEventListener('click', function(e) { + var pages = document.querySelector('iron-pages'); + pages.selectNext(); + }); +</script> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/bower.json b/third_party/polymer/v1_0/components-chromium/iron-pages/bower.json new file mode 100644 index 0000000..57fd16d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/bower.json @@ -0,0 +1,27 @@ +{ + "name": "iron-pages", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Organizes a set of pages and shows one at a time", + "main": "iron-pages.html", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "dependencies": { + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "iron-selector": "polymerelements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/hero.svg b/third_party/polymer/v1_0/components-chromium/iron-pages/hero.svg new file mode 100644 index 0000000..fa12783 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/hero.svg @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M143.3,73.6H51.7V26.7h91.6V73.6z M53.7,71.6h87.6V28.7H53.7V71.6z"/> + <path d="M158.3,85.4H66.7V38.6h91.6V85.4z M68.7,83.4h87.6V40.6H68.7V83.4z"/> + <path d="M172,99H80.4V52.1H172V99z M82.4,97H170V54.1H82.4V97z"/> + <circle cx="53" cy="28" r="4"/> + <circle cx="171" cy="98" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/index.html b/third_party/polymer/v1_0/components-chromium/iron-pages/index.html new file mode 100644 index 0000000..67ae088 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + <title>iron-pages</title> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/iron-pages-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-pages/iron-pages-extracted.js new file mode 100644 index 0000000..503d9b5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/iron-pages-extracted.js @@ -0,0 +1,20 @@ + + + Polymer({ + + is: 'iron-pages', + + behaviors: [ + Polymer.IronResizableBehavior, + Polymer.IronSelectableBehavior + ], + + observers: [ + '_selectedPageChanged(selected)' + ], + + _selectedPageChanged: function(selected, old) { + this.async(this.notifyResize); + } + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-pages/iron-pages.html b/third_party/polymer/v1_0/components-chromium/iron-pages/iron-pages.html new file mode 100644 index 0000000..dcc7d47 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-pages/iron-pages.html @@ -0,0 +1,61 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="../iron-selector/iron-selectable.html"> + +<!-- +`iron-pages` is used to select one of its children to show. One use is to cycle through a list of +children "pages". + +Example: + + <iron-pages selected="0"> + <div>One</div> + <div>Two</div> + <div>Three</div> + </iron-pages> + + <script> + document.addEventListener('click', function(e) { + var pages = document.querySelector('iron-pages'); + pages.selectNext(); + }); + </script> + +@group Iron Elements +@class iron-pages +@hero hero.svg +@demo demo/index.html +@extends iron-selector +--> + +</head><body><dom-module id="iron-pages"> + + <style> + + :host { + display: block; + } + + :host > ::content > :not(.iron-selected) { + display: none !important; + } + + </style> + + <template> + + <content></content> + + </template> + +</dom-module> + +<script src="iron-pages-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/.bower.json new file mode 100644 index 0000000..0a4896f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "iron-range-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for something with a minimum and maximum value", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "main": [ + "iron-range-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-range-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-range-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "80aa8588f3b8527b96f3206655b29e23970fb7a3" + }, + "_source": "git://github.com/PolymerElements/iron-range-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-range-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/README.md new file mode 100644 index 0000000..8d523bc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/README.md @@ -0,0 +1,4 @@ +iron-range-behavior +========== + +`Polymer.IronRangeBehavior` provides the behavior for something with a minimum to maximum range. diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/bower.json new file mode 100644 index 0000000..2f3cea4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/bower.json @@ -0,0 +1,30 @@ +{ + "name": "iron-range-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for something with a minimum and maximum value", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "main": [ + "iron-range-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-range-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/index.html new file mode 100644 index 0000000..25ed936 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/iron-range-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/iron-range-behavior-extracted.js new file mode 100644 index 0000000..ce73374 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/iron-range-behavior-extracted.js @@ -0,0 +1,88 @@ + + + /** + * `iron-range-behavior` provides the behavior for something with a minimum to maximum range. + * + * @demo demo/index.html + * @polymerBehavior + */ + Polymer.IronRangeBehavior = { + + properties: { + + /** + * The number that represents the current value. + */ + value: { + type: Number, + value: 0, + notify: true, + reflectToAttribute: true + }, + + /** + * The number that indicates the minimum value of the range. + */ + min: { + type: Number, + value: 0, + notify: true + }, + + /** + * The number that indicates the maximum value of the range. + */ + max: { + type: Number, + value: 100, + notify: true + }, + + /** + * Specifies the value granularity of the range's value. + */ + step: { + type: Number, + value: 1, + notify: true + }, + + /** + * Returns the ratio of the value. + */ + ratio: { + type: Number, + value: 0, + readOnly: true, + notify: true + }, + }, + + observers: [ + '_update(value, min, max, step)' + ], + + _calcRatio: function(value) { + return (this._clampValue(value) - this.min) / (this.max - this.min); + }, + + _clampValue: function(value) { + return Math.min(this.max, Math.max(this.min, this._calcStep(value))); + }, + + _calcStep: function(value) { + return this.step ? (Math.round(value / this.step) / (1 / this.step)) : value; + }, + + _validateValue: function() { + var v = this._clampValue(this.value); + this.value = this.oldValue = isNaN(v) ? this.oldValue : v; + return this.value !== v; + }, + + _update: function() { + this._validateValue(); + this._setRatio(this._calcRatio(this.value) * 100); + } + +}; diff --git a/third_party/polymer/v1_0/components-chromium/iron-range-behavior/iron-range-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/iron-range-behavior.html new file mode 100644 index 0000000..c6ec4a8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-range-behavior/iron-range-behavior.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-range-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/.bower.json new file mode 100644 index 0000000..abbcb68 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-resizable-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Coordinates the flow of resizeable elements", + "private": true, + "main": "iron-resizable-behavior.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-resizable-behavior", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "62e0fb1dd6d657bceab7c78faf1a8b0fb909239c" + }, + "_source": "git://github.com/PolymerElements/iron-resizable-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-resizable-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/README.md new file mode 100644 index 0000000..72be6de --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/README.md @@ -0,0 +1,16 @@ +iron-resizable-behavior +======================= + +`IronResizableBehavior` is a behavior that can be used in Polymer elements to +coordinate the flow of resize events between "resizers" (elements that control the +size or hidden state of their children) and "resizables" (elements that need to be +notified when they are resized or un-hidden by their parents in order to take +action on their new measurements). + +Elements that perform measurement should add the `IronResizableBehavior` behavior to +their element definition and listen for the `iron-resize` event on themselves. +This event will be fired when they become showing after having been hidden, +when they are resized explicitly by another resizable, or when the window has been +resized. + +Note, the `iron-resize` event is non-bubbling. diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/bower.json new file mode 100644 index 0000000..b1c66f0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/bower.json @@ -0,0 +1,26 @@ +{ + "name": "iron-resizable-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Coordinates the flow of resizeable elements", + "private": true, + "main": "iron-resizable-behavior.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/index.html new file mode 100644 index 0000000..b9b8809 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + + <title>iron-resizable-behavior</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/iron-resizable-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/iron-resizable-behavior-extracted.js new file mode 100644 index 0000000..f199bc9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/iron-resizable-behavior-extracted.js @@ -0,0 +1,125 @@ + + /** + * `IronResizableBehavior` is a behavior that can be used in Polymer elements to + * coordinate the flow of resize events between "resizers" (elements that control the + * size or hidden state of their children) and "resizables" (elements that need to be + * notified when they are resized or un-hidden by their parents in order to take + * action on their new measurements). + * Elements that perform measurement should add the `IronResizableBehavior` behavior to + * their element definition and listen for the `iron-resize` event on themselves. + * This event will be fired when they become showing after having been hidden, + * when they are resized explicitly by another resizable, or when the window has been + * resized. + * Note, the `iron-resize` event is non-bubbling. + * + * @polymerBehavior Polymer.IronResizableBehavior + * @demo demo/index.html + **/ + Polymer.IronResizableBehavior = { + properties: { + _parentResizable: { + type: Object, + observer: '_parentResizableChanged' + } + }, + + listeners: { + 'iron-request-resize-notifications': '_onIronRequestResizeNotifications' + }, + + created: function() { + // We don't really need property effects on these, and also we want them + // to be created before the `_parentResizable` observer fires: + this._interestedResizables = []; + this._boundNotifyResize = this.notifyResize.bind(this); + }, + + attached: function() { + this.fire('iron-request-resize-notifications', null, { + node: this, + bubbles: true + }); + + if (!this._parentResizable) { + window.addEventListener('resize', this._boundNotifyResize); + this.notifyResize(); + } + }, + + detached: function() { + if (this._parentResizable) { + this._parentResizable.stopResizeNotificationsFor(this); + } else { + window.removeEventListener('resize', this._boundNotifyResize); + } + + this._parentResizable = null; + }, + + /** + * Can be called to manually notify a resizable and its descendant + * resizables of a resize change. + */ + notifyResize: function() { + if (!this.isAttached) { + return; + } + + this._interestedResizables.forEach(function(resizable) { + // TODO(cdata): Currently behaviors cannot define "abstract" methods.. + if (!this.resizerShouldNotify || this.resizerShouldNotify(resizable)) { + resizable.notifyResize(); + } + }, this); + + this.fire('iron-resize', null, { + node: this, + bubbles: false + }); + }, + + /** + * Used to assign the closest resizable ancestor to this resizable + * if the ancestor detects a request for notifications. + */ + assignParentResizable: function(parentResizable) { + this._parentResizable = parentResizable; + }, + + /** + * Used to remove a resizable descendant from the list of descendants + * that should be notified of a resize change. + */ + stopResizeNotificationsFor: function(target) { + var index = this._interestedResizables.indexOf(target); + + if (index > -1) { + this._interestedResizables.splice(index, 1); + } + }, + + // TODO(cdata): Currently behaviors cannot define "abstract" methods. + // resizerShouldNotify: function(el) { return true; }, + + _parentResizableChanged: function(parentResizable) { + if (parentResizable) { + window.removeEventListener('resize', this._boundNotifyResize); + } + }, + + _onIronRequestResizeNotifications: function(event) { + var target = event.path ? event.path[0] : event.target; + + if (target === this) { + return; + } + + if (this._interestedResizables.indexOf(target) === -1) { + this._interestedResizables.push(target); + } + + target.assignParentResizable(this); + + event.stopPropagation(); + } + }; diff --git a/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/iron-resizable-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/iron-resizable-behavior.html new file mode 100644 index 0000000..0ee974a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-resizable-behavior/iron-resizable-behavior.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-resizable-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-selector/.bower.json new file mode 100644 index 0000000..31050826 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "iron-selector", + "version": "1.0.2", + "description": "Manages a set of elements that can be selected", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "main": [ + "iron-selector.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "selector" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-selector.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-selector", + "_release": "1.0.2", + "_resolution": { + "type": "version", + "tag": "v1.0.2", + "commit": "ea22d91d11ba6f72c01faa952d5e600f9d1773cf" + }, + "_source": "git://github.com/PolymerElements/iron-selector.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-selector" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-selector/.gitignore new file mode 100644 index 0000000..b13058c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/.gitignore @@ -0,0 +1,2 @@ +bower_components +.DS_Store diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/README.md b/third_party/polymer/v1_0/components-chromium/iron-selector/README.md new file mode 100644 index 0000000..8bb3d64 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/README.md @@ -0,0 +1,50 @@ +iron-selector +============= + +`iron-selector` is an element which can be used to manage a list of elements +that can be selected. Tapping on the item will make the item selected. The `selected` indicates +which item is being selected. The default is to use the index of the item. + +Example: + +```html +<iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> +</iron-selector> +``` + +If you want to use the attribute value of an element for `selected` instead of the index, +set `attrForSelected` to the name of the attribute. For example, if you want to select item by +`name`, set `attrForSelected` to `name`. + +Example: + +```html +<iron-selector attr-for-selected="name" selected="foo"> + <div name="foo">Foo</div> + <div name="bar">Bar</div> + <div name="zot">Zot</div> +</iron-selector> +``` + +`iron-selector` is not styled. Use the `iron-selected` CSS class to style the selected element. + +Example: + +```html +<style> + .iron-selected { + background: #eee; + } +</style> + +... + +<iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> +</iron-selector> +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/bower.json b/third_party/polymer/v1_0/components-chromium/iron-selector/bower.json new file mode 100644 index 0000000..b9751df --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-selector", + "version": "1.0.2", + "description": "Manages a set of elements that can be selected", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "main": [ + "iron-selector.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "selector" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-selector.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/index.html b/third_party/polymer/v1_0/components-chromium/iron-selector/index.html new file mode 100644 index 0000000..741693c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + + <title>iron-selector</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js new file mode 100644 index 0000000..a595e49 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js @@ -0,0 +1,106 @@ + + /** @polymerBehavior Polymer.IronMultiSelectableBehavior */ + Polymer.IronMultiSelectableBehaviorImpl = { + properties: { + + /** + * If true, multiple selections are allowed. + */ + multi: { + type: Boolean, + value: false, + observer: 'multiChanged' + }, + + /** + * Gets or sets the selected elements. This is used instead of `selected` when `multi` + * is true. + */ + selectedValues: { + type: Array, + notify: true + }, + + /** + * Returns an array of currently selected items. + */ + selectedItems: { + type: Array, + readOnly: true, + notify: true + }, + + }, + + observers: [ + '_updateSelected(attrForSelected, selectedValues)' + ], + + /** + * Selects the given value. If the `multi` property is true, then the selected state of the + * `value` will be toggled; otherwise the `value` will be selected. + * + * @method select + * @param {string} value the value to select. + */ + select: function(value) { + if (this.multi) { + if (this.selectedValues) { + this._toggleSelected(value); + } else { + this.selectedValues = [value]; + } + } else { + this.selected = value; + } + }, + + multiChanged: function(multi) { + this._selection.multi = multi; + }, + + _updateSelected: function() { + if (this.multi) { + this._selectMulti(this.selectedValues); + } else { + this._selectSelected(this.selected); + } + }, + + _selectMulti: function(values) { + this._selection.clear(); + if (values) { + for (var i = 0; i < values.length; i++) { + this._selection.setItemSelected(this._valueToItem(values[i]), true); + } + } + }, + + _selectionChange: function() { + var s = this._selection.get(); + if (this.multi) { + this._setSelectedItems(s); + } else { + this._setSelectedItems([s]); + this._setSelectedItem(s); + } + }, + + _toggleSelected: function(value) { + var i = this.selectedValues.indexOf(value); + var unselected = i < 0; + if (unselected) { + this.selectedValues.push(value); + } else { + this.selectedValues.splice(i, 1); + } + this._selection.setItemSelected(this._valueToItem(value), unselected); + } + }; + + /** @polymerBehavior */ + Polymer.IronMultiSelectableBehavior = [ + Polymer.IronSelectableBehavior, + Polymer.IronMultiSelectableBehaviorImpl + ]; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable.html b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable.html new file mode 100644 index 0000000..233ff60 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-selectable.html"> + +</head><body><script src="iron-multi-selectable-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selectable-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selectable-extracted.js new file mode 100644 index 0000000..a17f626 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selectable-extracted.js @@ -0,0 +1,294 @@ + + + /** @polymerBehavior */ + Polymer.IronSelectableBehavior = { + + properties: { + + /** + * If you want to use the attribute value of an element for `selected` instead of the index, + * set this to the name of the attribute. + * + * @attribute attrForSelected + * @type {string} + */ + attrForSelected: { + type: String, + value: null + }, + + /** + * Gets or sets the selected element. The default is to use the index of the item. + * + * @attribute selected + * @type {string} + */ + selected: { + type: String, + notify: true + }, + + /** + * Returns the currently selected item. + * + * @attribute selectedItem + * @type {Object} + */ + selectedItem: { + type: Object, + readOnly: true, + notify: true + }, + + /** + * The event that fires from items when they are selected. Selectable + * will listen for this event from items and update the selection state. + * Set to empty string to listen to no events. + * + * @attribute activateEvent + * @type {string} + * @default 'tap' + */ + activateEvent: { + type: String, + value: 'tap', + observer: '_activateEventChanged' + }, + + /** + * This is a CSS selector sting. If this is set, only items that matches the CSS selector + * are selectable. + * + * @attribute selectable + * @type {string} + */ + selectable: String, + + /** + * The class to set on elements when selected. + * + * @attribute selectedClass + * @type {string} + */ + selectedClass: { + type: String, + value: 'iron-selected' + }, + + /** + * The attribute to set on elements when selected. + * + * @attribute selectedAttribute + * @type {string} + */ + selectedAttribute: { + type: String, + value: null + } + + }, + + observers: [ + '_updateSelected(attrForSelected, selected)' + ], + + excludedLocalNames: { + 'template': 1 + }, + + created: function() { + this._bindFilterItem = this._filterItem.bind(this); + this._selection = new Polymer.IronSelection(this._applySelection.bind(this)); + }, + + attached: function() { + this._observer = this._observeItems(this); + this._contentObserver = this._observeContent(this); + }, + + detached: function() { + if (this._observer) { + this._observer.disconnect(); + } + if (this._contentObserver) { + this._contentObserver.disconnect(); + } + this._removeListener(this.activateEvent); + }, + + /** + * Returns an array of selectable items. + * + * @property items + * @type Array + */ + get items() { + var nodes = Polymer.dom(this).queryDistributedElements(this.selectable || '*'); + return Array.prototype.filter.call(nodes, this._bindFilterItem); + }, + + /** + * Returns the index of the given item. + * + * @method indexOf + * @param {Object} item + * @returns Returns the index of the item + */ + indexOf: function(item) { + return this.items.indexOf(item); + }, + + /** + * Selects the given value. + * + * @method select + * @param {string} value the value to select. + */ + select: function(value) { + this.selected = value; + }, + + /** + * Selects the previous item. + * + * @method selectPrevious + */ + selectPrevious: function() { + var length = this.items.length; + var index = (Number(this._valueToIndex(this.selected)) - 1 + length) % length; + this.selected = this._indexToValue(index); + }, + + /** + * Selects the next item. + * + * @method selectNext + */ + selectNext: function() { + var index = (Number(this._valueToIndex(this.selected)) + 1) % this.items.length; + this.selected = this._indexToValue(index); + }, + + _addListener: function(eventName) { + this.listen(this, eventName, '_activateHandler'); + }, + + _removeListener: function(eventName) { + // There is no unlisten yet... + // https://github.com/Polymer/polymer/issues/1639 + //this.removeEventListener(eventName, this._bindActivateHandler); + }, + + _activateEventChanged: function(eventName, old) { + this._removeListener(old); + this._addListener(eventName); + }, + + _updateSelected: function() { + this._selectSelected(this.selected); + }, + + _selectSelected: function(selected) { + this._selection.select(this._valueToItem(this.selected)); + }, + + _filterItem: function(node) { + return !this.excludedLocalNames[node.localName]; + }, + + _valueToItem: function(value) { + return (value == null) ? null : this.items[this._valueToIndex(value)]; + }, + + _valueToIndex: function(value) { + if (this.attrForSelected) { + for (var i = 0, item; item = this.items[i]; i++) { + if (this._valueForItem(item) == value) { + return i; + } + } + } else { + return Number(value); + } + }, + + _indexToValue: function(index) { + if (this.attrForSelected) { + var item = this.items[index]; + if (item) { + return this._valueForItem(item); + } + } else { + return index; + } + }, + + _valueForItem: function(item) { + return item[this.attrForSelected] || item.getAttribute(this.attrForSelected); + }, + + _applySelection: function(item, isSelected) { + if (this.selectedClass) { + this.toggleClass(this.selectedClass, isSelected, item); + } + if (this.selectedAttribute) { + this.toggleAttribute(this.selectedAttribute, isSelected, item); + } + this._selectionChange(); + this.fire('iron-' + (isSelected ? 'select' : 'deselect'), {item: item}); + }, + + _selectionChange: function() { + this._setSelectedItem(this._selection.get()); + }, + + // observe content changes under the given node. + _observeContent: function(node) { + var content = node.querySelector('content'); + if (content && content.parentElement === node) { + return this._observeItems(node.domHost); + } + }, + + // observe items change under the given node. + _observeItems: function(node) { + var observer = new MutationObserver(function() { + if (this.selected != null) { + this._updateSelected(); + } + }.bind(this)); + observer.observe(node, { + childList: true, + subtree: true + }); + return observer; + }, + + _activateHandler: function(e) { + // TODO: remove this when https://github.com/Polymer/polymer/issues/1639 is fixed so we + // can just remove the old event listener. + if (e.type !== this.activateEvent) { + return; + } + var t = e.target; + var items = this.items; + while (t && t != this) { + var i = items.indexOf(t); + if (i >= 0) { + var value = this._indexToValue(i); + this._itemActivate(value, t); + return; + } + t = t.parentNode; + } + }, + + _itemActivate: function(value, item) { + if (!this.fire('iron-activate', + {selected: value, item: item}, {cancelable: true}).defaultPrevented) { + this.select(value); + } + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selectable.html b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selectable.html new file mode 100644 index 0000000..3d38f77 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selectable.html @@ -0,0 +1,11 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-selection.html"> + +</head><body><script src="iron-selectable-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selection-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selection-extracted.js new file mode 100644 index 0000000..2758326 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selection-extracted.js @@ -0,0 +1,102 @@ + + + /** + * @param {!Function} selectCallback + * @constructor + */ + Polymer.IronSelection = function(selectCallback) { + this.selection = []; + this.selectCallback = selectCallback; + }; + + Polymer.IronSelection.prototype = { + + /** + * Retrieves the selected item(s). + * + * @method get + * @returns Returns the selected item(s). If the multi property is true, + * `get` will return an array, otherwise it will return + * the selected item or undefined if there is no selection. + */ + get: function() { + return this.multi ? this.selection : this.selection[0]; + }, + + /** + * Clears all the selection except the ones indicated. + * + * @method clear + * @param {Array} excludes items to be excluded. + */ + clear: function(excludes) { + this.selection.slice().forEach(function(item) { + if (!excludes || excludes.indexOf(item) < 0) { + this.setItemSelected(item, false); + } + }, this); + }, + + /** + * Indicates if a given item is selected. + * + * @method isSelected + * @param {*} item The item whose selection state should be checked. + * @returns Returns true if `item` is selected. + */ + isSelected: function(item) { + return this.selection.indexOf(item) >= 0; + }, + + /** + * Sets the selection state for a given item to either selected or deselected. + * + * @method setItemSelected + * @param {*} item The item to select. + * @param {boolean} isSelected True for selected, false for deselected. + */ + setItemSelected: function(item, isSelected) { + if (item != null) { + if (isSelected) { + this.selection.push(item); + } else { + var i = this.selection.indexOf(item); + if (i >= 0) { + this.selection.splice(i, 1); + } + } + if (this.selectCallback) { + this.selectCallback(item, isSelected); + } + } + }, + + /** + * Sets the selection state for a given item. If the `multi` property + * is true, then the selected state of `item` will be toggled; otherwise + * the `item` will be selected. + * + * @method select + * @param {*} item The item to select. + */ + select: function(item) { + if (this.multi) { + this.toggle(item); + } else if (this.get() !== item) { + this.setItemSelected(this.get(), false); + this.setItemSelected(item, true); + } + }, + + /** + * Toggles the selection state for `item`. + * + * @method toggle + * @param {*} item The item to toggle. + */ + toggle: function(item) { + this.setItemSelected(item, !this.isSelected(item)); + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selection.html b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selection.html new file mode 100644 index 0000000..0fe482f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selection.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-selection-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selector-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selector-extracted.js new file mode 100644 index 0000000..d430655 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selector-extracted.js @@ -0,0 +1,57 @@ + + /** + `iron-selector` is an element which can be used to manage a list of elements + that can be selected. Tapping on the item will make the item selected. The `selected` indicates + which item is being selected. The default is to use the index of the item. + + Example: + + <iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> + </iron-selector> + + If you want to use the attribute value of an element for `selected` instead of the index, + set `attrForSelected` to the name of the attribute. For example, if you want to select item by + `name`, set `attrForSelected` to `name`. + + Example: + + <iron-selector attr-for-selected="name" selected="foo"> + <div name="foo">Foo</div> + <div name="bar">Bar</div> + <div name="zot">Zot</div> + </iron-selector> + + `iron-selector` is not styled. Use the `iron-selected` CSS class to style the selected element. + + Example: + + <style> + .iron-selected { + background: #eee; + } + </style> + + ... + + <iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> + </iron-selector> + + @demo demo/index.html + */ + + Polymer({ + + is: 'iron-selector', + + behaviors: [ + Polymer.IronMultiSelectableBehavior + ] + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selector.html b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selector.html new file mode 100644 index 0000000..f7afa25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-selector.html @@ -0,0 +1,11 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-multi-selectable.html"> + +</head><body><script src="iron-selector-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-signals/.bower.json new file mode 100644 index 0000000..36a1cb2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/.bower.json @@ -0,0 +1,29 @@ +{ + "name": "iron-signals", + "version": "1.0.1", + "description": "Basic publish-subscribe functionality", + "keywords": [ + "web-component", + "polymer", + "signals" + ], + "main": "iron-signals.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-signals/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "bd43f7706bfb9f8099bfcd017affa9378fb3fa4b" + }, + "_source": "git://github.com/PolymerElements/iron-signals.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-signals" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-signals/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/README.md b/third_party/polymer/v1_0/components-chromium/iron-signals/README.md new file mode 100644 index 0000000..fe82ffd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/README.md @@ -0,0 +1,26 @@ +iron-signals +============ + +`iron-signals` provides basic publish-subscribe functionality. + +Note: avoid using `iron-signals` whenever you can use +a controller (parent element) to mediate communication +instead. + +To send a signal, fire a custom event of type `iron-signal`, with +a detail object containing `name` and `data` fields. + +```javascript +this.fire('iron-signal', {name: 'hello', data: null}); +``` + +To receive a signal, listen for `iron-signal-<name>` event on a +`iron-signals` element. + +```html +<iron-signals on-iron-signal-hello="{{helloSignal}}"> +``` + +You can fire a signal event from anywhere, and all +`iron-signals` elements will receive the event, regardless +of where they are in DOM. diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/bower.json b/third_party/polymer/v1_0/components-chromium/iron-signals/bower.json new file mode 100644 index 0000000..73a984c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/bower.json @@ -0,0 +1,20 @@ +{ + "name": "iron-signals", + "version": "1.0.1", + "description": "Basic publish-subscribe functionality", + "keywords": [ + "web-component", + "polymer", + "signals" + ], + "main": "iron-signals.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-signals/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/index.html b/third_party/polymer/v1_0/components-chromium/iron-signals/index.html new file mode 100644 index 0000000..246af10 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/index.html @@ -0,0 +1,23 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/iron-signals-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-signals/iron-signals-extracted.js new file mode 100644 index 0000000..2fdc69f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/iron-signals-extracted.js @@ -0,0 +1,69 @@ + +(function(){ +/** +`iron-signals` provides basic publish-subscribe functionality. + +Note: avoid using `iron-signals` whenever you can use +a controller (parent element) to mediate communication +instead. + +To send a signal, fire a custom event of type `iron-signal`, with +a detail object containing `name` and `data` fields. + + this.fire('iron-signal', {name: 'hello', data: null}); + +To receive a signal, listen for `iron-signal-<name>` event on a +`iron-signals` element. + + <iron-signals on-iron-signal-hello="{{helloSignal}}"> + +You can fire a signal event from anywhere, and all +`iron-signals` elements will receive the event, regardless +of where they are in DOM. + +@demo demo/index.html +*/ + Polymer({ + is: 'iron-signals', + + attached: function() { + signals.push(this); + }, + detached: function() { + var i = signals.indexOf(this); + if (i >= 0) { + signals.splice(i, 1); + } + } + }); + + // private shared database + var signals = []; + + // signal dispatcher + function notify(name, data) { + // convert generic-signal event to named-signal event + var signal = new CustomEvent('iron-signal-' + name, { + // if signals bubble, it's easy to get confusing duplicates + // (1) listen on a container on behalf of local child + // (2) some deep child ignores the event and it bubbles + // up to said container + // (3) local child event bubbles up to container + // also, for performance, we avoid signals flying up the + // tree from all over the place + bubbles: false, + detail: data + }); + // dispatch named-signal to all 'signals' instances, + // only interested listeners will react + signals.forEach(function(s) { + s.dispatchEvent(signal); + }); + } + + // signal listener at document + document.addEventListener('iron-signal', function(e) { + notify(e.detail.name, e.detail.data); + }); + +})(); diff --git a/third_party/polymer/v1_0/components-chromium/iron-signals/iron-signals.html b/third_party/polymer/v1_0/components-chromium/iron-signals/iron-signals.html new file mode 100644 index 0000000..c4305e4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-signals/iron-signals.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="iron-signals-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/.bower.json new file mode 100644 index 0000000..0f3971ac --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-test-helpers", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "description": "Utility classes to help make testing easier", + "keywords": [ + "web-components", + "web-component", + "polymer", + "test" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-test-helpers" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-test-helpers", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "4c5d28f58adda0d076850321582cfe86359f95fb" + }, + "_source": "git://github.com/PolymerElements/iron-test-helpers.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-test-helpers" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/README.md b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/README.md new file mode 100644 index 0000000..dbc5318 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/README.md @@ -0,0 +1,23 @@ +# iron-test-helpers + +Utility classes to make testing easier. + +## Mock Interactions + +This is a set of methods to simulate mouse or keyboard interaction with an element. Include `mock-interactions.js` and then use them like so: + +```javascript +test('can be triggered with space', function(done) { + button.addEventListener('keydown', function() { + done(); + }); + MockInteractions.pressSpace(button); +}); + +test('can be clicked', function(done) { + button.addEventListener('click', function() { + done(); + }); + MockInteractions.down(button); +}); +``` diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/bower.json b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/bower.json new file mode 100644 index 0000000..4b3f5f3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-test-helpers", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "description": "Utility classes to help make testing easier", + "keywords": [ + "web-components", + "web-component", + "polymer", + "test" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-test-helpers" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-test-helpers", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/iron-test-helpers-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/iron-test-helpers-extracted.js new file mode 100644 index 0000000..4143fa5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/iron-test-helpers-extracted.js @@ -0,0 +1,10 @@ + + (function(global) { + 'use strict'; + + var TestHelpers = global.TestHelpers = global.TestHelpers || {}; + + TestHelpers.flushAsynchronousOperations = flushAsynchronousOperations; + TestHelpers.forceXIfStamp = forceXIfStamp; + TestHelpers.fireEvent = fireEvent; + })(this); diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/iron-test-helpers.html b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/iron-test-helpers.html new file mode 100644 index 0000000..8ca97fb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/iron-test-helpers.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><script src="mock-interactions.js"></script> +<script src="test-helpers.js"></script> +</head><body><script src="iron-test-helpers-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/mock-interactions.js b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/mock-interactions.js new file mode 100644 index 0000000..887b9be --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/mock-interactions.js @@ -0,0 +1,177 @@ +/** + * @license + * Copyright (c) 2014 The Polymer Project Authors. All rights reserved. + * This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + * The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + * The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + * Code distributed by Google as part of the polymer project is also + * subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + */ + +(function(global) { + 'use strict'; + + var HAS_NEW_MOUSE = (function() { + var has = false; + try { + has = Boolean(new MouseEvent('x')); + } catch (_) {} + return has; + })(); + + function middleOfNode(node) { + var bcr = node.getBoundingClientRect(); + return { + y: bcr.top + (bcr.height / 2), + x: bcr.left + (bcr.width / 2) + }; + } + + function topLeftOfNode(node) { + var bcr = node.getBoundingClientRect(); + return { + y: bcr.top, + x: bcr.left + }; + } + + function makeEvent(type, xy, node) { + var props = { + bubbles: true, + cancelable: true, + clientX: xy.x, + clientY: xy.y + }; + var e; + var mousetype = type === 'tap' ? 'click' : 'mouse' + type; + if (HAS_NEW_MOUSE) { + e = new MouseEvent(mousetype, props); + } else { + e = document.createEvent('MouseEvent'); + e.initMouseEvent(mousetype, props.bubbles, props.cancelable, null, null, 0, 0, + props.clientX, props.clientY, false, false, false, false, 0, null); + } + node.dispatchEvent(e); + } + + function down(node, xy) { + xy = xy || middleOfNode(node); + makeEvent('down', xy, node); + } + + function move(node, fromXY, toXY, steps) { + steps = steps || 5; + var dx = Math.round((fromXY.x - toXY.x) / steps); + var dy = Math.round((fromXY.y - toXY.y) / steps); + var xy = { + x: fromXY.x, + y: fromXY.y + }; + for (var i = steps; i > 0; i--) { + makeEvent('move', xy, node); + xy.x += dx; + xy.y += dy; + } + makeEvent('move', { + x: toXY.x, + y: toXY.y + }, node); + } + + function up(node, xy) { + xy = xy || middleOfNode(node); + makeEvent('up', xy, node); + } + + function tap(node) { + var xy = middleOfNode(node); + down(node, xy); + up(node, xy); + makeEvent('tap', xy, node); + } + + function focus(target) { + Polymer.Base.fire.call(target, 'focus'); + } + + function blur(target) { + Polymer.Base.fire.call(target, 'blur'); + } + + function downAndUp(target, callback) { + down(target); + Polymer.Base.async(function() { + up(target); + tap(target); + + callback && callback(); + }); + } + + function track(target, dx, dy, steps) { + dx = dx | 0; + dy = dy | 0; + steps = steps || 5; + down(target); + var xy = middleOfNode(target); + var xy2 = { + x: xy.x + dx, + y: xy.y + dy + }; + move(target, xy, xy2, steps); + up(target, xy2); + } + + function keyboardEventFor(type, keyCode) { + var event = new CustomEvent(type); + + event.keyCode = keyCode; + event.code = keyCode; + + return event; + } + + function keyEventOn(target, type, keyCode) { + target.dispatchEvent(keyboardEventFor(type, keyCode)); + } + + function keyDownOn(target, keyCode) { + keyEventOn(target, 'keydown', keyCode); + } + + function keyUpOn(target, keyCode) { + keyEventOn(target, 'keyup', keyCode); + } + + function pressAndReleaseKeyOn(target, keyCode) { + keyDownOn(target, keyCode); + Polymer.Base.async(function() { + keyUpOn(target, keyCode); + }, 1); + } + + function pressEnter(target) { + pressAndReleaseKeyOn(target, 13); + } + + function pressSpace(target) { + pressAndReleaseKeyOn(target, 32); + } + + global.MockInteractions = { + focus: focus, + blur: blur, + down: down, + up: up, + downAndUp: downAndUp, + tap: tap, + track: track, + pressAndReleaseKeyOn: pressAndReleaseKeyOn, + pressEnter: pressEnter, + pressSpace: pressSpace, + keyDownOn: keyDownOn, + keyUpOn: keyUpOn, + middleOfNode: middleOfNode, + topLeftOfNode: topLeftOfNode + }; +})(this); diff --git a/third_party/polymer/v1_0/components-chromium/iron-test-helpers/test-helpers.js b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/test-helpers.js new file mode 100644 index 0000000..3465186 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-test-helpers/test-helpers.js @@ -0,0 +1,39 @@ +/** + * @license + * Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + * This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + * The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + * The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + * Code distributed by Google as part of the polymer project is also + * subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + */ +(function(global) { + + global.flushAsynchronousOperations = function() { + // force distribution + Polymer.dom.flush(); + // force lifecycle callback to fire on polyfill + window.CustomElements && window.CustomElements.takeRecords(); + }; + + global.forceXIfStamp = function(node) { + var templates = Polymer.dom(node.root).querySelectorAll('template[is=dom-if]'); + for (var tmpl, i = 0; tmpl = templates[i]; i++) { + tmpl.render(); + } + + global.flushAsynchronousOperations(); + }; + + global.fireEvent = function(type, props, node) { + var event = new CustomEvent(type, { + bubbles: true, + cancelable: true + }); + for (p in props) { + event[p] = props[p]; + } + node.dispatchEvent(event); + }; + +})(this); diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/.bower.json new file mode 100644 index 0000000..e274324 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/.bower.json @@ -0,0 +1,43 @@ +{ + "name": "iron-validatable-behavior", + "version": "1.0.1", + "description": "Provides a behavior for an element that validates user input", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validatable-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validatable-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validatable-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "63513294174960e48dfb4617f55e716de3c9fc49" + }, + "_source": "git://github.com/PolymerElements/iron-validatable-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-validatable-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/README.md new file mode 100644 index 0000000..48f7fb2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/README.md @@ -0,0 +1,3 @@ +# iron-validatable-behavior +Implements an element validated with Polymer.IronValidatorBehavior + diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/bower.json new file mode 100644 index 0000000..3b66313 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/bower.json @@ -0,0 +1,34 @@ +{ + "name": "iron-validatable-behavior", + "version": "1.0.1", + "description": "Provides a behavior for an element that validates user input", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validatable-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validatable-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validatable-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/index.html new file mode 100644 index 0000000..cfaa5b1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-validatable-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/iron-validatable-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/iron-validatable-behavior-extracted.js new file mode 100644 index 0000000..e39fd9e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/iron-validatable-behavior-extracted.js @@ -0,0 +1,86 @@ + + + /** + * Use `Polymer.IronValidatableBehavior` to implement an element that validates user input. + * + * ### Accessiblity + * + * Changing the `invalid` property, either manually or by calling `validate()` will update the + * `aria-invalid` attribute. + * + * @demo demo/index.html + * @polymerBehavior + */ + Polymer.IronValidatableBehavior = { + + properties: { + + /** + * Namespace for this validator. + */ + validatorType: { + type: String, + value: 'validator' + }, + + /** + * Name of the validator to use. + */ + validator: { + type: String + }, + + /** + * True if the last call to `validate` is invalid. + */ + invalid: { + reflectToAttribute: true, + type: Boolean, + value: false + }, + + _validatorMeta: { + type: Object + } + + }, + + observers: [ + '_invalidChanged(invalid)' + ], + + get _validator() { + return this._validatorMeta && this._validatorMeta.byKey(this.validator); + }, + + ready: function() { + this._validatorMeta = new Polymer.IronMeta({type: this.validatorType}); + }, + + _invalidChanged: function() { + if (this.invalid) { + this.setAttribute('aria-invalid', 'true'); + } else { + this.removeAttribute('aria-invalid'); + } + }, + + /** + * @return {Boolean} True if the validator `validator` exists. + */ + hasValidator: function() { + return this._validator != null; + }, + + /** + * @param {Object} values Passed to the validator's `validate()` function. + * @return {Boolean} True if `values` is valid. + */ + validate: function(values) { + var valid = this._validator && this._validator.validate(values); + this.invalid = !valid; + return valid; + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/iron-validatable-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/iron-validatable-behavior.html new file mode 100644 index 0000000..bb455c6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validatable-behavior/iron-validatable-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +</head><body><script src="iron-validatable-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/.bower.json new file mode 100644 index 0000000..257b945 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/.bower.json @@ -0,0 +1,43 @@ +{ + "name": "iron-validator-behavior", + "version": "1.0.1", + "description": "Implements a input validator", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validator-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validator-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validator-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "fd9c609472c0c0b64657488d1d33dfc2365dea44" + }, + "_source": "git://github.com/PolymerElements/iron-validator-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-validator-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/README.md b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/README.md new file mode 100644 index 0000000..8aa8b61 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/README.md @@ -0,0 +1,4 @@ +# iron-validator-behavior +Use `Polymer.IronValidatorBehavior` to implement a custom input/form validator. Element instances +implementing this behavior will be registered for use in elements that implement +`Polymer.IronValidatableBehavior`. diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/bower.json new file mode 100644 index 0000000..7d57d72 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/bower.json @@ -0,0 +1,34 @@ +{ + "name": "iron-validator-behavior", + "version": "1.0.1", + "description": "Implements a input validator", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validator-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validator-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validator-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/index.html b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/index.html new file mode 100644 index 0000000..d0f6936 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-validator-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/iron-validator-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/iron-validator-behavior-extracted.js new file mode 100644 index 0000000..debc886 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/iron-validator-behavior-extracted.js @@ -0,0 +1,47 @@ + + + /** + * Use `Polymer.IronValidatorBehavior` to implement a custom input/form validator. Element + * instances implementing this behavior will be registered for use in elements that implement + * `Polymer.IronValidatableBehavior`. + * + * @demo demo/index.html + * @polymerBehavior + */ + Polymer.IronValidatorBehavior = { + + properties: { + + /** + * Namespace for this validator. + */ + validatorType: { + type: String, + value: 'validator' + }, + + /** + * Name for this validator, used by `Polymer.IronValidatableBehavior` to lookup this element. + */ + validatorName: { + type: String, + value: function() { + return this.is; + } + } + + }, + + ready: function() { + new Polymer.IronMeta({type: this.validatorType, key: this.validatorName, value: this}); + }, + + /** + * Implement custom validation logic in this function. + * @param {Object} values The value to validate. May be any type depending on the validation logic. + * @return {Boolean} true if `values` is valid. + */ + validate: function(values) { + } + }; + diff --git a/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/iron-validator-behavior.html b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/iron-validator-behavior.html new file mode 100644 index 0000000..71e9f2d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/iron-validator-behavior/iron-validator-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +</head><body><script src="iron-validator-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/.bower.json b/third_party/polymer/v1_0/components-chromium/more-routing/.bower.json new file mode 100644 index 0000000..1c6276c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/.bower.json @@ -0,0 +1,42 @@ +{ + "name": "more-routing", + "version": "1.0.0", + "authors": [ + "The Polymer Authors" + ], + "description": "A composable suite of objects and elements to make routing with web components a breeze.", + "keywords": [ + "web-component", + "web-components", + "polymer", + "routing", + "router" + ], + "main": "more-routing.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerLabs/more-routing/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "b9dcc768f789547bb99f65cd976006cb578af255" + }, + "_source": "git://github.com/PolymerLabs/more-routing.git", + "_target": "^1.0.0", + "_originalSource": "PolymerLabs/more-routing" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/README.md b/third_party/polymer/v1_0/components-chromium/more-routing/README.md new file mode 100644 index 0000000..880ccfe --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/README.md @@ -0,0 +1,338 @@ +Routing +======= + +A composable suite of objects and elements to make routing with web components +a breeze. + +* [Hash-](#MoreRouting.HashDriver) and [path-](#MoreRouting.PathDriver)based + routing. +* [Named routes](#more-routing). +* [Nested (mounted) routes](#more-route--nesting). +* [Declarative route switching](#more-route-switch). +* [Polymer helpers](#polymer-helpers--filters) for easy integration into existing elements. + +[Rob Dodson](https://github.com/robdodson) has whipped up a great video +that can get you started with more-routing: + +<p align="center"> + <a href="https://www.youtube.com/watch?v=-67kb7poIT8"> + <img src="http://img.youtube.com/vi/-67kb7poIT8/0.jpg" alt="Moar routing with... more-routing"> + </a> +</p> + +Or, TL;DR: + +```html +<link rel="import" href="../more-routing/more-routing.html"> + +<more-routing-config driver="path"></more-routing-config> +<more-route name="user" path="/users/:userId"> + <more-route name="user-bio" path="/bio"></more-route> +</more-route> + +<more-route-selector selectedParams="{{params}}"> + <core-pages> + <section route="/"> + This is the index. + </section> + + <section route="/about"> + It's a routing demo! + <a href="{{ urlFor('user-bio', {userId: 1}) }}">Read about user 1</a>. + </section> + + <section route="user"> + <header>Heyo user {{params.userId}}!</header> + <template if="{{ route('user-bio').active }}"> + All the details about {{params.userId}} that you didn't want to know... + </template> + </section> + </core-pages> +</more-route-selector> +``` + +And finally, check out [the demo](demo/) for a project that makes comprehensive +use of the various features in more-routing. + + +Element API +=========== + +<a name="more-routing-config"></a> +`<more-routing-config>` +---------------- + +_Defined in [`more-routing-config.html`](more-routing-config.html)._ + +The declarative interface for configuring [`MoreRouting`](#MoreRouting). +Currently, this lets you declare which [driver](#MoreRouting.Driver) you wish +to use (`hash` or `path`): + +```html +<more-routing-config driver="hash"></more-routing-config> +``` + +You should place this as early in the load process for your app as you can. Any +routes defined prior to the driver being set will trigger an error. + + +<a name="more-route"></a> +`<more-route>` +-------------- + +_Defined in [`more-route.html`](more-route.html)._ + +Reference routes by path, and extract their params: + +```html +<more-route path="/users/:userId" params="{{user}}"></more-route> +``` + +Declare a named route: + +```html +<more-route path="/users/:userId" name="user"></more-route> +``` + +Reference a named route: + +```html +<more-route name="user" params="{{user}}"></more-route> +``` + + +<a name="more-route--nesting"></a> +### Route Nesting + +Routes can also be nested: + +```html +<more-route path="/users/:userId" name="user"> + <more-route path="/bio" name="user-bio"></more-route> +</more-route> +``` + +In this example, the route named `user-bio` will match `/users/:userId/bio`. + +Finally, `<more-route>` elements can declare a routing context for the element +that contains them by setting the `context` attribute. See the +[routed elements](#more-route-selector--routed-elements) section for more info. + + +<a name="more-route-selector"></a> +`<more-route-selector>` +----------------------- + +_Defined in [`more-route-selector.html`](more-route-selector.html)._ + +Manages a [`<core-selector>`](https://www.polymer-project.org/docs/elements/core-elements.html#core-selector) +(or anything that extends it/looks like one), where each item in the selector +have an associated route. The most specific route that is active will be +selected. + +```html +<more-route-selector> + <core-pages> + <section route="/">The index!</section> + <section route="user">A user (named route)</section> + <section route="/about">Another route</section> + </core-pages> +</more-route-selector> +``` + +By default, `more-route-selector` will look for the `route` attribute on any +children of the `core-selector` (change this via `routeAttribute`). + +It exposes information about the selected route via a few properties: + +`selectedParams`: The params of the selected route. + +`selectedRoute`: The [`MoreRouting.Route`](#MoreRouting.Route) representing the +selected route. + +`selectedPath`: The path expression of the selected route. + +`selectedIndex`: The index of the selected route (relative to `routes`). + + +<a name="more-route-selector--routed-elements"></a> +### Routed Elements + +Elements can declare a route to be associated with, which allows +`<more-route-selector>` to be smart and use that as the route it checks against +for your element. For example: + +```html +<polymer-element name="routed-element"> + <template> + <more-route path="/my/route" context></more-route> + I'm a routed element! + </template> +</polymer-element> +``` + +```html +<more-route-selector> + <core-pages> + <section route="/">The index!</section> + <routed-element></routed-element> + </core-pages> +</more-route-selector> +``` + +In this example, The `<more-route-selector>` will choose `<routed-element>` +whenever the path begins with `/my/route`. Keep it DRY! + + +<a name="more-route-selector--nesting-contexts"></a> +### Nesting Contexts + +Similar to [`more-route`'s nesting behavior](#more-route--nesting), any items in +the core-selector also behave as nesting contexts. Any route declared within a +routing context is effectively _mounted_ on the context route. + +Taking the example element, `<routed-element>` above; if we were to add the +following to its template: + +```html +<more-route path="/:tab" params="{{params}}"></more-route> +``` + +That route's full path would be `/my/route/:tab`, because `/my/route` is the +context in which it is nested. This allows you to create custom elements that +make use of routes, _while not requiring knowledge of the app's route +hierarchy_. Very handy for composable components! + +**Note:** All items in a `<more-route-selector>` are treated as routing +contexts! + + +<a name="polymer-helpers"></a> +Polymer Helpers +--------------- + +<a name="polymer-helpers--filters"></a> +### Filters + +_Defined in [`polymer-expressions.html`](polymer-expressions.html)._ + +Several filters (functions) are exposed to templates for your convenience: + +#### `route` + +You can fetch a `MoreRouting.Route` object via the `route` filter. Handy for +reading params, etc on the fly. + +```html +<x-user model="{{ route('user').params }}"></x-user> +``` + +**Note:** The `route()` helper is unfortunately _not_ aware of the current +routing context. Consider using only named routes to avoid confusion! + +#### `urlFor` + +Generates a URL for the specified route and params: + +```html +<a href="{{ urlFor('user', {userId: 1}) }}">User 1</a> +``` + + +JavaScript API +============== + +<a name="MoreRouting"></a> +`MoreRouting` +------------- + +_Defined in [`routing.html`](routing.html)._ + +The main entry point into `more-routing`, exposed as a global JavaScript +namespace of `MoreRouting`. For the most part, all elements and helpers are +built on top of it. + +`MoreRouting` manages the current [driver](#MoreRouting.Driver), and maintains +an identity map of all routes. + + +<a name="MoreRouting.driver"></a> +### `MoreRouting.driver` + +Before you can make use of navigation and URL parsing, a driver must be +registered. Simply assign an instance of `MoreRouting.Driver` to this property. + +This is exposed as a declarative element via +[`<more-routing-config driver="...">`](#more-routing). + + +<a name="MoreRouting.getRoute"></a> +### `MoreRouting.getRoute` + +Returns a [`MoreRouting.Route`](#MoreRouting.Route), by path... + + MoreRouting.getRoute('/users/:userId') + +...or by name: + + MoreRouting.getRoute('user') + +Because routes are identity mapped, `getRoute` guarantees that it will return +the same `Route` object for the same path. + + +<a name="MoreRouting.Route"></a> +`MoreRouting.Route` +------------------- + +_Defined in [`route.html`](route.html)._ + +The embodiment for an individual route. It has various handy properties. +Highlights: + +``active``: Whether the route is active (the current URL matches). + +``params``: A map of param keys to their values (matching the `:named` tokens) +within the path. + +``path``: The path expression that this route matches. + +### Paths + +Path expressions begin with a `/` (to disambiguate them from route names), and +are a series of tokens separated by `/`. + +Tokens can be of the form `:named`, where they named a parameter. Or they can +be regular strings, at which point they are static path parts. + +Should be familiar from many other routing systems. + + +<a href="MoreRouting.Driver"></a> +`MoreRouting.Driver` +-------------------- + +_Defined in [`driver.html`](driver.html)._ + +Drivers manage how the URL is read, and how to navigate to URLs. There are two +built in drivers: + + +<a href="MoreRouting.HashDriver"></a> +### `MoreRouting.HashDriver` + +_Defined in [`hash-driver.html`](hash-driver.html)._ + +Provides hash-based routing, generating URLs like `#!/users/1/bio`. It has a +configurable prefix (after the `#`). By default, it uses a prefix of `!/` +(to fit the [AJAX-crawling spec](https://developers.google.com/webmasters/ajax-crawling/docs/specification)). + + +<a href="MoreRouting.PathDriver"></a> +### `MoreRouting.PathDriver` + +_Defined in [`path-driver.html`](path-driver.html)._ + +Provides true path-based routing (via `pushState`), generating URLs like +`/users/1/bio`. If your web app is mounted on a path other than `/`, you can +specify that mount point via the `prefix`. diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/bower.json b/third_party/polymer/v1_0/components-chromium/more-routing/bower.json new file mode 100644 index 0000000..e225285 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/bower.json @@ -0,0 +1,33 @@ +{ + "name": "more-routing", + "version": "1.0.0", + "authors": [ + "The Polymer Authors" + ], + "description": "A composable suite of objects and elements to make routing with web components a breeze.", + "keywords": [ + "web-component", + "web-components", + "polymer", + "routing", + "router" + ], + "main": "more-routing.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerLabs/more-routing/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/driver-extracted.js new file mode 100644 index 0000000..eaf1862 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver-extracted.js @@ -0,0 +1,104 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Driver = Driver; + +/** + * TODO(nevir): Docs. + */ +function Driver(opt_config) { + var config = opt_config || {}; + if (config.prefix) this.prefix = config.prefix; + + this._activeRoutes = []; + + this._rootRoutes = []; +} + +Driver.prototype.manageRoute = function manageRoute(route) { + route.driver = this; + this._appendRoute(route); + + if (route.parent) { + if (route.parent.active) { + // Remember: `processPathParts` takes just the path parts relative to that + // route; not the full set. + route.processPathParts(this.currentPathParts.slice(route.parent.depth)); + } + } else { + route.processPathParts(this.currentPathParts); + } + + if (route.active) this._activeRoutes.push(route); +}; + +Driver.prototype.urlForParts = function urlForParts(parts) { + return this.prefix + parts.join(this.separator); +}; + +Driver.prototype.navigateToParts = function(parts) { + return this.navigateToUrl(this.urlForParts(parts)); +}; + +Driver.prototype.navigateToUrl = function navigateToUrl(url) { + throw new Error(this.constructor.name + '#navigateToUrl not implemented'); +}; + +// Subclass Interface + +Driver.prototype.prefix = '/'; +Driver.prototype.separator = '/'; + +Driver.prototype.setCurrentPath = function setCurrentPath(path) { + this.currentPathParts = this.splitPath(path); + var newRoutes = this._matchingRoutes(this.currentPathParts); + + // active -> inactive. + for (var i = 0, route; route = this._activeRoutes[i]; i++) { + if (newRoutes.indexOf(route) === -1) { + route.processPathParts(null); + } + } + + this._activeRoutes = newRoutes; +} + +Driver.prototype.splitPath = function splitPath(rawPath) { + if (this.prefix && rawPath.indexOf(this.prefix) !== 0) { + throw new Error( + 'Invalid path "' + rawPath + '"; ' + + 'expected it to be prefixed by "' + this.prefix + '"'); + } + var path = rawPath.substr(this.prefix.length); + var parts = path.split(this.separator); + // Ignore trailing separators. + if (!parts[parts.length - 1]) parts.pop(); + + return parts; +}; + +// Internal Implementation +Driver.prototype._appendRoute = function _appendRoute(route) { + if (route.parent) { + // We only care about root routes. + return; + } + this._rootRoutes.push(route); +}; + +Driver.prototype._matchingRoutes = function _matchingRoutes(parts, rootRoutes) { + var routes = []; + var candidates = rootRoutes || this._rootRoutes; + var route; + for (var i = 0; i < candidates.length; i++) { + route = candidates[i]; + route.processPathParts(parts); + if (route.active) { + routes.push(route); + routes = routes.concat(this._matchingRoutes(parts.slice(route.compiled.length), route.children)); + } + } + return routes; +} + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver.html b/third_party/polymer/v1_0/components-chromium/more-routing/driver.html new file mode 100644 index 0000000..d0537730 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver.html @@ -0,0 +1,8 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head></head><body><script src="driver-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver/hash-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/driver/hash-extracted.js new file mode 100644 index 0000000..50abd21 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver/hash-extracted.js @@ -0,0 +1,35 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.HashDriver = HashDriver; + +/** + * TODO(nevir): Docs. + */ +function HashDriver() { + MoreRouting.Driver.apply(this, arguments); + this._bindEvents(); + this._read(); +} +HashDriver.prototype = Object.create(MoreRouting.Driver.prototype); + +// By default, we prefer hashbang; but you can prefix with any string you wish. +HashDriver.prototype.prefix = '!/'; + +HashDriver.prototype.urlForParts = function urlForParts(parts) { + return '#' + MoreRouting.Driver.prototype.urlForParts.call(this, parts); +}; + +HashDriver.prototype.navigateToUrl = function navigateToUrl(url) { + window.location.hash = url; +}; + +HashDriver.prototype._bindEvents = function _bindEvents() { + window.addEventListener('hashchange', this._read.bind(this)); +}; + +HashDriver.prototype._read = function _read() { + this.setCurrentPath(window.location.hash.substr(1) || this.prefix); +}; + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver/hash.html b/third_party/polymer/v1_0/components-chromium/more-routing/driver/hash.html new file mode 100644 index 0000000..d92ddca --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver/hash.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../driver.html"> + +</head><body><script src="hash-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver/mock-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/driver/mock-extracted.js new file mode 100644 index 0000000..0933095 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver/mock-extracted.js @@ -0,0 +1,16 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.MockDriver = MockDriver; + +/** A mock driver for use in your tests. */ +function MockDriver() { + MoreRouting.Driver.apply(this, arguments); +} +MockDriver.prototype = Object.create(MoreRouting.Driver.prototype); + +MockDriver.prototype.navigateToUrl = function navigateToUrl(url) { + this.setCurrentPath(url); +}; + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver/mock.html b/third_party/polymer/v1_0/components-chromium/more-routing/driver/mock.html new file mode 100644 index 0000000..764c9f0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver/mock.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../driver.html"> + +</head><body><script src="mock-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver/path-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/driver/path-extracted.js new file mode 100644 index 0000000..ad64fd57 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver/path-extracted.js @@ -0,0 +1,29 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.PathDriver = PathDriver; + +/** + * TODO(nevir): Docs. + */ +function PathDriver() { + MoreRouting.Driver.apply(this, arguments); + this._bindEvents(); + this._read(); +} +PathDriver.prototype = Object.create(MoreRouting.Driver.prototype); + +PathDriver.prototype.navigateToUrl = function navigateToUrl(url) { + window.history.pushState({}, '', url); + this._read(); +}; + +PathDriver.prototype._bindEvents = function _bindEvents() { + window.addEventListener('popstate', this._read.bind(this)); +}; + +PathDriver.prototype._read = function _read() { + this.setCurrentPath(window.location.pathname); +}; + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/driver/path.html b/third_party/polymer/v1_0/components-chromium/more-routing/driver/path.html new file mode 100644 index 0000000..c867f3bf --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/driver/path.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../driver.html"> + +</head><body><script src="path-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/emitter-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/emitter-extracted.js new file mode 100644 index 0000000..4846102 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/emitter-extracted.js @@ -0,0 +1,68 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Emitter = Object.create(null); // Minimal set of properties. + +/** + * A dumb prototype that provides very simple event subscription. + * + * You are responsible for initializing `__listeners` as an array on objects + * that make use of this. + */ +Object.defineProperties(MoreRouting.Emitter, { + + /** + * Registers a callback that will be called each time any parameter managed by + * this object (or its parents) have changed. + * + * @param {!Function} callback + * @return {{close: function()}} + */ + __subscribe: { + value: function __subscribe(callback) { + this.__listeners.push(callback); + + return { + close: this.__unsubscribe.bind(this, callback), + }; + }, + }, + + /** + * Unsubscribes a previously registered callback. + * + * @param {!Function} callback + */ + __unsubscribe: { + value: function __unsubscribe(callback) { + var index = this.__listeners.indexOf(callback); + if (index < 0) { + console.warn(this, 'attempted unsubscribe of unregistered listener:', callback); + return; + } + this.__listeners.splice(index, 1); + }, + }, + + /** + * Notifies subscribed callbacks. + */ + __notify: { + value: function __notify(key, value) { + if (this.__silent) return; + var args = Array.prototype.slice.call(arguments); + // Notify listeners on parents first. + var parent = Object.getPrototypeOf(this); + if (parent && parent.__notify && parent.__listeners) { + parent.__notify.apply(parent, args); + } + + this.__listeners.forEach(function(listener) { + listener.apply(null, args); + }.bind(this)); + }, + }, + +}); + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/emitter.html b/third_party/polymer/v1_0/components-chromium/more-routing/emitter.html new file mode 100644 index 0000000..0cfa486 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/emitter.html @@ -0,0 +1,8 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head></head><body><script src="emitter-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/index.html b/third_party/polymer/v1_0/components-chromium/more-routing/index.html new file mode 100644 index 0000000..67f8282 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-doc-viewer/iron-doc-viewer.html"> + +</head> +<body> + + <iron-doc-viewer></iron-doc-viewer> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-context-aware-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-context-aware-extracted.js new file mode 100644 index 0000000..38377c1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-context-aware-extracted.js @@ -0,0 +1,52 @@ + + + MoreRouting.ContextAware = { + + /** @override */ + ready: function() { + this._makeRoutingReady(); + }, + + /** + * Calls `routingReady`, and ensures that it is called in a top-down manner. + * + * We need to be sure that parent nodes have `routingReady` triggered before + * their children so that they can properly configure nested routes. + * + * Unfortunately, `ready` is sometimes bottom-up, sometimes top-down. + * Ideally, this wouldn't be necessary. + * + * @see https://github.com/Polymer/polymer/pull/1448 + */ + _makeRoutingReady: function() { + if (this.routingIsReady) return; + + var node = this; + while (node = Polymer.dom(node).parentNode) { + if (typeof node._makeRoutingReady === 'function') break; + } + if (node) node._makeRoutingReady(); + + this.parentRoute = this._findParentRoute(); + this.routingIsReady = true; + if (typeof this.routingReady === 'function') this.routingReady(); + }, + + _findParentRoute: function() { + var node = this; + while (node) { + node = Polymer.dom(node).parentNode; + if (node && node.nodeType !== Node.ELEMENT_NODE) { + node = node.host; + } + + var route = node && node.moreRouteContext; + if (route instanceof MoreRouting.Route) { + return route; + } + } + return null; + }, + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-context-aware.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-context-aware.html new file mode 100644 index 0000000..abc3b43 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-context-aware.html @@ -0,0 +1,13 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="route.html"> +<link rel="import" href="routing.html"> + +</head><body><script src="more-route-context-aware-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-extracted.js new file mode 100644 index 0000000..549aadf --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-extracted.js @@ -0,0 +1,179 @@ + + + Polymer({ + + is: 'more-route', + + behaviors: [ + MoreRouting.ContextAware, + ], + + properties: { + + /** + * The name of this route. Behavior differs based on the presence of + * `path` during _declaration_. + * + * If `path` is present during declaration, it is registered via `name`. + * + * Otherwise, this `more-route` becomes a `reference` to the route with + * `name`. Changing `name` will update which route is referenced. + */ + name: { + type: String, + observer: '_nameChanged', + }, + + /** + * A path expression used to parse parameters from the window's URL. + */ + path: { + type: String, + obserer: '_pathChanged', + }, + + /** + * Whether this route should become a context for the element that + * contains it. + */ + context: { + type: Boolean, + }, + + /** + * The underlying `MoreRouting.Route` object that is being wrapped. + * + * @type {MoreRouting.Route} + */ + route: { + type: Object, + readOnly: true, + notify: true, + observer: '_routeChanged', + }, + + /** + * The full path expression for this route, including routes this is + * nested within. + */ + fullPath: { + type: String, + readOnly: true, + notify: true, + }, + + /** + * Param values matching the current URL, or an empty object if not + * `active`. + */ + params: { + type: Object, + // readOnly: true, + notify: true, + }, + + /** + * Whether the route matches the current URL. + */ + active: { + type: Boolean, + readOnly: true, + notify: true, + }, + + }, + + routingReady: function() { + this._identityChanged(); + }, + + _nameChanged: function(newName, oldName) { + if (oldName) { + console.error('Changing the `name` property is not supported for', this); + return; + } + this._identityChanged(); + }, + + _pathChanged: function(newPath, oldPath) { + if (oldPath) { + console.error('Changing the `path` property is not supported for', this); + return; + } + this._identityChanged(); + }, + + _identityChanged: function() { + if (!this.routingIsReady) return; + + if (this.name && this.path) { + this._setRoute(MoreRouting.registerNamedRoute(this.name, this.path, this.parentRoute)); + } else if (this.name) { + this._setRoute(MoreRouting.getRouteByName(this.name)); + } else if (this.path) { + this._setRoute(MoreRouting.getRouteByPath(this.path, this.parentRoute)); + } else { + this._setRoute(null); + } + }, + + _routeChanged: function() { + this._observeRoute(); + this._setFullPath(this.route.fullPath); + // this._setParams(this.route.params); + this.params = this.route.params; + this._setActive(this.route.active); + + // @see MoreRouting.ContextAware + this.moreRouteContext = this.route; + + if (this.context) { + var parent = Polymer.dom(this).parentNode; + if (parent.nodeType !== Node.ELEMENT_NODE) { + parent = parent.host; + } + + if (parent.nodeType === Node.ELEMENT_NODE) { + parent.moreRouteContext = this.route; + } else { + console.warn('Unable to determine parent element for', this, '- not setting a context'); + } + } + }, + + _observeRoute: function() { + // TODO(nevir) https://github.com/Polymore/more-routing/issues/24 + if (this._routeListener) { + this._routeListener.close(); + this._routeListener = null; + } + if (this._paramListener) { + this._paramListener.close(); + this._paramListener = null; + } + if (!this.route) return; + + this._routeListener = this.route.__subscribe(function() { + this._setActive(this.route && this.route.active); + }.bind(this)); + + this._paramListener = this.route.params.__subscribe(function(key, value) { + // https://github.com/Polymer/polymer/issues/1505 + this.notifyPath('params.' + key, value); + }.bind(this)); + }, + + urlFor: function(params) { + return this.route.urlFor(params); + }, + + navigateTo: function(params) { + return this.route.navigateTo(params); + }, + + isCurrentUrl: function(params) { + return this.route.isCurrentUrl(params); + }, + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selection-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selection-extracted.js new file mode 100644 index 0000000..9e76752 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selection-extracted.js @@ -0,0 +1,180 @@ + + + Polymer({ + + is: 'more-route-selection', + + behaviors: [ + MoreRouting.ContextAware, + ], + + properties: { + + /** + * Routes to select from, as either a path expression or route name. + * + * You can either specify routes via this attribute, or as child nodes + * to this element, but not both. + * + * @type {String|Array<string|MoreRouting.Route>} + */ + routes: { + type: String, + observer: '_routesChanged', + }, + + /** + * The selected `MoreRouting.Route` object, or `null`. + * + * @type {MoreRouting.Route} + */ + selectedRoute: { + type: Object, + value: null, + readOnly: true, + notify: true, + }, + + /** + * The index of the selected route (relative to `routes`). -1 when there + * is no active route. + */ + selectedIndex: { + type: Number, + value: -1, + readOnly: true, + notify: true, + }, + + /** + * The _full_ path expression of the selected route, or `null`. + */ + selectedPath: { + type: String, + readOnly: true, + notify: true, + }, + + /** + * The params of the selected route, or an empty object if no route. + */ + selectedParams: { + type: Object, + readOnly: true, + notify: true, + }, + + }, + + /** + * @event more-route-change fires when a new route is selected. + * @detail {{ + * newRoute: MoreRouting.Route, oldRoute: MoreRouting.Route, + * newIndex: number, oldIndex: number, + * newPath: ?string, oldPath: ?string, + * newParams: Object, oldParams: Object, + * }} + */ + + routingReady: function() { + this._routesChanged(); + }, + + _routesChanged: function() { + if (!this.routingIsReady) return; + var routes = this.routes || []; + if (typeof routes === 'string') { + routes = routes.split(/\s+/); + } + this._routeInfo = this._sortIndexes(routes.map(function(route, index) { + return { + model: MoreRouting.getRoute(route, this.parentRoute), + index: index, + }; + }.bind(this))); + + this._observeRoutes(); + this._evaluate(); + }, + + /** + * Tracks changes to the routes. + */ + _observeRoutes: function() { + if (this._routeListeners) { + for (var i = 0, listener; listener = this._routeListeners[i]; i++) { + listener.close(); + } + } + + this._routeListeners = this._routeInfo.map(function(routeInfo) { + return routeInfo.model.__subscribe(this._evaluate.bind(this)); + }.bind(this)); + }, + + _evaluate: function() { + var newIndex = -1; + var newRoute = null; + var oldIndex = this.selectedIndex; + + for (var i = 0, routeInfo; routeInfo = this._routeInfo[i]; i++) { + if (routeInfo.model && routeInfo.model.active) { + newIndex = routeInfo.index; + newRoute = routeInfo.model; + break; + } + } + if (newIndex === oldIndex) return; + + var oldRoute = this.selectedRoute; + var oldPath = this.selectedPath; + var oldParams = this.selectedParams; + + var newPath = newRoute ? newRoute.fullPath : null; + var newParams = newRoute ? newRoute.params : {}; + + this._setSelectedRoute(newRoute); + this._setSelectedIndex(newIndex); + this._setSelectedPath(newPath); + this._setSelectedParams(newParams); + + this.fire('more-route-change', { + newRoute: newRoute, oldRoute: oldRoute, + newIndex: newIndex, oldIndex: oldIndex, + newPath: newPath, oldPath: oldPath, + newParams: newParams, oldParams: oldParams, + }); + }, + /** + * We want the most specific routes to match first, so we must create a + * mapping of indexes within `routes` that map + */ + _sortIndexes: function(routeInfo) { + return routeInfo.sort(function(a, b) { + if (!a.model) { + return 1; + } else if (!b.model) { + return -1; + // Routes with more path parts are most definitely more specific. + } else if (a.model.depth < b.model.depth) { + return 1; + } if (a.model.depth > b.model.depth) { + return -1; + } else { + + // Also, routes with fewer params are more specific. For example + // `/users/foo` is more specific than `/users/:id`. + if (a.model.numParams < b.model.numParams) { + return -1; + } else if (a.model.numParams > b.model.numParams) { + return 1; + } else { + // Equally specific; we fall back to the default (and hopefully + // stable) sort order. + return 0; + } + } + }); + }, + + }); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selection.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selection.html new file mode 100644 index 0000000..ff56bca --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selection.html @@ -0,0 +1,16 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="more-route-context-aware.html"> +<link rel="import" href="route.html"> + +<!-- +TODO(nevir): Document. +--> +</head><body><script src="more-route-selection-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selector-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selector-extracted.js new file mode 100644 index 0000000..07d17d1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selector-extracted.js @@ -0,0 +1,171 @@ + +Polymer({ + + is: 'more-route-selector', + + behaviors: [ + MoreRouting.ContextAware, + ], + + properties: { + + /** + * The attribute to read route expressions from (on children). + */ + routeAttribute: { + type: String, + value: 'route', + }, + + /** + * The routes managed by this element (inferred from the items that are + * defined by the selector it targets). + */ + routes: { + type: Array, + readOnly: true, + notify: true, + }, + + /** + * The selected `MoreRouting.Route` object, or `null`. + * + * @type {MoreRouting.Route} + */ + selectedRoute: { + type: Object, + value: null, + readOnly: true, + notify: true, + }, + + /** + * The index of the selected route (relative to `routes`). -1 when there + * is no active route. + */ + selectedIndex: { + type: Number, + value: -1, + readOnly: true, + notify: true, + }, + + /** + * The _full_ path expression of the selected route, or `null`. + */ + selectedPath: { + type: String, + readOnly: true, + notify: true, + }, + + /** + * The params of the selected route, or an empty object if no route. + */ + selectedParams: { + type: Object, + readOnly: true, + notify: true, + }, + + }, + + /** + * @event more-route-selected fires when a new route is selected. + * @param {{ + * newRoute: MoreRouting.Route, oldRoute: MoreRouting.Route, + * newIndex: number, oldIndex: number, + * newPath: ?string, oldPath: ?string, + * newParams: Object, oldParams: Object, + * }} + */ + + attached: function() { + this._managedSelector = this._findTargetSelector(); + if (!this._managedSelector) { + console.warn(this, 'was built without a selector to manage. It will do nothing.'); + return; + } + + this._managedSelector.addEventListener( + 'selected-item-changed', this._onSelectedItemChanged.bind(this)); + this._updateRoutes(); + }, + + /** + * Handle a change in selected item, driven by the targeted selector. + * + * Note that this will fail if a route is chosen that requires params not + * defined by the current URL. + */ + _onSelectedItemChanged: function(event) { + if (this._settingSelection) return; + var route = this._routeForItem(event.detail.value); + if (!route) return; + route.navigateTo(); + }, + + _updateRoutes: function() { + var routes = []; + if (this._managedSelector) { + routes = this._managedSelector.items.map(this._routeForItem.bind(this)); + } + this._setRoutes(routes); + }, + + _onMoreRouteChange: function(event) { + if (!this._managedSelector) return; + + var selected = ''; + + var index = this.routes.indexOf(event.detail.newRoute); + var attrForSelected = this._managedSelector.attrForSelected; + if (!attrForSelected) { + selected = index; + } else { + var item = this._managedSelector.items[index]; + if (item) + selected = item[attrForSelected] || item.getAttribute(attrForSelected); + } + + // Make sure that we don't turn around and re-navigate + this._settingSelection = true; + this._managedSelector.select(selected); + this._settingSelection = false; + }, + + _findTargetSelector: function() { + var children = Polymer.dom(this).children; + if (children.length !== 1) { + console.error(this, 'expects only a single selector child'); + return null; + } + + var child = children[0]; + if ('selected' in child && 'items' in child) { + return child; + } else { + console.error(this, 'can only manage children that are selectors'); + return null; + } + }, + + _routeForItem: function(item) { + if (!item) return null; + if (item.moreRouteContext && item.moreRouteContext instanceof MoreRouting.Route) { + return item.moreRouteContext; + } + + if (!item.hasAttribute(this.routeAttribute)) { + console.warn(item, 'is missing a context route or "' + this.routeAttribute + '" attribute'); + return null; + } + var expression = item.getAttribute(this.routeAttribute); + var route = MoreRouting.getRoute(expression, this.parentRoute); + // Associate the route w/ its element while we're here. + item.moreRouteContext = route; + + return route; + }, + +}); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selector.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selector.html new file mode 100644 index 0000000..bf4e175 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-selector.html @@ -0,0 +1,25 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="more-route-context-aware.html"> +<link rel="import" href="more-route-selection.html"> + +<!-- +TODO(nevir): Document. + +TODO(nevir): Support child addition/removal/reorder. +--> +</head><body><dom-module id="more-route-selector"> + <template> + <more-route-selection id="selection" routes="[[routes]]" on-more-route-change="_onMoreRouteChange"> + </more-route-selection> + <content></content> + </template> +</dom-module> +<script src="more-route-selector-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-template-helpers-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-template-helpers-extracted.js new file mode 100644 index 0000000..f3c2b56 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-template-helpers-extracted.js @@ -0,0 +1,22 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; + +/** + * Helper functions to spruce up your templates. + * + * @behavior + */ +MoreRouting.TemplateHelpers = { + + urlFor: function(pathOrName, params) { + return MoreRouting.urlFor(pathOrName, params); + }, + + isCurrentUrl: function(pathOrName, params) { + return MoreRouting.isCurrentUrl(pathOrName, params); + }, + +}; + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route-template-helpers.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-template-helpers.html new file mode 100644 index 0000000..6725ed3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route-template-helpers.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="routing.html"> + +</head><body><script src="more-route-template-helpers-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-route.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-route.html new file mode 100644 index 0000000..20c1d6c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-route.html @@ -0,0 +1,13 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="routing.html"> +<link rel="import" href="more-route-context-aware.html"> + +</head><body><script src="more-route-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-routing-config-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/more-routing-config-extracted.js new file mode 100644 index 0000000..1011224 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-routing-config-extracted.js @@ -0,0 +1,46 @@ + + + Polymer({ + + is: 'more-routing-config', + + properties: { + + /** + * The routing driver to use. + * + * * `hash`: `MoreRouting.HashDriver` + * * `path`: `MoreRouting.PathDriver` + * * `mock`: `MoreRouting.MockDriver` + * + */ + driver: String, + + /** + * + */ + urlPrefix: String, + + }, + + ready: function() { + var config = {}; + if (this.urlPrefix) config.prefix = this.urlPrefix; + + var driver; + // TODO(nevir): Support custom drivers, too. + if (this.driver === 'hash') { + driver = new MoreRouting.HashDriver(config); + } else if (this.driver === 'path') { + driver = new MoreRouting.PathDriver(config); + } else if (this.driver === 'mock') { + driver = new MoreRouting.MockDriver(config); + } else { + throw new Error('Unknown driver type "' + this.driver + '"'); + } + + MoreRouting.driver = driver; + }, + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-routing-config.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-routing-config.html new file mode 100644 index 0000000..5c72aba --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-routing-config.html @@ -0,0 +1,16 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="routing.html"> +<!-- TODO(nevir): import on demand? --> +<link rel="import" href="driver/hash.html"> +<link rel="import" href="driver/mock.html"> +<link rel="import" href="driver/path.html"> + +</head><body><script src="more-routing-config-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/more-routing.html b/third_party/polymer/v1_0/components-chromium/more-routing/more-routing.html new file mode 100644 index 0000000..43c3eeb3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/more-routing.html @@ -0,0 +1,12 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="more-routing-config.html"> +<link rel="import" href="routing.html"> +<link rel="import" href="more-route.html"> +<link rel="import" href="more-route-selector.html"> diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/params-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/params-extracted.js new file mode 100644 index 0000000..9a9a1ee --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/params-extracted.js @@ -0,0 +1,46 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Params = Params; + +/** + * A collection of route parameters and their values, with nofications. + * + * Params prefixed by `__` are reserved. + * + * @param {!Array<string>} params The keys of the params being managed. + * @param {Params=} parent A parent route's params to inherit. + * @return {Params} + */ +function Params(params, parent) { + var model = Object.create(parent || Params.prototype); + // We have a different set of listeners at every level of the hierarchy. + Object.defineProperty(model, '__listeners', {value: []}); + + // We keep all state enclosed within this closure so that inheritance stays + // relatively straightfoward. + var state = {}; + _compile(model, params, state); + + return model; +} +Params.prototype = Object.create(MoreRouting.Emitter); + +// Utility + +function _compile(model, params, state) { + params.forEach(function(param) { + Object.defineProperty(model, param, { + get: function() { + return state[param]; + }, + set: function(value) { + if (state[param] === value) return; + state[param] = value; + model.__notify(param, value); + }, + }); + }); +} + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/params.html b/third_party/polymer/v1_0/components-chromium/more-routing/params.html new file mode 100644 index 0000000..370be63 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/params.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="emitter.html"> + +</head><body><script src="params-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/route-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/route-extracted.js new file mode 100644 index 0000000..6f6e6fa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/route-extracted.js @@ -0,0 +1,214 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Route = Route; + +// Note that this can differ from the part separator defined by the driver. The +// driver's separator is used when parsing/generating URLs given to the client, +// whereas this one is for route definitions. +var PART_SEPARATOR = '/'; +var PARAM_SENTINEL = ':'; +var SEPARATOR_CLEANER = /\/\/+/g; + +/** + * TODO(nevir): Docs. + */ +function Route(path, parent) { + // For `MoreRouting.Emitter`; Emits changes for `active`. + this.__listeners = []; + + this.path = path; + this.parent = parent; + this.fullPath = path; + this.compiled = this._compile(this.path); + this.active = false; + this.driver = null; + + var params = MoreRouting.Params(namedParams(this.compiled), this.parent && this.parent.params); + params.__subscribe(this._navigateToParams.bind(this)); + Object.defineProperty(this, 'params', { + get: function() { return params; }, + set: function() { throw new Error('Route#params cannot be overwritten'); }, + }); + + this.parts = []; + this.children = []; + + // Param values matching the current URL, or an empty object if not `active`. + // + // To make data "binding" easy, `Route` guarantees that `params` will always + // be the same object; just make a reference to it. + if (this.parent) { + this.parent.children.push(this); + this.fullPath = this.parent.fullPath + this.fullPath; + this.depth = this.parent.depth + this.compiled.length; + this.numParams = this.parent.numParams + countParams(this.compiled); + } else { + this.depth = this.compiled.length; + this.numParams = countParams(this.compiled); + } +} +Route.prototype = Object.create(MoreRouting.Emitter); + +Object.defineProperty(Route.prototype, 'active', { + get: function() { + return this._active; + }, + set: function(value) { + if (value !== this._active); + this._active = value; + this.__notify('active', value); + }, +}); + +Route.isPath = function isPath(pathOrName) { + return pathOrName.indexOf(PART_SEPARATOR) === 0; +}; + +Route.joinPath = function joinPath(paths) { + var joined = Array.prototype.join.call(arguments, PART_SEPARATOR); + joined = joined.replace(SEPARATOR_CLEANER, PART_SEPARATOR); + + var minLength = joined.length - PART_SEPARATOR.length; + if (joined.substr(minLength) === PART_SEPARATOR) { + joined = joined.substr(0, minLength); + } + + return joined; +}; + +Route.prototype.urlFor = function urlFor(params) { + return this.driver.urlForParts(this.partsForParams(params)); +}; + +Route.prototype.navigateTo = function navigateTo(params) { + return this.driver.navigateToParts(this.partsForParams(params)); +} + +Route.prototype.isCurrentUrl = function isCurrentUrl(params) { + if (!this.active) return false; + var currentKeys = Object.keys(this.params); + for (var i = 0, key; key = currentKeys[i]; i++) { + if (this.params[key] !== String(params[key])) { + return false; + } + } + return true; +}; + +// Driver Interface + +Route.prototype.partsForParams = function partsForParams(params, silent) { + var parts = this.parent && this.parent.partsForParams(params, silent) || []; + for (var i = 0, config; config = this.compiled[i]; i++) { + if (config.type === 'static') { + parts.push(config.part); + } else if (config.type === 'param') { + var value + if (params && config.name in params) { + value = params[config.name]; + } else { + value = this.params[config.name]; + } + if (value === undefined) { + if (silent) { + return null; + } else { + throw new Error('Missing param "' + config.name + '" for route ' + this); + } + } + parts.push(value); + } + } + return parts; +}; + +/** + * Called by the driver whenever it has detected a change to the URL. + * + * @param {Array.<String>|null} parts The parts of the URL, or null if the + * route should be disabled. + */ +Route.prototype.processPathParts = function processPathParts(parts) { + this.parts = parts; + this.active = this.matchesPathParts(parts); + + // We don't want to notify of these changes; they'd be no-op noise. + this.params.__silent = true; + + if (this.active) { + var keys = Object.keys(this.params); + for (var i = 0; i < keys.length; i++) { + delete this.params[keys[i]]; + } + for (var i = 0, config; config = this.compiled[i]; i++) { + if (config.type === 'param') { + this.params[config.name] = parts[i]; + } + } + } else { + for (key in this.params) { + this.params[key] = undefined; + } + } + + delete this.params.__silent; +}; + +Route.prototype.matchesPathParts = function matchesPathParts(parts) { + if (!parts) return false; + if (parts.length < this.compiled.length) return false; + for (var i = 0, config; config = this.compiled[i]; i++) { + if (config.type === 'static' && parts[i] !== config.part) { + return false; + } + } + return true; +}; + +Route.prototype.toString = function toString() { + return this.path; +}; + +// Internal Implementation + +Route.prototype._compile = function _compile(rawPath) { + // Not strictly required, but helps us stay consistent w/ `getRoute`, etc. + if (rawPath.indexOf(PART_SEPARATOR) !== 0) { + throw new Error('Route paths must begin with a path separator; got: "' + rawPath + '"'); + } + var path = rawPath.substr(PART_SEPARATOR.length); + if (path === '') return []; + + return path.split(PART_SEPARATOR).map(function(part) { + // raw fragment. + if (part.substr(0, 1) == PARAM_SENTINEL) { + return {type: 'param', name: part.substr(1)}; + } else { + return {type: 'static', part: part}; + } + }); +}; + +Route.prototype._navigateToParams = function _navigateToParams() { + var parts = this.partsForParams(this.params, true); + if (!parts) return; + this.driver.navigateToParts(parts); +}; + +function countParams(compiled) { + return compiled.reduce(function(count, part) { + return count + (part.type === 'param' ? 1 : 0); + }, 0); +} + +function namedParams(compiled) { + var result = []; + compiled.forEach(function(part) { + if (part.type === 'static') return; + result.push(part.name); + }); + return result; +} + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/route.html b/third_party/polymer/v1_0/components-chromium/more-routing/route.html new file mode 100644 index 0000000..123f9cd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/route.html @@ -0,0 +1,11 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="emitter.html"> +<link rel="import" href="params.html"> + +</head><body><script src="route-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/routing-extracted.js b/third_party/polymer/v1_0/components-chromium/more-routing/routing-extracted.js new file mode 100644 index 0000000..008b8fa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/routing-extracted.js @@ -0,0 +1,126 @@ + +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; + +// Route singletons. +var routesByPath = {}; +var pathsByName = {}; + +// Route Management + +/** + * Retrieves (or builds) the singleton `Route` for the given path expression or + * route name. + * + * Paths begin with `/`; anything else is considered a name. + * + * For convenience, `Route` objects can also be passed (and will be returned) - + * this can be used as a route coercion function. + * + * @param {String|MoreRouting.Route} pathOrName + * @param {MoreRouting.Route} parent + * @return {MoreRouting.Route} + */ +MoreRouting.getRoute = function getRoute(pathOrName, parent) { + if (typeof pathOrName !== 'string') return pathOrName; + if (this.isPath(pathOrName)) { + return this.getRouteByPath(pathOrName, parent); + } else { + return this.getRouteByName(pathOrName); + } +} + +/** + * Retrieves (or builds) the singleton `Route` for the given path expression. + * + * @param {String} path + * @param {MoreRouting.Route} parent + * @return {MoreRouting.Route} + */ +MoreRouting.getRouteByPath = function getRouteByPath(path, parent) { + var fullPath = (parent ? parent.fullPath : '') + path; + if (!routesByPath[fullPath]) { + routesByPath[fullPath] = new this.Route(path, parent); + this.driver.manageRoute(routesByPath[fullPath]); + } + return routesByPath[fullPath]; +} + +/** + * Retrieves the route registered via `name`. + * + * @param {String} name + * @return {MoreRouting.Route} + */ +MoreRouting.getRouteByName = function getRouteByName(name) { + var path = pathsByName[name]; + if (!path) { + throw new Error('No route named "' + name + '" has been registered'); + } + return this.getRouteByPath(path); +} + +/** + * @param {String} path + * @return {MoreRouting.Route} The newly registered route. + */ +MoreRouting.registerNamedRoute = function registerNamedRoute(name, path, parent) { + if (pathsByName[name]) { + console.warn( + 'Overwriting route named "' + name + '" with path:', path, + 'previously:', pathsByName[name]); + } + var route = this.getRouteByPath(path, parent); + pathsByName[name] = route.fullPath; + return route; +}; + +// Route Shortcuts +MoreRouting.urlFor = function urlFor(pathOrName, params) { + return this.getRoute(pathOrName).urlFor(params); +}; + +MoreRouting.navigateTo = function navigateTo(pathOrName, params) { + return this.getRoute(pathOrName).navigateTo(params); +}; + +MoreRouting.isCurrentUrl = function isCurrentUrl(pathOrName, params) { + return this.getRoute(pathOrName).isCurrentUrl(params); +}; + +// Utility + +/** + * + */ +MoreRouting.isPath = function isPath(pathOrName) { + return this.Route.isPath(pathOrName); +} + +/** + * @param {...String} paths + */ +MoreRouting.joinPath = function joinPath(paths) { + return this.Route.joinPath.apply(this.Route, arguments); +} + +// Driver Management + +var driver; +Object.defineProperty(MoreRouting, 'driver', { + get: function getDriver() { + if (!driver) { + throw new Error('No routing driver configured. Did you forget <more-routing-config>?'); + } + return driver; + }, + set: function setDriver(newDriver) { + if (driver) { + console.warn('Changing routing drivers is not supported, ignoring. You should have only one <more-routing-config> on the page!'); + return; + } + driver = newDriver; + } +}); + +})(window); diff --git a/third_party/polymer/v1_0/components-chromium/more-routing/routing.html b/third_party/polymer/v1_0/components-chromium/more-routing/routing.html new file mode 100644 index 0000000..4780074 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/more-routing/routing.html @@ -0,0 +1,10 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="route.html"> + +</head><body><script src="routing-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/.bower.json b/third_party/polymer/v1_0/components-chromium/neon-animation/.bower.json new file mode 100644 index 0000000..9d394ec --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/.bower.json @@ -0,0 +1,60 @@ +{ + "name": "neon-animation", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "web-animations" + ], + "main": [ + "neon-animatable-behavior.html", + "neon-animation-behavior.html", + "neon-animation-runner-behavior.html", + "neon-shared-element-animatable-behavior.html", + "neon-shared-element-animation-behavior.html", + "neon-animated-pages.html", + "neon-animatable.html", + "neon-animations.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/neon-animation" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/neon-animation", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-animations-js": "web-animations/web-animations-js#^2.0.0" + }, + "devDependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "160f14c31b4692cc8073b67e8849e444b0695cde" + }, + "_source": "git://github.com/PolymerElements/neon-animation.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/neon-animation" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/.gitignore b/third_party/polymer/v1_0/components-chromium/neon-animation/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/README.md b/third_party/polymer/v1_0/components-chromium/neon-animation/README.md new file mode 100644 index 0000000..c1b258c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/README.md @@ -0,0 +1,304 @@ +# neon-animation + +`neon-animation` is a suite of elements and behaviors to implement pluggable animated transitions for Polymer Elements using [Web Animations](https://w3c.github.io/web-animations/). + +*Warning: The API may change.* + +* [A basic animatable element](#basic) +* [Animation configuration](#configuration) + * [Animation types](#configuration-types) + * [Configuration properties](#configuration-properties) + * [Using multiple animations](#configuration-multiple) + * [Running animations encapsulated in children nodes](#configuration-encapsulation) +* [Page transitions](#page-transitions) + * [Shared element animations](#shared-element) + * [Declarative page transitions](#declarative-page) +* [Included animations](#animations) +* [Demos](#demos) + +<a name="basic"></a> +## A basic animatable element + +Elements that can be animated should implement the `Polymer.NeonAnimatableBehavior` behavior, or `Polymer.NeonAnimationRunnerBehavior` if they're also responsible for running an animation. + +```js +Polymer({ + is: 'my-animatable', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + animationConfig: { + value: function() { + return { + // provided by neon-animation/animations/scale-down-animation.html + name: 'scale-down-animation', + node: this + } + } + } + }, + listeners: { + // this event is fired when the animation finishes + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + animate: function() { + // run scale-down-animation + this.playAnimation(); + }, + _onNeonAnimationFinish: function() { + console.log('animation done!'); + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/basic.html) + +<a name="configuration"></a> +## Animation configuration + +<a name="configuration-types"></a> +### Animation types + +An element might run different animations, for example it might do something different when it enters the view and when it exits from view. You can set the `animationConfig` property to a map from an animation type to configuration. + +```js +Polymer({ + is: 'my-dialog', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + opened: { + type: Boolean + }, + animationConfig: { + value: function() { + return { + 'entry': { + // provided by neon-animation/animations/scale-up-animation.html + name: 'scale-up-animation', + node: this + }, + 'exit': { + // provided by neon-animation-animations/fade-out-animation.html + name: 'fade-out-animation', + node: this + } + } + } + } + }, + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + show: function() { + this.opened = true; + this.style.display = 'inline-block'; + // run scale-up-animation + this.playAnimation('entry'); + }, + hide: function() { + this.opened = false; + // run fade-out-animation + this.playAnimation('fade-out-animation'); + }, + _onNeonAnimationFinish: function() { + if (!this.opened) { + this.style.display = 'none'; + } + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/types.html) + +You can also use the convenience properties `entryAnimation` and `exitAnimation` to set `entry` and `exit` animations: + +```js +properties: { + entryAnimation: { + value: 'scale-up-animation' + }, + exitAnimation: { + value: 'fade-out-animation' + } +} +``` + +<a name="configuration-properties"></a> +### Configuration properties + +You can pass additional parameters to configure an animation in the animation configuration object. +All animations should accept the following properties: + + * `name`: The name of an animation, ie. an element implementing `Polymer.NeonAnimationBehavior`. + * `node`: The target node to apply the animation to. Defaults to `this`. + * `timing`: Timing properties to use in this animation. They match the [Web Animations Animation Effect Timing interface](https://w3c.github.io/web-animations/#the-animationeffecttiming-interface). The + properties include the following: + * `duration`: The duration of the animation in milliseconds. + * `delay`: The delay before the start of the animation in milliseconds. + * `easing`: A timing function for the animation. Matches the CSS timing function values. + +Animations may define additional configuration properties and they are listed in their documentation. + +<a name="configuration-multiple"></a> +### Using multiple animations + +Set the animation configuration to an array to combine animations, like this: + +```js +animationConfig: { + value: function() { + return { + // fade-in-animation is run with a 50ms delay from slide-down-animation + 'entry': [{ + name: 'slide-down-animation', + node: this + }, { + name: 'fade-in-animation', + node: this, + timing: {delay: 50} + }] + } + } +} +``` + +<a name="configuration-encapsulation"></a> +### Running animations encapsulated in children nodes + +You can include animations in the configuration that are encapsulated in a child element that implement `Polymer.NeonAnimatableBehavior` with the `animatable` property. + +```js +animationConfig: { + value: function() { + return { + // run fade-in-animation on this, and the entry animation on this.$.myAnimatable + 'entry': [ + {name: 'fade-in-animation', node: this}, + {animatable: this.$.myAnimatable, type: 'entry'} + ] + } + } +} +``` + +<a name="page-transitions"></a> +## Page transitions + +*The artist formerly known as `<core-animated-pages>`* + +The `neon-animated-pages` element manages a set of pages to switch between, and runs animations between the page transitions. It implements the `Polymer.IronSelectableBehavior` behavior. Each child node should implement `Polymer.NeonAnimatableBehavior` and define the `entry` and `exit` animations. During a page transition, the `entry` animation is run on the new page and the `exit` animation is run on the old page. + +<a name="shared-element"></a> +### Shared element animations + +Shared element animations work on multiple nodes. For example, a "hero" animation is used during a page transition to make two elements from separate pages appear to animate as a single element. Shared element animation configurations have an `id` property that identify they belong in the same animation. Elements containing shared elements also have a `sharedElements` property defines a map from `id` to element, the element involved with the animation. + +In the incoming page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the incoming page defines the 'entry' animation + 'entry': { + name: 'hero-animation', + id: 'hero', + toPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.hero + } + } + } +} +``` + +In the outgoing page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the outgoing page defines the 'exit' animation + 'exit': { + name: 'hero-animation', + id: 'hero', + fromPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.otherHero + } + } + } +} +``` + +<a name="declarative-page"></a> +### Declarative page transitions + +For convenience, if you define the `entry-animation` and `exit-animation` attributes on `<neon-animated-pages>`, those animations will apply for all page transitions. + +For example: + +```js +<neon-animated-pages id="pages" class="flex" selected="[[selected]]" entry-animation="slide-from-right-animation" exit-animation="slide-left-animation"> + <neon-animatable>1</neon-animatable> + <neon-animatable>2</neon-animatable> + <neon-animatable>3</neon-animatable> + <neon-animatable>4</neon-animatable> + <neon-animatable>5</neon-animatable> +</neon-animated-pages> +``` + +The new page will slide in from the right, and the old page slide away to the left. + +<a name="animations"></a> +## Included animations + +Single element animations: + + * `fade-in-animation` Animates opacity from `0` to `1`. + * `fade-out-animation` Animates opacity from `1` to `0`. + * `scale-down-animation` Animates transform from `scale(1)` to `scale(0)`. + * `scale-up-animation` Animates transform from `scale(0)` to `scale(1)`. + * `slide-down-animation` Animates transform from `translateY(-100%)` to `none`. + * `slide-up-animation` Animates transform from `none` to `translateY(-100%)`. + * `slide-left-animation` Animates transform from `none` to `translateX(-100%)`; + * `slide-right-animation` Animates transform from `none` to `translateX(100%)`; + * `slide-from-left-animation` Animates transform from `translateX(-100%)` to `none`; + * `slide-from-right-animation` Animates transform from `translateX(100%)` to `none`; + * `transform-animation` Animates a custom transform. + +Note that there is a restriction that only one transform animation can be applied on the same element at a time. Use the custom `transform-animation` to combine transform properties. + +Shared element animations + + * `hero-animation` Animates an element such that it looks like it scales and transforms from another element. + * `ripple-animation` Animates an element to full screen such that it looks like it ripples from another element. + +Group animations + * `cascaded-animation` Applys an animation to an array of elements with a delay between each. + +<a name="demos"></a> +## Demos + + * [Grid to full screen](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/grid/index.html) + * [Animation on load](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/load/index.html) + * [List item to detail](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/list/index.html) (For narrow width) + * [Dots to squares](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/tiles/index.html) + * [Declarative](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/declarative/index.html) diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/cascaded-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/cascaded-animation-extracted.js new file mode 100644 index 0000000..7cdb976 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/cascaded-animation-extracted.js @@ -0,0 +1,53 @@ + + + Polymer({ + + is: 'cascaded-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + properties: { + + _animationMeta: { + type: Object, + value: function() { + return new Polymer.IronMeta({type: 'animation'}); + } + } + + }, + + configure: function(config) { + var animationConstructor = this._animationMeta.byKey(config.animation); + if (!animationConstructor) { + console.warn(this.is + ':', 'constructor for', config.animation, 'not found!'); + return; + } + + var nodes = config.nodes; + var effects = []; + var nodeDelay = config.nodeDelay || 50; + + config.timing = config.timing || {}; + config.timing.delay = config.timing.delay || 0; + + var oldDelay = config.timing.delay; + for (var node, index = 0; node = nodes[index]; index++) { + config.timing.delay += nodeDelay; + config.node = node; + + var animation = new animationConstructor(); + var effect = animation.configure(config); + + effects.push(effect); + } + config.timing.delay = oldDelay; + + this._effect = new GroupEffect(effects); + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/cascaded-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/cascaded-animation.html new file mode 100644 index 0000000..e8d3c74 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/cascaded-animation.html @@ -0,0 +1,29 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<cascaded-animation>` applies an animation on an array of elements with a delay between each. +the delay defaults to 50ms. + +Configuration: +``` +{ + name: 'cascaded-animation', + animation: <animation-name>, + nodes: <array-of-nodes>, + nodedelay: <node-delay-in-ms>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="cascaded-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-in-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-in-animation-extracted.js new file mode 100644 index 0000000..28666b1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-in-animation-extracted.js @@ -0,0 +1,21 @@ + + + Polymer({ + + is: 'fade-in-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + this._effect = new KeyframeEffect(node, [ + {'opacity': '0'}, + {'opacity': '1'} + ], this.timingFromConfig(config)); + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-in-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-in-animation.html new file mode 100644 index 0000000..d45421f8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-in-animation.html @@ -0,0 +1,26 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<fade-in-animation>` animates the opacity of an element from 0 to 1. + +Configuration: +``` +{ + name: 'fade-in-animation', + node: <node> + timing: <animation-timing> +} +``` +--> + +</head><body><script src="fade-in-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-out-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-out-animation-extracted.js new file mode 100644 index 0000000..3f06ec54 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-out-animation-extracted.js @@ -0,0 +1,21 @@ + + + Polymer({ + + is: 'fade-out-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + this._effect = new KeyframeEffect(node, [ + {'opacity': '1'}, + {'opacity': '0'} + ], this.timingFromConfig(config)); + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-out-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-out-animation.html new file mode 100644 index 0000000..df80eb8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/fade-out-animation.html @@ -0,0 +1,26 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<fade-out-animation>` animates the opacity of an element from 1 to 0. + +Configuration: +``` +{ + name: 'fade-out-animation', + node: <node> + timing: <animation-timing> +} +``` +--> + +</head><body><script src="fade-out-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/hero-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/hero-animation-extracted.js new file mode 100644 index 0000000..501d61e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/hero-animation-extracted.js @@ -0,0 +1,47 @@ + + + Polymer({ + + is: 'hero-animation', + + behaviors: [ + Polymer.NeonSharedElementAnimationBehavior + ], + + configure: function(config) { + var shared = this.findSharedElements(config); + if (!shared) { + return null; + } + + var fromRect = shared.from.getBoundingClientRect(); + var toRect = shared.to.getBoundingClientRect(); + + var deltaLeft = fromRect.left - toRect.left; + var deltaTop = fromRect.top - toRect.top; + var deltaWidth = fromRect.width / toRect.width; + var deltaHeight = fromRect.height / toRect.height; + + this.setPrefixedProperty(shared.to, 'transformOrigin', '0 0'); + shared.to.style.zIndex = 10000; + shared.from.style.visibility = 'hidden'; + + this._effect = new KeyframeEffect(shared.to, [ + {'transform': 'translate(' + deltaLeft + 'px,' + deltaTop + 'px) scale(' + deltaWidth + ',' + deltaHeight + ')'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + }, + + complete: function(config) { + var shared = this.findSharedElements(config); + if (!shared) { + return null; + } + shared.to.style.zIndex = ''; + shared.from.style.visibility = ''; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/hero-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/hero-animation.html new file mode 100644 index 0000000..b2ad28b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/hero-animation.html @@ -0,0 +1,34 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-shared-element-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<hero-animation>` is a shared element animation that scales and transform an element such that it +appears to be shared between two pages. Use this in `<neon-animated-pages>`. The source page +should use this animation in an 'exit' animation and set the `fromPage` configuration property to +itself, and the destination page should use this animation in an `entry` animation and set the +`toPage` configuration property to itself. They should also define the hero elements in the +`sharedElements` property (not a configuration property, see +`Polymer.NeonSharedElementAnimatableBehavior`). + +Configuration: +``` +{ + name: 'hero-animation', + id: <shared-element-id>, + timing: <animation-timing>, + toPage: <node>, /* define for the destination page */ + fromPage: <node>, /* define for the source page */ +} +``` +--> + +</head><body><script src="hero-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/opaque-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/opaque-animation-extracted.js new file mode 100644 index 0000000..c5a4b5c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/opaque-animation-extracted.js @@ -0,0 +1,26 @@ + + + Polymer({ + + is: 'opaque-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + node.style.opacity = '0'; + this._effect = new KeyframeEffect(node, [ + {'opacity': '1'}, + {'opacity': '1'} + ], this.timingFromConfig(config)); + return this._effect; + }, + + complete: function(config) { + config.node.style.opacity = ''; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/opaque-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/opaque-animation.html new file mode 100644 index 0000000..2ba7d76 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/opaque-animation.html @@ -0,0 +1,18 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<opaque-animation>` makes an element `opacity:1` for the duration of the animation. Used to prevent +webkit/safari from drawing a frame before an animation for elements that animate from display:none. +--> + +</head><body><script src="opaque-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/ripple-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/ripple-animation-extracted.js new file mode 100644 index 0000000..c7e8c71 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/ripple-animation-extracted.js @@ -0,0 +1,53 @@ + + + Polymer({ + + is: 'ripple-animation', + + behaviors: [ + Polymer.NeonSharedElementAnimationBehavior + ], + + configure: function(config, fromPage, toPage) { + var shared = this.findSharedElements(config, fromPage, toPage); + if (!shared) { + return null; + } + + var translateX, translateY; + var toRect = shared.to.getBoundingClientRect(); + if (config.gesture) { + translateX = config.gesture.x - (toRect.left + (toRect.width / 2)); + translateY = config.gesture.y - (toRect.left + (toRect.height / 2)); + } else { + var fromRect = shared.from.getBoundingClientRect(); + translateX = (fromRect.left + (fromRect.width / 2)) - (toRect.left + (toRect.width / 2)); + translateY = (fromRect.top + (fromRect.height / 2)) - (toRect.left + (toRect.height / 2)); + } + var translate = 'translate(' + translateX + 'px,' + translateY + 'px)'; + + var size = Math.max(toRect.width + Math.abs(translateX) * 2, toRect.height + Math.abs(translateY) * 2); + var diameter = Math.sqrt(2 * size * size); + var scaleX = diameter / toRect.width; + var scaleY = diameter / toRect.height; + var scale = 'scale(' + scaleX + ',' + scaleY + ')'; + + this.setPrefixedProperty(shared.to, 'transformOrigin', '50% 50%'); + shared.to.style.borderRadius = '50%'; + + this._effect = new KeyframeEffect(shared.to, [ + {'transform': translate + ' scale(0)'}, + {'transform': translate + ' ' + scale} + ], this.timingFromConfig(config)); + return this._effect; + }, + + complete: function() { + if (this.sharedElements) { + this.setPrefixedProperty(this.sharedElements.to, 'transformOrigin', ''); + this.sharedElements.to.style.borderRadius = ''; + } + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/ripple-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/ripple-animation.html new file mode 100644 index 0000000..e600cde --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/ripple-animation.html @@ -0,0 +1,37 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-shared-element-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<ripple-animation>` scales and transform an element such that it appears to ripple from either +a shared element, or from a screen position, to full screen. + +If using as a shared element animation in `<neon-animated-pages>`, use this animation in an `exit` +animation in the source page and in an `entry` animation in the destination page. Also, define the +hero elements in the `sharedElements` property (not a configuration property, see +`Polymer.NeonSharedElementAnimatableBehavior`). + +If using a screen position, define the `gesture` property. + +Configuration: +``` +{ + name: 'ripple-animation`. + id: <shared-element-id>, /* set this or gesture */ + gesture: {x: <page-x>, y: <page-y>}, /* set this or id */ + timing: <animation-timing>, + toPage: <node>, /* define for the destination page */ + fromPage: <node>, /* define for the source page */ +} +``` +--> + +</head><body><script src="ripple-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-down-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-down-animation-extracted.js new file mode 100644 index 0000000..c87a64c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-down-animation-extracted.js @@ -0,0 +1,34 @@ + + + Polymer({ + + is: 'scale-down-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } + + var scaleProperty = 'scale(0, 0)'; + if (config.axis === 'x') { + scaleProperty = 'scale(0, 1)'; + } else if (config.axis === 'y') { + scaleProperty = 'scale(1, 0)'; + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'scale(1,1)'}, + {'transform': scaleProperty} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-down-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-down-animation.html new file mode 100644 index 0000000..13b8127 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-down-animation.html @@ -0,0 +1,29 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<scale-down-animation>` animates the scale transform of an element from 1 to 0. By default it +scales in both the x and y axes. + +Configuration: +``` +{ + name: 'scale-down-animation', + node: <node>, + axis: 'x' | 'y' | '', + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="scale-down-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-up-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-up-animation-extracted.js new file mode 100644 index 0000000..a63aad6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-up-animation-extracted.js @@ -0,0 +1,27 @@ + + + Polymer({ + + is: 'scale-up-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'scale(0)'}, + {'transform': 'scale(1)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-up-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-up-animation.html new file mode 100644 index 0000000..e228b29 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/scale-up-animation.html @@ -0,0 +1,29 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<scale-up-animation>` animates the scale transform of an element from 0 to 1. By default it +scales in both the x and y axes. + +Configuration: +``` +{ + name: 'scale-up-animation', + node: <node>, + axis: 'x' | 'y' | '', + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="scale-up-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-down-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-down-animation-extracted.js new file mode 100644 index 0000000..e711b40 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-down-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'slide-down-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '50% 0'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translateY(-100%)'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-down-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-down-animation.html new file mode 100644 index 0000000..4f9a381 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-down-animation.html @@ -0,0 +1,28 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-down-animation>` animates the transform of an element from `translateY(-100%)` to `none`. +The `transformOrigin` defaults to `50% 0`. + +Configuration: +``` +{ + name: 'slide-down-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="slide-down-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-left-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-left-animation-extracted.js new file mode 100644 index 0000000..56cd846 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-left-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'slide-from-left-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translateX(-100%)'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-left-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-left-animation.html new file mode 100644 index 0000000..7c80eca --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-left-animation.html @@ -0,0 +1,29 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-from-left-animation>` animates the transform of an element from +`translateX(-100%)` to `none`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-from-left-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="slide-from-left-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-right-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-right-animation-extracted.js new file mode 100644 index 0000000..02f5b84 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-right-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'slide-from-right-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translateX(100%)'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-right-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-right-animation.html new file mode 100644 index 0000000..c862baf --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-from-right-animation.html @@ -0,0 +1,29 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-from-right-animation>` animates the transform of an element from +`translateX(100%)` to `none`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-from-right-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="slide-from-right-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-left-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-left-animation-extracted.js new file mode 100644 index 0000000..1948849 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-left-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'slide-left-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'none'}, + {'transform': 'translateX(-100%)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-left-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-left-animation.html new file mode 100644 index 0000000..518d1aa8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-left-animation.html @@ -0,0 +1,28 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-left-animation>` animates the transform of an element from `none` to `translateX(-100%)`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-left-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="slide-left-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-right-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-right-animation-extracted.js new file mode 100644 index 0000000..057b16b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-right-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'slide-right-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'none'}, + {'transform': 'translateX(100%)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-right-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-right-animation.html new file mode 100644 index 0000000..29c48a5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-right-animation.html @@ -0,0 +1,28 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-right-animation>` animates the transform of an element from `none` to `translateX(100%)`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-right-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="slide-right-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-up-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-up-animation-extracted.js new file mode 100644 index 0000000..5030ad5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-up-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'slide-up-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '50% 0'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translate(0)'}, + {'transform': 'translateY(-100%)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-up-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-up-animation.html new file mode 100644 index 0000000..2468bbd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/slide-up-animation.html @@ -0,0 +1,28 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-up-animation>` animates the transform of an element from `translateY(0)` to +`translateY(-100%)`. The `transformOrigin` defaults to `50% 0`. + +Configuration: +``` +{ + name: 'slide-up-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="slide-up-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/transform-animation-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/transform-animation-extracted.js new file mode 100644 index 0000000..bb8eabd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/transform-animation-extracted.js @@ -0,0 +1,29 @@ + + + Polymer({ + + is: 'transform-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + var transformFrom = config.transformFrom || 'none'; + var transformTo = config.transformTo || 'none'; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': transformFrom}, + {'transform': transformTo} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/animations/transform-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/transform-animation.html new file mode 100644 index 0000000..b645ce9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/animations/transform-animation.html @@ -0,0 +1,30 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-down-animation>` animates a custom transform on an element. Use this to animate multiple +transform properties, or to apply a custom transform value. + +Configuration: +``` +{ + name: 'slide-down-animation', + node: <node>, + transformOrigin: <transform-origin>, + transformFrom: <transform-from-string>, + transformTo: <transform-to-string>, + timing: <animation-timing> +} +``` +--> + +</head><body><script src="transform-animation-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/bower.json b/third_party/polymer/v1_0/components-chromium/neon-animation/bower.json new file mode 100644 index 0000000..4e687f6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/bower.json @@ -0,0 +1,51 @@ +{ + "name": "neon-animation", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "web-animations" + ], + "main": [ + "neon-animatable-behavior.html", + "neon-animation-behavior.html", + "neon-animation-runner-behavior.html", + "neon-shared-element-animatable-behavior.html", + "neon-shared-element-animation-behavior.html", + "neon-animated-pages.html", + "neon-animatable.html", + "neon-animations.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/neon-animation" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/neon-animation", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-animations-js": "web-animations/web-animations-js#^2.0.0" + }, + "devDependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/guides/neon-animation.md b/third_party/polymer/v1_0/components-chromium/neon-animation/guides/neon-animation.md new file mode 100644 index 0000000..7af1659 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/guides/neon-animation.md @@ -0,0 +1,313 @@ +--- +title: neon-animation +summary: "A short guide to neon-animation and neon-animated-pages" +tags: ['animation','core-animated-pages'] +elements: ['neon-animation','neon-animated-pages'] +updated: 2015-05-26 +--- + +# neon-animation + +`neon-animation` is a suite of elements and behaviors to implement pluggable animated transitions for Polymer Elements using [Web Animations](https://w3c.github.io/web-animations/). + +*Warning: The API may change.* + +* [A basic animatable element](#basic) +* [Animation configuration](#configuration) + * [Animation types](#configuration-types) + * [Configuration properties](#configuration-properties) + * [Using multiple animations](#configuration-multiple) + * [Running animations encapsulated in children nodes](#configuration-encapsulation) +* [Page transitions](#page-transitions) + * [Shared element animations](#shared-element) + * [Declarative page transitions](#declarative-page) +* [Included animations](#animations) +* [Demos](#demos) + +<a name="basic"></a> +## A basic animatable element + +Elements that can be animated should implement the `Polymer.NeonAnimatableBehavior` behavior, or `Polymer.NeonAnimationRunnerBehavior` if they're also responsible for running an animation. + +```js +Polymer({ + is: 'my-animatable', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + animationConfig: { + value: function() { + return { + // provided by neon-animation/animations/scale-down-animation.html + name: 'scale-down-animation', + node: this + } + } + } + }, + listeners: { + // this event is fired when the animation finishes + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + animate: function() { + // run scale-down-animation + this.playAnimation(); + }, + _onNeonAnimationFinish: function() { + console.log('animation done!'); + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/basic.html) + +<a name="configuration"></a> +## Animation configuration + +<a name="configuration-types"></a> +### Animation types + +An element might run different animations, for example it might do something different when it enters the view and when it exits from view. You can set the `animationConfig` property to a map from an animation type to configuration. + +```js +Polymer({ + is: 'my-dialog', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + opened: { + type: Boolean + }, + animationConfig: { + value: function() { + return { + 'entry': { + // provided by neon-animation/animations/scale-up-animation.html + name: 'scale-up-animation', + node: this + }, + 'exit': { + // provided by neon-animation-animations/fade-out-animation.html + name: 'fade-out-animation', + node: this + } + } + } + } + }, + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + show: function() { + this.opened = true; + this.style.display = 'inline-block'; + // run scale-up-animation + this.playAnimation('entry'); + }, + hide: function() { + this.opened = false; + // run fade-out-animation + this.playAnimation('fade-out-animation'); + }, + _onNeonAnimationFinish: function() { + if (!this.opened) { + this.style.display = 'none'; + } + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/types.html) + +You can also use the convenience properties `entryAnimation` and `exitAnimation` to set `entry` and `exit` animations: + +```js +properties: { + entryAnimation: { + value: 'scale-up-animation' + }, + exitAnimation: { + value: 'fade-out-animation' + } +} +``` + +<a name="configuration-properties"></a> +### Configuration properties + +You can pass additional parameters to configure an animation in the animation configuration object. +All animations should accept the following properties: + + * `name`: The name of an animation, ie. an element implementing `Polymer.NeonAnimationBehavior`. + * `node`: The target node to apply the animation to. Defaults to `this`. + * `timing`: Timing properties to use in this animation. They match the [Web Animations Animation Effect Timing interface](https://w3c.github.io/web-animations/#the-animationeffecttiming-interface). The + properties include the following: + * `duration`: The duration of the animation in milliseconds. + * `delay`: The delay before the start of the animation in milliseconds. + * `easing`: A timing function for the animation. Matches the CSS timing function values. + +Animations may define additional configuration properties and they are listed in their documentation. + +<a name="configuration-multiple"></a> +### Using multiple animations + +Set the animation configuration to an array to combine animations, like this: + +```js +animationConfig: { + value: function() { + return { + // fade-in-animation is run with a 50ms delay from slide-down-animation + 'entry': [{ + name: 'slide-down-animation', + node: this + }, { + name: 'fade-in-animation', + node: this, + timing: {delay: 50} + }] + } + } +} +``` + +<a name="configuration-encapsulation"></a> +### Running animations encapsulated in children nodes + +You can include animations in the configuration that are encapsulated in a child element that implement `Polymer.NeonAnimatableBehavior` with the `animatable` property. + +```js +animationConfig: { + value: function() { + return { + // run fade-in-animation on this, and the entry animation on this.$.myAnimatable + 'entry': [ + {name: 'fade-in-animation', node: this}, + {animatable: this.$.myAnimatable, type: 'entry'} + ] + } + } +} +``` + +<a name="page-transitions"></a> +## Page transitions + +*The artist formerly known as `<core-animated-pages>`* + +The `neon-animated-pages` element manages a set of pages to switch between, and runs animations between the page transitions. It implements the `Polymer.IronSelectableBehavior` behavior. Each child node should implement `Polymer.NeonAnimatableBehavior` and define the `entry` and `exit` animations. During a page transition, the `entry` animation is run on the new page and the `exit` animation is run on the old page. + +<a name="shared-element"></a> +### Shared element animations + +Shared element animations work on multiple nodes. For example, a "hero" animation is used during a page transition to make two elements from separate pages appear to animate as a single element. Shared element animation configurations have an `id` property that identify they belong in the same animation. Elements containing shared elements also have a `sharedElements` property defines a map from `id` to element, the element involved with the animation. + +In the incoming page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the incoming page defines the 'entry' animation + 'entry': { + name: 'hero-animation', + id: 'hero', + toPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.hero + } + } + } +} +``` + +In the outgoing page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the outgoing page defines the 'exit' animation + 'exit': { + name: 'hero-animation', + id: 'hero', + fromPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.otherHero + } + } + } +} +``` + +<a name="declarative-page"></a> +### Declarative page transitions + +For convenience, if you define the `entry-animation` and `exit-animation` attributes on `<neon-animated-pages>`, those animations will apply for all page transitions. + +For example: + +```js +<neon-animated-pages id="pages" class="flex" selected="[[selected]]" entry-animation="slide-from-right-animation" exit-animation="slide-left-animation"> + <neon-animatable>1</neon-animatable> + <neon-animatable>2</neon-animatable> + <neon-animatable>3</neon-animatable> + <neon-animatable>4</neon-animatable> + <neon-animatable>5</neon-animatable> +</neon-animated-pages> +``` + +The new page will slide in from the right, and the old page slide away to the left. + +<a name="animations"></a> +## Included animations + +Single element animations: + + * `fade-in-animation` Animates opacity from `0` to `1`. + * `fade-out-animation` Animates opacity from `1` to `0`. + * `scale-down-animation` Animates transform from `scale(1)` to `scale(0)`. + * `scale-up-animation` Animates transform from `scale(0)` to `scale(1)`. + * `slide-down-animation` Animates transform from `translateY(-100%)` to `none`. + * `slide-up-animation` Animates transform from `none` to `translateY(-100%)`. + * `slide-left-animation` Animates transform from `none` to `translateX(-100%)`; + * `slide-right-animation` Animates transform from `none` to `translateX(100%)`; + * `slide-from-left-animation` Animates transform from `translateX(-100%)` to `none`; + * `slide-from-right-animation` Animates transform from `translateX(100%)` to `none`; + + * `transform-animation` Animates a custom transform. + +Note that there is a restriction that only one transform animation can be applied on the same element at a time. Use the custom `transform-animation` to combine transform properties. + +Shared element animations + + * `hero-animation` Animates an element such that it looks like it scales and transforms from another element. + * `ripple-animation` Animates an element to full screen such that it looks like it ripples from another element. + +Group animations + * `cascaded-animation` Applys an animation to an array of elements with a delay between each. + +<a name="demos"></a> +## Demos + + * [Grid to full screen](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/grid/index.html) + * [Animation on load](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/load/index.html) + * [List item to detail](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/list/index.html) (For narrow width) + * [Dots to squares](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/tiles/index.html) + * [Declarative](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/declarative/index.html) diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/index.html b/third_party/polymer/v1_0/components-chromium/neon-animation/index.html new file mode 100644 index 0000000..6f5feed --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>neon-animation</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-behavior-extracted.js new file mode 100644 index 0000000..366388e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-behavior-extracted.js @@ -0,0 +1,143 @@ + + + /** + * `Polymer.NeonAnimatableBehavior` is implemented by elements containing animations for use with + * elements implementing `Polymer.NeonAnimationRunnerBehavior`. + * @polymerBehavior + */ + Polymer.NeonAnimatableBehavior = { + + properties: { + + /** + * Animation configuration. See README for more info. + */ + animationConfig: { + type: Object + }, + + /** + * Convenience property for setting an 'entry' animation. Do not set `animationConfig.entry` + * manually if using this. The animated node is set to `this` if using this property. + */ + entryAnimation: { + observer: '_entryAnimationChanged', + type: String + }, + + /** + * Convenience property for setting an 'exit' animation. Do not set `animationConfig.exit` + * manually if using this. The animated node is set to `this` if using this property. + */ + exitAnimation: { + observer: '_exitAnimationChanged', + type: String + } + + }, + + _entryAnimationChanged: function() { + this.animationConfig = this.animationConfig || {}; + if (this.entryAnimation !== 'fade-in-animation') { + // insert polyfill hack + this.animationConfig['entry'] = [{ + name: 'opaque-animation', + node: this + }, { + name: this.entryAnimation, + node: this + }]; + } else { + this.animationConfig['entry'] = [{ + name: this.entryAnimation, + node: this + }]; + } + }, + + _exitAnimationChanged: function() { + this.animationConfig = this.animationConfig || {}; + this.animationConfig['exit'] = [{ + name: this.exitAnimation, + node: this + }]; + }, + + _copyProperties: function(config1, config2) { + // shallowly copy properties from config2 to config1 + for (var property in config2) { + config1[property] = config2[property]; + } + }, + + _cloneConfig: function(config) { + var clone = { + isClone: true + }; + this._copyProperties(clone, config); + return clone; + }, + + _getAnimationConfigRecursive: function(type, map, allConfigs) { + if (!this.animationConfig) { + return; + } + + // type is optional + var thisConfig; + if (type) { + thisConfig = this.animationConfig[type]; + } else { + thisConfig = this.animationConfig; + } + + if (!Array.isArray(thisConfig)) { + thisConfig = [thisConfig]; + } + + // iterate animations and recurse to process configurations from child nodes + if (thisConfig) { + for (var config, index = 0; config = thisConfig[index]; index++) { + if (config.animatable) { + config.animatable._getAnimationConfigRecursive(config.type || type, map, allConfigs); + } else { + if (config.id) { + var cachedConfig = map[config.id]; + if (cachedConfig) { + // merge configurations with the same id, making a clone lazily + if (!cachedConfig.isClone) { + map[config.id] = this._cloneConfig(cachedConfig) + cachedConfig = map[config.id]; + } + this._copyProperties(cachedConfig, config); + } else { + // put any configs with an id into a map + map[config.id] = config; + } + } else { + allConfigs.push(config); + } + } + } + } + }, + + /** + * An element implementing `Polymer.NeonAnimationRunnerBehavior` calls this method to configure + * an animation with an optional type. Elements implementing `Polymer.NeonAnimatableBehavior` + * should define the property `animationConfig`, which is either a configuration object + * or a map of animation type to array of configuration objects. + */ + getAnimationConfig: function(type) { + var map = []; + var allConfigs = []; + this._getAnimationConfigRecursive(type, map, allConfigs); + // append the configurations saved in the map to the array + for (var key in map) { + allConfigs.push(map[key]); + } + return allConfigs; + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-behavior.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-behavior.html new file mode 100644 index 0000000..bceccfa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-behavior.html @@ -0,0 +1,11 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="animations/opaque-animation.html"> + +</head><body><script src="neon-animatable-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-extracted.js new file mode 100644 index 0000000..8fb41af --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable-extracted.js @@ -0,0 +1,12 @@ + + + Polymer({ + + is: 'neon-animatable', + + behaviors: [ + Polymer.NeonAnimatableBehavior + ] + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable.html new file mode 100644 index 0000000..11e6b93 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animatable.html @@ -0,0 +1,40 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="neon-animatable-behavior.html"> + +<!-- +`<neon-animatable>` is a simple container element implementing `Polymer.NeonAnimatableBehavior`. This is a convenience element for use with `<neon-animated-pages>`. + +``` +<neon-animated-pages selected="0" + entry-animation="slide-from-right-animation" + exit-animation="slide-left-animation"> + <neon-animatable>1</neon-animatable> + <neon-animatable>2</neon-animatable> +</neon-animated-pages> +``` +--> + +</head><body><dom-module id="neon-animatable"> + + <style> + + :host { + display: block; + } + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script src="neon-animatable-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animated-pages-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animated-pages-extracted.js new file mode 100644 index 0000000..596fd73 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animated-pages-extracted.js @@ -0,0 +1,152 @@ + +(function() { + + Polymer({ + + is: 'neon-animated-pages', + + behaviors: [ + Polymer.IronResizableBehavior, + Polymer.IronSelectableBehavior, + Polymer.NeonAnimationRunnerBehavior + ], + + properties: { + + activateEvent: { + type: String, + value: '' + }, + + // if true, the initial page selection will also be animated according to its animation config. + animateInitialSelection: { + type: Boolean, + value: false + } + + }, + + observers: [ + '_selectedChanged(selected)' + ], + + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + + _selectedChanged: function(selected) { + + var selectedPage = this.selectedItem; + var oldPage = this._prevSelected || false; + this._prevSelected = selectedPage; + + // on initial load and if animateInitialSelection is negated, simply display selectedPage. + if (!oldPage && !this.animateInitialSelection) { + this._completeSelectedChanged(); + return; + } + + // insert safari fix. + this.animationConfig = [{ + name: 'opaque-animation', + node: selectedPage + }]; + + // configure selectedPage animations. + if (this.entryAnimation) { + this.animationConfig.push({ + name: this.entryAnimation, + node: selectedPage + }); + } else { + if (selectedPage.getAnimationConfig) { + this.animationConfig.push({ + animatable: selectedPage, + type: 'entry' + }); + } + } + + // configure oldPage animations iff exists. + if (oldPage) { + + // cancel the currently running animation if one is ongoing. + if (oldPage.classList.contains('neon-animating')) { + this._squelchNextFinishEvent = true; + this.cancelAnimation(); + this._completeSelectedChanged(); + } + + // configure the animation. + if (this.exitAnimation) { + this.animationConfig.push({ + name: this.exitAnimation, + node: oldPage + }); + } else { + if (oldPage.getAnimationConfig) { + this.animationConfig.push({ + animatable: oldPage, + type: 'exit' + }); + } + } + + // display the oldPage during the transition. + oldPage.classList.add('neon-animating'); + } + + // display the selectedPage during the transition. + selectedPage.classList.add('neon-animating'); + + // actually run the animations. + if (this.animationConfig.length > 1) { + + // on first load, ensure we run animations only after element is attached. + if (!this.isAttached) { + this.async(function () { + this.playAnimation(null, { + fromPage: null, + toPage: selectedPage + }); + }); + + } else { + this.playAnimation(null, { + fromPage: oldPage, + toPage: selectedPage + }); + } + + } else { + this._completeSelectedChanged(oldPage, selectedPage); + } + }, + + _completeSelectedChanged: function(oldPage, selectedPage) { + if (selectedPage) { + selectedPage.classList.remove('neon-animating'); + } + if (oldPage) { + oldPage.classList.remove('neon-animating'); + } + if (!selectedPage || !oldPage) { + var nodes = Polymer.dom(this.$.content).getDistributedNodes(); + for (var node, index = 0; node = nodes[index]; index++) { + node.classList && node.classList.remove('neon-animating'); + } + } + this.async(this.notifyResize); + }, + + _onNeonAnimationFinish: function(event) { + if (this._squelchNextFinishEvent) { + this._squelchNextFinishEvent = false; + return; + } + this._completeSelectedChanged(event.detail.fromPage, event.detail.toPage); + } + + }) + +})(); diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animated-pages.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animated-pages.html new file mode 100644 index 0000000..379e739 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animated-pages.html @@ -0,0 +1,55 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="../iron-selector/iron-selectable.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="neon-animation-runner-behavior.html"> +<link rel="import" href="animations/opaque-animation.html"> + +<!-- +`neon-animated-pages` manages a set of pages and runs an animation when switching between them. Its +children pages should implement `Polymer.NeonAnimatableBehavior` and define `entry` and `exit` +animations to be run when switching to or switching out of the page. + +@group Neon Elements +@element neon-animated-pages +@demo demo/index.html +--> + +</head><body><dom-module id="neon-animated-pages"> + + <style> + + :host { + display: block; + position: relative; + } + + :host > ::content > * { + @apply(--layout-fit); + height: 100%; + } + + :host > ::content > :not(.iron-selected):not(.neon-animating) { + display: none !important; + } + + :host > ::content > .neon-animating { + pointer-events: none; + } + + </style> + + <template> + <content id="content"></content> + </template> + +</dom-module> + +<script src="neon-animated-pages-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-behavior-extracted.js new file mode 100644 index 0000000..cb52f51 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-behavior-extracted.js @@ -0,0 +1,74 @@ + + + /** + * Use `Polymer.NeonAnimationBehavior` to implement an animation. + * @polymerBehavior + */ + Polymer.NeonAnimationBehavior = { + + properties: { + + /** + * Defines the animation timing. + */ + animationTiming: { + type: Object, + value: function() { + return { + duration: 500, + easing: 'cubic-bezier(0.4, 0, 0.2, 1)', + fill: 'both' + } + } + } + + }, + + registered: function() { + new Polymer.IronMeta({type: 'animation', key: this.is, value: this.constructor}); + }, + + /** + * Do any animation configuration here. + */ + // configure: function(config) { + // }, + + /** + * Returns the animation timing by mixing in properties from `config` to the defaults defined + * by the animation. + */ + timingFromConfig: function(config) { + if (config.timing) { + for (var property in config.timing) { + this.animationTiming[property] = config.timing[property]; + } + } + return this.animationTiming; + }, + + /** + * Sets `transform` and `transformOrigin` properties along with the prefixed versions. + */ + setPrefixedProperty: function(node, property, value) { + var map = { + 'transform': ['webkitTransform'], + 'transformOrigin': ['mozTransformOrigin', 'webkitTransformOrigin'] + }; + var prefixes = map[property]; + for (var prefix, index = 0; prefix = prefixes[index]; index++) { + node.style[prefix] = value; + } + node.style[property] = value; + }, + + /** + * Called when the animation finishes. + */ + complete: function() { + // FIXME not sure about non-bubbling event + this.fire(this.animationEndEvent, null, {bubbles: false}); + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-behavior.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-behavior.html new file mode 100644 index 0000000..121e9b7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +</head><body><script src="neon-animation-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-runner-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-runner-behavior-extracted.js new file mode 100644 index 0000000..6600ec6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-runner-behavior-extracted.js @@ -0,0 +1,97 @@ + + + /** + * `Polymer.NeonAnimationRunnerBehavior` adds a method to run animations. + * @polymerBehavior + */ + Polymer.NeonAnimationRunnerBehavior = [Polymer.NeonAnimatableBehavior, { + + properties: { + + _animationMeta: { + type: Object, + value: function() { + return new Polymer.IronMeta({type: 'animation'}); + } + }, + + _player: { + type: Object + } + + }, + + _configureAnimationEffects: function(allConfigs) { + var allAnimations = []; + if (allConfigs.length > 0) { + for (var config, index = 0; config = allConfigs[index]; index++) { + var animationConstructor = this._animationMeta.byKey(config.name); + if (animationConstructor) { + var animation = animationConstructor && new animationConstructor(); + var effect = animation.configure(config); + if (effect) { + allAnimations.push({ + animation: animation, + config: config, + effect: effect + }); + } + } else { + console.warn(this.is + ':', config.name, 'not found!'); + } + } + } + return allAnimations; + }, + + _runAnimationEffects: function(allEffects) { + return player = document.timeline.play(new GroupEffect(allEffects)); + }, + + _completeAnimations: function(allAnimations) { + for (var animation, index = 0; animation = allAnimations[index]; index++) { + animation.animation.complete(animation.config); + } + }, + + /** + * Plays an animation with an optional `type`. + */ + playAnimation: function(type, cookie) { + var allConfigs = this.getAnimationConfig(type); + if (!allConfigs) { + return; + } + var allAnimations = this._configureAnimationEffects(allConfigs); + var allEffects = allAnimations.map(function(animation) { + return animation.effect; + }); + + if (allEffects.length > 0) { + this._player = this._runAnimationEffects(allEffects); + this._player.onfinish = function() { + this._completeAnimations(allAnimations); + + if (this._player) { + this._player.cancel(); + this._player = null; + } + + this.fire('neon-animation-finish', cookie, {bubbles: false}); + }.bind(this); + + } else { + this.fire('neon-animation-finish', cookie, {bubbles: false}); + } + }, + + /** + * Cancels the currently running animation. + */ + cancelAnimation: function() { + if (this._player) { + this._player.cancel(); + } + } + + }]; diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-runner-behavior.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-runner-behavior.html new file mode 100644 index 0000000..92132fb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation-runner-behavior.html @@ -0,0 +1,12 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> +<link rel="import" href="neon-animatable-behavior.html"> + +</head><body><script src="neon-animation-runner-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation.html new file mode 100644 index 0000000..150068a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animation.html @@ -0,0 +1,17 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="neon-animatable-behavior.html"> +<link rel="import" href="neon-animated-pages.html"> +<link rel="import" href="neon-animatable.html"> +<link rel="import" href="neon-animation-behavior.html"> +<link rel="import" href="neon-animation-runner-behavior.html"> +<link rel="import" href="neon-animations.html"> +<link rel="import" href="neon-shared-element-animatable-behavior.html"> +<link rel="import" href="neon-shared-element-animation-behavior.html"> diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animations.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animations.html new file mode 100644 index 0000000..f3bdf49 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-animations.html @@ -0,0 +1,25 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="animations/cascaded-animation.html"> +<link rel="import" href="animations/fade-in-animation.html"> +<link rel="import" href="animations/fade-out-animation.html"> +<link rel="import" href="animations/hero-animation.html"> +<link rel="import" href="animations/opaque-animation.html"> +<link rel="import" href="animations/ripple-animation.html"> +<link rel="import" href="animations/scale-down-animation.html"> +<link rel="import" href="animations/scale-up-animation.html"> +<link rel="import" href="animations/slide-from-left-animation.html"> +<link rel="import" href="animations/slide-from-right-animation.html"> +<link rel="import" href="animations/slide-left-animation.html"> +<link rel="import" href="animations/slide-right-animation.html"> +<link rel="import" href="animations/slide-up-animation.html"> +<link rel="import" href="animations/slide-down-animation.html"> +<link rel="import" href="animations/transform-animation.html"> + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animatable-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animatable-behavior-extracted.js new file mode 100644 index 0000000..8724e9e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animatable-behavior-extracted.js @@ -0,0 +1,23 @@ + + + /** + * Use `Polymer.NeonSharedElementAnimatableBehavior` to implement elements containing shared element + * animations. + * @polymerBehavior + */ + Polymer.NeonSharedElementAnimatableBehavior = [Polymer.NeonAnimatableBehavior, { + + properties: { + + /** + * A map of shared element id to node. + */ + sharedElements: { + type: Object, + value: {} + } + + } + + }]; + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animatable-behavior.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animatable-behavior.html new file mode 100644 index 0000000..e78bf55 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animatable-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="neon-animatable-behavior.html"> + +</head><body><script src="neon-shared-element-animatable-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animation-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animation-behavior-extracted.js new file mode 100644 index 0000000..e5cd7c9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animation-behavior-extracted.js @@ -0,0 +1,52 @@ + + + /** + * Use `Polymer.NeonSharedElementAnimationBehavior` to implement shared element animations. + * @polymerBehavior + */ + Polymer.NeonSharedElementAnimationBehavior = [Polymer.NeonAnimationBehavior, { + + properties: { + + /** + * Cached copy of shared elements. + */ + sharedElements: { + type: Object + } + + }, + + /** + * Finds shared elements based on `config`. + */ + findSharedElements: function(config) { + var fromPage = config.fromPage; + var toPage = config.toPage; + if (!fromPage || !toPage) { + console.warn(this.is + ':', !fromPage ? 'fromPage' : 'toPage', 'is undefined!'); + return null; + }; + + if (!fromPage.sharedElements || !toPage.sharedElements) { + console.warn(this.is + ':', 'sharedElements are undefined for', !fromPage.sharedElements ? fromPage : toPage); + return null; + }; + + var from = fromPage.sharedElements[config.id] + var to = toPage.sharedElements[config.id]; + + if (!from || !to) { + console.warn(this.is + ':', 'sharedElement with id', config.id, 'not found in', !from ? fromPage : toPage); + return null; + } + + this.sharedElements = { + from: from, + to: to + }; + return this.sharedElements; + } + + }]; + diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animation-behavior.html b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animation-behavior.html new file mode 100644 index 0000000..da56257 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/neon-shared-element-animation-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="neon-animation-behavior.html"> + +</head><body><script src="neon-shared-element-animation-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/neon-animation/web-animations.html b/third_party/polymer/v1_0/components-chromium/neon-animation/web-animations.html new file mode 100644 index 0000000..c871854 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/neon-animation/web-animations.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<script src="../web-animations-js/web-animations-next-lite.min.js"></script> diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-behaviors/.bower.json new file mode 100644 index 0000000..4036b8dcc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-behaviors", + "version": "1.0.0", + "description": "Common behaviors across the paper elements", + "authors": [ + "The Polymer Authors" + ], + "main": [ + "paper-button-behavior.html", + "paper-radio-button-behavior.html" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "behavior" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-behaviors" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-behaviors", + "dependencies": { + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "cf1b11e381a8df169efe2c3aaf08e2787dda31b9" + }, + "_source": "git://github.com/PolymerElements/paper-behaviors.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-behaviors" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-behaviors/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/README.md b/third_party/polymer/v1_0/components-chromium/paper-behaviors/README.md new file mode 100644 index 0000000..e793a62 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/README.md @@ -0,0 +1,4 @@ +paper-behaviors +=============== + +These are common behaviors used across `paper-*` elements. diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/bower.json b/third_party/polymer/v1_0/components-chromium/paper-behaviors/bower.json new file mode 100644 index 0000000..0d55094 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-behaviors", + "version": "1.0.0", + "description": "Common behaviors across the paper elements", + "authors": [ + "The Polymer Authors" + ], + "main": [ + "paper-button-behavior.html", + "paper-radio-button-behavior.html" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "behavior" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-behaviors" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-behaviors", + "dependencies": { + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/index.html b/third_party/polymer/v1_0/components-chromium/paper-behaviors/index.html new file mode 100644 index 0000000..3e003cb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="paper-button-behavior.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-button-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-button-behavior-extracted.js new file mode 100644 index 0000000..5b2319a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-button-behavior-extracted.js @@ -0,0 +1,41 @@ + + + /** @polymerBehavior */ + Polymer.PaperButtonBehaviorImpl = { + + properties: { + + _elevation: { + type: Number + } + + }, + + observers: [ + '_calculateElevation(focused, disabled, active, pressed, receivedFocusFromKeyboard)' + ], + + hostAttributes: { + role: 'button', + tabindex: '0' + }, + + _calculateElevation: function() { + var e = 1; + if (this.disabled) { + e = 0; + } else if (this.active || this.pressed) { + e = 4; + } else if (this.receivedFocusFromKeyboard) { + e = 3; + } + this._elevation = e; + } + }; + + Polymer.PaperButtonBehavior = [ + Polymer.IronButtonState, + Polymer.IronControlState, + Polymer.PaperButtonBehaviorImpl + ]; + diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-button-behavior.html b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-button-behavior.html new file mode 100644 index 0000000..00b4e4c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-button-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-behaviors/iron-button-state.html"> + +</head><body><script src="paper-button-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-radio-button-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-radio-button-behavior-extracted.js new file mode 100644 index 0000000..11c5cfc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-radio-button-behavior-extracted.js @@ -0,0 +1,26 @@ + + + /** @polymerBehavior */ + Polymer.PaperRadioButtonInk = { + + observers: [ + '_focusedChanged(receivedFocusFromKeyboard)' + ], + + _focusedChanged: function(receivedFocusFromKeyboard) { + if (!this.$.ink) { + return; + } + + this.$.ink.holdDown = receivedFocusFromKeyboard; + } + + }; + + /** @polymerBehavior */ + Polymer.PaperRadioButtonBehavior = [ + Polymer.IronButtonState, + Polymer.IronControlState, + Polymer.PaperRadioButtonInk + ]; + diff --git a/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-radio-button-behavior.html b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-radio-button-behavior.html new file mode 100644 index 0000000..28c0d5b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-behaviors/paper-radio-button-behavior.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-behaviors/iron-button-state.html"> + +</head><body><script src="paper-radio-button-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-button/.bower.json new file mode 100644 index 0000000..21100e3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-button", + "version": "1.0.1", + "description": "Material design button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "button" + ], + "main": "paper-button.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-button", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "e11a0603feaaedd8cf6c7e0d533bdc67de24c8de" + }, + "_source": "git://github.com/PolymerElements/paper-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/README.md b/third_party/polymer/v1_0/components-chromium/paper-button/README.md new file mode 100644 index 0000000..035b004 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/README.md @@ -0,0 +1,45 @@ +paper-button +============ + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-button` is a button. When the user touches the button, a ripple effect emanates +from the point of contact. It may be flat or raised. A raised button is styled with a +shadow. + +Example: +```html + <paper-button>flat button</paper-button> + <paper-button raised>raised button</paper-button> + <paper-button noink>No ripple effect</paper-button> +``` +You may use custom DOM in the button body to create a variety of buttons. For example, to +create a button with an icon and some text: + +```html + <paper-button> + <iron-icon icon="favorite"></iron-icon> + custom button content + </paper-button> +``` +## Styling + +Style the button with CSS as you would a normal DOM element. + +```css + /* make #my-button green with yellow text */ + #my-button { + background: green; + color: yellow; + } +``` +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + +```css + /* make #my-button use a blue ripple instead of foreground color */ + #my-button::shadow paper-ripple { + color: blue; + } +``` +The opacity of the ripple is not customizable via CSS. diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/bower.json b/third_party/polymer/v1_0/components-chromium/paper-button/bower.json new file mode 100644 index 0000000..940aa6d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-button", + "version": "1.0.1", + "description": "Material design button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "button" + ], + "main": "paper-button.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-button", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/index.html b/third_party/polymer/v1_0/components-chromium/paper-button/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/paper-button-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-button/paper-button-extracted.js new file mode 100644 index 0000000..a4b23fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/paper-button-extracted.js @@ -0,0 +1,40 @@ + + + Polymer({ + + is: 'paper-button', + + behaviors: [ + Polymer.PaperButtonBehavior + ], + + properties: { + + /** + * If true, the button should be styled with a shadow. + */ + raised: { + type: Boolean, + reflectToAttribute: true, + value: false, + observer: '_calculateElevation' + } + }, + + _calculateElevation: function() { + if (!this.raised) { + this._elevation = 0; + } else { + Polymer.PaperButtonBehaviorImpl._calculateElevation.apply(this); + } + }, + + _computeContentClass: function(receivedFocusFromKeyboard) { + var className = 'content '; + if (receivedFocusFromKeyboard) { + className += ' keyboard-focus'; + } + return className; + } + }); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-button/paper-button.html b/third_party/polymer/v1_0/components-chromium/paper-button/paper-button.html new file mode 100644 index 0000000..f32d104 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-button/paper-button.html @@ -0,0 +1,135 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-material/paper-material.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-behaviors/paper-button-behavior.html"> + +<!-- + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-button` is a button. When the user touches the button, a ripple effect emanates +from the point of contact. It may be flat or raised. A raised button is styled with a +shadow. + +Example: + + <paper-button>flat button</paper-button> + <paper-button raised>raised button</paper-button> + <paper-button noink>No ripple effect</paper-button> + +You may use custom DOM in the button body to create a variety of buttons. For example, to +create a button with an icon and some text: + + <paper-button> + <core-icon icon="favorite"></core-icon> + custom button content + </paper-button> + +### Styling + +Style the button with CSS as you would a normal DOM element. + + /* make #my-button green with yellow text */ + #my-button { + background: green; + color: yellow; + } + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + + /* make #my-button use a blue ripple instead of foreground color */ + #my-button::shadow paper-ripple { + color: blue; + } + +The opacity of the ripple is not customizable via CSS. + +The following custom properties and mixins are also available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-button-flat-focus-color` | Background color of a focused flat button | `--paper-grey-200` +`--paper-button` | Mixin applied to the button | `{}` +`--paper-button-disabled` | Mixin applied to the disabled button | `{}` + +@demo demo/index.html +--> + +</head><body><dom-module id="paper-button"> + + <style> + + :host { + display: inline-block; + position: relative; + box-sizing: border-box; + min-width: 5.14em; + margin: 0 0.29em; + background: transparent; + text-align: center; + font: inherit; + text-transform: uppercase; + outline: none; + border-radius: 3px; + -moz-user-select: none; + -ms-user-select: none; + -webkit-user-select: none; + user-select: none; + cursor: pointer; + z-index: 0; + + @apply(--paper-button); + } + + .keyboard-focus { + font-weight: bold; + } + + :host([disabled]) { + background: #eaeaea; + color: #a8a8a8; + cursor: auto; + pointer-events: none; + + @apply(--paper-button-disabled); + } + + :host([noink]) paper-ripple { + display: none; + } + + paper-material { + border-radius: inherit; + } + + .content > ::content * { + text-transform: inherit; + } + + .content { + padding: 0.7em 0.57em + } + </style> + + <template> + + <paper-ripple></paper-ripple> + + <paper-material class$="[[_computeContentClass(receivedFocusFromKeyboard)]]" elevation="[[_elevation]]" animated=""> + <content></content> + </paper-material> + + </template> + +</dom-module> + +<script src="paper-button-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-checkbox/.bower.json new file mode 100644 index 0000000..27f1492 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "paper-checkbox", + "version": "1.0.1", + "description": "A material design checkbox", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "paper", + "checkbox", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-checkbox" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-checkbox", + "ignore": [], + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "d7b372fecace143f83ec67d323be9504308e5f5f" + }, + "_source": "git://github.com/PolymerElements/paper-checkbox.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-checkbox" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-checkbox/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/README.md b/third_party/polymer/v1_0/components-chromium/paper-checkbox/README.md new file mode 100644 index 0000000..2269079 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/README.md @@ -0,0 +1,31 @@ +# paper-checkbox + +`paper-checkbox` is a button that can be either checked or unchecked. User +can tap the checkbox to check or uncheck it. Usually you use checkboxes +to allow user to select multiple options from a set. If you have a single +ON/OFF option, avoid using a single checkbox and use `paper-toggle-button` +instead. + +Example: + +```html +<paper-checkbox>label</paper-checkbox> + +<paper-checkbox checked>label</paper-checkbox> +``` + +Styling a checkbox: + +```html +<style is="custom-style"> + paper-checkbox { + /* Unhecked state colors. */ + --paper-checkbox-unchecked-color: #5a5a5a; + --paper-checkbox-unchecked-ink-color: #5a5a5a; + + /* Checked state colors. */ + --paper-checkbox-checked-color: #009688; + --paper-checkbox-checked-ink-color: #009688; + } +</style> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/bower.json b/third_party/polymer/v1_0/components-chromium/paper-checkbox/bower.json new file mode 100644 index 0000000..6ae5621 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-checkbox", + "version": "1.0.1", + "description": "A material design checkbox", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "paper", + "checkbox", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-checkbox" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-checkbox", + "ignore": [], + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/index.html b/third_party/polymer/v1_0/components-chromium/paper-checkbox/index.html new file mode 100644 index 0000000..b368797 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-checkbox</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/metadata.html b/third_party/polymer/v1_0/components-chromium/paper-checkbox/metadata.html new file mode 100644 index 0000000..4d068e8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/metadata.html @@ -0,0 +1,17 @@ +<!-- + @license + Copyright (c) 2014 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<x-meta id="paper-checkbox" label="Checkbox" group="Paper"> + <template> + <paper-checkbox label="click me"></paper-checkbox> + </template> + <template id="imports"> + <link rel="import" href="paper-checkbox.html"> + </template> +</x-meta> diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox-extracted.js new file mode 100644 index 0000000..c166e07 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox-extracted.js @@ -0,0 +1,87 @@ + + Polymer({ + is: 'paper-checkbox', + + behaviors: [ + Polymer.PaperRadioButtonBehavior + ], + + hostAttributes: { + role: 'checkbox', + 'aria-checked': false, + tabindex: 0 + }, + + properties: { + /** + * Fired when the checked state changes due to user interaction. + * + * @event change + */ + + /** + * Fired when the checked state changes. + * + * @event iron-change + */ + + /** + * Gets or sets the state, `true` is checked and `false` is unchecked. + */ + checked: { + type: Boolean, + value: false, + reflectToAttribute: true, + notify: true, + observer: '_checkedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + */ + toggles: { + type: Boolean, + value: true, + reflectToAttribute: true + } + }, + + ready: function() { + if (Polymer.dom(this).textContent == '') { + this.$.checkboxLabel.hidden = true; + } else { + this.setAttribute('aria-label', Polymer.dom(this).textContent); + } + this._isReady = true; + }, + + // button-behavior hook + _buttonStateChanged: function() { + if (this.disabled) { + return; + } + if (this._isReady) { + this.checked = this.active; + } + }, + + _checkedChanged: function(checked) { + this.setAttribute('aria-checked', this.checked ? 'true' : 'false'); + this.active = this.checked; + this.fire('iron-change'); + }, + + _computeCheckboxClass: function(checked) { + if (checked) { + return 'checked'; + } + }, + + _computeCheckmarkClass: function(checked) { + if (!checked) { + return 'hidden'; + } + } + }) +
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox.css b/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox.css new file mode 100644 index 0000000..eb203fd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox.css @@ -0,0 +1,149 @@ +/* +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: inline-block; + white-space: nowrap; +} + +:host(:focus) { + outline: none; +} + +.hidden { + display: none; +} + +#checkboxContainer { + display: inline-block; + position: relative; + width: 18px; + height: 18px; + cursor: pointer; + -webkit-transform: translateZ(0); + transform: translateZ(0); + vertical-align: middle; +} + +:host #ink { + position: absolute; + top: -15px; + left: -15px; + width: 48px; + height: 48px; + color: var(--paper-checkbox-unchecked-ink-color); + opacity: 0.6; +} + +:host #ink[checked] { + color: var(--paper-checkbox-checked-ink-color); +} + +:host #checkbox { + position: relative; + box-sizing: border-box; + height: 100%; + border: solid 2px; + border-color: var(--paper-checkbox-unchecked-color); + border-radius: 2px; + pointer-events: none; + -webkit-transition: background-color 140ms, border-color 140ms; + transition: background-color 140ms, border-color 140ms; +} + +/* checkbox checked animations */ +#checkbox.checked #checkmark { + -webkit-animation: checkmark-expand 140ms ease-out forwards; + animation: checkmark-expand 140ms ease-out forwards; +} + +@-webkit-keyframes checkmark-expand { + 0% { + top: 9px; + left: 6px; + width: 0px; + height: 0px; + } + 100% { + top: -1px; + left: 4px; + width: 5px; + height: 10px; + } +} + +@keyframes checkmark-expand { + 0% { + top: 9px; + left: 6px; + width: 0px; + height: 0px; + } + 100% { + top: -1px; + left: 4px; + width: 5px; + height: 10px; + } +} + +:host #checkbox.checked { + background-color: var(--paper-checkbox-checked-color); + border-color: var(--paper-checkbox-checked-color); +} + +:host #checkmark { + -webkit-transform: rotate(45deg); + transform: rotate(45deg); + position: absolute; + top: -1px; + left: 4px; + width: 5px; + height: 10px; + border-style: solid; + border-top: none; + border-left: none; + border-right-width: 2px; + border-bottom-width: 2px; + border-color: white; +} + +/* label */ +#checkboxLabel { + position: relative; + display: inline-block; + vertical-align: middle; + padding-left: 8px; + white-space: normal; + pointer-events: none; + color: var(--paper-checkbox-label-color); +} + +#checkboxLabel[hidden] { + display: none; +} + +/* disabled state */ +:host([disabled]) { + pointer-events: none; +} + +:host([disabled]) #checkbox { + opacity: 0.5; + border-color: var(--paper-checkbox-unchecked-color); +} + +:host([disabled][checked]) #checkbox { + background-color: var(--paper-checkbox-unchecked-color); + opacity: 0.5; +} + +:host([disabled]) #checkboxLabel { + opacity: 0.65; +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox.html b/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox.html new file mode 100644 index 0000000..873a937 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-checkbox/paper-checkbox.html @@ -0,0 +1,72 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> + +<!-- + +`paper-checkbox` is a button that can be either checked or unchecked. User +can tap the checkbox to check or uncheck it. Usually you use checkboxes +to allow user to select multiple options from a set. If you have a single +ON/OFF option, avoid using a single checkbox and use `paper-toggle-button` +instead. + +Example: + + <paper-checkbox>label</paper-checkbox> + + <paper-checkbox checked> label</paper-checkbox> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-checkbox-unchecked-color` | Checkbox color when the input is not checked | `--primary-text-color` +`--paper-checkbox-unchecked-ink-color` | Selected/focus ripple color when the input is not checked | `--primary-text-color` +`--paper-checkbox-checked-color` | Checkbox color when the input is checked | `--default-primary-color` +`--paper-checkbox-checked-ink-color` | Selected/focus ripple color when the input is checked | `--default-primary-color` +`--paper-checkbox-label-color` | Label color | `--primary-text-color` + +@demo demo/index.html +--> + +<style is="custom-style"> + :root { + --paper-checkbox-unchecked-color: var(--primary-text-color); + --paper-checkbox-unchecked-ink-color: var(--primary-text-color); + + --paper-checkbox-checked-color: var(--default-primary-color); + --paper-checkbox-checked-ink-color: var(--default-primary-color); + + --paper-checkbox-label-color: var(--primary-text-color); + } +</style> + +</head><body><dom-module id="paper-checkbox"> + <link rel="import" type="css" href="paper-checkbox.css"> + + <template> + + <div id="checkboxContainer"> + <paper-ripple id="ink" class="circle" center="" checked$="[[checked]]"></paper-ripple> + <div id="checkbox" class$="[[_computeCheckboxClass(checked)]]"> + <div id="checkmark" class$="[[_computeCheckmarkClass(checked)]]"></div> + </div> + </div> + + <div id="checkboxLabel" aria-hidden="true"><content></content></div> + + </template> + + </dom-module> +<script src="paper-checkbox-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/.bower.json new file mode 100644 index 0000000..a47fd0f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "paper-dialog-behavior", + "version": "1.0.0", + "description": "Implements a behavior used for material design dialogs", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay", + "behavior" + ], + "main": [ + "paper-dialog-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-behavior", + "ignore": [], + "dependencies": { + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "cd65087ca07495d546bc46618563e53ceacd5325" + }, + "_source": "git://github.com/PolymerElements/paper-dialog-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-dialog-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/README.md b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/README.md new file mode 100644 index 0000000..2c63d3c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/README.md @@ -0,0 +1,24 @@ +# paper-dialog-behavior + +`paper-dialog-behavior` implements behavior related to a Material Design dialog. Use this behavior +and include `paper-dialog-common.css` in your element to implement a dialog. + +`paper-dialog-common.css` provide styles for a header, content area, and an action area for buttons. +Use the `<h2>` tag for the header and the `buttons` class for the action area. You can use the +`paper-dialog-scrollable` element (in its own repository) if you need a scrolling content area. + +Use the `dialog-dismiss` and `dialog-confirm` attributes on interactive controls to close the +dialog. + +For example, if `<paper-dialog-impl>` implements this behavior: + +```html +<paper-dialog-impl> + <h2>Header</h2> + <div>Dialog body</div> + <div class="buttons"> + <paper-button dialog-dismiss>Cancel</paper-button> + <paper-button dialog-confirm>Accept</paper-button> + </div> +</paper-dialog-impl> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/bower.json b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/bower.json new file mode 100644 index 0000000..7b3e6c1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-dialog-behavior", + "version": "1.0.0", + "description": "Implements a behavior used for material design dialogs", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay", + "behavior" + ], + "main": [ + "paper-dialog-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-behavior", + "ignore": [], + "dependencies": { + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/hero.svg new file mode 100644 index 0000000..d473816 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/hero.svg @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <polygon points="76.7,98 79.2,98 74,91.1 74,94.4 "/> + <polygon points="74,81.4 74,84.7 84.1,98 86.6,98 "/> + <polygon points="74,71.7 74,75 91.5,98 94,98 "/> + <polygon points="74,62 74,65.3 98.9,98 101.4,98 "/> + <polygon points="94.3,79 92,79 92,76 74,52.3 74,55.6 106.2,98 108.7,98 "/> + <polygon points="92,69.6 92,66.3 74,42.6 74,45.9 "/> + <polygon points="101.7,79 99.2,79 113.6,98 116.1,98 "/> + <polygon points="92,59.9 92,56.6 74,32.9 74,36.2 "/> + <polygon points="109.1,79 106.5,79 121,98 123.5,98 "/> + <polygon points="92,50.2 92,47 92.1,47 77.7,28 75.2,28 "/> + <polygon points="116.4,79 113.9,79 128.4,98 130.9,98 "/> + <polygon points="97,47 99.5,47 85,28 82.5,28 "/> + <polygon points="123.8,79 121.3,79 135.7,98 138.2,98 "/> + <polygon points="104.4,47 106.9,47 92.4,28 89.9,28 "/> + <polygon points="131.2,79 128.7,79 143.1,98 145.6,98 "/> + <polygon points="132,70.4 132,73.7 150,97.4 150,94.1 "/> + <polygon points="111.7,47 114.2,47 99.8,28 97.3,28 "/> + <polygon points="132,60.7 132,64 150,87.7 150,84.3 "/> + <polygon points="119.1,47 121.6,47 107.2,28 104.7,28 "/> + <polygon points="132,51 132,54.3 150,77.9 150,74.6 "/> + <polygon points="114.6,28 112,28 126.5,47 129,47 "/> + <polygon points="121.9,28 119.4,28 150,68.2 150,64.9 "/> + <polygon points="129.3,28 126.8,28 150,58.5 150,55.2 "/> + <polygon points="136.7,28 134.2,28 150,48.8 150,45.5 "/> + <polygon points="144.1,28 141.5,28 150,39.1 150,35.8 "/> + <polygon points="150,29.4 150,28 148.9,28 "/> + </g> + <path d="M133,80H91V46h42V80z M93,78h38V48H93V78z"/> + <path d="M151,99H73V27h78V99z M75,97h74V29H75V97z"/> + <circle cx="74" cy="28" r="4"/> + <circle cx="150" cy="28" r="4"/> + <circle cx="150" cy="98" r="4"/> + <circle cx="74" cy="98" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/index.html b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/index.html new file mode 100644 index 0000000..af98b85 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-dialog-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-behavior-extracted.js new file mode 100644 index 0000000..56dbb01 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-behavior-extracted.js @@ -0,0 +1,221 @@ + + +/* +Use `Polymer.PaperDialogBehavior` and `paper-dialog-common.css` to implement a Material Design +dialog. + +For example, if `<paper-dialog-impl>` implements this behavior: + + <paper-dialog-impl> + <h2>Header</h2> + <div>Dialog body</div> + <div class="buttons"> + <paper-button dialog-dismiss>Cancel</paper-button> + <paper-button dialog-confirm>Accept</paper-button> + </div> + </paper-dialog-impl> + +`paper-dialog-common.css` provide styles for a header, content area, and an action area for buttons. +Use the `<h2>` tag for the header and the `buttons` class for the action area. You can use the +`paper-dialog-scrollable` element (in its own repository) if you need a scrolling content area. + +Use the `dialog-dismiss` and `dialog-confirm` attributes on interactive controls to close the +dialog. If the user dismisses the dialog with `dialog-confirm`, the `closingReason` will update +to include `confirmed: true`. + +### Styling + +The following custom properties and mixins are available for styling. + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-dialog-background-color` | Dialog background color | `--primary-background-color` +`--paper-dialog-color` | Dialog foreground color | `--primary-text-color` +`--paper-dialog` | Mixin applied to the dialog | `{}` +`--paper-dialog-title` | Mixin applied to the title (`<h2>`) element | `{}` +`--paper-dialog-button-color` | Button area foreground color | `--default-primary-color` + +### Accessibility + +This element has `role="dialog"` by default. Depending on the context, it may be more appropriate +to override this attribute with `role="alertdialog"`. The header (a `<h2>` element) will + +If `modal` is set, the element will set `aria-modal` and prevent the focus from exiting the element. +It will also ensure that focus remains in the dialog. + +The `aria-labelledby` attribute will be set to the header element, if one exists. + +@hero hero.svg +@demo demo/index.html +@polymerBehavior Polymer.PaperDialogBehavior +*/ + + Polymer.PaperDialogBehaviorImpl = { + + hostAttributes: { + 'role': 'dialog', + 'tabindex': '-1' + }, + + properties: { + + /** + * If `modal` is true, this implies `no-cancel-on-outside-click` and `with-backdrop`. + */ + modal: { + observer: '_modalChanged', + type: Boolean, + value: false + }, + + _lastFocusedElement: { + type: Node + }, + + _boundOnFocus: { + type: Function, + value: function() { + return this._onFocus.bind(this); + } + }, + + _boundOnBackdropClick: { + type: Function, + value: function() { + return this._onBackdropClick.bind(this); + } + } + + }, + + listeners: { + 'click': '_onDialogClick', + 'iron-overlay-opened': '_onIronOverlayOpened', + 'iron-overlay-closed': '_onIronOverlayClosed' + }, + + attached: function() { + this._observer = this._observe(this); + this._updateAriaLabelledBy(); + }, + + detached: function() { + if (this._observer) { + this._observer.disconnect(); + } + }, + + _observe: function(node) { + var observer = new MutationObserver(function() { + this._updateAriaLabelledBy(); + }.bind(this)); + observer.observe(node, { + childList: true, + subtree: true + }); + return observer; + }, + + _modalChanged: function() { + if (this.modal) { + this.setAttribute('aria-modal', 'true'); + } else { + this.setAttribute('aria-modal', 'false'); + } + // modal implies noCancelOnOutsideClick and withBackdrop if true, don't overwrite + // those properties otherwise. + if (this.modal) { + this.noCancelOnOutsideClick = true; + this.withBackdrop = true; + } + }, + + _updateAriaLabelledBy: function() { + var header = Polymer.dom(this).querySelector('h2'); + if (!header) { + this.removeAttribute('aria-labelledby'); + return; + } + var headerId = header.getAttribute('id'); + if (headerId && this.getAttribute('aria-labelledby') === headerId) { + return; + } + // set aria-describedBy to the header element + var labelledById; + if (headerId) { + labelledById = headerId; + } else { + labelledById = 'paper-dialog-header-' + new Date().getUTCMilliseconds(); + header.setAttribute('id', labelledById); + } + this.setAttribute('aria-labelledby', labelledById); + }, + + _updateClosingReasonConfirmed: function(confirmed) { + this.closingReason = this.closingReason || {}; + this.closingReason.confirmed = confirmed; + }, + + _onDialogClick: function(event) { + var target = event.target; + while (target !== this) { + if (target.hasAttribute('dialog-dismiss')) { + this._updateClosingReasonConfirmed(false); + this.close(); + break; + } else if (target.hasAttribute('dialog-confirm')) { + this._updateClosingReasonConfirmed(true); + this.close(); + break; + } + target = target.parentNode; + } + }, + + _onIronOverlayOpened: function() { + if (this.modal) { + document.body.addEventListener('focus', this._boundOnFocus, true); + this.backdropElement.addEventListener('click', this._boundOnBackdropClick); + } + }, + + _onIronOverlayClosed: function() { + document.body.removeEventListener('focus', this._boundOnFocus, true); + this.backdropElement.removeEventListener('click', this._boundOnBackdropClick); + }, + + _onFocus: function(event) { + if (this.modal) { + var target = event.target; + while (target && target !== this && target !== document.body) { + target = target.parentNode; + } + if (target) { + if (target === document.body) { + if (this._lastFocusedElement) { + this._lastFocusedElement.focus(); + } else { + this._focusNode.focus(); + } + } else { + this._lastFocusedElement = event.target; + } + } + } + }, + + _onBackdropClick: function() { + if (this.modal) { + if (this._lastFocusedElement) { + this._lastFocusedElement.focus(); + } else { + this._focusNode.focus(); + } + } + } + + }; + + /** @polymerBehavior */ + Polymer.PaperDialogBehavior = [Polymer.IronOverlayBehavior, Polymer.PaperDialogBehaviorImpl]; + diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-behavior.html b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-behavior.html new file mode 100644 index 0000000..9d24b77 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-behavior.html @@ -0,0 +1,13 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-overlay-behavior/iron-overlay-behavior.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +</head><body><script src="paper-dialog-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-common.css b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-common.css new file mode 100644 index 0000000..57c665d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-behavior/paper-dialog-common.css @@ -0,0 +1,57 @@ +/* +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: block; + margin: 24px 40px; + + background: var(--paper-dialog-background-color, --primary-background-color); + color: var(--paper-dialog-color, --primary-text-color); + + @apply(--paper-font-body1); + @apply(--shadow-elevation-16dp); + @apply(--paper-dialog); +} + +:host > ::content > * { + margin-top: 20px; + padding: 0 24px; +} + +:host > ::content > .no-padding { + padding: 0; +}; + +:host > ::content > *:first-child { + margin-top: 24px; +} + +:host > ::content > *:last-child { + margin-bottom: 24px; +} + +:host > ::content h2 { + position: relative; + margin: 0; + @apply(--paper-font-title); + + @apply(--paper-dialog-title); +} + +:host > ::content .buttons { + position: relative; + padding: 8px 8px 8px 24px; + margin: 0; + + color: var(--paper-dialog-button-color, --default-primary-color); + + @apply(--layout-horizontal); + @apply(--layout-end-justified); +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/.bower.json new file mode 100644 index 0000000..88e5eb3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-dialog-scrollable", + "version": "1.0.0", + "description": "A scrollable area used inside the material design dialog", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": [ + "paper-dialog-scrollable.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-scrollable" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-scrollable", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "9d27cbdedfb4b4b06eefffbf99d0e7fa97c3e248" + }, + "_source": "git://github.com/PolymerElements/paper-dialog-scrollable.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-dialog-scrollable" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/README.md b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/README.md new file mode 100644 index 0000000..201d0af --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/README.md @@ -0,0 +1,8 @@ +# paper-dialog-scrollable + +`paper-dialog-scrollable` implements a scrolling area used in a Material Design dialog. Use this +together with elements implementing `paper-dialog-behavior`. + +It shows a top divider after scrolling if it is not the first child in its parent container. It +shows a bottom divider if it is scrollable and it is not the last child in its parent container. +The bottom divider is hidden if it is scrolled to the bottom. diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/bower.json b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/bower.json new file mode 100644 index 0000000..99553af --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-dialog-scrollable", + "version": "1.0.0", + "description": "A scrollable area used inside the material design dialog", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": [ + "paper-dialog-scrollable.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-scrollable" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-scrollable", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/hero.svg new file mode 100644 index 0000000..40bc69a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/hero.svg @@ -0,0 +1,69 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <polygon points="0,124 0,126 2,126 "/> + <polygon points="0,111.6 0,114.4 11.6,126 14.4,126 "/> + <polygon points="0,99.1 0,101.9 24.1,126 26.9,126 "/> + <polygon points="0,86.6 0,89.5 36.5,126 39.4,126 "/> + <polygon points="0,74.2 0,77 49,126 51.8,126 "/> + <polygon points="0,61.7 0,64.5 61.5,126 64.3,126 "/> + <polygon points="0,49.2 0,52.1 73.9,126 76.8,126 "/> + <polygon points="0,36.8 0,39.6 86.4,126 89.2,126 "/> + <polygon points="76.7,101 74,101 74,98.3 0,24.3 0,27.1 98.9,126 101.7,126 "/> + <polygon points="74,88.7 74,85.8 0,11.8 0,14.7 "/> + <polygon points="89.2,101 86.3,101 111.3,126 114.2,126 "/> + <polygon points="101.6,101 98.8,101 123.8,126 126.6,126 "/> + <polygon points="74,76.2 74,73.4 0.6,0 0,0 0,2.2 "/> + <polygon points="114.1,101 111.3,101 136.3,126 139.1,126 "/> + <polygon points="74,63.7 74,60.9 13.1,0 10.3,0 "/> + <polygon points="74,51.3 74,48.4 25.6,0 22.7,0 "/> + <polygon points="126.6,101 123.7,101 148.7,126 151.6,126 "/> + <polygon points="74,38.8 74,36 38,0 35.2,0 "/> + <polygon points="139,101 136.2,101 161.2,126 164,126 "/> + <polygon points="74,26.3 74,25 75.5,25 50.5,0 47.7,0 "/> + <polygon points="150,99.5 150,101 148.7,101 173.7,126 176.5,126 "/> + <polygon points="150,87 150,89.9 186.1,126 189,126 "/> + <polygon points="85.1,25 88,25 63,0 60.1,0 "/> + <polygon points="150,74.6 150,77.4 198.6,126 201.4,126 "/> + <polygon points="97.6,25 100.4,25 75.4,0 72.6,0 "/> + <polygon points="150,62.1 150,64.9 211.1,126 213.9,126 "/> + <polygon points="110.1,25 112.9,25 87.9,0 85.1,0 "/> + <polygon points="150,49.7 150,52.5 223.5,126 225,126 225,124.7 "/> + <polygon points="122.5,25 125.3,25 100.3,0 97.5,0 "/> + <polygon points="112.8,0 110,0 135,25 137.8,25 "/> + <polygon points="150,37.2 150,40 225,115 225,112.2 "/> + <polygon points="125.3,0 122.5,0 147.5,25 150,25 150,27.5 225,102.5 225,99.7 "/> + <polygon points="137.7,0 134.9,0 225,90.1 225,87.3 "/> + <polygon points="150.2,0 147.4,0 225,77.6 225,74.8 "/> + <polygon points="162.7,0 159.8,0 225,65.2 225,62.3 "/> + <polygon points="175.1,0 172.3,0 225,52.7 225,49.9 "/> + <polygon points="187.6,0 184.8,0 225,40.2 225,37.4 "/> + <polygon points="200.1,0 197.2,0 225,27.8 225,24.9 "/> + <polygon points="212.5,0 209.7,0 225,15.3 225,12.5 "/> + <polygon points="225,0 222.2,0 225,2.8 225,0 "/> + </g> + <path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/> + <rect x="82" y="53" width="26" height="2"/> + <rect x="116" y="53" width="26" height="2"/> + <rect x="82" y="62" width="26" height="2"/> + <rect x="82" y="72" width="26" height="2"/> + <rect x="116" y="72" width="26" height="2"/> + <rect x="82" y="42" width="26" height="2"/> + <circle cx="120" cy="63" r="4"/> + <circle cx="134" cy="63" r="4"/> + <rect x="116" y="85" width="22" height="5.5"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/index.html b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/index.html new file mode 100644 index 0000000..2d2ec7e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-dialog-scrollable</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/paper-dialog-scrollable-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/paper-dialog-scrollable-extracted.js new file mode 100644 index 0000000..b0335a7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/paper-dialog-scrollable-extracted.js @@ -0,0 +1,63 @@ + + +(function() { + + Polymer({ + + is: 'paper-dialog-scrollable', + + properties: { + + /** + * The dialog element that implements `Polymer.PaperDialogBehavior` containing this element. + */ + dialogElement: { + type: Object, + value: function() { + return this.parentNode; + } + } + + }, + + listeners: { + 'scrollable.scroll': '_onScroll', + 'iron-resize': '_onIronResize' + }, + + /** + * Returns the scrolling element. + */ + get scrollTarget() { + return this.$.scrollable; + }, + + attached: function() { + this.classList.add('no-padding'); + // Set itself to the overlay sizing target + this.dialogElement.sizingTarget = this.scrollTarget; + // If the host is sized, fit the scrollable area to the container. Otherwise let it be + // its natural size. + requestAnimationFrame(function() { + if (this.offsetHeight > 0) { + this.$.scrollable.classList.add('fit'); + } + this._scroll(); + }.bind(this)); + }, + + _scroll: function() { + this.toggleClass('is-scrolled', this.scrollTarget.scrollTop > 0); + this.toggleClass('can-scroll', this.scrollTarget.offsetHeight < this.scrollTarget.scrollHeight); + this.toggleClass('scrolled-to-bottom', + this.scrollTarget.scrollTop + this.scrollTarget.offsetHeight >= this.scrollTarget.scrollHeight); + }, + + _onScroll: function() { + this._scroll(); + } + + }) + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/paper-dialog-scrollable.html b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/paper-dialog-scrollable.html new file mode 100644 index 0000000..ad790ca --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog-scrollable/paper-dialog-scrollable.html @@ -0,0 +1,85 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`paper-dialog-scrollable` implements a scrolling area used in a Material Design dialog. It shows +a divider at the top and/or bottom indicating more content, depending on scroll position. Use this +together with elements implementing `Polymer.PaperDialogBehavior`. + + <paper-dialog-impl> + <h2>Header</h2> + <paper-dialog-scrollable> + Lorem ipsum... + </paper-dialog-scrollable> + <div class="buttons"> + <paper-button>OK</paper-button> + </div> + </paper-dialog-impl> + +It shows a top divider after scrolling if it is not the first child in its parent container, +indicating there is more content above. It shows a bottom divider if it is scrollable and it is not +the last child in its parent container, indicating there is more content below. The bottom divider +is hidden if it is scrolled to the bottom. + +@group Paper Elements +@element paper-dialog-scrollable +@demo demo/index.html +@hero hero.svg +--> + +</head><body><dom-module id="paper-dialog-scrollable"> + + <style> + + :host { + display: block; + position: relative; + } + + :host(.is-scrolled:not(:first-child))::before { + content: ''; + position: absolute; + top: 0; + left: 0; + right: 0; + height: 1px; + background: var(--divider-color); + } + + :host(.can-scroll:not(.scrolled-to-bottom):not(:last-child))::after { + content: ''; + position: absolute; + bottom: 0; + left: 0; + right: 0; + height: 1px; + background: var(--divider-color); + } + + .scrollable { + padding: 0 24px; + + @apply(--layout-scroll); + + @apply(--paper-dialog-scrollable); + } + </style> + + <template> + <div id="scrollable" class="scrollable"> + <content></content> + </div> + </template> + +</dom-module> + +<script src="paper-dialog-scrollable-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-dialog/.bower.json new file mode 100644 index 0000000..540adab --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-dialog", + "description": "A Material Design dialog", + "version": "1.0.0", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": "paper-dialog.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "neon-animation": "PolymerElements/neon-animation#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "6d66cf1e022e56ec28353a2f718e93535c7cac20" + }, + "_source": "git://github.com/PolymerElements/paper-dialog.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-dialog" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-dialog/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/README.md b/third_party/polymer/v1_0/components-chromium/paper-dialog/README.md new file mode 100644 index 0000000..a4d5c7f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/README.md @@ -0,0 +1,3 @@ +# paper-dialog + +A Material Design dialog diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/bower.json b/third_party/polymer/v1_0/components-chromium/paper-dialog/bower.json new file mode 100644 index 0000000..2bce00e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/bower.json @@ -0,0 +1,35 @@ +{ + "name": "paper-dialog", + "description": "A Material Design dialog", + "version": "1.0.0", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": "paper-dialog.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "neon-animation": "PolymerElements/neon-animation#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-dialog/hero.svg new file mode 100644 index 0000000..713329b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/hero.svg @@ -0,0 +1,58 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <polygon points="0,124 0,126 2,126 "/> + <polygon points="0,111.6 0,114.4 11.6,126 14.4,126 "/> + <polygon points="0,99.1 0,101.9 24.1,126 26.9,126 "/> + <polygon points="0,86.6 0,89.5 36.5,126 39.4,126 "/> + <polygon points="0,74.2 0,77 49,126 51.8,126 "/> + <polygon points="0,61.7 0,64.5 61.5,126 64.3,126 "/> + <polygon points="0,49.2 0,52.1 73.9,126 76.8,126 "/> + <polygon points="0,36.8 0,39.6 86.4,126 89.2,126 "/> + <polygon points="0,24.3 0,27.1 98.9,126 101.7,126 "/> + <polygon points="75.2,87 74,87 74,85.8 0,11.8 0,14.7 111.3,126 114.2,126 "/> + <polygon points="87.6,87 84.8,87 123.8,126 126.6,126 "/> + <polygon points="74,76.2 74,73.4 0.6,0 0,0 0,2.2 "/> + <polygon points="74,63.7 74,60.9 13.1,0 10.3,0 "/> + <polygon points="100.1,87 97.3,87 136.3,126 139.1,126 "/> + <polygon points="112.6,87 109.7,87 148.7,126 151.6,126 "/> + <polygon points="74,51.3 74,48.4 25.6,0 22.7,0 "/> + <polygon points="125,87 122.2,87 161.2,126 164,126 "/> + <polygon points="74.2,39 77,39 38,0 35.2,0 "/> + <polygon points="86.7,39 89.5,39 50.5,0 47.7,0 "/> + <polygon points="137.5,87 134.7,87 173.7,126 176.5,126 "/> + <polygon points="150,87 147.1,87 186.1,126 189,126 "/> + <polygon points="99.1,39 102,39 63,0 60.1,0 "/> + <polygon points="150,74.6 150,77.4 198.6,126 201.4,126 "/> + <polygon points="111.6,39 114.4,39 75.4,0 72.6,0 "/> + <polygon points="150,62.1 150,64.9 211.1,126 213.9,126 "/> + <polygon points="124.1,39 126.9,39 87.9,0 85.1,0 "/> + <polygon points="100.3,0 97.5,0 136.5,39 139.3,39 "/> + <polygon points="150,49.7 150,52.5 223.5,126 225,126 225,124.7 "/> + <polygon points="112.8,0 110,0 149,39 150,39 150,40 225,115 225,112.2 "/> + <polygon points="125.3,0 122.5,0 225,102.5 225,99.7 "/> + <polygon points="137.7,0 134.9,0 225,90.1 225,87.3 "/> + <polygon points="150.2,0 147.4,0 225,77.6 225,74.8 "/> + <polygon points="162.7,0 159.8,0 225,65.2 225,62.3 "/> + <polygon points="175.1,0 172.3,0 225,52.7 225,49.9 "/> + <polygon points="187.6,0 184.8,0 225,40.2 225,37.4 "/> + <polygon points="200.1,0 197.2,0 225,27.8 225,24.9 "/> + <polygon points="212.5,0 209.7,0 225,15.3 225,12.5 "/> + <polygon points="225,0 222.2,0 225,2.8 225,0 "/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> + <path d="M151,88H73V38h78V88z M75,86h74V40H75V86z"/> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/index.html b/third_party/polymer/v1_0/components-chromium/paper-dialog/index.html new file mode 100644 index 0000000..6304b8d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-dialog</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/paper-dialog-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-dialog/paper-dialog-extracted.js new file mode 100644 index 0000000..6e3705c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/paper-dialog-extracted.js @@ -0,0 +1,43 @@ + + +(function() { + + Polymer({ + + is: 'paper-dialog', + + behaviors: [ + Polymer.PaperDialogBehavior, + Polymer.NeonAnimationRunnerBehavior + ], + + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + + _renderOpened: function() { + if (this.withBackdrop) { + this.backdropElement.open(); + } + this.playAnimation('entry'); + }, + + _renderClosed: function() { + if (this.withBackdrop) { + this.backdropElement.close(); + } + this.playAnimation('exit'); + }, + + _onNeonAnimationFinish: function() { + if (this.opened) { + this._finishRenderOpened(); + } else { + this._finishRenderClosed(); + } + } + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-dialog/paper-dialog.html b/third_party/polymer/v1_0/components-chromium/paper-dialog/paper-dialog.html new file mode 100644 index 0000000..194ff73 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-dialog/paper-dialog.html @@ -0,0 +1,77 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../neon-animation/neon-animation-runner-behavior.html"> +<link rel="import" href="../paper-dialog-behavior/paper-dialog-behavior.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-dialog>` is a dialog with Material Design styling and optional animations when it is +opened or closed. It provides styles for a header, content area, and an action area for buttons. +You can use the `<paper-dialog-scrollable` element (in its own repository) if you need a scrolling +content area. See `Polymer.PaperDialogBehavior` for specifics. + +For example, the following code implements a dialog with a header, scrolling content area and +buttons. + + <paper-dialog> + <h2>Header</h2> + <paper-dialog-scrollable> + Lorem ipsum... + </paper-dialog-scrollable> + <div class="buttons"> + <paper-button dialog-dismiss>Cancel</paper-button> + <paper-button dialog-confirm>Accept</paper-button> + </div> + </paper-dialog> + +### Styling + +See the docs for `Polymer.PaperDialogBehavior` for the custom properties available for styling +this element. + +### Animations + +Set the `entry-animation` and/or `exit-animation` attributes to add an animation when the dialog +is opened or closed. See the documentation in +[PolymerElements/neon-animation](https://github.com/PolymerElements/neon-animation) for more info. + +For example: + + <link rel="import" href="components/neon-animation/animations/scale-up-animation.html"> + <link rel="import" href="components/neon-animation/animations/fade-out-animation.html"> + + <paper-dialog entry-animation="scale-up-animation" + exit-animation="fade-out-animation"> + <h2>Header</h2> + <div>Dialog body</div> + </paper-dialog> + +### Accessibility + +See the docs for `Polymer.PaperDialogBehavior` for accessibility features implemented by this +element. + +@group Paper Elements +@element paper-dialog +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-dialog"> + + <link rel="import" type="css" href="../paper-dialog-behavior/paper-dialog-common.css"> + + <template> + <content></content> + </template> + +</dom-module> + +<script src="paper-dialog-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/.bower.json new file mode 100644 index 0000000..f226642 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/.bower.json @@ -0,0 +1,42 @@ +{ + "name": "paper-drawer-panel", + "version": "1.0.1", + "description": "A responsive drawer panel", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "drawer", + "responsive", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-drawer-panel.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-drawer-panel", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "6294619b9eb3a9346854daef1b00fb3342dffef9" + }, + "_source": "git://github.com/PolymerElements/paper-drawer-panel.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-drawer-panel" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/README.md b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/README.md new file mode 100644 index 0000000..2828663 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/README.md @@ -0,0 +1,71 @@ +# paper-drawer-panel + +`paper-drawer-panel` contains a drawer panel and a main panel. The drawer +and the main panel are side-by-side with drawer on the left. When the browser +window size is smaller than the `responsiveWidth`, `paper-drawer-panel` +changes to narrow layout. In narrow layout, the drawer will be stacked on top +of the main panel. The drawer will slide in/out to hide/reveal the main +panel. + +Use the attribute `drawer` to indicate that the element is the drawer panel and +`main` to indicate that the element is the main panel. + +Example: + +```html +<paper-drawer-panel> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> +</paper-drawer-panel> +``` + +The drawer and the main panels are not scrollable. You can set CSS overflow +property on the elements to make them scrollable or use `paper-header-panel`. + +Example: + +```html +<paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar></paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar></paper-toolbar> + <div> Main content... </div> + </paper-header-panel> +</paper-drawer-panel> +``` + +An element that should toggle the drawer will automatically do so if it's +given the `paper-drawer-toggle` attribute. Also this element will automatically +be hidden in wide layout. + +Example: + +```html +<paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar> + <div>Application</div> + </paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar> + <paper-icon-button icon="menu" paper-drawer-toggle></paper-icon-button> + <div>Title</div> + </paper-toolbar> + <div> Main content... </div> + </paper-header-panel> +</paper-drawer-panel> +``` + +To position the drawer to the right, add `right-drawer` attribute. + +```html +<paper-drawer-panel right-drawer> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> +</paper-drawer-panel> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/bower.json b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/bower.json new file mode 100644 index 0000000..52edc76 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/bower.json @@ -0,0 +1,33 @@ +{ + "name": "paper-drawer-panel", + "version": "1.0.1", + "description": "A responsive drawer panel", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "drawer", + "responsive", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-drawer-panel.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-drawer-panel", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/hero.svg new file mode 100644 index 0000000..5dfef36 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/hero.svg @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M175,102H61V24h114V102z M63,100h110V26H63V100z"/> + <path d="M91,102H61V24h30V102z M63,100h26V26H63V100z"/> + <circle cx="123" cy="63" r="4"/> + <rect x="90" y="62" width="33" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/index.html b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/index.html new file mode 100644 index 0000000..1390ecc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-drawer-panel</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel-extracted.js new file mode 100644 index 0000000..5382e3c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel-extracted.js @@ -0,0 +1,448 @@ + + + (function() { + + 'use strict'; + + // this would be the only `paper-drawer-panel` in + // the whole app that can be in `dragging` state + var sharedPanel = null; + + function classNames(obj) { + var classes = []; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key]) { + classes.push(key); + } + } + + return classes.join(' '); + } + + Polymer({ + + is: 'paper-drawer-panel', + + /** + * Fired when the narrow layout changes. + * + * @event paper-responsive-change {{narrow: boolean}} detail - + * narrow: true if the panel is in narrow layout. + */ + + /** + * Fired when the selected panel changes. + * + * Listening for this event is an alternative to observing changes in the `selected` attribute. + * This event is fired both when a panel is selected and deselected. + * The `isSelected` detail property contains the selection state. + * + * @event paper-select {{isSelected: boolean, item: Object}} detail - + * isSelected: True for selection and false for deselection. + * item: The panel that the event refers to. + */ + + properties: { + + /** + * The panel to be selected when `paper-drawer-panel` changes to narrow + * layout. + */ + defaultSelected: { + type: String, + value: 'main' + }, + + /** + * If true, swipe from the edge is disable. + */ + disableEdgeSwipe: { + type: Boolean, + value: false + }, + + /** + * If true, swipe to open/close the drawer is disabled. + */ + disableSwipe: { + type: Boolean, + value: false + }, + + /** + * Whether the user is dragging the drawer interactively. + */ + dragging: { + type: Boolean, + value: false + }, + + /** + * Width of the drawer panel. + */ + drawerWidth: { + type: String, + value: '256px' + }, + + /** + * How many pixels on the side of the screen are sensitive to edge + * swipes and peek. + */ + edgeSwipeSensitivity: { + type: Number, + value: 30 + }, + + /** + * If true, ignore `responsiveWidth` setting and force the narrow layout. + */ + forceNarrow: { + type: Boolean, + value: false + }, + + /** + * Whether the browser has support for the transform CSS property. + */ + hasTransform: { + type: Boolean, + value: function() { + return 'transform' in this.style; + } + }, + + /** + * Whether the browser has support for the will-change CSS property. + */ + hasWillChange: { + type: Boolean, + value: function() { + return 'willChange' in this.style; + } + }, + + /** + * Returns true if the panel is in narrow layout. This is useful if you + * need to show/hide elements based on the layout. + */ + narrow: { + reflectToAttribute: true, + type: Boolean, + value: false, + notify: true + }, + + /** + * Whether the drawer is peeking out from the edge. + */ + peeking: { + type: Boolean, + value: false + }, + + /** + * Max-width when the panel changes to narrow layout. + */ + responsiveWidth: { + type: String, + value: '640px' + }, + + /** + * If true, position the drawer to the right. + */ + rightDrawer: { + type: Boolean, + value: false + }, + + /** + * The panel that is being selected. `drawer` for the drawer panel and + * `main` for the main panel. + */ + selected: { + reflectToAttribute: true, + type: String, + value: null + }, + + /** + * The attribute on elements that should toggle the drawer on tap, also elements will + * automatically be hidden in wide layout. + */ + drawerToggleAttribute: { + type: String, + value: 'paper-drawer-toggle' + }, + + /** + * Whether the transition is enabled. + */ + transition: { + type: Boolean, + value: false + }, + + }, + + listeners: { + tap: '_onTap', + track: '_onTrack', + down: '_downHandler', + up: '_upHandler' + }, + + observers: [ + '_forceNarrowChanged(forceNarrow, defaultSelected)' + ], + + /** + * Toggles the panel open and closed. + * + * @method togglePanel + */ + togglePanel: function() { + if (this._isMainSelected()) { + this.openDrawer(); + } else { + this.closeDrawer(); + } + }, + + /** + * Opens the drawer. + * + * @method openDrawer + */ + openDrawer: function() { + this.selected = 'drawer'; + }, + + /** + * Closes the drawer. + * + * @method closeDrawer + */ + closeDrawer: function() { + this.selected = 'main'; + }, + + ready: function() { + // Avoid transition at the beginning e.g. page loads and enable + // transitions only after the element is rendered and ready. + this.transition = true; + }, + + _computeIronSelectorClass: function(narrow, transition, dragging, rightDrawer) { + return classNames({ + dragging: dragging, + 'narrow-layout': narrow, + 'right-drawer': rightDrawer, + 'left-drawer': !rightDrawer, + transition: transition + }); + }, + + _computeDrawerStyle: function(drawerWidth) { + return 'width:' + drawerWidth + ';'; + }, + + _computeMainStyle: function(narrow, rightDrawer, drawerWidth) { + var style = ''; + + style += 'left:' + ((narrow || rightDrawer) ? '0' : drawerWidth) + ';'; + + if (rightDrawer) { + style += 'right:' + (narrow ? '' : drawerWidth) + ';'; + } else { + style += 'right:;'; + } + + return style; + }, + + _computeMediaQuery: function(forceNarrow, responsiveWidth) { + return forceNarrow ? '' : '(max-width: ' + responsiveWidth + ')'; + }, + + _computeSwipeOverlayHidden: function(narrow, disableEdgeSwipe) { + return !narrow || disableEdgeSwipe; + }, + + _onTrack: function(e) { + if (sharedPanel && this !== sharedPanel) { + return; + } + switch (e.detail.state) { + case 'start': + this._trackStart(e); + break; + case 'track': + this._trackX(e); + break; + case 'end': + this._trackEnd(e); + break; + } + + }, + + _responsiveChange: function(narrow) { + this.narrow = narrow; + + if (this.narrow) { + this.selected = this.defaultSelected; + } + + this.setScrollDirection(this._swipeAllowed() ? 'y' : 'all'); + this.fire('paper-responsive-change', {narrow: this.narrow}); + }, + + _onQueryMatchesChanged: function(e) { + this._responsiveChange(e.detail.value); + }, + + _forceNarrowChanged: function() { + // set the narrow mode only if we reached the `responsiveWidth` + this._responsiveChange(this.forceNarrow || this.$.mq.queryMatches); + }, + + _swipeAllowed: function() { + return this.narrow && !this.disableSwipe; + }, + + _isMainSelected: function() { + return this.selected === 'main'; + }, + + _startEdgePeek: function() { + this.width = this.$.drawer.offsetWidth; + this._moveDrawer(this._translateXForDeltaX(this.rightDrawer ? + -this.edgeSwipeSensitivity : this.edgeSwipeSensitivity)); + this.peeking = true; + }, + + _stopEdgePeek: function() { + if (this.peeking) { + this.peeking = false; + this._moveDrawer(null); + } + }, + + _downHandler: function(e) { + if (!this.dragging && this._isMainSelected() && this._isEdgeTouch(e) && !sharedPanel) { + this._startEdgePeek(); + // grab this panel + sharedPanel = this; + } + }, + + _upHandler: function() { + this._stopEdgePeek(); + // release the panel + sharedPanel = null; + }, + + _onTap: function(e) { + var targetElement = Polymer.dom(e).localTarget; + var isTargetToggleElement = targetElement && + this.drawerToggleAttribute && + targetElement.hasAttribute(this.drawerToggleAttribute); + + if (isTargetToggleElement) { + this.togglePanel(); + } + }, + + _isEdgeTouch: function(e) { + var x = e.detail.x; + + return !this.disableEdgeSwipe && this._swipeAllowed() && + (this.rightDrawer ? + x >= this.offsetWidth - this.edgeSwipeSensitivity : + x <= this.edgeSwipeSensitivity); + }, + + _trackStart: function() { + if (this._swipeAllowed()) { + sharedPanel = this; + this.dragging = true; + + if (this._isMainSelected()) { + this.dragging = this.peeking || this._isEdgeTouch(event); + } + + if (this.dragging) { + this.width = this.$.drawer.offsetWidth; + this.transition = false; + } + } + }, + + _translateXForDeltaX: function(deltaX) { + var isMain = this._isMainSelected(); + + if (this.rightDrawer) { + return Math.max(0, isMain ? this.width + deltaX : deltaX); + } else { + return Math.min(0, isMain ? deltaX - this.width : deltaX); + } + }, + + _trackX: function(e) { + if (this.dragging) { + var dx = e.detail.dx; + + if (this.peeking) { + if (Math.abs(dx) <= this.edgeSwipeSensitivity) { + // Ignore trackx until we move past the edge peek. + return; + } + this.peeking = false; + } + + this._moveDrawer(this._translateXForDeltaX(dx)); + } + }, + + _trackEnd: function(e) { + if (this.dragging) { + var xDirection = e.detail.dx > 0; + + this.dragging = false; + this.transition = true; + sharedPanel = null; + this._moveDrawer(null); + + if (this.rightDrawer) { + this[xDirection ? 'closeDrawer' : 'openDrawer'](); + } else { + this[xDirection ? 'openDrawer' : 'closeDrawer'](); + } + } + }, + + _transformForTranslateX: function(translateX) { + if (translateX === null) { + return ''; + } + + return this.hasWillChange ? 'translateX(' + translateX + 'px)' : + 'translate3d(' + translateX + 'px, 0, 0)'; + }, + + _moveDrawer: function(translateX) { + var s = this.$.drawer.style; + + if (this.hasTransform) { + s.transform = this._transformForTranslateX(translateX); + } else { + s.webkitTransform = this._transformForTranslateX(translateX); + } + } + + }); + + }()); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel.css b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel.css new file mode 100644 index 0000000..ab7c568 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel.css @@ -0,0 +1,142 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + +*/ +:host { + display: block; + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + overflow: hidden; +} + +iron-selector > #drawer { + position: absolute; + top: 0; + left: 0; + height: 100%; + background-color: white; + will-change: transform; + box-sizing: border-box; + -moz-box-sizing: border-box; + + @apply(--paper-drawer-panel-drawer-container); +} + +.transition > #drawer { + transition: -webkit-transform ease-in-out 0.3s, width ease-in-out 0.3s; + transition: transform ease-in-out 0.3s, width ease-in-out 0.3s; +} + +.left-drawer > #drawer { + @apply(--paper-drawer-panel-left-drawer-container); +} + +.right-drawer > #drawer { + left: auto; + right: 0; + + @apply(--paper-drawer-panel-right-drawer-container); +} + +iron-selector > #main { + position: absolute; + top: 0; + right: 0; + bottom: 0; + + @apply(--paper-drawer-panel-main-container); +} + +.transition > #main { + transition: left ease-in-out 0.3s, padding ease-in-out 0.3s; +} + +.right-drawer > #main { + left: 0; +} + +.right-drawer.transition > #main { + transition: right ease-in-out 0.3s, padding ease-in-out 0.3s; +} + +#main > ::content > [main] { + height: 100%; +} + +#drawer > ::content > [drawer] { + height: 100%; +} + +#scrim { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + visibility: hidden; + opacity: 0; + transition: opacity ease-in-out 0.38s, visibility ease-in-out 0.38s; + background-color: rgba(0, 0, 0, 0.3); +} + +.narrow-layout > #drawer.iron-selected { + box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.15); +} + +.right-drawer.narrow-layout > #drawer.iron-selected { + box-shadow: -2px 2px 4px rgba(0, 0, 0, 0.15); +} + +.narrow-layout > #drawer > ::content > [drawer] { + border: 0; +} + +.left-drawer.narrow-layout > #drawer:not(.iron-selected) { + -webkit-transform: translateX(-100%); + transform: translateX(-100%); +} + +.right-drawer.narrow-layout > #drawer:not(.iron-selected) { + left: auto; + -webkit-transform: translateX(100%); + transform: translateX(100%); +} + +.narrow-layout > #main { + left: 0 !important; + padding: 0; +} + +.right-drawer.narrow-layout > #main { + left: 0; + right: 0; + padding: 0; +} + +.narrow-layout > #main:not(.iron-selected) > #scrim, +.dragging > #main > #scrim { + visibility: visible; + opacity: var(--paper-drawer-panel-scrim-opacity, 1); +} + +.narrow-layout > #main > * { + margin: 0; + min-height: 100%; + left: 0; + right: 0; + box-sizing: border-box; + -moz-box-sizing: border-box; +} + +iron-selector:not(.narrow-layout) #main ::content [paper-drawer-toggle] { + display: none; +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel.html b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel.html new file mode 100644 index 0000000..d7ea76b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-drawer-panel/paper-drawer-panel.html @@ -0,0 +1,128 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-media-query/iron-media-query.html"> +<link rel="import" href="../iron-selector/iron-selector.html"> + +<!-- +`paper-drawer-panel` contains a drawer panel and a main panel. The drawer +and the main panel are side-by-side with drawer on the left. When the browser +window size is smaller than the `responsiveWidth`, `paper-drawer-panel` +changes to narrow layout. In narrow layout, the drawer will be stacked on top +of the main panel. The drawer will slide in/out to hide/reveal the main +panel. + +Use the attribute `drawer` to indicate that the element is the drawer panel and +`main` to indicate that the element is the main panel. + +Example: + + <paper-drawer-panel> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> + </paper-drawer-panel> + +The drawer and the main panels are not scrollable. You can set CSS overflow +property on the elements to make them scrollable or use `paper-header-panel`. + +Example: + + <paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar></paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar></paper-toolbar> + <div> Main content... </div> + </paper-header-panel> + </paper-drawer-panel> + +An element that should toggle the drawer will automatically do so if it's +given the `paper-drawer-toggle` attribute. Also this element will automatically +be hidden in wide layout. + +Example: + + <paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar> + <div>Application</div> + </paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar> + <paper-icon-button icon="menu" paper-drawer-toggle></paper-icon-button> + <div>Title</div> + </paper-toolbar> + <div> Main content... </div> + </paper-header-panel> + </paper-drawer-panel> + +To position the drawer to the right, add `right-drawer` attribute. + + <paper-drawer-panel right-drawer> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> + </paper-drawer-panel> + +Styling paper-drawer-panel: + +To change the main container: + paper-drawer-panel { + --paper-drawer-panel-main-container: { + background-color: gray; + }; + } + +To change the drawer container when it's in the left side: + paper-drawer-panel { + --paper-drawer-panel-left-drawer-container: { + background-color: white; + }; + } + +To change the drawer container when it's in the right side: + + paper-drawer-panel { + --paper-drawer-panel-right-drawer-container: { + background-color: white; + }; + } + +@group Paper elements +@element paper-drawer-panel +@demo demo/index.html +@hero hero.svg +--> + +</head><body><dom-module id="paper-drawer-panel"> + <link rel="import" type="css" href="paper-drawer-panel.css"> + + <template> + <iron-media-query id="mq" on-query-matches-changed="_onQueryMatchesChanged" query="[[_computeMediaQuery(forceNarrow, responsiveWidth)]]"> + </iron-media-query> + + <iron-selector attr-for-selected="id" class$="[[_computeIronSelectorClass(narrow, transition, dragging, rightDrawer)]]" activate-event="" selected="[[selected]]"> + + <div id="main" style$="[[_computeMainStyle(narrow, rightDrawer, drawerWidth)]]"> + <content select="[main]"></content> + <div id="scrim" on-tap="closeDrawer"></div> + </div> + + <div id="drawer" style$="[[_computeDrawerStyle(drawerWidth)]]"> + <content select="[drawer]"></content> + </div> + + </iron-selector> + </template> + +</dom-module> + +<script src="paper-drawer-panel-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-elements/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-elements/.bower.json new file mode 100644 index 0000000..5bfdd28 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-elements/.bower.json @@ -0,0 +1,60 @@ +{ + "name": "paper-elements", + "version": "1.0.1", + "homepage": "https://github.com/PolymerElements/paper-elements", + "authors": [ + "The Polymer Authors" + ], + "description": "Paper elements are a set of visual elements that implement Google's Material Design.", + "main": "paper-elements.html", + "keywords": [ + "web-components", + "polymer", + "paper" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-dialog": "PolymerElements/paper-dialog#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "paper-drawer-panel": "PolymerElements/paper-drawer-panel#^1.0.0", + "paper-fab": "PolymerElements/paper-fab#^1.0.0", + "paper-header-panel": "PolymerElements/paper-header-panel#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-menu": "PolymerElements/paper-menu#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-radio-group": "PolymerElements/paper-radio-group#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-slider": "PolymerElements/paper-slider#^1.0.0", + "paper-spinner": "PolymerElements/paper-spinner#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-tabs": "PolymerElements/paper-tabs#^1.0.0", + "paper-toast": "PolymerElements/paper-toast#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "paper-scroll-header-panel": "PolymerElements/paper-scroll-header-panel#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "c4b7d791a9a7cfec9d671a34112c97a0dad5de69" + }, + "_source": "git://github.com/PolymerElements/paper-elements.git", + "_target": "~1.0.0", + "_originalSource": "PolymerElements/paper-elements" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-elements/README.md b/third_party/polymer/v1_0/components-chromium/paper-elements/README.md new file mode 100644 index 0000000..300275c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-elements/README.md @@ -0,0 +1,21 @@ +#paper-elements + +The paper elements are a set of UI components designed to implement Google's [material design](http://www.google.com/design/spec/material-design/introduction.html) guidelines. + +## Roadmap + +### Elements in progress + +* `paper-dropdown-menu` - a dropdown menu + +### Elements planned +_Elements we're planning on building soon but haven't started yet_ + +* `paper-tooltip` - a hover tooltip + +[Currently focused on getting all elements up to speed] + +### Elements not planned, notably +_Elements we're not planning on building as part of this product line, but that one might be wondering about_ + +[None] diff --git a/third_party/polymer/v1_0/components-chromium/paper-elements/bower.json b/third_party/polymer/v1_0/components-chromium/paper-elements/bower.json new file mode 100644 index 0000000..34083c3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-elements/bower.json @@ -0,0 +1,51 @@ +{ + "name": "paper-elements", + "version": "1.0.1", + "homepage": "https://github.com/PolymerElements/paper-elements", + "authors": [ + "The Polymer Authors" + ], + "description": "Paper elements are a set of visual elements that implement Google's Material Design.", + "main": "paper-elements.html", + "keywords": [ + "web-components", + "polymer", + "paper" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-dialog": "PolymerElements/paper-dialog#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "paper-drawer-panel": "PolymerElements/paper-drawer-panel#^1.0.0", + "paper-fab": "PolymerElements/paper-fab#^1.0.0", + "paper-header-panel": "PolymerElements/paper-header-panel#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-menu": "PolymerElements/paper-menu#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-radio-group": "PolymerElements/paper-radio-group#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-slider": "PolymerElements/paper-slider#^1.0.0", + "paper-spinner": "PolymerElements/paper-spinner#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-tabs": "PolymerElements/paper-tabs#^1.0.0", + "paper-toast": "PolymerElements/paper-toast#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "paper-scroll-header-panel": "PolymerElements/paper-scroll-header-panel#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-fab/.bower.json new file mode 100644 index 0000000..4fe9c9f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-fab", + "version": "1.0.1", + "description": "A material design floating action button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button" + ], + "main": "paper-fab.html", + "ignore": [], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-fab" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-fab", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "3c626a4d116d774e9f4db3a3e0f92b0c8148f12e" + }, + "_source": "git://github.com/PolymerElements/paper-fab.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-fab" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-fab/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/README.md b/third_party/polymer/v1_0/components-chromium/paper-fab/README.md new file mode 100644 index 0000000..5da43e2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/README.md @@ -0,0 +1,44 @@ +paper-fab +========= + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Button</a> + +`paper-fab` is a floating action button. It contains an image placed in the center and +comes in two sizes: regular size and a smaller size by applying the attribute `mini`. When +the user touches the button, a ripple effect emanates from the center of the button. + +You may import `iron-icons` to use with this element, or provide a URL to a custom icon. +See `iron-iconset` for more information about how to use a custom icon set. + +Example: + +```html +<link href="path/to/iron-icons/iron-icons.html" rel="import"> + +<paper-fab icon="add"></paper-fab> +<paper-fab mini icon="favorite"></paper-fab> +<paper-fab src="star.png"></paper-fab> +``` + +Styling +------- + +Style the button with CSS as you would a normal DOM element. If you are using the icons +provided by `iron-icons`, the icon will inherit the foreground color of the button. + +```html +<!-- make a blue "cloud" button --> +<paper-fab icon="cloud" style="color: blue;"></paper-fab> +``` + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + +```css +/* make #my-button use a blue ripple instead of foreground color */ +#my-button::shadow #ripple { + color: blue; +} +``` + +The opacity of the ripple is not customizable via CSS. diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/bower.json b/third_party/polymer/v1_0/components-chromium/paper-fab/bower.json new file mode 100644 index 0000000..b195ccb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-fab", + "version": "1.0.1", + "description": "A material design floating action button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button" + ], + "main": "paper-fab.html", + "ignore": [], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-fab" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-fab", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/index.html b/third_party/polymer/v1_0/components-chromium/paper-fab/index.html new file mode 100644 index 0000000..c98a658 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>paper-fab</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/paper-fab-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-fab/paper-fab-extracted.js new file mode 100644 index 0000000..649e445 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/paper-fab-extracted.js @@ -0,0 +1,50 @@ + + Polymer({ + is: 'paper-fab', + + behaviors: [ + Polymer.PaperButtonBehavior + ], + + properties: { + /** + * The URL of an image for the icon. If the src property is specified, + * the icon property should not be. + * + * @attribute src + * @type string + * @default '' + */ + src: { + type: String, + value: '' + }, + + /** + * Specifies the icon name or index in the set of icons available in + * the icon's icon set. If the icon property is specified, + * the src property should not be. + * + * @attribute icon + * @type string + * @default '' + */ + icon: { + type: String, + value: '' + }, + + /** + * Set this to true to style this is a "mini" FAB. + * + * @attribute mini + * @type boolean + * @default false + */ + mini: { + type: Boolean, + value: false + } + } + + }); diff --git a/third_party/polymer/v1_0/components-chromium/paper-fab/paper-fab.html b/third_party/polymer/v1_0/components-chromium/paper-fab/paper-fab.html new file mode 100644 index 0000000..320293a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-fab/paper-fab.html @@ -0,0 +1,107 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-styles/color.html"> +<link rel="import" href="../paper-material/paper-material.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-behaviors/paper-button-behavior.html"> + +<!-- +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Button</a> + +`paper-fab` is a floating action button. It contains an image placed in the center and +comes in two sizes: regular size and a smaller size by applying the attribute `mini`. When +the user touches the button, a ripple effect emanates from the center of the button. + +You may import `iron-icons` to use with this element, or provide a URL to a custom icon. +See `iron-iconset` for more information about how to use a custom icon set. + +Example: + + <link href="path/to/iron-icons/iron-icons.html" rel="import"> + + <paper-fab icon="add"></paper-fab> + <paper-fab mini icon="favorite"></paper-fab> + <paper-fab src="star.png"></paper-fab> + + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-fab-background` | The background color of the button | `--paper-indigo-500` +`--paper-fab-disabled-background` | The background color of the button when it's disabled | `--paper-grey-300` +`--paper-fab-disabled-text` | The text color of the button when it's disabled | `--paper-grey-500` +`--paper-fab` | Mixin applied to the button | `{}` +`--paper-fab-mini` | Mixin applied to a mini button | `{}` +`--paper-fab-disabled` | Mixin applied to a disabled button | `{}` + +@group Paper Elements +@demo demo/index.html + +--> + +</head><body><dom-module id="paper-fab"> + <style> + + :host { + display: inline-block; + position: relative; + outline: none; + -moz-user-select: none; + -ms-user-select: none; + -webkit-user-select: none; + user-select: none; + cursor: pointer; + + box-sizing: border-box; + min-width: 0; + width: 56px; + height: 56px; + background: var(--paper-fab-background, --paper-indigo-500); + color: var(--text-primary-color); + border-radius: 50%; + padding: 16px; + + z-index: 0; + + @apply(--paper-fab); + } + + :host([mini]) { + width: 40px; + height: 40px; + padding: 8px; + + @apply(--paper-fab-mini); + } + + :host([disabled]) { + color: var(--paper-fab-disabled-text, --paper-grey-500); + background: var(--paper-fab-disabled-background, --paper-grey-300); + @apply(--paper-fab-disabled); + } + + paper-material { + border-radius: inherit; + } + </style> + <template> + <paper-ripple></paper-ripple> + <paper-material class="content fit flex layout vertical center-center" elevation="[[elevation]]" animated=""> + <iron-icon id="icon" src="[[src]]" icon="[[icon]]"></iron-icon> + </paper-material> + </template> +</dom-module> +<script src="paper-fab-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-header-panel/.bower.json new file mode 100644 index 0000000..394924f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-header-panel", + "version": "1.0.1", + "description": "A header and content wrapper for layout with headers", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-header-panel", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "ec388b9579fe61ce84e498132cd33ec275e8e398" + }, + "_source": "git://github.com/PolymerElements/paper-header-panel.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-header-panel" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-header-panel/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/README.md b/third_party/polymer/v1_0/components-chromium/paper-header-panel/README.md new file mode 100644 index 0000000..aab76e6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/README.md @@ -0,0 +1,105 @@ +# paper-header-panel + +`paper-header-panel` contains a header section and a content panel section. + +__Important:__ The `paper-header-panel` will not display if its parent does not have a height. + +Using [layout classes](http://www.polymer-project.org/docs/polymer/layout-attrs.html), you can make +the `paper-header-panel` fill the screen + +```html +<body class="fullbleed layout vertical"> + <paper-header-panel class="flex"> + <paper-toolbar> + <div>Hello World!</div> + </paper-toolbar> + </paper-header-panel> +</body> +``` + +Special support is provided for scrolling modes when one uses a `paper-toolbar` or equivalent for the header section. For example: + +```html +<paper-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> +</paper-header-panel> +``` + +If you want to use other than `paper-toolbar` for the header, add `paper-header` class to that +element: + +```html +<paper-header-panel> + <div class="paper-header">Header</div> + <div>Content goes here...</div> +</paper-header-panel> +``` + +To have the content fit to the main area, use the `fit` class: + +```html +<paper-header-panel> + <div class="paper-header">standard</div> + <div class="content fit">content fits 100% below the header</div> +</paper-header-panel> +``` + +### Mode + +Controls header and scrolling behavior. Options are `standard`, `seamed`, `waterfall`, `waterfall-tall`, `scroll` and +`cover`. Default is `standard`. + +Mode | Description +----------------|------------- +`standard` | The header is a step above the panel. The header will consume the panel at the point of entry, preventing it from passing through to the opposite side. +`seamed` | The header is presented as seamed with the panel. +`waterfall` | Similar to standard mode, but header is initially presented as seamed with panel, but then separates to form the step. +`waterfall-tall` | The header is initially taller (`tall` class is added to the header). As the user scrolls, the header separates (forming an edge) while condensing (`tall` class is removed from the header). +`scroll` | The header keeps its seam with the panel, and is pushed off screen. +`cover` | The panel covers the whole `paper-header-panel` including the header. This allows user to style the panel in such a way that the panel is partially covering the header. + +Example: + +```html +<paper-header-panel mode="waterfall"> + <div class="paper-header">standard</div> + <div class="content fit">content fits 100% below the header</div> +</paper-header-panel> +``` + +### Styling header panel: + +To change the shadow that shows up underneath the header: + +```css +paper-header-panel { + --paper-header-panel-shadow: { + height: 6px; + bottom: -6px; + box-shadow: inset 0px 5px 6px -3px rgba(0, 0, 0, 0.4); + }; +} +``` + +To change the panel container: + +```css +paper-slider { + --paper-header-panel-standard-container: { + border: 1px solid gray; + }; + + --paper-header-panel-cover-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-tall-container: { + border: 1px solid gray; + }; +} +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/bower.json b/third_party/polymer/v1_0/components-chromium/paper-header-panel/bower.json new file mode 100644 index 0000000..57314e7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/bower.json @@ -0,0 +1,28 @@ +{ + "name": "paper-header-panel", + "version": "1.0.1", + "description": "A header and content wrapper for layout with headers", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-header-panel", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-header-panel/hero.svg new file mode 100644 index 0000000..60c7488 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/hero.svg @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M163,102H73V24h90V102z M75,100h86V26H75V100z"/> + <g> + <polygon points="74,59.6 74,62.5 74.5,63 77.4,63 "/> + <polygon points="74,51.9 74,54.7 82.3,63 85.1,63 "/> + <polygon points="74,44.1 74,46.9 90.1,63 92.9,63 "/> + <polygon points="74,36.3 74,39.2 97.8,63 100.7,63 "/> + <polygon points="74,28.6 74,31.4 105.6,63 108.4,63 "/> + <polygon points="78.2,25 75.4,25 113.4,63 116.2,63 "/> + <polygon points="86,25 83.1,25 121.1,63 124,63 "/> + <polygon points="93.7,25 90.9,25 128.9,63 131.7,63 "/> + <polygon points="101.5,25 98.7,25 136.7,63 139.5,63 "/> + <polygon points="109.2,25 106.4,25 144.4,63 147.2,63 "/> + <polygon points="117,25 114.2,25 152.2,63 155,63 "/> + <polygon points="124.8,25 122,25 160,63 162,63 162,62.2 "/> + <polygon points="132.5,25 129.7,25 162,57.3 162,54.5 "/> + <polygon points="140.3,25 137.5,25 162,49.5 162,46.7 "/> + <polygon points="148.1,25 145.2,25 162,41.8 162,38.9 "/> + <polygon points="155.8,25 153,25 162,34 162,31.2 "/> + <polygon points="162,26.2 162,25 160.8,25 "/> + </g> + <rect x="74" y="62" width="88" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/index.html b/third_party/polymer/v1_0/components-chromium/paper-header-panel/index.html new file mode 100644 index 0000000..8d0771c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/index.html @@ -0,0 +1,36 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-header-panel</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + <style> + body { + margin: 16px; + } + </style> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/paper-header-panel-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-header-panel/paper-header-panel-extracted.js new file mode 100644 index 0000000..9a6ca40 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/paper-header-panel-extracted.js @@ -0,0 +1,250 @@ + + + (function() { + + 'use strict'; + + var SHADOW_WHEN_SCROLLING = 1; + var SHADOW_ALWAYS = 2; + + + var MODE_CONFIGS = { + + outerScroll: { + scroll: true + }, + + shadowMode: { + standard: SHADOW_ALWAYS, + waterfall: SHADOW_WHEN_SCROLLING, + 'waterfall-tall': SHADOW_WHEN_SCROLLING + }, + + tallMode: { + 'waterfall-tall': true + } + }; + + Polymer({ + + is: 'paper-header-panel', + + /** + * Fired when the content has been scrolled. `event.detail.target` returns + * the scrollable element which you can use to access scroll info such as + * `scrollTop`. + * + * <paper-header-panel on-content-scroll="{{scrollHandler}}"> + * ... + * </paper-header-panel> + * + * + * scrollHandler: function(event) { + * var scroller = event.detail.target; + * console.log(scroller.scrollTop); + * } + * + * @event content-scroll + */ + + properties: { + + /** + * Controls header and scrolling behavior. Options are + * `standard`, `seamed`, `waterfall`, `waterfall-tall`, `scroll` and + * `cover`. Default is `standard`. + * + * `standard`: The header is a step above the panel. The header will consume the + * panel at the point of entry, preventing it from passing through to the + * opposite side. + * + * `seamed`: The header is presented as seamed with the panel. + * + * `waterfall`: Similar to standard mode, but header is initially presented as + * seamed with panel, but then separates to form the step. + * + * `waterfall-tall`: The header is initially taller (`tall` class is added to + * the header). As the user scrolls, the header separates (forming an edge) + * while condensing (`tall` class is removed from the header). + * + * `scroll`: The header keeps its seam with the panel, and is pushed off screen. + * + * `cover`: The panel covers the whole `paper-header-panel` including the + * header. This allows user to style the panel in such a way that the panel is + * partially covering the header. + * + * <paper-header-panel mode="cover"> + * <paper-toolbar class="tall"> + * <core-icon-button icon="menu"></core-icon-button> + * </paper-toolbar> + * <div class="content"></div> + * </paper-header-panel> + */ + mode: { + type: String, + value: 'standard', + observer: '_modeChanged', + reflectToAttribute: true + }, + + /** + * If true, the drop-shadow is always shown no matter what mode is set to. + */ + shadow: { + type: Boolean, + value: false + }, + + /** + * The class used in waterfall-tall mode. Change this if the header + * accepts a different class for toggling height, e.g. "medium-tall" + */ + tallClass: { + type: String, + value: 'tall' + }, + + /** + * If true, the scroller is at the top + */ + atTop: { + type: Boolean, + value: true, + readOnly: true + } + }, + + observers: [ + '_computeDropShadowHidden(atTop, mode, shadow)' + ], + + ready: function() { + this.scrollHandler = this._scroll.bind(this); + this._addListener(); + + // Run `scroll` logic once to initialze class names, etc. + this._keepScrollingState(); + }, + + detached: function() { + this._removeListener(); + }, + + /** + * Returns the header element + * + * @property header + * @type Object + */ + get header() { + return Polymer.dom(this.$.headerContent).getDistributedNodes()[0]; + }, + + /** + * Returns the scrollable element. + * + * @property scroller + * @type Object + */ + get scroller() { + return this._getScrollerForMode(this.mode); + }, + + /** + * Returns true if the scroller has a visible shadow. + * + * @property visibleShadow + * @type Boolean + */ + get visibleShadow() { + return this.header.classList.contains('has-shadow'); + }, + + _computeDropShadowHidden: function(atTop, mode, shadow) { + + var shadowMode = MODE_CONFIGS.shadowMode[mode]; + + if (this.shadow) { + this.toggleClass('has-shadow', true, this.header); + + } else if (shadowMode === SHADOW_ALWAYS) { + this.toggleClass('has-shadow', true, this.header); + + } else if (shadowMode === SHADOW_WHEN_SCROLLING && !atTop) { + this.toggleClass('has-shadow', true, this.header); + + } else { + this.toggleClass('has-shadow', false, this.header); + + } + }, + + _computeMainContainerClass: function(mode) { + // TODO: It will be useful to have a utility for classes + // e.g. Polymer.Utils.classes({ foo: true }); + + var classes = {}; + + classes['flex'] = mode !== 'cover'; + + return Object.keys(classes).filter( + function(className) { + return classes[className]; + }).join(' '); + }, + + _addListener: function() { + this.scroller.addEventListener('scroll', this.scrollHandler, false); + }, + + _removeListener: function() { + this.scroller.removeEventListener('scroll', this.scrollHandler); + }, + + _modeChanged: function(newMode, oldMode) { + var configs = MODE_CONFIGS; + var header = this.header; + var animateDuration = 200; + + if (header) { + // in tallMode it may add tallClass to the header; so do the cleanup + // when mode is changed from tallMode to not tallMode + if (configs.tallMode[oldMode] && !configs.tallMode[newMode]) { + header.classList.remove(this.tallClass); + this.async(function() { + header.classList.remove('animate'); + }, null, animateDuration); + } else { + header.classList.toggle('animate', configs.tallMode[newMode]); + } + } + this._keepScrollingState(); + }, + + _keepScrollingState: function () { + var main = this.scroller; + var header = this.header; + + this._setAtTop(main.scrollTop === 0); + + if (header && MODE_CONFIGS.tallMode[this.mode]) { + this.toggleClass(this.tallClass, this.atTop || + header.classList.contains(this.tallClass) && + main.scrollHeight < this.offsetHeight, header); + } + }, + + _scroll: function(e) { + this._keepScrollingState(); + this.fire('content-scroll', {target: this.scroller}, this, false); + }, + + _getScrollerForMode: function(mode) { + return MODE_CONFIGS.outerScroll[mode] ? + this : this.$.mainContainer; + } + + }); + + })(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-header-panel/paper-header-panel.html b/third_party/polymer/v1_0/components-chromium/paper-header-panel/paper-header-panel.html new file mode 100644 index 0000000..9a6ec35 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-header-panel/paper-header-panel.html @@ -0,0 +1,244 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> + +<!-- +`paper-header-panel` contains a header section and a content panel section. + +__Important:__ The `paper-header-panel` will not display if its parent does not have a height. + +Using layout classes, you can make the `paper-header-panel` fill the screen + + <body class="fullbleed layout vertical"> + <paper-header-panel class="flex"> + <paper-toolbar> + <div>Hello World!</div> + </paper-toolbar> + </paper-header-panel> + </body> + +Special support is provided for scrolling modes when one uses a paper-toolbar or equivalent for the +header section. + +Example: + + <paper-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> + </paper-header-panel> + +If you want to use other than `paper-toolbar` for the header, add `paper-header` class to that +element. + +Example: + + <paper-header-panel> + <div class="paper-header">Header</div> + <div>Content goes here...</div> + </paper-header-panel> + +To have the content fit to the main area, use the `fit` class. + + <paper-header-panel> + <div class="paper-header">standard</div> + <div class="fit">content fits 100% below the header</div> + </paper-header-panel> + +Modes + +Controls header and scrolling behavior. Options are `standard`, `seamed`, `waterfall`, `waterfall-tall`, `scroll` and +`cover`. Default is `standard`. + +Mode | Description +----------------|------------- +`standard` | The header is a step above the panel. The header will consume the panel at the point of entry, preventing it from passing through to the opposite side. +`seamed` | The header is presented as seamed with the panel. +`waterfall` | Similar to standard mode, but header is initially presented as seamed with panel, but then separates to form the step. +`waterfall-tall` | The header is initially taller (`tall` class is added to the header). As the user scrolls, the header separates (forming an edge) while condensing (`tall` class is removed from the header). +`scroll` | The header keeps its seam with the panel, and is pushed off screen. +`cover` | The panel covers the whole `paper-header-panel` including the header. This allows user to style the panel in such a way that the panel is partially covering the header. + +Example: + + <paper-header-panel mode="waterfall"> + <div class="paper-header">standard</div> + <div class="content fit">content fits 100% below the header</div> + </paper-header-panel> + + +Styling header panel: + +To change the shadow that shows up underneath the header: + + paper-header-panel { + --paper-header-panel-shadow: { + height: 6px; + bottom: -6px; + box-shadow: inset 0px 5px 6px -3px rgba(0, 0, 0, 0.4); + }; + } + +To change the panel container in different modes: + + paper-slider { + --paper-header-panel-standard-container: { + border: 1px solid gray; + }; + + --paper-header-panel-cover-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-tall-container: { + border: 1px solid gray; + }; + } + +@group Paper Elements +@element paper-header-panel +@demo demo/index.html +@hero hero.svg +--> + +</head><body><dom-module id="paper-header-panel"> + + <style> + :host { + @apply(--layout); + @apply(--layout-vertical); + + display: block; + position: relative; + height: 100%; + + /* Create a stack context, we will need it for the shadow*/ + z-index: 0; + } + + #mainContainer { + @apply(--layout-flex); + + position: relative; + overflow-y: auto; + overflow-x: hidden; + -webkit-overflow-scrolling: touch; + flex-basis: 0.0001px; + } + + /* + * mode: scroll + */ + :host([mode=scroll]) #mainContainer { + @apply(--paper-header-panel-scroll-container); + overflow: visible; + } + + :host([mode=scroll]) { + overflow-y: auto; + overflow-x: hidden; + -webkit-overflow-scrolling: touch; + } + + /* + * mode: cover + */ + :host([mode=cover]) #mainContainer { + @apply(--paper-header-panel-cover-container); + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + /* + * mode: standard + */ + :host([mode=standard]) #mainContainer { + @apply(--paper-header-panel-standard-container); + } + + /* + * mode: waterfall + */ + :host([mode=waterfall]) #mainContainer { + @apply(--paper-header-panel-waterfall-container); + } + + /* + * mode: waterfall-tall + */ + :host([mode=waterfall-tall]) #mainContainer { + @apply(--paper-header-panel-waterfall-tall-container); + } + + :host ::content paper-toolbar, + :host ::content .paper-header { + position: relative; + overflow: visible !important; + } + + :host ::content paper-toolbar:after, + :host ::content .paper-header:after { + @apply(--paper-header-panel-shadow); + + -webkit-transition: opacity 0.5s, -webkit-transform 0.5s; + transition: opacity 0.5s, transform 0.5s; + + opacity: 0; + content: ""; + + width: 100%; + position: absolute; + left: 0px; + right: 0px; + z-index: 1; + + -webkit-transform: scale3d(1, 0, 1); + -webkit-transform-origin: 0% 0%; + + transform: scale3d(1, 0, 1); + transform-origin: 0% 0%; + } + + :host ::content paper-toolbar.has-shadow:after, + :host ::content .paper-header.has-shadow:after { + opacity: 1; + -webkit-transform: scale3d(1, 1, 1); + transform: scale3d(1, 1, 1); + } + </style> + + <template> + <content id="headerContent" select="paper-toolbar, .paper-header"></content> + <div id="mainContainer" class$="[[_computeMainContainerClass(mode)]]"> + <content id="mainContent" select="*"></content> + </div> + </template> + +</dom-module> + +<style is="custom-style"> + :root { + /** + * Default paper header panel shadow + */ + --paper-header-panel-shadow: { + height: 6px; + bottom: -6px; + box-shadow: inset 0px 5px 6px -3px rgba(0, 0, 0, 0.4); + }; + } +</style> + +<script src="paper-header-panel-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-icon-button/.bower.json new file mode 100644 index 0000000..f5ebf09 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/.bower.json @@ -0,0 +1,43 @@ +{ + "name": "paper-icon-button", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design icon button", + "main": "paper-icon-button.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button", + "icon", + "control" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^0.9.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-icon-button", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "0db7b75d5e37d8521b6aceb94b185a57145699d9" + }, + "_source": "git://github.com/PolymerElements/paper-icon-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-icon-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-icon-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/README.md b/third_party/polymer/v1_0/components-chromium/paper-icon-button/README.md new file mode 100644 index 0000000..96dbf8e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/README.md @@ -0,0 +1,49 @@ +paper-icon-button +================= + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-icon-button` is a button with an image placed at the center. When the user touches +the button, a ripple effect emanates from the center of the button. + +`paper-icon-button` includes a default icon set. Use `icon` to specify which icon +from the icon set to use. + +```html +<paper-icon-button icon="menu"></paper-icon-button> +``` + +See [`iron-iconset`](#iron-iconset) for more information about +how to use a custom icon set. + +Example: + +```html +<link href="path/to/iron-icons/iron-icons.html" rel="import"> + +<paper-icon-button icon="favorite"></paper-icon-button> +<paper-icon-button src="star.png"></paper-icon-button> +``` + +Styling +------- + +Style the button with CSS as you would a normal DOM element. If you are using the icons +provided by `iron-icons`, they will inherit the foreground color of the button. + +```html +<!-- make a red "favorite" button --> +<paper-icon-button icon="favorite" style="color: red;"></paper-icon-button> +``` + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + +```css +/* make #my-button use a blue ripple instead of foreground color */ +#my-button::shadow #ripple { + color: blue; +} +``` + +The opacity of the ripple is not customizable via CSS. diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/bower.json b/third_party/polymer/v1_0/components-chromium/paper-icon-button/bower.json new file mode 100644 index 0000000..879efb1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/bower.json @@ -0,0 +1,33 @@ +{ + "name": "paper-icon-button", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design icon button", + "main": "paper-icon-button.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button", + "icon", + "control" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^0.9.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/index.html b/third_party/polymer/v1_0/components-chromium/paper-icon-button/index.html new file mode 100644 index 0000000..94c3720 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/index.html @@ -0,0 +1,23 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <script src="../webcomponentsjs/webcomponents.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/paper-icon-button-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-icon-button/paper-icon-button-extracted.js new file mode 100644 index 0000000..b2698d2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/paper-icon-button-extracted.js @@ -0,0 +1,28 @@ + + Polymer({ + is: 'paper-icon-button', + + behaviors: [ + Polymer.PaperButtonBehavior, + Polymer.PaperRadioButtonBehavior + ], + + properties: { + /** + * The URL of an image for the icon. If the src property is specified, + * the icon property should not be. + */ + src: { + type: String + }, + + /** + * Specifies the icon name or index in the set of icons available in + * the icon's icon set. If the icon property is specified, + * the src property should not be. + */ + icon: { + type: String + } + } + }); diff --git a/third_party/polymer/v1_0/components-chromium/paper-icon-button/paper-icon-button.html b/third_party/polymer/v1_0/components-chromium/paper-icon-button/paper-icon-button.html new file mode 100644 index 0000000..45d584b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-icon-button/paper-icon-button.html @@ -0,0 +1,111 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-behaviors/paper-button-behavior.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> + +<style is="custom-style"> + :root { + --paper-icon-button-disabled-text: var(--disabled-text-color); + } +</style> + +<!-- +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-icon-button` is a button with an image placed at the center. When the user touches +the button, a ripple effect emanates from the center of the button. + +`paper-icon-button` includes a default icon set. Use `icon` to specify which icon +from the icon set to use. + + <paper-icon-button icon="menu"></paper-icon-button> + +See [`iron-iconset`](#iron-iconset) for more information about +how to use a custom icon set. + +Example: + + <link href="path/to/iron-icons/iron-icons.html" rel="import"> + + <paper-icon-button icon="favorite"></paper-icon-button> + <paper-icon-button src="star.png"></paper-icon-button> + +###Styling + +Style the button with CSS as you would a normal DOM element. If you are using the icons +provided by `iron-icons`, they will inherit the foreground color of the button. + + /* make a red "favorite" button */ + <paper-icon-button icon="favorite" style="color: red;"></paper-icon-button> + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + + /* make #my-button use a blue ripple instead of foreground color */ + #my-button::shadow #ripple { + color: blue; + } + +The opacity of the ripple is not customizable via CSS. + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-icon-button-disabled-text` | The color of the disabled button | `--primary-text-color` +`--paper-icon-button-ink-color` | Selected/focus ripple color | `--default-primary-color` +`--paper-icon-button` | Mixin for a button | `{}` +`--paper-icon-button-disabled` | Mixin for a disabled button | `{}` + +@group Paper Elements +@element paper-icon-button +@demo demo/index.html +--> + +</head><body><dom-module id="paper-icon-button"> + <style> + + :host { + display: inline-block; + position: relative; + padding: 8px; + outline: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; + z-index: 0; + + @apply(--paper-icon-button); + } + + :host #ink { + color: var(--paper-icon-button-ink-color, --primary-text-color); + opacity: 0.6; + } + + :host([disabled]) { + color: var(--paper-icon-button-disabled-text, #fff); + pointer-events: none; + cursor: auto; + @apply(--paper-icon-button-disabled); + } + </style> + <template> + <paper-ripple id="ink" class="circle" center=""></paper-ripple> + <iron-icon id="icon" src="[[src]]" icon="[[icon]]"></iron-icon> + </template> +</dom-module> +<script src="paper-icon-button-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-input/.bower.json new file mode 100644 index 0000000..fc83cc2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/.bower.json @@ -0,0 +1,53 @@ +{ + "name": "paper-input", + "version": "1.0.0", + "description": "Material design text fields", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "paper-input.html", + "paper-textarea.html", + "paper-input-behavior.html", + "paper-input-container.html", + "paper-input-error.html", + "paper-input-char-counter.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-input", + "ignore": [], + "dependencies": { + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "47a869b431fd03b9f611aee8eb286f0497ad379b" + }, + "_source": "git://github.com/PolymerElements/paper-input.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-input" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-input/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/README.md b/third_party/polymer/v1_0/components-chromium/paper-input/README.md new file mode 100644 index 0000000..c49ccc0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/README.md @@ -0,0 +1,5 @@ +# paper-input + +`<paper-input>` is a Material Design text field. + +Contains a number of different features for validation, character counting, and more. diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/all-imports.html b/third_party/polymer/v1_0/components-chromium/paper-input/all-imports.html new file mode 100644 index 0000000..0f45771 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/all-imports.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="paper-input.html"> +<link rel="import" href="paper-textarea.html"> diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/bower.json b/third_party/polymer/v1_0/components-chromium/paper-input/bower.json new file mode 100644 index 0000000..d98556e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-input", + "version": "1.0.0", + "description": "Material design text fields", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "paper-input.html", + "paper-textarea.html", + "paper-input-behavior.html", + "paper-input-container.html", + "paper-input-error.html", + "paper-input-char-counter.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-input", + "ignore": [], + "dependencies": { + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-input/hero.svg new file mode 100644 index 0000000..146ffea --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/hero.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <rect x="49" y="53" width="2" height="18"/> + <path d="M188,78H37V44h151V78z M39,76h147V46H39V76z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/index.html b/third_party/polymer/v1_0/components-chromium/paper-input/index.html new file mode 100644 index 0000000..e6c9fad --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-input</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="all-imports.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-addon-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-addon-behavior-extracted.js new file mode 100644 index 0000000..dda2f2e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-addon-behavior-extracted.js @@ -0,0 +1,30 @@ + + + /** + * Use `Polymer.PaperInputAddonBehavior` to implement an add-on for `<paper-input-container>`. A + * add-on appears below the input, and may display information based on the input value and + * validity such as a character counter or an error message. + * @polymerBehavior + */ + Polymer.PaperInputAddonBehavior = { + + hostAttributes: { + 'add-on': '' + }, + + attached: function() { + this.fire('addon-attached'); + }, + + /** + * The function called by `<paper-input-container>` when the input value or validity changes. + * @param {Object} state All properties are optional. + * @param {Node} state.inputElement The input element. + * @param {String} state.value The input value. + * @param {Boolean} state.invalid True if the input value is invalid. + */ + update: function(state) { + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-addon-behavior.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-addon-behavior.html new file mode 100644 index 0000000..a7e982d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-addon-behavior.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="paper-input-addon-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-behavior-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-behavior-extracted.js new file mode 100644 index 0000000..2a0d54c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-behavior-extracted.js @@ -0,0 +1,281 @@ + + + /** + * Use `Polymer.PaperInputBehavior` to implement inputs with `<paper-input-container>`. This + * behavior is implemented by `<paper-input>`. It exposes a number of properties from + * `<paper-input-container>` and `<input is="iron-input">` and they should be bound in your + * template. + * + * The input element can be accessed by the `inputElement` property if you need to access + * properties or methods that are not exposed. + * @polymerBehavior + */ + Polymer.PaperInputBehavior = { + + properties: { + + /** + * The label for this input. Bind this to `<paper-input-container>`'s `label` property. + */ + label: { + type: String + }, + + /** + * The value for this input. Bind this to the `<input is="iron-input">`'s `bindValue` + * property, or the value property of your input that is `notify:true`. + */ + value: { + notify: true, + type: String + }, + + /** + * Set to true to disable this input. Bind this to both the `<paper-input-container>`'s + * and the input's `disabled` property. + */ + disabled: { + type: Boolean, + value: false + }, + + /** + * Returns true if the value is invalid. Bind this to both the `<paper-input-container>`'s + * and the input's `invalid` property. + */ + invalid: { + type: Boolean, + value: false + }, + + /** + * Set to true to prevent the user from entering invalid input. Bind this to the + * `<input is="iron-input">`'s `preventInvalidInput` property. + */ + preventInvalidInput: { + type: Boolean + }, + + /** + * Set this to specify the pattern allowed by `preventInvalidInput`. Bind this to the + * `<input is="iron-input">`'s `allowedPattern` property. + */ + allowedPattern: { + type: String + }, + + /** + * The type of the input. The supported types are `text`, `number` and `password`. Bind this + * to the `<input is="iron-input">`'s `type` property. + */ + type: { + type: String + }, + + /** + * A pattern to validate the `input` with. Bind this to the `<input is="iron-input">`'s + * `pattern` property. + */ + pattern: { + type: String + }, + + /** + * Set to true to mark the input as required. Bind this to the `<input is="iron-input">`'s + * `required` property. + */ + required: { + type: Boolean, + value: false + }, + + /** + * The maximum length of the input value. Bind this to the `<input is="iron-input">`'s + * `maxlength` property. + */ + maxlength: { + type: Number + }, + + /** + * The error message to display when the input is invalid. Bind this to the + * `<paper-input-error>`'s content, if using. + */ + errorMessage: { + type: String + }, + + /** + * Set to true to show a character counter. + */ + charCounter: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable the floating label. Bind this to the `<paper-input-container>`'s + * `noLabelFloat` property. + */ + noLabelFloat: { + type: Boolean, + value: false + }, + + /** + * Set to true to always float the label. Bind this to the `<paper-input-container>`'s + * `alwaysFloatLabel` property. + */ + alwaysFloatLabel: { + type: Boolean, + value: false + }, + + /** + * Set to true to auto-validate the input value. Bind this to the `<paper-input-container>`'s + * `autoValidate` property. + */ + autoValidate: { + type: Boolean, + value: false + }, + + /** + * Name of the validator to use. Bind this to the `<input is="iron-input">`'s `validator` + * property. + */ + validator: { + type: String + }, + + // HTMLInputElement attributes for binding if needed + + /** + * Bind this to the `<input is="iron-input">`'s `autocomplete` property. + */ + autocomplete: { + type: String, + value: 'off' + }, + + /** + * Bind this to the `<input is="iron-input">`'s `autofocus` property. + */ + autofocus: { + type: Boolean + }, + + /** + * Bind this to the `<input is="iron-input">`'s `inputmode` property. + */ + inputmode: { + type: String + }, + + /** + * Bind this to the `<input is="iron-input">`'s `minlength` property. + */ + minlength: { + type: Number + }, + + /** + * Bind this to the `<input is="iron-input">`'s `name` property. + */ + name: { + type: String + }, + + /** + * A placeholder string in addition to the label. If this is set, the label will always float. + */ + placeholder: { + type: String + }, + + /** + * Bind this to the `<input is="iron-input">`'s `readonly` property. + */ + readonly: { + type: Boolean, + value: false + }, + + /** + * Bind this to the `<input is="iron-input">`'s `size` property. + */ + size: { + type: Number + }, + + _ariaDescribedBy: { + type: String, + value: '' + } + + }, + + listeners: { + 'addon-attached': '_onAddonAttached' + }, + + /** + * Returns a reference to the input element. + */ + get inputElement() { + return this.$.input; + }, + + attached: function() { + this._updateAriaLabelledBy(); + }, + + _appendStringWithSpace: function(str, more) { + if (str) { + str = str + ' ' + more; + } else { + str = more; + } + return str; + }, + + _onAddonAttached: function(event) { + var target = event.path ? event.path[0] : event.target; + if (target.id) { + this._ariaDescribedBy = this._appendStringWithSpace(this._ariaDescribedBy, target.id); + } else { + var id = 'paper-input-add-on-' + Math.floor((Math.random() * 100000)); + target.id = id; + this._ariaDescribedBy = this._appendStringWithSpace(this._ariaDescribedBy, id); + } + }, + + /** + * Validates the input element and sets an error style if needed. + */ + validate: function () { + return this.inputElement.validate(); + }, + + _computeAlwaysFloatLabel: function(alwaysFloatLabel, placeholder) { + return placeholder || alwaysFloatLabel; + }, + + _updateAriaLabelledBy: function() { + var label = Polymer.dom(this.root).querySelector('label'); + if (!label) { + this._ariaLabelledBy = ''; + return; + } + var labelledBy; + if (label.id) { + labelledBy = label.id; + } else { + labelledBy = 'paper-input-label-' + new Date().getUTCMilliseconds(); + label.id = labelledBy; + } + this._ariaLabelledBy = labelledBy; + } + + }; + diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-behavior.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-behavior.html new file mode 100644 index 0000000..0db3d09 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-behavior.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> + +</head><body><script src="paper-input-behavior-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-char-counter-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-char-counter-extracted.js new file mode 100644 index 0000000..673f5e7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-char-counter-extracted.js @@ -0,0 +1,41 @@ + + +(function() { + + Polymer({ + + is: 'paper-input-char-counter', + + behaviors: [ + Polymer.PaperInputAddonBehavior + ], + + properties: { + + _charCounterStr: { + type: String, + value: '0' + } + + }, + + update: function(state) { + if (!state.inputElement) { + return; + } + + state.value = state.value || ''; + + // Account for the textarea's new lines. + var str = state.value.replace(/(\r\n|\n|\r)/g, '--').length; + + if (state.inputElement.hasAttribute('maxlength')) { + str += '/' + state.inputElement.getAttribute('maxlength'); + } + this._charCounterStr = str; + } + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-char-counter.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-char-counter.html new file mode 100644 index 0000000..e987006 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-char-counter.html @@ -0,0 +1,52 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="paper-input-addon-behavior.html"> + +<!-- +`<paper-input-char-counter>` is a character counter for use with `<paper-input-container>`. It +shows the number of characters entered in the input and the max length if it is specified. + + <paper-input-container> + <input is="iron-input" maxlength="20"> + <paper-input-char-counter></paper-input-char-counter> + </paper-input-container> + +### Styling + +The following mixin is available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-input-char-counter` | Mixin applied to the element | `{}` +--> +</head><body><dom-module id="paper-input-char-counter"> + + <style> + + :host { + display: inline-block; + float: right; + + @apply(--paper-font-caption); + @apply(--paper-input-char-counter); + } + + </style> + + <template> + + <span>[[_charCounterStr]]</span> + + </template> + +</dom-module> + +<script src="paper-input-char-counter-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-container-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-container-extracted.js new file mode 100644 index 0000000..3b30b2c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-container-extracted.js @@ -0,0 +1,249 @@ + +(function() { + + Polymer({ + + is: 'paper-input-container', + + properties: { + + /** + * Set to true to disable the floating label. The label disappears when the input value is + * not null. + */ + noLabelFloat: { + type: Boolean, + value: false + }, + + /** + * Set to true to always float the floating label. + */ + alwaysFloatLabel: { + type: Boolean, + value: false + }, + + /** + * The attribute to listen for value changes on. + */ + attrForValue: { + type: String, + value: 'bind-value' + }, + + /** + * Set to true to auto-validate the input value when it changes. + */ + autoValidate: { + type: Boolean, + value: false + }, + + /** + * True if the input is invalid. This property is set automatically when the input value + * changes if auto-validating, or when the `iron-input-valid` event is heard from a child. + */ + invalid: { + observer: '_invalidChanged', + type: Boolean, + value: false + }, + + /** + * True if the input has focus. + */ + focused: { + readOnly: true, + type: Boolean, + value: false + }, + + _addons: { + type: Array, + value: function() { + return []; + } + }, + + _inputHasContent: { + type: Boolean, + value: false + }, + + _inputSelector: { + type: String, + value: 'input,textarea,.paper-input-input' + }, + + _boundOnFocus: { + type: Function, + value: function() { + return this._onFocus.bind(this); + } + }, + + _boundOnBlur: { + type: Function, + value: function() { + return this._onBlur.bind(this); + } + }, + + _boundOnInput: { + type: Function, + value: function() { + this._onInput.bind(this) + } + }, + + _boundValueChanged: { + type: Function, + value: function() { + return this._onValueChanged.bind(this); + } + } + + }, + + listeners: { + 'addon-attached': '_onAddonAttached', + 'iron-input-validate': '_onIronInputValidate' + }, + + get _valueChangedEvent() { + return this.attrForValue + '-changed'; + }, + + get _propertyForValue() { + return Polymer.CaseMap.dashToCamelCase(this.attrForValue); + }, + + get _inputElement() { + return Polymer.dom(this).querySelector(this._inputSelector); + }, + + ready: function() { + this.addEventListener('focus', this._boundOnFocus, true); + this.addEventListener('blur', this._boundOnBlur, true); + if (this.attrForValue) { + this._inputElement.addEventListener(this._valueChangedEvent, this._boundValueChanged); + } else { + this.addEventListener('input', this._onInput); + } + }, + + attached: function() { + this._handleValue(this._inputElement); + }, + + _onAddonAttached: function(event) { + this._addons.push(event.target); + this._handleValue(this._inputElement); + }, + + _onFocus: function() { + this._setFocused(true); + }, + + _onBlur: function() { + this._setFocused(false); + }, + + _onInput: function(event) { + this._handleValue(event.target); + }, + + _onValueChanged: function(event) { + this._handleValue(event.target); + }, + + _handleValue: function(inputElement) { + var value = inputElement[this._propertyForValue] || inputElement.value; + + if (this.autoValidate) { + var valid; + if (inputElement.validate) { + valid = inputElement.validate(value); + } else { + valid = inputElement.checkValidity(); + } + this.invalid = !valid; + } + + // type="number" hack needed because this.value is empty until it's valid + if (value || (inputElement.type === 'number' && !inputElement.checkValidity())) { + this._inputHasContent = true; + } else { + this._inputHasContent = false; + } + + this.updateAddons({ + inputElement: inputElement, + value: value, + invalid: this.invalid + }); + }, + + _onIronInputValidate: function(event) { + this.invalid = this._inputElement.invalid; + }, + + _invalidChanged: function() { + if (this._addons) { + this.updateAddons({invalid: this.invalid}); + } + }, + + /** + * Call this to update the state of add-ons. + * @param {Object} state Add-on state. + */ + updateAddons: function(state) { + for (var addon, index = 0; addon = this._addons[index]; index++) { + addon.update(state); + } + }, + + _computeInputContentClass: function(noLabelFloat, alwaysFloatLabel, focused, invalid, _inputHasContent) { + var cls = 'input-content'; + if (!noLabelFloat) { + if (alwaysFloatLabel || _inputHasContent) { + cls += ' label-is-floating'; + if (invalid) { + cls += ' is-invalid'; + } else if (focused) { + cls += " label-is-highlighted"; + } + } + } else { + if (_inputHasContent) { + cls += ' label-is-hidden'; + } + } + return cls; + }, + + _computeUnderlineClass: function(focused, invalid) { + var cls = 'underline'; + if (invalid) { + cls += ' is-invalid'; + } else if (focused) { + cls += ' is-highlighted' + } + return cls; + }, + + _computeAddOnContentClass: function(focused, invalid) { + var cls = 'add-on-content'; + if (invalid) { + cls += ' is-invalid'; + } else if (focused) { + cls += ' is-highlighted' + } + return cls; + } + + }); + +})(); diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-container.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-container.html new file mode 100644 index 0000000..82ff08e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-container.html @@ -0,0 +1,244 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-input-container>` is a container for a `<label>`, an `<input is="iron-input">` or +`<iron-autogrow-textarea>` and optional add-on elements such as an error message or character +counter, used to implement Material Design text fields. + +For example: + + <paper-input-container> + <label>Your name</label> + <input is="iron-input"> + </paper-input-container> + +### Listening for input changes + +By default, it listens for changes on the `bind-value` attribute on its children nodes and perform +tasks such as auto-validating and label styling when the `bind-value` changes. You can configure +the attribute it listens to with the `attr-for-value` attribute. + +### Using a custom input element + +You can use a custom input element in a `<paper-input-container>`, for example to implement a +compound input field like a social security number input. The custom input element should have the +`paper-input-input` class, have a `notify:true` value property and optionally implements +`Polymer.IronValidatableBehavior` if it is validatble. + + <paper-input-container attr-for-value="ssn-value"> + <label>Social security number</label> + <ssn-input class="paper-input-input"></ssn-input> + </paper-input-container> + +### Validation + +If the `auto-validate` attribute is set, the input container will validate the input and update +the container styling when the input value changes. + +### Add-ons + +Add-ons are child elements of a `<paper-input-container>` with the `add-on` attribute and +implements the `Polymer.PaperInputAddonBehavior` behavior. They are notified when the input value +or validity changes, and may implement functionality such as error messages or character counters. +They appear at the bottom of the input. + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-input-container-color` | Label and underline color when the input is not focused | `--secondary-text-color` +`--paper-input-container-focus-color` | Label and underline color when the input is focused | `--default-primary-color` +`--paper-input-container-invalid-color` | Label and underline color when the input is focused | `--google-red-500` +`--paper-input-container-input-color` | Input foreground color | `--primary-text-color` +`--paper-input-container` | Mixin applied to the container | `{}` +`--paper-input-container-label` | Mixin applied to the label | `{}` +`--paper-input-container-input` | Mixin applied to the input | `{}` + +This element is `display:block` by default, but you can set the `inline` attribute to make it +`display:inline-block`. +--> +</head><body><dom-module id="paper-input-container"> + + <style> + + :host { + display: block; + padding: 8px 0; + + @apply(--paper-input-container); + } + + :host[inline] { + display: inline-block; + } + + :host([disabled]) { + pointer-events: none; + opacity: 0.33; + } + + .floated-label-placeholder { + @apply(--paper-font-caption); + } + + .underline { + position: relative; + } + + .focused-line { + height: 2px; + + -webkit-transform-origin: center center; + transform-origin: center center; + -webkit-transform: scale3d(0,1,1); + transform: scale3d(0,1,1); + + background: var(--paper-input-container-focus-color, --default-primary-color); + } + + .is-highlighted .focused-line { + -webkit-transform: none; + transform: none; + -webkit-transition: -webkit-transform 0.25s; + transition: transform 0.25s; + + @apply(--paper-transition-easing); + } + + .is-invalid .focused-line { + background: var(--paper-input-container-invalid-color, --google-red-500); + + -webkit-transform: none; + transform: none; + -webkit-transition: -webkit-transform 0.25s; + transition: transform 0.25s; + + @apply(--paper-transition-easing); + } + + .unfocused-line { + height: 1px; + background: var(--paper-input-container-color, --secondary-text-color); + } + + :host([disabled]) .unfocused-line { + border-bottom: 1px dashed; + border-color: var(--paper-input-container-color, --secondary-text-color); + background: transparent; + } + + .input-content { + position: relative; + } + + .input-content ::content label, + .input-content ::content .paper-input-label { + position: absolute; + top: 0; + right: 0; + left: 0; + font: inherit; + color: var(--paper-input-container-color, --secondary-text-color); + + @apply(--paper-font-subhead); + @apply(--paper-input-container-label); + } + + .input-content.label-is-floating ::content label, + .input-content.label-is-floating ::content .paper-input-label { + -webkit-transform: translate3d(0, -75%, 0) scale(0.75); + transform: translate3d(0, -75%, 0) scale(0.75); + -webkit-transform-origin: left top; + transform-origin: left top; + -webkit-transition: -webkit-transform 0.25s; + transition: transform 0.25s; + + @apply(--paper-transition-easing); + } + + .input-content.label-is-highlighted ::content label, + .input-content.label-is-highlighted ::content .paper-input-label { + color: var(--paper-input-container-focus-color, --default-primary-color); + } + + .input-content.is-invalid ::content label, + .input-content.is-invalid ::content .paper-input-label { + color: var(--paper-input-container-invalid-color, --google-red-500); + } + + .input-content.label-is-hidden ::content label, + .input-content.label-is-hidden ::content .paper-input-label { + visibility: hidden; + } + + .input-content ::content input, + .input-content ::content textarea, + .input-content ::content iron-autogrow-textarea, + .input-content ::content .paper-input-input { + position: relative; /* to make a stacking context */ + outline: none; + box-shadow: none; + padding: 0; + width: 100%; + background: transparent; + border: none; + color: var(--paper-input-container-input-color, --primary-text-color); + + @apply(--paper-font-subhead); + @apply(--paper-input-container-input); + } + + /* Firefox sets a min-width on the input, which can cause layout issues */ + .input-content ::content input { + min-width: 0; + } + + .input-content ::content textarea { + resize: none; + } + + .add-on-content.is-invalid ::content * { + color: var(--paper-input-container-invalid-color, --google-red-500); + } + + .add-on-content.is-highlighted ::content * { + color: var(--paper-input-container-focus-color, --default-primary-color); + } + + </style> + + <template> + + <template is="dom-if" if="[[!noLabelFloat]]"> + <div class="floated-label-placeholder"> </div> + </template> + + <div class$="[[_computeInputContentClass(noLabelFloat,alwaysFloatLabel,focused,invalid,_inputHasContent)]]"> + <content select=":not([add-on])"></content> + </div> + + <div class$="[[_computeUnderlineClass(focused,invalid)]]"> + <div class="unfocused-line fit"></div> + <div class="focused-line fit"></div> + </div> + + <div class$="[[_computeAddOnContentClass(focused,invalid)]]"> + <content id="addOnContent" select="[add-on]"></content> + </div> + + </template> + +</dom-module> + +<script src="paper-input-container-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error-extracted.js new file mode 100644 index 0000000..4cea279 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error-extracted.js @@ -0,0 +1,37 @@ + + +(function() { + + Polymer({ + + is: 'paper-input-error', + + behaviors: [ + Polymer.PaperInputAddonBehavior + ], + + hostAttributes: { + 'role': 'alert' + }, + + properties: { + + /** + * True if the error is showing. + */ + invalid: { + readOnly: true, + reflectToAttribute: true, + type: Boolean + } + + }, + + update: function(state) { + this._setInvalid(state.invalid); + } + + }) + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error.html new file mode 100644 index 0000000..f32cad3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-error.html @@ -0,0 +1,60 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="paper-input-addon-behavior.html"> + +<!-- +`<paper-input-error>` is an error message for use with `<paper-input-container>`. The error is +displayed when the `<paper-input-container>` is `invalid`. + + <paper-input-container> + <input is="iron-input" pattern="[0-9]*"> + <paper-input-error>Only numbers are allowed!</paper-input-error> + </paper-input-container> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-input-container-invalid-color` | The foreground color of the error | `--google-red-500` +`--paper-input-error` | Mixin applied to the error | `{}` +--> +</head><body><dom-module id="paper-input-error"> + + <style> + + :host { + /* need to use display: none for role="alert" */ + display: none; + float: left; + + color: var(--paper-input-container-invalid-color, --google-red-500); + + @apply(--paper-font-caption); + @apply(--paper-input-error); + } + + :host([invalid]) { + display: inline-block; + }; + + </style> + + <template> + + <content></content> + + </template> + +</dom-module> + +<script src="paper-input-error-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-extracted.js new file mode 100644 index 0000000..a1d94bd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input-extracted.js @@ -0,0 +1,17 @@ + + +(function() { + + Polymer({ + + is: 'paper-input', + + behaviors: [ + Polymer.PaperInputBehavior, + Polymer.IronFormElementBehavior + ] + + }) + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-input.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input.html new file mode 100644 index 0000000..f9f900f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-input.html @@ -0,0 +1,88 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-input/iron-input.html"> +<link rel="import" href="../iron-form-element-behavior/iron-form-element-behavior.html"> +<link rel="import" href="paper-input-behavior.html"> +<link rel="import" href="paper-input-container.html"> +<link rel="import" href="paper-input-error.html"> +<link rel="import" href="paper-input-char-counter.html"> + +<!-- +`<paper-input>` is a single-line text field with Material Design styling. + + <paper-input label="Input label"></paper-input> + +It may include an optional error message or character counter. + + <paper-input error-message="Invalid input!" label="Input label"></paper-input> + <paper-input char-counter label="Input label"></paper-input> + +See `Polymer.PaperInputBehavior` for more API docs. + +### Styling + +See `Polymer.PaperInputContainer` for a list of custom properties used to +style this element. + +@group Paper Elements +@element paper-input +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-input"> + + <style> + + :host { + display: block; + } + + input::-webkit-input-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + input:-moz-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + input::-moz-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + input:-ms-input-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + </style> + + <template> + + <paper-input-container no-label-float="[[noLabelFloat]]" always-float-label="[[_computeAlwaysFloatLabel(alwaysFloatLabel,placeholder)]]" auto-validate$="[[autoValidate]]" disabled$="[[disabled]]" invalid="[[invalid]]"> + + <label hidden$="[[!label]]">[[label]]</label> + + <input is="iron-input" id="input" aria-labelledby$="[[_ariaLabelledBy]]" aria-describedby$="[[_ariaDescribedBy]]" disabled$="[[disabled]]" bind-value="{{value}}" invalid="{{invalid}}" prevent-invalid-input="[[preventInvalidInput]]" allowedpattern="[[allowedPattern]]" validator="[[validator]]" type$="[[type]]" pattern$="[[pattern]]" maxlength$="[[maxlength]]" required$="[[required]]" autocomplete$="[[autocomplete]]" autofocus$="[[autofocus]]" inputmode$="[[inputmode]]" minlength$="[[minlength]]" name$="[[name]]" placeholder$="[[placeholder]]" readonly$="[[readonly]]" size$="[[size]]"> + + <template is="dom-if" if="[[errorMessage]]"> + <paper-input-error>[[errorMessage]]</paper-input-error> + </template> + + <template is="dom-if" if="[[charCounter]]"> + <paper-input-char-counter></paper-input-char-counter> + </template> + + </paper-input-container> + + </template> + +</dom-module> + +<script src="paper-input-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-textarea-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-input/paper-textarea-extracted.js new file mode 100644 index 0000000..ca96bac --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-textarea-extracted.js @@ -0,0 +1,39 @@ + + +(function() { + + Polymer({ + + is: 'paper-textarea', + + behaviors: [ + Polymer.PaperInputBehavior, + Polymer.IronFormElementBehavior + ], + + properties: { + + _ariaLabelledBy: { + observer: '_ariaLabelledByChanged', + type: String + }, + + _ariaDescribedBy: { + observer: '_ariaDescribedByChanged', + type: String + } + + }, + + _ariaLabelledByChanged: function(ariaLabelledBy) { + this.$.input.textarea.setAttribute('aria-labelledby', ariaLabelledBy); + }, + + _ariaDescribedByChanged: function(ariaDescribedBy) { + this.$.input.textarea.setAttribute('aria-describedby', ariaDescribedBy); + } + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-input/paper-textarea.html b/third_party/polymer/v1_0/components-chromium/paper-input/paper-textarea.html new file mode 100644 index 0000000..fc50bba --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-input/paper-textarea.html @@ -0,0 +1,57 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-autogrow-textarea/iron-autogrow-textarea.html"> +<link rel="import" href="../iron-form-element-behavior/iron-form-element-behavior.html"> +<link rel="import" href="paper-input-behavior.html"> +<link rel="import" href="paper-input-container.html"> +<link rel="import" href="paper-input-error.html"> +<link rel="import" href="paper-input-char-counter.html"> + +<!-- +`<paper-textarea>` is a multi-line text field with Material Design styling. + + <paper-textarea label="Textarea label"></paper-textarea> + +See `Polymer.PaperInputBehavior` for more API docs. + +### Validation + +Currently only `required` and `maxlength` validation is supported. + +### Styling + +See `Polymer.PaperInputContainer` for a list of custom properties used to +style this element. +--> + +</head><body><dom-module id="paper-textarea"> + <template> + + <paper-input-container no-label-float$="[[noLabelFloat]]" auto-validate$="[[autoValidate]]" disabled$="[[disabled]]" invalid="[[invalid]]"> + + <label hidden$="[[!label]]">[[label]]</label> + + <iron-autogrow-textarea id="input" class="paper-input-input" bind-value="{{value}}" required$="[[required]]" maxlength$="[[maxlength]]"></iron-autogrow-textarea> + + <template is="dom-if" if="[[errorMessage]]"> + <paper-input-error>[[errorMessage]]</paper-input-error> + </template> + + <template is="dom-if" if="[[charCounter]]"> + <paper-input-char-counter></paper-input-char-counter> + </template> + + </paper-input-container> + + </template> + +</dom-module> + +<script src="paper-textarea-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-item/.bower.json new file mode 100644 index 0000000..00391bb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/.bower.json @@ -0,0 +1,49 @@ +{ + "name": "paper-item", + "version": "1.0.1", + "description": "A material-design styled list item", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "item" + ], + "main": [ + "paper-item.html", + "paper-icon-item.html", + "paper-item-body.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-item" + }, + "license": "MIT", + "homepage": "https://github.com/PolymerElements/paper-item", + "ignore": [], + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "645ebae475ab4fc28698da253ccc3aa2c48341d7" + }, + "_source": "git://github.com/PolymerElements/paper-item.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-item" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-item/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/README.md b/third_party/polymer/v1_0/components-chromium/paper-item/README.md new file mode 100644 index 0000000..02f8202 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/README.md @@ -0,0 +1,4 @@ +paper-item +========= + +A non-interactive list item. diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/all-imports.html b/third_party/polymer/v1_0/components-chromium/paper-item/all-imports.html new file mode 100644 index 0000000..4b1583f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/all-imports.html @@ -0,0 +1,13 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="paper-item.html"> +<link rel="import" href="paper-item-body.html"> +<link rel="import" href="paper-icon-item.html"> diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/bower.json b/third_party/polymer/v1_0/components-chromium/paper-item/bower.json new file mode 100644 index 0000000..f077268 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/bower.json @@ -0,0 +1,40 @@ +{ + "name": "paper-item", + "version": "1.0.1", + "description": "A material-design styled list item", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "item" + ], + "main": [ + "paper-item.html", + "paper-icon-item.html", + "paper-item-body.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-item" + }, + "license": "MIT", + "homepage": "https://github.com/PolymerElements/paper-item", + "ignore": [], + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/index.html b/third_party/polymer/v1_0/components-chromium/paper-item/index.html new file mode 100644 index 0000000..b409ed1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/index.html @@ -0,0 +1,30 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!doctype html> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-item</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="all-imports.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-icon-item-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-item/paper-icon-item-extracted.js new file mode 100644 index 0000000..75cbc7d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-icon-item-extracted.js @@ -0,0 +1,16 @@ + + +(function() { + + Polymer({ + + is: 'paper-icon-item', + + hostAttributes: { + 'role': 'listitem' + } + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-icon-item.html b/third_party/polymer/v1_0/components-chromium/paper-item/paper-icon-item.html new file mode 100644 index 0000000..4c8588b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-icon-item.html @@ -0,0 +1,68 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-icon-item>` is a convenience element to make an item with icon. It is a non interactive list +item with a fixed-width icon area, according to Material Design. This is useful if the icons are of +varying widths, but you want the item bodies to line up. Use this like a `<paper-item>`. The child +node with the attribute `item-icon` is placed in the icon area. + + <paper-icon-item> + <iron-icon icon="favorite" item-icon></iron-icon> + Favorite + </paper-icon-item> + <paper-icon-item> + <div class="avatar" item-icon></div> + Avatar + </paper-icon-item> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-item-icon-width` | Width of the icon area | `56px` +`--paper-icon-item` | Mixin applied to the item | `{}` + +--> + +</head><body><dom-module id="paper-icon-item"> + + <link rel="import" type="css" href="paper-item-shared.css"> + + <style> + + :host { + @apply(--layout-horizontal); + @apply(--layout-center); + @apply(--paper-font-subhead); + + @apply(--paper-item); + @apply(--paper-icon-item); + } + + .content-icon { + width: var(--paper-item-icon-width, 56px); + } + + </style> + + <template> + <div id="contentIcon" class="content-icon layout horizontal center"> + <content select="[item-icon]"></content> + </div> + <content></content> + </template> + +</dom-module> + +<script src="paper-icon-item-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-body-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-body-extracted.js new file mode 100644 index 0000000..a77a95b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-body-extracted.js @@ -0,0 +1,12 @@ + + +(function() { + + Polymer({ + + is: 'paper-item-body' + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-body.html b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-body.html new file mode 100644 index 0000000..bd61452 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-body.html @@ -0,0 +1,79 @@ +<!-- + @license + Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +Use `<paper-item-body>` in a `<paper-item>` or `<paper-icon-item>` to make two- or +three- line items. It is a flex item that is a vertical flexbox. + + <paper-item> + <paper-item-body two-line> + <div>Show your status</div> + <div secondary>Your status is visible to everyone</div> + </paper-item-body> + </paper-item> + +The child elements with the `secondary` attribute is given secondary text styling. + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-item-body-two-line-min-height` | Minimum height of a two-line item | `72px` +`--paper-item-body-three-line-min-height` | Minimum height of a three-line item | `88px` +`--paper-item-body-secondary-color` | Foreground color for the `secondary` area | `--secondary-text-color` +`--paper-item-body-secondary` | Mixin applied to the `secondary` area | `{}` + +--> + +</head><body><dom-module id="paper-item-body"> + + <style> + + :host { + overflow: hidden; /* needed for text-overflow: ellipsis to work on ff */ + @apply(--layout-vertical); + @apply(--layout-center-justified); + @apply(--layout-flex); + } + + :host([two-line]) { + min-height: var(--paper-item-body-two-line-min-height, 72px); + } + + :host([three-line]) { + min-height: var(--paper-item-body-three-line-min-height, 88px); + } + + :host > ::content > * { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + + :host > ::content [secondary] { + color: var(--paper-item-body-secondary-color, --secondary-text-color); + @apply(--paper-font-body1); + + @apply(--paper-item-body-secondary); + } + + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script src="paper-item-body-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-extracted.js new file mode 100644 index 0000000..d5e43ff --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-extracted.js @@ -0,0 +1,16 @@ + + +(function() { + + Polymer({ + + is: 'paper-item', + + hostAttributes: { + role: 'listitem' + } + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-shared.css b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-shared.css new file mode 100644 index 0000000..8528d1a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item-shared.css @@ -0,0 +1,19 @@ +/* + @license + Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: block; + min-height: var(--paper-item-min-height, 48px); + padding: 0px 16px; +} + +:host > ::content > *:not(:first-child):not(:last-child) { + margin-right: 16px; +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-item/paper-item.html b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item.html new file mode 100644 index 0000000..290e4f9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-item/paper-item.html @@ -0,0 +1,77 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-item>` is a non-interactive list item. By default, it is a horizontal flexbox. + + <paper-item>Item</paper-item> + +Use this element with `<paper-item-body>` to make Material Design styled two-line and three-line +items. + + <paper-item> + <paper-item-body two-line> + <div>Show your status</div> + <div secondary>Your status is visible to everyone</div> + </paper-item-body> + <iron-icon icon="warning"></iron-icon> + </paper-item> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-item-min-height` | Minimum height of the item | `48px` +`--paper-item` | Mixin applied to the item | `{}` + +### Accessibility + +This element has `role="listitem"` by default. Depending on usage, it may be more appropriate to set +`role="menuitem"`, `role="menuitemcheckbox"` or `role="menuitemradio"`. + + <paper-item role="menuitemcheckbox"> + <paper-item-body> + Show your status + </paper-item-body> + <paper-checkbox></paper-checkbox> + </paper-item> + +@group Paper Elements +@element paper-item +@demo demo/index.html +--> + +</head><body><dom-module id="paper-item"> + + <link rel="import" type="css" href="paper-item-shared.css"> + + <style> + + :host { + @apply(--layout-horizontal); + @apply(--layout-center); + @apply(--paper-font-subhead); + + @apply(--paper-item); + } + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script src="paper-item-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-material/.bower.json new file mode 100644 index 0000000..7775045 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-material", + "version": "1.0.0", + "description": "A material design container that looks like a lifted sheet of paper", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "container" + ], + "main": [ + "paper-material.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-material" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-material", + "ignore": [], + "dependencies": { + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "bd769d2b8c4f9ab000aee22582d76b5935793dc1" + }, + "_source": "git://github.com/PolymerElements/paper-material.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-material" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-material/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/README.md b/third_party/polymer/v1_0/components-chromium/paper-material/README.md new file mode 100644 index 0000000..1105102 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/README.md @@ -0,0 +1,13 @@ +# paper-material +A Material Design container that looks like a lifted piece of paper. + +`paper-material` is a container that renders two shadows on top of each other to +create the effect of a lifted piece of paper. + +Example: + +```html +<paper-material elevation="1"> + ... content ... +</paper-material> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/bower.json b/third_party/polymer/v1_0/components-chromium/paper-material/bower.json new file mode 100644 index 0000000..e6f78bc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-material", + "version": "1.0.0", + "description": "A material design container that looks like a lifted sheet of paper", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "container" + ], + "main": [ + "paper-material.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-material" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-material", + "ignore": [], + "dependencies": { + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/index.html b/third_party/polymer/v1_0/components-chromium/paper-material/index.html new file mode 100644 index 0000000..7209e6d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-material</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/paper-material-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-material/paper-material-extracted.js new file mode 100644 index 0000000..7a8f850 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/paper-material-extracted.js @@ -0,0 +1,36 @@ + + Polymer({ + is: 'paper-material', + + properties: { + + /** + * The z-depth of this element, from 0-5. Setting to 0 will remove the + * shadow, and each increasing number greater than 0 will be "deeper" + * than the last. + * + * @attribute elevation + * @type number + * @default 1 + */ + elevation: { + type: Number, + reflectToAttribute: true, + value: 1 + }, + + /** + * Set this to true to animate the shadow when setting a new + * `elevation` value. + * + * @attribute animated + * @type boolean + * @default false + */ + animated: { + type: Boolean, + reflectToAttribute: true, + value: false + } + } + }); diff --git a/third_party/polymer/v1_0/components-chromium/paper-material/paper-material.html b/third_party/polymer/v1_0/components-chromium/paper-material/paper-material.html new file mode 100644 index 0000000..634556b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-material/paper-material.html @@ -0,0 +1,60 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/shadow.html"> + +<!-- + +`paper-material` is a container that renders two shadows on top of each other to +create the effect of a lifted piece of paper. + +Example: + + <paper-material elevation="1"> + ... content ... + </paper-material> + +@group Paper Elements +@class paper-material +@demo demo/index.html +--> + +</head><body><dom-module id="paper-material"> + <style> + :host { + display: block; + position: relative; + @apply(--shadow-transition); + } + + :host([elevation="1"]) { + @apply(--shadow-elevation-2dp); + } + + :host([elevation="2"]) { + @apply(--shadow-elevation-4dp); + } + + :host([elevation="3"]) { + @apply(--shadow-elevation-6dp); + } + + :host([elevation="4"]) { + @apply(--shadow-elevation-8dp); + } + + :host([elevation="5"]) { + @apply(--shadow-elevation-16dp); + } + </style> + <template> + <content></content> + </template> +</dom-module> +<script src="paper-material-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-menu/.bower.json new file mode 100644 index 0000000..0e4dff9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "paper-menu", + "version": "1.0.0", + "description": "Implements an accessible material design menu", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "menu" + ], + "main": "paper-menu.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-menu" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-menu", + "ignore": [], + "dependencies": { + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "0642450ec9df0fc0b1d909842f436c3dea79ed1e" + }, + "_source": "git://github.com/PolymerElements/paper-menu.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-menu" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-menu/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/README.md b/third_party/polymer/v1_0/components-chromium/paper-menu/README.md new file mode 100644 index 0000000..9991680 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/README.md @@ -0,0 +1,3 @@ +# paper-menu + +`<paper-menu>` implements an accessible menu control with Material Design styling. diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/bower.json b/third_party/polymer/v1_0/components-chromium/paper-menu/bower.json new file mode 100644 index 0000000..dd2a5cd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/bower.json @@ -0,0 +1,32 @@ +{ + "name": "paper-menu", + "version": "1.0.0", + "description": "Implements an accessible material design menu", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "menu" + ], + "main": "paper-menu.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-menu" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-menu", + "ignore": [], + "dependencies": { + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-menu/hero.svg new file mode 100644 index 0000000..91af1f6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/hero.svg @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="86.5" cy="39" r="4"/> + <path d="M138,44c-2,0-3.6-2.4-4.6-4.6c-1.1-2.1-1.7-3.4-3-3.4s-2,1.3-3,3.4c-1.1,2.1-2.2,4.6-4.9,4.6c-2.6,0-3.8-2.4-4.9-4.6 + c-1.1-2.1-1.8-3.4-3.1-3.4c-1.3,0-2,1.3-3.1,3.4c-1.1,2.1-2.3,4.6-4.9,4.6c-2.6,0-4.1-2.4-5.1-4.6C100.3,37.3,100,36,98,36v-2 + c3,0,4.1,2.4,5.1,4.6c1.1,2.1,1.9,3.4,3.2,3.4c1.3,0,2.1-1.3,3.2-3.4c1.1-2.1,2.3-4.6,4.9-4.6c2.6,0,3.8,2.4,4.9,4.6 + c1.1,2.1,1.8,3.4,3.1,3.4c1.3,0,2-1.3,3.1-3.4c1.1-2.1,2.3-4.6,4.9-4.6s3.6,2.4,4.6,4.6c1.1,2.1,1.9,3.4,2.9,3.4V44z"/> + <circle cx="86.5" cy="63" r="4"/> + <path d="M138,68c-2,0-3.6-2.4-4.6-4.6c-1.1-2.1-1.7-3.4-3-3.4s-2,1.3-3,3.4c-1.1,2.1-2.2,4.6-4.9,4.6c-2.6,0-3.8-2.4-4.9-4.6 + c-1.1-2.1-1.8-3.4-3.1-3.4c-1.3,0-2,1.3-3.1,3.4c-1.1,2.1-2.3,4.6-4.9,4.6c-2.6,0-4.1-2.4-5.1-4.6C100.3,61.3,100,60,98,60v-2 + c3,0,4.1,2.4,5.1,4.6c1.1,2.1,1.9,3.4,3.2,3.4c1.3,0,2.1-1.3,3.2-3.4c1.1-2.1,2.3-4.6,4.9-4.6c2.6,0,3.8,2.4,4.9,4.6 + c1.1,2.1,1.8,3.4,3.1,3.4c1.3,0,2-1.3,3.1-3.4c1.1-2.1,2.3-4.6,4.9-4.6s3.6,2.4,4.6,4.6c1.1,2.1,1.9,3.4,2.9,3.4V68z"/> + <circle cx="86.5" cy="88" r="4"/> + <path d="M138,93c-2,0-3.6-2.4-4.6-4.6c-1.1-2.1-1.7-3.4-3-3.4s-2,1.3-3,3.4c-1.1,2.1-2.2,4.6-4.9,4.6c-2.6,0-3.8-2.4-4.9-4.6 + c-1.1-2.1-1.8-3.4-3.1-3.4c-1.3,0-2,1.3-3.1,3.4c-1.1,2.1-2.3,4.6-4.9,4.6c-2.6,0-4.1-2.4-5.1-4.6C100.3,86.3,100,85,98,85v-2 + c3,0,4.1,2.4,5.1,4.6c1.1,2.1,1.9,3.4,3.2,3.4c1.3,0,2.1-1.3,3.2-3.4c1.1-2.1,2.3-4.6,4.9-4.6c2.6,0,3.8,2.4,4.9,4.6 + c1.1,2.1,1.8,3.4,3.1,3.4c1.3,0,2-1.3,3.1-3.4c1.1-2.1,2.3-4.6,4.9-4.6s3.6,2.4,4.6,4.6c1.1,2.1,1.9,3.4,2.9,3.4V93z"/> + <path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/index.html b/third_party/polymer/v1_0/components-chromium/paper-menu/index.html new file mode 100644 index 0000000..fc88411 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-menu</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/paper-menu-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-menu/paper-menu-extracted.js new file mode 100644 index 0000000..191c2e1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/paper-menu-extracted.js @@ -0,0 +1,16 @@ + + +(function() { + + Polymer({ + + is: 'paper-menu', + + behaviors: [ + Polymer.IronMenuBehavior + ] + + }); + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-menu/paper-menu.html b/third_party/polymer/v1_0/components-chromium/paper-menu/paper-menu.html new file mode 100644 index 0000000..5233d19 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-menu/paper-menu.html @@ -0,0 +1,115 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-menu-behavior/iron-menu-behavior.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-menu>` implements an accessible menu control with Material Design styling. The focused item +is highlighted, and the selected item has bolded text. + + <paper-menu> + <paper-item>Item 1</paper-item> + <paper-item>Item 2</paper-item> + </paper-menu> + +Make a multi-select menu with the `multi` attribute. Items in a multi-select menu can be deselected, +and multiple item can be selected. + + <paper-menu multi> + <paper-item>Item 1</paper-item> + <paper-item>Item 2</paper-item> + </paper-menu> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-menu-background-color` | Menu background color | `--primary-background-color` +`-paper-menu-color` | Menu foreground color | `--primary-text-color` +`--paper-menu-disabled-color` | Foreground color for a disabled item | `--disabled-text-color` +`--paper-menu` | Mixin applied to the menu | `{}` +`--paper-menu-selected-item` | Mixin applied to the selected item | `{}` +`--paper-menu-focused-item` | Mixin applied to the focused item | `{}` +`--paper-menu-focused-item-after` | Mixin applied to the ::after pseudo-element for the focused item | `{}` + +### Accessibility + +`<paper-menu>` has `role="menu"` by default. A multi-select menu will also have +`aria-multiselectable` set. It implements key bindings to navigate through the menu with the up and +down arrow keys, esc to exit the menu, and enter to activate a menu item. Typing the first letter +of a menu item will also focus it. + +@group Paper Elements +@element paper-menu +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-menu"> + + <style> + + :host { + display: block; + padding: 8px 0; + + background: var(--paper-menu-background-color, --primary-background-color); + color: var(--paper-menu-color, --primary-text-color); + + @apply(--paper-menu); + } + + /* need a wrapper element to make this higher specificity than the :host rule in paper-item */ + .content > ::content > .iron-selected { + font-weight: bold; + + @apply(--paper-menu-selected-item); + } + + .content > ::content > [disabled] { + color: var(--paper-menu-disabled-color, --disabled-text-color); + } + + .content > ::content > *:focus { + position: relative; + outline: 0; + + @apply(--paper-menu-colored-focused-item); + } + + .content > ::content > *:focus:after { + @apply(--layout-fit); + background: currentColor; + /* FIXME move to paper-styles for next widget */ + opacity: 0.12; + content: ''; + + @apply(--paper-menu-colored-focused-item-after); + } + + .content > ::content > *[colored]:focus:after { + opacity: 0.26; + } + + </style> + + <template> + + <div class="content"> + <content></content> + </div> + + </template> + +</dom-module> + +<script src="paper-menu-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-progress/.bower.json new file mode 100644 index 0000000..100fe00 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "paper-progress", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design progress bar", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "progress" + ], + "main": [ + "paper-progress.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-progress.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-progress", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "1bef80a0d4110654b85746e70c006796ce8cdc2c" + }, + "_source": "git://github.com/PolymerElements/paper-progress.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-progress" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-progress/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/README.md b/third_party/polymer/v1_0/components-chromium/paper-progress/README.md new file mode 100644 index 0000000..7aaf060 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/README.md @@ -0,0 +1,47 @@ +paper-progress +=================== + +The progress bars are for situations where the percentage completed can be +determined. They give users a quick sense of how much longer an operation +will take. + +Example: + +```html +<paper-progress value="10"></paper-progress> +``` + +There is also a secondary progress which is useful for displaying intermediate +progress, such as the buffer level during a streaming playback progress bar. + +Example: + +```html +<paper-progress value="10" secondaryProgress="30"></paper-progress> +``` + +Styling progress bar: + +To change the active progress bar color: + +```css +paper-progress { + --paper-progress-active-color: #e91e63; +} +``` + +To change the secondary progress bar color: + +```css +paper-progress { + --paper-progress-secondary-color: #f8bbd0; +} +``` + +To change the progress bar background color: + +```css +paper-progress { + --paper-progress-container-color: #64ffda; +} +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/bower.json b/third_party/polymer/v1_0/components-chromium/paper-progress/bower.json new file mode 100644 index 0000000..8c17acb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/bower.json @@ -0,0 +1,31 @@ +{ + "name": "paper-progress", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design progress bar", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "progress" + ], + "main": [ + "paper-progress.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-progress.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-progress/hero.svg new file mode 100644 index 0000000..dc422a4 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/hero.svg @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <rect x="57" y="59" width="20" height="2"/> + <rect x="38" y="59" width="11" height="2"/> + <rect x="84" y="59" width="40" height="2"/> + <rect x="133" y="59" width="54" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/index.html b/third_party/polymer/v1_0/components-chromium/paper-progress/index.html new file mode 100644 index 0000000..225e3dd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-progress</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/paper-progress-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-progress/paper-progress-extracted.js new file mode 100644 index 0000000..93e3e9a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/paper-progress-extracted.js @@ -0,0 +1,72 @@ + + Polymer({ + + is: 'paper-progress', + + behaviors: [ + Polymer.IronRangeBehavior + ], + + properties: { + + /** + * The number that represents the current secondary progress. + */ + secondaryProgress: { + type: Number, + value: 0, + notify: true + }, + + /** + * The secondary ratio + */ + secondaryRatio: { + type: Number, + value: 0, + readOnly: true, + observer: '_secondaryRatioChanged' + }, + + /** + * Use an indeterminate progress indicator. + */ + indeterminate: { + type: Boolean, + value: false, + notify: true, + observer: '_toggleIndeterminate' + } + }, + + observers: [ + '_ratioChanged(ratio)', + '_secondaryProgressChanged(secondaryProgress, min, max)' + ], + + _toggleIndeterminate: function() { + // If we use attribute/class binding, the animation sometimes doesn't translate properly + // on Safari 7.1. So instead, we toggle the class here in the update method. + this.toggleClass('indeterminate', this.indeterminate, this.$.activeProgress); + }, + + _transformProgress: function(progress, ratio) { + var transform = 'scaleX(' + (ratio / 100) + ')'; + progress.style.transform = progress.style.webkitTransform = transform; + }, + + _ratioChanged: function(ratio) { + this._transformProgress(this.$.activeProgress, ratio); + }, + + _secondaryRatioChanged: function(secondaryRatio) { + this._transformProgress(this.$.secondaryProgress, secondaryRatio); + }, + + _secondaryProgressChanged: function() { + this.secondaryProgress = this._clampValue(this.secondaryProgress); + this._setSecondaryRatio(this._calcRatio(this.secondaryProgress) * 100); + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-progress/paper-progress.html b/third_party/polymer/v1_0/components-chromium/paper-progress/paper-progress.html new file mode 100644 index 0000000..9db7102 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-progress/paper-progress.html @@ -0,0 +1,125 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--><html><head><link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="../iron-range-behavior/iron-range-behavior.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<!-- +The progress bars are for situations where the percentage completed can be +determined. They give users a quick sense of how much longer an operation +will take. + +Example: + + <paper-progress value="10"></paper-progress> + +There is also a secondary progress which is useful for displaying intermediate +progress, such as the buffer level during a streaming playback progress bar. + +Example: + + <paper-progress value="10" secondary-progress="30"></paper-progress> + +Styling progress bar: + +To change the active progress bar color: + + paper-progress { + --paper-progress-active-color: #e91e63; + } + +To change the secondary progress bar color: + + paper-progress { + --paper-progress-secondary-color: #f8bbd0; + } + +To change the progress bar background color: + + paper-progress { + --paper-progress-container-color: #64ffda; + } + +@group Paper Elements +@element paper-progress +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-progress"> + <style> + :host { + display: inline-block; + width: 200px; + height: 4px; + } + + #progressContainer { + position: relative; + height: 100%; + background-color: var(--paper-progress-container-color, --google-grey-300); + overflow: hidden; + } + + #activeProgress, + #secondaryProgress { + -webkit-transform-origin: left center; + transform-origin: left center; + -webkit-transform: scaleX(0); + transform: scaleX(0); + } + + #activeProgress { + background-color: var(--paper-progress-active-color, --google-green-500); + } + + #secondaryProgress { + background-color: var(--paper-progress-secondary-color, --google-green-100); + } + + #activeProgress.indeterminate { + -webkit-transform-origin: center center; + transform-origin: center center; + -webkit-animation: indeterminate-bar 1s linear infinite; + animation: indeterminate-bar 1s linear infinite; + } + + @-webkit-keyframes indeterminate-bar { + 0% { + -webkit-transform: translate(-50%) scaleX(0); + } + 50% { + -webkit-transform: translate(0%) scaleX(0.3); + } + 100% { + -webkit-transform: translate(50%) scaleX(0); + } + } + + @keyframes indeterminate-bar { + 0% { + transform: translate(-50%) scaleX(0); + } + 50% { + transform: translate(0%) scaleX(0.3); + } + 100% { + transform: translate(50%) scaleX(0); + } + } + </style> + <template> + <div id="progressContainer" role="progressbar" aria-valuenow$="{{value}}" aria-valuemin$="{{min}}" aria-valuemax$="{{max}}"> + <div id="secondaryProgress" class="fit"></div> + <div id="activeProgress" class="fit"></div> + </div> + </template> +</dom-module> + +<script src="paper-progress-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-radio-button/.bower.json new file mode 100644 index 0000000..a5e2700 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-radio-button", + "version": "1.0.1", + "description": "A material design radio button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerLabs/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "922027de73c04f430d74679a167651a8c1db97e8" + }, + "_source": "git://github.com/PolymerElements/paper-radio-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-radio-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-radio-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/README.md b/third_party/polymer/v1_0/components-chromium/paper-radio-button/README.md new file mode 100644 index 0000000..f1bdf54 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/README.md @@ -0,0 +1,29 @@ +# paper-radio-button + +`paper-radio-button` is a button that can be either checked or unchecked. +User can tap the radio button to check it. But it cannot be unchecked by +tapping once checked. + +Use `paper-radio-group` to group a set of radio buttons. When radio buttons +are inside a radio group, only one radio button in the group can be checked. + +Example: + +```html +<paper-radio-button></paper-radio-button> +``` +Styling a radio button: + +```html +<style is="custom-style"> + :root { + /* Unchecked state colors. */ + --paper-radio-button-unchecked-color: #5a5a5a; + --paper-radio-button-unchecked-ink-color: #5a5a5a; + + /* Checked state colors. */ + --paper-radio-button-checked-color: #009688; + --paper-radio-button-checked-ink-color: #0f9d58; + } +</style> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/bower.json b/third_party/polymer/v1_0/components-chromium/paper-radio-button/bower.json new file mode 100644 index 0000000..51165feb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/bower.json @@ -0,0 +1,35 @@ +{ + "name": "paper-radio-button", + "version": "1.0.1", + "description": "A material design radio button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerLabs/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-radio-button/hero.svg new file mode 100644 index 0000000..7fbac94 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/hero.svg @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="112.5" cy="63" r="8"/> + <path d="M112.5,80c-9.4,0-17-7.6-17-17s7.6-17,17-17s17,7.6,17,17S121.9,80,112.5,80z M112.5,48c-8.3,0-15,6.7-15,15s6.7,15,15,15 + s15-6.7,15-15S120.8,48,112.5,48z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/index.html b/third_party/polymer/v1_0/components-chromium/paper-radio-button/index.html new file mode 100644 index 0000000..a564b41 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-radio-button</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button-extracted.js new file mode 100644 index 0000000..81b0561 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button-extracted.js @@ -0,0 +1,74 @@ + + Polymer({ + is: 'paper-radio-button', + + behaviors: [ + Polymer.PaperRadioButtonBehavior + ], + + hostAttributes: { + role: 'radio', + 'aria-checked': false, + tabindex: 0 + }, + + properties: { + /** + * Fired when the checked state changes due to user interaction. + * + * @event change + */ + + /** + * Fired when the checked state changes. + * + * @event iron-change + */ + + /** + * Gets or sets the state, `true` is checked and `false` is unchecked. + */ + checked: { + type: Boolean, + value: false, + reflectToAttribute: true, + notify: true, + observer: '_checkedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + */ + toggles: { + type: Boolean, + value: true, + reflectToAttribute: true + } + }, + + ready: function() { + if (Polymer.dom(this).textContent == '') { + this.$.radioLabel.hidden = true; + } else { + this.setAttribute('aria-label', Polymer.dom(this).textContent); + } + this._isReady = true; + }, + + _buttonStateChanged: function() { + if (this.disabled) { + return; + } + if (this._isReady) { + this.checked = this.active; + } + }, + + _checkedChanged: function() { + this.setAttribute('aria-checked', this.checked ? 'true' : 'false'); + this.active = this.checked; + this.fire('iron-change'); + } + }) +
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button.css b/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button.css new file mode 100644 index 0000000..dcb9695 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button.css @@ -0,0 +1,109 @@ +/* +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: inline-block; + white-space: nowrap; +} + +:host(:focus) { + outline: none; +} + +#radioContainer { + display: inline-block; + position: relative; + width: 16px; + height: 16px; + cursor: pointer; + vertical-align: middle; +} + +:host #ink { + position: absolute; + top: -16px; + left: -16px; + width: 48px; + height: 48px; + color: var(--paper-radio-button-unchecked-ink-color); + opacity: 0.6; +} + +:host #ink[checked] { + color: var(--paper-radio-button-checked-ink-color); +} + +:host #offRadio { + position: absolute; + top: 0px; + left: 0px; + width: 12px; + height: 12px; + border-radius: 50%; + border: solid 2px; + border-color: var(--paper-radio-button-unchecked-color); + transition: border-color 0.28s; +} + +:host #onRadio { + position: absolute; + top: 4px; + left: 4px; + width: 8px; + height: 8px; + border-radius: 50%; + background-color: var(--paper-radio-button-checked-color); + -webkit-transform: scale(0); + transform: scale(0); + transition: -webkit-transform ease 0.28s; + transition: transform ease 0.28s; +} + +:host([checked]) #offRadio { + border-color: var(--paper-radio-button-checked-color); +} + +:host([checked]) #onRadio { + -webkit-transform: scale(1); + transform: scale(1); +} + +#radioLabel { + position: relative; + display: inline-block; + vertical-align: middle; + margin-left: 10px; + white-space: normal; + pointer-events: none; + color: var(--paper-radio-button-label-color); +} + +#radioLabel[hidden] { + display: none; +} + +/* disabled state */ +:host([disabled]) { + pointer-events: none; +} + +:host([disabled]) #offRadio { + border-color: var(--paper-radio-button-unchecked-color); + opacity: 0.5; +} + +:host([disabled][checked]) #onRadio { + background-color: var(--paper-radio-button-unchecked-color); + opacity: 0.5; +} + +:host([disabled]) #radioLabel { + /* slightly darker than the button, so that it's readable */ + opacity: 0.65; +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button.html b/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button.html new file mode 100644 index 0000000..f50037f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-button/paper-radio-button.html @@ -0,0 +1,72 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> + +<!-- +`paper-radio-button` is a button that can be either checked or unchecked. +User can tap the radio button to check it. But it cannot be unchecked by +tapping once checked. + +Use `paper-radio-group` to group a set of radio buttons. When radio buttons +are inside a radio group, only one radio button in the group can be checked. + +Example: + + <paper-radio-button></paper-radio-button> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-radio-button-unchecked-color` | Radio button color when the input is not checked | `--primary-text-color` +`--paper-radio-button-unchecked-ink-color` | Selected/focus ripple color when the input is not checked | `--primary-text-color` +`--paper-radio-button-checked-color` | Radio button color when the input is checked | `--default-primary-color` +`--paper-radio-button-checked-ink-color` | Selected/focus ripple color when the input is checked | `--default-primary-color` +`--paper-radio-button-label-color` | Label color | `--primary-text-color` + +@group Paper Elements +@element paper-radio-button +@hero hero.svg +@demo demo/index.html +--> + +<style is="custom-style"> + :root { + --paper-radio-button-unchecked-color: var(--primary-text-color); + --paper-radio-button-unchecked-ink-color: var(--primary-text-color); + + --paper-radio-button-checked-color: var(--default-primary-color); + --paper-radio-button-checked-ink-color: var(--default-primary-color); + + --paper-radio-button-label-color: var(--primary-text-color); + } +</style> + +</head><body><dom-module id="paper-radio-button"> + + <link rel="import" type="css" href="paper-radio-button.css"> + + <template> + + <div id="radioContainer"> + <div id="offRadio"></div> + <div id="onRadio"></div> + <paper-ripple id="ink" class="circle" center="" checked$="[[checked]]"></paper-ripple> + </div> + + <div id="radioLabel" aria-hidden="true"><content></content></div> + + </template> + + </dom-module> +<script src="paper-radio-button-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-radio-group/.bower.json new file mode 100644 index 0000000..5c09912 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-radio-group", + "version": "1.0.1", + "description": "A group of material design radio buttons", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-group" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-group", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "b69ba0adcdc5e43773933e91009298360363b7bb" + }, + "_source": "git://github.com/PolymerElements/paper-radio-group.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-radio-group" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-radio-group/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/README.md b/third_party/polymer/v1_0/components-chromium/paper-radio-group/README.md new file mode 100644 index 0000000..0b02d58 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/README.md @@ -0,0 +1,20 @@ +paper-radio-group +================= + +`paper-radio-group` allows user to select only one radio button from a set. +Checking one radio button that belongs to a radio group unchecks any +previously checked radio button within the same group. Use +`selected` to get or set the selected radio button. + +Example: + +```html +<paper-radio-group selected="small"> + <paper-radio-button name="small" label="Small"></paper-radio-button> + <paper-radio-button name="medium" label="Medium"></paper-radio-button> + <paper-radio-button name="large" label="Large"></paper-radio-button> +</paper-radio-group> +``` + +See <a href="paper-radio-button.html">paper-radio-button</a> for more +information about `paper-radio-button`. diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/bower.json b/third_party/polymer/v1_0/components-chromium/paper-radio-group/bower.json new file mode 100644 index 0000000..10e8b51 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-radio-group", + "version": "1.0.1", + "description": "A group of material design radio buttons", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-group" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-group", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-radio-group/hero.svg new file mode 100644 index 0000000..fc78ba7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/hero.svg @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="112.5" cy="41" r="8"/> + <path d="M112.5,58c-9.4,0-17-7.6-17-17s7.6-17,17-17s17,7.6,17,17S121.9,58,112.5,58z M112.5,26c-8.3,0-15,6.7-15,15s6.7,15,15,15 + s15-6.7,15-15S120.8,26,112.5,26z"/> + <circle cx="112.5" cy="85" r="8"/> + <path d="M112.5,102c-9.4,0-17-7.6-17-17s7.6-17,17-17s17,7.6,17,17S121.9,102,112.5,102z M112.5,70c-8.3,0-15,6.7-15,15 + s6.7,15,15,15s15-6.7,15-15S120.8,70,112.5,70z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/index.html b/third_party/polymer/v1_0/components-chromium/paper-radio-group/index.html new file mode 100644 index 0000000..966c717 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-radio-group</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/paper-radio-group-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-radio-group/paper-radio-group-extracted.js new file mode 100644 index 0000000..6de17dc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/paper-radio-group-extracted.js @@ -0,0 +1,127 @@ + + Polymer({ + is: 'paper-radio-group', + + behaviors: [ + Polymer.IronA11yKeysBehavior + ], + + hostAttributes: { + role: 'radiogroup', + tabindex: 0 + }, + + properties: { + /** + * Fired when the selected element changes to user interaction. + * + * @event paper-radio-group-changed + */ + + /** + * Gets or sets the selected element. Use the `name` attribute of the + * <paper-radio-button> that should be selected. + * + * @attribute selected + * @type String + * @default null + */ + + selected: { + type: String, + value: null, + notify: true, + reflectToAttribute: true, + observer: "_selectedChanged" + } + }, + + keyBindings: { + 'left up': '_selectPrevious', + 'right down': '_selectNext', + }, + + _selectedChanged: function() { + // TODO: This only needs to be async while a domReady event is unavailable. + this.async(function() { + this._selectIndex(this._valueToIndex(this.items, this.selected)); + this.fire('paper-radio-group-changed'); + }); + }, + + _selectNext: function() { + this.selected = this._nextNode(); + }, + + _selectPrevious: function() { + this.selected = this._previousNode(); + }, + + /** + * Returns an array of all items. + * + * @property items + * @type array + */ + get items() { + return Polymer.dom(this.$.items).getDistributedNodes(); + }, + + _nextNode: function() { + var items = this.items; + var index = this._selectedIndex; + var newIndex = index; + do { + newIndex = (newIndex + 1) % items.length; + if (newIndex === index) { + break; + } + } while (items[newIndex].disabled); + return this._valueForNode(items[newIndex]); + }, + + _previousNode: function() { + var items = this.items; + var index = this._selectedIndex; + var newIndex = index; + do { + newIndex = (newIndex || items.length) - 1; + if (newIndex === index) { + break; + } + } while (items[newIndex].disabled); + return this._valueForNode(items[newIndex]); + }, + + _selectIndex: function(index) { + if (index == this._selectedIndex) + return; + + var nodes = this.items; + + // If there was a previously selected node, deselect it. + if (nodes[this._selectedIndex]) { + nodes[this._selectedIndex].checked = false; + } + + // Select a new node. + nodes[index].checked = true; + nodes[index].focus(); + this._selectedIndex = index; + }, + + _valueForNode: function(node) { + return node["name"] || node.getAttribute("name"); + }, + + // Finds an item with value == |value| and return its index. + _valueToIndex: function(items, value) { + for (var index = 0, node; (node = items[index]); index++) { + if (this._valueForNode(node) == value) { + return index; + } + } + // If no item found, the value itself is probably the index. + return value; + } + }); diff --git a/third_party/polymer/v1_0/components-chromium/paper-radio-group/paper-radio-group.html b/third_party/polymer/v1_0/components-chromium/paper-radio-group/paper-radio-group.html new file mode 100644 index 0000000..ff66597 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-radio-group/paper-radio-group.html @@ -0,0 +1,56 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-selector/iron-selector.html"> +<link rel="import" href="../paper-radio-button/paper-radio-button.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + +<!-- +`paper-radio-group` allows user to select only one radio button from a set. +Checking one radio button that belongs to a radio group unchecks any +previously checked radio button within the same group. Use +`selected` to get or set the selected radio button. + +Example: + + <paper-radio-group selected="small"> + <paper-radio-button name="small" label="Small"></paper-radio-button> + <paper-radio-button name="medium" label="Medium"></paper-radio-button> + <paper-radio-button name="large" label="Large"></paper-radio-button> + </paper-radio-group> + +See <a href="paper-radio-button.html">paper-radio-button</a> for more +information about `paper-radio-button`. + +@group Paper Elements +@element paper-radio-group +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module name="paper-radio-group"> + <style> + :host { + display: inline-block; + } + + iron-selector ::content > * { + padding: 12px; + } + </style> + + <template> + <iron-selector selected="{{selected}}" attr-for-selected="name" selectable="paper-radio-button"> + <content id="items" select="*"></content> + </iron-selector> + </template> + +</dom-module> + +<script src="paper-radio-group-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-ripple/.bower.json new file mode 100644 index 0000000..1b45160 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/.bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-ripple", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Adds a material design ripple to any container", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "ripple" + ], + "main": "paper-ripple.html", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-ripple", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "bcf189cf43bd935dec7a09868988f33a7bdd25fe" + }, + "_source": "git://github.com/PolymerElements/paper-ripple.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-ripple" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-ripple/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/README.md b/third_party/polymer/v1_0/components-chromium/paper-ripple/README.md new file mode 100644 index 0000000..b9bde23 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/README.md @@ -0,0 +1,65 @@ +paper-ripple +============ + +`paper-ripple` provides a visual effect that other paper elements can +use to simulate a rippling effect emanating from the point of contact. The +effect can be visualized as a concentric circle with motion. + +Example: + +```html +<paper-ripple></paper-ripple> +``` + +`paper-ripple` listens to "mousedown" and "mouseup" events so it would display ripple +effect when touches on it. You can also defeat the default behavior and +manually route the down and up actions to the ripple element. Note that it is +important if you call downAction() you will have to make sure to call +upAction() so that `paper-ripple` would end the animation loop. + +Example: + +```html +<paper-ripple id="ripple" style="pointer-events: none;"></paper-ripple> +... +<script> + downAction: function(e) { + this.$.ripple.downAction({x: e.x, y: e.y}); + }, + upAction: function(e) { + this.$.ripple.upAction(); + } +</script> +``` + +Styling ripple effect: + +Use CSS color property to style the ripple: + +```css +paper-ripple { + color: #4285f4; +} +``` + +Note that CSS color property is inherited so it is not required to set it on +the `paper-ripple` element directly. + + +By default, the ripple is centered on the point of contact. Apply the ``recenters`` attribute to have the ripple grow toward the center of its container. + +```html +<paper-ripple recenters></paper-ripple> +``` + +Apply `center` to center the ripple inside its container from the start. + +```html +<paper-ripple center></paper-ripple> +``` + +Apply `circle` class to make the rippling effect within a circle. + +```html +<paper-ripple class="circle"></paper-ripple> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/bower.json b/third_party/polymer/v1_0/components-chromium/paper-ripple/bower.json new file mode 100644 index 0000000..55b8678 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/bower.json @@ -0,0 +1,29 @@ +{ + "name": "paper-ripple", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Adds a material design ripple to any container", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "ripple" + ], + "main": "paper-ripple.html", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-ripple/hero.svg new file mode 100644 index 0000000..f8a872f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/hero.svg @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M175,81H49V45h126V81z M51,79h122V47H51V79z"/> + <g> + <defs> + <rect id="SVGID_5_" x="50" y="46" width="124" height="34"/> + </defs> + <clipPath id="SVGID_2_"> + <use xlink:href="#SVGID_5_" overflow="visible"/> + </clipPath> + <circle opacity="0.5" clip-path="url(#SVGID_2_)" cx="84.4" cy="62.7" r="41.9"/> + <circle opacity="0.6" clip-path="url(#SVGID_2_)" cx="84.4" cy="62.7" r="26.3"/> + <circle opacity="0.6" clip-path="url(#SVGID_2_)" cx="66.4" cy="62.7" r="26.3"/> + </g> + <circle cx="50" cy="80" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/index.html b/third_party/polymer/v1_0/components-chromium/paper-ripple/index.html new file mode 100644 index 0000000..3c371fa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>paper-ripple</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/paper-ripple-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-ripple/paper-ripple-extracted.js new file mode 100644 index 0000000..0e7e265 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/paper-ripple-extracted.js @@ -0,0 +1,564 @@ + + (function() { + var Utility = { + cssColorWithAlpha: function(cssColor, alpha) { + var parts = cssColor.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/); + + if (typeof alpha == 'undefined') { + alpha = 1; + } + + if (!parts) { + return 'rgba(255, 255, 255, ' + alpha + ')'; + } + + return 'rgba(' + parts[1] + ', ' + parts[2] + ', ' + parts[3] + ', ' + alpha + ')'; + }, + + distance: function(x1, y1, x2, y2) { + var xDelta = (x1 - x2); + var yDelta = (y1 - y2); + + return Math.sqrt(xDelta * xDelta + yDelta * yDelta); + }, + + now: (function() { + if (window.performance && window.performance.now) { + return window.performance.now.bind(window.performance); + } + + return Date.now; + })() + }; + + /** + * @param {HTMLElement} element + * @constructor + */ + function ElementMetrics(element) { + this.element = element; + this.width = this.boundingRect.width; + this.height = this.boundingRect.height; + + this.size = Math.max(this.width, this.height); + } + + ElementMetrics.prototype = { + get boundingRect () { + return this.element.getBoundingClientRect(); + }, + + furthestCornerDistanceFrom: function(x, y) { + var topLeft = Utility.distance(x, y, 0, 0); + var topRight = Utility.distance(x, y, this.width, 0); + var bottomLeft = Utility.distance(x, y, 0, this.height); + var bottomRight = Utility.distance(x, y, this.width, this.height); + + return Math.max(topLeft, topRight, bottomLeft, bottomRight); + } + }; + + /** + * @param {HTMLElement} element + * @constructor + */ + function Ripple(element) { + this.element = element; + this.color = window.getComputedStyle(element).color; + + this.wave = document.createElement('div'); + this.waveContainer = document.createElement('div'); + this.wave.style.backgroundColor = this.color; + this.wave.classList.add('wave'); + this.waveContainer.classList.add('wave-container'); + Polymer.dom(this.waveContainer).appendChild(this.wave); + + this.resetInteractionState(); + } + + Ripple.MAX_RADIUS = 300; + + Ripple.prototype = { + get recenters() { + return this.element.recenters; + }, + + get center() { + return this.element.center; + }, + + get mouseDownElapsed() { + var elapsed; + + if (!this.mouseDownStart) { + return 0; + } + + elapsed = Utility.now() - this.mouseDownStart; + + if (this.mouseUpStart) { + elapsed -= this.mouseUpElapsed; + } + + return elapsed; + }, + + get mouseUpElapsed() { + return this.mouseUpStart ? + Utility.now () - this.mouseUpStart : 0; + }, + + get mouseDownElapsedSeconds() { + return this.mouseDownElapsed / 1000; + }, + + get mouseUpElapsedSeconds() { + return this.mouseUpElapsed / 1000; + }, + + get mouseInteractionSeconds() { + return this.mouseDownElapsedSeconds + this.mouseUpElapsedSeconds; + }, + + get initialOpacity() { + return this.element.initialOpacity; + }, + + get opacityDecayVelocity() { + return this.element.opacityDecayVelocity; + }, + + get radius() { + var width2 = this.containerMetrics.width * this.containerMetrics.width; + var height2 = this.containerMetrics.height * this.containerMetrics.height; + var waveRadius = Math.min( + Math.sqrt(width2 + height2), + Ripple.MAX_RADIUS + ) * 1.1 + 5; + + var duration = 1.1 - 0.2 * (waveRadius / Ripple.MAX_RADIUS); + var timeNow = this.mouseInteractionSeconds / duration; + var size = waveRadius * (1 - Math.pow(80, -timeNow)); + + return Math.abs(size); + }, + + get opacity() { + if (!this.mouseUpStart) { + return this.initialOpacity; + } + + return Math.max( + 0, + this.initialOpacity - this.mouseUpElapsedSeconds * this.opacityDecayVelocity + ); + }, + + get outerOpacity() { + // Linear increase in background opacity, capped at the opacity + // of the wavefront (waveOpacity). + var outerOpacity = this.mouseUpElapsedSeconds * 0.3; + var waveOpacity = this.opacity; + + return Math.max( + 0, + Math.min(outerOpacity, waveOpacity) + ); + }, + + get isOpacityFullyDecayed() { + return this.opacity < 0.01 && + this.radius >= Math.min(this.maxRadius, Ripple.MAX_RADIUS); + }, + + get isRestingAtMaxRadius() { + return this.opacity >= this.initialOpacity && + this.radius >= Math.min(this.maxRadius, Ripple.MAX_RADIUS); + }, + + get isAnimationComplete() { + return this.mouseUpStart ? + this.isOpacityFullyDecayed : this.isRestingAtMaxRadius; + }, + + get translationFraction() { + return Math.min( + 1, + this.radius / this.containerMetrics.size * 2 / Math.sqrt(2) + ); + }, + + get xNow() { + if (this.xEnd) { + return this.xStart + this.translationFraction * (this.xEnd - this.xStart); + } + + return this.xStart; + }, + + get yNow() { + if (this.yEnd) { + return this.yStart + this.translationFraction * (this.yEnd - this.yStart); + } + + return this.yStart; + }, + + get isMouseDown() { + return this.mouseDownStart && !this.mouseUpStart; + }, + + resetInteractionState: function() { + this.maxRadius = 0; + this.mouseDownStart = 0; + this.mouseUpStart = 0; + + this.xStart = 0; + this.yStart = 0; + this.xEnd = 0; + this.yEnd = 0; + this.slideDistance = 0; + + this.containerMetrics = new ElementMetrics(this.element); + }, + + draw: function() { + var scale; + var translateString; + var dx; + var dy; + + this.wave.style.opacity = this.opacity; + + scale = this.radius / (this.containerMetrics.size / 2); + dx = this.xNow - (this.containerMetrics.width / 2); + dy = this.yNow - (this.containerMetrics.height / 2); + + + // 2d transform for safari because of border-radius and overflow:hidden clipping bug. + // https://bugs.webkit.org/show_bug.cgi?id=98538 + this.waveContainer.style.webkitTransform = 'translate(' + dx + 'px, ' + dy + 'px)'; + this.waveContainer.style.transform = 'translate3d(' + dx + 'px, ' + dy + 'px, 0)'; + this.wave.style.webkitTransform = 'scale(' + scale + ',' + scale + ')'; + this.wave.style.transform = 'scale3d(' + scale + ',' + scale + ',1)'; + }, + + downAction: function(event) { + var xCenter = this.containerMetrics.width / 2; + var yCenter = this.containerMetrics.height / 2; + + this.resetInteractionState(); + this.mouseDownStart = Utility.now(); + + if (this.center) { + this.xStart = xCenter; + this.yStart = yCenter; + this.slideDistance = Utility.distance( + this.xStart, this.yStart, this.xEnd, this.yEnd + ); + } else { + this.xStart = event ? + event.detail.x - this.containerMetrics.boundingRect.left : + this.containerMetrics.width / 2; + this.yStart = event ? + event.detail.y - this.containerMetrics.boundingRect.top : + this.containerMetrics.height / 2; + } + + if (this.recenters) { + this.xEnd = xCenter; + this.yEnd = yCenter; + this.slideDistance = Utility.distance( + this.xStart, this.yStart, this.xEnd, this.yEnd + ); + } + + this.maxRadius = this.containerMetrics.furthestCornerDistanceFrom( + this.xStart, + this.yStart + ); + + this.waveContainer.style.top = + (this.containerMetrics.height - this.containerMetrics.size) / 2 + 'px'; + this.waveContainer.style.left = + (this.containerMetrics.width - this.containerMetrics.size) / 2 + 'px'; + + this.waveContainer.style.width = this.containerMetrics.size + 'px'; + this.waveContainer.style.height = this.containerMetrics.size + 'px'; + }, + + upAction: function(event) { + if (!this.isMouseDown) { + return; + } + + this.mouseUpStart = Utility.now(); + }, + + remove: function() { + Polymer.dom(this.waveContainer.parentNode).removeChild( + this.waveContainer + ); + } + }; + + Polymer({ + is: 'paper-ripple', + + behaviors: [ + Polymer.IronA11yKeysBehavior + ], + + properties: { + /** + * The initial opacity set on the wave. + * + * @attribute initialOpacity + * @type number + * @default 0.25 + */ + initialOpacity: { + type: Number, + value: 0.25 + }, + + /** + * How fast (opacity per second) the wave fades out. + * + * @attribute opacityDecayVelocity + * @type number + * @default 0.8 + */ + opacityDecayVelocity: { + type: Number, + value: 0.8 + }, + + /** + * If true, ripples will exhibit a gravitational pull towards + * the center of their container as they fade away. + * + * @attribute recenters + * @type boolean + * @default false + */ + recenters: { + type: Boolean, + value: false + }, + + /** + * If true, ripples will center inside its container + * + * @attribute recenters + * @type boolean + * @default false + */ + center: { + type: Boolean, + value: false + }, + + /** + * A list of the visual ripples. + * + * @attribute ripples + * @type Array + * @default [] + */ + ripples: { + type: Array, + value: function() { + return []; + } + }, + + /** + * True when there are visible ripples animating within the + * element. + */ + animating: { + type: Boolean, + readOnly: true, + reflectToAttribute: true, + value: false + }, + + /** + * If true, the ripple will remain in the "down" state until `holdDown` + * is set to false again. + */ + holdDown: { + type: Boolean, + value: false, + observer: '_holdDownChanged' + }, + + _animating: { + type: Boolean + }, + + _boundAnimate: { + type: Function, + value: function() { + return this.animate.bind(this); + } + } + }, + + get target () { + var ownerRoot = Polymer.dom(this).getOwnerRoot(); + var target; + + if (ownerRoot) { + target = ownerRoot.host; + } + + if (!target) { + target = this.parentNode; + } + + return target; + }, + + keyBindings: { + 'enter:keydown': '_onEnterKeydown', + 'space:keydown': '_onSpaceKeydown', + 'space:keyup': '_onSpaceKeyup' + }, + + attached: function() { + this._listen(this.target, 'up', this.upAction.bind(this)); + this._listen(this.target, 'down', this.downAction.bind(this)); + + if (!this.target.hasAttribute('noink')) { + this.keyEventTarget = this.target; + } + }, + + get shouldKeepAnimating () { + for (var index = 0; index < this.ripples.length; ++index) { + if (!this.ripples[index].isAnimationComplete) { + return true; + } + } + + return false; + }, + + simulatedRipple: function() { + this.downAction(null); + + // Please see polymer/polymer#1305 + this.async(function() { + this.upAction(); + }, 1); + }, + + downAction: function(event) { + if (this.holdDown && this.ripples.length > 0) { + return; + } + + var ripple = this.addRipple(); + + ripple.downAction(event); + + if (!this._animating) { + this.animate(); + } + }, + + upAction: function(event) { + if (this.holdDown) { + return; + } + + this.ripples.forEach(function(ripple) { + ripple.upAction(event); + }); + + this.animate(); + }, + + onAnimationComplete: function() { + this._animating = false; + this.$.background.style.backgroundColor = null; + this.fire('transitionend'); + }, + + addRipple: function() { + var ripple = new Ripple(this); + + Polymer.dom(this.$.waves).appendChild(ripple.waveContainer); + this.$.background.style.backgroundColor = ripple.color; + this.ripples.push(ripple); + + this._setAnimating(true); + + return ripple; + }, + + removeRipple: function(ripple) { + var rippleIndex = this.ripples.indexOf(ripple); + + if (rippleIndex < 0) { + return; + } + + this.ripples.splice(rippleIndex, 1); + + ripple.remove(); + + if (!this.ripples.length) { + this._setAnimating(false); + } + }, + + animate: function() { + var index; + var ripple; + + this._animating = true; + + for (index = 0; index < this.ripples.length; ++index) { + ripple = this.ripples[index]; + + ripple.draw(); + + this.$.background.style.opacity = ripple.outerOpacity; + + if (ripple.isOpacityFullyDecayed && !ripple.isRestingAtMaxRadius) { + this.removeRipple(ripple); + } + } + + if (!this.shouldKeepAnimating && this.ripples.length === 0) { + this.onAnimationComplete(); + } else { + window.requestAnimationFrame(this._boundAnimate); + } + }, + + _onEnterKeydown: function() { + this.downAction(); + this.async(this.upAction, 1); + }, + + _onSpaceKeydown: function() { + this.downAction(); + }, + + _onSpaceKeyup: function() { + this.upAction(); + }, + + _holdDownChanged: function(holdDown) { + if (holdDown) { + this.downAction(); + } else { + this.upAction(); + } + } + }); + })(); diff --git a/third_party/polymer/v1_0/components-chromium/paper-ripple/paper-ripple.html b/third_party/polymer/v1_0/components-chromium/paper-ripple/paper-ripple.html new file mode 100644 index 0000000..37a4400 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-ripple/paper-ripple.html @@ -0,0 +1,148 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + +<!-- +`paper-ripple` provides a visual effect that other paper elements can +use to simulate a rippling effect emanating from the point of contact. The +effect can be visualized as a concentric circle with motion. + +Example: + + <paper-ripple></paper-ripple> + +`paper-ripple` listens to "mousedown" and "mouseup" events so it would display ripple +effect when touches on it. You can also defeat the default behavior and +manually route the down and up actions to the ripple element. Note that it is +important if you call downAction() you will have to make sure to call +upAction() so that `paper-ripple` would end the animation loop. + +Example: + + <paper-ripple id="ripple" style="pointer-events: none;"></paper-ripple> + ... + downAction: function(e) { + this.$.ripple.downAction({x: e.x, y: e.y}); + }, + upAction: function(e) { + this.$.ripple.upAction(); + } + +Styling ripple effect: + + Use CSS color property to style the ripple: + + paper-ripple { + color: #4285f4; + } + + Note that CSS color property is inherited so it is not required to set it on + the `paper-ripple` element directly. + +By default, the ripple is centered on the point of contact. Apply the `recenters` +attribute to have the ripple grow toward the center of its container. + + <paper-ripple recenters></paper-ripple> + +You can also center the ripple inside its container from the start. + + <paper-ripple center></paper-ripple> + +Apply `circle` class to make the rippling effect within a circle. + + <paper-ripple class="circle"></paper-ripple> + +@group Paper Elements +@element paper-ripple +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-ripple"> + + <!-- + Fired when the animation finishes. This is useful if you want to wait until the ripple + animation finishes to perform some action. + + @event transitionend + @param {Object} detail + @param {Object} detail.node The animated node + --> + + <style> + :host { + display: block; + position: absolute; + border-radius: inherit; + overflow: hidden; + top: 0; + left: 0; + right: 0; + bottom: 0; + } + + :host([animating]) { + /* This resolves a rendering issue in Chrome (as of 40) where the + ripple is not properly clipped by its parent (which may have + rounded corners). See: http://jsbin.com/temexa/4 + + Note: We only apply this style conditionally. Otherwise, the browser + will create a new compositing layer for every ripple element on the + page, and that would be bad. */ + -webkit-transform: translate(0, 0); + transform: translate3d(0, 0, 0); + } + + :host([noink]) { + pointer-events: none; + } + + #background, + #waves, + .wave-container, + .wave { + pointer-events: none; + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + } + + #background, + .wave { + opacity: 0; + } + + #waves, + .wave { + overflow: hidden; + } + + .wave-container, + .wave { + border-radius: 50%; + } + + :host(.circle) #background, + :host(.circle) #waves { + border-radius: 50%; + } + + :host(.circle) .wave-container { + overflow: hidden; + } + + </style> + <template> + <div id="background"></div> + <div id="waves"></div> + </template> +</dom-module> +<script src="paper-ripple-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/.bower.json new file mode 100644 index 0000000..18b4ee3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-scroll-header-panel", + "description": "A header bar with scrolling behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "layout", + "responsive" + ], + "main": [ + "paper-scroll-header-panel.html" + ], + "repository": { + "type": "git", + "url": "git@github.com:PolymerElements/paper-scroll-header-panel.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-scroll-header-panel", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "2b8db7a3cb8bfc7c8811438dd8cdfbdfda65d4d3" + }, + "_source": "git://github.com/PolymerElements/paper-scroll-header-panel.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-scroll-header-panel" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/README.md b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/README.md new file mode 100644 index 0000000..ac1be0c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/README.md @@ -0,0 +1,56 @@ +paper-scroll-header-panel +======================== + +`paper-scroll-header-panel` contains a header section and a content section. The header is initially on the top part of the view but it scrolls away with the rest of the scrollable content. Upon scrolling slightly up at any point, the header scrolls back into view. This saves screen space and allows users to access important controls by easily moving them back to the view. + +Important: The `paper-scroll-header-panel` will not display if its parent does not have a height. Using layout classes, you can easily make the `paper-scroll-header-panel` fill the screen + +```html +<body class="fullbleed layout vertical"> + <paper-scroll-header-panel class="flex"> + <paper-toolbar> + Hello World! + </paper-toolbar> + </paper-scroll-header-panel> +</body> +``` +or, if you would prefer to do it in CSS, just give html, body, and `paper-scroll-header-panel` a height of 100%: +```css +html, body { + height: 100%; + margin: 0; +} +paper-scroll-header-panel { + height: 100%; +} +``` +`paper-scroll-header-panel` works well with `paper-toolbar` but can use any element that represents a header by adding a core-header class to it. + +```html +<paper-scroll-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> +</paper-scroll-header-panel> +``` + +### Styling scroll-header-panel: + +To change background for toolbar when it is at its full size: + +```css +paper-scroll-header-panel { + --paper-scroll-header-panel-full-header: { + background-color: red; + }; +} +``` + +To change the background for toolbar when it is condensed: + +```css +paper-scroll-header-panel { + --paper-scroll-header-panel-condensed-header: { + background-color: #f4b400; + }; +} +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/bower.json b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/bower.json new file mode 100644 index 0000000..86ac91c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/bower.json @@ -0,0 +1,38 @@ +{ + "name": "paper-scroll-header-panel", + "description": "A header bar with scrolling behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "layout", + "responsive" + ], + "main": [ + "paper-scroll-header-panel.html" + ], + "repository": { + "type": "git", + "url": "git@github.com:PolymerElements/paper-scroll-header-panel.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/hero.svg new file mode 100644 index 0000000..c130c84 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/hero.svg @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="170.6" cy="28.5" r="4"/> + <circle cx="170.6" cy="58.5" r="4"/> + <rect x="170" y="29" width="2" height="30"/> + <path d="M163,102H73V24h90V102z M75,100h86V26H75V100z"/> + <rect x="74" y="62" width="88" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> + <g> + <polygon points="74,59.6 74,62.5 74.5,63 77.4,63 "/> + <polygon points="74,51.9 74,54.7 82.3,63 85.1,63 "/> + <polygon points="74,44.1 74,46.9 90.1,63 92.9,63 "/> + <polygon points="74,36.3 74,39.2 97.8,63 100.7,63 "/> + <polygon points="74,28.6 74,31.4 105.6,63 108.4,63 "/> + <polygon points="78.2,25 75.4,25 113.4,63 116.2,63 "/> + <polygon points="86,25 83.1,25 121.1,63 124,63 "/> + <polygon points="93.7,25 90.9,25 128.9,63 131.7,63 "/> + <polygon points="101.5,25 98.7,25 136.7,63 139.5,63 "/> + <polygon points="109.2,25 106.4,25 144.4,63 147.2,63 "/> + <polygon points="117,25 114.2,25 152.2,63 155,63 "/> + <polygon points="124.8,25 122,25 160,63 162,63 162,62.2 "/> + <polygon points="132.5,25 129.7,25 162,57.3 162,54.5 "/> + <polygon points="140.3,25 137.5,25 162,49.5 162,46.7 "/> + <polygon points="148.1,25 145.2,25 162,41.8 162,38.9 "/> + <polygon points="155.8,25 153,25 162,34 162,31.2 "/> + <polygon points="162,26.2 162,25 160.8,25 "/> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/index.html b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/index.html new file mode 100644 index 0000000..e2e7712 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-scroll-header-panel</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/paper-scroll-header-panel-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/paper-scroll-header-panel-extracted.js new file mode 100644 index 0000000..f7aa1f8 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/paper-scroll-header-panel-extracted.js @@ -0,0 +1,302 @@ + +(function() { + + 'use strict'; + + Polymer({ + + /** + * Fired when the content has been scrolled. + * + * @event content-scroll + */ + + /** + * Fired when the header is transformed. + * + * @event paper-header-transform + */ + + is: 'paper-scroll-header-panel', + + behaviors: [ + Polymer.IronResizableBehavior + ], + + properties: { + + /** + * If true, the header's height will condense to `_condensedHeaderHeight` + * as the user scrolls down from the top of the content area. + */ + condenses: { + type: Boolean, + value: false, + observer: '_condensesChanged' + }, + + /** + * If true, no cross-fade transition from one background to another. + */ + noDissolve: { + type: Boolean, + value: false + }, + + /** + * If true, the header doesn't slide back in when scrolling back up. + */ + noReveal: { + type: Boolean, + value: false + }, + + /** + * If true, the header is fixed to the top and never moves away. + */ + fixed: { + type: Boolean, + value: false + }, + + /** + * If true, the condensed header is always shown and does not move away. + */ + keepCondensedHeader: { + type: Boolean, + value: false + }, + + /** + * The height of the header when it is at its full size. + * + * By default, the height will be measured when it is ready. If the height + * changes later the user needs to either set this value to reflect the + * new height or invoke `measureHeaderHeight()`. + */ + headerHeight: { + type: Number, + value: 0 + }, + + /** + * The height of the header when it is condensed. + * + * By default, `_condensedHeaderHeight` is 1/3 of `headerHeight` unless + * this is specified. + */ + condensedHeaderHeight: { + type: Number, + value: 0 + }, + + /** + * By default, the top part of the header stays when the header is being + * condensed. Set this to true if you want the top part of the header + * to be scrolled away. + */ + scrollAwayTopbar: { + type: Boolean, + value: false + }, + + _headerMargin: { + type: Number + }, + + _prevScrollTop: { + type: Number + }, + + _y: { + type: Number + } + + }, + + observers: [ + '_setup(_headerMargin, headerHeight, fixed)', + '_headerHeightChanged(headerHeight, condensedHeaderHeight)', + '_condensedHeaderHeightChanged(headerHeight, condensedHeaderHeight)' + ], + + listeners: { + 'iron-resize': 'measureHeaderHeight' + }, + + ready: function() { + this.async(this.measureHeaderHeight, 5); + this._scrollHandler = this._scroll.bind(this); + this.scroller.addEventListener('scroll', this._scrollHandler); + }, + + detached: function() { + this.scroller.removeEventListener('scroll', this._scrollHandler); + }, + + /** + * Returns the header element. + * + * @property header + * @type Object + */ + get header() { + return Polymer.dom(this.$.headerContent).getDistributedNodes()[0]; + }, + + /** + * Returns the content element. + * + * @property content + * @type Object + */ + get content() { + return Polymer.dom(this.$.mainContent).getDistributedNodes()[0]; + }, + + /** + * Returns the scrollable element. + * + * @property scroller + * @type Object + */ + get scroller() { + return this.$.mainContainer; + }, + + /** + * Invoke this to tell `paper-scroll-header-panel` to re-measure the header's + * height. + * + * @method measureHeaderHeight + */ + measureHeaderHeight: function() { + var header = this.header; + if (header && header.offsetHeight) { + this.headerHeight = header.offsetHeight; + } + }, + + _headerHeightChanged: function() { + if (!this.condensedHeaderHeight) { + // assume condensedHeaderHeight is 1/3 of the headerHeight + this.condensedHeaderHeight = this.headerHeight * 1 / 3; + } + }, + + _condensedHeaderHeightChanged: function() { + if (this.headerHeight) { + this._headerMargin = this.headerHeight - this.condensedHeaderHeight; + } + }, + + _condensesChanged: function() { + if (this.condenses) { + this._scroll(); + } else { + // reset transform/opacity set on the header + this._condenseHeader(null); + } + }, + + _setup: function() { + var s = this.scroller.style; + s.paddingTop = this.fixed ? '' : this.headerHeight + 'px'; + + s.top = this.fixed ? this.headerHeight + 'px' : ''; + + if (this.fixed) { + this._transformHeader(null); + } else { + this._scroll(); + } + }, + + _transformHeader: function(y) { + var s = this.$.headerContainer.style; + this._translateY(s, -y); + + if (this.condenses) { + this._condenseHeader(y); + } + + this.fire('paper-header-transform', {y: y, height: this.headerHeight, + condensedHeight: this.condensedHeaderHeight}); + }, + + _condenseHeader: function(y) { + var reset = (y === null); + + // adjust top bar in core-header so the top bar stays at the top + if (!this.scrollAwayTopbar && this.header.$ && this.header.$.topBar) { + this._translateY(this.header.$.topBar.style, + reset ? null : Math.min(y, this._headerMargin)); + } + // transition header bg + var hbg = this.$.headerBg.style; + if (!this.noDissolve) { + hbg.opacity = reset ? '' : (this._headerMargin - y) / this._headerMargin; + } + // adjust header bg so it stays at the center + this._translateY(hbg, reset ? null : y / 2); + // transition condensed header bg + if (!this.noDissolve) { + var chbg = this.$.condensedHeaderBg.style; + chbg = this.$.condensedHeaderBg.style; + chbg.opacity = reset ? '' : y / this._headerMargin; + + // adjust condensed header bg so it stays at the center + this._translateY(chbg, reset ? null : y / 2); + } + }, + + _translateY: function(s, y) { + var t = (y === null) ? '' : 'translate3d(0, ' + y + 'px, 0)'; + setTransform(s, t); + }, + + _scroll: function(event) { + if (!this.header) { + return; + } + + var sTop = this.scroller.scrollTop; + + this._y = this._y || 0; + this._prevScrollTop = this._prevScrollTop || 0; + + var y = Math.min(this.keepCondensedHeader ? + this._headerMargin : this.headerHeight, Math.max(0, + (this.noReveal ? sTop : this._y + sTop - this._prevScrollTop))); + + if (this.condenses && this._prevScrollTop >= sTop && sTop > this._headerMargin) { + y = Math.max(y, this._headerMargin); + } + + if (!event || !this.fixed && y !== this._y) { + this._transformHeader(y); + } + + this._prevScrollTop = Math.max(sTop, 0); + this._y = y; + + if (event) { + this.fire('content-scroll', {target: this.scroller}, this, false); + } + } + + }); + + //determine proper transform mechanizm + if (document.documentElement.style.transform !== undefined) { + var setTransform = function(style, string) { + style.transform = string; + } + } else { + var setTransform = function(style, string) { + style.webkitTransform = string; + } + } + +})(); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/paper-scroll-header-panel.html b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/paper-scroll-header-panel.html new file mode 100644 index 0000000..eb18b0d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-scroll-header-panel/paper-scroll-header-panel.html @@ -0,0 +1,150 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> + +<!-- +`paper-scroll-header-panel` contains a header section and a content section. The +header is initially on the top part of the view but it scrolls away with the +rest of the scrollable content. Upon scrolling slightly up at any point, the +header scrolls back into view. This saves screen space and allows users to +access important controls by easily moving them back to the view. + +__Important:__ The `paper-scroll-header-panel` will not display if its parent does not have a height. + +Using [layout attributes](http://www.polymer-project.org/docs/polymer/layout-attrs.html), you can easily make the `paper-scroll-header-panel` fill the screen + + <body class="fullbleed layout vertical"> + <paper-scroll-header-panel class="flex"> + <paper-toolbar> + <div>Hello World!</div> + </paper-toolbar> + </paper-scroll-header-panel> + </body> + +or, if you would prefer to do it in CSS, just give `html`, `body`, and `paper-scroll-header-panel` a height of 100%: + + html, body { + height: 100%; + margin: 0; + } + paper-scroll-header-panel { + height: 100%; + } + +`paper-scroll-header-panel` works well with `paper-toolbar` but can use any element +that represents a header by adding a `core-header` class to it. + + <paper-scroll-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> + </paper-scroll-header-panel> + +Styling scroll-header-panel: + + To change background for toolbar when it is at its full size: + + paper-scroll-header-panel { + --paper-scroll-header-panel-full-header: { + background-color: red; + }; + } + + To change the background for toolbar when it is condensed: + + paper-scroll-header-panel { + --paper-scroll-header-panel-condensed-header: { + background-color: #f4b400; + }; + } + +@group Paper Element +@element paper-scrollheader-panel +@demo demo/index.html +@hero hero.svg +--> + +</head><body><dom-module id="paper-scroll-header-panel"> + + <style> + :host { + display: block; + position: relative; + overflow: hidden; + } + + #mainContainer { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + box-sizing: border-box; + -moz-box-sizing: border-box; + -webkit-overflow-scrolling: touch; + overflow-x: hidden; + overflow-_y: auto; + -webkit-transform: translateZ(0); + transform: translateZ(0); + } + + #headerContainer { + position: absolute; + top: 0; + right: 0; + left: 0; + } + + .bg-container { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + overflow: hidden; + } + + #headerBg { + @apply(--paper-scroll-header-panel-full-header); + } + + #condensedHeaderBg { + @apply(--paper-scroll-header-panel-condensed-header); + } + + #headerBg, #condensedHeaderBg { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background-repeat: no-repeat; + background-size: cover; + background-position: center center; + } + + #condensedHeaderBg { + opacity: 0; + } + </style> + <template> + <div id="mainContainer"> + <content id="mainContent" select=":not(paper-toolbar):not(.paper-header)"></content> + </div> + <div id="headerContainer"> + <div class="bg-container"> + <div id="condensedHeaderBg"></div> + <div id="headerBg"></div> + </div> + <content id="headerContent" select="paper-toolbar, .paper-header"></content> + </div> + </template> +</dom-module> + +<script src="paper-scroll-header-panel-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-slider/.bower.json new file mode 100644 index 0000000..9b0a642 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-slider", + "version": "1.0.1", + "description": "A material design-style slider", + "license": "http://polymer.github.io/LICENSE.txt", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "slider", + "control" + ], + "main": [ + "paper-slider.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-slider.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-slider", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "995905314b4aeffab020bdd53b0f68cc7b448a1d" + }, + "_source": "git://github.com/PolymerElements/paper-slider.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-slider" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-slider/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/README.md b/third_party/polymer/v1_0/components-chromium/paper-slider/README.md new file mode 100644 index 0000000..fd00cd2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/README.md @@ -0,0 +1,69 @@ +paper-slider +============ + +`paper-slider` allows user to select a value from a range of values by +moving the slider thumb. The interactive nature of the slider makes it a +great choice for settings that reflect intensity levels, such as volume, +brightness, or color saturation. + +Example: + +```html +<paper-slider></paper-slider> +``` + +Use `min` and `max` to specify the slider range. Default is `0` to `100`. For example: +```html +<paper-slider min="10" max="200" value="110"></paper-slider> +``` + +### Styling slider + +To change the slider progress bar color: +```css +paper-slider { + --paper-slider-active-color: #0f9d58; +} +``` + +To change the slider knob color: +```css +paper-slider { + --paper-slider-knob-color: #0f9d58; +} +``` + +To change the slider pin color: +```css +paper-slider { + --paper-slider-pin-color: #0f9d58; +} +``` + +To change the slider pin's font color: +```css +paper-slider { + --paper-slider-pin-font-color: #0f9d58; +} +``` + +To change the slider secondary progress bar color: +```css +paper-slider { + --paper-slider-secondary-color: #0f9d58; +} +``` + +To change the slider disabled active color: +```css +paper-slider { + --paper-slider-disabled-active-color: #ccc; +} +``` + +To change the slider disabled secondary progress bar color: +```css +paper-slider { + --paper-slider-disabled-secondary-color: #ccc; +} +```
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/bower.json b/third_party/polymer/v1_0/components-chromium/paper-slider/bower.json new file mode 100644 index 0000000..c40c262 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/bower.json @@ -0,0 +1,34 @@ +{ + "name": "paper-slider", + "version": "1.0.1", + "description": "A material design-style slider", + "license": "http://polymer.github.io/LICENSE.txt", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "slider", + "control" + ], + "main": [ + "paper-slider.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-slider.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-slider/hero.svg new file mode 100644 index 0000000..8a518e1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/hero.svg @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="110" cy="61" r="4"/> + <rect x="61" y="60" width="49" height="2"/> + <rect x="110" y="60" width="53" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/index.html b/third_party/polymer/v1_0/components-chromium/paper-slider/index.html new file mode 100644 index 0000000..6add074 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-slider</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> + diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider-extracted.js new file mode 100644 index 0000000..f69a9d7 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider-extracted.js @@ -0,0 +1,330 @@ + + /** + * Fired when the slider's value changes. + * + * @event value-change + */ + + /** + * Fired when the slider's immediateValue changes. + * + * @event immediate-value-change + */ + + /** + * Fired when the slider's value changes due to user interaction. + * + * Changes to the slider's value due to changes in an underlying + * bound variable will not trigger this event. + * + * @event change + */ + + Polymer({ + is: 'paper-slider', + + behaviors: [ + Polymer.IronRangeBehavior, + Polymer.IronControlState + ], + + properties: { + + /** + * If true, the slider thumb snaps to tick marks evenly spaced based + * on the `step` property value. + */ + snaps: { + type: Boolean, + value: false, + notify: true + }, + + /** + * If true, a pin with numeric value label is shown when the slider thumb + * is pressed. Use for settings for which users need to know the exact + * value of the setting. + */ + pin: { + type: Boolean, + value: false, + notify: true + }, + + /** + * The number that represents the current secondary progress. + */ + secondaryProgress: { + type: Number, + value: 0, + notify: true, + observer: '_secondaryProgressChanged' + }, + + /** + * If true, an input is shown and user can use it to set the slider value. + */ + editable: { + type: Boolean, + value: false + }, + + /** + * The immediate value of the slider. This value is updated while the user + * is dragging the slider. + */ + immediateValue: { + type: Number, + value: 0, + readOnly: true + }, + + /** + * The maximum number of markers + */ + maxMarkers: { + type: Number, + value: 0, + notify: true, + observer: '_maxMarkersChanged' + }, + + /** + * If true, the knob is expanded + */ + expand: { + type: Boolean, + value: false, + readOnly: true + }, + + /** + * True when the user is dragging the slider. + */ + dragging: { + type: Boolean, + value: false, + readOnly: true + }, + + transiting: { + type: Boolean, + value: false, + readOnly: true + }, + + markers: { + readOnly: true, + value: [] + }, + }, + + observers: [ + '_updateKnob(value, min, max, snaps, step)', + '_minChanged(min)', + '_maxChanged(max)', + '_valueChanged(value)', + '_immediateValueChanged(immediateValue)' + ], + + ready: function() { + // issue polymer/polymer#1305 + this.async(function() { + this._updateKnob(this.value); + this._updateInputValue(); + }, 1); + }, + + /** + * Increases value by `step` but not above `max`. + * @method increment + */ + increment: function() { + this.value = this._clampValue(this.value + this.step); + }, + + /** + * Decreases value by `step` but not below `min`. + * @method decrement + */ + decrement: function() { + this.value = this._clampValue(this.value - this.step); + }, + + _updateKnob: function(value) { + this._positionKnob(this._calcRatio(value)); + }, + + _minChanged: function() { + this.setAttribute('aria-valuemin', this.min); + }, + + _maxChanged: function() { + this.setAttribute('aria-valuemax', this.max); + }, + + _valueChanged: function() { + this.setAttribute('aria-valuenow', this.value); + this.fire('value-change'); + }, + + _immediateValueChanged: function() { + if (!this.dragging) { + this.value = this.immediateValue; + } + this._updateInputValue(); + this.fire('immediate-value-change'); + }, + + _secondaryProgressChanged: function() { + this.secondaryProgress = this._clampValue(this.secondaryProgress); + }, + + _updateInputValue: function() { + if (this.editable) { + this.$$('#input').value = this.immediateValue; + } + }, + + _expandKnob: function() { + this._setExpand(true); + }, + + _resetKnob: function() { + this._expandJob && this._expandJob.stop(); + this._setExpand(false); + }, + + _positionKnob: function(ratio) { + this._setImmediateValue(this._calcStep(this._calcKnobPosition(ratio)) || 0); + this._setRatio(this.snaps ? this._calcRatio(this.immediateValue) : ratio); + this.$.sliderKnob.style.left = this.ratio * 100 + '%'; + }, + + _inputChange: function() { + this.value = this.$$('#input').value; + this.fire('change'); + }, + + _calcKnobPosition: function(ratio) { + return (this.max - this.min) * ratio + this.min; + }, + + _onTrack: function(e) { + switch (event.detail.state) { + case 'end': + this._trackEnd(event); + break; + case 'track': + this._trackX(event); + break; + case 'start': + this._trackStart(event); + break; + } + }, + + _trackStart: function(e) { + this._w = this.$.sliderBar.offsetWidth; + this._x = this.ratio * this._w; + this._startx = this._x || 0; + this._minx = - this._startx; + this._maxx = this._w - this._startx; + this.$.sliderKnob.classList.add('dragging'); + this._setDragging(true); + e.preventDefault(); + }, + + _trackX: function(e) { + if (!this.dragging) { + this._trackStart(e); + } + var x = Math.min(this._maxx, Math.max(this._minx, e.detail.dx)); + this._x = this._startx + x; + this._setImmediateValue(this._calcStep( + this._calcKnobPosition(this._x / this._w)) || 0); + var s = this.$.sliderKnob.style; + s.transform = s.webkitTransform = 'translate3d(' + (this.snaps ? + (this._calcRatio(this.immediateValue) * this._w) - this._startx : x) + 'px, 0, 0)'; + }, + + _trackEnd: function() { + var s = this.$.sliderKnob.style; + s.transform = s.webkitTransform = ''; + this.$.sliderKnob.classList.remove('dragging'); + this._setDragging(false); + this._resetKnob(); + this.value = this.immediateValue; + this.fire('change'); + }, + + _knobdown: function(e) { + e.preventDefault(); + this._expandKnob(); + }, + + _bardown: function(e) { + e.preventDefault(); + this._setTransiting(true); + this._w = this.$.sliderBar.offsetWidth; + var rect = this.$.sliderBar.getBoundingClientRect(); + var ratio = (e.detail.x - rect.left) / this._w; + this._positionKnob(ratio); + this._expandJob = this.debounce(this._expandJob, this._expandKnob, 60); + + this.async(function() { + this.fire('change'); + }); + }, + + _knobTransitionEnd: function(e) { + if (e.target === this.$.sliderKnob) { + this._setTransiting(false); + } + }, + + _maxMarkersChanged: function(maxMarkers) { + var l = (this.max - this.min) / this.step; + if (!this.snaps && l > maxMarkers) { + this._setMarkers([]); + } else { + this._setMarkers(new Array(l)); + } + }, + + _getClassNames: function() { + var classes = {}; + + classes['disabled'] = this.disabled; + classes['pin'] = this.pin; + classes['snaps'] = this.snaps; + classes['ring'] = this.immediateValue <= this.min; + classes['expand'] = this.expand; + classes['dragging'] = this.dragging; + classes['transiting'] = this.transiting; + classes['editable'] = this.editable; + + return Object.keys(classes).filter( + function(className) { + return classes[className]; + }).join(' '); + }, + + _incrementKey: function(ev, keys) { + if (keys.key === 'end') { + this.value = this.max; + } else { + this.increment(); + } + this.fire('change'); + }, + + _decrementKey: function(ev, keys) { + if (keys.key === 'home') { + this.value = this.min; + } else { + this.decrement(); + } + this.fire('change'); + } + }) diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider.css b/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider.css new file mode 100644 index 0000000..0e0f784 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider.css @@ -0,0 +1,252 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +*/ + +:host { + display: inline-block; + width: 200px; + cursor: default; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} + +:host(:not([disabled])) #sliderBar::shadow #activeProgress { + background-color: var(--paper-slider-active-color, --google-blue-700); +} + +:host(:not([disabled])) #sliderBar::shadow #secondaryProgress { + background-color: var(--paper-slider-secondary-color, --google-blue-300); +} + +:host([disabled]) #sliderBar::shadow #activeProgress { + background-color: var(--paper-slider-disabled-active-color, --google-grey-500); +} + +:host([disabled]) #sliderBar::shadow #secondaryProgress { + background-color: var(--paper-slider-disabled-secondary-color, --google-grey-300); +} + +:host(:focus) { + outline: none; +} + +#sliderContainer { + position: relative; + width: calc(100% - 32px); + height: 32px; +} + +#sliderContainer.editable { + float: left; + width: calc(100% - 72px); + margin: 12px 0; +} + +.bar-container { + position: absolute; + top: 0; + left: 16px; + height: 100%; + width: 100%; + overflow: hidden; +} + +.ring > .bar-container { + left: 20px; + width: calc(100% - 4px); + transition: left 0.18s ease, width 0.18s ease; +} + +.ring.expand:not(.pin) > .bar-container { + left: 30px; + width: calc(100% - 14px); +} + +.ring.expand.dragging > .bar-container { + transition: none; +} + +#sliderBar { + position: absolute; + top: 15px; + left: 0; + height: 2px; + width: 100%; + padding: 8px 0; + margin: -8px 0; +} + +.ring #sliderBar { + left: -4px; + width: calc(100% + 4px); +} + +.ring.expand:not(.pin) #sliderBar { + left: -14px; + width: calc(100% + 14px); +} + +.slider-markers { + position: absolute; + top: 15px; + left: 15px; + height: 2px; + width: calc(100% + 2px); + box-sizing: border-box; + pointer-events: none; +} + +.slider-markers::after, +.slider-marker::after { + content: ""; + display: block; + width: 2px; + height: 2px; + border-radius: 50%; + background-color: black; +} + +.transiting #sliderBar::shadow #activeProgress { + transition: -webkit-transform 0.08s ease; + transition: transform 0.08s ease; +} + +#sliderKnob { + @apply(--layout-center-justified); + @apply(--layout-center); + @apply(--layout-horizontal); + + position: absolute; + left: 0; + top: 0; + width: 32px; + height: 32px; +} + +.transiting > #sliderKnob { + transition: left 0.08s ease; +} + +#sliderKnob:focus { + outline: none; +} + +#sliderKnob.dragging { + transition: none; +} + +.snaps > #sliderKnob.dragging { + transition: -webkit-transform 0.08s ease; + transition: transform 0.08s ease; +} + +#sliderKnobInner { + width: 12px; + height: 12px; + box-sizing: border-box; + -moz-box-sizing: border-box; + border-radius: 50%; + background-color: var(--paper-slider-knob-color, --google-blue-700); + transition-property: height, width, background-color, border; + transition-duration: 0.1s; + transition-timing-function: ease; +} + +.expand:not(.pin) > #sliderKnob > #sliderKnobInner { + width: 100%; + height: 100%; + -webkit-transform: translateZ(0); + transform: translateZ(0); +} + +.ring > #sliderKnob > #sliderKnobInner { + background-color: transparent; + border: 2px solid #c8c8c8; +} + +#sliderKnobInner::before { + background-color: var(--paper-slider-pin-color, --google-blue-700); +} + +.pin > #sliderKnob > #sliderKnobInner::before { + content: ""; + position: absolute; + top: 0; + left: 0; + width: 26px; + height: 26px; + margin-left: 3px; + border-radius: 50% 50% 50% 0; + -webkit-transform: rotate(-45deg) scale(0) translate(0); + transform: rotate(-45deg) scale(0) translate(0); +} + +#sliderKnobInner::before, +#sliderKnobInner::after { + transition: -webkit-transform .2s ease, background-color .18s ease; + transition: transform .2s ease, background-color .18s ease; +} + +.pin.ring > #sliderKnob > #sliderKnobInner::before { + background-color: #c8c8c8; +} + +.pin.expand > #sliderKnob > #sliderKnobInner::before { + -webkit-transform: rotate(-45deg) scale(1) translate(17px, -17px); + transform: rotate(-45deg) scale(1) translate(17px, -17px); +} + +.pin > #sliderKnob > #sliderKnobInner::after { + content: attr(value); + position: absolute; + top: 0; + left: 0; + width: 32px; + height: 26px; + text-align: center; + color: var(--paper-slider-font-color, #fff); + font-size: 10px; + -webkit-transform: scale(0) translate(0); + transform: scale(0) translate(0); +} + +.pin.expand > #sliderKnob > #sliderKnobInner::after { + -webkit-transform: scale(1) translate(0, -17px); + transform: scale(1) translate(0, -17px); +} + +/* editable: paper-input */ +.slider-input { + width: 40px; + float: right; + overflow: hidden; +} + +.slider-input::shadow input { + /* FIXME(ffu): should one be able set text-align directly on paper-input? */ + text-align: center; +} + +/* disabled state */ +#sliderContainer.disabled { + pointer-events: none; +} + +.disabled > #sliderKnob > #sliderKnobInner { + width: 8px; + height: 8px; + background-color: var(--paper-slider-disabled-knob-color, --google-grey-500); +} + +.disabled.ring > #sliderKnob > #sliderKnobInner { + background-color: transparent; +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider.html b/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider.html new file mode 100644 index 0000000..d5a02f9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-slider/paper-slider.html @@ -0,0 +1,113 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--><html><head><link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-behaviors/iron-control-state.html"> +<link rel="import" href="../paper-progress/paper-progress.html"> +<link rel="import" href="../paper-input/paper-input.html"> + +<!-- +`paper-slider` allows user to select a value from a range of values by +moving the slider thumb. The interactive nature of the slider makes it a +great choice for settings that reflect intensity levels, such as volume, +brightness, or color saturation. + +Example: + + <paper-slider></paper-slider> + +Use `min` and `max` to specify the slider range. Default is 0 to 100. + +Example: + + <paper-slider min="10" max="200" value="110"></paper-slider> + +Styling slider: + +To change the slider progress bar color: + + paper-slider { + --paper-slider-active-color: #0f9d58; + } + +To change the slider knob color: + + paper-slider { + --paper-slider-knob-color: #0f9d58; + } + +To change the slider pin color: + + paper-slider { + --paper-slider-pin-color: #0f9d58; + } + +To change the slider pin's font color: + + paper-slider { + --paper-slider-pin-font-color: #0f9d58; + } + +To change the slider secondary progress bar color: + + paper-slider { + --paper-slider-secondary-color: #0f9d58; + } + +To change the slider disabled active color: + + paper-slider { + --paper-slider-disabled-active-color: #ccc; + } + +To change the slider disabled secondary progress bar color: + + paper-slider { + --paper-slider-disabled-secondary-color: #ccc; + } + +@group Paper Elements +@element paper-slider +@demo demo/index.html +@hero hero.svg +--> + +</head><body><dom-module id="paper-slider"> + <link rel="import" type="css" href="paper-slider.css"> + <template> + <template is="dom-if" if="{{!disabled}}"> + </template> + + <div id="sliderContainer" class$="[[_getClassNames(disabled, pin, snaps, immediateValue, min, expand, dragging, transiting, editable)]]"> + <div class="bar-container"> + <paper-progress id="sliderBar" aria-hidden="true" min="[[min]]" max="[[max]]" value="[[immediateValue]]" secondary-progress="[[secondaryProgress]]" on-down="_bardown" on-up="_resetKnob" on-track="_onTrack"></paper-progress> + </div> + + <template is="dom-if" if="[[snaps]]"> + <div class="slider-markers horizontal layout"> + <template is="dom-repeat" items="[[markers]]"> + <div class="slider-marker flex"></div> + </template> + </div> + </template> + + <div id="sliderKnob" on-down="_knobdown" on-up="_resetKnob" on-track="_onTrack" on-transitionend="_knobTransitionEnd" center-justified="" center="" horizontal="" layout=""> + + <div id="sliderKnobInner" value$="[[immediateValue]]"></div> + </div> + </div> + + <template is="dom-if" if="[[editable]]"> + <paper-input id="input" class="slider-input" disabled$="[[disabled]]" on-change="_inputChange"></paper-input> + </template> + + </template> +</dom-module> + +<script src="paper-slider-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-spinner/.bower.json new file mode 100644 index 0000000..1787b05 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/.bower.json @@ -0,0 +1,42 @@ +{ + "name": "paper-spinner", + "version": "1.0.1", + "description": "A material design spinner", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "spinner", + "loading" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-spinner" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-spinner", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "5e2b7412922259c9eed1805d69abb18e433efaad" + }, + "_source": "git://github.com/PolymerElements/paper-spinner.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-spinner" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-spinner/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/README.md b/third_party/polymer/v1_0/components-chromium/paper-spinner/README.md new file mode 100644 index 0000000..c447c8b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/README.md @@ -0,0 +1,45 @@ +paper-spinner +============= + +Element providing material design circular spinner. + +##### Example + +```html +<paper-spinner active></paper-spinner> +``` + +The default spinner cycles between four layers of colors; by default they are +blue, red, yellow and green. It can be customized so that it uses one color only +by setting all the layer colors to the same value. + +##### Example + +```html +<style is="custom-style"> + paper-spinner .rainbow { + --paper-spinner-layer-1-color: yellow; + --paper-spinner-layer-2-color: red; + --paper-spinner-layer-3-color: blue; + --paper-spinner-layer-4-color: green; + } + + paper-spinner .red { + --paper-spinner-layer-1-color: red; + --paper-spinner-layer-2-color: red; + --paper-spinner-layer-3-color: red; + --paper-spinner-layer-4-color: red; + } +</style> +``` + +Alt attribute should be set to provide adequate context for accessibility. If not provided, +it defaults to 'loading'. +Empty alt can be provided to mark the element as decorative if alternative content is provided +in another form (e.g. a text block following the spinner). + +##### Example + +```html +<paper-spinner alt="Loading contacts list" active></paper-spinner> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/bower.json b/third_party/polymer/v1_0/components-chromium/paper-spinner/bower.json new file mode 100644 index 0000000..d27e049 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/bower.json @@ -0,0 +1,33 @@ +{ + "name": "paper-spinner", + "version": "1.0.1", + "description": "A material design spinner", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "spinner", + "loading" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-spinner" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-spinner", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-spinner/hero.svg new file mode 100644 index 0000000..034b1f1 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/hero.svg @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <path d="M112.1,92.3c-13.4,0-25.1-9.1-28.4-22l1.9-0.5c3.1,12.1,13.9,20.5,26.4,20.5c15,0,27.3-12.2,27.3-27.3 + s-12.2-27.3-27.3-27.3c-8.1,0-15.8,3.6-21,9.8l-1.5-1.3c5.6-6.7,13.8-10.6,22.5-10.6c16.1,0,29.3,13.1,29.3,29.3 + S128.2,92.3,112.1,92.3z"/> + <path d="M112.7,87.3c-6.6,0-12.7-2.5-17.3-7.2c-4.6-4.6-7.2-10.8-7.2-17.3c0-6.6,2.5-12.7,7.2-17.3c7.9-7.9,20.2-9.5,29.8-3.8 + l-1,1.7c-8.8-5.3-20.1-3.8-27.4,3.5c-4.2,4.2-6.6,9.9-6.6,15.9s2.3,11.7,6.6,15.9s9.9,6.6,15.9,6.6c6,0,11.7-2.3,15.9-6.6 + c4.7-4.7,7.1-11.3,6.5-18l2-0.2c0.7,7.3-1.9,14.4-7.1,19.6C125.4,84.7,119.2,87.3,112.7,87.3z"/> + <path d="M112.5,43.5C101.8,43.5,93,52.3,93,63s8.7,19.5,19.5,19.5S132,73.7,132,63S123.2,43.5,112.5,43.5z M119,64h-6v6h-2v-6h-6 + v-2h6v-6h2v6h6V64z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/index.html b/third_party/polymer/v1_0/components-chromium/paper-spinner/index.html new file mode 100644 index 0000000..9874334 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-spinner</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner-extracted.js new file mode 100644 index 0000000..4122215 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner-extracted.js @@ -0,0 +1,121 @@ + + + (function() { + + 'use strict'; + + function classNames(obj) { + var classNames = []; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key]) { + classNames.push(key); + } + } + + return classNames.join(' '); + } + + Polymer({ + + is: 'paper-spinner', + + listeners: { + 'animationend': 'reset', + 'webkitAnimationEnd': 'reset' + }, + + properties: { + + /** + * Displays the spinner. + * + * @attribute active + * @type boolean + * @default false + */ + active: { + observer: '_activeChanged', + type: Boolean, + value: false + }, + + /** + * Alternative text content for accessibility support. + * If alt is present, it will add an aria-label whose content matches alt when active. + * If alt is not present, it will default to 'loading' as the alt value. + * + * @attribute alt + * @type string + * @default 'loading' + */ + alt: { + observer: '_altChanged', + type: String, + value: 'loading' + }, + + /** + * True when the spinner is going from active to inactive. This is represented by a fade + * to 0% opacity to the user. + */ + _coolingDown: { + type: Boolean, + value: false + }, + + _spinnerContainerClassName: { + type: String, + computed: '_computeSpinnerContainerClassName(active, _coolingDown)' + } + + }, + + _computeSpinnerContainerClassName: function(active, _coolingDown) { + return classNames({ + active: active || _coolingDown, + cooldown: _coolingDown + }); + }, + + ready: function() { + // Allow user-provided `aria-label` take preference to any other text alternative. + if (this.hasAttribute('aria-label')) { + this.alt = this.getAttribute('aria-label'); + } else { + this.setAttribute('aria-label', this.alt); + } + + if (!this.active) { + this.setAttribute('aria-hidden', 'true'); + } + }, + + _activeChanged: function() { + if (this.active) { + this.removeAttribute('aria-hidden'); + } else { + this._coolingDown = true; + this.setAttribute('aria-hidden', 'true'); + } + }, + + _altChanged: function() { + if (this.alt === '') { + this.setAttribute('aria-hidden', 'true'); + } else { + this.removeAttribute('aria-hidden'); + } + + this.setAttribute('aria-label', this.alt); + }, + + reset: function() { + this.active = false; + this._coolingDown = false; + } + + }); + + }()); + +
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner.css b/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner.css new file mode 100644 index 0000000..30c4e7e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner.css @@ -0,0 +1,325 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + +*/ +/**************************/ +/* STYLES FOR THE SPINNER */ +/**************************/ + +/* + * Constants: + * STROKEWIDTH = 3px + * ARCSIZE = 270 degrees (amount of circle the arc takes up) + * ARCTIME = 1333ms (time it takes to expand and contract arc) + * ARCSTARTROT = 216 degrees (how much the start location of the arc + * should rotate each time, 216 gives us a + * 5 pointed star shape (it's 360/5 * 3). + * For a 7 pointed star, we might do + * 360/7 * 3 = 154.286) + * CONTAINERWIDTH = 28px + * SHRINK_TIME = 400ms + */ + + :host { + display: inline-block; + position: relative; + width: 28px; /* CONTAINERWIDTH */ + height: 28px; /* CONTAINERWIDTH */ +} + +#spinnerContainer { + width: 100%; + height: 100%; +} + +#spinnerContainer.active { + /* duration: 360 * ARCTIME / (ARCSTARTROT + (360-ARCSIZE)) */ + -webkit-animation: container-rotate 1568ms linear infinite; + animation: container-rotate 1568ms linear infinite; +} + +@-webkit-keyframes container-rotate { + to { -webkit-transform: rotate(360deg) } +} + +@keyframes container-rotate { + to { transform: rotate(360deg) } +} + +.spinner-layer { + position: absolute; + width: 100%; + height: 100%; + opacity: 0; +} + +.layer-1 { + border-color: var(--paper-spinner-layer-1-color, --google-blue-500); +} + +.layer-2 { + border-color: var(--paper-spinner-layer-2-color, --google-red-500); +} + +.layer-3 { + border-color: var(--paper-spinner-layer-3-color, --google-yellow-500); +} + +.layer-4 { + border-color: var(--paper-spinner-layer-4-color, --google-blue-500); +} + +/** + * IMPORTANT NOTE ABOUT CSS ANIMATION PROPERTIES (keanulee): + * + * iOS Safari (tested on iOS 8.1) does not handle animation-delay very well - it doesn't + * guarantee that the animation will start _exactly_ after that value. So we avoid using + * animation-delay and instead set custom keyframes for each color (as layer-2undant as it + * seems). + * + * We write out each animation in full (instead of separating animation-name, + * animation-duration, etc.) because under the polyfill, Safari does not recognize those + * specific properties properly, treats them as -webkit-animation, and overrides the + * other animation rules. See https://github.com/Polymer/platform/issues/53. + */ +.active .spinner-layer.layer-1 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-1-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-1-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .spinner-layer.layer-2 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-2-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-2-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .spinner-layer.layer-3 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-3-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-3-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .spinner-layer.layer-4 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-4-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-4-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +@-webkit-keyframes fill-unfill-rotate { + 12.5% { -webkit-transform: rotate(135deg); } /* 0.5 * ARCSIZE */ + 25% { -webkit-transform: rotate(270deg); } /* 1 * ARCSIZE */ + 37.5% { -webkit-transform: rotate(405deg); } /* 1.5 * ARCSIZE */ + 50% { -webkit-transform: rotate(540deg); } /* 2 * ARCSIZE */ + 62.5% { -webkit-transform: rotate(675deg); } /* 2.5 * ARCSIZE */ + 75% { -webkit-transform: rotate(810deg); } /* 3 * ARCSIZE */ + 87.5% { -webkit-transform: rotate(945deg); } /* 3.5 * ARCSIZE */ + to { -webkit-transform: rotate(1080deg); } /* 4 * ARCSIZE */ +} + +@keyframes fill-unfill-rotate { + 12.5% { transform: rotate(135deg); } /* 0.5 * ARCSIZE */ + 25% { transform: rotate(270deg); } /* 1 * ARCSIZE */ + 37.5% { transform: rotate(405deg); } /* 1.5 * ARCSIZE */ + 50% { transform: rotate(540deg); } /* 2 * ARCSIZE */ + 62.5% { transform: rotate(675deg); } /* 2.5 * ARCSIZE */ + 75% { transform: rotate(810deg); } /* 3 * ARCSIZE */ + 87.5% { transform: rotate(945deg); } /* 3.5 * ARCSIZE */ + to { transform: rotate(1080deg); } /* 4 * ARCSIZE */ +} + +/** + * HACK: Even though the intention is to have the current .spinner-layer at + * `opacity: 1`, we set it to `opacity: 0.99` instead since this forces Chrome + * to do proper subpixel rendering for the elements being animated. This is + * especially visible in Chrome 39 on Ubuntu 14.04. See: + * + * - https://github.com/Polymer/paper-spinner/issues/9 + * - https://code.google.com/p/chromium/issues/detail?id=436255 + */ +@-webkit-keyframes layer-1-fade-in-out { + from { opacity: 0.99; } + 25% { opacity: 0.99; } + 26% { opacity: 0; } + 89% { opacity: 0; } + 90% { opacity: 0.99; } + 100% { opacity: 0.99; } +} + +@keyframes layer-1-fade-in-out { + from { opacity: 0.99; } + 25% { opacity: 0.99; } + 26% { opacity: 0; } + 89% { opacity: 0; } + 90% { opacity: 0.99; } + 100% { opacity: 0.99; } +} + +@-webkit-keyframes layer-2-fade-in-out { + from { opacity: 0; } + 15% { opacity: 0; } + 25% { opacity: 0.99; } + 50% { opacity: 0.99; } + 51% { opacity: 0; } +} + +@keyframes layer-2-fade-in-out { + from { opacity: 0; } + 15% { opacity: 0; } + 25% { opacity: 0.99; } + 50% { opacity: 0.99; } + 51% { opacity: 0; } +} + +@-webkit-keyframes layer-3-fade-in-out { + from { opacity: 0; } + 40% { opacity: 0; } + 50% { opacity: 0.99; } + 75% { opacity: 0.99; } + 76% { opacity: 0; } +} + +@keyframes layer-3-fade-in-out { + from { opacity: 0; } + 40% { opacity: 0; } + 50% { opacity: 0.99; } + 75% { opacity: 0.99; } + 76% { opacity: 0; } +} + +@-webkit-keyframes layer-4-fade-in-out { + from { opacity: 0; } + 65% { opacity: 0; } + 75% { opacity: 0.99; } + 90% { opacity: 0.99; } + 100% { opacity: 0; } +} + +@keyframes layer-4-fade-in-out { + from { opacity: 0; } + 65% { opacity: 0; } + 75% { opacity: 0.99; } + 90% { opacity: 0.99; } + 100% { opacity: 0; } +} + +/** + * Patch the gap that appear between the two adjacent div.circle-clipper while the + * spinner is rotating (appears on Chrome 38, Safari 7.1, and IE 11). + * + * Update: the gap no longer appears on Chrome when .spinner-layer's opacity is 0.99, + * but still does on Safari and IE. + */ +.gap-patch { + position: absolute; + box-sizing: border-box; + top: 0; + left: 45%; + width: 10%; + height: 100%; + overflow: hidden; + border-color: inherit; +} + +.gap-patch .circle { + width: 1000%; + left: -450%; +} + +.circle-clipper { + display: inline-block; + position: relative; + width: 50%; + height: 100%; + overflow: hidden; + border-color: inherit; +} + +.circle-clipper .circle { + width: 200%; +} + +.circle { + box-sizing: border-box; + height: 100%; + border-width: 3px; /* STROKEWIDTH */ + border-style: solid; + border-color: inherit; + border-bottom-color: transparent !important; + border-radius: 50%; + -webkit-animation: none; + animation: none; + + @apply(--layout-fit); +} + +.circle-clipper.left .circle { + border-right-color: transparent !important; + -webkit-transform: rotate(129deg); + transform: rotate(129deg); +} + +.circle-clipper.right .circle { + left: -100%; + border-left-color: transparent !important; + -webkit-transform: rotate(-129deg); + transform: rotate(-129deg); +} + +.active .circle-clipper.left .circle { + /* duration: ARCTIME */ + -webkit-animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .circle-clipper.right .circle { + /* duration: ARCTIME */ + -webkit-animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +@-webkit-keyframes left-spin { + from { -webkit-transform: rotate(130deg); } + 50% { -webkit-transform: rotate(-5deg); } + to { -webkit-transform: rotate(130deg); } +} + +@keyframes left-spin { + from { transform: rotate(130deg); } + 50% { transform: rotate(-5deg); } + to { transform: rotate(130deg); } +} + +@-webkit-keyframes right-spin { + from { -webkit-transform: rotate(-130deg); } + 50% { -webkit-transform: rotate(5deg); } + to { -webkit-transform: rotate(-130deg); } +} + +@keyframes right-spin { + from { transform: rotate(-130deg); } + 50% { transform: rotate(5deg); } + to { transform: rotate(-130deg); } +} + +#spinnerContainer.cooldown { + /* duration: SHRINK_TIME */ + -webkit-animation: container-rotate 1568ms linear infinite, fade-out 400ms cubic-bezier(0.4, 0.0, 0.2, 1); + animation: container-rotate 1568ms linear infinite, fade-out 400ms cubic-bezier(0.4, 0.0, 0.2, 1); +} + +@-webkit-keyframes fade-out { + from { opacity: 0.99; } + to { opacity: 0; } +} + +@keyframes fade-out { + from { opacity: 0.99; } + to { opacity: 0; } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner.html b/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner.html new file mode 100644 index 0000000..1a36945 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-spinner/paper-spinner.html @@ -0,0 +1,99 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/color.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> + +<!-- +Element providing material design circular spinner. + + <paper-spinner active></paper-spinner> + +The default spinner cycles between four layers of colors; by default they are +blue, red, yellow and green. It can be customized so that it uses one color only +by setting all the layer colors to the same value. + +### Accessibility + +Alt attribute should be set to provide adequate context for accessibility. If not provided, +it defaults to 'loading'. +Empty alt can be provided to mark the element as decorative if alternative content is provided +in another form (e.g. a text block following the spinner). + + <paper-spinner alt="Loading contacts list" active></paper-spinner> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-spinner-layer-1-color` | Color of the first spinner rotation | `--google-blue-500` +`--paper-spinner-layer-2-color` | Color of the second spinner rotation | `--google-red-500` +`--paper-spinner-layer-3-color` | Color of the third spinner rotation | `--google-yellow-500` +`--paper-spinner-layer-4-color` | Color of the fourth spinner rotation | `--google-green-500` + +@group Paper Elements +@element paper-spinner +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-spinner"> + + <link rel="import" type="css" href="paper-spinner.css"> + + <template> + + <div id="spinnerContainer" class-name="[[_spinnerContainerClassName]]"> + <div class="spinner-layer layer-1"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + + <div class="spinner-layer layer-2"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + + <div class="spinner-layer layer-3"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + + <div class="spinner-layer layer-4"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + </div> + + </template> + + </dom-module> +<script src="paper-spinner-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-styles/.bower.json new file mode 100644 index 0000000..46a6457 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-styles", + "version": "1.0.3", + "description": "Common (global) styles for Material Design elements.", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "style" + ], + "main": "paper-styles.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/polymerelements/paper-styles/", + "ignore": [ + "/.*", + "/demo/" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.3", + "_resolution": { + "type": "version", + "tag": "v1.0.3", + "commit": "64adbb4e15214cdc0e5df1ac4b8f2d9e2eca6076" + }, + "_source": "git://github.com/PolymerElements/paper-styles.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-styles" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/README.md b/third_party/polymer/v1_0/components-chromium/paper-styles/README.md new file mode 100644 index 0000000..82a7847 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/README.md @@ -0,0 +1,3 @@ +# paper-styles + +Material design CSS styles. diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/bower.json b/third_party/polymer/v1_0/components-chromium/paper-styles/bower.json new file mode 100644 index 0000000..c818d34 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/bower.json @@ -0,0 +1,27 @@ +{ + "name": "paper-styles", + "version": "1.0.3", + "description": "Common (global) styles for Material Design elements.", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "style" + ], + "main": "paper-styles.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/polymerelements/paper-styles/", + "ignore": [ + "/.*", + "/demo/" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/classes/global.html b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/global.html new file mode 100644 index 0000000..6f0d5dd --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/global.html @@ -0,0 +1,96 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../paper-styles-classes.html"> + +<!-- +A set of base styles that are applied to the document and standard elements that +match the Material Design spec. +--> +<style> +/* +Note that there is a lot of style duplication here. The hope is that the Polymer +0.8 styling solution will allow for inheritance of properties so that we can +eventually avoid it. +*/ + +/* Mixins */ + +/* [paper-font] */ +body { + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; /* OS X subpixel AA bleed bug */ +} + +/* [paper-font=display2] */ +h1 { + font-size: 45px; + font-weight: 400; + letter-spacing: -.018em; + line-height: 48px; +} + +/* [paper-font=display1] */ +h2 { + font-size: 34px; + font-weight: 400; + letter-spacing: -.01em; + line-height: 40px; +} + +/* [paper-font=headline] */ +h3 { + font-size: 24px; + font-weight: 400; + letter-spacing: -.012em; + line-height: 32px; +} + +/* [paper-font=subhead] */ +h4 { + font-size: 16px; + font-weight: 400; + line-height: 24px; +} + +/* [paper-font=body2] */ +h5, h6 { + font-size: 14px; + font-weight: 500; + line-height: 24px; +} + +/* [paper-font=button] */ +a { + font-size: 14px; + font-weight: 500; + letter-spacing: 0.018em; + line-height: 24px; + text-transform: uppercase; +} + +/* Overrides */ + +body, a { + color: #212121; +} + +h1, h2, h3, h4, h5, h6, p { + margin: 0 0 20px 0; +} + +h1, h2, h3, h4, h5, h6, a { + text-rendering: optimizeLegibility; +} + +a { + text-decoration: none; +} + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/classes/shadow-layout.html b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/shadow-layout.html new file mode 100644 index 0000000..c42067a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/shadow-layout.html @@ -0,0 +1,302 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<style> + + /******************************* + Flex Layout + *******************************/ + + html /deep/ .layout.horizontal, + html /deep/ .layout.horizontal-reverse, + html /deep/ .layout.vertical, + html /deep/ .layout.vertical-reverse { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + } + + html /deep/ .layout.inline { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + } + + html /deep/ .layout.horizontal { + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + } + + html /deep/ .layout.horizontal-reverse { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + } + + html /deep/ .layout.vertical { + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + } + + html /deep/ .layout.vertical-reverse { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + } + + html /deep/ .layout.wrap { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + } + + html /deep/ .layout.wrap-reverse { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + } + + html /deep/ .flex-auto { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + } + + html /deep/ .flex-none { + -ms-flex: none; + -webkit-flex: none; + flex: none; + } + + html /deep/ .flex, + html /deep/ .flex-1 { + -ms-flex: 1; + -webkit-flex: 1; + flex: 1; + } + + html /deep/ .flex-2 { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + } + + html /deep/ .flex-3 { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + } + + html /deep/ .flex-4 { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + } + + html /deep/ .flex-5 { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + } + + html /deep/ .flex-6 { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + } + + html /deep/ .flex-7 { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + } + + html /deep/ .flex-8 { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + } + + html /deep/ .flex-9 { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + } + + html /deep/ .flex-10 { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + } + + html /deep/ .flex-11 { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + } + + html /deep/ .flex-12 { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + } + + /* alignment in cross axis */ + + html /deep/ .layout.start { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + } + + html /deep/ .layout.center, + html /deep/ .layout.center-center { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + } + + html /deep/ .layout.end { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + } + + /* alignment in main axis */ + + html /deep/ .layout.start-justified { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + } + + html /deep/ .layout.center-justified, + html /deep/ .layout.center-center { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + } + + html /deep/ .layout.end-justified { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + } + + html /deep/ .layout.around-justified { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + } + + html /deep/ .layout.justified { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + } + + /* self alignment */ + + html /deep/ .self-start { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + } + + html /deep/ .self-center { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + } + + html /deep/ .self-end { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + } + + html /deep/ .self-stretch { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + } + + /******************************* + Other Layout + *******************************/ + + html /deep/ .block { + display: block; + } + + /* IE 10 support for HTML5 hidden attr */ + html /deep/ [hidden] { + display: none !important; + } + + html /deep/ .invisible { + visibility: hidden !important; + } + + html /deep/ .relative { + position: relative; + } + + html /deep/ .fit { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + body.fullbleed { + margin: 0; + height: 100vh; + } + + html /deep/ .scroll { + -webkit-overflow-scrolling: touch; + overflow: auto; + } + + .fixed-bottom, + .fixed-left, + .fixed-right, + .fixed-top { + position: fixed; + } + + html /deep/ .fixed-top { + top: 0; + left: 0; + right: 0; + } + + html /deep/ .fixed-right { + top: 0; + right: 0; + botttom: 0; + } + + html /deep/ .fixed-bottom { + right: 0; + bottom: 0; + left: 0; + } + + html /deep/ .fixed-left { + top: 0; + botttom: 0; + left: 0; + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/classes/shadow.html b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/shadow.html new file mode 100644 index 0000000..b4c340d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/shadow.html @@ -0,0 +1,39 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<style> +.shadow-transition { + transition: box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1); +} + +.shadow-elevation-1 { + box-shadow: 0 1px 4px 0 rgba(0, 0, 0, 0.37); +} + +.shadow-elevation-2 { + box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.2), + 0 6px 10px 0 rgba(0, 0, 0, 0.3); +} + +.shadow-elevation-3 { + box-shadow: 0 11px 7px 0 rgba(0, 0, 0, 0.19), + 0 13px 25px 0 rgba(0, 0, 0, 0.3); +} + +.shadow-elevation-4 { + box-shadow: 0 14px 12px 0 rgba(0, 0, 0, 0.17), + 0 20px 40px 0 rgba(0, 0, 0, 0.3); +} + +.shadow-elevation-5 { + box-shadow: 0 17px 17px 0 rgba(0, 0, 0, 0.15), + 0 27px 55px 0 rgba(0, 0, 0, 0.3); +} +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/classes/typography.html b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/typography.html new file mode 100644 index 0000000..5514abb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/classes/typography.html @@ -0,0 +1,171 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!-- TODO(nevir): Should we upgrade Polymer/font-roboto to the final font? --> +<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto:400,300,300italic,400italic,500,500italic,700,700italic"> +<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Inconsolata:400,700"> + +<!-- +Typographic styles are provided matching the Material Design standard styles: +http://www.google.com/design/spec/style/typography.html#typography-standard-styles + +To make use of them, apply a `paper-font-<style>` class to elements, matching +the font style you wish it to inherit. + + <header class="paper-font-display2">Hey there!</header> + +Note that these are English/Latin centric styles. You may need to further adjust +line heights and weights for CJK typesetting. See the notes in the Material +Design typography section. +--> +<style> + +.paper-font-display4, +.paper-font-display3, +.paper-font-display2, +.paper-font-display1, +.paper-font-headline, +.paper-font-title, +.paper-font-subhead, +.paper-font-body2, +.paper-font-body1, +.paper-font-caption, +.paper-font-menu, +.paper-font-button { + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; /* OS X subpixel AA bleed bug */ +} + +.paper-font-code2, +.paper-font-code1 { + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; /* OS X subpixel AA bleed bug */ +} + +/* Opt for better kerning for headers & other short labels. */ +.paper-font-display4, +.paper-font-display3, +.paper-font-display2, +.paper-font-display1, +.paper-font-headline, +.paper-font-title, +.paper-font-subhead, +.paper-font-menu, +.paper-font-button { + text-rendering: optimizeLegibility; +} + +/* +"Line wrapping only applies to Body, Subhead, Headline, and the smaller Display +styles. All other styles should exist as single lines." +*/ +.paper-font-display4, +.paper-font-display3, +.paper-font-title, +.paper-font-caption, +.paper-font-menu, +.paper-font-button { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.paper-font-display4 { + font-size: 112px; + font-weight: 300; + letter-spacing: -.044em; + line-height: 120px; +} + +.paper-font-display3 { + font-size: 56px; + font-weight: 400; + letter-spacing: -.026em; + line-height: 60px; +} + +.paper-font-display2 { + font-size: 45px; + font-weight: 400; + letter-spacing: -.018em; + line-height: 48px; +} + +.paper-font-display1 { + font-size: 34px; + font-weight: 400; + letter-spacing: -.01em; + line-height: 40px; +} + +.paper-font-headline { + font-size: 24px; + font-weight: 400; + letter-spacing: -.012em; + line-height: 32px; +} + +.paper-font-title { + font-size: 20px; + font-weight: 500; + line-height: 28px; +} + +.paper-font-subhead { + font-size: 16px; + font-weight: 400; + line-height: 24px; +} + +.paper-font-body2 { + font-size: 14px; + font-weight: 500; + line-height: 24px; +} + +.paper-font-body1 { + font-size: 14px; + font-weight: 400; + line-height: 20px; +} + +.paper-font-caption { + font-size: 12px; + font-weight: 400; + letter-spacing: 0.011em; + line-height: 20px; +} + +.paper-font-menu { + font-size: 13px; + font-weight: 500; + line-height: 24px; +} + +.paper-font-button { + font-size: 14px; + font-weight: 500; + letter-spacing: 0.018em; + line-height: 24px; + text-transform: uppercase; +} + +.paper-font-code2 { + font-size: 14px; + font-weight: 700; + line-height: 20px; +} + +.paper-font-code1 { + font-size: 14px; + font-weight: 700; + line-height: 20px; +} + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/color.html b/third_party/polymer/v1_0/components-chromium/paper-styles/color.html new file mode 100644 index 0000000..5f8f887 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/color.html @@ -0,0 +1,333 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + /* Material Design color palette for Google products */ + + --google-red-100: #f4c7c3; + --google-red-300: #e67c73; + --google-red-500: #db4437; + --google-red-700: #c53929; + + --google-blue-100: #c6dafc; + --google-blue-300: #7baaf7; + --google-blue-500: #4285f4; + --google-blue-700: #3367d6; + + --google-green-100: #b7e1cd; + --google-green-300: #57bb8a; + --google-green-500: #0f9d58; + --google-green-700: #0b8043; + + --google-yellow-100: #fce8b2; + --google-yellow-300: #f7cb4d; + --google-yellow-500: #f4b400; + --google-yellow-700: #f09300; + + --google-grey-100: #f5f5f5; + --google-grey-300: #e0e0e0; + --google-grey-500: #9e9e9e; + --google-grey-700: #616161; + + /* Material Design color palette from online spec document */ + + --paper-red-50: #ffebee; + --paper-red-100: #ffcdd2; + --paper-red-200: #ef9a9a; + --paper-red-300: #e57373; + --paper-red-400: #ef5350; + --paper-red-500: #f44336; + --paper-red-600: #e53935; + --paper-red-700: #d32f2f; + --paper-red-800: #c62828; + --paper-red-900: #b71c1c; + --paper-red-a100: #ff8a80; + --paper-red-a200: #ff5252; + --paper-red-a400: #ff1744; + --paper-red-a700: #d50000; + + --paper-pink-50: #fce4ec; + --paper-pink-100: #f8bbd0; + --paper-pink-200: #f48fb1; + --paper-pink-300: #f06292; + --paper-pink-400: #ec407a; + --paper-pink-500: #e91e63; + --paper-pink-600: #d81b60; + --paper-pink-700: #c2185b; + --paper-pink-800: #ad1457; + --paper-pink-900: #880e4f; + --paper-pink-a100: #ff80ab; + --paper-pink-a200: #ff4081; + --paper-pink-a400: #f50057; + --paper-pink-a700: #c51162; + + --paper-purple-50: #f3e5f5; + --paper-purple-100: #e1bee7; + --paper-purple-200: #ce93d8; + --paper-purple-300: #ba68c8; + --paper-purple-400: #ab47bc; + --paper-purple-500: #9c27b0; + --paper-purple-600: #8e24aa; + --paper-purple-700: #7b1fa2; + --paper-purple-800: #6a1b9a; + --paper-purple-900: #4a148c; + --paper-purple-a100: #ea80fc; + --paper-purple-a200: #e040fb; + --paper-purple-a400: #d500f9; + --paper-purple-a700: #aa00ff; + + --paper-deep-purple-50: #ede7f6; + --paper-deep-purple-100: #d1c4e9; + --paper-deep-purple-200: #b39ddb; + --paper-deep-purple-300: #9575cd; + --paper-deep-purple-400: #7e57c2; + --paper-deep-purple-500: #673ab7; + --paper-deep-purple-600: #5e35b1; + --paper-deep-purple-700: #512da8; + --paper-deep-purple-800: #4527a0; + --paper-deep-purple-900: #311b92; + --paper-deep-purple-a100: #b388ff; + --paper-deep-purple-a200: #7c4dff; + --paper-deep-purple-a400: #651fff; + --paper-deep-purple-a700: #6200ea; + + --paper-indigo-50: #e8eaf6; + --paper-indigo-100: #c5cae9; + --paper-indigo-200: #9fa8da; + --paper-indigo-300: #7986cb; + --paper-indigo-400: #5c6bc0; + --paper-indigo-500: #3f51b5; + --paper-indigo-600: #3949ab; + --paper-indigo-700: #303f9f; + --paper-indigo-800: #283593; + --paper-indigo-900: #1a237e; + --paper-indigo-a100: #8c9eff; + --paper-indigo-a200: #536dfe; + --paper-indigo-a400: #3d5afe; + --paper-indigo-a700: #304ffe; + + --paper-blue-50: #e3f2fd; + --paper-blue-100: #bbdefb; + --paper-blue-200: #90caf9; + --paper-blue-300: #64b5f6; + --paper-blue-400: #42a5f5; + --paper-blue-500: #2196f3; + --paper-blue-600: #1e88e5; + --paper-blue-700: #1976d2; + --paper-blue-800: #1565c0; + --paper-blue-900: #0d47a1; + --paper-blue-a100: #82b1ff; + --paper-blue-a200: #448aff; + --paper-blue-a400: #2979ff; + --paper-blue-a700: #2962ff; + + --paper-light-blue-50: #e1f5fe; + --paper-light-blue-100: #b3e5fc; + --paper-light-blue-200: #81d4fa; + --paper-light-blue-300: #4fc3f7; + --paper-light-blue-400: #29b6f6; + --paper-light-blue-500: #03a9f4; + --paper-light-blue-600: #039be5; + --paper-light-blue-700: #0288d1; + --paper-light-blue-800: #0277bd; + --paper-light-blue-900: #01579b; + --paper-light-blue-a100: #80d8ff; + --paper-light-blue-a200: #40c4ff; + --paper-light-blue-a400: #00b0ff; + --paper-light-blue-a700: #0091ea; + + --paper-cyan-50: #e0f7fa; + --paper-cyan-100: #b2ebf2; + --paper-cyan-200: #80deea; + --paper-cyan-300: #4dd0e1; + --paper-cyan-400: #26c6da; + --paper-cyan-500: #00bcd4; + --paper-cyan-600: #00acc1; + --paper-cyan-700: #0097a7; + --paper-cyan-800: #00838f; + --paper-cyan-900: #006064; + --paper-cyan-a100: #84ffff; + --paper-cyan-a200: #18ffff; + --paper-cyan-a400: #00e5ff; + --paper-cyan-a700: #00b8d4; + + --paper-teal-50: #e0f2f1; + --paper-teal-100: #b2dfdb; + --paper-teal-200: #80cbc4; + --paper-teal-300: #4db6ac; + --paper-teal-400: #26a69a; + --paper-teal-500: #009688; + --paper-teal-600: #00897b; + --paper-teal-700: #00796b; + --paper-teal-800: #00695c; + --paper-teal-900: #004d40; + --paper-teal-a100: #a7ffeb; + --paper-teal-a200: #64ffda; + --paper-teal-a400: #1de9b6; + --paper-teal-a700: #00bfa5; + + --paper-green-50: #e8f5e9; + --paper-green-100: #c8e6c9; + --paper-green-200: #a5d6a7; + --paper-green-300: #81c784; + --paper-green-400: #66bb6a; + --paper-green-500: #4caf50; + --paper-green-600: #43a047; + --paper-green-700: #388e3c; + --paper-green-800: #2e7d32; + --paper-green-900: #1b5e20; + --paper-green-a100: #b9f6ca; + --paper-green-a200: #69f0ae; + --paper-green-a400: #00e676; + --paper-green-a700: #00c853; + + --paper-light-green-50: #f1f8e9; + --paper-light-green-100: #dcedc8; + --paper-light-green-200: #c5e1a5; + --paper-light-green-300: #aed581; + --paper-light-green-400: #9ccc65; + --paper-light-green-500: #8bc34a; + --paper-light-green-600: #7cb342; + --paper-light-green-700: #689f38; + --paper-light-green-800: #558b2f; + --paper-light-green-900: #33691e; + --paper-light-green-a100: #ccff90; + --paper-light-green-a200: #b2ff59; + --paper-light-green-a400: #76ff03; + --paper-light-green-a700: #64dd17; + + --paper-lime-50: #f9fbe7; + --paper-lime-100: #f0f4c3; + --paper-lime-200: #e6ee9c; + --paper-lime-300: #dce775; + --paper-lime-400: #d4e157; + --paper-lime-500: #cddc39; + --paper-lime-600: #c0ca33; + --paper-lime-700: #afb42b; + --paper-lime-800: #9e9d24; + --paper-lime-900: #827717; + --paper-lime-a100: #f4ff81; + --paper-lime-a200: #eeff41; + --paper-lime-a400: #c6ff00; + --paper-lime-a700: #aeea00; + + --paper-yellow-50: #fffde7; + --paper-yellow-100: #fff9c4; + --paper-yellow-200: #fff59d; + --paper-yellow-300: #fff176; + --paper-yellow-400: #ffee58; + --paper-yellow-500: #ffeb3b; + --paper-yellow-600: #fdd835; + --paper-yellow-700: #fbc02d; + --paper-yellow-800: #f9a825; + --paper-yellow-900: #f57f17; + --paper-yellow-a100: #ffff8d; + --paper-yellow-a200: #ffff00; + --paper-yellow-a400: #ffea00; + --paper-yellow-a700: #ffd600; + + --paper-amber-50: #fff8e1; + --paper-amber-100: #ffecb3; + --paper-amber-200: #ffe082; + --paper-amber-300: #ffd54f; + --paper-amber-400: #ffca28; + --paper-amber-500: #ffc107; + --paper-amber-600: #ffb300; + --paper-amber-700: #ffa000; + --paper-amber-800: #ff8f00; + --paper-amber-900: #ff6f00; + --paper-amber-a100: #ffe57f; + --paper-amber-a200: #ffd740; + --paper-amber-a400: #ffc400; + --paper-amber-a700: #ffab00; + + --paper-orange-50: #fff3e0; + --paper-orange-100: #ffe0b2; + --paper-orange-200: #ffcc80; + --paper-orange-300: #ffb74d; + --paper-orange-400: #ffa726; + --paper-orange-500: #ff9800; + --paper-orange-600: #fb8c00; + --paper-orange-700: #f57c00; + --paper-orange-800: #ef6c00; + --paper-orange-900: #e65100; + --paper-orange-a100: #ffd180; + --paper-orange-a200: #ffab40; + --paper-orange-a400: #ff9100; + --paper-orange-a700: #ff6500; + + --paper-deep-orange-50: #ff5722; + --paper-deep-orange-100: #fbe9e7; + --paper-deep-orange-200: #ffccbc; + --paper-deep-orange-300: #ff8a65; + --paper-deep-orange-400: #ff7043; + --paper-deep-orange-500: #ff5722; + --paper-deep-orange-600: #f4511e; + --paper-deep-orange-700: #e64a19; + --paper-deep-orange-800: #d84315; + --paper-deep-orange-900: #bf360c; + --paper-deep-orange-a100: #ff9e80; + --paper-deep-orange-a200: #ff6e40; + --paper-deep-orange-a400: #ff3d00; + --paper-deep-orange-a700: #dd2c00; + + --paper-brown-50: #795548; + --paper-brown-100: #efebe9; + --paper-brown-200: #d7ccc8; + --paper-brown-300: #a1887f; + --paper-brown-400: #8d6e63; + --paper-brown-500: #795548; + --paper-brown-600: #6d4c41; + --paper-brown-700: #5d4037; + --paper-brown-800: #4e342e; + --paper-brown-900: #3e2723; + + --paper-grey-50: #fafafa; + --paper-grey-100: #f5f5f5; + --paper-grey-200: #eeeeee; + --paper-grey-300: #e0e0e0; + --paper-grey-400: #bdbdbd; + --paper-grey-500: #9e9e9e; + --paper-grey-600: #757575; + --paper-grey-700: #616161; + --paper-grey-800: #424242; + --paper-grey-900: #212121; + + --paper-blue-grey-50: #eceff1; + --paper-blue-grey-100: #cfd8dc; + --paper-blue-grey-200: #b0bec5; + --paper-blue-grey-300: #90a4ae; + --paper-blue-grey-400: #78909c; + --paper-blue-grey-500: #607d8b; + --paper-blue-grey-600: #546e7a; + --paper-blue-grey-700: #455a64; + --paper-blue-grey-800: #37474f; + --paper-blue-grey-900: #263238; + + /* opacity for dark text on a light background */ + --dark-divider-opacity: 0.12; + --dark-disabled-opacity: 0.26; /* or hint text */ + --dark-secondary-opacity: 0.54; /* or icon */ + --dark-primary-opacity: 0.87; + + /* opacity for light text on a dark background */ + --light-divider-opacity: 0.12; + --light-disabled-opacity: 0.3; /* or hint text */ + --light-secondary-opacity: 0.7; /* or icon */ + --light-primary-opacity: 1.0; + + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/default-theme.html b/third_party/polymer/v1_0/components-chromium/paper-styles/default-theme.html new file mode 100644 index 0000000..add581c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/default-theme.html @@ -0,0 +1,39 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + --dark-primary-color: #303f9f; + + --default-primary-color: #3f51b5; + + --light-primary-color: #c5cae9; + + --text-primary-color: #ffffff; + + --accent-color: #ff4081; + + --primary-background-color: #ffffff; + + --primary-text-color: #212121; + + --secondary-text-color: #757575; + + --disabled-text-color: #bdbdbd; + + --divider-color: #e0e0e0; + + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/demo-pages.html b/third_party/polymer/v1_0/components-chromium/paper-styles/demo-pages.html new file mode 100644 index 0000000..9fc5739 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/demo-pages.html @@ -0,0 +1,64 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="color.html"> +<link rel="import" href="shadow.html"> + +<style is="custom-style"> + + body { + font-family: 'Roboto', 'Noto', sans-serif; + font-size: 14px; + margin: 0; + padding: 24px; + background-color: var(--paper-grey-50); + } + + .horizontal-section-container { + @apply(--layout-horizontal); + @apply(--layout-center-justified); + @apply(--layout-wrap); + } + + .vertical-section-container { + @apply(--layout-vertical); + @apply(--center-justified); + } + + .horizontal-section { + background-color: white; + padding: 24px; + margin-right: 24px; + min-width: 200px; + + @apply(--shadow-elevation-2dp); + } + + .vertical-section { + background-color: white; + padding: 24px; + margin: 0 24px 24px 24px; + + @apply(--shadow-elevation-2dp); + } + + .centered { + max-width: 400px; + margin-left: auto; + margin-right: auto; + } + + /* TODO: remove this hack and use horizontal-section-container instead */ + body > div.layout.horizontal.center-justified { + @apply(--layout-wrap); + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/demo.css b/third_party/polymer/v1_0/components-chromium/paper-styles/demo.css new file mode 100644 index 0000000..efd8b47 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/demo.css @@ -0,0 +1,25 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + +*/ +body { + font-family: 'Roboto', 'Noto', sans-serif; + font-size: 14px; + margin: 0; + padding: 24px; +} + +section { + padding: 20px 0; +} + +section > div { + padding: 14px; + font-size: 16px; +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/paper-styles-classes.html b/third_party/polymer/v1_0/components-chromium/paper-styles/paper-styles-classes.html new file mode 100644 index 0000000..ae315a5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/paper-styles-classes.html @@ -0,0 +1,14 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<link rel="import" href="classes/typography.html"> +<link rel="import" href="classes/shadow.html"> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/paper-styles.html b/third_party/polymer/v1_0/components-chromium/paper-styles/paper-styles.html new file mode 100644 index 0000000..1e4fce5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/paper-styles.html @@ -0,0 +1,17 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<link rel="import" href="color.html"> +<link rel="import" href="default-theme.html"> +<link rel="import" href="shadow.html"> +<link rel="import" href="typography.html"> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/shadow.html b/third_party/polymer/v1_0/components-chromium/paper-styles/shadow.html new file mode 100644 index 0000000..7339d8e --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/shadow.html @@ -0,0 +1,61 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + --shadow-transition: { + transition: box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1); + }; + + /* from http://codepen.io/shyndman/pen/c5394ddf2e8b2a5c9185904b57421cdb */ + + --shadow-elevation-2dp: { + box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14), + 0 1px 5px 0 rgba(0, 0, 0, 0.12), + 0 3px 1px -2px rgba(0, 0, 0, 0.2); + }; + + --shadow-elevation-3dp: { + box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.14), + 0 1px 8px 0 rgba(0, 0, 0, 0.12), + 0 3px 3px -2px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-4dp: { + box-shadow: 0 4px 5px 0 rgba(0, 0, 0, 0.14), + 0 1px 10px 0 rgba(0, 0, 0, 0.12), + 0 2px 4px -1px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-6dp: { + box-shadow: 0 6px 10px 0 rgba(0, 0, 0, 0.14), + 0 1px 18px 0 rgba(0, 0, 0, 0.12), + 0 3px 5px -1px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-8dp: { + box-shadow: 0 8px 10px 1px rgba(0, 0, 0, 0.14), + 0 3px 14px 2px rgba(0, 0, 0, 0.12), + 0 5px 5px -3px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-16dp: { + box-shadow: 0 16px 24px 2px rgba(0, 0, 0, 0.14), + 0 6px 30px 5px rgba(0, 0, 0, 0.12), + 0 8px 10px -5px rgba(0, 0, 0, 0.4); + }; + + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-styles/typography.html b/third_party/polymer/v1_0/components-chromium/paper-styles/typography.html new file mode 100644 index 0000000..a37cd34 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-styles/typography.html @@ -0,0 +1,240 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!-- TODO(nevir): Should we upgrade Polymer/font-roboto to the final font? --> +<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto:400,300,300italic,400italic,500,500italic,700,700italic"> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + /* Shared Styles */ + + /* + Unfortunately, we can't make use of these yet - sibling properties aren't + evaluated. See https://github.com/Polymer/polymer/issues/1399 + + --paper-font-common-base: { + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + }; + + --paper-font-common-code: { + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; + }; + + --paper-font-common-expensive-kerning: { + text-rendering: optimizeLegibility; + }; + + --paper-font-common-nowrap: { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + }; + */ + + /* Material Font Styles */ + + --paper-font-display4: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 112px; + font-weight: 300; + letter-spacing: -.044em; + line-height: 120px; + }; + + --paper-font-display3: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 56px; + font-weight: 400; + letter-spacing: -.026em; + line-height: 60px; + }; + + --paper-font-display2: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 45px; + font-weight: 400; + letter-spacing: -.018em; + line-height: 48px; + }; + + --paper-font-display1: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 34px; + font-weight: 400; + letter-spacing: -.01em; + line-height: 40px; + }; + + --paper-font-headline: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 24px; + font-weight: 400; + letter-spacing: -.012em; + line-height: 32px; + }; + + --paper-font-title: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 20px; + font-weight: 500; + line-height: 28px; + }; + + --paper-font-subhead: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 16px; + font-weight: 400; + line-height: 24px; + }; + + --paper-font-body2: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 500; + line-height: 24px; + }; + + --paper-font-body1: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 400; + line-height: 20px; + }; + + --paper-font-caption: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 12px; + font-weight: 400; + letter-spacing: 0.011em; + line-height: 20px; + }; + + --paper-font-menu: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 13px; + font-weight: 500; + line-height: 24px; + }; + + --paper-font-button: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 14px; + font-weight: 500; + letter-spacing: 0.018em; + line-height: 24px; + text-transform: uppercase; + }; + + --paper-font-code2: { + /* @apply(--paper-font-common-code); */ + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 700; + line-height: 20px; + }; + + --paper-font-code1: { + /* @apply(--paper-font-common-code); */ + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 500; + line-height: 20px; + }; + + } + +</style> diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-tabs/.bower.json new file mode 100644 index 0000000..0b9b4e2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/.bower.json @@ -0,0 +1,47 @@ +{ + "name": "paper-tabs", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Material design tabs", + "private": true, + "main": "paper-tabs.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "tabs", + "control" + ], + "repository": "https://github.com/PolymerElements/paper-tabs.git", + "dependencies": { + "iron-behaviors": "polymerelements/iron-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "iron-menu-behavior": "polymerelements/iron-menu-behavior#^1.0.0", + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "paper-icon-button": "polymerelements/paper-icon-button#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-toolbar": "polymerelements/paper-toolbar#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + }, + "homepage": "https://github.com/PolymerElements/paper-tabs", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "af6820e55f73fc5aa8c8e4d5294085e46374c7ca" + }, + "_source": "git://github.com/PolymerElements/paper-tabs.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-tabs" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-tabs/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/README.md b/third_party/polymer/v1_0/components-chromium/paper-tabs/README.md new file mode 100644 index 0000000..d4744e2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/README.md @@ -0,0 +1,56 @@ +paper-tabs +============ + +`paper-tabs` makes it easy to explore and switch between different views or functional aspects of +an app, or to browse categorized data sets. + +Use `selected` property to get or set the selected tab. + +Example: + +```html +<paper-tabs selected="0"> + <paper-tab>TAB 1</paper-tab> + <paper-tab>TAB 2</paper-tab> + <paper-tab>TAB 3</paper-tab> +</paper-tabs> +``` + +See <a href="#paper-tab">paper-tab</a> for more information about +`paper-tab`. + +A common usage for `paper-tabs` is to use it along with `iron-pages` to switch +between different views. + +```html +<paper-tabs selected="{{selected}}"> + <paper-tab>Tab 1</paper-tab> + <paper-tab>Tab 2</paper-tab> + <paper-tab>Tab 3</paper-tab> +</paper-tabs> + +<iron-pages selected="{{selected}}"> + <div>Page 1</div> + <div>Page 2</div> + <div>Page 3</div> +</iron-pages> +``` + +To use links in tabs, add `link` attribute to `paper-tab` and put an `<a>` +element in `paper-tab`. + +Example: + +```html +<paper-tabs selected="0"> + <paper-tab link> + <a href="#link1" class="horizontal center-center layout">TAB ONE</a> + </paper-tab> + <paper-tab link> + <a href="#link2" class="horizontal center-center layout">TAB TWO</a> + </paper-tab> + <paper-tab link> + <a href="#link3" class="horizontal center-center layout">TAB THREE</a> + </paper-tab> +</paper-tabs> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/bower.json b/third_party/polymer/v1_0/components-chromium/paper-tabs/bower.json new file mode 100644 index 0000000..cff76e9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-tabs", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Material design tabs", + "private": true, + "main": "paper-tabs.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "tabs", + "control" + ], + "repository": "https://github.com/PolymerElements/paper-tabs.git", + "dependencies": { + "iron-behaviors": "polymerelements/iron-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "iron-menu-behavior": "polymerelements/iron-menu-behavior#^1.0.0", + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "paper-icon-button": "polymerelements/paper-icon-button#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-toolbar": "polymerelements/paper-toolbar#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-tabs/hero.svg new file mode 100644 index 0000000..bfcbdac --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/hero.svg @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M188,78H37V44h151V78z M39,76h147V46H39V76z"/> + <polygon points="66,64.8 60.6,56.8 55.3,64.8 49.2,55.6 50.8,54.4 55.3,61.2 60.6,53.2 66,61.2 71.3,53.2 77.4,62.4 75.8,63.6 + 71.3,56.8 "/> + <rect x="149" y="58" width="26" height="2"/> + <rect x="99" y="58" width="26" height="2"/> + <rect x="38" y="72" width="50" height="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/index.html b/third_party/polymer/v1_0/components-chromium/paper-tabs/index.html new file mode 100644 index 0000000..98ab07d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>paper-tabs</title> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page sources='["paper-tabs.html", "paper-tab.html"]'></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tab-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tab-extracted.js new file mode 100644 index 0000000..975d991 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tab-extracted.js @@ -0,0 +1,42 @@ + + + Polymer({ + + is: 'paper-tab', + + behaviors: [ + Polymer.IronControlState + ], + + properties: { + + /** + * If true, ink ripple effect is disabled. + * + * @attribute noink + */ + noink: { + type: Boolean, + value: false + } + + }, + + hostAttributes: { + role: 'tab' + }, + + listeners: { + down: '_onDown' + }, + + get _parentNoink () { + var parent = Polymer.dom(this).parentNode; + return !!parent && !!parent.noink; + }, + + _onDown: function(e) { + this.noink = !!this.noink || !!this._parentNoink; + } + }); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tab.html b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tab.html new file mode 100644 index 0000000..0c0e1ed --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tab.html @@ -0,0 +1,114 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-behaviors/iron-control-state.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> + +<!-- +`paper-tab` is styled to look like a tab. It should be used in conjunction with +`paper-tabs`. + +Example: + + <paper-tabs selected="0"> + <paper-tab>TAB 1</paper-tab> + <paper-tab>TAB 2</paper-tab> + <paper-tab>TAB 3</paper-tab> + </paper-tabs> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-tab-ink` | Ink color | `--paper-yellow-a100` +`--paper-tab` | Mixin applied to the tab | `{}` +`--paper-tab-content` | Mixin applied to the tab content | `{}` + +--> + +</head><body><dom-module id="paper-tab"> + + <style> + + :host { + @apply(--layout-inline); + @apply(--layout-center); + @apply(--layout-center-justified); + @apply(--layout-flex); + + position: relative; + padding: 0 12px; + overflow: hidden; + cursor: pointer; + + @apply(--paper-tab); + } + + :host(:focus) { + outline: none; + } + + :host([link]) { + padding: 0; + } + + .tab-content { + height: 100%; + -webkit-transform: translateZ(0); + transform: translateZ(0); + transition: opacity 0.1s cubic-bezier(0.4, 0.0, 1, 1); + + @apply(--paper-tab-content); + } + + :host(:not(.iron-selected)) > .tab-content { + opacity: 0.8; + } + + :host(:focus) .tab-content { + opacity: 1; + font-weight: 700; + } + + #ink { + color: var(--paper-tab-ink, --paper-yellow-a100); + pointer-events: none; + } + + .tab-content > ::content > a { + height: 100%; + /* flex */ + -ms-flex: 1 1 0.000000001px; + -webkit-flex: 1; + flex: 1; + -webkit-flex-basis: 0.000000001px; + flex-basis: 0.000000001px; + } + + </style> + + <template> + + <div class="tab-content flex-auto center-center horizontal layout"> + <content></content> + </div> + + <template is="dom-if" if="[[!noink]]"> + <paper-ripple id="ink" initial-opacity="0.95" opacity-decay-velocity="0.98"></paper-ripple> + </template> + + </template> + +</dom-module> + +<script src="paper-tab-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs-extracted.js new file mode 100644 index 0000000..0948456 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs-extracted.js @@ -0,0 +1,287 @@ + + + Polymer({ + + is: 'paper-tabs', + + behaviors: [ + Polymer.IronResizableBehavior, + Polymer.IronMenubarBehavior + ], + + properties: { + + /** + * If true, ink ripple effect is disabled. + */ + noink: { + type: Boolean, + value: false + }, + + /** + * If true, the bottom bar to indicate the selected tab will not be shown. + */ + noBar: { + type: Boolean, + value: false + }, + + /** + * If true, the slide effect for the bottom bar is disabled. + */ + noSlide: { + type: Boolean, + value: false + }, + + /** + * If true, tabs are scrollable and the tab width is based on the label width. + */ + scrollable: { + type: Boolean, + value: false + }, + + /** + * If true, dragging on the tabs to scroll is disabled. + */ + disableDrag: { + type: Boolean, + value: false + }, + + /** + * If true, scroll buttons (left/right arrow) will be hidden for scrollable tabs. + */ + hideScrollButtons: { + type: Boolean, + value: false + }, + + /** + * If true, the tabs are aligned to bottom (the selection bar appears at the top). + */ + alignBottom: { + type: Boolean, + value: false + }, + + /** + * Gets or sets the selected element. The default is to use the index of the item. + */ + selected: { + type: String, + notify: true + }, + + selectable: { + type: String, + value: 'paper-tab' + }, + + _step: { + type: Number, + value: 10 + }, + + _holdDelay: { + type: Number, + value: 1 + }, + + _leftHidden: { + type: Boolean, + value: false + }, + + _rightHidden: { + type: Boolean, + value: false + }, + + _previousTab: { + type: Object + } + }, + + hostAttributes: { + role: 'tablist' + }, + + listeners: { + 'iron-resize': '_onResize', + 'iron-select': '_onIronSelect', + 'iron-deselect': '_onIronDeselect' + }, + + _computeScrollButtonClass: function(hideThisButton, scrollable, hideScrollButtons) { + if (!scrollable || hideScrollButtons) { + return 'hidden'; + } + + if (hideThisButton) { + return 'not-visible'; + } + + return ''; + }, + + _computeTabsContentClass: function(scrollable) { + return scrollable ? 'scrollable' : 'horizontal layout'; + }, + + _computeSelectionBarClass: function(noBar, alignBottom) { + if (noBar) { + return 'hidden'; + } else if (alignBottom) { + return 'align-bottom'; + } + }, + + // TODO(cdata): Add `track` response back in when gesture lands. + + _onResize: function() { + this.debounce('_onResize', function() { + this._scroll(); + this._tabChanged(this.selectedItem); + }, 10); + }, + + _onIronSelect: function(event) { + this._tabChanged(event.detail.item, this._previousTab); + this._previousTab = event.detail.item; + this.cancelDebouncer('tab-changed'); + }, + + _onIronDeselect: function(event) { + this.debounce('tab-changed', function() { + this._tabChanged(null, this._previousTab); + // See polymer/polymer#1305 + }, 1); + }, + + get _tabContainerScrollSize () { + return Math.max( + 0, + this.$.tabsContainer.scrollWidth - + this.$.tabsContainer.offsetWidth + ); + }, + + _scroll: function() { + var scrollLeft; + + if (!this.scrollable) { + return; + } + + scrollLeft = this.$.tabsContainer.scrollLeft; + + this._leftHidden = scrollLeft === 0; + this._rightHidden = scrollLeft === this._tabContainerScrollSize; + }, + + _onLeftScrollButtonDown: function() { + this._holdJob = setInterval(this._scrollToLeft.bind(this), this._holdDelay); + }, + + _onRightScrollButtonDown: function() { + this._holdJob = setInterval(this._scrollToRight.bind(this), this._holdDelay); + }, + + _onScrollButtonUp: function() { + clearInterval(this._holdJob); + this._holdJob = null; + }, + + _scrollToLeft: function() { + this.$.tabsContainer.scrollLeft -= this._step; + }, + + _scrollToRight: function() { + this.$.tabsContainer.scrollLeft += this._step; + }, + + _tabChanged: function(tab, old) { + if (!tab) { + this._positionBar(0, 0); + return; + } + + var r = this.$.tabsContent.getBoundingClientRect(); + var w = r.width; + var tabRect = tab.getBoundingClientRect(); + var tabOffsetLeft = tabRect.left - r.left; + + this._pos = { + width: this._calcPercent(tabRect.width, w), + left: this._calcPercent(tabOffsetLeft, w) + }; + + if (this.noSlide || old == null) { + // position bar directly without animation + this._positionBar(this._pos.width, this._pos.left); + return; + } + + var oldRect = old.getBoundingClientRect(); + var oldIndex = this.items.indexOf(old); + var index = this.items.indexOf(tab); + var m = 5; + + // bar animation: expand + this.$.selectionBar.classList.add('expand'); + + if (oldIndex < index) { + this._positionBar(this._calcPercent(tabRect.left + tabRect.width - oldRect.left, w) - m, + this._left); + } else { + this._positionBar(this._calcPercent(oldRect.left + oldRect.width - tabRect.left, w) - m, + this._calcPercent(tabOffsetLeft, w) + m); + } + + if (this.scrollable) { + this._scrollToSelectedIfNeeded(tabRect.width, tabOffsetLeft); + } + }, + + _scrollToSelectedIfNeeded: function(tabWidth, tabOffsetLeft) { + var l = tabOffsetLeft - this.$.tabsContainer.scrollLeft; + if (l < 0) { + this.$.tabsContainer.scrollLeft += l; + } else { + l += (tabWidth - this.$.tabsContainer.offsetWidth); + if (l > 0) { + this.$.tabsContainer.scrollLeft += l; + } + } + }, + + _calcPercent: function(w, w0) { + return 100 * w / w0; + }, + + _positionBar: function(width, left) { + this._width = width; + this._left = left; + this.transform( + 'translate3d(' + left + '%, 0, 0) scaleX(' + (width / 100) + ')', + this.$.selectionBar); + }, + + _onBarTransitionEnd: function(e) { + var cl = this.$.selectionBar.classList; + // bar animation: expand -> contract + if (cl.contains('expand')) { + cl.remove('expand'); + cl.add('contract'); + this._positionBar(this._pos.width, this._pos.left); + // bar animation done + } else if (cl.contains('contract')) { + cl.remove('contract'); + } + } + + }); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs-icons.html b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs-icons.html new file mode 100644 index 0000000..c299046 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs-icons.html @@ -0,0 +1,18 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> + +<iron-iconset-svg name="paper-tabs" size="24"> +<svg><defs> +<g id="chevron-left"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></g> +<g id="chevron-right"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs.html b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs.html new file mode 100644 index 0000000..b913b79 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-tabs/paper-tabs.html @@ -0,0 +1,193 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="../iron-menu-behavior/iron-menubar-behavior.html"> +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../paper-icon-button/paper-icon-button.html"> +<link rel="import" href="../paper-styles/color.html"> +<link rel="import" href="paper-tabs-icons.html"> +<link rel="import" href="paper-tab.html"> + +<!-- +`paper-tabs` makes it easy to explore and switch between different views or functional aspects of +an app, or to browse categorized data sets. + +Use `selected` property to get or set the selected tab. + +Example: + + <paper-tabs selected="0"> + <paper-tab>TAB 1</paper-tab> + <paper-tab>TAB 2</paper-tab> + <paper-tab>TAB 3</paper-tab> + </paper-tabs> + +See <a href="#paper-tab">paper-tab</a> for more information about +`paper-tab`. + +A common usage for `paper-tabs` is to use it along with `iron-pages` to switch +between different views. + + <paper-tabs selected="{{selected}}"> + <paper-tab>Tab 1</paper-tab> + <paper-tab>Tab 2</paper-tab> + <paper-tab>Tab 3</paper-tab> + </paper-tabs> + + <iron-pages selected="{{selected}}"> + <div>Page 1</div> + <div>Page 2</div> + <div>Page 3</div> + </iron-pages> + + +To use links in tabs, add `link` attribute to `paper-tab` and put an `<a>` +element in `paper-tab`. + +Example: + + <paper-tabs selected="0"> + <paper-tab link> + <a href="#link1" class="horizontal center-center layout">TAB ONE</a> + </paper-tab> + <paper-tab link> + <a href="#link2" class="horizontal center-center layout">TAB TWO</a> + </paper-tab> + <paper-tab link> + <a href="#link3" class="horizontal center-center layout">TAB THREE</a> + </paper-tab> + </paper-tabs> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-tabs-selection-bar-color` | Color for the selection bar | `--paper-yellow-a100` +`--paper-tabs` | Mixin applied to the tabs | `{}` + +@hero hero.svg +@demo demo/index.html +--> + +</head><body><dom-module id="paper-tabs"> + + <style> + + :host { + @apply(--layout); + @apply(--layout-center); + + height: 48px; + font-size: 14px; + font-weight: 500; + overflow: hidden; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + -webkit-tap-highlight-color: rgba(0,0,0,0); + + @apply(--paper-tabs); + } + + #tabsContainer { + position: relative; + height: 100%; + white-space: nowrap; + overflow: hidden; + } + + #tabsContent { + height: 100%; + } + + #tabsContent.scrollable { + position: absolute; + white-space: nowrap; + } + + .hidden { + display: none; + } + + .not-visible { + opacity: 0; + } + + paper-icon-button { + width: 24px; + padding: 16px; + } + + #selectionBar { + position: absolute; + height: 2px; + bottom: 0; + left: 0; + right: 0; + background-color: var(--paper-tabs-selection-bar-color, --paper-yellow-a100); + -webkit-transform-origin: left center; + transform-origin: left center; + -webkit-transform: scale(0); + transform: scale(0); + transition: -webkit-transform; + transition: transform; + + @apply(--paper-tabs-selection-bar); + } + + #selectionBar.align-bottom { + top: 0; + bottom: auto; + } + + #selectionBar.expand { + transition-duration: 0.15s; + transition-timing-function: cubic-bezier(0.4, 0.0, 1, 1); + } + + #selectionBar.contract { + transition-duration: 0.18s; + transition-timing-function: cubic-bezier(0.0, 0.0, 0.2, 1); + } + + #tabsContent > ::content > *:not(#selectionBar) { + height: 100%; + } + + </style> + + <template> + + <paper-icon-button icon="paper-tabs:chevron-left" class$="[[_computeScrollButtonClass(_leftHidden, scrollable, hideScrollButtons)]]" on-up="_onScrollButtonUp" on-down="_onLeftScrollButtonDown"></paper-icon-button> + + <div id="tabsContainer" class="flex" on-scroll="_scroll"> + + <div id="tabsContent" class$="[[_computeTabsContentClass(scrollable)]]"> + + <content select="*"></content> + + <div id="selectionBar" class$="[[_computeSelectionBarClass(noBar, alignBottom)]]" on-transitionend="_onBarTransitionEnd"></div> + + </div> + + </div> + + <paper-icon-button icon="paper-tabs:chevron-right" class$="[[_computeScrollButtonClass(_rightHidden, scrollable, hideScrollButtons)]]" on-up="_onScrollButtonUp" on-down="_onRightScrollButtonDown"></paper-icon-button> + + </template> + +</dom-module> + +<script src="paper-tabs-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-toast/.bower.json new file mode 100644 index 0000000..3c32c49d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/.bower.json @@ -0,0 +1,38 @@ +{ + "name": "paper-toast", + "version": "1.0.0", + "description": "A material design notification toast", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toast", + "notification" + ], + "main": "paper-toast.html", + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-announcer": "polymerelements/iron-a11y-announcer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-toast", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "71e6c327f7aafe9c71010c83d4c4571f63990072" + }, + "_source": "git://github.com/PolymerElements/paper-toast.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-toast" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-toast/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/README.md b/third_party/polymer/v1_0/components-chromium/paper-toast/README.md new file mode 100644 index 0000000..722ec35 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/README.md @@ -0,0 +1,4 @@ +paper-toast +============ + +A material design notification toast. diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/bower.json b/third_party/polymer/v1_0/components-chromium/paper-toast/bower.json new file mode 100644 index 0000000..a4fd51a --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/bower.json @@ -0,0 +1,28 @@ +{ + "name": "paper-toast", + "version": "1.0.0", + "description": "A material design notification toast", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toast", + "notification" + ], + "main": "paper-toast.html", + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-announcer": "polymerelements/iron-a11y-announcer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-toast/hero.svg new file mode 100644 index 0000000..bfdc180 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/hero.svg @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M164,114H13V88h151V114z M15,112h147V90H15V112z"/> + <rect x="26" y="100" width="79" height="2"/> + <rect x="135" y="100" width="16" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/index.html b/third_party/polymer/v1_0/components-chromium/paper-toast/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/paper-toast-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-toast/paper-toast-extracted.js new file mode 100644 index 0000000..999b6d70 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/paper-toast-extracted.js @@ -0,0 +1,89 @@ + +(function() { + + var PaperToast = Polymer({ + is: 'paper-toast', + + properties: { + /** + * The duration in milliseconds to show the toast. + */ + duration: { + type: Number, + value: 3000 + }, + + /** + * The text to display in the toast. + */ + text: { + type: String, + value: "" + }, + + /** + * True if the toast is currently visible. + */ + visible: { + type: Boolean, + readOnly: true, + value: false, + observer: '_visibleChanged' + } + }, + + created: function() { + Polymer.IronA11yAnnouncer.requestAvailability(); + }, + + ready: function() { + this.async(function() { + this.hide(); + }); + }, + + /** + * Show the toast. + * @method show + */ + show: function() { + if (PaperToast.currentToast) { + PaperToast.currentToast.hide(); + } + PaperToast.currentToast = this; + this.removeAttribute('aria-hidden'); + this._setVisible(true); + this.fire('iron-announce', { + text: this.text + }); + this.debounce('hide', this.hide, this.duration); + }, + + /** + * Hide the toast + */ + hide: function() { + this.setAttribute('aria-hidden', 'true'); + this._setVisible(false); + }, + + /** + * Toggle the opened state of the toast. + * @method toggle + */ + toggle: function() { + if (!this.visible) { + this.show(); + } else { + this.hide(); + } + }, + + _visibleChanged: function(visible) { + this.toggleClass('paper-toast-open', visible); + } + }); + + PaperToast.currentToast = null; + +})(); diff --git a/third_party/polymer/v1_0/components-chromium/paper-toast/paper-toast.html b/third_party/polymer/v1_0/components-chromium/paper-toast/paper-toast.html new file mode 100644 index 0000000..4c2e9c6 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toast/paper-toast.html @@ -0,0 +1,73 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/typography.html"> +<link rel="import" href="../iron-a11y-announcer/iron-a11y-announcer.html"> + +<!-- +`paper-toast` provides a subtle notification toast. + +@group Paper Elements +@element paper-toast +@demo demo/index.html +@hero hero.svg +--> +</head><body><dom-module id="paper-toast"> + <style> + :host { + display: inline-block; + position: fixed; + + background: #323232; + color: #f1f1f1; + min-height: 48px; + min-width: 288px; + padding: 16px 24px 12px; + box-sizing: border-box; + box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); + border-radius: 2px; + bottom: 12px; + left: 12px; + font-size: 14px; + cursor: default; + + -webkit-transition: visibility 0.3s, -webkit-transform 0.3s; + transition: visibility 0.3s, transform 0.3s; + + -webkit-transform: translateY(100px); + transform: translateY(100px); + + visibility: hidden; + } + + :host(.capsule) { + border-radius: 24px; + } + + :host(.fit-bottom) { + bottom: 0; + left: 0; + width: 100%; + min-width: 0; + border-radius: 0; + } + + :host(.paper-toast-open){ + visibility: visible; + + -webkit-transform: translateY(0px); + transform: translateY(0px); + } + </style> + <template> + <span id="label">{{text}}</span> + <content></content> + </template> +</dom-module> +<script src="paper-toast-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/.bower.json new file mode 100644 index 0000000..dae78ed --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-toggle-button", + "version": "1.0.1", + "description": "A material design toggle button control", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toggle", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toggle-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-toggle-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "577b045eea2d8e7623fcce40001a2d9e7008bd60" + }, + "_source": "git://github.com/PolymerElements/paper-toggle-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-toggle-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/README.md b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/README.md new file mode 100644 index 0000000..0924fe2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/README.md @@ -0,0 +1,26 @@ +paper-toggle-button +=================== + +`paper-toggle-button` provides a ON/OFF switch that user can toggle the state +by tapping or by dragging the swtich. + +Example: + +```html +<paper-toggle-button></paper-toggle-button> +``` + +Styling toggle-button: + +```html +<style is="custom-style"> + * { + --paper-toggle-button-unchecked-bar-color: #FF4081; + --paper-toggle-button-unchecked-button-color: #9c27b0; + --paper-toggle-button-unchecked-ink-color: #009688; + --paper-toggle-button-checked-bar-color: #5677fc; + --paper-toggle-button-checked-button-color: #ff4081; + --paper-toggle-button-checked-ink-color: #ff4081; + } +</style> +``` diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/bower.json b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/bower.json new file mode 100644 index 0000000..f7404f2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-toggle-button", + "version": "1.0.1", + "description": "A material design toggle button control", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toggle", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toggle-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-toggle-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/hero.svg b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/hero.svg new file mode 100644 index 0000000..21607b2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/hero.svg @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="123.8" cy="63" r="15.7"/> + <path d="M123,77H98.5c-7.7,0-14-6.3-14-14s6.3-14,14-14H123c7.7,0,14,6.3,14,14S130.7,77,123,77z M98.5,51c-6.6,0-12,5.4-12,12 + s5.4,12,12,12H123c6.6,0,12-5.4,12-12s-5.4-12-12-12H98.5z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/index.html b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button-extracted.js new file mode 100644 index 0000000..68a083c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button-extracted.js @@ -0,0 +1,114 @@ + + Polymer({ + is: 'paper-toggle-button', + + behaviors: [ + Polymer.PaperRadioButtonBehavior + ], + + hostAttributes: { + role: 'button', + 'aria-pressed': 'false', + tabindex: 0 + }, + + properties: { + /** + * Fired when the checked state changes due to user interaction. + * + * @event change + */ + /** + * Fired when the checked state changes. + * + * @event iron-change + */ + /** + * Gets or sets the state, `true` is checked and `false` is unchecked. + * + * @attribute checked + * @type boolean + * @default false + */ + checked: { + type: Boolean, + value: false, + reflectToAttribute: true, + notify: true, + observer: '_checkedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + * + * @attribute toggles + * @type boolean + * @default true + */ + toggles: { + type: Boolean, + value: true, + reflectToAttribute: true + } + }, + + listeners: { + track: '_ontrack' + }, + + ready: function() { + this._isReady = true; + }, + + // button-behavior hook + _buttonStateChanged: function() { + if (this.disabled) { + return; + } + if (this._isReady) { + this.checked = this.active; + } + }, + + _checkedChanged: function(checked) { + this.active = this.checked; + this.fire('iron-change'); + }, + + _ontrack: function(event) { + var track = event.detail; + if (track.state === 'start') { + this._trackStart(track); + } else if (track.state === 'track') { + this._trackMove(track); + } else if (track.state === 'end') { + this._trackEnd(track); + } + }, + + _trackStart: function(track) { + this._width = this.$.toggleBar.offsetWidth / 2; + /* + * keep an track-only check state to keep the dragging behavior smooth + * while toggling activations + */ + this._trackChecked = this.checked; + this.$.toggleButton.classList.add('dragging'); + }, + + _trackMove: function(track) { + var dx = track.dx; + this._x = Math.min(this._width, + Math.max(0, this._trackChecked ? this._width + dx : dx)); + this.translate3d(this._x + 'px', 0, 0, this.$.toggleButton); + this._userActivate(this._x > (this._width / 2)); + }, + + _trackEnd: function(track) { + this.$.toggleButton.classList.remove('dragging'); + this.transform('', this.$.toggleButton); + } + + }); +
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button.css b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button.css new file mode 100644 index 0000000..8eb9d2d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button.css @@ -0,0 +1,108 @@ +/* +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: inline-block; +} + +:host([disabled]) { + pointer-events: none; +} + +:host(:focus) { + outline:none; +} + +:host .toggle-bar { + background-color: var(--paper-toggle-button-unchecked-bar-color); +} + +:host .toggle-button { + background-color: var(--paper-toggle-button-unchecked-button-color); +} + +:host([checked]) .toggle-bar { + background-color: var(--paper-toggle-button-checked-bar-color); +} + +:host([checked]) .toggle-button { + background-color: var(--paper-toggle-button-checked-button-color); +} + +:host .toggle-ink { + color: var(--paper-toggle-button-unchecked-ink-color); +} + +:host([checked]) .toggle-ink { + color: var(--paper-toggle-button-checked-ink-color); +} + +/* ID selectors should not be overriden by users. */ + +#toggleContainer { + position: relative; + width: 36px; + height: 14px; +} + +#toggleBar { + position: absolute; + height: 100%; + width: 100%; + border-radius: 8px; + pointer-events: none; + opacity: 0.4; + transition: background-color linear .08s; +} + +:host([checked]) #toggleBar { + opacity: 0.5; +} + +:host([disabled]) #toggleBar { + background-color: #000; + opacity: 0.12; +} + +#toggleButton { + position: absolute; + top: -3px; + height: 20px; + width: 20px; + border-radius: 50%; + box-shadow: 0 1px 5px 0 rgba(0, 0, 0, 0.6); + transition: -webkit-transform linear .08s, background-color linear .08s; + transition: transform linear .08s, background-color linear .08s; + will-change: transform; +} + +#toggleButton.dragging { + -webkit-transition: none; + transition: none; +} + +:host([checked]) #toggleButton { + -webkit-transform: translate(16px, 0); + transform: translate(16px, 0); +} + +:host([disabled]) #toggleButton { + background-color: #bdbdbd; + opacity: 1; +} + +#ink { + position: absolute; + top: -14px; + left: -14px; + width: 48px; + height: 48px; + opacity: 0.5; +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button.html b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button.html new file mode 100644 index 0000000..dca8ed2 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toggle-button/paper-toggle-button.html @@ -0,0 +1,67 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> + +<!-- +`paper-toggle-button` provides a ON/OFF switch that user can toggle the state +by tapping or by dragging the switch. + +Example: + + <paper-toggle-button></paper-toggle-button> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-toggle-button-unchecked-bar-color` | Slider color when the input is not checked | `#000000` +`--paper-toggle-button-unchecked-button-color` | Button color when the input is not checked | `--paper-grey-50` +`--paper-toggle-button-unchecked-ink-color` | Selected/focus ripple color when the input is not checked | `--dark-primary-color` +`--paper-toggle-button-checked-bar-color` | Slider button color when the input is checked | `--google-green-500` +`--paper-toggle-button-checked-button-color` | Button color when the input is checked | `--google-green-500` +`--paper-toggle-button-checked-ink-color` | Selected/focus ripple color when the input is checked | `--google-green-500` + +@group Paper Elements +@element paper-toggle-button +@hero hero.svg +@demo demo/index.html +--> +<style is="custom-style"> + :root { + --paper-toggle-button-unchecked-bar-color: #000000; + --paper-toggle-button-unchecked-button-color: var(--paper-grey-50); + --paper-toggle-button-unchecked-ink-color: var(--dark-primary-color); + + --paper-toggle-button-checked-bar-color: var(--google-green-500); + --paper-toggle-button-checked-button-color: var(--google-green-500); + --paper-toggle-button-checked-ink-color: var(--google-green-500); + } +</style> + +</head><body><dom-module id="paper-toggle-button"> + + <link rel="import" type="css" href="paper-toggle-button.css"> + + <template> + + <div id="toggleContainer"> + <div id="toggleBar" class="toggle-bar"></div> + <div id="toggleButton" class="toggle-button"> + <paper-ripple id="ink" class="toggle-ink circle" recenters=""></paper-ripple> + </div> + </div> + + </template> + + </dom-module> +<script src="paper-toggle-button-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/.bower.json b/third_party/polymer/v1_0/components-chromium/paper-toolbar/.bower.json new file mode 100644 index 0000000..ac01bd5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-toolbar", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design toolbar that is easily customizable", + "private": true, + "main": [ + "paper-toolbar.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toolbar", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toolbar.git" + }, + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-toolbar", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "6d0a50375e529a5f750c3a30324d5de8a8824fd1" + }, + "_source": "git://github.com/PolymerElements/paper-toolbar.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-toolbar" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/.gitignore b/third_party/polymer/v1_0/components-chromium/paper-toolbar/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/README.md b/third_party/polymer/v1_0/components-chromium/paper-toolbar/README.md new file mode 100644 index 0000000..d9f7c05 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/README.md @@ -0,0 +1,51 @@ +paper-toolbar +============ + +`paper-toolbar` is a horizontal bar containing items that can be used for +label, navigation, search and actions. The items place inside the +`paper-toolbar` are projected into a `class="horizontal center layout"` container inside of +`paper-toolbar`'s Shadow DOM. You can use flex attributes to control the items' +sizing. + +Example: + +```html +<paper-toolbar> + <paper-icon-button icon="menu" on-tap="{{menuAction}}"></paper-icon-button> + <div title>Title</div> + <paper-icon-button icon="more" on-tap="{{moreAction}}"></paper-icon-button> +</paper-toolbar> +``` + +`paper-toolbar` has a standard height, but can made be taller by setting `tall` +class on the `paper-toolbar`. This will make the toolbar 3x the normal height. + +```html +<paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> +</paper-toolbar> +``` + +Apply `medium-tall` class to make the toolbar medium tall. This will make the +toolbar 2x the normal height. + +```html +<paper-toolbar class="medium-tall"> + <paper-icon-button icon="menu"></paper-icon-button> +</paper-toolbar> +``` + +When `tall`, items can pin to either the top (default), middle or bottom. Use +`middle` class for middle content and `bottom` class for bottom content. + +```html +<paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> + <div title class="middle">Middle Title</div> + <div title class="bottom">Bottom Title</div> +</paper-toolbar> +``` + +For `medium-tall` toolbar, the middle and bottom contents overlap and are +pinned to the bottom. But `middleJustify` and `bottomJustify` attributes are +still honored separately. diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/bower.json b/third_party/polymer/v1_0/components-chromium/paper-toolbar/bower.json new file mode 100644 index 0000000..3c26395 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/bower.json @@ -0,0 +1,35 @@ +{ + "name": "paper-toolbar", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design toolbar that is easily customizable", + "private": true, + "main": [ + "paper-toolbar.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toolbar", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toolbar.git" + }, + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/index.html b/third_party/polymer/v1_0/components-chromium/paper-toolbar/index.html new file mode 100644 index 0000000..6533b73 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/index.html @@ -0,0 +1,38 @@ +<!doctype html> +<!-- + @license + Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-toolbar</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + <style> + + body { + margin: 16px; + } + + </style> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar-extracted.js b/third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar-extracted.js new file mode 100644 index 0000000..1dc94c5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar-extracted.js @@ -0,0 +1,139 @@ + + + (function() { + + 'use strict'; + + function classNames(obj) { + var classNames = []; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key]) { + classNames.push(key); + } + } + + return classNames.join(' '); + } + + Polymer({ + + is: 'paper-toolbar', + + hostAttributes: { + 'role': 'toolbar' + }, + + properties: { + + /** + * Controls how the items are aligned horizontally when they are placed + * at the bottom. + * Options are `start`, `center`, `end`, `justified` and `around`. + * + * @attribute bottomJustify + * @type string + * @default '' + */ + bottomJustify: { + type: String, + value: '' + }, + + /** + * Controls how the items are aligned horizontally. + * Options are `start`, `center`, `end`, `justified` and `around`. + * + * @attribute justify + * @type string + * @default '' + */ + justify: { + type: String, + value: '' + }, + + /** + * Controls how the items are aligned horizontally when they are placed + * in the middle. + * Options are `start`, `center`, `end`, `justified` and `around`. + * + * @attribute middleJustify + * @type string + * @default '' + */ + middleJustify: { + type: String, + value: '' + } + + }, + + attached: function() { + this._observer = this._observe(this); + this._updateAriaLabelledBy(); + }, + + detached: function() { + if (this._observer) { + this._observer.disconnect(); + } + }, + + _observe: function(node) { + var observer = new MutationObserver(function() { + this._updateAriaLabelledBy(); + }.bind(this)); + observer.observe(node, { + childList: true, + subtree: true + }); + return observer; + }, + + _updateAriaLabelledBy: function() { + var labelledBy = []; + var contents = Polymer.dom(this.root).querySelectorAll('content'); + for (var content, index = 0; content = contents[index]; index++) { + var nodes = Polymer.dom(content).getDistributedNodes(); + for (var node, jndex = 0; node = nodes[jndex]; jndex++) { + if (node.hasAttribute && node.hasAttribute('title')) { + if (node.id) { + labelledBy.push(node.id); + } else { + var id = 'paper-toolbar-label-' + Math.floor(Math.random() * 10000); + node.id = id; + labelledBy.push(id); + } + } + } + } + if (labelledBy.length > 0) { + this.setAttribute('aria-labelledby', labelledBy.join(' ')); + } + }, + + _computeBarClassName: function(barJustify) { + var classObj = { + center: true, + horizontal: true, + layout: true, + 'toolbar-tools': true + }; + + // If a blank string or any falsy value is given, no other class name is + // added. + if (barJustify) { + var justifyClassName = (barJustify === 'justified') ? + barJustify : + barJustify + '-justified'; + + classObj[justifyClassName] = true; + } + + return classNames(classObj); + } + + }); + + }()); + diff --git a/third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar.html b/third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar.html new file mode 100644 index 0000000..88beb73 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar.html @@ -0,0 +1,234 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`paper-toolbar` is a horizontal bar containing items that can be used for +label, navigation, search and actions. The items place inside the +`paper-toolbar` are projected into a `class="horizontal center layout"` container inside of +`paper-toolbar`'s Shadow DOM. You can use flex attributes to control the items' +sizing. + +Example: + + <paper-toolbar> + <paper-icon-button icon="menu" on-tap="menuAction"></paper-icon-button> + <div title>Title</div> + <paper-icon-button icon="more" on-tap="moreAction"></paper-icon-button> + </paper-toolbar> + +`paper-toolbar` has a standard height, but can made be taller by setting `tall` +class on the `paper-toolbar`. This will make the toolbar 3x the normal height. + + <paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> + </paper-toolbar> + +Apply `medium-tall` class to make the toolbar medium tall. This will make the +toolbar 2x the normal height. + + <paper-toolbar class="medium-tall"> + <paper-icon-button icon="menu"></paper-icon-button> + </paper-toolbar> + +When `tall`, items can pin to either the top (default), middle or bottom. Use +`middle` class for middle content and `bottom` class for bottom content. + + <paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> + <div title class="middle">Middle Title</div> + <div title class="bottom">Bottom Title</div> + </paper-toolbar> + +For `medium-tall` toolbar, the middle and bottom contents overlap and are +pinned to the bottom. But `middleJustify` and `bottomJustify` attributes are +still honored separately. + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-toolbar-background` | Toolbar background color | `--default-primary-color` +`--paper-toolbar-color` | Toolbar foreground color | `--text-primary-color` +`--paper-toolbar` | Mixin applied to the toolbar | `{}` + +### Accessibility + +`<paper-toolbar>` has `role="toolbar"` by default. Any elements with the `title` attribute will +be used as the label of the toolbar via `aria-labelledby`. + +@demo demo/index.html +--> + +</head><body><dom-module id="paper-toolbar"> + + <style> + :host { + /* technical */ + display: block; + position: relative; + box-sizing: border-box; + -moz-box-sizing: border-box; + + /* size */ + height: 64px; + + background: var(--paper-toolbar-background, --default-primary-color); + color: var(--paper-toolbar-color, --text-primary-color); + + @apply(--paper-toolbar); + } + + :host(.animate) { + /* transition */ + transition: height 0.18s ease-in; + } + + :host(.medium-tall) { + height: 128px; + } + + :host(.tall) { + height: 192px; + } + + .toolbar-tools { + position: relative; + height: 64px; + padding: 0 16px; + pointer-events: none; + } + + /* + * TODO: Where should media query breakpoints live so they can be shared between elements? + */ + + @media (max-width: 639px) { + :host { + height: 56px; + } + + :host(.medium-tall) { + height: 112px; + } + + :host(.tall) { + height: 168px; + } + + .toolbar-tools { + height: 56px; + } + } + + #topBar { + position: relative; + z-index: 1; + } + + /* middle bar */ + #middleBar { + position: absolute; + top: 0; + right: 0; + left: 0; + z-index: 2; + } + + :host(.tall) #middleBar, + :host(.medium-tall) #middleBar { + -webkit-transform: translateY(100%); + transform: translateY(100%); + } + + /* bottom bar */ + #bottomBar { + position: absolute; + right: 0; + bottom: 0; + left: 0; + z-index: 1; + } + + /* + * make elements (e.g. buttons) respond to mouse/touch events + * + * `.toolbar-tools` disables touch events so multiple toolbars can stack and not + * absorb events. All children must have pointer events re-enabled to work as + * expected. + */ + .toolbar-tools > ::content > *:not([disabled]) { + pointer-events: auto; + } + + .toolbar-tools > ::content [title] { + @apply(--paper-font-title); + @apply(--layout-flex); + + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; + + /* + * Polymer/polymer/issues/1525 + * --paper-font-title defines a `font-weight` + * let's override its value, but we need `important!` + * because all mixins are resolved in rule's selector that has higher precedence + * than the current selector. + */ + font-weight: 400 !important; + } + + /** + * TODO: Refactor these selectors + * Work in progress. + */ + .toolbar-tools > ::content paper-icon-button[icon=menu] { + margin-left: -8px; + margin-right: 24px; + } + + .toolbar-tools > ::content paper-icon-button + paper-icon-button { + margin-right: -8px; + } + + .toolbar-tools > ::content > [title], + .toolbar-tools > ::content[select=".middle"] > [title], + .toolbar-tools > ::content[select=".bottom"] > [title] { + margin-left: 56px; + } + + .toolbar-tools > ::content > paper-icon-button + [title], + .toolbar-tools > ::content[select=".middle"] paper-icon-button + [title], + .toolbar-tools > ::content[select=".bottom"] paper-icon-button + [title] { + margin-left: 0; + } + </style> + + <template> + + <div id="topBar" class$="[[_computeBarClassName(justify)]]"> + <content select=":not(.middle):not(.bottom)"></content> + </div> + + <div id="middleBar" class$="[[_computeBarClassName(middleJustify)]]"> + <content select=".middle"></content> + </div> + + <div id="bottomBar" class$="[[_computeBarClassName(bottomJustify)]]"> + <content select=".bottom"></content> + </div> + + </template> + +</dom-module> + +<script src="paper-toolbar-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer-externs/.bower.json b/third_party/polymer/v1_0/components-chromium/polymer-externs/.bower.json new file mode 100644 index 0000000..3b1c1de --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer-externs/.bower.json @@ -0,0 +1,14 @@ +{ + "name": "polymer-externs", + "homepage": "https://github.com/PolymerLabs/polymer-externs", + "version": "1.0.0", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "1f2d54817701edfd0ded01e88ae0549e48efac49" + }, + "_source": "git://github.com/PolymerLabs/polymer-externs.git", + "_target": "~1.0.0", + "_originalSource": "PolymerLabs/polymer-externs" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer-externs/polymer.externs.js b/third_party/polymer/v1_0/components-chromium/polymer-externs/polymer.externs.js new file mode 100644 index 0000000..d07a15b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer-externs/polymer.externs.js @@ -0,0 +1,342 @@ +/** + * @fileoverview Closure compiler externs for the Polymer library. + * + * @externs + * @license + * Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + * This code may only be used under the BSD style license found at + * http://polymer.github.io/LICENSE.txt. The complete set of authors may be + * found at http://polymer.github.io/AUTHORS.txt. The complete set of + * contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt. Code + * distributed by Google as part of the polymer project is also subject to an + * additional IP rights grant found at http://polymer.github.io/PATENTS.txt. + */ + +/** + * @param {!{is: string}} descriptor The Polymer descriptor of the element. + * @see https://github.com/Polymer/polymer/blob/0.8-preview/PRIMER.md#custom-element-registration + */ +var Polymer = function(descriptor) {}; + + +/** @constructor @extends {HTMLElement} */ +var PolymerElement = function() {}; + +/** + * A mapping from ID to element in this Polymer Element's local DOM. + * @type {!Object} + */ +PolymerElement.prototype.$; + +/** + * True if the element has been attached to the DOM. + * @type {boolean} + */ +PolymerElement.prototype.isAttached; + +/** + * The root node of the element. + * @type {!Node} + */ +PolymerElement.prototype.root; + +/** + * Returns the first node in this element’s local DOM that matches selector. + * @param {string} selector + */ +PolymerElement.prototype.$$ = function(selector) {}; + +/** @type {string} The Custom element tag name. */ +PolymerElement.prototype.is; + +/** @type {string} The native element this element extends. */ +PolymerElement.prototype.extends; + +/** + * An array of objects whose properties get mixed in to this element. + * + * @type {!Array<!Object>|undefined} + */ +PolymerElement.prototype.mixins; + +/** + * A string-separated list of dependent properties that should result in a + * change function being called. These observers differ from single-property + * observers in that the change handler is called asynchronously. + * + * @type {!Object<string, string>|undefined} + */ +PolymerElement.prototype.observers; + +/** On create callback. */ +PolymerElement.prototype.created = function() {}; +/** On ready callback. */ +PolymerElement.prototype.ready = function() {}; +/** On attached to the DOM callback. */ +PolymerElement.prototype.attached = function() {}; +/** On detached from the DOM callback. */ +PolymerElement.prototype.detached = function() {}; + +/** + * Callback fired when an attribute on the element has been changed. + * + * @param {string} name The name of the attribute that changed. + */ +PolymerElement.prototype.attributeChanged = function(name) {}; + +/** @typedef {!{ + * type: !Function, + * reflectToAttribute: (boolean|undefined), + * readOnly: (boolean|undefined), + * notify: (boolean|undefined), + * value: *, + * computed: (string|undefined), + * observer: (string|undefined) + * }} */ +PolymerElement.PropertyConfig; + +/** @typedef {!Object<string, (!Function|!PolymerElement.PropertyConfig)>} */ +PolymerElement.Properties; + +/** @type {!PolymerElement.Properties} */ +PolymerElement.prototype.properties; + +/** @type {!Object<string, *>} */ +PolymerElement.prototype.hostAttributes; + +/** + * An object that maps events to event handler function names. + * @type {!Object<string, string>} + */ +PolymerElement.prototype.listeners; + +/** + * Notifies the event binding system of a change to a property. + * @param {string} path The path to set. + * @param {*} value The value to send in the update notification. + */ +PolymerElement.prototype.notifyPath = function(path, value) {}; + +/** + * Shorthand for setting a property, then calling notifyPath. + * @param {string} path The path to set. + * @param {*} value The new value. + */ +PolymerElement.prototype.setPathValue = function(path, value) {}; + +/** + * Fire an event. + * + * @param {string} type An event name. + * @param {Object=} detail + * @param {{ + * bubbles: (boolean|undefined), + * cancelable: (boolean|undefined), + * node: (!HTMLElement|undefined)}=} options + * @return {Object} event + */ +PolymerElement.prototype.fire = function(type, detail, options) {}; + +/** + * Toggles the named boolean class on the host element, adding the class if + * bool is truthy and removing it if bool is falsey. If node is specified, sets + * the class on node instead of the host element. + * @param {string} name + * @param {boolean} bool + * @param {HTMLElement=} node + */ +PolymerElement.prototype.toggleClass = function(name, bool, node) {}; + +/** + * Toggles the named boolean attribute on the host element, adding the attribute + * if bool is truthy and removing it if bool is falsey. If node is specified, + * sets the attribute on node instead of the host element. + * @param {string} name + * @param {boolean} bool + * @param {HTMLElement=} node + */ +PolymerElement.prototype.toggleAttribute = function(name, bool, node) {}; + +/** + * Moves a boolean attribute from oldNode to newNode, unsetting the attribute + * (if set) on oldNode and setting it on newNode. + * @param {string} name + * @param {!HTMLElement} newNode + * @param {!HTMLElement} oldNode + */ +PolymerElement.prototype.attributeFollows = function(name, newNode, oldNode) {}; + +/** + * @param {!Function} method + * @param {number=} wait + * @return {number} A handle which can be used to cancel the job. + */ +PolymerElement.prototype.async = function(method, wait) {}; + +/** + * @param {number} handle + */ +PolymerElement.prototype.cancelAsync = function(handle) {}; + +/** + * Call debounce to collapse multiple requests for a named task into one + * invocation, which is made after the wait time has elapsed with no new + * request. If no wait time is given, the callback is called at microtask timing + * (guaranteed to be before paint). + * @param {string} jobName + * @param {!Function} callback + * @param {number=} wait + */ +PolymerElement.prototype.debounce = function(jobName, callback, wait) {}; + +/** + * Cancels an active debouncer without calling the callback. + * @param {string} jobName + */ +PolymerElement.prototype.cancelDebouncer = function(jobName) {}; + +/** + * Calls the debounced callback immediately and cancels the debouncer. + * @param {string} jobName + */ +PolymerElement.prototype.flushDebouncer = function(jobName) {}; + +/** + * @param {string} jobName + * @return {boolean} True if the named debounce task is waiting to run. + */ +PolymerElement.prototype.isDebouncerActive = function(jobName) {}; + + +/** + * Applies a CSS transform to the specified node, or this element if no node is + * specified. transform is specified as a string. + * @param {string} transform + * @param {HTMLElement=} node + */ +PolymerElement.prototype.transform = function(transform, node) {}; + +/** + * Transforms the specified node, or this element if no node is specified. + * @param {string} x + * @param {string} y + * @param {string} z + * @param {HTMLElement=} node + */ +PolymerElement.prototype.translate3d = function(x, y, z, node) {}; + +/** + * Dynamically imports an HTML document. + * @param {string} href + * @param {Function=} onload + * @param {Function=} onerror + */ +PolymerElement.prototype.importHref = function(href, onload, onerror) {}; + +/** + * Delete an element from an array. + * @param {!Array} array + * @param {*} item + */ +PolymerElement.prototype.arrayDelete = function(array, item) {}; + +/** + * Resolve a url to make it relative to the current doc. + * @param {string} url + * @return {string} + */ +PolymerElement.prototype.resolveUrl = function(url) {}; + + +/** + * A Polymer DOM API for manipulating DOM such that local DOM and light DOM + * trees are properly maintained. + * + * @constructor + */ +var PolymerDomApi = function() {}; + +/** @param {!Node} node */ +PolymerDomApi.prototype.appendChild = function(node) {}; + +/** + * @param {!Node} node + * @param {!Node} beforeNode + */ +PolymerDomApi.prototype.insertBefore = function(node, beforeNode) {}; + +/** @param {!Node} node */ +PolymerDomApi.prototype.removeChild = function(node) {}; + +/** @type {!Array<!Node>} */ +PolymerDomApi.prototype.childNodes; + +/** @type {?Node} */ +PolymerDomApi.prototype.parentNode; + +/** @type {?Node} */ +PolymerDomApi.prototype.firstChild; + +/** @type {?Node} */ +PolymerDomApi.prototype.lastChild; + +/** @type {?HTMLElement} */ +PolymerDomApi.prototype.firstElementChild; + +/** @type {?HTMLElement} */ +PolymerDomApi.prototype.lastElementChild; + +/** @type {?Node} */ +PolymerDomApi.prototype.previousSibling; + +/** @type {?Node} */ +PolymerDomApi.prototype.nextSibling; + +/** @type {string} */ +PolymerDomApi.prototype.textContent; + +/** @type {string} */ +PolymerDomApi.prototype.innerHTML; + +/** + * @param {string} selector + * @return {?HTMLElement} + */ +PolymerDomApi.prototype.querySelector = function(selector) {}; + +/** + * @param {string} selector + * @return {!Array<?HTMLElement>} + */ +PolymerDomApi.prototype.querySelectorAll = function(selector) {}; + +/** @return {!Array<!Node>} */ +PolymerDomApi.prototype.getDistributedNodes = function() {}; + +/** @return {!Array<!Node>} */ +PolymerDomApi.prototype.getDestinationInsertionPoints = function() {}; + +/** + * @param {string} attribute + * @param {string|number|boolean} value Values are converted to strings with + * ToString, so we accept number and boolean since both convert easily to + * strings. + */ +PolymerDomApi.prototype.setAttribute = function(attribute, value) {}; + +/** @param {string} attribute */ +PolymerDomApi.prototype.removeAttribute = function(attribute) {}; + +/** @type {?DOMTokenList} */ +PolymerDomApi.prototype.classList; + +/** + * Returns a Polymer-friendly API for manipulating DOM of a specified node. + * + * @param {?Node} node + * @return {!PolymerDomApi} + */ +Polymer.dom = function(node) {}; + +Polymer.dom.flush = function() {}; + diff --git a/third_party/polymer/v1_0/components-chromium/polymer/.bower.json b/third_party/polymer/v1_0/components-chromium/polymer/.bower.json new file mode 100644 index 0000000..5ba173d --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "polymer", + "version": "1.0.2", + "main": [ + "polymer.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "/.*", + "/test/" + ], + "authors": [ + "The Polymer Authors (http://polymer.github.io/AUTHORS.txt)" + ], + "repository": { + "type": "git", + "url": "https://github.com/Polymer/polymer.git" + }, + "dependencies": { + "webcomponentsjs": "^0.7.2" + }, + "devDependencies": { + "web-component-tester": "*" + }, + "private": true, + "homepage": "https://github.com/Polymer/polymer", + "_release": "1.0.2", + "_resolution": { + "type": "version", + "tag": "v1.0.2", + "commit": "63f3bf1babfeaba5649345569b1bd9f3d61a88ae" + }, + "_source": "git://github.com/Polymer/polymer.git", + "_target": "~v1.0.0", + "_originalSource": "Polymer/polymer" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/LICENSE.txt b/third_party/polymer/v1_0/components-chromium/polymer/LICENSE.txt new file mode 100644 index 0000000..95987ba --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/LICENSE.txt @@ -0,0 +1,27 @@ +// Copyright (c) 2014 The Polymer Authors. All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/third_party/polymer/v1_0/components-chromium/polymer/bower.json b/third_party/polymer/v1_0/components-chromium/polymer/bower.json new file mode 100644 index 0000000..9c4f5c9 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/bower.json @@ -0,0 +1,26 @@ +{ + "name": "polymer", + "version": "1.0.2", + "main": [ + "polymer.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "/.*", + "/test/" + ], + "authors": [ + "The Polymer Authors (http://polymer.github.io/AUTHORS.txt)" + ], + "repository": { + "type": "git", + "url": "https://github.com/Polymer/polymer.git" + }, + "dependencies": { + "webcomponentsjs": "^0.7.2" + }, + "devDependencies": { + "web-component-tester": "*" + }, + "private": true +} diff --git a/third_party/polymer/v1_0/components-chromium/polymer/build.log b/third_party/polymer/v1_0/components-chromium/polymer/build.log new file mode 100644 index 0000000..736b31c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/build.log @@ -0,0 +1,26 @@ +BUILD LOG +--------- +Build Time: 2015-05-28T22:23:07-0700 + +NODEJS INFORMATION +================== +nodejs: v2.0.2 +del: 1.2.0 +gulp: 3.8.11 +gulp-audit: 1.0.0 +gulp-rename: 1.2.2 +gulp-replace: 0.5.3 +gulp-vulcanize: 6.0.0 +lazypipe: 0.2.3 +polyclean: 1.1.0 +run-sequence: 1.1.0 + +REPO REVISIONS +============== +polymer: 3b0d10b4da804703d493da7bd0b5c22fc6f7b173 + +BUILD HASHES +============ +polymer-mini.html: 6643b7ca3675fd7247fb1894a51435e0e1256e32 +polymer-micro.html: 9dda81fc6d99a1bc3c044543c4cad106042930a8 +polymer.html: f9f247c99df9ac2c7fb610aabfe3fcdcbbdbc9f9
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/polymer-extracted.js b/third_party/polymer/v1_0/components-chromium/polymer/polymer-extracted.js new file mode 100644 index 0000000..5f52247 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/polymer-extracted.js @@ -0,0 +1,3761 @@ +Polymer.nar = []; + +Polymer.Annotations = { +parseAnnotations: function(template) { +var list = []; +var content = template._content || template.content; +this._parseNodeAnnotations(content, list); +return list; +}, +_parseNodeAnnotations: function(node, list) { +return node.nodeType === Node.TEXT_NODE ? this._parseTextNodeAnnotation(node, list) : this._parseElementAnnotations(node, list); +}, +_testEscape: function(value) { +var escape = value.slice(0, 2); +if (escape === "{{" || escape === "[[") { +return escape; +} +}, +_parseTextNodeAnnotation: function(node, list) { +var v = node.textContent; +var escape = this._testEscape(v); +if (escape) { +node.textContent = " "; +var annote = { +bindings: [ { +kind: "text", +mode: escape[0], +value: v.slice(2, -2).trim() +} ] +}; +list.push(annote); +return annote; +} +}, +_parseElementAnnotations: function(element, list) { +var annote = { +bindings: [], +events: [] +}; +this._parseChildNodesAnnotations(element, annote, list); +if (element.attributes) { +this._parseNodeAttributeAnnotations(element, annote, list); +if (this.prepElement) { +this.prepElement(element); +} +} +if (annote.bindings.length || annote.events.length || annote.id) { +list.push(annote); +} +return annote; +}, +_parseChildNodesAnnotations: function(root, annote, list, callback) { +if (root.firstChild) { +for (var i = 0, node = root.firstChild; node; node = node.nextSibling, i++) { +if (node.localName === "template" && !node.hasAttribute("preserve-content")) { +this._parseTemplate(node, i, list, annote); +} +var childAnnotation = this._parseNodeAnnotations(node, list, callback); +if (childAnnotation) { +childAnnotation.parent = annote; +childAnnotation.index = i; +} +} +} +}, +_parseTemplate: function(node, index, list, parent) { +var content = document.createDocumentFragment(); +content._notes = this.parseAnnotations(node); +content.appendChild(node.content); +list.push({ +bindings: Polymer.nar, +events: Polymer.nar, +templateContent: content, +parent: parent, +index: index +}); +}, +_parseNodeAttributeAnnotations: function(node, annotation) { +for (var i = node.attributes.length - 1, a; a = node.attributes[i]; i--) { +var n = a.name, v = a.value; +if (n === "id" && !this._testEscape(v)) { +annotation.id = v; +} else if (n.slice(0, 3) === "on-") { +node.removeAttribute(n); +annotation.events.push({ +name: n.slice(3), +value: v +}); +} else { +var b = this._parseNodeAttributeAnnotation(node, n, v); +if (b) { +annotation.bindings.push(b); +} +} +} +}, +_parseNodeAttributeAnnotation: function(node, n, v) { +var escape = this._testEscape(v); +if (escape) { +var customEvent; +var name = n; +var mode = escape[0]; +v = v.slice(2, -2).trim(); +var not = false; +if (v[0] == "!") { +v = v.substring(1); +not = true; +} +var kind = "property"; +if (n[n.length - 1] == "$") { +name = n.slice(0, -1); +kind = "attribute"; +} +var notifyEvent, colon; +if (mode == "{" && (colon = v.indexOf("::")) > 0) { +notifyEvent = v.substring(colon + 2); +v = v.substring(0, colon); +customEvent = true; +} +if (node.localName == "input" && n == "value") { +node.setAttribute(n, ""); +} +node.removeAttribute(n); +if (kind === "property") { +name = Polymer.CaseMap.dashToCamelCase(name); +} +return { +kind: kind, +mode: mode, +name: name, +value: v, +negate: not, +event: notifyEvent, +customEvent: customEvent +}; +} +}, +_localSubTree: function(node, host) { +return node === host ? node.childNodes : node._lightChildren || node.childNodes; +}, +findAnnotatedNode: function(root, annote) { +var parent = annote.parent && Polymer.Annotations.findAnnotatedNode(root, annote.parent); +return !parent ? root : Polymer.Annotations._localSubTree(parent, root)[annote.index]; +} +}; + +(function() { +function resolveCss(cssText, ownerDocument) { +return cssText.replace(CSS_URL_RX, function(m, pre, url, post) { +return pre + "'" + resolve(url.replace(/["']/g, ""), ownerDocument) + "'" + post; +}); +} +function resolveAttrs(element, ownerDocument) { +for (var name in URL_ATTRS) { +var a$ = URL_ATTRS[name]; +for (var i = 0, l = a$.length, a, at, v; i < l && (a = a$[i]); i++) { +if (name === "*" || element.localName === name) { +at = element.attributes[a]; +v = at && at.value; +if (v && v.search(BINDING_RX) < 0) { +at.value = a === "style" ? resolveCss(v, ownerDocument) : resolve(v, ownerDocument); +} +} +} +} +} +function resolve(url, ownerDocument) { +var resolver = getUrlResolver(ownerDocument); +resolver.href = url; +return resolver.href || url; +} +var tempDoc; +var tempDocBase; +function resolveUrl(url, baseUri) { +if (!tempDoc) { +tempDoc = document.implementation.createHTMLDocument("temp"); +tempDocBase = tempDoc.createElement("base"); +tempDoc.head.appendChild(tempDocBase); +} +tempDocBase.href = baseUri; +return resolve(url, tempDoc); +} +function getUrlResolver(ownerDocument) { +return ownerDocument.__urlResolver || (ownerDocument.__urlResolver = ownerDocument.createElement("a")); +} +var CSS_URL_RX = /(url\()([^)]*)(\))/g; +var URL_ATTRS = { +"*": [ "href", "src", "style", "url" ], +form: [ "action" ] +}; +var BINDING_RX = /\{\{|\[\[/; +Polymer.ResolveUrl = { +resolveCss: resolveCss, +resolveAttrs: resolveAttrs, +resolveUrl: resolveUrl +}; +})(); + +Polymer.Base._addFeature({ +_prepAnnotations: function() { +if (!this._template) { +this._notes = []; +} else { +Polymer.Annotations.prepElement = this._prepElement.bind(this); +this._notes = Polymer.Annotations.parseAnnotations(this._template); +this._processAnnotations(this._notes); +Polymer.Annotations.prepElement = null; +} +}, +_processAnnotations: function(notes) { +for (var i = 0; i < notes.length; i++) { +var note = notes[i]; +for (var j = 0; j < note.bindings.length; j++) { +var b = note.bindings[j]; +b.signature = this._parseMethod(b.value); +if (!b.signature) { +b.model = this._modelForPath(b.value); +} +} +if (note.templateContent) { +this._processAnnotations(note.templateContent._notes); +var pp = note.templateContent._parentProps = this._discoverTemplateParentProps(note.templateContent._notes); +var bindings = []; +for (var prop in pp) { +bindings.push({ +index: note.index, +kind: "property", +mode: "{", +name: "_parent_" + prop, +model: prop, +value: prop +}); +} +note.bindings = note.bindings.concat(bindings); +} +} +}, +_discoverTemplateParentProps: function(notes) { +var pp = {}; +notes.forEach(function(n) { +n.bindings.forEach(function(b) { +if (b.signature) { +var args = b.signature.args; +for (var k = 0; k < args.length; k++) { +pp[args[k].model] = true; +} +} else { +pp[b.model] = true; +} +}); +if (n.templateContent) { +var tpp = n.templateContent._parentProps; +Polymer.Base.mixin(pp, tpp); +} +}); +return pp; +}, +_prepElement: function(element) { +Polymer.ResolveUrl.resolveAttrs(element, this._template.ownerDocument); +}, +_findAnnotatedNode: Polymer.Annotations.findAnnotatedNode, +_marshalAnnotationReferences: function() { +if (this._template) { +this._marshalIdNodes(); +this._marshalAnnotatedNodes(); +this._marshalAnnotatedListeners(); +} +}, +_configureAnnotationReferences: function() { +this._configureTemplateContent(); +}, +_configureTemplateContent: function() { +this._notes.forEach(function(note, i) { +if (note.templateContent) { +this._nodes[i]._content = note.templateContent; +} +}, this); +}, +_marshalIdNodes: function() { +this.$ = {}; +this._notes.forEach(function(a) { +if (a.id) { +this.$[a.id] = this._findAnnotatedNode(this.root, a); +} +}, this); +}, +_marshalAnnotatedNodes: function() { +if (this._nodes) { +this._nodes = this._nodes.map(function(a) { +return this._findAnnotatedNode(this.root, a); +}, this); +} +}, +_marshalAnnotatedListeners: function() { +this._notes.forEach(function(a) { +if (a.events && a.events.length) { +var node = this._findAnnotatedNode(this.root, a); +a.events.forEach(function(e) { +this.listen(node, e.name, e.value); +}, this); +} +}, this); +} +}); + +Polymer.Base._addFeature({ +listeners: {}, +_listenListeners: function(listeners) { +var node, name, key; +for (key in listeners) { +if (key.indexOf(".") < 0) { +node = this; +name = key; +} else { +name = key.split("."); +node = this.$[name[0]]; +name = name[1]; +} +this.listen(node, name, listeners[key]); +} +}, +listen: function(node, eventName, methodName) { +this._listen(node, eventName, this._createEventHandler(node, eventName, methodName)); +}, +_createEventHandler: function(node, eventName, methodName) { +var host = this; +return function(e) { +if (host[methodName]) { +host[methodName](e, e.detail); +} else { +host._warn(host._logf("_createEventHandler", "listener method `" + methodName + "` not defined")); +} +}; +}, +_listen: function(node, eventName, handler) { +node.addEventListener(eventName, handler); +} +}); + +(function() { +"use strict"; +var HAS_NATIVE_TA = typeof document.head.style.touchAction === "string"; +var GESTURE_KEY = "__polymerGestures"; +var HANDLED_OBJ = "__polymerGesturesHandled"; +var TOUCH_ACTION = "__polymerGesturesTouchAction"; +var TAP_DISTANCE = 25; +var TRACK_DISTANCE = 5; +var TRACK_LENGTH = 2; +var MOUSE_TIMEOUT = 2500; +var MOUSE_EVENTS = [ "mousedown", "mousemove", "mouseup", "click" ]; +var mouseCanceller = function(mouseEvent) { +mouseEvent[HANDLED_OBJ] = { +skip: true +}; +if (mouseEvent.type === "click") { +var path = Polymer.dom(mouseEvent).path; +for (var i = 0; i < path.length; i++) { +if (path[i] === POINTERSTATE.mouse.target) { +return; +} +} +mouseEvent.preventDefault(); +mouseEvent.stopPropagation(); +} +}; +function setupTeardownMouseCanceller(setup) { +for (var i = 0, en; i < MOUSE_EVENTS.length; i++) { +en = MOUSE_EVENTS[i]; +if (setup) { +document.addEventListener(en, mouseCanceller, true); +} else { +document.removeEventListener(en, mouseCanceller, true); +} +} +} +function ignoreMouse() { +if (!POINTERSTATE.mouse.mouseIgnoreJob) { +setupTeardownMouseCanceller(true); +} +var unset = function() { +setupTeardownMouseCanceller(); +POINTERSTATE.mouse.target = null; +POINTERSTATE.mouse.mouseIgnoreJob = null; +}; +POINTERSTATE.mouse.mouseIgnoreJob = Polymer.Debounce(POINTERSTATE.mouse.mouseIgnoreJob, unset, MOUSE_TIMEOUT); +} +var POINTERSTATE = { +tapPrevented: false, +mouse: { +target: null, +mouseIgnoreJob: null +}, +touch: { +x: 0, +y: 0, +id: -1, +scrollDecided: false +} +}; +function firstTouchAction(ev) { +var path = Polymer.dom(ev).path; +var ta = "auto"; +for (var i = 0, n; i < path.length; i++) { +n = path[i]; +if (n[TOUCH_ACTION]) { +ta = n[TOUCH_ACTION]; +break; +} +} +return ta; +} +var Gestures = { +gestures: {}, +recognizers: [], +deepTargetFind: function(x, y) { +var node = document.elementFromPoint(x, y); +var next = node; +while (next && next.shadowRoot) { +next = next.shadowRoot.elementFromPoint(x, y); +if (next) { +node = next; +} +} +return node; +}, +handleNative: function(ev) { +var handled; +var type = ev.type; +var node = ev.currentTarget; +var gobj = node[GESTURE_KEY]; +var gs = gobj[type]; +if (!gs) { +return; +} +if (!ev[HANDLED_OBJ]) { +ev[HANDLED_OBJ] = {}; +if (type.slice(0, 5) === "touch") { +var t = ev.changedTouches[0]; +if (type === "touchstart") { +if (ev.touches.length === 1) { +POINTERSTATE.touch.id = t.identifier; +} +} +if (POINTERSTATE.touch.id !== t.identifier) { +return; +} +if (!HAS_NATIVE_TA) { +if (type === "touchstart" || type === "touchmove") { +Gestures.handleTouchAction(ev); +} +} +if (type === "touchend") { +POINTERSTATE.mouse.target = Polymer.dom(ev).rootTarget; +ignoreMouse(true); +} +} +} +handled = ev[HANDLED_OBJ]; +if (handled.skip) { +return; +} +var recognizers = Gestures.recognizers; +for (var i = 0, r; i < recognizers.length; i++) { +r = recognizers[i]; +if (gs[r.name] && !handled[r.name]) { +handled[r.name] = true; +r[type](ev); +} +} +}, +handleTouchAction: function(ev) { +var t = ev.changedTouches[0]; +var type = ev.type; +if (type === "touchstart") { +POINTERSTATE.touch.x = t.clientX; +POINTERSTATE.touch.y = t.clientY; +POINTERSTATE.touch.scrollDecided = false; +} else if (type === "touchmove") { +if (POINTERSTATE.touch.scrollDecided) { +return; +} +POINTERSTATE.touch.scrollDecided = true; +var ta = firstTouchAction(ev); +var prevent = false; +var dx = Math.abs(POINTERSTATE.touch.x - t.clientX); +var dy = Math.abs(POINTERSTATE.touch.y - t.clientY); +if (!ev.cancelable) {} else if (ta === "none") { +prevent = true; +} else if (ta === "pan-x") { +prevent = dy > dx; +} else if (ta === "pan-y") { +prevent = dx > dy; +} +if (prevent) { +ev.preventDefault(); +} +} +}, +add: function(node, evType, handler) { +var recognizer = this.gestures[evType]; +var deps = recognizer.deps; +var name = recognizer.name; +var gobj = node[GESTURE_KEY]; +if (!gobj) { +node[GESTURE_KEY] = gobj = {}; +} +for (var i = 0, dep, gd; i < deps.length; i++) { +dep = deps[i]; +gd = gobj[dep]; +if (!gd) { +gobj[dep] = gd = {}; +node.addEventListener(dep, this.handleNative); +} +gd[name] = (gd[name] || 0) + 1; +} +node.addEventListener(evType, handler); +if (recognizer.touchAction) { +this.setTouchAction(node, recognizer.touchAction); +} +}, +register: function(recog) { +this.recognizers.push(recog); +for (var i = 0; i < recog.emits.length; i++) { +this.gestures[recog.emits[i]] = recog; +} +}, +setTouchAction: function(node, value) { +if (HAS_NATIVE_TA) { +node.style.touchAction = value; +} +node[TOUCH_ACTION] = value; +}, +fire: function(target, type, detail) { +var ev = new CustomEvent(type, { +detail: detail, +bubbles: true, +cancelable: true +}); +target.dispatchEvent(ev); +} +}; +Gestures.register({ +name: "downup", +deps: [ "mousedown", "touchstart", "touchend" ], +emits: [ "down", "up" ], +mousedown: function(e) { +var t = e.currentTarget; +var self = this; +var upfn = function upfn(e) { +self.fire("up", t, e); +document.removeEventListener("mouseup", upfn); +}; +document.addEventListener("mouseup", upfn); +this.fire("down", t, e); +}, +touchstart: function(e) { +this.fire("down", e.currentTarget, e.changedTouches[0]); +}, +touchend: function(e) { +this.fire("up", e.currentTarget, e.changedTouches[0]); +}, +fire: function(type, target, event) { +Gestures.fire(target, type, { +x: event.clientX, +y: event.clientY, +sourceEvent: event +}); +} +}); +Gestures.register({ +name: "track", +touchAction: "none", +deps: [ "mousedown", "touchstart", "touchmove", "touchend" ], +emits: [ "track" ], +info: { +x: 0, +y: 0, +state: "start", +started: false, +moves: [], +addMove: function(move) { +if (this.moves.length > TRACK_LENGTH) { +this.moves.shift(); +} +this.moves.push(move); +} +}, +clearInfo: function() { +this.info.state = "start"; +this.info.started = false; +this.info.moves = []; +this.info.x = 0; +this.info.y = 0; +}, +hasMovedEnough: function(x, y) { +if (this.info.started) { +return true; +} +var dx = Math.abs(this.info.x - x); +var dy = Math.abs(this.info.y - y); +return dx >= TRACK_DISTANCE || dy >= TRACK_DISTANCE; +}, +mousedown: function(e) { +var t = e.currentTarget; +var self = this; +var movefn = function movefn(e) { +var x = e.clientX, y = e.clientY; +if (self.hasMovedEnough(x, y)) { +self.info.state = self.info.started ? e.type === "mouseup" ? "end" : "track" : "start"; +self.info.addMove({ +x: x, +y: y +}); +self.fire(t, e); +e.preventDefault(); +self.info.started = true; +} +}; +var upfn = function upfn(e) { +if (self.info.started) { +POINTERSTATE.tapPrevented = true; +movefn(e); +} +self.clearInfo(); +document.removeEventListener("mousemove", movefn); +document.removeEventListener("mouseup", upfn); +}; +document.addEventListener("mousemove", movefn); +document.addEventListener("mouseup", upfn); +this.info.x = e.clientX; +this.info.y = e.clientY; +}, +touchstart: function(e) { +var ct = e.changedTouches[0]; +this.info.x = ct.clientX; +this.info.y = ct.clientY; +}, +touchmove: function(e) { +var t = e.currentTarget; +var ct = e.changedTouches[0]; +var x = ct.clientX, y = ct.clientY; +if (this.hasMovedEnough(x, y)) { +this.info.addMove({ +x: x, +y: y +}); +this.fire(t, ct); +this.info.state = "track"; +this.info.started = true; +} +}, +touchend: function(e) { +var t = e.currentTarget; +var ct = e.changedTouches[0]; +if (this.info.started) { +POINTERSTATE.tapPrevented = true; +this.info.state = "end"; +this.info.addMove({ +x: ct.clientX, +y: ct.clientY +}); +this.fire(t, ct); +} +this.clearInfo(); +}, +fire: function(target, touch) { +var secondlast = this.info.moves[this.info.moves.length - 2]; +var lastmove = this.info.moves[this.info.moves.length - 1]; +var dx = lastmove.x - this.info.x; +var dy = lastmove.y - this.info.y; +var ddx, ddy = 0; +if (secondlast) { +ddx = lastmove.x - secondlast.x; +ddy = lastmove.y - secondlast.y; +} +return Gestures.fire(target, "track", { +state: this.info.state, +x: touch.clientX, +y: touch.clientY, +dx: dx, +dy: dy, +ddx: ddx, +ddy: ddy, +sourceEvent: touch, +hover: function() { +return Gestures.deepTargetFind(touch.clientX, touch.clientY); +} +}); +} +}); +Gestures.register({ +name: "tap", +deps: [ "mousedown", "click", "touchstart", "touchend" ], +emits: [ "tap" ], +start: { +x: NaN, +y: NaN +}, +reset: function() { +this.start.x = NaN; +this.start.y = NaN; +}, +save: function(e) { +this.start.x = e.clientX; +this.start.y = e.clientY; +}, +mousedown: function(e) { +POINTERSTATE.tapPrevented = false; +this.save(e); +}, +click: function(e) { +this.forward(e); +}, +touchstart: function(e) { +POINTERSTATE.tapPrevented = false; +this.save(e.changedTouches[0]); +}, +touchend: function(e) { +this.forward(e.changedTouches[0]); +}, +forward: function(e) { +var dx = Math.abs(e.clientX - this.start.x); +var dy = Math.abs(e.clientY - this.start.y); +if (isNaN(dx) || isNaN(dy) || dx <= TAP_DISTANCE && dy <= TAP_DISTANCE) { +if (!POINTERSTATE.tapPrevented) { +Gestures.fire(e.target, "tap", { +x: e.clientX, +y: e.clientY, +sourceEvent: e +}); +} +} +this.reset(); +} +}); +var DIRECTION_MAP = { +x: "pan-x", +y: "pan-y", +none: "none", +all: "auto" +}; +Polymer.Base._addFeature({ +_listen: function(node, eventName, handler) { +if (Gestures.gestures[eventName]) { +Gestures.add(node, eventName, handler); +} else { +node.addEventListener(eventName, handler); +} +}, +setScrollDirection: function(direction, node) { +node = node || this; +Gestures.setTouchAction(node, DIRECTION_MAP[direction] || "auto"); +} +}); +Polymer.Gestures = Gestures; +})(); + +Polymer.Async = function() { +var currVal = 0; +var lastVal = 0; +var callbacks = []; +var twiddle = document.createTextNode(""); +function runAsync(callback, waitTime) { +if (waitTime > 0) { +return ~setTimeout(callback, waitTime); +} else { +twiddle.textContent = currVal++; +callbacks.push(callback); +return currVal - 1; +} +} +function cancelAsync(handle) { +if (handle < 0) { +clearTimeout(~handle); +} else { +var idx = handle - lastVal; +if (idx >= 0) { +if (!callbacks[idx]) { +throw "invalid async handle: " + handle; +} +callbacks[idx] = null; +} +} +} +function atEndOfMicrotask() { +var len = callbacks.length; +for (var i = 0; i < len; i++) { +var cb = callbacks[i]; +if (cb) { +cb(); +} +} +callbacks.splice(0, len); +lastVal += len; +} +new (window.MutationObserver || JsMutationObserver)(atEndOfMicrotask).observe(twiddle, { +characterData: true +}); +return { +run: runAsync, +cancel: cancelAsync +}; +}(); + +Polymer.Debounce = function() { +var Async = Polymer.Async; +var Debouncer = function(context) { +this.context = context; +this.boundComplete = this.complete.bind(this); +}; +Debouncer.prototype = { +go: function(callback, wait) { +var h; +this.finish = function() { +Async.cancel(h); +}; +h = Async.run(this.boundComplete, wait); +this.callback = callback; +}, +stop: function() { +if (this.finish) { +this.finish(); +this.finish = null; +} +}, +complete: function() { +if (this.finish) { +this.stop(); +this.callback.call(this.context); +} +} +}; +function debounce(debouncer, callback, wait) { +if (debouncer) { +debouncer.stop(); +} else { +debouncer = new Debouncer(this); +} +debouncer.go(callback, wait); +return debouncer; +} +return debounce; +}(); + +Polymer.Base._addFeature({ +$$: function(slctr) { +return Polymer.dom(this.root).querySelector(slctr); +}, +toggleClass: function(name, bool, node) { +node = node || this; +if (arguments.length == 1) { +bool = !node.classList.contains(name); +} +if (bool) { +Polymer.dom(node).classList.add(name); +} else { +Polymer.dom(node).classList.remove(name); +} +}, +toggleAttribute: function(name, bool, node) { +node = node || this; +if (arguments.length == 1) { +bool = !node.hasAttribute(name); +} +if (bool) { +Polymer.dom(node).setAttribute(name, ""); +} else { +Polymer.dom(node).removeAttribute(name); +} +}, +classFollows: function(name, toElement, fromElement) { +if (fromElement) { +Polymer.dom(fromElement).classList.remove(name); +} +if (toElement) { +Polymer.dom(toElement).classList.add(name); +} +}, +attributeFollows: function(name, toElement, fromElement) { +if (fromElement) { +Polymer.dom(fromElement).removeAttribute(name); +} +if (toElement) { +Polymer.dom(toElement).setAttribute(name, ""); +} +}, +getContentChildNodes: function(slctr) { +return Polymer.dom(Polymer.dom(this.root).querySelector(slctr || "content")).getDistributedNodes(); +}, +getContentChildren: function(slctr) { +return this.getContentChildNodes(slctr).filter(function(n) { +return n.nodeType === Node.ELEMENT_NODE; +}); +}, +fire: function(type, detail, options) { +options = options || Polymer.nob; +var node = options.node || this; +var detail = detail === null || detail === undefined ? Polymer.nob : detail; +var bubbles = options.bubbles === undefined ? true : options.bubbles; +var event = new CustomEvent(type, { +bubbles: Boolean(bubbles), +cancelable: Boolean(options.cancelable), +detail: detail +}); +node.dispatchEvent(event); +return event; +}, +async: function(callback, waitTime) { +return Polymer.Async.run(callback.bind(this), waitTime); +}, +cancelAsync: function(handle) { +Polymer.Async.cancel(handle); +}, +arrayDelete: function(path, item) { +var index; +if (Array.isArray(path)) { +index = path.indexOf(item); +if (index >= 0) { +return path.splice(index, 1); +} +} else { +var arr = this.get(path); +index = arr.indexOf(item); +if (index >= 0) { +return this.splice(path, index, 1); +} +} +}, +transform: function(transform, node) { +node = node || this; +node.style.webkitTransform = transform; +node.style.transform = transform; +}, +translate3d: function(x, y, z, node) { +node = node || this; +this.transform("translate3d(" + x + "," + y + "," + z + ")", node); +}, +importHref: function(href, onload, onerror) { +var l = document.createElement("link"); +l.rel = "import"; +l.href = href; +if (onload) { +l.onload = onload.bind(this); +} +if (onerror) { +l.onerror = onerror.bind(this); +} +document.head.appendChild(l); +return l; +}, +create: function(tag, props) { +var elt = document.createElement(tag); +if (props) { +for (var n in props) { +elt[n] = props[n]; +} +} +return elt; +}, +mixin: function(target, source) { +for (var i in source) { +target[i] = source[i]; +} +} +}); + +Polymer.Bind = { +prepareModel: function(model) { +model._propertyEffects = {}; +model._bindListeners = []; +var api = this._modelApi; +for (var n in api) { +model[n] = api[n]; +} +}, +_modelApi: { +_notifyChange: function(property) { +var eventName = Polymer.CaseMap.camelToDashCase(property) + "-changed"; +this.fire(eventName, { +value: this[property] +}, { +bubbles: false +}); +}, +_propertySet: function(property, value, effects) { +var old = this.__data__[property]; +if (old !== value) { +this.__data__[property] = value; +if (typeof value == "object") { +this._clearPath(property); +} +if (this._propertyChanged) { +this._propertyChanged(property, value, old); +} +if (effects) { +this._effectEffects(property, value, effects, old); +} +} +return old; +}, +_effectEffects: function(property, value, effects, old) { +effects.forEach(function(fx) { +var fn = Polymer.Bind["_" + fx.kind + "Effect"]; +if (fn) { +fn.call(this, property, value, fx.effect, old); +} +}, this); +}, +_clearPath: function(path) { +for (var prop in this.__data__) { +if (prop.indexOf(path + ".") === 0) { +this.__data__[prop] = undefined; +} +} +} +}, +ensurePropertyEffects: function(model, property) { +var fx = model._propertyEffects[property]; +if (!fx) { +fx = model._propertyEffects[property] = []; +} +return fx; +}, +addPropertyEffect: function(model, property, kind, effect) { +var fx = this.ensurePropertyEffects(model, property); +fx.push({ +kind: kind, +effect: effect +}); +}, +createBindings: function(model) { +var fx$ = model._propertyEffects; +if (fx$) { +for (var n in fx$) { +var fx = fx$[n]; +fx.sort(this._sortPropertyEffects); +this._createAccessors(model, n, fx); +} +} +}, +_sortPropertyEffects: function() { +var EFFECT_ORDER = { +compute: 0, +annotation: 1, +computedAnnotation: 2, +reflect: 3, +notify: 4, +observer: 5, +complexObserver: 6, +"function": 7 +}; +return function(a, b) { +return EFFECT_ORDER[a.kind] - EFFECT_ORDER[b.kind]; +}; +}(), +_createAccessors: function(model, property, effects) { +var defun = { +get: function() { +return this.__data__[property]; +} +}; +var setter = function(value) { +this._propertySet(property, value, effects); +}; +if (model.getPropertyInfo && model.getPropertyInfo(property).readOnly) { +model["_set" + this.upper(property)] = setter; +} else { +defun.set = setter; +} +Object.defineProperty(model, property, defun); +}, +upper: function(name) { +return name[0].toUpperCase() + name.substring(1); +}, +_addAnnotatedListener: function(model, index, property, path, event) { +var fn = this._notedListenerFactory(property, path, this._isStructured(path), this._isEventBogus); +var eventName = event || Polymer.CaseMap.camelToDashCase(property) + "-changed"; +model._bindListeners.push({ +index: index, +property: property, +path: path, +changedFn: fn, +event: eventName +}); +}, +_isStructured: function(path) { +return path.indexOf(".") > 0; +}, +_isEventBogus: function(e, target) { +return e.path && e.path[0] !== target; +}, +_notedListenerFactory: function(property, path, isStructured, bogusTest) { +return function(e, target) { +if (!bogusTest(e, target)) { +if (e.detail && e.detail.path) { +this.notifyPath(this._fixPath(path, property, e.detail.path), e.detail.value); +} else { +var value = target[property]; +if (!isStructured) { +this[path] = target[property]; +} else { +if (this.__data__[path] != value) { +this.set(path, value); +} +} +} +} +}; +}, +prepareInstance: function(inst) { +inst.__data__ = Object.create(null); +}, +setupBindListeners: function(inst) { +inst._bindListeners.forEach(function(info) { +var node = inst._nodes[info.index]; +node.addEventListener(info.event, inst._notifyListener.bind(inst, info.changedFn)); +}); +} +}; + +Polymer.Base.extend(Polymer.Bind, { +_shouldAddListener: function(effect) { +return effect.name && effect.mode === "{" && !effect.negate && effect.kind != "attribute"; +}, +_annotationEffect: function(source, value, effect) { +if (source != effect.value) { +value = this.get(effect.value); +this.__data__[effect.value] = value; +} +var calc = effect.negate ? !value : value; +if (!effect.customEvent || this._nodes[effect.index][effect.name] !== calc) { +return this._applyEffectValue(calc, effect); +} +}, +_reflectEffect: function(source) { +this.reflectPropertyToAttribute(source); +}, +_notifyEffect: function(source) { +this._notifyChange(source); +}, +_functionEffect: function(source, value, fn, old) { +fn.call(this, source, value, old); +}, +_observerEffect: function(source, value, effect, old) { +var fn = this[effect.method]; +if (fn) { +fn.call(this, value, old); +} else { +this._warn(this._logf("_observerEffect", "observer method `" + effect.method + "` not defined")); +} +}, +_complexObserverEffect: function(source, value, effect) { +var fn = this[effect.method]; +if (fn) { +var args = Polymer.Bind._marshalArgs(this.__data__, effect, source, value); +if (args) { +fn.apply(this, args); +} +} else { +this._warn(this._logf("_complexObserverEffect", "observer method `" + effect.method + "` not defined")); +} +}, +_computeEffect: function(source, value, effect) { +var args = Polymer.Bind._marshalArgs(this.__data__, effect, source, value); +if (args) { +var fn = this[effect.method]; +if (fn) { +this[effect.property] = fn.apply(this, args); +} else { +this._warn(this._logf("_computeEffect", "compute method `" + effect.method + "` not defined")); +} +} +}, +_annotatedComputationEffect: function(source, value, effect) { +var computedHost = this._rootDataHost || this; +var fn = computedHost[effect.method]; +if (fn) { +var args = Polymer.Bind._marshalArgs(this.__data__, effect, source, value); +if (args) { +var computedvalue = fn.apply(computedHost, args); +if (effect.negate) { +computedvalue = !computedvalue; +} +this._applyEffectValue(computedvalue, effect); +} +} else { +computedHost._warn(computedHost._logf("_annotatedComputationEffect", "compute method `" + effect.method + "` not defined")); +} +}, +_marshalArgs: function(model, effect, path, value) { +var values = []; +var args = effect.args; +for (var i = 0, l = args.length; i < l; i++) { +var arg = args[i]; +var name = arg.name; +if (arg.literal) { +v = arg.value; +} else if (arg.structured) { +v = Polymer.Base.get(name, model); +} else { +v = model[name]; +} +if (args.length > 1 && v === undefined) { +return; +} +if (arg.wildcard) { +var baseChanged = name.indexOf(path + ".") === 0; +var matches = effect.trigger.name.indexOf(name) === 0 && !baseChanged; +values[i] = { +path: matches ? path : name, +value: matches ? value : v, +base: v +}; +} else { +values[i] = v; +} +} +return values; +} +}); + +Polymer.Base._addFeature({ +_addPropertyEffect: function(property, kind, effect) { +Polymer.Bind.addPropertyEffect(this, property, kind, effect); +}, +_prepEffects: function() { +Polymer.Bind.prepareModel(this); +this._addAnnotationEffects(this._notes); +}, +_prepBindings: function() { +Polymer.Bind.createBindings(this); +}, +_addPropertyEffects: function(properties) { +if (properties) { +for (var p in properties) { +var prop = properties[p]; +if (prop.observer) { +this._addObserverEffect(p, prop.observer); +} +if (prop.computed) { +this._addComputedEffect(p, prop.computed); +} +if (prop.notify) { +this._addPropertyEffect(p, "notify"); +} +if (prop.reflectToAttribute) { +this._addPropertyEffect(p, "reflect"); +} +if (prop.readOnly) { +Polymer.Bind.ensurePropertyEffects(this, p); +} +} +} +}, +_addComputedEffect: function(name, expression) { +var sig = this._parseMethod(expression); +sig.args.forEach(function(arg) { +this._addPropertyEffect(arg.model, "compute", { +method: sig.method, +args: sig.args, +trigger: arg, +property: name +}); +}, this); +}, +_addObserverEffect: function(property, observer) { +this._addPropertyEffect(property, "observer", { +method: observer, +property: property +}); +}, +_addComplexObserverEffects: function(observers) { +if (observers) { +observers.forEach(function(observer) { +this._addComplexObserverEffect(observer); +}, this); +} +}, +_addComplexObserverEffect: function(observer) { +var sig = this._parseMethod(observer); +sig.args.forEach(function(arg) { +this._addPropertyEffect(arg.model, "complexObserver", { +method: sig.method, +args: sig.args, +trigger: arg +}); +}, this); +}, +_addAnnotationEffects: function(notes) { +this._nodes = []; +notes.forEach(function(note) { +var index = this._nodes.push(note) - 1; +note.bindings.forEach(function(binding) { +this._addAnnotationEffect(binding, index); +}, this); +}, this); +}, +_addAnnotationEffect: function(note, index) { +if (Polymer.Bind._shouldAddListener(note)) { +Polymer.Bind._addAnnotatedListener(this, index, note.name, note.value, note.event); +} +if (note.signature) { +this._addAnnotatedComputationEffect(note, index); +} else { +note.index = index; +this._addPropertyEffect(note.model, "annotation", note); +} +}, +_addAnnotatedComputationEffect: function(note, index) { +var sig = note.signature; +if (sig.static) { +this.__addAnnotatedComputationEffect("__static__", index, note, sig, null); +} else { +sig.args.forEach(function(arg) { +if (!arg.literal) { +this.__addAnnotatedComputationEffect(arg.model, index, note, sig, arg); +} +}, this); +} +}, +__addAnnotatedComputationEffect: function(property, index, note, sig, trigger) { +this._addPropertyEffect(property, "annotatedComputation", { +index: index, +kind: note.kind, +property: note.name, +negate: note.negate, +method: sig.method, +args: sig.args, +trigger: trigger +}); +}, +_parseMethod: function(expression) { +var m = expression.match(/(\w*)\((.*)\)/); +if (m) { +var sig = { +method: m[1], +"static": true +}; +if (m[2].trim()) { +var args = m[2].replace(/\\,/g, ",").split(","); +return this._parseArgs(args, sig); +} else { +sig.args = Polymer.nar; +return sig; +} +} +}, +_parseArgs: function(argList, sig) { +sig.args = argList.map(function(rawArg) { +var arg = this._parseArg(rawArg); +if (!arg.literal) { +sig.static = false; +} +return arg; +}, this); +return sig; +}, +_parseArg: function(rawArg) { +var arg = rawArg.trim().replace(/,/g, ",").replace(/\\(.)/g, "$1"); +var a = { +name: arg, +model: this._modelForPath(arg) +}; +var fc = arg[0]; +if (fc >= "0" && fc <= "9") { +fc = "#"; +} +switch (fc) { +case "'": +case '"': +a.value = arg.slice(1, -1); +a.literal = true; +break; + +case "#": +a.value = Number(arg); +a.literal = true; +break; +} +if (!a.literal) { +a.structured = arg.indexOf(".") > 0; +if (a.structured) { +a.wildcard = arg.slice(-2) == ".*"; +if (a.wildcard) { +a.name = arg.slice(0, -2); +} +} +} +return a; +}, +_marshalInstanceEffects: function() { +Polymer.Bind.prepareInstance(this); +Polymer.Bind.setupBindListeners(this); +}, +_applyEffectValue: function(value, info) { +var node = this._nodes[info.index]; +var property = info.property || info.name || "textContent"; +if (info.kind == "attribute") { +this.serializeValueToAttribute(value, property, node); +} else { +if (property === "className") { +value = this._scopeElementClass(node, value); +} +if (property === "textContent" || node.localName == "input" && property == "value") { +value = value == undefined ? "" : value; +} +return node[property] = value; +} +}, +_executeStaticEffects: function() { +if (this._propertyEffects.__static__) { +this._effectEffects("__static__", null, this._propertyEffects.__static__); +} +} +}); + +Polymer.Base._addFeature({ +_setupConfigure: function(initialConfig) { +this._config = initialConfig || {}; +this._handlers = []; +}, +_marshalAttributes: function() { +this._takeAttributesToModel(this._config); +}, +_configValue: function(name, value) { +this._config[name] = value; +}, +_beforeClientsReady: function() { +this._configure(); +}, +_configure: function() { +this._configureAnnotationReferences(); +var config = {}; +this.behaviors.forEach(function(b) { +this._configureProperties(b.properties, config); +}, this); +this._configureProperties(this.properties, config); +this._mixinConfigure(config, this._config); +this._config = config; +this._distributeConfig(this._config); +}, +_configureProperties: function(properties, config) { +for (var i in properties) { +var c = properties[i]; +if (c.value !== undefined) { +var value = c.value; +if (typeof value == "function") { +value = value.call(this, this._config); +} +config[i] = value; +} +} +}, +_mixinConfigure: function(a, b) { +for (var prop in b) { +if (!this.getPropertyInfo(prop).readOnly) { +a[prop] = b[prop]; +} +} +}, +_distributeConfig: function(config) { +var fx$ = this._propertyEffects; +if (fx$) { +for (var p in config) { +var fx = fx$[p]; +if (fx) { +for (var i = 0, l = fx.length, x; i < l && (x = fx[i]); i++) { +if (x.kind === "annotation") { +var node = this._nodes[x.effect.index]; +if (node._configValue) { +var value = p === x.effect.value ? config[p] : this.get(x.effect.value, config); +node._configValue(x.effect.name, value); +} +} +} +} +} +} +}, +_afterClientsReady: function() { +this._executeStaticEffects(); +this._applyConfig(this._config); +this._flushHandlers(); +}, +_applyConfig: function(config) { +for (var n in config) { +if (this[n] === undefined) { +var effects = this._propertyEffects[n]; +if (effects) { +this._propertySet(n, config[n], effects); +} else { +this[n] = config[n]; +} +} +} +}, +_notifyListener: function(fn, e) { +if (!this._clientsReadied) { +this._queueHandler([ fn, e, e.target ]); +} else { +return fn.call(this, e, e.target); +} +}, +_queueHandler: function(args) { +this._handlers.push(args); +}, +_flushHandlers: function() { +var h$ = this._handlers; +for (var i = 0, l = h$.length, h; i < l && (h = h$[i]); i++) { +h[0].call(this, h[1], h[2]); +} +} +}); + +(function() { +"use strict"; +Polymer.Base._addFeature({ +notifyPath: function(path, value, fromAbove) { +var old = this._propertySet(path, value); +if (old !== value) { +this._pathEffector(path, value); +if (!fromAbove) { +this._notifyPath(path, value); +} +} +}, +_getPathParts: function(path) { +if (Array.isArray(path)) { +var parts = []; +for (var i = 0; i < path.length; i++) { +var args = path[i].toString().split("."); +for (var j = 0; j < args.length; j++) { +parts.push(args[j]); +} +} +return parts; +} else { +return path.toString().split("."); +} +}, +set: function(path, value, root) { +var prop = root || this; +var parts = this._getPathParts(path); +var array; +var last = parts[parts.length - 1]; +if (parts.length > 1) { +for (var i = 0; i < parts.length - 1; i++) { +prop = prop[parts[i]]; +if (array) { +parts[i] = Polymer.Collection.get(array).getKey(prop); +} +if (!prop) { +return; +} +array = Array.isArray(prop) ? prop : null; +} +prop[last] = value; +if (!root) { +this.notifyPath(parts.join("."), value); +} +} else { +prop[path] = value; +} +}, +get: function(path, root) { +var prop = root || this; +var parts = this._getPathParts(path); +var last = parts.pop(); +while (parts.length) { +prop = prop[parts.shift()]; +if (!prop) { +return; +} +} +return prop[last]; +}, +_pathEffector: function(path, value) { +var model = this._modelForPath(path); +var fx$ = this._propertyEffects[model]; +if (fx$) { +fx$.forEach(function(fx) { +var fxFn = this["_" + fx.kind + "PathEffect"]; +if (fxFn) { +fxFn.call(this, path, value, fx.effect); +} +}, this); +} +if (this._boundPaths) { +this._notifyBoundPaths(path, value); +} +}, +_annotationPathEffect: function(path, value, effect) { +if (effect.value === path || effect.value.indexOf(path + ".") === 0) { +Polymer.Bind._annotationEffect.call(this, path, value, effect); +} else if (path.indexOf(effect.value + ".") === 0 && !effect.negate) { +var node = this._nodes[effect.index]; +if (node && node.notifyPath) { +var p = this._fixPath(effect.name, effect.value, path); +node.notifyPath(p, value, true); +} +} +}, +_complexObserverPathEffect: function(path, value, effect) { +if (this._pathMatchesEffect(path, effect)) { +Polymer.Bind._complexObserverEffect.call(this, path, value, effect); +} +}, +_computePathEffect: function(path, value, effect) { +if (this._pathMatchesEffect(path, effect)) { +Polymer.Bind._computeEffect.call(this, path, value, effect); +} +}, +_annotatedComputationPathEffect: function(path, value, effect) { +if (this._pathMatchesEffect(path, effect)) { +Polymer.Bind._annotatedComputationEffect.call(this, path, value, effect); +} +}, +_pathMatchesEffect: function(path, effect) { +var effectArg = effect.trigger.name; +return effectArg == path || effectArg.indexOf(path + ".") === 0 || effect.trigger.wildcard && path.indexOf(effectArg) === 0; +}, +linkPaths: function(to, from) { +this._boundPaths = this._boundPaths || {}; +if (from) { +this._boundPaths[to] = from; +} else { +this.unbindPath(to); +} +}, +unlinkPaths: function(path) { +if (this._boundPaths) { +delete this._boundPaths[path]; +} +}, +_notifyBoundPaths: function(path, value) { +var from, to; +for (var a in this._boundPaths) { +var b = this._boundPaths[a]; +if (path.indexOf(a + ".") == 0) { +from = a; +to = b; +break; +} +if (path.indexOf(b + ".") == 0) { +from = b; +to = a; +break; +} +} +if (from && to) { +var p = this._fixPath(to, from, path); +this.notifyPath(p, value); +} +}, +_fixPath: function(property, root, path) { +return property + path.slice(root.length); +}, +_notifyPath: function(path, value) { +var rootName = this._modelForPath(path); +var dashCaseName = Polymer.CaseMap.camelToDashCase(rootName); +var eventName = dashCaseName + this._EVENT_CHANGED; +this.fire(eventName, { +path: path, +value: value +}, { +bubbles: false +}); +}, +_modelForPath: function(path) { +var dot = path.indexOf("."); +return dot < 0 ? path : path.slice(0, dot); +}, +_EVENT_CHANGED: "-changed", +_notifySplice: function(array, path, index, added, removed) { +var splices = [ { +index: index, +addedCount: added, +removed: removed, +object: array, +type: "splice" +} ]; +var change = { +keySplices: Polymer.Collection.get(array).applySplices(splices), +indexSplices: splices +}; +this.set(path + ".splices", change); +if (added != removed.length) { +this.notifyPath(path + ".length", array.length); +} +change.keySplices = null; +change.indexSplices = null; +}, +push: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var len = array.length; +var ret = array.push.apply(array, args); +this._notifySplice(array, path, len, args.length, []); +return ret; +}, +pop: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var rem = array.slice(-1); +var ret = array.pop.apply(array, args); +this._notifySplice(array, path, array.length, 0, rem); +return ret; +}, +splice: function(path, start, deleteCount) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var rem = array.slice(start, start + deleteCount); +var ret = array.splice.apply(array, args); +this._notifySplice(array, path, start, args.length - 2, rem); +return ret; +}, +shift: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var ret = array.shift.apply(array, args); +this._notifySplice(array, path, 0, 0, [ ret ]); +return ret; +}, +unshift: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var ret = array.unshift.apply(array, args); +this._notifySplice(array, path, 0, args.length, []); +return ret; +} +}); +})(); + +Polymer.Base._addFeature({ +resolveUrl: function(url) { +var module = Polymer.DomModule.import(this.is); +var root = ""; +if (module) { +var assetPath = module.getAttribute("assetpath") || ""; +root = Polymer.ResolveUrl.resolveUrl(assetPath, module.ownerDocument.baseURI); +} +return Polymer.ResolveUrl.resolveUrl(url, root); +} +}); + +Polymer.CssParse = function() { +var api = { +parse: function(text) { +text = this._clean(text); +return this._parseCss(this._lex(text), text); +}, +_clean: function(cssText) { +return cssText.replace(rx.comments, "").replace(rx.port, ""); +}, +_lex: function(text) { +var root = { +start: 0, +end: text.length +}; +var n = root; +for (var i = 0, s = 0, l = text.length; i < l; i++) { +switch (text[i]) { +case this.OPEN_BRACE: +if (!n.rules) { +n.rules = []; +} +var p = n; +var previous = p.rules[p.rules.length - 1]; +n = { +start: i + 1, +parent: p, +previous: previous +}; +p.rules.push(n); +break; + +case this.CLOSE_BRACE: +n.end = i + 1; +n = n.parent || root; +break; +} +} +return root; +}, +_parseCss: function(node, text) { +var t = text.substring(node.start, node.end - 1); +node.parsedCssText = node.cssText = t.trim(); +if (node.parent) { +var ss = node.previous ? node.previous.end : node.parent.start; +t = text.substring(ss, node.start - 1); +t = t.substring(t.lastIndexOf(";") + 1); +var s = node.parsedSelector = node.selector = t.trim(); +node.atRule = s.indexOf(AT_START) === 0; +if (node.atRule) { +if (s.indexOf(MEDIA_START) === 0) { +node.type = this.types.MEDIA_RULE; +} else if (s.match(rx.keyframesRule)) { +node.type = this.types.KEYFRAMES_RULE; +} +} else { +if (s.indexOf(VAR_START) === 0) { +node.type = this.types.MIXIN_RULE; +} else { +node.type = this.types.STYLE_RULE; +} +} +} +var r$ = node.rules; +if (r$) { +for (var i = 0, l = r$.length, r; i < l && (r = r$[i]); i++) { +this._parseCss(r, text); +} +} +return node; +}, +stringify: function(node, preserveProperties, text) { +text = text || ""; +var cssText = ""; +if (node.cssText || node.rules) { +var r$ = node.rules; +if (r$ && (preserveProperties || !hasMixinRules(r$))) { +for (var i = 0, l = r$.length, r; i < l && (r = r$[i]); i++) { +cssText = this.stringify(r, preserveProperties, cssText); +} +} else { +cssText = preserveProperties ? node.cssText : removeCustomProps(node.cssText); +cssText = cssText.trim(); +if (cssText) { +cssText = " " + cssText + "\n"; +} +} +} +if (cssText) { +if (node.selector) { +text += node.selector + " " + this.OPEN_BRACE + "\n"; +} +text += cssText; +if (node.selector) { +text += this.CLOSE_BRACE + "\n\n"; +} +} +return text; +}, +types: { +STYLE_RULE: 1, +KEYFRAMES_RULE: 7, +MEDIA_RULE: 4, +MIXIN_RULE: 1e3 +}, +OPEN_BRACE: "{", +CLOSE_BRACE: "}" +}; +function hasMixinRules(rules) { +return rules[0].selector.indexOf(VAR_START) >= 0; +} +function removeCustomProps(cssText) { +return cssText.replace(rx.customProp, "").replace(rx.mixinProp, "").replace(rx.mixinApply, "").replace(rx.varApply, ""); +} +var VAR_START = "--"; +var MEDIA_START = "@media"; +var AT_START = "@"; +var rx = { +comments: /\/\*[^*]*\*+([^\/*][^*]*\*+)*\//gim, +port: /@import[^;]*;/gim, +customProp: /(?:^|[\s;])--[^;{]*?:[^{};]*?;/gim, +mixinProp: /(?:^|[\s;])--[^;{]*?:[^{;]*?{[^}]*?};?/gim, +mixinApply: /@apply[\s]*\([^)]*?\)[\s]*;/gim, +varApply: /[^;:]*?:[^;]*var[^;]*;/gim, +keyframesRule: /^@[^\s]*keyframes/ +}; +return api; +}(); + +Polymer.StyleUtil = function() { +return { +MODULE_STYLES_SELECTOR: "style, link[rel=import][type~=css]", +toCssText: function(rules, callback, preserveProperties) { +if (typeof rules === "string") { +rules = this.parser.parse(rules); +} +if (callback) { +this.forEachStyleRule(rules, callback); +} +return this.parser.stringify(rules, preserveProperties); +}, +forRulesInStyles: function(styles, callback) { +for (var i = 0, l = styles.length, s; i < l && (s = styles[i]); i++) { +this.forEachStyleRule(this.rulesForStyle(s), callback); +} +}, +rulesForStyle: function(style) { +if (!style.__cssRules) { +style.__cssRules = this.parser.parse(style.textContent); +} +return style.__cssRules; +}, +clearStyleRules: function(style) { +style.__cssRules = null; +}, +forEachStyleRule: function(node, callback) { +var s = node.selector; +var skipRules = false; +if (node.type === this.ruleTypes.STYLE_RULE) { +callback(node); +} else if (node.type === this.ruleTypes.KEYFRAMES_RULE || node.type === this.ruleTypes.MIXIN_RULE) { +skipRules = true; +} +var r$ = node.rules; +if (r$ && !skipRules) { +for (var i = 0, l = r$.length, r; i < l && (r = r$[i]); i++) { +this.forEachStyleRule(r, callback); +} +} +}, +applyCss: function(cssText, moniker, target, afterNode) { +var style = document.createElement("style"); +if (moniker) { +style.setAttribute("scope", moniker); +} +style.textContent = cssText; +target = target || document.head; +if (!afterNode) { +var n$ = target.querySelectorAll("style[scope]"); +afterNode = n$[n$.length - 1]; +} +target.insertBefore(style, afterNode && afterNode.nextSibling || target.firstChild); +return style; +}, +cssFromModule: function(moduleId) { +var m = Polymer.DomModule.import(moduleId); +if (m && !m._cssText) { +var cssText = ""; +var e$ = Array.prototype.slice.call(m.querySelectorAll(this.MODULE_STYLES_SELECTOR)); +for (var i = 0, e; i < e$.length; i++) { +e = e$[i]; +if (e.localName === "style") { +e = e.__appliedElement || e; +e.parentNode.removeChild(e); +} else { +e = e.import && e.import.body; +} +if (e) { +cssText += Polymer.ResolveUrl.resolveCss(e.textContent, e.ownerDocument); +} +} +m._cssText = cssText; +} +return m && m._cssText || ""; +}, +parser: Polymer.CssParse, +ruleTypes: Polymer.CssParse.types +}; +}(); + +Polymer.StyleTransformer = function() { +var nativeShadow = Polymer.Settings.useNativeShadow; +var styleUtil = Polymer.StyleUtil; +var api = { +dom: function(node, scope, useAttr, shouldRemoveScope) { +this._transformDom(node, scope || "", useAttr, shouldRemoveScope); +}, +_transformDom: function(node, selector, useAttr, shouldRemoveScope) { +if (node.setAttribute) { +this.element(node, selector, useAttr, shouldRemoveScope); +} +var c$ = Polymer.dom(node).childNodes; +for (var i = 0; i < c$.length; i++) { +this._transformDom(c$[i], selector, useAttr, shouldRemoveScope); +} +}, +element: function(element, scope, useAttr, shouldRemoveScope) { +if (useAttr) { +if (shouldRemoveScope) { +element.removeAttribute(SCOPE_NAME); +} else { +element.setAttribute(SCOPE_NAME, scope); +} +} else { +if (scope) { +if (element.classList) { +if (shouldRemoveScope) { +element.classList.remove(SCOPE_NAME); +element.classList.remove(scope); +} else { +element.classList.add(SCOPE_NAME); +element.classList.add(scope); +} +} else if (element.getAttribute) { +var c = element.getAttribute(CLASS); +if (shouldRemoveScope) { +if (c) { +element.setAttribute(CLASS, c.replace(SCOPE_NAME, "").replace(scope, "")); +} +} else { +element.setAttribute(CLASS, c + (c ? " " : "") + SCOPE_NAME + " " + scope); +} +} +} +} +}, +elementStyles: function(element, callback) { +var styles = element._styles; +var cssText = ""; +for (var i = 0, l = styles.length, s, text; i < l && (s = styles[i]); i++) { +var rules = styleUtil.rulesForStyle(s); +cssText += nativeShadow ? styleUtil.toCssText(rules, callback) : this.css(rules, element.is, element.extends, callback, element._scopeCssViaAttr) + "\n\n"; +} +return cssText.trim(); +}, +css: function(rules, scope, ext, callback, useAttr) { +var hostScope = this._calcHostScope(scope, ext); +scope = this._calcElementScope(scope, useAttr); +var self = this; +return styleUtil.toCssText(rules, function(rule) { +if (!rule.isScoped) { +self.rule(rule, scope, hostScope); +rule.isScoped = true; +} +if (callback) { +callback(rule, scope, hostScope); +} +}); +}, +_calcElementScope: function(scope, useAttr) { +if (scope) { +return useAttr ? CSS_ATTR_PREFIX + scope + CSS_ATTR_SUFFIX : CSS_CLASS_PREFIX + scope; +} else { +return ""; +} +}, +_calcHostScope: function(scope, ext) { +return ext ? "[is=" + scope + "]" : scope; +}, +rule: function(rule, scope, hostScope) { +this._transformRule(rule, this._transformComplexSelector, scope, hostScope); +}, +_transformRule: function(rule, transformer, scope, hostScope) { +var p$ = rule.selector.split(COMPLEX_SELECTOR_SEP); +for (var i = 0, l = p$.length, p; i < l && (p = p$[i]); i++) { +p$[i] = transformer.call(this, p, scope, hostScope); +} +rule.selector = p$.join(COMPLEX_SELECTOR_SEP); +}, +_transformComplexSelector: function(selector, scope, hostScope) { +var stop = false; +var self = this; +selector = selector.replace(SIMPLE_SELECTOR_SEP, function(m, c, s) { +if (!stop) { +var o = self._transformCompoundSelector(s, c, scope, hostScope); +if (o.stop) { +stop = true; +} +c = o.combinator; +s = o.value; +} +return c + s; +}); +return selector; +}, +_transformCompoundSelector: function(selector, combinator, scope, hostScope) { +var jumpIndex = selector.search(SCOPE_JUMP); +if (selector.indexOf(HOST) >= 0) { +selector = selector.replace(HOST_PAREN, function(m, host, paren) { +return hostScope + paren; +}); +selector = selector.replace(HOST, hostScope); +} else if (jumpIndex !== 0) { +selector = scope ? this._transformSimpleSelector(selector, scope) : selector; +} +if (selector.indexOf(CONTENT) >= 0) { +combinator = ""; +} +var stop; +if (jumpIndex >= 0) { +selector = selector.replace(SCOPE_JUMP, " "); +stop = true; +} +return { +value: selector, +combinator: combinator, +stop: stop +}; +}, +_transformSimpleSelector: function(selector, scope) { +var p$ = selector.split(PSEUDO_PREFIX); +p$[0] += scope; +return p$.join(PSEUDO_PREFIX); +}, +rootRule: function(rule) { +this._transformRule(rule, this._transformRootSelector); +}, +_transformRootSelector: function(selector) { +return selector.match(SCOPE_JUMP) ? this._transformComplexSelector(selector) : selector.trim() + SCOPE_ROOT_SELECTOR; +}, +SCOPE_NAME: "style-scope" +}; +var SCOPE_NAME = api.SCOPE_NAME; +var SCOPE_ROOT_SELECTOR = ":not([" + SCOPE_NAME + "])" + ":not(." + SCOPE_NAME + ")"; +var COMPLEX_SELECTOR_SEP = ","; +var SIMPLE_SELECTOR_SEP = /(^|[\s>+~]+)([^\s>+~]+)/g; +var HOST = ":host"; +var HOST_PAREN = /(\:host)(?:\(((?:\([^)(]*\)|[^)(]*)+?)\))/g; +var CONTENT = "::content"; +var SCOPE_JUMP = /\:\:content|\:\:shadow|\/deep\//; +var CSS_CLASS_PREFIX = "."; +var CSS_ATTR_PREFIX = "[" + SCOPE_NAME + "~="; +var CSS_ATTR_SUFFIX = "]"; +var PSEUDO_PREFIX = ":"; +var CLASS = "class"; +return api; +}(); + +Polymer.StyleExtends = function() { +var styleUtil = Polymer.StyleUtil; +return { +hasExtends: function(cssText) { +return Boolean(cssText.match(this.rx.EXTEND)); +}, +transform: function(style) { +var rules = styleUtil.rulesForStyle(style); +var self = this; +styleUtil.forEachStyleRule(rules, function(rule) { +var map = self._mapRule(rule); +if (rule.parent) { +var m; +while (m = self.rx.EXTEND.exec(rule.cssText)) { +var extend = m[1]; +var extendor = self._findExtendor(extend, rule); +if (extendor) { +self._extendRule(rule, extendor); +} +} +} +rule.cssText = rule.cssText.replace(self.rx.EXTEND, ""); +}); +return styleUtil.toCssText(rules, function(rule) { +if (rule.selector.match(self.rx.STRIP)) { +rule.cssText = ""; +} +}, true); +}, +_mapRule: function(rule) { +if (rule.parent) { +var map = rule.parent.map || (rule.parent.map = {}); +var parts = rule.selector.split(","); +for (var i = 0, p; i < parts.length; i++) { +p = parts[i]; +map[p.trim()] = rule; +} +return map; +} +}, +_findExtendor: function(extend, rule) { +return rule.parent && rule.parent.map && rule.parent.map[extend] || this._findExtendor(extend, rule.parent); +}, +_extendRule: function(target, source) { +if (target.parent !== source.parent) { +this._cloneAndAddRuleToParent(source, target.parent); +} +target.extends = target.extends || (target.extends = []); +target.extends.push(source); +source.selector = source.selector.replace(this.rx.STRIP, ""); +source.selector = (source.selector && source.selector + ",\n") + target.selector; +if (source.extends) { +source.extends.forEach(function(e) { +this._extendRule(target, e); +}, this); +} +}, +_cloneAndAddRuleToParent: function(rule, parent) { +rule = Object.create(rule); +rule.parent = parent; +if (rule.extends) { +rule.extends = rule.extends.slice(); +} +parent.rules.push(rule); +}, +rx: { +EXTEND: /@extends\(([^)]*)\)\s*?;/gim, +STRIP: /%[^,]*$/ +} +}; +}(); + +(function() { +var prepElement = Polymer.Base._prepElement; +var nativeShadow = Polymer.Settings.useNativeShadow; +var styleUtil = Polymer.StyleUtil; +var styleTransformer = Polymer.StyleTransformer; +var styleExtends = Polymer.StyleExtends; +Polymer.Base._addFeature({ +_prepElement: function(element) { +if (this._encapsulateStyle) { +styleTransformer.element(element, this.is, this._scopeCssViaAttr); +} +prepElement.call(this, element); +}, +_prepStyles: function() { +if (this._encapsulateStyle === undefined) { +this._encapsulateStyle = !nativeShadow && Boolean(this._template); +} +this._styles = this._collectStyles(); +var cssText = styleTransformer.elementStyles(this); +if (cssText && this._template) { +var style = styleUtil.applyCss(cssText, this.is, nativeShadow ? this._template.content : null); +if (!nativeShadow) { +this._scopeStyle = style; +} +} +}, +_collectStyles: function() { +var styles = []; +var cssText = "", m$ = this.styleModules; +if (m$) { +for (var i = 0, l = m$.length, m; i < l && (m = m$[i]); i++) { +cssText += styleUtil.cssFromModule(m); +} +} +cssText += styleUtil.cssFromModule(this.is); +if (cssText) { +var style = document.createElement("style"); +style.textContent = cssText; +if (styleExtends.hasExtends(style.textContent)) { +cssText = styleExtends.transform(style); +} +styles.push(style); +} +return styles; +}, +_elementAdd: function(node) { +if (this._encapsulateStyle && !node.__styleScoped) { +styleTransformer.dom(node, this.is, this._scopeCssViaAttr); +} +}, +_elementRemove: function(node) { +if (this._encapsulateStyle) { +styleTransformer.dom(node, this.is, this._scopeCssViaAttr, true); +} +}, +scopeSubtree: function(container, shouldObserve) { +if (nativeShadow) { +return; +} +var self = this; +var scopify = function(node) { +if (node.nodeType === Node.ELEMENT_NODE) { +node.className = self._scopeElementClass(node, node.className); +var n$ = node.querySelectorAll("*"); +Array.prototype.forEach.call(n$, function(n) { +n.className = self._scopeElementClass(n, n.className); +}); +} +}; +scopify(container); +if (shouldObserve) { +var mo = new MutationObserver(function(mxns) { +mxns.forEach(function(m) { +if (m.addedNodes) { +for (var i = 0; i < m.addedNodes.length; i++) { +scopify(m.addedNodes[i]); +} +} +}); +}); +mo.observe(container, { +childList: true, +subtree: true +}); +return mo; +} +} +}); +})(); + +Polymer.StyleProperties = function() { +var nativeShadow = Polymer.Settings.useNativeShadow; +var matchesSelector = Polymer.DomApi.matchesSelector; +var styleUtil = Polymer.StyleUtil; +var styleTransformer = Polymer.StyleTransformer; +return { +decorateStyles: function(styles) { +var self = this, props = {}; +styleUtil.forRulesInStyles(styles, function(rule) { +self.decorateRule(rule); +self.collectPropertiesInCssText(rule.propertyInfo.cssText, props); +}); +var names = []; +for (var i in props) { +names.push(i); +} +return names; +}, +decorateRule: function(rule) { +if (rule.propertyInfo) { +return rule.propertyInfo; +} +var info = {}, properties = {}; +var hasProperties = this.collectProperties(rule, properties); +if (hasProperties) { +info.properties = properties; +rule.rules = null; +} +info.cssText = this.collectCssText(rule); +rule.propertyInfo = info; +return info; +}, +collectProperties: function(rule, properties) { +var info = rule.propertyInfo; +if (info) { +if (info.properties) { +Polymer.Base.mixin(properties, info.properties); +return true; +} +} else { +var m, rx = this.rx.VAR_ASSIGN; +var cssText = rule.parsedCssText; +var any; +while (m = rx.exec(cssText)) { +properties[m[1]] = (m[2] || m[3]).trim(); +any = true; +} +return any; +} +}, +collectCssText: function(rule) { +var customCssText = ""; +var cssText = rule.parsedCssText; +cssText = cssText.replace(this.rx.BRACKETED, "").replace(this.rx.VAR_ASSIGN, ""); +var parts = cssText.split(";"); +for (var i = 0, p; i < parts.length; i++) { +p = parts[i]; +if (p.match(this.rx.MIXIN_MATCH) || p.match(this.rx.VAR_MATCH)) { +customCssText += p + ";\n"; +} +} +return customCssText; +}, +collectPropertiesInCssText: function(cssText, props) { +var m; +while (m = this.rx.VAR_CAPTURE.exec(cssText)) { +props[m[1]] = true; +} +}, +reify: function(props) { +var names = Object.getOwnPropertyNames(props); +for (var i = 0, n; i < names.length; i++) { +n = names[i]; +props[n] = this.valueForProperty(props[n], props); +} +}, +valueForProperty: function(property, props) { +if (property) { +if (property.indexOf(";") >= 0) { +property = this.valueForProperties(property, props); +} else { +var self = this; +var fn = function(all, prefix, value, fallback) { +var propertyValue = self.valueForProperty(props[value], props) || (props[fallback] ? self.valueForProperty(props[fallback], props) : fallback); +return prefix + (propertyValue || ""); +}; +property = property.replace(this.rx.VAR_MATCH, fn); +} +} +return property && property.trim() || ""; +}, +valueForProperties: function(property, props) { +var parts = property.split(";"); +for (var i = 0, p, m; i < parts.length && (p = parts[i]); i++) { +m = p.match(this.rx.MIXIN_MATCH); +if (m) { +p = this.valueForProperty(props[m[1]], props); +} else { +var pp = p.split(":"); +if (pp[1]) { +pp[1] = pp[1].trim(); +pp[1] = this.valueForProperty(pp[1], props) || pp[1]; +} +p = pp.join(":"); +} +parts[i] = p && p.lastIndexOf(";") === p.length - 1 ? p.slice(0, -1) : p || ""; +} +return parts.join(";"); +}, +applyProperties: function(rule, props) { +var output = ""; +if (!rule.properties) { +this.decorateRule(rule); +} +if (rule.propertyInfo.cssText) { +output = this.valueForProperties(rule.propertyInfo.cssText, props); +} +rule.cssText = output; +}, +propertyDataFromStyles: function(styles, element) { +var props = {}, self = this; +var o = [], i = 0; +styleUtil.forRulesInStyles(styles, function(rule) { +if (!rule.propertyInfo) { +self.decorateRule(rule); +} +if (element && rule.propertyInfo.properties && matchesSelector.call(element, rule.selector)) { +self.collectProperties(rule, props); +addToBitMask(i, o); +} +i++; +}); +return { +properties: props, +key: o +}; +}, +scopePropertiesFromStyles: function(styles) { +if (!styles._scopeStyleProperties) { +styles._scopeStyleProperties = this.selectedPropertiesFromStyles(styles, this.SCOPE_SELECTORS); +} +return styles._scopeStyleProperties; +}, +hostPropertiesFromStyles: function(styles) { +if (!styles._hostStyleProperties) { +styles._hostStyleProperties = this.selectedPropertiesFromStyles(styles, this.HOST_SELECTORS); +} +return styles._hostStyleProperties; +}, +selectedPropertiesFromStyles: function(styles, selectors) { +var props = {}, self = this; +styleUtil.forRulesInStyles(styles, function(rule) { +if (!rule.propertyInfo) { +self.decorateRule(rule); +} +for (var i = 0; i < selectors.length; i++) { +if (rule.parsedSelector === selectors[i]) { +self.collectProperties(rule, props); +return; +} +} +}); +return props; +}, +transformStyles: function(element, properties, scopeSelector) { +var self = this; +var hostRx = new RegExp(this.rx.HOST_PREFIX + element.is + this.rx.HOST_SUFFIX); +return styleTransformer.elementStyles(element, function(rule) { +self.applyProperties(rule, properties); +if (rule.cssText && !nativeShadow) { +self._scopeSelector(rule, hostRx, element.is, element._scopeCssViaAttr, scopeSelector); +} +}); +}, +_scopeSelector: function(rule, hostRx, is, viaAttr, scopeId) { +rule.transformedSelector = rule.transformedSelector || rule.selector; +var selector = rule.transformedSelector; +var scope = viaAttr ? "[" + styleTransformer.SCOPE_NAME + "~=" + scopeId + "]" : "." + scopeId; +var parts = selector.split(","); +for (var i = 0, l = parts.length, p; i < l && (p = parts[i]); i++) { +parts[i] = p.match(hostRx) ? p.replace(is, is + scope) : scope + " " + p; +} +rule.selector = parts.join(","); +}, +applyElementScopeSelector: function(element, selector, old, viaAttr) { +var c = viaAttr ? element.getAttribute(styleTransformer.SCOPE_NAME) : element.className; +v = old ? c.replace(old, selector) : (c ? c + " " : "") + this.XSCOPE_NAME + " " + selector; +if (c !== v) { +if (viaAttr) { +element.setAttribute(styleTransformer.SCOPE_NAME, v); +} else { +element.className = v; +} +} +}, +applyElementStyle: function(element, properties, selector, style) { +var cssText = style ? style.textContent || "" : this.transformStyles(element, properties, selector); +var s = element._customStyle; +if (s && !nativeShadow && s !== style) { +s._useCount--; +if (s._useCount <= 0) { +s.parentNode.removeChild(s); +} +} +if (nativeShadow || (!style || !style.parentNode)) { +if (nativeShadow && element._customStyle) { +element._customStyle.textContent = cssText; +style = element._customStyle; +} else if (cssText) { +style = styleUtil.applyCss(cssText, selector, nativeShadow ? element.root : null, element._scopeStyle); +} +} +if (style) { +style._useCount = style._useCount || 0; +if (element._customStyle != style) { +style._useCount++; +} +element._customStyle = style; +} +return style; +}, +rx: { +VAR_ASSIGN: /(?:^|;\s*)(--[^\:;]*?):\s*?(?:([^;{]*?)|{([^}]*)})(?=;)/gim, +MIXIN_MATCH: /(?:^|\W+)@apply[\s]*\(([^)]*)\);?/im, +VAR_MATCH: /(^|\W+)var\([\s]*([^,)]*)[\s]*,?[\s]*((?:[^,)]*)|(?:[^;]*\([^;)]*\)))[\s]*?\)/gim, +VAR_CAPTURE: /\([\s]*(--[^,\s)]*)(?:,[\s]*(--[^,\s)]*))?(?:\)|,)/gim, +BRACKETED: /\{[^}]*\}/g, +HOST_PREFIX: "(?:^|[^.])", +HOST_SUFFIX: "($|[.:[\\s>+~])" +}, +HOST_SELECTORS: [ ":host" ], +SCOPE_SELECTORS: [ ":root" ], +XSCOPE_NAME: "x-scope" +}; +function addToBitMask(n, bits) { +var o = parseInt(n / 32); +var v = 1 << n % 32; +bits[o] = (bits[o] || 0) | v; +} +}(); + +Polymer.StyleDefaults = function() { +var styleProperties = Polymer.StyleProperties; +var styleUtil = Polymer.StyleUtil; +var style = document.createElement("style"); +var api = { +style: style, +_styles: [ style ], +_properties: null, +applyCss: function(cssText) { +this.style.textContent += cssText; +styleUtil.clearStyleRules(this.style); +this._properties = null; +}, +get _styleProperties() { +if (!this._properties) { +styleProperties.decorateStyles(this._styles); +this._styles._scopeStyleProperties = null; +this._properties = styleProperties.scopePropertiesFromStyles(this._styles); +} +return this._properties; +}, +_needsStyleProperties: function() {}, +_computeStyleProperties: function() { +return this._styleProperties; +} +}; +return api; +}(); + +(function() { +Polymer.StyleCache = function() { +this.cache = {}; +}; +Polymer.StyleCache.prototype = { +MAX: 100, +store: function(is, data, keyValues, keyStyles) { +data.keyValues = keyValues; +data.styles = keyStyles; +var s$ = this.cache[is] = this.cache[is] || []; +s$.push(data); +if (s$.length > this.MAX) { +s$.shift(); +} +}, +retrieve: function(is, keyValues, keyStyles) { +var cache = this.cache[is]; +if (cache) { +for (var i = cache.length - 1, data; i >= 0; i--) { +data = cache[i]; +if (keyStyles === data.styles && this._objectsEqual(keyValues, data.keyValues)) { +return data; +} +} +} +}, +clear: function() { +this.cache = {}; +}, +_objectsEqual: function(target, source) { +for (var i in target) { +if (target[i] !== source[i]) { +return false; +} +} +if (Array.isArray(target)) { +return target.length === source.length; +} +return true; +} +}; +})(); + +(function() { +var serializeValueToAttribute = Polymer.Base.serializeValueToAttribute; +var propertyUtils = Polymer.StyleProperties; +var styleTransformer = Polymer.StyleTransformer; +var styleUtil = Polymer.StyleUtil; +var styleDefaults = Polymer.StyleDefaults; +var nativeShadow = Polymer.Settings.useNativeShadow; +Polymer.Base._addFeature({ +_prepStyleProperties: function() { +this._ownStylePropertyNames = this._styles ? propertyUtils.decorateStyles(this._styles) : []; +}, +_setupStyleProperties: function() { +this.customStyle = {}; +}, +_needsStyleProperties: function() { +return Boolean(this._ownStylePropertyNames && this._ownStylePropertyNames.length); +}, +_beforeAttached: function() { +if (!this._scopeSelector && this._needsStyleProperties()) { +this._updateStyleProperties(); +} +}, +_updateStyleProperties: function() { +var info, scope = this.domHost || styleDefaults; +if (!scope._styleCache) { +scope._styleCache = new Polymer.StyleCache(); +} +var scopeData = propertyUtils.propertyDataFromStyles(scope._styles, this); +info = scope._styleCache.retrieve(this.is, scopeData.key, this._styles); +var scopeCached = Boolean(info); +if (scopeCached) { +this._styleProperties = info._styleProperties; +} else { +this._computeStyleProperties(scopeData.properties); +} +this._computeOwnStyleProperties(); +if (!scopeCached) { +info = styleCache.retrieve(this.is, this._ownStyleProperties, this._styles); +} +var globalCached = Boolean(info) && !scopeCached; +style = this._applyStyleProperties(info); +if (!scopeCached) { +var cacheableStyle = style; +if (nativeShadow) { +cacheableStyle = style.cloneNode ? style.cloneNode(true) : Object.create(style || null); +} +info = { +style: cacheableStyle, +_scopeSelector: this._scopeSelector, +_styleProperties: this._styleProperties +}; +scope._styleCache.store(this.is, info, scopeData.key, this._styles); +if (!globalCached) { +styleCache.store(this.is, Object.create(info), this._ownStyleProperties, this._styles); +} +} +}, +_computeStyleProperties: function(scopeProps) { +var scope = this.domHost || styleDefaults; +if (!scope._styleProperties) { +scope._computeStyleProperties(); +} +var props = Object.create(scope._styleProperties); +this.mixin(props, propertyUtils.hostPropertiesFromStyles(this._styles)); +scopeProps = scopeProps || propertyUtils.propertyDataFromStyles(scope._styles, this).properties; +this.mixin(props, scopeProps); +this.mixin(props, propertyUtils.scopePropertiesFromStyles(this._styles)); +this.mixin(props, this.customStyle); +propertyUtils.reify(props); +this._styleProperties = props; +}, +_computeOwnStyleProperties: function() { +var props = {}; +for (var i = 0, n; i < this._ownStylePropertyNames.length; i++) { +n = this._ownStylePropertyNames[i]; +props[n] = this._styleProperties[n]; +} +this._ownStyleProperties = props; +}, +_scopeCount: 0, +_applyStyleProperties: function(info) { +var oldScopeSelector = this._scopeSelector; +this._scopeSelector = info ? info._scopeSelector : this.is + "-" + this.__proto__._scopeCount++; +style = propertyUtils.applyElementStyle(this, this._styleProperties, this._scopeSelector, info && info.style); +if ((style || oldScopeSelector) && !nativeShadow) { +propertyUtils.applyElementScopeSelector(this, this._scopeSelector, oldScopeSelector, this._scopeCssViaAttr); +} +return style || {}; +}, +serializeValueToAttribute: function(value, attribute, node) { +node = node || this; +if (attribute === "class") { +var host = node === this ? this.domHost || this.dataHost : this; +if (host) { +value = host._scopeElementClass(node, value); +} +} +node = Polymer.dom(node); +serializeValueToAttribute.call(this, value, attribute, node); +}, +_scopeElementClass: function(element, selector) { +if (!nativeShadow && !this._scopeCssViaAttr) { +selector += (selector ? " " : "") + SCOPE_NAME + " " + this.is + (element._scopeSelector ? " " + XSCOPE_NAME + " " + element._scopeSelector : ""); +} +return selector; +}, +updateStyles: function() { +if (this.isAttached) { +if (this._needsStyleProperties()) { +this._updateStyleProperties(); +} else { +this._styleProperties = null; +} +if (this._styleCache) { +this._styleCache.clear(); +} +this._updateRootStyles(); +} +}, +_updateRootStyles: function(root) { +root = root || this.root; +var c$ = Polymer.dom(root)._query(function(e) { +return e.shadyRoot || e.shadowRoot; +}); +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +if (c.updateStyles) { +c.updateStyles(); +} +} +} +}); +Polymer.updateStyles = function() { +styleDefaults._styleCache.clear(); +Polymer.Base._updateRootStyles(document); +}; +var styleCache = new Polymer.StyleCache(); +Polymer.customStyleCache = styleCache; +var SCOPE_NAME = styleTransformer.SCOPE_NAME; +var XSCOPE_NAME = propertyUtils.XSCOPE_NAME; +})(); + +Polymer.Base._addFeature({ +_registerFeatures: function() { +this._prepIs(); +this._prepAttributes(); +this._prepExtends(); +this._prepConstructor(); +this._prepTemplate(); +this._prepStyles(); +this._prepStyleProperties(); +this._prepAnnotations(); +this._prepEffects(); +this._prepBehaviors(); +this._prepBindings(); +this._prepShady(); +}, +_prepBehavior: function(b) { +this._addPropertyEffects(b.properties); +this._addComplexObserverEffects(b.observers); +this._addHostAttributes(b.hostAttributes); +}, +_initFeatures: function() { +this._poolContent(); +this._setupConfigure(); +this._setupStyleProperties(); +this._pushHost(); +this._stampTemplate(); +this._popHost(); +this._marshalAnnotationReferences(); +this._marshalHostAttributes(); +this._setupDebouncers(); +this._marshalInstanceEffects(); +this._marshalBehaviors(); +this._marshalAttributes(); +this._tryReady(); +}, +_marshalBehavior: function(b) { +this._listenListeners(b.listeners); +} +}); + +(function() { +var nativeShadow = Polymer.Settings.useNativeShadow; +var propertyUtils = Polymer.StyleProperties; +var styleUtil = Polymer.StyleUtil; +var styleDefaults = Polymer.StyleDefaults; +Polymer({ +is: "custom-style", +"extends": "style", +created: function() { +this._appliesToDocument = this.parentNode.localName !== "dom-module"; +if (this._appliesToDocument) { +var e = this.__appliedElement || this; +var rules = styleUtil.rulesForStyle(e); +propertyUtils.decorateStyles([ e ]); +this._rulesToDefaultProperties(rules); +this.async(this._applyStyle); +} +}, +_applyStyle: function() { +var e = this.__appliedElement || this; +this._computeStyleProperties(); +var props = this._styleProperties; +var self = this; +e.textContent = styleUtil.toCssText(styleUtil.rulesForStyle(e), function(rule) { +if (rule.selector === ":root") { +rule.selector = "body"; +} +var css = rule.cssText = rule.parsedCssText; +if (rule.propertyInfo.cssText) { +css = css.replace(propertyUtils.rx.VAR_ASSIGN, ""); +rule.cssText = propertyUtils.valueForProperties(css, props); +} +if (!nativeShadow) { +Polymer.StyleTransformer.rootRule(rule); +} +}); +}, +_rulesToDefaultProperties: function(rules) { +styleUtil.forEachStyleRule(rules, function(rule) { +if (!rule.propertyInfo.properties) { +rule.cssText = ""; +} +}); +var cssText = styleUtil.parser.stringify(rules, true); +if (cssText) { +styleDefaults.applyCss(cssText); +} +} +}); +})(); + +Polymer.Templatizer = { +properties: { +_hideTemplateChildren: { +observer: "_hideTemplateChildrenChanged" +} +}, +_templatizerStatic: { +count: 0, +callbacks: {}, +debouncer: null +}, +_instanceProps: Polymer.nob, +created: function() { +this._templatizerId = this._templatizerStatic.count++; +}, +templatize: function(template) { +if (!template._content) { +template._content = template.content; +} +if (template._content._ctor) { +this.ctor = template._content._ctor; +this._prepParentProperties(this.ctor.prototype, template); +return; +} +var archetype = Object.create(Polymer.Base); +this._customPrepAnnotations(archetype, template); +archetype._prepEffects(); +this._customPrepEffects(archetype); +archetype._prepBehaviors(); +archetype._prepBindings(); +this._prepParentProperties(archetype, template); +archetype._notifyPath = this._notifyPathImpl; +archetype._scopeElementClass = this._scopeElementClassImpl; +archetype.listen = this._listenImpl; +var _constructor = this._constructorImpl; +var ctor = function TemplateInstance(model, host) { +_constructor.call(this, model, host); +}; +ctor.prototype = archetype; +archetype.constructor = ctor; +template._content._ctor = ctor; +this.ctor = ctor; +}, +_getRootDataHost: function() { +return this.dataHost && this.dataHost._rootDataHost || this.dataHost; +}, +_hideTemplateChildrenChanged: function(hidden) { +if (this._hideChildren) { +this._hideChildren(hidden); +} +}, +_debounceTemplate: function(fn) { +this._templatizerStatic.callbacks[this._templatizerId] = fn.bind(this); +this._templatizerStatic.debouncer = Polymer.Debounce(this._templatizerStatic.debouncer, this._flushTemplates.bind(this, true)); +}, +_flushTemplates: function(debouncerExpired) { +var db = this._templatizerStatic.debouncer; +while (debouncerExpired || db && db.finish) { +db.stop(); +var cbs = this._templatizerStatic.callbacks; +this._templatizerStatic.callbacks = {}; +for (var id in cbs) { +cbs[id](); +} +debouncerExpired = false; +} +}, +_customPrepEffects: function(archetype) { +var parentProps = archetype._parentProps; +for (var prop in parentProps) { +archetype._addPropertyEffect(prop, "function", this._createHostPropEffector(prop)); +} +}, +_customPrepAnnotations: function(archetype, template) { +archetype._template = template; +var c = template._content; +if (!c._notes) { +var rootDataHost = archetype._rootDataHost; +if (rootDataHost) { +Polymer.Annotations.prepElement = rootDataHost._prepElement.bind(rootDataHost); +} +c._notes = Polymer.Annotations.parseAnnotations(template); +Polymer.Annotations.prepElement = null; +this._processAnnotations(c._notes); +} +archetype._notes = c._notes; +archetype._parentProps = c._parentProps; +}, +_prepParentProperties: function(archetype, template) { +var parentProps = this._parentProps = archetype._parentProps; +if (this._forwardParentProp && parentProps) { +var proto = archetype._parentPropProto; +var prop; +if (!proto) { +for (prop in this._instanceProps) { +delete parentProps[prop]; +} +proto = archetype._parentPropProto = Object.create(null); +if (template != this) { +Polymer.Bind.prepareModel(proto); +} +for (prop in parentProps) { +var parentProp = "_parent_" + prop; +var effects = [ { +kind: "function", +effect: this._createForwardPropEffector(prop) +}, { +kind: "notify" +} ]; +Polymer.Bind._createAccessors(proto, parentProp, effects); +} +} +if (template != this) { +Polymer.Bind.prepareInstance(template); +template._forwardParentProp = this._forwardParentProp.bind(this); +} +this._extendTemplate(template, proto); +} +}, +_createForwardPropEffector: function(prop) { +return function(source, value) { +this._forwardParentProp(prop, value); +}; +}, +_createHostPropEffector: function(prop) { +return function(source, value) { +this.dataHost["_parent_" + prop] = value; +}; +}, +_extendTemplate: function(template, proto) { +Object.getOwnPropertyNames(proto).forEach(function(n) { +var val = template[n]; +var pd = Object.getOwnPropertyDescriptor(proto, n); +Object.defineProperty(template, n, pd); +if (val !== undefined) { +template._propertySet(n, val); +} +}); +}, +_forwardInstancePath: function(inst, path, value) {}, +_notifyPathImpl: function(path, value) { +var dataHost = this.dataHost; +var dot = path.indexOf("."); +var root = dot < 0 ? path : path.slice(0, dot); +dataHost._forwardInstancePath.call(dataHost, this, path, value); +if (root in dataHost._parentProps) { +dataHost.notifyPath("_parent_" + path, value); +} +}, +_pathEffector: function(path, value, fromAbove) { +if (this._forwardParentPath) { +if (path.indexOf("_parent_") === 0) { +this._forwardParentPath(path.substring(8), value); +} +} +Polymer.Base._pathEffector.apply(this, arguments); +}, +_constructorImpl: function(model, host) { +this._rootDataHost = host._getRootDataHost(); +this._setupConfigure(model); +this._pushHost(host); +this.root = this.instanceTemplate(this._template); +this.root.__styleScoped = true; +this._popHost(); +this._marshalAnnotatedNodes(); +this._marshalInstanceEffects(); +this._marshalAnnotatedListeners(); +var children = []; +for (var n = this.root.firstChild; n; n = n.nextSibling) { +children.push(n); +n._templateInstance = this; +} +this._children = children; +this._tryReady(); +}, +_listenImpl: function(node, eventName, methodName) { +var model = this; +var host = this._rootDataHost; +var handler = host._createEventHandler(node, eventName, methodName); +var decorated = function(e) { +e.model = model; +handler(e); +}; +host._listen(node, eventName, decorated); +}, +_scopeElementClassImpl: function(node, value) { +var host = this._rootDataHost; +if (host) { +return host._scopeElementClass(node, value); +} +}, +stamp: function(model) { +model = model || {}; +if (this._parentProps) { +for (var prop in this._parentProps) { +model[prop] = this["_parent_" + prop]; +} +} +return new this.ctor(model, this); +} +}; + +Polymer({ +is: "dom-template", +"extends": "template", +behaviors: [ Polymer.Templatizer ], +ready: function() { +this.templatize(this); +} +}); + +Polymer._collections = new WeakMap(); + +Polymer.Collection = function(userArray) { +Polymer._collections.set(userArray, this); +this.userArray = userArray; +this.store = userArray.slice(); +this.initMap(); +}; + +Polymer.Collection.prototype = { +constructor: Polymer.Collection, +initMap: function() { +var omap = this.omap = new WeakMap(); +var pmap = this.pmap = {}; +var s = this.store; +for (var i = 0; i < s.length; i++) { +var item = s[i]; +if (item && typeof item == "object") { +omap.set(item, i); +} else { +pmap[item] = i; +} +} +}, +add: function(item) { +var key = this.store.push(item) - 1; +if (item && typeof item == "object") { +this.omap.set(item, key); +} else { +this.pmap[item] = key; +} +return key; +}, +removeKey: function(key) { +this._removeFromMap(this.store[key]); +delete this.store[key]; +}, +_removeFromMap: function(item) { +if (typeof item == "object") { +this.omap.delete(item); +} else { +delete this.pmap[item]; +} +}, +remove: function(item) { +var key = this.getKey(item); +this.removeKey(key); +return key; +}, +getKey: function(item) { +if (typeof item == "object") { +return this.omap.get(item); +} else { +return this.pmap[item]; +} +}, +getKeys: function() { +return Object.keys(this.store); +}, +setItem: function(key, value) { +this.store[key] = value; +}, +getItem: function(key) { +return this.store[key]; +}, +getItems: function() { +var items = [], store = this.store; +for (var key in store) { +items.push(store[key]); +} +return items; +}, +applySplices: function(splices) { +var keySplices = []; +for (var i = 0; i < splices.length; i++) { +var j, o, key, s = splices[i]; +var removed = []; +for (j = 0; j < s.removed.length; j++) { +o = s.removed[j]; +key = this.remove(o); +removed.push(key); +} +var added = []; +for (j = 0; j < s.addedCount; j++) { +o = this.userArray[s.index + j]; +key = this.add(o); +added.push(key); +} +keySplices.push({ +index: s.index, +removed: removed, +removedItems: s.removed, +added: added +}); +} +return keySplices; +} +}; + +Polymer.Collection.get = function(userArray) { +return Polymer._collections.get(userArray) || new Polymer.Collection(userArray); +}; + +Polymer({ +is: "dom-repeat", +"extends": "template", +properties: { +items: { +type: Array +}, +as: { +type: String, +value: "item" +}, +indexAs: { +type: String, +value: "index" +}, +sort: { +type: Function, +observer: "_sortChanged" +}, +filter: { +type: Function, +observer: "_filterChanged" +}, +observe: { +type: String, +observer: "_observeChanged" +}, +delay: Number +}, +behaviors: [ Polymer.Templatizer ], +observers: [ "_itemsChanged(items.*)" ], +detached: function() { +if (this.rows) { +for (var i = 0; i < this.rows.length; i++) { +this._detachRow(i); +} +} +this.rows = null; +}, +ready: function() { +this._instanceProps = { +__key__: true +}; +this._instanceProps[this.as] = true; +this._instanceProps[this.indexAs] = true; +if (!this.ctor) { +this.templatize(this); +} +}, +_sortChanged: function() { +var dataHost = this._getRootDataHost(); +var sort = this.sort; +this._sortFn = sort && (typeof sort == "function" ? sort : function() { +return dataHost[sort].apply(dataHost, arguments); +}); +this._fullRefresh = true; +if (this.items) { +this._debounceTemplate(this._render); +} +}, +_filterChanged: function() { +var dataHost = this._getRootDataHost(); +var filter = this.filter; +this._filterFn = filter && (typeof filter == "function" ? filter : function() { +return dataHost[filter].apply(dataHost, arguments); +}); +this._fullRefresh = true; +if (this.items) { +this._debounceTemplate(this._render); +} +}, +_observeChanged: function() { +this._observePaths = this.observe && this.observe.replace(".*", ".").split(" "); +}, +_itemsChanged: function(change) { +if (change.path == "items") { +if (Array.isArray(this.items)) { +this.collection = Polymer.Collection.get(this.items); +} else if (!this.items) { +this.collection = null; +} else { +this._error(this._logf("dom-repeat", "expected array for `items`," + " found", this.items)); +} +this._splices = []; +this._fullRefresh = true; +this._debounceTemplate(this._render); +} else if (change.path == "items.splices") { +this._splices = this._splices.concat(change.value.keySplices); +this._debounceTemplate(this._render); +} else { +var subpath = change.path.slice(6); +this._forwardItemPath(subpath, change.value); +this._checkObservedPaths(subpath); +} +}, +_checkObservedPaths: function(path) { +if (this._observePaths) { +path = path.substring(path.indexOf(".") + 1); +var paths = this._observePaths; +for (var i = 0; i < paths.length; i++) { +if (path.indexOf(paths[i]) === 0) { +this._fullRefresh = true; +if (this.delay) { +this.debounce("render", this._render, this.delay); +} else { +this._debounceTemplate(this._render); +} +return; +} +} +} +}, +render: function() { +this._fullRefresh = true; +this.debounce("render", this._render); +this._flushTemplates(); +}, +_render: function() { +var c = this.collection; +if (!this._fullRefresh) { +if (this._sortFn) { +this._applySplicesViewSort(this._splices); +} else { +if (this._filterFn) { +this._fullRefresh = true; +} else { +this._applySplicesArraySort(this._splices); +} +} +} +if (this._fullRefresh) { +this._sortAndFilter(); +this._fullRefresh = false; +} +this._splices = []; +var rowForKey = this._rowForKey = {}; +var keys = this._orderedKeys; +this.rows = this.rows || []; +for (var i = 0; i < keys.length; i++) { +var key = keys[i]; +var item = c.getItem(key); +var row = this.rows[i]; +rowForKey[key] = i; +if (!row) { +this.rows.push(row = this._insertRow(i, null, item)); +} +row[this.as] = item; +row.__key__ = key; +row[this.indexAs] = i; +} +for (;i < this.rows.length; i++) { +this._detachRow(i); +} +this.rows.splice(keys.length, this.rows.length - keys.length); +this.fire("dom-change"); +}, +_sortAndFilter: function() { +var c = this.collection; +if (!this._sortFn) { +this._orderedKeys = []; +var items = this.items; +if (items) { +for (var i = 0; i < items.length; i++) { +this._orderedKeys.push(c.getKey(items[i])); +} +} +} else { +this._orderedKeys = c ? c.getKeys() : []; +} +if (this._filterFn) { +this._orderedKeys = this._orderedKeys.filter(function(a) { +return this._filterFn(c.getItem(a)); +}, this); +} +if (this._sortFn) { +this._orderedKeys.sort(function(a, b) { +return this._sortFn(c.getItem(a), c.getItem(b)); +}.bind(this)); +} +}, +_keySort: function(a, b) { +return this.collection.getKey(a) - this.collection.getKey(b); +}, +_applySplicesViewSort: function(splices) { +var c = this.collection; +var keys = this._orderedKeys; +var rows = this.rows; +var removedRows = []; +var addedKeys = []; +var pool = []; +var sortFn = this._sortFn || this._keySort.bind(this); +splices.forEach(function(s) { +for (var i = 0; i < s.removed.length; i++) { +var idx = this._rowForKey[s.removed[i]]; +if (idx != null) { +removedRows.push(idx); +} +} +for (var i = 0; i < s.added.length; i++) { +addedKeys.push(s.added[i]); +} +}, this); +if (removedRows.length) { +removedRows.sort(); +for (var i = removedRows.length - 1; i >= 0; i--) { +var idx = removedRows[i]; +pool.push(this._detachRow(idx)); +rows.splice(idx, 1); +keys.splice(idx, 1); +} +} +if (addedKeys.length) { +if (this._filterFn) { +addedKeys = addedKeys.filter(function(a) { +return this._filterFn(c.getItem(a)); +}, this); +} +addedKeys.sort(function(a, b) { +return this._sortFn(c.getItem(a), c.getItem(b)); +}.bind(this)); +var start = 0; +for (var i = 0; i < addedKeys.length; i++) { +start = this._insertRowIntoViewSort(start, addedKeys[i], pool); +} +} +}, +_insertRowIntoViewSort: function(start, key, pool) { +var c = this.collection; +var item = c.getItem(key); +var end = this.rows.length - 1; +var idx = -1; +var sortFn = this._sortFn || this._keySort.bind(this); +while (start <= end) { +var mid = start + end >> 1; +var midKey = this._orderedKeys[mid]; +var cmp = sortFn(c.getItem(midKey), item); +if (cmp < 0) { +start = mid + 1; +} else if (cmp > 0) { +end = mid - 1; +} else { +idx = mid; +break; +} +} +if (idx < 0) { +idx = end + 1; +} +this._orderedKeys.splice(idx, 0, key); +this.rows.splice(idx, 0, this._insertRow(idx, pool, c.getItem(key))); +return idx; +}, +_applySplicesArraySort: function(splices) { +var keys = this._orderedKeys; +var pool = []; +splices.forEach(function(s) { +for (var i = 0; i < s.removed.length; i++) { +pool.push(this._detachRow(s.index + i)); +} +this.rows.splice(s.index, s.removed.length); +}, this); +var c = this.collection; +splices.forEach(function(s) { +var args = [ s.index, s.removed.length ].concat(s.added); +keys.splice.apply(keys, args); +for (var i = 0; i < s.added.length; i++) { +var item = c.getItem(s.added[i]); +var row = this._insertRow(s.index + i, pool, item); +this.rows.splice(s.index + i, 0, row); +} +}, this); +}, +_detachRow: function(idx) { +var row = this.rows[idx]; +var parentNode = Polymer.dom(this).parentNode; +for (var i = 0; i < row._children.length; i++) { +var el = row._children[i]; +Polymer.dom(row.root).appendChild(el); +} +return row; +}, +_insertRow: function(idx, pool, item) { +var row = pool && pool.pop() || this._generateRow(idx, item); +var beforeRow = this.rows[idx]; +var beforeNode = beforeRow ? beforeRow._children[0] : this; +var parentNode = Polymer.dom(this).parentNode; +Polymer.dom(parentNode).insertBefore(row.root, beforeNode); +return row; +}, +_generateRow: function(idx, item) { +var model = { +__key__: this.collection.getKey(item) +}; +model[this.as] = item; +model[this.indexAs] = idx; +var row = this.stamp(model); +return row; +}, +_hideChildren: function(hidden) { +if (this.rows) { +for (var i = 0; i < this.rows.length; i++) { +var c$ = this.rows[i]._children; +for (var j = 0; j < c$.length; j++) { +var c = c$[j]; +if (c.style) { +c.style.display = hidden ? "none" : ""; +} +c._hideTemplateChildren = hidden; +} +} +} +}, +_forwardInstancePath: function(row, path, value) { +if (path.indexOf(this.as + ".") === 0) { +this.notifyPath("items." + row.__key__ + "." + path.slice(this.as.length + 1), value); +return true; +} +}, +_forwardParentProp: function(prop, value) { +if (this.rows) { +this.rows.forEach(function(row) { +row[prop] = value; +}, this); +} +}, +_forwardParentPath: function(path, value) { +if (this.rows) { +this.rows.forEach(function(row) { +row.notifyPath(path, value, true); +}, this); +} +}, +_forwardItemPath: function(path, value) { +if (this._rowForKey) { +var dot = path.indexOf("."); +var key = path.substring(0, dot < 0 ? path.length : dot); +var idx = this._rowForKey[key]; +var row = this.rows[idx]; +if (row) { +if (dot >= 0) { +path = this.as + "." + path.substring(dot + 1); +row.notifyPath(path, value, true); +} else { +row[this.as] = value; +} +} +} +}, +modelForElement: function(el) { +var model; +while (el) { +if (model = el._templateInstance) { +if (model.dataHost != this) { +el = model.dataHost; +} else { +return model; +} +} else { +el = el.parentNode; +} +} +}, +itemForElement: function(el) { +var instance = this.modelForElement(el); +return instance && instance[this.as]; +}, +keyForElement: function(el) { +var instance = this.modelForElement(el); +return instance && instance.__key__; +}, +indexForElement: function(el) { +var instance = this.modelForElement(el); +return instance && instance[this.indexAs]; +} +}); + +Polymer({ +is: "array-selector", +properties: { +items: { +type: Array, +observer: "_itemsChanged" +}, +selected: { +type: Object, +notify: true +}, +toggle: Boolean, +multi: Boolean +}, +_itemsChanged: function() { +if (Array.isArray(this.selected)) { +for (var i = 0; i < this.selected.length; i++) { +this.unlinkPaths("selected." + i); +} +} else { +this.unlinkPaths("selected"); +} +if (this.multi) { +this.selected = []; +} else { +this.selected = null; +} +}, +deselect: function(item) { +if (this.multi) { +var scol = Polymer.Collection.get(this.selected); +var sidx = this.selected.indexOf(item); +if (sidx >= 0) { +var skey = scol.getKey(item); +this.splice("selected", sidx, 1); +this.unlinkPaths("selected." + skey); +return true; +} +} else { +this.selected = null; +this.unlinkPaths("selected"); +} +}, +select: function(item) { +var icol = Polymer.Collection.get(this.items); +var key = icol.getKey(item); +if (this.multi) { +var scol = Polymer.Collection.get(this.selected); +var skey = scol.getKey(item); +if (skey >= 0) { +this.deselect(item); +} else if (this.toggle) { +this.push("selected", item); +this.async(function() { +skey = scol.getKey(item); +this.linkPaths("selected." + skey, "items." + key); +}); +} +} else { +if (this.toggle && item == this.selected) { +this.deselect(); +} else { +this.linkPaths("selected", "items." + key); +this.selected = item; +} +} +} +}); + +Polymer({ +is: "dom-if", +"extends": "template", +properties: { +"if": { +type: Boolean, +value: false +}, +restamp: { +type: Boolean, +value: false +} +}, +behaviors: [ Polymer.Templatizer ], +observers: [ "_queueRender(if, restamp)" ], +_queueRender: function() { +this._debounceTemplate(this._render); +}, +detached: function() { +this._teardownInstance(); +}, +attached: function() { +if (this.if && this.ctor) { +this.async(this._ensureInstance); +} +}, +render: function() { +this._flushTemplates(); +}, +_render: function() { +if (this.if) { +if (!this.ctor) { +this._wrapTextNodes(this._content || this.content); +this.templatize(this); +} +this._ensureInstance(); +this._hideTemplateChildren = false; +} else if (this.restamp) { +this._teardownInstance(); +} +if (!this.restamp && this._instance) { +this._hideTemplateChildren = !this.if; +} +if (this.if != this._lastIf) { +this.fire("dom-change"); +this._lastIf = this.if; +} +}, +_ensureInstance: function() { +if (!this._instance) { +this._instance = this.stamp(); +var root = this._instance.root; +var parent = Polymer.dom(Polymer.dom(this).parentNode); +parent.insertBefore(root, this); +} +}, +_teardownInstance: function() { +if (this._instance) { +var c = this._instance._children; +if (c) { +var parent = Polymer.dom(Polymer.dom(c[0]).parentNode); +c.forEach(function(n) { +parent.removeChild(n); +}); +} +this._instance = null; +} +}, +_wrapTextNodes: function(root) { +for (var n = root.firstChild; n; n = n.nextSibling) { +if (n.nodeType === Node.TEXT_NODE) { +var s = document.createElement("span"); +root.insertBefore(s, n); +s.appendChild(n); +n = s; +} +} +}, +_hideChildren: function(hidden) { +if (this._instance) { +var c$ = this._instance._children; +for (var i = 0; i < c$.length; i++) { +var c = c$[i]; +c.style.display = hidden ? "none" : ""; +c._hideTemplateChildren = hidden; +} +} +}, +_forwardParentProp: function(prop, value) { +if (this._instance) { +this._instance[prop] = value; +} +}, +_forwardParentPath: function(path, value) { +if (this._instance) { +this._instance.notifyPath(path, value, true); +} +} +}); + +Polymer.ImportStatus = { +_ready: false, +_callbacks: [], +whenLoaded: function(cb) { +if (this._ready) { +cb(); +} else { +this._callbacks.push(cb); +} +}, +_importsLoaded: function() { +this._ready = true; +this._callbacks.forEach(function(cb) { +cb(); +}); +this._callbacks = []; +} +}; + +window.addEventListener("load", function() { +Polymer.ImportStatus._importsLoaded(); +}); + +if (window.HTMLImports) { +HTMLImports.whenReady(function() { +Polymer.ImportStatus._importsLoaded(); +}); +} + +Polymer({ +is: "dom-bind", +"extends": "template", +created: function() { +Polymer.ImportStatus.whenLoaded(this._readySelf.bind(this)); +}, +_registerFeatures: function() { +this._prepExtends(); +this._prepConstructor(); +}, +_insertChildren: function() { +var parentDom = Polymer.dom(Polymer.dom(this).parentNode); +parentDom.insertBefore(this.root, this); +}, +_removeChildren: function() { +if (this._children) { +for (var i = 0; i < this._children.length; i++) { +this.root.appendChild(this._children[i]); +} +} +}, +_initFeatures: function() {}, +_scopeElementClass: function(element, selector) { +if (this.dataHost) { +return this.dataHost._scopeElementClass(element, selector); +} else { +return selector; +} +}, +_prepConfigure: function() { +var config = {}; +for (var prop in this._propertyEffects) { +config[prop] = this[prop]; +} +this._setupConfigure = this._setupConfigure.bind(this, config); +}, +attached: function() { +if (!this._children) { +this._template = this; +this._prepAnnotations(); +this._prepEffects(); +this._prepBehaviors(); +this._prepConfigure(); +this._prepBindings(); +Polymer.Base._initFeatures.call(this); +this._children = Array.prototype.slice.call(this.root.childNodes); +} +this._insertChildren(); +this.fire("dom-change"); +}, +detached: function() { +this._removeChildren(); +} +});
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/polymer-micro-extracted.js b/third_party/polymer/v1_0/components-chromium/polymer/polymer-micro-extracted.js new file mode 100644 index 0000000..d6dfdc5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/polymer-micro-extracted.js @@ -0,0 +1,535 @@ +(function() { +function resolve() { +document.body.removeAttribute("unresolved"); +} +if (window.WebComponents) { +addEventListener("WebComponentsReady", resolve); +} else { +resolve(); +} +})(); + +Polymer = { +Settings: function() { +var user = window.Polymer || {}; +location.search.slice(1).split("&").forEach(function(o) { +o = o.split("="); +o[0] && (user[o[0]] = o[1] || true); +}); +var wantShadow = user.dom === "shadow"; +var hasShadow = Boolean(Element.prototype.createShadowRoot); +var nativeShadow = hasShadow && !window.ShadowDOMPolyfill; +var useShadow = wantShadow && hasShadow; +var hasNativeImports = Boolean("import" in document.createElement("link")); +var useNativeImports = hasNativeImports; +var useNativeCustomElements = !window.CustomElements || window.CustomElements.useNative; +return { +wantShadow: wantShadow, +hasShadow: hasShadow, +nativeShadow: nativeShadow, +useShadow: useShadow, +useNativeShadow: useShadow && nativeShadow, +useNativeImports: useNativeImports, +useNativeCustomElements: useNativeCustomElements +}; +}() +}; + +(function() { +var userPolymer = window.Polymer; +window.Polymer = function(prototype) { +var ctor = desugar(prototype); +prototype = ctor.prototype; +var options = { +prototype: prototype +}; +if (prototype.extends) { +options.extends = prototype.extends; +} +Polymer.telemetry._registrate(prototype); +document.registerElement(prototype.is, options); +return ctor; +}; +var desugar = function(prototype) { +prototype = Polymer.Base.chainObject(prototype, Polymer.Base); +prototype.registerCallback(); +return prototype.constructor; +}; +window.Polymer = Polymer; +if (userPolymer) { +for (var i in userPolymer) { +Polymer[i] = userPolymer[i]; +} +} +Polymer.Class = desugar; +})(); + +Polymer.telemetry = { +registrations: [], +_regLog: function(prototype) { +console.log("[" + prototype.is + "]: registered"); +}, +_registrate: function(prototype) { +this.registrations.push(prototype); +Polymer.log && this._regLog(prototype); +}, +dumpRegistrations: function() { +this.registrations.forEach(this._regLog); +} +}; + +Object.defineProperty(window, "currentImport", { +enumerable: true, +configurable: true, +get: function() { +return (document._currentScript || document.currentScript).ownerDocument; +} +}); + +Polymer.Base = { +_addFeature: function(feature) { +this.extend(this, feature); +}, +registerCallback: function() { +this._registerFeatures(); +this._doBehavior("registered"); +}, +createdCallback: function() { +Polymer.telemetry.instanceCount++; +this.root = this; +this._doBehavior("created"); +this._initFeatures(); +}, +attachedCallback: function() { +this.isAttached = true; +this._doBehavior("attached"); +}, +detachedCallback: function() { +this.isAttached = false; +this._doBehavior("detached"); +}, +attributeChangedCallback: function(name) { +this._setAttributeToProperty(this, name); +this._doBehavior("attributeChanged", arguments); +}, +extend: function(prototype, api) { +if (prototype && api) { +Object.getOwnPropertyNames(api).forEach(function(n) { +this.copyOwnProperty(n, api, prototype); +}, this); +} +return prototype || api; +}, +copyOwnProperty: function(name, source, target) { +var pd = Object.getOwnPropertyDescriptor(source, name); +if (pd) { +Object.defineProperty(target, name, pd); +} +}, +_log: console.log.apply.bind(console.log, console), +_warn: console.warn.apply.bind(console.warn, console), +_error: console.error.apply.bind(console.error, console), +_logf: function() { +return this._logPrefix.concat([ this.is ]).concat(Array.prototype.slice.call(arguments, 0)); +} +}; + +Polymer.Base._logPrefix = function() { +var color = window.chrome || /firefox/i.test(navigator.userAgent); +return color ? [ "%c[%s::%s]:", "font-weight: bold; background-color:#EEEE00;" ] : [ "[%s::%s]:" ]; +}(); + +Polymer.Base.chainObject = function(object, inherited) { +if (object && inherited && object !== inherited) { +if (!Object.__proto__) { +object = Polymer.Base.extend(Object.create(inherited), object); +} +object.__proto__ = inherited; +} +return object; +}; + +Polymer.Base = Polymer.Base.chainObject(Polymer.Base, HTMLElement.prototype); + +Polymer.telemetry.instanceCount = 0; + +(function() { +var modules = {}; +var DomModule = function() { +return document.createElement("dom-module"); +}; +DomModule.prototype = Object.create(HTMLElement.prototype); +DomModule.prototype.constructor = DomModule; +DomModule.prototype.createdCallback = function() { +var id = this.id || this.getAttribute("name") || this.getAttribute("is"); +if (id) { +this.id = id; +modules[id] = this; +} +}; +DomModule.prototype.import = function(id, slctr) { +var m = modules[id]; +if (!m) { +forceDocumentUpgrade(); +m = modules[id]; +} +if (m && slctr) { +m = m.querySelector(slctr); +} +return m; +}; +var cePolyfill = window.CustomElements && !CustomElements.useNative; +if (cePolyfill) { +var ready = CustomElements.ready; +CustomElements.ready = true; +} +document.registerElement("dom-module", DomModule); +if (cePolyfill) { +CustomElements.ready = ready; +} +function forceDocumentUpgrade() { +if (cePolyfill) { +var script = document._currentScript || document.currentScript; +if (script) { +CustomElements.upgradeAll(script.ownerDocument); +} +} +} +})(); + +Polymer.Base._addFeature({ +_prepIs: function() { +if (!this.is) { +var module = (document._currentScript || document.currentScript).parentNode; +if (module.localName === "dom-module") { +var id = module.id || module.getAttribute("name") || module.getAttribute("is"); +this.is = id; +} +} +} +}); + +Polymer.Base._addFeature({ +behaviors: [], +_prepBehaviors: function() { +if (this.behaviors.length) { +this.behaviors = this._flattenBehaviorsList(this.behaviors); +} +this._prepAllBehaviors(this.behaviors); +}, +_flattenBehaviorsList: function(behaviors) { +var flat = []; +behaviors.forEach(function(b) { +if (b instanceof Array) { +flat = flat.concat(this._flattenBehaviorsList(b)); +} else if (b) { +flat.push(b); +} else { +this._warn(this._logf("_flattenBehaviorsList", "behavior is null, check for missing or 404 import")); +} +}, this); +return flat; +}, +_prepAllBehaviors: function(behaviors) { +for (var i = behaviors.length - 1; i >= 0; i--) { +this._mixinBehavior(behaviors[i]); +} +for (var i = 0, l = behaviors.length; i < l; i++) { +this._prepBehavior(behaviors[i]); +} +this._prepBehavior(this); +}, +_mixinBehavior: function(b) { +Object.getOwnPropertyNames(b).forEach(function(n) { +switch (n) { +case "hostAttributes": +case "registered": +case "properties": +case "observers": +case "listeners": +case "created": +case "attached": +case "detached": +case "attributeChanged": +case "configure": +case "ready": +break; + +default: +if (!this.hasOwnProperty(n)) { +this.copyOwnProperty(n, b, this); +} +break; +} +}, this); +}, +_doBehavior: function(name, args) { +this.behaviors.forEach(function(b) { +this._invokeBehavior(b, name, args); +}, this); +this._invokeBehavior(this, name, args); +}, +_invokeBehavior: function(b, name, args) { +var fn = b[name]; +if (fn) { +fn.apply(this, args || Polymer.nar); +} +}, +_marshalBehaviors: function() { +this.behaviors.forEach(function(b) { +this._marshalBehavior(b); +}, this); +this._marshalBehavior(this); +} +}); + +Polymer.Base._addFeature({ +_prepExtends: function() { +if (this.extends) { +this.__proto__ = this._getExtendedPrototype(this.extends); +} +}, +_getExtendedPrototype: function(tag) { +return this._getExtendedNativePrototype(tag); +}, +_nativePrototypes: {}, +_getExtendedNativePrototype: function(tag) { +var p = this._nativePrototypes[tag]; +if (!p) { +var np = this.getNativePrototype(tag); +p = this.extend(Object.create(np), Polymer.Base); +this._nativePrototypes[tag] = p; +} +return p; +}, +getNativePrototype: function(tag) { +return Object.getPrototypeOf(document.createElement(tag)); +} +}); + +Polymer.Base._addFeature({ +_prepConstructor: function() { +this._factoryArgs = this.extends ? [ this.extends, this.is ] : [ this.is ]; +var ctor = function() { +return this._factory(arguments); +}; +if (this.hasOwnProperty("extends")) { +ctor.extends = this.extends; +} +Object.defineProperty(this, "constructor", { +value: ctor, +writable: true, +configurable: true +}); +ctor.prototype = this; +}, +_factory: function(args) { +var elt = document.createElement.apply(document, this._factoryArgs); +if (this.factoryImpl) { +this.factoryImpl.apply(elt, args); +} +return elt; +} +}); + +Polymer.nob = Object.create(null); + +Polymer.Base._addFeature({ +properties: {}, +getPropertyInfo: function(property) { +var info = this._getPropertyInfo(property, this.properties); +if (!info) { +this.behaviors.some(function(b) { +return info = this._getPropertyInfo(property, b.properties); +}, this); +} +return info || Polymer.nob; +}, +_getPropertyInfo: function(property, properties) { +var p = properties && properties[property]; +if (typeof p === "function") { +p = properties[property] = { +type: p +}; +} +if (p) { +p.defined = true; +} +return p; +} +}); + +Polymer.CaseMap = { +_caseMap: {}, +dashToCamelCase: function(dash) { +var mapped = Polymer.CaseMap._caseMap[dash]; +if (mapped) { +return mapped; +} +if (dash.indexOf("-") < 0) { +return Polymer.CaseMap._caseMap[dash] = dash; +} +return Polymer.CaseMap._caseMap[dash] = dash.replace(/-([a-z])/g, function(m) { +return m[1].toUpperCase(); +}); +}, +camelToDashCase: function(camel) { +var mapped = Polymer.CaseMap._caseMap[camel]; +if (mapped) { +return mapped; +} +return Polymer.CaseMap._caseMap[camel] = camel.replace(/([a-z][A-Z])/g, function(g) { +return g[0] + "-" + g[1].toLowerCase(); +}); +} +}; + +Polymer.Base._addFeature({ +_prepAttributes: function() { +this._aggregatedAttributes = {}; +}, +_addHostAttributes: function(attributes) { +if (attributes) { +this.mixin(this._aggregatedAttributes, attributes); +} +}, +_marshalHostAttributes: function() { +this._applyAttributes(this, this._aggregatedAttributes); +}, +_applyAttributes: function(node, attr$) { +for (var n in attr$) { +if (!this.hasAttribute(n) && n !== "class") { +this.serializeValueToAttribute(attr$[n], n, this); +} +} +}, +_marshalAttributes: function() { +this._takeAttributesToModel(this); +}, +_takeAttributesToModel: function(model) { +for (var i = 0, l = this.attributes.length; i < l; i++) { +this._setAttributeToProperty(model, this.attributes[i].name); +} +}, +_setAttributeToProperty: function(model, attrName) { +if (!this._serializing) { +var propName = Polymer.CaseMap.dashToCamelCase(attrName); +var info = this.getPropertyInfo(propName); +if (info.defined || this._propertyEffects && this._propertyEffects[propName]) { +var val = this.getAttribute(attrName); +model[propName] = this.deserialize(val, info.type); +} +} +}, +_serializing: false, +reflectPropertyToAttribute: function(name) { +this._serializing = true; +this.serializeValueToAttribute(this[name], Polymer.CaseMap.camelToDashCase(name)); +this._serializing = false; +}, +serializeValueToAttribute: function(value, attribute, node) { +var str = this.serialize(value); +(node || this)[str === undefined ? "removeAttribute" : "setAttribute"](attribute, str); +}, +deserialize: function(value, type) { +switch (type) { +case Number: +value = Number(value); +break; + +case Boolean: +value = value !== null; +break; + +case Object: +try { +value = JSON.parse(value); +} catch (x) {} +break; + +case Array: +try { +value = JSON.parse(value); +} catch (x) { +value = null; +console.warn("Polymer::Attributes: couldn`t decode Array as JSON"); +} +break; + +case Date: +value = new Date(value); +break; + +case String: +default: +break; +} +return value; +}, +serialize: function(value) { +switch (typeof value) { +case "boolean": +return value ? "" : undefined; + +case "object": +if (value instanceof Date) { +return value; +} else if (value) { +try { +return JSON.stringify(value); +} catch (x) { +return ""; +} +} + +default: +return value != null ? value : undefined; +} +} +}); + +Polymer.Base._addFeature({ +_setupDebouncers: function() { +this._debouncers = {}; +}, +debounce: function(jobName, callback, wait) { +this._debouncers[jobName] = Polymer.Debounce.call(this, this._debouncers[jobName], callback, wait); +}, +isDebouncerActive: function(jobName) { +var debouncer = this._debouncers[jobName]; +return debouncer && debouncer.finish; +}, +flushDebouncer: function(jobName) { +var debouncer = this._debouncers[jobName]; +if (debouncer) { +debouncer.complete(); +} +}, +cancelDebouncer: function(jobName) { +var debouncer = this._debouncers[jobName]; +if (debouncer) { +debouncer.stop(); +} +} +}); + +Polymer.version = "1.0.2"; + +Polymer.Base._addFeature({ +_registerFeatures: function() { +this._prepIs(); +this._prepAttributes(); +this._prepBehaviors(); +this._prepExtends(); +this._prepConstructor(); +}, +_prepBehavior: function(b) { +this._addHostAttributes(b.hostAttributes); +}, +_marshalBehavior: function(b) {}, +_initFeatures: function() { +this._marshalHostAttributes(); +this._setupDebouncers(); +this._marshalBehaviors(); +} +});
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/polymer-micro.html b/third_party/polymer/v1_0/components-chromium/polymer/polymer-micro.html new file mode 100644 index 0000000..4b776ae --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/polymer-micro.html @@ -0,0 +1,9 @@ +<!-- +@license +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head></head><body><script src="polymer-micro-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/polymer-mini-extracted.js b/third_party/polymer/v1_0/components-chromium/polymer/polymer-mini-extracted.js new file mode 100644 index 0000000..ff4e108 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/polymer-mini-extracted.js @@ -0,0 +1,1312 @@ +Polymer.Base._addFeature({ +_prepTemplate: function() { +this._template = this._template || Polymer.DomModule.import(this.is, "template"); +if (!this._template) { +var script = document._currentScript || document.currentScript; +var prev = script && script.previousElementSibling; +if (prev && prev.localName === "template") { +this._template = prev; +} +} +if (this._template && this._template.hasAttribute("is")) { +this._warn(this._logf("_prepTemplate", "top-level Polymer template " + "must not be a type-extension, found", this._template, "Move inside simple <template>.")); +} +}, +_stampTemplate: function() { +if (this._template) { +this.root = this.instanceTemplate(this._template); +} +}, +instanceTemplate: function(template) { +var dom = document.importNode(template._content || template.content, true); +return dom; +} +}); + +(function() { +var baseAttachedCallback = Polymer.Base.attachedCallback; +Polymer.Base._addFeature({ +_hostStack: [], +ready: function() {}, +_pushHost: function(host) { +this.dataHost = host = host || Polymer.Base._hostStack[Polymer.Base._hostStack.length - 1]; +if (host && host._clients) { +host._clients.push(this); +} +this._beginHost(); +}, +_beginHost: function() { +Polymer.Base._hostStack.push(this); +if (!this._clients) { +this._clients = []; +} +}, +_popHost: function() { +Polymer.Base._hostStack.pop(); +}, +_tryReady: function() { +if (this._canReady()) { +this._ready(); +} +}, +_canReady: function() { +return !this.dataHost || this.dataHost._clientsReadied; +}, +_ready: function() { +this._beforeClientsReady(); +this._setupRoot(); +this._readyClients(); +this._afterClientsReady(); +this._readySelf(); +}, +_readyClients: function() { +this._beginDistribute(); +var c$ = this._clients; +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +c._ready(); +} +this._finishDistribute(); +this._clientsReadied = true; +this._clients = null; +}, +_readySelf: function() { +this._doBehavior("ready"); +this._readied = true; +if (this._attachedPending) { +this._attachedPending = false; +this.attachedCallback(); +} +}, +_beforeClientsReady: function() {}, +_afterClientsReady: function() {}, +_beforeAttached: function() {}, +attachedCallback: function() { +if (this._readied) { +this._beforeAttached(); +baseAttachedCallback.call(this); +} else { +this._attachedPending = true; +} +} +}); +})(); + +Polymer.ArraySplice = function() { +function newSplice(index, removed, addedCount) { +return { +index: index, +removed: removed, +addedCount: addedCount +}; +} +var EDIT_LEAVE = 0; +var EDIT_UPDATE = 1; +var EDIT_ADD = 2; +var EDIT_DELETE = 3; +function ArraySplice() {} +ArraySplice.prototype = { +calcEditDistances: function(current, currentStart, currentEnd, old, oldStart, oldEnd) { +var rowCount = oldEnd - oldStart + 1; +var columnCount = currentEnd - currentStart + 1; +var distances = new Array(rowCount); +for (var i = 0; i < rowCount; i++) { +distances[i] = new Array(columnCount); +distances[i][0] = i; +} +for (var j = 0; j < columnCount; j++) distances[0][j] = j; +for (var i = 1; i < rowCount; i++) { +for (var j = 1; j < columnCount; j++) { +if (this.equals(current[currentStart + j - 1], old[oldStart + i - 1])) distances[i][j] = distances[i - 1][j - 1]; else { +var north = distances[i - 1][j] + 1; +var west = distances[i][j - 1] + 1; +distances[i][j] = north < west ? north : west; +} +} +} +return distances; +}, +spliceOperationsFromEditDistances: function(distances) { +var i = distances.length - 1; +var j = distances[0].length - 1; +var current = distances[i][j]; +var edits = []; +while (i > 0 || j > 0) { +if (i == 0) { +edits.push(EDIT_ADD); +j--; +continue; +} +if (j == 0) { +edits.push(EDIT_DELETE); +i--; +continue; +} +var northWest = distances[i - 1][j - 1]; +var west = distances[i - 1][j]; +var north = distances[i][j - 1]; +var min; +if (west < north) min = west < northWest ? west : northWest; else min = north < northWest ? north : northWest; +if (min == northWest) { +if (northWest == current) { +edits.push(EDIT_LEAVE); +} else { +edits.push(EDIT_UPDATE); +current = northWest; +} +i--; +j--; +} else if (min == west) { +edits.push(EDIT_DELETE); +i--; +current = west; +} else { +edits.push(EDIT_ADD); +j--; +current = north; +} +} +edits.reverse(); +return edits; +}, +calcSplices: function(current, currentStart, currentEnd, old, oldStart, oldEnd) { +var prefixCount = 0; +var suffixCount = 0; +var minLength = Math.min(currentEnd - currentStart, oldEnd - oldStart); +if (currentStart == 0 && oldStart == 0) prefixCount = this.sharedPrefix(current, old, minLength); +if (currentEnd == current.length && oldEnd == old.length) suffixCount = this.sharedSuffix(current, old, minLength - prefixCount); +currentStart += prefixCount; +oldStart += prefixCount; +currentEnd -= suffixCount; +oldEnd -= suffixCount; +if (currentEnd - currentStart == 0 && oldEnd - oldStart == 0) return []; +if (currentStart == currentEnd) { +var splice = newSplice(currentStart, [], 0); +while (oldStart < oldEnd) splice.removed.push(old[oldStart++]); +return [ splice ]; +} else if (oldStart == oldEnd) return [ newSplice(currentStart, [], currentEnd - currentStart) ]; +var ops = this.spliceOperationsFromEditDistances(this.calcEditDistances(current, currentStart, currentEnd, old, oldStart, oldEnd)); +var splice = undefined; +var splices = []; +var index = currentStart; +var oldIndex = oldStart; +for (var i = 0; i < ops.length; i++) { +switch (ops[i]) { +case EDIT_LEAVE: +if (splice) { +splices.push(splice); +splice = undefined; +} +index++; +oldIndex++; +break; + +case EDIT_UPDATE: +if (!splice) splice = newSplice(index, [], 0); +splice.addedCount++; +index++; +splice.removed.push(old[oldIndex]); +oldIndex++; +break; + +case EDIT_ADD: +if (!splice) splice = newSplice(index, [], 0); +splice.addedCount++; +index++; +break; + +case EDIT_DELETE: +if (!splice) splice = newSplice(index, [], 0); +splice.removed.push(old[oldIndex]); +oldIndex++; +break; +} +} +if (splice) { +splices.push(splice); +} +return splices; +}, +sharedPrefix: function(current, old, searchLength) { +for (var i = 0; i < searchLength; i++) if (!this.equals(current[i], old[i])) return i; +return searchLength; +}, +sharedSuffix: function(current, old, searchLength) { +var index1 = current.length; +var index2 = old.length; +var count = 0; +while (count < searchLength && this.equals(current[--index1], old[--index2])) count++; +return count; +}, +calculateSplices: function(current, previous) { +return this.calcSplices(current, 0, current.length, previous, 0, previous.length); +}, +equals: function(currentValue, previousValue) { +return currentValue === previousValue; +} +}; +return new ArraySplice(); +}(); + +Polymer.EventApi = function() { +var Settings = Polymer.Settings; +var EventApi = function(event) { +this.event = event; +}; +if (Settings.useShadow) { +EventApi.prototype = { +get rootTarget() { +return this.event.path[0]; +}, +get localTarget() { +return this.event.target; +}, +get path() { +return this.event.path; +} +}; +} else { +EventApi.prototype = { +get rootTarget() { +return this.event.target; +}, +get localTarget() { +var current = this.event.currentTarget; +var currentRoot = current && Polymer.dom(current).getOwnerRoot(); +var p$ = this.path; +for (var i = 0; i < p$.length; i++) { +if (Polymer.dom(p$[i]).getOwnerRoot() === currentRoot) { +return p$[i]; +} +} +}, +get path() { +if (!this.event._path) { +var path = []; +var o = this.rootTarget; +while (o) { +path.push(o); +o = Polymer.dom(o).parentNode || o.host; +} +path.push(window); +this.event._path = path; +} +return this.event._path; +} +}; +} +var factory = function(event) { +if (!event.__eventApi) { +event.__eventApi = new EventApi(event); +} +return event.__eventApi; +}; +return { +factory: factory +}; +}(); + +Polymer.domInnerHTML = function() { +var escapeAttrRegExp = /[&\u00A0"]/g; +var escapeDataRegExp = /[&\u00A0<>]/g; +function escapeReplace(c) { +switch (c) { +case "&": +return "&"; + +case "<": +return "<"; + +case ">": +return ">"; + +case '"': +return """; + +case "\u00A0": +return " "; +} +} +function escapeAttr(s) { +return s.replace(escapeAttrRegExp, escapeReplace); +} +function escapeData(s) { +return s.replace(escapeDataRegExp, escapeReplace); +} +function makeSet(arr) { +var set = {}; +for (var i = 0; i < arr.length; i++) { +set[arr[i]] = true; +} +return set; +} +var voidElements = makeSet([ "area", "base", "br", "col", "command", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr" ]); +var plaintextParents = makeSet([ "style", "script", "xmp", "iframe", "noembed", "noframes", "plaintext", "noscript" ]); +function getOuterHTML(node, parentNode, composed) { +switch (node.nodeType) { +case Node.ELEMENT_NODE: +var tagName = node.localName; +var s = "<" + tagName; +var attrs = node.attributes; +for (var i = 0, attr; attr = attrs[i]; i++) { +s += " " + attr.name + '="' + escapeAttr(attr.value) + '"'; +} +s += ">"; +if (voidElements[tagName]) { +return s; +} +return s + getInnerHTML(node, composed) + "</" + tagName + ">"; + +case Node.TEXT_NODE: +var data = node.data; +if (parentNode && plaintextParents[parentNode.localName]) { +return data; +} +return escapeData(data); + +case Node.COMMENT_NODE: +return "<!--" + node.data + "-->"; + +default: +console.error(node); +throw new Error("not implemented"); +} +} +function getInnerHTML(node, composed) { +if (node instanceof HTMLTemplateElement) node = node.content; +var s = ""; +var c$ = Polymer.dom(node).childNodes; +c$ = composed ? node._composedChildren : c$; +for (var i = 0, l = c$.length, child; i < l && (child = c$[i]); i++) { +s += getOuterHTML(child, node, composed); +} +return s; +} +return { +getInnerHTML: getInnerHTML +}; +}(); + +Polymer.DomApi = function() { +"use strict"; +var Settings = Polymer.Settings; +var getInnerHTML = Polymer.domInnerHTML.getInnerHTML; +var nativeInsertBefore = Element.prototype.insertBefore; +var nativeRemoveChild = Element.prototype.removeChild; +var nativeAppendChild = Element.prototype.appendChild; +var dirtyRoots = []; +var DomApi = function(node) { +this.node = node; +if (this.patch) { +this.patch(); +} +}; +DomApi.prototype = { +flush: function() { +for (var i = 0, host; i < dirtyRoots.length; i++) { +host = dirtyRoots[i]; +host.flushDebouncer("_distribute"); +} +dirtyRoots = []; +}, +_lazyDistribute: function(host) { +if (host.shadyRoot && host.shadyRoot._distributionClean) { +host.shadyRoot._distributionClean = false; +host.debounce("_distribute", host._distributeContent); +dirtyRoots.push(host); +} +}, +appendChild: function(node) { +var distributed; +this._removeNodeFromHost(node); +if (this._nodeIsInLogicalTree(this.node)) { +var host = this._hostForNode(this.node); +this._addLogicalInfo(node, this.node, host && host.shadyRoot); +this._addNodeToHost(node); +if (host) { +distributed = this._maybeDistribute(node, this.node, host); +} +} +if (!distributed && !this._tryRemoveUndistributedNode(node)) { +var container = this.node._isShadyRoot ? this.node.host : this.node; +nativeAppendChild.call(container, node); +addToComposedParent(container, node); +} +return node; +}, +insertBefore: function(node, ref_node) { +if (!ref_node) { +return this.appendChild(node); +} +var distributed; +this._removeNodeFromHost(node); +if (this._nodeIsInLogicalTree(this.node)) { +saveLightChildrenIfNeeded(this.node); +var children = this.childNodes; +var index = children.indexOf(ref_node); +if (index < 0) { +throw Error("The ref_node to be inserted before is not a child " + "of this node"); +} +var host = this._hostForNode(this.node); +this._addLogicalInfo(node, this.node, host && host.shadyRoot, index); +this._addNodeToHost(node); +if (host) { +distributed = this._maybeDistribute(node, this.node, host); +} +} +if (!distributed && !this._tryRemoveUndistributedNode(node)) { +ref_node = ref_node.localName === CONTENT ? this._firstComposedNode(ref_node) : ref_node; +var container = this.node._isShadyRoot ? this.node.host : this.node; +nativeInsertBefore.call(container, node, ref_node); +addToComposedParent(container, node, ref_node); +} +return node; +}, +removeChild: function(node) { +if (factory(node).parentNode !== this.node) { +console.warn("The node to be removed is not a child of this node", node); +} +var distributed; +if (this._nodeIsInLogicalTree(this.node)) { +var host = this._hostForNode(this.node); +distributed = this._maybeDistribute(node, this.node, host); +this._removeNodeFromHost(node); +} +if (!distributed) { +var container = this.node._isShadyRoot ? this.node.host : this.node; +if (container === node.parentNode) { +nativeRemoveChild.call(container, node); +removeFromComposedParent(container, node); +} +} +return node; +}, +replaceChild: function(node, ref_node) { +this.insertBefore(node, ref_node); +this.removeChild(ref_node); +return node; +}, +getOwnerRoot: function() { +return this._ownerShadyRootForNode(this.node); +}, +_ownerShadyRootForNode: function(node) { +if (!node) { +return; +} +if (node._ownerShadyRoot === undefined) { +var root; +if (node._isShadyRoot) { +root = node; +} else { +var parent = Polymer.dom(node).parentNode; +if (parent) { +root = parent._isShadyRoot ? parent : this._ownerShadyRootForNode(parent); +} else { +root = null; +} +} +node._ownerShadyRoot = root; +} +return node._ownerShadyRoot; +}, +_maybeDistribute: function(node, parent, host) { +var nodeNeedsDistribute = this._nodeNeedsDistribution(node); +var distribute = this._parentNeedsDistribution(parent) || nodeNeedsDistribute; +if (nodeNeedsDistribute) { +this._updateInsertionPoints(host); +} +if (distribute) { +this._lazyDistribute(host); +} +return distribute; +}, +_tryRemoveUndistributedNode: function(node) { +if (this.node.shadyRoot) { +if (node.parentNode) { +nativeRemoveChild.call(node.parentNode, node); +} +return true; +} +}, +_updateInsertionPoints: function(host) { +host.shadyRoot._insertionPoints = factory(host.shadyRoot).querySelectorAll(CONTENT); +}, +_nodeIsInLogicalTree: function(node) { +return Boolean(node._lightParent || node._isShadyRoot || this._ownerShadyRootForNode(node) || node.shadyRoot); +}, +_hostForNode: function(node) { +var root = node.shadyRoot || (node._isShadyRoot ? node : this._ownerShadyRootForNode(node)); +return root && root.host; +}, +_parentNeedsDistribution: function(parent) { +return parent && parent.shadyRoot && hasInsertionPoint(parent.shadyRoot); +}, +_nodeNeedsDistribution: function(node) { +return node.localName === CONTENT || node.nodeType === Node.DOCUMENT_FRAGMENT_NODE && node.querySelector(CONTENT); +}, +_removeNodeFromHost: function(node) { +if (node._lightParent) { +var root = this._ownerShadyRootForNode(node); +if (root) { +root.host._elementRemove(node); +} +this._removeLogicalInfo(node, node._lightParent); +} +this._removeOwnerShadyRoot(node); +}, +_addNodeToHost: function(node) { +var checkNode = node.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? node.firstChild : node; +var root = this._ownerShadyRootForNode(checkNode); +if (root) { +root.host._elementAdd(node); +} +}, +_addLogicalInfo: function(node, container, root, index) { +saveLightChildrenIfNeeded(container); +var children = factory(container).childNodes; +index = index === undefined ? children.length : index; +if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) { +var c$ = Array.prototype.slice.call(node.childNodes); +for (var i = 0, n; i < c$.length && (n = c$[i]); i++) { +children.splice(index++, 0, n); +n._lightParent = container; +} +} else { +children.splice(index, 0, node); +node._lightParent = container; +} +}, +_removeLogicalInfo: function(node, container) { +var children = factory(container).childNodes; +var index = children.indexOf(node); +if (index < 0 || container !== node._lightParent) { +throw Error("The node to be removed is not a child of this node"); +} +children.splice(index, 1); +node._lightParent = null; +}, +_removeOwnerShadyRoot: function(node) { +var hasCachedRoot = factory(node).getOwnerRoot() !== undefined; +if (hasCachedRoot) { +var c$ = factory(node).childNodes; +for (var i = 0, l = c$.length, n; i < l && (n = c$[i]); i++) { +this._removeOwnerShadyRoot(n); +} +} +node._ownerShadyRoot = undefined; +}, +_firstComposedNode: function(content) { +var n$ = factory(content).getDistributedNodes(); +for (var i = 0, l = n$.length, n, p$; i < l && (n = n$[i]); i++) { +p$ = factory(n).getDestinationInsertionPoints(); +if (p$[p$.length - 1] === content) { +return n; +} +} +}, +querySelector: function(selector) { +return this.querySelectorAll(selector)[0]; +}, +querySelectorAll: function(selector) { +return this._query(function(n) { +return matchesSelector.call(n, selector); +}, this.node); +}, +_query: function(matcher, node) { +node = node || this.node; +var list = []; +this._queryElements(factory(node).childNodes, matcher, list); +return list; +}, +_queryElements: function(elements, matcher, list) { +for (var i = 0, l = elements.length, c; i < l && (c = elements[i]); i++) { +if (c.nodeType === Node.ELEMENT_NODE) { +this._queryElement(c, matcher, list); +} +} +}, +_queryElement: function(node, matcher, list) { +if (matcher(node)) { +list.push(node); +} +this._queryElements(factory(node).childNodes, matcher, list); +}, +getDestinationInsertionPoints: function() { +return this.node._destinationInsertionPoints || []; +}, +getDistributedNodes: function() { +return this.node._distributedNodes || []; +}, +queryDistributedElements: function(selector) { +var c$ = this.childNodes; +var list = []; +this._distributedFilter(selector, c$, list); +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +if (c.localName === CONTENT) { +this._distributedFilter(selector, factory(c).getDistributedNodes(), list); +} +} +return list; +}, +_distributedFilter: function(selector, list, results) { +results = results || []; +for (var i = 0, l = list.length, d; i < l && (d = list[i]); i++) { +if (d.nodeType === Node.ELEMENT_NODE && d.localName !== CONTENT && matchesSelector.call(d, selector)) { +results.push(d); +} +} +return results; +}, +_clear: function() { +while (this.childNodes.length) { +this.removeChild(this.childNodes[0]); +} +}, +setAttribute: function(name, value) { +this.node.setAttribute(name, value); +this._distributeParent(); +}, +removeAttribute: function(name) { +this.node.removeAttribute(name); +this._distributeParent(); +}, +_distributeParent: function() { +if (this._parentNeedsDistribution(this.parentNode)) { +this._lazyDistribute(this.parentNode); +} +} +}; +Object.defineProperty(DomApi.prototype, "classList", { +get: function() { +if (!this._classList) { +this._classList = new DomApi.ClassList(this); +} +return this._classList; +}, +configurable: true +}); +DomApi.ClassList = function(host) { +this.domApi = host; +this.node = host.node; +}; +DomApi.ClassList.prototype = { +add: function() { +this.node.classList.add.apply(this.node.classList, arguments); +this.domApi._distributeParent(); +}, +remove: function() { +this.node.classList.remove.apply(this.node.classList, arguments); +this.domApi._distributeParent(); +}, +toggle: function() { +this.node.classList.toggle.apply(this.node.classList, arguments); +this.domApi._distributeParent(); +} +}; +if (!Settings.useShadow) { +Object.defineProperties(DomApi.prototype, { +childNodes: { +get: function() { +var c$ = getLightChildren(this.node); +return Array.isArray(c$) ? c$ : Array.prototype.slice.call(c$); +}, +configurable: true +}, +children: { +get: function() { +return Array.prototype.filter.call(this.childNodes, function(n) { +return n.nodeType === Node.ELEMENT_NODE; +}); +}, +configurable: true +}, +parentNode: { +get: function() { +return this.node._lightParent || (this.node.__patched ? this.node._composedParent : this.node.parentNode); +}, +configurable: true +}, +firstChild: { +get: function() { +return this.childNodes[0]; +}, +configurable: true +}, +lastChild: { +get: function() { +var c$ = this.childNodes; +return c$[c$.length - 1]; +}, +configurable: true +}, +nextSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).childNodes; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) + 1]; +} +}, +configurable: true +}, +previousSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).childNodes; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) - 1]; +} +}, +configurable: true +}, +firstElementChild: { +get: function() { +return this.children[0]; +}, +configurable: true +}, +lastElementChild: { +get: function() { +var c$ = this.children; +return c$[c$.length - 1]; +}, +configurable: true +}, +nextElementSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).children; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) + 1]; +} +}, +configurable: true +}, +previousElementSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).children; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) - 1]; +} +}, +configurable: true +}, +textContent: { +get: function() { +if (this.node.nodeType === Node.TEXT_NODE) { +return this.node.textContent; +} else { +return Array.prototype.map.call(this.childNodes, function(c) { +return c.textContent; +}).join(""); +} +}, +set: function(text) { +this._clear(); +if (text) { +this.appendChild(document.createTextNode(text)); +} +}, +configurable: true +}, +innerHTML: { +get: function() { +if (this.node.nodeType === Node.TEXT_NODE) { +return null; +} else { +return getInnerHTML(this.node); +} +}, +set: function(text) { +if (this.node.nodeType !== Node.TEXT_NODE) { +this._clear(); +var d = document.createElement("div"); +d.innerHTML = text; +for (var e = d.firstChild; e; e = e.nextSibling) { +this.appendChild(e); +} +} +}, +configurable: true +} +}); +DomApi.prototype._getComposedInnerHTML = function() { +return getInnerHTML(this.node, true); +}; +} else { +DomApi.prototype.querySelectorAll = function(selector) { +return Array.prototype.slice.call(this.node.querySelectorAll(selector)); +}; +DomApi.prototype.getOwnerRoot = function() { +var n = this.node; +while (n) { +if (n.nodeType === Node.DOCUMENT_FRAGMENT_NODE && n.host) { +return n; +} +n = n.parentNode; +} +}; +DomApi.prototype.getDestinationInsertionPoints = function() { +var n$ = this.node.getDestinationInsertionPoints(); +return n$ ? Array.prototype.slice.call(n$) : []; +}; +DomApi.prototype.getDistributedNodes = function() { +var n$ = this.node.getDistributedNodes(); +return n$ ? Array.prototype.slice.call(n$) : []; +}; +DomApi.prototype._distributeParent = function() {}; +Object.defineProperties(DomApi.prototype, { +childNodes: { +get: function() { +return Array.prototype.slice.call(this.node.childNodes); +}, +configurable: true +}, +children: { +get: function() { +return Array.prototype.slice.call(this.node.children); +}, +configurable: true +}, +textContent: { +get: function() { +return this.node.textContent; +}, +set: function(value) { +return this.node.textContent = value; +}, +configurable: true +}, +innerHTML: { +get: function() { +return this.node.innerHTML; +}, +set: function(value) { +return this.node.innerHTML = value; +}, +configurable: true +} +}); +var forwards = [ "parentNode", "firstChild", "lastChild", "nextSibling", "previousSibling", "firstElementChild", "lastElementChild", "nextElementSibling", "previousElementSibling" ]; +forwards.forEach(function(name) { +Object.defineProperty(DomApi.prototype, name, { +get: function() { +return this.node[name]; +}, +configurable: true +}); +}); +} +var CONTENT = "content"; +var factory = function(node, patch) { +node = node || document; +if (!node.__domApi) { +node.__domApi = new DomApi(node, patch); +} +return node.__domApi; +}; +Polymer.dom = function(obj, patch) { +if (obj instanceof Event) { +return Polymer.EventApi.factory(obj); +} else { +return factory(obj, patch); +} +}; +Polymer.dom.flush = DomApi.prototype.flush; +function getLightChildren(node) { +var children = node._lightChildren; +return children ? children : node.childNodes; +} +function getComposedChildren(node) { +if (!node._composedChildren) { +node._composedChildren = Array.prototype.slice.call(node.childNodes); +} +return node._composedChildren; +} +function addToComposedParent(parent, node, ref_node) { +var children = getComposedChildren(parent); +var i = ref_node ? children.indexOf(ref_node) : -1; +if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) { +var fragChildren = getComposedChildren(node); +fragChildren.forEach(function(c) { +addNodeToComposedChildren(c, parent, children, i); +}); +} else { +addNodeToComposedChildren(node, parent, children, i); +} +} +function addNodeToComposedChildren(node, parent, children, i) { +node._composedParent = parent; +if (i >= 0) { +children.splice(i, 0, node); +} else { +children.push(node); +} +} +function removeFromComposedParent(parent, node) { +node._composedParent = null; +if (parent) { +var children = getComposedChildren(parent); +var i = children.indexOf(node); +if (i >= 0) { +children.splice(i, 1); +} +} +} +function saveLightChildrenIfNeeded(node) { +if (!node._lightChildren) { +var c$ = Array.prototype.slice.call(node.childNodes); +for (var i = 0, l = c$.length, child; i < l && (child = c$[i]); i++) { +child._lightParent = child._lightParent || node; +} +node._lightChildren = c$; +} +} +function hasInsertionPoint(root) { +return Boolean(root._insertionPoints.length); +} +var p = Element.prototype; +var matchesSelector = p.matches || p.matchesSelector || p.mozMatchesSelector || p.msMatchesSelector || p.oMatchesSelector || p.webkitMatchesSelector; +return { +getLightChildren: getLightChildren, +getComposedChildren: getComposedChildren, +removeFromComposedParent: removeFromComposedParent, +saveLightChildrenIfNeeded: saveLightChildrenIfNeeded, +matchesSelector: matchesSelector, +hasInsertionPoint: hasInsertionPoint, +ctor: DomApi, +factory: factory +}; +}(); + +(function() { +Polymer.Base._addFeature({ +_prepShady: function() { +this._useContent = this._useContent || Boolean(this._template); +if (this._useContent) { +this._template._hasInsertionPoint = this._template.content.querySelector("content"); +} +}, +_poolContent: function() { +if (this._useContent) { +saveLightChildrenIfNeeded(this); +} +}, +_setupRoot: function() { +if (this._useContent) { +this._createLocalRoot(); +if (!this.dataHost) { +upgradeLightChildren(this._lightChildren); +} +} +}, +_createLocalRoot: function() { +this.shadyRoot = this.root; +this.shadyRoot._distributionClean = false; +this.shadyRoot._isShadyRoot = true; +this.shadyRoot._dirtyRoots = []; +this.shadyRoot._insertionPoints = this._template._hasInsertionPoint ? this.shadyRoot.querySelectorAll("content") : []; +saveLightChildrenIfNeeded(this.shadyRoot); +this.shadyRoot.host = this; +}, +get domHost() { +var root = Polymer.dom(this).getOwnerRoot(); +return root && root.host; +}, +distributeContent: function() { +if (this.shadyRoot) { +var host = getTopDistributingHost(this); +Polymer.dom(this)._lazyDistribute(host); +} +}, +_distributeContent: function() { +if (this._useContent && !this.shadyRoot._distributionClean) { +this._beginDistribute(); +this._distributeDirtyRoots(); +this._finishDistribute(); +} +}, +_beginDistribute: function() { +if (this._useContent && hasInsertionPoint(this.shadyRoot)) { +this._resetDistribution(); +this._distributePool(this.shadyRoot, this._collectPool()); +} +}, +_distributeDirtyRoots: function() { +var c$ = this.shadyRoot._dirtyRoots; +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +c._distributeContent(); +} +this.shadyRoot._dirtyRoots = []; +}, +_finishDistribute: function() { +if (this._useContent) { +if (hasInsertionPoint(this.shadyRoot)) { +this._composeTree(); +} else { +if (!this.shadyRoot._hasDistributed) { +this.textContent = ""; +this.appendChild(this.shadyRoot); +} else { +var children = this._composeNode(this); +this._updateChildNodes(this, children); +} +} +this.shadyRoot._hasDistributed = true; +this.shadyRoot._distributionClean = true; +} +}, +elementMatches: function(selector, node) { +node = node || this; +return matchesSelector.call(node, selector); +}, +_resetDistribution: function() { +var children = getLightChildren(this); +for (var i = 0; i < children.length; i++) { +var child = children[i]; +if (child._destinationInsertionPoints) { +child._destinationInsertionPoints = undefined; +} +if (isInsertionPoint(child)) { +clearDistributedDestinationInsertionPoints(child); +} +} +var root = this.shadyRoot; +var p$ = root._insertionPoints; +for (var j = 0; j < p$.length; j++) { +p$[j]._distributedNodes = []; +} +}, +_collectPool: function() { +var pool = []; +var children = getLightChildren(this); +for (var i = 0; i < children.length; i++) { +var child = children[i]; +if (isInsertionPoint(child)) { +pool.push.apply(pool, child._distributedNodes); +} else { +pool.push(child); +} +} +return pool; +}, +_distributePool: function(node, pool) { +var p$ = node._insertionPoints; +for (var i = 0, l = p$.length, p; i < l && (p = p$[i]); i++) { +this._distributeInsertionPoint(p, pool); +maybeRedistributeParent(p, this); +} +}, +_distributeInsertionPoint: function(content, pool) { +var anyDistributed = false; +for (var i = 0, l = pool.length, node; i < l; i++) { +node = pool[i]; +if (!node) { +continue; +} +if (this._matchesContentSelect(node, content)) { +distributeNodeInto(node, content); +pool[i] = undefined; +anyDistributed = true; +} +} +if (!anyDistributed) { +var children = getLightChildren(content); +for (var j = 0; j < children.length; j++) { +distributeNodeInto(children[j], content); +} +} +}, +_composeTree: function() { +this._updateChildNodes(this, this._composeNode(this)); +var p$ = this.shadyRoot._insertionPoints; +for (var i = 0, l = p$.length, p, parent; i < l && (p = p$[i]); i++) { +parent = p._lightParent || p.parentNode; +if (!parent._useContent && parent !== this && parent !== this.shadyRoot) { +this._updateChildNodes(parent, this._composeNode(parent)); +} +} +}, +_composeNode: function(node) { +var children = []; +var c$ = getLightChildren(node.shadyRoot || node); +for (var i = 0; i < c$.length; i++) { +var child = c$[i]; +if (isInsertionPoint(child)) { +var distributedNodes = child._distributedNodes; +for (var j = 0; j < distributedNodes.length; j++) { +var distributedNode = distributedNodes[j]; +if (isFinalDestination(child, distributedNode)) { +children.push(distributedNode); +} +} +} else { +children.push(child); +} +} +return children; +}, +_updateChildNodes: function(container, children) { +var composed = getComposedChildren(container); +var splices = Polymer.ArraySplice.calculateSplices(children, composed); +for (var i = 0, d = 0, s; i < splices.length && (s = splices[i]); i++) { +for (var j = 0, n; j < s.removed.length && (n = s.removed[j]); j++) { +remove(n); +composed.splice(s.index + d, 1); +} +d -= s.addedCount; +} +for (var i = 0, s, next; i < splices.length && (s = splices[i]); i++) { +next = composed[s.index]; +for (var j = s.index, n; j < s.index + s.addedCount; j++) { +n = children[j]; +insertBefore(container, n, next); +composed.splice(j, 0, n); +} +} +}, +_matchesContentSelect: function(node, contentElement) { +var select = contentElement.getAttribute("select"); +if (!select) { +return true; +} +select = select.trim(); +if (!select) { +return true; +} +if (!(node instanceof Element)) { +return false; +} +var validSelectors = /^(:not\()?[*.#[a-zA-Z_|]/; +if (!validSelectors.test(select)) { +return false; +} +return this.elementMatches(select, node); +}, +_elementAdd: function() {}, +_elementRemove: function() {} +}); +var saveLightChildrenIfNeeded = Polymer.DomApi.saveLightChildrenIfNeeded; +var getLightChildren = Polymer.DomApi.getLightChildren; +var matchesSelector = Polymer.DomApi.matchesSelector; +var hasInsertionPoint = Polymer.DomApi.hasInsertionPoint; +var getComposedChildren = Polymer.DomApi.getComposedChildren; +var removeFromComposedParent = Polymer.DomApi.removeFromComposedParent; +function distributeNodeInto(child, insertionPoint) { +insertionPoint._distributedNodes.push(child); +var points = child._destinationInsertionPoints; +if (!points) { +child._destinationInsertionPoints = [ insertionPoint ]; +} else { +points.push(insertionPoint); +} +} +function clearDistributedDestinationInsertionPoints(content) { +var e$ = content._distributedNodes; +for (var i = 0; i < e$.length; i++) { +var d = e$[i]._destinationInsertionPoints; +if (d) { +d.splice(d.indexOf(content) + 1, d.length); +} +} +} +function maybeRedistributeParent(content, host) { +var parent = content._lightParent; +if (parent && parent.shadyRoot && hasInsertionPoint(parent.shadyRoot) && parent.shadyRoot._distributionClean) { +parent.shadyRoot._distributionClean = false; +host.shadyRoot._dirtyRoots.push(parent); +} +} +function isFinalDestination(insertionPoint, node) { +var points = node._destinationInsertionPoints; +return points && points[points.length - 1] === insertionPoint; +} +function isInsertionPoint(node) { +return node.localName == "content"; +} +var nativeInsertBefore = Element.prototype.insertBefore; +var nativeRemoveChild = Element.prototype.removeChild; +function insertBefore(parentNode, newChild, refChild) { +var newChildParent = getComposedParent(newChild); +if (newChildParent !== parentNode) { +removeFromComposedParent(newChildParent, newChild); +} +remove(newChild); +saveLightChildrenIfNeeded(parentNode); +nativeInsertBefore.call(parentNode, newChild, refChild || null); +newChild._composedParent = parentNode; +} +function remove(node) { +var parentNode = getComposedParent(node); +if (parentNode) { +saveLightChildrenIfNeeded(parentNode); +node._composedParent = null; +nativeRemoveChild.call(parentNode, node); +} +} +function getComposedParent(node) { +return node.__patched ? node._composedParent : node.parentNode; +} +function getTopDistributingHost(host) { +while (host && hostNeedsRedistribution(host)) { +host = host.domHost; +} +return host; +} +function hostNeedsRedistribution(host) { +var c$ = Polymer.dom(host).children; +for (var i = 0, c; i < c$.length; i++) { +c = c$[i]; +if (c.localName === "content") { +return host.domHost; +} +} +} +var needsUpgrade = window.CustomElements && !CustomElements.useNative; +function upgradeLightChildren(children) { +if (needsUpgrade && children) { +for (var i = 0; i < children.length; i++) { +CustomElements.upgrade(children[i]); +} +} +} +})(); + +if (Polymer.Settings.useShadow) { +Polymer.Base._addFeature({ +_poolContent: function() {}, +_beginDistribute: function() {}, +distributeContent: function() {}, +_distributeContent: function() {}, +_finishDistribute: function() {}, +_createLocalRoot: function() { +this.createShadowRoot(); +this.shadowRoot.appendChild(this.root); +this.root = this.shadowRoot; +} +}); +} + +Polymer.DomModule = document.createElement("dom-module"); + +Polymer.Base._addFeature({ +_registerFeatures: function() { +this._prepIs(); +this._prepAttributes(); +this._prepBehaviors(); +this._prepExtends(); +this._prepConstructor(); +this._prepTemplate(); +this._prepShady(); +}, +_prepBehavior: function(b) { +this._addHostAttributes(b.hostAttributes); +}, +_initFeatures: function() { +this._poolContent(); +this._pushHost(); +this._stampTemplate(); +this._popHost(); +this._marshalHostAttributes(); +this._setupDebouncers(); +this._marshalBehaviors(); +this._tryReady(); +}, +_marshalBehavior: function(b) {} +});
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/polymer-mini.html b/third_party/polymer/v1_0/components-chromium/polymer/polymer-mini.html new file mode 100644 index 0000000..eb76276 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/polymer-mini.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="polymer-micro.html"> + +</head><body><script src="polymer-mini-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/polymer/polymer.html b/third_party/polymer/v1_0/components-chromium/polymer/polymer.html new file mode 100644 index 0000000..1fea268 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/polymer/polymer.html @@ -0,0 +1,19 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><!-- +@license +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><html><head><link rel="import" href="polymer-mini.html"> + +</head><body><script src="polymer-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/.bower.json b/third_party/polymer/v1_0/components-chromium/promise-polyfill/.bower.json new file mode 100644 index 0000000..ee0f467 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "promise-polyfill", + "version": "1.0.0", + "homepage": "https://github.com/taylorhakes/promise-polyfill", + "authors": [ + "Taylor Hakes" + ], + "description": "Lightweight promise polyfill for the browser and node. A+ Compliant.", + "main": "Promise.js", + "moduleType": [ + "globals", + "node" + ], + "keywords": [ + "promise", + "es6", + "polyfill", + "html5" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "2ef7dada161cae30e69ffff918485c57121d4b88" + }, + "_source": "git://github.com/polymerlabs/promise-polyfill.git", + "_target": "^1.0.0", + "_originalSource": "polymerlabs/promise-polyfill" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/Gruntfile.js b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Gruntfile.js new file mode 100644 index 0000000..3138444 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Gruntfile.js @@ -0,0 +1,40 @@ +module.exports = function(grunt) { + + grunt.initConfig({ + pkg: grunt.file.readJSON('package.json'), + + uglify: { + options: { + banner: '/*! <%= pkg.name %> <%= pkg.version %> */\n' + }, + dist: { + files: { + 'Promise.min.uglify.js': ['Promise.js'] + } + } + }, + + closurecompiler: { + options: { + compilation_level: 'ADVANCED_OPTIMIZATIONS', + }, + dist: { + files: { + 'Promise.min.js': ['Promise.js'] + } + } + }, + + bytesize: { + dist: { + src: ['Promise*.js'] + } + } + }); + + grunt.loadNpmTasks('grunt-contrib-uglify'); + grunt.loadNpmTasks('grunt-closurecompiler'); + grunt.loadNpmTasks('grunt-bytesize'); + + grunt.registerTask('build', ['closurecompiler', 'bytesize']); +}; diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/LICENSE b/third_party/polymer/v1_0/components-chromium/promise-polyfill/LICENSE new file mode 100644 index 0000000..94b9dac --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2014 Taylor Hakes +Copyright (c) 2014 Forbes Lindesay + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE.
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise-Statics.js b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise-Statics.js new file mode 100644 index 0000000..7ce402eb --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise-Statics.js @@ -0,0 +1,37 @@ +Promise.all = Promise.all || function () { + var args = Array.prototype.slice.call(arguments.length === 1 && Array.isArray(arguments[0]) ? arguments[0] : arguments); + + return new Promise(function (resolve, reject) { + if (args.length === 0) return resolve([]); + var remaining = args.length; + function res(i, val) { + try { + if (val && (typeof val === 'object' || typeof val === 'function')) { + var then = val.then; + if (typeof then === 'function') { + then.call(val, function (val) { res(i, val) }, reject); + return; + } + } + args[i] = val; + if (--remaining === 0) { + resolve(args); + } + } catch (ex) { + reject(ex); + } + } + for (var i = 0; i < args.length; i++) { + res(i, args[i]); + } + }); +}; + +Promise.race = Promise.race || function (values) { + return new Promise(function (resolve, reject) { + for(var i = 0, len = values.length; i < len; i++) { + values[i].then(resolve, reject); + } + }); +}; + diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise.js b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise.js new file mode 100644 index 0000000..dc6f58f --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise.js @@ -0,0 +1,128 @@ +function MakePromise (asap) { + function Promise(fn) { + if (typeof this !== 'object' || typeof fn !== 'function') throw new TypeError(); + this._state = null; + this._value = null; + this._deferreds = [] + + doResolve(fn, resolve.bind(this), reject.bind(this)); + } + + function handle(deferred) { + var me = this; + if (this._state === null) { + this._deferreds.push(deferred); + return + } + asap(function() { + var cb = me._state ? deferred.onFulfilled : deferred.onRejected + if (typeof cb !== 'function') { + (me._state ? deferred.resolve : deferred.reject)(me._value); + return; + } + var ret; + try { + ret = cb(me._value); + } + catch (e) { + deferred.reject(e); + return; + } + deferred.resolve(ret); + }) + } + + function resolve(newValue) { + try { //Promise Resolution Procedure: https://github.com/promises-aplus/promises-spec#the-promise-resolution-procedure + if (newValue === this) throw new TypeError(); + if (newValue && (typeof newValue === 'object' || typeof newValue === 'function')) { + var then = newValue.then; + if (typeof then === 'function') { + doResolve(then.bind(newValue), resolve.bind(this), reject.bind(this)); + return; + } + } + this._state = true; + this._value = newValue; + finale.call(this); + } catch (e) { reject.call(this, e); } + } + + function reject(newValue) { + this._state = false; + this._value = newValue; + finale.call(this); + } + + function finale() { + for (var i = 0, len = this._deferreds.length; i < len; i++) { + handle.call(this, this._deferreds[i]); + } + this._deferreds = null; + } + + /** + * Take a potentially misbehaving resolver function and make sure + * onFulfilled and onRejected are only called once. + * + * Makes no guarantees about asynchrony. + */ + function doResolve(fn, onFulfilled, onRejected) { + var done = false; + try { + fn(function (value) { + if (done) return; + done = true; + onFulfilled(value); + }, function (reason) { + if (done) return; + done = true; + onRejected(reason); + }) + } catch (ex) { + if (done) return; + done = true; + onRejected(ex); + } + } + + Promise.prototype['catch'] = function (onRejected) { + return this.then(null, onRejected); + }; + + Promise.prototype.then = function(onFulfilled, onRejected) { + var me = this; + return new Promise(function(resolve, reject) { + handle.call(me, { + onFulfilled: onFulfilled, + onRejected: onRejected, + resolve: resolve, + reject: reject + }); + }) + }; + + Promise.resolve = function (value) { + if (value && typeof value === 'object' && value.constructor === Promise) { + return value; + } + + return new Promise(function (resolve) { + resolve(value); + }); + }; + + Promise.reject = function (value) { + return new Promise(function (resolve, reject) { + reject(value); + }); + }; + + + return Promise; +} + +if (typeof module !== 'undefined') { + module.exports = MakePromise; +} + diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise.min.js b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise.min.js new file mode 100644 index 0000000..f37c6af --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/Promise.min.js @@ -0,0 +1,3 @@ +function m(n){function b(a){if("object"!==typeof this||"function"!==typeof a)throw new TypeError;this.c=this.a=null;this.b=[];g(a,h.bind(this),d.bind(this))}function k(a){var c=this;null===this.a?this.b.push(a):n(function(){var f=c.a?a.d:a.e;if("function"!==typeof f)(c.a?a.resolve:a.reject)(c.c);else{var e;try{e=f(c.c)}catch(b){a.reject(b);return}a.resolve(e)}})}function h(a){try{if(a===this)throw new TypeError;if(a&&("object"===typeof a||"function"===typeof a)){var c=a.then;if("function"===typeof c){g(c.bind(a), +h.bind(this),d.bind(this));return}}this.a=!0;this.c=a;l.call(this)}catch(b){d.call(this,b)}}function d(a){this.a=!1;this.c=a;l.call(this)}function l(){for(var a=0,c=this.b.length;a<c;a++)k.call(this,this.b[a]);this.b=null}function g(a,c,b){var e=!1;try{a(function(a){e||(e=!0,c(a))},function(a){e||(e=!0,b(a))})}catch(d){e||(e=!0,b(d))}}b.prototype["catch"]=function(a){return this.then(null,a)};b.prototype.then=function(a,c){var f=this;return new b(function(b,d){k.call(f,{d:a,e:c,resolve:b,reject:d})})}; +b.resolve=function(a){return a&&"object"===typeof a&&a.constructor===b?a:new b(function(b){b(a)})};b.reject=function(a){return new b(function(b,d){d(a)})};return b}"undefined"!==typeof module&&(module.f=m); diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/README.md b/third_party/polymer/v1_0/components-chromium/promise-polyfill/README.md new file mode 100644 index 0000000..de6806b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/README.md @@ -0,0 +1,13 @@ +# Promise Polyfill + +Note: this is an unsolicited fork of [taylorhakes/promise-polyfill](https://github.com/taylorhakes/promise-polyfill) +and should be considered experimental and unstable compared to upstream. + +## Testing +``` +npm install +npm test +``` + +## License +MIT diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/bower.json b/third_party/polymer/v1_0/components-chromium/promise-polyfill/bower.json new file mode 100644 index 0000000..fad59640 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/bower.json @@ -0,0 +1,31 @@ +{ + "name": "promise-polyfill", + "version": "1.0.0", + "homepage": "https://github.com/taylorhakes/promise-polyfill", + "authors": [ + "Taylor Hakes" + ], + "description": "Lightweight promise polyfill for the browser and node. A+ Compliant.", + "main": "Promise.js", + "moduleType": [ + "globals", + "node" + ], + "keywords": [ + "promise", + "es6", + "polyfill", + "html5" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/package.json b/third_party/polymer/v1_0/components-chromium/promise-polyfill/package.json new file mode 100644 index 0000000..5360534 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/package.json @@ -0,0 +1,35 @@ +{ + "name": "promise-polyfill", + "version": "2.0.0", + "description": "Lightweight promise polyfill. A+ compliant", + "main": "Promise.js", + "scripts": { + "test": "./node_modules/.bin/promises-aplus-tests tests/adapter.js; ./node_modules/.bin/promises-es6-tests tests/adapter.js" + }, + "repository": { + "type": "git", + "url": "https://taylorhakes@github.com/taylorhakes/promise-polyfill.git" + }, + "author": "Taylor Hakes", + "license": "MIT", + "bugs": { + "url": "https://github.com/taylorhakes/promise-polyfill/issues" + }, + "homepage": "https://github.com/taylorhakes/promise-polyfill", + "devDependencies": { + "grunt": "^0.4.5", + "grunt-bytesize": "^0.1.1", + "grunt-closurecompiler": "^0.9.9", + "grunt-contrib-uglify": "^0.4.0", + "mocha": "^2.2.1", + "promises-aplus-tests": "*", + "promises-es6-tests": "^0.5.0" + }, + "keywords": [ + "promise", + "promise-polyfill", + "ES6", + "promises-aplus" + ], + "dependencies": {} +} diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill-lite-extracted.js b/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill-lite-extracted.js new file mode 100644 index 0000000..dde0c89 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill-lite-extracted.js @@ -0,0 +1,4 @@ + +if (!window.Promise) { + window.Promise = MakePromise(Polymer.Base.async); +} diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill-lite.html b/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill-lite.html new file mode 100644 index 0000000..66d8906 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill-lite.html @@ -0,0 +1,3 @@ +<html><head><link rel="import" href="../polymer/polymer.html"> +<script src="./Promise.js"></script> +</head><body><script src="promise-polyfill-lite-extracted.js"></script></body></html>
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill.html b/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill.html new file mode 100644 index 0000000..94d2d2c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/promise-polyfill/promise-polyfill.html @@ -0,0 +1,2 @@ +<link rel="import" href="./promise-polyfill-lite.html"> +<script src='./Promise-Statics.js'></script> diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/.bower.json b/third_party/polymer/v1_0/components-chromium/web-animations-js/.bower.json new file mode 100644 index 0000000..f3e3715 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "web-animations-js", + "description": "JavaScript implementation of the Web Animations API", + "homepage": "https://github.com/web-animations/web-animations-js", + "main": "web-animations.min.js", + "moduleType": [ + "globals" + ], + "keywords": [ + "animations", + "polyfill" + ], + "license": "Apache-2.0", + "ignore": [ + "**/.*", + "node_modules", + "templates", + "test", + "src", + "Gruntfile.js", + "package.json", + "target-config.js", + "target-loader.js", + "web-animations.dev.html", + "web-animations.dev.js", + "web-animations-next.dev.html", + "web-animations-next.dev.js", + "web-animations-next-lite.dev.html", + "web-animations-next-lite.dev.js" + ], + "version": "2.0.0", + "_release": "2.0.0", + "_resolution": { + "type": "version", + "tag": "2.0.0", + "commit": "8a3bb632f39f8b5072c77a502eb43e880b08d94c" + }, + "_source": "git://github.com/web-animations/web-animations-js.git", + "_target": "^2.0.0", + "_originalSource": "web-animations/web-animations-js" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/COPYING b/third_party/polymer/v1_0/components-chromium/web-animations-js/COPYING new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/COPYING @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/History.md b/third_party/polymer/v1_0/components-chromium/web-animations-js/History.md new file mode 100644 index 0000000..4c50afa --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/History.md @@ -0,0 +1,108 @@ +### 2.0.0 - *April 5 2015* + + * Improve behavior of group Animation playback rate. + * Rename Animation to KeyframeEffect. + * Rename AnimationSequence to SequenceEffect. + * Rename AnimationGroup to GroupEffect. + * Rename AnimationPlayer to Animation. + * Remove KeyframeEffect.effect and add KeyframeEffect.getFrames. + * Rename Animation.source to Animation.effect. + * Rename Timeline.getAnimationPlayers to Timeline.getAnimations. + * Rename Element.getAnimationPlayers to Element.getAnimations. + +### 1.0.7 - *March 10 2015* + + * Improve performance of constructing groups and sequences. + * Remove support for animating zoom. + * Add bower file. + +### 1.0.6 - *February 5 2015* + + * Implement playbackRate setter for group players. + * Fix pausing a group player before its first tick. + * Fix cancelling a group player before its first tick. + * Fix excess CPU use on idle pages where custom effects and groups were used. + * Suppress AnimationTiming.playbackRate deprecation warning for cases where AnimationTiming.playbackRate == 1. + +### 1.0.5 - *January 6 2015* + + * Fix loading the polyfill in an SVG document + * Fix a problem where groups didn't take effect in their first frame + * Don't rely on performance.now + +### 1.0.4 - *December 8 2014* + + * Fix a critical bug where deprecation logic wasn't being loaded + when `web-animations-next` and `web-animations-next-lite` were + executed on top of a native `element.animate`. + +### 1.0.3 - *December 4 2014* + + * Fix a critical bug on iOS 7 and Safari <= 6. Due to limitations, + inline style patching is not supported on these platforms. + +### 1.0.2 - *November 28 2014* + + * Deprecated `AnimationTiming.playbackRate`. + + For example, this is no longer supported: + + var player = element.animate( + keyframes, + {duration: 1000, playbackRate: 2}); + + Use `AnimationPlayer.playbackRate` instead: + + var player = element.animate( + keyframes, + {duration: 1000}); + player.playbackRate = 2; + + If you have any feedback on this change, please start a discussion + on the public-fx mailing list: + http://lists.w3.org/Archives/Public/public-fx/ + + Or file an issue against the specification on GitHub: + https://github.com/w3c/web-animations/issues/new + +### 1.0.1 - *November 26 2014* + + * Players should be constructed in idle state + * `play()` and `reverse()` should not force a start times + * Add `requestAnimationFrame` ids and `cancelAnimationFrame` + +### 1.0.0 — *November 21 2014* + + The web-animations-js hackers are pleased to announce the release of + a new codebase for the Web Animations Polyfill: + https://github.com/web-animations/web-animations-js + + The previous polyfill has been moved to: + https://github.com/web-animations/web-animations-js-legacy + + The new codebase is focused on code-size -- our smallest target is + now only 33kb or 11kb after gzip. + + We've implemented native fallback. If the target browser provides + Web Animations features natively, the Polyfill will use them. + + We now provide three different build targets: + + `web-animations.min.js` - Tracks the Web Animations features that + are supported natively in browsers. Today that means Element.animate + and Playback Control in Chrome. If you’re not sure what features you + will need, start with this. + + `web-animations-next.min.js` - All of web-animations.min.js plus + features that are still undergoing discussion or have yet to be + implemented natively. + + `web-animations-next-lite.min.js` - A cut down version of + web-animations-next, removes several lesser used property handlers + and some of the larger and less used features such as matrix + interpolation/decomposition. + + Not all features of the previous polyfill have been ported to the + new codebase; most notably mutation of Animations and Groups and + Additive Animations are not yet supported. These features are still + important and will be implemented in the coming weeks. diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/README.md b/third_party/polymer/v1_0/components-chromium/web-animations-js/README.md new file mode 100644 index 0000000..e3e7d53 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/README.md @@ -0,0 +1,161 @@ + +Quick Start +----------- + +To provide native Chrome Web Animation features (`Element.animate` and Playback +Control) in other browsers, use `web-animations.min.js`. To explore all of the +proposed Web Animations API, use `web-animations-next.min.js`. + +What is Web Animations? +----------------------- + +Web Animations is a new JavaScript API for driving animated content on the web. +By unifying the animation features of SVG and CSS, Web Animations unlocks +features previously only usable declaratively, and exposes powerful, +high-performance animation capabilities to developers. + +For more details see the +[W3C specification](http://w3c.github.io/web-animations/). + +What is the polyfill? +--------------------- + +The polyfill is a JavaScript implementation of the Web Animations API. It works +on modern versions of all major browsers. For more details about browser +support see <https://www.polymer-project.org/resources/compatibility.html>. + +Getting Started +--------------- + +Here's a simple example of an animation that scales and changes the opacity of +a `<div>` over 0.5 seconds. The animation alternates producing a pulsing +effect. + + <script src="web-animations.min.js"></script> + <div class="pulse" style="width:150px;">Hello world!</div> + <script> + var elem = document.querySelector('.pulse'); + var animation = elem.animate([ + {opacity: 0.5, transform: "scale(0.5)"}, + {opacity: 1.0, transform: "scale(1)"} + ], { + direction: 'alternate', + duration: 500, + iterations: Infinity + }); + </script> + +Web Animations supports off-main-thread animations, and also allows procedural +generation of animations and fine-grained control of animation playback. See +<http://web-animations.github.io> for ideas and inspiration! + +Native Fallback +--------------- + +When the polyfill runs on a browser that implements `Element.animate` and +`Animation` Playback Control it will detect and use the underlying native +features. + +Different Build Targets +----------------------- + +### web-animations.min.js + +Tracks the Web Animations features that are supported natively in browsers. +Today that means Element.animate and Playback Control in Chrome. If you’re not +sure what features you will need, start with this. + +### web-animations-next.min.js + +Contains all of web-animations.min.js plus features that are still undergoing +discussion or have yet to be implemented natively. + +### web-animations-next-lite.min.js + +A cut down version of web-animations-next, it removes several lesser used +property handlers and some of the larger and less used features such as matrix +interpolation/decomposition. + +### Build Target Comparison + +| | web-animations | web-animations-next | web-animations-next-lite | +|------------------------|:--------------:|:-------------------:|:------------------------:| +|Size (gzipped) | 12.5kb | 14kb | 10.5kb | +|Element.animate | ✔ | ✔ | ✔ | +|Timing input (easings, duration, fillMode, etc.) for animation effects| ✔ | ✔ | ✔ | +|Playback control | ✔ | ✔ | ✔ | +|Support for animating lengths, transforms and opacity| ✔ | ✔ | ✔ | +|Support for animating other CSS properties| ✔ | ✔ | 🚫 | +|Matrix fallback for transform animations | ✔ | ✔ | 🚫 | +|KeyframeEffect constructor | 🚫 | ✔ | ✔ | +|Simple GroupEffects & SequenceEffects | 🚫 | ✔ | ✔ | +|Custom Effects | 🚫 | ✔ | ✔ | +|Timing input (easings, duration, fillMode, etc.) for groups</div>| 🚫 | 🚫\* | 🚫 | +|Additive animation | 🚫 | 🚫\* | 🚫 | +|Motion path | 🚫\* | 🚫\* | 🚫 | +|Modifiable keyframe effect timing| 🚫 | 🚫\* | 🚫\* | +|Modifiable group timing | 🚫 | 🚫\* | 🚫\* | +|Usable inline style\*\* | ✔ | ✔ | 🚫 | + +\* support is planned for these features. +\*\* see inline style caveat below. + +Caveats +------- + +Some things won’t ever be faithful to the native implementation due to browser +and CSS API limitations. These include: + +### Inline Style + +Inline style modification is the mechanism used by the polyfill to animate +properties. Both web-animations and web-animations-next incorporate a module +that emulates a vanilla inline style object, so that style modification from +JavaScript can still work in the presence of animations. However, to keep the +size of web-animations-next-lite as small as possible, the style emulation +module is not included. When using this version of the polyfill, JavaScript +inline style modification will be overwritten by animations. +Due to browser constraints inline style modification is not supported on iOS 7 +or Safari 6 (or earlier versions). + +### Prefix handling + +The polyfill will automatically detect the correctly prefixed name to use when +writing animated properties back to the platform. Where possible, the polyfill +will only accept unprefixed versions of experimental features. For example: + + var effect = new KeyframeEffect(elem, {"transform": "translate(100px, 100px)"}, 2000); + +will work in all browsers that implement a conforming version of transform, but + + var effect = new KeyframeEffect(elem, {"-webkit-transform": "translate(100px, 100px)"}, 2000); + +will not work anywhere. + +API and Specification Feedback +------------------------------ + +File an issue on GitHub: <https://github.com/w3c/web-animations/issues/new>. +Alternatively, send an email to <public-fx@w3.org> with subject line +“[web-animations] … message topic …” +([archives](http://lists.w3.org/Archives/Public/public-fx/)). + +Polyfill Issues +--------------- + +Report any issues with this implementation on GitHub: +<https://github.com/web-animations/web-animations-next/issues/new>. + +Breaking changes +---------------- + +When we make a potentially breaking change to the polyfill's API +surface (like a rename) we will, where possible, continue supporting the +old version, deprecated, for three months, and ensure that there are +console warnings to indicate that a change is pending. After three +months, the old version of the API surface (e.g. the old version of a +function name) will be removed. *If you see deprecation warnings you +can't avoid it by not updating*. + +We also announce anything that isn't a bug fix on +[web-animations-changes@googlegroups.com](https://groups.google.com/forum/#!forum/web-animations-changes). diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/bower.json b/third_party/polymer/v1_0/components-chromium/web-animations-js/bower.json new file mode 100644 index 0000000..22f26b5 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/bower.json @@ -0,0 +1,31 @@ +{ + "name": "web-animations-js", + "description": "JavaScript implementation of the Web Animations API", + "homepage": "https://github.com/web-animations/web-animations-js", + "main": "web-animations.min.js", + "moduleType": [ + "globals" + ], + "keywords": [ + "animations", + "polyfill" + ], + "license": "Apache-2.0", + "ignore": [ + "**/.*", + "node_modules", + "templates", + "test", + "src", + "Gruntfile.js", + "package.json", + "target-config.js", + "target-loader.js", + "web-animations.dev.html", + "web-animations.dev.js", + "web-animations-next.dev.html", + "web-animations-next.dev.js", + "web-animations-next-lite.dev.html", + "web-animations-next-lite.dev.js" + ] +} diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next-lite.min.js b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next-lite.min.js new file mode 100644 index 0000000..ad13084 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next-lite.min.js @@ -0,0 +1,17 @@ +// Copyright 2014 Google Inc. All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +!function(a,b){b["true"]=a;var c={},d={},e={},f=null;!function(a){function b(b,c){var d={delay:0,endDelay:0,fill:c?"both":"none",iterationStart:0,iterations:1,duration:c?"auto":0,playbackRate:1,direction:"normal",easing:"linear"};return"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof d[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==p.indexOf(b[c]))return;if("direction"==c&&-1==q.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;d[c]=b[c]}}):d.duration=b,d}function c(a,c){var d=b(a,c);return d.easing=f(d.easing),d}function d(a,b,c,d){return 0>a||a>1||0>c||c>1?y:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}for(var g=0,h=1;;){var i=(g+h)/2,j=f(a,c,i);if(Math.abs(e-j)<.001)return f(b,d,i);e>j?g=i:h=i}}}function e(a,b){return function(c){if(c>=1)return 1;var d=1/a;return c+=b*d,c-c%d}}function f(a){var b=w.exec(a);if(b)return d.apply(this,b.slice(1).map(Number));var c=x.exec(a);if(c)return e(Number(c[1]),{start:r,middle:s,end:t}[c[2]]);var f=u[a];return f?f:y}function g(a){return Math.abs(h(a)/a.playbackRate)}function h(a){return a.duration*a.iterations}function i(a,b,c){return null==b?z:b<c.delay?A:b>=c.delay+a?B:C}function j(a,b,c,d,e){switch(d){case A:return"backwards"==b||"both"==b?0:null;case C:return c-e;case B:return"forwards"==b||"both"==b?a:null;case z:return null}}function k(a,b,c,d){return(d.playbackRate<0?b-a:b)*d.playbackRate+c}function l(a,b,c,d,e){return 1/0===c||c===-1/0||c-d==b&&e.iterations&&(e.iterations+e.iterationStart)%1==0?a:c%a}function m(a,b,c,d){return 0===c?0:b==a?d.iterationStart+d.iterations-1:Math.floor(c/a)}function n(a,b,c,d){var e=a%2>=1,f="normal"==d.direction||d.direction==(e?"alternate-reverse":"alternate"),g=f?c:b-c,h=g/b;return b*d.easing(h)}function o(a,b,c){var d=i(a,b,c),e=j(a,c.fill,b,d,c.delay);if(null===e)return null;if(0===a)return d===A?0:1;var f=c.iterationStart*c.duration,g=k(a,e,f,c),o=l(c.duration,h(c),g,f,c),p=m(c.duration,o,g,c);return n(p,c.duration,o,c)/c.duration}var p="backwards|forwards|both|none".split("|"),q="reverse|alternate|alternate-reverse".split("|"),r=1,s=.5,t=0,u={ease:d(.25,.1,.25,1),"ease-in":d(.42,0,1,1),"ease-out":d(0,0,.58,1),"ease-in-out":d(.42,0,.58,1),"step-start":e(1,r),"step-middle":e(1,s),"step-end":e(1,t)},v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",w=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),x=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,y=function(a){return a},z=0,A=1,B=2,C=3;a.makeTiming=b,a.normalizeTimingInput=c,a.calculateActiveDuration=g,a.calculateTimeFraction=o,a.calculatePhase=i,a.toTimingFunction=f}(c,f),function(a){function b(a,b){return a in h?h[a][b]||b:b}function c(a,c,d){var g=e[a];if(g){f.style[a]=c;for(var h in g){var i=g[h],j=f.style[i];d[i]=b(i,j)}}else d[a]=b(a,c)}function d(b){function d(){var a=e.length;null==e[a-1].offset&&(e[a-1].offset=1),a>1&&null==e[0].offset&&(e[0].offset=0);for(var b=0,c=e[0].offset,d=1;a>d;d++){var f=e[d].offset;if(null!=f){for(var g=1;d-b>g;g++)e[b+g].offset=c+(f-c)*g/(d-b);b=d,c=f}}}if(!Array.isArray(b)&&null!==b)throw new TypeError("Keyframes must be null or an array of keyframes");if(null==b)return[];for(var e=b.map(function(b){var d={};for(var e in b){var f=b[e];if("offset"==e){if(null!=f&&(f=Number(f),!isFinite(f)))throw new TypeError("keyframe offsets must be numbers.")}else{if("composite"==e)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};f="easing"==e?a.toTimingFunction(f):""+f}c(e,f,d)}return void 0==d.offset&&(d.offset=null),void 0==d.easing&&(d.easing=a.toTimingFunction("linear")),d}),f=!0,g=-1/0,h=0;h<e.length;h++){var i=e[h].offset;if(null!=i){if(g>i)throw{code:DOMException.INVALID_MODIFICATION_ERR,name:"InvalidModificationError",message:"Keyframes are not loosely sorted by offset. Sort or specify offsets."};g=i}else f=!1}return e=e.filter(function(a){return a.offset>=0&&a.offset<=1}),f||d(),e}var e={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},f=document.createElementNS("http://www.w3.org/1999/xhtml","div"),g={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:g,borderLeftWidth:g,borderRightWidth:g,borderTopWidth:g,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:g,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.normalizeKeyframes=d}(c,f),function(a){var b={};a.isDeprecated=function(a,c,d,e){var f=e?"are":"is",g=new Date,h=new Date(c);return h.setMonth(h.getMonth()+3),h>g?(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,!1):!0},a.deprecated=function(b,c,d,e){var f=e?"are":"is";if(a.isDeprecated(b,c,d,e))throw new Error(b+" "+f+" no longer supported. "+d)}}(c),function(){if(document.documentElement.animate){var a=document.documentElement.animate([],0),b=!0;if(a&&(b=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach(function(c){void 0===a[c]&&(b=!0)})),!b)return}!function(a,b){function c(a){for(var b={},c=0;c<a.length;c++)for(var d in a[c])if("offset"!=d&&"easing"!=d&&"composite"!=d){var e={offset:a[c].offset,easing:a[c].easing,value:a[c][d]};b[d]=b[d]||[],b[d].push(e)}for(var f in b){var g=b[f];if(0!=g[0].offset||1!=g[g.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return b}function d(a){var c=[];for(var d in a)for(var e=a[d],f=0;f<e.length-1;f++){var g=e[f].offset,h=e[f+1].offset,i=e[f].value,j=e[f+1].value;g==h&&(1==h?i=j:j=i),c.push({startTime:g,endTime:h,easing:e[f].easing,property:d,interpolation:b.propertyInterpolation(d,i,j)})}return c.sort(function(a,b){return a.startTime-b.startTime}),c}b.convertEffectInput=function(e){var f=a.normalizeKeyframes(e),g=c(f),h=d(g);return function(a,c){if(null!=c)h.filter(function(a){return 0>=c&&0==a.startTime||c>=1&&1==a.endTime||c>=a.startTime&&c<=a.endTime}).forEach(function(d){var e=c-d.startTime,f=d.endTime-d.startTime,g=0==f?0:d.easing(e/f);b.apply(a,d.property,d.interpolation(g))});else for(var d in g)"offset"!=d&&"easing"!=d&&"composite"!=d&&b.clear(a,d)}}}(c,d,f),function(a){function b(a,b,c){e[c]=e[c]||[],e[c].push([a,b])}function c(a,c,d){for(var e=0;e<d.length;e++){var f=d[e];b(a,c,f),/-/.test(f)&&b(a,c,f.replace(/-(.)/g,function(a,b){return b.toUpperCase()}))}}function d(b,c,d){for(var f=c==d?[]:e[b],g=0;f&&g<f.length;g++){var h=f[g][0](c),i=f[g][0](d);if(void 0!==h&&void 0!==i){var j=f[g][1](h,i);if(j){var k=a.Interpolation.apply(null,j);return function(a){return 0==a?c:1==a?d:k(a)}}}}return a.Interpolation(!1,!0,function(a){return a?d:c})}var e={};a.addPropertiesHandler=c,a.propertyInterpolation=d}(d,f),function(a,b){function c(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateTimeFraction(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d._isCurrent=function(d){var e=a.calculatePhase(c,d,b);return e===PhaseActive||e===PhaseBefore},d}b.KeyframeEffect=function(d,e,f){var g,h=c(a.normalizeTimingInput(f)),i=b.convertEffectInput(e),j=function(){i(d,g)};return j._update=function(a){return g=h(a),null!==g},j._clear=function(){i(d,null)},j._hasSameTarget=function(a){return d===a},j._isCurrent=h._isCurrent,j._totalDuration=h._totalDuration,j},b.NullEffect=function(a){var b=function(){a&&(a(),a=null)};return b._update=function(){return null},b._totalDuration=0,b._isCurrent=function(){return!1},b._hasSameTarget=function(){return!1},b}}(c,d,f),function(a){a.apply=function(b,c,d){b.style[a.propertyName(c)]=d},a.clear=function(b,c){b.style[a.propertyName(c)]=""}}(d,f),function(a){window.Element.prototype.animate=function(b,c){return a.timeline._play(a.KeyframeEffect(this,b,c))}}(d),function(a){function b(a,c,d){if("number"==typeof a&&"number"==typeof c)return a*(1-d)+c*d;if("boolean"==typeof a&&"boolean"==typeof c)return.5>d?a:c;if(a.length==c.length){for(var e=[],f=0;f<a.length;f++)e.push(b(a[f],c[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+c}a.Interpolation=function(a,c,d){return function(e){return d(b(a,c,e))}}}(d,f),function(a){var b=0,c=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};a.Animation=function(a){this._sequenceNumber=b++,this._currentTime=0,this._startTime=null,this.paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!1,this.onfinish=null,this._finishHandlers=[],this._effect=a,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},a.Animation.prototype={_ensureAlive:function(){this._inEffect=this._effect._update(this.playbackRate<0&&0===this.currentTime?-1:this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,a.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this.finished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(b){b=+b,isNaN(b)||(a.restart(),this.paused||null==this._startTime||(this._startTime=this._timeline.currentTime-b/this._playbackRate),this._currentTimePending=!1,this._currentTime!=b&&(this._tickCurrentTime(b,!0),a.invalidateEffects()))},get startTime(){return this._startTime},set startTime(b){b=+b,isNaN(b)||this.paused||this._idle||(this._startTime=b,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),a.invalidateEffects())},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var b=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!=b&&(this.currentTime=b)}},get finished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this.paused&&0!=this.playbackRate||this._currentTimePending?"pending":this.paused?"paused":this.finished?"finished":"running"},play:function(){this.paused=!1,(this.finished||this._idle)&&(this._currentTime=this._playbackRate>0?0:this._totalDuration,this._startTime=null,a.invalidateEffects()),this._finishedFlag=!1,a.restart(),this._idle=!1,this._ensureAlive()},pause:function(){this.finished||this.paused||this._idle||(this._currentTimePending=!0),this._startTime=null,this.paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1)},cancel:function(){this._inEffect=!1,this._idle=!0,this.currentTime=0,this._startTime=null},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(a,b){"function"==typeof b&&"finish"==a&&this._finishHandlers.push(b)},removeEventListener:function(a,b){if("finish"==a){var c=this._finishHandlers.indexOf(b);c>=0&&this._finishHandlers.splice(c,1)}},_fireEvents:function(a){var b=this.finished;if((b||this._idle)&&!this._finishedFlag){var d=new c(this,this._currentTime,a),e=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){e.forEach(function(a){a.call(d.target,d)})},0)}this._finishedFlag=b},_tick:function(a){return this._idle||this.paused||(null==this._startTime?this.startTime=a-this._currentTime/this.playbackRate:this.finished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),this._currentTimePending=!1,this._fireEvents(a),!this._idle&&(this._inEffect||!this._finishedFlag)}}}(d,f),function(a,b){function c(a){var b=i;i=[],g(a),b.forEach(function(b){b[1](a)}),m&&g(a),f()}function d(a,b){return a._sequenceNumber-b._sequenceNumber}function e(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function f(){n.forEach(function(a){a()}),n.length=0}function g(a){l=!1;var c=b.timeline;c.currentTime=a,c._animations.sort(d),k=!1;var e=c._animations;c._animations=[];var f=[],g=[];e=e.filter(function(b){return b._inTimeline=b._tick(a),b._inEffect?g.push(b._effect):f.push(b._effect),b.finished||b.paused||b._idle||(k=!0),b._inTimeline}),n.push.apply(n,f),n.push.apply(n,g),c._animations.push.apply(c._animations,e),m=!1,k&&requestAnimationFrame(function(){})}var h=window.requestAnimationFrame,i=[],j=0;window.requestAnimationFrame=function(a){var b=j++;return 0==i.length&&h(c),i.push([b,a]),b},window.cancelAnimationFrame=function(a){i.forEach(function(b){b[0]==a&&(b[1]=function(){})})},e.prototype={_play:function(c){c._timing=a.normalizeTimingInput(c.timing);var d=new b.Animation(c);return d._idle=!1,d._timeline=this,this._animations.push(d),b.restart(),b.invalidateEffects(),d}};var k=!1,l=!1;b.restart=function(){return k||(k=!0,requestAnimationFrame(function(){}),l=!0),l};var m=!1;b.invalidateEffects=function(){m=!0};var n=[],o=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){return m&&g(p.currentTime),f(),o.apply(this,arguments)}});var p=new e;b.timeline=p}(c,d,f),function(a){function b(a,b){var c=a.exec(b);return c?(c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]):void 0}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);return c?[c[0],c[1].replace(/^\s*/,"")]:void 0}function d(a,d,e){a=c.bind(null,a);for(var f=[];;){var g=a(e);if(!g)return[f,e];if(f.push(g[0]),e=g[1],g=b(d,e),!g||""==g[1])return[f,e];e=g[1]}}function e(a,b){for(var c=0,d=0;d<b.length&&(!/\s|,/.test(b[d])||0!=c);d++)if("("==b[d])c++;else if(")"==b[d]&&(c--,0==c&&d++,0>=c))break;var e=a(b.substr(0,d));return void 0==e?void 0:[e,b.substr(d)]}function f(a,b){for(var c=a,d=b;c&&d;)c>d?c%=d:d%=c;return c=a*b/(c+d)}function g(a){return function(b){var c=a(b);return c&&(c[0]=void 0),c}}function h(a,b){return function(c){var d=a(c);return d?d:[b,c]}}function i(b,c){for(var d=[],e=0;e<b.length;e++){var f=a.consumeTrimmed(b[e],c);if(!f||""==f[0])return;void 0!==f[0]&&d.push(f[0]),c=f[1]}return""==c?d:void 0}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;j>k;k++){var l=b(d[k%d.length],e[k%e.length]);if(!l)return;g.push(l[0]),h.push(l[1]),i.push(l[2])}return[g,h,function(b){var d=b.map(function(a,b){return i[b](a)}).join(c);return a?a(d):d}]}function k(a,b,c){for(var d=[],e=[],f=[],g=0,h=0;h<c.length;h++)if("function"==typeof c[h]){var i=c[h](a[g],b[g++]);d.push(i[0]),e.push(i[1]),f.push(i[2])}else!function(a){d.push(!1),e.push(!1),f.push(function(){return c[a]})}(h);return[d,e,function(a){for(var b="",c=0;c<a.length;c++)b+=f[c](a[c]);return b}]}a.consumeToken=b,a.consumeTrimmed=c,a.consumeRepeated=d,a.consumeParenthesised=e,a.ignore=g,a.optional=h,a.consumeList=i,a.mergeNestedRepeated=j.bind(null,null),a.mergeWrappedNestedRepeated=j,a.mergeList=k}(d),function(a){function b(b){function c(b){var c=a.consumeToken(/^inset/i,b);if(c)return d.inset=!0,c;var c=a.consumeLengthOrPercent(b);if(c)return d.lengths.push(c[0]),c;var c=a.consumeColor(b);return c?(d.color=c[0],c):void 0}var d={inset:!1,lengths:[],color:null},e=a.consumeRepeated(c,/^/,b);return e&&e[0].length?[d,e[1]]:void 0}function c(c){var d=a.consumeRepeated(b,/^,/,c);return d&&""==d[1]?d[0]:void 0}function d(b,c){for(;b.lengths.length<Math.max(b.lengths.length,c.lengths.length);)b.lengths.push({px:0});for(;c.lengths.length<Math.max(b.lengths.length,c.lengths.length);)c.lengths.push({px:0});if(b.inset==c.inset&&!!b.color==!!c.color){for(var d,e=[],f=[[],0],g=[[],0],h=0;h<b.lengths.length;h++){var i=a.mergeDimensions(b.lengths[h],c.lengths[h],2==h);f[0].push(i[0]),g[0].push(i[1]),e.push(i[2])}if(b.color&&c.color){var j=a.mergeColors(b.color,c.color);f[1]=j[0],g[1]=j[1],d=j[2]}return[f,g,function(a){for(var c=b.inset?"inset ":" ",f=0;f<e.length;f++)c+=e[f](a[0][f])+" ";return d&&(c+=d(a[1])),c}]}}function e(b,c,d,e){function f(a){return{inset:a,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var g=[],h=[],i=0;i<d.length||i<e.length;i++){var j=d[i]||f(e[i].inset),k=e[i]||f(d[i].inset);g.push(j),h.push(k)}return a.mergeNestedRepeated(b,c,g,h)}var f=e.bind(null,d,", ");a.addPropertiesHandler(c,f,["box-shadow","text-shadow"])}(d),function(a){function b(a){return a.toFixed(3).replace(".000","")}function c(a,b,c){return Math.min(b,Math.max(a,c))}function d(a){return/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a)?Number(a):void 0}function e(a,c){return[a,c,b]}function f(a,b){return 0!=a?h(0,1/0)(a,b):void 0}function g(a,b){return[a,b,function(a){return Math.round(c(1,1/0,a))}]}function h(a,d){return function(e,f){return[e,f,function(e){return b(c(a,d,e))}]}}function i(a,b){return[a,b,Math.round]}a.clamp=c,a.addPropertiesHandler(d,h(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(d,h(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(d,f,["flex-grow","flex-shrink"]),a.addPropertiesHandler(d,g,["orphans","widows"]),a.addPropertiesHandler(d,i,["z-index"]),a.parseNumber=d,a.mergeNumbers=e,a.numberToString=b}(d,f),function(a){function b(a,b){return"visible"==a||"visible"==b?[0,1,function(c){return 0>=c?a:c>=1?b:"visible"}]:void 0}a.addPropertiesHandler(String,b,["visibility"])}(d),function(a){function b(a){a=a.trim(),e.fillStyle="#000",e.fillStyle=a;var b=e.fillStyle;if(e.fillStyle="#fff",e.fillStyle=a,b==e.fillStyle){e.fillRect(0,0,1,1);var c=e.getImageData(0,0,1,1).data;e.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function c(b,c){return[b,c,function(b){function c(a){return Math.max(0,Math.min(255,a))}if(b[3])for(var d=0;3>d;d++)b[d]=Math.round(c(b[d]/b[3]));return b[3]=a.numberToString(a.clamp(0,1,b[3])),"rgba("+b.join(",")+")"}]}var d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=d.height=1;var e=d.getContext("2d");a.addPropertiesHandler(b,c,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,b),a.mergeColors=c}(d,f),function(a,b){function c(a,b){if(b=b.trim().toLowerCase(),"0"==b&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var c={};b=b.replace(a,function(a){return c[a]=null,"U"+a});for(var d="U("+a.source+")",e=b.replace(/[-+]?(\d*\.)?\d+/g,"N").replace(new RegExp("N"+d,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),f=[/N\*(D)/g,/(N|D)[*/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],g=0;g<f.length;)f[g].test(e)?(e=e.replace(f[g],"$1"),g=0):g++;if("D"==e){for(var h in c){var i=eval(b.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(d,"g"),"*0"));if(!isFinite(i))return;c[h]=i}return c}}}function d(a,b){return e(a,b,!0)}function e(b,c,d){var e,f=[];for(e in b)f.push(e);for(e in c)f.indexOf(e)<0&&f.push(e);return b=f.map(function(a){return b[a]||0}),c=f.map(function(a){return c[a]||0}),[b,c,function(b){var c=b.map(function(c,e){return 1==b.length&&d&&(c=Math.max(c,0)),a.numberToString(c)+f[e]}).join(" + ");return b.length>1?"calc("+c+")":c}]}var f="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",g=c.bind(null,new RegExp(f,"g")),h=c.bind(null,new RegExp(f+"|%","g")),i=c.bind(null,/deg|rad|grad|turn/g);a.parseLength=g,a.parseLengthOrPercent=h,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,h),a.parseAngle=i,a.mergeDimensions=e;var j=a.consumeParenthesised.bind(null,g),k=a.consumeRepeated.bind(void 0,j,/^/),l=a.consumeRepeated.bind(void 0,k,/^,/);a.consumeSizePairList=l;var m=function(a){var b=l(a);return b&&""==b[1]?b[0]:void 0},n=a.mergeNestedRepeated.bind(void 0,d," "),o=a.mergeNestedRepeated.bind(void 0,n,",");a.mergeNonNegativeSizePair=n,a.addPropertiesHandler(m,o,["background-size"]),a.addPropertiesHandler(h,d,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),a.addPropertiesHandler(h,e,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","text-indent","top","vertical-align","word-spacing"])}(d,f),function(a){function b(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function c(c){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,b,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],c);return d&&4==d[0].length?d[0]:void 0}function d(b,c){return"auto"==b||"auto"==c?[!0,!1,function(d){var e=d?b:c;if("auto"==e)return"auto";var f=a.mergeDimensions(e,e);return f[2](f[0])}]:a.mergeDimensions(b,c)}function e(a){return"rect("+a+")"}var f=a.mergeWrappedNestedRepeated.bind(null,e,d,", ");a.parseBox=c,a.mergeBoxes=f,a.addPropertiesHandler(c,f,["clip"])}(d,f),function(a){function b(a){return function(b){var c=0;return a.map(function(a){return a===j?b[c++]:a})}}function c(a){return a}function d(b){if(b=b.toLowerCase().trim(),"none"==b)return[];for(var c,d=/\s*(\w+)\(([^)]*)\)/g,e=[],f=0;c=d.exec(b);){if(c.index!=f)return;f=c.index+c[0].length;var g=c[1],h=m[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var n=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(p=q?{A:function(b){return"0"==b.trim()?l:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:l,n:n[0],t:k}[r],void 0===p)return;n.push(p)}if(e.push({t:g,d:n}),d.lastIndex==b.length)return e}}function e(a){return a.toFixed(6).replace(".000000","")}function f(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var f=a.makeMatrixDecomposition(c)}return null==d[0]||null==f[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),f[0].push(1),[d,f,function(b){var c=a.quat(d[0][3],f[0][3],b[5]),g=a.composeMatrix(b[0],b[1],b[2],c,b[4]),h=g.map(e).join(",");return h}])}function g(a){return a.replace(/[xy]/,"")}function h(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function i(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var i=0;i<b.length;i++){var j=b[i].t,k=b[i].d,l="scale"==j.substr(0,5)?1:0;c.push({t:j,d:k.map(function(a){if("number"==typeof a)return l;var b={};for(var c in a)b[c]=l;return b})})}}var n=function(a,b){return"perspective"==a&&"perspective"==b||("matrix"==a||"matrix3d"==a)&&("matrix"==b||"matrix3d"==b)},o=[],p=[],q=[];if(b.length!=c.length){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var i=0;i<b.length;i++){var j,s=b[i].t,t=c[i].t,u=b[i].d,v=c[i].d,w=m[s],x=m[t];if(n(s,t)){if(!d)return;var r=f([b[i]],[c[i]]);o.push(r[0]),p.push(r[1]),q.push(["matrix",[r[2]]])}else{if(s==t)j=s;else if(w[2]&&x[2]&&g(s)==g(t))j=g(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||h(s)!=h(t)){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=h(s),u=w[1](u),v=x[1](v)}for(var y=[],z=[],A=[],B=0;B<u.length;B++){var C="number"==typeof u[B]?a.mergeNumbers:a.mergeDimensions,r=C(u[B],v[B]);y[B]=r[0],z[B]=r[1],A.push(r[2])}o.push(y),p.push(z),q.push([j,A])}}if(e){var D=o;o=p,p=D}return[o,p,function(a){return a.map(function(a,b){var c=a.map(function(a,c){return q[b][1][c](a)}).join(",");return"matrix"==q[b][0]&&16==c.split(",").length&&(q[b][0]="matrix3d"),q[b][0]+"("+c+")"}).join(" ")}]}var j=null,k={px:0},l={deg:0},m={matrix:["NNNNNN",[j,j,0,0,j,j,0,0,0,0,1,0,j,j,0,1],c],matrix3d:["NNNNNNNNNNNNNNNN",c],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",b([j,j,1]),c],scalex:["N",b([j,1,1]),b([j,1])],scaley:["N",b([1,j,1]),b([1,j])],scalez:["N",b([1,1,j])],scale3d:["NNN",c],skew:["Aa",null,c],skewx:["A",null,b([j,l])],skewy:["A",null,b([l,j])],translate:["Tt",b([j,j,k]),c],translatex:["T",b([j,k,k]),b([j,k])],translatey:["T",b([k,j,k]),b([k,j])],translatez:["L",b([k,k,j])],translate3d:["TTL",c]};a.addPropertiesHandler(d,i,["transform"])}(d,f),function(a){function b(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(c[a]=b)})}var c={};b("transform",["webkitTransform","msTransform"]),b("transformOrigin",["webkitTransformOrigin"]),b("perspective",["webkitPerspective"]),b("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return c[a]||a}}(d,f)}(),!function(a,b){function c(a){var b=window.document.timeline;b.currentTime=a,b._discardAnimations(),0==b._animations.length?d=!1:requestAnimationFrame(c)}b.AnimationTimeline=function(){this._animations=[],this.currentTime=void 0},b.AnimationTimeline.prototype={getAnimations:function(){return this._discardAnimations(),this._animations.slice()},getAnimationPlayers:function(){return a.deprecated("AnimationTimeline.getAnimationPlayers","2015-03-23","Use AnimationTimeline.getAnimations instead."),this.getAnimations()},_discardAnimations:function(){this._animations=this._animations.filter(function(a){return"finished"!=a.playState&&"idle"!=a.playState})},play:function(a){var c=new b.Animation(a);return this._animations.push(c),b.restartWebAnimationsNextTick(),c._animation.play(),c}};var d=!1;b.restartWebAnimationsNextTick=function(){d||(d=!0,requestAnimationFrame(c))};var e=new b.AnimationTimeline;b.timeline=e;try{Object.defineProperty(window.document,"timeline",{configurable:!0,get:function(){return e}})}catch(f){}try{window.document.timeline=e}catch(f){}}(c,e,f),function(a,b){b.Animation=function(a){this.effect=a,a&&(a.animation=this),this._isGroup=!1,this._animation=null,this._childAnimations=[],this._callback=null,this._rebuildUnderlyingAnimation(),this._animation.cancel()},b.Animation.prototype={_rebuildUnderlyingAnimation:function(){this._animation&&(this._animation.cancel(),this._animation=null),(!this.effect||this.effect instanceof window.KeyframeEffect)&&(this._animation=b.newUnderlyingAnimationForKeyframeEffect(this.effect),b.bindAnimationForKeyframeEffect(this)),(this.effect instanceof window.SequenceEffect||this.effect instanceof window.GroupEffect)&&(this._animation=b.newUnderlyingAnimationForGroup(this.effect),b.bindAnimationForGroup(this))},_updateChildren:function(){if(this.effect&&"idle"!=this.playState){var a=this.effect._timing.delay;this._childAnimations.forEach(function(c){this._arrangeChildren(c,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c.effect))}.bind(this))}},_setExternalAnimation:function(a){if(this.effect&&this._isGroup)for(var b=0;b<this.effect.children.length;b++)this.effect.children[b].animation=a,this._childAnimations[b]._setExternalAnimation(a)},_constructChildren:function(){if(this.effect&&this._isGroup){var a=this.effect._timing.delay;this.effect.children.forEach(function(c){var d=window.document.timeline.play(c);this._childAnimations.push(d),d.playbackRate=this.playbackRate,this.paused&&d.pause(),c.animation=this.effect.animation,this._arrangeChildren(d,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c))}.bind(this))}},_arrangeChildren:function(a,b){null===this.startTime?(a.currentTime=this.currentTime-b/this.playbackRate,a._startTime=null):a.startTime!==this.startTime+b/this.playbackRate&&(a.startTime=this.startTime+b/this.playbackRate)},get paused(){return this._animation.paused},get playState(){return this._animation.playState},get onfinish(){return this._onfinish},set onfinish(a){"function"==typeof a?(this._onfinish=a,this._animation.onfinish=function(b){b.target=this,a.call(this,b)}.bind(this)):(this._animation.onfinish=a,this.onfinish=this._animation.onfinish)},get currentTime(){return this._animation.currentTime},set currentTime(a){this._animation.currentTime=a,this._register(),this._forEachChild(function(b,c){b.currentTime=a-c})},get startTime(){return this._animation.startTime},set startTime(a){this._animation.startTime=a,this._register(),this._forEachChild(function(b,c){b.startTime=a+c})},get playbackRate(){return this._animation.playbackRate},set playbackRate(a){var b=this.currentTime;this._animation.playbackRate=a,this._forEachChild(function(b){b.playbackRate=a}),"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!==b&&(this.currentTime=b)},get finished(){return this._animation.finished},get source(){return a.deprecated("Animation.source","2015-03-23","Use Animation.effect instead."),this.effect},play:function(){this._animation.play(),this._register(),b.awaitStartTime(this),this._forEachChild(function(a){var b=a.currentTime;a.play(),a.currentTime=b})},pause:function(){this._animation.pause(),this._register(),this._forEachChild(function(a){a.pause()})},finish:function(){this._animation.finish(),this._register()},cancel:function(){this._animation.cancel(),this._register(),this._removeChildren()},reverse:function(){var a=this.currentTime;this._animation.reverse(),this._forEachChild(function(a){a.reverse()}),null!==a&&(this.currentTime=a)},addEventListener:function(a,b){var c=b;"function"==typeof b&&(c=function(a){a.target=this,b.call(this,a)}.bind(this),b._wrapper=c),this._animation.addEventListener(a,c)},removeEventListener:function(a,b){this._animation.removeEventListener(a,b&&b._wrapper||b)},_removeChildren:function(){for(;this._childAnimations.length;)this._childAnimations.pop().cancel()},_forEachChild:function(b){var c=0;if(this.effect.children&&this._childAnimations.length<this.effect.children.length&&this._constructChildren(),this._childAnimations.forEach(function(a){b.call(this,a,c),this.effect instanceof window.SequenceEffect&&(c+=a.effect.activeDuration)}.bind(this)),"pending"!=this._animation.playState){var d=this.effect._timing,e=this._animation.currentTime;null!==e&&(e=a.calculateTimeFraction(a.calculateActiveDuration(d),e,d)),(null==e||isNaN(e))&&this._removeChildren()}}}}(c,e,f),function(a,b){function c(b){this._frames=a.normalizeKeyframes(b)}function d(){for(var a=!1;g.length;)g.shift()._updateChildren(),a=!0;return a}b.KeyframeEffect=function(b,d,e){return this.target=b,this._timingInput=e,this._timing=a.normalizeTimingInput(e),this.timing=a.makeTiming(e),this._normalizedKeyframes="function"==typeof d?d:new c(d),this._keyframes=d,this.activeDuration=a.calculateActiveDuration(this._timing),this +},b.KeyframeEffect.prototype={getFrames:function(){return"function"==typeof this._normalizedKeyframes?this._normalizedKeyframes:this._normalizedKeyframes._frames},get effect(){return a.deprecated("KeyframeEffect.effect","2015-03-23","Use KeyframeEffect.getFrames() instead."),this._normalizedKeyframes}};var e=Element.prototype.animate;Element.prototype.animate=function(a,c){return b.timeline.play(new b.KeyframeEffect(this,a,c))};var f=document.createElementNS("http://www.w3.org/1999/xhtml","div");b.newUnderlyingAnimationForKeyframeEffect=function(a){var b=a.target||f,c=a._keyframes;return"function"==typeof c&&(c=[]),e.apply(b,[c,a._timingInput])},b.bindAnimationForKeyframeEffect=function(a){a.effect&&"function"==typeof a.effect._normalizedKeyframes&&b.bindAnimationForCustomEffect(a)};var g=[];b.awaitStartTime=function(a){null===a.startTime&&a._isGroup&&(0==g.length&&requestAnimationFrame(d),g.push(a))};var h=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){var a=h.apply(this,arguments);return d()&&(a=h.apply(this,arguments)),a}}),window.KeyframeEffect=b.KeyframeEffect,window.Element.prototype.getAnimations=function(){return document.timeline.getAnimations().filter(function(a){return null!==a.effect&&a.effect.target==this}.bind(this))},window.Element.prototype.getAnimationPlayers=function(){return a.deprecated("Element.getAnimationPlayers","2015-03-23","Use Element.getAnimations instead."),this.getAnimations()},window.Animation=function(){a.deprecated("window.Animation","2015-03-23","Use window.KeyframeEffect instead."),window.KeyframeEffect.apply(this,arguments)},window.Animation.prototype=Object.create(window.KeyframeEffect.prototype),window.Animation.prototype.constructor=window.Animation}(c,e,f),function(a,b){function c(a){a._registered||(a._registered=!0,f.push(a),g||(g=!0,requestAnimationFrame(d)))}function d(){var a=f;f=[],a.sort(function(a,b){return a._sequenceNumber-b._sequenceNumber}),a=a.filter(function(a){a();var b=a._animation?a._animation.playState:"idle";return"running"!=b&&"pending"!=b&&(a._registered=!1),a._registered}),f.push.apply(f,a),f.length?(g=!0,requestAnimationFrame(d)):g=!1}var e=(document.createElementNS("http://www.w3.org/1999/xhtml","div"),0);b.bindAnimationForCustomEffect=function(b){var d=b.effect.target,f=b.effect._normalizedKeyframes,g=b.effect.timing,h=null;g=a.normalizeTimingInput(g);var i=function(){var c=i._animation?i._animation.currentTime:null;null!==c&&(c=a.calculateTimeFraction(a.calculateActiveDuration(g),c,g),isNaN(c)&&(c=null)),c!==h&&f(c,d,b.effect),h=c};i._animation=b,i._registered=!1,i._sequenceNumber=e++,b._callback=i,c(i)};var f=[],g=!1;b.Animation.prototype._register=function(){this._callback&&c(this._callback)}}(c,e,f),function(a,b){function c(a){return a._timing.delay+a.activeDuration+a._timing.endDelay}function d(b,c){this.children=b||[],this._timing=a.normalizeTimingInput(c,!0),this.timing=a.makeTiming(c,!0),"auto"===this._timing.duration&&(this._timing.duration=this.activeDuration)}window.SequenceEffect=function(){d.apply(this,arguments)},window.GroupEffect=function(){d.apply(this,arguments)},window.SequenceEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a+=c(b)}),Math.max(a,0)}},window.GroupEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a=Math.max(a,c(b))}),a}},b.newUnderlyingAnimationForGroup=function(c){var d,e=null,f=function(b){var c=d._wrapper;return"pending"!=c.playState&&c.effect?null==b?void c._removeChildren():0==b&&c.playbackRate<0&&(e||(e=a.normalizeTimingInput(c.effect.timing)),b=a.calculateTimeFraction(a.calculateActiveDuration(e),-1,e),isNaN(b)||null==b)?(c._forEachChild(function(a){a.currentTime=-1}),void c._removeChildren()):void 0:void 0};return d=b.timeline.play(new b.KeyframeEffect(null,f,c._timing))},b.bindAnimationForGroup=function(a){a._animation._wrapper=a,a._isGroup=!0,b.awaitStartTime(a),a._constructChildren(),a._setExternalAnimation(a)},b.groupChildDuration=c,window.AnimationSequence=function(){a.deprecated("window.AnimationSequence","2015-03-23","Use window.SequenceEffect instead."),window.SequenceEffect.apply(this,arguments)},window.AnimationSequence.prototype=Object.create(window.SequenceEffect.prototype),window.AnimationSequence.prototype.constructor=window.AnimationSequence,window.AnimationGroup=function(){a.deprecated("window.AnimationGroup","2015-03-23","Use window.GroupEffect instead."),window.GroupEffect.apply(this,arguments)},window.AnimationGroup.prototype=Object.create(window.GroupEffect.prototype),window.AnimationGroup.prototype.constructor=window.AnimationGroup}(c,e,f)}({},function(){return this}()); +//# sourceMappingURL=web-animations-next-lite.min.js.map
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next-lite.min.js.map b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next-lite.min.js.map new file mode 100644 index 0000000..51f503b --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next-lite.min.js.map @@ -0,0 +1 @@ +{"version":3,"file":"web-animations-next-lite.min.js","sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/timeline.js","src/web-animations-next-animation.js","src/keyframe-effect-constructor.js","src/effect-callback.js","src/group-constructors.js"],"names":["webAnimationsShared","webAnimations1","webAnimationsNext","webAnimationsTesting","shared","makeTiming","timingInput","forGroup","timing","delay","endDelay","fill","iterationStart","iterations","duration","playbackRate","direction","easing","isNaN","undefined","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","isDeprecated","normalizeTimingInput","toTimingFunction","cubic","a","b","c","d","linear","x","f","m","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","cubicData","cubicBezierRe","exec","apply","this","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","preset","presets","calculateActiveDuration","repeatedDuration","calculatePhase","activeDuration","localTime","PhaseNone","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateScaledActiveTime","activeTime","startOffset","calculateIterationTime","iterationDuration","scaledActiveTime","Infinity","calculateCurrentIteration","iterationTime","floor","calculateTransformedTime","currentIteration","currentIterationIsOdd","currentDirectionIsForwards","directedTime","timeFraction","calculateTimeFraction","split","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","value","aliases","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","style","i","longProperty","longhandValue","normalizeKeyframes","effectInput","spaceKeyframes","length","keyframes","offset","previousIndex","previousOffset","j","Array","isArray","TypeError","originalKeyframe","keyframe","member","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","code","INVALID_MODIFICATION_ERR","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","document","createElementNS","borderWidthAliases","thin","medium","thick","borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","fontSize","xx-small","x-small","small","large","x-large","xx-large","fontWeight","normal","bold","outlineWidth","textShadow","none","boxShadow","silenced","feature","date","advice","plural","auxVerb","today","Date","expiry","setMonth","getMonth","console","warn","toDateString","deprecated","Error","scope","webAnimationsNextTick","t","timeline","window","currentTime","_discardAnimations","_animations","ticking","requestAnimationFrame","AnimationTimeline","prototype","getAnimations","getAnimationPlayers","animation","playState","play","effect","Animation","push","restartWebAnimationsNextTick","_animation","defineProperty","configurable","get","e","_isGroup","_childAnimations","_callback","_rebuildUnderlyingAnimation","cancel","KeyframeEffect","newUnderlyingAnimationForKeyframeEffect","bindAnimationForKeyframeEffect","SequenceEffect","GroupEffect","newUnderlyingAnimationForGroup","bindAnimationForGroup","_updateChildren","_timing","childAnimation","_arrangeChildren","groupChildDuration","bind","_setExternalAnimation","children","_constructChildren","child","paused","pause","startTime","_startTime",{"end":{"file":"src/animation.js","comments_before":[],"nlb":false,"endpos":2465,"pos":2454,"col":8,"line":72,"value":"currentTime","type":"name"},"start":{"file":"src/animation.js","comments_before":[],"nlb":false,"endpos":2465,"pos":2454,"col":8,"line":72,"value":"currentTime","type":"name"},"name":"currentTime"},"onfinish","_onfinish","v","target","call","_register","_forEachChild","oldCurrentTime","finished","source","awaitStartTime","time","finish","_removeChildren","reverse","addEventListener","handler","wrapped","_wrapper","removeEventListener","pop","KeyframeList","_frames","updatePendingGroups","updated","pendingGroups","shift","_timingInput","_normalizedKeyframes","_keyframes","getFrames","originalElementAnimate","Element","animate","nullTarget","keyframeEffect","bindAnimationForCustomEffect","groupAnimation","originalGetComputedStyle","getComputedStyle","enumerable","arguments","create","constructor","register","callback","_registered","callbacks","tick","updating","sort","left","right","_sequenceNumber","sequenceNumber","effectFunction","last","node","total","max","group","underlyingAnimation","ticker","tf","AnimationSequence","AnimationGroup"],"mappings":"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"}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next.min.js b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next.min.js new file mode 100644 index 0000000..f163ff3 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next.min.js @@ -0,0 +1,17 @@ +// Copyright 2014 Google Inc. All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +!function(a,b){b["true"]=a;var c={},d={},e={},f=null;!function(a){function b(b,c){var d={delay:0,endDelay:0,fill:c?"both":"none",iterationStart:0,iterations:1,duration:c?"auto":0,playbackRate:1,direction:"normal",easing:"linear"};return"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof d[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==p.indexOf(b[c]))return;if("direction"==c&&-1==q.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;d[c]=b[c]}}):d.duration=b,d}function c(a,c){var d=b(a,c);return d.easing=f(d.easing),d}function d(a,b,c,d){return 0>a||a>1||0>c||c>1?y:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}for(var g=0,h=1;;){var i=(g+h)/2,j=f(a,c,i);if(Math.abs(e-j)<.001)return f(b,d,i);e>j?g=i:h=i}}}function e(a,b){return function(c){if(c>=1)return 1;var d=1/a;return c+=b*d,c-c%d}}function f(a){var b=w.exec(a);if(b)return d.apply(this,b.slice(1).map(Number));var c=x.exec(a);if(c)return e(Number(c[1]),{start:r,middle:s,end:t}[c[2]]);var f=u[a];return f?f:y}function g(a){return Math.abs(h(a)/a.playbackRate)}function h(a){return a.duration*a.iterations}function i(a,b,c){return null==b?z:b<c.delay?A:b>=c.delay+a?B:C}function j(a,b,c,d,e){switch(d){case A:return"backwards"==b||"both"==b?0:null;case C:return c-e;case B:return"forwards"==b||"both"==b?a:null;case z:return null}}function k(a,b,c,d){return(d.playbackRate<0?b-a:b)*d.playbackRate+c}function l(a,b,c,d,e){return 1/0===c||c===-1/0||c-d==b&&e.iterations&&(e.iterations+e.iterationStart)%1==0?a:c%a}function m(a,b,c,d){return 0===c?0:b==a?d.iterationStart+d.iterations-1:Math.floor(c/a)}function n(a,b,c,d){var e=a%2>=1,f="normal"==d.direction||d.direction==(e?"alternate-reverse":"alternate"),g=f?c:b-c,h=g/b;return b*d.easing(h)}function o(a,b,c){var d=i(a,b,c),e=j(a,c.fill,b,d,c.delay);if(null===e)return null;if(0===a)return d===A?0:1;var f=c.iterationStart*c.duration,g=k(a,e,f,c),o=l(c.duration,h(c),g,f,c),p=m(c.duration,o,g,c);return n(p,c.duration,o,c)/c.duration}var p="backwards|forwards|both|none".split("|"),q="reverse|alternate|alternate-reverse".split("|"),r=1,s=.5,t=0,u={ease:d(.25,.1,.25,1),"ease-in":d(.42,0,1,1),"ease-out":d(0,0,.58,1),"ease-in-out":d(.42,0,.58,1),"step-start":e(1,r),"step-middle":e(1,s),"step-end":e(1,t)},v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",w=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),x=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,y=function(a){return a},z=0,A=1,B=2,C=3;a.makeTiming=b,a.normalizeTimingInput=c,a.calculateActiveDuration=g,a.calculateTimeFraction=o,a.calculatePhase=i,a.toTimingFunction=f}(c,f),function(a){function b(a,b){return a in h?h[a][b]||b:b}function c(a,c,d){var g=e[a];if(g){f.style[a]=c;for(var h in g){var i=g[h],j=f.style[i];d[i]=b(i,j)}}else d[a]=b(a,c)}function d(b){function d(){var a=e.length;null==e[a-1].offset&&(e[a-1].offset=1),a>1&&null==e[0].offset&&(e[0].offset=0);for(var b=0,c=e[0].offset,d=1;a>d;d++){var f=e[d].offset;if(null!=f){for(var g=1;d-b>g;g++)e[b+g].offset=c+(f-c)*g/(d-b);b=d,c=f}}}if(!Array.isArray(b)&&null!==b)throw new TypeError("Keyframes must be null or an array of keyframes");if(null==b)return[];for(var e=b.map(function(b){var d={};for(var e in b){var f=b[e];if("offset"==e){if(null!=f&&(f=Number(f),!isFinite(f)))throw new TypeError("keyframe offsets must be numbers.")}else{if("composite"==e)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};f="easing"==e?a.toTimingFunction(f):""+f}c(e,f,d)}return void 0==d.offset&&(d.offset=null),void 0==d.easing&&(d.easing=a.toTimingFunction("linear")),d}),f=!0,g=-1/0,h=0;h<e.length;h++){var i=e[h].offset;if(null!=i){if(g>i)throw{code:DOMException.INVALID_MODIFICATION_ERR,name:"InvalidModificationError",message:"Keyframes are not loosely sorted by offset. Sort or specify offsets."};g=i}else f=!1}return e=e.filter(function(a){return a.offset>=0&&a.offset<=1}),f||d(),e}var e={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},f=document.createElementNS("http://www.w3.org/1999/xhtml","div"),g={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:g,borderLeftWidth:g,borderRightWidth:g,borderTopWidth:g,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:g,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.normalizeKeyframes=d}(c,f),function(a){var b={};a.isDeprecated=function(a,c,d,e){var f=e?"are":"is",g=new Date,h=new Date(c);return h.setMonth(h.getMonth()+3),h>g?(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,!1):!0},a.deprecated=function(b,c,d,e){var f=e?"are":"is";if(a.isDeprecated(b,c,d,e))throw new Error(b+" "+f+" no longer supported. "+d)}}(c),function(){if(document.documentElement.animate){var a=document.documentElement.animate([],0),b=!0;if(a&&(b=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach(function(c){void 0===a[c]&&(b=!0)})),!b)return}!function(a,b){function c(a){for(var b={},c=0;c<a.length;c++)for(var d in a[c])if("offset"!=d&&"easing"!=d&&"composite"!=d){var e={offset:a[c].offset,easing:a[c].easing,value:a[c][d]};b[d]=b[d]||[],b[d].push(e)}for(var f in b){var g=b[f];if(0!=g[0].offset||1!=g[g.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return b}function d(a){var c=[];for(var d in a)for(var e=a[d],f=0;f<e.length-1;f++){var g=e[f].offset,h=e[f+1].offset,i=e[f].value,j=e[f+1].value;g==h&&(1==h?i=j:j=i),c.push({startTime:g,endTime:h,easing:e[f].easing,property:d,interpolation:b.propertyInterpolation(d,i,j)})}return c.sort(function(a,b){return a.startTime-b.startTime}),c}b.convertEffectInput=function(e){var f=a.normalizeKeyframes(e),g=c(f),h=d(g);return function(a,c){if(null!=c)h.filter(function(a){return 0>=c&&0==a.startTime||c>=1&&1==a.endTime||c>=a.startTime&&c<=a.endTime}).forEach(function(d){var e=c-d.startTime,f=d.endTime-d.startTime,g=0==f?0:d.easing(e/f);b.apply(a,d.property,d.interpolation(g))});else for(var d in g)"offset"!=d&&"easing"!=d&&"composite"!=d&&b.clear(a,d)}}}(c,d,f),function(a){function b(a,b,c){e[c]=e[c]||[],e[c].push([a,b])}function c(a,c,d){for(var e=0;e<d.length;e++){var f=d[e];b(a,c,f),/-/.test(f)&&b(a,c,f.replace(/-(.)/g,function(a,b){return b.toUpperCase()}))}}function d(b,c,d){for(var f=c==d?[]:e[b],g=0;f&&g<f.length;g++){var h=f[g][0](c),i=f[g][0](d);if(void 0!==h&&void 0!==i){var j=f[g][1](h,i);if(j){var k=a.Interpolation.apply(null,j);return function(a){return 0==a?c:1==a?d:k(a)}}}}return a.Interpolation(!1,!0,function(a){return a?d:c})}var e={};a.addPropertiesHandler=c,a.propertyInterpolation=d}(d,f),function(a,b){function c(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateTimeFraction(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d._isCurrent=function(d){var e=a.calculatePhase(c,d,b);return e===PhaseActive||e===PhaseBefore},d}b.KeyframeEffect=function(d,e,f){var g,h=c(a.normalizeTimingInput(f)),i=b.convertEffectInput(e),j=function(){i(d,g)};return j._update=function(a){return g=h(a),null!==g},j._clear=function(){i(d,null)},j._hasSameTarget=function(a){return d===a},j._isCurrent=h._isCurrent,j._totalDuration=h._totalDuration,j},b.NullEffect=function(a){var b=function(){a&&(a(),a=null)};return b._update=function(){return null},b._totalDuration=0,b._isCurrent=function(){return!1},b._hasSameTarget=function(){return!1},b}}(c,d,f),function(a){function b(a,b,c){c.enumerable=!0,c.configurable=!0,Object.defineProperty(a,b,c)}function c(a){this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=a.style,this._length=0,this._isAnimatedProperty={};for(var b=0;b<this._style.length;b++){var c=this._style[b];this._surrogateStyle[c]=this._style[c]}this._updateIndices()}function d(a){if(!a._webAnimationsPatchedStyle){var d=new c(a);try{b(a,"style",{get:function(){return d}})}catch(e){a.style._set=function(b,c){a.style[b]=c},a.style._clear=function(b){a.style[b]=""}}a._webAnimationsPatchedStyle=a.style}}var e={cssText:1,length:1,parentRule:1},f={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},g={removeProperty:1,setProperty:1};c.prototype={get cssText(){return this._surrogateStyle.cssText},set cssText(a){for(var b={},c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;this._surrogateStyle.cssText=a,this._updateIndices();for(var c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;for(var d in b)this._isAnimatedProperty[d]||this._style.setProperty(d,this._surrogateStyle.getPropertyValue(d))},get length(){return this._surrogateStyle.length},get parentRule(){return this._style.parentRule},_updateIndices:function(){for(;this._length<this._surrogateStyle.length;)Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,get:function(a){return function(){return this._surrogateStyle[a]}}(this._length)}),this._length++;for(;this._length>this._surrogateStyle.length;)this._length--,Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,value:void 0})},_set:function(a,b){this._style[a]=b,this._isAnimatedProperty[a]=!0},_clear:function(a){this._style[a]=this._surrogateStyle[a],delete this._isAnimatedProperty[a]}};for(var h in f)c.prototype[h]=function(a,b){return function(){var c=this._surrogateStyle[a].apply(this._surrogateStyle,arguments);return b&&(this._isAnimatedProperty[arguments[0]]||this._style[a].apply(this._style,arguments),this._updateIndices()),c}}(h,h in g);for(var i in document.documentElement.style)i in e||i in f||!function(a){b(c.prototype,a,{get:function(){return this._surrogateStyle[a]},set:function(b){this._surrogateStyle[a]=b,this._updateIndices(),this._isAnimatedProperty[a]||(this._style[a]=b)}})}(i);a.apply=function(b,c,e){d(b),b.style._set(a.propertyName(c),e)},a.clear=function(b,c){b._webAnimationsPatchedStyle&&b.style._clear(a.propertyName(c))}}(d,f),function(a){window.Element.prototype.animate=function(b,c){return a.timeline._play(a.KeyframeEffect(this,b,c))}}(d),function(a){function b(a,c,d){if("number"==typeof a&&"number"==typeof c)return a*(1-d)+c*d;if("boolean"==typeof a&&"boolean"==typeof c)return.5>d?a:c;if(a.length==c.length){for(var e=[],f=0;f<a.length;f++)e.push(b(a[f],c[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+c}a.Interpolation=function(a,c,d){return function(e){return d(b(a,c,e))}}}(d,f),function(a){function b(a,b,c){return Math.max(Math.min(a,c),b)}function c(c,d,e){var f=a.dot(c,d);f=b(f,-1,1);var g=[];if(1===f)g=c;else for(var h=Math.acos(f),i=1*Math.sin(e*h)/Math.sqrt(1-f*f),j=0;4>j;j++)g.push(c[j]*(Math.cos(e*h)-f*i)+d[j]*i);return g}var d=function(){function a(a,b){for(var c=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],d=0;4>d;d++)for(var e=0;4>e;e++)for(var f=0;4>f;f++)c[d][e]+=b[d][f]*a[f][e];return c}function b(a){return 0==a[0][2]&&0==a[0][3]&&0==a[1][2]&&0==a[1][3]&&0==a[2][0]&&0==a[2][1]&&1==a[2][2]&&0==a[2][3]&&0==a[3][2]&&1==a[3][3]}function c(c,d,e,f,g){for(var h=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],i=0;4>i;i++)h[i][3]=g[i];for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[3][i]+=c[j]*h[j][i];var k=f[0],l=f[1],m=f[2],n=f[3],o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];o[0][0]=1-2*(l*l+m*m),o[0][1]=2*(k*l-m*n),o[0][2]=2*(k*m+l*n),o[1][0]=2*(k*l+m*n),o[1][1]=1-2*(k*k+m*m),o[1][2]=2*(l*m-k*n),o[2][0]=2*(k*m-l*n),o[2][1]=2*(l*m+k*n),o[2][2]=1-2*(k*k+l*l),h=a(h,o);var p=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];e[2]&&(p[2][1]=e[2],h=a(h,p)),e[1]&&(p[2][1]=0,p[2][0]=e[0],h=a(h,p)),e[0]&&(p[2][0]=0,p[1][0]=e[0],h=a(h,p));for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[i][j]*=d[i];return b(h)?[h[0][0],h[0][1],h[1][0],h[1][1],h[3][0],h[3][1]]:h[0].concat(h[1],h[2],h[3])}return c}();a.composeMatrix=d,a.quat=c}(d,f),function(a){var b=0,c=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};a.Animation=function(a){this._sequenceNumber=b++,this._currentTime=0,this._startTime=null,this.paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!1,this.onfinish=null,this._finishHandlers=[],this._effect=a,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},a.Animation.prototype={_ensureAlive:function(){this._inEffect=this._effect._update(this.playbackRate<0&&0===this.currentTime?-1:this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,a.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this.finished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(b){b=+b,isNaN(b)||(a.restart(),this.paused||null==this._startTime||(this._startTime=this._timeline.currentTime-b/this._playbackRate),this._currentTimePending=!1,this._currentTime!=b&&(this._tickCurrentTime(b,!0),a.invalidateEffects()))},get startTime(){return this._startTime},set startTime(b){b=+b,isNaN(b)||this.paused||this._idle||(this._startTime=b,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),a.invalidateEffects())},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var b=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!=b&&(this.currentTime=b)}},get finished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this.paused&&0!=this.playbackRate||this._currentTimePending?"pending":this.paused?"paused":this.finished?"finished":"running"},play:function(){this.paused=!1,(this.finished||this._idle)&&(this._currentTime=this._playbackRate>0?0:this._totalDuration,this._startTime=null,a.invalidateEffects()),this._finishedFlag=!1,a.restart(),this._idle=!1,this._ensureAlive()},pause:function(){this.finished||this.paused||this._idle||(this._currentTimePending=!0),this._startTime=null,this.paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1)},cancel:function(){this._inEffect=!1,this._idle=!0,this.currentTime=0,this._startTime=null},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(a,b){"function"==typeof b&&"finish"==a&&this._finishHandlers.push(b)},removeEventListener:function(a,b){if("finish"==a){var c=this._finishHandlers.indexOf(b);c>=0&&this._finishHandlers.splice(c,1)}},_fireEvents:function(a){var b=this.finished;if((b||this._idle)&&!this._finishedFlag){var d=new c(this,this._currentTime,a),e=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){e.forEach(function(a){a.call(d.target,d)})},0)}this._finishedFlag=b},_tick:function(a){return this._idle||this.paused||(null==this._startTime?this.startTime=a-this._currentTime/this.playbackRate:this.finished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),this._currentTimePending=!1,this._fireEvents(a),!this._idle&&(this._inEffect||!this._finishedFlag)}}}(d,f),function(a,b){function c(a){var b=i;i=[],g(a),b.forEach(function(b){b[1](a)}),m&&g(a),f()}function d(a,b){return a._sequenceNumber-b._sequenceNumber}function e(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function f(){n.forEach(function(a){a()}),n.length=0}function g(a){l=!1;var c=b.timeline;c.currentTime=a,c._animations.sort(d),k=!1;var e=c._animations;c._animations=[];var f=[],g=[];e=e.filter(function(b){return b._inTimeline=b._tick(a),b._inEffect?g.push(b._effect):f.push(b._effect),b.finished||b.paused||b._idle||(k=!0),b._inTimeline}),n.push.apply(n,f),n.push.apply(n,g),c._animations.push.apply(c._animations,e),m=!1,k&&requestAnimationFrame(function(){})}var h=window.requestAnimationFrame,i=[],j=0;window.requestAnimationFrame=function(a){var b=j++;return 0==i.length&&h(c),i.push([b,a]),b},window.cancelAnimationFrame=function(a){i.forEach(function(b){b[0]==a&&(b[1]=function(){})})},e.prototype={_play:function(c){c._timing=a.normalizeTimingInput(c.timing);var d=new b.Animation(c);return d._idle=!1,d._timeline=this,this._animations.push(d),b.restart(),b.invalidateEffects(),d}};var k=!1,l=!1;b.restart=function(){return k||(k=!0,requestAnimationFrame(function(){}),l=!0),l};var m=!1;b.invalidateEffects=function(){m=!0};var n=[],o=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){return m&&g(p.currentTime),f(),o.apply(this,arguments)}});var p=new e;b.timeline=p}(c,d,f),function(a){function b(a,b){for(var c=0,d=0;d<a.length;d++)c+=a[d]*b[d];return c}function c(a,b){return[a[0]*b[0]+a[4]*b[1]+a[8]*b[2]+a[12]*b[3],a[1]*b[0]+a[5]*b[1]+a[9]*b[2]+a[13]*b[3],a[2]*b[0]+a[6]*b[1]+a[10]*b[2]+a[14]*b[3],a[3]*b[0]+a[7]*b[1]+a[11]*b[2]+a[15]*b[3],a[0]*b[4]+a[4]*b[5]+a[8]*b[6]+a[12]*b[7],a[1]*b[4]+a[5]*b[5]+a[9]*b[6]+a[13]*b[7],a[2]*b[4]+a[6]*b[5]+a[10]*b[6]+a[14]*b[7],a[3]*b[4]+a[7]*b[5]+a[11]*b[6]+a[15]*b[7],a[0]*b[8]+a[4]*b[9]+a[8]*b[10]+a[12]*b[11],a[1]*b[8]+a[5]*b[9]+a[9]*b[10]+a[13]*b[11],a[2]*b[8]+a[6]*b[9]+a[10]*b[10]+a[14]*b[11],a[3]*b[8]+a[7]*b[9]+a[11]*b[10]+a[15]*b[11],a[0]*b[12]+a[4]*b[13]+a[8]*b[14]+a[12]*b[15],a[1]*b[12]+a[5]*b[13]+a[9]*b[14]+a[13]*b[15],a[2]*b[12]+a[6]*b[13]+a[10]*b[14]+a[14]*b[15],a[3]*b[12]+a[7]*b[13]+a[11]*b[14]+a[15]*b[15]]}function d(a){switch(a.t){case"rotatex":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,0,Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1];case"rotatey":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),0,-Math.sin(d),0,0,1,0,0,Math.sin(d),0,Math.cos(d),0,0,0,0,1];case"rotate":case"rotatez":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var e=a.d[0],f=a.d[1],g=a.d[2],b=a.d[3].rad||0,c=a.d[3].deg||0,d=c*Math.PI/180+b,h=e*e+f*f+g*g;if(0===h)e=1,f=0,g=0;else if(1!==h){var i=Math.sqrt(h);e/=i,f/=i,g/=i}var j=Math.sin(d/2),k=j*Math.cos(d/2),l=j*j;return[1-2*(f*f+g*g)*l,2*(e*f*l+g*k),2*(e*g*l-f*k),0,2*(e*f*l-g*k),1-2*(e*e+g*g)*l,2*(f*g*l+e*k),0,2*(e*g*l+f*k),2*(f*g*l-e*k),1-2*(e*e+f*f)*l,0,0,0,0,1];case"scale":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,1,0,0,0,0,1];case"scalex":return[a.d[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"scaley":return[1,0,0,0,0,a.d[0],0,0,0,0,1,0,0,0,0,1];case"scalez":return[1,0,0,0,0,1,0,0,0,0,a.d[0],0,0,0,0,1];case"scale3d":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,a.d[2],0,0,0,0,1];case"skew":var m=a.d[0].deg||0,n=a.d[0].rad||0,o=a.d[1].deg||0,p=a.d[1].rad||0,q=m*Math.PI/180+n,r=o*Math.PI/180+p;return[1,Math.tan(r),0,0,Math.tan(q),1,0,0,0,0,1,0,0,0,0,1];case"skewx":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,Math.tan(d),1,0,0,0,0,1,0,0,0,0,1];case"skewy":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,Math.tan(d),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":var e=a.d[0].px||0,f=a.d[1].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,0,1];case"translatex":var e=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,0,0,1];case"translatey":var f=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,f,0,1];case"translatez":var g=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,g,1];case"translate3d":var e=a.d[0].px||0,f=a.d[1].px||0,g=a.d[2].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,g,1];case"perspective":var s=a.d[0].px?-1/a.d[0].px:0;return[1,0,0,0,0,1,0,0,0,0,1,s,0,0,0,1];case"matrix":return[a.d[0],a.d[1],0,0,a.d[2],a.d[3],0,0,0,0,1,0,a.d[4],a.d[5],0,1];case"matrix3d":return a.d}}function e(a){return 0===a.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:a.map(d).reduce(c)}function f(a){return[g(e(a))]}var g=function(){function a(a){return a[0][0]*a[1][1]*a[2][2]+a[1][0]*a[2][1]*a[0][2]+a[2][0]*a[0][1]*a[1][2]-a[0][2]*a[1][1]*a[2][0]-a[1][2]*a[2][1]*a[0][0]-a[2][2]*a[0][1]*a[1][0]}function c(b){for(var c=1/a(b),d=b[0][0],e=b[0][1],f=b[0][2],g=b[1][0],h=b[1][1],i=b[1][2],j=b[2][0],k=b[2][1],l=b[2][2],m=[[(h*l-i*k)*c,(f*k-e*l)*c,(e*i-f*h)*c,0],[(i*j-g*l)*c,(d*l-f*j)*c,(f*g-d*i)*c,0],[(g*k-h*j)*c,(j*e-d*k)*c,(d*h-e*g)*c,0]],n=[],o=0;3>o;o++){for(var p=0,q=0;3>q;q++)p+=b[3][q]*m[q][o];n.push(p)}return n.push(1),m.push(n),m}function d(a){return[[a[0][0],a[1][0],a[2][0],a[3][0]],[a[0][1],a[1][1],a[2][1],a[3][1]],[a[0][2],a[1][2],a[2][2],a[3][2]],[a[0][3],a[1][3],a[2][3],a[3][3]]]}function e(a,b){for(var c=[],d=0;4>d;d++){for(var e=0,f=0;4>f;f++)e+=a[f]*b[f][d];c.push(e)}return c}function f(a){var b=g(a);return[a[0]/b,a[1]/b,a[2]/b]}function g(a){return Math.sqrt(a[0]*a[0]+a[1]*a[1]+a[2]*a[2])}function h(a,b,c,d){return[c*a[0]+d*b[0],c*a[1]+d*b[1],c*a[2]+d*b[2]]}function i(a,b){return[a[1]*b[2]-a[2]*b[1],a[2]*b[0]-a[0]*b[2],a[0]*b[1]-a[1]*b[0]]}function j(j){var k=[j.slice(0,4),j.slice(4,8),j.slice(8,12),j.slice(12,16)];if(1!==k[3][3])return null;for(var l=[],m=0;4>m;m++)l.push(k[m].slice());for(var m=0;3>m;m++)l[m][3]=0;if(0===a(l))return!1;var n,o=[];if(k[0][3]||k[1][3]||k[2][3]){o.push(k[0][3]),o.push(k[1][3]),o.push(k[2][3]),o.push(k[3][3]);var p=c(l),q=d(p);n=e(o,q)}else n=[0,0,0,1];var r=k[3].slice(0,3),s=[];s.push(k[0].slice(0,3));var t=[];t.push(g(s[0])),s[0]=f(s[0]);var u=[];s.push(k[1].slice(0,3)),u.push(b(s[0],s[1])),s[1]=h(s[1],s[0],1,-u[0]),t.push(g(s[1])),s[1]=f(s[1]),u[0]/=t[1],s.push(k[2].slice(0,3)),u.push(b(s[0],s[2])),s[2]=h(s[2],s[0],1,-u[1]),u.push(b(s[1],s[2])),s[2]=h(s[2],s[1],1,-u[2]),t.push(g(s[2])),s[2]=f(s[2]),u[1]/=t[2],u[2]/=t[2];var v=i(s[1],s[2]);if(b(s[0],v)<0)for(var m=0;3>m;m++)t[m]*=-1,s[m][0]*=-1,s[m][1]*=-1,s[m][2]*=-1;var w,x,y=s[0][0]+s[1][1]+s[2][2]+1;return y>1e-4?(w=.5/Math.sqrt(y),x=[(s[2][1]-s[1][2])*w,(s[0][2]-s[2][0])*w,(s[1][0]-s[0][1])*w,.25/w]):s[0][0]>s[1][1]&&s[0][0]>s[2][2]?(w=2*Math.sqrt(1+s[0][0]-s[1][1]-s[2][2]),x=[.25*w,(s[0][1]+s[1][0])/w,(s[0][2]+s[2][0])/w,(s[2][1]-s[1][2])/w]):s[1][1]>s[2][2]?(w=2*Math.sqrt(1+s[1][1]-s[0][0]-s[2][2]),x=[(s[0][1]+s[1][0])/w,.25*w,(s[1][2]+s[2][1])/w,(s[0][2]-s[2][0])/w]):(w=2*Math.sqrt(1+s[2][2]-s[0][0]-s[1][1]),x=[(s[0][2]+s[2][0])/w,(s[1][2]+s[2][1])/w,.25*w,(s[1][0]-s[0][1])/w]),[r,t,u,x,n]}return j}();a.dot=b,a.makeMatrixDecomposition=f}(d,f),function(a){function b(a,b){var c=a.exec(b);return c?(c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]):void 0}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);return c?[c[0],c[1].replace(/^\s*/,"")]:void 0}function d(a,d,e){a=c.bind(null,a);for(var f=[];;){var g=a(e);if(!g)return[f,e];if(f.push(g[0]),e=g[1],g=b(d,e),!g||""==g[1])return[f,e];e=g[1]}}function e(a,b){for(var c=0,d=0;d<b.length&&(!/\s|,/.test(b[d])||0!=c);d++)if("("==b[d])c++;else if(")"==b[d]&&(c--,0==c&&d++,0>=c))break;var e=a(b.substr(0,d));return void 0==e?void 0:[e,b.substr(d)]}function f(a,b){for(var c=a,d=b;c&&d;)c>d?c%=d:d%=c;return c=a*b/(c+d)}function g(a){return function(b){var c=a(b);return c&&(c[0]=void 0),c}}function h(a,b){return function(c){var d=a(c);return d?d:[b,c]}}function i(b,c){for(var d=[],e=0;e<b.length;e++){var f=a.consumeTrimmed(b[e],c);if(!f||""==f[0])return;void 0!==f[0]&&d.push(f[0]),c=f[1]}return""==c?d:void 0}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;j>k;k++){var l=b(d[k%d.length],e[k%e.length]);if(!l)return;g.push(l[0]),h.push(l[1]),i.push(l[2])}return[g,h,function(b){var d=b.map(function(a,b){return i[b](a)}).join(c);return a?a(d):d}]}function k(a,b,c){for(var d=[],e=[],f=[],g=0,h=0;h<c.length;h++)if("function"==typeof c[h]){var i=c[h](a[g],b[g++]);d.push(i[0]),e.push(i[1]),f.push(i[2])}else!function(a){d.push(!1),e.push(!1),f.push(function(){return c[a]})}(h);return[d,e,function(a){for(var b="",c=0;c<a.length;c++)b+=f[c](a[c]);return b}]}a.consumeToken=b,a.consumeTrimmed=c,a.consumeRepeated=d,a.consumeParenthesised=e,a.ignore=g,a.optional=h,a.consumeList=i,a.mergeNestedRepeated=j.bind(null,null),a.mergeWrappedNestedRepeated=j,a.mergeList=k}(d),function(a){function b(b){function c(b){var c=a.consumeToken(/^inset/i,b);if(c)return d.inset=!0,c;var c=a.consumeLengthOrPercent(b);if(c)return d.lengths.push(c[0]),c;var c=a.consumeColor(b);return c?(d.color=c[0],c):void 0}var d={inset:!1,lengths:[],color:null},e=a.consumeRepeated(c,/^/,b);return e&&e[0].length?[d,e[1]]:void 0}function c(c){var d=a.consumeRepeated(b,/^,/,c);return d&&""==d[1]?d[0]:void 0}function d(b,c){for(;b.lengths.length<Math.max(b.lengths.length,c.lengths.length);)b.lengths.push({px:0});for(;c.lengths.length<Math.max(b.lengths.length,c.lengths.length);)c.lengths.push({px:0});if(b.inset==c.inset&&!!b.color==!!c.color){for(var d,e=[],f=[[],0],g=[[],0],h=0;h<b.lengths.length;h++){var i=a.mergeDimensions(b.lengths[h],c.lengths[h],2==h);f[0].push(i[0]),g[0].push(i[1]),e.push(i[2])}if(b.color&&c.color){var j=a.mergeColors(b.color,c.color);f[1]=j[0],g[1]=j[1],d=j[2]}return[f,g,function(a){for(var c=b.inset?"inset ":" ",f=0;f<e.length;f++)c+=e[f](a[0][f])+" ";return d&&(c+=d(a[1])),c}]}}function e(b,c,d,e){function f(a){return{inset:a,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var g=[],h=[],i=0;i<d.length||i<e.length;i++){var j=d[i]||f(e[i].inset),k=e[i]||f(d[i].inset);g.push(j),h.push(k)}return a.mergeNestedRepeated(b,c,g,h)}var f=e.bind(null,d,", ");a.addPropertiesHandler(c,f,["box-shadow","text-shadow"])}(d),function(a){function b(a){return a.toFixed(3).replace(".000","")}function c(a,b,c){return Math.min(b,Math.max(a,c))}function d(a){return/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a)?Number(a):void 0}function e(a,c){return[a,c,b]}function f(a,b){return 0!=a?h(0,1/0)(a,b):void 0}function g(a,b){return[a,b,function(a){return Math.round(c(1,1/0,a))}]}function h(a,d){return function(e,f){return[e,f,function(e){return b(c(a,d,e))}]}}function i(a,b){return[a,b,Math.round]}a.clamp=c,a.addPropertiesHandler(d,h(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(d,h(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(d,f,["flex-grow","flex-shrink"]),a.addPropertiesHandler(d,g,["orphans","widows"]),a.addPropertiesHandler(d,i,["z-index"]),a.parseNumber=d,a.mergeNumbers=e,a.numberToString=b}(d,f),function(a){function b(a,b){return"visible"==a||"visible"==b?[0,1,function(c){return 0>=c?a:c>=1?b:"visible"}]:void 0}a.addPropertiesHandler(String,b,["visibility"])}(d),function(a){function b(a){a=a.trim(),e.fillStyle="#000",e.fillStyle=a;var b=e.fillStyle;if(e.fillStyle="#fff",e.fillStyle=a,b==e.fillStyle){e.fillRect(0,0,1,1);var c=e.getImageData(0,0,1,1).data;e.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function c(b,c){return[b,c,function(b){function c(a){return Math.max(0,Math.min(255,a))}if(b[3])for(var d=0;3>d;d++)b[d]=Math.round(c(b[d]/b[3]));return b[3]=a.numberToString(a.clamp(0,1,b[3])),"rgba("+b.join(",")+")"}]}var d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=d.height=1;var e=d.getContext("2d");a.addPropertiesHandler(b,c,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,b),a.mergeColors=c}(d,f),function(a,b){function c(a,b){if(b=b.trim().toLowerCase(),"0"==b&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var c={};b=b.replace(a,function(a){return c[a]=null,"U"+a});for(var d="U("+a.source+")",e=b.replace(/[-+]?(\d*\.)?\d+/g,"N").replace(new RegExp("N"+d,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),f=[/N\*(D)/g,/(N|D)[*/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],g=0;g<f.length;)f[g].test(e)?(e=e.replace(f[g],"$1"),g=0):g++;if("D"==e){for(var h in c){var i=eval(b.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(d,"g"),"*0"));if(!isFinite(i))return;c[h]=i}return c}}}function d(a,b){return e(a,b,!0)}function e(b,c,d){var e,f=[];for(e in b)f.push(e);for(e in c)f.indexOf(e)<0&&f.push(e);return b=f.map(function(a){return b[a]||0}),c=f.map(function(a){return c[a]||0}),[b,c,function(b){var c=b.map(function(c,e){return 1==b.length&&d&&(c=Math.max(c,0)),a.numberToString(c)+f[e]}).join(" + ");return b.length>1?"calc("+c+")":c}]}var f="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",g=c.bind(null,new RegExp(f,"g")),h=c.bind(null,new RegExp(f+"|%","g")),i=c.bind(null,/deg|rad|grad|turn/g);a.parseLength=g,a.parseLengthOrPercent=h,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,h),a.parseAngle=i,a.mergeDimensions=e;var j=a.consumeParenthesised.bind(null,g),k=a.consumeRepeated.bind(void 0,j,/^/),l=a.consumeRepeated.bind(void 0,k,/^,/);a.consumeSizePairList=l;var m=function(a){var b=l(a);return b&&""==b[1]?b[0]:void 0},n=a.mergeNestedRepeated.bind(void 0,d," "),o=a.mergeNestedRepeated.bind(void 0,n,",");a.mergeNonNegativeSizePair=n,a.addPropertiesHandler(m,o,["background-size"]),a.addPropertiesHandler(h,d,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),a.addPropertiesHandler(h,e,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","text-indent","top","vertical-align","word-spacing"])}(d,f),function(a){function b(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function c(c){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,b,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],c);return d&&4==d[0].length?d[0]:void 0}function d(b,c){return"auto"==b||"auto"==c?[!0,!1,function(d){var e=d?b:c;if("auto"==e)return"auto";var f=a.mergeDimensions(e,e);return f[2](f[0])}]:a.mergeDimensions(b,c)}function e(a){return"rect("+a+")"}var f=a.mergeWrappedNestedRepeated.bind(null,e,d,", ");a.parseBox=c,a.mergeBoxes=f,a.addPropertiesHandler(c,f,["clip"]) +}(d,f),function(a){function b(a){return function(b){var c=0;return a.map(function(a){return a===j?b[c++]:a})}}function c(a){return a}function d(b){if(b=b.toLowerCase().trim(),"none"==b)return[];for(var c,d=/\s*(\w+)\(([^)]*)\)/g,e=[],f=0;c=d.exec(b);){if(c.index!=f)return;f=c.index+c[0].length;var g=c[1],h=m[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var n=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(p=q?{A:function(b){return"0"==b.trim()?l:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:l,n:n[0],t:k}[r],void 0===p)return;n.push(p)}if(e.push({t:g,d:n}),d.lastIndex==b.length)return e}}function e(a){return a.toFixed(6).replace(".000000","")}function f(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var f=a.makeMatrixDecomposition(c)}return null==d[0]||null==f[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),f[0].push(1),[d,f,function(b){var c=a.quat(d[0][3],f[0][3],b[5]),g=a.composeMatrix(b[0],b[1],b[2],c,b[4]),h=g.map(e).join(",");return h}])}function g(a){return a.replace(/[xy]/,"")}function h(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function i(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var i=0;i<b.length;i++){var j=b[i].t,k=b[i].d,l="scale"==j.substr(0,5)?1:0;c.push({t:j,d:k.map(function(a){if("number"==typeof a)return l;var b={};for(var c in a)b[c]=l;return b})})}}var n=function(a,b){return"perspective"==a&&"perspective"==b||("matrix"==a||"matrix3d"==a)&&("matrix"==b||"matrix3d"==b)},o=[],p=[],q=[];if(b.length!=c.length){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var i=0;i<b.length;i++){var j,s=b[i].t,t=c[i].t,u=b[i].d,v=c[i].d,w=m[s],x=m[t];if(n(s,t)){if(!d)return;var r=f([b[i]],[c[i]]);o.push(r[0]),p.push(r[1]),q.push(["matrix",[r[2]]])}else{if(s==t)j=s;else if(w[2]&&x[2]&&g(s)==g(t))j=g(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||h(s)!=h(t)){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=h(s),u=w[1](u),v=x[1](v)}for(var y=[],z=[],A=[],B=0;B<u.length;B++){var C="number"==typeof u[B]?a.mergeNumbers:a.mergeDimensions,r=C(u[B],v[B]);y[B]=r[0],z[B]=r[1],A.push(r[2])}o.push(y),p.push(z),q.push([j,A])}}if(e){var D=o;o=p,p=D}return[o,p,function(a){return a.map(function(a,b){var c=a.map(function(a,c){return q[b][1][c](a)}).join(",");return"matrix"==q[b][0]&&16==c.split(",").length&&(q[b][0]="matrix3d"),q[b][0]+"("+c+")"}).join(" ")}]}var j=null,k={px:0},l={deg:0},m={matrix:["NNNNNN",[j,j,0,0,j,j,0,0,0,0,1,0,j,j,0,1],c],matrix3d:["NNNNNNNNNNNNNNNN",c],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",b([j,j,1]),c],scalex:["N",b([j,1,1]),b([j,1])],scaley:["N",b([1,j,1]),b([1,j])],scalez:["N",b([1,1,j])],scale3d:["NNN",c],skew:["Aa",null,c],skewx:["A",null,b([j,l])],skewy:["A",null,b([l,j])],translate:["Tt",b([j,j,k]),c],translatex:["T",b([j,k,k]),b([j,k])],translatey:["T",b([k,j,k]),b([k,j])],translatez:["L",b([k,k,j])],translate3d:["TTL",c]};a.addPropertiesHandler(d,i,["transform"])}(d,f),function(a){function b(a){var b=Number(a);return isNaN(b)||100>b||b>900||b%100!==0?void 0:b}function c(b){return b=100*Math.round(b/100),b=a.clamp(100,900,b),400===b?"normal":700===b?"bold":String(b)}function d(a,b){return[a,b,c]}a.addPropertiesHandler(b,d,["font-weight"])}(d),function(a){function b(a){var b={};for(var c in a)b[c]=-a[c];return b}function c(b){return a.consumeToken(/^(left|center|right|top|bottom)\b/i,b)||a.consumeLengthOrPercent(b)}function d(b,d){var e=a.consumeRepeated(c,/^/,d);if(e&&""==e[1]){var f=e[0];if(f[0]=f[0]||"center",f[1]=f[1]||"center",3==b&&(f[2]=f[2]||{px:0}),f.length==b){if(/top|bottom/.test(f[0])||/left|right/.test(f[1])){var h=f[0];f[0]=f[1],f[1]=h}if(/left|right|center|Object/.test(f[0])&&/top|bottom|center|Object/.test(f[1]))return f.map(function(a){return"object"==typeof a?a:g[a]})}}}function e(d){var e=a.consumeRepeated(c,/^/,d);if(e){for(var f=e[0],h=[{"%":50},{"%":50}],i=0,j=!1,k=0;k<f.length;k++){var l=f[k];"string"==typeof l?(j=/bottom|right/.test(l),i={left:0,right:0,center:i,top:1,bottom:1}[l],h[i]=g[l],"center"==l&&i++):(j&&(l=b(l),l["%"]=(l["%"]||0)+100),h[i]=l,i++,j=!1)}return[h,e[1]]}}function f(b){var c=a.consumeRepeated(e,/^,/,b);return c&&""==c[1]?c[0]:void 0}var g={left:{"%":0},center:{"%":50},right:{"%":100},top:{"%":0},bottom:{"%":100}},h=a.mergeNestedRepeated.bind(null,a.mergeDimensions," ");a.addPropertiesHandler(d.bind(null,3),h,["transform-origin"]),a.addPropertiesHandler(d.bind(null,2),h,["perspective-origin"]),a.consumePosition=e,a.mergeOffsetList=h;var i=a.mergeNestedRepeated.bind(null,h,", ");a.addPropertiesHandler(f,i,["background-position","object-position"])}(d),function(a){function b(b){var c=a.consumeToken(/^circle/,b);if(c&&c[0])return["circle"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),d,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],c[1]));var f=a.consumeToken(/^ellipse/,b);if(f&&f[0])return["ellipse"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),e,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],f[1]));var g=a.consumeToken(/^polygon/,b);return g&&g[0]?["polygon"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),a.optional(a.consumeToken.bind(void 0,/^nonzero\s*,|^evenodd\s*,/),"nonzero,"),a.consumeSizePairList,a.ignore(a.consumeToken.bind(void 0,/^\)/))],g[1])):void 0}function c(b,c){return b[0]===c[0]?"circle"==b[0]?a.mergeList(b.slice(1),c.slice(1),["circle(",a.mergeDimensions," at ",a.mergeOffsetList,")"]):"ellipse"==b[0]?a.mergeList(b.slice(1),c.slice(1),["ellipse(",a.mergeNonNegativeSizePair," at ",a.mergeOffsetList,")"]):"polygon"==b[0]&&b[1]==c[1]?a.mergeList(b.slice(2),c.slice(2),["polygon(",b[1],g,")"]):void 0:void 0}var d=a.consumeParenthesised.bind(null,a.parseLengthOrPercent),e=a.consumeRepeated.bind(void 0,d,/^/),f=a.mergeNestedRepeated.bind(void 0,a.mergeDimensions," "),g=a.mergeNestedRepeated.bind(void 0,f,",");a.addPropertiesHandler(b,c,["shape-outside"])}(d),function(a){function b(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(c[a]=b)})}var c={};b("transform",["webkitTransform","msTransform"]),b("transformOrigin",["webkitTransformOrigin"]),b("perspective",["webkitPerspective"]),b("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return c[a]||a}}(d,f)}(),!function(a,b){function c(a){var b=window.document.timeline;b.currentTime=a,b._discardAnimations(),0==b._animations.length?d=!1:requestAnimationFrame(c)}b.AnimationTimeline=function(){this._animations=[],this.currentTime=void 0},b.AnimationTimeline.prototype={getAnimations:function(){return this._discardAnimations(),this._animations.slice()},getAnimationPlayers:function(){return a.deprecated("AnimationTimeline.getAnimationPlayers","2015-03-23","Use AnimationTimeline.getAnimations instead."),this.getAnimations()},_discardAnimations:function(){this._animations=this._animations.filter(function(a){return"finished"!=a.playState&&"idle"!=a.playState})},play:function(a){var c=new b.Animation(a);return this._animations.push(c),b.restartWebAnimationsNextTick(),c._animation.play(),c}};var d=!1;b.restartWebAnimationsNextTick=function(){d||(d=!0,requestAnimationFrame(c))};var e=new b.AnimationTimeline;b.timeline=e;try{Object.defineProperty(window.document,"timeline",{configurable:!0,get:function(){return e}})}catch(f){}try{window.document.timeline=e}catch(f){}}(c,e,f),function(a,b){b.Animation=function(a){this.effect=a,a&&(a.animation=this),this._isGroup=!1,this._animation=null,this._childAnimations=[],this._callback=null,this._rebuildUnderlyingAnimation(),this._animation.cancel()},b.Animation.prototype={_rebuildUnderlyingAnimation:function(){this._animation&&(this._animation.cancel(),this._animation=null),(!this.effect||this.effect instanceof window.KeyframeEffect)&&(this._animation=b.newUnderlyingAnimationForKeyframeEffect(this.effect),b.bindAnimationForKeyframeEffect(this)),(this.effect instanceof window.SequenceEffect||this.effect instanceof window.GroupEffect)&&(this._animation=b.newUnderlyingAnimationForGroup(this.effect),b.bindAnimationForGroup(this))},_updateChildren:function(){if(this.effect&&"idle"!=this.playState){var a=this.effect._timing.delay;this._childAnimations.forEach(function(c){this._arrangeChildren(c,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c.effect))}.bind(this))}},_setExternalAnimation:function(a){if(this.effect&&this._isGroup)for(var b=0;b<this.effect.children.length;b++)this.effect.children[b].animation=a,this._childAnimations[b]._setExternalAnimation(a)},_constructChildren:function(){if(this.effect&&this._isGroup){var a=this.effect._timing.delay;this.effect.children.forEach(function(c){var d=window.document.timeline.play(c);this._childAnimations.push(d),d.playbackRate=this.playbackRate,this.paused&&d.pause(),c.animation=this.effect.animation,this._arrangeChildren(d,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c))}.bind(this))}},_arrangeChildren:function(a,b){null===this.startTime?(a.currentTime=this.currentTime-b/this.playbackRate,a._startTime=null):a.startTime!==this.startTime+b/this.playbackRate&&(a.startTime=this.startTime+b/this.playbackRate)},get paused(){return this._animation.paused},get playState(){return this._animation.playState},get onfinish(){return this._onfinish},set onfinish(a){"function"==typeof a?(this._onfinish=a,this._animation.onfinish=function(b){b.target=this,a.call(this,b)}.bind(this)):(this._animation.onfinish=a,this.onfinish=this._animation.onfinish)},get currentTime(){return this._animation.currentTime},set currentTime(a){this._animation.currentTime=a,this._register(),this._forEachChild(function(b,c){b.currentTime=a-c})},get startTime(){return this._animation.startTime},set startTime(a){this._animation.startTime=a,this._register(),this._forEachChild(function(b,c){b.startTime=a+c})},get playbackRate(){return this._animation.playbackRate},set playbackRate(a){var b=this.currentTime;this._animation.playbackRate=a,this._forEachChild(function(b){b.playbackRate=a}),"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!==b&&(this.currentTime=b)},get finished(){return this._animation.finished},get source(){return a.deprecated("Animation.source","2015-03-23","Use Animation.effect instead."),this.effect},play:function(){this._animation.play(),this._register(),b.awaitStartTime(this),this._forEachChild(function(a){var b=a.currentTime;a.play(),a.currentTime=b})},pause:function(){this._animation.pause(),this._register(),this._forEachChild(function(a){a.pause()})},finish:function(){this._animation.finish(),this._register()},cancel:function(){this._animation.cancel(),this._register(),this._removeChildren()},reverse:function(){var a=this.currentTime;this._animation.reverse(),this._forEachChild(function(a){a.reverse()}),null!==a&&(this.currentTime=a)},addEventListener:function(a,b){var c=b;"function"==typeof b&&(c=function(a){a.target=this,b.call(this,a)}.bind(this),b._wrapper=c),this._animation.addEventListener(a,c)},removeEventListener:function(a,b){this._animation.removeEventListener(a,b&&b._wrapper||b)},_removeChildren:function(){for(;this._childAnimations.length;)this._childAnimations.pop().cancel()},_forEachChild:function(b){var c=0;if(this.effect.children&&this._childAnimations.length<this.effect.children.length&&this._constructChildren(),this._childAnimations.forEach(function(a){b.call(this,a,c),this.effect instanceof window.SequenceEffect&&(c+=a.effect.activeDuration)}.bind(this)),"pending"!=this._animation.playState){var d=this.effect._timing,e=this._animation.currentTime;null!==e&&(e=a.calculateTimeFraction(a.calculateActiveDuration(d),e,d)),(null==e||isNaN(e))&&this._removeChildren()}}}}(c,e,f),function(a,b){function c(b){this._frames=a.normalizeKeyframes(b)}function d(){for(var a=!1;g.length;)g.shift()._updateChildren(),a=!0;return a}b.KeyframeEffect=function(b,d,e){return this.target=b,this._timingInput=e,this._timing=a.normalizeTimingInput(e),this.timing=a.makeTiming(e),this._normalizedKeyframes="function"==typeof d?d:new c(d),this._keyframes=d,this.activeDuration=a.calculateActiveDuration(this._timing),this},b.KeyframeEffect.prototype={getFrames:function(){return"function"==typeof this._normalizedKeyframes?this._normalizedKeyframes:this._normalizedKeyframes._frames},get effect(){return a.deprecated("KeyframeEffect.effect","2015-03-23","Use KeyframeEffect.getFrames() instead."),this._normalizedKeyframes}};var e=Element.prototype.animate;Element.prototype.animate=function(a,c){return b.timeline.play(new b.KeyframeEffect(this,a,c))};var f=document.createElementNS("http://www.w3.org/1999/xhtml","div");b.newUnderlyingAnimationForKeyframeEffect=function(a){var b=a.target||f,c=a._keyframes;return"function"==typeof c&&(c=[]),e.apply(b,[c,a._timingInput])},b.bindAnimationForKeyframeEffect=function(a){a.effect&&"function"==typeof a.effect._normalizedKeyframes&&b.bindAnimationForCustomEffect(a)};var g=[];b.awaitStartTime=function(a){null===a.startTime&&a._isGroup&&(0==g.length&&requestAnimationFrame(d),g.push(a))};var h=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){var a=h.apply(this,arguments);return d()&&(a=h.apply(this,arguments)),a}}),window.KeyframeEffect=b.KeyframeEffect,window.Element.prototype.getAnimations=function(){return document.timeline.getAnimations().filter(function(a){return null!==a.effect&&a.effect.target==this}.bind(this))},window.Element.prototype.getAnimationPlayers=function(){return a.deprecated("Element.getAnimationPlayers","2015-03-23","Use Element.getAnimations instead."),this.getAnimations()},window.Animation=function(){a.deprecated("window.Animation","2015-03-23","Use window.KeyframeEffect instead."),window.KeyframeEffect.apply(this,arguments)},window.Animation.prototype=Object.create(window.KeyframeEffect.prototype),window.Animation.prototype.constructor=window.Animation}(c,e,f),function(a,b){function c(a){a._registered||(a._registered=!0,f.push(a),g||(g=!0,requestAnimationFrame(d)))}function d(){var a=f;f=[],a.sort(function(a,b){return a._sequenceNumber-b._sequenceNumber}),a=a.filter(function(a){a();var b=a._animation?a._animation.playState:"idle";return"running"!=b&&"pending"!=b&&(a._registered=!1),a._registered}),f.push.apply(f,a),f.length?(g=!0,requestAnimationFrame(d)):g=!1}var e=(document.createElementNS("http://www.w3.org/1999/xhtml","div"),0);b.bindAnimationForCustomEffect=function(b){var d=b.effect.target,f=b.effect._normalizedKeyframes,g=b.effect.timing,h=null;g=a.normalizeTimingInput(g);var i=function(){var c=i._animation?i._animation.currentTime:null;null!==c&&(c=a.calculateTimeFraction(a.calculateActiveDuration(g),c,g),isNaN(c)&&(c=null)),c!==h&&f(c,d,b.effect),h=c};i._animation=b,i._registered=!1,i._sequenceNumber=e++,b._callback=i,c(i)};var f=[],g=!1;b.Animation.prototype._register=function(){this._callback&&c(this._callback)}}(c,e,f),function(a,b){function c(a){return a._timing.delay+a.activeDuration+a._timing.endDelay}function d(b,c){this.children=b||[],this._timing=a.normalizeTimingInput(c,!0),this.timing=a.makeTiming(c,!0),"auto"===this._timing.duration&&(this._timing.duration=this.activeDuration)}window.SequenceEffect=function(){d.apply(this,arguments)},window.GroupEffect=function(){d.apply(this,arguments)},window.SequenceEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a+=c(b)}),Math.max(a,0)}},window.GroupEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a=Math.max(a,c(b))}),a}},b.newUnderlyingAnimationForGroup=function(c){var d,e=null,f=function(b){var c=d._wrapper;return"pending"!=c.playState&&c.effect?null==b?void c._removeChildren():0==b&&c.playbackRate<0&&(e||(e=a.normalizeTimingInput(c.effect.timing)),b=a.calculateTimeFraction(a.calculateActiveDuration(e),-1,e),isNaN(b)||null==b)?(c._forEachChild(function(a){a.currentTime=-1}),void c._removeChildren()):void 0:void 0};return d=b.timeline.play(new b.KeyframeEffect(null,f,c._timing))},b.bindAnimationForGroup=function(a){a._animation._wrapper=a,a._isGroup=!0,b.awaitStartTime(a),a._constructChildren(),a._setExternalAnimation(a)},b.groupChildDuration=c,window.AnimationSequence=function(){a.deprecated("window.AnimationSequence","2015-03-23","Use window.SequenceEffect instead."),window.SequenceEffect.apply(this,arguments)},window.AnimationSequence.prototype=Object.create(window.SequenceEffect.prototype),window.AnimationSequence.prototype.constructor=window.AnimationSequence,window.AnimationGroup=function(){a.deprecated("window.AnimationGroup","2015-03-23","Use window.GroupEffect instead."),window.GroupEffect.apply(this,arguments)},window.AnimationGroup.prototype=Object.create(window.GroupEffect.prototype),window.AnimationGroup.prototype.constructor=window.AnimationGroup}(c,e,f)}({},function(){return this}()); +//# sourceMappingURL=web-animations-next.min.js.map
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next.min.js.map b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next.min.js.map new file mode 100644 index 0000000..67ffbe0 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations-next.min.js.map @@ -0,0 +1 @@ +{"version":3,"file":"web-animations-next.min.js","sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/keyframe-interpolations.js","src/property-interpolation.js","src/keyframe-effect.js","src/apply-preserving-inline-style.js","src/element-animatable.js","src/interpolation.js","src/matrix-interpolation.js","src/animation.js","src/tick.js","src/timeline.js","src/web-animations-next-animation.js","src/keyframe-effect-constructor.js","src/effect-callback.js","src/group-constructors.js"],"names":["webAnimationsShared","webAnimations1","webAnimationsNext","webAnimationsTesting","shared","makeTiming","timingInput","forGroup","timing","delay","endDelay","fill","iterationStart","iterations","duration","playbackRate","direction","easing","isNaN","undefined","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","isDeprecated","normalizeTimingInput","toTimingFunction","cubic","a","b","c","d","linear","x","f","m","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","cubicData","cubicBezierRe","exec","apply","this","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","preset","presets","calculateActiveDuration","repeatedDuration","calculatePhase","activeDuration","localTime","PhaseNone","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateScaledActiveTime","activeTime","startOffset","calculateIterationTime","iterationDuration","scaledActiveTime","Infinity","calculateCurrentIteration","iterationTime","floor","calculateTransformedTime","currentIteration","currentIterationIsOdd","currentDirectionIsForwards","directedTime","timeFraction","calculateTimeFraction","split","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","value","aliases","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","style","i","longProperty","longhandValue","normalizeKeyframes","effectInput","spaceKeyframes","length","keyframes","offset","previousIndex","previousOffset","j","Array","isArray","TypeError","originalKeyframe","keyframe","member","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","code","INVALID_MODIFICATION_ERR","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","document","createElementNS","borderWidthAliases","thin","medium","thick","borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","fontSize","xx-small","x-small","small","large","x-large","xx-large","fontWeight","normal","bold","outlineWidth","textShadow","none","boxShadow","silenced","feature","date","advice","plural","auxVerb","today","Date","expiry","setMonth","getMonth","console","warn","toDateString","deprecated","Error","scope","makePropertySpecificKeyframeGroups","propertySpecificKeyframeGroups","propertySpecificKeyframe","push","groupName","group","makeInterpolations","interpolations","endTime","startValue","endValue","startTime","propertyInterpolation","leftInterpolation","rightInterpolation","convertEffectInput","target","fraction","interpolation","offsetFraction","localDuration","scaledLocalTime","clear","addPropertyHandler","parser","merger","propertyHandlers","addPropertiesHandler","properties","replace","toUpperCase","right","handlers","parsedLeft","parsedRight","interpolationArgs","Interpolation","t","interp","bool","left","testing","EffectTime","effectTime","keyframeEffect","_clear","_hasSameTarget","otherTarget","_isCurrent","_totalDuration","NullEffect","nullEffect","_update","configureProperty","descriptor","enumerable","configurable","defineProperty","object","AnimatedCSSStyleDeclaration","element","_surrogateStyle","_style","_isAnimatedProperty","_updateIndices","ensureStyleIsPatched","_webAnimationsPatchedStyle","animatedStyle","styleAttributes","cssText","parentRule","styleMethods","getPropertyCSSValue","getPropertyPriority","getPropertyValue","removeProperty","setProperty","styleMutatingMethods",{"end":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"start":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"name":"cssText"},"isAffectedProperty","text","_length","index","_set","method","prototype","modifiesStyle","arguments","documentElement","set","propertyName","window","Element","animate","timeline","_play","KeyframeEffect","interpolate","from","to","r","convertToString","clamp","max","fromQ","toQ","product","quat","acos","theta","sqrt","w","composeMatrix","multiply","k","is2D","translate","skew","matrix","perspective","z","rotMatrix","y","temp","scale","concat","sequenceNumber","AnimationEvent","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","now","Animation","effect","_sequenceNumber","_currentTime","_startTime","_playbackRate","_inTimeline","_finishedFlag","onfinish","_finishHandlers","_effect","_inEffect","_idle","_currentTimePending","_ensureAlive","_animations","_tickCurrentTime","newTime","ignoreLimit","finished","restart","_timeline","invalidateEffects","paused","oldCurrentTime","playState","play","pause","cancel","reverse","addEventListener","handler","removeEventListener","splice","_fireEvents","baseTime","event","setTimeout","_tick","processRafCallbacks","processing","rafCallbacks","tick","entry","needsRetick","applyPendingEffects","compareAnimations","leftAnimation","rightAnimation","InternalTimeline","performance","pendingEffects","hasRestartedThisFrame","updatingAnimations","newPendingClears","newPendingEffects","webAnimationsNextTick","_discardAnimations","ticking","requestAnimationFrame","AnimationTimeline","getAnimations","getAnimationPlayers","animation","restartWebAnimationsNextTick","_animation","get","e","_isGroup","_childAnimations","_callback","_rebuildUnderlyingAnimation","newUnderlyingAnimationForKeyframeEffect","bindAnimationForKeyframeEffect","SequenceEffect","GroupEffect","newUnderlyingAnimationForGroup","bindAnimationForGroup","_updateChildren","_timing","childAnimation","_arrangeChildren","groupChildDuration","bind","_setExternalAnimation","children","_constructChildren","child","_onfinish","v","call","_register","_forEachChild","source","awaitStartTime","time","finish","_removeChildren","wrapped","_wrapper","pop","KeyframeList","_frames","updatePendingGroups","updated","pendingGroups","shift","_timingInput","_normalizedKeyframes","_keyframes","getFrames","originalElementAnimate","nullTarget","bindAnimationForCustomEffect","groupAnimation","originalGetComputedStyle","getComputedStyle","create","constructor","register","callback","_registered","callbacks","updating","sort","effectFunction","last","node","total","underlyingAnimation","ticker","tf","AnimationSequence","AnimationGroup"],"mappings":"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"}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.html b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.html new file mode 100644 index 0000000..b5de36c --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.html @@ -0,0 +1,50 @@ +<!-- + Copyright 2014 Google Inc. All rights reserved. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<!-- WARNING: This file is DEPRECATED, for development purposes use + web-animations*.dev.html instead or depend on + web-animations*.min.js in the web-animations-js + repository --> + +<script src="src/dev.js"></script> +<script src="src/scope.js"></script> +<script src="src/deprecation.js"></script> +<script src="src/timing-utilities.js"></script> +<script src="src/normalize-keyframes.js"></script> +<script src="src/animation-node.js"></script> +<script src="src/effect.js"></script> +<script src="src/property-interpolation.js"></script> +<script src="src/animation.js"></script> +<script src="src/apply.js"></script> +<script src="src/element-animatable.js"></script> +<script src="src/interpolation.js"></script> +<script src="src/player.js"></script> +<script src="src/tick.js"></script> +<script src="src/handler-utils.js"></script> +<script src="src/shadow-handler.js"></script> +<script src="src/number-handler.js"></script> +<script src="src/visibility-handler.js"></script> +<script src="src/color-handler.js"></script> +<script src="src/dimension-handler.js"></script> +<script src="src/box-handler.js"></script> +<script src="src/transform-handler.js"></script> +<script src="src/property-names.js"></script> +<script src="src/timeline.js"></script> +<script src="src/maxifill-player.js"></script> +<script src="src/animation-constructor.js"></script> +<script src="src/effect-callback.js"></script> +<script src="src/group-constructors.js"></script> + diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.min.js b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.min.js new file mode 100644 index 0000000..1c46a84 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.min.js @@ -0,0 +1,17 @@ +// Copyright 2014 Google Inc. All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +!function(a,b){b["true"]=a,function(){if(document.documentElement.animate){var a=document.documentElement.animate([],0),b=!0;if(a&&(b=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach(function(c){void 0===a[c]&&(b=!0)})),!b)return}var c={},d={},e={},f=null;!function(a){function b(b,c){var d={delay:0,endDelay:0,fill:c?"both":"none",iterationStart:0,iterations:1,duration:c?"auto":0,playbackRate:1,direction:"normal",easing:"linear"};return"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof d[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==p.indexOf(b[c]))return;if("direction"==c&&-1==q.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;d[c]=b[c]}}):d.duration=b,d}function c(a,c){var d=b(a,c);return d.easing=f(d.easing),d}function d(a,b,c,d){return 0>a||a>1||0>c||c>1?y:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}for(var g=0,h=1;;){var i=(g+h)/2,j=f(a,c,i);if(Math.abs(e-j)<.001)return f(b,d,i);e>j?g=i:h=i}}}function e(a,b){return function(c){if(c>=1)return 1;var d=1/a;return c+=b*d,c-c%d}}function f(a){var b=w.exec(a);if(b)return d.apply(this,b.slice(1).map(Number));var c=x.exec(a);if(c)return e(Number(c[1]),{start:r,middle:s,end:t}[c[2]]);var f=u[a];return f?f:y}function g(a){return Math.abs(h(a)/a.playbackRate)}function h(a){return a.duration*a.iterations}function i(a,b,c){return null==b?z:b<c.delay?A:b>=c.delay+a?B:C}function j(a,b,c,d,e){switch(d){case A:return"backwards"==b||"both"==b?0:null;case C:return c-e;case B:return"forwards"==b||"both"==b?a:null;case z:return null}}function k(a,b,c,d){return(d.playbackRate<0?b-a:b)*d.playbackRate+c}function l(a,b,c,d,e){return 1/0===c||c===-1/0||c-d==b&&e.iterations&&(e.iterations+e.iterationStart)%1==0?a:c%a}function m(a,b,c,d){return 0===c?0:b==a?d.iterationStart+d.iterations-1:Math.floor(c/a)}function n(a,b,c,d){var e=a%2>=1,f="normal"==d.direction||d.direction==(e?"alternate-reverse":"alternate"),g=f?c:b-c,h=g/b;return b*d.easing(h)}function o(a,b,c){var d=i(a,b,c),e=j(a,c.fill,b,d,c.delay);if(null===e)return null;if(0===a)return d===A?0:1;var f=c.iterationStart*c.duration,g=k(a,e,f,c),o=l(c.duration,h(c),g,f,c),p=m(c.duration,o,g,c);return n(p,c.duration,o,c)/c.duration}var p="backwards|forwards|both|none".split("|"),q="reverse|alternate|alternate-reverse".split("|"),r=1,s=.5,t=0,u={ease:d(.25,.1,.25,1),"ease-in":d(.42,0,1,1),"ease-out":d(0,0,.58,1),"ease-in-out":d(.42,0,.58,1),"step-start":e(1,r),"step-middle":e(1,s),"step-end":e(1,t)},v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",w=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),x=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,y=function(a){return a},z=0,A=1,B=2,C=3;a.makeTiming=b,a.normalizeTimingInput=c,a.calculateActiveDuration=g,a.calculateTimeFraction=o,a.calculatePhase=i,a.toTimingFunction=f}(c,f),function(a){function b(a,b){return a in h?h[a][b]||b:b}function c(a,c,d){var g=e[a];if(g){f.style[a]=c;for(var h in g){var i=g[h],j=f.style[i];d[i]=b(i,j)}}else d[a]=b(a,c)}function d(b){function d(){var a=e.length;null==e[a-1].offset&&(e[a-1].offset=1),a>1&&null==e[0].offset&&(e[0].offset=0);for(var b=0,c=e[0].offset,d=1;a>d;d++){var f=e[d].offset;if(null!=f){for(var g=1;d-b>g;g++)e[b+g].offset=c+(f-c)*g/(d-b);b=d,c=f}}}if(!Array.isArray(b)&&null!==b)throw new TypeError("Keyframes must be null or an array of keyframes");if(null==b)return[];for(var e=b.map(function(b){var d={};for(var e in b){var f=b[e];if("offset"==e){if(null!=f&&(f=Number(f),!isFinite(f)))throw new TypeError("keyframe offsets must be numbers.")}else{if("composite"==e)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};f="easing"==e?a.toTimingFunction(f):""+f}c(e,f,d)}return void 0==d.offset&&(d.offset=null),void 0==d.easing&&(d.easing=a.toTimingFunction("linear")),d}),f=!0,g=-1/0,h=0;h<e.length;h++){var i=e[h].offset;if(null!=i){if(g>i)throw{code:DOMException.INVALID_MODIFICATION_ERR,name:"InvalidModificationError",message:"Keyframes are not loosely sorted by offset. Sort or specify offsets."};g=i}else f=!1}return e=e.filter(function(a){return a.offset>=0&&a.offset<=1}),f||d(),e}var e={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},f=document.createElementNS("http://www.w3.org/1999/xhtml","div"),g={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:g,borderLeftWidth:g,borderRightWidth:g,borderTopWidth:g,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:g,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.normalizeKeyframes=d}(c,f),function(a){var b={};a.isDeprecated=function(a,c,d,e){var f=e?"are":"is",g=new Date,h=new Date(c);return h.setMonth(h.getMonth()+3),h>g?(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,!1):!0},a.deprecated=function(b,c,d,e){var f=e?"are":"is";if(a.isDeprecated(b,c,d,e))throw new Error(b+" "+f+" no longer supported. "+d)}}(c),function(a,b){function c(a){for(var b={},c=0;c<a.length;c++)for(var d in a[c])if("offset"!=d&&"easing"!=d&&"composite"!=d){var e={offset:a[c].offset,easing:a[c].easing,value:a[c][d]};b[d]=b[d]||[],b[d].push(e)}for(var f in b){var g=b[f];if(0!=g[0].offset||1!=g[g.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return b}function d(a){var c=[];for(var d in a)for(var e=a[d],f=0;f<e.length-1;f++){var g=e[f].offset,h=e[f+1].offset,i=e[f].value,j=e[f+1].value;g==h&&(1==h?i=j:j=i),c.push({startTime:g,endTime:h,easing:e[f].easing,property:d,interpolation:b.propertyInterpolation(d,i,j)})}return c.sort(function(a,b){return a.startTime-b.startTime}),c}b.convertEffectInput=function(e){var f=a.normalizeKeyframes(e),g=c(f),h=d(g);return function(a,c){if(null!=c)h.filter(function(a){return 0>=c&&0==a.startTime||c>=1&&1==a.endTime||c>=a.startTime&&c<=a.endTime}).forEach(function(d){var e=c-d.startTime,f=d.endTime-d.startTime,g=0==f?0:d.easing(e/f);b.apply(a,d.property,d.interpolation(g))});else for(var d in g)"offset"!=d&&"easing"!=d&&"composite"!=d&&b.clear(a,d)}}}(c,d,f),function(a){function b(a,b,c){e[c]=e[c]||[],e[c].push([a,b])}function c(a,c,d){for(var e=0;e<d.length;e++){var f=d[e];b(a,c,f),/-/.test(f)&&b(a,c,f.replace(/-(.)/g,function(a,b){return b.toUpperCase()}))}}function d(b,c,d){for(var f=c==d?[]:e[b],g=0;f&&g<f.length;g++){var h=f[g][0](c),i=f[g][0](d);if(void 0!==h&&void 0!==i){var j=f[g][1](h,i);if(j){var k=a.Interpolation.apply(null,j);return function(a){return 0==a?c:1==a?d:k(a)}}}}return a.Interpolation(!1,!0,function(a){return a?d:c})}var e={};a.addPropertiesHandler=c,a.propertyInterpolation=d}(d,f),function(a,b){function c(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateTimeFraction(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d._isCurrent=function(d){var e=a.calculatePhase(c,d,b);return e===PhaseActive||e===PhaseBefore},d}b.KeyframeEffect=function(d,e,f){var g,h=c(a.normalizeTimingInput(f)),i=b.convertEffectInput(e),j=function(){i(d,g)};return j._update=function(a){return g=h(a),null!==g},j._clear=function(){i(d,null)},j._hasSameTarget=function(a){return d===a},j._isCurrent=h._isCurrent,j._totalDuration=h._totalDuration,j},b.NullEffect=function(a){var b=function(){a&&(a(),a=null)};return b._update=function(){return null},b._totalDuration=0,b._isCurrent=function(){return!1},b._hasSameTarget=function(){return!1},b}}(c,d,f),function(a){function b(a,b,c){c.enumerable=!0,c.configurable=!0,Object.defineProperty(a,b,c)}function c(a){this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=a.style,this._length=0,this._isAnimatedProperty={};for(var b=0;b<this._style.length;b++){var c=this._style[b];this._surrogateStyle[c]=this._style[c]}this._updateIndices()}function d(a){if(!a._webAnimationsPatchedStyle){var d=new c(a);try{b(a,"style",{get:function(){return d}})}catch(e){a.style._set=function(b,c){a.style[b]=c},a.style._clear=function(b){a.style[b]=""}}a._webAnimationsPatchedStyle=a.style}}var e={cssText:1,length:1,parentRule:1},f={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},g={removeProperty:1,setProperty:1};c.prototype={get cssText(){return this._surrogateStyle.cssText},set cssText(a){for(var b={},c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;this._surrogateStyle.cssText=a,this._updateIndices();for(var c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;for(var d in b)this._isAnimatedProperty[d]||this._style.setProperty(d,this._surrogateStyle.getPropertyValue(d))},get length(){return this._surrogateStyle.length},get parentRule(){return this._style.parentRule},_updateIndices:function(){for(;this._length<this._surrogateStyle.length;)Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,get:function(a){return function(){return this._surrogateStyle[a]}}(this._length)}),this._length++;for(;this._length>this._surrogateStyle.length;)this._length--,Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,value:void 0})},_set:function(a,b){this._style[a]=b,this._isAnimatedProperty[a]=!0},_clear:function(a){this._style[a]=this._surrogateStyle[a],delete this._isAnimatedProperty[a]}};for(var h in f)c.prototype[h]=function(a,b){return function(){var c=this._surrogateStyle[a].apply(this._surrogateStyle,arguments);return b&&(this._isAnimatedProperty[arguments[0]]||this._style[a].apply(this._style,arguments),this._updateIndices()),c}}(h,h in g);for(var i in document.documentElement.style)i in e||i in f||!function(a){b(c.prototype,a,{get:function(){return this._surrogateStyle[a]},set:function(b){this._surrogateStyle[a]=b,this._updateIndices(),this._isAnimatedProperty[a]||(this._style[a]=b)}})}(i);a.apply=function(b,c,e){d(b),b.style._set(a.propertyName(c),e)},a.clear=function(b,c){b._webAnimationsPatchedStyle&&b.style._clear(a.propertyName(c))}}(d,f),function(a){window.Element.prototype.animate=function(b,c){return a.timeline._play(a.KeyframeEffect(this,b,c))}}(d),function(a){function b(a,c,d){if("number"==typeof a&&"number"==typeof c)return a*(1-d)+c*d;if("boolean"==typeof a&&"boolean"==typeof c)return.5>d?a:c;if(a.length==c.length){for(var e=[],f=0;f<a.length;f++)e.push(b(a[f],c[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+c}a.Interpolation=function(a,c,d){return function(e){return d(b(a,c,e))}}}(d,f),function(a){function b(a,b,c){return Math.max(Math.min(a,c),b)}function c(c,d,e){var f=a.dot(c,d);f=b(f,-1,1);var g=[];if(1===f)g=c;else for(var h=Math.acos(f),i=1*Math.sin(e*h)/Math.sqrt(1-f*f),j=0;4>j;j++)g.push(c[j]*(Math.cos(e*h)-f*i)+d[j]*i);return g}var d=function(){function a(a,b){for(var c=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],d=0;4>d;d++)for(var e=0;4>e;e++)for(var f=0;4>f;f++)c[d][e]+=b[d][f]*a[f][e];return c}function b(a){return 0==a[0][2]&&0==a[0][3]&&0==a[1][2]&&0==a[1][3]&&0==a[2][0]&&0==a[2][1]&&1==a[2][2]&&0==a[2][3]&&0==a[3][2]&&1==a[3][3]}function c(c,d,e,f,g){for(var h=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],i=0;4>i;i++)h[i][3]=g[i];for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[3][i]+=c[j]*h[j][i];var k=f[0],l=f[1],m=f[2],n=f[3],o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];o[0][0]=1-2*(l*l+m*m),o[0][1]=2*(k*l-m*n),o[0][2]=2*(k*m+l*n),o[1][0]=2*(k*l+m*n),o[1][1]=1-2*(k*k+m*m),o[1][2]=2*(l*m-k*n),o[2][0]=2*(k*m-l*n),o[2][1]=2*(l*m+k*n),o[2][2]=1-2*(k*k+l*l),h=a(h,o);var p=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];e[2]&&(p[2][1]=e[2],h=a(h,p)),e[1]&&(p[2][1]=0,p[2][0]=e[0],h=a(h,p)),e[0]&&(p[2][0]=0,p[1][0]=e[0],h=a(h,p));for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[i][j]*=d[i];return b(h)?[h[0][0],h[0][1],h[1][0],h[1][1],h[3][0],h[3][1]]:h[0].concat(h[1],h[2],h[3])}return c}();a.composeMatrix=d,a.quat=c}(d,f),function(a){var b=0,c=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};a.Animation=function(a){this._sequenceNumber=b++,this._currentTime=0,this._startTime=null,this.paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!1,this.onfinish=null,this._finishHandlers=[],this._effect=a,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},a.Animation.prototype={_ensureAlive:function(){this._inEffect=this._effect._update(this.playbackRate<0&&0===this.currentTime?-1:this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,a.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this.finished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(b){b=+b,isNaN(b)||(a.restart(),this.paused||null==this._startTime||(this._startTime=this._timeline.currentTime-b/this._playbackRate),this._currentTimePending=!1,this._currentTime!=b&&(this._tickCurrentTime(b,!0),a.invalidateEffects()))},get startTime(){return this._startTime},set startTime(b){b=+b,isNaN(b)||this.paused||this._idle||(this._startTime=b,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),a.invalidateEffects())},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var b=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!=b&&(this.currentTime=b)}},get finished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this.paused&&0!=this.playbackRate||this._currentTimePending?"pending":this.paused?"paused":this.finished?"finished":"running"},play:function(){this.paused=!1,(this.finished||this._idle)&&(this._currentTime=this._playbackRate>0?0:this._totalDuration,this._startTime=null,a.invalidateEffects()),this._finishedFlag=!1,a.restart(),this._idle=!1,this._ensureAlive()},pause:function(){this.finished||this.paused||this._idle||(this._currentTimePending=!0),this._startTime=null,this.paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1)},cancel:function(){this._inEffect=!1,this._idle=!0,this.currentTime=0,this._startTime=null},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(a,b){"function"==typeof b&&"finish"==a&&this._finishHandlers.push(b)},removeEventListener:function(a,b){if("finish"==a){var c=this._finishHandlers.indexOf(b);c>=0&&this._finishHandlers.splice(c,1)}},_fireEvents:function(a){var b=this.finished;if((b||this._idle)&&!this._finishedFlag){var d=new c(this,this._currentTime,a),e=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){e.forEach(function(a){a.call(d.target,d)})},0)}this._finishedFlag=b},_tick:function(a){return this._idle||this.paused||(null==this._startTime?this.startTime=a-this._currentTime/this.playbackRate:this.finished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),this._currentTimePending=!1,this._fireEvents(a),!this._idle&&(this._inEffect||!this._finishedFlag)}}}(d,f),function(a,b){function c(a){var b=i;i=[],g(a),b.forEach(function(b){b[1](a)}),m&&g(a),f()}function d(a,b){return a._sequenceNumber-b._sequenceNumber}function e(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function f(){n.forEach(function(a){a()}),n.length=0}function g(a){l=!1;var c=b.timeline;c.currentTime=a,c._animations.sort(d),k=!1;var e=c._animations;c._animations=[];var f=[],g=[];e=e.filter(function(b){return b._inTimeline=b._tick(a),b._inEffect?g.push(b._effect):f.push(b._effect),b.finished||b.paused||b._idle||(k=!0),b._inTimeline}),n.push.apply(n,f),n.push.apply(n,g),c._animations.push.apply(c._animations,e),m=!1,k&&requestAnimationFrame(function(){})}var h=window.requestAnimationFrame,i=[],j=0;window.requestAnimationFrame=function(a){var b=j++;return 0==i.length&&h(c),i.push([b,a]),b},window.cancelAnimationFrame=function(a){i.forEach(function(b){b[0]==a&&(b[1]=function(){})})},e.prototype={_play:function(c){c._timing=a.normalizeTimingInput(c.timing);var d=new b.Animation(c);return d._idle=!1,d._timeline=this,this._animations.push(d),b.restart(),b.invalidateEffects(),d}};var k=!1,l=!1;b.restart=function(){return k||(k=!0,requestAnimationFrame(function(){}),l=!0),l};var m=!1;b.invalidateEffects=function(){m=!0};var n=[],o=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){return m&&g(p.currentTime),f(),o.apply(this,arguments)}});var p=new e;b.timeline=p}(c,d,f),function(a){function b(a,b){for(var c=0,d=0;d<a.length;d++)c+=a[d]*b[d];return c}function c(a,b){return[a[0]*b[0]+a[4]*b[1]+a[8]*b[2]+a[12]*b[3],a[1]*b[0]+a[5]*b[1]+a[9]*b[2]+a[13]*b[3],a[2]*b[0]+a[6]*b[1]+a[10]*b[2]+a[14]*b[3],a[3]*b[0]+a[7]*b[1]+a[11]*b[2]+a[15]*b[3],a[0]*b[4]+a[4]*b[5]+a[8]*b[6]+a[12]*b[7],a[1]*b[4]+a[5]*b[5]+a[9]*b[6]+a[13]*b[7],a[2]*b[4]+a[6]*b[5]+a[10]*b[6]+a[14]*b[7],a[3]*b[4]+a[7]*b[5]+a[11]*b[6]+a[15]*b[7],a[0]*b[8]+a[4]*b[9]+a[8]*b[10]+a[12]*b[11],a[1]*b[8]+a[5]*b[9]+a[9]*b[10]+a[13]*b[11],a[2]*b[8]+a[6]*b[9]+a[10]*b[10]+a[14]*b[11],a[3]*b[8]+a[7]*b[9]+a[11]*b[10]+a[15]*b[11],a[0]*b[12]+a[4]*b[13]+a[8]*b[14]+a[12]*b[15],a[1]*b[12]+a[5]*b[13]+a[9]*b[14]+a[13]*b[15],a[2]*b[12]+a[6]*b[13]+a[10]*b[14]+a[14]*b[15],a[3]*b[12]+a[7]*b[13]+a[11]*b[14]+a[15]*b[15]]}function d(a){switch(a.t){case"rotatex":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,0,Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1];case"rotatey":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),0,-Math.sin(d),0,0,1,0,0,Math.sin(d),0,Math.cos(d),0,0,0,0,1];case"rotate":case"rotatez":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var e=a.d[0],f=a.d[1],g=a.d[2],b=a.d[3].rad||0,c=a.d[3].deg||0,d=c*Math.PI/180+b,h=e*e+f*f+g*g;if(0===h)e=1,f=0,g=0;else if(1!==h){var i=Math.sqrt(h);e/=i,f/=i,g/=i}var j=Math.sin(d/2),k=j*Math.cos(d/2),l=j*j;return[1-2*(f*f+g*g)*l,2*(e*f*l+g*k),2*(e*g*l-f*k),0,2*(e*f*l-g*k),1-2*(e*e+g*g)*l,2*(f*g*l+e*k),0,2*(e*g*l+f*k),2*(f*g*l-e*k),1-2*(e*e+f*f)*l,0,0,0,0,1];case"scale":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,1,0,0,0,0,1];case"scalex":return[a.d[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"scaley":return[1,0,0,0,0,a.d[0],0,0,0,0,1,0,0,0,0,1];case"scalez":return[1,0,0,0,0,1,0,0,0,0,a.d[0],0,0,0,0,1];case"scale3d":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,a.d[2],0,0,0,0,1];case"skew":var m=a.d[0].deg||0,n=a.d[0].rad||0,o=a.d[1].deg||0,p=a.d[1].rad||0,q=m*Math.PI/180+n,r=o*Math.PI/180+p;return[1,Math.tan(r),0,0,Math.tan(q),1,0,0,0,0,1,0,0,0,0,1];case"skewx":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,Math.tan(d),1,0,0,0,0,1,0,0,0,0,1];case"skewy":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,Math.tan(d),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":var e=a.d[0].px||0,f=a.d[1].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,0,1];case"translatex":var e=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,0,0,1];case"translatey":var f=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,f,0,1];case"translatez":var g=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,g,1];case"translate3d":var e=a.d[0].px||0,f=a.d[1].px||0,g=a.d[2].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,g,1];case"perspective":var s=a.d[0].px?-1/a.d[0].px:0;return[1,0,0,0,0,1,0,0,0,0,1,s,0,0,0,1];case"matrix":return[a.d[0],a.d[1],0,0,a.d[2],a.d[3],0,0,0,0,1,0,a.d[4],a.d[5],0,1];case"matrix3d":return a.d}}function e(a){return 0===a.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:a.map(d).reduce(c)}function f(a){return[g(e(a))]}var g=function(){function a(a){return a[0][0]*a[1][1]*a[2][2]+a[1][0]*a[2][1]*a[0][2]+a[2][0]*a[0][1]*a[1][2]-a[0][2]*a[1][1]*a[2][0]-a[1][2]*a[2][1]*a[0][0]-a[2][2]*a[0][1]*a[1][0]}function c(b){for(var c=1/a(b),d=b[0][0],e=b[0][1],f=b[0][2],g=b[1][0],h=b[1][1],i=b[1][2],j=b[2][0],k=b[2][1],l=b[2][2],m=[[(h*l-i*k)*c,(f*k-e*l)*c,(e*i-f*h)*c,0],[(i*j-g*l)*c,(d*l-f*j)*c,(f*g-d*i)*c,0],[(g*k-h*j)*c,(j*e-d*k)*c,(d*h-e*g)*c,0]],n=[],o=0;3>o;o++){for(var p=0,q=0;3>q;q++)p+=b[3][q]*m[q][o];n.push(p)}return n.push(1),m.push(n),m}function d(a){return[[a[0][0],a[1][0],a[2][0],a[3][0]],[a[0][1],a[1][1],a[2][1],a[3][1]],[a[0][2],a[1][2],a[2][2],a[3][2]],[a[0][3],a[1][3],a[2][3],a[3][3]]]}function e(a,b){for(var c=[],d=0;4>d;d++){for(var e=0,f=0;4>f;f++)e+=a[f]*b[f][d];c.push(e)}return c}function f(a){var b=g(a);return[a[0]/b,a[1]/b,a[2]/b]}function g(a){return Math.sqrt(a[0]*a[0]+a[1]*a[1]+a[2]*a[2])}function h(a,b,c,d){return[c*a[0]+d*b[0],c*a[1]+d*b[1],c*a[2]+d*b[2]]}function i(a,b){return[a[1]*b[2]-a[2]*b[1],a[2]*b[0]-a[0]*b[2],a[0]*b[1]-a[1]*b[0]]}function j(j){var k=[j.slice(0,4),j.slice(4,8),j.slice(8,12),j.slice(12,16)];if(1!==k[3][3])return null;for(var l=[],m=0;4>m;m++)l.push(k[m].slice());for(var m=0;3>m;m++)l[m][3]=0;if(0===a(l))return!1;var n,o=[];if(k[0][3]||k[1][3]||k[2][3]){o.push(k[0][3]),o.push(k[1][3]),o.push(k[2][3]),o.push(k[3][3]);var p=c(l),q=d(p);n=e(o,q)}else n=[0,0,0,1];var r=k[3].slice(0,3),s=[];s.push(k[0].slice(0,3));var t=[];t.push(g(s[0])),s[0]=f(s[0]);var u=[];s.push(k[1].slice(0,3)),u.push(b(s[0],s[1])),s[1]=h(s[1],s[0],1,-u[0]),t.push(g(s[1])),s[1]=f(s[1]),u[0]/=t[1],s.push(k[2].slice(0,3)),u.push(b(s[0],s[2])),s[2]=h(s[2],s[0],1,-u[1]),u.push(b(s[1],s[2])),s[2]=h(s[2],s[1],1,-u[2]),t.push(g(s[2])),s[2]=f(s[2]),u[1]/=t[2],u[2]/=t[2];var v=i(s[1],s[2]);if(b(s[0],v)<0)for(var m=0;3>m;m++)t[m]*=-1,s[m][0]*=-1,s[m][1]*=-1,s[m][2]*=-1;var w,x,y=s[0][0]+s[1][1]+s[2][2]+1;return y>1e-4?(w=.5/Math.sqrt(y),x=[(s[2][1]-s[1][2])*w,(s[0][2]-s[2][0])*w,(s[1][0]-s[0][1])*w,.25/w]):s[0][0]>s[1][1]&&s[0][0]>s[2][2]?(w=2*Math.sqrt(1+s[0][0]-s[1][1]-s[2][2]),x=[.25*w,(s[0][1]+s[1][0])/w,(s[0][2]+s[2][0])/w,(s[2][1]-s[1][2])/w]):s[1][1]>s[2][2]?(w=2*Math.sqrt(1+s[1][1]-s[0][0]-s[2][2]),x=[(s[0][1]+s[1][0])/w,.25*w,(s[1][2]+s[2][1])/w,(s[0][2]-s[2][0])/w]):(w=2*Math.sqrt(1+s[2][2]-s[0][0]-s[1][1]),x=[(s[0][2]+s[2][0])/w,(s[1][2]+s[2][1])/w,.25*w,(s[1][0]-s[0][1])/w]),[r,t,u,x,n]}return j}();a.dot=b,a.makeMatrixDecomposition=f}(d,f),function(a){function b(a,b){var c=a.exec(b);return c?(c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]):void 0}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);return c?[c[0],c[1].replace(/^\s*/,"")]:void 0}function d(a,d,e){a=c.bind(null,a);for(var f=[];;){var g=a(e);if(!g)return[f,e];if(f.push(g[0]),e=g[1],g=b(d,e),!g||""==g[1])return[f,e];e=g[1]}}function e(a,b){for(var c=0,d=0;d<b.length&&(!/\s|,/.test(b[d])||0!=c);d++)if("("==b[d])c++;else if(")"==b[d]&&(c--,0==c&&d++,0>=c))break;var e=a(b.substr(0,d));return void 0==e?void 0:[e,b.substr(d)]}function f(a,b){for(var c=a,d=b;c&&d;)c>d?c%=d:d%=c;return c=a*b/(c+d)}function g(a){return function(b){var c=a(b);return c&&(c[0]=void 0),c}}function h(a,b){return function(c){var d=a(c);return d?d:[b,c]}}function i(b,c){for(var d=[],e=0;e<b.length;e++){var f=a.consumeTrimmed(b[e],c);if(!f||""==f[0])return;void 0!==f[0]&&d.push(f[0]),c=f[1]}return""==c?d:void 0}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;j>k;k++){var l=b(d[k%d.length],e[k%e.length]);if(!l)return;g.push(l[0]),h.push(l[1]),i.push(l[2])}return[g,h,function(b){var d=b.map(function(a,b){return i[b](a)}).join(c);return a?a(d):d}]}function k(a,b,c){for(var d=[],e=[],f=[],g=0,h=0;h<c.length;h++)if("function"==typeof c[h]){var i=c[h](a[g],b[g++]);d.push(i[0]),e.push(i[1]),f.push(i[2])}else!function(a){d.push(!1),e.push(!1),f.push(function(){return c[a]})}(h);return[d,e,function(a){for(var b="",c=0;c<a.length;c++)b+=f[c](a[c]);return b}]}a.consumeToken=b,a.consumeTrimmed=c,a.consumeRepeated=d,a.consumeParenthesised=e,a.ignore=g,a.optional=h,a.consumeList=i,a.mergeNestedRepeated=j.bind(null,null),a.mergeWrappedNestedRepeated=j,a.mergeList=k}(d),function(a){function b(b){function c(b){var c=a.consumeToken(/^inset/i,b);if(c)return d.inset=!0,c;var c=a.consumeLengthOrPercent(b);if(c)return d.lengths.push(c[0]),c;var c=a.consumeColor(b);return c?(d.color=c[0],c):void 0}var d={inset:!1,lengths:[],color:null},e=a.consumeRepeated(c,/^/,b);return e&&e[0].length?[d,e[1]]:void 0}function c(c){var d=a.consumeRepeated(b,/^,/,c);return d&&""==d[1]?d[0]:void 0}function d(b,c){for(;b.lengths.length<Math.max(b.lengths.length,c.lengths.length);)b.lengths.push({px:0});for(;c.lengths.length<Math.max(b.lengths.length,c.lengths.length);)c.lengths.push({px:0});if(b.inset==c.inset&&!!b.color==!!c.color){for(var d,e=[],f=[[],0],g=[[],0],h=0;h<b.lengths.length;h++){var i=a.mergeDimensions(b.lengths[h],c.lengths[h],2==h);f[0].push(i[0]),g[0].push(i[1]),e.push(i[2])}if(b.color&&c.color){var j=a.mergeColors(b.color,c.color);f[1]=j[0],g[1]=j[1],d=j[2]}return[f,g,function(a){for(var c=b.inset?"inset ":" ",f=0;f<e.length;f++)c+=e[f](a[0][f])+" ";return d&&(c+=d(a[1])),c}]}}function e(b,c,d,e){function f(a){return{inset:a,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var g=[],h=[],i=0;i<d.length||i<e.length;i++){var j=d[i]||f(e[i].inset),k=e[i]||f(d[i].inset);g.push(j),h.push(k)}return a.mergeNestedRepeated(b,c,g,h)}var f=e.bind(null,d,", ");a.addPropertiesHandler(c,f,["box-shadow","text-shadow"])}(d),function(a){function b(a){return a.toFixed(3).replace(".000","")}function c(a,b,c){return Math.min(b,Math.max(a,c))}function d(a){return/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a)?Number(a):void 0}function e(a,c){return[a,c,b]}function f(a,b){return 0!=a?h(0,1/0)(a,b):void 0}function g(a,b){return[a,b,function(a){return Math.round(c(1,1/0,a))}]}function h(a,d){return function(e,f){return[e,f,function(e){return b(c(a,d,e))}]}}function i(a,b){return[a,b,Math.round]}a.clamp=c,a.addPropertiesHandler(d,h(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(d,h(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(d,f,["flex-grow","flex-shrink"]),a.addPropertiesHandler(d,g,["orphans","widows"]),a.addPropertiesHandler(d,i,["z-index"]),a.parseNumber=d,a.mergeNumbers=e,a.numberToString=b}(d,f),function(a){function b(a,b){return"visible"==a||"visible"==b?[0,1,function(c){return 0>=c?a:c>=1?b:"visible"}]:void 0}a.addPropertiesHandler(String,b,["visibility"])}(d),function(a){function b(a){a=a.trim(),e.fillStyle="#000",e.fillStyle=a;var b=e.fillStyle;if(e.fillStyle="#fff",e.fillStyle=a,b==e.fillStyle){e.fillRect(0,0,1,1);var c=e.getImageData(0,0,1,1).data;e.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function c(b,c){return[b,c,function(b){function c(a){return Math.max(0,Math.min(255,a))}if(b[3])for(var d=0;3>d;d++)b[d]=Math.round(c(b[d]/b[3]));return b[3]=a.numberToString(a.clamp(0,1,b[3])),"rgba("+b.join(",")+")"}]}var d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=d.height=1;var e=d.getContext("2d");a.addPropertiesHandler(b,c,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,b),a.mergeColors=c}(d,f),function(a,b){function c(a,b){if(b=b.trim().toLowerCase(),"0"==b&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var c={};b=b.replace(a,function(a){return c[a]=null,"U"+a});for(var d="U("+a.source+")",e=b.replace(/[-+]?(\d*\.)?\d+/g,"N").replace(new RegExp("N"+d,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),f=[/N\*(D)/g,/(N|D)[*/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],g=0;g<f.length;)f[g].test(e)?(e=e.replace(f[g],"$1"),g=0):g++;if("D"==e){for(var h in c){var i=eval(b.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(d,"g"),"*0"));if(!isFinite(i))return;c[h]=i}return c}}}function d(a,b){return e(a,b,!0)}function e(b,c,d){var e,f=[];for(e in b)f.push(e);for(e in c)f.indexOf(e)<0&&f.push(e);return b=f.map(function(a){return b[a]||0}),c=f.map(function(a){return c[a]||0}),[b,c,function(b){var c=b.map(function(c,e){return 1==b.length&&d&&(c=Math.max(c,0)),a.numberToString(c)+f[e]}).join(" + ");return b.length>1?"calc("+c+")":c}]}var f="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",g=c.bind(null,new RegExp(f,"g")),h=c.bind(null,new RegExp(f+"|%","g")),i=c.bind(null,/deg|rad|grad|turn/g);a.parseLength=g,a.parseLengthOrPercent=h,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,h),a.parseAngle=i,a.mergeDimensions=e;var j=a.consumeParenthesised.bind(null,g),k=a.consumeRepeated.bind(void 0,j,/^/),l=a.consumeRepeated.bind(void 0,k,/^,/);a.consumeSizePairList=l;var m=function(a){var b=l(a);return b&&""==b[1]?b[0]:void 0},n=a.mergeNestedRepeated.bind(void 0,d," "),o=a.mergeNestedRepeated.bind(void 0,n,",");a.mergeNonNegativeSizePair=n,a.addPropertiesHandler(m,o,["background-size"]),a.addPropertiesHandler(h,d,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),a.addPropertiesHandler(h,e,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","text-indent","top","vertical-align","word-spacing"])}(d,f),function(a){function b(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function c(c){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,b,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],c);return d&&4==d[0].length?d[0]:void 0}function d(b,c){return"auto"==b||"auto"==c?[!0,!1,function(d){var e=d?b:c;if("auto"==e)return"auto";var f=a.mergeDimensions(e,e);return f[2](f[0])}]:a.mergeDimensions(b,c)}function e(a){return"rect("+a+")"}var f=a.mergeWrappedNestedRepeated.bind(null,e,d,", ");a.parseBox=c,a.mergeBoxes=f,a.addPropertiesHandler(c,f,["clip"]) +}(d,f),function(a){function b(a){return function(b){var c=0;return a.map(function(a){return a===j?b[c++]:a})}}function c(a){return a}function d(b){if(b=b.toLowerCase().trim(),"none"==b)return[];for(var c,d=/\s*(\w+)\(([^)]*)\)/g,e=[],f=0;c=d.exec(b);){if(c.index!=f)return;f=c.index+c[0].length;var g=c[1],h=m[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var n=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(p=q?{A:function(b){return"0"==b.trim()?l:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:l,n:n[0],t:k}[r],void 0===p)return;n.push(p)}if(e.push({t:g,d:n}),d.lastIndex==b.length)return e}}function e(a){return a.toFixed(6).replace(".000000","")}function f(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var f=a.makeMatrixDecomposition(c)}return null==d[0]||null==f[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),f[0].push(1),[d,f,function(b){var c=a.quat(d[0][3],f[0][3],b[5]),g=a.composeMatrix(b[0],b[1],b[2],c,b[4]),h=g.map(e).join(",");return h}])}function g(a){return a.replace(/[xy]/,"")}function h(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function i(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var i=0;i<b.length;i++){var j=b[i].t,k=b[i].d,l="scale"==j.substr(0,5)?1:0;c.push({t:j,d:k.map(function(a){if("number"==typeof a)return l;var b={};for(var c in a)b[c]=l;return b})})}}var n=function(a,b){return"perspective"==a&&"perspective"==b||("matrix"==a||"matrix3d"==a)&&("matrix"==b||"matrix3d"==b)},o=[],p=[],q=[];if(b.length!=c.length){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var i=0;i<b.length;i++){var j,s=b[i].t,t=c[i].t,u=b[i].d,v=c[i].d,w=m[s],x=m[t];if(n(s,t)){if(!d)return;var r=f([b[i]],[c[i]]);o.push(r[0]),p.push(r[1]),q.push(["matrix",[r[2]]])}else{if(s==t)j=s;else if(w[2]&&x[2]&&g(s)==g(t))j=g(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||h(s)!=h(t)){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=h(s),u=w[1](u),v=x[1](v)}for(var y=[],z=[],A=[],B=0;B<u.length;B++){var C="number"==typeof u[B]?a.mergeNumbers:a.mergeDimensions,r=C(u[B],v[B]);y[B]=r[0],z[B]=r[1],A.push(r[2])}o.push(y),p.push(z),q.push([j,A])}}if(e){var D=o;o=p,p=D}return[o,p,function(a){return a.map(function(a,b){var c=a.map(function(a,c){return q[b][1][c](a)}).join(",");return"matrix"==q[b][0]&&16==c.split(",").length&&(q[b][0]="matrix3d"),q[b][0]+"("+c+")"}).join(" ")}]}var j=null,k={px:0},l={deg:0},m={matrix:["NNNNNN",[j,j,0,0,j,j,0,0,0,0,1,0,j,j,0,1],c],matrix3d:["NNNNNNNNNNNNNNNN",c],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",b([j,j,1]),c],scalex:["N",b([j,1,1]),b([j,1])],scaley:["N",b([1,j,1]),b([1,j])],scalez:["N",b([1,1,j])],scale3d:["NNN",c],skew:["Aa",null,c],skewx:["A",null,b([j,l])],skewy:["A",null,b([l,j])],translate:["Tt",b([j,j,k]),c],translatex:["T",b([j,k,k]),b([j,k])],translatey:["T",b([k,j,k]),b([k,j])],translatez:["L",b([k,k,j])],translate3d:["TTL",c]};a.addPropertiesHandler(d,i,["transform"])}(d,f),function(a){function b(a){var b=Number(a);return isNaN(b)||100>b||b>900||b%100!==0?void 0:b}function c(b){return b=100*Math.round(b/100),b=a.clamp(100,900,b),400===b?"normal":700===b?"bold":String(b)}function d(a,b){return[a,b,c]}a.addPropertiesHandler(b,d,["font-weight"])}(d),function(a){function b(a){var b={};for(var c in a)b[c]=-a[c];return b}function c(b){return a.consumeToken(/^(left|center|right|top|bottom)\b/i,b)||a.consumeLengthOrPercent(b)}function d(b,d){var e=a.consumeRepeated(c,/^/,d);if(e&&""==e[1]){var f=e[0];if(f[0]=f[0]||"center",f[1]=f[1]||"center",3==b&&(f[2]=f[2]||{px:0}),f.length==b){if(/top|bottom/.test(f[0])||/left|right/.test(f[1])){var h=f[0];f[0]=f[1],f[1]=h}if(/left|right|center|Object/.test(f[0])&&/top|bottom|center|Object/.test(f[1]))return f.map(function(a){return"object"==typeof a?a:g[a]})}}}function e(d){var e=a.consumeRepeated(c,/^/,d);if(e){for(var f=e[0],h=[{"%":50},{"%":50}],i=0,j=!1,k=0;k<f.length;k++){var l=f[k];"string"==typeof l?(j=/bottom|right/.test(l),i={left:0,right:0,center:i,top:1,bottom:1}[l],h[i]=g[l],"center"==l&&i++):(j&&(l=b(l),l["%"]=(l["%"]||0)+100),h[i]=l,i++,j=!1)}return[h,e[1]]}}function f(b){var c=a.consumeRepeated(e,/^,/,b);return c&&""==c[1]?c[0]:void 0}var g={left:{"%":0},center:{"%":50},right:{"%":100},top:{"%":0},bottom:{"%":100}},h=a.mergeNestedRepeated.bind(null,a.mergeDimensions," ");a.addPropertiesHandler(d.bind(null,3),h,["transform-origin"]),a.addPropertiesHandler(d.bind(null,2),h,["perspective-origin"]),a.consumePosition=e,a.mergeOffsetList=h;var i=a.mergeNestedRepeated.bind(null,h,", ");a.addPropertiesHandler(f,i,["background-position","object-position"])}(d),function(a){function b(b){var c=a.consumeToken(/^circle/,b);if(c&&c[0])return["circle"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),d,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],c[1]));var f=a.consumeToken(/^ellipse/,b);if(f&&f[0])return["ellipse"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),e,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],f[1]));var g=a.consumeToken(/^polygon/,b);return g&&g[0]?["polygon"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),a.optional(a.consumeToken.bind(void 0,/^nonzero\s*,|^evenodd\s*,/),"nonzero,"),a.consumeSizePairList,a.ignore(a.consumeToken.bind(void 0,/^\)/))],g[1])):void 0}function c(b,c){return b[0]===c[0]?"circle"==b[0]?a.mergeList(b.slice(1),c.slice(1),["circle(",a.mergeDimensions," at ",a.mergeOffsetList,")"]):"ellipse"==b[0]?a.mergeList(b.slice(1),c.slice(1),["ellipse(",a.mergeNonNegativeSizePair," at ",a.mergeOffsetList,")"]):"polygon"==b[0]&&b[1]==c[1]?a.mergeList(b.slice(2),c.slice(2),["polygon(",b[1],g,")"]):void 0:void 0}var d=a.consumeParenthesised.bind(null,a.parseLengthOrPercent),e=a.consumeRepeated.bind(void 0,d,/^/),f=a.mergeNestedRepeated.bind(void 0,a.mergeDimensions," "),g=a.mergeNestedRepeated.bind(void 0,f,",");a.addPropertiesHandler(b,c,["shape-outside"])}(d),function(a){function b(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(c[a]=b)})}var c={};b("transform",["webkitTransform","msTransform"]),b("transformOrigin",["webkitTransformOrigin"]),b("perspective",["webkitPerspective"]),b("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return c[a]||a}}(d,f)}()}({},function(){return this}()); +//# sourceMappingURL=web-animations.min.js.map
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.min.js.map b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.min.js.map new file mode 100644 index 0000000..fdf6c02 --- /dev/null +++ b/third_party/polymer/v1_0/components-chromium/web-animations-js/web-animations.min.js.map @@ -0,0 +1 @@ +{"version":3,"file":"web-animations.min.js","sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/keyframe-interpolations.js","src/property-interpolation.js","src/keyframe-effect.js","src/apply-preserving-inline-style.js","src/element-animatable.js","src/interpolation.js","src/matrix-interpolation.js","src/animation.js","src/tick.js"],"names":["webAnimationsShared","webAnimations1","webAnimationsNext","WEB_ANIMATIONS_TESTING","webAnimationsTesting","shared","testing","makeTiming","timingInput","timing","delay","endDelay","fill","forGroup","iterationStart","iterations","direction","isNaN","getOwnPropertyNames","forEach","property","fills","indexOf","directions","isDeprecated","duration","normalizeTimingInput","easing","toTimingFunction","cubic","c","a","linear","x","f","b","m","start","mid","end","xEst","Math","abs","step","count","pos","stepSize","cubicData","cubicBezierRe","exec","apply","Number","stepData","stepRe","Start","middle","Middle","End","preset","presets","calculateActiveDuration","repeatedDuration","playbackRate","calculatePhase","activeDuration","localTime","PhaseNone","PhaseBefore","PhaseAfter","calculateActiveTime","fillMode","PhaseActive","calculateScaledActiveTime","activeTime","startOffset","calculateIterationTime","iterationDuration","scaledActiveTime","Infinity","calculateCurrentIteration","iterationTime","floor","calculateTransformedTime","currentIteration","currentIterationIsOdd","currentDirectionIsForwards","directedTime","timeFraction","calculateTimeFraction","phase","split","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","value","aliases","expandShorthandAndAntiAlias","longProperties","shorthandToLonghand","shorthandExpanderElem","style","i","longProperty","longhandValue","result","normalizeKeyframes","effectInput","spaceKeyframes","length","keyframes","offset","previousIndex","previousOffset","j","isArray","TypeError","map","originalKeyframe","member","memberValue","type","DOMException","NOT_SUPPORTED_ERR","message","keyframe","undefined","everyFrameHasOffset","code","INVALID_MODIFICATION_ERR","name","filter","background","border","borderBottom","borderColor","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","document","createElementNS","borderWidthAliases","medium","borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","fontSize","xx-small","small","x-large","xx-large","fontWeight","outlineWidth","textShadow","none","boxShadow","silenced","feature","date","advice","plural","today","Date","setMonth","getMonth","warn","expiry","toDateString","deprecated","auxVerb","Error","makePropertySpecificKeyframeGroups","propertySpecificKeyframeGroups","propertySpecificKeyframe","groupName","group","makeInterpolations","interpolations","startTime","endTime","startValue","endValue","push","interpolation","scope","propertyInterpolation","leftInterpolation","rightInterpolation","convertEffectInput","target","fraction","offsetFraction","localDuration","scaledLocalTime","clear","addPropertyHandler","parser","merger","propertyHandlers","addPropertiesHandler","properties","replace","toUpperCase","right","handlers","left","parsedLeft","parsedRight","interpolationArgs","interp","Interpolation","t","bool","effectTime","_totalDuration","_isCurrent","KeyframeEffect","keyframeEffect","_update","_hasSameTarget","otherTarget","nullEffect","configureProperty","object","descriptor","enumerable","configurable","Object","defineProperty","AnimatedCSSStyleDeclaration","element","_surrogateStyle","this","_style","_length","_isAnimatedProperty","_updateIndices","ensureStyleIsPatched","_webAnimationsPatchedStyle","animatedStyle","get","_set","styleAttributes","cssText","parentRule","styleMethods","getPropertyCSSValue","getPropertyPriority","getPropertyValue","removeProperty","setProperty","styleMutatingMethods","prototype","text","isAffectedProperty",{"end":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"start":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"name":"cssText"},"index","_clear","method","modifiesStyle","arguments","documentElement","set","propertyName","window","animate","timeline","_play","interpolate","from","r","to","convertToString","clamp","max","min","quat","toQ","dot","fromQ","product","theta","sin","sqrt","cos","composeMatrix","multiply","k","translate","scale","perspective","matrix","y","z","rotMatrix","w","temp","skew","is2D","concat","sequenceNumber","AnimationEvent","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","now","Animation","effect","_sequenceNumber","_currentTime","_startTime","paused","_playbackRate","_inTimeline","_finishedFlag","onfinish","_finishHandlers","_effect","_idle","_inEffect","_animations","_tickCurrentTime","newTime","ignoreLimit","finished","_ensureAlive","_currentTimePending","restart","_timeline","invalidateEffects","oldCurrentTime","playState","play","pause","finish","cancel","reverse","addEventListener","handler","removeEventListener","splice","_fireEvents","baseTime","setTimeout","call","event","processRafCallbacks","processing","rafCallbacks","tick","entry","needsRetick","applyPendingEffects","compareAnimations","leftAnimation","rightAnimation","InternalTimeline","performance","pendingEffects","hasRestartedThisFrame","sort","ticking","newPendingClears","newPendingEffects","updatingAnimations"],"mappings":"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"}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-a11y-announcer/.bower.json b/third_party/polymer/v1_0/components/iron-a11y-announcer/.bower.json new file mode 100644 index 0000000..54806db --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-announcer/.bower.json @@ -0,0 +1,38 @@ +{ + "name": "iron-a11y-announcer", + "version": "1.0.0", + "description": "A singleton element that simplifies announcing text to screen readers.", + "keywords": [ + "web-components", + "polymer", + "a11y", + "live" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-announcer.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + }, + "homepage": "https://github.com/PolymerElements/iron-a11y-announcer", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "c809efbb3fd27a25eef515acd2f46f07a5f5c6a2" + }, + "_source": "git://github.com/PolymerElements/iron-a11y-announcer.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-a11y-announcer" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-a11y-announcer/.gitignore b/third_party/polymer/v1_0/components/iron-a11y-announcer/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-announcer/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-a11y-announcer/README.md b/third_party/polymer/v1_0/components/iron-a11y-announcer/README.md new file mode 100644 index 0000000..5988d8c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-announcer/README.md @@ -0,0 +1,29 @@ +iron-a11y-announcer +=================== + +`iron-a11y-announcer` is a singleton element that is intended to add a11y +to features that require on-demand announcement from screen readers. In +order to make use of the announcer, it is best to request its availability +in the announcing element. + +Example: + + Polymer({ + is: 'x-chatty', + attached: function() { + // This will create the singlton element if it has not + // been created yet: + Polymer.IronA11yAnnouncer.requestAvailability(); + } + }); + +After the `iron-a11y-announcer` has been made available, elements can +make announces by firing bubbling `iron-announce` events. + +Example: + + this.fire('iron-announce', { + text: 'This is an announcement!' + }, { bubbles: true }); + +Note: announcements are only audible if you have a screen reader enabled. diff --git a/third_party/polymer/v1_0/components/iron-a11y-announcer/bower.json b/third_party/polymer/v1_0/components/iron-a11y-announcer/bower.json new file mode 100644 index 0000000..ce802c1 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-announcer/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-a11y-announcer", + "version": "1.0.0", + "description": "A singleton element that simplifies announcing text to screen readers.", + "keywords": [ + "web-components", + "polymer", + "a11y", + "live" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-announcer.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + } +} diff --git a/third_party/polymer/v1_0/components/iron-a11y-announcer/index.html b/third_party/polymer/v1_0/components/iron-a11y-announcer/index.html new file mode 100644 index 0000000..1f8889a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-announcer/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + + <title>iron-a11y-announcer</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-a11y-announcer/iron-a11y-announcer.html b/third_party/polymer/v1_0/components/iron-a11y-announcer/iron-a11y-announcer.html new file mode 100644 index 0000000..87e2be1 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-announcer/iron-a11y-announcer.html @@ -0,0 +1,125 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-a11y-announcer` is a singleton element that is intended to add a11y +to features that require on-demand announcement from screen readers. In +order to make use of the announcer, it is best to request its availability +in the announcing element. + +Example: + + Polymer({ + + is: 'x-chatty', + + attached: function() { + // This will create the singlton element if it has not + // been created yet: + Polymer.IronA11yAnnouncer.requestAvailability(); + } + }); + +After the `iron-a11y-announcer` has been made available, elements can +make announces by firing bubbling `iron-announce` events. + +Example: + + this.fire('iron-announce', { + text: 'This is an announcement!' + }, { bubbles: true }); + +Note: announcements are only audible if you have a screen reader enabled. + +@group Iron Elements +@demo demo/index.html +--> + +<dom-module id="iron-a11y-announcer"> + <style> + :host { + display: inline-block; + position: fixed; + clip: rect(0px,0px,0px,0px); + } + </style> + + <template> + <span aria-live$="[[mode]]">[[_text]]</span> + </template> + + <script> + + (function() { + 'use strict'; + + Polymer.IronA11yAnnouncer = Polymer({ + is: 'iron-a11y-announcer', + + properties: { + + /** + * The value of mode is used to set the `aria-live` attribute + * for the element that will be announced. Valid values are: `off`, + * `polite` and `assertive`. + */ + mode: { + type: String, + value: 'polite' + }, + + _text: { + type: String, + value: '' + } + }, + + created: function() { + if (!Polymer.IronA11yAnnouncer.instance) { + Polymer.IronA11yAnnouncer.instance = this; + } + + document.body.addEventListener('iron-announce', this._onIronAnnounce.bind(this)); + }, + + /** + * Cause a text string to be announced by screen readers. + * + * @param {string} text The text that should be announced. + */ + announce: function(text) { + this._text = ''; + this.async(function() { + this._text = text; + }, 100); + }, + + _onIronAnnounce: function(event) { + if (event.detail && event.detail.text) { + this.announce(event.detail.text); + } + } + }); + + Polymer.IronA11yAnnouncer.instance = null; + + Polymer.IronA11yAnnouncer.requestAvailability = function() { + if (!Polymer.IronA11yAnnouncer.instance) { + document.createElement('iron-a11y-announcer'); + } + + document.body.appendChild(Polymer.IronA11yAnnouncer.instance); + }; + })(); + + </script> +</dom-module> diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/.bower.json new file mode 100644 index 0000000..7a68cd2 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-a11y-keys-behavior", + "version": "1.0.1", + "description": "A behavior that enables keybindings for greater a11y.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys-behavior.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-a11y-keys-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "443f7fc3947aa1d2bb4817588da4bb67fcbbc09d" + }, + "_source": "git://github.com/PolymerElements/iron-a11y-keys-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-a11y-keys-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/README.md b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/README.md new file mode 100644 index 0000000..2d16daa --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/README.md @@ -0,0 +1,15 @@ +iron-a11y-keys-behavior +======================= + +`Polymer.IronA11yKeysBehavior` provides a normalized interface for processing +keyboard commands that pertain to [WAI-ARIA best practices](http://www.w3.org/TR/wai-aria-practices/#kbd_general_binding). +The element takes care of browser differences with respect to Keyboard events +and uses an expressive syntax to filter key presses. + +Use the `keyBindings` prototype property to express what combination of keys +will trigger the event to fire. + +Use the `key-event-target` attribute to set up event handlers on a specific +node. +The `keys-pressed` event will fire when one of the key combinations set with the +`keys` property is pressed. diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/bower.json b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/bower.json new file mode 100644 index 0000000..87e2f64 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/bower.json @@ -0,0 +1,27 @@ +{ + "name": "iron-a11y-keys-behavior", + "version": "1.0.0", + "description": "A behavior that enables keybindings for greater a11y.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys-behavior.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/index.html b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/index.html new file mode 100644 index 0000000..e533e79 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-a11y-keys-behavior</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html new file mode 100644 index 0000000..ba571b6 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys-behavior/iron-a11y-keys-behavior.html @@ -0,0 +1,418 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + (function() { + 'use strict'; + + /** + * Chrome uses an older version of DOM Level 3 Keyboard Events + * + * Most keys are labeled as text, but some are Unicode codepoints. + * Values taken from: http://www.w3.org/TR/2007/WD-DOM-Level-3-Events-20071221/keyset.html#KeySet-Set + */ + var KEY_IDENTIFIER = { + 'U+0009': 'tab', + 'U+001B': 'esc', + 'U+0020': 'space', + 'U+002A': '*', + 'U+0030': '0', + 'U+0031': '1', + 'U+0032': '2', + 'U+0033': '3', + 'U+0034': '4', + 'U+0035': '5', + 'U+0036': '6', + 'U+0037': '7', + 'U+0038': '8', + 'U+0039': '9', + 'U+0041': 'a', + 'U+0042': 'b', + 'U+0043': 'c', + 'U+0044': 'd', + 'U+0045': 'e', + 'U+0046': 'f', + 'U+0047': 'g', + 'U+0048': 'h', + 'U+0049': 'i', + 'U+004A': 'j', + 'U+004B': 'k', + 'U+004C': 'l', + 'U+004D': 'm', + 'U+004E': 'n', + 'U+004F': 'o', + 'U+0050': 'p', + 'U+0051': 'q', + 'U+0052': 'r', + 'U+0053': 's', + 'U+0054': 't', + 'U+0055': 'u', + 'U+0056': 'v', + 'U+0057': 'w', + 'U+0058': 'x', + 'U+0059': 'y', + 'U+005A': 'z', + 'U+007F': 'del' + }; + + /** + * Special table for KeyboardEvent.keyCode. + * KeyboardEvent.keyIdentifier is better, and KeyBoardEvent.key is even better + * than that. + * + * Values from: https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent.keyCode#Value_of_keyCode + */ + var KEY_CODE = { + 9: 'tab', + 13: 'enter', + 27: 'esc', + 33: 'pageup', + 34: 'pagedown', + 35: 'end', + 36: 'home', + 32: 'space', + 37: 'left', + 38: 'up', + 39: 'right', + 40: 'down', + 46: 'del', + 106: '*' + }; + + /** + * MODIFIER_KEYS maps the short name for modifier keys used in a key + * combo string to the property name that references those same keys + * in a KeyboardEvent instance. + */ + var MODIFIER_KEYS = { + shift: 'shiftKey', + ctrl: 'ctrlKey', + alt: 'altKey', + meta: 'metaKey' + }; + + /** + * KeyboardEvent.key is mostly represented by printable character made by + * the keyboard, with unprintable keys labeled nicely. + * + * However, on OS X, Alt+char can make a Unicode character that follows an + * Apple-specific mapping. In this case, we + * fall back to .keyCode. + */ + var KEY_CHAR = /[a-z0-9*]/; + + /** + * Matches a keyIdentifier string. + */ + var IDENT_CHAR = /U\+/; + + /** + * Matches arrow keys in Gecko 27.0+ + */ + var ARROW_KEY = /^arrow/; + + /** + * Matches space keys everywhere (notably including IE10's exceptional name + * `spacebar`). + */ + var SPACE_KEY = /^space(bar)?/; + + function transformKey(key) { + var validKey = ''; + if (key) { + var lKey = key.toLowerCase(); + if (lKey.length == 1) { + if (KEY_CHAR.test(lKey)) { + validKey = lKey; + } + } else if (ARROW_KEY.test(lKey)) { + validKey = lKey.replace('arrow', ''); + } else if (SPACE_KEY.test(lKey)) { + validKey = 'space'; + } else if (lKey == 'multiply') { + // numpad '*' can map to Multiply on IE/Windows + validKey = '*'; + } else { + validKey = lKey; + } + } + return validKey; + } + + function transformKeyIdentifier(keyIdent) { + var validKey = ''; + if (keyIdent) { + if (IDENT_CHAR.test(keyIdent)) { + validKey = KEY_IDENTIFIER[keyIdent]; + } else { + validKey = keyIdent.toLowerCase(); + } + } + return validKey; + } + + function transformKeyCode(keyCode) { + var validKey = ''; + if (Number(keyCode)) { + if (keyCode >= 65 && keyCode <= 90) { + // ascii a-z + // lowercase is 32 offset from uppercase + validKey = String.fromCharCode(32 + keyCode); + } else if (keyCode >= 112 && keyCode <= 123) { + // function keys f1-f12 + validKey = 'f' + (keyCode - 112); + } else if (keyCode >= 48 && keyCode <= 57) { + // top 0-9 keys + validKey = String(48 - keyCode); + } else if (keyCode >= 96 && keyCode <= 105) { + // num pad 0-9 + validKey = String(96 - keyCode); + } else { + validKey = KEY_CODE[keyCode]; + } + } + return validKey; + } + + function normalizedKeyForEvent(keyEvent) { + // fall back from .key, to .keyIdentifier, to .keyCode, and then to + // .detail.key to support artificial keyboard events + return transformKey(keyEvent.key) || + transformKeyIdentifier(keyEvent.keyIdentifier) || + transformKeyCode(keyEvent.keyCode) || + transformKey(keyEvent.detail.key) || ''; + } + + function keyComboMatchesEvent(keyCombo, keyEvent) { + return normalizedKeyForEvent(keyEvent) === keyCombo.key && + !!keyEvent.shiftKey === !!keyCombo.shiftKey && + !!keyEvent.ctrlKey === !!keyCombo.ctrlKey && + !!keyEvent.altKey === !!keyCombo.altKey && + !!keyEvent.metaKey === !!keyCombo.metaKey; + } + + function parseKeyComboString(keyComboString) { + return keyComboString.split('+').reduce(function(parsedKeyCombo, keyComboPart) { + var eventParts = keyComboPart.split(':'); + var keyName = eventParts[0]; + var event = eventParts[1]; + + if (keyName in MODIFIER_KEYS) { + parsedKeyCombo[MODIFIER_KEYS[keyName]] = true; + } else { + parsedKeyCombo.key = keyName; + parsedKeyCombo.event = event || 'keydown'; + } + + return parsedKeyCombo; + }, { + combo: keyComboString.split(':').shift() + }); + } + + function parseEventString(eventString) { + return eventString.split(' ').map(function(keyComboString) { + return parseKeyComboString(keyComboString); + }); + } + + + /** + * `Polymer.IronA11yKeysBehavior` provides a normalized interface for processing + * keyboard commands that pertain to [WAI-ARIA best practices](http://www.w3.org/TR/wai-aria-practices/#kbd_general_binding). + * The element takes care of browser differences with respect to Keyboard events + * and uses an expressive syntax to filter key presses. + * + * Use the `keyBindings` prototype property to express what combination of keys + * will trigger the event to fire. + * + * Use the `key-event-target` attribute to set up event handlers on a specific + * node. + * The `keys-pressed` event will fire when one of the key combinations set with the + * `keys` property is pressed. + * + * @polymerBehavior IronA11yKeysBehavior + */ + Polymer.IronA11yKeysBehavior = { + properties: { + /** + * The HTMLElement that will be firing relevant KeyboardEvents. + */ + keyEventTarget: { + type: Object, + value: function() { + return this; + } + }, + + _boundKeyHandlers: { + value: function() { + return []; + } + }, + + // We use this due to a limitation in IE10 where instances will have + // own properties of everything on the "prototype". + _imperativeKeyBindings: { + value: function() { + return {}; + } + } + }, + + observers: [ + '_resetKeyEventListeners(keyEventTarget, _boundKeyHandlers)' + ], + + keyBindings: {}, + + registered: function() { + this._prepKeyBindings(); + }, + + attached: function() { + this._listenKeyEventListeners(); + }, + + detached: function() { + this._unlistenKeyEventListeners(); + }, + + /** + * Can be used to imperatively add a key binding to the implementing + * element. This is the imperative equivalent of declaring a keybinding + * in the `keyBindings` prototype property. + */ + addOwnKeyBinding: function(eventString, handlerName) { + this._imperativeKeyBindings[eventString] = handlerName; + this._prepKeyBindings(); + this._resetKeyEventListeners(); + }, + + /** + * When called, will remove all imperatively-added key bindings. + */ + removeOwnKeyBindings: function() { + this._imperativeKeyBindings = {}; + this._prepKeyBindings(); + this._resetKeyEventListeners(); + }, + + keyboardEventMatchesKeys: function(event, eventString) { + var keyCombos = parseEventString(eventString); + var index; + + for (index = 0; index < keyCombos.length; ++index) { + if (keyComboMatchesEvent(keyCombos[index], event)) { + return true; + } + } + + return false; + }, + + _collectKeyBindings: function() { + var keyBindings = this.behaviors.map(function(behavior) { + return behavior.keyBindings; + }); + + if (keyBindings.indexOf(this.keyBindings) === -1) { + keyBindings.push(this.keyBindings); + } + + return keyBindings; + }, + + _prepKeyBindings: function() { + this._keyBindings = {}; + + this._collectKeyBindings().forEach(function(keyBindings) { + for (var eventString in keyBindings) { + this._addKeyBinding(eventString, keyBindings[eventString]); + } + }, this); + + for (var eventString in this._imperativeKeyBindings) { + this._addKeyBinding(eventString, this._imperativeKeyBindings[eventString]); + } + }, + + _addKeyBinding: function(eventString, handlerName) { + parseEventString(eventString).forEach(function(keyCombo) { + this._keyBindings[keyCombo.event] = + this._keyBindings[keyCombo.event] || []; + + this._keyBindings[keyCombo.event].push([ + keyCombo, + handlerName + ]); + }, this); + }, + + _resetKeyEventListeners: function() { + this._unlistenKeyEventListeners(); + + if (this.isAttached) { + this._listenKeyEventListeners(); + } + }, + + _listenKeyEventListeners: function() { + Object.keys(this._keyBindings).forEach(function(eventName) { + var keyBindings = this._keyBindings[eventName]; + var boundKeyHandler = this._onKeyBindingEvent.bind(this, keyBindings); + + this._boundKeyHandlers.push([this.keyEventTarget, eventName, boundKeyHandler]); + + this.keyEventTarget.addEventListener(eventName, boundKeyHandler); + }, this); + }, + + _unlistenKeyEventListeners: function() { + var keyHandlerTuple; + var keyEventTarget; + var eventName; + var boundKeyHandler; + + while (this._boundKeyHandlers.length) { + // My kingdom for block-scope binding and destructuring assignment.. + keyHandlerTuple = this._boundKeyHandlers.pop(); + keyEventTarget = keyHandlerTuple[0]; + eventName = keyHandlerTuple[1]; + boundKeyHandler = keyHandlerTuple[2]; + + keyEventTarget.removeEventListener(eventName, boundKeyHandler); + } + }, + + _onKeyBindingEvent: function(keyBindings, event) { + keyBindings.forEach(function(keyBinding) { + var keyCombo = keyBinding[0]; + var handlerName = keyBinding[1]; + + if (!event.defaultPrevented && keyComboMatchesEvent(keyCombo, event)) { + this._triggerKeyHandler(keyCombo, handlerName, event); + } + }, this); + }, + + _triggerKeyHandler: function(keyCombo, handlerName, keyboardEvent) { + var detail = Object.create(keyCombo); + detail.keyboardEvent = keyboardEvent; + + this[handlerName].call(this, new CustomEvent(keyCombo.event, { + detail: detail + })); + } + }; + })(); +</script> diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys/.bower.json b/third_party/polymer/v1_0/components/iron-a11y-keys/.bower.json new file mode 100644 index 0000000..7eb99e5 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys/.bower.json @@ -0,0 +1,38 @@ +{ + "name": "iron-a11y-keys", + "version": "1.0.0", + "description": "A basic element implementation of iron-a11y-keys-behavior, matching the legacy core-a11y-keys.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0" + }, + "homepage": "https://github.com/PolymerElements/iron-a11y-keys", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "11963b0e817ed910f5d13d1d68f4abac62c1a8f3" + }, + "_source": "git://github.com/PolymerElements/iron-a11y-keys.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-a11y-keys" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys/README.md b/third_party/polymer/v1_0/components/iron-a11y-keys/README.md new file mode 100644 index 0000000..514b4f5 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys/README.md @@ -0,0 +1,3 @@ +iron-a11y-keys +============== + diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys/bower.json b/third_party/polymer/v1_0/components/iron-a11y-keys/bower.json new file mode 100644 index 0000000..7776b7d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-a11y-keys", + "version": "1.0.0", + "description": "A basic element implementation of iron-a11y-keys-behavior, matching the legacy core-a11y-keys.", + "keywords": [ + "web-components", + "web-component", + "polymer", + "a11y", + "input" + ], + "authors": [ + "The Polymer Authors" + ], + "main": "iron-a11y-keys.html", + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys/index.html b/third_party/polymer/v1_0/components/iron-a11y-keys/index.html new file mode 100644 index 0000000..02c5182 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-a11y-keys</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-a11y-keys/iron-a11y-keys.html b/third_party/polymer/v1_0/components/iron-a11y-keys/iron-a11y-keys.html new file mode 100644 index 0000000..f937e87 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-a11y-keys/iron-a11y-keys.html @@ -0,0 +1,121 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + + +<script> + +/* +`iron-a11y-keys` provides a normalized interface for processing keyboard commands that pertain to [WAI-ARIA best +practices](http://www.w3.org/TR/wai-aria-practices/#kbd_general_binding). The element takes care of browser differences +with respect to Keyboard events and uses an expressive syntax to filter key presses. + +Use the `keys` attribute to express what combination of keys will trigger the event to fire. + +Use the `target` attribute to set up event handlers on a specific node. +The `keys-pressed` event will fire when one of the key combinations set with the `keys` attribute is pressed. + +Example: + +This element will call `arrowHandler` on all arrow keys: + + <iron-a11y-keys target="{{}}" keys="up down left right" on-keys-pressed="{{arrowHandler}}"></iron-a11y-keys> + +Keys Syntax: + +The `keys` attribute can accepts a space seprated, `+` concatenated set of modifier keys and some common keyboard keys. + +The common keys are `a-z`, `0-9` (top row and number pad), `*` (shift 8 and number pad), `F1-F12`, `Page Up`, `Page +Down`, `Left Arrow`, `Right Arrow`, `Down Arrow`, `Up Arrow`, `Home`, `End`, `Escape`, `Space`, `Tab`, and `Enter` keys. + +The modifier keys are `Shift`, `Control`, and `Alt`. + +All keys are expected to be lowercase and shortened: +`Left Arrow` is `left`, `Page Down` is `pagedown`, `Control` is `ctrl`, `F1` is `f1`, `Escape` is `esc` etc. + +Keys Syntax Example: + +Given the `keys` attribute value "ctrl+shift+f7 up pagedown esc space alt+m", the `<iron-a11y-keys>` element will send +the `keys-pressed` event if any of the follow key combos are pressed: Control and Shift and F7 keys, Up Arrow key, Page +Down key, Escape key, Space key, Alt and M key. + +Slider Example: + +The following is an example of the set of keys that fulfil the WAI-ARIA "slider" role [best +practices](http://www.w3.org/TR/wai-aria-practices/#slider): + + <iron-a11y-keys target="{{}}" keys="left pagedown down" on-keys-pressed="{{decrement}}"></iron-a11y-keys> + <iron-a11y-keys target="{{}}" keys="right pageup up" on-keys-pressed="{{increment}}"></iron-a11y-keys> + <iron-a11y-keys target="{{}}" keys="home" on-keys-pressed="{{setMin}}"></iron-a11y-keys> + <iron-a11y-keys target="{{}}" keys="end" on-keys-pressed="{{setMax}}"></iron-a11y-keys> + +The `increment` function will move the slider a set amount toward the maximum value. +The `decrement` function will move the slider a set amount toward the minimum value. +The `setMin` function will move the slider to the minimum value. +The `setMax` function will move the slider to the maximum value. + +Keys Syntax Grammar: + +[EBNF](http://en.wikipedia.org/wiki/Extended_Backus%E2%80%93Naur_Form) Grammar of the `keys` attribute. + + modifier = "shift" | "ctrl" | "alt"; + ascii = ? /[a-z0-9]/ ? ; + fnkey = ? f1 through f12 ? ; + arrow = "up" | "down" | "left" | "right" ; + key = "tab" | "esc" | "space" | "*" | "pageup" | "pagedown" | "home" | "end" | arrow | ascii | fnkey ; + keycombo = { modifier, "+" }, key ; + keys = keycombo, { " ", keycombo } ; + +@demo demo/index.html +*/ + + + Polymer({ + is: 'iron-a11y-keys', + + behaviors: [ + Polymer.IronA11yKeysBehavior + ], + + properties: { + target: { + type: Object, + observer: '_targetChanged' + }, + + keys: { + type: String, + reflectToAttribute: true, + observer: '_keysChanged' + } + }, + + attached: function() { + if (!this.target) { + this.target = this.parentNode; + } + }, + + _targetChanged: function(target) { + this.keyEventTarget = target; + }, + + _keysChanged: function() { + this.removeOwnKeyBindings(); + this.addOwnKeyBinding(this.keys, '_fireKeysPressed'); + }, + + _fireKeysPressed: function(event) { + this.fire('keys-pressed', event.detail, {}); + } + }); +</script> diff --git a/third_party/polymer/v1_0/components/iron-ajax/.bower.json b/third_party/polymer/v1_0/components/iron-ajax/.bower.json new file mode 100644 index 0000000..b2da472 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/.bower.json @@ -0,0 +1,47 @@ +{ + "name": "iron-ajax", + "version": "1.0.0", + "description": "Makes it easy to make ajax calls and parse the response", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "main": [ + "iron-ajax.html", + "iron-request.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-ajax.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-ajax", + "ignore": [], + "dependencies": { + "promise-polyfill": "polymerlabs/promise-polyfill#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-image": "polymerelements/iron-image#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "97cc0c5e407ccde33f385ffbf9e6b6c706e63977" + }, + "_source": "git://github.com/PolymerElements/iron-ajax.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-ajax" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-ajax/.gitignore b/third_party/polymer/v1_0/components/iron-ajax/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-ajax/README.md b/third_party/polymer/v1_0/components/iron-ajax/README.md new file mode 100644 index 0000000..6d9f223 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/README.md @@ -0,0 +1,23 @@ +iron-ajax +========= + +The `iron-ajax` element exposes network request functionality. + +```html +<iron-ajax + auto + url="http://gdata.youtube.com/feeds/api/videos/" + params='{"alt":"json", "q":"chrome"}' + handle-as="json" + on-response="handleResponse"></iron-ajax> +``` + +With `auto` set to `true`, the element performs a request whenever +its `url`, `params` or `body` properties are changed. Automatically generated +requests will be debounced in the case that multiple attributes are changed +sequentially. + +Note: The `params` attribute must be double quoted JSON. + +You can trigger a request explicitly by calling `generateRequest` on the +element. diff --git a/third_party/polymer/v1_0/components/iron-ajax/bower.json b/third_party/polymer/v1_0/components/iron-ajax/bower.json new file mode 100644 index 0000000..33b3614 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/bower.json @@ -0,0 +1,38 @@ +{ + "name": "iron-ajax", + "version": "1.0.0", + "description": "Makes it easy to make ajax calls and parse the response", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "main": [ + "iron-ajax.html", + "iron-request.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-ajax.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-ajax", + "ignore": [], + "dependencies": { + "promise-polyfill": "polymerlabs/promise-polyfill#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-image": "polymerelements/iron-image#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-ajax/index.html b/third_party/polymer/v1_0/components/iron-ajax/index.html new file mode 100644 index 0000000..0341b16 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-ajax</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-ajax/iron-ajax.html b/third_party/polymer/v1_0/components/iron-ajax/iron-ajax.html new file mode 100644 index 0000000..47d202b --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/iron-ajax.html @@ -0,0 +1,398 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-request.html"> + +<!-- +The `iron-ajax` element exposes network request functionality. + + <iron-ajax + auto + url="http://gdata.youtube.com/feeds/api/videos/" + params='{"alt":"json", "q":"chrome"}' + handle-as="json" + on-response="handleResponse" + debounce-duration="300"></iron-ajax> + +With `auto` set to `true`, the element performs a request whenever +its `url`, `params` or `body` properties are changed. Automatically generated +requests will be debounced in the case that multiple attributes are changed +sequentially. + +Note: The `params` attribute must be double quoted JSON. + +You can trigger a request explicitly by calling `generateRequest` on the +element. +--> + +<script> + + Polymer({ + + is: 'iron-ajax', + + /** + * Fired when a request is sent. + * + * @event request + */ + + /** + * Fired when a response is received. + * + * @event response + */ + + /** + * Fired when an error is received. + * + * @event error + */ + + properties: { + /** + * The URL target of the request. + */ + url: { + type: String, + value: '' + }, + + /** + * An object that contains query parameters to be appended to the + * specified `url` when generating a request. + */ + params: { + type: Object, + value: function() { + return {}; + } + }, + + /** + * The HTTP method to use such as 'GET', 'POST', 'PUT', or 'DELETE'. + * Default is 'GET'. + */ + method: { + type: String, + value: 'GET' + }, + + /** + * HTTP request headers to send. + * + * Example: + * + * <iron-ajax + * auto + * url="http://somesite.com" + * headers='{"X-Requested-With": "XMLHttpRequest"}' + * handle-as="json" + * last-response-changed="{{handleResponse}}"></iron-ajax> + */ + headers: { + type: Object, + value: function() { + return {}; + } + }, + + /** + * Content type to use when sending data. If the contenttype is set + * and a `Content-Type` header is specified in the `headers` attribute, + * the `headers` attribute value will take precedence. + */ + contentType: { + type: String, + value: 'application/x-www-form-urlencoded' + }, + + /** + * Optional raw body content to send when method === "POST". + * + * Example: + * + * <iron-ajax method="POST" auto url="http://somesite.com" + * body='{"foo":1, "bar":2}'> + * </iron-ajax> + */ + body: { + type: String, + value: '' + }, + + /** + * Toggle whether XHR is synchronous or asynchronous. Don't change this + * to true unless You Know What You Are Doing™. + */ + sync: { + type: Boolean, + value: false + }, + + /** + * Specifies what data to store in the `response` property, and + * to deliver as `event.response` in `response` events. + * + * One of: + * + * `text`: uses `XHR.responseText`. + * + * `xml`: uses `XHR.responseXML`. + * + * `json`: uses `XHR.responseText` parsed as JSON. + * + * `arraybuffer`: uses `XHR.response`. + * + * `blob`: uses `XHR.response`. + * + * `document`: uses `XHR.response`. + */ + handleAs: { + type: String, + value: 'json' + }, + + /** + * Set the withCredentials flag on the request. + */ + withCredentials: { + type: Boolean, + value: false + }, + + /** + * If true, automatically performs an Ajax request when either `url` or + * `params` changes. + */ + auto: { + type: Boolean, + value: false + }, + + /** + * If true, error messages will automatically be logged to the console. + */ + verbose: { + type: Boolean, + value: false + }, + + /** + * Will be set to true if there is at least one in-flight request + * associated with this iron-ajax element. + */ + loading: { + type: Boolean, + notify: true, + readOnly: true + }, + + /** + * Will be set to the most recent request made by this iron-ajax element. + */ + lastRequest: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * Will be set to the most recent response received by a request + * that originated from this iron-ajax element. The type of the response + * is determined by the value of `handleas` at the time that the request + * was generated. + */ + lastResponse: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * Will be set to the most recent error that resulted from a request + * that originated from this iron-ajax element. + */ + lastError: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * An Array of all in-flight requests originating from this iron-ajax + * element. + */ + activeRequests: { + type: Array, + notify: true, + readOnly: true, + value: function() { + this._setActiveRequests([]); + } + }, + + /** + * Length of time in milliseconds to debounce multiple requests. + */ + debounceDuration: { + type: Number, + value: 0, + notify: true + }, + + _boundHandleResponse: { + type: Function, + value: function() { + return this.handleResponse.bind(this); + } + }, + + _boundDiscardRequest: { + type: Function, + value: function() { + return this.discardRequest.bind(this); + } + } + }, + + observers: [ + 'requestOptionsChanged(url, method, params, headers,' + + 'contentType, body, sync, handleAs, withCredentials, auto)' + ], + + get queryString () { + var queryParts = []; + var param; + var value; + + for (param in this.params) { + value = this.params[param]; + param = window.encodeURIComponent(param); + + if (value !== null) { + param += '=' + window.encodeURIComponent(value); + } + + queryParts.push(param); + } + + return queryParts.join('&'); + }, + + get requestUrl() { + var queryString = this.queryString; + + if (queryString) { + return this.url + '?' + queryString; + } + + return this.url; + }, + + get requestHeaders() { + var headers = { + 'content-type': this.contentType + }; + var header; + + if (this.headers instanceof Object) { + for (header in this.headers) { + headers[header] = this.headers[header].toString(); + } + } + + return headers; + }, + + toRequestOptions: function() { + return { + url: this.requestUrl, + method: this.method, + headers: this.requestHeaders, + body: this.body, + async: !this.sync, + handleAs: this.handleAs, + withCredentials: this.withCredentials + }; + }, + + requestOptionsChanged: function() { + this.debounce('generate-request', function() { + if (!this.url && this.url !== '') { + return; + } + + if (this.auto) { + this.generateRequest(); + } + }, this.debounceDuration); + }, + + /** + * Performs an AJAX request to the specified URL. + * + * @method generateRequest + */ + generateRequest: function() { + var request = document.createElement('iron-request'); + var requestOptions = this.toRequestOptions(); + + this.activeRequests.push(request); + + request.completes.then( + this._boundHandleResponse + ).catch( + this.handleError.bind(this, request) + ).then( + this._boundDiscardRequest + ); + + request.send(requestOptions); + + this._setLastRequest(request); + + this.fire('request', { + request: request, + options: requestOptions + }); + + return request; + }, + + handleResponse: function(request) { + this._setLastResponse(request.response); + this.fire('response', request); + }, + + handleError: function(request, error) { + if (this.verbose) { + console.error(error); + } + + this._setLastError({ + request: request, + error: error + }); + this.fire('error', { + request: request, + error: error + }); + }, + + discardRequest: function(request) { + var requestIndex = this.activeRequests.indexOf(request); + + if (requestIndex > 0) { + this.activeRequests.splice(requestIndex, 1); + } + } + }); +</script> diff --git a/third_party/polymer/v1_0/components/iron-ajax/iron-request.html b/third_party/polymer/v1_0/components/iron-ajax/iron-request.html new file mode 100644 index 0000000..d1737ca --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-ajax/iron-request.html @@ -0,0 +1,267 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../promise-polyfill/promise-polyfill-lite.html"> + +<!-- +@group Iron Elements + +iron-request can be used to perform XMLHttpRequests. + + <iron-request id="xhr"></iron-request> + ... + this.$.xhr.send({url: url, params: params}); + +@element iron-request +--> + +<script> + Polymer({ + is: 'iron-request', + + properties: { + + /** + * A reference to the XMLHttpRequest instance used to generate the + * network request. + * + * @attribute xhr + * @type XMLHttpRequest + * @default `new XMLHttpRequest` + */ + xhr: { + type: Object, + notify: true, + readOnly: true, + value: function() { + return new XMLHttpRequest(); + } + }, + + /** + * A reference to the parsed response body, if the `xhr` has completely + * resolved. + * + * @attribute response + * @type Object + * @default null + */ + response: { + type: Object, + notify: true, + readOnly: true, + value: function() { + return null; + } + }, + + /** + * A promise that resolves when the `xhr` response comes back, or rejects + * if there is an error before the `xhr` completes. + * + * @attribute completes + * @type Promise + * @default `new Promise` + */ + completes: { + type: Object, + readOnly: true, + notify: true, + value: function() { + return new Promise(function (resolve, reject) { + this.resolveCompletes = resolve; + this.rejectCompletes = reject; + }.bind(this)); + } + }, + + /** + * An object that contains progress information emitted by the XHR if + * available. + * + * @attribute progress + * @type Object + * @default {} + */ + progress: { + type: Object, + notify: true, + readOnly: true, + value: function() { + return {}; + } + }, + + /** + * Aborted will be true if an abort of the request is attempted. + * + * @attribute aborted + * @type boolean + * @default false + */ + aborted: { + type: Boolean, + notify: true, + readOnly: true, + value: false, + } + }, + + /** + * Succeeded is true if the request succeeded. The request succeeded if the + * status code is greater-than-or-equal-to 200, and less-than 300. Also, + * the status code 0 is accepted as a success even though the outcome may + * be ambiguous. + * + * @return boolean + */ + get succeeded() { + var status = this.xhr.status || 0; + + // Note: if we are using the file:// protocol, the status code will be 0 + // for all outcomes (successful or otherwise). + return status === 0 || + (status >= 200 && status < 300); + }, + + /** + * Sends an HTTP request to the server and returns the XHR object. + * + * @method request + * @param {{ + * url: string, + * method: (string|undefined), + * async: (boolean|undefined), + * body: (ArrayBuffer|ArrayBufferView|Blob|Document|FormData|null|string|undefined), + * headers: (Object|undefined), + * handleAs: (string|undefined), + * withCredentials: (boolean|undefined)}} options - + * url The url to which the request is sent. + * method The HTTP method to use, default is GET. + * async By default, all requests are sent asynchronously. To send synchronous requests, + * set to true. + * body The content for the request body for POST method. + * headers HTTP request headers. + * handleAs The response type. Default is 'text'. + * withCredentials Whether or not to send credentials on the request. Default is false. + * @return Promise + */ + send: function (options) { + var xhr = this.xhr; + + if (xhr.readyState > 0) { + return; + } + + xhr.addEventListener('readystatechange', function () { + if (xhr.readyState === 4 && !this.aborted) { + + if (!this.succeeded) { + this.rejectCompletes(new Error('The request failed with status code: ' + this.xhr.status)); + return; + } + + this._setResponse(this.parseResponse()); + this.resolveCompletes(this); + } + }.bind(this)); + + xhr.addEventListener('progress', function (progress) { + this._setProgress({ + lengthComputable: progress.lengthComputable, + loaded: progress.loaded, + total: progress.total + }); + }.bind(this)) + + xhr.addEventListener('error', function (error) { + this.rejectCompletes(error); + }.bind(this)); + + xhr.addEventListener('abort', function () { + this.rejectCompletes(new Error('Request aborted.')); + }.bind(this)); + + xhr.open( + options.method || 'GET', + options.url, + options.async !== false + ); + + if (options.headers) { + Object.keys(options.headers).forEach(function (requestHeader) { + xhr.setRequestHeader( + requestHeader, + options.headers[requestHeader] + ); + }, this); + } + + // In IE, `xhr.responseType` is an empty string when the response + // returns. Hence, caching it as `xhr._responseType`. + xhr.responseType = xhr._responseType = (options.handleAs || 'text'); + xhr.withCredentials = !!options.withCredentials; + + xhr.send(options.body); + + return this.completes; + }, + + parseResponse: function () { + var xhr = this.xhr; + var responseType = this.xhr.responseType || + this.xhr._responseType; + // If we don't have a natural `xhr.responseType`, we prefer parsing + // `xhr.responseText` over returning `xhr.response`.. + var preferResponseText = !this.xhr.responseType; + + try { + switch (responseType) { + case 'json': + // If xhr.response is undefined, responseType `json` may + // not be supported. + if (preferResponseText || xhr.response === undefined) { + // If accessing `xhr.responseText` throws, responseType `json` + // is supported and the result is rightly `undefined`. + try { + xhr.responseText; + } catch (e) { + return xhr.response; + } + + // Otherwise, attempt to parse `xhr.responseText` as JSON. + if (xhr.responseText) { + return JSON.parse(xhr.responseText); + } + } + + return xhr.response; + case 'xml': + return xhr.responseXML; + case 'blob': + case 'document': + case 'arraybuffer': + return xhr.response; + case 'text': + default: + return xhr.responseText; + } + } catch (e) { + this.rejectCompletes(new Error('Could not parse response. ' + e.message)); + } + }, + + abort: function () { + this._setAborted(true); + this.xhr.abort(); + } + }); +</script> + diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/.bower.json b/third_party/polymer/v1_0/components/iron-autogrow-textarea/.bower.json new file mode 100644 index 0000000..dcec326 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "iron-autogrow-textarea", + "version": "1.0.0", + "description": "A textarea element that automatically grows with input", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input", + "textarea" + ], + "main": [ + "iron-autogrow-textarea.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-autogrow-textarea.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-autogrow-textarea", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "ae96e84193694882ff4112566bf365e495b6263f" + }, + "_source": "git://github.com/PolymerElements/iron-autogrow-textarea.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-autogrow-textarea" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/.gitignore b/third_party/polymer/v1_0/components/iron-autogrow-textarea/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/README.md b/third_party/polymer/v1_0/components/iron-autogrow-textarea/README.md new file mode 100644 index 0000000..7242abc --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/README.md @@ -0,0 +1,24 @@ +# iron-autogrow-textarea + +`iron-autogrow-textarea` is an element containing a textarea that grows in height as more +lines of input are entered. Unless an explicit height or the `maxRows` property is set, it will +never scroll. + +Example: + + <iron-autogrow-textarea id="a1"> + <textarea id="t1"></textarea> + </iron-autogrow-textarea> + +Because the `textarea`'s `value` property is not observable, you should use +this element's `bind-value` instead for imperative updates. Alternatively, if +you do set the `textarea`'s `value` imperatively, you must also call `update` +to notify this element the value has changed. + + Example: + /* preferred, using the example HTML above*/ + a1.bindValue = 'some\ntext'; + + /* alternatively, */ + t1.value = 'some\ntext'; + a1.update(); diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/bower.json b/third_party/polymer/v1_0/components/iron-autogrow-textarea/bower.json new file mode 100644 index 0000000..39d4fd2 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-autogrow-textarea", + "version": "1.0.0", + "description": "A textarea element that automatically grows with input", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input", + "textarea" + ], + "main": [ + "iron-autogrow-textarea.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-autogrow-textarea.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-autogrow-textarea", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/hero.svg b/third_party/polymer/v1_0/components/iron-autogrow-textarea/hero.svg new file mode 100644 index 0000000..19ec70a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/hero.svg @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M140,47c-3,0-4.7-2.4-6.2-4.4c-1.3-1.9-2.4-3.6-4.7-3.6c-2.3,0-3.4,1.7-4.7,3.6c-1.5,2.1-3.1,4.4-6.4,4.4 + c-3.3,0-4.9-2.4-6.4-4.4c-1.3-1.9-2.5-3.6-4.8-3.6c-2.3,0-3.4,1.7-4.8,3.6c-1.5,2.1-3.1,4.4-6.4,4.4s-5.2-2.4-6.7-4.4 + c-1.3-1.9-2-3.6-5-3.6v-2c4,0,5.2,2.4,6.7,4.4c1.3,1.9,2.6,3.6,4.9,3.6c2.3,0,3.5-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.5-4.4 + s5,2.4,6.4,4.4c1.3,1.9,2.5,3.6,4.8,3.6c2.3,0,3.4-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.4-4.4c3.3,0,4.7,2.4,6.2,4.4 + c1.3,1.9,2.5,3.6,4.5,3.6V47z"/> + <path d="M140,65c-3,0-4.7-2.4-6.2-4.4c-1.3-1.9-2.4-3.6-4.7-3.6c-2.3,0-3.4,1.7-4.7,3.6c-1.5,2.1-3.1,4.4-6.4,4.4 + c-3.3,0-4.9-2.4-6.4-4.4c-1.3-1.9-2.5-3.6-4.8-3.6c-2.3,0-3.4,1.7-4.8,3.6c-1.5,2.1-3.1,4.4-6.4,4.4s-5.2-2.4-6.7-4.4 + c-1.3-1.9-2-3.6-5-3.6v-2c4,0,5.2,2.4,6.7,4.4c1.3,1.9,2.6,3.6,4.9,3.6c2.3,0,3.5-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.5-4.4 + s5,2.4,6.4,4.4c1.3,1.9,2.5,3.6,4.8,3.6c2.3,0,3.4-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.4-4.4c3.3,0,4.7,2.4,6.2,4.4 + c1.3,1.9,2.5,3.6,4.5,3.6V65z"/> + <path d="M140,83c-3,0-4.7-2.4-6.2-4.4c-1.3-1.9-2.4-3.6-4.7-3.6c-2.3,0-3.4,1.7-4.7,3.6c-1.5,2.1-3.1,4.4-6.4,4.4 + c-3.3,0-4.9-2.4-6.4-4.4c-1.3-1.9-2.5-3.6-4.8-3.6c-2.3,0-3.4,1.7-4.8,3.6c-1.5,2.1-3.1,4.4-6.4,4.4s-5.2-2.4-6.7-4.4 + c-1.3-1.9-2-3.6-5-3.6v-2c4,0,5.2,2.4,6.7,4.4c1.3,1.9,2.6,3.6,4.9,3.6c2.3,0,3.5-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.5-4.4 + s5,2.4,6.4,4.4c1.3,1.9,2.5,3.6,4.8,3.6c2.3,0,3.4-1.7,4.8-3.6c1.5-2.1,3.1-4.4,6.4-4.4c3.3,0,4.7,2.4,6.2,4.4 + c1.3,1.9,2.5,3.6,4.5,3.6V83z"/> + <g id="ic_x5F_add_x0D_"> + </g> + <path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/index.html b/third_party/polymer/v1_0/components/iron-autogrow-textarea/index.html new file mode 100644 index 0000000..3be2964 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-autogrow-textarea</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-autogrow-textarea/iron-autogrow-textarea.html b/third_party/polymer/v1_0/components/iron-autogrow-textarea/iron-autogrow-textarea.html new file mode 100644 index 0000000..6a21146 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-autogrow-textarea/iron-autogrow-textarea.html @@ -0,0 +1,210 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../iron-validatable-behavior/iron-validatable-behavior.html"> + +<!-- +`iron-autogrow-textarea` is an element containing a textarea that grows in height as more +lines of input are entered. Unless an explicit height or the `maxRows` property is set, it will +never scroll. + +Example: + + <iron-autogrow-textarea id="a1"> + <textarea id="t1"></textarea> + </iron-autogrow-textarea> + +Because the `textarea`'s `value` property is not observable, you should use +this element's `bind-value` instead for imperative updates. + +@group Iron Elements +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="iron-autogrow-textarea"> + + <style> + :host { + display: inline-block; + position: relative; + width: 400px; + border: 1px solid; + padding: 2px; + -moz-appearance: textarea; + -webkit-appearance: textarea; + } + + .mirror-text { + visibility: hidden; + word-wrap: break-word; + } + + textarea { + position: relative; + outline: none; + border: none; + resize: none; + background: inherit; + /* see comments in template */ + width: 100%; + height: 100%; + font-size: inherit; + font-family: inherit; + } + + ::content textarea:invalid { + box-shadow: none; + } + + </style> + <template> + <!-- the mirror sizes the input/textarea so it grows with typing --> + <div id="mirror" class="mirror-text" aria-hidden="true"> </div> + + <!-- size the input/textarea with a div, because the textarea has intrinsic size in ff --> + <div class="textarea-container fit"> + <textarea id="textarea" required$="[[required]]" rows$="[[rows]]" maxlength$="[[maxlength]]"></textarea> + </div> + </template> + +<script> + + Polymer({ + + is: 'iron-autogrow-textarea', + + behaviors: [ + Polymer.IronValidatableBehavior + ], + + properties: { + + /** + * Use this property instead of `value` for two-way data binding. + */ + bindValue: { + observer: '_bindValueChanged', + type: String + }, + + /** + * The initial number of rows. + * + * @attribute rows + * @type number + * @default 1 + */ + rows: { + type: Number, + value: 1, + observer: '_updateCached' + }, + + /** + * The maximum number of rows this element can grow to until it + * scrolls. 0 means no maximum. + * + * @attribute maxRows + * @type number + * @default 0 + */ + maxRows: { + type: Number, + value: 0, + observer: '_updateCached' + }, + + /** + * Set to true to mark the textarea as required. + */ + required: { + type: Boolean + }, + + /** + * The maximum length of the input value. + */ + maxlength: { + type: Number + } + + }, + + listeners: { + 'input': '_onInput' + }, + + /** + * Returns the underlying textarea. + */ + get textarea() { + return this.$.textarea; + }, + + _update: function() { + this.$.mirror.innerHTML = this._valueForMirror(); + + var textarea = this.textarea; + // If the value of the textarea was updated imperatively, then we + // need to manually update bindValue as well. + if (textarea && this.bindValue != textarea.value) { + this.bindValue = textarea.value; + } + }, + + _bindValueChanged: function() { + var textarea = this.textarea; + if (!textarea) { + return; + } + + textarea.value = this.bindValue; + this._update(); + // manually notify because we don't want to notify until after setting value + this.fire('bind-value-changed', {value: this.bindValue}); + }, + + _onInput: function(event) { + this.bindValue = event.path ? event.path[0].value : event.target.value; + this._update(); + }, + + _constrain: function(tokens) { + var _tokens; + tokens = tokens || ['']; + // Enforce the min and max heights for a multiline input to avoid measurement + if (this.maxRows > 0 && tokens.length > this.maxRows) { + _tokens = tokens.slice(0, this.maxRows); + } else { + _tokens = tokens.slice(0); + } + while (this.rows > 0 && _tokens.length < this.rows) { + _tokens.push(''); + } + return _tokens.join('<br>') + ' '; + }, + + _valueForMirror: function() { + var input = this.textarea; + if (!input) { + return; + } + this.tokens = (input && input.value) ? input.value.replace(/&/gm, '&').replace(/"/gm, '"').replace(/'/gm, ''').replace(/</gm, '<').replace(/>/gm, '>').split('\n') : ['']; + return this._constrain(this.tokens); + }, + + _updateCached: function() { + this.$.mirror.innerHTML = this._constrain(this.tokens); + } + }) +</script> diff --git a/third_party/polymer/v1_0/components/iron-behaviors/.bower.json b/third_party/polymer/v1_0/components/iron-behaviors/.bower.json new file mode 100644 index 0000000..2b621455 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/.bower.json @@ -0,0 +1,35 @@ +{ + "name": "iron-behaviors", + "version": "1.0.1", + "description": "Provides a set of behaviors for the iron elements", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "main": [ + "iron-button-state.html", + "iron-control-state.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-behaviors", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "03284936c45f058a8192752869a57a0a57a2963f" + }, + "_source": "git://github.com/PolymerElements/iron-behaviors.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-behaviors" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-behaviors/.gitignore b/third_party/polymer/v1_0/components/iron-behaviors/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-behaviors/README.md b/third_party/polymer/v1_0/components/iron-behaviors/README.md new file mode 100644 index 0000000..593986e --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/README.md @@ -0,0 +1,4 @@ +iron-behaviors +============== + +This repository collects shared behaviors that are mixed in to other elements. diff --git a/third_party/polymer/v1_0/components/iron-behaviors/bower.json b/third_party/polymer/v1_0/components/iron-behaviors/bower.json new file mode 100644 index 0000000..c3c6a73 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/bower.json @@ -0,0 +1,25 @@ +{ + "name": "iron-behaviors", + "version": "1.0.1", + "description": "Provides a set of behaviors for the iron elements", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "main": [ + "iron-button-state.html", + "iron-control-state.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-behaviors/index.html b/third_party/polymer/v1_0/components/iron-behaviors/index.html new file mode 100644 index 0000000..220deb0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <title>Iron Behaviors</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="iron-button-state.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-behaviors/iron-button-state.html b/third_party/polymer/v1_0/components/iron-behaviors/iron-button-state.html new file mode 100644 index 0000000..bc7249a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/iron-button-state.html @@ -0,0 +1,195 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> +<link rel="import" href="iron-control-state.html"> + +<script> + + /** @polymerBehavior Polymer.IronButtonState */ + Polymer.IronButtonStateImpl = { + + properties: { + + /** + * If true, the user is currently holding down the button. + * + * @attribute pressed + * @type boolean + * @default false + */ + pressed: { + type: Boolean, + readOnly: true, + value: false, + reflectToAttribute: true, + observer: '_pressedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + * + * @attribute toggles + * @type boolean + * @default false + */ + toggles: { + type: Boolean, + value: false, + reflectToAttribute: true + }, + + /** + * If true, the button is a toggle and is currently in the active state. + * + * @attribute active + * @type boolean + * @default false + */ + active: { + type: Boolean, + value: false, + notify: true, + reflectToAttribute: true, + observer: '_activeChanged' + }, + + /** + * True if the element is currently being pressed by a "pointer," which + * is loosely defined as mouse or touch input (but specifically excluding + * keyboard input). + */ + pointerDown: { + type: Boolean, + readOnly: true, + value: false + }, + + /** + * True if the input device that caused the element to receive focus + * was a keyboard. + */ + receivedFocusFromKeyboard: { + type: Boolean, + readOnly: true + } + }, + + listeners: { + down: '_downHandler', + up: '_upHandler', + tap: '_tapHandler' + }, + + observers: [ + '_detectKeyboardFocus(focused)' + ], + + keyBindings: { + 'enter:keydown': '_asyncClick', + 'space:keydown': '_spaceKeyDownHandler', + 'space:keyup': '_spaceKeyUpHandler', + }, + + _tapHandler: function() { + if (this.toggles) { + // a tap is needed to toggle the active state + this._userActivate(!this.active); + } else { + this.active = false; + } + }, + + _detectKeyboardFocus: function(focused) { + this._setReceivedFocusFromKeyboard(!this.pointerDown && focused); + }, + + // to emulate native checkbox, (de-)activations from a user interaction fire + // 'change' events + _userActivate: function(active) { + this.active = active; + this.fire('change'); + }, + + _downHandler: function() { + this._setPointerDown(true); + this._setPressed(true); + this._setReceivedFocusFromKeyboard(false); + }, + + _upHandler: function() { + this._setPointerDown(false); + this._setPressed(false); + }, + + _spaceKeyDownHandler: function(event) { + var keyboardEvent = event.detail.keyboardEvent; + keyboardEvent.preventDefault(); + keyboardEvent.stopImmediatePropagation(); + this._setPressed(true); + }, + + _spaceKeyUpHandler: function() { + if (this.pressed) { + this._asyncClick(); + } + this._setPressed(false); + }, + + // trigger click asynchronously, the asynchrony is useful to allow one + // event handler to unwind before triggering another event + _asyncClick: function() { + this.async(function() { + this.click(); + }, 1); + }, + + // any of these changes are considered a change to button state + + _pressedChanged: function(pressed) { + this._changedButtonState(); + }, + + _activeChanged: function(active) { + if (this.toggles) { + this.setAttribute('aria-pressed', active ? 'true' : 'false'); + } else { + this.removeAttribute('aria-pressed'); + } + this._changedButtonState(); + }, + + _controlStateChanged: function() { + if (this.disabled) { + this._setPressed(false); + } else { + this._changedButtonState(); + } + }, + + // provide hook for follow-on behaviors to react to button-state + + _changedButtonState: function() { + if (this._buttonStateChanged) { + this._buttonStateChanged(); // abstract + } + } + + }; + + /** @polymerBehavior Polymer.IronButtonState */ + Polymer.IronButtonState = [ + Polymer.IronA11yKeysBehavior, + Polymer.IronButtonStateImpl + ]; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-behaviors/iron-control-state.html b/third_party/polymer/v1_0/components/iron-behaviors/iron-control-state.html new file mode 100644 index 0000000..f2efb7c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-behaviors/iron-control-state.html @@ -0,0 +1,102 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + + /** @polymerBehavior */ + + Polymer.IronControlState = { + + properties: { + + /** + * If true, the element currently has focus. + * + * @attribute focused + * @type boolean + * @default false + */ + focused: { + type: Boolean, + value: false, + notify: true, + readOnly: true, + reflectToAttribute: true + }, + + /** + * If true, the user cannot interact with this element. + * + * @attribute disabled + * @type boolean + * @default false + */ + disabled: { + type: Boolean, + value: false, + notify: true, + observer: '_disabledChanged', + reflectToAttribute: true + }, + + _oldTabIndex: { + type: Number + } + }, + + observers: [ + '_changedControlState(focused, disabled)' + ], + + listeners: { + focus: '_focusHandler', + blur: '_blurHandler' + }, + + ready: function() { + // TODO(sjmiles): ensure read-only property is valued so the compound + // observer will fire + if (this.focused === undefined) { + this._setFocused(false); + } + }, + + _focusHandler: function() { + this._setFocused(true); + }, + + _blurHandler: function() { + this._setFocused(false); + }, + + _disabledChanged: function(disabled, old) { + this.setAttribute('aria-disabled', disabled ? 'true' : 'false'); + this.style.pointerEvents = disabled ? 'none' : ''; + if (disabled) { + this._oldTabIndex = this.tabIndex; + this.focused = false; + this.tabIndex = -1; + } else if (this._oldTabIndex !== undefined) { + this.tabIndex = this._oldTabIndex; + } + }, + + _changedControlState: function() { + // _controlStateChanged is abstract, follow-on behaviors may implement it + if (this._controlStateChanged) { + this._controlStateChanged(); + } + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-collapse/.bower.json b/third_party/polymer/v1_0/components/iron-collapse/.bower.json new file mode 100644 index 0000000..67ce4ad --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "iron-collapse", + "version": "1.0.1", + "description": "Provides a collapsable container", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "private": true, + "repository": { + "type": "git", + "url": "https://github.com/PolymerElements/iron-collapse" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-collapse", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "336d40cd1aacc16602cae1b7cf6172c32b5f947d" + }, + "_source": "git://github.com/PolymerElements/iron-collapse.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-collapse" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-collapse/.gitignore b/third_party/polymer/v1_0/components/iron-collapse/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-collapse/README.md b/third_party/polymer/v1_0/components/iron-collapse/README.md new file mode 100644 index 0000000..13a013b --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/README.md @@ -0,0 +1,37 @@ +# iron-collapse + +`iron-collapse` creates a collapsible block of content. By default, the content +will be collapsed. Use `opened` or `toggle()` to show/hide the content. + +```html +<button on-click="{{toggle}}">toggle collapse</button> + +<iron-collapse id="collapse"> + <div>Content goes here...</div> +</iron-collapse> +``` + +```javascript +toggle: function() { + this.$.collapse.toggle(); +} +``` + +`iron-collapse` adjusts the height/width of the collapsible element to show/hide +the content. So avoid putting padding/margin/border on the collapsible directly, +and instead put a div inside and style that. + +```html +<style> + .collapse-content { + padding: 15px; + border: 1px solid #dedede; + } +</style> + +<iron-collapse> + <div class="collapse-content"> + <div>Content goes here...</div> + </div> +</iron-collapse> +``` diff --git a/third_party/polymer/v1_0/components/iron-collapse/bower.json b/third_party/polymer/v1_0/components/iron-collapse/bower.json new file mode 100644 index 0000000..55df067 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-collapse", + "version": "1.0.1", + "description": "Provides a collapsable container", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "private": true, + "repository": { + "type": "git", + "url": "https://github.com/PolymerElements/iron-collapse" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-collapse", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-collapse/hero.svg b/third_party/polymer/v1_0/components/iron-collapse/hero.svg new file mode 100644 index 0000000..ae1a49e --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/hero.svg @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> + <path display="inline" fill="none" d="M167.5,51.7c3.7-0.8,6.9,2.4,6.1,6.1c-0.4,1.9-1.9,3.4-3.8,3.8c-3.7,0.8-6.9-2.4-6.1-6.1 + C164.2,53.6,165.7,52.1,167.5,51.7z"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M151,102H73V52h78V102z M75,100h74V54H75V100z"/> + <path d="M151,38H73V24h78V38z M75,36h74V26H75V36z"/> + <circle cx="171" cy="51" r="4"/> + <path d="M151,72v-2c10.5,0,19-8.5,19-19s-8.5-19-19-19v-2c11.6,0,21,9.4,21,21S162.6,72,151,72z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-collapse/index.html b/third_party/polymer/v1_0/components/iron-collapse/index.html new file mode 100644 index 0000000..b5d2007 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/index.html @@ -0,0 +1,31 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-collapse</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-collapse/iron-collapse.html b/third_party/polymer/v1_0/components/iron-collapse/iron-collapse.html new file mode 100644 index 0000000..3821c28 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-collapse/iron-collapse.html @@ -0,0 +1,196 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-collapse` creates a collapsible block of content. By default, the content +will be collapsed. Use `opened` or `toggle()` to show/hide the content. + + <button on-click="{{toggle}}">toggle collapse</button> + + <iron-collapse id="collapse"> + <div>Content goes here...</div> + </iron-collapse> + + ... + + toggle: function() { + this.$.collapse.toggle(); + } + +`iron-collapse` adjusts the height/width of the collapsible element to show/hide +the content. So avoid putting padding/margin/border on the collapsible directly, +and instead put a div inside and style that. + + <style> + .collapse-content { + padding: 15px; + border: 1px solid #dedede; + } + </style> + + <iron-collapse> + <div class="collapse-content"> + <div>Content goes here...</div> + </div> + </iron-collapse> + +@group Iron Elements +@hero hero.svg +@demo demo/index.html +@element iron-collapse +--> + +<dom-module id="iron-collapse"> + + <style> + + :host { + display: block; + transition-duration: 300ms; + } + + :host(.iron-collapse-closed) { + display: none; + } + + :host(:not(.iron-collapse-opened)) { + overflow: hidden; + } + + </style> + + <template> + + <content></content> + + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'iron-collapse', + + properties: { + + /** + * If true, the orientation is horizontal; otherwise is vertical. + * + * @attribute horizontal + */ + horizontal: { + type: Boolean, + value: false, + observer: '_horizontalChanged' + }, + + /** + * Set opened to true to show the collapse element and to false to hide it. + * + * @attribute opened + */ + opened: { + type: Boolean, + value: false, + notify: true, + observer: '_openedChanged' + } + + }, + + hostAttributes: { + role: 'group', + 'aria-expanded': 'false', + tabindex: 0 + }, + + listeners: { + transitionend: '_transitionEnd' + }, + + ready: function() { + // Avoid transition at the beginning e.g. page loads and enable + // transitions only after the element is rendered and ready. + this._enableTransition = true; + }, + + /** + * Toggle the opened state. + * + * @method toggle + */ + toggle: function() { + this.opened = !this.opened; + }, + + show: function() { + this.toggleClass('iron-collapse-closed', false); + this.updateSize('auto', false); + var s = this._calcSize(); + this.updateSize('0px', false); + // force layout to ensure transition will go + this.offsetHeight; + this.updateSize(s, true); + }, + + hide: function() { + this.toggleClass('iron-collapse-opened', false); + this.updateSize(this._calcSize(), false); + // force layout to ensure transition will go + this.offsetHeight; + this.updateSize('0px', true); + }, + + updateSize: function(size, animated) { + this.enableTransition(animated); + var s = this.style; + var nochange = s[this.dimension] === size; + s[this.dimension] = size; + if (animated && nochange) { + this._transitionEnd(); + } + }, + + enableTransition: function(enabled) { + this.style.transitionDuration = (enabled && this._enableTransition) ? '' : '0s'; + }, + + _horizontalChanged: function() { + this.dimension = this.horizontal ? 'width' : 'height'; + this.style.transitionProperty = this.dimension; + }, + + _openedChanged: function() { + this[this.opened ? 'show' : 'hide'](); + this.setAttribute('aria-expanded', this.opened ? 'true' : 'false'); + + }, + + _transitionEnd: function() { + if (this.opened) { + this.updateSize('auto', false); + } + this.toggleClass('iron-collapse-closed', !this.opened); + this.toggleClass('iron-collapse-opened', this.opened); + this.enableTransition(false); + }, + + _calcSize: function() { + return this.getBoundingClientRect()[this.dimension] + 'px'; + }, + + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-elements/.bower.json b/third_party/polymer/v1_0/components/iron-elements/.bower.json new file mode 100644 index 0000000..98a0928 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-elements/.bower.json @@ -0,0 +1,68 @@ +{ + "name": "iron-elements", + "version": "1.0.0", + "description": "Iron elements are a set of visual and non-visual utility elements. They include elements for working with layout, user input, selection, and scaffolding apps.", + "keywords": [ + "web-components", + "polymer", + "utility", + "user-input", + "selection" + ], + "dependencies": { + "iron-a11y-announcer": "PolymerElements/iron-a11y-announcer#^1.0.0", + "iron-a11y-keys": "PolymerElements/iron-a11y-keys#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "iron-collapse": "PolymerElements/iron-collapse#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-form": "PolymerElements/iron-form#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "iron-iconset": "PolymerElements/iron-iconset#^1.0.0", + "iron-iconset-svg": "PolymerElements/iron-iconset-svg#^1.0.0", + "iron-image": "PolymerElements/iron-image#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-jsonp-library": "PolymerElements/iron-jsonp-library#^1.0.0", + "iron-localstorage": "PolymerElements/iron-localstorage#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "iron-pages": "PolymerElements/iron-pages#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-signals": "PolymerElements/iron-signals#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0" + }, + "homepage": "https://github.com/PolymerElements/iron-elements", + "authors": [ + "The Polymer Authors" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "3afca31d047c2a3bcf3b196f77fcf2018b84f173" + }, + "_source": "git://github.com/PolymerElements/iron-elements.git", + "_target": "~1.0.0", + "_originalSource": "PolymerElements/iron-elements" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-elements/README.md b/third_party/polymer/v1_0/components/iron-elements/README.md new file mode 100644 index 0000000..979217f --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-elements/README.md @@ -0,0 +1,34 @@ +# iron-elements + +Basic building blocks for creating an application. + +## Roadmap + +### Elements in progress + +* `iron-list` - the upgraded version of a virtualized infinite list, previously named `core-list`. ETA: Couple weeks. + +### Elements planned +_Elements we're planning on building soon but haven't started yet_ + +[Currently focused on getting all elements up to speed] + +### Elements not planned, notably +_Elements we're not planning on building as part of this product line, but that one might be wondering about_ + +A number of elements existed as `core` elements that are not in this product line: +* `core-action-icons` - This wasn't really an element, and wasn't particularly heavily used. +* `core-animation` - The animation-related elements that were part of core will be created as part of the `neon` product line. +* `core-docs` - Deprecated: use [`iron-doc-viewer`](https://github.com/polymerelements/iron-doc-viewer). +* `core-drag-drop` - Not currently working on. +* `core-dropdown` and `core-dropdown-menu` - These were confusing UI to have in `core`, so we've moved them to the `paper` element set for now and made them easier to customize. More on the thought process behind this change in the [blog](https://blog.polymer-project.org/announcements/2015/05/14/updated-elements/). +* `core-focusable` - This has been re-implemented using Polymer behaviors - see for example the `paper-radio-button-behavior` in [`paper-behaviors`](https://github.com/PolymerElements/paper-behaviors). +* `core-item` - This had UI opinion, so was re-implemented as [`paper-item`](https://github.com/polymerelements/paper-item). +* `core-layout` - We're working on more stable, consistent layout elements. +* `core-overlay` - This is re-implemented as a behavior, in [`iron-overlay-behavior`](https://github.com/polymerelements/iron-overlay-behavior). +* `core-popup-menu` - This element wasn't particularly of unique value, so we're putting it away for now. +* `core-scroll-header-panel` - This had UI opinion, so it's been moved to [`paper-scroll-header-panel`](https://github.com/polymerelements/paper-scroll-header-panel). +* `core-splitter` - This element was relatively trivial, so we've put it off for now. +* `core-style` - This element is not useful with Polymer's new styling system. Check out the latest docs for more. +* `core-tooltip` - This will become `paper-tooltip`. +* `core-menu` - This had UI opinion, and will become `paper-dropdown-menu`. diff --git a/third_party/polymer/v1_0/components/iron-elements/bower.json b/third_party/polymer/v1_0/components/iron-elements/bower.json new file mode 100644 index 0000000..de10b39 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-elements/bower.json @@ -0,0 +1,59 @@ +{ + "name": "iron-elements", + "version": "1.0.0", + "description": "Iron elements are a set of visual and non-visual utility elements. They include elements for working with layout, user input, selection, and scaffolding apps.", + "keywords": [ + "web-components", + "polymer", + "utility", + "user-input", + "selection" + ], + + "dependencies": { + "iron-a11y-announcer": "PolymerElements/iron-a11y-announcer#^1.0.0", + "iron-a11y-keys": "PolymerElements/iron-a11y-keys#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "iron-collapse": "PolymerElements/iron-collapse#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-form": "PolymerElements/iron-form#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "iron-iconset": "PolymerElements/iron-iconset#^1.0.0", + "iron-iconset-svg": "PolymerElements/iron-iconset-svg#^1.0.0", + "iron-image": "PolymerElements/iron-image#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-jsonp-library": "PolymerElements/iron-jsonp-library#^1.0.0", + "iron-localstorage": "PolymerElements/iron-localstorage#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "iron-pages": "PolymerElements/iron-pages#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-signals": "PolymerElements/iron-signals#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0" + }, + + "homepage": "https://github.com/PolymerElements/iron-elements", + "authors": ["The Polymer Authors"], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ] +} diff --git a/third_party/polymer/v1_0/components/iron-fit-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-fit-behavior/.bower.json new file mode 100644 index 0000000..2ab1f93 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-fit-behavior/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "iron-fit-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Fits an element inside another element", + "private": true, + "main": [ + "iron-fit-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-fit-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-fit-behavior", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "971104a539e356fc9f8d5c640fced7f1af653c15" + }, + "_source": "git://github.com/PolymerElements/iron-fit-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-fit-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-fit-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-fit-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-fit-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-fit-behavior/README.md b/third_party/polymer/v1_0/components/iron-fit-behavior/README.md new file mode 100644 index 0000000..8f4fc76 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-fit-behavior/README.md @@ -0,0 +1,3 @@ +# iron-fit-behavior + +Fits an element in the window, or another element. diff --git a/third_party/polymer/v1_0/components/iron-fit-behavior/bower.json b/third_party/polymer/v1_0/components/iron-fit-behavior/bower.json new file mode 100644 index 0000000..c8f7dc8 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-fit-behavior/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-fit-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Fits an element inside another element", + "private": true, + "main": [ + "iron-fit-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-fit-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-fit-behavior/index.html b/third_party/polymer/v1_0/components/iron-fit-behavior/index.html new file mode 100644 index 0000000..5ffa7d6 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-fit-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-fit-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-fit-behavior/iron-fit-behavior.html b/third_party/polymer/v1_0/components/iron-fit-behavior/iron-fit-behavior.html new file mode 100644 index 0000000..f072dcf --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-fit-behavior/iron-fit-behavior.html @@ -0,0 +1,230 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + +/** +Polymer.IronFitBehavior fits an element in another element using `max-height` and `max-width`, and +optionally centers it in the window or another element. + +The element will only be sized and/or positioned if it has not already been sized and/or positioned +by CSS. + +CSS properties | Action +-----------------------------|------------------------------------------- +`position` set | Element is not centered horizontally or vertically +`top` or `bottom` set | Element is not vertically centered +`left` or `right` set | Element is not horizontally centered +`max-height` or `height` set | Element respects `max-height` or `height` +`max-width` or `width` set | Element respects `max-width` or `width` + +@demo demo/index.html +@polymerBehavior +*/ + + Polymer.IronFitBehavior = { + + properties: { + + /** + * The element that will receive a `max-height`/`width`. By default it is the same as `this`, + * but it can be set to a child element. This is useful, for example, for implementing a + * scrolling region inside the element. + */ + sizingTarget: { + type: Object, + value: function() { + return this; + } + }, + + /** + * The element to fit `this` into. + */ + fitInto: { + type: Object, + value: window + }, + + /** + * Set to true to auto-fit on attach. + */ + autoFitOnAttach: { + type: Boolean, + value: false + }, + + _fitInfo: { + type: Object + } + + }, + + get _fitWidth() { + var fitWidth; + if (this.fitInto === window) { + fitWidth = this.fitInto.innerWidth; + } else { + fitWidth = this.fitInto.getBoundingClientRect().width; + } + return fitWidth; + }, + + get _fitHeight() { + var fitHeight; + if (this.fitInto === window) { + fitHeight = this.fitInto.innerHeight; + } else { + fitHeight = this.fitInto.getBoundingClientRect().height; + } + return fitHeight; + }, + + attached: function() { + if (this.autoFitOnAttach) { + if (window.getComputedStyle(this).display === 'none') { + setTimeout(function() { + this.fit(); + }.bind(this)); + } else { + this.fit(); + } + } + }, + + /** + * Fits and optionally centers the element into the window, or `fitInfo` if specified. + */ + fit: function() { + this._discoverInfo(); + this.constrain(); + this.center(); + }, + + /** + * Memoize information needed to position and size the target element. + */ + _discoverInfo: function() { + if (this._fitInfo) { + return; + } + var target = window.getComputedStyle(this); + var sizer = window.getComputedStyle(this.sizingTarget); + this._fitInfo = { + positionedBy: { + vertically: target.top !== 'auto' ? 'top' : (target.bottom !== 'auto' ? + 'bottom' : null), + horizontally: target.left !== 'auto' ? 'left' : (target.right !== 'auto' ? + 'right' : null), + css: target.position + }, + sizedBy: { + height: sizer.maxHeight !== 'none', + width: sizer.maxWidth !== 'none' + }, + margin: { + top: parseInt(target.marginTop, 10) || 0, + right: parseInt(target.marginRight, 10) || 0, + bottom: parseInt(target.marginBottom, 10) || 0, + left: parseInt(target.marginLeft, 10) || 0 + } + }; + }, + + /** + * Resets the target element's position and size constraints, and clear + * the memoized data. + */ + resetFit: function() { + if (!this._fitInfo || !this._fitInfo.sizedBy.height) { + this.sizingTarget.style.maxHeight = ''; + this.style.top = ''; + } + if (!this._fitInfo || !this._fitInfo.sizedBy.width) { + this.sizingTarget.style.maxWidth = ''; + this.style.left = ''; + } + if (this._fitInfo) { + this.style.position = this._fitInfo.positionedBy.css; + } + this._fitInfo = null; + }, + + /** + * Equivalent to calling `resetFit()` and `fit()`. Useful to call this after the element, + * the window, or the `fitInfo` element has been resized. + */ + refit: function() { + this.resetFit(); + this.fit(); + }, + + /** + * Constrains the size of the element to the window or `fitInfo` by setting `max-height` + * and/or `max-width`. + */ + constrain: function() { + var info = this._fitInfo; + // position at (0px, 0px) if not already positioned, so we can measure the natural size. + if (!this._fitInfo.positionedBy.vertically) { + this.style.top = '0px'; + } + if (!this._fitInfo.positionedBy.horizontally) { + this.style.left = '0px'; + } + // need border-box for margin/padding + this.sizingTarget.style.boxSizing = 'border-box'; + // constrain the width and height if not already set + var rect = this.getBoundingClientRect(); + if (!info.sizedBy.height) { + this._sizeDimension(rect, info.positionedBy.vertically, 'top', 'bottom', 'Height'); + } + if (!info.sizedBy.width) { + this._sizeDimension(rect, info.positionedBy.horizontally, 'left', 'right', 'Width'); + } + }, + + _sizeDimension: function(rect, positionedBy, start, end, extent) { + var info = this._fitInfo; + var max = extent === 'Width' ? this._fitWidth : this._fitHeight; + var flip = (positionedBy === end); + var offset = flip ? max - rect[end] : rect[start]; + var margin = info.margin[flip ? start : end]; + var offsetExtent = 'offset' + extent; + var sizingOffset = this[offsetExtent] - this.sizingTarget[offsetExtent]; + this.sizingTarget.style['max' + extent] = (max - margin - offset - sizingOffset) + 'px'; + }, + + /** + * Centers horizontally and vertically if not already positioned. This also sets + * `position:fixed`. + */ + center: function() { + if (!this._fitInfo.positionedBy.vertically || !this._fitInfo.positionedBy.horizontally) { + // need position:fixed to center + this.style.position = 'fixed'; + } + if (!this._fitInfo.positionedBy.vertically) { + var top = (this._fitHeight - this.offsetHeight) / 2; + top -= this._fitInfo.margin.top; + this.style.top = top + 'px'; + } + if (!this._fitInfo.positionedBy.horizontally) { + var left = (this._fitWidth - this.offsetWidth) / 2; + left -= this._fitInfo.margin.left; + this.style.left = left + 'px'; + } + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-flex-layout/.bower.json b/third_party/polymer/v1_0/components/iron-flex-layout/.bower.json new file mode 100644 index 0000000..dff0707 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-flex-layout/.bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-flex-layout", + "version": "1.0.1", + "description": "Provide flexbox-based layouts", + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-flex-layout", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "8828cc6ad1bb70d6a99aa1ecabc070b30256da06" + }, + "_source": "git://github.com/PolymerElements/iron-flex-layout.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-flex-layout" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-flex-layout/README.md b/third_party/polymer/v1_0/components/iron-flex-layout/README.md new file mode 100644 index 0000000..895ed0f --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-flex-layout/README.md @@ -0,0 +1,4 @@ +iron-flex-layout +================ + +Layout styles for the iron elements. diff --git a/third_party/polymer/v1_0/components/iron-flex-layout/bower.json b/third_party/polymer/v1_0/components/iron-flex-layout/bower.json new file mode 100644 index 0000000..46dcdb8 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-flex-layout/bower.json @@ -0,0 +1,21 @@ +{ + "name": "iron-flex-layout", + "version": "1.0.1", + "description": "Provide flexbox-based layouts", + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-flex-layout/classes/iron-flex-layout.html b/third_party/polymer/v1_0/components/iron-flex-layout/classes/iron-flex-layout.html new file mode 100644 index 0000000..283c2a8 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-flex-layout/classes/iron-flex-layout.html @@ -0,0 +1,307 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="iron-shadow-flex-layout.html"> + +<style> + + /******************************* + Flex Layout + *******************************/ + + .layout.horizontal, + .layout.horizontal-reverse, + .layout.vertical, + .layout.vertical-reverse { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + } + + .layout.inline { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + } + + .layout.horizontal { + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + } + + .layout.horizontal-reverse { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + } + + .layout.vertical { + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + } + + .layout.vertical-reverse { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + } + + .layout.wrap { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + } + + .layout.wrap-reverse { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + } + + .flex-auto { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + } + + .flex-none { + -ms-flex: none; + -webkit-flex: none; + flex: none; + } + + .flex, + .flex-1 { + -ms-flex: 1; + -webkit-flex: 1; + flex: 1; + } + + .flex-2 { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + } + + .flex-3 { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + } + + .flex-4 { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + } + + .flex-5 { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + } + + .flex-6 { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + } + + .flex-7 { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + } + + .flex-8 { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + } + + .flex-9 { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + } + + .flex-10 { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + } + + .flex-11 { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + } + + .flex-12 { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + } + + /* alignment in cross axis */ + + .layout.start { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + } + + .layout.center, + .layout.center-center { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + } + + .layout.end { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + } + + /* alignment in main axis */ + + .layout.start-justified { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + } + + .layout.center-justified, + .layout.center-center { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + } + + .layout.end-justified { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + } + + .layout.around-justified { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + } + + .layout.justified { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + } + + /* self alignment */ + + .self-start { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + } + + .self-center { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + } + + .self-end { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + } + + .self-stretch { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + } + + /******************************* + Other Layout + *******************************/ + + .block { + display: block; + } + + /* IE 10 support for HTML5 hidden attr */ + [hidden] { + display: none !important; + } + + .invisible { + visibility: hidden !important; + } + + .relative { + position: relative; + } + + .fit { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + body.fullbleed { + margin: 0; + height: 100vh; + } + + .scroll { + -webkit-overflow-scrolling: touch; + overflow: auto; + } + + /* fixed position */ + + .fixed-bottom, + .fixed-left, + .fixed-right, + .fixed-top { + position: fixed; + } + + .fixed-top { + top: 0; + left: 0; + right: 0; + } + + .fixed-right { + top: 0; + right: 0; + bottom: 0; + } + + .fixed-bottom { + right: 0; + bottom: 0; + left: 0; + } + + .fixed-left { + top: 0; + bottom: 0; + left: 0; + } + +</style> diff --git a/third_party/polymer/v1_0/components/iron-flex-layout/classes/iron-shadow-flex-layout.html b/third_party/polymer/v1_0/components/iron-flex-layout/classes/iron-shadow-flex-layout.html new file mode 100644 index 0000000..c42067a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-flex-layout/classes/iron-shadow-flex-layout.html @@ -0,0 +1,302 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<style> + + /******************************* + Flex Layout + *******************************/ + + html /deep/ .layout.horizontal, + html /deep/ .layout.horizontal-reverse, + html /deep/ .layout.vertical, + html /deep/ .layout.vertical-reverse { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + } + + html /deep/ .layout.inline { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + } + + html /deep/ .layout.horizontal { + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + } + + html /deep/ .layout.horizontal-reverse { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + } + + html /deep/ .layout.vertical { + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + } + + html /deep/ .layout.vertical-reverse { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + } + + html /deep/ .layout.wrap { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + } + + html /deep/ .layout.wrap-reverse { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + } + + html /deep/ .flex-auto { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + } + + html /deep/ .flex-none { + -ms-flex: none; + -webkit-flex: none; + flex: none; + } + + html /deep/ .flex, + html /deep/ .flex-1 { + -ms-flex: 1; + -webkit-flex: 1; + flex: 1; + } + + html /deep/ .flex-2 { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + } + + html /deep/ .flex-3 { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + } + + html /deep/ .flex-4 { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + } + + html /deep/ .flex-5 { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + } + + html /deep/ .flex-6 { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + } + + html /deep/ .flex-7 { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + } + + html /deep/ .flex-8 { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + } + + html /deep/ .flex-9 { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + } + + html /deep/ .flex-10 { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + } + + html /deep/ .flex-11 { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + } + + html /deep/ .flex-12 { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + } + + /* alignment in cross axis */ + + html /deep/ .layout.start { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + } + + html /deep/ .layout.center, + html /deep/ .layout.center-center { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + } + + html /deep/ .layout.end { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + } + + /* alignment in main axis */ + + html /deep/ .layout.start-justified { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + } + + html /deep/ .layout.center-justified, + html /deep/ .layout.center-center { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + } + + html /deep/ .layout.end-justified { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + } + + html /deep/ .layout.around-justified { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + } + + html /deep/ .layout.justified { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + } + + /* self alignment */ + + html /deep/ .self-start { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + } + + html /deep/ .self-center { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + } + + html /deep/ .self-end { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + } + + html /deep/ .self-stretch { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + } + + /******************************* + Other Layout + *******************************/ + + html /deep/ .block { + display: block; + } + + /* IE 10 support for HTML5 hidden attr */ + html /deep/ [hidden] { + display: none !important; + } + + html /deep/ .invisible { + visibility: hidden !important; + } + + html /deep/ .relative { + position: relative; + } + + html /deep/ .fit { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + body.fullbleed { + margin: 0; + height: 100vh; + } + + html /deep/ .scroll { + -webkit-overflow-scrolling: touch; + overflow: auto; + } + + .fixed-bottom, + .fixed-left, + .fixed-right, + .fixed-top { + position: fixed; + } + + html /deep/ .fixed-top { + top: 0; + left: 0; + right: 0; + } + + html /deep/ .fixed-right { + top: 0; + right: 0; + botttom: 0; + } + + html /deep/ .fixed-bottom { + right: 0; + bottom: 0; + left: 0; + } + + html /deep/ .fixed-left { + top: 0; + botttom: 0; + left: 0; + } + +</style> diff --git a/third_party/polymer/v1_0/components/iron-flex-layout/iron-flex-layout.html b/third_party/polymer/v1_0/components/iron-flex-layout/iron-flex-layout.html new file mode 100644 index 0000000..ed9cd7b --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-flex-layout/iron-flex-layout.html @@ -0,0 +1,313 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + --layout: { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + }; + + --layout-inline: { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + }; + + --layout-horizontal: { + /* @apply(--layout); */ + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + }; + + --layout-horizontal-reverse: { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + }; + + --layout-vertical: { + /* @apply(--layout); */ + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + }; + + --layout-vertical-reverse: { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + }; + + --layout-wrap: { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + }; + + --layout-wrap-reverse: { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + }; + + --layout-flex-auto: { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + }; + + --layout-flex-none: { + -ms-flex: none; + -webkit-flex: none; + flex: none; + }; + + --layout-flex: { + -ms-flex: 1 1 0.000000001px; + -webkit-flex: 1; + flex: 1; + -webkit-flex-basis: 0.000000001px; + flex-basis: 0.000000001px; + }; + + --layout-flex-2: { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + }; + + --layout-flex-3: { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + }; + + --layout-flex-4: { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + }; + + --layout-flex-5: { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + }; + + --layout-flex-6: { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + }; + + --layout-flex-7: { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + }; + + --layout-flex-8: { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + }; + + --layout-flex-9: { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + }; + + --layout-flex-10: { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + }; + + --layout-flex-11: { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + }; + + --layout-flex-12: { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + }; + + /* alignment in cross axis */ + + --layout-start: { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + }; + + --layout-center: { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + }; + + --layout-end: { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + }; + + /* alignment in main axis */ + + --layout-start-justified: { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + }; + + --layout-center-justified: { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + }; + + --layout-end-justified: { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + }; + + --layout-around-justified: { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + }; + + --layout-justified: { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + }; + + --layout-center-center: { + /* @apply(--layout-center --layout-center-justified); */ + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + }; + + /* self alignment */ + + --layout-self-start: { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + }; + + --layout-self-center: { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + }; + + --layout-self-end: { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + }; + + --layout-self-stretch: { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + }; + + /******************************* + Other Layout + *******************************/ + + --layout-block: { + display: block; + }; + + --layout-invisible: { + visibility: hidden !important; + }; + + --layout-relative: { + position: relative; + }; + + --layout-fit: { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + }; + + --layout-scroll: { + -webkit-overflow-scrolling: touch; + overflow: auto; + }; + + /* fixed position */ + + --layout-fixed-bottom:, + --layout-fixed-left:, + --layout-fixed-right:, + --layout-fixed-top: { + position: fixed; + }; + + --layout-fixed-top: { + top: 0; + left: 0; + right: 0; + }; + + --layout-fixed-right: { + top: 0; + right: 0; + bottom: 0; + }; + + --layout-fixed-bottom: { + right: 0; + bottom: 0; + left: 0; + }; + + --layout-fixed-left: { + top: 0; + bottom: 0; + left: 0; + }; + + } + +</style> diff --git a/third_party/polymer/v1_0/components/iron-form-element-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-form-element-behavior/.bower.json new file mode 100644 index 0000000..f1369b1 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form-element-behavior/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-form-element-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "main": "iron-form-element-behavior", + "authors": "The Polymer Authors", + "description": "Enables a custom element to be included in an iron-form", + "keywords": [ + "web-components", + "polymer", + "form" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form-element-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-form-element-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "f386143e866c320025589f3d79798c12103377a4" + }, + "_source": "git://github.com/PolymerElements/iron-form-element-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-form-element-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-form-element-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-form-element-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form-element-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-form-element-behavior/README.md b/third_party/polymer/v1_0/components/iron-form-element-behavior/README.md new file mode 100644 index 0000000..555063f --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form-element-behavior/README.md @@ -0,0 +1,2 @@ +# iron-form-element-behavior +Behavior that allows an element to be tracked by an iron-form diff --git a/third_party/polymer/v1_0/components/iron-form-element-behavior/bower.json b/third_party/polymer/v1_0/components/iron-form-element-behavior/bower.json new file mode 100644 index 0000000..1e141f2 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form-element-behavior/bower.json @@ -0,0 +1,27 @@ +{ + "name": "iron-form-element-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "main": "iron-form-element-behavior", + "authors": "The Polymer Authors", + "description": "Enables a custom element to be included in an iron-form", + "keywords": [ + "web-components", + "polymer", + "form" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form-element-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-form-element-behavior/index.html b/third_party/polymer/v1_0/components/iron-form-element-behavior/index.html new file mode 100644 index 0000000..8d748c0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form-element-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-form-element-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-form-element-behavior/iron-form-element-behavior.html b/third_party/polymer/v1_0/components/iron-form-element-behavior/iron-form-element-behavior.html new file mode 100644 index 0000000..d7678a7 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form-element-behavior/iron-form-element-behavior.html @@ -0,0 +1,50 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<!-- +Enables a custom element to be included in an `iron-form`. +--> +<script> + + /** + + @demo demo/index.html + @polymerBehavior + + */ + Polymer.IronFormElementBehavior = { + + properties: { + + /** + * The name of this element. + */ + name: { + type: String + }, + + /** + * The value for this element. + */ + value: { + notify: true, + type: String + }, + }, + + attached: function() { + this.fire('iron-form-element-register'); + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-form/.bower.json b/third_party/polymer/v1_0/components/iron-form/.bower.json new file mode 100644 index 0000000..fad4679 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form/.bower.json @@ -0,0 +1,47 @@ +{ + "name": "iron-form", + "version": "1.0.1", + "description": "Makes it easier to manage forms", + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "authors": [ + "The Polymer Authors" + ], + "main": [ + "iron-form.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-form", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "^0.7.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "b884414ee5d9c9e1484554cd1e644e4cfa562153" + }, + "_source": "git://github.com/PolymerElements/iron-form.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-form" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-form/.gitignore b/third_party/polymer/v1_0/components/iron-form/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-form/README.md b/third_party/polymer/v1_0/components/iron-form/README.md new file mode 100644 index 0000000..424b29f --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form/README.md @@ -0,0 +1,2 @@ +# iron-form +Custom form element diff --git a/third_party/polymer/v1_0/components/iron-form/bower.json b/third_party/polymer/v1_0/components/iron-form/bower.json new file mode 100644 index 0000000..8abd458 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form/bower.json @@ -0,0 +1,43 @@ +{ + "name": "iron-form", + "version": "1.0.1", + "description": "Makes it easier to manage forms", + "keywords": [ + "web-components", + "polymer", + "form" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer" + ], + "main": [ + "iron-form.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-form.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-form", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "^0.7.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-form/index.html b/third_party/polymer/v1_0/components/iron-form/index.html new file mode 100644 index 0000000..acd7140 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-form</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-form/iron-form.html b/third_party/polymer/v1_0/components/iron-form/iron-form.html new file mode 100644 index 0000000..44b77ae --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-form/iron-form.html @@ -0,0 +1,191 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-ajax/iron-ajax.html"> + +<script> +/* +``<iron-form>` is an HTML `<form>` element that can validate and submit any custom +elements that implement `Polymer.IronFormElementBehavior`, as well as any +native HTML elements. + +It supports both `get` and `post` methods, and uses an `iron-ajax` element to +submit the form data to the action URL. + + Example: + + <form is="iron-form" id="form" method="post" action="/form/handler"> + <paper-input name="name" label="name"></paper-input> + <input name="address"> + ... + </form> + +By default, a native `<button>` element will submit this form. However, if you +want to submit it from a custom element's click handler, you need to explicitly +call the form's `submit` method. + + Example: + + <paper-button raised onclick="submitForm()">Submit</paper-button> + + function submitForm() { + document.getElementById('form').submit(); + } + +@demo demo/index.html +*/ + + Polymer({ + + is: 'iron-form', + + extends: 'form', + + /** + * Fired after the form is submitted. + * + * @event iron-form-submit + */ + + /** + * Fired after the form is submitted and a response is received. + * + * @event iron-form-response + */ + + /** + * Fired after the form is submitted and an error is received. + * + * @event iron-form-error + */ + + listeners: { + 'iron-form-element-register': '_registerElement', + 'submit': 'submit' + }, + + ready: function() { + // Object that handles the ajax form submission request. + this._requestBot = document.createElement('iron-ajax'); + this._requestBot.addEventListener('response', this._handleFormResponse.bind(this)); + this._requestBot.addEventListener('error', this._handleFormError.bind(this)); + + // Holds all the custom elements registered with this form. + this._customElements = []; + }, + + /** + * Called to submit the form. + */ + submit: function(event) { + if (!this._validate()) { + return false; + } + + var json = this.serialize(); + + this._requestBot.url = this.action; + this._requestBot.method = this.method; + this._requestBot.params = json; + + if (this.method == 'POST') { + this._requestBot.body = JSON.stringify(json); + } + + this._requestBot.generateRequest(); + this.fire('iron-form-submit', json); + + // Don't perform a page refresh. + if (event) { + event.preventDefault(); + } + + return false; + }, + + /** + * Returns a json object containing name/value pairs for all the registered + * custom components and native elements of the form. If there are elements + * with duplicate names, then their values will get aggregated into an + * array of values. + */ + serialize: function() { + var json = {}; + + function addSerializedElement(el) { + // If the name doesn't exist, add it. Otherwise, serialize it to + // an array, + if (!json[el.name]) { + json[el.name] = el.value; + } else { + if (!Array.isArray(json[el.name])) { + json[el.name] = [json[el.name]]; + } + json[el.name].push(el.value); + } + } + + // Go through all of the registered custom components. + for (var el, i = 0; el = this._customElements[i], i < this._customElements.length; i++) { + if (el.name) { + addSerializedElement(el); + } + } + + // Also go through the form's native elements. + for (var el, i = 0; el = this.elements[i], i < this.elements.length; i++) { + // Checkboxes and radio buttons should only use their value if they're checked. + // Also, custom elements that extend native elements (like an + // `<input is="fancy-input">`) will appear in both lists. Since they + // were already added as a custom element, they don't need + // to be re-added. + if (!el.name || !this._useValue(el) || + (el.hasAttribute('is') && json[el.name])) { + continue; + } + addSerializedElement(el); + } + + return json; + }, + + _handleFormResponse: function (event) { + this.fire('iron-form-response', event.detail.response); + }, + + _handleFormError: function (event) { + this.fire('iron-form-error', event.detail); + }, + + _registerElement: function(e) { + this._customElements.push(e.target); + }, + + _validate: function() { + var valid = true; + for (var el, i = 0; el = this._customElements[i], i < this._customElements.length; i++) { + valid = el.validate() && valid; + } + return valid; + }, + + _useValue: function(el) { + // Checkboxes and radio buttons should only use their value if they're checked. + if (el.type !== 'checkbox' && el.type !== 'radio') { + return true; + } else { + return el.checked; + } + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-icon/.bower.json b/third_party/polymer/v1_0/components/iron-icon/.bower.json new file mode 100644 index 0000000..4f44f2e8 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/.bower.json @@ -0,0 +1,39 @@ +{ + "name": "iron-icon", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An element that supports displaying an icon", + "main": "iron-icon.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-iconset": "polymerelements/iron-iconset#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-icon", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "b6c36359baf7dff86cc4174012296555512ce0c1" + }, + "_source": "git://github.com/PolymerElements/iron-icon.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-icon" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-icon/.gitignore b/third_party/polymer/v1_0/components/iron-icon/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-icon/README.md b/third_party/polymer/v1_0/components/iron-icon/README.md new file mode 100644 index 0000000..27b65c0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/README.md @@ -0,0 +1,56 @@ +iron-icon +========= + +The `iron-icon` element displays an icon. By default an icon renders as a 24px square. + +Example using src: + +```html +<iron-icon src="star.png"></iron-icon> +``` + +Example setting size to 32px x 32px: + +```html +<iron-icon class="big" src="big_star.png"></iron-icon> + +<style> + .big { + height: 32px; + width: 32px; + } +</style> +``` + +The iron elements include several sets of icons. +To use the default set of icons, import `iron-icons.html` and use the `icon` attribute to specify an icon: + +```html +<!-- import default iconset and iron-icon --> +<link rel="import" href="/components/iron-icons/iron-icons.html"> + +<iron-icon icon="menu"></iron-icon> +``` + +To use a different built-in set of icons, import `iron-icons/<iconset>-icons.html`, and +specify the icon as `<iconset>:<icon>`. For example: + +```html +<!-- import communication iconset and iron-icon --> +<link rel="import" href="/components/iron-icons/communication-icons.html"> + +<iron-icon icon="communication:email"></iron-icon> +``` + +You can also create custom icon sets of bitmap or SVG icons. + +Example of using an icon named `cherry` from a custom iconset with the ID `fruit`: + +```html +<iron-icon icon="fruit:cherry"></iron-icon> +``` + +See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for more information about +how to create a custom iconset. + +See [iron-icons](http://www.polymer-project.org/components/iron-icons/demo.html) for the default set of icons. diff --git a/third_party/polymer/v1_0/components/iron-icon/bower.json b/third_party/polymer/v1_0/components/iron-icon/bower.json new file mode 100644 index 0000000..e5ebedb --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/bower.json @@ -0,0 +1,29 @@ +{ + "name": "iron-icon", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An element that supports displaying an icon", + "main": "iron-icon.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-iconset": "polymerelements/iron-iconset#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-icon/hero.svg b/third_party/polymer/v1_0/components/iron-icon/hero.svg new file mode 100644 index 0000000..f0f5853 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/hero.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="112" cy="61" r="8"/> + <path d="M129,78H95V44h34V78z M97,76h30V46H97V76z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-icon/index.html b/third_party/polymer/v1_0/components/iron-icon/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-icon/iron-icon.html b/third_party/polymer/v1_0/components/iron-icon/iron-icon.html new file mode 100644 index 0000000..ea9778a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icon/iron-icon.html @@ -0,0 +1,187 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> + +<!-- + +The `iron-icon` element displays an icon. By default an icon renders as a 24px square. + +Example using src: + + <iron-icon src="star.png"></iron-icon> + +Example setting size to 32px x 32px: + + <iron-icon class="big" src="big_star.png"></iron-icon> + + <style> + .big { + height: 32px; + width: 32px; + } + </style> + +The iron elements include several sets of icons. +To use the default set of icons, import `iron-icons.html` and use the `icon` attribute to specify an icon: + + <!-- import default iconset and iron-icon --> + <link rel="import" href="/components/iron-icons/iron-icons.html"> + + <iron-icon icon="menu"></iron-icon> + +To use a different built-in set of icons, import `iron-icons/<iconset>-icons.html`, and +specify the icon as `<iconset>:<icon>`. For example: + + <!-- import communication iconset and iron-icon --> + <link rel="import" href="/components/iron-icons/communication-icons.html"> + + <iron-icon icon="communication:email"></iron-icon> + +You can also create custom icon sets of bitmap or SVG icons. + +Example of using an icon named `cherry` from a custom iconset with the ID `fruit`: + + <iron-icon icon="fruit:cherry"></iron-icon> + +See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for more information about +how to create a custom iconset. + +See [iron-icons](http://www.polymer-project.org/components/iron-icons/demo.html) for the default set of icons. + + +### Styling + +The following custom properties are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--iron-icon-width` | Width of the icon | `24px` +`--iron-icon-height` | Height of the icon | `24px` + +@group Iron Elements +@element iron-icon +@demo demo/index.html +@hero hero.svg +@homepage polymer.github.io +--> + +<style is="custom-style"> + :root { + --iron-icon-width: 24px; + --iron-icon-height: 24px; + } +</style> + +<dom-module id="iron-icon"> + + <style> + :host { + @apply(--layout-inline); + @apply(--layout-center-center); + position: relative; + + vertical-align: middle; + + fill: currentcolor; + + width: var(--iron-icon-width); + height: var(--iron-icon-height); + } + </style> + + <template> + <iron-meta id="meta" type="iconset"></iron-meta> + </template> + + <script> + + Polymer({ + + is: 'iron-icon', + + properties: { + + /** + * The name of the icon to use. The name should be of the form: + * `iconset_name:icon_name`. + */ + icon: { + type: String, + observer: '_iconChanged' + }, + + /** + * The name of the theme to used, if one is specified by the + * iconset. + */ + theme: { + type: String, + observer: '_updateIcon' + }, + + /** + * If using iron-icon without an iconset, you can set the src to be + * the URL of an individual icon image file. Note that this will take + * precedence over a given icon attribute. + */ + src: { + type: String, + observer: '_srcChanged' + } + }, + + _DEFAULT_ICONSET: 'icons', + + _iconChanged: function(icon) { + var parts = (icon || '').split(':'); + this._iconName = parts.pop(); + this._iconsetName = parts.pop() || this._DEFAULT_ICONSET; + this._updateIcon(); + }, + + _srcChanged: function(src) { + this._updateIcon(); + }, + + _usesIconset: function() { + return this.icon || !this.src; + }, + + _updateIcon: function() { + if (this._usesIconset()) { + if (this._iconsetName) { + this._iconset = this.$.meta.byKey(this._iconsetName); + if (this._iconset) { + this._iconset.applyIcon(this, this._iconName, this.theme); + } else { + this._warn(this._logf('_updateIcon', 'could not find iconset `' + + this._iconsetName + '`, did you import the iconset?')); + } + } + } else { + if (!this._img) { + this._img = document.createElement('img'); + this._img.style.width = '100%'; + this._img.style.height = '100%'; + } + this._img.src = this.src; + Polymer.dom(this.root).appendChild(this._img); + } + } + + }); + + </script> + +</dom-module> + diff --git a/third_party/polymer/v1_0/components/iron-icons/.bower.json b/third_party/polymer/v1_0/components/iron-icons/.bower.json new file mode 100644 index 0000000..f7e7900 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "iron-icons", + "version": "1.0.1", + "description": "A set of icons for use with iron-icon", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "main": "iron-icons.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-icons" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-icons", + "dependencies": { + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "ignore": [ + "util", + "update-icons.sh" + ], + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "a1727591f312fe6cd2e065cab6490232716a646a" + }, + "_source": "git://github.com/PolymerElements/iron-icons.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-icons" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-icons/.gitignore b/third_party/polymer/v1_0/components/iron-icons/.gitignore new file mode 100644 index 0000000..bb1944e --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/.gitignore @@ -0,0 +1,3 @@ +util/node_modules +material-design-icons +bower_components diff --git a/third_party/polymer/v1_0/components/iron-icons/README.md b/third_party/polymer/v1_0/components/iron-icons/README.md new file mode 100644 index 0000000..ed473f7 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/README.md @@ -0,0 +1,8 @@ +iron-icons +========= + +See the [component page](http://polymer-project.org/docs/elements/iron-elements.html#iron-icons) for more information. + +## Building +Running `update-icons.sh` will checkout [material-design-icons](https://github.com/google/material-design-icons), reduce +the fileset to 24px svgs, and compile the iconsets. diff --git a/third_party/polymer/v1_0/components/iron-icons/av-icons.html b/third_party/polymer/v1_0/components/iron-icons/av-icons.html new file mode 100644 index 0000000..0d6ff37 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/av-icons.html @@ -0,0 +1,73 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="av" size="24"> +<svg><defs> +<g id="airplay"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><defs><path id="c" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><clipPath id="d" clip-path="url(#b)"><use xlink:href="#c" overflow="visible"/></clipPath><path d="M6 22h12l-6-6zM21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h4v-2H3V5h18v12h-4v2h4c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z" clip-path="url(#d)"/></g> +<g id="album"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 14.5c-2.49 0-4.5-2.01-4.5-4.5S9.51 7.5 12 7.5s4.5 2.01 4.5 4.5-2.01 4.5-4.5 4.5zm0-5.5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1z"/></g> +<g id="av-timer"><path d="M11 17c0 .55.45 1 1 1s1-.45 1-1-.45-1-1-1-1 .45-1 1zm0-14v4h2V5.08c3.39.49 6 3.39 6 6.92 0 3.87-3.13 7-7 7s-7-3.13-7-7c0-1.68.59-3.22 1.58-4.42L12 13l1.41-1.41-6.8-6.8v.02C4.42 6.45 3 9.05 3 12c0 4.97 4.02 9 9 9 4.97 0 9-4.03 9-9s-4.03-9-9-9h-1zm7 9c0-.55-.45-1-1-1s-1 .45-1 1 .45 1 1 1 1-.45 1-1zM6 12c0 .55.45 1 1 1s1-.45 1-1-.45-1-1-1-1 .45-1 1z"/></g> +<g id="closed-caption"><path d="M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 7H9.5v-.5h-2v3h2V13H11v1c0 .55-.45 1-1 1H7c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1h3c.55 0 1 .45 1 1v1zm7 0h-1.5v-.5h-2v3h2V13H18v1c0 .55-.45 1-1 1h-3c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1h3c.55 0 1 .45 1 1v1z"/></g> +<g id="equalizer"><path d="M10 20h4V4h-4v16zm-6 0h4v-8H4v8zM16 9v11h4V9h-4z"/></g> +<g id="explicit"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 6h-4v2h4v2h-4v2h4v2H9V7h6v2z"/></g> +<g id="fast-forward"><path d="M4 18l8.5-6L4 6v12zm9-12v12l8.5-6L13 6z"/></g> +<g id="fast-rewind"><path d="M11 18V6l-8.5 6 8.5 6zm.5-6l8.5 6V6l-8.5 6z"/></g> +<g id="forward-10"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M4 13c0 4.4 3.6 8 8 8s8-3.6 8-8h-2c0 3.3-2.7 6-6 6s-6-2.7-6-6 2.7-6 6-6v4l5-5-5-5v4c-4.4 0-8 3.6-8 8zm6.8 3H10v-3.3L9 13v-.7l1.8-.6h.1V16zm4.3-1.8c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1.3.2.5.3.2.3.3.6.1.5.1.8v.7zm-.8-.8v-.5s-.1-.2-.1-.3-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5z" clip-path="url(#b)"/></g> +<g id="forward-30"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M9.6 13.5h.4c.2 0 .4-.1.5-.2s.2-.2.2-.4v-.2s-.1-.1-.1-.2-.1-.1-.2-.1h-.5s-.1.1-.2.1-.1.1-.1.2v.2h-1c0-.2 0-.3.1-.5s.2-.3.3-.4.3-.2.4-.2.4-.1.5-.1c.2 0 .4 0 .6.1s.3.1.5.2.2.2.3.4.1.3.1.5v.3s-.1.2-.1.3-.1.2-.2.2-.2.1-.3.2c.2.1.4.2.5.4s.2.4.2.6c0 .2 0 .4-.1.5s-.2.3-.3.4-.3.2-.5.2-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.4-.1-.6h.8v.2s.1.1.1.2.1.1.2.1h.5s.1-.1.2-.1.1-.1.1-.2v-.5s-.1-.1-.1-.2-.1-.1-.2-.1h-.6v-.7zm5.7.7c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1.3.2.5.3.2.3.3.6.1.5.1.8v.7zm-.9-.8v-.5s-.1-.2-.1-.3-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5zM4 13c0 4.4 3.6 8 8 8s8-3.6 8-8h-2c0 3.3-2.7 6-6 6s-6-2.7-6-6 2.7-6 6-6v4l5-5-5-5v4c-4.4 0-8 3.6-8 8z" clip-path="url(#b)"/></g> +<g id="forward-5"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M4 13c0 4.4 3.6 8 8 8s8-3.6 8-8h-2c0 3.3-2.7 6-6 6s-6-2.7-6-6 2.7-6 6-6v4l5-5-5-5v4c-4.4 0-8 3.6-8 8zm6.7.9l.2-2.2h2.4v.7h-1.7l-.1.9s.1 0 .1-.1.1 0 .1-.1.1 0 .2 0h.2c.2 0 .4 0 .5.1s.3.2.4.3.2.3.3.5.1.4.1.6c0 .2 0 .4-.1.5s-.1.3-.3.5-.3.2-.5.3-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.3-.1-.5h.8c0 .2.1.3.2.4s.2.1.4.1c.1 0 .2 0 .3-.1l.2-.2s.1-.2.1-.3v-.6l-.1-.2-.2-.2s-.2-.1-.3-.1h-.2s-.1 0-.2.1-.1 0-.1.1-.1.1-.1.1h-.6z" clip-path="url(#b)"/></g> +<g id="games"><path d="M15 7.5V2H9v5.5l3 3 3-3zM7.5 9H2v6h5.5l3-3-3-3zM9 16.5V22h6v-5.5l-3-3-3 3zM16.5 9l-3 3 3 3H22V9h-5.5z"/></g> +<g id="hd"><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-8 12H9.5v-2h-2v2H6V9h1.5v2.5h2V9H11v6zm2-6h4c.55 0 1 .45 1 1v4c0 .55-.45 1-1 1h-4V9zm1.5 4.5h2v-3h-2v3z"/></g> +<g id="hearing"><path d="M17 20c-.29 0-.56-.06-.76-.15-.71-.37-1.21-.88-1.71-2.38-.51-1.56-1.47-2.29-2.39-3-.79-.61-1.61-1.24-2.32-2.53C9.29 10.98 9 9.93 9 9c0-2.8 2.2-5 5-5s5 2.2 5 5h2c0-3.93-3.07-7-7-7S7 5.07 7 9c0 1.26.38 2.65 1.07 3.9.91 1.65 1.98 2.48 2.85 3.15.81.62 1.39 1.07 1.71 2.05.6 1.82 1.37 2.84 2.73 3.55.51.23 1.07.35 1.64.35 2.21 0 4-1.79 4-4h-2c0 1.1-.9 2-2 2zM7.64 2.64L6.22 1.22C4.23 3.21 3 5.96 3 9s1.23 5.79 3.22 7.78l1.41-1.41C6.01 13.74 5 11.49 5 9s1.01-4.74 2.64-6.36zM11.5 9c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5-1.12-2.5-2.5-2.5-2.5 1.12-2.5 2.5z"/></g> +<g id="high-quality"><path d="M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 11H9.5v-2h-2v2H6V9h1.5v2.5h2V9H11v6zm7-1c0 .55-.45 1-1 1h-.75v1.5h-1.5V15H14c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1h3c.55 0 1 .45 1 1v4zm-3.5-.5h2v-3h-2v3z"/></g> +<g id="library-add"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/></g> +<g id="library-books"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9H9V9h10v2zm-4 4H9v-2h6v2zm4-8H9V5h10v2z"/></g> +<g id="library-music"><path d="M20 2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-2 5h-3v5.5c0 1.38-1.12 2.5-2.5 2.5S10 13.88 10 12.5s1.12-2.5 2.5-2.5c.57 0 1.08.19 1.5.51V5h4v2zM4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6z"/></g> +<g id="loop"><path d="M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"/></g> +<g id="mic"><path d="M12 14c1.66 0 2.99-1.34 2.99-3L15 5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm5.3-3c0 3-2.54 5.1-5.3 5.1S6.7 14 6.7 11H5c0 3.41 2.72 6.23 6 6.72V21h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"/></g> +<g id="mic-none"><path d="M12 14c1.66 0 2.99-1.34 2.99-3L15 5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm-1.2-9.1c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2l-.01 6.2c0 .66-.53 1.2-1.19 1.2-.66 0-1.2-.54-1.2-1.2V4.9zm6.5 6.1c0 3-2.54 5.1-5.3 5.1S6.7 14 6.7 11H5c0 3.41 2.72 6.23 6 6.72V21h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"/></g> +<g id="mic-off"><path d="M19 11h-1.7c0 .74-.16 1.43-.43 2.05l1.23 1.23c.56-.98.9-2.09.9-3.28zm-4.02.17c0-.06.02-.11.02-.17V5c0-1.66-1.34-3-3-3S9 3.34 9 5v.18l5.98 5.99zM4.27 3L3 4.27l6.01 6.01V11c0 1.66 1.33 3 2.99 3 .22 0 .44-.03.65-.08l1.66 1.66c-.71.33-1.5.52-2.31.52-2.76 0-5.3-2.1-5.3-5.1H5c0 3.41 2.72 6.23 6 6.72V21h2v-3.28c.91-.13 1.77-.45 2.54-.9L19.73 21 21 19.73 4.27 3z"/></g> +<g id="movie"><path d="M18 4l2 4h-3l-2-4h-2l2 4h-3l-2-4H8l2 4H7L5 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4h-4z"/></g> +<g id="new-releases"><path d="M23 12l-2.44-2.78.34-3.68-3.61-.82-1.89-3.18L12 3 8.6 1.54 6.71 4.72l-3.61.81.34 3.68L1 12l2.44 2.78-.34 3.69 3.61.82 1.89 3.18L12 21l3.4 1.46 1.89-3.18 3.61-.82-.34-3.68L23 12zm-10 5h-2v-2h2v2zm0-4h-2V7h2v6z"/></g> +<g id="not-interested"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8 0-1.85.63-3.55 1.69-4.9L16.9 18.31C15.55 19.37 13.85 20 12 20zm6.31-3.1L7.1 5.69C8.45 4.63 10.15 4 12 4c4.42 0 8 3.58 8 8 0 1.85-.63 3.55-1.69 4.9z"/></g> +<g id="pause"><path d="M6 19h4V5H6v14zm8-14v14h4V5h-4z"/></g> +<g id="pause-circle-filled"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 14H9V8h2v8zm4 0h-2V8h2v8z"/></g> +<g id="pause-circle-outline"><path d="M9 16h2V8H9v8zm3-14C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm1-4h2V8h-2v8z"/></g> +<g id="play-arrow"><path d="M8 5v14l11-7z"/></g> +<g id="play-circle-filled"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 14.5v-9l6 4.5-6 4.5z"/></g> +<g id="play-circle-outline"><path d="M10 16.5l6-4.5-6-4.5v9zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="playlist-add"><path d="M14 10H2v2h12v-2zm0-4H2v2h12V6zm4 8v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zM2 16h8v-2H2v2z"/></g> +<g id="queue"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/></g> +<g id="queue-music"><path d="M15 6H3v2h12V6zm0 4H3v2h12v-2zM3 16h8v-2H3v2zM17 6v8.18c-.31-.11-.65-.18-1-.18-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3V8h3V6h-5z"/></g> +<g id="radio"><path d="M3.24 6.15C2.51 6.43 2 7.17 2 8v12c0 1.1.89 2 2 2h16c1.11 0 2-.9 2-2V8c0-1.11-.89-2-2-2H8.3l8.26-3.34L15.88 1 3.24 6.15zM7 20c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm13-8h-2v-2h-2v2H4V8h16v4z"/></g> +<g id="recent-actors"><path d="M21 5v14h2V5h-2zm-4 14h2V5h-2v14zM14 5H2c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h12c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zM8 7.75c1.24 0 2.25 1.01 2.25 2.25S9.24 12.25 8 12.25 5.75 11.24 5.75 10 6.76 7.75 8 7.75zM12.5 17h-9v-.75c0-1.5 3-2.25 4.5-2.25s4.5.75 4.5 2.25V17z"/></g> +<g id="repeat"><path d="M7 7h10v3l4-4-4-4v3H5v6h2V7zm10 10H7v-3l-4 4 4 4v-3h12v-6h-2v4z"/></g> +<g id="repeat-one"><path d="M7 7h10v3l4-4-4-4v3H5v6h2V7zm10 10H7v-3l-4 4 4 4v-3h12v-6h-2v4zm-4-2V9h-1l-2 1v1h1.5v4H13z"/></g> +<g id="replay"><path d="M12 5V1L7 6l5 5V7c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6H4c0 4.42 3.58 8 8 8s8-3.58 8-8-3.58-8-8-8z"/></g> +<g id="replay-10"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M12 5V1L7 6l5 5V7c3.3 0 6 2.7 6 6s-2.7 6-6 6-6-2.7-6-6H4c0 4.4 3.6 8 8 8s8-3.6 8-8-3.6-8-8-8zm-1.1 11H10v-3.3L9 13v-.7l1.8-.6h.1V16zm4.3-1.8c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1c.2.1.3.2.5.3s.2.3.3.6.1.5.1.8v.7zm-.9-.8v-.5s-.1-.2-.1-.3-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5z" clip-path="url(#b)"/></g> +<g id="replay-30"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M12 5V1L7 6l5 5V7c3.3 0 6 2.7 6 6s-2.7 6-6 6-6-2.7-6-6H4c0 4.4 3.6 8 8 8s8-3.6 8-8-3.6-8-8-8zm-2.4 8.5h.4c.2 0 .4-.1.5-.2s.2-.2.2-.4v-.2s-.1-.1-.1-.2-.1-.1-.2-.1h-.5s-.1.1-.2.1-.1.1-.1.2v.2h-1c0-.2 0-.3.1-.5s.2-.3.3-.4.3-.2.4-.2.4-.1.5-.1c.2 0 .4 0 .6.1s.3.1.5.2.2.2.3.4.1.3.1.5v.3s-.1.2-.1.3-.1.2-.2.2-.2.1-.3.2c.2.1.4.2.5.4s.2.4.2.6c0 .2 0 .4-.1.5s-.2.3-.3.4-.3.2-.5.2-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.4-.1-.6h.8v.2s.1.1.1.2.1.1.2.1h.5s.1-.1.2-.1.1-.1.1-.2v-.5s-.1-.1-.1-.2-.1-.1-.2-.1h-.6v-.7zm5.7.7c0 .3 0 .6-.1.8l-.3.6s-.3.3-.5.3-.4.1-.6.1-.4 0-.6-.1-.3-.2-.5-.3-.2-.3-.3-.6-.1-.5-.1-.8v-.7c0-.3 0-.6.1-.8l.3-.6s.3-.3.5-.3.4-.1.6-.1.4 0 .6.1.3.2.5.3.2.3.3.6.1.5.1.8v.7zm-.8-.8v-.5c0-.1-.1-.2-.1-.3s-.1-.1-.2-.2-.2-.1-.3-.1-.2 0-.3.1l-.2.2s-.1.2-.1.3v2s.1.2.1.3.1.1.2.2.2.1.3.1.2 0 .3-.1l.2-.2s.1-.2.1-.3v-1.5z" clip-path="url(#b)"/></g> +<g id="replay-5"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M12 5V1L7 6l5 5V7c3.3 0 6 2.7 6 6s-2.7 6-6 6-6-2.7-6-6H4c0 4.4 3.6 8 8 8s8-3.6 8-8-3.6-8-8-8zm-1.3 8.9l.2-2.2h2.4v.7h-1.7l-.1.9s.1 0 .1-.1.1 0 .1-.1.1 0 .2 0h.2c.2 0 .4 0 .5.1s.3.2.4.3.2.3.3.5.1.4.1.6c0 .2 0 .4-.1.5s-.1.3-.3.5-.3.2-.4.3-.4.1-.6.1c-.2 0-.4 0-.5-.1s-.3-.1-.5-.2-.2-.2-.3-.4-.1-.3-.1-.5h.8c0 .2.1.3.2.4s.2.1.4.1c.1 0 .2 0 .3-.1l.2-.2s.1-.2.1-.3v-.6l-.1-.2-.2-.2s-.2-.1-.3-.1h-.2s-.1 0-.2.1-.1 0-.1.1-.1.1-.1.1h-.7z" clip-path="url(#b)"/></g> +<g id="shuffle"><path d="M10.59 9.17L5.41 4 4 5.41l5.17 5.17 1.42-1.41zM14.5 4l2.04 2.04L4 18.59 5.41 20 17.96 7.46 20 9.5V4h-5.5zm.33 9.41l-1.41 1.41 3.13 3.13L14.5 20H20v-5.5l-2.04 2.04-3.13-3.13z"/></g> +<g id="skip-next"><path d="M6 18l8.5-6L6 6v12zM16 6v12h2V6h-2z"/></g> +<g id="skip-previous"><path d="M6 6h2v12H6zm3.5 6l8.5 6V6z"/></g> +<g id="snooze"><path d="M7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm-3-9h3.63L9 15.2V17h6v-2h-3.63L15 10.8V9H9v2z"/></g> +<g id="sort-by-alpha"><path d="M14.94 4.66h-4.72l2.36-2.36zm-4.69 14.71h4.66l-2.33 2.33zM6.1 6.27L1.6 17.73h1.84l.92-2.45h5.11l.92 2.45h1.84L7.74 6.27H6.1zm-1.13 7.37l1.94-5.18 1.94 5.18H4.97zm10.76 2.5h6.12v1.59h-8.53v-1.29l5.92-8.56h-5.88v-1.6h8.3v1.26l-5.93 8.6z"/></g> +<g id="stop"><path d="M6 6h12v12H6z"/></g> +<g id="subtitles"><path d="M20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM4 12h4v2H4v-2zm10 6H4v-2h10v2zm6 0h-4v-2h4v2zm0-4H10v-2h10v2z"/></g> +<g id="surround-sound"><path d="M20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM7.76 16.24l-1.41 1.41C4.78 16.1 4 14.05 4 12c0-2.05.78-4.1 2.34-5.66l1.41 1.41C6.59 8.93 6 10.46 6 12s.59 3.07 1.76 4.24zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm5.66 1.66l-1.41-1.41C17.41 15.07 18 13.54 18 12s-.59-3.07-1.76-4.24l1.41-1.41C19.22 7.9 20 9.95 20 12c0 2.05-.78 4.1-2.34 5.66zM12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="video-library"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-8 12.5v-9l6 4.5-6 4.5z"/></g> +<g id="videocam"><path d="M17 10.5V7c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.55 0 1-.45 1-1v-3.5l4 4v-11l-4 4z"/></g> +<g id="videocam-off"><path d="M21 6.5l-4 4V7c0-.55-.45-1-1-1H9.82L21 17.18V6.5zM3.27 2L2 3.27 4.73 6H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.21 0 .39-.08.54-.18L19.73 21 21 19.73 3.27 2z"/></g> +<g id="volume-down"><path d="M18.5 12c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM5 9v6h4l5 5V4L9 9H5z"/></g> +<g id="volume-mute"><path d="M7 9v6h4l5 5V4l-5 5H7z"/></g> +<g id="volume-off"><path d="M16.5 12c0-1.77-1.02-3.29-2.5-4.03v2.21l2.45 2.45c.03-.2.05-.41.05-.63zm2.5 0c0 .94-.2 1.82-.54 2.64l1.51 1.51C20.63 14.91 21 13.5 21 12c0-4.28-2.99-7.86-7-8.77v2.06c2.89.86 5 3.54 5 6.71zM4.27 3L3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25c-.67.52-1.42.93-2.25 1.18v2.06c1.38-.31 2.63-.95 3.69-1.81L19.73 21 21 19.73l-9-9L4.27 3zM12 4L9.91 6.09 12 8.18V4z"/></g> +<g id="volume-up"><path d="M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"/></g> +<g id="web"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 14H4v-4h11v4zm0-5H4V9h11v4zm5 5h-4V9h4v9z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/bower.json b/third_party/polymer/v1_0/components/iron-icons/bower.json new file mode 100644 index 0000000..1ba69fb --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-icons", + "version": "1.0.1", + "description": "A set of icons for use with iron-icon", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "main": "iron-icons.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-icons" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-icons", + "dependencies": { + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "ignore": [ + "util", + "update-icons.sh" + ] +} diff --git a/third_party/polymer/v1_0/components/iron-icons/communication-icons.html b/third_party/polymer/v1_0/components/iron-icons/communication-icons.html new file mode 100644 index 0000000..ec72704 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/communication-icons.html @@ -0,0 +1,59 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="communication" size="24"> +<svg><defs> +<g id="business"><path d="M12 7V3H2v18h20V7H12zM6 19H4v-2h2v2zm0-4H4v-2h2v2zm0-4H4V9h2v2zm0-4H4V5h2v2zm4 12H8v-2h2v2zm0-4H8v-2h2v2zm0-4H8V9h2v2zm0-4H8V5h2v2zm10 12h-8v-2h2v-2h-2v-2h2v-2h-2V9h8v10zm-2-8h-2v2h2v-2zm0 4h-2v2h2v-2z"/></g> +<g id="call"><path d="M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z"/></g> +<g id="call-end"><path d="M12 9c-1.6 0-3.15.25-4.6.72v3.1c0 .39-.23.74-.56.9-.98.49-1.87 1.12-2.66 1.85-.18.18-.43.28-.7.28-.28 0-.53-.11-.71-.29L.29 13.08c-.18-.17-.29-.42-.29-.7 0-.28.11-.53.29-.71C3.34 8.78 7.46 7 12 7s8.66 1.78 11.71 4.67c.18.18.29.43.29.71 0 .28-.11.53-.29.71l-2.48 2.48c-.18.18-.43.29-.71.29-.27 0-.52-.11-.7-.28-.79-.74-1.69-1.36-2.67-1.85-.33-.16-.56-.5-.56-.9v-3.1C15.15 9.25 13.6 9 12 9z"/></g> +<g id="call-made"><path d="M9 5v2h6.59L4 18.59 5.41 20 17 8.41V15h2V5z"/></g> +<g id="call-merge"><path d="M17 20.41L18.41 19 15 15.59 13.59 17 17 20.41zM7.5 8H11v5.59L5.59 19 7 20.41l6-6V8h3.5L12 3.5 7.5 8z"/></g> +<g id="call-missed"><path d="M19.59 7L12 14.59 6.41 9H11V7H3v8h2v-4.59l7 7 9-9z"/></g> +<g id="call-received"><path d="M20 5.41L18.59 4 7 15.59V9H5v10h10v-2H8.41z"/></g> +<g id="call-split"><path d="M14 4l2.29 2.29-2.88 2.88 1.42 1.42 2.88-2.88L20 10V4zm-4 0H4v6l2.29-2.29 4.71 4.7V20h2v-8.41l-5.29-5.3z"/></g> +<g id="chat"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 9h12v2H6V9zm8 5H6v-2h8v2zm4-6H6V6h12v2z"/></g> +<g id="chat-bubble"><path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2z"/></g> +<g id="chat-bubble-outline"><path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H6l-2 2V4h16v12z"/></g> +<g id="clear-all"><path d="M5 13h14v-2H5v2zm-2 4h14v-2H3v2zM7 7v2h14V7H7z"/></g> +<g id="comment"><path d="M21.99 4c0-1.1-.89-2-1.99-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4-.01-18zM18 14H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z"/></g> +<g id="contact-phone"><path d="M22 3H2C.9 3 0 3.9 0 5v14c0 1.1.9 2 2 2h20c1.1 0 1.99-.9 1.99-2L24 5c0-1.1-.9-2-2-2zM8 6c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H2v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1zm3.85-4h1.64L21 16l-1.99 1.99c-1.31-.98-2.28-2.38-2.73-3.99-.18-.64-.28-1.31-.28-2s.1-1.36.28-2c.45-1.62 1.42-3.01 2.73-3.99L21 8l-1.51 2h-1.64c-.22.63-.35 1.3-.35 2s.13 1.37.35 2z"/></g> +<g id="contacts"><path d="M20 0H4v2h16V0zM4 24h16v-2H4v2zM20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 2.75c1.24 0 2.25 1.01 2.25 2.25s-1.01 2.25-2.25 2.25S9.75 10.24 9.75 9 10.76 6.75 12 6.75zM17 17H7v-1.5c0-1.67 3.33-2.5 5-2.5s5 .83 5 2.5V17z"/></g> +<g id="dialer-sip"><path d="M17 3h-1v5h1V3zm-2 2h-2V4h2V3h-3v3h2v1h-2v1h3V5zm3-2v5h1V6h2V3h-3zm2 2h-1V4h1v1zm0 10.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.01.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.27-.26.35-.65.24-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1z"/></g> +<g id="dialpad"><path d="M12 19c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 1c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12-8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-6 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="email"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="forum"><path d="M21 6h-2v9H6v2c0 .55.45 1 1 1h11l4 4V7c0-.55-.45-1-1-1zm-4 6V3c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v14l4-4h10c.55 0 1-.45 1-1z"/></g> +<g id="import-export"><path d="M9 3L5 6.99h3V14h2V6.99h3L9 3zm7 14.01V10h-2v7.01h-3L15 21l4-3.99h-3z"/></g> +<g id="invert-colors-off"><path d="M20.65 20.87l-2.35-2.35-6.3-6.29-3.56-3.57-1.42-1.41L4.27 4.5 3 5.77l2.78 2.78c-2.55 3.14-2.36 7.76.56 10.69C7.9 20.8 9.95 21.58 12 21.58c1.79 0 3.57-.59 5.03-1.78l2.7 2.7L21 21.23l-.35-.36zM12 19.59c-1.6 0-3.11-.62-4.24-1.76C6.62 16.69 6 15.19 6 13.59c0-1.32.43-2.57 1.21-3.6L12 14.77v4.82zM12 5.1v4.58l7.25 7.26c1.37-2.96.84-6.57-1.6-9.01L12 2.27l-3.7 3.7 1.41 1.41L12 5.1z"/></g> +<g id="live-help"><path d="M19 2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h4l3 3 3-3h4c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6 16h-2v-2h2v2zm2.07-7.75l-.9.92C13.45 11.9 13 12.5 13 14h-2v-.5c0-1.1.45-2.1 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41 0-1.1-.9-2-2-2s-2 .9-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 .88-.36 1.68-.93 2.25z"/></g> +<g id="location-off"><path d="M12 6.5c1.38 0 2.5 1.12 2.5 2.5 0 .74-.33 1.39-.83 1.85l3.63 3.63c.98-1.86 1.7-3.8 1.7-5.48 0-3.87-3.13-7-7-7-1.98 0-3.76.83-5.04 2.15l3.19 3.19c.46-.52 1.11-.84 1.85-.84zm4.37 9.6l-4.63-4.63-.11-.11L3.27 3 2 4.27l3.18 3.18C5.07 7.95 5 8.47 5 9c0 5.25 7 13 7 13s1.67-1.85 3.38-4.35L18.73 21 20 19.73l-3.63-3.63z"/></g> +<g id="location-on"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="mail"><path d="M21 8V7l-3 2-3-2v1l3 2 3-2zm1-5H2C.9 3 0 3.9 0 5v14c0 1.1.9 2 2 2h20c1.1 0 1.99-.9 1.99-2L24 5c0-1.1-.9-2-2-2zM8 6c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H2v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1zm8-6h-8V6h8v6z"/></g> +<g id="message"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-2 12H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z"/></g> +<g id="no-sim"><path d="M18.99 5c0-1.1-.89-2-1.99-2h-7L7.66 5.34 19 16.68 18.99 5zM3.65 3.88L2.38 5.15 5 7.77V19c0 1.1.9 2 2 2h10.01c.35 0 .67-.1.96-.26l1.88 1.88 1.27-1.27L3.65 3.88z"/></g> +<g id="phone"><path d="M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z"/></g> +<g id="phonelink-erase"><path d="M13 8.2l-1-1-4 4-4-4-1 1 4 4-4 4 1 1 4-4 4 4 1-1-4-4 4-4zM19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2z"/></g> +<g id="phonelink-lock"><path d="M19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm-8.2 10V9.5C10.8 8.1 9.4 7 8 7S5.2 8.1 5.2 9.5V11c-.6 0-1.2.6-1.2 1.2v3.5c0 .7.6 1.3 1.2 1.3h5.5c.7 0 1.3-.6 1.3-1.2v-3.5c0-.7-.6-1.3-1.2-1.3zm-1.3 0h-3V9.5c0-.8.7-1.3 1.5-1.3s1.5.5 1.5 1.3V11z"/></g> +<g id="phonelink-ring"><path d="M20.1 7.7l-1 1c1.8 1.8 1.8 4.6 0 6.5l1 1c2.5-2.3 2.5-6.1 0-8.5zM18 9.8l-1 1c.5.7.5 1.6 0 2.3l1 1c1.2-1.2 1.2-3 0-4.3zM14 1H4c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 19H4V4h10v16z"/></g> +<g id="phonelink-setup"><path d="M11.8 12.5v-1l1.1-.8c.1-.1.1-.2.1-.3l-1-1.7c-.1-.1-.2-.2-.3-.1l-1.3.4c-.3-.2-.6-.4-.9-.5l-.2-1.3c0-.1-.1-.2-.3-.2H7c-.1 0-.2.1-.3.2l-.2 1.3c-.3.1-.6.3-.9.5l-1.3-.5c-.1 0-.2 0-.3.1l-1 1.7c-.1.1 0 .2.1.3l1.1.8v1l-1.1.8c-.1.2-.1.3-.1.4l1 1.7c.1.1.2.2.3.1l1.4-.4c.3.2.6.4.9.5l.2 1.3c-.1.1.1.2.2.2h2c.1 0 .2-.1.3-.2l.2-1.3c.3-.1.6-.3.9-.5l1.3.5c.1 0 .2 0 .3-.1l1-1.7c.1-.1 0-.2-.1-.3l-1.1-.9zM8 14c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM19 1H9c-1.1 0-2 .9-2 2v3h2V4h10v16H9v-2H7v3c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2z"/></g> +<g id="portable-wifi-off"><path d="M17.56 14.24c.28-.69.44-1.45.44-2.24 0-3.31-2.69-6-6-6-.79 0-1.55.16-2.24.44l1.62 1.62c.2-.03.41-.06.62-.06 2.21 0 4 1.79 4 4 0 .21-.02.42-.05.63l1.61 1.61zM12 4c4.42 0 8 3.58 8 8 0 1.35-.35 2.62-.95 3.74l1.47 1.47C21.46 15.69 22 13.91 22 12c0-5.52-4.48-10-10-10-1.91 0-3.69.55-5.21 1.47l1.46 1.46C9.37 4.34 10.65 4 12 4zM3.27 2.5L2 3.77l2.1 2.1C2.79 7.57 2 9.69 2 12c0 3.7 2.01 6.92 4.99 8.65l1-1.73C5.61 17.53 4 14.96 4 12c0-1.76.57-3.38 1.53-4.69l1.43 1.44C6.36 9.68 6 10.8 6 12c0 2.22 1.21 4.15 3 5.19l1-1.74c-1.19-.7-2-1.97-2-3.45 0-.65.17-1.25.44-1.79l1.58 1.58L10 12c0 1.1.9 2 2 2l.21-.02.01.01 7.51 7.51L21 20.23 4.27 3.5l-1-1z"/></g> +<g id="present-to-all"><path d="M21 3H3c-1.11 0-2 .89-2 2v14c0 1.11.89 2 2 2h18c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2zm0 16.02H3V4.98h18v14.04zM10 12H8l4-4 4 4h-2v4h-4v-4z"/></g> +<g id="ring-volume"><path d="M23.71 16.67C20.66 13.78 16.54 12 12 12 7.46 12 3.34 13.78.29 16.67c-.18.18-.29.43-.29.71 0 .28.11.53.29.71l2.48 2.48c.18.18.43.29.71.29.27 0 .52-.11.7-.28.79-.74 1.69-1.36 2.66-1.85.33-.16.56-.5.56-.9v-3.1c1.45-.48 3-.73 4.6-.73s3.15.25 4.6.72v3.1c0 .39.23.74.56.9.98.49 1.87 1.12 2.66 1.85.18.18.43.28.7.28.28 0 .53-.11.71-.29l2.48-2.48c.18-.18.29-.43.29-.71 0-.27-.11-.52-.29-.7zM21.16 6.26l-1.41-1.41-3.56 3.55 1.41 1.41s3.45-3.52 3.56-3.55zM13 2h-2v5h2V2zM6.4 9.81L7.81 8.4 4.26 4.84 2.84 6.26c.11.03 3.56 3.55 3.56 3.55z"/></g> +<g id="speaker-phone"><path d="M7 7.07L8.43 8.5c.91-.91 2.18-1.48 3.57-1.48s2.66.57 3.57 1.48L17 7.07C15.72 5.79 13.95 5 12 5s-3.72.79-5 2.07zM12 1C8.98 1 6.24 2.23 4.25 4.21l1.41 1.41C7.28 4 9.53 3 12 3s4.72 1 6.34 2.62l1.41-1.41C17.76 2.23 15.02 1 12 1zm2.86 9.01L9.14 10C8.51 10 8 10.51 8 11.14v9.71c0 .63.51 1.14 1.14 1.14h5.71c.63 0 1.14-.51 1.14-1.14v-9.71c.01-.63-.5-1.13-1.13-1.13zM15 20H9v-8h6v8z"/></g> +<g id="stay-current-landscape"><path d="M1.01 7L1 17c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2H3c-1.1 0-1.99.9-1.99 2zM19 7v10H5V7h14z"/></g> +<g id="stay-current-portrait"><path d="M17 1.01L7 1c-1.1 0-1.99.9-1.99 2v18c0 1.1.89 2 1.99 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="stay-primary-landscape"><path d="M1.01 7L1 17c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2H3c-1.1 0-1.99.9-1.99 2zM19 7v10H5V7h14z"/></g> +<g id="stay-primary-portrait"><path d="M17 1.01L7 1c-1.1 0-1.99.9-1.99 2v18c0 1.1.89 2 1.99 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="swap-calls"><path d="M18 4l-4 4h3v7c0 1.1-.9 2-2 2s-2-.9-2-2V8c0-2.21-1.79-4-4-4S5 5.79 5 8v7H2l4 4 4-4H7V8c0-1.1.9-2 2-2s2 .9 2 2v7c0 2.21 1.79 4 4 4s4-1.79 4-4V8h3l-4-4z"/></g> +<g id="textsms"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM9 11H7V9h2v2zm4 0h-2V9h2v2zm4 0h-2V9h2v2z"/></g> +<g id="voicemail"><path d="M18.5 6C15.46 6 13 8.46 13 11.5c0 1.33.47 2.55 1.26 3.5H9.74c.79-.95 1.26-2.17 1.26-3.5C11 8.46 8.54 6 5.5 6S0 8.46 0 11.5 2.46 17 5.5 17h13c3.04 0 5.5-2.46 5.5-5.5S21.54 6 18.5 6zm-13 9C3.57 15 2 13.43 2 11.5S3.57 8 5.5 8 9 9.57 9 11.5 7.43 15 5.5 15zm13 0c-1.93 0-3.5-1.57-3.5-3.5S16.57 8 18.5 8 22 9.57 22 11.5 20.43 15 18.5 15z"/></g> +<g id="vpn-key"><path d="M12.65 10C11.83 7.67 9.61 6 7 6c-3.31 0-6 2.69-6 6s2.69 6 6 6c2.61 0 4.83-1.67 5.65-4H17v4h4v-4h2v-4H12.65zM7 14c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/device-icons.html b/third_party/polymer/v1_0/components/iron-icons/device-icons.html new file mode 100644 index 0000000..e875a05 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/device-icons.html @@ -0,0 +1,94 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="device" size="24"> +<svg><defs> +<g id="access-alarm"><path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="access-alarms"><path d="M22 5.7l-4.6-3.9-1.3 1.5 4.6 3.9L22 5.7zM7.9 3.4L6.6 1.9 2 5.7l1.3 1.5 4.6-3.8zM12.5 8H11v6l4.7 2.9.8-1.2-4-2.4V8zM12 4c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7z"/></g> +<g id="access-time"><path fill-opacity=".9" d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zM12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></g> +<g id="add-alarm"><path d="M7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm1-11h-2v3H8v2h3v3h2v-3h3v-2h-3V9z"/></g> +<g id="airplanemode-active"><path d="M10.18 9"/><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/></g> +<g id="airplanemode-inactive"><path d="M13 9V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v3.68l7.83 7.83L21 16v-2l-8-5zM3 5.27l4.99 4.99L2 14v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-3.73L18.73 21 20 19.73 4.27 4 3 5.27z"/></g> +<g id="battery-20"><path d="M7 17v3.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V17H7z"/><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V17h10V5.33z"/></g> +<g id="battery-30"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V15h10V5.33z"/><path d="M7 15v5.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V15H7z"/></g> +<g id="battery-50"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V13h10V5.33z"/><path d="M7 13v7.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V13H7z"/></g> +<g id="battery-60"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V11h10V5.33z"/><path d="M7 11v9.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V11H7z"/></g> +<g id="battery-80"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V9h10V5.33z"/><path d="M7 9v11.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V9H7z"/></g> +<g id="battery-90"><path fill-opacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V8h10V5.33z"/><path d="M7 8v12.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V8H7z"/></g> +<g id="battery-alert"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4zM13 18h-2v-2h2v2zm0-4h-2V9h2v5z"/></g> +<g id="battery-charging-20"><path d="M11 20v-3H7v3.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V17h-4.4L11 20z"/><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V17h4v-2.5H9L13 7v5.5h2L12.6 17H17V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-charging-30"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v9.17h2L13 7v5.5h2l-1.07 2H17V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M11 20v-5.5H7v6.17C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V14.5h-3.07L11 20z"/></g> +<g id="battery-charging-50"><path d="M14.47 13.5L11 20v-5.5H9l.53-1H7v7.17C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V13.5h-2.53z"/><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v8.17h2.53L13 7v5.5h2l-.53 1H17V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-charging-60"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V11h3.87L13 7v4h4V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M13 12.5h2L11 20v-5.5H9l1.87-3.5H7v9.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V11h-4v1.5z"/></g> +<g id="battery-charging-80"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V9h4.93L13 7v2h4V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M13 12.5h2L11 20v-5.5H9L11.93 9H7v11.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V9h-4v3.5z"/></g> +<g id="battery-charging-90"><path fill-opacity=".3" d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V8h5.47L13 7v1h4V5.33C17 4.6 16.4 4 15.67 4z"/><path d="M13 12.5h2L11 20v-5.5H9L12.47 8H7v12.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V8h-4v4.5z"/></g> +<g id="battery-charging-full"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4zM11 20v-5.5H9L13 7v5.5h2L11 20z"/></g> +<g id="battery-full"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-std"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"/></g> +<g id="battery-unknown"><path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4zm-2.72 13.95h-1.9v-1.9h1.9v1.9zm1.35-5.26s-.38.42-.67.71c-.48.48-.83 1.15-.83 1.6h-1.6c0-.83.46-1.52.93-2l.93-.94c.27-.27.44-.65.44-1.06 0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5H9c0-1.66 1.34-3 3-3s3 1.34 3 3c0 .66-.27 1.26-.7 1.69z"/></g> +<g id="bluetooth"><path d="M17.71 7.71L12 2h-1v7.59L6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 5.83l1.88 1.88L13 9.59V5.83zm1.88 10.46L13 18.17v-3.76l1.88 1.88z"/></g> +<g id="bluetooth-connected"><path d="M7 12l-2-2-2 2 2 2 2-2zm10.71-4.29L12 2h-1v7.59L6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 5.83l1.88 1.88L13 9.59V5.83zm1.88 10.46L13 18.17v-3.76l1.88 1.88zM19 10l-2 2 2 2 2-2-2-2z"/></g> +<g id="bluetooth-disabled"><path d="M13 5.83l1.88 1.88-1.6 1.6 1.41 1.41 3.02-3.02L12 2h-1v5.03l2 2v-3.2zM5.41 4L4 5.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l4.29-4.29 2.3 2.29L20 18.59 5.41 4zM13 18.17v-3.76l1.88 1.88L13 18.17z"/></g> +<g id="bluetooth-searching"><path d="M14.24 12.01l2.32 2.32c.28-.72.44-1.51.44-2.33 0-.82-.16-1.59-.43-2.31l-2.33 2.32zm5.29-5.3l-1.26 1.26c.63 1.21.98 2.57.98 4.02s-.36 2.82-.98 4.02l1.2 1.2c.97-1.54 1.54-3.36 1.54-5.31-.01-1.89-.55-3.67-1.48-5.19zm-3.82 1L10 2H9v7.59L4.41 5 3 6.41 8.59 12 3 17.59 4.41 19 9 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM11 5.83l1.88 1.88L11 9.59V5.83zm1.88 10.46L11 18.17v-3.76l1.88 1.88z"/></g> +<g id="brightness-auto"><path d="M10.85 12.65h2.3L12 9l-1.15 3.65zM20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM14.3 16l-.7-2h-3.2l-.7 2H7.8L11 7h2l3.2 9h-1.9z"/></g> +<g id="brightness-high"><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6zm0-10c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4z"/></g> +<g id="brightness-low"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6z"/></g> +<g id="brightness-medium"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18V6c3.31 0 6 2.69 6 6s-2.69 6-6 6z"/></g> +<g id="data-usage"><path d="M13 2.05v3.03c3.39.49 6 3.39 6 6.92 0 .9-.18 1.75-.48 2.54l2.6 1.53c.56-1.24.88-2.62.88-4.07 0-5.18-3.95-9.45-9-9.95zM12 19c-3.87 0-7-3.13-7-7 0-3.53 2.61-6.43 6-6.92V2.05c-5.06.5-9 4.76-9 9.95 0 5.52 4.47 10 9.99 10 3.31 0 6.24-1.61 8.06-4.09l-2.6-1.53C16.17 17.98 14.21 19 12 19z"/></g> +<g id="developer-mode"><path d="M7 5h10v2h2V3c0-1.1-.9-1.99-2-1.99L7 1c-1.1 0-2 .9-2 2v4h2V5zm8.41 11.59L20 12l-4.59-4.59L14 8.83 17.17 12 14 15.17l1.41 1.42zM10 15.17L6.83 12 10 8.83 8.59 7.41 4 12l4.59 4.59L10 15.17zM17 19H7v-2H5v4c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2v-4h-2v2z"/></g> +<g id="devices"><path d="M4 6h18V4H4c-1.1 0-2 .9-2 2v11H0v3h14v-3H4V6zm19 2h-6c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zm-1 9h-4v-7h4v7z"/></g> +<g id="dvr"><path d="M21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.1-.9-2-2-2zm0 14H3V5h18v12zm-2-9H8v2h11V8zm0 4H8v2h11v-2zM7 8H5v2h2V8zm0 4H5v2h2v-2z"/></g> +<g id="gps-fixed"><path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm8.94 3c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="gps-not-fixed"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="gps-off"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06c-1.13.12-2.19.46-3.16.97l1.5 1.5C10.16 5.19 11.06 5 12 5c3.87 0 7 3.13 7 7 0 .94-.19 1.84-.52 2.65l1.5 1.5c.5-.96.84-2.02.97-3.15H23v-2h-2.06zM3 4.27l2.04 2.04C3.97 7.62 3.25 9.23 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c1.77-.2 3.38-.91 4.69-1.98L19.73 21 21 19.73 4.27 3 3 4.27zm13.27 13.27C15.09 18.45 13.61 19 12 19c-3.87 0-7-3.13-7-7 0-1.61.55-3.09 1.46-4.27l9.81 9.81z"/></g> +<g id="graphic-eq"><path d="M7 18h2V6H7v12zm4 4h2V2h-2v20zm-8-8h2v-4H3v4zm12 4h2V6h-2v12zm4-8v4h2v-4h-2z"/></g> +<g id="location-disabled"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06c-1.13.12-2.19.46-3.16.97l1.5 1.5C10.16 5.19 11.06 5 12 5c3.87 0 7 3.13 7 7 0 .94-.19 1.84-.52 2.65l1.5 1.5c.5-.96.84-2.02.97-3.15H23v-2h-2.06zM3 4.27l2.04 2.04C3.97 7.62 3.25 9.23 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c1.77-.2 3.38-.91 4.69-1.98L19.73 21 21 19.73 4.27 3 3 4.27zm13.27 13.27C15.09 18.45 13.61 19 12 19c-3.87 0-7-3.13-7-7 0-1.61.55-3.09 1.46-4.27l9.81 9.81z"/></g> +<g id="location-searching"><path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="network-cell"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M17 7L2 22h15z"/></g> +<g id="network-wifi"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M3.53 10.95l8.46 10.54.01.01.01-.01 8.46-10.54C20.04 10.62 16.81 8 12 8c-4.81 0-8.04 2.62-8.47 2.95z"/></g> +<g id="nfc"><path d="M20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 18H4V4h16v16zM18 6h-5c-1.1 0-2 .9-2 2v2.28c-.6.35-1 .98-1 1.72 0 1.1.9 2 2 2s2-.9 2-2c0-.74-.4-1.38-1-1.72V8h3v8H8V8h2V6H6v12h12V6z"/></g> +<g id="screen-lock-landscape"><path d="M21 5H3c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-2 12H5V7h14v10zm-9-1h4c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1v-1c0-1.11-.9-2-2-2-1.11 0-2 .9-2 2v1c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1zm.8-6c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2v1h-2.4v-1z"/></g> +<g id="screen-lock-portrait"><path d="M10 16h4c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1v-1c0-1.11-.9-2-2-2-1.11 0-2 .9-2 2v1c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1zm.8-6c0-.66.54-1.2 1.2-1.2.66 0 1.2.54 1.2 1.2v1h-2.4v-1zM17 1H7c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 18H7V5h10v14z"/></g> +<g id="screen-lock-rotation"><path d="M23.25 12.77l-2.57-2.57-1.41 1.41 2.22 2.22-5.66 5.66L4.51 8.17l5.66-5.66 2.1 2.1 1.41-1.41L11.23.75c-.59-.59-1.54-.59-2.12 0L2.75 7.11c-.59.59-.59 1.54 0 2.12l12.02 12.02c.59.59 1.54.59 2.12 0l6.36-6.36c.59-.59.59-1.54 0-2.12zM8.47 20.48C5.2 18.94 2.86 15.76 2.5 12H1c.51 6.16 5.66 11 11.95 11l.66-.03-3.81-3.82-1.33 1.33zM16 9h5c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1v-.5C21 1.12 19.88 0 18.5 0S16 1.12 16 2.5V3c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1zm.8-6.5c0-.94.76-1.7 1.7-1.7s1.7.76 1.7 1.7V3h-3.4v-.5z"/></g> +<g id="screen-rotation"><path d="M16.48 2.52c3.27 1.55 5.61 4.72 5.97 8.48h1.5C23.44 4.84 18.29 0 12 0l-.66.03 3.81 3.81 1.33-1.32zm-6.25-.77c-.59-.59-1.54-.59-2.12 0L1.75 8.11c-.59.59-.59 1.54 0 2.12l12.02 12.02c.59.59 1.54.59 2.12 0l6.36-6.36c.59-.59.59-1.54 0-2.12L10.23 1.75zm4.6 19.44L2.81 9.17l6.36-6.36 12.02 12.02-6.36 6.36zm-7.31.29C4.25 19.94 1.91 16.76 1.55 13H.05C.56 19.16 5.71 24 12 24l.66-.03-3.81-3.81-1.33 1.32z"/></g> +<g id="sd-storage"><path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6 6h-2V4h2v4zm3 0h-2V4h2v4zm3 0h-2V4h2v4z"/></g> +<g id="settings-system-daydream"><path d="M9 16h6.5c1.38 0 2.5-1.12 2.5-2.5S16.88 11 15.5 11h-.05c-.24-1.69-1.69-3-3.45-3-1.4 0-2.6.83-3.16 2.02h-.16C7.17 10.18 6 11.45 6 13c0 1.66 1.34 3 3 3zM21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/></g> +<g id="signal-cellular-0-bar"><path fill-opacity=".3" d="M2 22h20V2z"/></g> +<g id="signal-cellular-1-bar"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M12 12L2 22h10z"/></g> +<g id="signal-cellular-2-bar"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M14 10L2 22h12z"/></g> +<g id="signal-cellular-3-bar"><path fill-opacity=".3" d="M2 22h20V2z"/><path d="M17 7L2 22h15z"/></g> +<g id="signal-cellular-4-bar"><path d="M2 22h20V2z"/></g> +<g id="signal-cellular-connected-no-internet-0-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M20 22h2v-2h-2v2zm0-12v8h2v-8h-2z"/></g> +<g id="signal-cellular-connected-no-internet-1-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M20 10v8h2v-8h-2zm-8 12V12L2 22h10zm8 0h2v-2h-2v2z"/></g> +<g id="signal-cellular-connected-no-internet-2-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M14 22V10L2 22h12zm6-12v8h2v-8h-2zm0 12h2v-2h-2v2z"/></g> +<g id="signal-cellular-connected-no-internet-3-bar"><path fill-opacity=".3" d="M22 8V2L2 22h16V8z"/><path d="M17 22V7L2 22h15zm3-12v8h2v-8h-2zm0 12h2v-2h-2v2z"/></g> +<g id="signal-cellular-connected-no-internet-4-bar"><path d="M20 18h2v-8h-2v8zm0 4h2v-2h-2v2zM2 22h16V8h4V2L2 22z"/></g> +<g id="signal-cellular-no-sim"><path d="M18.99 5c0-1.1-.89-2-1.99-2h-7L7.66 5.34 19 16.68 18.99 5zM3.65 3.88L2.38 5.15 5 7.77V19c0 1.1.9 2 2 2h10.01c.35 0 .67-.1.96-.26l1.88 1.88 1.27-1.27L3.65 3.88z"/></g> +<g id="signal-cellular-null"><path d="M20 6.83V20H6.83L20 6.83M22 2L2 22h20V2z"/></g> +<g id="signal-cellular-off"><path d="M21 1l-8.59 8.59L21 18.18V1zM4.77 4.5L3.5 5.77l6.36 6.36L1 21h17.73l2 2L22 21.73 4.77 4.5z"/></g> +<g id="signal-wifi-0-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/></g> +<g id="signal-wifi-1-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M6.67 14.86L12 21.49v.01l.01-.01 5.33-6.63C17.06 14.65 15.03 13 12 13s-5.06 1.65-5.33 1.86z"/></g> +<g id="signal-wifi-1-bar-lock"><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16z"/><path d="M15.5 14.5c0-2.8 2.2-5 5-5 .4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4C5.3 3 .8 6.7.4 7L12 21.5l3.5-4.3v-2.7z" opacity=".3"/><path d="M6.7 14.9l5.3 6.6 3.5-4.3v-2.6c0-.2 0-.5.1-.7-.9-.5-2.2-.9-3.6-.9-3 0-5.1 1.7-5.3 1.9z"/></g> +<g id="signal-wifi-2-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M4.79 12.52l7.2 8.98H12l.01-.01 7.2-8.98C18.85 12.24 16.1 10 12 10s-6.85 2.24-7.21 2.52z"/></g> +<g id="signal-wifi-2-bar-lock"><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16z"/><path d="M15.5 14.5c0-2.8 2.2-5 5-5 .4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4C5.3 3 .8 6.7.4 7L12 21.5l3.5-4.3v-2.7z" opacity=".3"/><path d="M4.8 12.5l7.2 9 3.5-4.4v-2.6c0-1.3.5-2.5 1.4-3.4C15.6 10.5 14 10 12 10c-4.1 0-6.8 2.2-7.2 2.5z"/></g> +<g id="signal-wifi-3-bar"><path fill-opacity=".3" d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/><path d="M3.53 10.95l8.46 10.54.01.01.01-.01 8.46-10.54C20.04 10.62 16.81 8 12 8c-4.81 0-8.04 2.62-8.47 2.95z"/></g> +<g id="signal-wifi-3-bar-lock"><path opacity=".3" d="M12 3C5.3 3 .8 6.7.4 7l3.2 3.9L12 21.5l3.5-4.3v-2.6c0-2.2 1.4-4 3.3-4.7.3-.1.5-.2.8-.2.3-.1.6-.1.9-.1.4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4z"/><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16zm-10 5.5l3.5-4.3v-2.6c0-2.2 1.4-4 3.3-4.7C17.3 9 14.9 8 12 8c-4.8 0-8 2.6-8.5 2.9"/></g> +<g id="signal-wifi-4-bar"><path d="M12.01 21.49L23.64 7c-.45-.34-4.93-4-11.64-4C5.28 3 .81 6.66.36 7l11.63 14.49.01.01.01-.01z"/></g> +<g id="signal-wifi-4-bar-lock"><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16zm-6.5-1.5c0-2.8 2.2-5 5-5 .4 0 .7 0 1 .1L23.6 7c-.4-.3-4.9-4-11.6-4C5.3 3 .8 6.7.4 7L12 21.5l3.5-4.4v-2.6z"/></g> +<g id="signal-wifi-off"><path d="M23.64 7c-.45-.34-4.93-4-11.64-4-1.5 0-2.89.19-4.15.48L18.18 13.8 23.64 7zm-6.6 8.22L3.27 1.44 2 2.72l2.05 2.06C1.91 5.76.59 6.82.36 7l11.63 14.49.01.01.01-.01 3.9-4.86 3.32 3.32 1.27-1.27-3.46-3.46z"/></g> +<g id="storage"><path d="M2 20h20v-4H2v4zm2-3h2v2H4v-2zM2 4v4h20V4H2zm4 3H4V5h2v2zm-4 7h20v-4H2v4zm2-3h2v2H4v-2z"/></g> +<g id="usb"><path d="M15 7v4h1v2h-3V5h2l-3-4-3 4h2v8H8v-2.07c.7-.37 1.2-1.08 1.2-1.93 0-1.21-.99-2.2-2.2-2.2-1.21 0-2.2.99-2.2 2.2 0 .85.5 1.56 1.2 1.93V13c0 1.11.89 2 2 2h3v3.05c-.71.37-1.2 1.1-1.2 1.95 0 1.22.99 2.2 2.2 2.2 1.21 0 2.2-.98 2.2-2.2 0-.85-.49-1.58-1.2-1.95V15h3c1.11 0 2-.89 2-2v-2h1V7h-4z"/></g> +<g id="wallpaper"><path d="M4 4h7V2H4c-1.1 0-2 .9-2 2v7h2V4zm6 9l-4 5h12l-3-4-2.03 2.71L10 13zm7-4.5c0-.83-.67-1.5-1.5-1.5S14 7.67 14 8.5s.67 1.5 1.5 1.5S17 9.33 17 8.5zM20 2h-7v2h7v7h2V4c0-1.1-.9-2-2-2zm0 18h-7v2h7c1.1 0 2-.9 2-2v-7h-2v7zM4 13H2v7c0 1.1.9 2 2 2h7v-2H4v-7z"/></g> +<g id="widgets"><path d="M13 13v8h8v-8h-8zM3 21h8v-8H3v8zM3 3v8h8V3H3zm13.66-1.31L11 7.34 16.66 13l5.66-5.66-5.66-5.65z"/></g> +<g id="wifi-lock"><path d="M20.5 9.5c.28 0 .55.04.81.08L24 6c-3.34-2.51-7.5-4-12-4S3.34 3.49 0 6l12 16 3.5-4.67V14.5c0-2.76 2.24-5 5-5zM23 16v-1.5c0-1.38-1.12-2.5-2.5-2.5S18 13.12 18 14.5V16c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1v-4c0-.55-.45-1-1-1zm-1 0h-3v-1.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V16z"/></g> +<g id="wifi-tethering"><path d="M12 11c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 2c0-3.31-2.69-6-6-6s-6 2.69-6 6c0 2.22 1.21 4.15 3 5.19l1-1.74c-1.19-.7-2-1.97-2-3.45 0-2.21 1.79-4 4-4s4 1.79 4 4c0 1.48-.81 2.75-2 3.45l1 1.74c1.79-1.04 3-2.97 3-5.19zM12 3C6.48 3 2 7.48 2 13c0 3.7 2.01 6.92 4.99 8.65l1-1.73C5.61 18.53 4 15.96 4 13c0-4.42 3.58-8 8-8s8 3.58 8 8c0 2.96-1.61 5.53-4 6.92l1 1.73c2.99-1.73 5-4.95 5-8.65 0-5.52-4.48-10-10-10z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/editor-icons.html b/third_party/polymer/v1_0/components/iron-icons/editor-icons.html new file mode 100644 index 0000000..7fabfe0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/editor-icons.html @@ -0,0 +1,70 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="editor" size="24"> +<svg><defs> +<g id="attach-file"><path d="M16.5 6v11.5c0 2.21-1.79 4-4 4s-4-1.79-4-4V5c0-1.38 1.12-2.5 2.5-2.5s2.5 1.12 2.5 2.5v10.5c0 .55-.45 1-1 1s-1-.45-1-1V6H10v9.5c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5V5c0-2.21-1.79-4-4-4S7 2.79 7 5v12.5c0 3.04 2.46 5.5 5.5 5.5s5.5-2.46 5.5-5.5V6h-1.5z"/></g> +<g id="attach-money"><path d="M11.8 10.9c-2.27-.59-3-1.2-3-2.15 0-1.09 1.01-1.85 2.7-1.85 1.78 0 2.44.85 2.5 2.1h2.21c-.07-1.72-1.12-3.3-3.21-3.81V3h-3v2.16c-1.94.42-3.5 1.68-3.5 3.61 0 2.31 1.91 3.46 4.7 4.13 2.5.6 3 1.48 3 2.41 0 .69-.49 1.79-2.7 1.79-2.06 0-2.87-.92-2.98-2.1h-2.2c.12 2.19 1.76 3.42 3.68 3.83V21h3v-2.15c1.95-.37 3.5-1.5 3.5-3.55 0-2.84-2.43-3.81-4.7-4.4z"/></g> +<g id="border-all"><path d="M3 3v18h18V3H3zm8 16H5v-6h6v6zm0-8H5V5h6v6zm8 8h-6v-6h6v6zm0-8h-6V5h6v6z"/></g> +<g id="border-bottom"><path d="M9 11H7v2h2v-2zm4 4h-2v2h2v-2zM9 3H7v2h2V3zm4 8h-2v2h2v-2zM5 3H3v2h2V3zm8 4h-2v2h2V7zm4 4h-2v2h2v-2zm-4-8h-2v2h2V3zm4 0h-2v2h2V3zm2 10h2v-2h-2v2zm0 4h2v-2h-2v2zM5 7H3v2h2V7zm14-4v2h2V3h-2zm0 6h2V7h-2v2zM5 11H3v2h2v-2zM3 21h18v-2H3v2zm2-6H3v2h2v-2z"/></g> +<g id="border-clear"><path d="M7 5h2V3H7v2zm0 8h2v-2H7v2zm0 8h2v-2H7v2zm4-4h2v-2h-2v2zm0 4h2v-2h-2v2zm-8 0h2v-2H3v2zm0-4h2v-2H3v2zm0-4h2v-2H3v2zm0-4h2V7H3v2zm0-4h2V3H3v2zm8 8h2v-2h-2v2zm8 4h2v-2h-2v2zm0-4h2v-2h-2v2zm0 8h2v-2h-2v2zm0-12h2V7h-2v2zm-8 0h2V7h-2v2zm8-6v2h2V3h-2zm-8 2h2V3h-2v2zm4 16h2v-2h-2v2zm0-8h2v-2h-2v2zm0-8h2V3h-2v2z"/></g> +<g id="border-color"><path d="M17.75 7L14 3.25l-10 10V17h3.75l10-10zm2.96-2.96c.39-.39.39-1.02 0-1.41L18.37.29c-.39-.39-1.02-.39-1.41 0L15 2.25 18.75 6l1.96-1.96z"/><path fill-opacity=".36" d="M0 20h24v4H0z"/></g> +<g id="border-horizontal"><path d="M3 21h2v-2H3v2zM5 7H3v2h2V7zM3 17h2v-2H3v2zm4 4h2v-2H7v2zM5 3H3v2h2V3zm4 0H7v2h2V3zm8 0h-2v2h2V3zm-4 4h-2v2h2V7zm0-4h-2v2h2V3zm6 14h2v-2h-2v2zm-8 4h2v-2h-2v2zm-8-8h18v-2H3v2zM19 3v2h2V3h-2zm0 6h2V7h-2v2zm-8 8h2v-2h-2v2zm4 4h2v-2h-2v2zm4 0h2v-2h-2v2z"/></g> +<g id="border-inner"><path d="M3 21h2v-2H3v2zm4 0h2v-2H7v2zM5 7H3v2h2V7zM3 17h2v-2H3v2zM9 3H7v2h2V3zM5 3H3v2h2V3zm12 0h-2v2h2V3zm2 6h2V7h-2v2zm0-6v2h2V3h-2zm-4 18h2v-2h-2v2zM13 3h-2v8H3v2h8v8h2v-8h8v-2h-8V3zm6 18h2v-2h-2v2zm0-4h2v-2h-2v2z"/></g> +<g id="border-left"><path d="M11 21h2v-2h-2v2zm0-4h2v-2h-2v2zm0-12h2V3h-2v2zm0 4h2V7h-2v2zm0 4h2v-2h-2v2zm-4 8h2v-2H7v2zM7 5h2V3H7v2zm0 8h2v-2H7v2zm-4 8h2V3H3v18zM19 9h2V7h-2v2zm-4 12h2v-2h-2v2zm4-4h2v-2h-2v2zm0-14v2h2V3h-2zm0 10h2v-2h-2v2zm0 8h2v-2h-2v2zm-4-8h2v-2h-2v2zm0-8h2V3h-2v2z"/></g> +<g id="border-outer"><path d="M13 7h-2v2h2V7zm0 4h-2v2h2v-2zm4 0h-2v2h2v-2zM3 3v18h18V3H3zm16 16H5V5h14v14zm-6-4h-2v2h2v-2zm-4-4H7v2h2v-2z"/></g> +<g id="border-right"><path d="M7 21h2v-2H7v2zM3 5h2V3H3v2zm4 0h2V3H7v2zm0 8h2v-2H7v2zm-4 8h2v-2H3v2zm8 0h2v-2h-2v2zm-8-8h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2V7H3v2zm8 8h2v-2h-2v2zm4-4h2v-2h-2v2zm4-10v18h2V3h-2zm-4 18h2v-2h-2v2zm0-16h2V3h-2v2zm-4 8h2v-2h-2v2zm0-8h2V3h-2v2zm0 4h2V7h-2v2z"/></g> +<g id="border-style"><path d="M15 21h2v-2h-2v2zm4 0h2v-2h-2v2zM7 21h2v-2H7v2zm4 0h2v-2h-2v2zm8-4h2v-2h-2v2zm0-4h2v-2h-2v2zM3 3v18h2V5h16V3H3zm16 6h2V7h-2v2z"/></g> +<g id="border-top"><path d="M7 21h2v-2H7v2zm0-8h2v-2H7v2zm4 0h2v-2h-2v2zm0 8h2v-2h-2v2zm-8-4h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2v-2H3v2zm0-4h2V7H3v2zm8 8h2v-2h-2v2zm8-8h2V7h-2v2zm0 4h2v-2h-2v2zM3 3v2h18V3H3zm16 14h2v-2h-2v2zm-4 4h2v-2h-2v2zM11 9h2V7h-2v2zm8 12h2v-2h-2v2zm-4-8h2v-2h-2v2z"/></g> +<g id="border-vertical"><path d="M3 9h2V7H3v2zm0-4h2V3H3v2zm4 16h2v-2H7v2zm0-8h2v-2H7v2zm-4 0h2v-2H3v2zm0 8h2v-2H3v2zm0-4h2v-2H3v2zM7 5h2V3H7v2zm12 12h2v-2h-2v2zm-8 4h2V3h-2v18zm8 0h2v-2h-2v2zm0-8h2v-2h-2v2zm0-10v2h2V3h-2zm0 6h2V7h-2v2zm-4-4h2V3h-2v2zm0 16h2v-2h-2v2zm0-8h2v-2h-2v2z"/></g> +<g id="format-align-center"><path d="M7 15v2h10v-2H7zm-4 6h18v-2H3v2zm0-8h18v-2H3v2zm4-6v2h10V7H7zM3 3v2h18V3H3z"/></g> +<g id="format-align-justify"><path d="M3 21h18v-2H3v2zm0-4h18v-2H3v2zm0-4h18v-2H3v2zm0-4h18V7H3v2zm0-6v2h18V3H3z"/></g> +<g id="format-align-left"><path d="M15 15H3v2h12v-2zm0-8H3v2h12V7zM3 13h18v-2H3v2zm0 8h18v-2H3v2zM3 3v2h18V3H3z"/></g> +<g id="format-align-right"><path d="M3 21h18v-2H3v2zm6-4h12v-2H9v2zm-6-4h18v-2H3v2zm6-4h12V7H9v2zM3 3v2h18V3H3z"/></g> +<g id="format-bold"><path d="M15.6 10.79c.97-.67 1.65-1.77 1.65-2.79 0-2.26-1.75-4-4-4H7v14h7.04c2.09 0 3.71-1.7 3.71-3.79 0-1.52-.86-2.82-2.15-3.42zM10 6.5h3c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5h-3v-3zm3.5 9H10v-3h3.5c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5z"/></g> +<g id="format-clear"><path d="M3.27 5L2 6.27l6.97 6.97L6.5 19h3l1.57-3.66L16.73 21 18 19.73 3.55 5.27 3.27 5zM6 5v.18L8.82 8h2.4l-.72 1.68 2.1 2.1L14.21 8H20V5H6z"/></g> +<g id="format-color-fill"><path d="M16.56 8.94L7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.59-.59 1.54 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.58.59-1.53 0-2.12zM5.21 10L10 5.21 14.79 10H5.21zM19 11.5s-2 2.17-2 3.5c0 1.1.9 2 2 2s2-.9 2-2c0-1.33-2-3.5-2-3.5z"/><path fill-opacity=".36" d="M0 20h24v4H0z"/></g> +<g id="format-color-reset"><path d="M18 14c0-4-6-10.8-6-10.8s-1.33 1.51-2.73 3.52l8.59 8.59c.09-.42.14-.86.14-1.31zm-.88 3.12L12.5 12.5 5.27 5.27 4 6.55l3.32 3.32C6.55 11.32 6 12.79 6 14c0 3.31 2.69 6 6 6 1.52 0 2.9-.57 3.96-1.5l2.63 2.63 1.27-1.27-2.74-2.74z"/></g> +<g id="format-color-text"><path fill-opacity=".36" d="M0 20h24v4H0z"/><path d="M11 3L5.5 17h2.25l1.12-3h6.25l1.12 3h2.25L13 3h-2zm-1.38 9L12 5.67 14.38 12H9.62z"/></g> +<g id="format-indent-decrease"><path d="M11 17h10v-2H11v2zm-8-5l4 4V8l-4 4zm0 9h18v-2H3v2zM3 3v2h18V3H3zm8 6h10V7H11v2zm0 4h10v-2H11v2z"/></g> +<g id="format-indent-increase"><path d="M3 21h18v-2H3v2zM3 8v8l4-4-4-4zm8 9h10v-2H11v2zM3 3v2h18V3H3zm8 6h10V7H11v2zm0 4h10v-2H11v2z"/></g> +<g id="format-italic"><path d="M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4z"/></g> +<g id="format-line-spacing"><path d="M6 7h2.5L5 3.5 1.5 7H4v10H1.5L5 20.5 8.5 17H6V7zm4-2v2h12V5H10zm0 14h12v-2H10v2zm0-6h12v-2H10v2z"/></g> +<g id="format-list-bulleted"><path d="M4 10.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm0-6c-.83 0-1.5.67-1.5 1.5S3.17 7.5 4 7.5 5.5 6.83 5.5 6 4.83 4.5 4 4.5zm0 12.17c-.74 0-1.33.6-1.33 1.33s.6 1.33 1.33 1.33 1.33-.6 1.33-1.33-.59-1.33-1.33-1.33zM7 19h14v-2H7v2zm0-6h14v-2H7v2zm0-8v2h14V5H7z"/></g> +<g id="format-list-numbered"><path d="M2 17h2v.5H3v1h1v.5H2v1h3v-4H2v1zm1-9h1V4H2v1h1v3zm-1 3h1.8L2 13.1v.9h3v-1H3.2L5 10.9V10H2v1zm5-6v2h14V5H7zm0 14h14v-2H7v2zm0-6h14v-2H7v2z"/></g> +<g id="format-paint"><path d="M18 4V3c0-.55-.45-1-1-1H5c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h12c.55 0 1-.45 1-1V6h1v4H9v11c0 .55.45 1 1 1h2c.55 0 1-.45 1-1v-9h8V4h-3z"/></g> +<g id="format-quote"><path d="M6 17h3l2-4V7H5v6h3zm8 0h3l2-4V7h-6v6h3z"/></g> +<g id="format-size"><path d="M9 4v3h5v12h3V7h5V4H9zm-6 8h3v7h3v-7h3V9H3v3z"/></g> +<g id="format-strikethrough"><path d="M10 19h4v-3h-4v3zM5 4v3h5v3h4V7h5V4H5zM3 14h18v-2H3v2z"/></g> +<g id="format-textdirection-l-to-r"><path d="M9 10v5h2V4h2v11h2V4h2V2H9C6.79 2 5 3.79 5 6s1.79 4 4 4zm12 8l-4-4v3H5v2h12v3l4-4z"/></g> +<g id="format-textdirection-r-to-l"><path d="M10 10v5h2V4h2v11h2V4h2V2h-8C7.79 2 6 3.79 6 6s1.79 4 4 4zm-2 7v-3l-4 4 4 4v-3h12v-2H8z"/></g> +<g id="format-underlined"><path d="M12 17c3.31 0 6-2.69 6-6V3h-2.5v8c0 1.93-1.57 3.5-3.5 3.5S8.5 12.93 8.5 11V3H6v8c0 3.31 2.69 6 6 6zm-7 2v2h14v-2H5z"/></g> +<g id="functions"><path d="M18 4H6v2l6.5 6L6 18v2h12v-3h-7l5-5-5-5h7z"/></g> +<g id="insert-chart"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/></g> +<g id="insert-comment"><path d="M20 2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4V4c0-1.1-.9-2-2-2zm-2 12H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z"/></g> +<g id="insert-drive-file"><path d="M6 2c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6H6zm7 7V3.5L18.5 9H13z"/></g> +<g id="insert-emoticon"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 6.5c2.33 0 4.31-1.46 5.11-3.5H6.89c.8 2.04 2.78 3.5 5.11 3.5z"/></g> +<g id="insert-invitation"><path d="M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"/></g> +<g id="insert-link"><path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/></g> +<g id="insert-photo"><path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/></g> +<g id="merge-type"><path d="M17 20.41L18.41 19 15 15.59 13.59 17 17 20.41zM7.5 8H11v5.59L5.59 19 7 20.41l6-6V8h3.5L12 3.5 7.5 8z"/></g> +<g id="mode-comment"><path d="M21.99 4c0-1.1-.89-2-1.99-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4-.01-18z"/></g> +<g id="mode-edit"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"/></g> +<g id="money-off"><path d="M12.5 6.9c1.78 0 2.44.85 2.5 2.1h2.21c-.07-1.72-1.12-3.3-3.21-3.81V3h-3v2.16c-.53.12-1.03.3-1.48.54l1.47 1.47c.41-.17.91-.27 1.51-.27zM5.33 4.06L4.06 5.33 7.5 8.77c0 2.08 1.56 3.21 3.91 3.91l3.51 3.51c-.34.48-1.05.91-2.42.91-2.06 0-2.87-.92-2.98-2.1h-2.2c.12 2.19 1.76 3.42 3.68 3.83V21h3v-2.15c.96-.18 1.82-.55 2.45-1.12l2.22 2.22 1.27-1.27L5.33 4.06z"/></g> +<g id="publish"><path d="M5 4v2h14V4H5zm0 10h4v6h6v-6h4l-7-7-7 7z"/></g> +<g id="space-bar"><path d="M18 9v4H6V9H4v6h16V9z"/></g> +<g id="strikethrough-s"><path d="M5.9 10h6.3c-.8-.3-1.5-.6-2-.9-.7-.4-1-1-1-1.6 0-.3.1-.6.2-.9.1-.3.3-.5.6-.7.3-.2.6-.4 1-.5.4-.1.8-.2 1.4-.2.5 0 1 .1 1.4.2.4.1.7.3 1 .6.3.2.5.5.6.9.1.3.2.7.2 1.1h4c0-.9-.2-1.7-.5-2.4s-.8-1.4-1.4-1.9c-.6-.5-1.4-1-2.3-1.2-1-.4-2-.5-3.1-.5s-2 .1-2.9.4c-.9.3-1.6.6-2.3 1.1-.6.5-1.1 1-1.4 1.7-.4.7-.6 1.4-.6 2.2 0 .8.2 1.6.5 2.2.1.2.2.3.3.4zM23 12H1v2h11.9c.2.1.5.2.7.3.5.2.9.5 1.2.7.3.2.5.5.6.8.1.3.1.6.1.9 0 .3-.1.6-.2.9-.1.3-.3.5-.6.7-.2.2-.6.3-.9.5-.4.1-.8.2-1.4.2-.6 0-1.1-.1-1.6-.2s-.9-.3-1.2-.6c-.3-.3-.6-.6-.8-1-.2-.4-.3-1-.3-1.6h-4c0 .7.1 1.5.3 2.1.2.6.5 1.1.9 1.6s.8.9 1.3 1.2c.5.3 1 .6 1.6.9.6.2 1.2.4 1.8.5.6.1 1.3.2 1.9.2 1.1 0 2-.1 2.9-.4.9-.2 1.6-.6 2.2-1.1.6-.5 1.1-1 1.4-1.7.3-.7.5-1.4.5-2.3 0-.8-.1-1.5-.4-2.2-.1-.2-.1-.3-.2-.4H23v-2z"/></g> +<g id="vertical-align-bottom"><path d="M16 13h-3V3h-2v10H8l4 4 4-4zM4 19v2h16v-2H4z"/></g> +<g id="vertical-align-center"><path d="M8 19h3v4h2v-4h3l-4-4-4 4zm8-14h-3V1h-2v4H8l4 4 4-4zM4 11v2h16v-2H4z"/></g> +<g id="vertical-align-top"><path d="M8 11h3v10h2V11h3l-4-4-4 4zM4 3v2h16V3H4z"/></g> +<g id="wrap-text"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/hardware-icons.html b/third_party/polymer/v1_0/components/iron-icons/hardware-icons.html new file mode 100644 index 0000000..670cb07 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/hardware-icons.html @@ -0,0 +1,61 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="hardware" size="24"> +<svg><defs> +<g id="cast"><path d="M21 3H3c-1.1 0-2 .9-2 2v3h2V5h18v14h-7v2h7c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM1 18v3h3c0-1.66-1.34-3-3-3zm0-4v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm0-4v2c4.97 0 9 4.03 9 9h2c0-6.08-4.93-11-11-11z"/></g> +<g id="cast-connected"><path d="M1 18v3h3c0-1.66-1.34-3-3-3zm0-4v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm18-7H5v1.63c3.96 1.28 7.09 4.41 8.37 8.37H19V7zM1 10v2c4.97 0 9 4.03 9 9h2c0-6.08-4.93-11-11-11zm20-7H3c-1.1 0-2 .9-2 2v3h2V5h18v14h-7v2h7c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="computer"><path d="M20 18c1.1 0 1.99-.9 1.99-2L22 6c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2H0v2h24v-2h-4zM4 6h16v10H4V6z"/></g> +<g id="desktop-mac"><path d="M21 2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7l-2 3v1h8v-1l-2-3h7c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 12H3V4h18v10z"/></g> +<g id="desktop-windows"><path d="M21 2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7v2H8v2h8v-2h-2v-2h7c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H3V4h18v12z"/></g> +<g id="developer-board"><path d="M22 9V7h-2V5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-2h2v-2h-2v-2h2v-2h-2V9h2zm-4 10H4V5h14v14zM6 13h5v4H6zm6-6h4v3h-4zM6 7h5v5H6zm6 4h4v6h-4z"/></g> +<g id="device-hub"><path d="M17 16l-4-4V8.82C14.16 8.4 15 7.3 15 6c0-1.66-1.34-3-3-3S9 4.34 9 6c0 1.3.84 2.4 2 2.82V12l-4 4H3v5h5v-3.05l4-4.2 4 4.2V21h5v-5h-4z"/></g> +<g id="dock"><path d="M8 23h8v-2H8v2zm8-21.99L8 1c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM16 15H8V5h8v10z"/></g> +<g id="gamepad"><path d="M15 7.5V2H9v5.5l3 3 3-3zM7.5 9H2v6h5.5l3-3-3-3zM9 16.5V22h6v-5.5l-3-3-3 3zM16.5 9l-3 3 3 3H22V9h-5.5z"/></g> +<g id="headset"><path d="M12 1c-4.97 0-9 4.03-9 9v7c0 1.66 1.34 3 3 3h3v-8H5v-2c0-3.87 3.13-7 7-7s7 3.13 7 7v2h-4v8h3c1.66 0 3-1.34 3-3v-7c0-4.97-4.03-9-9-9z"/></g> +<g id="headset-mic"><path d="M12 1c-4.97 0-9 4.03-9 9v7c0 1.66 1.34 3 3 3h3v-8H5v-2c0-3.87 3.13-7 7-7s7 3.13 7 7v2h-4v8h4v1h-7v2h6c1.66 0 3-1.34 3-3V10c0-4.97-4.03-9-9-9z"/></g> +<g id="keyboard"><path d="M20 5H4c-1.1 0-1.99.9-1.99 2L2 17c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-9 3h2v2h-2V8zm0 3h2v2h-2v-2zM8 8h2v2H8V8zm0 3h2v2H8v-2zm-1 2H5v-2h2v2zm0-3H5V8h2v2zm9 7H8v-2h8v2zm0-4h-2v-2h2v2zm0-3h-2V8h2v2zm3 3h-2v-2h2v2zm0-3h-2V8h2v2z"/></g> +<g id="keyboard-arrow-down"><path d="M7.41 7.84L12 12.42l4.59-4.58L18 9.25l-6 6-6-6z"/></g> +<g id="keyboard-arrow-left"><path d="M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"/></g> +<g id="keyboard-arrow-right"><path d="M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"/></g> +<g id="keyboard-arrow-up"><path d="M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6-6 6z"/></g> +<g id="keyboard-backspace"><path d="M21 11H6.83l3.58-3.59L9 6l-6 6 6 6 1.41-1.41L6.83 13H21z"/></g> +<g id="keyboard-capslock"><path d="M12 8.41L16.59 13 18 11.59l-6-6-6 6L7.41 13 12 8.41zM6 18h12v-2H6v2z"/></g> +<g id="keyboard-hide"><path d="M20 3H4c-1.1 0-1.99.9-1.99 2L2 15c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-9 3h2v2h-2V6zm0 3h2v2h-2V9zM8 6h2v2H8V6zm0 3h2v2H8V9zm-1 2H5V9h2v2zm0-3H5V6h2v2zm9 7H8v-2h8v2zm0-4h-2V9h2v2zm0-3h-2V6h2v2zm3 3h-2V9h2v2zm0-3h-2V6h2v2zm-7 15l4-4H8l4 4z"/></g> +<g id="keyboard-return"><path d="M19 7v4H5.83l3.58-3.59L8 6l-6 6 6 6 1.41-1.41L5.83 13H21V7z"/></g> +<g id="keyboard-tab"><path d="M11.59 7.41L15.17 11H1v2h14.17l-3.59 3.59L13 18l6-6-6-6-1.41 1.41zM20 6v12h2V6h-2z"/></g> +<g id="keyboard-voice"><path d="M12 15c1.66 0 2.99-1.34 2.99-3L15 6c0-1.66-1.34-3-3-3S9 4.34 9 6v6c0 1.66 1.34 3 3 3zm5.3-3c0 3-2.54 5.1-5.3 5.1S6.7 15 6.7 12H5c0 3.42 2.72 6.23 6 6.72V22h2v-3.28c3.28-.48 6-3.3 6-6.72h-1.7z"/></g> +<g id="laptop"><path d="M20 18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2H0v2h24v-2h-4zM4 6h16v10H4V6z"/></g> +<g id="laptop-chromebook"><path d="M22 18V3H2v15H0v2h24v-2h-2zm-8 0h-4v-1h4v1zm6-3H4V5h16v10z"/></g> +<g id="laptop-mac"><path d="M20 18c1.1 0 1.99-.9 1.99-2L22 5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v11c0 1.1.9 2 2 2H0c0 1.1.9 2 2 2h20c1.1 0 2-.9 2-2h-4zM4 5h16v11H4V5zm8 14c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="laptop-windows"><path d="M20 18v-1c1.1 0 1.99-.9 1.99-2L22 5c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2v1H0v2h24v-2h-4zM4 5h16v10H4V5z"/></g> +<g id="memory"><path d="M15 9H9v6h6V9zm-2 4h-2v-2h2v2zm8-2V9h-2V7c0-1.1-.9-2-2-2h-2V3h-2v2h-2V3H9v2H7c-1.1 0-2 .9-2 2v2H3v2h2v2H3v2h2v2c0 1.1.9 2 2 2h2v2h2v-2h2v2h2v-2h2c1.1 0 2-.9 2-2v-2h2v-2h-2v-2h2zm-4 6H7V7h10v10z"/></g> +<g id="mouse"><path d="M13 1.07V9h7c0-4.08-3.05-7.44-7-7.93zM4 15c0 4.42 3.58 8 8 8s8-3.58 8-8v-4H4v4zm7-13.93C7.05 1.56 4 4.92 4 9h7V1.07z"/></g> +<g id="phone-android"><path d="M16 1H8C6.34 1 5 2.34 5 4v16c0 1.66 1.34 3 3 3h8c1.66 0 3-1.34 3-3V4c0-1.66-1.34-3-3-3zm-2 20h-4v-1h4v1zm3.25-3H6.75V4h10.5v14z"/></g> +<g id="phone-iphone"><path d="M15.5 1h-8C6.12 1 5 2.12 5 3.5v17C5 21.88 6.12 23 7.5 23h8c1.38 0 2.5-1.12 2.5-2.5v-17C18 2.12 16.88 1 15.5 1zm-4 21c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm4.5-4H7V4h9v14z"/></g> +<g id="phonelink"><path d="M4 6h18V4H4c-1.1 0-2 .9-2 2v11H0v3h14v-3H4V6zm19 2h-6c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zm-1 9h-4v-7h4v7z"/></g> +<g id="phonelink-off"><path d="M22 6V4H6.82l2 2H22zM1.92 1.65L.65 2.92l1.82 1.82C2.18 5.08 2 5.52 2 6v11H0v3h17.73l2.35 2.35 1.27-1.27L3.89 3.62 1.92 1.65zM4 6.27L14.73 17H4V6.27zM23 8h-6c-.55 0-1 .45-1 1v4.18l2 2V10h4v7h-2.18l3 3H23c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1z"/></g> +<g id="power-input"><path d="M2 9v2h19V9H2zm0 6h5v-2H2v2zm7 0h5v-2H9v2zm7 0h5v-2h-5v2z"/></g> +<g id="router"><path d="M20.2 5.9l.8-.8C19.6 3.7 17.8 3 16 3s-3.6.7-5 2.1l.8.8C13 4.8 14.5 4.2 16 4.2s3 .6 4.2 1.7zm-.9.8c-.9-.9-2.1-1.4-3.3-1.4s-2.4.5-3.3 1.4l.8.8c.7-.7 1.6-1 2.5-1 .9 0 1.8.3 2.5 1l.8-.8zM19 13h-2V9h-2v4H5c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-4c0-1.1-.9-2-2-2zM8 18H6v-2h2v2zm3.5 0h-2v-2h2v2zm3.5 0h-2v-2h2v2z"/></g> +<g id="scanner"><path d="M19.8 10.7L4.2 5l-.7 1.9L17.6 12H5c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-5.5c0-.8-.5-1.6-1.2-1.8zM7 17H5v-2h2v2zm12 0H9v-2h10v2z"/></g> +<g id="security"><path d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 10.99h7c-.53 4.12-3.28 7.79-7 8.94V12H5V6.3l7-3.11v8.8z"/></g> +<g id="sim-card"><path d="M19.99 4c0-1.1-.89-2-1.99-2h-8L4 8v12c0 1.1.9 2 2 2h12.01c1.1 0 1.99-.9 1.99-2l-.01-16zM9 19H7v-2h2v2zm8 0h-2v-2h2v2zm-8-4H7v-4h2v4zm4 4h-2v-4h2v4zm0-6h-2v-2h2v2zm4 2h-2v-4h2v4z"/></g> +<g id="smartphone"><path d="M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="speaker"><path d="M17 2H7c-1.1 0-2 .9-2 2v16c0 1.1.9 1.99 2 1.99L17 22c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5 2c1.1 0 2 .9 2 2s-.9 2-2 2c-1.11 0-2-.9-2-2s.89-2 2-2zm0 16c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="speaker-group"><path d="M18.2 1H9.8C8.81 1 8 1.81 8 2.8v14.4c0 .99.81 1.79 1.8 1.79l8.4.01c.99 0 1.8-.81 1.8-1.8V2.8c0-.99-.81-1.8-1.8-1.8zM14 3c1.1 0 2 .89 2 2s-.9 2-2 2-2-.89-2-2 .9-2 2-2zm0 13.5c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"/><circle cx="14" cy="12.5" r="2.5"/><path d="M6 5H4v16c0 1.1.89 2 2 2h10v-2H6V5z"/></g> +<g id="tablet"><path d="M21 4H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h18c1.1 0 1.99-.9 1.99-2L23 6c0-1.1-.9-2-2-2zm-2 14H5V6h14v12z"/></g> +<g id="tablet-android"><path d="M18 0H6C4.34 0 3 1.34 3 3v18c0 1.66 1.34 3 3 3h12c1.66 0 3-1.34 3-3V3c0-1.66-1.34-3-3-3zm-4 22h-4v-1h4v1zm5.25-3H4.75V3h14.5v16z"/></g> +<g id="tablet-mac"><path d="M18.5 0h-14C3.12 0 2 1.12 2 2.5v19C2 22.88 3.12 24 4.5 24h14c1.38 0 2.5-1.12 2.5-2.5v-19C21 1.12 19.88 0 18.5 0zm-7 23c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm7.5-4H4V3h15v16z"/></g> +<g id="toys"><path d="M12 12c0-3 2.5-5.5 5.5-5.5S23 9 23 12H12zm0 0c0 3-2.5 5.5-5.5 5.5S1 15 1 12h11zm0 0c-3 0-5.5-2.5-5.5-5.5S9 1 12 1v11zm0 0c3 0 5.5 2.5 5.5 5.5S15 23 12 23V12z"/></g> +<g id="tv"><path d="M21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.1-.9-2-2-2zm0 14H3V5h18v12z"/></g> +<g id="watch"><path d="M20 12c0-2.54-1.19-4.81-3.04-6.27L16 0H8l-.95 5.73C5.19 7.19 4 9.45 4 12s1.19 4.81 3.05 6.27L8 24h8l.96-5.73C18.81 16.81 20 14.54 20 12zM6 12c0-3.31 2.69-6 6-6s6 2.69 6 6-2.69 6-6 6-6-2.69-6-6z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/hero.svg b/third_party/polymer/v1_0/components/iron-icons/hero.svg new file mode 100644 index 0000000..167321c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/hero.svg @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="73" cy="24" r="4"/> + <path d="M82,33H64V15h18V33z M66,31h14V17H66V31z"/> + <circle cx="112.5" cy="24" r="4"/> + <circle cx="151" cy="24" r="4"/> + <path d="M121,33h-18V15h18V33z M105,31h14V17h-14V31z"/> + <path d="M160,33h-18V15h18V33z M144,31h14V17h-14V31z"/> + <circle cx="73" cy="62" r="4"/> + <path d="M82,71H64V53h18V71z M66,69h14V55H66V69z"/> + <circle cx="112.5" cy="62" r="4"/> + <path d="M121,71h-18V53h18V71z M105,69h14V55h-14V69z"/> + <circle cx="151" cy="62" r="4"/> + <path d="M160,71h-18V53h18V71z M144,69h14V55h-14V69z"/> + <circle cx="73" cy="102" r="4"/> + <path d="M82,111H64V93h18V111z M66,109h14V95H66V109z"/> + <circle cx="112.5" cy="102" r="4"/> + <path d="M121,111h-18V93h18V111z M105,109h14V95h-14V109z"/> + <circle cx="151" cy="102" r="4"/> + <path d="M160,111h-18V93h18V111z M144,109h14V95h-14V109z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/image-icons.html b/third_party/polymer/v1_0/components/iron-icons/image-icons.html new file mode 100644 index 0000000..f6c45f5 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/image-icons.html @@ -0,0 +1,164 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="image" size="24"> +<svg><defs> +<g id="add-to-photos"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/></g> +<g id="adjust"><path d="M12 2C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm3-8c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3z"/></g> +<g id="assistant"><path d="M19 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h4l3 3 3-3h4c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5.12 10.88L12 17l-1.88-4.12L6 11l4.12-1.88L12 5l1.88 4.12L18 11l-4.12 1.88z"/></g> +<g id="assistant-photo"><path d="M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6z"/></g> +<g id="audiotrack"><path d="M12 3v9.28c-.47-.17-.97-.28-1.5-.28C8.01 12 6 14.01 6 16.5S8.01 21 10.5 21c2.31 0 4.2-1.75 4.45-4H15V6h4V3h-7z"/></g> +<g id="blur-circular"><path d="M10 9c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zM7 9.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm3 7c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm-3-3c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm3-6c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM14 9c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-1.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm3 6c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm0-4c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm2-3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm0-3.5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1z"/></g> +<g id="blur-linear"><path d="M5 17.5c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5-1.5.67-1.5 1.5.67 1.5 1.5 1.5zM9 13c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zM3 21h18v-2H3v2zM5 9.5c.83 0 1.5-.67 1.5-1.5S5.83 6.5 5 6.5 3.5 7.17 3.5 8 4.17 9.5 5 9.5zm0 4c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5-1.5.67-1.5 1.5.67 1.5 1.5 1.5zM9 17c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm8-.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM3 3v2h18V3H3zm14 5.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm0 4c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM13 9c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0 4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0 4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1z"/></g> +<g id="blur-off"><path d="M14 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm-.2 4.48l.2.02c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5-1.5.67-1.5 1.5l.02.2c.09.67.61 1.19 1.28 1.28zM14 3.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm-4 0c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm11 7c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM10 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm8 8c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-4c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm-4 13.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM2.5 5.27l3.78 3.78L6 9c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1c0-.1-.03-.19-.06-.28l2.81 2.81c-.71.11-1.25.73-1.25 1.47 0 .83.67 1.5 1.5 1.5.74 0 1.36-.54 1.47-1.25l2.81 2.81c-.09-.03-.18-.06-.28-.06-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1c0-.1-.03-.19-.06-.28l3.78 3.78L20 20.23 3.77 4 2.5 5.27zM10 17c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm11-3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM6 13c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zM3 9.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm7 11c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM6 17c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm-3-3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5z"/></g> +<g id="blur-on"><path d="M6 13c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-8c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm-3 .5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM6 5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm15 5.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM14 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0-3.5c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zm-11 10c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm7 7c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm0-17c.28 0 .5-.22.5-.5s-.22-.5-.5-.5-.5.22-.5.5.22.5.5.5zM10 7c.55 0 1-.45 1-1s-.45-1-1-1-1 .45-1 1 .45 1 1 1zm0 5.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm8 .5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-8c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0-4c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm3 8.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zM14 17c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm0 3.5c-.28 0-.5.22-.5.5s.22.5.5.5.5-.22.5-.5-.22-.5-.5-.5zm-4-12c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm0 8.5c-.55 0-1 .45-1 1s.45 1 1 1 1-.45 1-1-.45-1-1-1zm4-4.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm0-4c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5z"/></g> +<g id="brightness-1"><circle cx="12" cy="12" r="10"/></g> +<g id="brightness-2"><path d="M10 2c-1.82 0-3.53.5-5 1.35C7.99 5.08 10 8.3 10 12s-2.01 6.92-5 8.65C6.47 21.5 8.18 22 10 22c5.52 0 10-4.48 10-10S15.52 2 10 2z"/></g> +<g id="brightness-3"><path d="M9 2c-1.05 0-2.05.16-3 .46 4.06 1.27 7 5.06 7 9.54 0 4.48-2.94 8.27-7 9.54.95.3 1.95.46 3 .46 5.52 0 10-4.48 10-10S14.52 2 9 2z"/></g> +<g id="brightness-4"><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-.89 0-1.74-.2-2.5-.55C11.56 16.5 13 14.42 13 12s-1.44-4.5-3.5-5.45C10.26 6.2 11.11 6 12 6c3.31 0 6 2.69 6 6s-2.69 6-6 6z"/></g> +<g id="brightness-5"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6z"/></g> +<g id="brightness-6"><path d="M20 15.31L23.31 12 20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69zM12 18V6c3.31 0 6 2.69 6 6s-2.69 6-6 6z"/></g> +<g id="brightness-7"><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6zm0-10c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4z"/></g> +<g id="broken-image"><path d="M21 5v6.59l-3-3.01-4 4.01-4-4-4 4-3-3.01V5c0-1.1.9-2 2-2h14c1.1 0 2 .9 2 2zm-3 6.42l3 3.01V19c0 1.1-.9 2-2 2H5c-1.1 0-2-.9-2-2v-6.58l3 2.99 4-4 4 4 4-3.99z"/></g> +<g id="brush"><path d="M7 14c-1.66 0-3 1.34-3 3 0 1.31-1.16 2-2 2 .92 1.22 2.49 2 4 2 2.21 0 4-1.79 4-4 0-1.66-1.34-3-3-3zm13.71-9.37l-1.34-1.34c-.39-.39-1.02-.39-1.41 0L9 12.25 11.75 15l8.96-8.96c.39-.39.39-1.02 0-1.41z"/></g> +<g id="camera"><path d="M9.4 10.5l4.77-8.26C13.47 2.09 12.75 2 12 2c-2.4 0-4.6.85-6.32 2.25l3.66 6.35.06-.1zM21.54 9c-.92-2.92-3.15-5.26-6-6.34L11.88 9h9.66zm.26 1h-7.49l.29.5 4.76 8.25C21 16.97 22 14.61 22 12c0-.69-.07-1.35-.2-2zM8.54 12l-3.9-6.75C3.01 7.03 2 9.39 2 12c0 .69.07 1.35.2 2h7.49l-1.15-2zm-6.08 3c.92 2.92 3.15 5.26 6 6.34L12.12 15H2.46zm11.27 0l-3.9 6.76c.7.15 1.42.24 2.17.24 2.4 0 4.6-.85 6.32-2.25l-3.66-6.35-.93 1.6z"/></g> +<g id="camera-alt"><circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"/></g> +<g id="camera-front"><path d="M10 20H5v2h5v2l3-3-3-3v2zm4 0v2h5v-2h-5zM12 8c1.1 0 2-.9 2-2s-.9-2-2-2-1.99.9-1.99 2S10.9 8 12 8zm5-8H7C5.9 0 5 .9 5 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V2c0-1.1-.9-2-2-2zM7 2h10v10.5c0-1.67-3.33-2.5-5-2.5s-5 .83-5 2.5V2z"/></g> +<g id="camera-rear"><path d="M10 20H5v2h5v2l3-3-3-3v2zm4 0v2h5v-2h-5zm3-20H7C5.9 0 5 .9 5 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V2c0-1.1-.9-2-2-2zm-5 6c-1.11 0-2-.9-2-2s.89-2 1.99-2 2 .9 2 2C14 5.1 13.1 6 12 6z"/></g> +<g id="camera-roll"><path d="M14 5c0-1.1-.9-2-2-2h-1V2c0-.55-.45-1-1-1H6c-.55 0-1 .45-1 1v1H4c-1.1 0-2 .9-2 2v15c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2h8V5h-8zm-2 13h-2v-2h2v2zm0-9h-2V7h2v2zm4 9h-2v-2h2v2zm0-9h-2V7h2v2zm4 9h-2v-2h2v2zm0-9h-2V7h2v2z"/></g> +<g id="center-focus-strong"><path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm-7 7H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4z"/></g> +<g id="center-focus-weak"><path d="M5 15H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zM12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="collections"><path d="M22 16V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2zm-11-4l2.03 2.71L16 11l4 5H8l3-4zM2 6v14c0 1.1.9 2 2 2h14v-2H4V6H2z"/></g> +<g id="collections-bookmark"><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zM20 2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 10l-2.5-1.5L15 12V4h5v8z"/></g> +<g id="color-lens"><path d="M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9c.83 0 1.5-.67 1.5-1.5 0-.39-.15-.74-.39-1.01-.23-.26-.38-.61-.38-.99 0-.83.67-1.5 1.5-1.5H16c2.76 0 5-2.24 5-5 0-4.42-4.03-8-9-8zm-5.5 9c-.83 0-1.5-.67-1.5-1.5S5.67 9 6.5 9 8 9.67 8 10.5 7.33 12 6.5 12zm3-4C8.67 8 8 7.33 8 6.5S8.67 5 9.5 5s1.5.67 1.5 1.5S10.33 8 9.5 8zm5 0c-.83 0-1.5-.67-1.5-1.5S13.67 5 14.5 5s1.5.67 1.5 1.5S15.33 8 14.5 8zm3 4c-.83 0-1.5-.67-1.5-1.5S16.67 9 17.5 9s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="colorize"><path d="M20.71 5.63l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-3.12 3.12-1.93-1.91-1.41 1.41 1.42 1.42L3 16.25V21h4.75l8.92-8.92 1.42 1.42 1.41-1.41-1.92-1.92 3.12-3.12c.4-.4.4-1.03.01-1.42zM6.92 19L5 17.08l8.06-8.06 1.92 1.92L6.92 19z"/></g> +<g id="compare"><path d="M10 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h5v2h2V1h-2v2zm0 15H5l5-6v6zm9-15h-5v2h5v13l-5-6v9h5c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="control-point"><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.49 2 2 6.49 2 12s4.49 10 10 10 10-4.49 10-10S17.51 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="control-point-duplicate"><path d="M16 8h-2v3h-3v2h3v3h2v-3h3v-2h-3zM2 12c0-2.79 1.64-5.2 4.01-6.32V3.52C2.52 4.76 0 8.09 0 12s2.52 7.24 6.01 8.48v-2.16C3.64 17.2 2 14.79 2 12zm13-9c-4.96 0-9 4.04-9 9s4.04 9 9 9 9-4.04 9-9-4.04-9-9-9zm0 16c-3.86 0-7-3.14-7-7s3.14-7 7-7 7 3.14 7 7-3.14 7-7 7z"/></g> +<g id="crop"><path d="M17 15h2V7c0-1.1-.9-2-2-2H9v2h8v8zM7 17V1H5v4H1v2h4v10c0 1.1.9 2 2 2h10v4h2v-4h4v-2H7z"/></g> +<g id="crop-16-9"><path d="M19 6H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 10H5V8h14v8z"/></g> +<g id="crop-3-2"><path d="M19 4H5c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H5V6h14v12z"/></g> +<g id="crop-5-4"><path d="M19 5H5c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 12H5V7h14v10z"/></g> +<g id="crop-7-5"><path d="M19 7H5c-1.1 0-2 .9-2 2v6c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2zm0 8H5V9h14v6z"/></g> +<g id="crop-din"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/></g> +<g id="crop-free"><path d="M3 5v4h2V5h4V3H5c-1.1 0-2 .9-2 2zm2 10H3v4c0 1.1.9 2 2 2h4v-2H5v-4zm14 4h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zm0-16h-4v2h4v4h2V5c0-1.1-.9-2-2-2z"/></g> +<g id="crop-landscape"><path d="M19 5H5c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 12H5V7h14v10z"/></g> +<g id="crop-original"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14zm-5.04-6.71l-2.75 3.54-1.96-2.36L6.5 17h11l-3.54-4.71z"/></g> +<g id="crop-portrait"><path d="M17 3H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H7V5h10v14z"/></g> +<g id="crop-square"><path d="M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H6V6h12v12z"/></g> +<g id="dehaze"><path d="M2 15.5v2h20v-2H2zm0-5v2h20v-2H2zm0-5v2h20v-2H2z"/></g> +<g id="details"><path d="M3 4l9 16 9-16H3zm3.38 2h11.25L12 16 6.38 6z"/></g> +<g id="edit"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"/></g> +<g id="exposure"><path d="M15 17v2h2v-2h2v-2h-2v-2h-2v2h-2v2h2zm5-15H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM5 5h6v2H5V5zm15 15H4L20 4v16z"/></g> +<g id="exposure-neg-1"><path d="M4 11v2h8v-2H4zm15 7h-2V7.38L14 8.4V6.7L18.7 5h.3v13z"/></g> +<g id="exposure-neg-2"><path d="M15.05 16.29l2.86-3.07c.38-.39.72-.79 1.04-1.18.32-.39.59-.78.82-1.17.23-.39.41-.78.54-1.17s.19-.79.19-1.18c0-.53-.09-1.02-.27-1.46-.18-.44-.44-.81-.78-1.11-.34-.31-.77-.54-1.26-.71-.51-.16-1.08-.24-1.72-.24-.69 0-1.31.11-1.85.32-.54.21-1 .51-1.36.88-.37.37-.65.8-.84 1.3-.18.47-.27.97-.28 1.5h2.14c.01-.31.05-.6.13-.87.09-.29.23-.54.4-.75.18-.21.41-.37.68-.49.27-.12.6-.18.96-.18.31 0 .58.05.81.15.23.1.43.25.59.43.16.18.28.4.37.65.08.25.13.52.13.81 0 .22-.03.43-.08.65-.06.22-.15.45-.29.7-.14.25-.32.53-.56.83-.23.3-.52.65-.88 1.03l-4.17 4.55V18H21v-1.71h-5.95zM2 11v2h8v-2H2z"/></g> +<g id="exposure-plus-1"><path d="M10 7H8v4H4v2h4v4h2v-4h4v-2h-4V7zm10 11h-2V7.38L15 8.4V6.7L19.7 5h.3v13z"/></g> +<g id="exposure-plus-2"><path d="M16.05 16.29l2.86-3.07c.38-.39.72-.79 1.04-1.18.32-.39.59-.78.82-1.17.23-.39.41-.78.54-1.17.13-.39.19-.79.19-1.18 0-.53-.09-1.02-.27-1.46-.18-.44-.44-.81-.78-1.11-.34-.31-.77-.54-1.26-.71-.51-.16-1.08-.24-1.72-.24-.69 0-1.31.11-1.85.32-.54.21-1 .51-1.36.88-.37.37-.65.8-.84 1.3-.18.47-.27.97-.28 1.5h2.14c.01-.31.05-.6.13-.87.09-.29.23-.54.4-.75.18-.21.41-.37.68-.49.27-.12.6-.18.96-.18.31 0 .58.05.81.15.23.1.43.25.59.43.16.18.28.4.37.65.08.25.13.52.13.81 0 .22-.03.43-.08.65-.06.22-.15.45-.29.7-.14.25-.32.53-.56.83-.23.3-.52.65-.88 1.03l-4.17 4.55V18H22v-1.71h-5.95zM8 7H6v4H2v2h4v4h2v-4h4v-2H8V7z"/></g> +<g id="exposure-zero"><path d="M16.14 12.5c0 1-.1 1.85-.3 2.55-.2.7-.48 1.27-.83 1.7-.36.44-.79.75-1.3.95-.51.2-1.07.3-1.7.3-.62 0-1.18-.1-1.69-.3-.51-.2-.95-.51-1.31-.95-.36-.44-.65-1.01-.85-1.7-.2-.7-.3-1.55-.3-2.55v-2.04c0-1 .1-1.85.3-2.55.2-.7.48-1.26.84-1.69.36-.43.8-.74 1.31-.93C10.81 5.1 11.38 5 12 5c.63 0 1.19.1 1.7.29.51.19.95.5 1.31.93.36.43.64.99.84 1.69.2.7.3 1.54.3 2.55v2.04zm-2.11-2.36c0-.64-.05-1.18-.13-1.62-.09-.44-.22-.79-.4-1.06-.17-.27-.39-.46-.64-.58-.25-.13-.54-.19-.86-.19-.32 0-.61.06-.86.18s-.47.31-.64.58c-.17.27-.31.62-.4 1.06s-.13.98-.13 1.62v2.67c0 .64.05 1.18.14 1.62.09.45.23.81.4 1.09s.39.48.64.61.54.19.87.19c.33 0 .62-.06.87-.19s.46-.33.63-.61c.17-.28.3-.64.39-1.09.09-.45.13-.99.13-1.62v-2.66z"/></g> +<g id="filter"><path d="M15.96 10.29l-2.75 3.54-1.96-2.36L8.5 15h11l-3.54-4.71zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-1"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 10h2V5h-4v2h2v8zm7-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-2"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-4-4h-4v-2h2c1.1 0 2-.89 2-2V7c0-1.11-.9-2-2-2h-4v2h4v2h-2c-1.1 0-2 .89-2 2v4h6v-2z"/></g> +<g id="filter-3"><path d="M21 1H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm14 8v-1.5c0-.83-.67-1.5-1.5-1.5.83 0 1.5-.67 1.5-1.5V7c0-1.11-.9-2-2-2h-4v2h4v2h-2v2h2v2h-4v2h4c1.1 0 2-.89 2-2z"/></g> +<g id="filter-4"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm12 10h2V5h-2v4h-2V5h-2v6h4v4zm6-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-5"><path d="M21 1H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm14 8v-2c0-1.11-.9-2-2-2h-2V7h4V5h-6v6h4v2h-4v2h4c1.1 0 2-.89 2-2z"/></g> +<g id="filter-6"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-8-2h2c1.1 0 2-.89 2-2v-2c0-1.11-.9-2-2-2h-2V7h4V5h-4c-1.1 0-2 .89-2 2v6c0 1.11.9 2 2 2zm0-4h2v2h-2v-2z"/></g> +<g id="filter-7"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-8-2l4-8V5h-6v2h4l-4 8h2z"/></g> +<g id="filter-8"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-8-2h2c1.1 0 2-.89 2-2v-1.5c0-.83-.67-1.5-1.5-1.5.83 0 1.5-.67 1.5-1.5V7c0-1.11-.9-2-2-2h-2c-1.1 0-2 .89-2 2v1.5c0 .83.67 1.5 1.5 1.5-.83 0-1.5.67-1.5 1.5V13c0 1.11.9 2 2 2zm0-8h2v2h-2V7zm0 4h2v2h-2v-2z"/></g> +<g id="filter-9"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM15 5h-2c-1.1 0-2 .89-2 2v2c0 1.11.9 2 2 2h2v2h-4v2h4c1.1 0 2-.89 2-2V7c0-1.11-.9-2-2-2zm0 4h-2V7h2v2z"/></g> +<g id="filter-9-plus"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 7V8c0-1.11-.9-2-2-2h-1c-1.1 0-2 .89-2 2v1c0 1.11.9 2 2 2h1v1H9v2h3c1.1 0 2-.89 2-2zm-3-3V8h1v1h-1zm10-8H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 8h-2V7h-2v2h-2v2h2v2h2v-2h2v6H7V3h14v6z"/></g> +<g id="filter-b-and-w"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16l-7-8v8H5l7-8V5h7v14z"/></g> +<g id="filter-center-focus"><path d="M5 15H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zM12 9c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="filter-drama"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.61 5.64 5.36 8.04 2.35 8.36 0 10.9 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4h2c0-2.76-1.86-5.08-4.4-5.78C8.61 6.88 10.2 6 12 6c3.03 0 5.5 2.47 5.5 5.5v.5H19c1.65 0 3 1.35 3 3s-1.35 3-3 3z"/></g> +<g id="filter-frames"><path d="M20 4h-4l-4-4-4 4H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H4V6h4.52l3.52-3.5L15.52 6H20v14zM18 8H6v10h12"/></g> +<g id="filter-hdr"><path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z"/></g> +<g id="filter-none"><path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/></g> +<g id="filter-tilt-shift"><path d="M11 4.07V2.05c-2.01.2-3.84 1-5.32 2.21L7.1 5.69c1.11-.86 2.44-1.44 3.9-1.62zm7.32.19C16.84 3.05 15.01 2.25 13 2.05v2.02c1.46.18 2.79.76 3.9 1.62l1.42-1.43zM19.93 11h2.02c-.2-2.01-1-3.84-2.21-5.32L18.31 7.1c.86 1.11 1.44 2.44 1.62 3.9zM5.69 7.1L4.26 5.68C3.05 7.16 2.25 8.99 2.05 11h2.02c.18-1.46.76-2.79 1.62-3.9zM4.07 13H2.05c.2 2.01 1 3.84 2.21 5.32l1.43-1.43c-.86-1.1-1.44-2.43-1.62-3.89zM15 12c0-1.66-1.34-3-3-3s-3 1.34-3 3 1.34 3 3 3 3-1.34 3-3zm3.31 4.9l1.43 1.43c1.21-1.48 2.01-3.32 2.21-5.32h-2.02c-.18 1.45-.76 2.78-1.62 3.89zM13 19.93v2.02c2.01-.2 3.84-1 5.32-2.21l-1.43-1.43c-1.1.86-2.43 1.44-3.89 1.62zm-7.32-.19C7.16 20.95 9 21.75 11 21.95v-2.02c-1.46-.18-2.79-.76-3.9-1.62l-1.42 1.43z"/></g> +<g id="filter-vintage"><path d="M18.7 12.4c-.28-.16-.57-.29-.86-.4.29-.11.58-.24.86-.4 1.92-1.11 2.99-3.12 3-5.19-1.79-1.03-4.07-1.11-6 0-.28.16-.54.35-.78.54.05-.31.08-.63.08-.95 0-2.22-1.21-4.15-3-5.19C10.21 1.85 9 3.78 9 6c0 .32.03.64.08.95-.24-.2-.5-.39-.78-.55-1.92-1.11-4.2-1.03-6 0 0 2.07 1.07 4.08 3 5.19.28.16.57.29.86.4-.29.11-.58.24-.86.4-1.92 1.11-2.99 3.12-3 5.19 1.79 1.03 4.07 1.11 6 0 .28-.16.54-.35.78-.54-.05.32-.08.64-.08.96 0 2.22 1.21 4.15 3 5.19 1.79-1.04 3-2.97 3-5.19 0-.32-.03-.64-.08-.95.24.2.5.38.78.54 1.92 1.11 4.2 1.03 6 0-.01-2.07-1.08-4.08-3-5.19zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"/></g> +<g id="flare"><path d="M7 11H1v2h6v-2zm2.17-3.24L7.05 5.64 5.64 7.05l2.12 2.12 1.41-1.41zM13 1h-2v6h2V1zm5.36 6.05l-1.41-1.41-2.12 2.12 1.41 1.41 2.12-2.12zM17 11v2h6v-2h-6zm-5-2c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3zm2.83 7.24l2.12 2.12 1.41-1.41-2.12-2.12-1.41 1.41zm-9.19.71l1.41 1.41 2.12-2.12-1.41-1.41-2.12 2.12zM11 23h2v-6h-2v6z"/></g> +<g id="flash-auto"><path d="M3 2v12h3v9l7-12H9l4-9H3zm16 0h-2l-3.2 9h1.9l.7-2h3.2l.7 2h1.9L19 2zm-2.15 5.65L18 4l1.15 3.65h-2.3z"/></g> +<g id="flash-off"><path d="M3.27 3L2 4.27l5 5V13h3v9l3.58-6.14L17.73 20 19 18.73 3.27 3zM17 10h-4l4-8H7v2.18l8.46 8.46L17 10z"/></g> +<g id="flash-on"><path d="M7 2v11h3v9l7-12h-4l4-8z"/></g> +<g id="flip"><path d="M15 21h2v-2h-2v2zm4-12h2V7h-2v2zM3 5v14c0 1.1.9 2 2 2h4v-2H5V5h4V3H5c-1.1 0-2 .9-2 2zm16-2v2h2c0-1.1-.9-2-2-2zm-8 20h2V1h-2v22zm8-6h2v-2h-2v2zM15 5h2V3h-2v2zm4 8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2z"/></g> +<g id="gradient"><path d="M11 9h2v2h-2zm-2 2h2v2H9zm4 0h2v2h-2zm2-2h2v2h-2zM7 9h2v2H7zm12-6H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 18H7v-2h2v2zm4 0h-2v-2h2v2zm4 0h-2v-2h2v2zm2-7h-2v2h2v2h-2v-2h-2v2h-2v-2h-2v2H9v-2H7v2H5v-2h2v-2H5V5h14v6z"/></g> +<g id="grain"><path d="M10 12c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12-8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-4 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm4-4c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-4-4c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-4-4c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="grid-off"><path d="M8 4v1.45l2 2V4h4v4h-3.45l2 2H14v1.45l2 2V10h4v4h-3.45l2 2H20v1.45l2 2V4c0-1.1-.9-2-2-2H4.55l2 2H8zm8 0h4v4h-4V4zM1.27 1.27L0 2.55l2 2V20c0 1.1.9 2 2 2h15.46l2 2 1.27-1.27L1.27 1.27zM10 12.55L11.45 14H10v-1.45zm-6-6L5.45 8H4V6.55zM8 20H4v-4h4v4zm0-6H4v-4h3.45l.55.55V14zm6 6h-4v-4h3.45l.55.54V20zm2 0v-1.46L17.46 20H16z"/></g> +<g id="grid-on"><path d="M20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM8 20H4v-4h4v4zm0-6H4v-4h4v4zm0-6H4V4h4v4zm6 12h-4v-4h4v4zm0-6h-4v-4h4v4zm0-6h-4V4h4v4zm6 12h-4v-4h4v4zm0-6h-4v-4h4v4zm0-6h-4V4h4v4z"/></g> +<g id="hdr-off"><path d="M17.5 15v-2h1.1l.9 2H21l-.9-2.1c.5-.2.9-.8.9-1.4v-1c0-.8-.7-1.5-1.5-1.5H16v4.9l1.1 1.1h.4zm0-4.5h2v1h-2v-1zm-4.5 0v.4l1.5 1.5v-1.9c0-.8-.7-1.5-1.5-1.5h-1.9l1.5 1.5h.4zm-3.5-1l-7-7-1.1 1L6.9 9h-.4v2h-2V9H3v6h1.5v-2.5h2V15H8v-4.9l1.5 1.5V15h3.4l7.6 7.6 1.1-1.1-12.1-12z"/></g> +<g id="hdr-on"><path d="M21 11.5v-1c0-.8-.7-1.5-1.5-1.5H16v6h1.5v-2h1.1l.9 2H21l-.9-2.1c.5-.3.9-.8.9-1.4zm-1.5 0h-2v-1h2v1zm-13-.5h-2V9H3v6h1.5v-2.5h2V15H8V9H6.5v2zM13 9H9.5v6H13c.8 0 1.5-.7 1.5-1.5v-3c0-.8-.7-1.5-1.5-1.5zm0 4.5h-2v-3h2v3z"/></g> +<g id="hdr-strong"><path d="M17 6c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zM5 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="hdr-weak"><path d="M5 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm12-2c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm0 10c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4z"/></g> +<g id="healing"><path d="M17.73 12.02l3.98-3.98c.39-.39.39-1.02 0-1.41l-4.34-4.34c-.39-.39-1.02-.39-1.41 0l-3.98 3.98L8 2.29C7.8 2.1 7.55 2 7.29 2c-.25 0-.51.1-.7.29L2.25 6.63c-.39.39-.39 1.02 0 1.41l3.98 3.98L2.25 16c-.39.39-.39 1.02 0 1.41l4.34 4.34c.39.39 1.02.39 1.41 0l3.98-3.98 3.98 3.98c.2.2.45.29.71.29.26 0 .51-.1.71-.29l4.34-4.34c.39-.39.39-1.02 0-1.41l-3.99-3.98zM12 9c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm-4.71 1.96L3.66 7.34l3.63-3.63 3.62 3.62-3.62 3.63zM10 13c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm2 2c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm2-4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm2.66 9.34l-3.63-3.62 3.63-3.63 3.62 3.62-3.62 3.63z"/></g> +<g id="image"><path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/></g> +<g id="image-aspect-ratio"><path d="M16 10h-2v2h2v-2zm0 4h-2v2h2v-2zm-8-4H6v2h2v-2zm4 0h-2v2h2v-2zm8-6H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H4V6h16v12z"/></g> +<g id="iso"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5.5 7.5h2v-2H9v2h2V9H9v2H7.5V9h-2V7.5zM19 19H5L19 5v14zm-2-2v-1.5h-5V17h5z"/></g> +<g id="landscape"><path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z"/></g> +<g id="leak-add"><path d="M6 3H3v3c1.66 0 3-1.34 3-3zm8 0h-2c0 4.97-4.03 9-9 9v2c6.08 0 11-4.93 11-11zm-4 0H8c0 2.76-2.24 5-5 5v2c3.87 0 7-3.13 7-7zm0 18h2c0-4.97 4.03-9 9-9v-2c-6.07 0-11 4.93-11 11zm8 0h3v-3c-1.66 0-3 1.34-3 3zm-4 0h2c0-2.76 2.24-5 5-5v-2c-3.87 0-7 3.13-7 7z"/></g> +<g id="leak-remove"><path d="M10 3H8c0 .37-.04.72-.12 1.06l1.59 1.59C9.81 4.84 10 3.94 10 3zM3 4.27l2.84 2.84C5.03 7.67 4.06 8 3 8v2c1.61 0 3.09-.55 4.27-1.46L8.7 9.97C7.14 11.24 5.16 12 3 12v2c2.71 0 5.19-.99 7.11-2.62l2.5 2.5C10.99 15.81 10 18.29 10 21h2c0-2.16.76-4.14 2.03-5.69l1.43 1.43C14.55 17.91 14 19.39 14 21h2c0-1.06.33-2.03.89-2.84L19.73 21 21 19.73 4.27 3 3 4.27zM14 3h-2c0 1.5-.37 2.91-1.02 4.16l1.46 1.46C13.42 6.98 14 5.06 14 3zm5.94 13.12c.34-.08.69-.12 1.06-.12v-2c-.94 0-1.84.19-2.66.52l1.6 1.6zm-4.56-4.56l1.46 1.46C18.09 12.37 19.5 12 21 12v-2c-2.06 0-3.98.58-5.62 1.56z"/></g> +<g id="lens"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2z"/></g> +<g id="looks"><path d="M12 10c-3.86 0-7 3.14-7 7h2c0-2.76 2.24-5 5-5s5 2.24 5 5h2c0-3.86-3.14-7-7-7zm0-4C5.93 6 1 10.93 1 17h2c0-4.96 4.04-9 9-9s9 4.04 9 9h2c0-6.07-4.93-11-11-11z"/></g> +<g id="looks-3"><path d="M19.01 3h-14c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 7.5c0 .83-.67 1.5-1.5 1.5.83 0 1.5.67 1.5 1.5V15c0 1.11-.9 2-2 2h-4v-2h4v-2h-2v-2h2V9h-4V7h4c1.1 0 2 .89 2 2v1.5z"/></g> +<g id="looks-4"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 14h-2v-4H9V7h2v4h2V7h2v10z"/></g> +<g id="looks-5"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 6h-4v2h2c1.1 0 2 .89 2 2v2c0 1.11-.9 2-2 2H9v-2h4v-2H9V7h6v2z"/></g> +<g id="looks-6"><path d="M11 15h2v-2h-2v2zm8-12H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 6h-4v2h2c1.1 0 2 .89 2 2v2c0 1.11-.9 2-2 2h-2c-1.1 0-2-.89-2-2V9c0-1.11.9-2 2-2h4v2z"/></g> +<g id="looks-one"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-5 14h-2V9h-2V7h4v10z"/></g> +<g id="looks-two"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-4 8c0 1.11-.9 2-2 2h-2v2h4v2H9v-4c0-1.11.9-2 2-2h2V9H9V7h4c1.1 0 2 .89 2 2v2z"/></g> +<g id="loupe"><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.49 2 2 6.49 2 12s4.49 10 10 10h8c1.1 0 2-.9 2-2v-8c0-5.51-4.49-10-10-10zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="monochrome-photos"><path d="M20 5h-3.2L15 3H9L7.2 5H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 14h-8v-1c-2.8 0-5-2.2-5-5s2.2-5 5-5V7h8v12zm-3-6c0-2.8-2.2-5-5-5v1.8c1.8 0 3.2 1.4 3.2 3.2s-1.4 3.2-3.2 3.2V18c2.8 0 5-2.2 5-5zm-8.2 0c0 1.8 1.4 3.2 3.2 3.2V9.8c-1.8 0-3.2 1.4-3.2 3.2z"/></g> +<g id="movie-creation"><path d="M18 4l2 4h-3l-2-4h-2l2 4h-3l-2-4H8l2 4H7L5 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4h-4z"/></g> +<g id="music-note"><path d="M12 3v10.55c-.59-.34-1.27-.55-2-.55-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4V7h4V3h-6z"/></g> +<g id="nature"><path d="M13 16.12c3.47-.41 6.17-3.36 6.17-6.95 0-3.87-3.13-7-7-7s-7 3.13-7 7c0 3.47 2.52 6.34 5.83 6.89V20H5v2h14v-2h-6v-3.88z"/></g> +<g id="nature-people"><path d="M22.17 9.17c0-3.87-3.13-7-7-7s-7 3.13-7 7c0 3.47 2.52 6.34 5.83 6.89V20H6v-3h1v-4c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v4h1v5h16v-2h-3v-3.88c3.47-.41 6.17-3.36 6.17-6.95zM4.5 11c.83 0 1.5-.67 1.5-1.5S5.33 8 4.5 8 3 8.67 3 9.5 3.67 11 4.5 11z"/></g> +<g id="navigate-before"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></g> +<g id="navigate-next"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></g> +<g id="palette"><path d="M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9c.83 0 1.5-.67 1.5-1.5 0-.39-.15-.74-.39-1.01-.23-.26-.38-.61-.38-.99 0-.83.67-1.5 1.5-1.5H16c2.76 0 5-2.24 5-5 0-4.42-4.03-8-9-8zm-5.5 9c-.83 0-1.5-.67-1.5-1.5S5.67 9 6.5 9 8 9.67 8 10.5 7.33 12 6.5 12zm3-4C8.67 8 8 7.33 8 6.5S8.67 5 9.5 5s1.5.67 1.5 1.5S10.33 8 9.5 8zm5 0c-.83 0-1.5-.67-1.5-1.5S13.67 5 14.5 5s1.5.67 1.5 1.5S15.33 8 14.5 8zm3 4c-.83 0-1.5-.67-1.5-1.5S16.67 9 17.5 9s1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="panorama"><path d="M23 18V6c0-1.1-.9-2-2-2H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zM8.5 12.5l2.5 3.01L14.5 11l4.5 6H5l3.5-4.5z"/></g> +<g id="panorama-fish-eye"><path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="panorama-horizontal"><path d="M20 6.54v10.91c-2.6-.77-5.28-1.16-8-1.16-2.72 0-5.4.39-8 1.16V6.54c2.6.77 5.28 1.16 8 1.16 2.72.01 5.4-.38 8-1.16M21.43 4c-.1 0-.2.02-.31.06C18.18 5.16 15.09 5.7 12 5.7c-3.09 0-6.18-.55-9.12-1.64-.11-.04-.22-.06-.31-.06-.34 0-.57.23-.57.63v14.75c0 .39.23.62.57.62.1 0 .2-.02.31-.06 2.94-1.1 6.03-1.64 9.12-1.64 3.09 0 6.18.55 9.12 1.64.11.04.21.06.31.06.33 0 .57-.23.57-.63V4.63c0-.4-.24-.63-.57-.63z"/></g> +<g id="panorama-vertical"><path d="M19.94 21.12c-1.1-2.94-1.64-6.03-1.64-9.12 0-3.09.55-6.18 1.64-9.12.04-.11.06-.22.06-.31 0-.34-.23-.57-.63-.57H4.63c-.4 0-.63.23-.63.57 0 .1.02.2.06.31C5.16 5.82 5.71 8.91 5.71 12c0 3.09-.55 6.18-1.64 9.12-.05.11-.07.22-.07.31 0 .33.23.57.63.57h14.75c.39 0 .63-.24.63-.57-.01-.1-.03-.2-.07-.31zM6.54 20c.77-2.6 1.16-5.28 1.16-8 0-2.72-.39-5.4-1.16-8h10.91c-.77 2.6-1.16 5.28-1.16 8 0 2.72.39 5.4 1.16 8H6.54z"/></g> +<g id="panorama-wide-angle"><path d="M12 6c2.45 0 4.71.2 7.29.64.47 1.78.71 3.58.71 5.36 0 1.78-.24 3.58-.71 5.36-2.58.44-4.84.64-7.29.64s-4.71-.2-7.29-.64C4.24 15.58 4 13.78 4 12c0-1.78.24-3.58.71-5.36C7.29 6.2 9.55 6 12 6m0-2c-2.73 0-5.22.24-7.95.72l-.93.16-.25.9C2.29 7.85 2 9.93 2 12s.29 4.15.87 6.22l.25.89.93.16c2.73.49 5.22.73 7.95.73s5.22-.24 7.95-.72l.93-.16.25-.89c.58-2.08.87-4.16.87-6.23s-.29-4.15-.87-6.22l-.25-.89-.93-.16C17.22 4.24 14.73 4 12 4z"/></g> +<g id="photo"><path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/></g> +<g id="photo-album"><path d="M18 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 4h5v8l-2.5-1.5L6 12V4zm0 15l3-3.86 2.14 2.58 3-3.86L18 19H6z"/></g> +<g id="photo-camera"><circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"/></g> +<g id="photo-library"><path d="M22 16V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2zm-11-4l2.03 2.71L16 11l4 5H8l3-4zM2 6v14c0 1.1.9 2 2 2h14v-2H4V6H2z"/></g> +<g id="photo-size-select-actual"><path d="M21 3H3C2 3 1 4 1 5v14c0 1.1.9 2 2 2h18c1 0 2-1 2-2V5c0-1-1-2-2-2zM5 17l3.5-4.5 2.5 3.01L14.5 11l4.5 6H5z"/></g> +<g id="photo-size-select-large"><path d="M21 15h2v2h-2v-2zm0-4h2v2h-2v-2zm2 8h-2v2c1 0 2-1 2-2zM13 3h2v2h-2V3zm8 4h2v2h-2V7zm0-4v2h2c0-1-1-2-2-2zM1 7h2v2H1V7zm16-4h2v2h-2V3zm0 16h2v2h-2v-2zM3 3C2 3 1 4 1 5h2V3zm6 0h2v2H9V3zM5 3h2v2H5V3zm-4 8v8c0 1.1.9 2 2 2h12V11H1zm2 8l2.5-3.21 1.79 2.15 2.5-3.22L13 19H3z"/></g> +<g id="photo-size-select-small"><path d="M23 15h-2v2h2v-2zm0-4h-2v2h2v-2zm0 8h-2v2c1 0 2-1 2-2zM15 3h-2v2h2V3zm8 4h-2v2h2V7zm-2-4v2h2c0-1-1-2-2-2zM3 21h8v-6H1v4c0 1.1.9 2 2 2zM3 7H1v2h2V7zm12 12h-2v2h2v-2zm4-16h-2v2h2V3zm0 16h-2v2h2v-2zM3 3C2 3 1 4 1 5h2V3zm0 8H1v2h2v-2zm8-8H9v2h2V3zM7 3H5v2h2V3z"/></g> +<g id="picture-as-pdf"><path d="M20 2H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-8.5 7.5c0 .83-.67 1.5-1.5 1.5H9v2H7.5V7H10c.83 0 1.5.67 1.5 1.5v1zm5 2c0 .83-.67 1.5-1.5 1.5h-2.5V7H15c.83 0 1.5.67 1.5 1.5v3zm4-3H19v1h1.5V11H19v2h-1.5V7h3v1.5zM9 9.5h1v-1H9v1zM4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm10 5.5h1v-3h-1v3z"/></g> +<g id="portrait"><path d="M12 12.25c1.24 0 2.25-1.01 2.25-2.25S13.24 7.75 12 7.75 9.75 8.76 9.75 10s1.01 2.25 2.25 2.25zm4.5 4c0-1.5-3-2.25-4.5-2.25s-4.5.75-4.5 2.25V17h9v-.75zM19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/></g> +<g id="remove-red-eye"><path d="M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="rotate-90-degrees-ccw"><path d="M7.34 6.41L.86 12.9l6.49 6.48 6.49-6.48-6.5-6.49zM3.69 12.9l3.66-3.66L11 12.9l-3.66 3.66-3.65-3.66zm15.67-6.26C17.61 4.88 15.3 4 13 4V.76L8.76 5 13 9.24V6c1.79 0 3.58.68 4.95 2.05 2.73 2.73 2.73 7.17 0 9.9C16.58 19.32 14.79 20 13 20c-.97 0-1.94-.21-2.84-.61l-1.49 1.49C10.02 21.62 11.51 22 13 22c2.3 0 4.61-.88 6.36-2.64 3.52-3.51 3.52-9.21 0-12.72z"/></g> +<g id="rotate-left"><path d="M7.11 8.53L5.7 7.11C4.8 8.27 4.24 9.61 4.07 11h2.02c.14-.87.49-1.72 1.02-2.47zM6.09 13H4.07c.17 1.39.72 2.73 1.62 3.89l1.41-1.42c-.52-.75-.87-1.59-1.01-2.47zm1.01 5.32c1.16.9 2.51 1.44 3.9 1.61V17.9c-.87-.15-1.71-.49-2.46-1.03L7.1 18.32zM13 4.07V1L8.45 5.55 13 10V6.09c2.84.48 5 2.94 5 5.91s-2.16 5.43-5 5.91v2.02c3.95-.49 7-3.85 7-7.93s-3.05-7.44-7-7.93z"/></g> +<g id="rotate-right"><path d="M15.55 5.55L11 1v3.07C7.06 4.56 4 7.92 4 12s3.05 7.44 7 7.93v-2.02c-2.84-.48-5-2.94-5-5.91s2.16-5.43 5-5.91V10l4.55-4.45zM19.93 11c-.17-1.39-.72-2.73-1.62-3.89l-1.42 1.42c.54.75.88 1.6 1.02 2.47h2.02zM13 17.9v2.02c1.39-.17 2.74-.71 3.9-1.61l-1.44-1.44c-.75.54-1.59.89-2.46 1.03zm3.89-2.42l1.42 1.41c.9-1.16 1.45-2.5 1.62-3.89h-2.02c-.14.87-.48 1.72-1.02 2.48z"/></g> +<g id="slideshow"><path d="M10 8v8l5-4-5-4zm9-5H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/></g> +<g id="straighten"><path d="M21 6H3c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 10H3V8h2v4h2V8h2v4h2V8h2v4h2V8h2v4h2V8h2v8z"/></g> +<g id="style"><path d="M2.53 19.65l1.34.56v-9.03l-2.43 5.86c-.41 1.02.08 2.19 1.09 2.61zm19.5-3.7L17.07 3.98c-.31-.75-1.04-1.21-1.81-1.23-.26 0-.53.04-.79.15L7.1 5.95c-.75.31-1.21 1.03-1.23 1.8-.01.27.04.54.15.8l4.96 11.97c.31.76 1.05 1.22 1.83 1.23.26 0 .52-.05.77-.15l7.36-3.05c1.02-.42 1.51-1.59 1.09-2.6zM7.88 8.75c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-2 11c0 1.1.9 2 2 2h1.45l-3.45-8.34v6.34z"/></g> +<g id="switch-camera"><path d="M20 4h-3.17L15 2H9L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 11.5V13H9v2.5L5.5 12 9 8.5V11h6V8.5l3.5 3.5-3.5 3.5z"/></g> +<g id="switch-video"><path d="M18 9.5V6c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h14c.55 0 1-.45 1-1v-3.5l4 4v-13l-4 4zm-5 6V13H7v2.5L3.5 12 7 8.5V11h6V8.5l3.5 3.5-3.5 3.5z"/></g> +<g id="tag-faces"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 6.5c2.33 0 4.31-1.46 5.11-3.5H6.89c.8 2.04 2.78 3.5 5.11 3.5z"/></g> +<g id="texture"><path d="M19.51 3.08L3.08 19.51c.09.34.27.65.51.9.25.24.56.42.9.51L20.93 4.49c-.19-.69-.73-1.23-1.42-1.41zM11.88 3L3 11.88v2.83L14.71 3h-2.83zM5 3c-1.1 0-2 .9-2 2v2l4-4H5zm14 18c.55 0 1.05-.22 1.41-.59.37-.36.59-.86.59-1.41v-2l-4 4h2zm-9.71 0h2.83L21 12.12V9.29L9.29 21z"/></g> +<g id="timelapse"><path d="M16.24 7.76C15.07 6.59 13.54 6 12 6v6l-4.24 4.24c2.34 2.34 6.14 2.34 8.49 0 2.34-2.34 2.34-6.14-.01-8.48zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="timer"><path d="M15 1H9v2h6V1zm-4 13h2V8h-2v6zm8.03-6.61l1.42-1.42c-.43-.51-.9-.99-1.41-1.41l-1.42 1.42C16.07 4.74 14.12 4 12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9 9-4.03 9-9c0-2.12-.74-4.07-1.97-5.61zM12 20c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="timer-10"><path d="M0 7.72V9.4l3-1V18h2V6h-.25L0 7.72zm23.78 6.65c-.14-.28-.35-.53-.63-.74-.28-.21-.61-.39-1.01-.53s-.85-.27-1.35-.38c-.35-.07-.64-.15-.87-.23-.23-.08-.41-.16-.55-.25-.14-.09-.23-.19-.28-.3-.05-.11-.08-.24-.08-.39 0-.14.03-.28.09-.41.06-.13.15-.25.27-.34.12-.1.27-.18.45-.24s.4-.09.64-.09c.25 0 .47.04.66.11.19.07.35.17.48.29.13.12.22.26.29.42.06.16.1.32.1.49h1.95c0-.39-.08-.75-.24-1.09-.16-.34-.39-.63-.69-.88-.3-.25-.66-.44-1.09-.59C21.49 9.07 21 9 20.46 9c-.51 0-.98.07-1.39.21-.41.14-.77.33-1.06.57-.29.24-.51.52-.67.84-.16.32-.23.65-.23 1.01s.08.69.23.96c.15.28.36.52.64.73.27.21.6.38.98.53.38.14.81.26 1.27.36.39.08.71.17.95.26s.43.19.57.29c.13.1.22.22.27.34.05.12.07.25.07.39 0 .32-.13.57-.4.77-.27.2-.66.29-1.17.29-.22 0-.43-.02-.64-.08-.21-.05-.4-.13-.56-.24-.17-.11-.3-.26-.41-.44-.11-.18-.17-.41-.18-.67h-1.89c0 .36.08.71.24 1.05.16.34.39.65.7.93.31.27.69.49 1.15.66.46.17.98.25 1.58.25.53 0 1.01-.06 1.44-.19.43-.13.8-.31 1.11-.54.31-.23.54-.51.71-.83.17-.32.25-.67.25-1.06-.02-.4-.09-.74-.24-1.02zm-9.96-7.32c-.34-.4-.75-.7-1.23-.88-.47-.18-1.01-.27-1.59-.27-.58 0-1.11.09-1.59.27-.48.18-.89.47-1.23.88-.34.41-.6.93-.79 1.59-.18.65-.28 1.45-.28 2.39v1.92c0 .94.09 1.74.28 2.39.19.66.45 1.19.8 1.6.34.41.75.71 1.23.89.48.18 1.01.28 1.59.28.59 0 1.12-.09 1.59-.28.48-.18.88-.48 1.22-.89.34-.41.6-.94.78-1.6.18-.65.28-1.45.28-2.39v-1.92c0-.94-.09-1.74-.28-2.39-.18-.66-.44-1.19-.78-1.59zm-.92 6.17c0 .6-.04 1.11-.12 1.53-.08.42-.2.76-.36 1.02-.16.26-.36.45-.59.57-.23.12-.51.18-.82.18-.3 0-.58-.06-.82-.18s-.44-.31-.6-.57c-.16-.26-.29-.6-.38-1.02-.09-.42-.13-.93-.13-1.53v-2.5c0-.6.04-1.11.13-1.52.09-.41.21-.74.38-1 .16-.25.36-.43.6-.55.24-.11.51-.17.81-.17.31 0 .58.06.81.17.24.11.44.29.6.55.16.25.29.58.37.99.08.41.13.92.13 1.52v2.51z"/></g> +<g id="timer-3"><path d="M11.61 12.97c-.16-.24-.36-.46-.62-.65-.25-.19-.56-.35-.93-.48.3-.14.57-.3.8-.5.23-.2.42-.41.57-.64.15-.23.27-.46.34-.71.08-.24.11-.49.11-.73 0-.55-.09-1.04-.28-1.46-.18-.42-.44-.77-.78-1.06-.33-.28-.73-.5-1.2-.64-.45-.13-.97-.2-1.53-.2-.55 0-1.06.08-1.52.24-.47.17-.87.4-1.2.69-.33.29-.6.63-.78 1.03-.2.39-.29.83-.29 1.29h1.98c0-.26.05-.49.14-.69.09-.2.22-.38.38-.52.17-.14.36-.25.58-.33.22-.08.46-.12.73-.12.61 0 1.06.16 1.36.47.3.31.44.75.44 1.32 0 .27-.04.52-.12.74-.08.22-.21.41-.38.57-.17.16-.38.28-.63.37-.25.09-.55.13-.89.13H6.72v1.57H7.9c.34 0 .64.04.91.11.27.08.5.19.69.35.19.16.34.36.44.61.1.24.16.54.16.87 0 .62-.18 1.09-.53 1.42-.35.33-.84.49-1.45.49-.29 0-.56-.04-.8-.13-.24-.08-.44-.2-.61-.36-.17-.16-.3-.34-.39-.56-.09-.22-.14-.46-.14-.72H4.19c0 .55.11 1.03.32 1.45.21.42.5.77.86 1.05s.77.49 1.24.63.96.21 1.48.21c.57 0 1.09-.08 1.58-.23.49-.15.91-.38 1.26-.68.36-.3.64-.66.84-1.1.2-.43.3-.93.3-1.48 0-.29-.04-.58-.11-.86-.08-.25-.19-.51-.35-.76zm9.26 1.4c-.14-.28-.35-.53-.63-.74-.28-.21-.61-.39-1.01-.53s-.85-.27-1.35-.38c-.35-.07-.64-.15-.87-.23-.23-.08-.41-.16-.55-.25-.14-.09-.23-.19-.28-.3-.05-.11-.08-.24-.08-.39s.03-.28.09-.41c.06-.13.15-.25.27-.34.12-.1.27-.18.45-.24s.4-.09.64-.09c.25 0 .47.04.66.11.19.07.35.17.48.29.13.12.22.26.29.42.06.16.1.32.1.49h1.95c0-.39-.08-.75-.24-1.09-.16-.34-.39-.63-.69-.88-.3-.25-.66-.44-1.09-.59-.43-.15-.92-.22-1.46-.22-.51 0-.98.07-1.39.21-.41.14-.77.33-1.06.57-.29.24-.51.52-.67.84-.16.32-.23.65-.23 1.01s.08.68.23.96c.15.28.37.52.64.73.27.21.6.38.98.53.38.14.81.26 1.27.36.39.08.71.17.95.26s.43.19.57.29c.13.1.22.22.27.34.05.12.07.25.07.39 0 .32-.13.57-.4.77-.27.2-.66.29-1.17.29-.22 0-.43-.02-.64-.08-.21-.05-.4-.13-.56-.24-.17-.11-.3-.26-.41-.44-.11-.18-.17-.41-.18-.67h-1.89c0 .36.08.71.24 1.05.16.34.39.65.7.93.31.27.69.49 1.15.66.46.17.98.25 1.58.25.53 0 1.01-.06 1.44-.19.43-.13.8-.31 1.11-.54.31-.23.54-.51.71-.83.17-.32.25-.67.25-1.06-.02-.4-.09-.74-.24-1.02z"/></g> +<g id="timer-off"><path d="M19.04 4.55l-1.42 1.42C16.07 4.74 14.12 4 12 4c-1.83 0-3.53.55-4.95 1.48l1.46 1.46C9.53 6.35 10.73 6 12 6c3.87 0 7 3.13 7 7 0 1.27-.35 2.47-.94 3.49l1.45 1.45C20.45 16.53 21 14.83 21 13c0-2.12-.74-4.07-1.97-5.61l1.42-1.42-1.41-1.42zM15 1H9v2h6V1zm-4 8.44l2 2V8h-2v1.44zM3.02 4L1.75 5.27 4.5 8.03C3.55 9.45 3 11.16 3 13c0 4.97 4.02 9 9 9 1.84 0 3.55-.55 4.98-1.5l2.5 2.5 1.27-1.27-7.71-7.71L3.02 4zM12 20c-3.87 0-7-3.13-7-7 0-1.28.35-2.48.95-3.52l9.56 9.56c-1.03.61-2.23.96-3.51.96z"/></g> +<g id="tonality"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.94-.49-7-3.85-7-7.93s3.05-7.44 7-7.93v15.86zm2-15.86c1.03.13 2 .45 2.87.93H13v-.93zM13 7h5.24c.25.31.48.65.68 1H13V7zm0 3h6.74c.08.33.15.66.19 1H13v-1zm0 9.93V19h2.87c-.87.48-1.84.8-2.87.93zM18.24 17H13v-1h5.92c-.2.35-.43.69-.68 1zm1.5-3H13v-1h6.93c-.04.34-.11.67-.19 1z"/></g> +<g id="transform"><path d="M22 18v-2H8V4h2L7 1 4 4h2v2H2v2h4v8c0 1.1.9 2 2 2h8v2h-2l3 3 3-3h-2v-2h4zM10 8h6v6h2V8c0-1.1-.9-2-2-2h-6v2z"/></g> +<g id="tune"><path d="M3 17v2h6v-2H3zM3 5v2h10V5H3zm10 16v-2h8v-2h-8v-2h-2v6h2zM7 9v2H3v2h4v2h2V9H7zm14 4v-2H11v2h10zm-6-4h2V7h4V5h-4V3h-2v6z"/></g> +<g id="view-comfy"><path d="M3 9h4V5H3v4zm0 5h4v-4H3v4zm5 0h4v-4H8v4zm5 0h4v-4h-4v4zM8 9h4V5H8v4zm5-4v4h4V5h-4zm5 9h4v-4h-4v4zM3 19h4v-4H3v4zm5 0h4v-4H8v4zm5 0h4v-4h-4v4zm5 0h4v-4h-4v4zm0-14v4h4V5h-4z"/></g> +<g id="view-compact"><path d="M3 19h6v-7H3v7zm7 0h12v-7H10v7zM3 5v6h19V5H3z"/></g> +<g id="vignette"><path d="M21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-9 15c-4.42 0-8-2.69-8-6s3.58-6 8-6 8 2.69 8 6-3.58 6-8 6z"/></g> +<g id="wb-auto"><path d="M6.85 12.65h2.3L8 9l-1.15 3.65zM22 7l-1.2 6.29L19.3 7h-1.6l-1.49 6.29L15 7h-.76C12.77 5.17 10.53 4 8 4c-4.42 0-8 3.58-8 8s3.58 8 8 8c3.13 0 5.84-1.81 7.15-4.43l.1.43H17l1.5-6.1L20 16h1.75l2.05-9H22zm-11.7 9l-.7-2H6.4l-.7 2H3.8L7 7h2l3.2 9h-1.9z"/></g> +<g id="wb-cloudy"><path d="M19.36 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.64-4.96z"/></g> +<g id="wb-incandescent"><path d="M3.55 18.54l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8zM11 22.45h2V19.5h-2v2.95zM4 10.5H1v2h3v-2zm11-4.19V1.5H9v4.81C7.21 7.35 6 9.28 6 11.5c0 3.31 2.69 6 6 6s6-2.69 6-6c0-2.22-1.21-4.15-3-5.19zm5 4.19v2h3v-2h-3zm-2.76 7.66l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4z"/></g> +<g id="wb-iridescent"><path d="M5 14.5h14v-6H5v6zM11 .55V3.5h2V.55h-2zm8.04 2.5l-1.79 1.79 1.41 1.41 1.8-1.79-1.42-1.41zM13 22.45V19.5h-2v2.95h2zm7.45-3.91l-1.8-1.79-1.41 1.41 1.79 1.8 1.42-1.42zM3.55 4.46l1.79 1.79 1.41-1.41-1.79-1.79-1.41 1.41zm1.41 15.49l1.79-1.8-1.41-1.41-1.79 1.79 1.41 1.42z"/></g> +<g id="wb-sunny"><path d="M6.76 4.84l-1.8-1.79-1.41 1.41 1.79 1.79 1.42-1.41zM4 10.5H1v2h3v-2zm9-9.95h-2V3.5h2V.55zm7.45 3.91l-1.41-1.41-1.79 1.79 1.41 1.41 1.79-1.79zm-3.21 13.7l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4zM20 10.5v2h3v-2h-3zm-8-5c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm-1 16.95h2V19.5h-2v2.95zm-7.45-3.91l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/index.html b/third_party/polymer/v1_0/components/iron-icons/index.html new file mode 100644 index 0000000..95d1991 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-icons/iron-icons.html b/third_party/polymer/v1_0/components/iron-icons/iron-icons.html new file mode 100644 index 0000000..c0cf1e9 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/iron-icons.html @@ -0,0 +1,303 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!-- +`iron-icons` is a utitliy import that includes the definition for the `iron-icon` element, `iron-iconset-svg` element, as well as an import for the default icon set. + +The `iron-icons` directory also includes imports for additional icon sets that can be loaded into your project. + +Example loading icon set: + + <link rel="import" href="../iron-icons/maps-icons.html"> + +To use an icon from one of these sets, first prefix your `iron-icon` with the icon set name, followed by a colon, ":", and then the icon id. + +Example using the directions-bus icon from the maps icon set: + + <iron-icon icon="maps:directions-bus"></iron-icon> + + +See [iron-icon](#iron-icon) for more information about working with icons. + +See [iron-iconset](#iron-iconset) and [iron-iconset-svg](#iron-iconset-svg) for more information about how to create a custom iconset. + +@group Iron Elements +@element iron-icons +@demo demo/index.html +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="icons" size="24"> +<svg><defs> +<g id="3d-rotation"><path d="M7.52 21.48C4.25 19.94 1.91 16.76 1.55 13H.05C.56 19.16 5.71 24 12 24l.66-.03-3.81-3.81-1.33 1.32zm.89-6.52c-.19 0-.37-.03-.52-.08-.16-.06-.29-.13-.4-.24-.11-.1-.2-.22-.26-.37-.06-.14-.09-.3-.09-.47h-1.3c0 .36.07.68.21.95.14.27.33.5.56.69.24.18.51.32.82.41.3.1.62.15.96.15.37 0 .72-.05 1.03-.15.32-.1.6-.25.83-.44s.42-.43.55-.72c.13-.29.2-.61.2-.97 0-.19-.02-.38-.07-.56-.05-.18-.12-.35-.23-.51-.1-.16-.24-.3-.4-.43-.17-.13-.37-.23-.61-.31.2-.09.37-.2.52-.33.15-.13.27-.27.37-.42.1-.15.17-.3.22-.46.05-.16.07-.32.07-.48 0-.36-.06-.68-.18-.96-.12-.28-.29-.51-.51-.69-.2-.19-.47-.33-.77-.43C9.1 8.05 8.76 8 8.39 8c-.36 0-.69.05-1 .16-.3.11-.57.26-.79.45-.21.19-.38.41-.51.67-.12.26-.18.54-.18.85h1.3c0-.17.03-.32.09-.45s.14-.25.25-.34c.11-.09.23-.17.38-.22.15-.05.3-.08.48-.08.4 0 .7.1.89.31.19.2.29.49.29.86 0 .18-.03.34-.08.49-.05.15-.14.27-.25.37-.11.1-.25.18-.41.24-.16.06-.36.09-.58.09H7.5v1.03h.77c.22 0 .42.02.6.07s.33.13.45.23c.12.11.22.24.29.4.07.16.1.35.1.57 0 .41-.12.72-.35.93-.23.23-.55.33-.95.33zm8.55-5.92c-.32-.33-.7-.59-1.14-.77-.43-.18-.92-.27-1.46-.27H12v8h2.3c.55 0 1.06-.09 1.51-.27.45-.18.84-.43 1.16-.76.32-.33.57-.73.74-1.19.17-.47.26-.99.26-1.57v-.4c0-.58-.09-1.1-.26-1.57-.18-.47-.43-.87-.75-1.2zm-.39 3.16c0 .42-.05.79-.14 1.13-.1.33-.24.62-.43.85-.19.23-.43.41-.71.53-.29.12-.62.18-.99.18h-.91V9.12h.97c.72 0 1.27.23 1.64.69.38.46.57 1.12.57 1.99v.4zM12 0l-.66.03 3.81 3.81 1.33-1.33c3.27 1.55 5.61 4.72 5.96 8.48h1.5C23.44 4.84 18.29 0 12 0z"/></g> +<g id="accessibility"><path d="M12 2c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm9 7h-6v13h-2v-6h-2v6H9V9H3V7h18v2z"/></g> +<g id="account-balance"><path d="M4 10v7h3v-7H4zm6 0v7h3v-7h-3zM2 22h19v-3H2v3zm14-12v7h3v-7h-3zm-4.5-9L2 6v2h19V6l-9.5-5z"/></g> +<g id="account-balance-wallet"><path d="M21 18v1c0 1.1-.9 2-2 2H5c-1.11 0-2-.9-2-2V5c0-1.1.89-2 2-2h14c1.1 0 2 .9 2 2v1h-9c-1.11 0-2 .9-2 2v8c0 1.1.89 2 2 2h9zm-9-2h10V8H12v8zm4-2.5c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="account-box"><path d="M3 5v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2H5c-1.11 0-2 .9-2 2zm12 4c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3zm-9 8c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1H6v-1z"/></g> +<g id="account-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm0 14.2c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08 1.99 0 5.97 1.09 6 3.08-1.29 1.94-3.5 3.22-6 3.22z"/></g> +<g id="add"><path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/></g> +<g id="add-alert"><path d="M10.01 21.01c0 1.1.89 1.99 1.99 1.99s1.99-.89 1.99-1.99h-3.98zm8.87-4.19V11c0-3.25-2.25-5.97-5.29-6.69v-.72C13.59 2.71 12.88 2 12 2s-1.59.71-1.59 1.59v.72C7.37 5.03 5.12 7.75 5.12 11v5.82L3 18.94V20h18v-1.06l-2.12-2.12zM16 13.01h-3v3h-2v-3H8V11h3V8h2v3h3v2.01z"/></g> +<g id="add-box"><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"/></g> +<g id="add-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm5 11h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"/></g> +<g id="add-circle-outline"><path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="add-shopping-cart"><path d="M11 9h2V6h3V4h-3V1h-2v3H8v2h3v3zm-4 9c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zm10 0c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2zm-9.83-3.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.86-7.01L19.42 4h-.01l-1.1 2-2.76 5H8.53l-.13-.27L6.16 6l-.95-2-.94-2H1v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.13 0-.25-.11-.25-.25z"/></g> +<g id="alarm"><path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="alarm-add"><path d="M7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm1-11h-2v3H8v2h3v3h2v-3h3v-2h-3V9z"/></g> +<g id="alarm-off"><path d="M12 6c3.87 0 7 3.13 7 7 0 .84-.16 1.65-.43 2.4l1.52 1.52c.58-1.19.91-2.51.91-3.92 0-4.97-4.03-9-9-9-1.41 0-2.73.33-3.92.91L9.6 6.43C10.35 6.16 11.16 6 12 6zm10-.28l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM2.92 2.29L1.65 3.57 2.98 4.9l-1.11.93 1.42 1.42 1.11-.94.8.8C3.83 8.69 3 10.75 3 13c0 4.97 4.02 9 9 9 2.25 0 4.31-.83 5.89-2.2l2.2 2.2 1.27-1.27L3.89 3.27l-.97-.98zm13.55 16.1C15.26 19.39 13.7 20 12 20c-3.87 0-7-3.13-7-7 0-1.7.61-3.26 1.61-4.47l9.86 9.86zM8.02 3.28L6.6 1.86l-.86.71 1.42 1.42.86-.71z"/></g> +<g id="alarm-on"><path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9c4.97 0 9-4.03 9-9s-4.03-9-9-9zm0 16c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7zm-1.46-5.47L8.41 12.4l-1.06 1.06 3.18 3.18 6-6-1.06-1.06-4.93 4.95z"/></g> +<g id="android"><path d="M6 18c0 .55.45 1 1 1h1v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h2v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h1c.55 0 1-.45 1-1V8H6v10zM3.5 8C2.67 8 2 8.67 2 9.5v7c0 .83.67 1.5 1.5 1.5S5 17.33 5 16.5v-7C5 8.67 4.33 8 3.5 8zm17 0c-.83 0-1.5.67-1.5 1.5v7c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5v-7c0-.83-.67-1.5-1.5-1.5zm-4.97-5.84l1.3-1.3c.2-.2.2-.51 0-.71-.2-.2-.51-.2-.71 0l-1.48 1.48C13.85 1.23 12.95 1 12 1c-.96 0-1.86.23-2.66.63L7.85.15c-.2-.2-.51-.2-.71 0-.2.2-.2.51 0 .71l1.31 1.31C6.97 3.26 6 5.01 6 7h12c0-1.99-.97-3.75-2.47-4.84zM10 5H9V4h1v1zm5 0h-1V4h1v1z"/></g> +<g id="announcement"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 9h-2V5h2v6zm0 4h-2v-2h2v2z"/></g> +<g id="apps"><path d="M4 8h4V4H4v4zm6 12h4v-4h-4v4zm-6 0h4v-4H4v4zm0-6h4v-4H4v4zm6 0h4v-4h-4v4zm6-10v4h4V4h-4zm-6 4h4V4h-4v4zm6 6h4v-4h-4v4zm0 6h4v-4h-4v4z"/></g> +<g id="archive"><path d="M20.54 5.23l-1.39-1.68C18.88 3.21 18.47 3 18 3H6c-.47 0-.88.21-1.16.55L3.46 5.23C3.17 5.57 3 6.02 3 6.5V19c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6.5c0-.48-.17-.93-.46-1.27zM12 17.5L6.5 12H10v-2h4v2h3.5L12 17.5zM5.12 5l.81-1h12l.94 1H5.12z"/></g> +<g id="arrow-back"><path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z"/></g> +<g id="arrow-drop-down"><path d="M7 10l5 5 5-5z"/></g> +<g id="arrow-drop-down-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 12l-4-4h8l-4 4z"/></g> +<g id="arrow-drop-up"><path d="M7 14l5-5 5 5z"/></g> +<g id="arrow-forward"><path d="M12 4l-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8z"/></g> +<g id="aspect-ratio"><path d="M19 12h-2v3h-3v2h5v-5zM7 9h3V7H5v5h2V9zm14-6H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/></g> +<g id="assessment"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/></g> +<g id="assignment"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm2 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z"/></g> +<g id="assignment-ind"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm0 4c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H6v-1.4c0-2 4-3.1 6-3.1s6 1.1 6 3.1V19z"/></g> +<g id="assignment-late"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-6 15h-2v-2h2v2zm0-4h-2V8h2v6zm-1-9c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="assignment-return"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm4 12h-4v3l-5-5 5-5v3h4v4z"/></g> +<g id="assignment-returned"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm0 15l-5-5h3V9h4v4h3l-5 5z"/></g> +<g id="assignment-turned-in"><path d="M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm-2 14l-4-4 1.41-1.41L10 14.17l6.59-6.59L18 9l-8 8z"/></g> +<g id="attachment"><path d="M7.5 18C4.46 18 2 15.54 2 12.5S4.46 7 7.5 7H18c2.21 0 4 1.79 4 4s-1.79 4-4 4H9.5C8.12 15 7 13.88 7 12.5S8.12 10 9.5 10H17v1.5H9.5c-.55 0-1 .45-1 1s.45 1 1 1H18c1.38 0 2.5-1.12 2.5-2.5S19.38 8.5 18 8.5H7.5c-2.21 0-4 1.79-4 4s1.79 4 4 4H17V18H7.5z"/></g> +<g id="autorenew"><path d="M12 6v3l4-4-4-4v3c-4.42 0-8 3.58-8 8 0 1.57.46 3.03 1.24 4.26L6.7 14.8c-.45-.83-.7-1.79-.7-2.8 0-3.31 2.69-6 6-6zm6.76 1.74L17.3 9.2c.44.84.7 1.79.7 2.8 0 3.31-2.69 6-6 6v-3l-4 4 4 4v-3c4.42 0 8-3.58 8-8 0-1.57-.46-3.03-1.24-4.26z"/></g> +<g id="backspace"><path d="M22 3H7c-.69 0-1.23.35-1.59.88L0 12l5.41 8.11c.36.53.9.89 1.59.89h15c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-3 12.59L17.59 17 14 13.41 10.41 17 9 15.59 12.59 12 9 8.41 10.41 7 14 10.59 17.59 7 19 8.41 15.41 12 19 15.59z"/></g> +<g id="backup"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM14 13v4h-4v-4H7l5-5 5 5h-3z"/></g> +<g id="block"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM4 12c0-4.42 3.58-8 8-8 1.85 0 3.55.63 4.9 1.69L5.69 16.9C4.63 15.55 4 13.85 4 12zm8 8c-1.85 0-3.55-.63-4.9-1.69L18.31 7.1C19.37 8.45 20 10.15 20 12c0 4.42-3.58 8-8 8z"/></g> +<g id="book"><path d="M18 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 4h5v8l-2.5-1.5L6 12V4z"/></g> +<g id="bookmark"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2z"/></g> +<g id="bookmark-border"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2zm0 15l-5-2.18L7 18V5h10v13z"/></g> +<g id="bug-report"><path d="M20 8h-2.81c-.45-.78-1.07-1.45-1.82-1.96L17 4.41 15.59 3l-2.17 2.17C12.96 5.06 12.49 5 12 5c-.49 0-.96.06-1.41.17L8.41 3 7 4.41l1.62 1.63C7.88 6.55 7.26 7.22 6.81 8H4v2h2.09c-.05.33-.09.66-.09 1v1H4v2h2v1c0 .34.04.67.09 1H4v2h2.81c1.04 1.79 2.97 3 5.19 3s4.15-1.21 5.19-3H20v-2h-2.09c.05-.33.09-.66.09-1v-1h2v-2h-2v-1c0-.34-.04-.67-.09-1H20V8zm-6 8h-4v-2h4v2zm0-4h-4v-2h4v2z"/></g> +<g id="build"><path d="M22.7 19l-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z"/></g> +<g id="cached"><path d="M19 8l-4 4h3c0 3.31-2.69 6-6 6-1.01 0-1.97-.25-2.8-.7l-1.46 1.46C8.97 19.54 10.43 20 12 20c4.42 0 8-3.58 8-8h3l-4-4zM6 12c0-3.31 2.69-6 6-6 1.01 0 1.97.25 2.8.7l1.46-1.46C15.03 4.46 13.57 4 12 4c-4.42 0-8 3.58-8 8H1l4 4 4-4H6z"/></g> +<g id="camera-enhance"><path d="M9 3L7.17 5H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2h-3.17L15 3H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zM12 17l1.25-2.75L16 13l-2.75-1.25L12 9l-1.25 2.75L8 13l2.75 1.25z"/></g> +<g id="cancel"><path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"/></g> +<g id="card-giftcard"><path d="M20 6h-2.18c.11-.31.18-.65.18-1 0-1.66-1.34-3-3-3-1.05 0-1.96.54-2.5 1.35l-.5.67-.5-.68C10.96 2.54 10.05 2 9 2 7.34 2 6 3.34 6 5c0 .35.07.69.18 1H4c-1.11 0-1.99.89-1.99 2L2 19c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zm-5-2c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zM9 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm11 15H4v-2h16v2zm0-5H4V8h5.08L7 10.83 8.62 12 11 8.76l1-1.36 1 1.36L15.38 12 17 10.83 14.92 8H20v6z"/></g> +<g id="card-membership"><path d="M20 2H4c-1.11 0-2 .89-2 2v11c0 1.11.89 2 2 2h4v5l4-2 4 2v-5h4c1.11 0 2-.89 2-2V4c0-1.11-.89-2-2-2zm0 13H4v-2h16v2zm0-5H4V4h16v6z"/></g> +<g id="card-travel"><path d="M20 6h-3V4c0-1.11-.89-2-2-2H9c-1.11 0-2 .89-2 2v2H4c-1.11 0-2 .89-2 2v11c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zM9 4h6v2H9V4zm11 15H4v-2h16v2zm0-5H4V8h3v2h2V8h6v2h2V8h3v6z"/></g> +<g id="change-history"><path d="M12 7.77L18.39 18H5.61L12 7.77M12 4L2 20h20L12 4z"/></g> +<g id="check"><path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></g> +<g id="check-box"><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></g> +<g id="check-box-outline-blank"><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="check-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></g> +<g id="chevron-left"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></g> +<g id="chevron-right"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></g> +<g id="chrome-reader-mode"><path d="M13 12h7v1.5h-7zm0-2.5h7V11h-7zm0 5h7V16h-7zM21 4H3c-1.1 0-2 .9-2 2v13c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 15h-9V6h9v13z"/></g> +<g id="class"><path d="M18 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 4h5v8l-2.5-1.5L6 12V4z"/></g> +<g id="clear"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></g> +<g id="close"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></g> +<g id="cloud"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96z"/></g> +<g id="cloud-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm4.5 14H8c-1.66 0-3-1.34-3-3s1.34-3 3-3l.14.01C8.58 8.28 10.13 7 12 7c2.21 0 4 1.79 4 4h.5c1.38 0 2.5 1.12 2.5 2.5S17.88 16 16.5 16z"/></g> +<g id="cloud-done"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM10 17l-3.5-3.5 1.41-1.41L10 14.17 15.18 9l1.41 1.41L10 17z"/></g> +<g id="cloud-download"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM17 13l-5 5-5-5h3V9h4v4h3z"/></g> +<g id="cloud-off"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4c-1.48 0-2.85.43-4.01 1.17l1.46 1.46C10.21 6.23 11.08 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3 0 1.13-.64 2.11-1.56 2.62l1.45 1.45C23.16 18.16 24 16.68 24 15c0-2.64-2.05-4.78-4.65-4.96zM3 5.27l2.75 2.74C2.56 8.15 0 10.77 0 14c0 3.31 2.69 6 6 6h11.73l2 2L21 20.73 4.27 4 3 5.27zM7.73 10l8 8H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h1.73z"/></g> +<g id="cloud-queue"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h.71C7.37 7.69 9.48 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3s-1.34 3-3 3z"/></g> +<g id="cloud-upload"><path d="M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM14 13v4h-4v-4H7l5-5 5 5h-3z"/></g> +<g id="code"><path d="M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z"/></g> +<g id="content-copy"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></g> +<g id="content-cut"><path d="M9.64 7.64c.23-.5.36-1.05.36-1.64 0-2.21-1.79-4-4-4S2 3.79 2 6s1.79 4 4 4c.59 0 1.14-.13 1.64-.36L10 12l-2.36 2.36C7.14 14.13 6.59 14 6 14c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4c0-.59-.13-1.14-.36-1.64L12 14l7 7h3v-1L9.64 7.64zM6 8c-1.1 0-2-.89-2-2s.9-2 2-2 2 .89 2 2-.9 2-2 2zm0 12c-1.1 0-2-.89-2-2s.9-2 2-2 2 .89 2 2-.9 2-2 2zm6-7.5c-.28 0-.5-.22-.5-.5s.22-.5.5-.5.5.22.5.5-.22.5-.5.5zM19 3l-6 6 2 2 7-7V3z"/></g> +<g id="content-paste"><path d="M19 2h-4.18C14.4.84 13.3 0 12 0c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm7 18H5V4h2v3h10V4h2v16z"/></g> +<g id="create"><path d="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"/></g> +<g id="credit-card"><path d="M20 4H4c-1.11 0-1.99.89-1.99 2L2 18c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6c0-1.11-.89-2-2-2zm0 14H4v-6h16v6zm0-10H4V6h16v2z"/></g> +<g id="dashboard"><path d="M3 13h8V3H3v10zm0 8h8v-6H3v6zm10 0h8V11h-8v10zm0-18v6h8V3h-8z"/></g> +<g id="delete"><path d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"/></g> +<g id="description"><path d="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z"/></g> +<g id="dns"><path d="M20 13H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zM7 19c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM20 3H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1zM7 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="done"><path d="M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z"/></g> +<g id="done-all"><path d="M18 7l-1.41-1.41-6.34 6.34 1.41 1.41L18 7zm4.24-1.41L11.66 16.17 7.48 12l-1.41 1.41L11.66 19l12-12-1.42-1.41zM.41 13.41L6 19l1.41-1.41L1.83 12 .41 13.41z"/></g> +<g id="drafts"><path d="M21.99 8c0-.72-.37-1.35-.94-1.7L12 1 2.95 6.3C2.38 6.65 2 7.28 2 8v10c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2l-.01-10zM12 13L3.74 7.84 12 3l8.26 4.84L12 13z"/></g> +<g id="eject"><path d="M5 17h14v2H5zm7-12L5.33 15h13.34z"/></g> +<g id="error"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></g> +<g id="error-outline"><path d="M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="event"><path d="M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"/></g> +<g id="event-seat"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M4 18v3h3v-3h10v3h3v-6H4zm15-8h3v3h-3zM2 10h3v3H2zm15 3H7V5c0-1.1.9-2 2-2h6c1.1 0 2 .9 2 2v8z" clip-path="url(#b)"/></g> +<g id="exit-to-app"><path d="M10.09 15.59L11.5 17l5-5-5-5-1.41 1.41L12.67 11H3v2h9.67l-2.58 2.59zM19 3H5c-1.11 0-2 .9-2 2v4h2V5h14v14H5v-4H3v4c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></g> +<g id="expand-less"><path d="M12 8l-6 6 1.41 1.41L12 10.83l4.59 4.58L18 14z"/></g> +<g id="expand-more"><path d="M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"/></g> +<g id="explore"><path d="M12 10.9c-.61 0-1.1.49-1.1 1.1s.49 1.1 1.1 1.1c.61 0 1.1-.49 1.1-1.1s-.49-1.1-1.1-1.1zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm2.19 12.19L6 18l3.81-8.19L18 6l-3.81 8.19z"/></g> +<g id="extension"><path d="M20.5 11H19V7c0-1.1-.9-2-2-2h-4V3.5C13 2.12 11.88 1 10.5 1S8 2.12 8 3.5V5H4c-1.1 0-1.99.9-1.99 2v3.8H3.5c1.49 0 2.7 1.21 2.7 2.7s-1.21 2.7-2.7 2.7H2V20c0 1.1.9 2 2 2h3.8v-1.5c0-1.49 1.21-2.7 2.7-2.7 1.49 0 2.7 1.21 2.7 2.7V22H17c1.1 0 2-.9 2-2v-4h1.5c1.38 0 2.5-1.12 2.5-2.5S21.88 11 20.5 11z"/></g> +<g id="face"><path d="M9 11.75c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zm6 0c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8 0-.29.02-.58.05-.86 2.36-1.05 4.23-2.98 5.21-5.37C11.07 8.33 14.05 10 17.42 10c.78 0 1.53-.09 2.25-.26.21.71.33 1.47.33 2.26 0 4.41-3.59 8-8 8z"/></g> +<g id="favorite"><path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"/></g> +<g id="favorite-border"><path d="M16.5 3c-1.74 0-3.41.81-4.5 2.09C10.91 3.81 9.24 3 7.5 3 4.42 3 2 5.42 2 8.5c0 3.78 3.4 6.86 8.55 11.54L12 21.35l1.45-1.32C18.6 15.36 22 12.28 22 8.5 22 5.42 19.58 3 16.5 3zm-4.4 15.55l-.1.1-.1-.1C7.14 14.24 4 11.39 4 8.5 4 6.5 5.5 5 7.5 5c1.54 0 3.04.99 3.57 2.36h1.87C13.46 5.99 14.96 5 16.5 5c2 0 3.5 1.5 3.5 3.5 0 2.89-3.14 5.74-7.9 10.05z"/></g> +<g id="feedback"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 12h-2v-2h2v2zm0-4h-2V6h2v4z"/></g> +<g id="file-download"><path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/></g> +<g id="file-upload"><path d="M9 16h6v-6h4l-7-7-7 7h4zm-4 2h14v2H5z"/></g> +<g id="filter-list"><path d="M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"/></g> +<g id="find-in-page"><path d="M20 19.59V8l-6-6H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c.45 0 .85-.15 1.19-.4l-4.43-4.43c-.8.52-1.74.83-2.76.83-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5c0 1.02-.31 1.96-.83 2.75L20 19.59zM9 13c0 1.66 1.34 3 3 3s3-1.34 3-3-1.34-3-3-3-3 1.34-3 3z"/></g> +<g id="find-replace"><path d="M11 6c1.38 0 2.63.56 3.54 1.46L12 10h6V4l-2.05 2.05C14.68 4.78 12.93 4 11 4c-3.53 0-6.43 2.61-6.92 6H6.1c.46-2.28 2.48-4 4.9-4zm5.64 9.14c.66-.9 1.12-1.97 1.28-3.14H15.9c-.46 2.28-2.48 4-4.9 4-1.38 0-2.63-.56-3.54-1.46L10 12H4v6l2.05-2.05C7.32 17.22 9.07 18 11 18c1.55 0 2.98-.51 4.14-1.36L20 21.49 21.49 20l-4.85-4.86z"/></g> +<g id="flag"><path d="M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6z"/></g> +<g id="flight-land"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><defs><path id="c" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><clipPath id="d" clip-path="url(#b)"><use xlink:href="#c" overflow="visible"/></clipPath><path d="M2.5 19h19v2h-19zm7.18-5.73l4.35 1.16 5.31 1.42c.8.21 1.62-.26 1.84-1.06.21-.8-.26-1.62-1.06-1.84l-5.31-1.42-2.76-9.02L10.12 2v8.28L5.15 8.95l-.93-2.32-1.45-.39v5.17l1.6.43 5.31 1.43z" clip-path="url(#d)"/></g> +<g id="flight-takeoff"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M2.5 19h19v2h-19zm19.57-9.36c-.21-.8-1.04-1.28-1.84-1.06L14.92 10l-6.9-6.43-1.93.51 4.14 7.17-4.97 1.33-1.97-1.54-1.45.39 1.82 3.16.77 1.33 1.6-.43 5.31-1.42 4.35-1.16L21 11.49c.81-.23 1.28-1.05 1.07-1.85z" clip-path="url(#b)"/></g> +<g id="flip-to-back"><path d="M9 7H7v2h2V7zm0 4H7v2h2v-2zm0-8c-1.11 0-2 .9-2 2h2V3zm4 12h-2v2h2v-2zm6-12v2h2c0-1.1-.9-2-2-2zm-6 0h-2v2h2V3zM9 17v-2H7c0 1.1.89 2 2 2zm10-4h2v-2h-2v2zm0-4h2V7h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zM5 7H3v12c0 1.1.89 2 2 2h12v-2H5V7zm10-2h2V3h-2v2zm0 12h2v-2h-2v2z"/></g> +<g id="flip-to-front"><path d="M3 13h2v-2H3v2zm0 4h2v-2H3v2zm2 4v-2H3c0 1.1.89 2 2 2zM3 9h2V7H3v2zm12 12h2v-2h-2v2zm4-18H9c-1.11 0-2 .9-2 2v10c0 1.1.89 2 2 2h10c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 12H9V5h10v10zm-8 6h2v-2h-2v2zm-4 0h2v-2H7v2z"/></g> +<g id="folder"><path d="M10 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2h-8l-2-2z"/></g> +<g id="folder-open"><path d="M20 6h-8l-2-2H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm0 12H4V8h16v10z"/></g> +<g id="folder-shared"><path d="M20 6h-8l-2-2H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-5 3c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm4 8h-8v-1c0-1.33 2.67-2 4-2s4 .67 4 2v1z"/></g> +<g id="font-download"><path d="M9.93 13.5h4.14L12 7.98zM20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-4.05 16.5l-1.14-3H9.17l-1.12 3H5.96l5.11-13h1.86l5.11 13h-2.09z"/></g> +<g id="forward"><path d="M12 8V4l8 8-8 8v-4H4V8z"/></g> +<g id="fullscreen"><path d="M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"/></g> +<g id="fullscreen-exit"><path d="M5 16h3v3h2v-5H5v2zm3-8H5v2h5V5H8v3zm6 11h2v-3h3v-2h-5v5zm2-11V5h-2v5h5V8h-3z"/></g> +<g id="gesture"><path d="M4.59 6.89c.7-.71 1.4-1.35 1.71-1.22.5.2 0 1.03-.3 1.52-.25.42-2.86 3.89-2.86 6.31 0 1.28.48 2.34 1.34 2.98.75.56 1.74.73 2.64.46 1.07-.31 1.95-1.4 3.06-2.77 1.21-1.49 2.83-3.44 4.08-3.44 1.63 0 1.65 1.01 1.76 1.79-3.78.64-5.38 3.67-5.38 5.37 0 1.7 1.44 3.09 3.21 3.09 1.63 0 4.29-1.33 4.69-6.1H21v-2.5h-2.47c-.15-1.65-1.09-4.2-4.03-4.2-2.25 0-4.18 1.91-4.94 2.84-.58.73-2.06 2.48-2.29 2.72-.25.3-.68.84-1.11.84-.45 0-.72-.83-.36-1.92.35-1.09 1.4-2.86 1.85-3.52.78-1.14 1.3-1.92 1.3-3.28C8.95 3.69 7.31 3 6.44 3 5.12 3 3.97 4 3.72 4.25c-.36.36-.66.66-.88.93l1.75 1.71zm9.29 11.66c-.31 0-.74-.26-.74-.72 0-.6.73-2.2 2.87-2.76-.3 2.69-1.43 3.48-2.13 3.48z"/></g> +<g id="get-app"><path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/></g> +<g id="gif"><defs><path id="a" d="M24 24H0V0h24v24z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M11.5 9H13v6h-1.5zM9 9H6c-.6 0-1 .5-1 1v4c0 .5.4 1 1 1h3c.6 0 1-.5 1-1v-2H8.5v1.5h-2v-3H10V10c0-.5-.4-1-1-1zm10 1.5V9h-4.5v6H16v-2h2v-1.5h-2v-1z" clip-path="url(#b)"/></g> +<g id="grade"><path d="M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"/></g> +<g id="group-work"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM8 17.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5zM9.5 8c0-1.38 1.12-2.5 2.5-2.5s2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5S9.5 9.38 9.5 8zm6.5 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="help"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 17h-2v-2h2v2zm2.07-7.75l-.9.92C13.45 12.9 13 13.5 13 15h-2v-.5c0-1.1.45-2.1 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41 0-1.1-.9-2-2-2s-2 .9-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 .88-.36 1.68-.93 2.25z"/></g> +<g id="help-outline"><path d="M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4z"/></g> +<g id="highlight-off"><path d="M14.59 8L12 10.59 9.41 8 8 9.41 10.59 12 8 14.59 9.41 16 12 13.41 14.59 16 16 14.59 13.41 12 16 9.41 14.59 8zM12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="history"><path opacity=".9" d="M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9zm-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8H12z"/></g> +<g id="home"><path d="M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z"/></g> +<g id="hourglass-empty"><path d="M6 2v6h.01L6 8.01 10 12l-4 4 .01.01H6V22h12v-5.99h-.01L18 16l-4-4 4-3.99-.01-.01H18V2H6zm10 14.5V20H8v-3.5l4-4 4 4zm-4-5l-4-4V4h8v3.5l-4 4z"/></g> +<g id="hourglass-full"><path d="M6 2v6h.01L6 8.01 10 12l-4 4 .01.01H6V22h12v-5.99h-.01L18 16l-4-4 4-3.99-.01-.01H18V2H6z"/></g> +<g id="http"><path d="M4.5 11h-2V9H1v6h1.5v-2.5h2V15H6V9H4.5v2zm2.5-.5h1.5V15H10v-4.5h1.5V9H7v1.5zm5.5 0H14V15h1.5v-4.5H17V9h-4.5v1.5zm9-1.5H18v6h1.5v-2h2c.8 0 1.5-.7 1.5-1.5v-1c0-.8-.7-1.5-1.5-1.5zm0 2.5h-2v-1h2v1z"/></g> +<g id="https"><path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"/></g> +<g id="inbox"><path d="M19 3H4.99c-1.1 0-1.98.9-1.98 2L3 19c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 12h-4c0 1.66-1.34 3-3 3s-3-1.34-3-3H4.99V5H19v10zm-3-5h-2V7h-4v3H8l4 4 4-4z"/></g> +<g id="indeterminate-check-box"><defs><path id="a" d="M0 0h24v24H0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path clip-path="url(#b)" d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"/></g> +<g id="info"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/></g> +<g id="info-outline"><path d="M11 17h2v-6h-2v6zm1-15C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zM11 9h2V7h-2v2z"/></g> +<g id="input"><path d="M21 3.01H3c-1.1 0-2 .9-2 2V9h2V4.99h18v14.03H3V15H1v4.01c0 1.1.9 1.98 2 1.98h18c1.1 0 2-.88 2-1.98v-14c0-1.11-.9-2-2-2zM11 16l4-4-4-4v3H1v2h10v3z"/></g> +<g id="invert-colors"><path d="M17.66 7.93L12 2.27 6.34 7.93c-3.12 3.12-3.12 8.19 0 11.31C7.9 20.8 9.95 21.58 12 21.58c2.05 0 4.1-.78 5.66-2.34 3.12-3.12 3.12-8.19 0-11.31zM12 19.59c-1.6 0-3.11-.62-4.24-1.76C6.62 16.69 6 15.19 6 13.59s.62-3.11 1.76-4.24L12 5.1v14.49z"/></g> +<g id="label"><path d="M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16z"/></g> +<g id="label-outline"><path d="M17.63 5.84C17.27 5.33 16.67 5 16 5L5 5.01C3.9 5.01 3 5.9 3 7v10c0 1.1.9 1.99 2 1.99L16 19c.67 0 1.27-.33 1.63-.84L22 12l-4.37-6.16zM16 17H5V7h11l3.55 5L16 17z"/></g> +<g id="language"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z"/></g> +<g id="launch"><path d="M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/></g> +<g id="link"><path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5z"/></g> +<g id="list"><path d="M3 13h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2V7H3v2zm4 4h14v-2H7v2zm0 4h14v-2H7v2zM7 7v2h14V7H7z"/></g> +<g id="lock"><path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"/></g> +<g id="lock-open"><path d="M12 17c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm6-9h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6h1.9c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm0 12H6V10h12v10z"/></g> +<g id="lock-outline"><path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6-5.1c1.71 0 3.1 1.39 3.1 3.1v2H9V6h-.1c0-1.71 1.39-3.1 3.1-3.1zM18 20H6V10h12v10zm-6-3c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2z"/></g> +<g id="loyalty"><path d="M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58.55 0 1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41 0-.55-.23-1.06-.59-1.42zM5.5 7C4.67 7 4 6.33 4 5.5S4.67 4 5.5 4 7 4.67 7 5.5 6.33 7 5.5 7zm11.77 8.27L13 19.54l-4.27-4.27C8.28 14.81 8 14.19 8 13.5c0-1.38 1.12-2.5 2.5-2.5.69 0 1.32.28 1.77.74l.73.72.73-.73c.45-.45 1.08-.73 1.77-.73 1.38 0 2.5 1.12 2.5 2.5 0 .69-.28 1.32-.73 1.77z"/></g> +<g id="mail"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="markunread"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="markunread-mailbox"><path d="M20 6H10v6H8V4h6V0H6v6H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2z"/></g> +<g id="menu"><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/></g> +<g id="more-horiz"><path d="M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="more-vert"><path d="M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="note-add"><path d="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 14h-3v3h-2v-3H8v-2h3v-3h2v3h3v2zm-3-7V3.5L18.5 9H13z"/></g> +<g id="offline-pin"><defs><path id="a" d="M0 0h24v24H0V0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path clip-path="url(#b)" d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zm5 16H7v-2h10v2zm-6.7-4L7 10.7l1.4-1.4 1.9 1.9 5.3-5.3L17 7.3 10.3 14z"/></g> +<g id="open-in-browser"><path d="M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.89 2 2 2h4v-2H5V8h14v10h-4v2h4c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm-7 6l-4 4h3v6h2v-6h3l-4-4z"/></g> +<g id="open-in-new"><path d="M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/></g> +<g id="open-with"><path d="M10 9h4V6h3l-5-5-5 5h3v3zm-1 1H6V7l-5 5 5 5v-3h3v-4zm14 2l-5-5v3h-3v4h3v3l5-5zm-9 3h-4v3H7l5 5 5-5h-3v-3z"/></g> +<g id="pageview"><path d="M11.5 9C10.12 9 9 10.12 9 11.5s1.12 2.5 2.5 2.5 2.5-1.12 2.5-2.5S12.88 9 11.5 9zM20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-3.21 14.21l-2.91-2.91c-.69.44-1.51.7-2.39.7C9.01 16 7 13.99 7 11.5S9.01 7 11.5 7 16 9.01 16 11.5c0 .88-.26 1.69-.7 2.39l2.91 2.9-1.42 1.42z"/></g> +<g id="payment"><path d="M20 4H4c-1.11 0-1.99.89-1.99 2L2 18c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6c0-1.11-.89-2-2-2zm0 14H4v-6h16v6zm0-10H4V6h16v2z"/></g> +<g id="perm-camera-mic"><path d="M20 5h-3.17L15 3H9L7.17 5H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h7v-2.09c-2.83-.48-5-2.94-5-5.91h2c0 2.21 1.79 4 4 4s4-1.79 4-4h2c0 2.97-2.17 5.43-5 5.91V21h7c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm-6 8c0 1.1-.9 2-2 2s-2-.9-2-2V9c0-1.1.9-2 2-2s2 .9 2 2v4z"/></g> +<g id="perm-contact-calendar"><path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm6 12H6v-1c0-2 4-3.1 6-3.1s6 1.1 6 3.1v1z"/></g> +<g id="perm-data-setting"><path d="M18.99 11.5c.34 0 .67.03 1 .07L20 0 0 20h11.56c-.04-.33-.07-.66-.07-1 0-4.14 3.36-7.5 7.5-7.5zm3.71 7.99c.02-.16.04-.32.04-.49 0-.17-.01-.33-.04-.49l1.06-.83c.09-.08.12-.21.06-.32l-1-1.73c-.06-.11-.19-.15-.31-.11l-1.24.5c-.26-.2-.54-.37-.85-.49l-.19-1.32c-.01-.12-.12-.21-.24-.21h-2c-.12 0-.23.09-.25.21l-.19 1.32c-.3.13-.59.29-.85.49l-1.24-.5c-.11-.04-.24 0-.31.11l-1 1.73c-.06.11-.04.24.06.32l1.06.83c-.02.16-.03.32-.03.49 0 .17.01.33.03.49l-1.06.83c-.09.08-.12.21-.06.32l1 1.73c.06.11.19.15.31.11l1.24-.5c.26.2.54.37.85.49l.19 1.32c.02.12.12.21.25.21h2c.12 0 .23-.09.25-.21l.19-1.32c.3-.13.59-.29.84-.49l1.25.5c.11.04.24 0 .31-.11l1-1.73c.06-.11.03-.24-.06-.32l-1.07-.83zm-3.71 1.01c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="perm-device-information"><path d="M13 7h-2v2h2V7zm0 4h-2v6h2v-6zm4-9.99L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/></g> +<g id="perm-identity"><path d="M12 5.9c1.16 0 2.1.94 2.1 2.1s-.94 2.1-2.1 2.1S9.9 9.16 9.9 8s.94-2.1 2.1-2.1m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z"/></g> +<g id="perm-media"><path d="M2 6H0v5h.01L0 20c0 1.1.9 2 2 2h18v-2H2V6zm20-2h-8l-2-2H6c-1.1 0-1.99.9-1.99 2L4 16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM7 15l4.5-6 3.5 4.51 2.5-3.01L21 15H7z"/></g> +<g id="perm-phone-msg"><path d="M20 15.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.58l2.2-2.21c.28-.27.36-.66.25-1.01C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM12 3v10l3-3h6V3h-9z"/></g> +<g id="perm-scan-wifi"><path d="M12 3C6.95 3 3.15 4.85 0 7.23L12 22 24 7.25C20.85 4.87 17.05 3 12 3zm1 13h-2v-6h2v6zm-2-8V6h2v2h-2z"/></g> +<g id="picture-in-picture"><path d="M19 7h-8v6h8V7zm2-4H3c-1.1 0-2 .9-2 2v14c0 1.1.9 1.98 2 1.98h18c1.1 0 2-.88 2-1.98V5c0-1.1-.9-2-2-2zm0 16.01H3V4.98h18v14.03z"/></g> +<g id="play-for-work"><path fill="#010101" d="M11 5v5.59H7.5l4.5 4.5 4.5-4.5H13V5h-2zm-5 9c0 3.31 2.69 6 6 6s6-2.69 6-6h-2c0 2.21-1.79 4-4 4s-4-1.79-4-4H6z"/></g> +<g id="polymer"><path d="M19 4h-4L7.11 16.63 4.5 12 9 4H5L.5 12 5 20h4l7.89-12.63L19.5 12 15 20h4l4.5-8z"/></g> +<g id="power-settings-new"><path d="M13 3h-2v10h2V3zm4.83 2.17l-1.42 1.42C17.99 7.86 19 9.81 19 12c0 3.87-3.13 7-7 7s-7-3.13-7-7c0-2.19 1.01-4.14 2.58-5.42L6.17 5.17C4.23 6.82 3 9.26 3 12c0 4.97 4.03 9 9 9s9-4.03 9-9c0-2.74-1.23-5.18-3.17-6.83z"/></g> +<g id="print"><path d="M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"/></g> +<g id="query-builder"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zM12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></g> +<g id="question-answer"><path d="M21 6h-2v9H6v2c0 .55.45 1 1 1h11l4 4V7c0-.55-.45-1-1-1zm-4 6V3c0-.55-.45-1-1-1H3c-.55 0-1 .45-1 1v14l4-4h10c.55 0 1-.45 1-1z"/></g> +<g id="radio-button-checked"><path d="M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="radio-button-unchecked"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/></g> +<g id="receipt"><path d="M18 17H6v-2h12v2zm0-4H6v-2h12v2zm0-4H6V7h12v2zM3 22l1.5-1.5L6 22l1.5-1.5L9 22l1.5-1.5L12 22l1.5-1.5L15 22l1.5-1.5L18 22l1.5-1.5L21 22V2l-1.5 1.5L18 2l-1.5 1.5L15 2l-1.5 1.5L12 2l-1.5 1.5L9 2 7.5 3.5 6 2 4.5 3.5 3 2v20z"/></g> +<g id="redeem"><path d="M20 6h-2.18c.11-.31.18-.65.18-1 0-1.66-1.34-3-3-3-1.05 0-1.96.54-2.5 1.35l-.5.67-.5-.68C10.96 2.54 10.05 2 9 2 7.34 2 6 3.34 6 5c0 .35.07.69.18 1H4c-1.11 0-1.99.89-1.99 2L2 19c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zm-5-2c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zM9 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm11 15H4v-2h16v2zm0-5H4V8h5.08L7 10.83 8.62 12 11 8.76l1-1.36 1 1.36L15.38 12 17 10.83 14.92 8H20v6z"/></g> +<g id="redo"><path d="M18.4 10.6C16.55 8.99 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16c1.05-3.19 4.05-5.5 7.6-5.5 1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"/></g> +<g id="refresh"><path d="M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z"/></g> +<g id="remove"><path d="M19 13H5v-2h14v2z"/></g> +<g id="remove-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm5 11H7v-2h10v2z"/></g> +<g id="remove-circle-outline"><path d="M7 11v2h10v-2H7zm5-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></g> +<g id="reorder"><path d="M3 15h18v-2H3v2zm0 4h18v-2H3v2zm0-8h18V9H3v2zm0-6v2h18V5H3z"/></g> +<g id="reply"><path d="M10 9V5l-7 7 7 7v-4.1c5 0 8.5 1.6 11 5.1-1-5-4-10-11-11z"/></g> +<g id="reply-all"><path d="M7 8V5l-7 7 7 7v-3l-4-4 4-4zm6 1V5l-7 7 7 7v-4.1c5 0 8.5 1.6 11 5.1-1-5-4-10-11-11z"/></g> +<g id="report"><path d="M15.73 3H8.27L3 8.27v7.46L8.27 21h7.46L21 15.73V8.27L15.73 3zM12 17.3c-.72 0-1.3-.58-1.3-1.3 0-.72.58-1.3 1.3-1.3.72 0 1.3.58 1.3 1.3 0 .72-.58 1.3-1.3 1.3zm1-4.3h-2V7h2v6z"/></g> +<g id="report-problem"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></g> +<g id="restore"><path d="M13 3c-4.97 0-9 4.03-9 9H1l3.89 3.89.07.14L9 12H6c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.93 0-3.68-.79-4.94-2.06l-1.42 1.42C8.27 19.99 10.51 21 13 21c4.97 0 9-4.03 9-9s-4.03-9-9-9zm-1 5v5l4.28 2.54.72-1.21-3.5-2.08V8H12z"/></g> +<g id="room"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="save"><path d="M17 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V7l-4-4zm-5 16c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm3-10H5V5h10v4z"/></g> +<g id="schedule"><path fill-opacity=".9" d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zM12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"/></g> +<g id="search"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"/></g> +<g id="select-all"><path d="M3 5h2V3c-1.1 0-2 .9-2 2zm0 8h2v-2H3v2zm4 8h2v-2H7v2zM3 9h2V7H3v2zm10-6h-2v2h2V3zm6 0v2h2c0-1.1-.9-2-2-2zM5 21v-2H3c0 1.1.9 2 2 2zm-2-4h2v-2H3v2zM9 3H7v2h2V3zm2 18h2v-2h-2v2zm8-8h2v-2h-2v2zm0 8c1.1 0 2-.9 2-2h-2v2zm0-12h2V7h-2v2zm0 8h2v-2h-2v2zm-4 4h2v-2h-2v2zm0-16h2V3h-2v2zM7 17h10V7H7v10zm2-8h6v6H9V9z"/></g> +<g id="send"><path d="M2.01 21L23 12 2.01 3 2 10l15 2-15 2z"/></g> +<g id="settings"><path d="M19.43 12.98c.04-.32.07-.64.07-.98s-.03-.66-.07-.98l2.11-1.65c.19-.15.24-.42.12-.64l-2-3.46c-.12-.22-.39-.3-.61-.22l-2.49 1c-.52-.4-1.08-.73-1.69-.98l-.38-2.65C14.46 2.18 14.25 2 14 2h-4c-.25 0-.46.18-.49.42l-.38 2.65c-.61.25-1.17.59-1.69.98l-2.49-1c-.23-.09-.49 0-.61.22l-2 3.46c-.13.22-.07.49.12.64l2.11 1.65c-.04.32-.07.65-.07.98s.03.66.07.98l-2.11 1.65c-.19.15-.24.42-.12.64l2 3.46c.12.22.39.3.61.22l2.49-1c.52.4 1.08.73 1.69.98l.38 2.65c.03.24.24.42.49.42h4c.25 0 .46-.18.49-.42l.38-2.65c.61-.25 1.17-.59 1.69-.98l2.49 1c.23.09.49 0 .61-.22l2-3.46c.12-.22.07-.49-.12-.64l-2.11-1.65zM12 15.5c-1.93 0-3.5-1.57-3.5-3.5s1.57-3.5 3.5-3.5 3.5 1.57 3.5 3.5-1.57 3.5-3.5 3.5z"/></g> +<g id="settings-applications"><path d="M12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm7-7H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-1.75 9c0 .23-.02.46-.05.68l1.48 1.16c.13.11.17.3.08.45l-1.4 2.42c-.09.15-.27.21-.43.15l-1.74-.7c-.36.28-.76.51-1.18.69l-.26 1.85c-.03.17-.18.3-.35.3h-2.8c-.17 0-.32-.13-.35-.29l-.26-1.85c-.43-.18-.82-.41-1.18-.69l-1.74.7c-.16.06-.34 0-.43-.15l-1.4-2.42c-.09-.15-.05-.34.08-.45l1.48-1.16c-.03-.23-.05-.46-.05-.69 0-.23.02-.46.05-.68l-1.48-1.16c-.13-.11-.17-.3-.08-.45l1.4-2.42c.09-.15.27-.21.43-.15l1.74.7c.36-.28.76-.51 1.18-.69l.26-1.85c.03-.17.18-.3.35-.3h2.8c.17 0 .32.13.35.29l.26 1.85c.43.18.82.41 1.18.69l1.74-.7c.16-.06.34 0 .43.15l1.4 2.42c.09.15.05.34-.08.45l-1.48 1.16c.03.23.05.46.05.69z"/></g> +<g id="settings-backup-restore"><path d="M14 12c0-1.1-.9-2-2-2s-2 .9-2 2 .9 2 2 2 2-.9 2-2zm-2-9c-4.97 0-9 4.03-9 9H0l4 4 4-4H5c0-3.87 3.13-7 7-7s7 3.13 7 7-3.13 7-7 7c-1.51 0-2.91-.49-4.06-1.3l-1.42 1.44C8.04 20.3 9.94 21 12 21c4.97 0 9-4.03 9-9s-4.03-9-9-9z"/></g> +<g id="settings-bluetooth"><path d="M11 24h2v-2h-2v2zm-4 0h2v-2H7v2zm8 0h2v-2h-2v2zm2.71-18.29L12 0h-1v7.59L6.41 3 5 4.41 10.59 10 5 15.59 6.41 17 11 12.41V20h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 3.83l1.88 1.88L13 7.59V3.83zm1.88 10.46L13 16.17v-3.76l1.88 1.88z"/></g> +<g id="settings-brightness"><path d="M21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02zM8 16h2.5l1.5 1.5 1.5-1.5H16v-2.5l1.5-1.5-1.5-1.5V8h-2.5L12 6.5 10.5 8H8v2.5L6.5 12 8 13.5V16zm4-7c1.66 0 3 1.34 3 3s-1.34 3-3 3V9z"/></g> +<g id="settings-cell"><path d="M7 24h2v-2H7v2zm4 0h2v-2h-2v2zm4 0h2v-2h-2v2zM16 .01L8 0C6.9 0 6 .9 6 2v16c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V2c0-1.1-.9-1.99-2-1.99zM16 16H8V4h8v12z"/></g> +<g id="settings-ethernet"><path d="M7.77 6.76L6.23 5.48.82 12l5.41 6.52 1.54-1.28L3.42 12l4.35-5.24zM7 13h2v-2H7v2zm10-2h-2v2h2v-2zm-6 2h2v-2h-2v2zm6.77-7.52l-1.54 1.28L20.58 12l-4.35 5.24 1.54 1.28L23.18 12l-5.41-6.52z"/></g> +<g id="settings-input-antenna"><path d="M12 5c-3.87 0-7 3.13-7 7h2c0-2.76 2.24-5 5-5s5 2.24 5 5h2c0-3.87-3.13-7-7-7zm1 9.29c.88-.39 1.5-1.26 1.5-2.29 0-1.38-1.12-2.5-2.5-2.5S9.5 10.62 9.5 12c0 1.02.62 1.9 1.5 2.29v3.3L7.59 21 9 22.41l3-3 3 3L16.41 21 13 17.59v-3.3zM12 1C5.93 1 1 5.93 1 12h2c0-4.97 4.03-9 9-9s9 4.03 9 9h2c0-6.07-4.93-11-11-11z"/></g> +<g id="settings-input-component"><path d="M5 2c0-.55-.45-1-1-1s-1 .45-1 1v4H1v6h6V6H5V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2H9v2zm-8 0c0 1.3.84 2.4 2 2.82V23h2v-4.18C6.16 18.4 7 17.3 7 16v-2H1v2zM21 6V2c0-.55-.45-1-1-1s-1 .45-1 1v4h-2v6h6V6h-2zm-8-4c0-.55-.45-1-1-1s-1 .45-1 1v4H9v6h6V6h-2V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2h-6v2z"/></g> +<g id="settings-input-composite"><path d="M5 2c0-.55-.45-1-1-1s-1 .45-1 1v4H1v6h6V6H5V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2H9v2zm-8 0c0 1.3.84 2.4 2 2.82V23h2v-4.18C6.16 18.4 7 17.3 7 16v-2H1v2zM21 6V2c0-.55-.45-1-1-1s-1 .45-1 1v4h-2v6h6V6h-2zm-8-4c0-.55-.45-1-1-1s-1 .45-1 1v4H9v6h6V6h-2V2zm4 14c0 1.3.84 2.4 2 2.82V23h2v-4.18c1.16-.41 2-1.51 2-2.82v-2h-6v2z"/></g> +<g id="settings-input-hdmi"><path d="M18 7V4c0-1.1-.9-2-2-2H8c-1.1 0-2 .9-2 2v3H5v6l3 6v3h8v-3l3-6V7h-1zM8 4h8v3h-2V5h-1v2h-2V5h-1v2H8V4z"/></g> +<g id="settings-input-svideo"><path d="M8 11.5c0-.83-.67-1.5-1.5-1.5S5 10.67 5 11.5 5.67 13 6.5 13 8 12.33 8 11.5zm7-5c0-.83-.67-1.5-1.5-1.5h-3C9.67 5 9 5.67 9 6.5S9.67 8 10.5 8h3c.83 0 1.5-.67 1.5-1.5zM8.5 15c-.83 0-1.5.67-1.5 1.5S7.67 18 8.5 18s1.5-.67 1.5-1.5S9.33 15 8.5 15zM12 1C5.93 1 1 5.93 1 12s4.93 11 11 11 11-4.93 11-11S18.07 1 12 1zm0 20c-4.96 0-9-4.04-9-9s4.04-9 9-9 9 4.04 9 9-4.04 9-9 9zm5.5-11c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5zm-2 5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5z"/></g> +<g id="settings-overscan"><path d="M12.01 5.5L10 8h4l-1.99-2.5zM18 10v4l2.5-1.99L18 10zM6 10l-2.5 2.01L6 14v-4zm8 6h-4l2.01 2.5L14 16zm7-13H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/></g> +<g id="settings-phone"><path d="M13 9h-2v2h2V9zm4 0h-2v2h2V9zm3 6.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.58l2.2-2.21c.28-.27.36-.66.25-1.01C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM19 9v2h2V9h-2z"/></g> +<g id="settings-power"><path d="M7 24h2v-2H7v2zm4 0h2v-2h-2v2zm2-22h-2v10h2V2zm3.56 2.44l-1.45 1.45C16.84 6.94 18 8.83 18 11c0 3.31-2.69 6-6 6s-6-2.69-6-6c0-2.17 1.16-4.06 2.88-5.12L7.44 4.44C5.36 5.88 4 8.28 4 11c0 4.42 3.58 8 8 8s8-3.58 8-8c0-2.72-1.36-5.12-3.44-6.56zM15 24h2v-2h-2v2z"/></g> +<g id="settings-remote"><path d="M15 9H9c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V10c0-.55-.45-1-1-1zm-3 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM7.05 6.05l1.41 1.41C9.37 6.56 10.62 6 12 6s2.63.56 3.54 1.46l1.41-1.41C15.68 4.78 13.93 4 12 4s-3.68.78-4.95 2.05zM12 0C8.96 0 6.21 1.23 4.22 3.22l1.41 1.41C7.26 3.01 9.51 2 12 2s4.74 1.01 6.36 2.64l1.41-1.41C17.79 1.23 15.04 0 12 0z"/></g> +<g id="settings-voice"><path d="M7 24h2v-2H7v2zm5-11c1.66 0 2.99-1.34 2.99-3L15 4c0-1.66-1.34-3-3-3S9 2.34 9 4v6c0 1.66 1.34 3 3 3zm-1 11h2v-2h-2v2zm4 0h2v-2h-2v2zm4-14h-1.7c0 3-2.54 5.1-5.3 5.1S6.7 13 6.7 10H5c0 3.41 2.72 6.23 6 6.72V20h2v-3.28c3.28-.49 6-3.31 6-6.72z"/></g> +<g id="shop"><path d="M16 6V4c0-1.11-.89-2-2-2h-4c-1.11 0-2 .89-2 2v2H2v13c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6h-6zm-6-2h4v2h-4V4zM9 18V9l7.5 4L9 18z"/></g> +<g id="shop-two"><path d="M3 9H1v11c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2H3V9zm15-4V3c0-1.11-.89-2-2-2h-4c-1.11 0-2 .89-2 2v2H5v11c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2V5h-5zm-6-2h4v2h-4V3zm0 12V8l5.5 3-5.5 4z"/></g> +<g id="shopping-basket"><path d="M17.21 9l-4.38-6.56c-.19-.28-.51-.42-.83-.42-.32 0-.64.14-.83.43L6.79 9H2c-.55 0-1 .45-1 1 0 .09.01.18.04.27l2.54 9.27c.23.84 1 1.46 1.92 1.46h13c.92 0 1.69-.62 1.93-1.46l2.54-9.27L23 10c0-.55-.45-1-1-1h-4.79zM9 9l3-4.4L15 9H9zm3 8c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="shopping-cart"><path d="M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="sort"><path d="M3 18h6v-2H3v2zM3 6v2h18V6H3zm0 7h12v-2H3v2z"/></g> +<g id="speaker-notes"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM8 14H6v-2h2v2zm0-3H6V9h2v2zm0-3H6V6h2v2zm7 6h-5v-2h5v2zm3-3h-8V9h8v2zm0-3h-8V6h8v2z"/></g> +<g id="spellcheck"><path d="M12.45 16h2.09L9.43 3H7.57L2.46 16h2.09l1.12-3h5.64l1.14 3zm-6.02-5L8.5 5.48 10.57 11H6.43zm15.16.59l-8.09 8.09L9.83 16l-1.41 1.41 5.09 5.09L23 13l-1.41-1.41z"/></g> +<g id="star"><path d="M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"/></g> +<g id="star-border"><path d="M22 9.24l-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4l-3.76 2.27 1-4.28-3.32-2.88 4.38-.38L12 6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"/></g> +<g id="star-half"><path d="M22 9.74l-7.19-.62L12 2.5 9.19 9.13 2 9.74l5.46 4.73-1.64 7.03L12 17.77l6.18 3.73-1.63-7.03L22 9.74zM12 15.9V6.6l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.9z"/></g> +<g id="stars"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm4.24 16L12 15.45 7.77 18l1.12-4.81-3.73-3.23 4.92-.42L12 5l1.92 4.53 4.92.42-3.73 3.23L16.23 18z"/></g> +<g id="store"><path d="M20 4H4v2h16V4zm1 10v-2l-1-5H4l-1 5v2h1v6h10v-6h4v6h2v-6h1zm-9 4H6v-4h6v4z"/></g> +<g id="subject"><path d="M14 17H4v2h10v-2zm6-8H4v2h16V9zM4 15h16v-2H4v2zM4 5v2h16V5H4z"/></g> +<g id="supervisor-account"><path d="M16.5 12c1.38 0 2.49-1.12 2.49-2.5S17.88 7 16.5 7C15.12 7 14 8.12 14 9.5s1.12 2.5 2.5 2.5zM9 11c1.66 0 2.99-1.34 2.99-3S10.66 5 9 5C7.34 5 6 6.34 6 8s1.34 3 3 3zm7.5 3c-1.83 0-5.5.92-5.5 2.75V19h11v-2.25c0-1.83-3.67-2.75-5.5-2.75zM9 13c-2.33 0-7 1.17-7 3.5V19h7v-2.25c0-.85.33-2.34 2.37-3.47C10.5 13.1 9.66 13 9 13z"/></g> +<g id="swap-horiz"><path d="M6.99 11L3 15l3.99 4v-3H14v-2H6.99v-3zM21 9l-3.99-4v3H10v2h7.01v3L21 9z"/></g> +<g id="swap-vert"><path d="M16 17.01V10h-2v7.01h-3L15 21l4-3.99h-3zM9 3L5 6.99h3V14h2V6.99h3L9 3z"/></g> +<g id="swap-vertical-circle"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM6.5 9L10 5.5 13.5 9H11v4H9V9H6.5zm11 6L14 18.5 10.5 15H13v-4h2v4h2.5z"/></g> +<g id="system-update-alt"><path d="M12 16.5l4-4h-3v-9h-2v9H8l4 4zm9-13h-6v1.99h6v14.03H3V5.49h6V3.5H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2v-14c0-1.1-.9-2-2-2z"/></g> +<g id="tab"><path d="M21 3H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H3V5h10v4h8v10z"/></g> +<g id="tab-unselected"><path d="M1 9h2V7H1v2zm0 4h2v-2H1v2zm0-8h2V3c-1.1 0-2 .9-2 2zm8 16h2v-2H9v2zm-8-4h2v-2H1v2zm2 4v-2H1c0 1.1.9 2 2 2zM21 3h-8v6h10V5c0-1.1-.9-2-2-2zm0 14h2v-2h-2v2zM9 5h2V3H9v2zM5 21h2v-2H5v2zM5 5h2V3H5v2zm16 16c1.1 0 2-.9 2-2h-2v2zm0-8h2v-2h-2v2zm-8 8h2v-2h-2v2zm4 0h2v-2h-2v2z"/></g> +<g id="text-format"><path d="M5 17v2h14v-2H5zm4.5-4.2h5l.9 2.2h2.1L12.75 4h-1.5L6.5 15h2.1l.9-2.2zM12 5.98L13.87 11h-3.74L12 5.98z"/></g> +<g id="theaters"><path d="M18 3v2h-2V3H8v2H6V3H4v18h2v-2h2v2h8v-2h2v2h2V3h-2zM8 17H6v-2h2v2zm0-4H6v-2h2v2zm0-4H6V7h2v2zm10 8h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V7h2v2z"/></g> +<g id="thumb-down"><path d="M15 3H6c-.83 0-1.54.5-1.84 1.22l-3.02 7.05c-.09.23-.14.47-.14.73v1.91l.01.01L1 14c0 1.1.9 2 2 2h6.31l-.95 4.57-.03.32c0 .41.17.79.44 1.06L9.83 23l6.59-6.59c.36-.36.58-.86.58-1.41V5c0-1.1-.9-2-2-2zm4 0v12h4V3h-4z"/></g> +<g id="thumb-up"><path d="M1 21h4V9H1v12zm22-11c0-1.1-.9-2-2-2h-6.31l.95-4.57.03-.32c0-.41-.17-.79-.44-1.06L14.17 1 7.59 7.59C7.22 7.95 7 8.45 7 9v10c0 1.1.9 2 2 2h9c.83 0 1.54-.5 1.84-1.22l3.02-7.05c.09-.23.14-.47.14-.73v-1.91l-.01-.01L23 10z"/></g> +<g id="thumbs-up-down"><path d="M12 6c0-.55-.45-1-1-1H5.82l.66-3.18.02-.23c0-.31-.13-.59-.33-.8L5.38 0 .44 4.94C.17 5.21 0 5.59 0 6v6.5c0 .83.67 1.5 1.5 1.5h6.75c.62 0 1.15-.38 1.38-.91l2.26-5.29c.07-.17.11-.36.11-.55V6zm10.5 4h-6.75c-.62 0-1.15.38-1.38.91l-2.26 5.29c-.07.17-.11.36-.11.55V18c0 .55.45 1 1 1h5.18l-.66 3.18-.02.24c0 .31.13.59.33.8l.79.78 4.94-4.94c.27-.27.44-.65.44-1.06v-6.5c0-.83-.67-1.5-1.5-1.5z"/></g> +<g id="toc"><path d="M3 9h14V7H3v2zm0 4h14v-2H3v2zm0 4h14v-2H3v2zm16 0h2v-2h-2v2zm0-10v2h2V7h-2zm0 6h2v-2h-2v2z"/></g> +<g id="today"><path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z"/></g> +<g id="toll"><path d="M15 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6zM3 12c0-2.61 1.67-4.83 4-5.65V4.26C3.55 5.15 1 8.27 1 12s2.55 6.85 6 7.74v-2.09c-2.33-.82-4-3.04-4-5.65z"/></g> +<g id="track-changes"><path fill="#231F20" d="M19.07 4.93l-1.41 1.41C19.1 7.79 20 9.79 20 12c0 4.42-3.58 8-8 8s-8-3.58-8-8c0-4.08 3.05-7.44 7-7.93v2.02C8.16 6.57 6 9.03 6 12c0 3.31 2.69 6 6 6s6-2.69 6-6c0-1.66-.67-3.16-1.76-4.24l-1.41 1.41C15.55 9.9 16 10.9 16 12c0 2.21-1.79 4-4 4s-4-1.79-4-4c0-1.86 1.28-3.41 3-3.86v2.14c-.6.35-1 .98-1 1.72 0 1.1.9 2 2 2s2-.9 2-2c0-.74-.4-1.38-1-1.72V2h-1C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10c0-2.76-1.12-5.26-2.93-7.07z"/></g> +<g id="translate"><path d="M12.87 15.07l-2.54-2.51.03-.03c1.74-1.94 2.98-4.17 3.71-6.53H17V4h-7V2H8v2H1v1.99h11.17C11.5 7.92 10.44 9.75 9 11.35 8.07 10.32 7.3 9.19 6.69 8h-2c.73 1.63 1.73 3.17 2.98 4.56l-5.09 5.02L4 19l5-5 3.11 3.11.76-2.04zM18.5 10h-2L12 22h2l1.12-3h4.75L21 22h2l-4.5-12zm-2.62 7l1.62-4.33L19.12 17h-3.24z"/></g> +<g id="trending-down"><path d="M16 18l2.29-2.29-4.88-4.88-4 4L2 7.41 3.41 6l6 6 4-4 6.3 6.29L22 12v6z"/></g> +<g id="trending-flat"><path d="M22 12l-4-4v3H3v2h15v3z"/></g> +<g id="trending-up"><path d="M16 6l2.29 2.29-4.88 4.88-4-4L2 16.59 3.41 18l6-6 4 4 6.3-6.29L22 12V6z"/></g> +<g id="turned-in"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2z"/></g> +<g id="turned-in-not"><path d="M17 3H7c-1.1 0-1.99.9-1.99 2L5 21l7-3 7 3V5c0-1.1-.9-2-2-2zm0 15l-5-2.18L7 18V5h10v13z"/></g> +<g id="undo"><path d="M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"/></g> +<g id="unfold-less"><path d="M7.41 18.59L8.83 20 12 16.83 15.17 20l1.41-1.41L12 14l-4.59 4.59zm9.18-13.18L15.17 4 12 7.17 8.83 4 7.41 5.41 12 10l4.59-4.59z"/></g> +<g id="unfold-more"><path d="M12 5.83L15.17 9l1.41-1.41L12 3 7.41 7.59 8.83 9 12 5.83zm0 12.34L8.83 15l-1.41 1.41L12 21l4.59-4.59L15.17 15 12 18.17z"/></g> +<g id="verified-user"><path d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm-2 16l-4-4 1.41-1.41L10 14.17l6.59-6.59L18 9l-8 8z"/></g> +<g id="view-agenda"><path d="M20 13H3c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h17c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zm0-10H3c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h17c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1z"/></g> +<g id="view-array"><path d="M4 18h3V5H4v13zM18 5v13h3V5h-3zM8 18h9V5H8v13z"/></g> +<g id="view-carousel"><path d="M7 19h10V4H7v15zm-5-2h4V6H2v11zM18 6v11h4V6h-4z"/></g> +<g id="view-column"><path d="M10 18h5V5h-5v13zm-6 0h5V5H4v13zM16 5v13h5V5h-5z"/></g> +<g id="view-day"><path d="M2 21h19v-3H2v3zM20 8H3c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h17c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zM2 3v3h19V3H2z"/></g> +<g id="view-headline"><path d="M4 15h16v-2H4v2zm0 4h16v-2H4v2zm0-8h16V9H4v2zm0-6v2h16V5H4z"/></g> +<g id="view-list"><path d="M4 14h4v-4H4v4zm0 5h4v-4H4v4zM4 9h4V5H4v4zm5 5h12v-4H9v4zm0 5h12v-4H9v4zM9 5v4h12V5H9z"/></g> +<g id="view-module"><path d="M4 11h5V5H4v6zm0 7h5v-6H4v6zm6 0h5v-6h-5v6zm6 0h5v-6h-5v6zm-6-7h5V5h-5v6zm6-6v6h5V5h-5z"/></g> +<g id="view-quilt"><path d="M10 18h5v-6h-5v6zm-6 0h5V5H4v13zm12 0h5v-6h-5v6zM10 5v6h11V5H10z"/></g> +<g id="view-stream"><path d="M4 18h17v-6H4v6zM4 5v6h17V5H4z"/></g> +<g id="view-week"><path d="M6 5H3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h3c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zm14 0h-3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h3c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zm-7 0h-3c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h3c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1z"/></g> +<g id="visibility"><path d="M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"/></g> +<g id="visibility-off"><path d="M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"/></g> +<g id="warning"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></g> +<g id="work"><path d="M20 6h-4V4c0-1.11-.89-2-2-2h-4c-1.11 0-2 .89-2 2v2H4c-1.11 0-1.99.89-1.99 2L2 19c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V8c0-1.11-.89-2-2-2zm-6 0h-4V4h4v2z"/></g> +<g id="youtube-searched-for"><path d="M17.01 14h-.8l-.27-.27c.98-1.14 1.57-2.61 1.57-4.23 0-3.59-2.91-6.5-6.5-6.5s-6.5 3-6.5 6.5H2l3.84 4 4.16-4H6.51C6.51 7 8.53 5 11.01 5s4.5 2.01 4.5 4.5c0 2.48-2.02 4.5-4.5 4.5-.65 0-1.26-.14-1.82-.38L7.71 15.1c.97.57 2.09.9 3.3.9 1.61 0 3.08-.59 4.22-1.57l.27.27v.79l5.01 4.99L22 19l-4.99-5z"/></g> +<g id="zoom-in"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14zM12 10h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></g> +<g id="zoom-out"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14zM7 9h5v1H7z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/maps-icons.html b/third_party/polymer/v1_0/components/iron-icons/maps-icons.html new file mode 100644 index 0000000..008a0ef --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/maps-icons.html @@ -0,0 +1,71 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="maps" size="24"> +<svg><defs> +<g id="beenhere"><path d="M19 1H5c-1.1 0-1.99.9-1.99 2L3 15.93c0 .69.35 1.3.88 1.66L12 23l8.11-5.41c.53-.36.88-.97.88-1.66L21 3c0-1.1-.9-2-2-2zm-9 15l-5-5 1.41-1.41L10 13.17l7.59-7.59L19 7l-9 9z"/></g> +<g id="directions"><path d="M21.71 11.29l-9-9c-.39-.39-1.02-.39-1.41 0l-9 9c-.39.39-.39 1.02 0 1.41l9 9c.39.39 1.02.39 1.41 0l9-9c.39-.38.39-1.01 0-1.41zM14 14.5V12h-4v3H8v-4c0-.55.45-1 1-1h5V7.5l3.5 3.5-3.5 3.5z"/></g> +<g id="directions-bike"><path d="M15.5 5.5c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zM5 12c-2.8 0-5 2.2-5 5s2.2 5 5 5 5-2.2 5-5-2.2-5-5-5zm0 8.5c-1.9 0-3.5-1.6-3.5-3.5s1.6-3.5 3.5-3.5 3.5 1.6 3.5 3.5-1.6 3.5-3.5 3.5zm5.8-10l2.4-2.4.8.8c1.3 1.3 3 2.1 5.1 2.1V9c-1.5 0-2.7-.6-3.6-1.5l-1.9-1.9c-.5-.4-1-.6-1.6-.6s-1.1.2-1.4.6L7.8 8.4c-.4.4-.6.9-.6 1.4 0 .6.2 1.1.6 1.4L11 14v5h2v-6.2l-2.2-2.3zM19 12c-2.8 0-5 2.2-5 5s2.2 5 5 5 5-2.2 5-5-2.2-5-5-5zm0 8.5c-1.9 0-3.5-1.6-3.5-3.5s1.6-3.5 3.5-3.5 3.5 1.6 3.5 3.5-1.6 3.5-3.5 3.5z"/></g> +<g id="directions-boat"><path d="M20 21c-1.39 0-2.78-.47-4-1.32-2.44 1.71-5.56 1.71-8 0C6.78 20.53 5.39 21 4 21H2v2h2c1.38 0 2.74-.35 4-.99 2.52 1.29 5.48 1.29 8 0 1.26.65 2.62.99 4 .99h2v-2h-2zM3.95 19H4c1.6 0 3.02-.88 4-2 .98 1.12 2.4 2 4 2s3.02-.88 4-2c.98 1.12 2.4 2 4 2h.05l1.89-6.68c.08-.26.06-.54-.06-.78s-.34-.42-.6-.5L20 10.62V6c0-1.1-.9-2-2-2h-3V1H9v3H6c-1.1 0-2 .9-2 2v4.62l-1.29.42c-.26.08-.48.26-.6.5s-.15.52-.06.78L3.95 19zM6 6h12v3.97L12 8 6 9.97V6z"/></g> +<g id="directions-bus"><path d="M4 16c0 .88.39 1.67 1 2.22V20c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h8v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1.78c.61-.55 1-1.34 1-2.22V6c0-3.5-3.58-4-8-4s-8 .5-8 4v10zm3.5 1c-.83 0-1.5-.67-1.5-1.5S6.67 14 7.5 14s1.5.67 1.5 1.5S8.33 17 7.5 17zm9 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm1.5-6H6V6h12v5z"/></g> +<g id="directions-car"><path d="M18.92 6.01C18.72 5.42 18.16 5 17.5 5h-11c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 16c-.83 0-1.5-.67-1.5-1.5S5.67 13 6.5 13s1.5.67 1.5 1.5S7.33 16 6.5 16zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 11l1.5-4.5h11L19 11H5z"/></g> +<g id="directions-railway"><path d="M4 15.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V5c0-3.5-3.58-4-8-4s-8 .5-8 4v10.5zm8 1.5c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm6-7H6V5h12v5z"/></g> +<g id="directions-run"><path d="M13.49 5.48c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-3.6 13.9l1-4.4 2.1 2v6h2v-7.5l-2.1-2 .6-3c1.3 1.5 3.3 2.5 5.5 2.5v-2c-1.9 0-3.5-1-4.3-2.4l-1-1.6c-.4-.6-1-1-1.7-1-.3 0-.5.1-.8.1l-5.2 2.2v4.7h2v-3.4l1.8-.7-1.6 8.1-4.9-1-.4 2 7 1.4z"/></g> +<g id="directions-subway"><path d="M12 2c-4.42 0-8 .5-8 4v9.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V6c0-3.5-3.58-4-8-4zM7.5 17c-.83 0-1.5-.67-1.5-1.5S6.67 14 7.5 14s1.5.67 1.5 1.5S8.33 17 7.5 17zm3.5-6H6V6h5v5zm5.5 6c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm1.5-6h-5V6h5v5z"/></g> +<g id="directions-transit"><path d="M12 2c-4.42 0-8 .5-8 4v9.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V6c0-3.5-3.58-4-8-4zM7.5 17c-.83 0-1.5-.67-1.5-1.5S6.67 14 7.5 14s1.5.67 1.5 1.5S8.33 17 7.5 17zm3.5-6H6V6h5v5zm5.5 6c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm1.5-6h-5V6h5v5z"/></g> +<g id="directions-walk"><path d="M13.5 5.5c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zM9.8 8.9L7 23h2.1l1.8-8 2.1 2v6h2v-7.5l-2.1-2 .6-3C14.8 12 16.8 13 19 13v-2c-1.9 0-3.5-1-4.3-2.4l-1-1.6c-.4-.6-1-1-1.7-1-.3 0-.5.1-.8.1L6 8.3V13h2V9.6l1.8-.7"/></g> +<g id="flight"><path d="M10.18 9"/><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/></g> +<g id="hotel"><path d="M7 13c1.66 0 3-1.34 3-3S8.66 7 7 7s-3 1.34-3 3 1.34 3 3 3zm12-6h-8v7H3V5H1v15h2v-3h18v3h2v-9c0-2.21-1.79-4-4-4z"/></g> +<g id="layers"><path d="M11.99 18.54l-7.37-5.73L3 14.07l9 7 9-7-1.63-1.27-7.38 5.74zM12 16l7.36-5.73L21 9l-9-7-9 7 1.63 1.27L12 16z"/></g> +<g id="layers-clear"><path d="M19.81 14.99l1.19-.92-1.43-1.43-1.19.92 1.43 1.43zm-.45-4.72L21 9l-9-7-2.91 2.27 7.87 7.88 2.4-1.88zM3.27 1L2 2.27l4.22 4.22L3 9l1.63 1.27L12 16l2.1-1.63 1.43 1.43L12 18.54l-7.37-5.73L3 14.07l9 7 4.95-3.85L20.73 21 22 19.73 3.27 1z"/></g> +<g id="local-activity"><path d="M20 12c0-1.1.9-2 2-2V6c0-1.1-.9-2-2-2H4c-1.1 0-1.99.9-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2zm-4.42 4.8L12 14.5l-3.58 2.3 1.08-4.12-3.29-2.69 4.24-.25L12 5.8l1.54 3.95 4.24.25-3.29 2.69 1.09 4.11z"/></g> +<g id="local-airport"><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/></g> +<g id="local-atm"><path d="M11 17h2v-1h1c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1h-3v-1h4V8h-2V7h-2v1h-1c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1h3v1H9v2h2v1zm9-13H4c-1.11 0-1.99.89-1.99 2L2 18c0 1.11.89 2 2 2h16c1.11 0 2-.89 2-2V6c0-1.11-.89-2-2-2zm0 14H4V6h16v12z"/></g> +<g id="local-bar"><path d="M11 13v6H6v2h12v-2h-5v-6l8-8V3H3v2l8 8zM7.5 7l-2-2h13l-2 2h-9z"/></g> +<g id="local-cafe"><path d="M20 3H4v10c0 2.21 1.79 4 4 4h6c2.21 0 4-1.79 4-4v-3h2c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2zm0 5h-2V5h2v3zM2 21h18v-2H2v2z"/></g> +<g id="local-car-wash"><path d="M17 5c.83 0 1.5-.67 1.5-1.5 0-1-1.5-2.7-1.5-2.7s-1.5 1.7-1.5 2.7c0 .83.67 1.5 1.5 1.5zm-5 0c.83 0 1.5-.67 1.5-1.5 0-1-1.5-2.7-1.5-2.7s-1.5 1.7-1.5 2.7c0 .83.67 1.5 1.5 1.5zM7 5c.83 0 1.5-.67 1.5-1.5C8.5 2.5 7 .8 7 .8S5.5 2.5 5.5 3.5C5.5 4.33 6.17 5 7 5zm11.92 3.01C18.72 7.42 18.16 7 17.5 7h-11c-.66 0-1.21.42-1.42 1.01L3 14v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 18c-.83 0-1.5-.67-1.5-1.5S5.67 15 6.5 15s1.5.67 1.5 1.5S7.33 18 6.5 18zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 13l1.5-4.5h11L19 13H5z"/></g> +<g id="local-convenience-store"><path d="M19 7V4H5v3H2v13h8v-4h4v4h8V7h-3zm-8 3H9v1h2v1H8V9h2V8H8V7h3v3zm5 2h-1v-2h-2V7h1v2h1V7h1v5z"/></g> +<g id="local-dining"><path d="M8.1 13.34l2.83-2.83L3.91 3.5c-1.56 1.56-1.56 4.09 0 5.66l4.19 4.18zm6.78-1.81c1.53.71 3.68.21 5.27-1.38 1.91-1.91 2.28-4.65.81-6.12-1.46-1.46-4.2-1.1-6.12.81-1.59 1.59-2.09 3.74-1.38 5.27L3.7 19.87l1.41 1.41L12 14.41l6.88 6.88 1.41-1.41L13.41 13l1.47-1.47z"/></g> +<g id="local-drink"><path d="M3 2l2.01 18.23C5.13 21.23 5.97 22 7 22h10c1.03 0 1.87-.77 1.99-1.77L21 2H3zm9 17c-1.66 0-3-1.34-3-3 0-2 3-5.4 3-5.4s3 3.4 3 5.4c0 1.66-1.34 3-3 3zm6.33-11H5.67l-.44-4h13.53l-.43 4z"/></g> +<g id="local-florist"><path d="M12 22c4.97 0 9-4.03 9-9-4.97 0-9 4.03-9 9zM5.6 10.25c0 1.38 1.12 2.5 2.5 2.5.53 0 1.01-.16 1.42-.44l-.02.19c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5l-.02-.19c.4.28.89.44 1.42.44 1.38 0 2.5-1.12 2.5-2.5 0-1-.59-1.85-1.43-2.25.84-.4 1.43-1.25 1.43-2.25 0-1.38-1.12-2.5-2.5-2.5-.53 0-1.01.16-1.42.44l.02-.19C14.5 2.12 13.38 1 12 1S9.5 2.12 9.5 3.5l.02.19c-.4-.28-.89-.44-1.42-.44-1.38 0-2.5 1.12-2.5 2.5 0 1 .59 1.85 1.43 2.25-.84.4-1.43 1.25-1.43 2.25zM12 5.5c1.38 0 2.5 1.12 2.5 2.5s-1.12 2.5-2.5 2.5S9.5 9.38 9.5 8s1.12-2.5 2.5-2.5zM3 13c0 4.97 4.03 9 9 9 0-4.97-4.03-9-9-9z"/></g> +<g id="local-gas-station"><path d="M19.77 7.23l.01-.01-3.72-3.72L15 4.56l2.11 2.11c-.94.36-1.61 1.26-1.61 2.33 0 1.38 1.12 2.5 2.5 2.5.36 0 .69-.08 1-.21v7.21c0 .55-.45 1-1 1s-1-.45-1-1V14c0-1.1-.9-2-2-2h-1V5c0-1.1-.9-2-2-2H6c-1.1 0-2 .9-2 2v16h10v-7.5h1.5v5c0 1.38 1.12 2.5 2.5 2.5s2.5-1.12 2.5-2.5V9c0-.69-.28-1.32-.73-1.77zM12 10H6V5h6v5zm6 0c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="local-grocery-store"><path d="M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"/></g> +<g id="local-hospital"><path d="M19 3H5c-1.1 0-1.99.9-1.99 2L3 19c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-1 11h-4v4h-4v-4H6v-4h4V6h4v4h4v4z"/></g> +<g id="local-hotel"><path d="M7 13c1.66 0 3-1.34 3-3S8.66 7 7 7s-3 1.34-3 3 1.34 3 3 3zm12-6h-8v7H3V5H1v15h2v-3h18v3h2v-9c0-2.21-1.79-4-4-4z"/></g> +<g id="local-laundry-service"><path d="M9.17 16.83c1.56 1.56 4.1 1.56 5.66 0 1.56-1.56 1.56-4.1 0-5.66l-5.66 5.66zM18 2.01L6 2c-1.11 0-2 .89-2 2v16c0 1.11.89 2 2 2h12c1.11 0 2-.89 2-2V4c0-1.11-.89-1.99-2-1.99zM10 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zM7 4c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm5 16c-3.31 0-6-2.69-6-6s2.69-6 6-6 6 2.69 6 6-2.69 6-6 6z"/></g> +<g id="local-library"><path d="M12 11.55C9.64 9.35 6.48 8 3 8v11c3.48 0 6.64 1.35 9 3.55 2.36-2.19 5.52-3.55 9-3.55V8c-3.48 0-6.64 1.35-9 3.55zM12 8c1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3 1.34 3 3 3z"/></g> +<g id="local-mall"><path d="M19 6h-2c0-2.76-2.24-5-5-5S7 3.24 7 6H5c-1.1 0-1.99.9-1.99 2L3 20c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-7-3c1.66 0 3 1.34 3 3H9c0-1.66 1.34-3 3-3zm0 10c-2.76 0-5-2.24-5-5h2c0 1.66 1.34 3 3 3s3-1.34 3-3h2c0 2.76-2.24 5-5 5z"/></g> +<g id="local-movies"><path d="M18 3v2h-2V3H8v2H6V3H4v18h2v-2h2v2h8v-2h2v2h2V3h-2zM8 17H6v-2h2v2zm0-4H6v-2h2v2zm0-4H6V7h2v2zm10 8h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V7h2v2z"/></g> +<g id="local-offer"><path d="M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58.55 0 1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41 0-.55-.23-1.06-.59-1.42zM5.5 7C4.67 7 4 6.33 4 5.5S4.67 4 5.5 4 7 4.67 7 5.5 6.33 7 5.5 7z"/></g> +<g id="local-parking"><path d="M13 3H6v18h4v-6h3c3.31 0 6-2.69 6-6s-2.69-6-6-6zm.2 8H10V7h3.2c1.1 0 2 .9 2 2s-.9 2-2 2z"/></g> +<g id="local-pharmacy"><path d="M21 5h-2.64l1.14-3.14L17.15 1l-1.46 4H3v2l2 6-2 6v2h18v-2l-2-6 2-6V5zm-5 9h-3v3h-2v-3H8v-2h3V9h2v3h3v2z"/></g> +<g id="local-phone"><path d="M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z"/></g> +<g id="local-pizza"><path d="M12 2C8.43 2 5.23 3.54 3.01 6L12 22l8.99-16C18.78 3.55 15.57 2 12 2zM7 7c0-1.1.9-2 2-2s2 .9 2 2-.9 2-2 2-2-.9-2-2zm5 8c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="local-play"><path d="M20 12c0-1.1.9-2 2-2V6c0-1.1-.9-2-2-2H4c-1.1 0-1.99.9-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2zm-4.42 4.8L12 14.5l-3.58 2.3 1.08-4.12-3.29-2.69 4.24-.25L12 5.8l1.54 3.95 4.24.25-3.29 2.69 1.09 4.11z"/></g> +<g id="local-post-office"><path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></g> +<g id="local-printshop"><path d="M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"/></g> +<g id="local-see"><circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5z"/></g> +<g id="local-shipping"><path d="M20 8h-3V4H3c-1.1 0-2 .9-2 2v11h2c0 1.66 1.34 3 3 3s3-1.34 3-3h6c0 1.66 1.34 3 3 3s3-1.34 3-3h2v-5l-3-4zM6 18.5c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm13.5-9l1.96 2.5H17V9.5h2.5zm-1.5 9c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="local-taxi"><path d="M18.92 6.01C18.72 5.42 18.16 5 17.5 5H15V3H9v2H6.5c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 16c-.83 0-1.5-.67-1.5-1.5S5.67 13 6.5 13s1.5.67 1.5 1.5S7.33 16 6.5 16zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 11l1.5-4.5h11L19 11H5z"/></g> +<g id="map"><path d="M20.5 3l-.16.03L15 5.1 9 3 3.36 4.9c-.21.07-.36.25-.36.48V20.5c0 .28.22.5.5.5l.16-.03L9 18.9l6 2.1 5.64-1.9c.21-.07.36-.25.36-.48V3.5c0-.28-.22-.5-.5-.5zM15 19l-6-2.11V5l6 2.11V19z"/></g> +<g id="my-location"><path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm8.94 3c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/></g> +<g id="navigation"><path d="M12 2L4.5 20.29l.71.71L12 18l6.79 3 .71-.71z"/></g> +<g id="person-pin"><path d="M19 2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h4l3 3 3-3h4c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 3.3c1.49 0 2.7 1.21 2.7 2.7 0 1.49-1.21 2.7-2.7 2.7-1.49 0-2.7-1.21-2.7-2.7 0-1.49 1.21-2.7 2.7-2.7zM18 16H6v-.9c0-2 4-3.1 6-3.1s6 1.1 6 3.1v.9z"/></g> +<g id="pin-drop"><path d="M18 8c0-3.31-2.69-6-6-6S6 4.69 6 8c0 4.5 6 11 6 11s6-6.5 6-11zm-8 0c0-1.1.9-2 2-2s2 .9 2 2-.89 2-2 2c-1.1 0-2-.9-2-2zM5 20v2h14v-2H5z"/></g> +<g id="place"><path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/></g> +<g id="rate-review"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM6 14v-2.47l6.88-6.88c.2-.2.51-.2.71 0l1.77 1.77c.2.2.2.51 0 .71L8.47 14H6zm12 0h-7.5l2-2H18v2z"/></g> +<g id="restaurant-menu"><path d="M8.1 13.34l2.83-2.83L3.91 3.5c-1.56 1.56-1.56 4.09 0 5.66l4.19 4.18zm6.78-1.81c1.53.71 3.68.21 5.27-1.38 1.91-1.91 2.28-4.65.81-6.12-1.46-1.46-4.2-1.1-6.12.81-1.59 1.59-2.09 3.74-1.38 5.27L3.7 19.87l1.41 1.41L12 14.41l6.88 6.88 1.41-1.41L13.41 13l1.47-1.47z"/></g> +<g id="satellite"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5 4.99h3C8 6.65 6.66 8 5 8V4.99zM5 12v-2c2.76 0 5-2.25 5-5.01h2C12 8.86 8.87 12 5 12zm0 6l3.5-4.5 2.5 3.01L14.5 12l4.5 6H5z"/></g> +<g id="store-mall-directory"><path d="M20 4H4v2h16V4zm1 10v-2l-1-5H4l-1 5v2h1v6h10v-6h4v6h2v-6h1zm-9 4H6v-4h6v4z"/></g> +<g id="terrain"><path d="M14 6l-3.75 5 2.85 3.8-1.6 1.2C9.81 13.75 7 10 7 10l-6 8h22L14 6z"/></g> +<g id="traffic"><path d="M20 10h-3V8.86c1.72-.45 3-2 3-3.86h-3V4c0-.55-.45-1-1-1H8c-.55 0-1 .45-1 1v1H4c0 1.86 1.28 3.41 3 3.86V10H4c0 1.86 1.28 3.41 3 3.86V15H4c0 1.86 1.28 3.41 3 3.86V20c0 .55.45 1 1 1h8c.55 0 1-.45 1-1v-1.14c1.72-.45 3-2 3-3.86h-3v-1.14c1.72-.45 3-2 3-3.86zm-8 9c-1.11 0-2-.9-2-2s.89-2 2-2c1.1 0 2 .9 2 2s-.89 2-2 2zm0-5c-1.11 0-2-.9-2-2s.89-2 2-2c1.1 0 2 .9 2 2s-.89 2-2 2zm0-5c-1.11 0-2-.9-2-2 0-1.11.89-2 2-2 1.1 0 2 .89 2 2 0 1.1-.89 2-2 2z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/notification-icons.html b/third_party/polymer/v1_0/components/iron-icons/notification-icons.html new file mode 100644 index 0000000..39db434 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/notification-icons.html @@ -0,0 +1,62 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="notification" size="24"> +<svg><defs> +<g id="adb"><path d="M5 16c0 3.87 3.13 7 7 7s7-3.13 7-7v-4H5v4zM16.12 4.37l2.1-2.1-.82-.83-2.3 2.31C14.16 3.28 13.12 3 12 3s-2.16.28-3.09.75L6.6 1.44l-.82.83 2.1 2.1C6.14 5.64 5 7.68 5 10v1h14v-1c0-2.32-1.14-4.36-2.88-5.63zM9 9c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm6 0c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/></g> +<g id="airline-seat-flat"><path d="M22 11v2H9V7h9c2.21 0 4 1.79 4 4zM2 14v2h6v2h8v-2h6v-2H2zm5.14-1.9c1.16-1.19 1.14-3.08-.04-4.24-1.19-1.16-3.08-1.14-4.24.04-1.16 1.19-1.14 3.08.04 4.24 1.19 1.16 3.08 1.14 4.24-.04z"/></g> +<g id="airline-seat-flat-angled"><path d="M22.25 14.29l-.69 1.89L9.2 11.71l2.08-5.66 8.56 3.09c2.1.76 3.18 3.06 2.41 5.15zM1.5 12.14L8 14.48V19h8v-1.63L20.52 19l.69-1.89-19.02-6.86-.69 1.89zm5.8-1.94c1.49-.72 2.12-2.51 1.41-4C7.99 4.71 6.2 4.08 4.7 4.8c-1.49.71-2.12 2.5-1.4 4 .71 1.49 2.5 2.12 4 1.4z"/></g> +<g id="airline-seat-individual-suite"><path d="M7 13c1.65 0 3-1.35 3-3S8.65 7 7 7s-3 1.35-3 3 1.35 3 3 3zm12-6h-8v7H3V7H1v10h22v-6c0-2.21-1.79-4-4-4z"/></g> +<g id="airline-seat-legroom-extra"><path d="M4 12V3H2v9c0 2.76 2.24 5 5 5h6v-2H7c-1.66 0-3-1.34-3-3zm18.83 5.24c-.38-.72-1.29-.97-2.03-.63l-1.09.5-3.41-6.98c-.34-.68-1.03-1.12-1.79-1.12L11 9V3H5v8c0 1.66 1.34 3 3 3h7l3.41 7 3.72-1.7c.77-.36 1.1-1.3.7-2.06z"/></g> +<g id="airline-seat-legroom-normal"><path d="M5 12V3H3v9c0 2.76 2.24 5 5 5h6v-2H8c-1.66 0-3-1.34-3-3zm15.5 6H19v-7c0-1.1-.9-2-2-2h-5V3H6v8c0 1.65 1.35 3 3 3h7v7h4.5c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5z"/></g> +<g id="airline-seat-legroom-reduced"><path d="M19.97 19.2c.18.96-.55 1.8-1.47 1.8H14v-3l1-4H9c-1.65 0-3-1.35-3-3V3h6v6h5c1.1 0 2 .9 2 2l-2 7h1.44c.73 0 1.39.49 1.53 1.2zM5 12V3H3v9c0 2.76 2.24 5 5 5h4v-2H8c-1.66 0-3-1.34-3-3z"/></g> +<g id="airline-seat-recline-extra"><path d="M5.35 5.64c-.9-.64-1.12-1.88-.49-2.79.63-.9 1.88-1.12 2.79-.49.9.64 1.12 1.88.49 2.79-.64.9-1.88 1.12-2.79.49zM16 19H8.93c-1.48 0-2.74-1.08-2.96-2.54L4 7H2l1.99 9.76C4.37 19.2 6.47 21 8.94 21H16v-2zm.23-4h-4.88l-1.03-4.1c1.58.89 3.28 1.54 5.15 1.22V9.99c-1.63.31-3.44-.27-4.69-1.25L9.14 7.47c-.23-.18-.49-.3-.76-.38-.32-.09-.66-.12-.99-.06h-.02c-1.23.22-2.05 1.39-1.84 2.61l1.35 5.92C7.16 16.98 8.39 18 9.83 18h6.85l3.82 3 1.5-1.5-5.77-4.5z"/></g> +<g id="airline-seat-recline-normal"><path d="M7.59 5.41c-.78-.78-.78-2.05 0-2.83.78-.78 2.05-.78 2.83 0 .78.78.78 2.05 0 2.83-.79.79-2.05.79-2.83 0zM6 16V7H4v9c0 2.76 2.24 5 5 5h6v-2H9c-1.66 0-3-1.34-3-3zm14 4.07L14.93 15H11.5v-3.68c1.4 1.15 3.6 2.16 5.5 2.16v-2.16c-1.66.02-3.61-.87-4.67-2.04l-1.4-1.55c-.19-.21-.43-.38-.69-.5-.29-.14-.62-.23-.96-.23h-.03C8.01 7 7 8.01 7 9.25V15c0 1.66 1.34 3 3 3h5.07l3.5 3.5L20 20.07z"/></g> +<g id="bluetooth-audio"><path d="M14.24 12.01l2.32 2.32c.28-.72.44-1.51.44-2.33 0-.82-.16-1.59-.43-2.31l-2.33 2.32zm5.29-5.3l-1.26 1.26c.63 1.21.98 2.57.98 4.02s-.36 2.82-.98 4.02l1.2 1.2c.97-1.54 1.54-3.36 1.54-5.31-.01-1.89-.55-3.67-1.48-5.19zm-3.82 1L10 2H9v7.59L4.41 5 3 6.41 8.59 12 3 17.59 4.41 19 9 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM11 5.83l1.88 1.88L11 9.59V5.83zm1.88 10.46L11 18.17v-3.76l1.88 1.88z"/></g> +<g id="confirmation-number"><defs><path id="a" d="M0 0h24v24H0z"/></defs><clipPath id="b"><use xlink:href="#a" overflow="visible"/></clipPath><path d="M22 10V6c0-1.11-.9-2-2-2H4c-1.1 0-1.99.89-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2s.9-2 2-2zm-9 7.5h-2v-2h2v2zm0-4.5h-2v-2h2v2zm0-4.5h-2v-2h2v2z" clip-path="url(#b)"/></g> +<g id="disc-full"><path d="M20 16h2v-2h-2v2zm0-9v5h2V7h-2zM10 4c-4.42 0-8 3.58-8 8s3.58 8 8 8 8-3.58 8-8-3.58-8-8-8zm0 10c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"/></g> +<g id="do-not-disturb"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8 0-1.85.63-3.55 1.69-4.9L16.9 18.31C15.55 19.37 13.85 20 12 20zm6.31-3.1L7.1 5.69C8.45 4.63 10.15 4 12 4c4.42 0 8 3.58 8 8 0 1.85-.63 3.55-1.69 4.9z"/></g> +<g id="do-not-disturb-alt"><path d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zM4 12c0-4.4 3.6-8 8-8 1.8 0 3.5.6 4.9 1.7L5.7 16.9C4.6 15.5 4 13.8 4 12zm8 8c-1.8 0-3.5-.6-4.9-1.7L18.3 7.1C19.4 8.5 20 10.2 20 12c0 4.4-3.6 8-8 8z"/></g> +<g id="drive-eta"><path d="M18.92 5.01C18.72 4.42 18.16 4 17.5 4h-11c-.66 0-1.21.42-1.42 1.01L3 11v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 15c-.83 0-1.5-.67-1.5-1.5S5.67 12 6.5 12s1.5.67 1.5 1.5S7.33 15 6.5 15zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 10l1.5-4.5h11L19 10H5z"/></g> +<g id="event-available"><path d="M16.53 11.06L15.47 10l-4.88 4.88-2.12-2.12-1.06 1.06L10.59 17l5.94-5.94zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11z"/></g> +<g id="event-busy"><path d="M9.31 17l2.44-2.44L14.19 17l1.06-1.06-2.44-2.44 2.44-2.44L14.19 10l-2.44 2.44L9.31 10l-1.06 1.06 2.44 2.44-2.44 2.44L9.31 17zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11z"/></g> +<g id="event-note"><path d="M17 10H7v2h10v-2zm2-7h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zm-5-5H7v2h7v-2z"/></g> +<g id="folder-special"><path d="M20 6h-8l-2-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-6.42 12L10 15.9 6.42 18l.95-4.07-3.16-2.74 4.16-.36L10 7l1.63 3.84 4.16.36-3.16 2.74.95 4.06z"/></g> +<g id="live-tv"><path d="M21 6h-7.59l3.29-3.29L16 2l-4 4-4-4-.71.71L10.59 6H3c-1.1 0-2 .89-2 2v12c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.11-.9-2-2-2zm0 14H3V8h18v12zM9 10v8l7-4z"/></g> +<g id="mms"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM5 14l3.5-4.5 2.5 3.01L14.5 8l4.5 6H5z"/></g> +<g id="more"><path d="M22 3H7c-.69 0-1.23.35-1.59.88L0 12l5.41 8.11c.36.53.97.89 1.66.89H22c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 13.5c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm5 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm5 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5z"/></g> +<g id="network-locked"><path d="M19.5 10c.17 0 .33.03.5.05V1L1 20h13v-3c0-.89.39-1.68 1-2.23v-.27c0-2.48 2.02-4.5 4.5-4.5zm2.5 6v-1.5c0-1.38-1.12-2.5-2.5-2.5S17 13.12 17 14.5V16c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1v-4c0-.55-.45-1-1-1zm-1 0h-3v-1.5c0-.83.67-1.5 1.5-1.5s1.5.67 1.5 1.5V16z"/></g> +<g id="ondemand-video"><path d="M21 3H3c-1.11 0-2 .89-2 2v12c0 1.1.89 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.11-.9-2-2-2zm0 14H3V5h18v12zm-5-6l-7 4V7z"/></g> +<g id="personal-video"><path d="M21 3H3c-1.11 0-2 .89-2 2v12c0 1.1.89 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.11-.9-2-2-2zm0 14H3V5h18v12z"/></g> +<g id="phone-bluetooth-speaker"><path d="M14.71 9.5L17 7.21V11h.5l2.85-2.85L18.21 6l2.15-2.15L17.5 1H17v3.79L14.71 2.5l-.71.71L16.79 6 14 8.79l.71.71zM18 2.91l.94.94-.94.94V2.91zm0 4.3l.94.94-.94.94V7.21zm2 8.29c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1z"/></g> +<g id="phone-forwarded"><path d="M18 11l5-5-5-5v3h-4v4h4v3zm2 4.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1z"/></g> +<g id="phone-in-talk"><path d="M20 15.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM19 12h2c0-4.97-4.03-9-9-9v2c3.87 0 7 3.13 7 7zm-4 0h2c0-2.76-2.24-5-5-5v2c1.66 0 3 1.34 3 3z"/></g> +<g id="phone-locked"><path d="M20 15.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM20 4v-.5C20 2.12 18.88 1 17.5 1S15 2.12 15 3.5V4c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1V5c0-.55-.45-1-1-1zm-.8 0h-3.4v-.5c0-.94.76-1.7 1.7-1.7s1.7.76 1.7 1.7V4z"/></g> +<g id="phone-missed"><path d="M6.5 5.5L12 11l7-7-1-1-6 6-4.5-4.5H11V3H5v6h1.5V5.5zm17.21 11.17C20.66 13.78 16.54 12 12 12 7.46 12 3.34 13.78.29 16.67c-.18.18-.29.43-.29.71s.11.53.29.71l2.48 2.48c.18.18.43.29.71.29.27 0 .52-.11.7-.28.79-.74 1.69-1.36 2.66-1.85.33-.16.56-.5.56-.9v-3.1c1.45-.48 3-.73 4.6-.73 1.6 0 3.15.25 4.6.72v3.1c0 .39.23.74.56.9.98.49 1.87 1.12 2.67 1.85.18.18.43.28.7.28.28 0 .53-.11.71-.29l2.48-2.48c.18-.18.29-.43.29-.71s-.12-.52-.3-.7z"/></g> +<g id="phone-paused"><path d="M17 3h-2v7h2V3zm3 12.5c-1.25 0-2.45-.2-3.57-.57-.35-.11-.74-.03-1.02.24l-2.2 2.2c-2.83-1.44-5.15-3.75-6.59-6.59l2.2-2.21c.28-.26.36-.65.25-1C8.7 6.45 8.5 5.25 8.5 4c0-.55-.45-1-1-1H4c-.55 0-1 .45-1 1 0 9.39 7.61 17 17 17 .55 0 1-.45 1-1v-3.5c0-.55-.45-1-1-1zM19 3v7h2V3h-2z"/></g> +<g id="power"><path d="M16.01 7L16 3h-2v4h-4V3H8v4h-.01C7 6.99 6 7.99 6 8.99v5.49L9.5 18v3h5v-3l3.5-3.51v-5.5c0-1-1-2-1.99-1.99z"/></g> +<g id="sd-card"><path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-6 6h-2V4h2v4zm3 0h-2V4h2v4zm3 0h-2V4h2v4z"/></g> +<g id="sim-card-alert"><path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5 15h-2v-2h2v2zm0-4h-2V8h2v5z"/></g> +<g id="sms"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM9 11H7V9h2v2zm4 0h-2V9h2v2zm4 0h-2V9h2v2z"/></g> +<g id="sms-failed"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-7 12h-2v-2h2v2zm0-4h-2V6h2v4z"/></g> +<g id="sync"><path d="M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"/></g> +<g id="sync-disabled"><path d="M10 6.35V4.26c-.8.21-1.55.54-2.23.96l1.46 1.46c.25-.12.5-.24.77-.33zm-7.14-.94l2.36 2.36C4.45 8.99 4 10.44 4 12c0 2.21.91 4.2 2.36 5.64L4 20h6v-6l-2.24 2.24C6.68 15.15 6 13.66 6 12c0-1 .25-1.94.68-2.77l8.08 8.08c-.25.13-.5.25-.77.34v2.09c.8-.21 1.55-.54 2.23-.96l2.36 2.36 1.27-1.27L4.14 4.14 2.86 5.41zM20 4h-6v6l2.24-2.24C17.32 8.85 18 10.34 18 12c0 1-.25 1.94-.68 2.77l1.46 1.46C19.55 15.01 20 13.56 20 12c0-2.21-.91-4.2-2.36-5.64L20 4z"/></g> +<g id="sync-problem"><path d="M3 12c0 2.21.91 4.2 2.36 5.64L3 20h6v-6l-2.24 2.24C5.68 15.15 5 13.66 5 12c0-2.61 1.67-4.83 4-5.65V4.26C5.55 5.15 3 8.27 3 12zm8 5h2v-2h-2v2zM21 4h-6v6l2.24-2.24C18.32 8.85 19 10.34 19 12c0 2.61-1.67 4.83-4 5.65v2.09c3.45-.89 6-4.01 6-7.74 0-2.21-.91-4.2-2.36-5.64L21 4zm-10 9h2V7h-2v6z"/></g> +<g id="system-update"><path d="M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14zm-1-6h-3V8h-2v5H8l4 4 4-4z"/></g> +<g id="tap-and-play"><path d="M2 16v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm0 4v3h3c0-1.66-1.34-3-3-3zm0-8v2c4.97 0 9 4.03 9 9h2c0-6.08-4.92-11-11-11zM17 1.01L7 1c-1.1 0-2 .9-2 2v7.37c.69.16 1.36.37 2 .64V5h10v13h-3.03c.52 1.25.84 2.59.95 4H17c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99z"/></g> +<g id="time-to-leave"><path d="M18.92 5.01C18.72 4.42 18.16 4 17.5 4h-11c-.66 0-1.21.42-1.42 1.01L3 11v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 15c-.83 0-1.5-.67-1.5-1.5S5.67 12 6.5 12s1.5.67 1.5 1.5S7.33 15 6.5 15zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zM5 10l1.5-4.5h11L19 10H5z"/></g> +<g id="vibration"><path d="M0 15h2V9H0v6zm3 2h2V7H3v10zm19-8v6h2V9h-2zm-3 8h2V7h-2v10zM16.5 3h-9C6.67 3 6 3.67 6 4.5v15c0 .83.67 1.5 1.5 1.5h9c.83 0 1.5-.67 1.5-1.5v-15c0-.83-.67-1.5-1.5-1.5zM16 19H8V5h8v14z"/></g> +<g id="voice-chat"><path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-2 12l-4-3.2V14H6V6h8v3.2L18 6v8z"/></g> +<g id="vpn-lock"><path d="M22 4v-.5C22 2.12 20.88 1 19.5 1S17 2.12 17 3.5V4c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h5c.55 0 1-.45 1-1V5c0-.55-.45-1-1-1zm-.8 0h-3.4v-.5c0-.94.76-1.7 1.7-1.7s1.7.76 1.7 1.7V4zm-2.28 8c.04.33.08.66.08 1 0 2.08-.8 3.97-2.1 5.39-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H7v-2h2c.55 0 1-.45 1-1V8h2c1.1 0 2-.9 2-2V3.46c-.95-.3-1.95-.46-3-.46C5.48 3 1 7.48 1 13s4.48 10 10 10 10-4.48 10-10c0-.34-.02-.67-.05-1h-2.03zM10 20.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L8 16v1c0 1.1.9 2 2 2v1.93z"/></g> +<g id="wc"><path d="M5.5 22v-7.5H4V9c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2v5.5H9.5V22h-4zM18 22v-6h3l-2.54-7.63C18.18 7.55 17.42 7 16.56 7h-.12c-.86 0-1.63.55-1.9 1.37L12 16h3v6h3zM7.5 6c1.11 0 2-.89 2-2s-.89-2-2-2-2 .89-2 2 .89 2 2 2zm9 0c1.11 0 2-.89 2-2s-.89-2-2-2-2 .89-2 2 .89 2 2 2z"/></g> +<g id="wifi"><path d="M1 9l2 2c4.97-4.97 13.03-4.97 18 0l2-2C16.93 2.93 7.08 2.93 1 9zm8 8l3 3 3-3c-1.65-1.66-4.34-1.66-6 0zm-4-4l2 2c2.76-2.76 7.24-2.76 10 0l2-2C15.14 9.14 8.87 9.14 5 13z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-icons/social-icons.html b/third_party/polymer/v1_0/components/iron-icons/social-icons.html new file mode 100644 index 0000000..5553caa --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-icons/social-icons.html @@ -0,0 +1,40 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> +<iron-iconset-svg name="social" size="24"> +<svg><defs> +<g id="cake"><path d="M12 6c1.11 0 2-.9 2-2 0-.38-.1-.73-.29-1.03L12 0l-1.71 2.97c-.19.3-.29.65-.29 1.03 0 1.1.9 2 2 2zm4.6 9.99l-1.07-1.07-1.08 1.07c-1.3 1.3-3.58 1.31-4.89 0l-1.07-1.07-1.09 1.07C6.75 16.64 5.88 17 4.96 17c-.73 0-1.4-.23-1.96-.61V21c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-4.61c-.56.38-1.23.61-1.96.61-.92 0-1.79-.36-2.44-1.01zM18 9h-5V7h-2v2H6c-1.66 0-3 1.34-3 3v1.54c0 1.08.88 1.96 1.96 1.96.52 0 1.02-.2 1.38-.57l2.14-2.13 2.13 2.13c.74.74 2.03.74 2.77 0l2.14-2.13 2.13 2.13c.37.37.86.57 1.38.57 1.08 0 1.96-.88 1.96-1.96V12C21 10.34 19.66 9 18 9z"/></g> +<g id="domain"><path d="M12 7V3H2v18h20V7H12zM6 19H4v-2h2v2zm0-4H4v-2h2v2zm0-4H4V9h2v2zm0-4H4V5h2v2zm4 12H8v-2h2v2zm0-4H8v-2h2v2zm0-4H8V9h2v2zm0-4H8V5h2v2zm10 12h-8v-2h2v-2h-2v-2h2v-2h-2V9h8v10zm-2-8h-2v2h2v-2zm0 4h-2v2h2v-2z"/></g> +<g id="group"><path d="M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"/></g> +<g id="group-add"><path d="M8 10H5V7H3v3H0v2h3v3h2v-3h3v-2zm10 1c1.66 0 2.99-1.34 2.99-3S19.66 5 18 5c-.32 0-.63.05-.91.14.57.81.9 1.79.9 2.86s-.34 2.04-.9 2.86c.28.09.59.14.91.14zm-5 0c1.66 0 2.99-1.34 2.99-3S14.66 5 13 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm6.62 2.16c.83.73 1.38 1.66 1.38 2.84v2h3v-2c0-1.54-2.37-2.49-4.38-2.84zM13 13c-2 0-6 1-6 3v2h12v-2c0-2-4-3-6-3z"/></g> +<g id="location-city"><path d="M15 11V5l-3-3-3 3v2H3v14h18V11h-6zm-8 8H5v-2h2v2zm0-4H5v-2h2v2zm0-4H5V9h2v2zm6 8h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V9h2v2zm0-4h-2V5h2v2zm6 12h-2v-2h2v2zm0-4h-2v-2h2v2z"/></g> +<g id="mood"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 6.5c2.33 0 4.31-1.46 5.11-3.5H6.89c.8 2.04 2.78 3.5 5.11 3.5z"/></g> +<g id="mood-bad"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm3.5-9c.83 0 1.5-.67 1.5-1.5S16.33 8 15.5 8 14 8.67 14 9.5s.67 1.5 1.5 1.5zm-7 0c.83 0 1.5-.67 1.5-1.5S9.33 8 8.5 8 7 8.67 7 9.5 7.67 11 8.5 11zm3.5 3c-2.33 0-4.31 1.46-5.11 3.5h10.22c-.8-2.04-2.78-3.5-5.11-3.5z"/></g> +<g id="notifications"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6.5-6v-5.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2z"/></g> +<g id="notifications-active"><path d="M6.58 3.58L5.15 2.15C2.76 3.97 1.18 6.8 1.03 10h2c.15-2.65 1.51-4.97 3.55-6.42zM19.97 10h2c-.15-3.2-1.73-6.03-4.13-7.85l-1.43 1.43c2.05 1.45 3.41 3.77 3.56 6.42zm-1.97.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2v-5.5zM11.5 22c.14 0 .27-.01.4-.04.65-.13 1.19-.58 1.44-1.18.1-.24.16-.5.16-.78h-4c0 1.1.9 2 2 2z"/></g> +<g id="notifications-none"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6.5-6v-5.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2zm-2 1H7v-6.5C7 8.01 9.01 6 11.5 6S16 8.01 16 10.5V17z"/></g> +<g id="notifications-off"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zM18 10.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-.51.12-.99.32-1.45.56L18 14.18V10.5zm-.27 8.5l2 2L21 19.73 4.27 3 3 4.27l2.92 2.92C5.34 8.16 5 9.29 5 10.5V16l-2 2v1h14.73z"/></g> +<g id="notifications-paused"><path d="M11.5 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6.5-6v-5.5c0-3.07-2.13-5.64-5-6.32V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5v.68c-2.87.68-5 3.25-5 6.32V16l-2 2v1h17v-1l-2-2zm-4-6.2l-2.8 3.4H14V15H9v-1.8l2.8-3.4H9V8h5v1.8z"/></g> +<g id="pages"><path d="M3 5v6h5L7 7l4 1V3H5c-1.1 0-2 .9-2 2zm5 8H3v6c0 1.1.9 2 2 2h6v-5l-4 1 1-4zm9 4l-4-1v5h6c1.1 0 2-.9 2-2v-6h-5l1 4zm2-14h-6v5l4-1-1 4h5V5c0-1.1-.9-2-2-2z"/></g> +<g id="party-mode"><path d="M20 4h-3.17L15 2H9L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-8 3c1.63 0 3.06.79 3.98 2H12c-1.66 0-3 1.34-3 3 0 .35.07.69.18 1H7.1c-.06-.32-.1-.66-.1-1 0-2.76 2.24-5 5-5zm0 10c-1.63 0-3.06-.79-3.98-2H12c1.66 0 3-1.34 3-3 0-.35-.07-.69-.18-1h2.08c.07.32.1.66.1 1 0 2.76-2.24 5-5 5z"/></g> +<g id="people"><path d="M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"/></g> +<g id="people-outline"><path d="M16.5 13c-1.2 0-3.07.34-4.5 1-1.43-.67-3.3-1-4.5-1C5.33 13 1 14.08 1 16.25V19h22v-2.75c0-2.17-4.33-3.25-6.5-3.25zm-4 4.5h-10v-1.25c0-.54 2.56-1.75 5-1.75s5 1.21 5 1.75v1.25zm9 0H14v-1.25c0-.46-.2-.86-.52-1.22.88-.3 1.96-.53 3.02-.53 2.44 0 5 1.21 5 1.75v1.25zM7.5 12c1.93 0 3.5-1.57 3.5-3.5S9.43 5 7.5 5 4 6.57 4 8.5 5.57 12 7.5 12zm0-5.5c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2zm9 5.5c1.93 0 3.5-1.57 3.5-3.5S18.43 5 16.5 5 13 6.57 13 8.5s1.57 3.5 3.5 3.5zm0-5.5c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2z"/></g> +<g id="person"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></g> +<g id="person-add"><path d="M15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm-9-2V7H4v3H1v2h3v3h2v-3h3v-2H6zm9 4c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></g> +<g id="person-outline"><path d="M12 5.9c1.16 0 2.1.94 2.1 2.1s-.94 2.1-2.1 2.1S9.9 9.16 9.9 8s.94-2.1 2.1-2.1m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z"/></g> +<g id="plus-one"><path d="M10 8H8v4H4v2h4v4h2v-4h4v-2h-4zm4.5-1.92V7.9l2.5-.5V18h2V5z"/></g> +<g id="poll"><path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/></g> +<g id="public"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z"/></g> +<g id="school"><path d="M5 13.18v4L12 21l7-3.82v-4L12 17l-7-3.82zM12 3L1 9l11 6 9-4.91V17h2V9L12 3z"/></g> +<g id="share"><path d="M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92 1.61 0 2.92-1.31 2.92-2.92s-1.31-2.92-2.92-2.92z"/></g> +<g id="whatshot"><path d="M13.5.67s.74 2.65.74 4.8c0 2.06-1.35 3.73-3.41 3.73-2.07 0-3.63-1.67-3.63-3.73l.03-.36C5.21 7.51 4 10.62 4 14c0 4.42 3.58 8 8 8s8-3.58 8-8C20 8.61 17.41 3.8 13.5.67zM11.71 19c-1.78 0-3.22-1.4-3.22-3.14 0-1.62 1.05-2.76 2.81-3.12 1.77-.36 3.6-1.21 4.62-2.58.39 1.29.59 2.65.59 4.04 0 2.65-2.15 4.8-4.8 4.8z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/iron-iconset-svg/.bower.json b/third_party/polymer/v1_0/components/iron-iconset-svg/.bower.json new file mode 100644 index 0000000..33c74b8 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset-svg/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-iconset-svg", + "description": "Manages a set of svg icons", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + }, + "homepage": "https://github.com/PolymerElements/iron-iconset-svg", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "ce54b944d6f1f67a254ea9c99585e553eba76b6d" + }, + "_source": "git://github.com/PolymerElements/iron-iconset-svg.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-iconset-svg" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-iconset-svg/.gitignore b/third_party/polymer/v1_0/components/iron-iconset-svg/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset-svg/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-iconset-svg/README.md b/third_party/polymer/v1_0/components/iron-iconset-svg/README.md new file mode 100644 index 0000000..37d603a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset-svg/README.md @@ -0,0 +1,4 @@ +iron-iconset-svg +========= + +See the [component page](http://polymer-project.org/docs/elements/iron-elements.html#iron-iconset-svg) for more information. diff --git a/third_party/polymer/v1_0/components/iron-iconset-svg/bower.json b/third_party/polymer/v1_0/components/iron-iconset-svg/bower.json new file mode 100644 index 0000000..64e7d83 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset-svg/bower.json @@ -0,0 +1,26 @@ +{ + "name": "iron-iconset-svg", + "description": "Manages a set of svg icons", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer", + "icon" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0", + "iron-meta": "polymerelements/iron-meta#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + } +} diff --git a/third_party/polymer/v1_0/components/iron-iconset-svg/index.html b/third_party/polymer/v1_0/components/iron-iconset-svg/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset-svg/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-iconset-svg/iron-iconset-svg.html b/third_party/polymer/v1_0/components/iron-iconset-svg/iron-iconset-svg.html new file mode 100644 index 0000000..0c5977d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset-svg/iron-iconset-svg.html @@ -0,0 +1,199 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +<script> + /** + * The `iron-iconset-svg` element allows users to define their own icon sets + * that contain svg icons. The svg icon elements should be children of the + * `iron-iconset-svg` element. Multiple icons should be given distinct id's. + * + * Using svg elements to create icons has a few advantages over traditional + * bitmap graphics like jpg or png. Icons that use svg are vector based so they + * are resolution independent and should look good on any device. They are + * stylable via css. Icons can be themed, colorized, and even animated. + * + * Example: + * + * <iron-iconset-svg id="my-svg-icons" iconSize="24"> + * <svg> + * <defs> + * <g id="shape"> + * <rect x="50" y="50" width="50" height="50" /> + * <circle cx="50" cy="50" r="50" /> + * </g> + * </defs> + * </svg> + * </iron-iconset-svg> + * + * This will automatically register the icon set "my-svg-icons" to the iconset + * database. To use these icons from within another element, make a + * `iron-iconset` element and call the `byId` method + * to retrieve a given iconset. To apply a particular icon inside an + * element use the `applyIcon` method. For example: + * + * iconset.applyIcon(iconNode, 'car'); + * + * @element iron-iconset-svg + */ + Polymer({ + + is: 'iron-iconset-svg', + + properties: { + + /** + * The name of the iconset. + * + * @attribute name + * @type string + */ + name: { + type: String, + observer: '_nameChanged' + }, + + /** + * Array of fully-qualitifed icon names in the iconset. + */ + iconNames: { + type: Array, + notify: true + }, + + /** + * The size of an individual icon. Note that icons must be square. + * + * @attribute iconSize + * @type number + * @default 24 + */ + size: { + type: Number, + value: 24 + } + + }, + + /** + * Applies an icon to the given element. + * + * An svg icon is prepended to the element's shadowRoot if it exists, + * otherwise to the element itself. + * + * @method applyIcon + * @param {Element} element Element to which the icon is applied. + * @param {string} iconName Name of the icon to apply. + * @return {Element} The svg element which renders the icon. + */ + applyIcon: function(element, iconName) { + // insert svg element into shadow root, if it exists + element = element.root || element; + // Remove old svg element + this.removeIcon(element); + // install new svg element + var svg = this._cloneIcon(iconName); + if (svg) { + var pde = Polymer.dom(element); + pde.insertBefore(svg, pde.childNodes[0]); + return element._svgIcon = svg; + } + return null; + }, + + /** + * Remove an icon from the given element by undoing the changes effected + * by `applyIcon`. + * + * @param {Element} element The element from which the icon is removed. + */ + removeIcon: function(element) { + // Remove old svg element + if (element._svgIcon) { + Polymer.dom(element).removeChild(element._svgIcon); + element._svgIcon = null; + } + }, + + /** + * + * When name is changed, either register a new iconset with the included + * icons, or if there are no children, set up a meta-iconset. + * + */ + _nameChanged: function() { + new Polymer.IronMeta({type: 'iconset', key: this.name, value: this}); + // icons (descendents) must exist a-priori + this._icons = this._createIconMap(); + this.iconNames = this._getIconNames(); + }, + + /** + * Array of all icon names in this iconset. + * + * @return {!Array} Array of icon names. + */ + _getIconNames: function() { + return Object.keys(this._icons).map(function(n) { + return this.name + ':' + n; + }, this); + }, + + /** + * Create a map of child SVG elements by id. + * + * @return {Object} Map of id's to SVG elements. + */ + _createIconMap: function() { + // Objects chained to Object.prototype (`{}`) have members. Specifically, + // on FF there is a `watch` method that confuses the icon map, so we + // need to use a null-based object here. + var icons = Object.create(null); + Polymer.dom(this).querySelectorAll('[id]') + .forEach(function(icon) { + icons[icon.id] = icon; + }); + return icons; + }, + + /** + * Produce installable clone of the SVG element matching `id` in this + * iconset, or `undefined` if there is no matching element. + * + * @return {Element} Returns an installable clone of the SVG element + * matching `id`. + */ + _cloneIcon: function(id) { + return this._prepareSvgClone(this._icons[id], this.size); + }, + + /** + * @param {Element} sourceSvg + * @param {number} size + * @return {Element} + */ + _prepareSvgClone: function(sourceSvg, size) { + if (sourceSvg) { + var svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg'); + svg.setAttribute('viewBox', ['0', '0', size, size].join(' ')); + svg.setAttribute('preserveAspectRatio', 'xMidYMid meet'); + // TODO(dfreedm): `pointer-events: none` works around https://crbug.com/370136 + // TODO(sjmiles): inline style may not be ideal, but avoids requiring a shadow-root + svg.style.cssText = 'pointer-events: none; display: block; width: 100%; height: 100%;'; + svg.appendChild(sourceSvg.cloneNode(true)).removeAttribute('id'); + return svg; + } + return null; + } + + }); +</script> diff --git a/third_party/polymer/v1_0/components/iron-iconset/.bower.json b/third_party/polymer/v1_0/components/iron-iconset/.bower.json new file mode 100644 index 0000000..e4ecbfa --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset/.bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-iconset", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Represents a set of icons", + "authors": [ + "The Polymer Authors" + ], + "private": true, + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-iconset", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "3ce6be6b689dd8e309410b0c30d7be23a493a880" + }, + "_source": "git://github.com/PolymerElements/iron-iconset.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-iconset" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-iconset/.gitignore b/third_party/polymer/v1_0/components/iron-iconset/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-iconset/README.md b/third_party/polymer/v1_0/components/iron-iconset/README.md new file mode 100644 index 0000000..53a245b --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset/README.md @@ -0,0 +1,51 @@ +iron-iconset +============ + +The `iron-iconset` element allows users to define their own icon sets. +The `src` property specifies the url of the icon image. Multiple icons may +be included in this image and they may be organized into rows. +The `icons` property is a space separated list of names corresponding to the +icons. The names must be ordered as the icons are ordered in the icon image. +Icons are expected to be square and are the size specified by the `size` +property. The `width` property corresponds to the width of the icon image +and must be specified if icons are arranged into multiple rows in the image. + +All `iron-iconset` elements are available for use by other `iron-iconset` +elements via a database keyed by id. Typically, an element author that wants +to support a set of custom icons uses a `iron-iconset` to retrieve +and use another, user-defined iconset. + +Example: + +```html +<iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> +</iron-iconset> +``` + +This will automatically register the icon set "my-icons" to the iconset +database. To use these icons from within another element, make a +`iron-iconset` element and call the `byId` method to retrieve a +given iconset. To apply a particular icon to an element, use the +`applyIcon` method. For example: + +```javascript +iconset.applyIcon(iconNode, 'car'); +``` + +Themed icon sets are also supported. The `iron-iconset` can contain child +`property` elements that specify a theme with an offsetX and offsetY of the +theme within the icon resource. For example. + +```html +<iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> + <property theme="special" offsetX="256" offsetY="24"></property> +</iron-iconset> +``` + +Then a themed icon can be applied like this: + +```javascript +iconset.applyIcon(iconNode, 'car', 'special'); +``` diff --git a/third_party/polymer/v1_0/components/iron-iconset/bower.json b/third_party/polymer/v1_0/components/iron-iconset/bower.json new file mode 100644 index 0000000..8766bf3 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset/bower.json @@ -0,0 +1,21 @@ +{ + "name": "iron-iconset", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Represents a set of icons", + "authors": [ + "The Polymer Authors" + ], + "private": true, + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-iconset/index.html b/third_party/polymer/v1_0/components/iron-iconset/index.html new file mode 100644 index 0000000..64e80d5 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-iconset</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-iconset/iron-iconset.html b/third_party/polymer/v1_0/components/iron-iconset/iron-iconset.html new file mode 100644 index 0000000..1fbc628 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-iconset/iron-iconset.html @@ -0,0 +1,336 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +<!-- +The `iron-iconset` element allows users to define their own icon sets. +The `src` property specifies the url of the icon image. Multiple icons may +be included in this image and they may be organized into rows. +The `icons` property is a space separated list of names corresponding to the +icons. The names must be ordered as the icons are ordered in the icon image. +Icons are expected to be square and are the size specified by the `size` +property. The `width` property corresponds to the width of the icon image +and must be specified if icons are arranged into multiple rows in the image. + +All `iron-iconset` elements are available for use by other `iron-iconset` +elements via a database keyed by id. Typically, an element author that wants +to support a set of custom icons uses a `iron-iconset` to retrieve +and use another, user-defined iconset. + +Example: + + <iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> + </iron-iconset> + +This will automatically register the icon set "my-icons" to the iconset +database. To use these icons from within another element, make a +`iron-iconset` element and call the `byId` method to retrieve a +given iconset. To apply a particular icon to an element, use the +`applyIcon` method. For example: + + iconset.applyIcon(iconNode, 'car'); + +Themed icon sets are also supported. The `iron-iconset` can contain child +`property` elements that specify a theme with an offsetX and offsetY of the +theme within the icon resource. For example. + + <iron-iconset id="my-icons" src="my-icons.png" width="96" size="24" + icons="location place starta stopb bus car train walk"> + <property theme="special" offsetX="256" offsetY="24"></property> + </iron-iconset> + +Then a themed icon can be applied like this: + + iconset.applyIcon(iconNode, 'car', 'special'); + +@element iron-iconset +--> + +<script> + + Polymer({ + + is: 'iron-iconset', + + properties: { + + /** + * The URL of the iconset image. + * + * @attribute src + * @type string + * @default '' + */ + src: { + type: String, + observer: '_srcChanged' + }, + + /** + * The name of the iconset. + * + * @attribute name + * @type string + * @default 'no-name' + */ + name: { + type: String, + observer: '_nameChanged' + }, + + /** + * The width of the iconset image. This must only be specified if the + * icons are arranged into separate rows inside the image. + * + * @attribute width + * @type number + * @default 0 + */ + width: { + type: Number, + value: 0 + }, + + /** + * A space separated list of names corresponding to icons in the iconset + * image file. This list must be ordered the same as the icon images + * in the image file. + * + * @attribute icons + * @type string + * @default '' + */ + icons: { + type: String + }, + + /** + * The size of an individual icon. Note that icons must be square. + * + * @attribute size + * @type number + * @default 24 + */ + size: { + type: Number, + value: 24 + }, + + /** + * The horizontal offset of the icon images in the inconset src image. + * This is typically used if the image resource contains additional images + * beside those intended for the iconset. + * + * @attribute offset-x + * @type number + * @default 0 + */ + _offsetX: { + type: Number, + value: 0 + }, + + /** + * The vertical offset of the icon images in the inconset src image. + * This is typically used if the image resource contains additional images + * beside those intended for the iconset. + * + * @attribute offset-y + * @type number + * @default 0 + */ + _offsetY: { + type: Number, + value: 0 + }, + + /** + * Array of fully-qualified names of icons in this set. + */ + iconNames: { + type: Array, + notify: true + } + + }, + + hostAttributes: { + // non-visual + style: 'display: none;' + }, + + ready: function() { + // theme data must exist at ready-time + this._themes = this._mapThemes(); + }, + + /** + * Applies an icon to the given element as a css background image. This + * method does not size the element, and it's usually necessary to set + * the element's height and width so that the background image is visible. + * + * @method applyIcon + * @param {Element} element The element to which the icon is applied. + * @param {String|Number} icon The name or index of the icon to apply. + * @param {String} theme (optional) The name or index of the icon to apply. + * @param {Number} scale (optional, defaults to 1) Icon scaling factor. + * @return {Element} The applied icon element. + */ + applyIcon: function(element, icon, theme, scale) { + this._validateIconMap(); + var offset = this._getThemedOffset(icon, theme); + if (element && offset) { + this._addIconStyles(element, this._srcUrl, offset, scale || 1, + this.size, this.width); + } + }, + + /** + * Remove an icon from the given element by undoing the changes effected + * by `applyIcon`. + * + * @param {Element} element The element from which the icon is removed. + */ + removeIcon: function(element) { + this._removeIconStyles(element.style); + }, + + _mapThemes: function() { + var themes = Object.create(null); + Polymer.dom(this).querySelectorAll('property[theme]') + .forEach(function(property) { + var offsetX = window.parseInt( + property.getAttribute('offset-x'), 10 + ) || 0; + var offsetY = window.parseInt( + property.getAttribute('offset-y'), 10 + ) || 0; + themes[property.getAttribute('theme')] = { + offsetX: offsetX, + offsetY: offsetY + }; + }); + return themes; + }, + + _srcChanged: function(src) { + // ensure `srcUrl` is always relative to the main document + this._srcUrl = this.ownerDocument !== document + ? this.resolveUrl(src) : src; + this._prepareIconset(); + }, + + _nameChanged: function(name) { + this._prepareIconset(); + }, + + _prepareIconset: function() { + new Polymer.IronMeta({type: 'iconset', key: this.name, value: this}); + }, + + _invalidateIconMap: function() { + this._iconMapValid = false; + }, + + _validateIconMap: function() { + if (!this._iconMapValid) { + this._recomputeIconMap(); + this._iconMapValid = true; + } + }, + + _recomputeIconMap: function() { + this.iconNames = this._computeIconNames(this.icons); + this.iconMap = this._computeIconMap(this._offsetX, this._offsetY, + this.size, this.width, this.iconNames); + }, + + _computeIconNames: function(icons) { + return icons.split(/\s+/g); + }, + + _computeIconMap: function(offsetX, offsetY, size, width, iconNames) { + var iconMap = {}; + if (offsetX !== undefined && offsetY !== undefined) { + var x0 = offsetX; + iconNames.forEach(function(iconName) { + iconMap[iconName] = { + offsetX: offsetX, + offsetY: offsetY + }; + if ((offsetX + size) < width) { + offsetX += size; + } else { + offsetX = x0; + offsetY += size; + } + }, this); + } + return iconMap; + }, + + /** + * Returns an object containing `offsetX` and `offsetY` properties which + * specify the pixel location in the iconset's src file for the given + * `icon` and `theme`. It's uncommon to call this method. It is useful, + * for example, to manually position a css backgroundImage to the proper + * offset. It's more common to use the `applyIcon` method. + * + * @method getThemedOffset + * @param {String|Number} identifier The name of the icon or the index of + * the icon within in the icon image. + * @param {String} theme The name of the theme. + * @returns {Object} An object specifying the offset of the given icon + * within the icon resource file; `offsetX` is the horizontal offset and + * `offsetY` is the vertical offset. Both values are in pixel units. + */ + _getThemedOffset: function(identifier, theme) { + var iconOffset = this._getIconOffset(identifier); + var themeOffset = this._themes[theme]; + if (iconOffset && themeOffset) { + return { + offsetX: iconOffset.offsetX + themeOffset.offsetX, + offsetY: iconOffset.offsetY + themeOffset.offsetY + }; + } + return iconOffset; + }, + + _getIconOffset: function(identifier) { + // TODO(sjmiles): consider creating offsetArray (indexed by Number) + // and having iconMap map names to indices, then and index is just + // iconMap[identifier] || identifier (be careful of zero, store indices + // as 1-based) + return this.iconMap[identifier] || + this.iconMap[this.iconNames[Number(identifier)]]; + }, + + _addIconStyles: function(element, url, offset, scale, size, width) { + var style = element.style; + style.backgroundImage = 'url(' + url + ')'; + style.backgroundPosition = + (-offset.offsetX * scale + 'px') + ' ' + + (-offset.offsetY * scale + 'px'); + style.backgroundSize = (scale === 1) ? 'auto' : width * scale + 'px'; + style.width = size + 'px'; + style.height = size + 'px'; + element.setAttribute('role', 'img'); + }, + + _removeIconStyles: function(style) { + style.background = ''; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-image/.bower.json b/third_party/polymer/v1_0/components/iron-image/.bower.json new file mode 100644 index 0000000..3e2ce06 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-image/.bower.json @@ -0,0 +1,35 @@ +{ + "name": "iron-image", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An image-displaying element with lots of convenient features", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-image", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "b2a3ef4c558b91a3f9a897f2d0b4c961a220a325" + }, + "_source": "git://github.com/PolymerElements/iron-image.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-image" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-image/.gitignore b/third_party/polymer/v1_0/components/iron-image/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-image/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-image/README.md b/third_party/polymer/v1_0/components/iron-image/README.md new file mode 100644 index 0000000..04fda7a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-image/README.md @@ -0,0 +1,60 @@ +iron-image +========== + +`iron-image` is an element for displaying an image that provides useful sizing and +preloading options not found on the standard `<img>` tag. + +The `sizing` option allows the image to be either cropped (`cover`) or +letterboxed (`contain`) to fill a fixed user-size placed on the element. + +The `preload` option prevents the browser from rendering the image until the +image is fully loaded. In the interim, either the element's CSS `background-color` +can be be used as the placeholder, or the `placeholder` property can be +set to a URL (preferably a data-URI, for instant rendering) for an +placeholder image. + +The `fade` option (only valid when `preload` is set) will cause the placeholder +image/color to be faded out once the image is rendered. + +Examples: + +Basically identical to `<img src="...">` tag: + +```html +<iron-image src="http://lorempixel.com/400/400"></iron-image> +``` + +Will letterbox the image to fit: + +```html +<iron-image style="width:400px; height:400px;" sizing="contain" + src="http://lorempixel.com/600/400"></iron-image> +``` + +Will crop the image to fit: + +```html +<iron-image style="width:400px; height:400px;" sizing="cover" + src="http://lorempixel.com/600/400"></iron-image> +``` + +Will show light-gray background until the image loads: + +```html +<iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> +``` + +Will show a base-64 encoded placeholder image until the image loads: + +```html +<iron-image style="width:400px; height:400px;" placeholder="data:image/gif;base64,..." + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> +``` + +Will fade the light-gray background out once the image is loaded: + +```html +<iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload fade src="http://lorempixel.com/600/400"></iron-image> +``` diff --git a/third_party/polymer/v1_0/components/iron-image/bower.json b/third_party/polymer/v1_0/components/iron-image/bower.json new file mode 100644 index 0000000..6e1d418 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-image/bower.json @@ -0,0 +1,25 @@ +{ + "name": "iron-image", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "An image-displaying element with lots of convenient features", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-image/index.html b/third_party/polymer/v1_0/components/iron-image/index.html new file mode 100644 index 0000000..b12d417 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-image/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>iron-image</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-image/iron-image.html b/third_party/polymer/v1_0/components/iron-image/iron-image.html new file mode 100644 index 0000000..07eb458 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-image/iron-image.html @@ -0,0 +1,394 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<!-- +`iron-image` is an element for displaying an image that provides useful sizing and +preloading options not found on the standard `<img>` tag. + +The `sizing` option allows the image to be either cropped (`cover`) or +letterboxed (`contain`) to fill a fixed user-size placed on the element. + +The `preload` option prevents the browser from rendering the image until the +image is fully loaded. In the interim, either the element's CSS `background-color` +can be be used as the placeholder, or the `placeholder` property can be +set to a URL (preferably a data-URI, for instant rendering) for an +placeholder image. + +The `fade` option (only valid when `preload` is set) will cause the placeholder +image/color to be faded out once the image is rendered. + +Examples: + + Basically identical to <img src="..."> tag: + + <iron-image src="http://lorempixel.com/400/400"></iron-image> + + Will letterbox the image to fit: + + <iron-image style="width:400px; height:400px;" sizing="contain" + src="http://lorempixel.com/600/400"></iron-image> + + Will crop the image to fit: + + <iron-image style="width:400px; height:400px;" sizing="cover" + src="http://lorempixel.com/600/400"></iron-image> + + Will show light-gray background until the image loads: + + <iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> + + Will show a base-64 encoded placeholder image until the image loads: + + <iron-image style="width:400px; height:400px;" placeholder="data:image/gif;base64,..." + sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image> + + Will fade the light-gray background out once the image is loaded: + + <iron-image style="width:400px; height:400px; background-color: lightgray;" + sizing="cover" preload fade src="http://lorempixel.com/600/400"></iron-image> + + +@group Iron Elements +@element iron-image +@demo demo/index.html +--> + +<dom-module id="iron-image"> + + <style> + + :host { + display: inline-block; + overflow: hidden; + position: relative; + } + + :host([sizing]) #img { + display: none; + } + + #placeholder { + background-color: inherit; + opacity: 1; + } + + #placeholder.faded-out { + transition: opacity 0.5s linear; + opacity: 0; + } + + </style> + + <template> + + <img id="img" role="none" hidden$="[[_computeImageVisibility(sizing)]]"> + <div id="placeholder" hidden$="[[_computePlaceholderVisibility(fade,loaded,preload)]]" class$="[[_computePlaceholderClassName(fade,loaded,preload)]]"></div> + <content></content> + + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'iron-image', + + properties: { + /** + * The URL of an image. + * + * @attribute src + * @type string + * @default '' + */ + src: { + observer: '_srcChanged', + type: String, + value: '' + }, + + /** + * When true, the image is prevented from loading and any placeholder is + * shown. This may be useful when a binding to the src property is known to + * be invalid, to prevent 404 requests. + * + * @attribute preventLoad + * @type boolean + * @default false + */ + preventLoad: { + type: Boolean, + value: false + }, + + /** + * Sets a sizing option for the image. Valid values are `contain` (full + * aspect ratio of the image is contained within the element and + * letterboxed) or `cover` (image is cropped in order to fully cover the + * bounds of the element), or `null` (default: image takes natural size). + * + * @attribute sizing + * @type string + * @default null + */ + sizing: { + type: String, + value: null + }, + + /** + * When a sizing option is uzed (`cover` or `contain`), this determines + * how the image is aligned within the element bounds. + * + * @attribute position + * @type string + * @default 'center' + */ + position: { + type: String, + value: 'center' + }, + + /** + * When `true`, any change to the `src` property will cause the `placeholder` + * image to be shown until the + * + * @attribute preload + * @type boolean + * @default false + */ + preload: { + type: Boolean, + value: false + }, + + /** + * This image will be used as a background/placeholder until the src image has + * loaded. Use of a data-URI for placeholder is encouraged for instant rendering. + * + * @attribute placeholder + * @type string + * @default null + */ + placeholder: { + type: String, + value: null + }, + + /** + * When `preload` is true, setting `fade` to true will cause the image to + * fade into place. + * + * @attribute fade + * @type boolean + * @default false + */ + fade: { + type: Boolean, + value: false + }, + + /** + * Read-only value that is true when the image is loaded. + * + * @attribute preloaded + * @type boolean + * @default false + */ + loaded: { + notify: true, + type: Boolean, + value: false + }, + + /** + * Read-only value that tracks the loading state of the image when the `preload` + * option is used. + * + * @attribute loading + * @type boolean + * @default false + */ + loading: { + notify: true, + type: Boolean, + value: false + }, + + /** + * Can be used to set the width of image (e.g. via binding); size may also be + * set via CSS. + * + * @attribute width + * @type number + * @default null + */ + width: { + observer: '_widthChanged', + type: Number, + value: null + }, + + /** + * Can be used to set the height of image (e.g. via binding); size may also be + * set via CSS. + * + * @attribute height + * @type number + * @default null + */ + height: { + observer: '_heightChanged', + type: Number, + value: null + }, + + _placeholderBackgroundUrl: { + type: String, + computed: '_computePlaceholderBackgroundUrl(preload,placeholder)', + observer: '_placeholderBackgroundUrlChanged' + }, + + requiresPreload: { + type: Boolean, + computed: '_computeRequiresPreload(preload,loaded)' + }, + + canLoad: { + type: Boolean, + computed: '_computeCanLoad(preventLoad, src)' + } + + }, + + observers: [ + '_transformChanged(sizing, position)', + '_loadBehaviorChanged(canLoad, preload, loaded)', + '_loadStateChanged(src, preload, loaded)', + ], + + ready: function() { + if (!this.hasAttribute('role')) { + this.setAttribute('role', 'img'); + } + }, + + _computeImageVisibility: function() { + return !!this.sizing; + }, + + _computePlaceholderVisibility: function() { + return !this.preload || (this.loaded && !this.fade); + }, + + _computePlaceholderClassName: function() { + if (!this.preload) { + return ''; + } + + var className = 'fit'; + if (this.loaded && this.fade) { + className += ' faded-out'; + } + return className; + }, + + _computePlaceholderBackgroundUrl: function() { + if (this.preload && this.placeholder) { + return 'url(' + this.placeholder + ')'; + } + + return null; + }, + + _computeRequiresPreload: function() { + return this.preload && !this.loaded; + }, + + _computeCanLoad: function() { + return Boolean(!this.preventLoad && this.src); + }, + + _widthChanged: function() { + this.style.width = isNaN(this.width) ? this.width : this.width + 'px'; + }, + + _heightChanged: function() { + this.style.height = isNaN(this.height) ? this.height : this.height + 'px'; + }, + + _srcChanged: function(newSrc, oldSrc) { + if (newSrc !== oldSrc) { + this.loaded = false; + } + }, + + _placeholderBackgroundUrlChanged: function() { + this.$.placeholder.style.backgroundImage = + this._placeholderBackgroundUrl; + }, + + _transformChanged: function() { + var placeholderStyle = this.$.placeholder.style; + + this.style.backgroundSize = + placeholderStyle.backgroundSize = this.sizing; + + this.style.backgroundPosition = + placeholderStyle.backgroundPosition = + this.sizing ? this.position : null; + + this.style.backgroundRepeat = + placeholderStyle.backgroundRepeat = + this.sizing ? 'no-repeat' : null; + }, + + _loadBehaviorChanged: function() { + var img; + + if (!this.canLoad) { + return; + } + + if (this.requiresPreload) { + img = new Image(); + img.src = this.src; + + this.loading = true; + + img.onload = function() { + this.loading = false; + this.loaded = true; + }.bind(this); + } else { + this.loaded = true; + } + }, + + _loadStateChanged: function() { + if (this.requiresPreload) { + return; + } + + if (this.sizing) { + this.style.backgroundImage = this.src ? 'url(' + this.src + ')': ''; + } else { + this.$.img.src = this.src || ''; + } + } + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-input/.bower.json b/third_party/polymer/v1_0/components/iron-input/.bower.json new file mode 100644 index 0000000..5120860c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "iron-input", + "version": "1.0.1", + "description": "An input element with data binding", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "iron-input.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-input", + "ignore": [], + "dependencies": { + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "f54d4945cf96ede414904055547fd4c46dc0c053" + }, + "_source": "git://github.com/PolymerElements/iron-input.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-input" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-input/.gitignore b/third_party/polymer/v1_0/components/iron-input/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-input/README.md b/third_party/polymer/v1_0/components/iron-input/README.md new file mode 100644 index 0000000..05a74b7 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/README.md @@ -0,0 +1,16 @@ +# iron-input + +An input with data binding. + +By default you can only get notified of changes to an `input`'s `value` due to user input: + +```html +<input value="{{myValue::input}}"> +``` + +`iron-input` adds the `bind-value` property that mirrors the `value` property, and can be used +for two-way data binding. `bind-value` will notify if it is changed either by user input or by script. + +```html +<input is="iron-input" bind-value="{{myValue}}"> +``` diff --git a/third_party/polymer/v1_0/components/iron-input/bower.json b/third_party/polymer/v1_0/components/iron-input/bower.json new file mode 100644 index 0000000..15142ba --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/bower.json @@ -0,0 +1,35 @@ +{ + "name": "iron-input", + "version": "1.0.1", + "description": "An input element with data binding", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "iron-input.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-input", + "ignore": [], + "dependencies": { + "iron-validatable-behavior": "PolymerElements/iron-validatable-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-input/hero.svg b/third_party/polymer/v1_0/components/iron-input/hero.svg new file mode 100644 index 0000000..146ffea --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/hero.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <rect x="49" y="53" width="2" height="18"/> + <path d="M188,78H37V44h151V78z M39,76h147V46H39V76z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-input/index.html b/third_party/polymer/v1_0/components/iron-input/index.html new file mode 100644 index 0000000..ca0dac0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-input</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-input/iron-input.html b/third_party/polymer/v1_0/components/iron-input/iron-input.html new file mode 100644 index 0000000..623a605 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-input/iron-input.html @@ -0,0 +1,188 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-validatable-behavior/iron-validatable-behavior.html"> + +<script> + +/* +`<iron-input>` adds two-way binding and custom validators using `Polymer.IronValidatorBehavior` +to `<input>`. + +### Two-way binding + +By default you can only get notified of changes to an `input`'s `value` due to user input: + + <input value="{{myValue::input}}"> + +`iron-input` adds the `bind-value` property that mirrors the `value` property, and can be used +for two-way data binding. `bind-value` will notify if it is changed either by user input or by script. + + <input is="iron-input" bind-value="{{myValue}}"> + +### Custom validators + +You can use custom validators that implement `Polymer.IronValidatorBehavior` with `<iron-input>`. + + <input is="iron-input" validator="my-custom-validator"> + +### Stopping invalid input + +It may be desirable to only allow users to enter certain characters. You can use the +`prevent-invalid-input` and `allowed-pattern` attributes together to accomplish this. This feature +is separate from validation, and `allowed-pattern` does not affect how the input is validated. + + <!-- only allow characters that match [0-9] --> + <input is="iron-input" prevent-invaild-input allowed-pattern="[0-9]"> + +@hero hero.svg +@demo demo/index.html +*/ + + Polymer({ + + is: 'iron-input', + + extends: 'input', + + behaviors: [ + Polymer.IronValidatableBehavior + ], + + properties: { + + /** + * Use this property instead of `value` for two-way data binding. + */ + bindValue: { + observer: '_bindValueChanged', + type: String + }, + + /** + * Set to true to prevent the user from entering invalid input. The new input characters are + * matched with `allowedPattern` if it is set, otherwise it will use the `pattern` attribute if + * set, or the `type` attribute (only supported for `type=number`). + */ + preventInvalidInput: { + type: Boolean + }, + + /** + * Regular expression to match valid input characters. + */ + allowedPattern: { + type: String + }, + + _previousValidInput: { + type: String, + value: '' + } + + }, + + listeners: { + 'input': '_onInput', + 'keydown': '_onKeydown' + }, + + get _patternRegExp() { + var pattern; + if (this.allowedPattern) { + pattern = new RegExp(this.allowedPattern); + } else if (this.pattern) { + pattern = new RegExp(this.pattern); + } else { + switch (this.type) { + case 'number': + pattern = /[0-9.,e-]/; + break; + } + } + return pattern; + }, + + ready: function() { + this.bindValue = this.value; + }, + + _bindValueChanged: function() { + if (this.value !== this.bindValue) { + this.value = this.bindValue; + } + // manually notify because we don't want to notify until after setting value + this.fire('bind-value-changed', {value: this.bindValue}); + }, + + _onInput: function() { + this.bindValue = this.value; + }, + + _isPrintable: function(keyCode) { + var printable = + (keyCode > 47 && keyCode < 58) || // number keys + keyCode == 32 || keyCode == 13 || // spacebar & return key + (keyCode > 64 && keyCode < 91) || // letter keys + (keyCode > 95 && keyCode < 112) || // numpad keys + (keyCode > 185 && keyCode < 193) || // ;=,-./` (in order) + (keyCode > 218 && keyCode < 223); // [\]' (in order) + return printable; + }, + + // convert printable numpad keys to number keys + _correctNumpadKeys: function(keyCode) { + return (keyCode > 95 && keyCode < 112) ? keyCode - 48 : keyCode; + }, + + _onKeydown: function(event) { + if (!this.preventInvalidInput && this.type !== 'number') { + return; + } + var regexp = this._patternRegExp; + if (!regexp) { + return; + } + var thisChar = String.fromCharCode(this._correctNumpadKeys(event.keyCode)); + if (this._isPrintable(event.keyCode) && !regexp.test(thisChar)) { + event.preventDefault(); + } + }, + + /** + * Returns true if `value` is valid. The validator provided in `validator` will be used first, + * then any constraints. + * @return {Boolean} True if the value is valid. + */ + validate: function() { + // Empty, non-required input is valid. + if (!this.required && this.value == '') + return true; + + var valid; + if (this.hasValidator()) { + valid = Polymer.IronValidatableBehavior.validate.call(this, this.value); + } else { + this.invalid = !this.validity.valid; + valid = this.validity.valid; + } + this.fire('iron-input-validate'); + return valid; + } + + }); + + /* + The `iron-input-validate` event is fired whenever `validate()` is called. + @event iron-input-validate + */ + +</script> diff --git a/third_party/polymer/v1_0/components/iron-jsonp-library/.bower.json b/third_party/polymer/v1_0/components/iron-jsonp-library/.bower.json new file mode 100644 index 0000000..31660e4 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-jsonp-library/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "iron-jsonp-library", + "version": "1.0.0", + "description": "Loads jsonp libraries", + "authors": [ + "Aleks Totic <a@totic.org>", + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "behavior" + ], + "main": "iron-jsonp-library.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-jsonp-library/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "2957a77f8797e59f2cd97a61b9844c4f7a716f19" + }, + "_source": "git://github.com/PolymerElements/iron-jsonp-library.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-jsonp-library" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-jsonp-library/README.md b/third_party/polymer/v1_0/components/iron-jsonp-library/README.md new file mode 100644 index 0000000..d1b3206 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-jsonp-library/README.md @@ -0,0 +1,10 @@ +# iron-jsonp-library + +`Polymer.IronJsonpLibraryBehavior` loads a jsonp library. +Multiple components can request same library, only one copy will load. + +Some libraries require a specific global function be defined. +If this is the case, specify the `callbackName` property. + +You should use an HTML Import to load library dependencies +when possible instead of using this element. diff --git a/third_party/polymer/v1_0/components/iron-jsonp-library/bower.json b/third_party/polymer/v1_0/components/iron-jsonp-library/bower.json new file mode 100644 index 0000000..7f865fe --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-jsonp-library/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-jsonp-library", + "version": "1.0.0", + "description": "Loads jsonp libraries", + "authors": [ + "Aleks Totic <a@totic.org>", + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "behavior" + ], + "main": "iron-jsonp-library.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-jsonp-library/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-ajax": "PolymerElements/iron-ajax#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-jsonp-library/hero.svg b/third_party/polymer/v1_0/components/iron-jsonp-library/hero.svg new file mode 100644 index 0000000..d6c1c13 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-jsonp-library/hero.svg @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="112" cy="36" r="4"/> + <circle cx="112" cy="90" r="4"/> + <circle cx="91" cy="98" r="4"/> + <circle cx="91" cy="29" r="4"/> + <circle cx="133" cy="29" r="4"/> + <circle cx="133" cy="97" r="4"/> + <circle cx="56" cy="63" r="4"/> + <circle cx="168" cy="63" r="4"/> + <circle cx="99" cy="63" r="4"/> + <circle cx="125" cy="63" r="4"/> + <path d="M90.8,98.5c-19.6,0-35.5-15.9-35.5-35.5s15.9-35.5,35.5-35.5s35.5,15.9,35.5,35.5S110.3,98.5,90.8,98.5z M90.8,29.5 + c-18.5,0-33.5,15-33.5,33.5s15,33.5,33.5,33.5s33.5-15,33.5-33.5S109.2,29.5,90.8,29.5z"/> + <path d="M133.2,98.5c-19.6,0-35.5-15.9-35.5-35.5s15.9-35.5,35.5-35.5s35.5,15.9,35.5,35.5S152.8,98.5,133.2,98.5z M133.2,29.5 + c-18.5,0-33.5,15-33.5,33.5s15,33.5,33.5,33.5s33.5-15,33.5-33.5S151.7,29.5,133.2,29.5z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-jsonp-library/index.html b/third_party/polymer/v1_0/components/iron-jsonp-library/index.html new file mode 100644 index 0000000..487bb5c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-jsonp-library/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-jsonp-library/iron-jsonp-library.html b/third_party/polymer/v1_0/components/iron-jsonp-library/iron-jsonp-library.html new file mode 100644 index 0000000..e4c04b5 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-jsonp-library/iron-jsonp-library.html @@ -0,0 +1,257 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<script> +(function() { + "use strict"; + /** + `Polymer.IronJsonpLibraryBehavior` loads a jsonp library. + Multiple components can request same library, only one copy will load. + + Some libraries require a specific global function be defined. + If this is the case, specify the `callbackName` property. + + You should use an HTML Import to load library dependencies + when possible instead of using this element. + + @hero hero.svg + @polymerBehavior + */ + Polymer.IronJsonpLibraryBehavior = { + + properties: { + /** + * True if library has been successfully loaded + */ + libraryLoaded: { + type: Boolean, + value: false, + notify: true, + readOnly: true + }, + /** + * Not null if library has failed to load + */ + libraryErrorMessage: { + type: String, + value: null, + notify: true, + readOnly: true + } + // Following properties are to be set by behavior users + /** + * Library url. Must contain string `%%callback_name%%`. + * + * `%%callback_name%%` is a placeholder for jsonp wrapper function name + * + * Ex: https://maps.googleapis.com/maps/api/js?callback=%%callback%% + * @property libraryUrl + */ + /** + * Set if library requires specific callback name. + * Name will be automatically generated if not set. + * @property callbackName + */ + /** + * name of event to be emitted when library loads. Standard is `api-load` + * @property notifyEvent + */ + /** + * event with name specified in `notifyEvent` attribute + * will fire upon successful load2 + * @event `notifyEvent` + */ + }, + + _libraryLoadCallback: function(err, result) { + if (err) { + console.warn("Library load failed:", err.message); + this._setLibraryErrorMessage(err.message); + } + else { + this._setLibraryErrorMessage(null); + this._setLibraryLoaded(true); + if (this.notifyEvent) + this.fire( this.notifyEvent, result); + } + }, + + /** loads the library, and fires this.notifyEvent upon completion */ + _loadLibrary: function() { + LoaderMap.require( + this.libraryUrl, + this._libraryLoadCallback.bind(this), + this.callbackName + ); + }, + + ready: function() { + this._loadLibrary(); + } + }; + + /* + * LoaderMap keeps track of all Loaders + */ + var LoaderMap = { + apiMap: {}, // { hash -> Loader } + + /* + * @param {function} notifyCallback loaded callback fn(result) + * @param {string} jsonpCallbackName name of jsonpcallback. If API does not provide it, leave empty. Optional. + */ + require: function(url, notifyCallback, jsonpCallbackName) { + + // make hashable string form url + var name = this.nameFromUrl(url); + + // create a loader as needed + if (!this.apiMap[name]) + this.apiMap[name] = new Loader(name, url, jsonpCallbackName); + + // ask for notification + this.apiMap[name].requestNotify(notifyCallback); + }, + + nameFromUrl: function(url) { + return url.replace(/[\:\/\%\?\&\.\=\-\,]/g, '_') + '_api'; + } + }; + + var Loader = function(name, url, callbackName) { + this.notifiers = []; // array of notifyFn [ notifyFn* ] + + // callback is specified either as callback name + // or computed dynamically if url has callbackMacro in it + if (!callbackName) { + if (url.indexOf(this.callbackMacro) >= 0) { + callbackName = name + '_loaded'; + url = url.replace(this.callbackMacro, callbackName); + } else { + this.error = new Error('IronJsonpLibraryBehavior a %%callback_name%% parameter is required in libraryUrl'); + // TODO(sjmiles): we should probably fallback to listening to script.load + return; + } + } + this.callbackName = callbackName; + window[this.callbackName] = this.success.bind(this); + this.addScript(url); + }; + + Loader.prototype = { + + callbackMacro: '%%callback%%', + loaded: false, + + addScript: function(src) { + var script = document.createElement('script'); + script.src = src; + script.onerror = this.handleError.bind(this); + var s = document.querySelector('script') || document.body; + s.parentNode.insertBefore(script, s); + this.script = script; + }, + + removeScript: function() { + if (this.script.parentNode) { + this.script.parentNode.removeChild(this.script); + } + this.script = null; + }, + + handleError: function(ev) { + this.error = new Error("Library failed to load"); + this.notifyAll(); + this.cleanup(); + }, + + success: function() { + this.loaded = true; + this.result = Array.prototype.slice.call(arguments); + this.notifyAll(); + this.cleanup(); + }, + + cleanup: function() { + delete window[this.callbackName]; + }, + + notifyAll: function(notifyCallback) { + this.notifiers.forEach( function(notifyCallback) { + notifyCallback(this.error, this.result); + }.bind(this)); + this.notifiers = []; + }, + + requestNotify: function(notifyCallback) { + if (this.loaded || this.error) { + notifyCallback( this.error, this.result); + } else { + this.notifiers.push(notifyCallback); + } + } + }; +})(); +</script> + +<!-- + Loads specified jsonp library. + + Example: + + <iron-jsonp-library + library-url="https://apis.google.com/js/plusone.js?onload=%%callback%%" + notify-event="api-load" + library-loaded="{{loaded}}"></iron-jsonp-library> + + Will emit 'api-load' event when loaded, and set 'loaded' to true + + Implemented by Polymer.IronJsonpLibraryBehavior. Use it + to create specific library loader elements. + + @demo +--> +<script> + Polymer({ + + is: 'iron-jsonp-library', + + behaviors: [ Polymer.IronJsonpLibraryBehavior ], + + properties: { + /** + * Library url. Must contain string `%%callback_name%%`. + * + * `%%callback_name%%` is a placeholder for jsonp wrapper function name + * + * Ex: https://maps.googleapis.com/maps/api/js?callback=%%callback%% + */ + libraryUrl: String, + /** + * Set if library requires specific callback name. + * Name will be automatically generated if not set. + */ + callbackName: String, + /** + * event with name specified in 'notifyEvent' attribute + * will fire upon successful load + */ + notifyEvent: String + /** + * event with name specified in 'notifyEvent' attribute + * will fire upon successful load + * @event `notifyEvent` + */ + + } + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-localstorage/.bower.json b/third_party/polymer/v1_0/components/iron-localstorage/.bower.json new file mode 100644 index 0000000..4e59d72 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/.bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-localstorage", + "version": "1.0.0", + "description": "Provides access to local storage", + "keywords": [ + "web-component", + "polymer", + "storage" + ], + "main": "iron-localstorage.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-localstorage/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "cecc6c2578287e779ffd76056cf5cf023799fc21" + }, + "_source": "git://github.com/PolymerElements/iron-localstorage.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-localstorage" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-localstorage/.gitignore b/third_party/polymer/v1_0/components/iron-localstorage/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-localstorage/README.md b/third_party/polymer/v1_0/components/iron-localstorage/README.md new file mode 100644 index 0000000..f3e1acd --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/README.md @@ -0,0 +1,13 @@ +iron-localstorage +================= + +Element access to localStorage. The "name" property +is the key to the data ("value" property) stored in localStorage. + +`iron-localstorage` automatically saves the value to localStorage when +value is changed. Note that if value is an object auto-save will be +triggered only when value is a different instance. + +```html +<iron-localstorage name="my-app-storage" value="{{value}}"></iron-localstorage> +``` diff --git a/third_party/polymer/v1_0/components/iron-localstorage/bower.json b/third_party/polymer/v1_0/components/iron-localstorage/bower.json new file mode 100644 index 0000000..95784b64a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/bower.json @@ -0,0 +1,22 @@ +{ + "name": "iron-localstorage", + "version": "1.0.0", + "description": "Provides access to local storage", + "keywords": [ + "web-component", + "polymer", + "storage" + ], + "main": "iron-localstorage.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-localstorage/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-localstorage/hero.svg b/third_party/polymer/v1_0/components/iron-localstorage/hero.svg new file mode 100644 index 0000000..0c0ec6b --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/hero.svg @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M124,45.3c-0.5-0.6-4.7-1.6-12-1.6s-11.5,1.1-12,1.6c0,0,0.1-0.3,0.1-0.3h-2c0-3,10.7-3.4,14-3.4s14,0.4,14,3.4h-2 + C124,45,124,45.3,124,45.3z"/> + <path d="M112,83c-3.3,0-14-0.2-14-3.4l0-7.6l0-1.6l2,0c0-0.2-0.1-0.3-0.1-0.3c0.5,0.6,4.7,1.6,12,1.6s11.5-1.1,12-1.6 + c0,0-0.1,0.1-0.1,0.3l2,0l0,1.5l0,7.7C126,82.8,115.3,83,112,83z M100,79.4c0.8,0.6,4.9,1.6,12,1.6s11.2-1,12-1.6l0-7 + c-3.2,1.3-9.6,1.4-12,1.4c-2.4,0-8.8-0.1-12-1.4L100,79.4z"/> + <path d="M112,70c-3.3,0-14-0.2-14-3.4l0-7.6l0-1.6l2,0c0-0.2-0.1-0.3-0.1-0.3c0.5,0.6,4.7,1.6,12,1.6s11.5-1.1,12-1.6 + c0,0-0.1,0.1-0.1,0.3l2,0l0,1.5l0,7.7C126,69.8,115.3,70,112,70z M100,66.4c0.8,0.6,4.9,1.6,12,1.6s11.2-1,12-1.6l0-7 + c-3.2,1.3-9.6,1.4-12,1.4c-2.4,0-8.8-0.1-12-1.4L100,66.4z"/> + <path d="M112,57c-3.3,0-14-0.2-14-3.4l0-7.6l0-1.6l2,0c0-0.2-0.1-0.3-0.1-0.3c0.5,0.6,4.7,1.6,12,1.6s11.5-1.1,12-1.6 + c0,0-0.1,0.1-0.1,0.3l2,0l0,1.5l0,7.7C126,56.8,115.3,57,112,57z M100,53.4c0.8,0.6,4.9,1.6,12,1.6s11.2-1,12-1.6l0-7 + c-3.2,1.3-9.6,1.4-12,1.4c-2.4,0-8.8-0.1-12-1.4L100,53.4z"/> + <path d="M151,99H73V27h78V99z M75,97h74V29H75V97z"/> + <circle cx="74" cy="28" r="4"/> + <circle cx="150" cy="28" r="4"/> + <circle cx="150" cy="98" r="4"/> + <circle cx="74" cy="98" r="4"/> + <circle cx="113" cy="98" r="4"/> + <circle cx="113" cy="28" r="4"/> + <circle cx="74" cy="63" r="4"/> + <circle cx="150" cy="63" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-localstorage/index.html b/third_party/polymer/v1_0/components/iron-localstorage/index.html new file mode 100644 index 0000000..246af10 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/index.html @@ -0,0 +1,23 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-localstorage/iron-localstorage.html b/third_party/polymer/v1_0/components/iron-localstorage/iron-localstorage.html new file mode 100644 index 0000000..986cbcd --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-localstorage/iron-localstorage.html @@ -0,0 +1,196 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<!-- +Element access to Web Storage API (window.localStorage). + +Keeps `value` is sync with a localStorage key. + +Direct assignments to `value` are automatically detected and saved. +Subproperty assignments are not (ex: `value.bar='foo'`). +Call `save()` manually to commit your changes after modifying subproperties. + +Value is saved in localStorage as JSON by default. + +If you set the value to null, storage key will be deleted. + + <iron-localstorage name="my-app-storage" value="{{value}}"> + </iron-localstorage> + + +<b>Warning</b>: do not pass subproperty bindings to iron-localstorage until Polymer +[bug 1550](https://github.com/Polymer/polymer/issues/1550) +is resolved. Local storage will be blown away. +No `<iron-localstorage value="{{foo.bar}}"`. + +@group Iron Elements +@demo demo/index.html +@hero hero.svg +@element iron-localstorage +--> +<dom-module id="iron-localstorage"></dom-module> +<script> + + Polymer({ + is: 'iron-localstorage', + + /** + * Fired when value loads from localStorage. + * + * @param {Object} detail + * @param {Boolean} detail.externalChange true if change occured in different window + * @event iron-localstorage-load + */ + + /** + * Fired when loaded value is null. + * You can use event handler to initialize default value. + * + * @event iron-localstorage-load-empty + */ + properties: { + /** + * The key to the data stored in localStorage. + */ + name: { + type: String, + value: '' + }, + /** + * The data associated with this storage. + * If value is set to null, and storage is in useRaw mode, item will be deleted + */ + value: { + type: Object, + notify: true + }, + + /** + * Value is stored and retrieved without JSON parse if true + */ + useRaw: { + type: Boolean, + value: false + }, + + /** + * Auto save is disabled if true. Default to false. + */ + autoSaveDisabled: { + type: Boolean, + value: false + }, + /** + * Last error encountered while saving/loading items. Null otherwise + */ + errorMessage: { + type: String, + notify: true + }, + /* + * True if value was loaded + */ + _loaded: { + type: Boolean, + value: false + } + }, + + observers: [ + 'reload(name,useRaw)', + '_trySaveValue(value, _loaded, autoSaveDisabled)' + ], + + ready: function() { + this._boundHandleStorage = this._handleStorage.bind(this); + }, + + attached: function() { + window.addEventListener('storage', this._boundHandleStorage); + }, + + detached: function() { + window.removeEventListener('storage', this._boundHandleStorage); + }, + + _handleStorage: function(ev) { + if (ev.key == this.name) { + this._load(true); + } + }, + + _trySaveValue: function(value, _loaded, autoSaveDisabled) { + if (this._justLoaded) { // guard against saving after _load() + this._justLoaded = false; + return; + } + if (_loaded && !autoSaveDisabled) { + this.save(); + } + }, + + /** + * Loads the value again. Use if you modify + * localStorage using DOM calls, and want to + * keep this element in sync. + */ + reload: function() { + this._load(); + }, + + /** + * loads value from local storage + * @param {Boolean} externalChange true if loading changes from a different window + */ + _load: function(externalChange) { + var v = localStorage.getItem(this.name); + + if (v === null) { + this.fire('iron-localstorage-load-empty'); + } else if (!this.useRaw) { + try { + v = JSON.parse(v); + } catch(x) { + this.errorMessage = "Could not parse local storage value"; + console.error("could not parse local storage value", v); + } + } + + this._justLoaded = true; + this._loaded = true; + this.value = v; + this.fire('iron-localstorage-load', { externalChange: externalChange}); + }, + + /** + * Saves the value to localStorage. Call to save if autoSaveDisabled is set. + * If `value` is null, deletes localStorage. + */ + save: function() { + var v = this.useRaw ? this.value : JSON.stringify(this.value); + try { + if (this.value === null) { + localStorage.removeItem(this.name); + } else { + localStorage.setItem(this.name, v); + } + } + catch(ex) { + // Happens in Safari incognito mode, + this.errorMessage = ex.message; + console.error("localStorage could not be saved. Safari incoginito mode?", ex); + } + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-media-query/.bower.json b/third_party/polymer/v1_0/components/iron-media-query/.bower.json new file mode 100644 index 0000000..7bc9132 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/.bower.json @@ -0,0 +1,39 @@ +{ + "name": "iron-media-query", + "version": "1.0.1", + "description": "Lets you bind to a CSS media query", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-media-query" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-media-query", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "655ba5a1b8f2d8c3e5d0c4053a4f18d6c4c6ac69" + }, + "_source": "git://github.com/PolymerElements/iron-media-query.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-media-query" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-media-query/.gitignore b/third_party/polymer/v1_0/components/iron-media-query/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-media-query/README.md b/third_party/polymer/v1_0/components/iron-media-query/README.md new file mode 100644 index 0000000..3f1b91c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/README.md @@ -0,0 +1,11 @@ +# iron-media-query + +`iron-media-query` can be used to data bind to a CSS media query. +The `query` property is a bare CSS media query. +The `queryMatches` property is a boolean representing if the page matches that media query. + +Example: + +```html +<iron-media-query query="(min-width: 600px)" queryMatches="{{queryMatches}}"></iron-media-query> +``` diff --git a/third_party/polymer/v1_0/components/iron-media-query/bower.json b/third_party/polymer/v1_0/components/iron-media-query/bower.json new file mode 100644 index 0000000..1c692e7 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/bower.json @@ -0,0 +1,30 @@ +{ + "name": "iron-media-query", + "version": "1.0.1", + "description": "Lets you bind to a CSS media query", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "media" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-media-query" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-media-query", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-media-query/hero.svg b/third_party/polymer/v1_0/components/iron-media-query/hero.svg new file mode 100644 index 0000000..9b5e2a6 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/hero.svg @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M173,99H91V41h82V99z M93,97h78V43H93V97z"/> + <path d="M77,89H51V42h26V89z M53,87h22V44H53V87z"/> + <rect x="52" y="56" width="24" height="2"/> + <rect x="92" y="58" width="80" height="2"/> + <path d="M65.3,42h-2c0-10,8.7-18.7,18.7-18.7v2C73,25.3,65.3,33,65.3,42z"/> + <path d="M105.3,42h-2c0-9-7.3-16.7-16.3-16.7v-2C97,23.3,105.3,32,105.3,42z"/> + <circle cx="84.3" cy="24.3" r="4"/> + <circle cx="69.3" cy="80.3" r="4"/> + <circle cx="160.3" cy="59.3" r="4"/> + <path d="M49,41v49c0,1.1,0.9,2,2,2h26c1.1,0,2-0.9,2-2V41c0-1.1-0.9-2-2-2H51C49.9,39,49,39.9,49,41z M76,88H52V43h24V88z"/> + <path d="M88.9,40.7v59c0,1.1,0.9,2,2,2h82c1.1,0,2-0.9,2-2v-59c0-1.1-0.9-2-2-2h-82C89.8,38.7,88.9,39.6,88.9,40.7z M172,98H93V42 + h79V98z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-media-query/index.html b/third_party/polymer/v1_0/components/iron-media-query/index.html new file mode 100644 index 0000000..7aee5c1 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-media-query</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-media-query/iron-media-query.html b/third_party/polymer/v1_0/components/iron-media-query/iron-media-query.html new file mode 100644 index 0000000..4d51cb7 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-media-query/iron-media-query.html @@ -0,0 +1,84 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-media-query` can be used to data bind to a CSS media query. +The `query` property is a bare CSS media query. +The `queryMatches` property is a boolean representing if the page matches that media query. + +Example: + + <iron-media-query query="(min-width: 600px)" queryMatches="{{queryMatches}}"></iron-media-query> + +@group Iron Elements +@demo demo/index.html +@hero hero.svg +@element iron-media-query +--> + +<script> + + Polymer({ + + is: 'iron-media-query', + + properties: { + + /** + * The Boolean return value of the media query. + * + * @attribute queryMatches + * @type Boolean + * @default false + */ + queryMatches: { + type: Boolean, + value: false, + readOnly: true, + notify: true + }, + + /** + * The CSS media query to evaluate. + * + * @attribute query + * @type String + */ + query: { + type: String, + observer: 'queryChanged' + } + + }, + + created: function() { + this._mqHandler = this.queryHandler.bind(this); + }, + + queryChanged: function(query) { + if (this._mq) { + this._mq.removeListener(this._mqHandler); + } + if (query[0] !== '(') { + query = '(' + query + ')'; + } + this._mq = window.matchMedia(query); + this._mq.addListener(this._mqHandler); + this.queryHandler(this._mq); + }, + + queryHandler: function(mq) { + this._setQueryMatches(mq.matches); + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-menu-behavior/.bower.json new file mode 100644 index 0000000..7ca24d4 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "iron-menu-behavior", + "version": "1.0.1", + "description": "Provides accessible menu behavior", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior", + "menu" + ], + "main": "iron-menu-behavior.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-menu-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-menu-behavior", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "3809f0eb7461c8ca63640aaa238775b3a25aa578" + }, + "_source": "git://github.com/PolymerElements/iron-menu-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-menu-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-menu-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/README.md b/third_party/polymer/v1_0/components/iron-menu-behavior/README.md new file mode 100644 index 0000000..42ab7fa --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/README.md @@ -0,0 +1,3 @@ +# iron-menu-behavior + +`Polymer.IronMenuBehavior` implements accessible menu behavior. diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/bower.json b/third_party/polymer/v1_0/components/iron-menu-behavior/bower.json new file mode 100644 index 0000000..f0d453c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/bower.json @@ -0,0 +1,32 @@ +{ + "name": "iron-menu-behavior", + "version": "1.0.1", + "description": "Provides accessible menu behavior", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior", + "menu" + ], + "main": "iron-menu-behavior.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-menu-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-menu-behavior", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/index.html b/third_party/polymer/v1_0/components/iron-menu-behavior/index.html new file mode 100644 index 0000000..2c643c4 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-menu-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="iron-menubar-behavior.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/iron-menu-behavior.html b/third_party/polymer/v1_0/components/iron-menu-behavior/iron-menu-behavior.html new file mode 100644 index 0000000..aa58c7f --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/iron-menu-behavior.html @@ -0,0 +1,214 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-selector/iron-multi-selectable.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + +<script> + + /** + * `Polymer.IronMenuBehavior` implements accessible menu behavior. + * + * @demo demo/index.html + * @polymerBehavior Polymer.IronMenuBehavior + */ + Polymer.IronMenuBehaviorImpl = { + + properties: { + + /** + * Returns the currently focused item. + * + * @attribute focusedItem + * @type Object + */ + focusedItem: { + observer: '_focusedItemChanged', + readOnly: true, + type: Object + }, + + /** + * The attribute to use on menu items to look up the item title. Typing the first + * letter of an item when the menu is open focuses that item. If unset, `textContent` + * will be used. + * + * @attribute attrForItemTitle + * @type String + */ + attrForItemTitle: { + type: String + } + }, + + hostAttributes: { + 'role': 'menu', + 'tabindex': '0' + }, + + observers: [ + '_updateMultiselectable(multi)' + ], + + listeners: { + 'focus': '_onFocus', + 'keydown': '_onKeydown' + }, + + keyBindings: { + 'up': '_onUpKey', + 'down': '_onDownKey', + 'esc': '_onEscKey', + 'enter': '_onEnterKey', + 'shift+tab:keydown': '_onShiftTabDown' + }, + + _updateMultiselectable: function(multi) { + if (multi) { + this.setAttribute('aria-multiselectable', 'true'); + } else { + this.removeAttribute('aria-multiselectable'); + } + }, + + _onShiftTabDown: function() { + var oldTabIndex; + + Polymer.IronMenuBehaviorImpl._shiftTabPressed = true; + + oldTabIndex = this.getAttribute('tabindex'); + + this.setAttribute('tabindex', '-1'); + + this.async(function() { + this.setAttribute('tabindex', oldTabIndex); + Polymer.IronMenuBehaviorImpl._shiftTabPressed = false; + // Note: polymer/polymer#1305 + }, 1); + }, + + _applySelection: function(item, isSelected) { + if (isSelected) { + item.setAttribute('aria-selected', 'true'); + } else { + item.removeAttribute('aria-selected'); + } + + Polymer.IronSelectableBehavior._applySelection.apply(this, arguments); + }, + + _focusedItemChanged: function(focusedItem, old) { + old && old.setAttribute('tabindex', '-1'); + if (focusedItem) { + focusedItem.setAttribute('tabindex', '0'); + focusedItem.focus(); + } + }, + + select: function(value) { + if (this._defaultFocusAsync) { + this.cancelAsync(this._defaultFocusAsync); + this._defaultFocusAsync = null; + } + var item = this._valueToItem(value); + this._setFocusedItem(item); + Polymer.IronMultiSelectableBehaviorImpl.select.apply(this, arguments); + }, + + _onFocus: function(event) { + if (Polymer.IronMenuBehaviorImpl._shiftTabPressed) { + return; + } + // do not focus the menu itself + this.blur(); + // clear the cached focus item + this._setFocusedItem(null); + this._defaultFocusAsync = this.async(function() { + // focus the selected item when the menu receives focus, or the first item + // if no item is selected + var selectedItem = this.multi ? (this.selectedItems && this.selectedItems[0]) : this.selectedItem; + if (selectedItem) { + this._setFocusedItem(selectedItem); + } else { + this._setFocusedItem(this.items[0]); + } + // async 100ms to wait for `select` to get called from `_itemActivate` + }, 100); + }, + + _onUpKey: function() { + // up and down arrows moves the focus + this._focusPrevious(); + }, + + _onDownKey: function() { + this._focusNext(); + }, + + _onEscKey: function() { + // esc blurs the control + this.focusedItem.blur(); + }, + + _onEnterKey: function(event) { + // enter activates the item unless it is disabled + this._activateFocused(event.detail.keyboardEvent); + }, + + _onKeydown: function(event) { + if (this.keyboardEventMatchesKeys(event, 'up down esc enter')) { + return; + } + + // all other keys focus the menu item starting with that character + this._focusWithKeyboardEvent(event); + }, + + _focusWithKeyboardEvent: function(event) { + for (var i = 0, item; item = this.items[i]; i++) { + var attr = this.attrForItemTitle || 'textContent'; + var title = item[attr] || item.getAttribute(attr); + if (title && title.trim().charAt(0).toLowerCase() === String.fromCharCode(event.keyCode).toLowerCase()) { + this._setFocusedItem(item); + break; + } + } + }, + + _activateFocused: function(event) { + if (!this.focusedItem.hasAttribute('disabled')) { + this._activateHandler(event); + } + }, + + _focusPrevious: function() { + var length = this.items.length; + var index = (Number(this.indexOf(this.focusedItem)) - 1 + length) % length; + this._setFocusedItem(this.items[index]); + }, + + _focusNext: function() { + var index = (Number(this.indexOf(this.focusedItem)) + 1) % this.items.length; + this._setFocusedItem(this.items[index]); + } + + }; + + Polymer.IronMenuBehaviorImpl._shiftTabPressed = false; + + /** @polymerBehavior Polymer.IronMenuBehavior */ + Polymer.IronMenuBehavior = [ + Polymer.IronMultiSelectableBehavior, + Polymer.IronA11yKeysBehavior, + Polymer.IronMenuBehaviorImpl + ]; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-menu-behavior/iron-menubar-behavior.html b/third_party/polymer/v1_0/components/iron-menu-behavior/iron-menubar-behavior.html new file mode 100644 index 0000000..e25304a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-menu-behavior/iron-menubar-behavior.html @@ -0,0 +1,65 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-menu-behavior.html"> + +<script> + + /** + * `Polymer.IronMenubarBehavior` implements accessible menubar behavior. + * + * @polymerBehavior Polymer.IronMenubarBehavior + */ + Polymer.IronMenubarBehaviorImpl = { + + hostAttributes: { + 'role': 'menubar' + }, + + keyBindings: { + 'left': '_onLeftKey', + 'right': '_onRightKey' + }, + + _onUpKey: function(event) { + this._activateFocused(event.detail.keyboardEvent); + }, + + _onDownKey: function(event) { + this._activateFocused(event.detail.keyboardEvent); + }, + + _onLeftKey: function() { + this._focusPrevious(); + }, + + _onRightKey: function() { + this._focusNext(); + }, + + _onKeydown: function(event) { + if (this.keyboardEventMatchesKeys(event, 'up down left right esc enter')) { + return; + } + + // all other keys focus the menu item starting with that character + this._focusWithKeyboardEvent(event); + } + + }; + + /** @polymerBehavior Polymer.IronMenubarBehavior */ + Polymer.IronMenubarBehavior = [ + Polymer.IronMenuBehavior, + Polymer.IronMenubarBehaviorImpl + ]; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-meta/.bower.json b/third_party/polymer/v1_0/components/iron-meta/.bower.json new file mode 100644 index 0000000..0336c02 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/.bower.json @@ -0,0 +1,33 @@ +{ + "name": "iron-meta", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Useful for sharing information across a DOM tree", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-meta", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "74e95dc020cfebfbf4343fb952f0f224ccd47f8e" + }, + "_source": "git://github.com/PolymerElements/iron-meta.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-meta" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-meta/.gitignore b/third_party/polymer/v1_0/components/iron-meta/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-meta/README.md b/third_party/polymer/v1_0/components/iron-meta/README.md new file mode 100644 index 0000000..b3b0f27 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/README.md @@ -0,0 +1,46 @@ +iron-meta +========= + +`iron-meta` is a generic element you can use for sharing information across the DOM tree. +It uses [monostate pattern](http://c2.com/cgi/wiki?MonostatePattern) such that any +instance of iron-meta has access to the shared +information. You can use `iron-meta` to share whatever you want (or create an extension +[like x-meta] for enhancements). + +The `iron-meta` instances containing your actual data can be loaded in an import, +or constructed in any way you see fit. The only requirement is that you create them +before you try to access them. + +Examples: + +If I create an instance like this: + +```html +<iron-meta key="info" keyUrl="foo/bar"></iron-meta> +``` + +Note that keyUrl="foo/bar" is the metadata I've defined. I could define more +attributes or use child nodes to define additional metadata. + +Now I can access that element (and it's metadata) from any iron-meta instance +via the byKey method, e.g. + +```javascript +meta.byKey('info').getAttribute('keyUrl'). +``` + +Pure imperative form would be like: + +```javascript +document.createElement('iron-meta').byKey('info').getAttribute('keyUrl'); +``` + +Or, in a Polymer element, you can include a meta in your template: + +```html +<iron-meta id="meta"></iron-meta> +``` + +```javascript +this.$.meta.byKey('info').getAttribute('keyUrl'); +``` diff --git a/third_party/polymer/v1_0/components/iron-meta/bower.json b/third_party/polymer/v1_0/components/iron-meta/bower.json new file mode 100644 index 0000000..6e7e3f3 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-meta", + "version": "1.0.1", + "keywords": [ + "web-components", + "polymer", + "meta" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Useful for sharing information across a DOM tree", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-meta/hero.svg b/third_party/polymer/v1_0/components/iron-meta/hero.svg new file mode 100644 index 0000000..ea8548d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/hero.svg @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="22" cy="85" r="4"/> + <circle cx="88" cy="98" r="4"/> + <path d="M87.5,100c-3.8-0.3-5.5-2.8-7-5c-1.4-2.1-2.7-3.9-5.5-4.2c-2.8-0.3-4.4,1.3-6.2,3.1c-1.9,1.9-4,4-7.8,3.7 + c-3.8-0.3-5.5-2.8-7-5c-1.4-2.1-2.7-3.9-5.5-4.2c-2.8-0.3-4.4,1.3-6.2,3.1c-1.9,1.9-4,4-7.8,3.7c-3.8-0.3-5.5-2.8-7-5 + c-1.4-2.1-2.7-3.9-5.5-4.2l0.2-2c3.8,0.3,5.5,2.8,7,5c1.4,2.1,2.7,3.9,5.5,4.2c2.8,0.3,4.4-1.3,6.2-3.1c1.9-1.9,4-4,7.8-3.7 + c3.8,0.3,5.5,2.8,7,5c1.4,2.1,2.7,3.9,5.5,4.2c2.8,0.3,4.4-1.3,6.2-3.1c1.9-1.9,4-4,7.8-3.7c3.8,0.3,5.5,2.8,7,5 + c1.4,2.1,2.7,3.9,5.5,4.2L87.5,100z"/> + <circle cx="96" cy="86" r="4"/> + <circle cx="162" cy="98" r="4"/> + <rect x="95.5" y="91" transform="matrix(0.9839 0.1789 -0.1789 0.9839 18.5382 -21.5923)" width="67.1" height="2"/> + <g> + <path d="M27,41.5l4.5,13.4l4.9-13.4h5.4v32h-4.4V61l0.4-13.4l-5.4,14.5h-2L25.6,48L26,61v12.5h-4.4v-32H27z"/> + <path d="M67.5,58.7H53.4V70h16.4v3.5H49v-32h20.6V45H53.4v10.2h14.2V58.7z"/> + <path d="M98.5,45H88.3v28.5h-4.4V45H73.6v-3.5h24.9V45z"/> + <path d="M116.2,65.3H105l-2.6,8.2h-4.5l10.9-32h3.8l10.6,32h-4.5L116.2,65.3z M106.2,61.6h8.9l-4.4-14.2L106.2,61.6z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-meta/index.html b/third_party/polymer/v1_0/components/iron-meta/index.html new file mode 100644 index 0000000..c70dc6e --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <title>iron-meta</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-meta/iron-meta.html b/third_party/polymer/v1_0/components/iron-meta/iron-meta.html new file mode 100644 index 0000000..10addd7 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-meta/iron-meta.html @@ -0,0 +1,352 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<!-- +`iron-meta` is a generic element you can use for sharing information across the DOM tree. +It uses [monostate pattern](http://c2.com/cgi/wiki?MonostatePattern) such that any +instance of iron-meta has access to the shared +information. You can use `iron-meta` to share whatever you want (or create an extension +[like x-meta] for enhancements). + +The `iron-meta` instances containing your actual data can be loaded in an import, +or constructed in any way you see fit. The only requirement is that you create them +before you try to access them. + +Examples: + +If I create an instance like this: + + <iron-meta key="info" keyUrl="foo/bar"></iron-meta> + +Note that keyUrl="foo/bar" is the metadata I've defined. I could define more +attributes or use child nodes to define additional metadata. + +Now I can access that element (and it's metadata) from any iron-meta instance +via the byKey method, e.g. + + meta.byKey('info').getAttribute('keyUrl'). + +Pure imperative form would be like: + + document.createElement('iron-meta').byKey('info').getAttribute('keyUrl'); + +Or, in a Polymer element, you can include a meta in your template: + + <iron-meta id="meta"></iron-meta> + ... + this.$.meta.byKey('info').getAttribute('keyUrl'); + +@group Iron Elements +@demo demo/index.html +@hero hero.svg +@element iron-meta +--> + +<script> + + (function() { + + // monostate data + var metaDatas = {}; + var metaArrays = {}; + + Polymer.IronMeta = Polymer({ + + is: 'iron-meta', + + properties: { + + /** + * The type of meta-data. All meta-data of the same type is stored + * together. + * + * @attribute type + * @type String + * @default 'default' + */ + type: { + type: String, + value: 'default', + observer: '_typeChanged' + }, + + /** + * The key used to store `value` under the `type` namespace. + * + * @attribute key + * @type String + * @default '' + */ + key: { + type: String, + observer: '_keyChanged' + }, + + /** + * The meta-data to store or retrieve. + * + * @attribute value + * @type * + * @default this + */ + value: { + type: Object, + notify: true, + observer: '_valueChanged' + }, + + /** + * If true, `value` is set to the iron-meta instance itself. + * + * @attribute self + * @type Boolean + * @default false + */ + self: { + type: Boolean, + observer: '_selfChanged' + }, + + /** + * Array of all meta-data values for the given type. + * + * @property list + * @type Array + */ + list: { + type: Array, + notify: true + } + + }, + + /** + * Only runs if someone invokes the factory/constructor directly + * e.g. `new Polymer.IronMeta()` + */ + factoryImpl: function(config) { + if (config) { + for (var n in config) { + switch(n) { + case 'type': + case 'key': + case 'value': + this[n] = config[n]; + break; + } + } + } + }, + + created: function() { + // TODO(sjmiles): good for debugging? + this._metaDatas = metaDatas; + this._metaArrays = metaArrays; + }, + + _keyChanged: function(key, old) { + this._resetRegistration(old); + }, + + _valueChanged: function(value) { + this._resetRegistration(this.key); + }, + + _selfChanged: function(self) { + if (self) { + this.value = this; + } + }, + + _typeChanged: function(type) { + this._unregisterKey(this.key); + if (!metaDatas[type]) { + metaDatas[type] = {}; + } + this._metaData = metaDatas[type]; + if (!metaArrays[type]) { + metaArrays[type] = []; + } + this.list = metaArrays[type]; + this._registerKeyValue(this.key, this.value); + }, + + /** + * Retrieves meta data value by key. + * + * @method byKey + * @param {String} key The key of the meta-data to be returned. + * @returns * + */ + byKey: function(key) { + return this._metaData && this._metaData[key]; + }, + + _resetRegistration: function(oldKey) { + this._unregisterKey(oldKey); + this._registerKeyValue(this.key, this.value); + }, + + _unregisterKey: function(key) { + this._unregister(key, this._metaData, this.list); + }, + + _registerKeyValue: function(key, value) { + this._register(key, value, this._metaData, this.list); + }, + + _register: function(key, value, data, list) { + if (key && data && value !== undefined) { + data[key] = value; + list.push(value); + } + }, + + _unregister: function(key, data, list) { + if (key && data) { + if (key in data) { + var value = data[key]; + delete data[key]; + this.arrayDelete(list, value); + } + } + } + + }); + + /** + `iron-meta-query` can be used to access infomation stored in `iron-meta`. + + Examples: + + If I create an instance like this: + + <iron-meta key="info" value="foo/bar"></iron-meta> + + Note that keyUrl="foo/bar" is the metadata I've defined. I could define more + attributes or use child nodes to define additional metadata. + + Now I can access that element (and it's metadata) from any `iron-meta-query` instance: + + var value = new Polymer.IronMetaQuery({key: 'info'}).value; + + @group Polymer Iron Elements + @element iron-meta-query + */ + Polymer.IronMetaQuery = Polymer({ + + is: 'iron-meta-query', + + properties: { + + /** + * The type of meta-data. All meta-data of the same type is stored + * together. + * + * @attribute type + * @type String + * @default 'default' + */ + type: { + type: String, + value: 'default', + observer: '_typeChanged' + }, + + /** + * Specifies a key to use for retrieving `value` from the `type` + * namespace. + * + * @attribute key + * @type String + */ + key: { + type: String, + observer: '_keyChanged' + }, + + /** + * The meta-data to store or retrieve. + * + * @attribute value + * @type * + * @default this + */ + value: { + type: Object, + notify: true, + readOnly: true + }, + + /** + * Array of all meta-data values for the given type. + * + * @property list + * @type Array + */ + list: { + type: Array, + notify: true + } + + }, + + /** + * Actually a factory method, not a true constructor. Only runs if + * someone invokes it directly (via `new Polymer.IronMeta()`); + */ + constructor: function(config) { + if (config) { + for (var n in config) { + switch(n) { + case 'type': + case 'key': + this[n] = config[n]; + break; + } + } + } + }, + + created: function() { + // TODO(sjmiles): good for debugging? + this._metaDatas = metaDatas; + this._metaArrays = metaArrays; + }, + + _keyChanged: function(key) { + this._setValue(this._metaData && this._metaData[key]); + }, + + _typeChanged: function(type) { + this._metaData = metaDatas[type]; + this.list = metaArrays[type]; + if (this.key) { + this._keyChanged(this.key); + } + }, + + /** + * Retrieves meta data value by key. + * + * @method byKey + * @param {String} key The key of the meta-data to be returned. + * @returns * + */ + byKey: function(key) { + return this._metaData && this._metaData[key]; + } + + }); + + })(); +</script> diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-overlay-behavior/.bower.json new file mode 100644 index 0000000..dd439c4 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "iron-overlay-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for making an element an overlay", + "private": true, + "main": [ + "iron-overlay-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior", + "overlay" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-overlay-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-overlay-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "03debac2eb637f2b3e68edb05d8f1e5902e81ebc" + }, + "_source": "git://github.com/PolymerElements/iron-overlay-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-overlay-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-overlay-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/README.md b/third_party/polymer/v1_0/components/iron-overlay-behavior/README.md new file mode 100644 index 0000000..17df695 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/README.md @@ -0,0 +1,11 @@ +# iron-overlay-behavior +Makes an element an overlay with an optional backdrop. + +`iron-overlay-behavior` displays an element on top of other content. It starts out hidden and is +displayed by calling `open()` or setting the `opened` property to `true`. It may be closed by +calling `close()` or `cancel()`, or by setting the `opened` property to `true`. + +The difference between `close()` and `cancel()` is user intent. `close()` generally implies that +the user acknowledged the content of the overlay. By default, it will cancel whenever the user taps +outside it or presses the escape key. This behavior can be turned off via the `no-cancel-on-esc-key` +and the `no-cancel-on-outside-click` properties. diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/bower.json b/third_party/polymer/v1_0/components/iron-overlay-behavior/bower.json new file mode 100644 index 0000000..7d4dead --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-overlay-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for making an element an overlay", + "private": true, + "main": [ + "iron-overlay-behavior.html" + ], + "keywords": [ + "web-components", + "polymer", + "behavior", + "overlay" + ], + "authors": [ + "The Polymer Authors" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-overlay-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-fit-behavior": "PolymerElements/iron-fit-behavior#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/index.html b/third_party/polymer/v1_0/components/iron-overlay-behavior/index.html new file mode 100644 index 0000000..d69e304 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-overlay-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-backdrop.html b/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-backdrop.html new file mode 100644 index 0000000..5682c28 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-backdrop.html @@ -0,0 +1,132 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-overlay-manager.html"> + +<!-- +`iron-overlay-backdrop` is a backdrop used by `Polymer.IronOverlayBehavior`. It should be a +singleton. + +### Styling + +The following custom properties and mixins are available for styling. + +Custom property | Description | Default +-------------------------------------------|------------------------|--------- +`--iron-overlay-backdrop-background-color` | Backdrop background color | #000 +`--iron-overlay-backdrop-opacity` | Backdrop opacity | 0.6 +`--iron-overlay-backdrop` | Mixin applied to `iron-overlay-backdrop`. | {} +`--iron-overlay-backdrop-opened` | Mixin applied to `iron-overlay-backdrop` when it is displayed | {} +--> + +<dom-module id="iron-overlay-backdrop"> + + <style> + + :host { + position: fixed; + top: 0; + left: 0; + width: 100vw; + height: 100vh; + background-color: var(--iron-overlay-backdrop-background-color, #000); + opacity: 0; + transition: opacity 0.2s; + + @apply(--iron-overlay-backdrop); + } + + :host([opened]) { + opacity: var(--iron-overlay-backdrop-opacity, 0.6); + + @apply(--iron-overlay-backdrop-opened); + } + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'iron-overlay-backdrop', + + properties: { + + /** + * Returns true if the backdrop is opened. + */ + opened: { + readOnly: true, + reflectToAttribute: true, + type: Boolean, + value: false + }, + + _manager: { + type: Object, + value: Polymer.IronOverlayManager + } + + }, + + /** + * Appends the backdrop to document body and sets its `z-index` to be below the latest overlay. + */ + prepare: function() { + if (!this.parentNode) { + Polymer.dom(document.body).appendChild(this); + this.style.zIndex = this._manager.currentOverlayZ() - 1; + } + }, + + /** + * Shows the backdrop if needed. + */ + open: function() { + // only need to make the backdrop visible if this is called by the first overlay with a backdrop + if (this._manager.getBackdrops().length < 2) { + this._setOpened(true); + } + }, + + /** + * Hides the backdrop if needed. + */ + close: function() { + // only need to make the backdrop invisible if this is called by the last overlay with a backdrop + if (this._manager.getBackdrops().length < 2) { + this._setOpened(false); + } + }, + + /** + * Removes the backdrop from document body if needed. + */ + complete: function() { + // only remove the backdrop if there are no more overlays with backdrops + if (this._manager.getBackdrops().length === 0 && this.parentNode) { + Polymer.dom(this.parentNode).removeChild(this); + } + } + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-behavior.html b/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-behavior.html new file mode 100644 index 0000000..affc81a --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-behavior.html @@ -0,0 +1,432 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-fit-behavior/iron-fit-behavior.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="iron-overlay-backdrop.html"> +<link rel="import" href="iron-overlay-manager.html"> + +<script> + +/* +Use `Polymer.IronOverlayBehavior` to implement an element that can be hidden or shown, and displays +on top of other content. It includes an optional backdrop, and can be used to implement a variety +of UI controls including dialogs and drop downs. Multiple overlays may be displayed at once. + +### Closing and canceling + +A dialog may be hidden by closing or canceling. The difference between close and cancel is user +intent. Closing generally implies that the user acknowledged the content on the overlay. By default, +it will cancel whenever the user taps outside it or presses the escape key. This behavior is +configurable with the `no-cancel-on-esc-key` and the `no-cancel-on-outside-click` properties. +`close()` should be called explicitly by the implementer when the user interacts with a control +in the overlay element. + +### Positioning + +By default the element is sized and positioned to fit and centered inside the window. You can +position and size it manually using CSS. See `Polymer.IronFitBehavior`. + +### Backdrop + +Set the `with-backdrop` attribute to display a backdrop behind the overlay. The backdrop is +appended to `<body>` and is of type `<iron-overlay-backdrop>`. See its doc page for styling +options. + +### Limitations + +The element is styled to appear on top of other content by setting its `z-index` property. You +must ensure no element has a stacking context with a higher `z-index` than its parent stacking +context. You should place this element as a child of `<body>` whenever possible. + +@demo demo/index.html +@polymerBehavior Polymer.IronOverlayBehavior +*/ + + Polymer.IronOverlayBehaviorImpl = { + + properties: { + + /** + * True if the overlay is currently displayed. + */ + opened: { + observer: '_openedChanged', + type: Boolean, + value: false + }, + + /** + * True if the overlay was canceled when it was last closed. + */ + canceled: { + observer: '_canceledChanged', + readOnly: true, + type: Boolean, + value: false + }, + + /** + * Set to true to display a backdrop behind the overlay. + */ + withBackdrop: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable auto-focusing the overlay or child nodes with + * the `autofocus` attribute` when the overlay is opened. + */ + noAutoFocus: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable canceling the overlay with the ESC key. + */ + noCancelOnEscKey: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable canceling the overlay by clicking outside it. + */ + noCancelOnOutsideClick: { + type: Boolean, + value: false + }, + + /** + * Returns the reason this dialog was last closed. + */ + closingReason: { + // was a getter before, but needs to be a property so other + // behaviors can override this. + type: Object + }, + + _manager: { + type: Object, + value: Polymer.IronOverlayManager + }, + + _boundOnCaptureClick: { + type: Function, + value: function() { + return this._onCaptureClick.bind(this); + } + }, + + _boundOnCaptureKeydown: { + type: Function, + value: function() { + return this._onCaptureKeydown.bind(this); + } + } + + }, + + listeners: { + 'click': '_onClick', + 'iron-resize': '_onIronResize' + }, + + /** + * The backdrop element. + * @type Node + */ + get backdropElement() { + return this._backdrop; + }, + + get _focusNode() { + return Polymer.dom(this).querySelector('[autofocus]') || this; + }, + + registered: function() { + this._backdrop = document.createElement('iron-overlay-backdrop'); + }, + + ready: function() { + this._ensureSetup(); + if (this._callOpenedWhenReady) { + this._openedChanged(); + } + }, + + detached: function() { + this.opened = false; + this._completeBackdrop(); + this._manager.removeOverlay(this); + }, + + /** + * Toggle the opened state of the overlay. + */ + toggle: function() { + this.opened = !this.opened; + }, + + /** + * Open the overlay. + */ + open: function() { + this.opened = true; + this.closingReason = {canceled: false}; + }, + + /** + * Close the overlay. + */ + close: function() { + this.opened = false; + this._setCanceled(false); + }, + + /** + * Cancels the overlay. + */ + cancel: function() { + this.opened = false, + this._setCanceled(true); + }, + + _ensureSetup: function() { + if (this._overlaySetup) { + return; + } + this._overlaySetup = true; + this.style.outline = 'none'; + this.style.display = 'none'; + }, + + _openedChanged: function() { + if (this.opened) { + this.removeAttribute('aria-hidden'); + } else { + this.setAttribute('aria-hidden', 'true'); + } + + // wait to call after ready only if we're initially open + if (!this._overlaySetup) { + this._callOpenedWhenReady = this.opened; + return; + } + if (this._openChangedAsync) { + this.cancelAsync(this._openChangedAsync); + } + + this._toggleListeners(); + + if (this.opened) { + this._prepareRenderOpened(); + } + + // async here to allow overlay layer to become visible. + this._openChangedAsync = this.async(function() { + // overlay becomes visible here + this.style.display = ''; + // force layout to ensure transitions will go + this.offsetWidth; + if (this.opened) { + this._renderOpened(); + } else { + this._renderClosed(); + } + this._openChangedAsync = null; + }); + + }, + + _canceledChanged: function() { + this.closingReason = this.closingReason || {}; + this.closingReason.canceled = this.canceled; + }, + + _toggleListener: function(enable, node, event, boundListener, capture) { + if (enable) { + node.addEventListener(event, boundListener, capture); + } else { + node.removeEventListener(event, boundListener, capture); + } + }, + + _toggleListeners: function() { + if (this._toggleListenersAsync) { + this.cancelAsync(this._toggleListenersAsync); + } + // async so we don't auto-close immediately via a click. + this._toggleListenersAsync = this.async(function() { + this._toggleListener(this.opened, document, 'click', this._boundOnCaptureClick, true); + this._toggleListener(this.opened, document, 'keydown', this._boundOnCaptureKeydown, true); + this._toggleListenersAsync = null; + }); + }, + + // tasks which must occur before opening; e.g. making the element visible + _prepareRenderOpened: function() { + this._manager.addOverlay(this); + + if (this.withBackdrop) { + this.backdropElement.prepare(); + this._manager.trackBackdrop(this); + } + + this._preparePositioning(); + this.fit(); + this._finishPositioning(); + }, + + // tasks which cause the overlay to actually open; typically play an + // animation + _renderOpened: function() { + if (this.withBackdrop) { + this.backdropElement.open(); + } + this._finishRenderOpened(); + }, + + _renderClosed: function() { + if (this.withBackdrop) { + this.backdropElement.close(); + } + this._finishRenderClosed(); + }, + + _onTransitionend: function(event) { + // make sure this is our transition event. + if (event && event.target !== this) { + return; + } + if (this.opened) { + this._finishRenderOpened(); + } else { + this._finishRenderClosed(); + } + }, + + _finishRenderOpened: function() { + // focus the child node with [autofocus] + if (!this.noAutoFocus) { + this._focusNode.focus(); + } + + this.fire('iron-overlay-opened'); + + this._squelchNextResize = true; + this.async(this.notifyResize); + }, + + _finishRenderClosed: function() { + // hide the overlay and remove the backdrop + this.resetFit(); + this.style.display = 'none'; + this._completeBackdrop(); + this._manager.removeOverlay(this); + + this._focusNode.blur(); + // focus the next overlay, if there is one + this._manager.focusOverlay(); + + this.fire('iron-overlay-closed', this.closingReason); + + this._squelchNextResize = true; + this.async(this.notifyResize); + }, + + _completeBackdrop: function() { + if (this.withBackdrop) { + this._manager.trackBackdrop(this); + this.backdropElement.complete(); + } + }, + + _preparePositioning: function() { + this.style.transition = this.style.webkitTransition = 'none'; + this.style.transform = this.style.webkitTransform = 'none'; + this.style.display = ''; + }, + + _finishPositioning: function(target) { + this.style.display = 'none'; + this.style.transform = this.style.webkitTransform = ''; + // force layout to avoid application of transform + this.offsetWidth; + this.style.transition = this.style.webkitTransition = ''; + }, + + _applyFocus: function() { + if (this.opened) { + if (!this.noAutoFocus) { + this._focusNode.focus(); + } + } else { + this._focusNode.blur(); + this._manager.focusOverlay(); + } + }, + + _onCaptureClick: function(event) { + // attempt to close asynchronously and prevent the close of a tap event is immediately heard + // on target. This is because in shadow dom due to event retargetting event.target is not + // useful. + if (!this.noCancelOnOutsideClick && (this._manager.currentOverlay() == this)) { + this._cancelJob = this.async(function() { + this.cancel(); + }, 10); + } + }, + + _onClick: function(event) { + if (this._cancelJob) { + this.cancelAsync(this._cancelJob); + this._cancelJob = null; + } + }, + + _onCaptureKeydown: function(event) { + var ESC = 27; + if (!this.noCancelOnEscKey && (event.keyCode === ESC)) { + this.cancel(); + event.stopPropagation(); + } + }, + + _onIronResize: function() { + if (this._squelchNextResize) { + this._squelchNextResize = false; + return; + } + if (this.opened) { + this.refit(); + } + } + + }; + + /** @polymerBehavior */ + Polymer.IronOverlayBehavior = [Polymer.IronFitBehavior, Polymer.IronResizableBehavior, Polymer.IronOverlayBehaviorImpl]; + +/* + * Fired after the `iron-overlay` opens. + * @event iron-overlay-opened + */ + +/* + * Fired after the `iron-overlay` closes. + * @event iron-overlay-closed {{canceled: boolean}} detail - + * canceled: True if the overlay was canceled. + */ + +</script> diff --git a/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-manager.html b/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-manager.html new file mode 100644 index 0000000..c66f9aa --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-overlay-behavior/iron-overlay-manager.html @@ -0,0 +1,107 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + + Polymer.IronOverlayManager = (function() { + + var overlays = []; + var DEFAULT_Z = 10; + var backdrops = []; + + // track overlays for z-index and focus managemant + function addOverlay(overlay) { + var z0 = currentOverlayZ(); + overlays.push(overlay); + var z1 = currentOverlayZ(); + if (z1 <= z0) { + applyOverlayZ(overlay, z0); + } + } + + function removeOverlay(overlay) { + var i = overlays.indexOf(overlay); + if (i >= 0) { + overlays.splice(i, 1); + setZ(overlay, ''); + } + } + + function applyOverlayZ(overlay, aboveZ) { + setZ(overlay, aboveZ + 2); + } + + function setZ(element, z) { + element.style.zIndex = z; + } + + function currentOverlay() { + return overlays[overlays.length-1]; + } + + function currentOverlayZ() { + var z; + var current = currentOverlay(); + if (current) { + var z1 = window.getComputedStyle(current).zIndex; + if (!isNaN(z1)) { + z = Number(z1); + } + } + return z || DEFAULT_Z; + } + + function focusOverlay() { + var current = currentOverlay(); + // We have to be careful to focus the next overlay _after_ any current + // transitions are complete (due to the state being toggled prior to the + // transition). Otherwise, we risk infinite recursion when a transitioning + // (closed) overlay becomes the current overlay. + // + // NOTE: We make the assumption that any overlay that completes a transition + // will call into focusOverlay to kick the process back off. Currently: + // transitionend -> _applyFocus -> focusOverlay. + if (current && !current.transitioning) { + current._applyFocus(); + } + } + + function trackBackdrop(element) { + // backdrops contains the overlays with a backdrop that are currently + // visible + if (element.opened) { + backdrops.push(element); + } else { + var index = backdrops.indexOf(element); + if (index >= 0) { + backdrops.splice(index, 1); + } + } + } + + function getBackdrops() { + return backdrops; + } + + return { + addOverlay: addOverlay, + removeOverlay: removeOverlay, + currentOverlay: currentOverlay, + currentOverlayZ: currentOverlayZ, + focusOverlay: focusOverlay, + trackBackdrop: trackBackdrop, + getBackdrops: getBackdrops + }; + + })(); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-pages/.bower.json b/third_party/polymer/v1_0/components/iron-pages/.bower.json new file mode 100644 index 0000000..46d3ac1 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-pages", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Organizes a set of pages and shows one at a time", + "main": "iron-pages.html", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "dependencies": { + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "iron-selector": "polymerelements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-pages", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "5450f62ac96fb0b21237efb58b9847cd2ce9a27c" + }, + "_source": "git://github.com/PolymerElements/iron-pages.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-pages" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-pages/.gitignore b/third_party/polymer/v1_0/components/iron-pages/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-pages/README.md b/third_party/polymer/v1_0/components/iron-pages/README.md new file mode 100644 index 0000000..716ccc3 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/README.md @@ -0,0 +1,22 @@ +iron-pages +========== + +`iron-pages` is used to select one of its children to show. One use is to cycle through a list of +children "pages". + +Example: + +```html +<iron-pages selected="0"> + <div>One</div> + <div>Two</div> + <div>Three</div> +</iron-pages> + +<script> + document.addEventListener('click', function(e) { + var pages = document.querySelector('iron-pages'); + pages.selectNext(); + }); +</script> +``` diff --git a/third_party/polymer/v1_0/components/iron-pages/bower.json b/third_party/polymer/v1_0/components/iron-pages/bower.json new file mode 100644 index 0000000..57fd16d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/bower.json @@ -0,0 +1,27 @@ +{ + "name": "iron-pages", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Organizes a set of pages and shows one at a time", + "main": "iron-pages.html", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "container" + ], + "dependencies": { + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "iron-selector": "polymerelements/iron-selector#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-pages/hero.svg b/third_party/polymer/v1_0/components/iron-pages/hero.svg new file mode 100644 index 0000000..fa12783 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/hero.svg @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M143.3,73.6H51.7V26.7h91.6V73.6z M53.7,71.6h87.6V28.7H53.7V71.6z"/> + <path d="M158.3,85.4H66.7V38.6h91.6V85.4z M68.7,83.4h87.6V40.6H68.7V83.4z"/> + <path d="M172,99H80.4V52.1H172V99z M82.4,97H170V54.1H82.4V97z"/> + <circle cx="53" cy="28" r="4"/> + <circle cx="171" cy="98" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/iron-pages/index.html b/third_party/polymer/v1_0/components/iron-pages/index.html new file mode 100644 index 0000000..67ae088 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + <title>iron-pages</title> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-pages/iron-pages.html b/third_party/polymer/v1_0/components/iron-pages/iron-pages.html new file mode 100644 index 0000000..6fe2f48 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-pages/iron-pages.html @@ -0,0 +1,83 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="../iron-selector/iron-selectable.html"> + +<!-- +`iron-pages` is used to select one of its children to show. One use is to cycle through a list of +children "pages". + +Example: + + <iron-pages selected="0"> + <div>One</div> + <div>Two</div> + <div>Three</div> + </iron-pages> + + <script> + document.addEventListener('click', function(e) { + var pages = document.querySelector('iron-pages'); + pages.selectNext(); + }); + </script> + +@group Iron Elements +@class iron-pages +@hero hero.svg +@demo demo/index.html +@extends iron-selector +--> + +<dom-module id="iron-pages"> + + <style> + + :host { + display: block; + } + + :host > ::content > :not(.iron-selected) { + display: none !important; + } + + </style> + + <template> + + <content></content> + + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'iron-pages', + + behaviors: [ + Polymer.IronResizableBehavior, + Polymer.IronSelectableBehavior + ], + + observers: [ + '_selectedPageChanged(selected)' + ], + + _selectedPageChanged: function(selected, old) { + this.async(this.notifyResize); + } + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-range-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-range-behavior/.bower.json new file mode 100644 index 0000000..0a4896f --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-range-behavior/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "iron-range-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for something with a minimum and maximum value", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "main": [ + "iron-range-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-range-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-range-behavior", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "80aa8588f3b8527b96f3206655b29e23970fb7a3" + }, + "_source": "git://github.com/PolymerElements/iron-range-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-range-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-range-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-range-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-range-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-range-behavior/README.md b/third_party/polymer/v1_0/components/iron-range-behavior/README.md new file mode 100644 index 0000000..8d523bc --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-range-behavior/README.md @@ -0,0 +1,4 @@ +iron-range-behavior +========== + +`Polymer.IronRangeBehavior` provides the behavior for something with a minimum to maximum range. diff --git a/third_party/polymer/v1_0/components/iron-range-behavior/bower.json b/third_party/polymer/v1_0/components/iron-range-behavior/bower.json new file mode 100644 index 0000000..2f3cea4 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-range-behavior/bower.json @@ -0,0 +1,30 @@ +{ + "name": "iron-range-behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Provides a behavior for something with a minimum and maximum value", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "behavior" + ], + "main": [ + "iron-range-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-range-behavior.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-input": "PolymerElements/iron-input#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-range-behavior/index.html b/third_party/polymer/v1_0/components/iron-range-behavior/index.html new file mode 100644 index 0000000..25ed936 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-range-behavior/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-range-behavior/iron-range-behavior.html b/third_party/polymer/v1_0/components/iron-range-behavior/iron-range-behavior.html new file mode 100644 index 0000000..d89843d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-range-behavior/iron-range-behavior.html @@ -0,0 +1,101 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + + /** + * `iron-range-behavior` provides the behavior for something with a minimum to maximum range. + * + * @demo demo/index.html + * @polymerBehavior + */ + Polymer.IronRangeBehavior = { + + properties: { + + /** + * The number that represents the current value. + */ + value: { + type: Number, + value: 0, + notify: true, + reflectToAttribute: true + }, + + /** + * The number that indicates the minimum value of the range. + */ + min: { + type: Number, + value: 0, + notify: true + }, + + /** + * The number that indicates the maximum value of the range. + */ + max: { + type: Number, + value: 100, + notify: true + }, + + /** + * Specifies the value granularity of the range's value. + */ + step: { + type: Number, + value: 1, + notify: true + }, + + /** + * Returns the ratio of the value. + */ + ratio: { + type: Number, + value: 0, + readOnly: true, + notify: true + }, + }, + + observers: [ + '_update(value, min, max, step)' + ], + + _calcRatio: function(value) { + return (this._clampValue(value) - this.min) / (this.max - this.min); + }, + + _clampValue: function(value) { + return Math.min(this.max, Math.max(this.min, this._calcStep(value))); + }, + + _calcStep: function(value) { + return this.step ? (Math.round(value / this.step) / (1 / this.step)) : value; + }, + + _validateValue: function() { + var v = this._clampValue(this.value); + this.value = this.oldValue = isNaN(v) ? this.oldValue : v; + return this.value !== v; + }, + + _update: function() { + this._validateValue(); + this._setRatio(this._calcRatio(this.value) * 100); + } + +}; +</script> diff --git a/third_party/polymer/v1_0/components/iron-resizable-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-resizable-behavior/.bower.json new file mode 100644 index 0000000..abbcb68 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-resizable-behavior/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "iron-resizable-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Coordinates the flow of resizeable elements", + "private": true, + "main": "iron-resizable-behavior.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-resizable-behavior", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "62e0fb1dd6d657bceab7c78faf1a8b0fb909239c" + }, + "_source": "git://github.com/PolymerElements/iron-resizable-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-resizable-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-resizable-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-resizable-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-resizable-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-resizable-behavior/README.md b/third_party/polymer/v1_0/components/iron-resizable-behavior/README.md new file mode 100644 index 0000000..72be6de --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-resizable-behavior/README.md @@ -0,0 +1,16 @@ +iron-resizable-behavior +======================= + +`IronResizableBehavior` is a behavior that can be used in Polymer elements to +coordinate the flow of resize events between "resizers" (elements that control the +size or hidden state of their children) and "resizables" (elements that need to be +notified when they are resized or un-hidden by their parents in order to take +action on their new measurements). + +Elements that perform measurement should add the `IronResizableBehavior` behavior to +their element definition and listen for the `iron-resize` event on themselves. +This event will be fired when they become showing after having been hidden, +when they are resized explicitly by another resizable, or when the window has been +resized. + +Note, the `iron-resize` event is non-bubbling. diff --git a/third_party/polymer/v1_0/components/iron-resizable-behavior/bower.json b/third_party/polymer/v1_0/components/iron-resizable-behavior/bower.json new file mode 100644 index 0000000..b1c66f0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-resizable-behavior/bower.json @@ -0,0 +1,26 @@ +{ + "name": "iron-resizable-behavior", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Coordinates the flow of resizeable elements", + "private": true, + "main": "iron-resizable-behavior.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-resizable-behavior/index.html b/third_party/polymer/v1_0/components/iron-resizable-behavior/index.html new file mode 100644 index 0000000..b9b8809 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-resizable-behavior/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + + <title>iron-resizable-behavior</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-resizable-behavior/iron-resizable-behavior.html b/third_party/polymer/v1_0/components/iron-resizable-behavior/iron-resizable-behavior.html new file mode 100644 index 0000000..3529b4d0 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-resizable-behavior/iron-resizable-behavior.html @@ -0,0 +1,139 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + /** + * `IronResizableBehavior` is a behavior that can be used in Polymer elements to + * coordinate the flow of resize events between "resizers" (elements that control the + * size or hidden state of their children) and "resizables" (elements that need to be + * notified when they are resized or un-hidden by their parents in order to take + * action on their new measurements). + * Elements that perform measurement should add the `IronResizableBehavior` behavior to + * their element definition and listen for the `iron-resize` event on themselves. + * This event will be fired when they become showing after having been hidden, + * when they are resized explicitly by another resizable, or when the window has been + * resized. + * Note, the `iron-resize` event is non-bubbling. + * + * @polymerBehavior Polymer.IronResizableBehavior + * @demo demo/index.html + **/ + Polymer.IronResizableBehavior = { + properties: { + _parentResizable: { + type: Object, + observer: '_parentResizableChanged' + } + }, + + listeners: { + 'iron-request-resize-notifications': '_onIronRequestResizeNotifications' + }, + + created: function() { + // We don't really need property effects on these, and also we want them + // to be created before the `_parentResizable` observer fires: + this._interestedResizables = []; + this._boundNotifyResize = this.notifyResize.bind(this); + }, + + attached: function() { + this.fire('iron-request-resize-notifications', null, { + node: this, + bubbles: true + }); + + if (!this._parentResizable) { + window.addEventListener('resize', this._boundNotifyResize); + this.notifyResize(); + } + }, + + detached: function() { + if (this._parentResizable) { + this._parentResizable.stopResizeNotificationsFor(this); + } else { + window.removeEventListener('resize', this._boundNotifyResize); + } + + this._parentResizable = null; + }, + + /** + * Can be called to manually notify a resizable and its descendant + * resizables of a resize change. + */ + notifyResize: function() { + if (!this.isAttached) { + return; + } + + this._interestedResizables.forEach(function(resizable) { + // TODO(cdata): Currently behaviors cannot define "abstract" methods.. + if (!this.resizerShouldNotify || this.resizerShouldNotify(resizable)) { + resizable.notifyResize(); + } + }, this); + + this.fire('iron-resize', null, { + node: this, + bubbles: false + }); + }, + + /** + * Used to assign the closest resizable ancestor to this resizable + * if the ancestor detects a request for notifications. + */ + assignParentResizable: function(parentResizable) { + this._parentResizable = parentResizable; + }, + + /** + * Used to remove a resizable descendant from the list of descendants + * that should be notified of a resize change. + */ + stopResizeNotificationsFor: function(target) { + var index = this._interestedResizables.indexOf(target); + + if (index > -1) { + this._interestedResizables.splice(index, 1); + } + }, + + // TODO(cdata): Currently behaviors cannot define "abstract" methods. + // resizerShouldNotify: function(el) { return true; }, + + _parentResizableChanged: function(parentResizable) { + if (parentResizable) { + window.removeEventListener('resize', this._boundNotifyResize); + } + }, + + _onIronRequestResizeNotifications: function(event) { + var target = event.path ? event.path[0] : event.target; + + if (target === this) { + return; + } + + if (this._interestedResizables.indexOf(target) === -1) { + this._interestedResizables.push(target); + } + + target.assignParentResizable(this); + + event.stopPropagation(); + } + }; +</script> + diff --git a/third_party/polymer/v1_0/components/iron-selector/.bower.json b/third_party/polymer/v1_0/components/iron-selector/.bower.json new file mode 100644 index 0000000..31050826 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "iron-selector", + "version": "1.0.2", + "description": "Manages a set of elements that can be selected", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "main": [ + "iron-selector.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "selector" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-selector.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/iron-selector", + "_release": "1.0.2", + "_resolution": { + "type": "version", + "tag": "v1.0.2", + "commit": "ea22d91d11ba6f72c01faa952d5e600f9d1773cf" + }, + "_source": "git://github.com/PolymerElements/iron-selector.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-selector" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-selector/.gitignore b/third_party/polymer/v1_0/components/iron-selector/.gitignore new file mode 100644 index 0000000..b13058c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/.gitignore @@ -0,0 +1,2 @@ +bower_components +.DS_Store diff --git a/third_party/polymer/v1_0/components/iron-selector/README.md b/third_party/polymer/v1_0/components/iron-selector/README.md new file mode 100644 index 0000000..8bb3d64 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/README.md @@ -0,0 +1,50 @@ +iron-selector +============= + +`iron-selector` is an element which can be used to manage a list of elements +that can be selected. Tapping on the item will make the item selected. The `selected` indicates +which item is being selected. The default is to use the index of the item. + +Example: + +```html +<iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> +</iron-selector> +``` + +If you want to use the attribute value of an element for `selected` instead of the index, +set `attrForSelected` to the name of the attribute. For example, if you want to select item by +`name`, set `attrForSelected` to `name`. + +Example: + +```html +<iron-selector attr-for-selected="name" selected="foo"> + <div name="foo">Foo</div> + <div name="bar">Bar</div> + <div name="zot">Zot</div> +</iron-selector> +``` + +`iron-selector` is not styled. Use the `iron-selected` CSS class to style the selected element. + +Example: + +```html +<style> + .iron-selected { + background: #eee; + } +</style> + +... + +<iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> +</iron-selector> +``` diff --git a/third_party/polymer/v1_0/components/iron-selector/bower.json b/third_party/polymer/v1_0/components/iron-selector/bower.json new file mode 100644 index 0000000..b9751df --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/bower.json @@ -0,0 +1,31 @@ +{ + "name": "iron-selector", + "version": "1.0.2", + "description": "Manages a set of elements that can be selected", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "main": [ + "iron-selector.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "selector" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-selector.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-selector/index.html b/third_party/polymer/v1_0/components/iron-selector/index.html new file mode 100644 index 0000000..741693c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<html> +<head> + + <title>iron-selector</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-selector/iron-multi-selectable.html b/third_party/polymer/v1_0/components/iron-selector/iron-multi-selectable.html new file mode 100644 index 0000000..ba9455d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/iron-multi-selectable.html @@ -0,0 +1,120 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-selectable.html"> + +<script> + /** @polymerBehavior Polymer.IronMultiSelectableBehavior */ + Polymer.IronMultiSelectableBehaviorImpl = { + properties: { + + /** + * If true, multiple selections are allowed. + */ + multi: { + type: Boolean, + value: false, + observer: 'multiChanged' + }, + + /** + * Gets or sets the selected elements. This is used instead of `selected` when `multi` + * is true. + */ + selectedValues: { + type: Array, + notify: true + }, + + /** + * Returns an array of currently selected items. + */ + selectedItems: { + type: Array, + readOnly: true, + notify: true + }, + + }, + + observers: [ + '_updateSelected(attrForSelected, selectedValues)' + ], + + /** + * Selects the given value. If the `multi` property is true, then the selected state of the + * `value` will be toggled; otherwise the `value` will be selected. + * + * @method select + * @param {string} value the value to select. + */ + select: function(value) { + if (this.multi) { + if (this.selectedValues) { + this._toggleSelected(value); + } else { + this.selectedValues = [value]; + } + } else { + this.selected = value; + } + }, + + multiChanged: function(multi) { + this._selection.multi = multi; + }, + + _updateSelected: function() { + if (this.multi) { + this._selectMulti(this.selectedValues); + } else { + this._selectSelected(this.selected); + } + }, + + _selectMulti: function(values) { + this._selection.clear(); + if (values) { + for (var i = 0; i < values.length; i++) { + this._selection.setItemSelected(this._valueToItem(values[i]), true); + } + } + }, + + _selectionChange: function() { + var s = this._selection.get(); + if (this.multi) { + this._setSelectedItems(s); + } else { + this._setSelectedItems([s]); + this._setSelectedItem(s); + } + }, + + _toggleSelected: function(value) { + var i = this.selectedValues.indexOf(value); + var unselected = i < 0; + if (unselected) { + this.selectedValues.push(value); + } else { + this.selectedValues.splice(i, 1); + } + this._selection.setItemSelected(this._valueToItem(value), unselected); + } + }; + + /** @polymerBehavior */ + Polymer.IronMultiSelectableBehavior = [ + Polymer.IronSelectableBehavior, + Polymer.IronMultiSelectableBehaviorImpl + ]; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-selector/iron-selectable.html b/third_party/polymer/v1_0/components/iron-selector/iron-selectable.html new file mode 100644 index 0000000..f0506d5 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/iron-selectable.html @@ -0,0 +1,307 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-selection.html"> + +<script> + + /** @polymerBehavior */ + Polymer.IronSelectableBehavior = { + + properties: { + + /** + * If you want to use the attribute value of an element for `selected` instead of the index, + * set this to the name of the attribute. + * + * @attribute attrForSelected + * @type {string} + */ + attrForSelected: { + type: String, + value: null + }, + + /** + * Gets or sets the selected element. The default is to use the index of the item. + * + * @attribute selected + * @type {string} + */ + selected: { + type: String, + notify: true + }, + + /** + * Returns the currently selected item. + * + * @attribute selectedItem + * @type {Object} + */ + selectedItem: { + type: Object, + readOnly: true, + notify: true + }, + + /** + * The event that fires from items when they are selected. Selectable + * will listen for this event from items and update the selection state. + * Set to empty string to listen to no events. + * + * @attribute activateEvent + * @type {string} + * @default 'tap' + */ + activateEvent: { + type: String, + value: 'tap', + observer: '_activateEventChanged' + }, + + /** + * This is a CSS selector sting. If this is set, only items that matches the CSS selector + * are selectable. + * + * @attribute selectable + * @type {string} + */ + selectable: String, + + /** + * The class to set on elements when selected. + * + * @attribute selectedClass + * @type {string} + */ + selectedClass: { + type: String, + value: 'iron-selected' + }, + + /** + * The attribute to set on elements when selected. + * + * @attribute selectedAttribute + * @type {string} + */ + selectedAttribute: { + type: String, + value: null + } + + }, + + observers: [ + '_updateSelected(attrForSelected, selected)' + ], + + excludedLocalNames: { + 'template': 1 + }, + + created: function() { + this._bindFilterItem = this._filterItem.bind(this); + this._selection = new Polymer.IronSelection(this._applySelection.bind(this)); + }, + + attached: function() { + this._observer = this._observeItems(this); + this._contentObserver = this._observeContent(this); + }, + + detached: function() { + if (this._observer) { + this._observer.disconnect(); + } + if (this._contentObserver) { + this._contentObserver.disconnect(); + } + this._removeListener(this.activateEvent); + }, + + /** + * Returns an array of selectable items. + * + * @property items + * @type Array + */ + get items() { + var nodes = Polymer.dom(this).queryDistributedElements(this.selectable || '*'); + return Array.prototype.filter.call(nodes, this._bindFilterItem); + }, + + /** + * Returns the index of the given item. + * + * @method indexOf + * @param {Object} item + * @returns Returns the index of the item + */ + indexOf: function(item) { + return this.items.indexOf(item); + }, + + /** + * Selects the given value. + * + * @method select + * @param {string} value the value to select. + */ + select: function(value) { + this.selected = value; + }, + + /** + * Selects the previous item. + * + * @method selectPrevious + */ + selectPrevious: function() { + var length = this.items.length; + var index = (Number(this._valueToIndex(this.selected)) - 1 + length) % length; + this.selected = this._indexToValue(index); + }, + + /** + * Selects the next item. + * + * @method selectNext + */ + selectNext: function() { + var index = (Number(this._valueToIndex(this.selected)) + 1) % this.items.length; + this.selected = this._indexToValue(index); + }, + + _addListener: function(eventName) { + this.listen(this, eventName, '_activateHandler'); + }, + + _removeListener: function(eventName) { + // There is no unlisten yet... + // https://github.com/Polymer/polymer/issues/1639 + //this.removeEventListener(eventName, this._bindActivateHandler); + }, + + _activateEventChanged: function(eventName, old) { + this._removeListener(old); + this._addListener(eventName); + }, + + _updateSelected: function() { + this._selectSelected(this.selected); + }, + + _selectSelected: function(selected) { + this._selection.select(this._valueToItem(this.selected)); + }, + + _filterItem: function(node) { + return !this.excludedLocalNames[node.localName]; + }, + + _valueToItem: function(value) { + return (value == null) ? null : this.items[this._valueToIndex(value)]; + }, + + _valueToIndex: function(value) { + if (this.attrForSelected) { + for (var i = 0, item; item = this.items[i]; i++) { + if (this._valueForItem(item) == value) { + return i; + } + } + } else { + return Number(value); + } + }, + + _indexToValue: function(index) { + if (this.attrForSelected) { + var item = this.items[index]; + if (item) { + return this._valueForItem(item); + } + } else { + return index; + } + }, + + _valueForItem: function(item) { + return item[this.attrForSelected] || item.getAttribute(this.attrForSelected); + }, + + _applySelection: function(item, isSelected) { + if (this.selectedClass) { + this.toggleClass(this.selectedClass, isSelected, item); + } + if (this.selectedAttribute) { + this.toggleAttribute(this.selectedAttribute, isSelected, item); + } + this._selectionChange(); + this.fire('iron-' + (isSelected ? 'select' : 'deselect'), {item: item}); + }, + + _selectionChange: function() { + this._setSelectedItem(this._selection.get()); + }, + + // observe content changes under the given node. + _observeContent: function(node) { + var content = node.querySelector('content'); + if (content && content.parentElement === node) { + return this._observeItems(node.domHost); + } + }, + + // observe items change under the given node. + _observeItems: function(node) { + var observer = new MutationObserver(function() { + if (this.selected != null) { + this._updateSelected(); + } + }.bind(this)); + observer.observe(node, { + childList: true, + subtree: true + }); + return observer; + }, + + _activateHandler: function(e) { + // TODO: remove this when https://github.com/Polymer/polymer/issues/1639 is fixed so we + // can just remove the old event listener. + if (e.type !== this.activateEvent) { + return; + } + var t = e.target; + var items = this.items; + while (t && t != this) { + var i = items.indexOf(t); + if (i >= 0) { + var value = this._indexToValue(i); + this._itemActivate(value, t); + return; + } + t = t.parentNode; + } + }, + + _itemActivate: function(value, item) { + if (!this.fire('iron-activate', + {selected: value, item: item}, {cancelable: true}).defaultPrevented) { + this.select(value); + } + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-selector/iron-selection.html b/third_party/polymer/v1_0/components/iron-selector/iron-selection.html new file mode 100644 index 0000000..0ff04cf --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/iron-selection.html @@ -0,0 +1,115 @@ + +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + + /** + * @param {!Function} selectCallback + * @constructor + */ + Polymer.IronSelection = function(selectCallback) { + this.selection = []; + this.selectCallback = selectCallback; + }; + + Polymer.IronSelection.prototype = { + + /** + * Retrieves the selected item(s). + * + * @method get + * @returns Returns the selected item(s). If the multi property is true, + * `get` will return an array, otherwise it will return + * the selected item or undefined if there is no selection. + */ + get: function() { + return this.multi ? this.selection : this.selection[0]; + }, + + /** + * Clears all the selection except the ones indicated. + * + * @method clear + * @param {Array} excludes items to be excluded. + */ + clear: function(excludes) { + this.selection.slice().forEach(function(item) { + if (!excludes || excludes.indexOf(item) < 0) { + this.setItemSelected(item, false); + } + }, this); + }, + + /** + * Indicates if a given item is selected. + * + * @method isSelected + * @param {*} item The item whose selection state should be checked. + * @returns Returns true if `item` is selected. + */ + isSelected: function(item) { + return this.selection.indexOf(item) >= 0; + }, + + /** + * Sets the selection state for a given item to either selected or deselected. + * + * @method setItemSelected + * @param {*} item The item to select. + * @param {boolean} isSelected True for selected, false for deselected. + */ + setItemSelected: function(item, isSelected) { + if (item != null) { + if (isSelected) { + this.selection.push(item); + } else { + var i = this.selection.indexOf(item); + if (i >= 0) { + this.selection.splice(i, 1); + } + } + if (this.selectCallback) { + this.selectCallback(item, isSelected); + } + } + }, + + /** + * Sets the selection state for a given item. If the `multi` property + * is true, then the selected state of `item` will be toggled; otherwise + * the `item` will be selected. + * + * @method select + * @param {*} item The item to select. + */ + select: function(item) { + if (this.multi) { + this.toggle(item); + } else if (this.get() !== item) { + this.setItemSelected(this.get(), false); + this.setItemSelected(item, true); + } + }, + + /** + * Toggles the selection state for `item`. + * + * @method toggle + * @param {*} item The item to toggle. + */ + toggle: function(item) { + this.setItemSelected(item, !this.isSelected(item)); + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-selector/iron-selector.html b/third_party/polymer/v1_0/components/iron-selector/iron-selector.html new file mode 100644 index 0000000..92abe04 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-selector/iron-selector.html @@ -0,0 +1,71 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="iron-multi-selectable.html"> + +<script> + /** + `iron-selector` is an element which can be used to manage a list of elements + that can be selected. Tapping on the item will make the item selected. The `selected` indicates + which item is being selected. The default is to use the index of the item. + + Example: + + <iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> + </iron-selector> + + If you want to use the attribute value of an element for `selected` instead of the index, + set `attrForSelected` to the name of the attribute. For example, if you want to select item by + `name`, set `attrForSelected` to `name`. + + Example: + + <iron-selector attr-for-selected="name" selected="foo"> + <div name="foo">Foo</div> + <div name="bar">Bar</div> + <div name="zot">Zot</div> + </iron-selector> + + `iron-selector` is not styled. Use the `iron-selected` CSS class to style the selected element. + + Example: + + <style> + .iron-selected { + background: #eee; + } + </style> + + ... + + <iron-selector selected="0"> + <div>Item 1</div> + <div>Item 2</div> + <div>Item 3</div> + </iron-selector> + + @demo demo/index.html + */ + + Polymer({ + + is: 'iron-selector', + + behaviors: [ + Polymer.IronMultiSelectableBehavior + ] + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/iron-signals/.bower.json b/third_party/polymer/v1_0/components/iron-signals/.bower.json new file mode 100644 index 0000000..36a1cb2 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-signals/.bower.json @@ -0,0 +1,29 @@ +{ + "name": "iron-signals", + "version": "1.0.1", + "description": "Basic publish-subscribe functionality", + "keywords": [ + "web-component", + "polymer", + "signals" + ], + "main": "iron-signals.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-signals/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "bd43f7706bfb9f8099bfcd017affa9378fb3fa4b" + }, + "_source": "git://github.com/PolymerElements/iron-signals.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-signals" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-signals/.gitignore b/third_party/polymer/v1_0/components/iron-signals/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-signals/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-signals/README.md b/third_party/polymer/v1_0/components/iron-signals/README.md new file mode 100644 index 0000000..fe82ffd --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-signals/README.md @@ -0,0 +1,26 @@ +iron-signals +============ + +`iron-signals` provides basic publish-subscribe functionality. + +Note: avoid using `iron-signals` whenever you can use +a controller (parent element) to mediate communication +instead. + +To send a signal, fire a custom event of type `iron-signal`, with +a detail object containing `name` and `data` fields. + +```javascript +this.fire('iron-signal', {name: 'hello', data: null}); +``` + +To receive a signal, listen for `iron-signal-<name>` event on a +`iron-signals` element. + +```html +<iron-signals on-iron-signal-hello="{{helloSignal}}"> +``` + +You can fire a signal event from anywhere, and all +`iron-signals` elements will receive the event, regardless +of where they are in DOM. diff --git a/third_party/polymer/v1_0/components/iron-signals/bower.json b/third_party/polymer/v1_0/components/iron-signals/bower.json new file mode 100644 index 0000000..73a984c --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-signals/bower.json @@ -0,0 +1,20 @@ +{ + "name": "iron-signals", + "version": "1.0.1", + "description": "Basic publish-subscribe functionality", + "keywords": [ + "web-component", + "polymer", + "signals" + ], + "main": "iron-signals.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-signals/", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-signals/index.html b/third_party/polymer/v1_0/components/iron-signals/index.html new file mode 100644 index 0000000..246af10 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-signals/index.html @@ -0,0 +1,23 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-signals/iron-signals.html b/third_party/polymer/v1_0/components/iron-signals/iron-signals.html new file mode 100644 index 0000000..dcf2e59 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-signals/iron-signals.html @@ -0,0 +1,81 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<script> +(function(){ +/** +`iron-signals` provides basic publish-subscribe functionality. + +Note: avoid using `iron-signals` whenever you can use +a controller (parent element) to mediate communication +instead. + +To send a signal, fire a custom event of type `iron-signal`, with +a detail object containing `name` and `data` fields. + + this.fire('iron-signal', {name: 'hello', data: null}); + +To receive a signal, listen for `iron-signal-<name>` event on a +`iron-signals` element. + + <iron-signals on-iron-signal-hello="{{helloSignal}}"> + +You can fire a signal event from anywhere, and all +`iron-signals` elements will receive the event, regardless +of where they are in DOM. + +@demo demo/index.html +*/ + Polymer({ + is: 'iron-signals', + + attached: function() { + signals.push(this); + }, + detached: function() { + var i = signals.indexOf(this); + if (i >= 0) { + signals.splice(i, 1); + } + } + }); + + // private shared database + var signals = []; + + // signal dispatcher + function notify(name, data) { + // convert generic-signal event to named-signal event + var signal = new CustomEvent('iron-signal-' + name, { + // if signals bubble, it's easy to get confusing duplicates + // (1) listen on a container on behalf of local child + // (2) some deep child ignores the event and it bubbles + // up to said container + // (3) local child event bubbles up to container + // also, for performance, we avoid signals flying up the + // tree from all over the place + bubbles: false, + detail: data + }); + // dispatch named-signal to all 'signals' instances, + // only interested listeners will react + signals.forEach(function(s) { + s.dispatchEvent(signal); + }); + } + + // signal listener at document + document.addEventListener('iron-signal', function(e) { + notify(e.detail.name, e.detail.data); + }); + +})(); +</script> diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/.bower.json b/third_party/polymer/v1_0/components/iron-test-helpers/.bower.json new file mode 100644 index 0000000..0f3971ac --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "iron-test-helpers", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "description": "Utility classes to help make testing easier", + "keywords": [ + "web-components", + "web-component", + "polymer", + "test" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-test-helpers" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-test-helpers", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "4c5d28f58adda0d076850321582cfe86359f95fb" + }, + "_source": "git://github.com/PolymerElements/iron-test-helpers.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-test-helpers" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/.gitignore b/third_party/polymer/v1_0/components/iron-test-helpers/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/README.md b/third_party/polymer/v1_0/components/iron-test-helpers/README.md new file mode 100644 index 0000000..dbc5318 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/README.md @@ -0,0 +1,23 @@ +# iron-test-helpers + +Utility classes to make testing easier. + +## Mock Interactions + +This is a set of methods to simulate mouse or keyboard interaction with an element. Include `mock-interactions.js` and then use them like so: + +```javascript +test('can be triggered with space', function(done) { + button.addEventListener('keydown', function() { + done(); + }); + MockInteractions.pressSpace(button); +}); + +test('can be clicked', function(done) { + button.addEventListener('click', function() { + done(); + }); + MockInteractions.down(button); +}); +``` diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/bower.json b/third_party/polymer/v1_0/components/iron-test-helpers/bower.json new file mode 100644 index 0000000..4b3f5f3 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/bower.json @@ -0,0 +1,28 @@ +{ + "name": "iron-test-helpers", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "description": "Utility classes to help make testing easier", + "keywords": [ + "web-components", + "web-component", + "polymer", + "test" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-test-helpers" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-test-helpers", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/iron-test-helpers.html b/third_party/polymer/v1_0/components/iron-test-helpers/iron-test-helpers.html new file mode 100644 index 0000000..b68589d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/iron-test-helpers.html @@ -0,0 +1,22 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<script src="mock-interactions.js"></script> +<script src="test-helpers.js"></script> +<script> + (function(global) { + 'use strict'; + + var TestHelpers = global.TestHelpers = global.TestHelpers || {}; + + TestHelpers.flushAsynchronousOperations = flushAsynchronousOperations; + TestHelpers.forceXIfStamp = forceXIfStamp; + TestHelpers.fireEvent = fireEvent; + })(this); +</script> diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/mock-interactions.js b/third_party/polymer/v1_0/components/iron-test-helpers/mock-interactions.js new file mode 100644 index 0000000..887b9be --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/mock-interactions.js @@ -0,0 +1,177 @@ +/** + * @license + * Copyright (c) 2014 The Polymer Project Authors. All rights reserved. + * This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + * The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + * The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + * Code distributed by Google as part of the polymer project is also + * subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + */ + +(function(global) { + 'use strict'; + + var HAS_NEW_MOUSE = (function() { + var has = false; + try { + has = Boolean(new MouseEvent('x')); + } catch (_) {} + return has; + })(); + + function middleOfNode(node) { + var bcr = node.getBoundingClientRect(); + return { + y: bcr.top + (bcr.height / 2), + x: bcr.left + (bcr.width / 2) + }; + } + + function topLeftOfNode(node) { + var bcr = node.getBoundingClientRect(); + return { + y: bcr.top, + x: bcr.left + }; + } + + function makeEvent(type, xy, node) { + var props = { + bubbles: true, + cancelable: true, + clientX: xy.x, + clientY: xy.y + }; + var e; + var mousetype = type === 'tap' ? 'click' : 'mouse' + type; + if (HAS_NEW_MOUSE) { + e = new MouseEvent(mousetype, props); + } else { + e = document.createEvent('MouseEvent'); + e.initMouseEvent(mousetype, props.bubbles, props.cancelable, null, null, 0, 0, + props.clientX, props.clientY, false, false, false, false, 0, null); + } + node.dispatchEvent(e); + } + + function down(node, xy) { + xy = xy || middleOfNode(node); + makeEvent('down', xy, node); + } + + function move(node, fromXY, toXY, steps) { + steps = steps || 5; + var dx = Math.round((fromXY.x - toXY.x) / steps); + var dy = Math.round((fromXY.y - toXY.y) / steps); + var xy = { + x: fromXY.x, + y: fromXY.y + }; + for (var i = steps; i > 0; i--) { + makeEvent('move', xy, node); + xy.x += dx; + xy.y += dy; + } + makeEvent('move', { + x: toXY.x, + y: toXY.y + }, node); + } + + function up(node, xy) { + xy = xy || middleOfNode(node); + makeEvent('up', xy, node); + } + + function tap(node) { + var xy = middleOfNode(node); + down(node, xy); + up(node, xy); + makeEvent('tap', xy, node); + } + + function focus(target) { + Polymer.Base.fire.call(target, 'focus'); + } + + function blur(target) { + Polymer.Base.fire.call(target, 'blur'); + } + + function downAndUp(target, callback) { + down(target); + Polymer.Base.async(function() { + up(target); + tap(target); + + callback && callback(); + }); + } + + function track(target, dx, dy, steps) { + dx = dx | 0; + dy = dy | 0; + steps = steps || 5; + down(target); + var xy = middleOfNode(target); + var xy2 = { + x: xy.x + dx, + y: xy.y + dy + }; + move(target, xy, xy2, steps); + up(target, xy2); + } + + function keyboardEventFor(type, keyCode) { + var event = new CustomEvent(type); + + event.keyCode = keyCode; + event.code = keyCode; + + return event; + } + + function keyEventOn(target, type, keyCode) { + target.dispatchEvent(keyboardEventFor(type, keyCode)); + } + + function keyDownOn(target, keyCode) { + keyEventOn(target, 'keydown', keyCode); + } + + function keyUpOn(target, keyCode) { + keyEventOn(target, 'keyup', keyCode); + } + + function pressAndReleaseKeyOn(target, keyCode) { + keyDownOn(target, keyCode); + Polymer.Base.async(function() { + keyUpOn(target, keyCode); + }, 1); + } + + function pressEnter(target) { + pressAndReleaseKeyOn(target, 13); + } + + function pressSpace(target) { + pressAndReleaseKeyOn(target, 32); + } + + global.MockInteractions = { + focus: focus, + blur: blur, + down: down, + up: up, + downAndUp: downAndUp, + tap: tap, + track: track, + pressAndReleaseKeyOn: pressAndReleaseKeyOn, + pressEnter: pressEnter, + pressSpace: pressSpace, + keyDownOn: keyDownOn, + keyUpOn: keyUpOn, + middleOfNode: middleOfNode, + topLeftOfNode: topLeftOfNode + }; +})(this); diff --git a/third_party/polymer/v1_0/components/iron-test-helpers/test-helpers.js b/third_party/polymer/v1_0/components/iron-test-helpers/test-helpers.js new file mode 100644 index 0000000..3465186 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-test-helpers/test-helpers.js @@ -0,0 +1,39 @@ +/** + * @license + * Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + * This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + * The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + * The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + * Code distributed by Google as part of the polymer project is also + * subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + */ +(function(global) { + + global.flushAsynchronousOperations = function() { + // force distribution + Polymer.dom.flush(); + // force lifecycle callback to fire on polyfill + window.CustomElements && window.CustomElements.takeRecords(); + }; + + global.forceXIfStamp = function(node) { + var templates = Polymer.dom(node.root).querySelectorAll('template[is=dom-if]'); + for (var tmpl, i = 0; tmpl = templates[i]; i++) { + tmpl.render(); + } + + global.flushAsynchronousOperations(); + }; + + global.fireEvent = function(type, props, node) { + var event = new CustomEvent(type, { + bubbles: true, + cancelable: true + }); + for (p in props) { + event[p] = props[p]; + } + node.dispatchEvent(event); + }; + +})(this); diff --git a/third_party/polymer/v1_0/components/iron-validatable-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-validatable-behavior/.bower.json new file mode 100644 index 0000000..e274324 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validatable-behavior/.bower.json @@ -0,0 +1,43 @@ +{ + "name": "iron-validatable-behavior", + "version": "1.0.1", + "description": "Provides a behavior for an element that validates user input", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validatable-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validatable-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validatable-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "63513294174960e48dfb4617f55e716de3c9fc49" + }, + "_source": "git://github.com/PolymerElements/iron-validatable-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-validatable-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-validatable-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-validatable-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validatable-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-validatable-behavior/README.md b/third_party/polymer/v1_0/components/iron-validatable-behavior/README.md new file mode 100644 index 0000000..48f7fb2 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validatable-behavior/README.md @@ -0,0 +1,3 @@ +# iron-validatable-behavior +Implements an element validated with Polymer.IronValidatorBehavior + diff --git a/third_party/polymer/v1_0/components/iron-validatable-behavior/bower.json b/third_party/polymer/v1_0/components/iron-validatable-behavior/bower.json new file mode 100644 index 0000000..3b66313 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validatable-behavior/bower.json @@ -0,0 +1,34 @@ +{ + "name": "iron-validatable-behavior", + "version": "1.0.1", + "description": "Provides a behavior for an element that validates user input", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validatable-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validatable-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validatable-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-validatable-behavior/index.html b/third_party/polymer/v1_0/components/iron-validatable-behavior/index.html new file mode 100644 index 0000000..cfaa5b1 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validatable-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-validatable-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-validatable-behavior/iron-validatable-behavior.html b/third_party/polymer/v1_0/components/iron-validatable-behavior/iron-validatable-behavior.html new file mode 100644 index 0000000..d792b0d --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validatable-behavior/iron-validatable-behavior.html @@ -0,0 +1,100 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +<script> + + /** + * Use `Polymer.IronValidatableBehavior` to implement an element that validates user input. + * + * ### Accessiblity + * + * Changing the `invalid` property, either manually or by calling `validate()` will update the + * `aria-invalid` attribute. + * + * @demo demo/index.html + * @polymerBehavior + */ + Polymer.IronValidatableBehavior = { + + properties: { + + /** + * Namespace for this validator. + */ + validatorType: { + type: String, + value: 'validator' + }, + + /** + * Name of the validator to use. + */ + validator: { + type: String + }, + + /** + * True if the last call to `validate` is invalid. + */ + invalid: { + reflectToAttribute: true, + type: Boolean, + value: false + }, + + _validatorMeta: { + type: Object + } + + }, + + observers: [ + '_invalidChanged(invalid)' + ], + + get _validator() { + return this._validatorMeta && this._validatorMeta.byKey(this.validator); + }, + + ready: function() { + this._validatorMeta = new Polymer.IronMeta({type: this.validatorType}); + }, + + _invalidChanged: function() { + if (this.invalid) { + this.setAttribute('aria-invalid', 'true'); + } else { + this.removeAttribute('aria-invalid'); + } + }, + + /** + * @return {Boolean} True if the validator `validator` exists. + */ + hasValidator: function() { + return this._validator != null; + }, + + /** + * @param {Object} values Passed to the validator's `validate()` function. + * @return {Boolean} True if `values` is valid. + */ + validate: function(values) { + var valid = this._validator && this._validator.validate(values); + this.invalid = !valid; + return valid; + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/iron-validator-behavior/.bower.json b/third_party/polymer/v1_0/components/iron-validator-behavior/.bower.json new file mode 100644 index 0000000..257b945 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validator-behavior/.bower.json @@ -0,0 +1,43 @@ +{ + "name": "iron-validator-behavior", + "version": "1.0.1", + "description": "Implements a input validator", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validator-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validator-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validator-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "fd9c609472c0c0b64657488d1d33dfc2365dea44" + }, + "_source": "git://github.com/PolymerElements/iron-validator-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/iron-validator-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/iron-validator-behavior/.gitignore b/third_party/polymer/v1_0/components/iron-validator-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validator-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/iron-validator-behavior/README.md b/third_party/polymer/v1_0/components/iron-validator-behavior/README.md new file mode 100644 index 0000000..8aa8b61 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validator-behavior/README.md @@ -0,0 +1,4 @@ +# iron-validator-behavior +Use `Polymer.IronValidatorBehavior` to implement a custom input/form validator. Element instances +implementing this behavior will be registered for use in elements that implement +`Polymer.IronValidatableBehavior`. diff --git a/third_party/polymer/v1_0/components/iron-validator-behavior/bower.json b/third_party/polymer/v1_0/components/iron-validator-behavior/bower.json new file mode 100644 index 0000000..7d57d72 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validator-behavior/bower.json @@ -0,0 +1,34 @@ +{ + "name": "iron-validator-behavior", + "version": "1.0.1", + "description": "Implements a input validator", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "iron", + "behavior" + ], + "main": [ + "iron-validator-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/iron-validator-behavior.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/iron-validator-behavior", + "ignore": [], + "dependencies": { + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/iron-validator-behavior/index.html b/third_party/polymer/v1_0/components/iron-validator-behavior/index.html new file mode 100644 index 0000000..d0f6936 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validator-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>iron-validator-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/iron-validator-behavior/iron-validator-behavior.html b/third_party/polymer/v1_0/components/iron-validator-behavior/iron-validator-behavior.html new file mode 100644 index 0000000..d8afc84 --- /dev/null +++ b/third_party/polymer/v1_0/components/iron-validator-behavior/iron-validator-behavior.html @@ -0,0 +1,61 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +<script> + + /** + * Use `Polymer.IronValidatorBehavior` to implement a custom input/form validator. Element + * instances implementing this behavior will be registered for use in elements that implement + * `Polymer.IronValidatableBehavior`. + * + * @demo demo/index.html + * @polymerBehavior + */ + Polymer.IronValidatorBehavior = { + + properties: { + + /** + * Namespace for this validator. + */ + validatorType: { + type: String, + value: 'validator' + }, + + /** + * Name for this validator, used by `Polymer.IronValidatableBehavior` to lookup this element. + */ + validatorName: { + type: String, + value: function() { + return this.is; + } + } + + }, + + ready: function() { + new Polymer.IronMeta({type: this.validatorType, key: this.validatorName, value: this}); + }, + + /** + * Implement custom validation logic in this function. + * @param {Object} values The value to validate. May be any type depending on the validation logic. + * @return {Boolean} true if `values` is valid. + */ + validate: function(values) { + } + }; + +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/.bower.json b/third_party/polymer/v1_0/components/more-routing/.bower.json new file mode 100644 index 0000000..1c6276c --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/.bower.json @@ -0,0 +1,42 @@ +{ + "name": "more-routing", + "version": "1.0.0", + "authors": [ + "The Polymer Authors" + ], + "description": "A composable suite of objects and elements to make routing with web components a breeze.", + "keywords": [ + "web-component", + "web-components", + "polymer", + "routing", + "router" + ], + "main": "more-routing.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerLabs/more-routing/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "b9dcc768f789547bb99f65cd976006cb578af255" + }, + "_source": "git://github.com/PolymerLabs/more-routing.git", + "_target": "^1.0.0", + "_originalSource": "PolymerLabs/more-routing" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/more-routing/README.md b/third_party/polymer/v1_0/components/more-routing/README.md new file mode 100644 index 0000000..880ccfe --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/README.md @@ -0,0 +1,338 @@ +Routing +======= + +A composable suite of objects and elements to make routing with web components +a breeze. + +* [Hash-](#MoreRouting.HashDriver) and [path-](#MoreRouting.PathDriver)based + routing. +* [Named routes](#more-routing). +* [Nested (mounted) routes](#more-route--nesting). +* [Declarative route switching](#more-route-switch). +* [Polymer helpers](#polymer-helpers--filters) for easy integration into existing elements. + +[Rob Dodson](https://github.com/robdodson) has whipped up a great video +that can get you started with more-routing: + +<p align="center"> + <a href="https://www.youtube.com/watch?v=-67kb7poIT8"> + <img src="http://img.youtube.com/vi/-67kb7poIT8/0.jpg" alt="Moar routing with... more-routing"> + </a> +</p> + +Or, TL;DR: + +```html +<link rel="import" href="../more-routing/more-routing.html"> + +<more-routing-config driver="path"></more-routing-config> +<more-route name="user" path="/users/:userId"> + <more-route name="user-bio" path="/bio"></more-route> +</more-route> + +<more-route-selector selectedParams="{{params}}"> + <core-pages> + <section route="/"> + This is the index. + </section> + + <section route="/about"> + It's a routing demo! + <a href="{{ urlFor('user-bio', {userId: 1}) }}">Read about user 1</a>. + </section> + + <section route="user"> + <header>Heyo user {{params.userId}}!</header> + <template if="{{ route('user-bio').active }}"> + All the details about {{params.userId}} that you didn't want to know... + </template> + </section> + </core-pages> +</more-route-selector> +``` + +And finally, check out [the demo](demo/) for a project that makes comprehensive +use of the various features in more-routing. + + +Element API +=========== + +<a name="more-routing-config"></a> +`<more-routing-config>` +---------------- + +_Defined in [`more-routing-config.html`](more-routing-config.html)._ + +The declarative interface for configuring [`MoreRouting`](#MoreRouting). +Currently, this lets you declare which [driver](#MoreRouting.Driver) you wish +to use (`hash` or `path`): + +```html +<more-routing-config driver="hash"></more-routing-config> +``` + +You should place this as early in the load process for your app as you can. Any +routes defined prior to the driver being set will trigger an error. + + +<a name="more-route"></a> +`<more-route>` +-------------- + +_Defined in [`more-route.html`](more-route.html)._ + +Reference routes by path, and extract their params: + +```html +<more-route path="/users/:userId" params="{{user}}"></more-route> +``` + +Declare a named route: + +```html +<more-route path="/users/:userId" name="user"></more-route> +``` + +Reference a named route: + +```html +<more-route name="user" params="{{user}}"></more-route> +``` + + +<a name="more-route--nesting"></a> +### Route Nesting + +Routes can also be nested: + +```html +<more-route path="/users/:userId" name="user"> + <more-route path="/bio" name="user-bio"></more-route> +</more-route> +``` + +In this example, the route named `user-bio` will match `/users/:userId/bio`. + +Finally, `<more-route>` elements can declare a routing context for the element +that contains them by setting the `context` attribute. See the +[routed elements](#more-route-selector--routed-elements) section for more info. + + +<a name="more-route-selector"></a> +`<more-route-selector>` +----------------------- + +_Defined in [`more-route-selector.html`](more-route-selector.html)._ + +Manages a [`<core-selector>`](https://www.polymer-project.org/docs/elements/core-elements.html#core-selector) +(or anything that extends it/looks like one), where each item in the selector +have an associated route. The most specific route that is active will be +selected. + +```html +<more-route-selector> + <core-pages> + <section route="/">The index!</section> + <section route="user">A user (named route)</section> + <section route="/about">Another route</section> + </core-pages> +</more-route-selector> +``` + +By default, `more-route-selector` will look for the `route` attribute on any +children of the `core-selector` (change this via `routeAttribute`). + +It exposes information about the selected route via a few properties: + +`selectedParams`: The params of the selected route. + +`selectedRoute`: The [`MoreRouting.Route`](#MoreRouting.Route) representing the +selected route. + +`selectedPath`: The path expression of the selected route. + +`selectedIndex`: The index of the selected route (relative to `routes`). + + +<a name="more-route-selector--routed-elements"></a> +### Routed Elements + +Elements can declare a route to be associated with, which allows +`<more-route-selector>` to be smart and use that as the route it checks against +for your element. For example: + +```html +<polymer-element name="routed-element"> + <template> + <more-route path="/my/route" context></more-route> + I'm a routed element! + </template> +</polymer-element> +``` + +```html +<more-route-selector> + <core-pages> + <section route="/">The index!</section> + <routed-element></routed-element> + </core-pages> +</more-route-selector> +``` + +In this example, The `<more-route-selector>` will choose `<routed-element>` +whenever the path begins with `/my/route`. Keep it DRY! + + +<a name="more-route-selector--nesting-contexts"></a> +### Nesting Contexts + +Similar to [`more-route`'s nesting behavior](#more-route--nesting), any items in +the core-selector also behave as nesting contexts. Any route declared within a +routing context is effectively _mounted_ on the context route. + +Taking the example element, `<routed-element>` above; if we were to add the +following to its template: + +```html +<more-route path="/:tab" params="{{params}}"></more-route> +``` + +That route's full path would be `/my/route/:tab`, because `/my/route` is the +context in which it is nested. This allows you to create custom elements that +make use of routes, _while not requiring knowledge of the app's route +hierarchy_. Very handy for composable components! + +**Note:** All items in a `<more-route-selector>` are treated as routing +contexts! + + +<a name="polymer-helpers"></a> +Polymer Helpers +--------------- + +<a name="polymer-helpers--filters"></a> +### Filters + +_Defined in [`polymer-expressions.html`](polymer-expressions.html)._ + +Several filters (functions) are exposed to templates for your convenience: + +#### `route` + +You can fetch a `MoreRouting.Route` object via the `route` filter. Handy for +reading params, etc on the fly. + +```html +<x-user model="{{ route('user').params }}"></x-user> +``` + +**Note:** The `route()` helper is unfortunately _not_ aware of the current +routing context. Consider using only named routes to avoid confusion! + +#### `urlFor` + +Generates a URL for the specified route and params: + +```html +<a href="{{ urlFor('user', {userId: 1}) }}">User 1</a> +``` + + +JavaScript API +============== + +<a name="MoreRouting"></a> +`MoreRouting` +------------- + +_Defined in [`routing.html`](routing.html)._ + +The main entry point into `more-routing`, exposed as a global JavaScript +namespace of `MoreRouting`. For the most part, all elements and helpers are +built on top of it. + +`MoreRouting` manages the current [driver](#MoreRouting.Driver), and maintains +an identity map of all routes. + + +<a name="MoreRouting.driver"></a> +### `MoreRouting.driver` + +Before you can make use of navigation and URL parsing, a driver must be +registered. Simply assign an instance of `MoreRouting.Driver` to this property. + +This is exposed as a declarative element via +[`<more-routing-config driver="...">`](#more-routing). + + +<a name="MoreRouting.getRoute"></a> +### `MoreRouting.getRoute` + +Returns a [`MoreRouting.Route`](#MoreRouting.Route), by path... + + MoreRouting.getRoute('/users/:userId') + +...or by name: + + MoreRouting.getRoute('user') + +Because routes are identity mapped, `getRoute` guarantees that it will return +the same `Route` object for the same path. + + +<a name="MoreRouting.Route"></a> +`MoreRouting.Route` +------------------- + +_Defined in [`route.html`](route.html)._ + +The embodiment for an individual route. It has various handy properties. +Highlights: + +``active``: Whether the route is active (the current URL matches). + +``params``: A map of param keys to their values (matching the `:named` tokens) +within the path. + +``path``: The path expression that this route matches. + +### Paths + +Path expressions begin with a `/` (to disambiguate them from route names), and +are a series of tokens separated by `/`. + +Tokens can be of the form `:named`, where they named a parameter. Or they can +be regular strings, at which point they are static path parts. + +Should be familiar from many other routing systems. + + +<a href="MoreRouting.Driver"></a> +`MoreRouting.Driver` +-------------------- + +_Defined in [`driver.html`](driver.html)._ + +Drivers manage how the URL is read, and how to navigate to URLs. There are two +built in drivers: + + +<a href="MoreRouting.HashDriver"></a> +### `MoreRouting.HashDriver` + +_Defined in [`hash-driver.html`](hash-driver.html)._ + +Provides hash-based routing, generating URLs like `#!/users/1/bio`. It has a +configurable prefix (after the `#`). By default, it uses a prefix of `!/` +(to fit the [AJAX-crawling spec](https://developers.google.com/webmasters/ajax-crawling/docs/specification)). + + +<a href="MoreRouting.PathDriver"></a> +### `MoreRouting.PathDriver` + +_Defined in [`path-driver.html`](path-driver.html)._ + +Provides true path-based routing (via `pushState`), generating URLs like +`/users/1/bio`. If your web app is mounted on a path other than `/`, you can +specify that mount point via the `prefix`. diff --git a/third_party/polymer/v1_0/components/more-routing/bower.json b/third_party/polymer/v1_0/components/more-routing/bower.json new file mode 100644 index 0000000..e225285 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/bower.json @@ -0,0 +1,33 @@ +{ + "name": "more-routing", + "version": "1.0.0", + "authors": [ + "The Polymer Authors" + ], + "description": "A composable suite of objects and elements to make routing with web components a breeze.", + "keywords": [ + "web-component", + "web-components", + "polymer", + "routing", + "router" + ], + "main": "more-routing.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerLabs/more-routing/", + "ignore": [ + "/.*", + "/test/", + "/demo/" + ], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-doc-viewer": "PolymerElements/iron-doc-viewer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/more-routing/driver.html b/third_party/polymer/v1_0/components/more-routing/driver.html new file mode 100644 index 0000000..031c87d --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/driver.html @@ -0,0 +1,113 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Driver = Driver; + +/** + * TODO(nevir): Docs. + */ +function Driver(opt_config) { + var config = opt_config || {}; + if (config.prefix) this.prefix = config.prefix; + + this._activeRoutes = []; + + this._rootRoutes = []; +} + +Driver.prototype.manageRoute = function manageRoute(route) { + route.driver = this; + this._appendRoute(route); + + if (route.parent) { + if (route.parent.active) { + // Remember: `processPathParts` takes just the path parts relative to that + // route; not the full set. + route.processPathParts(this.currentPathParts.slice(route.parent.depth)); + } + } else { + route.processPathParts(this.currentPathParts); + } + + if (route.active) this._activeRoutes.push(route); +}; + +Driver.prototype.urlForParts = function urlForParts(parts) { + return this.prefix + parts.join(this.separator); +}; + +Driver.prototype.navigateToParts = function(parts) { + return this.navigateToUrl(this.urlForParts(parts)); +}; + +Driver.prototype.navigateToUrl = function navigateToUrl(url) { + throw new Error(this.constructor.name + '#navigateToUrl not implemented'); +}; + +// Subclass Interface + +Driver.prototype.prefix = '/'; +Driver.prototype.separator = '/'; + +Driver.prototype.setCurrentPath = function setCurrentPath(path) { + this.currentPathParts = this.splitPath(path); + var newRoutes = this._matchingRoutes(this.currentPathParts); + + // active -> inactive. + for (var i = 0, route; route = this._activeRoutes[i]; i++) { + if (newRoutes.indexOf(route) === -1) { + route.processPathParts(null); + } + } + + this._activeRoutes = newRoutes; +} + +Driver.prototype.splitPath = function splitPath(rawPath) { + if (this.prefix && rawPath.indexOf(this.prefix) !== 0) { + throw new Error( + 'Invalid path "' + rawPath + '"; ' + + 'expected it to be prefixed by "' + this.prefix + '"'); + } + var path = rawPath.substr(this.prefix.length); + var parts = path.split(this.separator); + // Ignore trailing separators. + if (!parts[parts.length - 1]) parts.pop(); + + return parts; +}; + +// Internal Implementation +Driver.prototype._appendRoute = function _appendRoute(route) { + if (route.parent) { + // We only care about root routes. + return; + } + this._rootRoutes.push(route); +}; + +Driver.prototype._matchingRoutes = function _matchingRoutes(parts, rootRoutes) { + var routes = []; + var candidates = rootRoutes || this._rootRoutes; + var route; + for (var i = 0; i < candidates.length; i++) { + route = candidates[i]; + route.processPathParts(parts); + if (route.active) { + routes.push(route); + routes = routes.concat(this._matchingRoutes(parts.slice(route.compiled.length), route.children)); + } + } + return routes; +} + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/driver/hash.html b/third_party/polymer/v1_0/components/more-routing/driver/hash.html new file mode 100644 index 0000000..e20ded1 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/driver/hash.html @@ -0,0 +1,46 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../driver.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.HashDriver = HashDriver; + +/** + * TODO(nevir): Docs. + */ +function HashDriver() { + MoreRouting.Driver.apply(this, arguments); + this._bindEvents(); + this._read(); +} +HashDriver.prototype = Object.create(MoreRouting.Driver.prototype); + +// By default, we prefer hashbang; but you can prefix with any string you wish. +HashDriver.prototype.prefix = '!/'; + +HashDriver.prototype.urlForParts = function urlForParts(parts) { + return '#' + MoreRouting.Driver.prototype.urlForParts.call(this, parts); +}; + +HashDriver.prototype.navigateToUrl = function navigateToUrl(url) { + window.location.hash = url; +}; + +HashDriver.prototype._bindEvents = function _bindEvents() { + window.addEventListener('hashchange', this._read.bind(this)); +}; + +HashDriver.prototype._read = function _read() { + this.setCurrentPath(window.location.hash.substr(1) || this.prefix); +}; + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/driver/mock.html b/third_party/polymer/v1_0/components/more-routing/driver/mock.html new file mode 100644 index 0000000..714f43b --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/driver/mock.html @@ -0,0 +1,27 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../driver.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.MockDriver = MockDriver; + +/** A mock driver for use in your tests. */ +function MockDriver() { + MoreRouting.Driver.apply(this, arguments); +} +MockDriver.prototype = Object.create(MoreRouting.Driver.prototype); + +MockDriver.prototype.navigateToUrl = function navigateToUrl(url) { + this.setCurrentPath(url); +}; + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/driver/path.html b/third_party/polymer/v1_0/components/more-routing/driver/path.html new file mode 100644 index 0000000..9cbb5ea --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/driver/path.html @@ -0,0 +1,40 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../driver.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.PathDriver = PathDriver; + +/** + * TODO(nevir): Docs. + */ +function PathDriver() { + MoreRouting.Driver.apply(this, arguments); + this._bindEvents(); + this._read(); +} +PathDriver.prototype = Object.create(MoreRouting.Driver.prototype); + +PathDriver.prototype.navigateToUrl = function navigateToUrl(url) { + window.history.pushState({}, '', url); + this._read(); +}; + +PathDriver.prototype._bindEvents = function _bindEvents() { + window.addEventListener('popstate', this._read.bind(this)); +}; + +PathDriver.prototype._read = function _read() { + this.setCurrentPath(window.location.pathname); +}; + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/emitter.html b/third_party/polymer/v1_0/components/more-routing/emitter.html new file mode 100644 index 0000000..5c2aa0e --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/emitter.html @@ -0,0 +1,77 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Emitter = Object.create(null); // Minimal set of properties. + +/** + * A dumb prototype that provides very simple event subscription. + * + * You are responsible for initializing `__listeners` as an array on objects + * that make use of this. + */ +Object.defineProperties(MoreRouting.Emitter, { + + /** + * Registers a callback that will be called each time any parameter managed by + * this object (or its parents) have changed. + * + * @param {!Function} callback + * @return {{close: function()}} + */ + __subscribe: { + value: function __subscribe(callback) { + this.__listeners.push(callback); + + return { + close: this.__unsubscribe.bind(this, callback), + }; + }, + }, + + /** + * Unsubscribes a previously registered callback. + * + * @param {!Function} callback + */ + __unsubscribe: { + value: function __unsubscribe(callback) { + var index = this.__listeners.indexOf(callback); + if (index < 0) { + console.warn(this, 'attempted unsubscribe of unregistered listener:', callback); + return; + } + this.__listeners.splice(index, 1); + }, + }, + + /** + * Notifies subscribed callbacks. + */ + __notify: { + value: function __notify(key, value) { + if (this.__silent) return; + var args = Array.prototype.slice.call(arguments); + // Notify listeners on parents first. + var parent = Object.getPrototypeOf(this); + if (parent && parent.__notify && parent.__listeners) { + parent.__notify.apply(parent, args); + } + + this.__listeners.forEach(function(listener) { + listener.apply(null, args); + }.bind(this)); + }, + }, + +}); + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/index.html b/third_party/polymer/v1_0/components/more-routing/index.html new file mode 100644 index 0000000..67f8282 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-doc-viewer/iron-doc-viewer.html"> + +</head> +<body> + + <iron-doc-viewer></iron-doc-viewer> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/more-routing/more-route-context-aware.html b/third_party/polymer/v1_0/components/more-routing/more-route-context-aware.html new file mode 100644 index 0000000..0da57c2 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-route-context-aware.html @@ -0,0 +1,66 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="route.html"> +<link rel="import" href="routing.html"> + +<script> + + MoreRouting.ContextAware = { + + /** @override */ + ready: function() { + this._makeRoutingReady(); + }, + + /** + * Calls `routingReady`, and ensures that it is called in a top-down manner. + * + * We need to be sure that parent nodes have `routingReady` triggered before + * their children so that they can properly configure nested routes. + * + * Unfortunately, `ready` is sometimes bottom-up, sometimes top-down. + * Ideally, this wouldn't be necessary. + * + * @see https://github.com/Polymer/polymer/pull/1448 + */ + _makeRoutingReady: function() { + if (this.routingIsReady) return; + + var node = this; + while (node = Polymer.dom(node).parentNode) { + if (typeof node._makeRoutingReady === 'function') break; + } + if (node) node._makeRoutingReady(); + + this.parentRoute = this._findParentRoute(); + this.routingIsReady = true; + if (typeof this.routingReady === 'function') this.routingReady(); + }, + + _findParentRoute: function() { + var node = this; + while (node) { + node = Polymer.dom(node).parentNode; + if (node && node.nodeType !== Node.ELEMENT_NODE) { + node = node.host; + } + + var route = node && node.moreRouteContext; + if (route instanceof MoreRouting.Route) { + return route; + } + } + return null; + }, + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/more-route-selection.html b/third_party/polymer/v1_0/components/more-routing/more-route-selection.html new file mode 100644 index 0000000..04e292f --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-route-selection.html @@ -0,0 +1,197 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="more-route-context-aware.html"> +<link rel="import" href="route.html"> + +<!-- +TODO(nevir): Document. +--> +<script> + + Polymer({ + + is: 'more-route-selection', + + behaviors: [ + MoreRouting.ContextAware, + ], + + properties: { + + /** + * Routes to select from, as either a path expression or route name. + * + * You can either specify routes via this attribute, or as child nodes + * to this element, but not both. + * + * @type {String|Array<string|MoreRouting.Route>} + */ + routes: { + type: String, + observer: '_routesChanged', + }, + + /** + * The selected `MoreRouting.Route` object, or `null`. + * + * @type {MoreRouting.Route} + */ + selectedRoute: { + type: Object, + value: null, + readOnly: true, + notify: true, + }, + + /** + * The index of the selected route (relative to `routes`). -1 when there + * is no active route. + */ + selectedIndex: { + type: Number, + value: -1, + readOnly: true, + notify: true, + }, + + /** + * The _full_ path expression of the selected route, or `null`. + */ + selectedPath: { + type: String, + readOnly: true, + notify: true, + }, + + /** + * The params of the selected route, or an empty object if no route. + */ + selectedParams: { + type: Object, + readOnly: true, + notify: true, + }, + + }, + + /** + * @event more-route-change fires when a new route is selected. + * @detail {{ + * newRoute: MoreRouting.Route, oldRoute: MoreRouting.Route, + * newIndex: number, oldIndex: number, + * newPath: ?string, oldPath: ?string, + * newParams: Object, oldParams: Object, + * }} + */ + + routingReady: function() { + this._routesChanged(); + }, + + _routesChanged: function() { + if (!this.routingIsReady) return; + var routes = this.routes || []; + if (typeof routes === 'string') { + routes = routes.split(/\s+/); + } + this._routeInfo = this._sortIndexes(routes.map(function(route, index) { + return { + model: MoreRouting.getRoute(route, this.parentRoute), + index: index, + }; + }.bind(this))); + + this._observeRoutes(); + this._evaluate(); + }, + + /** + * Tracks changes to the routes. + */ + _observeRoutes: function() { + if (this._routeListeners) { + for (var i = 0, listener; listener = this._routeListeners[i]; i++) { + listener.close(); + } + } + + this._routeListeners = this._routeInfo.map(function(routeInfo) { + return routeInfo.model.__subscribe(this._evaluate.bind(this)); + }.bind(this)); + }, + + _evaluate: function() { + var newIndex = -1; + var newRoute = null; + var oldIndex = this.selectedIndex; + + for (var i = 0, routeInfo; routeInfo = this._routeInfo[i]; i++) { + if (routeInfo.model && routeInfo.model.active) { + newIndex = routeInfo.index; + newRoute = routeInfo.model; + break; + } + } + if (newIndex === oldIndex) return; + + var oldRoute = this.selectedRoute; + var oldPath = this.selectedPath; + var oldParams = this.selectedParams; + + var newPath = newRoute ? newRoute.fullPath : null; + var newParams = newRoute ? newRoute.params : {}; + + this._setSelectedRoute(newRoute); + this._setSelectedIndex(newIndex); + this._setSelectedPath(newPath); + this._setSelectedParams(newParams); + + this.fire('more-route-change', { + newRoute: newRoute, oldRoute: oldRoute, + newIndex: newIndex, oldIndex: oldIndex, + newPath: newPath, oldPath: oldPath, + newParams: newParams, oldParams: oldParams, + }); + }, + /** + * We want the most specific routes to match first, so we must create a + * mapping of indexes within `routes` that map + */ + _sortIndexes: function(routeInfo) { + return routeInfo.sort(function(a, b) { + if (!a.model) { + return 1; + } else if (!b.model) { + return -1; + // Routes with more path parts are most definitely more specific. + } else if (a.model.depth < b.model.depth) { + return 1; + } if (a.model.depth > b.model.depth) { + return -1; + } else { + + // Also, routes with fewer params are more specific. For example + // `/users/foo` is more specific than `/users/:id`. + if (a.model.numParams < b.model.numParams) { + return -1; + } else if (a.model.numParams > b.model.numParams) { + return 1; + } else { + // Equally specific; we fall back to the default (and hopefully + // stable) sort order. + return 0; + } + } + }); + }, + + }); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/more-route-selector.html b/third_party/polymer/v1_0/components/more-routing/more-route-selector.html new file mode 100644 index 0000000..c45a193 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-route-selector.html @@ -0,0 +1,200 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="more-route-context-aware.html"> +<link rel="import" href="more-route-selection.html"> + +<!-- +TODO(nevir): Document. + +TODO(nevir): Support child addition/removal/reorder. +--> +<dom-module id="more-route-selector"> + <template> + <more-route-selection + id="selection" + routes="[[routes]]" + on-more-route-change="_onMoreRouteChange"> + </more-route-selection> + <content></content> + </template> +</dom-module> +<script> +Polymer({ + + is: 'more-route-selector', + + behaviors: [ + MoreRouting.ContextAware, + ], + + properties: { + + /** + * The attribute to read route expressions from (on children). + */ + routeAttribute: { + type: String, + value: 'route', + }, + + /** + * The routes managed by this element (inferred from the items that are + * defined by the selector it targets). + */ + routes: { + type: Array, + readOnly: true, + notify: true, + }, + + /** + * The selected `MoreRouting.Route` object, or `null`. + * + * @type {MoreRouting.Route} + */ + selectedRoute: { + type: Object, + value: null, + readOnly: true, + notify: true, + }, + + /** + * The index of the selected route (relative to `routes`). -1 when there + * is no active route. + */ + selectedIndex: { + type: Number, + value: -1, + readOnly: true, + notify: true, + }, + + /** + * The _full_ path expression of the selected route, or `null`. + */ + selectedPath: { + type: String, + readOnly: true, + notify: true, + }, + + /** + * The params of the selected route, or an empty object if no route. + */ + selectedParams: { + type: Object, + readOnly: true, + notify: true, + }, + + }, + + /** + * @event more-route-selected fires when a new route is selected. + * @param {{ + * newRoute: MoreRouting.Route, oldRoute: MoreRouting.Route, + * newIndex: number, oldIndex: number, + * newPath: ?string, oldPath: ?string, + * newParams: Object, oldParams: Object, + * }} + */ + + attached: function() { + this._managedSelector = this._findTargetSelector(); + if (!this._managedSelector) { + console.warn(this, 'was built without a selector to manage. It will do nothing.'); + return; + } + + this._managedSelector.addEventListener( + 'selected-item-changed', this._onSelectedItemChanged.bind(this)); + this._updateRoutes(); + }, + + /** + * Handle a change in selected item, driven by the targeted selector. + * + * Note that this will fail if a route is chosen that requires params not + * defined by the current URL. + */ + _onSelectedItemChanged: function(event) { + if (this._settingSelection) return; + var route = this._routeForItem(event.detail.value); + if (!route) return; + route.navigateTo(); + }, + + _updateRoutes: function() { + var routes = []; + if (this._managedSelector) { + routes = this._managedSelector.items.map(this._routeForItem.bind(this)); + } + this._setRoutes(routes); + }, + + _onMoreRouteChange: function(event) { + if (!this._managedSelector) return; + + var selected = ''; + + var index = this.routes.indexOf(event.detail.newRoute); + var attrForSelected = this._managedSelector.attrForSelected; + if (!attrForSelected) { + selected = index; + } else { + var item = this._managedSelector.items[index]; + if (item) + selected = item[attrForSelected] || item.getAttribute(attrForSelected); + } + + // Make sure that we don't turn around and re-navigate + this._settingSelection = true; + this._managedSelector.select(selected); + this._settingSelection = false; + }, + + _findTargetSelector: function() { + var children = Polymer.dom(this).children; + if (children.length !== 1) { + console.error(this, 'expects only a single selector child'); + return null; + } + + var child = children[0]; + if ('selected' in child && 'items' in child) { + return child; + } else { + console.error(this, 'can only manage children that are selectors'); + return null; + } + }, + + _routeForItem: function(item) { + if (!item) return null; + if (item.moreRouteContext && item.moreRouteContext instanceof MoreRouting.Route) { + return item.moreRouteContext; + } + + if (!item.hasAttribute(this.routeAttribute)) { + console.warn(item, 'is missing a context route or "' + this.routeAttribute + '" attribute'); + return null; + } + var expression = item.getAttribute(this.routeAttribute); + var route = MoreRouting.getRoute(expression, this.parentRoute); + // Associate the route w/ its element while we're here. + item.moreRouteContext = route; + + return route; + }, + +}); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/more-route-template-helpers.html b/third_party/polymer/v1_0/components/more-routing/more-route-template-helpers.html new file mode 100644 index 0000000..7c8d8d1 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-route-template-helpers.html @@ -0,0 +1,33 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="routing.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; + +/** + * Helper functions to spruce up your templates. + * + * @behavior + */ +MoreRouting.TemplateHelpers = { + + urlFor: function(pathOrName, params) { + return MoreRouting.urlFor(pathOrName, params); + }, + + isCurrentUrl: function(pathOrName, params) { + return MoreRouting.isCurrentUrl(pathOrName, params); + }, + +}; + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/more-route.html b/third_party/polymer/v1_0/components/more-routing/more-route.html new file mode 100644 index 0000000..27dfa25 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-route.html @@ -0,0 +1,193 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="routing.html"> +<link rel="import" href="more-route-context-aware.html"> + +<script> + + Polymer({ + + is: 'more-route', + + behaviors: [ + MoreRouting.ContextAware, + ], + + properties: { + + /** + * The name of this route. Behavior differs based on the presence of + * `path` during _declaration_. + * + * If `path` is present during declaration, it is registered via `name`. + * + * Otherwise, this `more-route` becomes a `reference` to the route with + * `name`. Changing `name` will update which route is referenced. + */ + name: { + type: String, + observer: '_nameChanged', + }, + + /** + * A path expression used to parse parameters from the window's URL. + */ + path: { + type: String, + obserer: '_pathChanged', + }, + + /** + * Whether this route should become a context for the element that + * contains it. + */ + context: { + type: Boolean, + }, + + /** + * The underlying `MoreRouting.Route` object that is being wrapped. + * + * @type {MoreRouting.Route} + */ + route: { + type: Object, + readOnly: true, + notify: true, + observer: '_routeChanged', + }, + + /** + * The full path expression for this route, including routes this is + * nested within. + */ + fullPath: { + type: String, + readOnly: true, + notify: true, + }, + + /** + * Param values matching the current URL, or an empty object if not + * `active`. + */ + params: { + type: Object, + // readOnly: true, + notify: true, + }, + + /** + * Whether the route matches the current URL. + */ + active: { + type: Boolean, + readOnly: true, + notify: true, + }, + + }, + + routingReady: function() { + this._identityChanged(); + }, + + _nameChanged: function(newName, oldName) { + if (oldName) { + console.error('Changing the `name` property is not supported for', this); + return; + } + this._identityChanged(); + }, + + _pathChanged: function(newPath, oldPath) { + if (oldPath) { + console.error('Changing the `path` property is not supported for', this); + return; + } + this._identityChanged(); + }, + + _identityChanged: function() { + if (!this.routingIsReady) return; + + if (this.name && this.path) { + this._setRoute(MoreRouting.registerNamedRoute(this.name, this.path, this.parentRoute)); + } else if (this.name) { + this._setRoute(MoreRouting.getRouteByName(this.name)); + } else if (this.path) { + this._setRoute(MoreRouting.getRouteByPath(this.path, this.parentRoute)); + } else { + this._setRoute(null); + } + }, + + _routeChanged: function() { + this._observeRoute(); + this._setFullPath(this.route.fullPath); + // this._setParams(this.route.params); + this.params = this.route.params; + this._setActive(this.route.active); + + // @see MoreRouting.ContextAware + this.moreRouteContext = this.route; + + if (this.context) { + var parent = Polymer.dom(this).parentNode; + if (parent.nodeType !== Node.ELEMENT_NODE) { + parent = parent.host; + } + + if (parent.nodeType === Node.ELEMENT_NODE) { + parent.moreRouteContext = this.route; + } else { + console.warn('Unable to determine parent element for', this, '- not setting a context'); + } + } + }, + + _observeRoute: function() { + // TODO(nevir) https://github.com/Polymore/more-routing/issues/24 + if (this._routeListener) { + this._routeListener.close(); + this._routeListener = null; + } + if (this._paramListener) { + this._paramListener.close(); + this._paramListener = null; + } + if (!this.route) return; + + this._routeListener = this.route.__subscribe(function() { + this._setActive(this.route && this.route.active); + }.bind(this)); + + this._paramListener = this.route.params.__subscribe(function(key, value) { + // https://github.com/Polymer/polymer/issues/1505 + this.notifyPath('params.' + key, value); + }.bind(this)); + }, + + urlFor: function(params) { + return this.route.urlFor(params); + }, + + navigateTo: function(params) { + return this.route.navigateTo(params); + }, + + isCurrentUrl: function(params) { + return this.route.isCurrentUrl(params); + }, + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/more-routing-config.html b/third_party/polymer/v1_0/components/more-routing/more-routing-config.html new file mode 100644 index 0000000..3d9b70f --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-routing-config.html @@ -0,0 +1,63 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<link rel="import" href="routing.html"> +<!-- TODO(nevir): import on demand? --> +<link rel="import" href="driver/hash.html"> +<link rel="import" href="driver/mock.html"> +<link rel="import" href="driver/path.html"> + +<script> + + Polymer({ + + is: 'more-routing-config', + + properties: { + + /** + * The routing driver to use. + * + * * `hash`: `MoreRouting.HashDriver` + * * `path`: `MoreRouting.PathDriver` + * * `mock`: `MoreRouting.MockDriver` + * + */ + driver: String, + + /** + * + */ + urlPrefix: String, + + }, + + ready: function() { + var config = {}; + if (this.urlPrefix) config.prefix = this.urlPrefix; + + var driver; + // TODO(nevir): Support custom drivers, too. + if (this.driver === 'hash') { + driver = new MoreRouting.HashDriver(config); + } else if (this.driver === 'path') { + driver = new MoreRouting.PathDriver(config); + } else if (this.driver === 'mock') { + driver = new MoreRouting.MockDriver(config); + } else { + throw new Error('Unknown driver type "' + this.driver + '"'); + } + + MoreRouting.driver = driver; + }, + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/more-routing.html b/third_party/polymer/v1_0/components/more-routing/more-routing.html new file mode 100644 index 0000000..43c3eeb3 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/more-routing.html @@ -0,0 +1,12 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="more-routing-config.html"> +<link rel="import" href="routing.html"> +<link rel="import" href="more-route.html"> +<link rel="import" href="more-route-selector.html"> diff --git a/third_party/polymer/v1_0/components/more-routing/params.html b/third_party/polymer/v1_0/components/more-routing/params.html new file mode 100644 index 0000000..71b3d53 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/params.html @@ -0,0 +1,57 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="emitter.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Params = Params; + +/** + * A collection of route parameters and their values, with nofications. + * + * Params prefixed by `__` are reserved. + * + * @param {!Array<string>} params The keys of the params being managed. + * @param {Params=} parent A parent route's params to inherit. + * @return {Params} + */ +function Params(params, parent) { + var model = Object.create(parent || Params.prototype); + // We have a different set of listeners at every level of the hierarchy. + Object.defineProperty(model, '__listeners', {value: []}); + + // We keep all state enclosed within this closure so that inheritance stays + // relatively straightfoward. + var state = {}; + _compile(model, params, state); + + return model; +} +Params.prototype = Object.create(MoreRouting.Emitter); + +// Utility + +function _compile(model, params, state) { + params.forEach(function(param) { + Object.defineProperty(model, param, { + get: function() { + return state[param]; + }, + set: function(value) { + if (state[param] === value) return; + state[param] = value; + model.__notify(param, value); + }, + }); + }); +} + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/route.html b/third_party/polymer/v1_0/components/more-routing/route.html new file mode 100644 index 0000000..e53ccbc --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/route.html @@ -0,0 +1,226 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="emitter.html"> +<link rel="import" href="params.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; +MoreRouting.Route = Route; + +// Note that this can differ from the part separator defined by the driver. The +// driver's separator is used when parsing/generating URLs given to the client, +// whereas this one is for route definitions. +var PART_SEPARATOR = '/'; +var PARAM_SENTINEL = ':'; +var SEPARATOR_CLEANER = /\/\/+/g; + +/** + * TODO(nevir): Docs. + */ +function Route(path, parent) { + // For `MoreRouting.Emitter`; Emits changes for `active`. + this.__listeners = []; + + this.path = path; + this.parent = parent; + this.fullPath = path; + this.compiled = this._compile(this.path); + this.active = false; + this.driver = null; + + var params = MoreRouting.Params(namedParams(this.compiled), this.parent && this.parent.params); + params.__subscribe(this._navigateToParams.bind(this)); + Object.defineProperty(this, 'params', { + get: function() { return params; }, + set: function() { throw new Error('Route#params cannot be overwritten'); }, + }); + + this.parts = []; + this.children = []; + + // Param values matching the current URL, or an empty object if not `active`. + // + // To make data "binding" easy, `Route` guarantees that `params` will always + // be the same object; just make a reference to it. + if (this.parent) { + this.parent.children.push(this); + this.fullPath = this.parent.fullPath + this.fullPath; + this.depth = this.parent.depth + this.compiled.length; + this.numParams = this.parent.numParams + countParams(this.compiled); + } else { + this.depth = this.compiled.length; + this.numParams = countParams(this.compiled); + } +} +Route.prototype = Object.create(MoreRouting.Emitter); + +Object.defineProperty(Route.prototype, 'active', { + get: function() { + return this._active; + }, + set: function(value) { + if (value !== this._active); + this._active = value; + this.__notify('active', value); + }, +}); + +Route.isPath = function isPath(pathOrName) { + return pathOrName.indexOf(PART_SEPARATOR) === 0; +}; + +Route.joinPath = function joinPath(paths) { + var joined = Array.prototype.join.call(arguments, PART_SEPARATOR); + joined = joined.replace(SEPARATOR_CLEANER, PART_SEPARATOR); + + var minLength = joined.length - PART_SEPARATOR.length; + if (joined.substr(minLength) === PART_SEPARATOR) { + joined = joined.substr(0, minLength); + } + + return joined; +}; + +Route.prototype.urlFor = function urlFor(params) { + return this.driver.urlForParts(this.partsForParams(params)); +}; + +Route.prototype.navigateTo = function navigateTo(params) { + return this.driver.navigateToParts(this.partsForParams(params)); +} + +Route.prototype.isCurrentUrl = function isCurrentUrl(params) { + if (!this.active) return false; + var currentKeys = Object.keys(this.params); + for (var i = 0, key; key = currentKeys[i]; i++) { + if (this.params[key] !== String(params[key])) { + return false; + } + } + return true; +}; + +// Driver Interface + +Route.prototype.partsForParams = function partsForParams(params, silent) { + var parts = this.parent && this.parent.partsForParams(params, silent) || []; + for (var i = 0, config; config = this.compiled[i]; i++) { + if (config.type === 'static') { + parts.push(config.part); + } else if (config.type === 'param') { + var value + if (params && config.name in params) { + value = params[config.name]; + } else { + value = this.params[config.name]; + } + if (value === undefined) { + if (silent) { + return null; + } else { + throw new Error('Missing param "' + config.name + '" for route ' + this); + } + } + parts.push(value); + } + } + return parts; +}; + +/** + * Called by the driver whenever it has detected a change to the URL. + * + * @param {Array.<String>|null} parts The parts of the URL, or null if the + * route should be disabled. + */ +Route.prototype.processPathParts = function processPathParts(parts) { + this.parts = parts; + this.active = this.matchesPathParts(parts); + + // We don't want to notify of these changes; they'd be no-op noise. + this.params.__silent = true; + + if (this.active) { + var keys = Object.keys(this.params); + for (var i = 0; i < keys.length; i++) { + delete this.params[keys[i]]; + } + for (var i = 0, config; config = this.compiled[i]; i++) { + if (config.type === 'param') { + this.params[config.name] = parts[i]; + } + } + } else { + for (key in this.params) { + this.params[key] = undefined; + } + } + + delete this.params.__silent; +}; + +Route.prototype.matchesPathParts = function matchesPathParts(parts) { + if (!parts) return false; + if (parts.length < this.compiled.length) return false; + for (var i = 0, config; config = this.compiled[i]; i++) { + if (config.type === 'static' && parts[i] !== config.part) { + return false; + } + } + return true; +}; + +Route.prototype.toString = function toString() { + return this.path; +}; + +// Internal Implementation + +Route.prototype._compile = function _compile(rawPath) { + // Not strictly required, but helps us stay consistent w/ `getRoute`, etc. + if (rawPath.indexOf(PART_SEPARATOR) !== 0) { + throw new Error('Route paths must begin with a path separator; got: "' + rawPath + '"'); + } + var path = rawPath.substr(PART_SEPARATOR.length); + if (path === '') return []; + + return path.split(PART_SEPARATOR).map(function(part) { + // raw fragment. + if (part.substr(0, 1) == PARAM_SENTINEL) { + return {type: 'param', name: part.substr(1)}; + } else { + return {type: 'static', part: part}; + } + }); +}; + +Route.prototype._navigateToParams = function _navigateToParams() { + var parts = this.partsForParams(this.params, true); + if (!parts) return; + this.driver.navigateToParts(parts); +}; + +function countParams(compiled) { + return compiled.reduce(function(count, part) { + return count + (part.type === 'param' ? 1 : 0); + }, 0); +} + +function namedParams(compiled) { + var result = []; + compiled.forEach(function(part) { + if (part.type === 'static') return; + result.push(part.name); + }); + return result; +} + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/more-routing/routing.html b/third_party/polymer/v1_0/components/more-routing/routing.html new file mode 100644 index 0000000..0b1cf50 --- /dev/null +++ b/third_party/polymer/v1_0/components/more-routing/routing.html @@ -0,0 +1,137 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="route.html"> + +<script> +(function(scope) { +var MoreRouting = scope.MoreRouting = scope.MoreRouting || {}; + +// Route singletons. +var routesByPath = {}; +var pathsByName = {}; + +// Route Management + +/** + * Retrieves (or builds) the singleton `Route` for the given path expression or + * route name. + * + * Paths begin with `/`; anything else is considered a name. + * + * For convenience, `Route` objects can also be passed (and will be returned) - + * this can be used as a route coercion function. + * + * @param {String|MoreRouting.Route} pathOrName + * @param {MoreRouting.Route} parent + * @return {MoreRouting.Route} + */ +MoreRouting.getRoute = function getRoute(pathOrName, parent) { + if (typeof pathOrName !== 'string') return pathOrName; + if (this.isPath(pathOrName)) { + return this.getRouteByPath(pathOrName, parent); + } else { + return this.getRouteByName(pathOrName); + } +} + +/** + * Retrieves (or builds) the singleton `Route` for the given path expression. + * + * @param {String} path + * @param {MoreRouting.Route} parent + * @return {MoreRouting.Route} + */ +MoreRouting.getRouteByPath = function getRouteByPath(path, parent) { + var fullPath = (parent ? parent.fullPath : '') + path; + if (!routesByPath[fullPath]) { + routesByPath[fullPath] = new this.Route(path, parent); + this.driver.manageRoute(routesByPath[fullPath]); + } + return routesByPath[fullPath]; +} + +/** + * Retrieves the route registered via `name`. + * + * @param {String} name + * @return {MoreRouting.Route} + */ +MoreRouting.getRouteByName = function getRouteByName(name) { + var path = pathsByName[name]; + if (!path) { + throw new Error('No route named "' + name + '" has been registered'); + } + return this.getRouteByPath(path); +} + +/** + * @param {String} path + * @return {MoreRouting.Route} The newly registered route. + */ +MoreRouting.registerNamedRoute = function registerNamedRoute(name, path, parent) { + if (pathsByName[name]) { + console.warn( + 'Overwriting route named "' + name + '" with path:', path, + 'previously:', pathsByName[name]); + } + var route = this.getRouteByPath(path, parent); + pathsByName[name] = route.fullPath; + return route; +}; + +// Route Shortcuts +MoreRouting.urlFor = function urlFor(pathOrName, params) { + return this.getRoute(pathOrName).urlFor(params); +}; + +MoreRouting.navigateTo = function navigateTo(pathOrName, params) { + return this.getRoute(pathOrName).navigateTo(params); +}; + +MoreRouting.isCurrentUrl = function isCurrentUrl(pathOrName, params) { + return this.getRoute(pathOrName).isCurrentUrl(params); +}; + +// Utility + +/** + * + */ +MoreRouting.isPath = function isPath(pathOrName) { + return this.Route.isPath(pathOrName); +} + +/** + * @param {...String} paths + */ +MoreRouting.joinPath = function joinPath(paths) { + return this.Route.joinPath.apply(this.Route, arguments); +} + +// Driver Management + +var driver; +Object.defineProperty(MoreRouting, 'driver', { + get: function getDriver() { + if (!driver) { + throw new Error('No routing driver configured. Did you forget <more-routing-config>?'); + } + return driver; + }, + set: function setDriver(newDriver) { + if (driver) { + console.warn('Changing routing drivers is not supported, ignoring. You should have only one <more-routing-config> on the page!'); + return; + } + driver = newDriver; + } +}); + +})(window); +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/.bower.json b/third_party/polymer/v1_0/components/neon-animation/.bower.json new file mode 100644 index 0000000..9d394ec --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/.bower.json @@ -0,0 +1,60 @@ +{ + "name": "neon-animation", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "web-animations" + ], + "main": [ + "neon-animatable-behavior.html", + "neon-animation-behavior.html", + "neon-animation-runner-behavior.html", + "neon-shared-element-animatable-behavior.html", + "neon-shared-element-animation-behavior.html", + "neon-animated-pages.html", + "neon-animatable.html", + "neon-animations.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/neon-animation" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/neon-animation", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-animations-js": "web-animations/web-animations-js#^2.0.0" + }, + "devDependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "160f14c31b4692cc8073b67e8849e444b0695cde" + }, + "_source": "git://github.com/PolymerElements/neon-animation.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/neon-animation" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/neon-animation/.gitignore b/third_party/polymer/v1_0/components/neon-animation/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/neon-animation/README.md b/third_party/polymer/v1_0/components/neon-animation/README.md new file mode 100644 index 0000000..c1b258c --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/README.md @@ -0,0 +1,304 @@ +# neon-animation + +`neon-animation` is a suite of elements and behaviors to implement pluggable animated transitions for Polymer Elements using [Web Animations](https://w3c.github.io/web-animations/). + +*Warning: The API may change.* + +* [A basic animatable element](#basic) +* [Animation configuration](#configuration) + * [Animation types](#configuration-types) + * [Configuration properties](#configuration-properties) + * [Using multiple animations](#configuration-multiple) + * [Running animations encapsulated in children nodes](#configuration-encapsulation) +* [Page transitions](#page-transitions) + * [Shared element animations](#shared-element) + * [Declarative page transitions](#declarative-page) +* [Included animations](#animations) +* [Demos](#demos) + +<a name="basic"></a> +## A basic animatable element + +Elements that can be animated should implement the `Polymer.NeonAnimatableBehavior` behavior, or `Polymer.NeonAnimationRunnerBehavior` if they're also responsible for running an animation. + +```js +Polymer({ + is: 'my-animatable', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + animationConfig: { + value: function() { + return { + // provided by neon-animation/animations/scale-down-animation.html + name: 'scale-down-animation', + node: this + } + } + } + }, + listeners: { + // this event is fired when the animation finishes + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + animate: function() { + // run scale-down-animation + this.playAnimation(); + }, + _onNeonAnimationFinish: function() { + console.log('animation done!'); + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/basic.html) + +<a name="configuration"></a> +## Animation configuration + +<a name="configuration-types"></a> +### Animation types + +An element might run different animations, for example it might do something different when it enters the view and when it exits from view. You can set the `animationConfig` property to a map from an animation type to configuration. + +```js +Polymer({ + is: 'my-dialog', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + opened: { + type: Boolean + }, + animationConfig: { + value: function() { + return { + 'entry': { + // provided by neon-animation/animations/scale-up-animation.html + name: 'scale-up-animation', + node: this + }, + 'exit': { + // provided by neon-animation-animations/fade-out-animation.html + name: 'fade-out-animation', + node: this + } + } + } + } + }, + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + show: function() { + this.opened = true; + this.style.display = 'inline-block'; + // run scale-up-animation + this.playAnimation('entry'); + }, + hide: function() { + this.opened = false; + // run fade-out-animation + this.playAnimation('fade-out-animation'); + }, + _onNeonAnimationFinish: function() { + if (!this.opened) { + this.style.display = 'none'; + } + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/types.html) + +You can also use the convenience properties `entryAnimation` and `exitAnimation` to set `entry` and `exit` animations: + +```js +properties: { + entryAnimation: { + value: 'scale-up-animation' + }, + exitAnimation: { + value: 'fade-out-animation' + } +} +``` + +<a name="configuration-properties"></a> +### Configuration properties + +You can pass additional parameters to configure an animation in the animation configuration object. +All animations should accept the following properties: + + * `name`: The name of an animation, ie. an element implementing `Polymer.NeonAnimationBehavior`. + * `node`: The target node to apply the animation to. Defaults to `this`. + * `timing`: Timing properties to use in this animation. They match the [Web Animations Animation Effect Timing interface](https://w3c.github.io/web-animations/#the-animationeffecttiming-interface). The + properties include the following: + * `duration`: The duration of the animation in milliseconds. + * `delay`: The delay before the start of the animation in milliseconds. + * `easing`: A timing function for the animation. Matches the CSS timing function values. + +Animations may define additional configuration properties and they are listed in their documentation. + +<a name="configuration-multiple"></a> +### Using multiple animations + +Set the animation configuration to an array to combine animations, like this: + +```js +animationConfig: { + value: function() { + return { + // fade-in-animation is run with a 50ms delay from slide-down-animation + 'entry': [{ + name: 'slide-down-animation', + node: this + }, { + name: 'fade-in-animation', + node: this, + timing: {delay: 50} + }] + } + } +} +``` + +<a name="configuration-encapsulation"></a> +### Running animations encapsulated in children nodes + +You can include animations in the configuration that are encapsulated in a child element that implement `Polymer.NeonAnimatableBehavior` with the `animatable` property. + +```js +animationConfig: { + value: function() { + return { + // run fade-in-animation on this, and the entry animation on this.$.myAnimatable + 'entry': [ + {name: 'fade-in-animation', node: this}, + {animatable: this.$.myAnimatable, type: 'entry'} + ] + } + } +} +``` + +<a name="page-transitions"></a> +## Page transitions + +*The artist formerly known as `<core-animated-pages>`* + +The `neon-animated-pages` element manages a set of pages to switch between, and runs animations between the page transitions. It implements the `Polymer.IronSelectableBehavior` behavior. Each child node should implement `Polymer.NeonAnimatableBehavior` and define the `entry` and `exit` animations. During a page transition, the `entry` animation is run on the new page and the `exit` animation is run on the old page. + +<a name="shared-element"></a> +### Shared element animations + +Shared element animations work on multiple nodes. For example, a "hero" animation is used during a page transition to make two elements from separate pages appear to animate as a single element. Shared element animation configurations have an `id` property that identify they belong in the same animation. Elements containing shared elements also have a `sharedElements` property defines a map from `id` to element, the element involved with the animation. + +In the incoming page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the incoming page defines the 'entry' animation + 'entry': { + name: 'hero-animation', + id: 'hero', + toPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.hero + } + } + } +} +``` + +In the outgoing page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the outgoing page defines the 'exit' animation + 'exit': { + name: 'hero-animation', + id: 'hero', + fromPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.otherHero + } + } + } +} +``` + +<a name="declarative-page"></a> +### Declarative page transitions + +For convenience, if you define the `entry-animation` and `exit-animation` attributes on `<neon-animated-pages>`, those animations will apply for all page transitions. + +For example: + +```js +<neon-animated-pages id="pages" class="flex" selected="[[selected]]" entry-animation="slide-from-right-animation" exit-animation="slide-left-animation"> + <neon-animatable>1</neon-animatable> + <neon-animatable>2</neon-animatable> + <neon-animatable>3</neon-animatable> + <neon-animatable>4</neon-animatable> + <neon-animatable>5</neon-animatable> +</neon-animated-pages> +``` + +The new page will slide in from the right, and the old page slide away to the left. + +<a name="animations"></a> +## Included animations + +Single element animations: + + * `fade-in-animation` Animates opacity from `0` to `1`. + * `fade-out-animation` Animates opacity from `1` to `0`. + * `scale-down-animation` Animates transform from `scale(1)` to `scale(0)`. + * `scale-up-animation` Animates transform from `scale(0)` to `scale(1)`. + * `slide-down-animation` Animates transform from `translateY(-100%)` to `none`. + * `slide-up-animation` Animates transform from `none` to `translateY(-100%)`. + * `slide-left-animation` Animates transform from `none` to `translateX(-100%)`; + * `slide-right-animation` Animates transform from `none` to `translateX(100%)`; + * `slide-from-left-animation` Animates transform from `translateX(-100%)` to `none`; + * `slide-from-right-animation` Animates transform from `translateX(100%)` to `none`; + * `transform-animation` Animates a custom transform. + +Note that there is a restriction that only one transform animation can be applied on the same element at a time. Use the custom `transform-animation` to combine transform properties. + +Shared element animations + + * `hero-animation` Animates an element such that it looks like it scales and transforms from another element. + * `ripple-animation` Animates an element to full screen such that it looks like it ripples from another element. + +Group animations + * `cascaded-animation` Applys an animation to an array of elements with a delay between each. + +<a name="demos"></a> +## Demos + + * [Grid to full screen](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/grid/index.html) + * [Animation on load](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/load/index.html) + * [List item to detail](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/list/index.html) (For narrow width) + * [Dots to squares](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/tiles/index.html) + * [Declarative](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/declarative/index.html) diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html new file mode 100644 index 0000000..9e089e9 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html @@ -0,0 +1,84 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<cascaded-animation>` applies an animation on an array of elements with a delay between each. +the delay defaults to 50ms. + +Configuration: +``` +{ + name: 'cascaded-animation', + animation: <animation-name>, + nodes: <array-of-nodes>, + nodedelay: <node-delay-in-ms>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'cascaded-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + properties: { + + _animationMeta: { + type: Object, + value: function() { + return new Polymer.IronMeta({type: 'animation'}); + } + } + + }, + + configure: function(config) { + var animationConstructor = this._animationMeta.byKey(config.animation); + if (!animationConstructor) { + console.warn(this.is + ':', 'constructor for', config.animation, 'not found!'); + return; + } + + var nodes = config.nodes; + var effects = []; + var nodeDelay = config.nodeDelay || 50; + + config.timing = config.timing || {}; + config.timing.delay = config.timing.delay || 0; + + var oldDelay = config.timing.delay; + for (var node, index = 0; node = nodes[index]; index++) { + config.timing.delay += nodeDelay; + config.node = node; + + var animation = new animationConstructor(); + var effect = animation.configure(config); + + effects.push(effect); + } + config.timing.delay = oldDelay; + + this._effect = new GroupEffect(effects); + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/fade-in-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/fade-in-animation.html new file mode 100644 index 0000000..cdb74e30 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/fade-in-animation.html @@ -0,0 +1,49 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<fade-in-animation>` animates the opacity of an element from 0 to 1. + +Configuration: +``` +{ + name: 'fade-in-animation', + node: <node> + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'fade-in-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + this._effect = new KeyframeEffect(node, [ + {'opacity': '0'}, + {'opacity': '1'} + ], this.timingFromConfig(config)); + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/fade-out-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/fade-out-animation.html new file mode 100644 index 0000000..82cc399 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/fade-out-animation.html @@ -0,0 +1,49 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<fade-out-animation>` animates the opacity of an element from 1 to 0. + +Configuration: +``` +{ + name: 'fade-out-animation', + node: <node> + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'fade-out-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + this._effect = new KeyframeEffect(node, [ + {'opacity': '1'}, + {'opacity': '0'} + ], this.timingFromConfig(config)); + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/hero-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/hero-animation.html new file mode 100644 index 0000000..6891561 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/hero-animation.html @@ -0,0 +1,83 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-shared-element-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<hero-animation>` is a shared element animation that scales and transform an element such that it +appears to be shared between two pages. Use this in `<neon-animated-pages>`. The source page +should use this animation in an 'exit' animation and set the `fromPage` configuration property to +itself, and the destination page should use this animation in an `entry` animation and set the +`toPage` configuration property to itself. They should also define the hero elements in the +`sharedElements` property (not a configuration property, see +`Polymer.NeonSharedElementAnimatableBehavior`). + +Configuration: +``` +{ + name: 'hero-animation', + id: <shared-element-id>, + timing: <animation-timing>, + toPage: <node>, /* define for the destination page */ + fromPage: <node>, /* define for the source page */ +} +``` +--> + +<script> + + Polymer({ + + is: 'hero-animation', + + behaviors: [ + Polymer.NeonSharedElementAnimationBehavior + ], + + configure: function(config) { + var shared = this.findSharedElements(config); + if (!shared) { + return null; + } + + var fromRect = shared.from.getBoundingClientRect(); + var toRect = shared.to.getBoundingClientRect(); + + var deltaLeft = fromRect.left - toRect.left; + var deltaTop = fromRect.top - toRect.top; + var deltaWidth = fromRect.width / toRect.width; + var deltaHeight = fromRect.height / toRect.height; + + this.setPrefixedProperty(shared.to, 'transformOrigin', '0 0'); + shared.to.style.zIndex = 10000; + shared.from.style.visibility = 'hidden'; + + this._effect = new KeyframeEffect(shared.to, [ + {'transform': 'translate(' + deltaLeft + 'px,' + deltaTop + 'px) scale(' + deltaWidth + ',' + deltaHeight + ')'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + }, + + complete: function(config) { + var shared = this.findSharedElements(config); + if (!shared) { + return null; + } + shared.to.style.zIndex = ''; + shared.from.style.visibility = ''; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/opaque-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/opaque-animation.html new file mode 100644 index 0000000..f5b60a4 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/opaque-animation.html @@ -0,0 +1,46 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<opaque-animation>` makes an element `opacity:1` for the duration of the animation. Used to prevent +webkit/safari from drawing a frame before an animation for elements that animate from display:none. +--> + +<script> + + Polymer({ + + is: 'opaque-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + node.style.opacity = '0'; + this._effect = new KeyframeEffect(node, [ + {'opacity': '1'}, + {'opacity': '1'} + ], this.timingFromConfig(config)); + return this._effect; + }, + + complete: function(config) { + config.node.style.opacity = ''; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/ripple-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/ripple-animation.html new file mode 100644 index 0000000..afc61f6 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/ripple-animation.html @@ -0,0 +1,92 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-shared-element-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<ripple-animation>` scales and transform an element such that it appears to ripple from either +a shared element, or from a screen position, to full screen. + +If using as a shared element animation in `<neon-animated-pages>`, use this animation in an `exit` +animation in the source page and in an `entry` animation in the destination page. Also, define the +hero elements in the `sharedElements` property (not a configuration property, see +`Polymer.NeonSharedElementAnimatableBehavior`). + +If using a screen position, define the `gesture` property. + +Configuration: +``` +{ + name: 'ripple-animation`. + id: <shared-element-id>, /* set this or gesture */ + gesture: {x: <page-x>, y: <page-y>}, /* set this or id */ + timing: <animation-timing>, + toPage: <node>, /* define for the destination page */ + fromPage: <node>, /* define for the source page */ +} +``` +--> + +<script> + + Polymer({ + + is: 'ripple-animation', + + behaviors: [ + Polymer.NeonSharedElementAnimationBehavior + ], + + configure: function(config, fromPage, toPage) { + var shared = this.findSharedElements(config, fromPage, toPage); + if (!shared) { + return null; + } + + var translateX, translateY; + var toRect = shared.to.getBoundingClientRect(); + if (config.gesture) { + translateX = config.gesture.x - (toRect.left + (toRect.width / 2)); + translateY = config.gesture.y - (toRect.left + (toRect.height / 2)); + } else { + var fromRect = shared.from.getBoundingClientRect(); + translateX = (fromRect.left + (fromRect.width / 2)) - (toRect.left + (toRect.width / 2)); + translateY = (fromRect.top + (fromRect.height / 2)) - (toRect.left + (toRect.height / 2)); + } + var translate = 'translate(' + translateX + 'px,' + translateY + 'px)'; + + var size = Math.max(toRect.width + Math.abs(translateX) * 2, toRect.height + Math.abs(translateY) * 2); + var diameter = Math.sqrt(2 * size * size); + var scaleX = diameter / toRect.width; + var scaleY = diameter / toRect.height; + var scale = 'scale(' + scaleX + ',' + scaleY + ')'; + + this.setPrefixedProperty(shared.to, 'transformOrigin', '50% 50%'); + shared.to.style.borderRadius = '50%'; + + this._effect = new KeyframeEffect(shared.to, [ + {'transform': translate + ' scale(0)'}, + {'transform': translate + ' ' + scale} + ], this.timingFromConfig(config)); + return this._effect; + }, + + complete: function() { + if (this.sharedElements) { + this.setPrefixedProperty(this.sharedElements.to, 'transformOrigin', ''); + this.sharedElements.to.style.borderRadius = ''; + } + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/scale-down-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/scale-down-animation.html new file mode 100644 index 0000000..6dc187b --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/scale-down-animation.html @@ -0,0 +1,65 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<scale-down-animation>` animates the scale transform of an element from 1 to 0. By default it +scales in both the x and y axes. + +Configuration: +``` +{ + name: 'scale-down-animation', + node: <node>, + axis: 'x' | 'y' | '', + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'scale-down-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } + + var scaleProperty = 'scale(0, 0)'; + if (config.axis === 'x') { + scaleProperty = 'scale(0, 1)'; + } else if (config.axis === 'y') { + scaleProperty = 'scale(1, 0)'; + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'scale(1,1)'}, + {'transform': scaleProperty} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/scale-up-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/scale-up-animation.html new file mode 100644 index 0000000..43d3d46 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/scale-up-animation.html @@ -0,0 +1,58 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<scale-up-animation>` animates the scale transform of an element from 0 to 1. By default it +scales in both the x and y axes. + +Configuration: +``` +{ + name: 'scale-up-animation', + node: <node>, + axis: 'x' | 'y' | '', + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'scale-up-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'scale(0)'}, + {'transform': 'scale(1)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/slide-down-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/slide-down-animation.html new file mode 100644 index 0000000..83c1f9b --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/slide-down-animation.html @@ -0,0 +1,59 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-down-animation>` animates the transform of an element from `translateY(-100%)` to `none`. +The `transformOrigin` defaults to `50% 0`. + +Configuration: +``` +{ + name: 'slide-down-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'slide-down-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '50% 0'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translateY(-100%)'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/slide-from-left-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/slide-from-left-animation.html new file mode 100644 index 0000000..d248175 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/slide-from-left-animation.html @@ -0,0 +1,60 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-from-left-animation>` animates the transform of an element from +`translateX(-100%)` to `none`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-from-left-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'slide-from-left-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translateX(-100%)'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/slide-from-right-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/slide-from-right-animation.html new file mode 100644 index 0000000..4ebbf11 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/slide-from-right-animation.html @@ -0,0 +1,60 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-from-right-animation>` animates the transform of an element from +`translateX(100%)` to `none`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-from-right-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'slide-from-right-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translateX(100%)'}, + {'transform': 'none'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/slide-left-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/slide-left-animation.html new file mode 100644 index 0000000..7fbc446 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/slide-left-animation.html @@ -0,0 +1,59 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-left-animation>` animates the transform of an element from `none` to `translateX(-100%)`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-left-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'slide-left-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'none'}, + {'transform': 'translateX(-100%)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/slide-right-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/slide-right-animation.html new file mode 100644 index 0000000..e6441c4 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/slide-right-animation.html @@ -0,0 +1,59 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-right-animation>` animates the transform of an element from `none` to `translateX(100%)`. +The `transformOrigin` defaults to `0 50%`. + +Configuration: +``` +{ + name: 'slide-right-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'slide-right-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '0 50%'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'none'}, + {'transform': 'translateX(100%)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/slide-up-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/slide-up-animation.html new file mode 100644 index 0000000..fdf1186 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/slide-up-animation.html @@ -0,0 +1,59 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-up-animation>` animates the transform of an element from `translateY(0)` to +`translateY(-100%)`. The `transformOrigin` defaults to `50% 0`. + +Configuration: +``` +{ + name: 'slide-up-animation', + node: <node>, + transformOrigin: <transform-origin>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'slide-up-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } else { + this.setPrefixedProperty(node, 'transformOrigin', '50% 0'); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': 'translate(0)'}, + {'transform': 'translateY(-100%)'} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/transform-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/transform-animation.html new file mode 100644 index 0000000..b0d7af5 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/animations/transform-animation.html @@ -0,0 +1,61 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../../polymer/polymer.html"> +<link rel="import" href="../neon-animation-behavior.html"> +<link rel="import" href="../web-animations.html"> + +<!-- +`<slide-down-animation>` animates a custom transform on an element. Use this to animate multiple +transform properties, or to apply a custom transform value. + +Configuration: +``` +{ + name: 'slide-down-animation', + node: <node>, + transformOrigin: <transform-origin>, + transformFrom: <transform-from-string>, + transformTo: <transform-to-string>, + timing: <animation-timing> +} +``` +--> + +<script> + + Polymer({ + + is: 'transform-animation', + + behaviors: [ + Polymer.NeonAnimationBehavior + ], + + configure: function(config) { + var node = config.node; + var transformFrom = config.transformFrom || 'none'; + var transformTo = config.transformTo || 'none'; + + if (config.transformOrigin) { + this.setPrefixedProperty(node, 'transformOrigin', config.transformOrigin); + } + + this._effect = new KeyframeEffect(node, [ + {'transform': transformFrom}, + {'transform': transformTo} + ], this.timingFromConfig(config)); + + return this._effect; + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/bower.json b/third_party/polymer/v1_0/components/neon-animation/bower.json new file mode 100644 index 0000000..4e687f6 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/bower.json @@ -0,0 +1,51 @@ +{ + "name": "neon-animation", + "version": "1.0.1", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "web-animations" + ], + "main": [ + "neon-animatable-behavior.html", + "neon-animation-behavior.html", + "neon-animation-runner-behavior.html", + "neon-shared-element-animatable-behavior.html", + "neon-shared-element-animation-behavior.html", + "neon-animated-pages.html", + "neon-animatable.html", + "neon-animations.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/neon-animation" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/neon-animation", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-meta": "PolymerElements/iron-meta#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-animations-js": "web-animations/web-animations-js#^2.0.0" + }, + "devDependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/neon-animation/guides/neon-animation.md b/third_party/polymer/v1_0/components/neon-animation/guides/neon-animation.md new file mode 100644 index 0000000..7af1659 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/guides/neon-animation.md @@ -0,0 +1,313 @@ +--- +title: neon-animation +summary: "A short guide to neon-animation and neon-animated-pages" +tags: ['animation','core-animated-pages'] +elements: ['neon-animation','neon-animated-pages'] +updated: 2015-05-26 +--- + +# neon-animation + +`neon-animation` is a suite of elements and behaviors to implement pluggable animated transitions for Polymer Elements using [Web Animations](https://w3c.github.io/web-animations/). + +*Warning: The API may change.* + +* [A basic animatable element](#basic) +* [Animation configuration](#configuration) + * [Animation types](#configuration-types) + * [Configuration properties](#configuration-properties) + * [Using multiple animations](#configuration-multiple) + * [Running animations encapsulated in children nodes](#configuration-encapsulation) +* [Page transitions](#page-transitions) + * [Shared element animations](#shared-element) + * [Declarative page transitions](#declarative-page) +* [Included animations](#animations) +* [Demos](#demos) + +<a name="basic"></a> +## A basic animatable element + +Elements that can be animated should implement the `Polymer.NeonAnimatableBehavior` behavior, or `Polymer.NeonAnimationRunnerBehavior` if they're also responsible for running an animation. + +```js +Polymer({ + is: 'my-animatable', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + animationConfig: { + value: function() { + return { + // provided by neon-animation/animations/scale-down-animation.html + name: 'scale-down-animation', + node: this + } + } + } + }, + listeners: { + // this event is fired when the animation finishes + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + animate: function() { + // run scale-down-animation + this.playAnimation(); + }, + _onNeonAnimationFinish: function() { + console.log('animation done!'); + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/basic.html) + +<a name="configuration"></a> +## Animation configuration + +<a name="configuration-types"></a> +### Animation types + +An element might run different animations, for example it might do something different when it enters the view and when it exits from view. You can set the `animationConfig` property to a map from an animation type to configuration. + +```js +Polymer({ + is: 'my-dialog', + behaviors: [ + Polymer.NeonAnimationRunnerBehavior + ], + properties: { + opened: { + type: Boolean + }, + animationConfig: { + value: function() { + return { + 'entry': { + // provided by neon-animation/animations/scale-up-animation.html + name: 'scale-up-animation', + node: this + }, + 'exit': { + // provided by neon-animation-animations/fade-out-animation.html + name: 'fade-out-animation', + node: this + } + } + } + } + }, + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + show: function() { + this.opened = true; + this.style.display = 'inline-block'; + // run scale-up-animation + this.playAnimation('entry'); + }, + hide: function() { + this.opened = false; + // run fade-out-animation + this.playAnimation('fade-out-animation'); + }, + _onNeonAnimationFinish: function() { + if (!this.opened) { + this.style.display = 'none'; + } + } +}); +``` + +[Live demo](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/doc/types.html) + +You can also use the convenience properties `entryAnimation` and `exitAnimation` to set `entry` and `exit` animations: + +```js +properties: { + entryAnimation: { + value: 'scale-up-animation' + }, + exitAnimation: { + value: 'fade-out-animation' + } +} +``` + +<a name="configuration-properties"></a> +### Configuration properties + +You can pass additional parameters to configure an animation in the animation configuration object. +All animations should accept the following properties: + + * `name`: The name of an animation, ie. an element implementing `Polymer.NeonAnimationBehavior`. + * `node`: The target node to apply the animation to. Defaults to `this`. + * `timing`: Timing properties to use in this animation. They match the [Web Animations Animation Effect Timing interface](https://w3c.github.io/web-animations/#the-animationeffecttiming-interface). The + properties include the following: + * `duration`: The duration of the animation in milliseconds. + * `delay`: The delay before the start of the animation in milliseconds. + * `easing`: A timing function for the animation. Matches the CSS timing function values. + +Animations may define additional configuration properties and they are listed in their documentation. + +<a name="configuration-multiple"></a> +### Using multiple animations + +Set the animation configuration to an array to combine animations, like this: + +```js +animationConfig: { + value: function() { + return { + // fade-in-animation is run with a 50ms delay from slide-down-animation + 'entry': [{ + name: 'slide-down-animation', + node: this + }, { + name: 'fade-in-animation', + node: this, + timing: {delay: 50} + }] + } + } +} +``` + +<a name="configuration-encapsulation"></a> +### Running animations encapsulated in children nodes + +You can include animations in the configuration that are encapsulated in a child element that implement `Polymer.NeonAnimatableBehavior` with the `animatable` property. + +```js +animationConfig: { + value: function() { + return { + // run fade-in-animation on this, and the entry animation on this.$.myAnimatable + 'entry': [ + {name: 'fade-in-animation', node: this}, + {animatable: this.$.myAnimatable, type: 'entry'} + ] + } + } +} +``` + +<a name="page-transitions"></a> +## Page transitions + +*The artist formerly known as `<core-animated-pages>`* + +The `neon-animated-pages` element manages a set of pages to switch between, and runs animations between the page transitions. It implements the `Polymer.IronSelectableBehavior` behavior. Each child node should implement `Polymer.NeonAnimatableBehavior` and define the `entry` and `exit` animations. During a page transition, the `entry` animation is run on the new page and the `exit` animation is run on the old page. + +<a name="shared-element"></a> +### Shared element animations + +Shared element animations work on multiple nodes. For example, a "hero" animation is used during a page transition to make two elements from separate pages appear to animate as a single element. Shared element animation configurations have an `id` property that identify they belong in the same animation. Elements containing shared elements also have a `sharedElements` property defines a map from `id` to element, the element involved with the animation. + +In the incoming page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the incoming page defines the 'entry' animation + 'entry': { + name: 'hero-animation', + id: 'hero', + toPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.hero + } + } + } +} +``` + +In the outgoing page: + +```js +properties: { + animationConfig: { + value: function() { + return { + // the outgoing page defines the 'exit' animation + 'exit': { + name: 'hero-animation', + id: 'hero', + fromPage: this + } + } + } + }, + sharedElements: { + value: function() { + return { + 'hero': this.$.otherHero + } + } + } +} +``` + +<a name="declarative-page"></a> +### Declarative page transitions + +For convenience, if you define the `entry-animation` and `exit-animation` attributes on `<neon-animated-pages>`, those animations will apply for all page transitions. + +For example: + +```js +<neon-animated-pages id="pages" class="flex" selected="[[selected]]" entry-animation="slide-from-right-animation" exit-animation="slide-left-animation"> + <neon-animatable>1</neon-animatable> + <neon-animatable>2</neon-animatable> + <neon-animatable>3</neon-animatable> + <neon-animatable>4</neon-animatable> + <neon-animatable>5</neon-animatable> +</neon-animated-pages> +``` + +The new page will slide in from the right, and the old page slide away to the left. + +<a name="animations"></a> +## Included animations + +Single element animations: + + * `fade-in-animation` Animates opacity from `0` to `1`. + * `fade-out-animation` Animates opacity from `1` to `0`. + * `scale-down-animation` Animates transform from `scale(1)` to `scale(0)`. + * `scale-up-animation` Animates transform from `scale(0)` to `scale(1)`. + * `slide-down-animation` Animates transform from `translateY(-100%)` to `none`. + * `slide-up-animation` Animates transform from `none` to `translateY(-100%)`. + * `slide-left-animation` Animates transform from `none` to `translateX(-100%)`; + * `slide-right-animation` Animates transform from `none` to `translateX(100%)`; + * `slide-from-left-animation` Animates transform from `translateX(-100%)` to `none`; + * `slide-from-right-animation` Animates transform from `translateX(100%)` to `none`; + + * `transform-animation` Animates a custom transform. + +Note that there is a restriction that only one transform animation can be applied on the same element at a time. Use the custom `transform-animation` to combine transform properties. + +Shared element animations + + * `hero-animation` Animates an element such that it looks like it scales and transforms from another element. + * `ripple-animation` Animates an element to full screen such that it looks like it ripples from another element. + +Group animations + * `cascaded-animation` Applys an animation to an array of elements with a delay between each. + +<a name="demos"></a> +## Demos + + * [Grid to full screen](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/grid/index.html) + * [Animation on load](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/load/index.html) + * [List item to detail](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/list/index.html) (For narrow width) + * [Dots to squares](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/tiles/index.html) + * [Declarative](http://morethanreal.github.io/neon-animation-demo/bower_components/neon-animation/demo/declarative/index.html) diff --git a/third_party/polymer/v1_0/components/neon-animation/index.html b/third_party/polymer/v1_0/components/neon-animation/index.html new file mode 100644 index 0000000..6f5feed --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>neon-animation</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animatable-behavior.html b/third_party/polymer/v1_0/components/neon-animation/neon-animatable-behavior.html new file mode 100644 index 0000000..fac56f8 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animatable-behavior.html @@ -0,0 +1,156 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="animations/opaque-animation.html"> + +<script> + + /** + * `Polymer.NeonAnimatableBehavior` is implemented by elements containing animations for use with + * elements implementing `Polymer.NeonAnimationRunnerBehavior`. + * @polymerBehavior + */ + Polymer.NeonAnimatableBehavior = { + + properties: { + + /** + * Animation configuration. See README for more info. + */ + animationConfig: { + type: Object + }, + + /** + * Convenience property for setting an 'entry' animation. Do not set `animationConfig.entry` + * manually if using this. The animated node is set to `this` if using this property. + */ + entryAnimation: { + observer: '_entryAnimationChanged', + type: String + }, + + /** + * Convenience property for setting an 'exit' animation. Do not set `animationConfig.exit` + * manually if using this. The animated node is set to `this` if using this property. + */ + exitAnimation: { + observer: '_exitAnimationChanged', + type: String + } + + }, + + _entryAnimationChanged: function() { + this.animationConfig = this.animationConfig || {}; + if (this.entryAnimation !== 'fade-in-animation') { + // insert polyfill hack + this.animationConfig['entry'] = [{ + name: 'opaque-animation', + node: this + }, { + name: this.entryAnimation, + node: this + }]; + } else { + this.animationConfig['entry'] = [{ + name: this.entryAnimation, + node: this + }]; + } + }, + + _exitAnimationChanged: function() { + this.animationConfig = this.animationConfig || {}; + this.animationConfig['exit'] = [{ + name: this.exitAnimation, + node: this + }]; + }, + + _copyProperties: function(config1, config2) { + // shallowly copy properties from config2 to config1 + for (var property in config2) { + config1[property] = config2[property]; + } + }, + + _cloneConfig: function(config) { + var clone = { + isClone: true + }; + this._copyProperties(clone, config); + return clone; + }, + + _getAnimationConfigRecursive: function(type, map, allConfigs) { + if (!this.animationConfig) { + return; + } + + // type is optional + var thisConfig; + if (type) { + thisConfig = this.animationConfig[type]; + } else { + thisConfig = this.animationConfig; + } + + if (!Array.isArray(thisConfig)) { + thisConfig = [thisConfig]; + } + + // iterate animations and recurse to process configurations from child nodes + if (thisConfig) { + for (var config, index = 0; config = thisConfig[index]; index++) { + if (config.animatable) { + config.animatable._getAnimationConfigRecursive(config.type || type, map, allConfigs); + } else { + if (config.id) { + var cachedConfig = map[config.id]; + if (cachedConfig) { + // merge configurations with the same id, making a clone lazily + if (!cachedConfig.isClone) { + map[config.id] = this._cloneConfig(cachedConfig) + cachedConfig = map[config.id]; + } + this._copyProperties(cachedConfig, config); + } else { + // put any configs with an id into a map + map[config.id] = config; + } + } else { + allConfigs.push(config); + } + } + } + } + }, + + /** + * An element implementing `Polymer.NeonAnimationRunnerBehavior` calls this method to configure + * an animation with an optional type. Elements implementing `Polymer.NeonAnimatableBehavior` + * should define the property `animationConfig`, which is either a configuration object + * or a map of animation type to array of configuration objects. + */ + getAnimationConfig: function(type) { + var map = []; + var allConfigs = []; + this._getAnimationConfigRecursive(type, map, allConfigs); + // append the configurations saved in the map to the array + for (var key in map) { + allConfigs.push(map[key]); + } + return allConfigs; + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animatable.html b/third_party/polymer/v1_0/components/neon-animation/neon-animatable.html new file mode 100644 index 0000000..6db9d83 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animatable.html @@ -0,0 +1,54 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="neon-animatable-behavior.html"> + +<!-- +`<neon-animatable>` is a simple container element implementing `Polymer.NeonAnimatableBehavior`. This is a convenience element for use with `<neon-animated-pages>`. + +``` +<neon-animated-pages selected="0" + entry-animation="slide-from-right-animation" + exit-animation="slide-left-animation"> + <neon-animatable>1</neon-animatable> + <neon-animatable>2</neon-animatable> +</neon-animated-pages> +``` +--> + +<dom-module id="neon-animatable"> + + <style> + + :host { + display: block; + } + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'neon-animatable', + + behaviors: [ + Polymer.NeonAnimatableBehavior + ] + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animated-pages.html b/third_party/polymer/v1_0/components/neon-animation/neon-animated-pages.html new file mode 100644 index 0000000..3a5259d --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animated-pages.html @@ -0,0 +1,208 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="../iron-selector/iron-selectable.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="neon-animation-runner-behavior.html"> +<link rel="import" href="animations/opaque-animation.html"> + +<!-- +`neon-animated-pages` manages a set of pages and runs an animation when switching between them. Its +children pages should implement `Polymer.NeonAnimatableBehavior` and define `entry` and `exit` +animations to be run when switching to or switching out of the page. + +@group Neon Elements +@element neon-animated-pages +@demo demo/index.html +--> + +<dom-module id="neon-animated-pages"> + + <style> + + :host { + display: block; + position: relative; + } + + :host > ::content > * { + @apply(--layout-fit); + height: 100%; + } + + :host > ::content > :not(.iron-selected):not(.neon-animating) { + display: none !important; + } + + :host > ::content > .neon-animating { + pointer-events: none; + } + + </style> + + <template> + <content id="content"></content> + </template> + +</dom-module> + +<script> +(function() { + + Polymer({ + + is: 'neon-animated-pages', + + behaviors: [ + Polymer.IronResizableBehavior, + Polymer.IronSelectableBehavior, + Polymer.NeonAnimationRunnerBehavior + ], + + properties: { + + activateEvent: { + type: String, + value: '' + }, + + // if true, the initial page selection will also be animated according to its animation config. + animateInitialSelection: { + type: Boolean, + value: false + } + + }, + + observers: [ + '_selectedChanged(selected)' + ], + + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + + _selectedChanged: function(selected) { + + var selectedPage = this.selectedItem; + var oldPage = this._prevSelected || false; + this._prevSelected = selectedPage; + + // on initial load and if animateInitialSelection is negated, simply display selectedPage. + if (!oldPage && !this.animateInitialSelection) { + this._completeSelectedChanged(); + return; + } + + // insert safari fix. + this.animationConfig = [{ + name: 'opaque-animation', + node: selectedPage + }]; + + // configure selectedPage animations. + if (this.entryAnimation) { + this.animationConfig.push({ + name: this.entryAnimation, + node: selectedPage + }); + } else { + if (selectedPage.getAnimationConfig) { + this.animationConfig.push({ + animatable: selectedPage, + type: 'entry' + }); + } + } + + // configure oldPage animations iff exists. + if (oldPage) { + + // cancel the currently running animation if one is ongoing. + if (oldPage.classList.contains('neon-animating')) { + this._squelchNextFinishEvent = true; + this.cancelAnimation(); + this._completeSelectedChanged(); + } + + // configure the animation. + if (this.exitAnimation) { + this.animationConfig.push({ + name: this.exitAnimation, + node: oldPage + }); + } else { + if (oldPage.getAnimationConfig) { + this.animationConfig.push({ + animatable: oldPage, + type: 'exit' + }); + } + } + + // display the oldPage during the transition. + oldPage.classList.add('neon-animating'); + } + + // display the selectedPage during the transition. + selectedPage.classList.add('neon-animating'); + + // actually run the animations. + if (this.animationConfig.length > 1) { + + // on first load, ensure we run animations only after element is attached. + if (!this.isAttached) { + this.async(function () { + this.playAnimation(null, { + fromPage: null, + toPage: selectedPage + }); + }); + + } else { + this.playAnimation(null, { + fromPage: oldPage, + toPage: selectedPage + }); + } + + } else { + this._completeSelectedChanged(oldPage, selectedPage); + } + }, + + _completeSelectedChanged: function(oldPage, selectedPage) { + if (selectedPage) { + selectedPage.classList.remove('neon-animating'); + } + if (oldPage) { + oldPage.classList.remove('neon-animating'); + } + if (!selectedPage || !oldPage) { + var nodes = Polymer.dom(this.$.content).getDistributedNodes(); + for (var node, index = 0; node = nodes[index]; index++) { + node.classList && node.classList.remove('neon-animating'); + } + } + this.async(this.notifyResize); + }, + + _onNeonAnimationFinish: function(event) { + if (this._squelchNextFinishEvent) { + this._squelchNextFinishEvent = false; + return; + } + this._completeSelectedChanged(event.detail.fromPage, event.detail.toPage); + } + + }) + +})(); +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animation-behavior.html b/third_party/polymer/v1_0/components/neon-animation/neon-animation-behavior.html new file mode 100644 index 0000000..f3b9bc6 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animation-behavior.html @@ -0,0 +1,88 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> + +<script> + + /** + * Use `Polymer.NeonAnimationBehavior` to implement an animation. + * @polymerBehavior + */ + Polymer.NeonAnimationBehavior = { + + properties: { + + /** + * Defines the animation timing. + */ + animationTiming: { + type: Object, + value: function() { + return { + duration: 500, + easing: 'cubic-bezier(0.4, 0, 0.2, 1)', + fill: 'both' + } + } + } + + }, + + registered: function() { + new Polymer.IronMeta({type: 'animation', key: this.is, value: this.constructor}); + }, + + /** + * Do any animation configuration here. + */ + // configure: function(config) { + // }, + + /** + * Returns the animation timing by mixing in properties from `config` to the defaults defined + * by the animation. + */ + timingFromConfig: function(config) { + if (config.timing) { + for (var property in config.timing) { + this.animationTiming[property] = config.timing[property]; + } + } + return this.animationTiming; + }, + + /** + * Sets `transform` and `transformOrigin` properties along with the prefixed versions. + */ + setPrefixedProperty: function(node, property, value) { + var map = { + 'transform': ['webkitTransform'], + 'transformOrigin': ['mozTransformOrigin', 'webkitTransformOrigin'] + }; + var prefixes = map[property]; + for (var prefix, index = 0; prefix = prefixes[index]; index++) { + node.style[prefix] = value; + } + node.style[property] = value; + }, + + /** + * Called when the animation finishes. + */ + complete: function() { + // FIXME not sure about non-bubbling event + this.fire(this.animationEndEvent, null, {bubbles: false}); + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animation-runner-behavior.html b/third_party/polymer/v1_0/components/neon-animation/neon-animation-runner-behavior.html new file mode 100644 index 0000000..ce1211e --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animation-runner-behavior.html @@ -0,0 +1,110 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-meta/iron-meta.html"> +<link rel="import" href="neon-animatable-behavior.html"> + +<script> + + /** + * `Polymer.NeonAnimationRunnerBehavior` adds a method to run animations. + * @polymerBehavior + */ + Polymer.NeonAnimationRunnerBehavior = [Polymer.NeonAnimatableBehavior, { + + properties: { + + _animationMeta: { + type: Object, + value: function() { + return new Polymer.IronMeta({type: 'animation'}); + } + }, + + _player: { + type: Object + } + + }, + + _configureAnimationEffects: function(allConfigs) { + var allAnimations = []; + if (allConfigs.length > 0) { + for (var config, index = 0; config = allConfigs[index]; index++) { + var animationConstructor = this._animationMeta.byKey(config.name); + if (animationConstructor) { + var animation = animationConstructor && new animationConstructor(); + var effect = animation.configure(config); + if (effect) { + allAnimations.push({ + animation: animation, + config: config, + effect: effect + }); + } + } else { + console.warn(this.is + ':', config.name, 'not found!'); + } + } + } + return allAnimations; + }, + + _runAnimationEffects: function(allEffects) { + return player = document.timeline.play(new GroupEffect(allEffects)); + }, + + _completeAnimations: function(allAnimations) { + for (var animation, index = 0; animation = allAnimations[index]; index++) { + animation.animation.complete(animation.config); + } + }, + + /** + * Plays an animation with an optional `type`. + */ + playAnimation: function(type, cookie) { + var allConfigs = this.getAnimationConfig(type); + if (!allConfigs) { + return; + } + var allAnimations = this._configureAnimationEffects(allConfigs); + var allEffects = allAnimations.map(function(animation) { + return animation.effect; + }); + + if (allEffects.length > 0) { + this._player = this._runAnimationEffects(allEffects); + this._player.onfinish = function() { + this._completeAnimations(allAnimations); + + if (this._player) { + this._player.cancel(); + this._player = null; + } + + this.fire('neon-animation-finish', cookie, {bubbles: false}); + }.bind(this); + + } else { + this.fire('neon-animation-finish', cookie, {bubbles: false}); + } + }, + + /** + * Cancels the currently running animation. + */ + cancelAnimation: function() { + if (this._player) { + this._player.cancel(); + } + } + + }]; +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animation.html b/third_party/polymer/v1_0/components/neon-animation/neon-animation.html new file mode 100644 index 0000000..150068a --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animation.html @@ -0,0 +1,17 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="neon-animatable-behavior.html"> +<link rel="import" href="neon-animated-pages.html"> +<link rel="import" href="neon-animatable.html"> +<link rel="import" href="neon-animation-behavior.html"> +<link rel="import" href="neon-animation-runner-behavior.html"> +<link rel="import" href="neon-animations.html"> +<link rel="import" href="neon-shared-element-animatable-behavior.html"> +<link rel="import" href="neon-shared-element-animation-behavior.html"> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-animations.html b/third_party/polymer/v1_0/components/neon-animation/neon-animations.html new file mode 100644 index 0000000..f3bdf49 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-animations.html @@ -0,0 +1,25 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="animations/cascaded-animation.html"> +<link rel="import" href="animations/fade-in-animation.html"> +<link rel="import" href="animations/fade-out-animation.html"> +<link rel="import" href="animations/hero-animation.html"> +<link rel="import" href="animations/opaque-animation.html"> +<link rel="import" href="animations/ripple-animation.html"> +<link rel="import" href="animations/scale-down-animation.html"> +<link rel="import" href="animations/scale-up-animation.html"> +<link rel="import" href="animations/slide-from-left-animation.html"> +<link rel="import" href="animations/slide-from-right-animation.html"> +<link rel="import" href="animations/slide-left-animation.html"> +<link rel="import" href="animations/slide-right-animation.html"> +<link rel="import" href="animations/slide-up-animation.html"> +<link rel="import" href="animations/slide-down-animation.html"> +<link rel="import" href="animations/transform-animation.html"> + diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-shared-element-animatable-behavior.html b/third_party/polymer/v1_0/components/neon-animation/neon-shared-element-animatable-behavior.html new file mode 100644 index 0000000..9d5f6e7 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-shared-element-animatable-behavior.html @@ -0,0 +1,37 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="neon-animatable-behavior.html"> + +<script> + + /** + * Use `Polymer.NeonSharedElementAnimatableBehavior` to implement elements containing shared element + * animations. + * @polymerBehavior + */ + Polymer.NeonSharedElementAnimatableBehavior = [Polymer.NeonAnimatableBehavior, { + + properties: { + + /** + * A map of shared element id to node. + */ + sharedElements: { + type: Object, + value: {} + } + + } + + }]; + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/neon-shared-element-animation-behavior.html b/third_party/polymer/v1_0/components/neon-animation/neon-shared-element-animation-behavior.html new file mode 100644 index 0000000..88a9ccb --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/neon-shared-element-animation-behavior.html @@ -0,0 +1,66 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="neon-animation-behavior.html"> + +<script> + + /** + * Use `Polymer.NeonSharedElementAnimationBehavior` to implement shared element animations. + * @polymerBehavior + */ + Polymer.NeonSharedElementAnimationBehavior = [Polymer.NeonAnimationBehavior, { + + properties: { + + /** + * Cached copy of shared elements. + */ + sharedElements: { + type: Object + } + + }, + + /** + * Finds shared elements based on `config`. + */ + findSharedElements: function(config) { + var fromPage = config.fromPage; + var toPage = config.toPage; + if (!fromPage || !toPage) { + console.warn(this.is + ':', !fromPage ? 'fromPage' : 'toPage', 'is undefined!'); + return null; + }; + + if (!fromPage.sharedElements || !toPage.sharedElements) { + console.warn(this.is + ':', 'sharedElements are undefined for', !fromPage.sharedElements ? fromPage : toPage); + return null; + }; + + var from = fromPage.sharedElements[config.id] + var to = toPage.sharedElements[config.id]; + + if (!from || !to) { + console.warn(this.is + ':', 'sharedElement with id', config.id, 'not found in', !from ? fromPage : toPage); + return null; + } + + this.sharedElements = { + from: from, + to: to + }; + return this.sharedElements; + } + + }]; + +</script> diff --git a/third_party/polymer/v1_0/components/neon-animation/web-animations.html b/third_party/polymer/v1_0/components/neon-animation/web-animations.html new file mode 100644 index 0000000..c871854 --- /dev/null +++ b/third_party/polymer/v1_0/components/neon-animation/web-animations.html @@ -0,0 +1,11 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<script src="../web-animations-js/web-animations-next-lite.min.js"></script> diff --git a/third_party/polymer/v1_0/components/paper-behaviors/.bower.json b/third_party/polymer/v1_0/components/paper-behaviors/.bower.json new file mode 100644 index 0000000..4036b8dcc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-behaviors", + "version": "1.0.0", + "description": "Common behaviors across the paper elements", + "authors": [ + "The Polymer Authors" + ], + "main": [ + "paper-button-behavior.html", + "paper-radio-button-behavior.html" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "behavior" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-behaviors" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-behaviors", + "dependencies": { + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "cf1b11e381a8df169efe2c3aaf08e2787dda31b9" + }, + "_source": "git://github.com/PolymerElements/paper-behaviors.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-behaviors" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-behaviors/.gitignore b/third_party/polymer/v1_0/components/paper-behaviors/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-behaviors/README.md b/third_party/polymer/v1_0/components/paper-behaviors/README.md new file mode 100644 index 0000000..e793a62 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/README.md @@ -0,0 +1,4 @@ +paper-behaviors +=============== + +These are common behaviors used across `paper-*` elements. diff --git a/third_party/polymer/v1_0/components/paper-behaviors/bower.json b/third_party/polymer/v1_0/components/paper-behaviors/bower.json new file mode 100644 index 0000000..0d55094 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-behaviors", + "version": "1.0.0", + "description": "Common behaviors across the paper elements", + "authors": [ + "The Polymer Authors" + ], + "main": [ + "paper-button-behavior.html", + "paper-radio-button-behavior.html" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "behavior" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-behaviors" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-behaviors", + "dependencies": { + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-behaviors/index.html b/third_party/polymer/v1_0/components/paper-behaviors/index.html new file mode 100644 index 0000000..3e003cb --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="paper-button-behavior.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-behaviors/paper-button-behavior.html b/third_party/polymer/v1_0/components/paper-behaviors/paper-button-behavior.html new file mode 100644 index 0000000..7f8aa974 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/paper-button-behavior.html @@ -0,0 +1,55 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-behaviors/iron-button-state.html"> + +<script> + + /** @polymerBehavior */ + Polymer.PaperButtonBehaviorImpl = { + + properties: { + + _elevation: { + type: Number + } + + }, + + observers: [ + '_calculateElevation(focused, disabled, active, pressed, receivedFocusFromKeyboard)' + ], + + hostAttributes: { + role: 'button', + tabindex: '0' + }, + + _calculateElevation: function() { + var e = 1; + if (this.disabled) { + e = 0; + } else if (this.active || this.pressed) { + e = 4; + } else if (this.receivedFocusFromKeyboard) { + e = 3; + } + this._elevation = e; + } + }; + + Polymer.PaperButtonBehavior = [ + Polymer.IronButtonState, + Polymer.IronControlState, + Polymer.PaperButtonBehaviorImpl + ]; + +</script> diff --git a/third_party/polymer/v1_0/components/paper-behaviors/paper-radio-button-behavior.html b/third_party/polymer/v1_0/components/paper-behaviors/paper-radio-button-behavior.html new file mode 100644 index 0000000..f79d65d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-behaviors/paper-radio-button-behavior.html @@ -0,0 +1,40 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-behaviors/iron-button-state.html"> + +<script> + + /** @polymerBehavior */ + Polymer.PaperRadioButtonInk = { + + observers: [ + '_focusedChanged(receivedFocusFromKeyboard)' + ], + + _focusedChanged: function(receivedFocusFromKeyboard) { + if (!this.$.ink) { + return; + } + + this.$.ink.holdDown = receivedFocusFromKeyboard; + } + + }; + + /** @polymerBehavior */ + Polymer.PaperRadioButtonBehavior = [ + Polymer.IronButtonState, + Polymer.IronControlState, + Polymer.PaperRadioButtonInk + ]; + +</script> diff --git a/third_party/polymer/v1_0/components/paper-button/.bower.json b/third_party/polymer/v1_0/components/paper-button/.bower.json new file mode 100644 index 0000000..21100e3 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-button/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-button", + "version": "1.0.1", + "description": "Material design button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "button" + ], + "main": "paper-button.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-button", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "e11a0603feaaedd8cf6c7e0d533bdc67de24c8de" + }, + "_source": "git://github.com/PolymerElements/paper-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-button/.gitignore b/third_party/polymer/v1_0/components/paper-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-button/README.md b/third_party/polymer/v1_0/components/paper-button/README.md new file mode 100644 index 0000000..035b004 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-button/README.md @@ -0,0 +1,45 @@ +paper-button +============ + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-button` is a button. When the user touches the button, a ripple effect emanates +from the point of contact. It may be flat or raised. A raised button is styled with a +shadow. + +Example: +```html + <paper-button>flat button</paper-button> + <paper-button raised>raised button</paper-button> + <paper-button noink>No ripple effect</paper-button> +``` +You may use custom DOM in the button body to create a variety of buttons. For example, to +create a button with an icon and some text: + +```html + <paper-button> + <iron-icon icon="favorite"></iron-icon> + custom button content + </paper-button> +``` +## Styling + +Style the button with CSS as you would a normal DOM element. + +```css + /* make #my-button green with yellow text */ + #my-button { + background: green; + color: yellow; + } +``` +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + +```css + /* make #my-button use a blue ripple instead of foreground color */ + #my-button::shadow paper-ripple { + color: blue; + } +``` +The opacity of the ripple is not customizable via CSS. diff --git a/third_party/polymer/v1_0/components/paper-button/bower.json b/third_party/polymer/v1_0/components/paper-button/bower.json new file mode 100644 index 0000000..940aa6d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-button/bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-button", + "version": "1.0.1", + "description": "Material design button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "button" + ], + "main": "paper-button.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-button", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "iron-test-helpers": "polymerelements/iron-test-helpers#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-button/index.html b/third_party/polymer/v1_0/components/paper-button/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-button/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-button/paper-button.html b/third_party/polymer/v1_0/components/paper-button/paper-button.html new file mode 100644 index 0000000..897ccc6 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-button/paper-button.html @@ -0,0 +1,177 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-material/paper-material.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-behaviors/paper-button-behavior.html"> + +<!-- + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-button` is a button. When the user touches the button, a ripple effect emanates +from the point of contact. It may be flat or raised. A raised button is styled with a +shadow. + +Example: + + <paper-button>flat button</paper-button> + <paper-button raised>raised button</paper-button> + <paper-button noink>No ripple effect</paper-button> + +You may use custom DOM in the button body to create a variety of buttons. For example, to +create a button with an icon and some text: + + <paper-button> + <core-icon icon="favorite"></core-icon> + custom button content + </paper-button> + +### Styling + +Style the button with CSS as you would a normal DOM element. + + /* make #my-button green with yellow text */ + #my-button { + background: green; + color: yellow; + } + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + + /* make #my-button use a blue ripple instead of foreground color */ + #my-button::shadow paper-ripple { + color: blue; + } + +The opacity of the ripple is not customizable via CSS. + +The following custom properties and mixins are also available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-button-flat-focus-color` | Background color of a focused flat button | `--paper-grey-200` +`--paper-button` | Mixin applied to the button | `{}` +`--paper-button-disabled` | Mixin applied to the disabled button | `{}` + +@demo demo/index.html +--> + +<dom-module id="paper-button"> + + <style> + + :host { + display: inline-block; + position: relative; + box-sizing: border-box; + min-width: 5.14em; + margin: 0 0.29em; + background: transparent; + text-align: center; + font: inherit; + text-transform: uppercase; + outline: none; + border-radius: 3px; + -moz-user-select: none; + -ms-user-select: none; + -webkit-user-select: none; + user-select: none; + cursor: pointer; + z-index: 0; + + @apply(--paper-button); + } + + .keyboard-focus { + font-weight: bold; + } + + :host([disabled]) { + background: #eaeaea; + color: #a8a8a8; + cursor: auto; + pointer-events: none; + + @apply(--paper-button-disabled); + } + + :host([noink]) paper-ripple { + display: none; + } + + paper-material { + border-radius: inherit; + } + + .content > ::content * { + text-transform: inherit; + } + + .content { + padding: 0.7em 0.57em + } + </style> + + <template> + + <paper-ripple></paper-ripple> + + <paper-material class$="[[_computeContentClass(receivedFocusFromKeyboard)]]" elevation="[[_elevation]]" animated> + <content></content> + </paper-material> + + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'paper-button', + + behaviors: [ + Polymer.PaperButtonBehavior + ], + + properties: { + + /** + * If true, the button should be styled with a shadow. + */ + raised: { + type: Boolean, + reflectToAttribute: true, + value: false, + observer: '_calculateElevation' + } + }, + + _calculateElevation: function() { + if (!this.raised) { + this._elevation = 0; + } else { + Polymer.PaperButtonBehaviorImpl._calculateElevation.apply(this); + } + }, + + _computeContentClass: function(receivedFocusFromKeyboard) { + var className = 'content '; + if (receivedFocusFromKeyboard) { + className += ' keyboard-focus'; + } + return className; + } + }); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-checkbox/.bower.json b/third_party/polymer/v1_0/components/paper-checkbox/.bower.json new file mode 100644 index 0000000..27f1492 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "paper-checkbox", + "version": "1.0.1", + "description": "A material design checkbox", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "paper", + "checkbox", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-checkbox" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-checkbox", + "ignore": [], + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "d7b372fecace143f83ec67d323be9504308e5f5f" + }, + "_source": "git://github.com/PolymerElements/paper-checkbox.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-checkbox" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-checkbox/.gitignore b/third_party/polymer/v1_0/components/paper-checkbox/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-checkbox/README.md b/third_party/polymer/v1_0/components/paper-checkbox/README.md new file mode 100644 index 0000000..2269079 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/README.md @@ -0,0 +1,31 @@ +# paper-checkbox + +`paper-checkbox` is a button that can be either checked or unchecked. User +can tap the checkbox to check or uncheck it. Usually you use checkboxes +to allow user to select multiple options from a set. If you have a single +ON/OFF option, avoid using a single checkbox and use `paper-toggle-button` +instead. + +Example: + +```html +<paper-checkbox>label</paper-checkbox> + +<paper-checkbox checked>label</paper-checkbox> +``` + +Styling a checkbox: + +```html +<style is="custom-style"> + paper-checkbox { + /* Unhecked state colors. */ + --paper-checkbox-unchecked-color: #5a5a5a; + --paper-checkbox-unchecked-ink-color: #5a5a5a; + + /* Checked state colors. */ + --paper-checkbox-checked-color: #009688; + --paper-checkbox-checked-ink-color: #009688; + } +</style> +``` diff --git a/third_party/polymer/v1_0/components/paper-checkbox/bower.json b/third_party/polymer/v1_0/components/paper-checkbox/bower.json new file mode 100644 index 0000000..6ae5621 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-checkbox", + "version": "1.0.1", + "description": "A material design checkbox", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "paper", + "checkbox", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-checkbox" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-checkbox", + "ignore": [], + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-checkbox/index.html b/third_party/polymer/v1_0/components/paper-checkbox/index.html new file mode 100644 index 0000000..b368797 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-checkbox</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-checkbox/metadata.html b/third_party/polymer/v1_0/components/paper-checkbox/metadata.html new file mode 100644 index 0000000..4d068e8 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/metadata.html @@ -0,0 +1,17 @@ +<!-- + @license + Copyright (c) 2014 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<x-meta id="paper-checkbox" label="Checkbox" group="Paper"> + <template> + <paper-checkbox label="click me"></paper-checkbox> + </template> + <template id="imports"> + <link rel="import" href="paper-checkbox.html"> + </template> +</x-meta> diff --git a/third_party/polymer/v1_0/components/paper-checkbox/paper-checkbox.css b/third_party/polymer/v1_0/components/paper-checkbox/paper-checkbox.css new file mode 100644 index 0000000..eb203fd --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/paper-checkbox.css @@ -0,0 +1,149 @@ +/* +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: inline-block; + white-space: nowrap; +} + +:host(:focus) { + outline: none; +} + +.hidden { + display: none; +} + +#checkboxContainer { + display: inline-block; + position: relative; + width: 18px; + height: 18px; + cursor: pointer; + -webkit-transform: translateZ(0); + transform: translateZ(0); + vertical-align: middle; +} + +:host #ink { + position: absolute; + top: -15px; + left: -15px; + width: 48px; + height: 48px; + color: var(--paper-checkbox-unchecked-ink-color); + opacity: 0.6; +} + +:host #ink[checked] { + color: var(--paper-checkbox-checked-ink-color); +} + +:host #checkbox { + position: relative; + box-sizing: border-box; + height: 100%; + border: solid 2px; + border-color: var(--paper-checkbox-unchecked-color); + border-radius: 2px; + pointer-events: none; + -webkit-transition: background-color 140ms, border-color 140ms; + transition: background-color 140ms, border-color 140ms; +} + +/* checkbox checked animations */ +#checkbox.checked #checkmark { + -webkit-animation: checkmark-expand 140ms ease-out forwards; + animation: checkmark-expand 140ms ease-out forwards; +} + +@-webkit-keyframes checkmark-expand { + 0% { + top: 9px; + left: 6px; + width: 0px; + height: 0px; + } + 100% { + top: -1px; + left: 4px; + width: 5px; + height: 10px; + } +} + +@keyframes checkmark-expand { + 0% { + top: 9px; + left: 6px; + width: 0px; + height: 0px; + } + 100% { + top: -1px; + left: 4px; + width: 5px; + height: 10px; + } +} + +:host #checkbox.checked { + background-color: var(--paper-checkbox-checked-color); + border-color: var(--paper-checkbox-checked-color); +} + +:host #checkmark { + -webkit-transform: rotate(45deg); + transform: rotate(45deg); + position: absolute; + top: -1px; + left: 4px; + width: 5px; + height: 10px; + border-style: solid; + border-top: none; + border-left: none; + border-right-width: 2px; + border-bottom-width: 2px; + border-color: white; +} + +/* label */ +#checkboxLabel { + position: relative; + display: inline-block; + vertical-align: middle; + padding-left: 8px; + white-space: normal; + pointer-events: none; + color: var(--paper-checkbox-label-color); +} + +#checkboxLabel[hidden] { + display: none; +} + +/* disabled state */ +:host([disabled]) { + pointer-events: none; +} + +:host([disabled]) #checkbox { + opacity: 0.5; + border-color: var(--paper-checkbox-unchecked-color); +} + +:host([disabled][checked]) #checkbox { + background-color: var(--paper-checkbox-unchecked-color); + opacity: 0.5; +} + +:host([disabled]) #checkboxLabel { + opacity: 0.65; +} diff --git a/third_party/polymer/v1_0/components/paper-checkbox/paper-checkbox.html b/third_party/polymer/v1_0/components/paper-checkbox/paper-checkbox.html new file mode 100644 index 0000000..2deb9a80 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-checkbox/paper-checkbox.html @@ -0,0 +1,161 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> + +<!-- + +`paper-checkbox` is a button that can be either checked or unchecked. User +can tap the checkbox to check or uncheck it. Usually you use checkboxes +to allow user to select multiple options from a set. If you have a single +ON/OFF option, avoid using a single checkbox and use `paper-toggle-button` +instead. + +Example: + + <paper-checkbox>label</paper-checkbox> + + <paper-checkbox checked> label</paper-checkbox> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-checkbox-unchecked-color` | Checkbox color when the input is not checked | `--primary-text-color` +`--paper-checkbox-unchecked-ink-color` | Selected/focus ripple color when the input is not checked | `--primary-text-color` +`--paper-checkbox-checked-color` | Checkbox color when the input is checked | `--default-primary-color` +`--paper-checkbox-checked-ink-color` | Selected/focus ripple color when the input is checked | `--default-primary-color` +`--paper-checkbox-label-color` | Label color | `--primary-text-color` + +@demo demo/index.html +--> + +<style is="custom-style"> + :root { + --paper-checkbox-unchecked-color: var(--primary-text-color); + --paper-checkbox-unchecked-ink-color: var(--primary-text-color); + + --paper-checkbox-checked-color: var(--default-primary-color); + --paper-checkbox-checked-ink-color: var(--default-primary-color); + + --paper-checkbox-label-color: var(--primary-text-color); + } +</style> + +<dom-module id="paper-checkbox"> + <link rel="import" type="css" href="paper-checkbox.css"> + + <template> + + <div id="checkboxContainer"> + <paper-ripple id="ink" class="circle" center checked$="[[checked]]"></paper-ripple> + <div id="checkbox" class$="[[_computeCheckboxClass(checked)]]"> + <div id="checkmark" class$="[[_computeCheckmarkClass(checked)]]"></div> + </div> + </div> + + <div id="checkboxLabel" aria-hidden="true"><content></content></div> + + </template> + + <script> + Polymer({ + is: 'paper-checkbox', + + behaviors: [ + Polymer.PaperRadioButtonBehavior + ], + + hostAttributes: { + role: 'checkbox', + 'aria-checked': false, + tabindex: 0 + }, + + properties: { + /** + * Fired when the checked state changes due to user interaction. + * + * @event change + */ + + /** + * Fired when the checked state changes. + * + * @event iron-change + */ + + /** + * Gets or sets the state, `true` is checked and `false` is unchecked. + */ + checked: { + type: Boolean, + value: false, + reflectToAttribute: true, + notify: true, + observer: '_checkedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + */ + toggles: { + type: Boolean, + value: true, + reflectToAttribute: true + } + }, + + ready: function() { + if (Polymer.dom(this).textContent == '') { + this.$.checkboxLabel.hidden = true; + } else { + this.setAttribute('aria-label', Polymer.dom(this).textContent); + } + this._isReady = true; + }, + + // button-behavior hook + _buttonStateChanged: function() { + if (this.disabled) { + return; + } + if (this._isReady) { + this.checked = this.active; + } + }, + + _checkedChanged: function(checked) { + this.setAttribute('aria-checked', this.checked ? 'true' : 'false'); + this.active = this.checked; + this.fire('iron-change'); + }, + + _computeCheckboxClass: function(checked) { + if (checked) { + return 'checked'; + } + }, + + _computeCheckmarkClass: function(checked) { + if (!checked) { + return 'hidden'; + } + } + }) + </script> + +</dom-module> diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/.bower.json b/third_party/polymer/v1_0/components/paper-dialog-behavior/.bower.json new file mode 100644 index 0000000..a47fd0f --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/.bower.json @@ -0,0 +1,46 @@ +{ + "name": "paper-dialog-behavior", + "version": "1.0.0", + "description": "Implements a behavior used for material design dialogs", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay", + "behavior" + ], + "main": [ + "paper-dialog-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-behavior", + "ignore": [], + "dependencies": { + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "cd65087ca07495d546bc46618563e53ceacd5325" + }, + "_source": "git://github.com/PolymerElements/paper-dialog-behavior.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-dialog-behavior" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/.gitignore b/third_party/polymer/v1_0/components/paper-dialog-behavior/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/README.md b/third_party/polymer/v1_0/components/paper-dialog-behavior/README.md new file mode 100644 index 0000000..2c63d3c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/README.md @@ -0,0 +1,24 @@ +# paper-dialog-behavior + +`paper-dialog-behavior` implements behavior related to a Material Design dialog. Use this behavior +and include `paper-dialog-common.css` in your element to implement a dialog. + +`paper-dialog-common.css` provide styles for a header, content area, and an action area for buttons. +Use the `<h2>` tag for the header and the `buttons` class for the action area. You can use the +`paper-dialog-scrollable` element (in its own repository) if you need a scrolling content area. + +Use the `dialog-dismiss` and `dialog-confirm` attributes on interactive controls to close the +dialog. + +For example, if `<paper-dialog-impl>` implements this behavior: + +```html +<paper-dialog-impl> + <h2>Header</h2> + <div>Dialog body</div> + <div class="buttons"> + <paper-button dialog-dismiss>Cancel</paper-button> + <paper-button dialog-confirm>Accept</paper-button> + </div> +</paper-dialog-impl> +``` diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/bower.json b/third_party/polymer/v1_0/components/paper-dialog-behavior/bower.json new file mode 100644 index 0000000..7b3e6c1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-dialog-behavior", + "version": "1.0.0", + "description": "Implements a behavior used for material design dialogs", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay", + "behavior" + ], + "main": [ + "paper-dialog-behavior.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-behavior" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-behavior", + "ignore": [], + "dependencies": { + "iron-overlay-behavior": "PolymerElements/iron-overlay-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/hero.svg b/third_party/polymer/v1_0/components/paper-dialog-behavior/hero.svg new file mode 100644 index 0000000..d473816 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/hero.svg @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <polygon points="76.7,98 79.2,98 74,91.1 74,94.4 "/> + <polygon points="74,81.4 74,84.7 84.1,98 86.6,98 "/> + <polygon points="74,71.7 74,75 91.5,98 94,98 "/> + <polygon points="74,62 74,65.3 98.9,98 101.4,98 "/> + <polygon points="94.3,79 92,79 92,76 74,52.3 74,55.6 106.2,98 108.7,98 "/> + <polygon points="92,69.6 92,66.3 74,42.6 74,45.9 "/> + <polygon points="101.7,79 99.2,79 113.6,98 116.1,98 "/> + <polygon points="92,59.9 92,56.6 74,32.9 74,36.2 "/> + <polygon points="109.1,79 106.5,79 121,98 123.5,98 "/> + <polygon points="92,50.2 92,47 92.1,47 77.7,28 75.2,28 "/> + <polygon points="116.4,79 113.9,79 128.4,98 130.9,98 "/> + <polygon points="97,47 99.5,47 85,28 82.5,28 "/> + <polygon points="123.8,79 121.3,79 135.7,98 138.2,98 "/> + <polygon points="104.4,47 106.9,47 92.4,28 89.9,28 "/> + <polygon points="131.2,79 128.7,79 143.1,98 145.6,98 "/> + <polygon points="132,70.4 132,73.7 150,97.4 150,94.1 "/> + <polygon points="111.7,47 114.2,47 99.8,28 97.3,28 "/> + <polygon points="132,60.7 132,64 150,87.7 150,84.3 "/> + <polygon points="119.1,47 121.6,47 107.2,28 104.7,28 "/> + <polygon points="132,51 132,54.3 150,77.9 150,74.6 "/> + <polygon points="114.6,28 112,28 126.5,47 129,47 "/> + <polygon points="121.9,28 119.4,28 150,68.2 150,64.9 "/> + <polygon points="129.3,28 126.8,28 150,58.5 150,55.2 "/> + <polygon points="136.7,28 134.2,28 150,48.8 150,45.5 "/> + <polygon points="144.1,28 141.5,28 150,39.1 150,35.8 "/> + <polygon points="150,29.4 150,28 148.9,28 "/> + </g> + <path d="M133,80H91V46h42V80z M93,78h38V48H93V78z"/> + <path d="M151,99H73V27h78V99z M75,97h74V29H75V97z"/> + <circle cx="74" cy="28" r="4"/> + <circle cx="150" cy="28" r="4"/> + <circle cx="150" cy="98" r="4"/> + <circle cx="74" cy="98" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/index.html b/third_party/polymer/v1_0/components/paper-dialog-behavior/index.html new file mode 100644 index 0000000..af98b85 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-dialog-behavior</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/paper-dialog-behavior.html b/third_party/polymer/v1_0/components/paper-dialog-behavior/paper-dialog-behavior.html new file mode 100644 index 0000000..8e83fed --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/paper-dialog-behavior.html @@ -0,0 +1,236 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-overlay-behavior/iron-overlay-behavior.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<script> + +/* +Use `Polymer.PaperDialogBehavior` and `paper-dialog-common.css` to implement a Material Design +dialog. + +For example, if `<paper-dialog-impl>` implements this behavior: + + <paper-dialog-impl> + <h2>Header</h2> + <div>Dialog body</div> + <div class="buttons"> + <paper-button dialog-dismiss>Cancel</paper-button> + <paper-button dialog-confirm>Accept</paper-button> + </div> + </paper-dialog-impl> + +`paper-dialog-common.css` provide styles for a header, content area, and an action area for buttons. +Use the `<h2>` tag for the header and the `buttons` class for the action area. You can use the +`paper-dialog-scrollable` element (in its own repository) if you need a scrolling content area. + +Use the `dialog-dismiss` and `dialog-confirm` attributes on interactive controls to close the +dialog. If the user dismisses the dialog with `dialog-confirm`, the `closingReason` will update +to include `confirmed: true`. + +### Styling + +The following custom properties and mixins are available for styling. + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-dialog-background-color` | Dialog background color | `--primary-background-color` +`--paper-dialog-color` | Dialog foreground color | `--primary-text-color` +`--paper-dialog` | Mixin applied to the dialog | `{}` +`--paper-dialog-title` | Mixin applied to the title (`<h2>`) element | `{}` +`--paper-dialog-button-color` | Button area foreground color | `--default-primary-color` + +### Accessibility + +This element has `role="dialog"` by default. Depending on the context, it may be more appropriate +to override this attribute with `role="alertdialog"`. The header (a `<h2>` element) will + +If `modal` is set, the element will set `aria-modal` and prevent the focus from exiting the element. +It will also ensure that focus remains in the dialog. + +The `aria-labelledby` attribute will be set to the header element, if one exists. + +@hero hero.svg +@demo demo/index.html +@polymerBehavior Polymer.PaperDialogBehavior +*/ + + Polymer.PaperDialogBehaviorImpl = { + + hostAttributes: { + 'role': 'dialog', + 'tabindex': '-1' + }, + + properties: { + + /** + * If `modal` is true, this implies `no-cancel-on-outside-click` and `with-backdrop`. + */ + modal: { + observer: '_modalChanged', + type: Boolean, + value: false + }, + + _lastFocusedElement: { + type: Node + }, + + _boundOnFocus: { + type: Function, + value: function() { + return this._onFocus.bind(this); + } + }, + + _boundOnBackdropClick: { + type: Function, + value: function() { + return this._onBackdropClick.bind(this); + } + } + + }, + + listeners: { + 'click': '_onDialogClick', + 'iron-overlay-opened': '_onIronOverlayOpened', + 'iron-overlay-closed': '_onIronOverlayClosed' + }, + + attached: function() { + this._observer = this._observe(this); + this._updateAriaLabelledBy(); + }, + + detached: function() { + if (this._observer) { + this._observer.disconnect(); + } + }, + + _observe: function(node) { + var observer = new MutationObserver(function() { + this._updateAriaLabelledBy(); + }.bind(this)); + observer.observe(node, { + childList: true, + subtree: true + }); + return observer; + }, + + _modalChanged: function() { + if (this.modal) { + this.setAttribute('aria-modal', 'true'); + } else { + this.setAttribute('aria-modal', 'false'); + } + // modal implies noCancelOnOutsideClick and withBackdrop if true, don't overwrite + // those properties otherwise. + if (this.modal) { + this.noCancelOnOutsideClick = true; + this.withBackdrop = true; + } + }, + + _updateAriaLabelledBy: function() { + var header = Polymer.dom(this).querySelector('h2'); + if (!header) { + this.removeAttribute('aria-labelledby'); + return; + } + var headerId = header.getAttribute('id'); + if (headerId && this.getAttribute('aria-labelledby') === headerId) { + return; + } + // set aria-describedBy to the header element + var labelledById; + if (headerId) { + labelledById = headerId; + } else { + labelledById = 'paper-dialog-header-' + new Date().getUTCMilliseconds(); + header.setAttribute('id', labelledById); + } + this.setAttribute('aria-labelledby', labelledById); + }, + + _updateClosingReasonConfirmed: function(confirmed) { + this.closingReason = this.closingReason || {}; + this.closingReason.confirmed = confirmed; + }, + + _onDialogClick: function(event) { + var target = event.target; + while (target !== this) { + if (target.hasAttribute('dialog-dismiss')) { + this._updateClosingReasonConfirmed(false); + this.close(); + break; + } else if (target.hasAttribute('dialog-confirm')) { + this._updateClosingReasonConfirmed(true); + this.close(); + break; + } + target = target.parentNode; + } + }, + + _onIronOverlayOpened: function() { + if (this.modal) { + document.body.addEventListener('focus', this._boundOnFocus, true); + this.backdropElement.addEventListener('click', this._boundOnBackdropClick); + } + }, + + _onIronOverlayClosed: function() { + document.body.removeEventListener('focus', this._boundOnFocus, true); + this.backdropElement.removeEventListener('click', this._boundOnBackdropClick); + }, + + _onFocus: function(event) { + if (this.modal) { + var target = event.target; + while (target && target !== this && target !== document.body) { + target = target.parentNode; + } + if (target) { + if (target === document.body) { + if (this._lastFocusedElement) { + this._lastFocusedElement.focus(); + } else { + this._focusNode.focus(); + } + } else { + this._lastFocusedElement = event.target; + } + } + } + }, + + _onBackdropClick: function() { + if (this.modal) { + if (this._lastFocusedElement) { + this._lastFocusedElement.focus(); + } else { + this._focusNode.focus(); + } + } + } + + }; + + /** @polymerBehavior */ + Polymer.PaperDialogBehavior = [Polymer.IronOverlayBehavior, Polymer.PaperDialogBehaviorImpl]; + +</script> diff --git a/third_party/polymer/v1_0/components/paper-dialog-behavior/paper-dialog-common.css b/third_party/polymer/v1_0/components/paper-dialog-behavior/paper-dialog-common.css new file mode 100644 index 0000000..57c665d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-behavior/paper-dialog-common.css @@ -0,0 +1,57 @@ +/* +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: block; + margin: 24px 40px; + + background: var(--paper-dialog-background-color, --primary-background-color); + color: var(--paper-dialog-color, --primary-text-color); + + @apply(--paper-font-body1); + @apply(--shadow-elevation-16dp); + @apply(--paper-dialog); +} + +:host > ::content > * { + margin-top: 20px; + padding: 0 24px; +} + +:host > ::content > .no-padding { + padding: 0; +}; + +:host > ::content > *:first-child { + margin-top: 24px; +} + +:host > ::content > *:last-child { + margin-bottom: 24px; +} + +:host > ::content h2 { + position: relative; + margin: 0; + @apply(--paper-font-title); + + @apply(--paper-dialog-title); +} + +:host > ::content .buttons { + position: relative; + padding: 8px 8px 8px 24px; + margin: 0; + + color: var(--paper-dialog-button-color, --default-primary-color); + + @apply(--layout-horizontal); + @apply(--layout-end-justified); +} diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/.bower.json b/third_party/polymer/v1_0/components/paper-dialog-scrollable/.bower.json new file mode 100644 index 0000000..88e5eb3 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-dialog-scrollable", + "version": "1.0.0", + "description": "A scrollable area used inside the material design dialog", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": [ + "paper-dialog-scrollable.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-scrollable" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-scrollable", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "9d27cbdedfb4b4b06eefffbf99d0e7fa97c3e248" + }, + "_source": "git://github.com/PolymerElements/paper-dialog-scrollable.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-dialog-scrollable" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/.gitignore b/third_party/polymer/v1_0/components/paper-dialog-scrollable/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/README.md b/third_party/polymer/v1_0/components/paper-dialog-scrollable/README.md new file mode 100644 index 0000000..201d0af --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/README.md @@ -0,0 +1,8 @@ +# paper-dialog-scrollable + +`paper-dialog-scrollable` implements a scrolling area used in a Material Design dialog. Use this +together with elements implementing `paper-dialog-behavior`. + +It shows a top divider after scrolling if it is not the first child in its parent container. It +shows a bottom divider if it is scrollable and it is not the last child in its parent container. +The bottom divider is hidden if it is scrolled to the bottom. diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/bower.json b/third_party/polymer/v1_0/components/paper-dialog-scrollable/bower.json new file mode 100644 index 0000000..99553af --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-dialog-scrollable", + "version": "1.0.0", + "description": "A scrollable area used inside the material design dialog", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": [ + "paper-dialog-scrollable.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog-scrollable" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog-scrollable", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/hero.svg b/third_party/polymer/v1_0/components/paper-dialog-scrollable/hero.svg new file mode 100644 index 0000000..40bc69a --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/hero.svg @@ -0,0 +1,69 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <polygon points="0,124 0,126 2,126 "/> + <polygon points="0,111.6 0,114.4 11.6,126 14.4,126 "/> + <polygon points="0,99.1 0,101.9 24.1,126 26.9,126 "/> + <polygon points="0,86.6 0,89.5 36.5,126 39.4,126 "/> + <polygon points="0,74.2 0,77 49,126 51.8,126 "/> + <polygon points="0,61.7 0,64.5 61.5,126 64.3,126 "/> + <polygon points="0,49.2 0,52.1 73.9,126 76.8,126 "/> + <polygon points="0,36.8 0,39.6 86.4,126 89.2,126 "/> + <polygon points="76.7,101 74,101 74,98.3 0,24.3 0,27.1 98.9,126 101.7,126 "/> + <polygon points="74,88.7 74,85.8 0,11.8 0,14.7 "/> + <polygon points="89.2,101 86.3,101 111.3,126 114.2,126 "/> + <polygon points="101.6,101 98.8,101 123.8,126 126.6,126 "/> + <polygon points="74,76.2 74,73.4 0.6,0 0,0 0,2.2 "/> + <polygon points="114.1,101 111.3,101 136.3,126 139.1,126 "/> + <polygon points="74,63.7 74,60.9 13.1,0 10.3,0 "/> + <polygon points="74,51.3 74,48.4 25.6,0 22.7,0 "/> + <polygon points="126.6,101 123.7,101 148.7,126 151.6,126 "/> + <polygon points="74,38.8 74,36 38,0 35.2,0 "/> + <polygon points="139,101 136.2,101 161.2,126 164,126 "/> + <polygon points="74,26.3 74,25 75.5,25 50.5,0 47.7,0 "/> + <polygon points="150,99.5 150,101 148.7,101 173.7,126 176.5,126 "/> + <polygon points="150,87 150,89.9 186.1,126 189,126 "/> + <polygon points="85.1,25 88,25 63,0 60.1,0 "/> + <polygon points="150,74.6 150,77.4 198.6,126 201.4,126 "/> + <polygon points="97.6,25 100.4,25 75.4,0 72.6,0 "/> + <polygon points="150,62.1 150,64.9 211.1,126 213.9,126 "/> + <polygon points="110.1,25 112.9,25 87.9,0 85.1,0 "/> + <polygon points="150,49.7 150,52.5 223.5,126 225,126 225,124.7 "/> + <polygon points="122.5,25 125.3,25 100.3,0 97.5,0 "/> + <polygon points="112.8,0 110,0 135,25 137.8,25 "/> + <polygon points="150,37.2 150,40 225,115 225,112.2 "/> + <polygon points="125.3,0 122.5,0 147.5,25 150,25 150,27.5 225,102.5 225,99.7 "/> + <polygon points="137.7,0 134.9,0 225,90.1 225,87.3 "/> + <polygon points="150.2,0 147.4,0 225,77.6 225,74.8 "/> + <polygon points="162.7,0 159.8,0 225,65.2 225,62.3 "/> + <polygon points="175.1,0 172.3,0 225,52.7 225,49.9 "/> + <polygon points="187.6,0 184.8,0 225,40.2 225,37.4 "/> + <polygon points="200.1,0 197.2,0 225,27.8 225,24.9 "/> + <polygon points="212.5,0 209.7,0 225,15.3 225,12.5 "/> + <polygon points="225,0 222.2,0 225,2.8 225,0 "/> + </g> + <path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/> + <rect x="82" y="53" width="26" height="2"/> + <rect x="116" y="53" width="26" height="2"/> + <rect x="82" y="62" width="26" height="2"/> + <rect x="82" y="72" width="26" height="2"/> + <rect x="116" y="72" width="26" height="2"/> + <rect x="82" y="42" width="26" height="2"/> + <circle cx="120" cy="63" r="4"/> + <circle cx="134" cy="63" r="4"/> + <rect x="116" y="85" width="22" height="5.5"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/index.html b/third_party/polymer/v1_0/components/paper-dialog-scrollable/index.html new file mode 100644 index 0000000..2d2ec7e --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-dialog-scrollable</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-dialog-scrollable/paper-dialog-scrollable.html b/third_party/polymer/v1_0/components/paper-dialog-scrollable/paper-dialog-scrollable.html new file mode 100644 index 0000000..9817489 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog-scrollable/paper-dialog-scrollable.html @@ -0,0 +1,150 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`paper-dialog-scrollable` implements a scrolling area used in a Material Design dialog. It shows +a divider at the top and/or bottom indicating more content, depending on scroll position. Use this +together with elements implementing `Polymer.PaperDialogBehavior`. + + <paper-dialog-impl> + <h2>Header</h2> + <paper-dialog-scrollable> + Lorem ipsum... + </paper-dialog-scrollable> + <div class="buttons"> + <paper-button>OK</paper-button> + </div> + </paper-dialog-impl> + +It shows a top divider after scrolling if it is not the first child in its parent container, +indicating there is more content above. It shows a bottom divider if it is scrollable and it is not +the last child in its parent container, indicating there is more content below. The bottom divider +is hidden if it is scrolled to the bottom. + +@group Paper Elements +@element paper-dialog-scrollable +@demo demo/index.html +@hero hero.svg +--> + +<dom-module id="paper-dialog-scrollable"> + + <style> + + :host { + display: block; + position: relative; + } + + :host(.is-scrolled:not(:first-child))::before { + content: ''; + position: absolute; + top: 0; + left: 0; + right: 0; + height: 1px; + background: var(--divider-color); + } + + :host(.can-scroll:not(.scrolled-to-bottom):not(:last-child))::after { + content: ''; + position: absolute; + bottom: 0; + left: 0; + right: 0; + height: 1px; + background: var(--divider-color); + } + + .scrollable { + padding: 0 24px; + + @apply(--layout-scroll); + + @apply(--paper-dialog-scrollable); + } + </style> + + <template> + <div id="scrollable" class="scrollable"> + <content></content> + </div> + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-dialog-scrollable', + + properties: { + + /** + * The dialog element that implements `Polymer.PaperDialogBehavior` containing this element. + */ + dialogElement: { + type: Object, + value: function() { + return this.parentNode; + } + } + + }, + + listeners: { + 'scrollable.scroll': '_onScroll', + 'iron-resize': '_onIronResize' + }, + + /** + * Returns the scrolling element. + */ + get scrollTarget() { + return this.$.scrollable; + }, + + attached: function() { + this.classList.add('no-padding'); + // Set itself to the overlay sizing target + this.dialogElement.sizingTarget = this.scrollTarget; + // If the host is sized, fit the scrollable area to the container. Otherwise let it be + // its natural size. + requestAnimationFrame(function() { + if (this.offsetHeight > 0) { + this.$.scrollable.classList.add('fit'); + } + this._scroll(); + }.bind(this)); + }, + + _scroll: function() { + this.toggleClass('is-scrolled', this.scrollTarget.scrollTop > 0); + this.toggleClass('can-scroll', this.scrollTarget.offsetHeight < this.scrollTarget.scrollHeight); + this.toggleClass('scrolled-to-bottom', + this.scrollTarget.scrollTop + this.scrollTarget.offsetHeight >= this.scrollTarget.scrollHeight); + }, + + _onScroll: function() { + this._scroll(); + } + + }) + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-dialog/.bower.json b/third_party/polymer/v1_0/components/paper-dialog/.bower.json new file mode 100644 index 0000000..540adab --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-dialog", + "description": "A Material Design dialog", + "version": "1.0.0", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": "paper-dialog.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "neon-animation": "PolymerElements/neon-animation#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "6d66cf1e022e56ec28353a2f718e93535c7cac20" + }, + "_source": "git://github.com/PolymerElements/paper-dialog.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-dialog" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-dialog/.gitignore b/third_party/polymer/v1_0/components/paper-dialog/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-dialog/README.md b/third_party/polymer/v1_0/components/paper-dialog/README.md new file mode 100644 index 0000000..a4d5c7f --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/README.md @@ -0,0 +1,3 @@ +# paper-dialog + +A Material Design dialog diff --git a/third_party/polymer/v1_0/components/paper-dialog/bower.json b/third_party/polymer/v1_0/components/paper-dialog/bower.json new file mode 100644 index 0000000..2bce00e --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/bower.json @@ -0,0 +1,35 @@ +{ + "name": "paper-dialog", + "description": "A Material Design dialog", + "version": "1.0.0", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "dialog", + "overlay" + ], + "main": "paper-dialog.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-dialog" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-dialog", + "ignore": [], + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "neon-animation": "PolymerElements/neon-animation#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-dialog/hero.svg b/third_party/polymer/v1_0/components/paper-dialog/hero.svg new file mode 100644 index 0000000..713329b --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/hero.svg @@ -0,0 +1,58 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <polygon points="0,124 0,126 2,126 "/> + <polygon points="0,111.6 0,114.4 11.6,126 14.4,126 "/> + <polygon points="0,99.1 0,101.9 24.1,126 26.9,126 "/> + <polygon points="0,86.6 0,89.5 36.5,126 39.4,126 "/> + <polygon points="0,74.2 0,77 49,126 51.8,126 "/> + <polygon points="0,61.7 0,64.5 61.5,126 64.3,126 "/> + <polygon points="0,49.2 0,52.1 73.9,126 76.8,126 "/> + <polygon points="0,36.8 0,39.6 86.4,126 89.2,126 "/> + <polygon points="0,24.3 0,27.1 98.9,126 101.7,126 "/> + <polygon points="75.2,87 74,87 74,85.8 0,11.8 0,14.7 111.3,126 114.2,126 "/> + <polygon points="87.6,87 84.8,87 123.8,126 126.6,126 "/> + <polygon points="74,76.2 74,73.4 0.6,0 0,0 0,2.2 "/> + <polygon points="74,63.7 74,60.9 13.1,0 10.3,0 "/> + <polygon points="100.1,87 97.3,87 136.3,126 139.1,126 "/> + <polygon points="112.6,87 109.7,87 148.7,126 151.6,126 "/> + <polygon points="74,51.3 74,48.4 25.6,0 22.7,0 "/> + <polygon points="125,87 122.2,87 161.2,126 164,126 "/> + <polygon points="74.2,39 77,39 38,0 35.2,0 "/> + <polygon points="86.7,39 89.5,39 50.5,0 47.7,0 "/> + <polygon points="137.5,87 134.7,87 173.7,126 176.5,126 "/> + <polygon points="150,87 147.1,87 186.1,126 189,126 "/> + <polygon points="99.1,39 102,39 63,0 60.1,0 "/> + <polygon points="150,74.6 150,77.4 198.6,126 201.4,126 "/> + <polygon points="111.6,39 114.4,39 75.4,0 72.6,0 "/> + <polygon points="150,62.1 150,64.9 211.1,126 213.9,126 "/> + <polygon points="124.1,39 126.9,39 87.9,0 85.1,0 "/> + <polygon points="100.3,0 97.5,0 136.5,39 139.3,39 "/> + <polygon points="150,49.7 150,52.5 223.5,126 225,126 225,124.7 "/> + <polygon points="112.8,0 110,0 149,39 150,39 150,40 225,115 225,112.2 "/> + <polygon points="125.3,0 122.5,0 225,102.5 225,99.7 "/> + <polygon points="137.7,0 134.9,0 225,90.1 225,87.3 "/> + <polygon points="150.2,0 147.4,0 225,77.6 225,74.8 "/> + <polygon points="162.7,0 159.8,0 225,65.2 225,62.3 "/> + <polygon points="175.1,0 172.3,0 225,52.7 225,49.9 "/> + <polygon points="187.6,0 184.8,0 225,40.2 225,37.4 "/> + <polygon points="200.1,0 197.2,0 225,27.8 225,24.9 "/> + <polygon points="212.5,0 209.7,0 225,15.3 225,12.5 "/> + <polygon points="225,0 222.2,0 225,2.8 225,0 "/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> + <path d="M151,88H73V38h78V88z M75,86h74V40H75V86z"/> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-dialog/index.html b/third_party/polymer/v1_0/components/paper-dialog/index.html new file mode 100644 index 0000000..6304b8d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-dialog</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-dialog/paper-dialog.html b/third_party/polymer/v1_0/components/paper-dialog/paper-dialog.html new file mode 100644 index 0000000..002e242 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-dialog/paper-dialog.html @@ -0,0 +1,122 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../neon-animation/neon-animation-runner-behavior.html"> +<link rel="import" href="../paper-dialog-behavior/paper-dialog-behavior.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-dialog>` is a dialog with Material Design styling and optional animations when it is +opened or closed. It provides styles for a header, content area, and an action area for buttons. +You can use the `<paper-dialog-scrollable` element (in its own repository) if you need a scrolling +content area. See `Polymer.PaperDialogBehavior` for specifics. + +For example, the following code implements a dialog with a header, scrolling content area and +buttons. + + <paper-dialog> + <h2>Header</h2> + <paper-dialog-scrollable> + Lorem ipsum... + </paper-dialog-scrollable> + <div class="buttons"> + <paper-button dialog-dismiss>Cancel</paper-button> + <paper-button dialog-confirm>Accept</paper-button> + </div> + </paper-dialog> + +### Styling + +See the docs for `Polymer.PaperDialogBehavior` for the custom properties available for styling +this element. + +### Animations + +Set the `entry-animation` and/or `exit-animation` attributes to add an animation when the dialog +is opened or closed. See the documentation in +[PolymerElements/neon-animation](https://github.com/PolymerElements/neon-animation) for more info. + +For example: + + <link rel="import" href="components/neon-animation/animations/scale-up-animation.html"> + <link rel="import" href="components/neon-animation/animations/fade-out-animation.html"> + + <paper-dialog entry-animation="scale-up-animation" + exit-animation="fade-out-animation"> + <h2>Header</h2> + <div>Dialog body</div> + </paper-dialog> + +### Accessibility + +See the docs for `Polymer.PaperDialogBehavior` for accessibility features implemented by this +element. + +@group Paper Elements +@element paper-dialog +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-dialog"> + + <link rel="import" type="css" href="../paper-dialog-behavior/paper-dialog-common.css"> + + <template> + <content></content> + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-dialog', + + behaviors: [ + Polymer.PaperDialogBehavior, + Polymer.NeonAnimationRunnerBehavior + ], + + listeners: { + 'neon-animation-finish': '_onNeonAnimationFinish' + }, + + _renderOpened: function() { + if (this.withBackdrop) { + this.backdropElement.open(); + } + this.playAnimation('entry'); + }, + + _renderClosed: function() { + if (this.withBackdrop) { + this.backdropElement.close(); + } + this.playAnimation('exit'); + }, + + _onNeonAnimationFinish: function() { + if (this.opened) { + this._finishRenderOpened(); + } else { + this._finishRenderClosed(); + } + } + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/.bower.json b/third_party/polymer/v1_0/components/paper-drawer-panel/.bower.json new file mode 100644 index 0000000..f226642 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/.bower.json @@ -0,0 +1,42 @@ +{ + "name": "paper-drawer-panel", + "version": "1.0.1", + "description": "A responsive drawer panel", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "drawer", + "responsive", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-drawer-panel.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-drawer-panel", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "6294619b9eb3a9346854daef1b00fb3342dffef9" + }, + "_source": "git://github.com/PolymerElements/paper-drawer-panel.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-drawer-panel" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/.gitignore b/third_party/polymer/v1_0/components/paper-drawer-panel/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/README.md b/third_party/polymer/v1_0/components/paper-drawer-panel/README.md new file mode 100644 index 0000000..2828663 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/README.md @@ -0,0 +1,71 @@ +# paper-drawer-panel + +`paper-drawer-panel` contains a drawer panel and a main panel. The drawer +and the main panel are side-by-side with drawer on the left. When the browser +window size is smaller than the `responsiveWidth`, `paper-drawer-panel` +changes to narrow layout. In narrow layout, the drawer will be stacked on top +of the main panel. The drawer will slide in/out to hide/reveal the main +panel. + +Use the attribute `drawer` to indicate that the element is the drawer panel and +`main` to indicate that the element is the main panel. + +Example: + +```html +<paper-drawer-panel> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> +</paper-drawer-panel> +``` + +The drawer and the main panels are not scrollable. You can set CSS overflow +property on the elements to make them scrollable or use `paper-header-panel`. + +Example: + +```html +<paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar></paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar></paper-toolbar> + <div> Main content... </div> + </paper-header-panel> +</paper-drawer-panel> +``` + +An element that should toggle the drawer will automatically do so if it's +given the `paper-drawer-toggle` attribute. Also this element will automatically +be hidden in wide layout. + +Example: + +```html +<paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar> + <div>Application</div> + </paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar> + <paper-icon-button icon="menu" paper-drawer-toggle></paper-icon-button> + <div>Title</div> + </paper-toolbar> + <div> Main content... </div> + </paper-header-panel> +</paper-drawer-panel> +``` + +To position the drawer to the right, add `right-drawer` attribute. + +```html +<paper-drawer-panel right-drawer> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> +</paper-drawer-panel> +``` diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/bower.json b/third_party/polymer/v1_0/components/paper-drawer-panel/bower.json new file mode 100644 index 0000000..52edc76 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/bower.json @@ -0,0 +1,33 @@ +{ + "name": "paper-drawer-panel", + "version": "1.0.1", + "description": "A responsive drawer panel", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "drawer", + "responsive", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-drawer-panel.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-drawer-panel", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/hero.svg b/third_party/polymer/v1_0/components/paper-drawer-panel/hero.svg new file mode 100644 index 0000000..5dfef36 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/hero.svg @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M175,102H61V24h114V102z M63,100h110V26H63V100z"/> + <path d="M91,102H61V24h30V102z M63,100h26V26H63V100z"/> + <circle cx="123" cy="63" r="4"/> + <rect x="90" y="62" width="33" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/index.html b/third_party/polymer/v1_0/components/paper-drawer-panel/index.html new file mode 100644 index 0000000..1390ecc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-drawer-panel</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/paper-drawer-panel.css b/third_party/polymer/v1_0/components/paper-drawer-panel/paper-drawer-panel.css new file mode 100644 index 0000000..ab7c568 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/paper-drawer-panel.css @@ -0,0 +1,142 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + +*/ +:host { + display: block; + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + overflow: hidden; +} + +iron-selector > #drawer { + position: absolute; + top: 0; + left: 0; + height: 100%; + background-color: white; + will-change: transform; + box-sizing: border-box; + -moz-box-sizing: border-box; + + @apply(--paper-drawer-panel-drawer-container); +} + +.transition > #drawer { + transition: -webkit-transform ease-in-out 0.3s, width ease-in-out 0.3s; + transition: transform ease-in-out 0.3s, width ease-in-out 0.3s; +} + +.left-drawer > #drawer { + @apply(--paper-drawer-panel-left-drawer-container); +} + +.right-drawer > #drawer { + left: auto; + right: 0; + + @apply(--paper-drawer-panel-right-drawer-container); +} + +iron-selector > #main { + position: absolute; + top: 0; + right: 0; + bottom: 0; + + @apply(--paper-drawer-panel-main-container); +} + +.transition > #main { + transition: left ease-in-out 0.3s, padding ease-in-out 0.3s; +} + +.right-drawer > #main { + left: 0; +} + +.right-drawer.transition > #main { + transition: right ease-in-out 0.3s, padding ease-in-out 0.3s; +} + +#main > ::content > [main] { + height: 100%; +} + +#drawer > ::content > [drawer] { + height: 100%; +} + +#scrim { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + visibility: hidden; + opacity: 0; + transition: opacity ease-in-out 0.38s, visibility ease-in-out 0.38s; + background-color: rgba(0, 0, 0, 0.3); +} + +.narrow-layout > #drawer.iron-selected { + box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.15); +} + +.right-drawer.narrow-layout > #drawer.iron-selected { + box-shadow: -2px 2px 4px rgba(0, 0, 0, 0.15); +} + +.narrow-layout > #drawer > ::content > [drawer] { + border: 0; +} + +.left-drawer.narrow-layout > #drawer:not(.iron-selected) { + -webkit-transform: translateX(-100%); + transform: translateX(-100%); +} + +.right-drawer.narrow-layout > #drawer:not(.iron-selected) { + left: auto; + -webkit-transform: translateX(100%); + transform: translateX(100%); +} + +.narrow-layout > #main { + left: 0 !important; + padding: 0; +} + +.right-drawer.narrow-layout > #main { + left: 0; + right: 0; + padding: 0; +} + +.narrow-layout > #main:not(.iron-selected) > #scrim, +.dragging > #main > #scrim { + visibility: visible; + opacity: var(--paper-drawer-panel-scrim-opacity, 1); +} + +.narrow-layout > #main > * { + margin: 0; + min-height: 100%; + left: 0; + right: 0; + box-sizing: border-box; + -moz-box-sizing: border-box; +} + +iron-selector:not(.narrow-layout) #main ::content [paper-drawer-toggle] { + display: none; +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-drawer-panel/paper-drawer-panel.html b/third_party/polymer/v1_0/components/paper-drawer-panel/paper-drawer-panel.html new file mode 100644 index 0000000..758d88a --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-drawer-panel/paper-drawer-panel.html @@ -0,0 +1,585 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-media-query/iron-media-query.html"> +<link rel="import" href="../iron-selector/iron-selector.html"> + +<!-- +`paper-drawer-panel` contains a drawer panel and a main panel. The drawer +and the main panel are side-by-side with drawer on the left. When the browser +window size is smaller than the `responsiveWidth`, `paper-drawer-panel` +changes to narrow layout. In narrow layout, the drawer will be stacked on top +of the main panel. The drawer will slide in/out to hide/reveal the main +panel. + +Use the attribute `drawer` to indicate that the element is the drawer panel and +`main` to indicate that the element is the main panel. + +Example: + + <paper-drawer-panel> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> + </paper-drawer-panel> + +The drawer and the main panels are not scrollable. You can set CSS overflow +property on the elements to make them scrollable or use `paper-header-panel`. + +Example: + + <paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar></paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar></paper-toolbar> + <div> Main content... </div> + </paper-header-panel> + </paper-drawer-panel> + +An element that should toggle the drawer will automatically do so if it's +given the `paper-drawer-toggle` attribute. Also this element will automatically +be hidden in wide layout. + +Example: + + <paper-drawer-panel> + <paper-header-panel drawer> + <paper-toolbar> + <div>Application</div> + </paper-toolbar> + <div> Drawer content... </div> + </paper-header-panel> + <paper-header-panel main> + <paper-toolbar> + <paper-icon-button icon="menu" paper-drawer-toggle></paper-icon-button> + <div>Title</div> + </paper-toolbar> + <div> Main content... </div> + </paper-header-panel> + </paper-drawer-panel> + +To position the drawer to the right, add `right-drawer` attribute. + + <paper-drawer-panel right-drawer> + <div drawer> Drawer panel... </div> + <div main> Main panel... </div> + </paper-drawer-panel> + +Styling paper-drawer-panel: + +To change the main container: + paper-drawer-panel { + --paper-drawer-panel-main-container: { + background-color: gray; + }; + } + +To change the drawer container when it's in the left side: + paper-drawer-panel { + --paper-drawer-panel-left-drawer-container: { + background-color: white; + }; + } + +To change the drawer container when it's in the right side: + + paper-drawer-panel { + --paper-drawer-panel-right-drawer-container: { + background-color: white; + }; + } + +@group Paper elements +@element paper-drawer-panel +@demo demo/index.html +@hero hero.svg +--> + +<dom-module id="paper-drawer-panel"> + <link rel="import" type="css" href="paper-drawer-panel.css"> + + <template> + <iron-media-query + id="mq" + on-query-matches-changed="_onQueryMatchesChanged" + query="[[_computeMediaQuery(forceNarrow, responsiveWidth)]]"> + </iron-media-query> + + <iron-selector + attr-for-selected="id" + class$="[[_computeIronSelectorClass(narrow, transition, dragging, rightDrawer)]]" + activate-event="" + selected="[[selected]]"> + + <div id="main" style$="[[_computeMainStyle(narrow, rightDrawer, drawerWidth)]]"> + <content select="[main]"></content> + <div id="scrim" on-tap="closeDrawer"></div> + </div> + + <div id="drawer" style$="[[_computeDrawerStyle(drawerWidth)]]"> + <content select="[drawer]"></content> + </div> + + </iron-selector> + </template> + +</dom-module> + +<script> + + (function() { + + 'use strict'; + + // this would be the only `paper-drawer-panel` in + // the whole app that can be in `dragging` state + var sharedPanel = null; + + function classNames(obj) { + var classes = []; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key]) { + classes.push(key); + } + } + + return classes.join(' '); + } + + Polymer({ + + is: 'paper-drawer-panel', + + /** + * Fired when the narrow layout changes. + * + * @event paper-responsive-change {{narrow: boolean}} detail - + * narrow: true if the panel is in narrow layout. + */ + + /** + * Fired when the selected panel changes. + * + * Listening for this event is an alternative to observing changes in the `selected` attribute. + * This event is fired both when a panel is selected and deselected. + * The `isSelected` detail property contains the selection state. + * + * @event paper-select {{isSelected: boolean, item: Object}} detail - + * isSelected: True for selection and false for deselection. + * item: The panel that the event refers to. + */ + + properties: { + + /** + * The panel to be selected when `paper-drawer-panel` changes to narrow + * layout. + */ + defaultSelected: { + type: String, + value: 'main' + }, + + /** + * If true, swipe from the edge is disable. + */ + disableEdgeSwipe: { + type: Boolean, + value: false + }, + + /** + * If true, swipe to open/close the drawer is disabled. + */ + disableSwipe: { + type: Boolean, + value: false + }, + + /** + * Whether the user is dragging the drawer interactively. + */ + dragging: { + type: Boolean, + value: false + }, + + /** + * Width of the drawer panel. + */ + drawerWidth: { + type: String, + value: '256px' + }, + + /** + * How many pixels on the side of the screen are sensitive to edge + * swipes and peek. + */ + edgeSwipeSensitivity: { + type: Number, + value: 30 + }, + + /** + * If true, ignore `responsiveWidth` setting and force the narrow layout. + */ + forceNarrow: { + type: Boolean, + value: false + }, + + /** + * Whether the browser has support for the transform CSS property. + */ + hasTransform: { + type: Boolean, + value: function() { + return 'transform' in this.style; + } + }, + + /** + * Whether the browser has support for the will-change CSS property. + */ + hasWillChange: { + type: Boolean, + value: function() { + return 'willChange' in this.style; + } + }, + + /** + * Returns true if the panel is in narrow layout. This is useful if you + * need to show/hide elements based on the layout. + */ + narrow: { + reflectToAttribute: true, + type: Boolean, + value: false, + notify: true + }, + + /** + * Whether the drawer is peeking out from the edge. + */ + peeking: { + type: Boolean, + value: false + }, + + /** + * Max-width when the panel changes to narrow layout. + */ + responsiveWidth: { + type: String, + value: '640px' + }, + + /** + * If true, position the drawer to the right. + */ + rightDrawer: { + type: Boolean, + value: false + }, + + /** + * The panel that is being selected. `drawer` for the drawer panel and + * `main` for the main panel. + */ + selected: { + reflectToAttribute: true, + type: String, + value: null + }, + + /** + * The attribute on elements that should toggle the drawer on tap, also elements will + * automatically be hidden in wide layout. + */ + drawerToggleAttribute: { + type: String, + value: 'paper-drawer-toggle' + }, + + /** + * Whether the transition is enabled. + */ + transition: { + type: Boolean, + value: false + }, + + }, + + listeners: { + tap: '_onTap', + track: '_onTrack', + down: '_downHandler', + up: '_upHandler' + }, + + observers: [ + '_forceNarrowChanged(forceNarrow, defaultSelected)' + ], + + /** + * Toggles the panel open and closed. + * + * @method togglePanel + */ + togglePanel: function() { + if (this._isMainSelected()) { + this.openDrawer(); + } else { + this.closeDrawer(); + } + }, + + /** + * Opens the drawer. + * + * @method openDrawer + */ + openDrawer: function() { + this.selected = 'drawer'; + }, + + /** + * Closes the drawer. + * + * @method closeDrawer + */ + closeDrawer: function() { + this.selected = 'main'; + }, + + ready: function() { + // Avoid transition at the beginning e.g. page loads and enable + // transitions only after the element is rendered and ready. + this.transition = true; + }, + + _computeIronSelectorClass: function(narrow, transition, dragging, rightDrawer) { + return classNames({ + dragging: dragging, + 'narrow-layout': narrow, + 'right-drawer': rightDrawer, + 'left-drawer': !rightDrawer, + transition: transition + }); + }, + + _computeDrawerStyle: function(drawerWidth) { + return 'width:' + drawerWidth + ';'; + }, + + _computeMainStyle: function(narrow, rightDrawer, drawerWidth) { + var style = ''; + + style += 'left:' + ((narrow || rightDrawer) ? '0' : drawerWidth) + ';'; + + if (rightDrawer) { + style += 'right:' + (narrow ? '' : drawerWidth) + ';'; + } else { + style += 'right:;'; + } + + return style; + }, + + _computeMediaQuery: function(forceNarrow, responsiveWidth) { + return forceNarrow ? '' : '(max-width: ' + responsiveWidth + ')'; + }, + + _computeSwipeOverlayHidden: function(narrow, disableEdgeSwipe) { + return !narrow || disableEdgeSwipe; + }, + + _onTrack: function(e) { + if (sharedPanel && this !== sharedPanel) { + return; + } + switch (e.detail.state) { + case 'start': + this._trackStart(e); + break; + case 'track': + this._trackX(e); + break; + case 'end': + this._trackEnd(e); + break; + } + + }, + + _responsiveChange: function(narrow) { + this.narrow = narrow; + + if (this.narrow) { + this.selected = this.defaultSelected; + } + + this.setScrollDirection(this._swipeAllowed() ? 'y' : 'all'); + this.fire('paper-responsive-change', {narrow: this.narrow}); + }, + + _onQueryMatchesChanged: function(e) { + this._responsiveChange(e.detail.value); + }, + + _forceNarrowChanged: function() { + // set the narrow mode only if we reached the `responsiveWidth` + this._responsiveChange(this.forceNarrow || this.$.mq.queryMatches); + }, + + _swipeAllowed: function() { + return this.narrow && !this.disableSwipe; + }, + + _isMainSelected: function() { + return this.selected === 'main'; + }, + + _startEdgePeek: function() { + this.width = this.$.drawer.offsetWidth; + this._moveDrawer(this._translateXForDeltaX(this.rightDrawer ? + -this.edgeSwipeSensitivity : this.edgeSwipeSensitivity)); + this.peeking = true; + }, + + _stopEdgePeek: function() { + if (this.peeking) { + this.peeking = false; + this._moveDrawer(null); + } + }, + + _downHandler: function(e) { + if (!this.dragging && this._isMainSelected() && this._isEdgeTouch(e) && !sharedPanel) { + this._startEdgePeek(); + // grab this panel + sharedPanel = this; + } + }, + + _upHandler: function() { + this._stopEdgePeek(); + // release the panel + sharedPanel = null; + }, + + _onTap: function(e) { + var targetElement = Polymer.dom(e).localTarget; + var isTargetToggleElement = targetElement && + this.drawerToggleAttribute && + targetElement.hasAttribute(this.drawerToggleAttribute); + + if (isTargetToggleElement) { + this.togglePanel(); + } + }, + + _isEdgeTouch: function(e) { + var x = e.detail.x; + + return !this.disableEdgeSwipe && this._swipeAllowed() && + (this.rightDrawer ? + x >= this.offsetWidth - this.edgeSwipeSensitivity : + x <= this.edgeSwipeSensitivity); + }, + + _trackStart: function() { + if (this._swipeAllowed()) { + sharedPanel = this; + this.dragging = true; + + if (this._isMainSelected()) { + this.dragging = this.peeking || this._isEdgeTouch(event); + } + + if (this.dragging) { + this.width = this.$.drawer.offsetWidth; + this.transition = false; + } + } + }, + + _translateXForDeltaX: function(deltaX) { + var isMain = this._isMainSelected(); + + if (this.rightDrawer) { + return Math.max(0, isMain ? this.width + deltaX : deltaX); + } else { + return Math.min(0, isMain ? deltaX - this.width : deltaX); + } + }, + + _trackX: function(e) { + if (this.dragging) { + var dx = e.detail.dx; + + if (this.peeking) { + if (Math.abs(dx) <= this.edgeSwipeSensitivity) { + // Ignore trackx until we move past the edge peek. + return; + } + this.peeking = false; + } + + this._moveDrawer(this._translateXForDeltaX(dx)); + } + }, + + _trackEnd: function(e) { + if (this.dragging) { + var xDirection = e.detail.dx > 0; + + this.dragging = false; + this.transition = true; + sharedPanel = null; + this._moveDrawer(null); + + if (this.rightDrawer) { + this[xDirection ? 'closeDrawer' : 'openDrawer'](); + } else { + this[xDirection ? 'openDrawer' : 'closeDrawer'](); + } + } + }, + + _transformForTranslateX: function(translateX) { + if (translateX === null) { + return ''; + } + + return this.hasWillChange ? 'translateX(' + translateX + 'px)' : + 'translate3d(' + translateX + 'px, 0, 0)'; + }, + + _moveDrawer: function(translateX) { + var s = this.$.drawer.style; + + if (this.hasTransform) { + s.transform = this._transformForTranslateX(translateX); + } else { + s.webkitTransform = this._transformForTranslateX(translateX); + } + } + + }); + + }()); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-elements/.bower.json b/third_party/polymer/v1_0/components/paper-elements/.bower.json new file mode 100644 index 0000000..5bfdd28 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-elements/.bower.json @@ -0,0 +1,60 @@ +{ + "name": "paper-elements", + "version": "1.0.1", + "homepage": "https://github.com/PolymerElements/paper-elements", + "authors": [ + "The Polymer Authors" + ], + "description": "Paper elements are a set of visual elements that implement Google's Material Design.", + "main": "paper-elements.html", + "keywords": [ + "web-components", + "polymer", + "paper" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-dialog": "PolymerElements/paper-dialog#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "paper-drawer-panel": "PolymerElements/paper-drawer-panel#^1.0.0", + "paper-fab": "PolymerElements/paper-fab#^1.0.0", + "paper-header-panel": "PolymerElements/paper-header-panel#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-menu": "PolymerElements/paper-menu#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-radio-group": "PolymerElements/paper-radio-group#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-slider": "PolymerElements/paper-slider#^1.0.0", + "paper-spinner": "PolymerElements/paper-spinner#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-tabs": "PolymerElements/paper-tabs#^1.0.0", + "paper-toast": "PolymerElements/paper-toast#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "paper-scroll-header-panel": "PolymerElements/paper-scroll-header-panel#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "c4b7d791a9a7cfec9d671a34112c97a0dad5de69" + }, + "_source": "git://github.com/PolymerElements/paper-elements.git", + "_target": "~1.0.0", + "_originalSource": "PolymerElements/paper-elements" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-elements/README.md b/third_party/polymer/v1_0/components/paper-elements/README.md new file mode 100644 index 0000000..300275c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-elements/README.md @@ -0,0 +1,21 @@ +#paper-elements + +The paper elements are a set of UI components designed to implement Google's [material design](http://www.google.com/design/spec/material-design/introduction.html) guidelines. + +## Roadmap + +### Elements in progress + +* `paper-dropdown-menu` - a dropdown menu + +### Elements planned +_Elements we're planning on building soon but haven't started yet_ + +* `paper-tooltip` - a hover tooltip + +[Currently focused on getting all elements up to speed] + +### Elements not planned, notably +_Elements we're not planning on building as part of this product line, but that one might be wondering about_ + +[None] diff --git a/third_party/polymer/v1_0/components/paper-elements/bower.json b/third_party/polymer/v1_0/components/paper-elements/bower.json new file mode 100644 index 0000000..34083c3 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-elements/bower.json @@ -0,0 +1,51 @@ +{ + "name": "paper-elements", + "version": "1.0.1", + "homepage": "https://github.com/PolymerElements/paper-elements", + "authors": [ + "The Polymer Authors" + ], + "description": "Paper elements are a set of visual elements that implement Google's Material Design.", + "main": "paper-elements.html", + "keywords": [ + "web-components", + "polymer", + "paper" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-dialog": "PolymerElements/paper-dialog#^1.0.0", + "paper-dialog-behavior": "PolymerElements/paper-dialog-behavior#^1.0.0", + "paper-dialog-scrollable": "PolymerElements/paper-dialog-scrollable#^1.0.0", + "paper-drawer-panel": "PolymerElements/paper-drawer-panel#^1.0.0", + "paper-fab": "PolymerElements/paper-fab#^1.0.0", + "paper-header-panel": "PolymerElements/paper-header-panel#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "paper-material": "PolymerElements/paper-material#^1.0.0", + "paper-menu": "PolymerElements/paper-menu#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-radio-group": "PolymerElements/paper-radio-group#^1.0.0", + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-slider": "PolymerElements/paper-slider#^1.0.0", + "paper-spinner": "PolymerElements/paper-spinner#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-tabs": "PolymerElements/paper-tabs#^1.0.0", + "paper-toast": "PolymerElements/paper-toast#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "paper-scroll-header-panel": "PolymerElements/paper-scroll-header-panel#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-fab/.bower.json b/third_party/polymer/v1_0/components/paper-fab/.bower.json new file mode 100644 index 0000000..4fe9c9f --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-fab/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-fab", + "version": "1.0.1", + "description": "A material design floating action button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button" + ], + "main": "paper-fab.html", + "ignore": [], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-fab" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-fab", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "3c626a4d116d774e9f4db3a3e0f92b0c8148f12e" + }, + "_source": "git://github.com/PolymerElements/paper-fab.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-fab" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-fab/.gitignore b/third_party/polymer/v1_0/components/paper-fab/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-fab/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-fab/README.md b/third_party/polymer/v1_0/components/paper-fab/README.md new file mode 100644 index 0000000..5da43e2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-fab/README.md @@ -0,0 +1,44 @@ +paper-fab +========= + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Button</a> + +`paper-fab` is a floating action button. It contains an image placed in the center and +comes in two sizes: regular size and a smaller size by applying the attribute `mini`. When +the user touches the button, a ripple effect emanates from the center of the button. + +You may import `iron-icons` to use with this element, or provide a URL to a custom icon. +See `iron-iconset` for more information about how to use a custom icon set. + +Example: + +```html +<link href="path/to/iron-icons/iron-icons.html" rel="import"> + +<paper-fab icon="add"></paper-fab> +<paper-fab mini icon="favorite"></paper-fab> +<paper-fab src="star.png"></paper-fab> +``` + +Styling +------- + +Style the button with CSS as you would a normal DOM element. If you are using the icons +provided by `iron-icons`, the icon will inherit the foreground color of the button. + +```html +<!-- make a blue "cloud" button --> +<paper-fab icon="cloud" style="color: blue;"></paper-fab> +``` + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + +```css +/* make #my-button use a blue ripple instead of foreground color */ +#my-button::shadow #ripple { + color: blue; +} +``` + +The opacity of the ripple is not customizable via CSS. diff --git a/third_party/polymer/v1_0/components/paper-fab/bower.json b/third_party/polymer/v1_0/components/paper-fab/bower.json new file mode 100644 index 0000000..b195ccb --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-fab/bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-fab", + "version": "1.0.1", + "description": "A material design floating action button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button" + ], + "main": "paper-fab.html", + "ignore": [], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-fab" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-fab", + "dependencies": { + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-material": "polymerelements/paper-material#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-fab/index.html b/third_party/polymer/v1_0/components/paper-fab/index.html new file mode 100644 index 0000000..c98a658 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-fab/index.html @@ -0,0 +1,24 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>paper-fab</title> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-fab/paper-fab.html b/third_party/polymer/v1_0/components/paper-fab/paper-fab.html new file mode 100644 index 0000000..16e5de1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-fab/paper-fab.html @@ -0,0 +1,159 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-styles/color.html"> +<link rel="import" href="../paper-material/paper-material.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-behaviors/paper-button-behavior.html"> + +<!-- +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Button</a> + +`paper-fab` is a floating action button. It contains an image placed in the center and +comes in two sizes: regular size and a smaller size by applying the attribute `mini`. When +the user touches the button, a ripple effect emanates from the center of the button. + +You may import `iron-icons` to use with this element, or provide a URL to a custom icon. +See `iron-iconset` for more information about how to use a custom icon set. + +Example: + + <link href="path/to/iron-icons/iron-icons.html" rel="import"> + + <paper-fab icon="add"></paper-fab> + <paper-fab mini icon="favorite"></paper-fab> + <paper-fab src="star.png"></paper-fab> + + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-fab-background` | The background color of the button | `--paper-indigo-500` +`--paper-fab-disabled-background` | The background color of the button when it's disabled | `--paper-grey-300` +`--paper-fab-disabled-text` | The text color of the button when it's disabled | `--paper-grey-500` +`--paper-fab` | Mixin applied to the button | `{}` +`--paper-fab-mini` | Mixin applied to a mini button | `{}` +`--paper-fab-disabled` | Mixin applied to a disabled button | `{}` + +@group Paper Elements +@demo demo/index.html + +--> + +<dom-module id="paper-fab"> + <style> + + :host { + display: inline-block; + position: relative; + outline: none; + -moz-user-select: none; + -ms-user-select: none; + -webkit-user-select: none; + user-select: none; + cursor: pointer; + + box-sizing: border-box; + min-width: 0; + width: 56px; + height: 56px; + background: var(--paper-fab-background, --paper-indigo-500); + color: var(--text-primary-color); + border-radius: 50%; + padding: 16px; + + z-index: 0; + + @apply(--paper-fab); + } + + :host([mini]) { + width: 40px; + height: 40px; + padding: 8px; + + @apply(--paper-fab-mini); + } + + :host([disabled]) { + color: var(--paper-fab-disabled-text, --paper-grey-500); + background: var(--paper-fab-disabled-background, --paper-grey-300); + @apply(--paper-fab-disabled); + } + + paper-material { + border-radius: inherit; + } + </style> + <template> + <paper-ripple></paper-ripple> + <paper-material class="content fit flex layout vertical center-center" elevation="[[elevation]]" animated> + <iron-icon id="icon" src="[[src]]" icon="[[icon]]"></iron-icon> + </paper-material> + </template> +</dom-module> +<script> + Polymer({ + is: 'paper-fab', + + behaviors: [ + Polymer.PaperButtonBehavior + ], + + properties: { + /** + * The URL of an image for the icon. If the src property is specified, + * the icon property should not be. + * + * @attribute src + * @type string + * @default '' + */ + src: { + type: String, + value: '' + }, + + /** + * Specifies the icon name or index in the set of icons available in + * the icon's icon set. If the icon property is specified, + * the src property should not be. + * + * @attribute icon + * @type string + * @default '' + */ + icon: { + type: String, + value: '' + }, + + /** + * Set this to true to style this is a "mini" FAB. + * + * @attribute mini + * @type boolean + * @default false + */ + mini: { + type: Boolean, + value: false + } + } + + }); +</script> diff --git a/third_party/polymer/v1_0/components/paper-header-panel/.bower.json b/third_party/polymer/v1_0/components/paper-header-panel/.bower.json new file mode 100644 index 0000000..394924f --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/.bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-header-panel", + "version": "1.0.1", + "description": "A header and content wrapper for layout with headers", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-header-panel", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "ec388b9579fe61ce84e498132cd33ec275e8e398" + }, + "_source": "git://github.com/PolymerElements/paper-header-panel.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-header-panel" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-header-panel/.gitignore b/third_party/polymer/v1_0/components/paper-header-panel/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-header-panel/README.md b/third_party/polymer/v1_0/components/paper-header-panel/README.md new file mode 100644 index 0000000..aab76e6 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/README.md @@ -0,0 +1,105 @@ +# paper-header-panel + +`paper-header-panel` contains a header section and a content panel section. + +__Important:__ The `paper-header-panel` will not display if its parent does not have a height. + +Using [layout classes](http://www.polymer-project.org/docs/polymer/layout-attrs.html), you can make +the `paper-header-panel` fill the screen + +```html +<body class="fullbleed layout vertical"> + <paper-header-panel class="flex"> + <paper-toolbar> + <div>Hello World!</div> + </paper-toolbar> + </paper-header-panel> +</body> +``` + +Special support is provided for scrolling modes when one uses a `paper-toolbar` or equivalent for the header section. For example: + +```html +<paper-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> +</paper-header-panel> +``` + +If you want to use other than `paper-toolbar` for the header, add `paper-header` class to that +element: + +```html +<paper-header-panel> + <div class="paper-header">Header</div> + <div>Content goes here...</div> +</paper-header-panel> +``` + +To have the content fit to the main area, use the `fit` class: + +```html +<paper-header-panel> + <div class="paper-header">standard</div> + <div class="content fit">content fits 100% below the header</div> +</paper-header-panel> +``` + +### Mode + +Controls header and scrolling behavior. Options are `standard`, `seamed`, `waterfall`, `waterfall-tall`, `scroll` and +`cover`. Default is `standard`. + +Mode | Description +----------------|------------- +`standard` | The header is a step above the panel. The header will consume the panel at the point of entry, preventing it from passing through to the opposite side. +`seamed` | The header is presented as seamed with the panel. +`waterfall` | Similar to standard mode, but header is initially presented as seamed with panel, but then separates to form the step. +`waterfall-tall` | The header is initially taller (`tall` class is added to the header). As the user scrolls, the header separates (forming an edge) while condensing (`tall` class is removed from the header). +`scroll` | The header keeps its seam with the panel, and is pushed off screen. +`cover` | The panel covers the whole `paper-header-panel` including the header. This allows user to style the panel in such a way that the panel is partially covering the header. + +Example: + +```html +<paper-header-panel mode="waterfall"> + <div class="paper-header">standard</div> + <div class="content fit">content fits 100% below the header</div> +</paper-header-panel> +``` + +### Styling header panel: + +To change the shadow that shows up underneath the header: + +```css +paper-header-panel { + --paper-header-panel-shadow: { + height: 6px; + bottom: -6px; + box-shadow: inset 0px 5px 6px -3px rgba(0, 0, 0, 0.4); + }; +} +``` + +To change the panel container: + +```css +paper-slider { + --paper-header-panel-standard-container: { + border: 1px solid gray; + }; + + --paper-header-panel-cover-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-tall-container: { + border: 1px solid gray; + }; +} +``` diff --git a/third_party/polymer/v1_0/components/paper-header-panel/bower.json b/third_party/polymer/v1_0/components/paper-header-panel/bower.json new file mode 100644 index 0000000..57314e7 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/bower.json @@ -0,0 +1,28 @@ +{ + "name": "paper-header-panel", + "version": "1.0.1", + "description": "A header and content wrapper for layout with headers", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "layout" + ], + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-header-panel", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-header-panel/hero.svg b/third_party/polymer/v1_0/components/paper-header-panel/hero.svg new file mode 100644 index 0000000..60c7488 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/hero.svg @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M163,102H73V24h90V102z M75,100h86V26H75V100z"/> + <g> + <polygon points="74,59.6 74,62.5 74.5,63 77.4,63 "/> + <polygon points="74,51.9 74,54.7 82.3,63 85.1,63 "/> + <polygon points="74,44.1 74,46.9 90.1,63 92.9,63 "/> + <polygon points="74,36.3 74,39.2 97.8,63 100.7,63 "/> + <polygon points="74,28.6 74,31.4 105.6,63 108.4,63 "/> + <polygon points="78.2,25 75.4,25 113.4,63 116.2,63 "/> + <polygon points="86,25 83.1,25 121.1,63 124,63 "/> + <polygon points="93.7,25 90.9,25 128.9,63 131.7,63 "/> + <polygon points="101.5,25 98.7,25 136.7,63 139.5,63 "/> + <polygon points="109.2,25 106.4,25 144.4,63 147.2,63 "/> + <polygon points="117,25 114.2,25 152.2,63 155,63 "/> + <polygon points="124.8,25 122,25 160,63 162,63 162,62.2 "/> + <polygon points="132.5,25 129.7,25 162,57.3 162,54.5 "/> + <polygon points="140.3,25 137.5,25 162,49.5 162,46.7 "/> + <polygon points="148.1,25 145.2,25 162,41.8 162,38.9 "/> + <polygon points="155.8,25 153,25 162,34 162,31.2 "/> + <polygon points="162,26.2 162,25 160.8,25 "/> + </g> + <rect x="74" y="62" width="88" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-header-panel/index.html b/third_party/polymer/v1_0/components/paper-header-panel/index.html new file mode 100644 index 0000000..8d0771c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/index.html @@ -0,0 +1,36 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-header-panel</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + <style> + body { + margin: 16px; + } + </style> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-header-panel/paper-header-panel.html b/third_party/polymer/v1_0/components/paper-header-panel/paper-header-panel.html new file mode 100644 index 0000000..8ce83ac --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-header-panel/paper-header-panel.html @@ -0,0 +1,496 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> + +<!-- +`paper-header-panel` contains a header section and a content panel section. + +__Important:__ The `paper-header-panel` will not display if its parent does not have a height. + +Using layout classes, you can make the `paper-header-panel` fill the screen + + <body class="fullbleed layout vertical"> + <paper-header-panel class="flex"> + <paper-toolbar> + <div>Hello World!</div> + </paper-toolbar> + </paper-header-panel> + </body> + +Special support is provided for scrolling modes when one uses a paper-toolbar or equivalent for the +header section. + +Example: + + <paper-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> + </paper-header-panel> + +If you want to use other than `paper-toolbar` for the header, add `paper-header` class to that +element. + +Example: + + <paper-header-panel> + <div class="paper-header">Header</div> + <div>Content goes here...</div> + </paper-header-panel> + +To have the content fit to the main area, use the `fit` class. + + <paper-header-panel> + <div class="paper-header">standard</div> + <div class="fit">content fits 100% below the header</div> + </paper-header-panel> + +Modes + +Controls header and scrolling behavior. Options are `standard`, `seamed`, `waterfall`, `waterfall-tall`, `scroll` and +`cover`. Default is `standard`. + +Mode | Description +----------------|------------- +`standard` | The header is a step above the panel. The header will consume the panel at the point of entry, preventing it from passing through to the opposite side. +`seamed` | The header is presented as seamed with the panel. +`waterfall` | Similar to standard mode, but header is initially presented as seamed with panel, but then separates to form the step. +`waterfall-tall` | The header is initially taller (`tall` class is added to the header). As the user scrolls, the header separates (forming an edge) while condensing (`tall` class is removed from the header). +`scroll` | The header keeps its seam with the panel, and is pushed off screen. +`cover` | The panel covers the whole `paper-header-panel` including the header. This allows user to style the panel in such a way that the panel is partially covering the header. + +Example: + + <paper-header-panel mode="waterfall"> + <div class="paper-header">standard</div> + <div class="content fit">content fits 100% below the header</div> + </paper-header-panel> + + +Styling header panel: + +To change the shadow that shows up underneath the header: + + paper-header-panel { + --paper-header-panel-shadow: { + height: 6px; + bottom: -6px; + box-shadow: inset 0px 5px 6px -3px rgba(0, 0, 0, 0.4); + }; + } + +To change the panel container in different modes: + + paper-slider { + --paper-header-panel-standard-container: { + border: 1px solid gray; + }; + + --paper-header-panel-cover-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-container: { + border: 1px solid gray; + }; + + --paper-header-panel-waterfall-tall-container: { + border: 1px solid gray; + }; + } + +@group Paper Elements +@element paper-header-panel +@demo demo/index.html +@hero hero.svg +--> + +<dom-module id="paper-header-panel"> + + <style> + :host { + @apply(--layout); + @apply(--layout-vertical); + + display: block; + position: relative; + height: 100%; + + /* Create a stack context, we will need it for the shadow*/ + z-index: 0; + } + + #mainContainer { + @apply(--layout-flex); + + position: relative; + overflow-y: auto; + overflow-x: hidden; + -webkit-overflow-scrolling: touch; + flex-basis: 0.0001px; + } + + /* + * mode: scroll + */ + :host([mode=scroll]) #mainContainer { + @apply(--paper-header-panel-scroll-container); + overflow: visible; + } + + :host([mode=scroll]) { + overflow-y: auto; + overflow-x: hidden; + -webkit-overflow-scrolling: touch; + } + + /* + * mode: cover + */ + :host([mode=cover]) #mainContainer { + @apply(--paper-header-panel-cover-container); + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + /* + * mode: standard + */ + :host([mode=standard]) #mainContainer { + @apply(--paper-header-panel-standard-container); + } + + /* + * mode: waterfall + */ + :host([mode=waterfall]) #mainContainer { + @apply(--paper-header-panel-waterfall-container); + } + + /* + * mode: waterfall-tall + */ + :host([mode=waterfall-tall]) #mainContainer { + @apply(--paper-header-panel-waterfall-tall-container); + } + + :host ::content paper-toolbar, + :host ::content .paper-header { + position: relative; + overflow: visible !important; + } + + :host ::content paper-toolbar:after, + :host ::content .paper-header:after { + @apply(--paper-header-panel-shadow); + + -webkit-transition: opacity 0.5s, -webkit-transform 0.5s; + transition: opacity 0.5s, transform 0.5s; + + opacity: 0; + content: ""; + + width: 100%; + position: absolute; + left: 0px; + right: 0px; + z-index: 1; + + -webkit-transform: scale3d(1, 0, 1); + -webkit-transform-origin: 0% 0%; + + transform: scale3d(1, 0, 1); + transform-origin: 0% 0%; + } + + :host ::content paper-toolbar.has-shadow:after, + :host ::content .paper-header.has-shadow:after { + opacity: 1; + -webkit-transform: scale3d(1, 1, 1); + transform: scale3d(1, 1, 1); + } + </style> + + <template> + <content id="headerContent" select="paper-toolbar, .paper-header"></content> + <div id="mainContainer" class$="[[_computeMainContainerClass(mode)]]"> + <content id="mainContent" select="*"></content> + </div> + </template> + +</dom-module> + +<style is="custom-style"> + :root { + /** + * Default paper header panel shadow + */ + --paper-header-panel-shadow: { + height: 6px; + bottom: -6px; + box-shadow: inset 0px 5px 6px -3px rgba(0, 0, 0, 0.4); + }; + } +</style> + +<script> + + (function() { + + 'use strict'; + + var SHADOW_WHEN_SCROLLING = 1; + var SHADOW_ALWAYS = 2; + + + var MODE_CONFIGS = { + + outerScroll: { + scroll: true + }, + + shadowMode: { + standard: SHADOW_ALWAYS, + waterfall: SHADOW_WHEN_SCROLLING, + 'waterfall-tall': SHADOW_WHEN_SCROLLING + }, + + tallMode: { + 'waterfall-tall': true + } + }; + + Polymer({ + + is: 'paper-header-panel', + + /** + * Fired when the content has been scrolled. `event.detail.target` returns + * the scrollable element which you can use to access scroll info such as + * `scrollTop`. + * + * <paper-header-panel on-content-scroll="{{scrollHandler}}"> + * ... + * </paper-header-panel> + * + * + * scrollHandler: function(event) { + * var scroller = event.detail.target; + * console.log(scroller.scrollTop); + * } + * + * @event content-scroll + */ + + properties: { + + /** + * Controls header and scrolling behavior. Options are + * `standard`, `seamed`, `waterfall`, `waterfall-tall`, `scroll` and + * `cover`. Default is `standard`. + * + * `standard`: The header is a step above the panel. The header will consume the + * panel at the point of entry, preventing it from passing through to the + * opposite side. + * + * `seamed`: The header is presented as seamed with the panel. + * + * `waterfall`: Similar to standard mode, but header is initially presented as + * seamed with panel, but then separates to form the step. + * + * `waterfall-tall`: The header is initially taller (`tall` class is added to + * the header). As the user scrolls, the header separates (forming an edge) + * while condensing (`tall` class is removed from the header). + * + * `scroll`: The header keeps its seam with the panel, and is pushed off screen. + * + * `cover`: The panel covers the whole `paper-header-panel` including the + * header. This allows user to style the panel in such a way that the panel is + * partially covering the header. + * + * <paper-header-panel mode="cover"> + * <paper-toolbar class="tall"> + * <core-icon-button icon="menu"></core-icon-button> + * </paper-toolbar> + * <div class="content"></div> + * </paper-header-panel> + */ + mode: { + type: String, + value: 'standard', + observer: '_modeChanged', + reflectToAttribute: true + }, + + /** + * If true, the drop-shadow is always shown no matter what mode is set to. + */ + shadow: { + type: Boolean, + value: false + }, + + /** + * The class used in waterfall-tall mode. Change this if the header + * accepts a different class for toggling height, e.g. "medium-tall" + */ + tallClass: { + type: String, + value: 'tall' + }, + + /** + * If true, the scroller is at the top + */ + atTop: { + type: Boolean, + value: true, + readOnly: true + } + }, + + observers: [ + '_computeDropShadowHidden(atTop, mode, shadow)' + ], + + ready: function() { + this.scrollHandler = this._scroll.bind(this); + this._addListener(); + + // Run `scroll` logic once to initialze class names, etc. + this._keepScrollingState(); + }, + + detached: function() { + this._removeListener(); + }, + + /** + * Returns the header element + * + * @property header + * @type Object + */ + get header() { + return Polymer.dom(this.$.headerContent).getDistributedNodes()[0]; + }, + + /** + * Returns the scrollable element. + * + * @property scroller + * @type Object + */ + get scroller() { + return this._getScrollerForMode(this.mode); + }, + + /** + * Returns true if the scroller has a visible shadow. + * + * @property visibleShadow + * @type Boolean + */ + get visibleShadow() { + return this.header.classList.contains('has-shadow'); + }, + + _computeDropShadowHidden: function(atTop, mode, shadow) { + + var shadowMode = MODE_CONFIGS.shadowMode[mode]; + + if (this.shadow) { + this.toggleClass('has-shadow', true, this.header); + + } else if (shadowMode === SHADOW_ALWAYS) { + this.toggleClass('has-shadow', true, this.header); + + } else if (shadowMode === SHADOW_WHEN_SCROLLING && !atTop) { + this.toggleClass('has-shadow', true, this.header); + + } else { + this.toggleClass('has-shadow', false, this.header); + + } + }, + + _computeMainContainerClass: function(mode) { + // TODO: It will be useful to have a utility for classes + // e.g. Polymer.Utils.classes({ foo: true }); + + var classes = {}; + + classes['flex'] = mode !== 'cover'; + + return Object.keys(classes).filter( + function(className) { + return classes[className]; + }).join(' '); + }, + + _addListener: function() { + this.scroller.addEventListener('scroll', this.scrollHandler, false); + }, + + _removeListener: function() { + this.scroller.removeEventListener('scroll', this.scrollHandler); + }, + + _modeChanged: function(newMode, oldMode) { + var configs = MODE_CONFIGS; + var header = this.header; + var animateDuration = 200; + + if (header) { + // in tallMode it may add tallClass to the header; so do the cleanup + // when mode is changed from tallMode to not tallMode + if (configs.tallMode[oldMode] && !configs.tallMode[newMode]) { + header.classList.remove(this.tallClass); + this.async(function() { + header.classList.remove('animate'); + }, null, animateDuration); + } else { + header.classList.toggle('animate', configs.tallMode[newMode]); + } + } + this._keepScrollingState(); + }, + + _keepScrollingState: function () { + var main = this.scroller; + var header = this.header; + + this._setAtTop(main.scrollTop === 0); + + if (header && MODE_CONFIGS.tallMode[this.mode]) { + this.toggleClass(this.tallClass, this.atTop || + header.classList.contains(this.tallClass) && + main.scrollHeight < this.offsetHeight, header); + } + }, + + _scroll: function(e) { + this._keepScrollingState(); + this.fire('content-scroll', {target: this.scroller}, this, false); + }, + + _getScrollerForMode: function(mode) { + return MODE_CONFIGS.outerScroll[mode] ? + this : this.$.mainContainer; + } + + }); + + })(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-icon-button/.bower.json b/third_party/polymer/v1_0/components/paper-icon-button/.bower.json new file mode 100644 index 0000000..f5ebf09 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-icon-button/.bower.json @@ -0,0 +1,43 @@ +{ + "name": "paper-icon-button", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design icon button", + "main": "paper-icon-button.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button", + "icon", + "control" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^0.9.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-icon-button", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "0db7b75d5e37d8521b6aceb94b185a57145699d9" + }, + "_source": "git://github.com/PolymerElements/paper-icon-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-icon-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-icon-button/.gitignore b/third_party/polymer/v1_0/components/paper-icon-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-icon-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-icon-button/README.md b/third_party/polymer/v1_0/components/paper-icon-button/README.md new file mode 100644 index 0000000..96dbf8e --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-icon-button/README.md @@ -0,0 +1,49 @@ +paper-icon-button +================= + +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-icon-button` is a button with an image placed at the center. When the user touches +the button, a ripple effect emanates from the center of the button. + +`paper-icon-button` includes a default icon set. Use `icon` to specify which icon +from the icon set to use. + +```html +<paper-icon-button icon="menu"></paper-icon-button> +``` + +See [`iron-iconset`](#iron-iconset) for more information about +how to use a custom icon set. + +Example: + +```html +<link href="path/to/iron-icons/iron-icons.html" rel="import"> + +<paper-icon-button icon="favorite"></paper-icon-button> +<paper-icon-button src="star.png"></paper-icon-button> +``` + +Styling +------- + +Style the button with CSS as you would a normal DOM element. If you are using the icons +provided by `iron-icons`, they will inherit the foreground color of the button. + +```html +<!-- make a red "favorite" button --> +<paper-icon-button icon="favorite" style="color: red;"></paper-icon-button> +``` + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + +```css +/* make #my-button use a blue ripple instead of foreground color */ +#my-button::shadow #ripple { + color: blue; +} +``` + +The opacity of the ripple is not customizable via CSS. diff --git a/third_party/polymer/v1_0/components/paper-icon-button/bower.json b/third_party/polymer/v1_0/components/paper-icon-button/bower.json new file mode 100644 index 0000000..879efb1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-icon-button/bower.json @@ -0,0 +1,33 @@ +{ + "name": "paper-icon-button", + "private": true, + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design icon button", + "main": "paper-icon-button.html", + "author": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "button", + "icon", + "control" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-behaviors": "polymerelements/paper-behaviors#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^0.9.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-icon-button/index.html b/third_party/polymer/v1_0/components/paper-icon-button/index.html new file mode 100644 index 0000000..94c3720 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-icon-button/index.html @@ -0,0 +1,23 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <script src="../webcomponentsjs/webcomponents.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-icon-button/paper-icon-button.html b/third_party/polymer/v1_0/components/paper-icon-button/paper-icon-button.html new file mode 100644 index 0000000..99d8d88 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-icon-button/paper-icon-button.html @@ -0,0 +1,141 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-behaviors/paper-button-behavior.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> + +<style is="custom-style"> + :root { + --paper-icon-button-disabled-text: var(--disabled-text-color); + } +</style> + +<!-- +Material Design: <a href="http://www.google.com/design/spec/components/buttons.html">Buttons</a> + +`paper-icon-button` is a button with an image placed at the center. When the user touches +the button, a ripple effect emanates from the center of the button. + +`paper-icon-button` includes a default icon set. Use `icon` to specify which icon +from the icon set to use. + + <paper-icon-button icon="menu"></paper-icon-button> + +See [`iron-iconset`](#iron-iconset) for more information about +how to use a custom icon set. + +Example: + + <link href="path/to/iron-icons/iron-icons.html" rel="import"> + + <paper-icon-button icon="favorite"></paper-icon-button> + <paper-icon-button src="star.png"></paper-icon-button> + +###Styling + +Style the button with CSS as you would a normal DOM element. If you are using the icons +provided by `iron-icons`, they will inherit the foreground color of the button. + + /* make a red "favorite" button */ + <paper-icon-button icon="favorite" style="color: red;"></paper-icon-button> + +By default, the ripple is the same color as the foreground at 25% opacity. You may +customize the color using this selector: + + /* make #my-button use a blue ripple instead of foreground color */ + #my-button::shadow #ripple { + color: blue; + } + +The opacity of the ripple is not customizable via CSS. + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-icon-button-disabled-text` | The color of the disabled button | `--primary-text-color` +`--paper-icon-button-ink-color` | Selected/focus ripple color | `--default-primary-color` +`--paper-icon-button` | Mixin for a button | `{}` +`--paper-icon-button-disabled` | Mixin for a disabled button | `{}` + +@group Paper Elements +@element paper-icon-button +@demo demo/index.html +--> + +<dom-module id="paper-icon-button"> + <style> + + :host { + display: inline-block; + position: relative; + padding: 8px; + outline: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; + z-index: 0; + + @apply(--paper-icon-button); + } + + :host #ink { + color: var(--paper-icon-button-ink-color, --primary-text-color); + opacity: 0.6; + } + + :host([disabled]) { + color: var(--paper-icon-button-disabled-text, #fff); + pointer-events: none; + cursor: auto; + @apply(--paper-icon-button-disabled); + } + </style> + <template> + <paper-ripple id="ink" class="circle" center></paper-ripple> + <iron-icon id="icon" src="[[src]]" icon="[[icon]]"></iron-icon> + </template> +</dom-module> +<script> + Polymer({ + is: 'paper-icon-button', + + behaviors: [ + Polymer.PaperButtonBehavior, + Polymer.PaperRadioButtonBehavior + ], + + properties: { + /** + * The URL of an image for the icon. If the src property is specified, + * the icon property should not be. + */ + src: { + type: String + }, + + /** + * Specifies the icon name or index in the set of icons available in + * the icon's icon set. If the icon property is specified, + * the src property should not be. + */ + icon: { + type: String + } + } + }); +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/.bower.json b/third_party/polymer/v1_0/components/paper-input/.bower.json new file mode 100644 index 0000000..fc83cc2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/.bower.json @@ -0,0 +1,53 @@ +{ + "name": "paper-input", + "version": "1.0.0", + "description": "Material design text fields", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "paper-input.html", + "paper-textarea.html", + "paper-input-behavior.html", + "paper-input-container.html", + "paper-input-error.html", + "paper-input-char-counter.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-input", + "ignore": [], + "dependencies": { + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "47a869b431fd03b9f611aee8eb286f0497ad379b" + }, + "_source": "git://github.com/PolymerElements/paper-input.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-input" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-input/.gitignore b/third_party/polymer/v1_0/components/paper-input/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-input/README.md b/third_party/polymer/v1_0/components/paper-input/README.md new file mode 100644 index 0000000..c49ccc0 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/README.md @@ -0,0 +1,5 @@ +# paper-input + +`<paper-input>` is a Material Design text field. + +Contains a number of different features for validation, character counting, and more. diff --git a/third_party/polymer/v1_0/components/paper-input/all-imports.html b/third_party/polymer/v1_0/components/paper-input/all-imports.html new file mode 100644 index 0000000..0f45771 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/all-imports.html @@ -0,0 +1,12 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="paper-input.html"> +<link rel="import" href="paper-textarea.html"> diff --git a/third_party/polymer/v1_0/components/paper-input/bower.json b/third_party/polymer/v1_0/components/paper-input/bower.json new file mode 100644 index 0000000..d98556e --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-input", + "version": "1.0.0", + "description": "Material design text fields", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "input" + ], + "main": [ + "paper-input.html", + "paper-textarea.html", + "paper-input-behavior.html", + "paper-input-container.html", + "paper-input-error.html", + "paper-input-char-counter.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-input.git" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-input", + "ignore": [], + "dependencies": { + "iron-input": "PolymerElements/iron-input#^1.0.0", + "iron-form-element-behavior": "PolymerElements/iron-form-element-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-autogrow-textarea": "PolymerElements/iron-autogrow-textarea#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-validator-behavior": "PolymerElements/iron-validator-behavior#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-input/hero.svg b/third_party/polymer/v1_0/components/paper-input/hero.svg new file mode 100644 index 0000000..146ffea --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/hero.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <rect x="49" y="53" width="2" height="18"/> + <path d="M188,78H37V44h151V78z M39,76h147V46H39V76z"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-input/index.html b/third_party/polymer/v1_0/components/paper-input/index.html new file mode 100644 index 0000000..e6c9fad --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-input</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="all-imports.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-input-addon-behavior.html b/third_party/polymer/v1_0/components/paper-input/paper-input-addon-behavior.html new file mode 100644 index 0000000..dd17a78 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-input-addon-behavior.html @@ -0,0 +1,43 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<script> + + /** + * Use `Polymer.PaperInputAddonBehavior` to implement an add-on for `<paper-input-container>`. A + * add-on appears below the input, and may display information based on the input value and + * validity such as a character counter or an error message. + * @polymerBehavior + */ + Polymer.PaperInputAddonBehavior = { + + hostAttributes: { + 'add-on': '' + }, + + attached: function() { + this.fire('addon-attached'); + }, + + /** + * The function called by `<paper-input-container>` when the input value or validity changes. + * @param {Object} state All properties are optional. + * @param {Node} state.inputElement The input element. + * @param {String} state.value The input value. + * @param {Boolean} state.invalid True if the input value is invalid. + */ + update: function(state) { + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-input-behavior.html b/third_party/polymer/v1_0/components/paper-input/paper-input-behavior.html new file mode 100644 index 0000000..06a4e54 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-input-behavior.html @@ -0,0 +1,293 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> + +<script> + + /** + * Use `Polymer.PaperInputBehavior` to implement inputs with `<paper-input-container>`. This + * behavior is implemented by `<paper-input>`. It exposes a number of properties from + * `<paper-input-container>` and `<input is="iron-input">` and they should be bound in your + * template. + * + * The input element can be accessed by the `inputElement` property if you need to access + * properties or methods that are not exposed. + * @polymerBehavior + */ + Polymer.PaperInputBehavior = { + + properties: { + + /** + * The label for this input. Bind this to `<paper-input-container>`'s `label` property. + */ + label: { + type: String + }, + + /** + * The value for this input. Bind this to the `<input is="iron-input">`'s `bindValue` + * property, or the value property of your input that is `notify:true`. + */ + value: { + notify: true, + type: String + }, + + /** + * Set to true to disable this input. Bind this to both the `<paper-input-container>`'s + * and the input's `disabled` property. + */ + disabled: { + type: Boolean, + value: false + }, + + /** + * Returns true if the value is invalid. Bind this to both the `<paper-input-container>`'s + * and the input's `invalid` property. + */ + invalid: { + type: Boolean, + value: false + }, + + /** + * Set to true to prevent the user from entering invalid input. Bind this to the + * `<input is="iron-input">`'s `preventInvalidInput` property. + */ + preventInvalidInput: { + type: Boolean + }, + + /** + * Set this to specify the pattern allowed by `preventInvalidInput`. Bind this to the + * `<input is="iron-input">`'s `allowedPattern` property. + */ + allowedPattern: { + type: String + }, + + /** + * The type of the input. The supported types are `text`, `number` and `password`. Bind this + * to the `<input is="iron-input">`'s `type` property. + */ + type: { + type: String + }, + + /** + * A pattern to validate the `input` with. Bind this to the `<input is="iron-input">`'s + * `pattern` property. + */ + pattern: { + type: String + }, + + /** + * Set to true to mark the input as required. Bind this to the `<input is="iron-input">`'s + * `required` property. + */ + required: { + type: Boolean, + value: false + }, + + /** + * The maximum length of the input value. Bind this to the `<input is="iron-input">`'s + * `maxlength` property. + */ + maxlength: { + type: Number + }, + + /** + * The error message to display when the input is invalid. Bind this to the + * `<paper-input-error>`'s content, if using. + */ + errorMessage: { + type: String + }, + + /** + * Set to true to show a character counter. + */ + charCounter: { + type: Boolean, + value: false + }, + + /** + * Set to true to disable the floating label. Bind this to the `<paper-input-container>`'s + * `noLabelFloat` property. + */ + noLabelFloat: { + type: Boolean, + value: false + }, + + /** + * Set to true to always float the label. Bind this to the `<paper-input-container>`'s + * `alwaysFloatLabel` property. + */ + alwaysFloatLabel: { + type: Boolean, + value: false + }, + + /** + * Set to true to auto-validate the input value. Bind this to the `<paper-input-container>`'s + * `autoValidate` property. + */ + autoValidate: { + type: Boolean, + value: false + }, + + /** + * Name of the validator to use. Bind this to the `<input is="iron-input">`'s `validator` + * property. + */ + validator: { + type: String + }, + + // HTMLInputElement attributes for binding if needed + + /** + * Bind this to the `<input is="iron-input">`'s `autocomplete` property. + */ + autocomplete: { + type: String, + value: 'off' + }, + + /** + * Bind this to the `<input is="iron-input">`'s `autofocus` property. + */ + autofocus: { + type: Boolean + }, + + /** + * Bind this to the `<input is="iron-input">`'s `inputmode` property. + */ + inputmode: { + type: String + }, + + /** + * Bind this to the `<input is="iron-input">`'s `minlength` property. + */ + minlength: { + type: Number + }, + + /** + * Bind this to the `<input is="iron-input">`'s `name` property. + */ + name: { + type: String + }, + + /** + * A placeholder string in addition to the label. If this is set, the label will always float. + */ + placeholder: { + type: String + }, + + /** + * Bind this to the `<input is="iron-input">`'s `readonly` property. + */ + readonly: { + type: Boolean, + value: false + }, + + /** + * Bind this to the `<input is="iron-input">`'s `size` property. + */ + size: { + type: Number + }, + + _ariaDescribedBy: { + type: String, + value: '' + } + + }, + + listeners: { + 'addon-attached': '_onAddonAttached' + }, + + /** + * Returns a reference to the input element. + */ + get inputElement() { + return this.$.input; + }, + + attached: function() { + this._updateAriaLabelledBy(); + }, + + _appendStringWithSpace: function(str, more) { + if (str) { + str = str + ' ' + more; + } else { + str = more; + } + return str; + }, + + _onAddonAttached: function(event) { + var target = event.path ? event.path[0] : event.target; + if (target.id) { + this._ariaDescribedBy = this._appendStringWithSpace(this._ariaDescribedBy, target.id); + } else { + var id = 'paper-input-add-on-' + Math.floor((Math.random() * 100000)); + target.id = id; + this._ariaDescribedBy = this._appendStringWithSpace(this._ariaDescribedBy, id); + } + }, + + /** + * Validates the input element and sets an error style if needed. + */ + validate: function () { + return this.inputElement.validate(); + }, + + _computeAlwaysFloatLabel: function(alwaysFloatLabel, placeholder) { + return placeholder || alwaysFloatLabel; + }, + + _updateAriaLabelledBy: function() { + var label = Polymer.dom(this.root).querySelector('label'); + if (!label) { + this._ariaLabelledBy = ''; + return; + } + var labelledBy; + if (label.id) { + labelledBy = label.id; + } else { + labelledBy = 'paper-input-label-' + new Date().getUTCMilliseconds(); + label.id = labelledBy; + } + this._ariaLabelledBy = labelledBy; + } + + }; + +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-input-char-counter.html b/third_party/polymer/v1_0/components/paper-input/paper-input-char-counter.html new file mode 100644 index 0000000..566f8c6 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-input-char-counter.html @@ -0,0 +1,95 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="paper-input-addon-behavior.html"> + +<!-- +`<paper-input-char-counter>` is a character counter for use with `<paper-input-container>`. It +shows the number of characters entered in the input and the max length if it is specified. + + <paper-input-container> + <input is="iron-input" maxlength="20"> + <paper-input-char-counter></paper-input-char-counter> + </paper-input-container> + +### Styling + +The following mixin is available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-input-char-counter` | Mixin applied to the element | `{}` +--> +<dom-module id="paper-input-char-counter"> + + <style> + + :host { + display: inline-block; + float: right; + + @apply(--paper-font-caption); + @apply(--paper-input-char-counter); + } + + </style> + + <template> + + <span>[[_charCounterStr]]</span> + + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-input-char-counter', + + behaviors: [ + Polymer.PaperInputAddonBehavior + ], + + properties: { + + _charCounterStr: { + type: String, + value: '0' + } + + }, + + update: function(state) { + if (!state.inputElement) { + return; + } + + state.value = state.value || ''; + + // Account for the textarea's new lines. + var str = state.value.replace(/(\r\n|\n|\r)/g, '--').length; + + if (state.inputElement.hasAttribute('maxlength')) { + str += '/' + state.inputElement.getAttribute('maxlength'); + } + this._charCounterStr = str; + } + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-input-container.html b/third_party/polymer/v1_0/components/paper-input/paper-input-container.html new file mode 100644 index 0000000..18935c1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-input-container.html @@ -0,0 +1,495 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-input-container>` is a container for a `<label>`, an `<input is="iron-input">` or +`<iron-autogrow-textarea>` and optional add-on elements such as an error message or character +counter, used to implement Material Design text fields. + +For example: + + <paper-input-container> + <label>Your name</label> + <input is="iron-input"> + </paper-input-container> + +### Listening for input changes + +By default, it listens for changes on the `bind-value` attribute on its children nodes and perform +tasks such as auto-validating and label styling when the `bind-value` changes. You can configure +the attribute it listens to with the `attr-for-value` attribute. + +### Using a custom input element + +You can use a custom input element in a `<paper-input-container>`, for example to implement a +compound input field like a social security number input. The custom input element should have the +`paper-input-input` class, have a `notify:true` value property and optionally implements +`Polymer.IronValidatableBehavior` if it is validatble. + + <paper-input-container attr-for-value="ssn-value"> + <label>Social security number</label> + <ssn-input class="paper-input-input"></ssn-input> + </paper-input-container> + +### Validation + +If the `auto-validate` attribute is set, the input container will validate the input and update +the container styling when the input value changes. + +### Add-ons + +Add-ons are child elements of a `<paper-input-container>` with the `add-on` attribute and +implements the `Polymer.PaperInputAddonBehavior` behavior. They are notified when the input value +or validity changes, and may implement functionality such as error messages or character counters. +They appear at the bottom of the input. + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-input-container-color` | Label and underline color when the input is not focused | `--secondary-text-color` +`--paper-input-container-focus-color` | Label and underline color when the input is focused | `--default-primary-color` +`--paper-input-container-invalid-color` | Label and underline color when the input is focused | `--google-red-500` +`--paper-input-container-input-color` | Input foreground color | `--primary-text-color` +`--paper-input-container` | Mixin applied to the container | `{}` +`--paper-input-container-label` | Mixin applied to the label | `{}` +`--paper-input-container-input` | Mixin applied to the input | `{}` + +This element is `display:block` by default, but you can set the `inline` attribute to make it +`display:inline-block`. +--> +<dom-module id="paper-input-container"> + + <style> + + :host { + display: block; + padding: 8px 0; + + @apply(--paper-input-container); + } + + :host[inline] { + display: inline-block; + } + + :host([disabled]) { + pointer-events: none; + opacity: 0.33; + } + + .floated-label-placeholder { + @apply(--paper-font-caption); + } + + .underline { + position: relative; + } + + .focused-line { + height: 2px; + + -webkit-transform-origin: center center; + transform-origin: center center; + -webkit-transform: scale3d(0,1,1); + transform: scale3d(0,1,1); + + background: var(--paper-input-container-focus-color, --default-primary-color); + } + + .is-highlighted .focused-line { + -webkit-transform: none; + transform: none; + -webkit-transition: -webkit-transform 0.25s; + transition: transform 0.25s; + + @apply(--paper-transition-easing); + } + + .is-invalid .focused-line { + background: var(--paper-input-container-invalid-color, --google-red-500); + + -webkit-transform: none; + transform: none; + -webkit-transition: -webkit-transform 0.25s; + transition: transform 0.25s; + + @apply(--paper-transition-easing); + } + + .unfocused-line { + height: 1px; + background: var(--paper-input-container-color, --secondary-text-color); + } + + :host([disabled]) .unfocused-line { + border-bottom: 1px dashed; + border-color: var(--paper-input-container-color, --secondary-text-color); + background: transparent; + } + + .input-content { + position: relative; + } + + .input-content ::content label, + .input-content ::content .paper-input-label { + position: absolute; + top: 0; + right: 0; + left: 0; + font: inherit; + color: var(--paper-input-container-color, --secondary-text-color); + + @apply(--paper-font-subhead); + @apply(--paper-input-container-label); + } + + .input-content.label-is-floating ::content label, + .input-content.label-is-floating ::content .paper-input-label { + -webkit-transform: translate3d(0, -75%, 0) scale(0.75); + transform: translate3d(0, -75%, 0) scale(0.75); + -webkit-transform-origin: left top; + transform-origin: left top; + -webkit-transition: -webkit-transform 0.25s; + transition: transform 0.25s; + + @apply(--paper-transition-easing); + } + + .input-content.label-is-highlighted ::content label, + .input-content.label-is-highlighted ::content .paper-input-label { + color: var(--paper-input-container-focus-color, --default-primary-color); + } + + .input-content.is-invalid ::content label, + .input-content.is-invalid ::content .paper-input-label { + color: var(--paper-input-container-invalid-color, --google-red-500); + } + + .input-content.label-is-hidden ::content label, + .input-content.label-is-hidden ::content .paper-input-label { + visibility: hidden; + } + + .input-content ::content input, + .input-content ::content textarea, + .input-content ::content iron-autogrow-textarea, + .input-content ::content .paper-input-input { + position: relative; /* to make a stacking context */ + outline: none; + box-shadow: none; + padding: 0; + width: 100%; + background: transparent; + border: none; + color: var(--paper-input-container-input-color, --primary-text-color); + + @apply(--paper-font-subhead); + @apply(--paper-input-container-input); + } + + /* Firefox sets a min-width on the input, which can cause layout issues */ + .input-content ::content input { + min-width: 0; + } + + .input-content ::content textarea { + resize: none; + } + + .add-on-content.is-invalid ::content * { + color: var(--paper-input-container-invalid-color, --google-red-500); + } + + .add-on-content.is-highlighted ::content * { + color: var(--paper-input-container-focus-color, --default-primary-color); + } + + </style> + + <template> + + <template is="dom-if" if="[[!noLabelFloat]]"> + <div class="floated-label-placeholder"> </div> + </template> + + <div class$="[[_computeInputContentClass(noLabelFloat,alwaysFloatLabel,focused,invalid,_inputHasContent)]]"> + <content select=":not([add-on])"></content> + </div> + + <div class$="[[_computeUnderlineClass(focused,invalid)]]"> + <div class="unfocused-line fit"></div> + <div class="focused-line fit"></div> + </div> + + <div class$="[[_computeAddOnContentClass(focused,invalid)]]"> + <content id="addOnContent" select="[add-on]"></content> + </div> + + </template> + +</dom-module> + +<script> +(function() { + + Polymer({ + + is: 'paper-input-container', + + properties: { + + /** + * Set to true to disable the floating label. The label disappears when the input value is + * not null. + */ + noLabelFloat: { + type: Boolean, + value: false + }, + + /** + * Set to true to always float the floating label. + */ + alwaysFloatLabel: { + type: Boolean, + value: false + }, + + /** + * The attribute to listen for value changes on. + */ + attrForValue: { + type: String, + value: 'bind-value' + }, + + /** + * Set to true to auto-validate the input value when it changes. + */ + autoValidate: { + type: Boolean, + value: false + }, + + /** + * True if the input is invalid. This property is set automatically when the input value + * changes if auto-validating, or when the `iron-input-valid` event is heard from a child. + */ + invalid: { + observer: '_invalidChanged', + type: Boolean, + value: false + }, + + /** + * True if the input has focus. + */ + focused: { + readOnly: true, + type: Boolean, + value: false + }, + + _addons: { + type: Array, + value: function() { + return []; + } + }, + + _inputHasContent: { + type: Boolean, + value: false + }, + + _inputSelector: { + type: String, + value: 'input,textarea,.paper-input-input' + }, + + _boundOnFocus: { + type: Function, + value: function() { + return this._onFocus.bind(this); + } + }, + + _boundOnBlur: { + type: Function, + value: function() { + return this._onBlur.bind(this); + } + }, + + _boundOnInput: { + type: Function, + value: function() { + this._onInput.bind(this) + } + }, + + _boundValueChanged: { + type: Function, + value: function() { + return this._onValueChanged.bind(this); + } + } + + }, + + listeners: { + 'addon-attached': '_onAddonAttached', + 'iron-input-validate': '_onIronInputValidate' + }, + + get _valueChangedEvent() { + return this.attrForValue + '-changed'; + }, + + get _propertyForValue() { + return Polymer.CaseMap.dashToCamelCase(this.attrForValue); + }, + + get _inputElement() { + return Polymer.dom(this).querySelector(this._inputSelector); + }, + + ready: function() { + this.addEventListener('focus', this._boundOnFocus, true); + this.addEventListener('blur', this._boundOnBlur, true); + if (this.attrForValue) { + this._inputElement.addEventListener(this._valueChangedEvent, this._boundValueChanged); + } else { + this.addEventListener('input', this._onInput); + } + }, + + attached: function() { + this._handleValue(this._inputElement); + }, + + _onAddonAttached: function(event) { + this._addons.push(event.target); + this._handleValue(this._inputElement); + }, + + _onFocus: function() { + this._setFocused(true); + }, + + _onBlur: function() { + this._setFocused(false); + }, + + _onInput: function(event) { + this._handleValue(event.target); + }, + + _onValueChanged: function(event) { + this._handleValue(event.target); + }, + + _handleValue: function(inputElement) { + var value = inputElement[this._propertyForValue] || inputElement.value; + + if (this.autoValidate) { + var valid; + if (inputElement.validate) { + valid = inputElement.validate(value); + } else { + valid = inputElement.checkValidity(); + } + this.invalid = !valid; + } + + // type="number" hack needed because this.value is empty until it's valid + if (value || (inputElement.type === 'number' && !inputElement.checkValidity())) { + this._inputHasContent = true; + } else { + this._inputHasContent = false; + } + + this.updateAddons({ + inputElement: inputElement, + value: value, + invalid: this.invalid + }); + }, + + _onIronInputValidate: function(event) { + this.invalid = this._inputElement.invalid; + }, + + _invalidChanged: function() { + if (this._addons) { + this.updateAddons({invalid: this.invalid}); + } + }, + + /** + * Call this to update the state of add-ons. + * @param {Object} state Add-on state. + */ + updateAddons: function(state) { + for (var addon, index = 0; addon = this._addons[index]; index++) { + addon.update(state); + } + }, + + _computeInputContentClass: function(noLabelFloat, alwaysFloatLabel, focused, invalid, _inputHasContent) { + var cls = 'input-content'; + if (!noLabelFloat) { + if (alwaysFloatLabel || _inputHasContent) { + cls += ' label-is-floating'; + if (invalid) { + cls += ' is-invalid'; + } else if (focused) { + cls += " label-is-highlighted"; + } + } + } else { + if (_inputHasContent) { + cls += ' label-is-hidden'; + } + } + return cls; + }, + + _computeUnderlineClass: function(focused, invalid) { + var cls = 'underline'; + if (invalid) { + cls += ' is-invalid'; + } else if (focused) { + cls += ' is-highlighted' + } + return cls; + }, + + _computeAddOnContentClass: function(focused, invalid) { + var cls = 'add-on-content'; + if (invalid) { + cls += ' is-invalid'; + } else if (focused) { + cls += ' is-highlighted' + } + return cls; + } + + }); + +})(); +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-input-error.html b/third_party/polymer/v1_0/components/paper-input/paper-input-error.html new file mode 100644 index 0000000..c034e96 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-input-error.html @@ -0,0 +1,99 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="paper-input-addon-behavior.html"> + +<!-- +`<paper-input-error>` is an error message for use with `<paper-input-container>`. The error is +displayed when the `<paper-input-container>` is `invalid`. + + <paper-input-container> + <input is="iron-input" pattern="[0-9]*"> + <paper-input-error>Only numbers are allowed!</paper-input-error> + </paper-input-container> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-input-container-invalid-color` | The foreground color of the error | `--google-red-500` +`--paper-input-error` | Mixin applied to the error | `{}` +--> +<dom-module id="paper-input-error"> + + <style> + + :host { + /* need to use display: none for role="alert" */ + display: none; + float: left; + + color: var(--paper-input-container-invalid-color, --google-red-500); + + @apply(--paper-font-caption); + @apply(--paper-input-error); + } + + :host([invalid]) { + display: inline-block; + }; + + </style> + + <template> + + <content></content> + + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-input-error', + + behaviors: [ + Polymer.PaperInputAddonBehavior + ], + + hostAttributes: { + 'role': 'alert' + }, + + properties: { + + /** + * True if the error is showing. + */ + invalid: { + readOnly: true, + reflectToAttribute: true, + type: Boolean + } + + }, + + update: function(state) { + this._setInvalid(state.invalid); + } + + }) + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-input.html b/third_party/polymer/v1_0/components/paper-input/paper-input.html new file mode 100644 index 0000000..234db95 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-input.html @@ -0,0 +1,126 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-input/iron-input.html"> +<link rel="import" href="../iron-form-element-behavior/iron-form-element-behavior.html"> +<link rel="import" href="paper-input-behavior.html"> +<link rel="import" href="paper-input-container.html"> +<link rel="import" href="paper-input-error.html"> +<link rel="import" href="paper-input-char-counter.html"> + +<!-- +`<paper-input>` is a single-line text field with Material Design styling. + + <paper-input label="Input label"></paper-input> + +It may include an optional error message or character counter. + + <paper-input error-message="Invalid input!" label="Input label"></paper-input> + <paper-input char-counter label="Input label"></paper-input> + +See `Polymer.PaperInputBehavior` for more API docs. + +### Styling + +See `Polymer.PaperInputContainer` for a list of custom properties used to +style this element. + +@group Paper Elements +@element paper-input +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-input"> + + <style> + + :host { + display: block; + } + + input::-webkit-input-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + input:-moz-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + input::-moz-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + input:-ms-input-placeholder { + color: var(--paper-input-container-color, --secondary-text-color); + } + + </style> + + <template> + + <paper-input-container no-label-float="[[noLabelFloat]]" always-float-label="[[_computeAlwaysFloatLabel(alwaysFloatLabel,placeholder)]]" auto-validate$="[[autoValidate]]" disabled$="[[disabled]]" invalid="[[invalid]]"> + + <label hidden$="[[!label]]">[[label]]</label> + + <input is="iron-input" id="input" + aria-labelledby$="[[_ariaLabelledBy]]" + aria-describedby$="[[_ariaDescribedBy]]" + disabled$="[[disabled]]" + bind-value="{{value}}" + invalid="{{invalid}}" + prevent-invalid-input="[[preventInvalidInput]]" + allowedPattern="[[allowedPattern]]" + validator="[[validator]]" + type$="[[type]]" + pattern$="[[pattern]]" + maxlength$="[[maxlength]]" + required$="[[required]]" + autocomplete$="[[autocomplete]]" + autofocus$="[[autofocus]]" + inputmode$="[[inputmode]]" + minlength$="[[minlength]]" + name$="[[name]]" + placeholder$="[[placeholder]]" + readonly$="[[readonly]]" + size$="[[size]]"> + + <template is="dom-if" if="[[errorMessage]]"> + <paper-input-error>[[errorMessage]]</paper-input-error> + </template> + + <template is="dom-if" if="[[charCounter]]"> + <paper-input-char-counter></paper-input-char-counter> + </template> + + </paper-input-container> + + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-input', + + behaviors: [ + Polymer.PaperInputBehavior, + Polymer.IronFormElementBehavior + ] + + }) + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-input/paper-textarea.html b/third_party/polymer/v1_0/components/paper-input/paper-textarea.html new file mode 100644 index 0000000..0c74edf --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-input/paper-textarea.html @@ -0,0 +1,100 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-autogrow-textarea/iron-autogrow-textarea.html"> +<link rel="import" href="../iron-form-element-behavior/iron-form-element-behavior.html"> +<link rel="import" href="paper-input-behavior.html"> +<link rel="import" href="paper-input-container.html"> +<link rel="import" href="paper-input-error.html"> +<link rel="import" href="paper-input-char-counter.html"> + +<!-- +`<paper-textarea>` is a multi-line text field with Material Design styling. + + <paper-textarea label="Textarea label"></paper-textarea> + +See `Polymer.PaperInputBehavior` for more API docs. + +### Validation + +Currently only `required` and `maxlength` validation is supported. + +### Styling + +See `Polymer.PaperInputContainer` for a list of custom properties used to +style this element. +--> + +<dom-module id="paper-textarea"> + <template> + + <paper-input-container no-label-float$="[[noLabelFloat]]" auto-validate$="[[autoValidate]]" disabled$="[[disabled]]" invalid="[[invalid]]"> + + <label hidden$="[[!label]]">[[label]]</label> + + <iron-autogrow-textarea id="input" class="paper-input-input" + bind-value="{{value}}" + required$="[[required]]" + maxlength$="[[maxlength]]"></iron-autogrow-textarea> + + <template is="dom-if" if="[[errorMessage]]"> + <paper-input-error>[[errorMessage]]</paper-input-error> + </template> + + <template is="dom-if" if="[[charCounter]]"> + <paper-input-char-counter></paper-input-char-counter> + </template> + + </paper-input-container> + + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-textarea', + + behaviors: [ + Polymer.PaperInputBehavior, + Polymer.IronFormElementBehavior + ], + + properties: { + + _ariaLabelledBy: { + observer: '_ariaLabelledByChanged', + type: String + }, + + _ariaDescribedBy: { + observer: '_ariaDescribedByChanged', + type: String + } + + }, + + _ariaLabelledByChanged: function(ariaLabelledBy) { + this.$.input.textarea.setAttribute('aria-labelledby', ariaLabelledBy); + }, + + _ariaDescribedByChanged: function(ariaDescribedBy) { + this.$.input.textarea.setAttribute('aria-describedby', ariaDescribedBy); + } + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-item/.bower.json b/third_party/polymer/v1_0/components/paper-item/.bower.json new file mode 100644 index 0000000..00391bb --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/.bower.json @@ -0,0 +1,49 @@ +{ + "name": "paper-item", + "version": "1.0.1", + "description": "A material-design styled list item", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "item" + ], + "main": [ + "paper-item.html", + "paper-icon-item.html", + "paper-item-body.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-item" + }, + "license": "MIT", + "homepage": "https://github.com/PolymerElements/paper-item", + "ignore": [], + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "645ebae475ab4fc28698da253ccc3aa2c48341d7" + }, + "_source": "git://github.com/PolymerElements/paper-item.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-item" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-item/.gitignore b/third_party/polymer/v1_0/components/paper-item/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-item/README.md b/third_party/polymer/v1_0/components/paper-item/README.md new file mode 100644 index 0000000..02f8202 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/README.md @@ -0,0 +1,4 @@ +paper-item +========= + +A non-interactive list item. diff --git a/third_party/polymer/v1_0/components/paper-item/all-imports.html b/third_party/polymer/v1_0/components/paper-item/all-imports.html new file mode 100644 index 0000000..4b1583f --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/all-imports.html @@ -0,0 +1,13 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="paper-item.html"> +<link rel="import" href="paper-item-body.html"> +<link rel="import" href="paper-icon-item.html"> diff --git a/third_party/polymer/v1_0/components/paper-item/bower.json b/third_party/polymer/v1_0/components/paper-item/bower.json new file mode 100644 index 0000000..f077268 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/bower.json @@ -0,0 +1,40 @@ +{ + "name": "paper-item", + "version": "1.0.1", + "description": "A material-design styled list item", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "item" + ], + "main": [ + "paper-item.html", + "paper-icon-item.html", + "paper-item-body.html" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-item" + }, + "license": "MIT", + "homepage": "https://github.com/PolymerElements/paper-item", + "ignore": [], + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icon": "PolymerElements/iron-icon#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0", + "paper-toggle-button": "PolymerElements/paper-toggle-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-item/index.html b/third_party/polymer/v1_0/components/paper-item/index.html new file mode 100644 index 0000000..b409ed1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/index.html @@ -0,0 +1,30 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!doctype html> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-item</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page src="all-imports.html"></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-item/paper-icon-item.html b/third_party/polymer/v1_0/components/paper-item/paper-icon-item.html new file mode 100644 index 0000000..231159c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/paper-icon-item.html @@ -0,0 +1,86 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-icon-item>` is a convenience element to make an item with icon. It is a non interactive list +item with a fixed-width icon area, according to Material Design. This is useful if the icons are of +varying widths, but you want the item bodies to line up. Use this like a `<paper-item>`. The child +node with the attribute `item-icon` is placed in the icon area. + + <paper-icon-item> + <iron-icon icon="favorite" item-icon></iron-icon> + Favorite + </paper-icon-item> + <paper-icon-item> + <div class="avatar" item-icon></div> + Avatar + </paper-icon-item> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-item-icon-width` | Width of the icon area | `56px` +`--paper-icon-item` | Mixin applied to the item | `{}` + +--> + +<dom-module id="paper-icon-item"> + + <link rel="import" type="css" href="paper-item-shared.css"> + + <style> + + :host { + @apply(--layout-horizontal); + @apply(--layout-center); + @apply(--paper-font-subhead); + + @apply(--paper-item); + @apply(--paper-icon-item); + } + + .content-icon { + width: var(--paper-item-icon-width, 56px); + } + + </style> + + <template> + <div id="contentIcon" class="content-icon layout horizontal center"> + <content select="[item-icon]"></content> + </div> + <content></content> + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-icon-item', + + hostAttributes: { + 'role': 'listitem' + } + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-item/paper-item-body.html b/third_party/polymer/v1_0/components/paper-item/paper-item-body.html new file mode 100644 index 0000000..6345830 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/paper-item-body.html @@ -0,0 +1,93 @@ +<!-- + @license + Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +Use `<paper-item-body>` in a `<paper-item>` or `<paper-icon-item>` to make two- or +three- line items. It is a flex item that is a vertical flexbox. + + <paper-item> + <paper-item-body two-line> + <div>Show your status</div> + <div secondary>Your status is visible to everyone</div> + </paper-item-body> + </paper-item> + +The child elements with the `secondary` attribute is given secondary text styling. + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-item-body-two-line-min-height` | Minimum height of a two-line item | `72px` +`--paper-item-body-three-line-min-height` | Minimum height of a three-line item | `88px` +`--paper-item-body-secondary-color` | Foreground color for the `secondary` area | `--secondary-text-color` +`--paper-item-body-secondary` | Mixin applied to the `secondary` area | `{}` + +--> + +<dom-module id="paper-item-body"> + + <style> + + :host { + overflow: hidden; /* needed for text-overflow: ellipsis to work on ff */ + @apply(--layout-vertical); + @apply(--layout-center-justified); + @apply(--layout-flex); + } + + :host([two-line]) { + min-height: var(--paper-item-body-two-line-min-height, 72px); + } + + :host([three-line]) { + min-height: var(--paper-item-body-three-line-min-height, 88px); + } + + :host > ::content > * { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + + :host > ::content [secondary] { + color: var(--paper-item-body-secondary-color, --secondary-text-color); + @apply(--paper-font-body1); + + @apply(--paper-item-body-secondary); + } + + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-item-body' + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-item/paper-item-shared.css b/third_party/polymer/v1_0/components/paper-item/paper-item-shared.css new file mode 100644 index 0000000..8528d1a --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/paper-item-shared.css @@ -0,0 +1,19 @@ +/* + @license + Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: block; + min-height: var(--paper-item-min-height, 48px); + padding: 0px 16px; +} + +:host > ::content > *:not(:first-child):not(:last-child) { + margin-right: 16px; +} diff --git a/third_party/polymer/v1_0/components/paper-item/paper-item.html b/third_party/polymer/v1_0/components/paper-item/paper-item.html new file mode 100644 index 0000000..50b89fe --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-item/paper-item.html @@ -0,0 +1,95 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-item>` is a non-interactive list item. By default, it is a horizontal flexbox. + + <paper-item>Item</paper-item> + +Use this element with `<paper-item-body>` to make Material Design styled two-line and three-line +items. + + <paper-item> + <paper-item-body two-line> + <div>Show your status</div> + <div secondary>Your status is visible to everyone</div> + </paper-item-body> + <iron-icon icon="warning"></iron-icon> + </paper-item> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-item-min-height` | Minimum height of the item | `48px` +`--paper-item` | Mixin applied to the item | `{}` + +### Accessibility + +This element has `role="listitem"` by default. Depending on usage, it may be more appropriate to set +`role="menuitem"`, `role="menuitemcheckbox"` or `role="menuitemradio"`. + + <paper-item role="menuitemcheckbox"> + <paper-item-body> + Show your status + </paper-item-body> + <paper-checkbox></paper-checkbox> + </paper-item> + +@group Paper Elements +@element paper-item +@demo demo/index.html +--> + +<dom-module id="paper-item"> + + <link rel="import" type="css" href="paper-item-shared.css"> + + <style> + + :host { + @apply(--layout-horizontal); + @apply(--layout-center); + @apply(--paper-font-subhead); + + @apply(--paper-item); + } + + </style> + + <template> + <content></content> + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-item', + + hostAttributes: { + role: 'listitem' + } + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-material/.bower.json b/third_party/polymer/v1_0/components/paper-material/.bower.json new file mode 100644 index 0000000..7775045 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-material/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-material", + "version": "1.0.0", + "description": "A material design container that looks like a lifted sheet of paper", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "container" + ], + "main": [ + "paper-material.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-material" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-material", + "ignore": [], + "dependencies": { + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "bd769d2b8c4f9ab000aee22582d76b5935793dc1" + }, + "_source": "git://github.com/PolymerElements/paper-material.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-material" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-material/.gitignore b/third_party/polymer/v1_0/components/paper-material/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-material/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-material/README.md b/third_party/polymer/v1_0/components/paper-material/README.md new file mode 100644 index 0000000..1105102 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-material/README.md @@ -0,0 +1,13 @@ +# paper-material +A Material Design container that looks like a lifted piece of paper. + +`paper-material` is a container that renders two shadows on top of each other to +create the effect of a lifted piece of paper. + +Example: + +```html +<paper-material elevation="1"> + ... content ... +</paper-material> +``` diff --git a/third_party/polymer/v1_0/components/paper-material/bower.json b/third_party/polymer/v1_0/components/paper-material/bower.json new file mode 100644 index 0000000..e6f78bc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-material/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-material", + "version": "1.0.0", + "description": "A material design container that looks like a lifted sheet of paper", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "web-component", + "polymer", + "paper", + "container" + ], + "main": [ + "paper-material.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-material" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-material", + "ignore": [], + "dependencies": { + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-material/index.html b/third_party/polymer/v1_0/components/paper-material/index.html new file mode 100644 index 0000000..7209e6d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-material/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-material</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-material/paper-material.html b/third_party/polymer/v1_0/components/paper-material/paper-material.html new file mode 100644 index 0000000..60f87ba --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-material/paper-material.html @@ -0,0 +1,98 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/shadow.html"> + +<!-- + +`paper-material` is a container that renders two shadows on top of each other to +create the effect of a lifted piece of paper. + +Example: + + <paper-material elevation="1"> + ... content ... + </paper-material> + +@group Paper Elements +@class paper-material +@demo demo/index.html +--> + +<dom-module id="paper-material"> + <style> + :host { + display: block; + position: relative; + @apply(--shadow-transition); + } + + :host([elevation="1"]) { + @apply(--shadow-elevation-2dp); + } + + :host([elevation="2"]) { + @apply(--shadow-elevation-4dp); + } + + :host([elevation="3"]) { + @apply(--shadow-elevation-6dp); + } + + :host([elevation="4"]) { + @apply(--shadow-elevation-8dp); + } + + :host([elevation="5"]) { + @apply(--shadow-elevation-16dp); + } + </style> + <template> + <content></content> + </template> +</dom-module> +<script> + Polymer({ + is: 'paper-material', + + properties: { + + /** + * The z-depth of this element, from 0-5. Setting to 0 will remove the + * shadow, and each increasing number greater than 0 will be "deeper" + * than the last. + * + * @attribute elevation + * @type number + * @default 1 + */ + elevation: { + type: Number, + reflectToAttribute: true, + value: 1 + }, + + /** + * Set this to true to animate the shadow when setting a new + * `elevation` value. + * + * @attribute animated + * @type boolean + * @default false + */ + animated: { + type: Boolean, + reflectToAttribute: true, + value: false + } + } + }); +</script> diff --git a/third_party/polymer/v1_0/components/paper-menu/.bower.json b/third_party/polymer/v1_0/components/paper-menu/.bower.json new file mode 100644 index 0000000..0e4dff9 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "paper-menu", + "version": "1.0.0", + "description": "Implements an accessible material design menu", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "menu" + ], + "main": "paper-menu.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-menu" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-menu", + "ignore": [], + "dependencies": { + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "0642450ec9df0fc0b1d909842f436c3dea79ed1e" + }, + "_source": "git://github.com/PolymerElements/paper-menu.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-menu" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-menu/.gitignore b/third_party/polymer/v1_0/components/paper-menu/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-menu/README.md b/third_party/polymer/v1_0/components/paper-menu/README.md new file mode 100644 index 0000000..9991680 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/README.md @@ -0,0 +1,3 @@ +# paper-menu + +`<paper-menu>` implements an accessible menu control with Material Design styling. diff --git a/third_party/polymer/v1_0/components/paper-menu/bower.json b/third_party/polymer/v1_0/components/paper-menu/bower.json new file mode 100644 index 0000000..dd2a5cd --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/bower.json @@ -0,0 +1,32 @@ +{ + "name": "paper-menu", + "version": "1.0.0", + "description": "Implements an accessible material design menu", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "menu" + ], + "main": "paper-menu.html", + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-menu" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-menu", + "ignore": [], + "dependencies": { + "iron-menu-behavior": "PolymerElements/iron-menu-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-item": "PolymerElements/paper-item#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-menu/hero.svg b/third_party/polymer/v1_0/components/paper-menu/hero.svg new file mode 100644 index 0000000..91af1f6 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/hero.svg @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="86.5" cy="39" r="4"/> + <path d="M138,44c-2,0-3.6-2.4-4.6-4.6c-1.1-2.1-1.7-3.4-3-3.4s-2,1.3-3,3.4c-1.1,2.1-2.2,4.6-4.9,4.6c-2.6,0-3.8-2.4-4.9-4.6 + c-1.1-2.1-1.8-3.4-3.1-3.4c-1.3,0-2,1.3-3.1,3.4c-1.1,2.1-2.3,4.6-4.9,4.6c-2.6,0-4.1-2.4-5.1-4.6C100.3,37.3,100,36,98,36v-2 + c3,0,4.1,2.4,5.1,4.6c1.1,2.1,1.9,3.4,3.2,3.4c1.3,0,2.1-1.3,3.2-3.4c1.1-2.1,2.3-4.6,4.9-4.6c2.6,0,3.8,2.4,4.9,4.6 + c1.1,2.1,1.8,3.4,3.1,3.4c1.3,0,2-1.3,3.1-3.4c1.1-2.1,2.3-4.6,4.9-4.6s3.6,2.4,4.6,4.6c1.1,2.1,1.9,3.4,2.9,3.4V44z"/> + <circle cx="86.5" cy="63" r="4"/> + <path d="M138,68c-2,0-3.6-2.4-4.6-4.6c-1.1-2.1-1.7-3.4-3-3.4s-2,1.3-3,3.4c-1.1,2.1-2.2,4.6-4.9,4.6c-2.6,0-3.8-2.4-4.9-4.6 + c-1.1-2.1-1.8-3.4-3.1-3.4c-1.3,0-2,1.3-3.1,3.4c-1.1,2.1-2.3,4.6-4.9,4.6c-2.6,0-4.1-2.4-5.1-4.6C100.3,61.3,100,60,98,60v-2 + c3,0,4.1,2.4,5.1,4.6c1.1,2.1,1.9,3.4,3.2,3.4c1.3,0,2.1-1.3,3.2-3.4c1.1-2.1,2.3-4.6,4.9-4.6c2.6,0,3.8,2.4,4.9,4.6 + c1.1,2.1,1.8,3.4,3.1,3.4c1.3,0,2-1.3,3.1-3.4c1.1-2.1,2.3-4.6,4.9-4.6s3.6,2.4,4.6,4.6c1.1,2.1,1.9,3.4,2.9,3.4V68z"/> + <circle cx="86.5" cy="88" r="4"/> + <path d="M138,93c-2,0-3.6-2.4-4.6-4.6c-1.1-2.1-1.7-3.4-3-3.4s-2,1.3-3,3.4c-1.1,2.1-2.2,4.6-4.9,4.6c-2.6,0-3.8-2.4-4.9-4.6 + c-1.1-2.1-1.8-3.4-3.1-3.4c-1.3,0-2,1.3-3.1,3.4c-1.1,2.1-2.3,4.6-4.9,4.6c-2.6,0-4.1-2.4-5.1-4.6C100.3,86.3,100,85,98,85v-2 + c3,0,4.1,2.4,5.1,4.6c1.1,2.1,1.9,3.4,3.2,3.4c1.3,0,2.1-1.3,3.2-3.4c1.1-2.1,2.3-4.6,4.9-4.6c2.6,0,3.8,2.4,4.9,4.6 + c1.1,2.1,1.8,3.4,3.1,3.4c1.3,0,2-1.3,3.1-3.4c1.1-2.1,2.3-4.6,4.9-4.6s3.6,2.4,4.6,4.6c1.1,2.1,1.9,3.4,2.9,3.4V93z"/> + <path d="M151,102H73V24h78V102z M75,100h74V26H75V100z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-menu/index.html b/third_party/polymer/v1_0/components/paper-menu/index.html new file mode 100644 index 0000000..fc88411 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-menu</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-menu/paper-menu.html b/third_party/polymer/v1_0/components/paper-menu/paper-menu.html new file mode 100644 index 0000000..45ecd72 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-menu/paper-menu.html @@ -0,0 +1,133 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-menu-behavior/iron-menu-behavior.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`<paper-menu>` implements an accessible menu control with Material Design styling. The focused item +is highlighted, and the selected item has bolded text. + + <paper-menu> + <paper-item>Item 1</paper-item> + <paper-item>Item 2</paper-item> + </paper-menu> + +Make a multi-select menu with the `multi` attribute. Items in a multi-select menu can be deselected, +and multiple item can be selected. + + <paper-menu multi> + <paper-item>Item 1</paper-item> + <paper-item>Item 2</paper-item> + </paper-menu> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-menu-background-color` | Menu background color | `--primary-background-color` +`-paper-menu-color` | Menu foreground color | `--primary-text-color` +`--paper-menu-disabled-color` | Foreground color for a disabled item | `--disabled-text-color` +`--paper-menu` | Mixin applied to the menu | `{}` +`--paper-menu-selected-item` | Mixin applied to the selected item | `{}` +`--paper-menu-focused-item` | Mixin applied to the focused item | `{}` +`--paper-menu-focused-item-after` | Mixin applied to the ::after pseudo-element for the focused item | `{}` + +### Accessibility + +`<paper-menu>` has `role="menu"` by default. A multi-select menu will also have +`aria-multiselectable` set. It implements key bindings to navigate through the menu with the up and +down arrow keys, esc to exit the menu, and enter to activate a menu item. Typing the first letter +of a menu item will also focus it. + +@group Paper Elements +@element paper-menu +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-menu"> + + <style> + + :host { + display: block; + padding: 8px 0; + + background: var(--paper-menu-background-color, --primary-background-color); + color: var(--paper-menu-color, --primary-text-color); + + @apply(--paper-menu); + } + + /* need a wrapper element to make this higher specificity than the :host rule in paper-item */ + .content > ::content > .iron-selected { + font-weight: bold; + + @apply(--paper-menu-selected-item); + } + + .content > ::content > [disabled] { + color: var(--paper-menu-disabled-color, --disabled-text-color); + } + + .content > ::content > *:focus { + position: relative; + outline: 0; + + @apply(--paper-menu-colored-focused-item); + } + + .content > ::content > *:focus:after { + @apply(--layout-fit); + background: currentColor; + /* FIXME move to paper-styles for next widget */ + opacity: 0.12; + content: ''; + + @apply(--paper-menu-colored-focused-item-after); + } + + .content > ::content > *[colored]:focus:after { + opacity: 0.26; + } + + </style> + + <template> + + <div class="content"> + <content></content> + </div> + + </template> + +</dom-module> + +<script> + +(function() { + + Polymer({ + + is: 'paper-menu', + + behaviors: [ + Polymer.IronMenuBehavior + ] + + }); + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-progress/.bower.json b/third_party/polymer/v1_0/components/paper-progress/.bower.json new file mode 100644 index 0000000..100fe00 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "paper-progress", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design progress bar", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "progress" + ], + "main": [ + "paper-progress.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-progress.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-progress", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "1bef80a0d4110654b85746e70c006796ce8cdc2c" + }, + "_source": "git://github.com/PolymerElements/paper-progress.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-progress" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-progress/.gitignore b/third_party/polymer/v1_0/components/paper-progress/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-progress/README.md b/third_party/polymer/v1_0/components/paper-progress/README.md new file mode 100644 index 0000000..7aaf060 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/README.md @@ -0,0 +1,47 @@ +paper-progress +=================== + +The progress bars are for situations where the percentage completed can be +determined. They give users a quick sense of how much longer an operation +will take. + +Example: + +```html +<paper-progress value="10"></paper-progress> +``` + +There is also a secondary progress which is useful for displaying intermediate +progress, such as the buffer level during a streaming playback progress bar. + +Example: + +```html +<paper-progress value="10" secondaryProgress="30"></paper-progress> +``` + +Styling progress bar: + +To change the active progress bar color: + +```css +paper-progress { + --paper-progress-active-color: #e91e63; +} +``` + +To change the secondary progress bar color: + +```css +paper-progress { + --paper-progress-secondary-color: #f8bbd0; +} +``` + +To change the progress bar background color: + +```css +paper-progress { + --paper-progress-container-color: #64ffda; +} +``` diff --git a/third_party/polymer/v1_0/components/paper-progress/bower.json b/third_party/polymer/v1_0/components/paper-progress/bower.json new file mode 100644 index 0000000..8c17acb --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/bower.json @@ -0,0 +1,31 @@ +{ + "name": "paper-progress", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design progress bar", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "progress" + ], + "main": [ + "paper-progress.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-progress.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-range-behavior": "PolymerElements/iron-range-behavior#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-button": "PolymerElements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-progress/hero.svg b/third_party/polymer/v1_0/components/paper-progress/hero.svg new file mode 100644 index 0000000..dc422a4 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/hero.svg @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <rect x="57" y="59" width="20" height="2"/> + <rect x="38" y="59" width="11" height="2"/> + <rect x="84" y="59" width="40" height="2"/> + <rect x="133" y="59" width="54" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-progress/index.html b/third_party/polymer/v1_0/components/paper-progress/index.html new file mode 100644 index 0000000..225e3dd --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-progress</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-progress/paper-progress.html b/third_party/polymer/v1_0/components/paper-progress/paper-progress.html new file mode 100644 index 0000000..949e1bc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-progress/paper-progress.html @@ -0,0 +1,199 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> + +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="../iron-range-behavior/iron-range-behavior.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<!-- +The progress bars are for situations where the percentage completed can be +determined. They give users a quick sense of how much longer an operation +will take. + +Example: + + <paper-progress value="10"></paper-progress> + +There is also a secondary progress which is useful for displaying intermediate +progress, such as the buffer level during a streaming playback progress bar. + +Example: + + <paper-progress value="10" secondary-progress="30"></paper-progress> + +Styling progress bar: + +To change the active progress bar color: + + paper-progress { + --paper-progress-active-color: #e91e63; + } + +To change the secondary progress bar color: + + paper-progress { + --paper-progress-secondary-color: #f8bbd0; + } + +To change the progress bar background color: + + paper-progress { + --paper-progress-container-color: #64ffda; + } + +@group Paper Elements +@element paper-progress +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-progress"> + <style> + :host { + display: inline-block; + width: 200px; + height: 4px; + } + + #progressContainer { + position: relative; + height: 100%; + background-color: var(--paper-progress-container-color, --google-grey-300); + overflow: hidden; + } + + #activeProgress, + #secondaryProgress { + -webkit-transform-origin: left center; + transform-origin: left center; + -webkit-transform: scaleX(0); + transform: scaleX(0); + } + + #activeProgress { + background-color: var(--paper-progress-active-color, --google-green-500); + } + + #secondaryProgress { + background-color: var(--paper-progress-secondary-color, --google-green-100); + } + + #activeProgress.indeterminate { + -webkit-transform-origin: center center; + transform-origin: center center; + -webkit-animation: indeterminate-bar 1s linear infinite; + animation: indeterminate-bar 1s linear infinite; + } + + @-webkit-keyframes indeterminate-bar { + 0% { + -webkit-transform: translate(-50%) scaleX(0); + } + 50% { + -webkit-transform: translate(0%) scaleX(0.3); + } + 100% { + -webkit-transform: translate(50%) scaleX(0); + } + } + + @keyframes indeterminate-bar { + 0% { + transform: translate(-50%) scaleX(0); + } + 50% { + transform: translate(0%) scaleX(0.3); + } + 100% { + transform: translate(50%) scaleX(0); + } + } + </style> + <template> + <div id="progressContainer" role="progressbar" aria-valuenow$="{{value}}" aria-valuemin$="{{min}}" aria-valuemax$="{{max}}"> + <div id="secondaryProgress" class="fit"></div> + <div id="activeProgress" class="fit"></div> + </div> + </template> +</dom-module> + +<script> + Polymer({ + + is: 'paper-progress', + + behaviors: [ + Polymer.IronRangeBehavior + ], + + properties: { + + /** + * The number that represents the current secondary progress. + */ + secondaryProgress: { + type: Number, + value: 0, + notify: true + }, + + /** + * The secondary ratio + */ + secondaryRatio: { + type: Number, + value: 0, + readOnly: true, + observer: '_secondaryRatioChanged' + }, + + /** + * Use an indeterminate progress indicator. + */ + indeterminate: { + type: Boolean, + value: false, + notify: true, + observer: '_toggleIndeterminate' + } + }, + + observers: [ + '_ratioChanged(ratio)', + '_secondaryProgressChanged(secondaryProgress, min, max)' + ], + + _toggleIndeterminate: function() { + // If we use attribute/class binding, the animation sometimes doesn't translate properly + // on Safari 7.1. So instead, we toggle the class here in the update method. + this.toggleClass('indeterminate', this.indeterminate, this.$.activeProgress); + }, + + _transformProgress: function(progress, ratio) { + var transform = 'scaleX(' + (ratio / 100) + ')'; + progress.style.transform = progress.style.webkitTransform = transform; + }, + + _ratioChanged: function(ratio) { + this._transformProgress(this.$.activeProgress, ratio); + }, + + _secondaryRatioChanged: function(secondaryRatio) { + this._transformProgress(this.$.secondaryProgress, secondaryRatio); + }, + + _secondaryProgressChanged: function() { + this.secondaryProgress = this._clampValue(this.secondaryProgress); + this._setSecondaryRatio(this._calcRatio(this.secondaryProgress) * 100); + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-radio-button/.bower.json b/third_party/polymer/v1_0/components/paper-radio-button/.bower.json new file mode 100644 index 0000000..a5e2700 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-radio-button", + "version": "1.0.1", + "description": "A material design radio button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerLabs/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "922027de73c04f430d74679a167651a8c1db97e8" + }, + "_source": "git://github.com/PolymerElements/paper-radio-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-radio-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-radio-button/.gitignore b/third_party/polymer/v1_0/components/paper-radio-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-radio-button/README.md b/third_party/polymer/v1_0/components/paper-radio-button/README.md new file mode 100644 index 0000000..f1bdf54 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/README.md @@ -0,0 +1,29 @@ +# paper-radio-button + +`paper-radio-button` is a button that can be either checked or unchecked. +User can tap the radio button to check it. But it cannot be unchecked by +tapping once checked. + +Use `paper-radio-group` to group a set of radio buttons. When radio buttons +are inside a radio group, only one radio button in the group can be checked. + +Example: + +```html +<paper-radio-button></paper-radio-button> +``` +Styling a radio button: + +```html +<style is="custom-style"> + :root { + /* Unchecked state colors. */ + --paper-radio-button-unchecked-color: #5a5a5a; + --paper-radio-button-unchecked-ink-color: #5a5a5a; + + /* Checked state colors. */ + --paper-radio-button-checked-color: #009688; + --paper-radio-button-checked-ink-color: #0f9d58; + } +</style> +``` diff --git a/third_party/polymer/v1_0/components/paper-radio-button/bower.json b/third_party/polymer/v1_0/components/paper-radio-button/bower.json new file mode 100644 index 0000000..51165feb --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/bower.json @@ -0,0 +1,35 @@ +{ + "name": "paper-radio-button", + "version": "1.0.1", + "description": "A material design radio button", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerLabs/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-radio-button/hero.svg b/third_party/polymer/v1_0/components/paper-radio-button/hero.svg new file mode 100644 index 0000000..7fbac94 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/hero.svg @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="112.5" cy="63" r="8"/> + <path d="M112.5,80c-9.4,0-17-7.6-17-17s7.6-17,17-17s17,7.6,17,17S121.9,80,112.5,80z M112.5,48c-8.3,0-15,6.7-15,15s6.7,15,15,15 + s15-6.7,15-15S120.8,48,112.5,48z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-radio-button/index.html b/third_party/polymer/v1_0/components/paper-radio-button/index.html new file mode 100644 index 0000000..a564b41 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-radio-button</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-radio-button/paper-radio-button.css b/third_party/polymer/v1_0/components/paper-radio-button/paper-radio-button.css new file mode 100644 index 0000000..dcb9695 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/paper-radio-button.css @@ -0,0 +1,109 @@ +/* +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: inline-block; + white-space: nowrap; +} + +:host(:focus) { + outline: none; +} + +#radioContainer { + display: inline-block; + position: relative; + width: 16px; + height: 16px; + cursor: pointer; + vertical-align: middle; +} + +:host #ink { + position: absolute; + top: -16px; + left: -16px; + width: 48px; + height: 48px; + color: var(--paper-radio-button-unchecked-ink-color); + opacity: 0.6; +} + +:host #ink[checked] { + color: var(--paper-radio-button-checked-ink-color); +} + +:host #offRadio { + position: absolute; + top: 0px; + left: 0px; + width: 12px; + height: 12px; + border-radius: 50%; + border: solid 2px; + border-color: var(--paper-radio-button-unchecked-color); + transition: border-color 0.28s; +} + +:host #onRadio { + position: absolute; + top: 4px; + left: 4px; + width: 8px; + height: 8px; + border-radius: 50%; + background-color: var(--paper-radio-button-checked-color); + -webkit-transform: scale(0); + transform: scale(0); + transition: -webkit-transform ease 0.28s; + transition: transform ease 0.28s; +} + +:host([checked]) #offRadio { + border-color: var(--paper-radio-button-checked-color); +} + +:host([checked]) #onRadio { + -webkit-transform: scale(1); + transform: scale(1); +} + +#radioLabel { + position: relative; + display: inline-block; + vertical-align: middle; + margin-left: 10px; + white-space: normal; + pointer-events: none; + color: var(--paper-radio-button-label-color); +} + +#radioLabel[hidden] { + display: none; +} + +/* disabled state */ +:host([disabled]) { + pointer-events: none; +} + +:host([disabled]) #offRadio { + border-color: var(--paper-radio-button-unchecked-color); + opacity: 0.5; +} + +:host([disabled][checked]) #onRadio { + background-color: var(--paper-radio-button-unchecked-color); + opacity: 0.5; +} + +:host([disabled]) #radioLabel { + /* slightly darker than the button, so that it's readable */ + opacity: 0.65; +} diff --git a/third_party/polymer/v1_0/components/paper-radio-button/paper-radio-button.html b/third_party/polymer/v1_0/components/paper-radio-button/paper-radio-button.html new file mode 100644 index 0000000..ab67812 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-button/paper-radio-button.html @@ -0,0 +1,148 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-styles/default-theme.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> + +<!-- +`paper-radio-button` is a button that can be either checked or unchecked. +User can tap the radio button to check it. But it cannot be unchecked by +tapping once checked. + +Use `paper-radio-group` to group a set of radio buttons. When radio buttons +are inside a radio group, only one radio button in the group can be checked. + +Example: + + <paper-radio-button></paper-radio-button> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-radio-button-unchecked-color` | Radio button color when the input is not checked | `--primary-text-color` +`--paper-radio-button-unchecked-ink-color` | Selected/focus ripple color when the input is not checked | `--primary-text-color` +`--paper-radio-button-checked-color` | Radio button color when the input is checked | `--default-primary-color` +`--paper-radio-button-checked-ink-color` | Selected/focus ripple color when the input is checked | `--default-primary-color` +`--paper-radio-button-label-color` | Label color | `--primary-text-color` + +@group Paper Elements +@element paper-radio-button +@hero hero.svg +@demo demo/index.html +--> + +<style is="custom-style"> + :root { + --paper-radio-button-unchecked-color: var(--primary-text-color); + --paper-radio-button-unchecked-ink-color: var(--primary-text-color); + + --paper-radio-button-checked-color: var(--default-primary-color); + --paper-radio-button-checked-ink-color: var(--default-primary-color); + + --paper-radio-button-label-color: var(--primary-text-color); + } +</style> + +<dom-module id="paper-radio-button"> + + <link rel="import" type="css" href="paper-radio-button.css"> + + <template> + + <div id="radioContainer"> + <div id="offRadio"></div> + <div id="onRadio"></div> + <paper-ripple id="ink" class="circle" center checked$="[[checked]]"></paper-ripple> + </div> + + <div id="radioLabel" aria-hidden="true"><content></content></div> + + </template> + + <script> + Polymer({ + is: 'paper-radio-button', + + behaviors: [ + Polymer.PaperRadioButtonBehavior + ], + + hostAttributes: { + role: 'radio', + 'aria-checked': false, + tabindex: 0 + }, + + properties: { + /** + * Fired when the checked state changes due to user interaction. + * + * @event change + */ + + /** + * Fired when the checked state changes. + * + * @event iron-change + */ + + /** + * Gets or sets the state, `true` is checked and `false` is unchecked. + */ + checked: { + type: Boolean, + value: false, + reflectToAttribute: true, + notify: true, + observer: '_checkedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + */ + toggles: { + type: Boolean, + value: true, + reflectToAttribute: true + } + }, + + ready: function() { + if (Polymer.dom(this).textContent == '') { + this.$.radioLabel.hidden = true; + } else { + this.setAttribute('aria-label', Polymer.dom(this).textContent); + } + this._isReady = true; + }, + + _buttonStateChanged: function() { + if (this.disabled) { + return; + } + if (this._isReady) { + this.checked = this.active; + } + }, + + _checkedChanged: function() { + this.setAttribute('aria-checked', this.checked ? 'true' : 'false'); + this.active = this.checked; + this.fire('iron-change'); + } + }) + </script> + +</dom-module> diff --git a/third_party/polymer/v1_0/components/paper-radio-group/.bower.json b/third_party/polymer/v1_0/components/paper-radio-group/.bower.json new file mode 100644 index 0000000..5c09912 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-radio-group", + "version": "1.0.1", + "description": "A group of material design radio buttons", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-group" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-group", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "b69ba0adcdc5e43773933e91009298360363b7bb" + }, + "_source": "git://github.com/PolymerElements/paper-radio-group.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-radio-group" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-radio-group/.gitignore b/third_party/polymer/v1_0/components/paper-radio-group/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-radio-group/README.md b/third_party/polymer/v1_0/components/paper-radio-group/README.md new file mode 100644 index 0000000..0b02d58 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/README.md @@ -0,0 +1,20 @@ +paper-radio-group +================= + +`paper-radio-group` allows user to select only one radio button from a set. +Checking one radio button that belongs to a radio group unchecks any +previously checked radio button within the same group. Use +`selected` to get or set the selected radio button. + +Example: + +```html +<paper-radio-group selected="small"> + <paper-radio-button name="small" label="Small"></paper-radio-button> + <paper-radio-button name="medium" label="Medium"></paper-radio-button> + <paper-radio-button name="large" label="Large"></paper-radio-button> +</paper-radio-group> +``` + +See <a href="paper-radio-button.html">paper-radio-button</a> for more +information about `paper-radio-button`. diff --git a/third_party/polymer/v1_0/components/paper-radio-group/bower.json b/third_party/polymer/v1_0/components/paper-radio-group/bower.json new file mode 100644 index 0000000..10e8b51 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-radio-group", + "version": "1.0.1", + "description": "A group of material design radio buttons", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "radio", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-radio-group" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-radio-group", + "ignore": [], + "dependencies": { + "iron-selector": "PolymerElements/iron-selector#^1.0.0", + "iron-a11y-keys-behavior": "PolymerElements/iron-a11y-keys-behavior#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "paper-radio-button": "PolymerElements/paper-radio-button#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-radio-group/hero.svg b/third_party/polymer/v1_0/components/paper-radio-group/hero.svg new file mode 100644 index 0000000..fc78ba7 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/hero.svg @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="112.5" cy="41" r="8"/> + <path d="M112.5,58c-9.4,0-17-7.6-17-17s7.6-17,17-17s17,7.6,17,17S121.9,58,112.5,58z M112.5,26c-8.3,0-15,6.7-15,15s6.7,15,15,15 + s15-6.7,15-15S120.8,26,112.5,26z"/> + <circle cx="112.5" cy="85" r="8"/> + <path d="M112.5,102c-9.4,0-17-7.6-17-17s7.6-17,17-17s17,7.6,17,17S121.9,102,112.5,102z M112.5,70c-8.3,0-15,6.7-15,15 + s6.7,15,15,15s15-6.7,15-15S120.8,70,112.5,70z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-radio-group/index.html b/third_party/polymer/v1_0/components/paper-radio-group/index.html new file mode 100644 index 0000000..966c717 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-radio-group</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-radio-group/paper-radio-group.html b/third_party/polymer/v1_0/components/paper-radio-group/paper-radio-group.html new file mode 100644 index 0000000..7960f27 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-radio-group/paper-radio-group.html @@ -0,0 +1,186 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-selector/iron-selector.html"> +<link rel="import" href="../paper-radio-button/paper-radio-button.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + +<!-- +`paper-radio-group` allows user to select only one radio button from a set. +Checking one radio button that belongs to a radio group unchecks any +previously checked radio button within the same group. Use +`selected` to get or set the selected radio button. + +Example: + + <paper-radio-group selected="small"> + <paper-radio-button name="small" label="Small"></paper-radio-button> + <paper-radio-button name="medium" label="Medium"></paper-radio-button> + <paper-radio-button name="large" label="Large"></paper-radio-button> + </paper-radio-group> + +See <a href="paper-radio-button.html">paper-radio-button</a> for more +information about `paper-radio-button`. + +@group Paper Elements +@element paper-radio-group +@hero hero.svg +@demo demo/index.html +--> + +<dom-module name="paper-radio-group"> + <style> + :host { + display: inline-block; + } + + iron-selector ::content > * { + padding: 12px; + } + </style> + + <template> + <iron-selector selected="{{selected}}" attr-for-selected="name" + selectable="paper-radio-button"> + <content id="items" select="*"></content> + </iron-selector> + </template> + +</dom-module> + +<script> + Polymer({ + is: 'paper-radio-group', + + behaviors: [ + Polymer.IronA11yKeysBehavior + ], + + hostAttributes: { + role: 'radiogroup', + tabindex: 0 + }, + + properties: { + /** + * Fired when the selected element changes to user interaction. + * + * @event paper-radio-group-changed + */ + + /** + * Gets or sets the selected element. Use the `name` attribute of the + * <paper-radio-button> that should be selected. + * + * @attribute selected + * @type String + * @default null + */ + + selected: { + type: String, + value: null, + notify: true, + reflectToAttribute: true, + observer: "_selectedChanged" + } + }, + + keyBindings: { + 'left up': '_selectPrevious', + 'right down': '_selectNext', + }, + + _selectedChanged: function() { + // TODO: This only needs to be async while a domReady event is unavailable. + this.async(function() { + this._selectIndex(this._valueToIndex(this.items, this.selected)); + this.fire('paper-radio-group-changed'); + }); + }, + + _selectNext: function() { + this.selected = this._nextNode(); + }, + + _selectPrevious: function() { + this.selected = this._previousNode(); + }, + + /** + * Returns an array of all items. + * + * @property items + * @type array + */ + get items() { + return Polymer.dom(this.$.items).getDistributedNodes(); + }, + + _nextNode: function() { + var items = this.items; + var index = this._selectedIndex; + var newIndex = index; + do { + newIndex = (newIndex + 1) % items.length; + if (newIndex === index) { + break; + } + } while (items[newIndex].disabled); + return this._valueForNode(items[newIndex]); + }, + + _previousNode: function() { + var items = this.items; + var index = this._selectedIndex; + var newIndex = index; + do { + newIndex = (newIndex || items.length) - 1; + if (newIndex === index) { + break; + } + } while (items[newIndex].disabled); + return this._valueForNode(items[newIndex]); + }, + + _selectIndex: function(index) { + if (index == this._selectedIndex) + return; + + var nodes = this.items; + + // If there was a previously selected node, deselect it. + if (nodes[this._selectedIndex]) { + nodes[this._selectedIndex].checked = false; + } + + // Select a new node. + nodes[index].checked = true; + nodes[index].focus(); + this._selectedIndex = index; + }, + + _valueForNode: function(node) { + return node["name"] || node.getAttribute("name"); + }, + + // Finds an item with value == |value| and return its index. + _valueToIndex: function(items, value) { + for (var index = 0, node; (node = items[index]); index++) { + if (this._valueForNode(node) == value) { + return index; + } + } + // If no item found, the value itself is probably the index. + return value; + } + }); +</script> diff --git a/third_party/polymer/v1_0/components/paper-ripple/.bower.json b/third_party/polymer/v1_0/components/paper-ripple/.bower.json new file mode 100644 index 0000000..1b45160 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/.bower.json @@ -0,0 +1,39 @@ +{ + "name": "paper-ripple", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Adds a material design ripple to any container", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "ripple" + ], + "main": "paper-ripple.html", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-ripple", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "bcf189cf43bd935dec7a09868988f33a7bdd25fe" + }, + "_source": "git://github.com/PolymerElements/paper-ripple.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-ripple" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-ripple/.gitignore b/third_party/polymer/v1_0/components/paper-ripple/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-ripple/README.md b/third_party/polymer/v1_0/components/paper-ripple/README.md new file mode 100644 index 0000000..b9bde23 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/README.md @@ -0,0 +1,65 @@ +paper-ripple +============ + +`paper-ripple` provides a visual effect that other paper elements can +use to simulate a rippling effect emanating from the point of contact. The +effect can be visualized as a concentric circle with motion. + +Example: + +```html +<paper-ripple></paper-ripple> +``` + +`paper-ripple` listens to "mousedown" and "mouseup" events so it would display ripple +effect when touches on it. You can also defeat the default behavior and +manually route the down and up actions to the ripple element. Note that it is +important if you call downAction() you will have to make sure to call +upAction() so that `paper-ripple` would end the animation loop. + +Example: + +```html +<paper-ripple id="ripple" style="pointer-events: none;"></paper-ripple> +... +<script> + downAction: function(e) { + this.$.ripple.downAction({x: e.x, y: e.y}); + }, + upAction: function(e) { + this.$.ripple.upAction(); + } +</script> +``` + +Styling ripple effect: + +Use CSS color property to style the ripple: + +```css +paper-ripple { + color: #4285f4; +} +``` + +Note that CSS color property is inherited so it is not required to set it on +the `paper-ripple` element directly. + + +By default, the ripple is centered on the point of contact. Apply the ``recenters`` attribute to have the ripple grow toward the center of its container. + +```html +<paper-ripple recenters></paper-ripple> +``` + +Apply `center` to center the ripple inside its container from the start. + +```html +<paper-ripple center></paper-ripple> +``` + +Apply `circle` class to make the rippling effect within a circle. + +```html +<paper-ripple class="circle"></paper-ripple> +``` diff --git a/third_party/polymer/v1_0/components/paper-ripple/bower.json b/third_party/polymer/v1_0/components/paper-ripple/bower.json new file mode 100644 index 0000000..55b8678 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/bower.json @@ -0,0 +1,29 @@ +{ + "name": "paper-ripple", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Adds a material design ripple to any container", + "private": true, + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "ripple" + ], + "main": "paper-ripple.html", + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-keys-behavior": "polymerelements/iron-a11y-keys-behavior#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-icons": "polymerelements/iron-icons#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-ripple/hero.svg b/third_party/polymer/v1_0/components/paper-ripple/hero.svg new file mode 100644 index 0000000..f8a872f --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/hero.svg @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M175,81H49V45h126V81z M51,79h122V47H51V79z"/> + <g> + <defs> + <rect id="SVGID_5_" x="50" y="46" width="124" height="34"/> + </defs> + <clipPath id="SVGID_2_"> + <use xlink:href="#SVGID_5_" overflow="visible"/> + </clipPath> + <circle opacity="0.5" clip-path="url(#SVGID_2_)" cx="84.4" cy="62.7" r="41.9"/> + <circle opacity="0.6" clip-path="url(#SVGID_2_)" cx="84.4" cy="62.7" r="26.3"/> + <circle opacity="0.6" clip-path="url(#SVGID_2_)" cx="66.4" cy="62.7" r="26.3"/> + </g> + <circle cx="50" cy="80" r="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-ripple/index.html b/third_party/polymer/v1_0/components/paper-ripple/index.html new file mode 100644 index 0000000..3c371fa --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/index.html @@ -0,0 +1,27 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>paper-ripple</title> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-ripple/paper-ripple.html b/third_party/polymer/v1_0/components/paper-ripple/paper-ripple.html new file mode 100644 index 0000000..704738c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-ripple/paper-ripple.html @@ -0,0 +1,714 @@ +<!-- +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-a11y-keys-behavior/iron-a11y-keys-behavior.html"> + +<!-- +`paper-ripple` provides a visual effect that other paper elements can +use to simulate a rippling effect emanating from the point of contact. The +effect can be visualized as a concentric circle with motion. + +Example: + + <paper-ripple></paper-ripple> + +`paper-ripple` listens to "mousedown" and "mouseup" events so it would display ripple +effect when touches on it. You can also defeat the default behavior and +manually route the down and up actions to the ripple element. Note that it is +important if you call downAction() you will have to make sure to call +upAction() so that `paper-ripple` would end the animation loop. + +Example: + + <paper-ripple id="ripple" style="pointer-events: none;"></paper-ripple> + ... + downAction: function(e) { + this.$.ripple.downAction({x: e.x, y: e.y}); + }, + upAction: function(e) { + this.$.ripple.upAction(); + } + +Styling ripple effect: + + Use CSS color property to style the ripple: + + paper-ripple { + color: #4285f4; + } + + Note that CSS color property is inherited so it is not required to set it on + the `paper-ripple` element directly. + +By default, the ripple is centered on the point of contact. Apply the `recenters` +attribute to have the ripple grow toward the center of its container. + + <paper-ripple recenters></paper-ripple> + +You can also center the ripple inside its container from the start. + + <paper-ripple center></paper-ripple> + +Apply `circle` class to make the rippling effect within a circle. + + <paper-ripple class="circle"></paper-ripple> + +@group Paper Elements +@element paper-ripple +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-ripple"> + + <!-- + Fired when the animation finishes. This is useful if you want to wait until the ripple + animation finishes to perform some action. + + @event transitionend + @param {Object} detail + @param {Object} detail.node The animated node + --> + + <style> + :host { + display: block; + position: absolute; + border-radius: inherit; + overflow: hidden; + top: 0; + left: 0; + right: 0; + bottom: 0; + } + + :host([animating]) { + /* This resolves a rendering issue in Chrome (as of 40) where the + ripple is not properly clipped by its parent (which may have + rounded corners). See: http://jsbin.com/temexa/4 + + Note: We only apply this style conditionally. Otherwise, the browser + will create a new compositing layer for every ripple element on the + page, and that would be bad. */ + -webkit-transform: translate(0, 0); + transform: translate3d(0, 0, 0); + } + + :host([noink]) { + pointer-events: none; + } + + #background, + #waves, + .wave-container, + .wave { + pointer-events: none; + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + } + + #background, + .wave { + opacity: 0; + } + + #waves, + .wave { + overflow: hidden; + } + + .wave-container, + .wave { + border-radius: 50%; + } + + :host(.circle) #background, + :host(.circle) #waves { + border-radius: 50%; + } + + :host(.circle) .wave-container { + overflow: hidden; + } + + </style> + <template> + <div id="background"></div> + <div id="waves"></div> + </template> +</dom-module> +<script> + (function() { + var Utility = { + cssColorWithAlpha: function(cssColor, alpha) { + var parts = cssColor.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/); + + if (typeof alpha == 'undefined') { + alpha = 1; + } + + if (!parts) { + return 'rgba(255, 255, 255, ' + alpha + ')'; + } + + return 'rgba(' + parts[1] + ', ' + parts[2] + ', ' + parts[3] + ', ' + alpha + ')'; + }, + + distance: function(x1, y1, x2, y2) { + var xDelta = (x1 - x2); + var yDelta = (y1 - y2); + + return Math.sqrt(xDelta * xDelta + yDelta * yDelta); + }, + + now: (function() { + if (window.performance && window.performance.now) { + return window.performance.now.bind(window.performance); + } + + return Date.now; + })() + }; + + /** + * @param {HTMLElement} element + * @constructor + */ + function ElementMetrics(element) { + this.element = element; + this.width = this.boundingRect.width; + this.height = this.boundingRect.height; + + this.size = Math.max(this.width, this.height); + } + + ElementMetrics.prototype = { + get boundingRect () { + return this.element.getBoundingClientRect(); + }, + + furthestCornerDistanceFrom: function(x, y) { + var topLeft = Utility.distance(x, y, 0, 0); + var topRight = Utility.distance(x, y, this.width, 0); + var bottomLeft = Utility.distance(x, y, 0, this.height); + var bottomRight = Utility.distance(x, y, this.width, this.height); + + return Math.max(topLeft, topRight, bottomLeft, bottomRight); + } + }; + + /** + * @param {HTMLElement} element + * @constructor + */ + function Ripple(element) { + this.element = element; + this.color = window.getComputedStyle(element).color; + + this.wave = document.createElement('div'); + this.waveContainer = document.createElement('div'); + this.wave.style.backgroundColor = this.color; + this.wave.classList.add('wave'); + this.waveContainer.classList.add('wave-container'); + Polymer.dom(this.waveContainer).appendChild(this.wave); + + this.resetInteractionState(); + } + + Ripple.MAX_RADIUS = 300; + + Ripple.prototype = { + get recenters() { + return this.element.recenters; + }, + + get center() { + return this.element.center; + }, + + get mouseDownElapsed() { + var elapsed; + + if (!this.mouseDownStart) { + return 0; + } + + elapsed = Utility.now() - this.mouseDownStart; + + if (this.mouseUpStart) { + elapsed -= this.mouseUpElapsed; + } + + return elapsed; + }, + + get mouseUpElapsed() { + return this.mouseUpStart ? + Utility.now () - this.mouseUpStart : 0; + }, + + get mouseDownElapsedSeconds() { + return this.mouseDownElapsed / 1000; + }, + + get mouseUpElapsedSeconds() { + return this.mouseUpElapsed / 1000; + }, + + get mouseInteractionSeconds() { + return this.mouseDownElapsedSeconds + this.mouseUpElapsedSeconds; + }, + + get initialOpacity() { + return this.element.initialOpacity; + }, + + get opacityDecayVelocity() { + return this.element.opacityDecayVelocity; + }, + + get radius() { + var width2 = this.containerMetrics.width * this.containerMetrics.width; + var height2 = this.containerMetrics.height * this.containerMetrics.height; + var waveRadius = Math.min( + Math.sqrt(width2 + height2), + Ripple.MAX_RADIUS + ) * 1.1 + 5; + + var duration = 1.1 - 0.2 * (waveRadius / Ripple.MAX_RADIUS); + var timeNow = this.mouseInteractionSeconds / duration; + var size = waveRadius * (1 - Math.pow(80, -timeNow)); + + return Math.abs(size); + }, + + get opacity() { + if (!this.mouseUpStart) { + return this.initialOpacity; + } + + return Math.max( + 0, + this.initialOpacity - this.mouseUpElapsedSeconds * this.opacityDecayVelocity + ); + }, + + get outerOpacity() { + // Linear increase in background opacity, capped at the opacity + // of the wavefront (waveOpacity). + var outerOpacity = this.mouseUpElapsedSeconds * 0.3; + var waveOpacity = this.opacity; + + return Math.max( + 0, + Math.min(outerOpacity, waveOpacity) + ); + }, + + get isOpacityFullyDecayed() { + return this.opacity < 0.01 && + this.radius >= Math.min(this.maxRadius, Ripple.MAX_RADIUS); + }, + + get isRestingAtMaxRadius() { + return this.opacity >= this.initialOpacity && + this.radius >= Math.min(this.maxRadius, Ripple.MAX_RADIUS); + }, + + get isAnimationComplete() { + return this.mouseUpStart ? + this.isOpacityFullyDecayed : this.isRestingAtMaxRadius; + }, + + get translationFraction() { + return Math.min( + 1, + this.radius / this.containerMetrics.size * 2 / Math.sqrt(2) + ); + }, + + get xNow() { + if (this.xEnd) { + return this.xStart + this.translationFraction * (this.xEnd - this.xStart); + } + + return this.xStart; + }, + + get yNow() { + if (this.yEnd) { + return this.yStart + this.translationFraction * (this.yEnd - this.yStart); + } + + return this.yStart; + }, + + get isMouseDown() { + return this.mouseDownStart && !this.mouseUpStart; + }, + + resetInteractionState: function() { + this.maxRadius = 0; + this.mouseDownStart = 0; + this.mouseUpStart = 0; + + this.xStart = 0; + this.yStart = 0; + this.xEnd = 0; + this.yEnd = 0; + this.slideDistance = 0; + + this.containerMetrics = new ElementMetrics(this.element); + }, + + draw: function() { + var scale; + var translateString; + var dx; + var dy; + + this.wave.style.opacity = this.opacity; + + scale = this.radius / (this.containerMetrics.size / 2); + dx = this.xNow - (this.containerMetrics.width / 2); + dy = this.yNow - (this.containerMetrics.height / 2); + + + // 2d transform for safari because of border-radius and overflow:hidden clipping bug. + // https://bugs.webkit.org/show_bug.cgi?id=98538 + this.waveContainer.style.webkitTransform = 'translate(' + dx + 'px, ' + dy + 'px)'; + this.waveContainer.style.transform = 'translate3d(' + dx + 'px, ' + dy + 'px, 0)'; + this.wave.style.webkitTransform = 'scale(' + scale + ',' + scale + ')'; + this.wave.style.transform = 'scale3d(' + scale + ',' + scale + ',1)'; + }, + + downAction: function(event) { + var xCenter = this.containerMetrics.width / 2; + var yCenter = this.containerMetrics.height / 2; + + this.resetInteractionState(); + this.mouseDownStart = Utility.now(); + + if (this.center) { + this.xStart = xCenter; + this.yStart = yCenter; + this.slideDistance = Utility.distance( + this.xStart, this.yStart, this.xEnd, this.yEnd + ); + } else { + this.xStart = event ? + event.detail.x - this.containerMetrics.boundingRect.left : + this.containerMetrics.width / 2; + this.yStart = event ? + event.detail.y - this.containerMetrics.boundingRect.top : + this.containerMetrics.height / 2; + } + + if (this.recenters) { + this.xEnd = xCenter; + this.yEnd = yCenter; + this.slideDistance = Utility.distance( + this.xStart, this.yStart, this.xEnd, this.yEnd + ); + } + + this.maxRadius = this.containerMetrics.furthestCornerDistanceFrom( + this.xStart, + this.yStart + ); + + this.waveContainer.style.top = + (this.containerMetrics.height - this.containerMetrics.size) / 2 + 'px'; + this.waveContainer.style.left = + (this.containerMetrics.width - this.containerMetrics.size) / 2 + 'px'; + + this.waveContainer.style.width = this.containerMetrics.size + 'px'; + this.waveContainer.style.height = this.containerMetrics.size + 'px'; + }, + + upAction: function(event) { + if (!this.isMouseDown) { + return; + } + + this.mouseUpStart = Utility.now(); + }, + + remove: function() { + Polymer.dom(this.waveContainer.parentNode).removeChild( + this.waveContainer + ); + } + }; + + Polymer({ + is: 'paper-ripple', + + behaviors: [ + Polymer.IronA11yKeysBehavior + ], + + properties: { + /** + * The initial opacity set on the wave. + * + * @attribute initialOpacity + * @type number + * @default 0.25 + */ + initialOpacity: { + type: Number, + value: 0.25 + }, + + /** + * How fast (opacity per second) the wave fades out. + * + * @attribute opacityDecayVelocity + * @type number + * @default 0.8 + */ + opacityDecayVelocity: { + type: Number, + value: 0.8 + }, + + /** + * If true, ripples will exhibit a gravitational pull towards + * the center of their container as they fade away. + * + * @attribute recenters + * @type boolean + * @default false + */ + recenters: { + type: Boolean, + value: false + }, + + /** + * If true, ripples will center inside its container + * + * @attribute recenters + * @type boolean + * @default false + */ + center: { + type: Boolean, + value: false + }, + + /** + * A list of the visual ripples. + * + * @attribute ripples + * @type Array + * @default [] + */ + ripples: { + type: Array, + value: function() { + return []; + } + }, + + /** + * True when there are visible ripples animating within the + * element. + */ + animating: { + type: Boolean, + readOnly: true, + reflectToAttribute: true, + value: false + }, + + /** + * If true, the ripple will remain in the "down" state until `holdDown` + * is set to false again. + */ + holdDown: { + type: Boolean, + value: false, + observer: '_holdDownChanged' + }, + + _animating: { + type: Boolean + }, + + _boundAnimate: { + type: Function, + value: function() { + return this.animate.bind(this); + } + } + }, + + get target () { + var ownerRoot = Polymer.dom(this).getOwnerRoot(); + var target; + + if (ownerRoot) { + target = ownerRoot.host; + } + + if (!target) { + target = this.parentNode; + } + + return target; + }, + + keyBindings: { + 'enter:keydown': '_onEnterKeydown', + 'space:keydown': '_onSpaceKeydown', + 'space:keyup': '_onSpaceKeyup' + }, + + attached: function() { + this._listen(this.target, 'up', this.upAction.bind(this)); + this._listen(this.target, 'down', this.downAction.bind(this)); + + if (!this.target.hasAttribute('noink')) { + this.keyEventTarget = this.target; + } + }, + + get shouldKeepAnimating () { + for (var index = 0; index < this.ripples.length; ++index) { + if (!this.ripples[index].isAnimationComplete) { + return true; + } + } + + return false; + }, + + simulatedRipple: function() { + this.downAction(null); + + // Please see polymer/polymer#1305 + this.async(function() { + this.upAction(); + }, 1); + }, + + downAction: function(event) { + if (this.holdDown && this.ripples.length > 0) { + return; + } + + var ripple = this.addRipple(); + + ripple.downAction(event); + + if (!this._animating) { + this.animate(); + } + }, + + upAction: function(event) { + if (this.holdDown) { + return; + } + + this.ripples.forEach(function(ripple) { + ripple.upAction(event); + }); + + this.animate(); + }, + + onAnimationComplete: function() { + this._animating = false; + this.$.background.style.backgroundColor = null; + this.fire('transitionend'); + }, + + addRipple: function() { + var ripple = new Ripple(this); + + Polymer.dom(this.$.waves).appendChild(ripple.waveContainer); + this.$.background.style.backgroundColor = ripple.color; + this.ripples.push(ripple); + + this._setAnimating(true); + + return ripple; + }, + + removeRipple: function(ripple) { + var rippleIndex = this.ripples.indexOf(ripple); + + if (rippleIndex < 0) { + return; + } + + this.ripples.splice(rippleIndex, 1); + + ripple.remove(); + + if (!this.ripples.length) { + this._setAnimating(false); + } + }, + + animate: function() { + var index; + var ripple; + + this._animating = true; + + for (index = 0; index < this.ripples.length; ++index) { + ripple = this.ripples[index]; + + ripple.draw(); + + this.$.background.style.opacity = ripple.outerOpacity; + + if (ripple.isOpacityFullyDecayed && !ripple.isRestingAtMaxRadius) { + this.removeRipple(ripple); + } + } + + if (!this.shouldKeepAnimating && this.ripples.length === 0) { + this.onAnimationComplete(); + } else { + window.requestAnimationFrame(this._boundAnimate); + } + }, + + _onEnterKeydown: function() { + this.downAction(); + this.async(this.upAction, 1); + }, + + _onSpaceKeydown: function() { + this.downAction(); + }, + + _onSpaceKeyup: function() { + this.upAction(); + }, + + _holdDownChanged: function(holdDown) { + if (holdDown) { + this.downAction(); + } else { + this.upAction(); + } + } + }); + })(); +</script> diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/.bower.json b/third_party/polymer/v1_0/components/paper-scroll-header-panel/.bower.json new file mode 100644 index 0000000..18b4ee3 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/.bower.json @@ -0,0 +1,48 @@ +{ + "name": "paper-scroll-header-panel", + "description": "A header bar with scrolling behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "layout", + "responsive" + ], + "main": [ + "paper-scroll-header-panel.html" + ], + "repository": { + "type": "git", + "url": "git@github.com:PolymerElements/paper-scroll-header-panel.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-scroll-header-panel", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "2b8db7a3cb8bfc7c8811438dd8cdfbdfda65d4d3" + }, + "_source": "git://github.com/PolymerElements/paper-scroll-header-panel.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-scroll-header-panel" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/.gitignore b/third_party/polymer/v1_0/components/paper-scroll-header-panel/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/README.md b/third_party/polymer/v1_0/components/paper-scroll-header-panel/README.md new file mode 100644 index 0000000..ac1be0c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/README.md @@ -0,0 +1,56 @@ +paper-scroll-header-panel +======================== + +`paper-scroll-header-panel` contains a header section and a content section. The header is initially on the top part of the view but it scrolls away with the rest of the scrollable content. Upon scrolling slightly up at any point, the header scrolls back into view. This saves screen space and allows users to access important controls by easily moving them back to the view. + +Important: The `paper-scroll-header-panel` will not display if its parent does not have a height. Using layout classes, you can easily make the `paper-scroll-header-panel` fill the screen + +```html +<body class="fullbleed layout vertical"> + <paper-scroll-header-panel class="flex"> + <paper-toolbar> + Hello World! + </paper-toolbar> + </paper-scroll-header-panel> +</body> +``` +or, if you would prefer to do it in CSS, just give html, body, and `paper-scroll-header-panel` a height of 100%: +```css +html, body { + height: 100%; + margin: 0; +} +paper-scroll-header-panel { + height: 100%; +} +``` +`paper-scroll-header-panel` works well with `paper-toolbar` but can use any element that represents a header by adding a core-header class to it. + +```html +<paper-scroll-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> +</paper-scroll-header-panel> +``` + +### Styling scroll-header-panel: + +To change background for toolbar when it is at its full size: + +```css +paper-scroll-header-panel { + --paper-scroll-header-panel-full-header: { + background-color: red; + }; +} +``` + +To change the background for toolbar when it is condensed: + +```css +paper-scroll-header-panel { + --paper-scroll-header-panel-condensed-header: { + background-color: #f4b400; + }; +} +``` diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/bower.json b/third_party/polymer/v1_0/components/paper-scroll-header-panel/bower.json new file mode 100644 index 0000000..86ac91c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/bower.json @@ -0,0 +1,38 @@ +{ + "name": "paper-scroll-header-panel", + "description": "A header bar with scrolling behavior", + "version": "1.0.1", + "license": "http://polymer.github.io/LICENSE.txt", + "private": true, + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "layout", + "responsive" + ], + "main": [ + "paper-scroll-header-panel.html" + ], + "repository": { + "type": "git", + "url": "git@github.com:PolymerElements/paper-scroll-header-panel.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-toolbar": "PolymerElements/paper-toolbar#^1.0.0", + "iron-resizable-behavior": "PolymerElements/iron-resizable-behavior#^1.0.0" + }, + "devDependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "iron-media-query": "PolymerElements/iron-media-query#^1.0.0", + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/hero.svg b/third_party/polymer/v1_0/components/paper-scroll-header-panel/hero.svg new file mode 100644 index 0000000..c130c84 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/hero.svg @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="170.6" cy="28.5" r="4"/> + <circle cx="170.6" cy="58.5" r="4"/> + <rect x="170" y="29" width="2" height="30"/> + <path d="M163,102H73V24h90V102z M75,100h86V26H75V100z"/> + <rect x="74" y="62" width="88" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> + <g> + <polygon points="74,59.6 74,62.5 74.5,63 77.4,63 "/> + <polygon points="74,51.9 74,54.7 82.3,63 85.1,63 "/> + <polygon points="74,44.1 74,46.9 90.1,63 92.9,63 "/> + <polygon points="74,36.3 74,39.2 97.8,63 100.7,63 "/> + <polygon points="74,28.6 74,31.4 105.6,63 108.4,63 "/> + <polygon points="78.2,25 75.4,25 113.4,63 116.2,63 "/> + <polygon points="86,25 83.1,25 121.1,63 124,63 "/> + <polygon points="93.7,25 90.9,25 128.9,63 131.7,63 "/> + <polygon points="101.5,25 98.7,25 136.7,63 139.5,63 "/> + <polygon points="109.2,25 106.4,25 144.4,63 147.2,63 "/> + <polygon points="117,25 114.2,25 152.2,63 155,63 "/> + <polygon points="124.8,25 122,25 160,63 162,63 162,62.2 "/> + <polygon points="132.5,25 129.7,25 162,57.3 162,54.5 "/> + <polygon points="140.3,25 137.5,25 162,49.5 162,46.7 "/> + <polygon points="148.1,25 145.2,25 162,41.8 162,38.9 "/> + <polygon points="155.8,25 153,25 162,34 162,31.2 "/> + <polygon points="162,26.2 162,25 160.8,25 "/> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/index.html b/third_party/polymer/v1_0/components/paper-scroll-header-panel/index.html new file mode 100644 index 0000000..e2e7712 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/index.html @@ -0,0 +1,28 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-scroll-header-panel</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-scroll-header-panel/paper-scroll-header-panel.html b/third_party/polymer/v1_0/components/paper-scroll-header-panel/paper-scroll-header-panel.html new file mode 100644 index 0000000..3cb82f1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-scroll-header-panel/paper-scroll-header-panel.html @@ -0,0 +1,454 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> + +<!-- +`paper-scroll-header-panel` contains a header section and a content section. The +header is initially on the top part of the view but it scrolls away with the +rest of the scrollable content. Upon scrolling slightly up at any point, the +header scrolls back into view. This saves screen space and allows users to +access important controls by easily moving them back to the view. + +__Important:__ The `paper-scroll-header-panel` will not display if its parent does not have a height. + +Using [layout attributes](http://www.polymer-project.org/docs/polymer/layout-attrs.html), you can easily make the `paper-scroll-header-panel` fill the screen + + <body class="fullbleed layout vertical"> + <paper-scroll-header-panel class="flex"> + <paper-toolbar> + <div>Hello World!</div> + </paper-toolbar> + </paper-scroll-header-panel> + </body> + +or, if you would prefer to do it in CSS, just give `html`, `body`, and `paper-scroll-header-panel` a height of 100%: + + html, body { + height: 100%; + margin: 0; + } + paper-scroll-header-panel { + height: 100%; + } + +`paper-scroll-header-panel` works well with `paper-toolbar` but can use any element +that represents a header by adding a `core-header` class to it. + + <paper-scroll-header-panel> + <paper-toolbar>Header</paper-toolbar> + <div>Content goes here...</div> + </paper-scroll-header-panel> + +Styling scroll-header-panel: + + To change background for toolbar when it is at its full size: + + paper-scroll-header-panel { + --paper-scroll-header-panel-full-header: { + background-color: red; + }; + } + + To change the background for toolbar when it is condensed: + + paper-scroll-header-panel { + --paper-scroll-header-panel-condensed-header: { + background-color: #f4b400; + }; + } + +@group Paper Element +@element paper-scrollheader-panel +@demo demo/index.html +@hero hero.svg +--> + +<dom-module id="paper-scroll-header-panel"> + + <style> + :host { + display: block; + position: relative; + overflow: hidden; + } + + #mainContainer { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + box-sizing: border-box; + -moz-box-sizing: border-box; + -webkit-overflow-scrolling: touch; + overflow-x: hidden; + overflow-_y: auto; + -webkit-transform: translateZ(0); + transform: translateZ(0); + } + + #headerContainer { + position: absolute; + top: 0; + right: 0; + left: 0; + } + + .bg-container { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + overflow: hidden; + } + + #headerBg { + @apply(--paper-scroll-header-panel-full-header); + } + + #condensedHeaderBg { + @apply(--paper-scroll-header-panel-condensed-header); + } + + #headerBg, #condensedHeaderBg { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background-repeat: no-repeat; + background-size: cover; + background-position: center center; + } + + #condensedHeaderBg { + opacity: 0; + } + </style> + <template> + <div id="mainContainer"> + <content id="mainContent" select=":not(paper-toolbar):not(.paper-header)"></content> + </div> + <div id="headerContainer"> + <div class="bg-container"> + <div id="condensedHeaderBg"></div> + <div id="headerBg"></div> + </div> + <content id="headerContent" select="paper-toolbar, .paper-header"></content> + </div> + </template> +</dom-module> + +<script> +(function() { + + 'use strict'; + + Polymer({ + + /** + * Fired when the content has been scrolled. + * + * @event content-scroll + */ + + /** + * Fired when the header is transformed. + * + * @event paper-header-transform + */ + + is: 'paper-scroll-header-panel', + + behaviors: [ + Polymer.IronResizableBehavior + ], + + properties: { + + /** + * If true, the header's height will condense to `_condensedHeaderHeight` + * as the user scrolls down from the top of the content area. + */ + condenses: { + type: Boolean, + value: false, + observer: '_condensesChanged' + }, + + /** + * If true, no cross-fade transition from one background to another. + */ + noDissolve: { + type: Boolean, + value: false + }, + + /** + * If true, the header doesn't slide back in when scrolling back up. + */ + noReveal: { + type: Boolean, + value: false + }, + + /** + * If true, the header is fixed to the top and never moves away. + */ + fixed: { + type: Boolean, + value: false + }, + + /** + * If true, the condensed header is always shown and does not move away. + */ + keepCondensedHeader: { + type: Boolean, + value: false + }, + + /** + * The height of the header when it is at its full size. + * + * By default, the height will be measured when it is ready. If the height + * changes later the user needs to either set this value to reflect the + * new height or invoke `measureHeaderHeight()`. + */ + headerHeight: { + type: Number, + value: 0 + }, + + /** + * The height of the header when it is condensed. + * + * By default, `_condensedHeaderHeight` is 1/3 of `headerHeight` unless + * this is specified. + */ + condensedHeaderHeight: { + type: Number, + value: 0 + }, + + /** + * By default, the top part of the header stays when the header is being + * condensed. Set this to true if you want the top part of the header + * to be scrolled away. + */ + scrollAwayTopbar: { + type: Boolean, + value: false + }, + + _headerMargin: { + type: Number + }, + + _prevScrollTop: { + type: Number + }, + + _y: { + type: Number + } + + }, + + observers: [ + '_setup(_headerMargin, headerHeight, fixed)', + '_headerHeightChanged(headerHeight, condensedHeaderHeight)', + '_condensedHeaderHeightChanged(headerHeight, condensedHeaderHeight)' + ], + + listeners: { + 'iron-resize': 'measureHeaderHeight' + }, + + ready: function() { + this.async(this.measureHeaderHeight, 5); + this._scrollHandler = this._scroll.bind(this); + this.scroller.addEventListener('scroll', this._scrollHandler); + }, + + detached: function() { + this.scroller.removeEventListener('scroll', this._scrollHandler); + }, + + /** + * Returns the header element. + * + * @property header + * @type Object + */ + get header() { + return Polymer.dom(this.$.headerContent).getDistributedNodes()[0]; + }, + + /** + * Returns the content element. + * + * @property content + * @type Object + */ + get content() { + return Polymer.dom(this.$.mainContent).getDistributedNodes()[0]; + }, + + /** + * Returns the scrollable element. + * + * @property scroller + * @type Object + */ + get scroller() { + return this.$.mainContainer; + }, + + /** + * Invoke this to tell `paper-scroll-header-panel` to re-measure the header's + * height. + * + * @method measureHeaderHeight + */ + measureHeaderHeight: function() { + var header = this.header; + if (header && header.offsetHeight) { + this.headerHeight = header.offsetHeight; + } + }, + + _headerHeightChanged: function() { + if (!this.condensedHeaderHeight) { + // assume condensedHeaderHeight is 1/3 of the headerHeight + this.condensedHeaderHeight = this.headerHeight * 1 / 3; + } + }, + + _condensedHeaderHeightChanged: function() { + if (this.headerHeight) { + this._headerMargin = this.headerHeight - this.condensedHeaderHeight; + } + }, + + _condensesChanged: function() { + if (this.condenses) { + this._scroll(); + } else { + // reset transform/opacity set on the header + this._condenseHeader(null); + } + }, + + _setup: function() { + var s = this.scroller.style; + s.paddingTop = this.fixed ? '' : this.headerHeight + 'px'; + + s.top = this.fixed ? this.headerHeight + 'px' : ''; + + if (this.fixed) { + this._transformHeader(null); + } else { + this._scroll(); + } + }, + + _transformHeader: function(y) { + var s = this.$.headerContainer.style; + this._translateY(s, -y); + + if (this.condenses) { + this._condenseHeader(y); + } + + this.fire('paper-header-transform', {y: y, height: this.headerHeight, + condensedHeight: this.condensedHeaderHeight}); + }, + + _condenseHeader: function(y) { + var reset = (y === null); + + // adjust top bar in core-header so the top bar stays at the top + if (!this.scrollAwayTopbar && this.header.$ && this.header.$.topBar) { + this._translateY(this.header.$.topBar.style, + reset ? null : Math.min(y, this._headerMargin)); + } + // transition header bg + var hbg = this.$.headerBg.style; + if (!this.noDissolve) { + hbg.opacity = reset ? '' : (this._headerMargin - y) / this._headerMargin; + } + // adjust header bg so it stays at the center + this._translateY(hbg, reset ? null : y / 2); + // transition condensed header bg + if (!this.noDissolve) { + var chbg = this.$.condensedHeaderBg.style; + chbg = this.$.condensedHeaderBg.style; + chbg.opacity = reset ? '' : y / this._headerMargin; + + // adjust condensed header bg so it stays at the center + this._translateY(chbg, reset ? null : y / 2); + } + }, + + _translateY: function(s, y) { + var t = (y === null) ? '' : 'translate3d(0, ' + y + 'px, 0)'; + setTransform(s, t); + }, + + _scroll: function(event) { + if (!this.header) { + return; + } + + var sTop = this.scroller.scrollTop; + + this._y = this._y || 0; + this._prevScrollTop = this._prevScrollTop || 0; + + var y = Math.min(this.keepCondensedHeader ? + this._headerMargin : this.headerHeight, Math.max(0, + (this.noReveal ? sTop : this._y + sTop - this._prevScrollTop))); + + if (this.condenses && this._prevScrollTop >= sTop && sTop > this._headerMargin) { + y = Math.max(y, this._headerMargin); + } + + if (!event || !this.fixed && y !== this._y) { + this._transformHeader(y); + } + + this._prevScrollTop = Math.max(sTop, 0); + this._y = y; + + if (event) { + this.fire('content-scroll', {target: this.scroller}, this, false); + } + } + + }); + + //determine proper transform mechanizm + if (document.documentElement.style.transform !== undefined) { + var setTransform = function(style, string) { + style.transform = string; + } + } else { + var setTransform = function(style, string) { + style.webkitTransform = string; + } + } + +})(); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-slider/.bower.json b/third_party/polymer/v1_0/components/paper-slider/.bower.json new file mode 100644 index 0000000..9b0a642 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/.bower.json @@ -0,0 +1,44 @@ +{ + "name": "paper-slider", + "version": "1.0.1", + "description": "A material design-style slider", + "license": "http://polymer.github.io/LICENSE.txt", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "slider", + "control" + ], + "main": [ + "paper-slider.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-slider.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-slider", + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "995905314b4aeffab020bdd53b0f68cc7b448a1d" + }, + "_source": "git://github.com/PolymerElements/paper-slider.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-slider" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-slider/.gitignore b/third_party/polymer/v1_0/components/paper-slider/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-slider/README.md b/third_party/polymer/v1_0/components/paper-slider/README.md new file mode 100644 index 0000000..fd00cd2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/README.md @@ -0,0 +1,69 @@ +paper-slider +============ + +`paper-slider` allows user to select a value from a range of values by +moving the slider thumb. The interactive nature of the slider makes it a +great choice for settings that reflect intensity levels, such as volume, +brightness, or color saturation. + +Example: + +```html +<paper-slider></paper-slider> +``` + +Use `min` and `max` to specify the slider range. Default is `0` to `100`. For example: +```html +<paper-slider min="10" max="200" value="110"></paper-slider> +``` + +### Styling slider + +To change the slider progress bar color: +```css +paper-slider { + --paper-slider-active-color: #0f9d58; +} +``` + +To change the slider knob color: +```css +paper-slider { + --paper-slider-knob-color: #0f9d58; +} +``` + +To change the slider pin color: +```css +paper-slider { + --paper-slider-pin-color: #0f9d58; +} +``` + +To change the slider pin's font color: +```css +paper-slider { + --paper-slider-pin-font-color: #0f9d58; +} +``` + +To change the slider secondary progress bar color: +```css +paper-slider { + --paper-slider-secondary-color: #0f9d58; +} +``` + +To change the slider disabled active color: +```css +paper-slider { + --paper-slider-disabled-active-color: #ccc; +} +``` + +To change the slider disabled secondary progress bar color: +```css +paper-slider { + --paper-slider-disabled-secondary-color: #ccc; +} +```
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-slider/bower.json b/third_party/polymer/v1_0/components/paper-slider/bower.json new file mode 100644 index 0000000..c40c262 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/bower.json @@ -0,0 +1,34 @@ +{ + "name": "paper-slider", + "version": "1.0.1", + "description": "A material design-style slider", + "license": "http://polymer.github.io/LICENSE.txt", + "authors": "The Polymer Authors", + "keywords": [ + "web-components", + "polymer", + "slider", + "control" + ], + "main": [ + "paper-slider.html" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-slider.git" + }, + "dependencies": { + "polymer": "Polymer/polymer#^1.0.0", + "paper-input": "PolymerElements/paper-input#^1.0.0", + "paper-progress": "PolymerElements/paper-progress#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "iron-behaviors": "PolymerElements/iron-behaviors#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-slider/hero.svg b/third_party/polymer/v1_0/components/paper-slider/hero.svg new file mode 100644 index 0000000..8a518e1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/hero.svg @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <circle cx="110" cy="61" r="4"/> + <rect x="61" y="60" width="49" height="2"/> + <rect x="110" y="60" width="53" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-slider/index.html b/third_party/polymer/v1_0/components/paper-slider/index.html new file mode 100644 index 0000000..6add074 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/index.html @@ -0,0 +1,29 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <title>paper-slider</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> + diff --git a/third_party/polymer/v1_0/components/paper-slider/paper-slider.css b/third_party/polymer/v1_0/components/paper-slider/paper-slider.css new file mode 100644 index 0000000..0e0f784 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/paper-slider.css @@ -0,0 +1,252 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +*/ + +:host { + display: inline-block; + width: 200px; + cursor: default; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} + +:host(:not([disabled])) #sliderBar::shadow #activeProgress { + background-color: var(--paper-slider-active-color, --google-blue-700); +} + +:host(:not([disabled])) #sliderBar::shadow #secondaryProgress { + background-color: var(--paper-slider-secondary-color, --google-blue-300); +} + +:host([disabled]) #sliderBar::shadow #activeProgress { + background-color: var(--paper-slider-disabled-active-color, --google-grey-500); +} + +:host([disabled]) #sliderBar::shadow #secondaryProgress { + background-color: var(--paper-slider-disabled-secondary-color, --google-grey-300); +} + +:host(:focus) { + outline: none; +} + +#sliderContainer { + position: relative; + width: calc(100% - 32px); + height: 32px; +} + +#sliderContainer.editable { + float: left; + width: calc(100% - 72px); + margin: 12px 0; +} + +.bar-container { + position: absolute; + top: 0; + left: 16px; + height: 100%; + width: 100%; + overflow: hidden; +} + +.ring > .bar-container { + left: 20px; + width: calc(100% - 4px); + transition: left 0.18s ease, width 0.18s ease; +} + +.ring.expand:not(.pin) > .bar-container { + left: 30px; + width: calc(100% - 14px); +} + +.ring.expand.dragging > .bar-container { + transition: none; +} + +#sliderBar { + position: absolute; + top: 15px; + left: 0; + height: 2px; + width: 100%; + padding: 8px 0; + margin: -8px 0; +} + +.ring #sliderBar { + left: -4px; + width: calc(100% + 4px); +} + +.ring.expand:not(.pin) #sliderBar { + left: -14px; + width: calc(100% + 14px); +} + +.slider-markers { + position: absolute; + top: 15px; + left: 15px; + height: 2px; + width: calc(100% + 2px); + box-sizing: border-box; + pointer-events: none; +} + +.slider-markers::after, +.slider-marker::after { + content: ""; + display: block; + width: 2px; + height: 2px; + border-radius: 50%; + background-color: black; +} + +.transiting #sliderBar::shadow #activeProgress { + transition: -webkit-transform 0.08s ease; + transition: transform 0.08s ease; +} + +#sliderKnob { + @apply(--layout-center-justified); + @apply(--layout-center); + @apply(--layout-horizontal); + + position: absolute; + left: 0; + top: 0; + width: 32px; + height: 32px; +} + +.transiting > #sliderKnob { + transition: left 0.08s ease; +} + +#sliderKnob:focus { + outline: none; +} + +#sliderKnob.dragging { + transition: none; +} + +.snaps > #sliderKnob.dragging { + transition: -webkit-transform 0.08s ease; + transition: transform 0.08s ease; +} + +#sliderKnobInner { + width: 12px; + height: 12px; + box-sizing: border-box; + -moz-box-sizing: border-box; + border-radius: 50%; + background-color: var(--paper-slider-knob-color, --google-blue-700); + transition-property: height, width, background-color, border; + transition-duration: 0.1s; + transition-timing-function: ease; +} + +.expand:not(.pin) > #sliderKnob > #sliderKnobInner { + width: 100%; + height: 100%; + -webkit-transform: translateZ(0); + transform: translateZ(0); +} + +.ring > #sliderKnob > #sliderKnobInner { + background-color: transparent; + border: 2px solid #c8c8c8; +} + +#sliderKnobInner::before { + background-color: var(--paper-slider-pin-color, --google-blue-700); +} + +.pin > #sliderKnob > #sliderKnobInner::before { + content: ""; + position: absolute; + top: 0; + left: 0; + width: 26px; + height: 26px; + margin-left: 3px; + border-radius: 50% 50% 50% 0; + -webkit-transform: rotate(-45deg) scale(0) translate(0); + transform: rotate(-45deg) scale(0) translate(0); +} + +#sliderKnobInner::before, +#sliderKnobInner::after { + transition: -webkit-transform .2s ease, background-color .18s ease; + transition: transform .2s ease, background-color .18s ease; +} + +.pin.ring > #sliderKnob > #sliderKnobInner::before { + background-color: #c8c8c8; +} + +.pin.expand > #sliderKnob > #sliderKnobInner::before { + -webkit-transform: rotate(-45deg) scale(1) translate(17px, -17px); + transform: rotate(-45deg) scale(1) translate(17px, -17px); +} + +.pin > #sliderKnob > #sliderKnobInner::after { + content: attr(value); + position: absolute; + top: 0; + left: 0; + width: 32px; + height: 26px; + text-align: center; + color: var(--paper-slider-font-color, #fff); + font-size: 10px; + -webkit-transform: scale(0) translate(0); + transform: scale(0) translate(0); +} + +.pin.expand > #sliderKnob > #sliderKnobInner::after { + -webkit-transform: scale(1) translate(0, -17px); + transform: scale(1) translate(0, -17px); +} + +/* editable: paper-input */ +.slider-input { + width: 40px; + float: right; + overflow: hidden; +} + +.slider-input::shadow input { + /* FIXME(ffu): should one be able set text-align directly on paper-input? */ + text-align: center; +} + +/* disabled state */ +#sliderContainer.disabled { + pointer-events: none; +} + +.disabled > #sliderKnob > #sliderKnobInner { + width: 8px; + height: 8px; + background-color: var(--paper-slider-disabled-knob-color, --google-grey-500); +} + +.disabled.ring > #sliderKnob > #sliderKnobInner { + background-color: transparent; +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-slider/paper-slider.html b/third_party/polymer/v1_0/components/paper-slider/paper-slider.html new file mode 100644 index 0000000..135dba8 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-slider/paper-slider.html @@ -0,0 +1,449 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> + +<link rel="import" href="../paper-styles/paper-styles.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-behaviors/iron-control-state.html"> +<link rel="import" href="../paper-progress/paper-progress.html"> +<link rel="import" href="../paper-input/paper-input.html"> + +<!-- +`paper-slider` allows user to select a value from a range of values by +moving the slider thumb. The interactive nature of the slider makes it a +great choice for settings that reflect intensity levels, such as volume, +brightness, or color saturation. + +Example: + + <paper-slider></paper-slider> + +Use `min` and `max` to specify the slider range. Default is 0 to 100. + +Example: + + <paper-slider min="10" max="200" value="110"></paper-slider> + +Styling slider: + +To change the slider progress bar color: + + paper-slider { + --paper-slider-active-color: #0f9d58; + } + +To change the slider knob color: + + paper-slider { + --paper-slider-knob-color: #0f9d58; + } + +To change the slider pin color: + + paper-slider { + --paper-slider-pin-color: #0f9d58; + } + +To change the slider pin's font color: + + paper-slider { + --paper-slider-pin-font-color: #0f9d58; + } + +To change the slider secondary progress bar color: + + paper-slider { + --paper-slider-secondary-color: #0f9d58; + } + +To change the slider disabled active color: + + paper-slider { + --paper-slider-disabled-active-color: #ccc; + } + +To change the slider disabled secondary progress bar color: + + paper-slider { + --paper-slider-disabled-secondary-color: #ccc; + } + +@group Paper Elements +@element paper-slider +@demo demo/index.html +@hero hero.svg +--> + +<dom-module id="paper-slider"> + <link rel="import" type="css" href="paper-slider.css"> + <template> + <template is="dom-if" if="{{!disabled}}"> + </template> + + <div id="sliderContainer" class$="[[_getClassNames(disabled, pin, snaps, immediateValue, min, expand, dragging, transiting, editable)]]"> + <div class="bar-container"> + <paper-progress id="sliderBar" aria-hidden="true" min="[[min]]" max="[[max]]" value="[[immediateValue]]" secondary-progress="[[secondaryProgress]]" + on-down="_bardown" on-up="_resetKnob" on-track="_onTrack"></paper-progress> + </div> + + <template is="dom-if" if="[[snaps]]"> + <div class="slider-markers horizontal layout"> + <template is="dom-repeat" items="[[markers]]"> + <div class="slider-marker flex"></div> + </template> + </div> + </template> + + <div id="sliderKnob" on-down="_knobdown" on-up="_resetKnob" + on-track="_onTrack" + on-transitionend="_knobTransitionEnd" + center-justified center horizontal layout> + + <div id="sliderKnobInner" value$="[[immediateValue]]"></div> + </div> + </div> + + <template is="dom-if" if="[[editable]]"> + <paper-input id="input" class="slider-input" disabled$="[[disabled]]" on-change="_inputChange"></paper-input> + </template> + + </template> +</dom-module> + +<script> + /** + * Fired when the slider's value changes. + * + * @event value-change + */ + + /** + * Fired when the slider's immediateValue changes. + * + * @event immediate-value-change + */ + + /** + * Fired when the slider's value changes due to user interaction. + * + * Changes to the slider's value due to changes in an underlying + * bound variable will not trigger this event. + * + * @event change + */ + + Polymer({ + is: 'paper-slider', + + behaviors: [ + Polymer.IronRangeBehavior, + Polymer.IronControlState + ], + + properties: { + + /** + * If true, the slider thumb snaps to tick marks evenly spaced based + * on the `step` property value. + */ + snaps: { + type: Boolean, + value: false, + notify: true + }, + + /** + * If true, a pin with numeric value label is shown when the slider thumb + * is pressed. Use for settings for which users need to know the exact + * value of the setting. + */ + pin: { + type: Boolean, + value: false, + notify: true + }, + + /** + * The number that represents the current secondary progress. + */ + secondaryProgress: { + type: Number, + value: 0, + notify: true, + observer: '_secondaryProgressChanged' + }, + + /** + * If true, an input is shown and user can use it to set the slider value. + */ + editable: { + type: Boolean, + value: false + }, + + /** + * The immediate value of the slider. This value is updated while the user + * is dragging the slider. + */ + immediateValue: { + type: Number, + value: 0, + readOnly: true + }, + + /** + * The maximum number of markers + */ + maxMarkers: { + type: Number, + value: 0, + notify: true, + observer: '_maxMarkersChanged' + }, + + /** + * If true, the knob is expanded + */ + expand: { + type: Boolean, + value: false, + readOnly: true + }, + + /** + * True when the user is dragging the slider. + */ + dragging: { + type: Boolean, + value: false, + readOnly: true + }, + + transiting: { + type: Boolean, + value: false, + readOnly: true + }, + + markers: { + readOnly: true, + value: [] + }, + }, + + observers: [ + '_updateKnob(value, min, max, snaps, step)', + '_minChanged(min)', + '_maxChanged(max)', + '_valueChanged(value)', + '_immediateValueChanged(immediateValue)' + ], + + ready: function() { + // issue polymer/polymer#1305 + this.async(function() { + this._updateKnob(this.value); + this._updateInputValue(); + }, 1); + }, + + /** + * Increases value by `step` but not above `max`. + * @method increment + */ + increment: function() { + this.value = this._clampValue(this.value + this.step); + }, + + /** + * Decreases value by `step` but not below `min`. + * @method decrement + */ + decrement: function() { + this.value = this._clampValue(this.value - this.step); + }, + + _updateKnob: function(value) { + this._positionKnob(this._calcRatio(value)); + }, + + _minChanged: function() { + this.setAttribute('aria-valuemin', this.min); + }, + + _maxChanged: function() { + this.setAttribute('aria-valuemax', this.max); + }, + + _valueChanged: function() { + this.setAttribute('aria-valuenow', this.value); + this.fire('value-change'); + }, + + _immediateValueChanged: function() { + if (!this.dragging) { + this.value = this.immediateValue; + } + this._updateInputValue(); + this.fire('immediate-value-change'); + }, + + _secondaryProgressChanged: function() { + this.secondaryProgress = this._clampValue(this.secondaryProgress); + }, + + _updateInputValue: function() { + if (this.editable) { + this.$$('#input').value = this.immediateValue; + } + }, + + _expandKnob: function() { + this._setExpand(true); + }, + + _resetKnob: function() { + this._expandJob && this._expandJob.stop(); + this._setExpand(false); + }, + + _positionKnob: function(ratio) { + this._setImmediateValue(this._calcStep(this._calcKnobPosition(ratio)) || 0); + this._setRatio(this.snaps ? this._calcRatio(this.immediateValue) : ratio); + this.$.sliderKnob.style.left = this.ratio * 100 + '%'; + }, + + _inputChange: function() { + this.value = this.$$('#input').value; + this.fire('change'); + }, + + _calcKnobPosition: function(ratio) { + return (this.max - this.min) * ratio + this.min; + }, + + _onTrack: function(e) { + switch (event.detail.state) { + case 'end': + this._trackEnd(event); + break; + case 'track': + this._trackX(event); + break; + case 'start': + this._trackStart(event); + break; + } + }, + + _trackStart: function(e) { + this._w = this.$.sliderBar.offsetWidth; + this._x = this.ratio * this._w; + this._startx = this._x || 0; + this._minx = - this._startx; + this._maxx = this._w - this._startx; + this.$.sliderKnob.classList.add('dragging'); + this._setDragging(true); + e.preventDefault(); + }, + + _trackX: function(e) { + if (!this.dragging) { + this._trackStart(e); + } + var x = Math.min(this._maxx, Math.max(this._minx, e.detail.dx)); + this._x = this._startx + x; + this._setImmediateValue(this._calcStep( + this._calcKnobPosition(this._x / this._w)) || 0); + var s = this.$.sliderKnob.style; + s.transform = s.webkitTransform = 'translate3d(' + (this.snaps ? + (this._calcRatio(this.immediateValue) * this._w) - this._startx : x) + 'px, 0, 0)'; + }, + + _trackEnd: function() { + var s = this.$.sliderKnob.style; + s.transform = s.webkitTransform = ''; + this.$.sliderKnob.classList.remove('dragging'); + this._setDragging(false); + this._resetKnob(); + this.value = this.immediateValue; + this.fire('change'); + }, + + _knobdown: function(e) { + e.preventDefault(); + this._expandKnob(); + }, + + _bardown: function(e) { + e.preventDefault(); + this._setTransiting(true); + this._w = this.$.sliderBar.offsetWidth; + var rect = this.$.sliderBar.getBoundingClientRect(); + var ratio = (e.detail.x - rect.left) / this._w; + this._positionKnob(ratio); + this._expandJob = this.debounce(this._expandJob, this._expandKnob, 60); + + this.async(function() { + this.fire('change'); + }); + }, + + _knobTransitionEnd: function(e) { + if (e.target === this.$.sliderKnob) { + this._setTransiting(false); + } + }, + + _maxMarkersChanged: function(maxMarkers) { + var l = (this.max - this.min) / this.step; + if (!this.snaps && l > maxMarkers) { + this._setMarkers([]); + } else { + this._setMarkers(new Array(l)); + } + }, + + _getClassNames: function() { + var classes = {}; + + classes['disabled'] = this.disabled; + classes['pin'] = this.pin; + classes['snaps'] = this.snaps; + classes['ring'] = this.immediateValue <= this.min; + classes['expand'] = this.expand; + classes['dragging'] = this.dragging; + classes['transiting'] = this.transiting; + classes['editable'] = this.editable; + + return Object.keys(classes).filter( + function(className) { + return classes[className]; + }).join(' '); + }, + + _incrementKey: function(ev, keys) { + if (keys.key === 'end') { + this.value = this.max; + } else { + this.increment(); + } + this.fire('change'); + }, + + _decrementKey: function(ev, keys) { + if (keys.key === 'home') { + this.value = this.min; + } else { + this.decrement(); + } + this.fire('change'); + } + }) +</script> diff --git a/third_party/polymer/v1_0/components/paper-spinner/.bower.json b/third_party/polymer/v1_0/components/paper-spinner/.bower.json new file mode 100644 index 0000000..1787b05 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/.bower.json @@ -0,0 +1,42 @@ +{ + "name": "paper-spinner", + "version": "1.0.1", + "description": "A material design spinner", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "spinner", + "loading" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-spinner" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-spinner", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "5e2b7412922259c9eed1805d69abb18e433efaad" + }, + "_source": "git://github.com/PolymerElements/paper-spinner.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-spinner" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-spinner/.gitignore b/third_party/polymer/v1_0/components/paper-spinner/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-spinner/README.md b/third_party/polymer/v1_0/components/paper-spinner/README.md new file mode 100644 index 0000000..c447c8b --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/README.md @@ -0,0 +1,45 @@ +paper-spinner +============= + +Element providing material design circular spinner. + +##### Example + +```html +<paper-spinner active></paper-spinner> +``` + +The default spinner cycles between four layers of colors; by default they are +blue, red, yellow and green. It can be customized so that it uses one color only +by setting all the layer colors to the same value. + +##### Example + +```html +<style is="custom-style"> + paper-spinner .rainbow { + --paper-spinner-layer-1-color: yellow; + --paper-spinner-layer-2-color: red; + --paper-spinner-layer-3-color: blue; + --paper-spinner-layer-4-color: green; + } + + paper-spinner .red { + --paper-spinner-layer-1-color: red; + --paper-spinner-layer-2-color: red; + --paper-spinner-layer-3-color: red; + --paper-spinner-layer-4-color: red; + } +</style> +``` + +Alt attribute should be set to provide adequate context for accessibility. If not provided, +it defaults to 'loading'. +Empty alt can be provided to mark the element as decorative if alternative content is provided +in another form (e.g. a text block following the spinner). + +##### Example + +```html +<paper-spinner alt="Loading contacts list" active></paper-spinner> +``` diff --git a/third_party/polymer/v1_0/components/paper-spinner/bower.json b/third_party/polymer/v1_0/components/paper-spinner/bower.json new file mode 100644 index 0000000..d27e049 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/bower.json @@ -0,0 +1,33 @@ +{ + "name": "paper-spinner", + "version": "1.0.1", + "description": "A material design spinner", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "spinner", + "loading" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-spinner" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-spinner", + "ignore": [], + "dependencies": { + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-spinner/hero.svg b/third_party/polymer/v1_0/components/paper-spinner/hero.svg new file mode 100644 index 0000000..034b1f1 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/hero.svg @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <path d="M112.1,92.3c-13.4,0-25.1-9.1-28.4-22l1.9-0.5c3.1,12.1,13.9,20.5,26.4,20.5c15,0,27.3-12.2,27.3-27.3 + s-12.2-27.3-27.3-27.3c-8.1,0-15.8,3.6-21,9.8l-1.5-1.3c5.6-6.7,13.8-10.6,22.5-10.6c16.1,0,29.3,13.1,29.3,29.3 + S128.2,92.3,112.1,92.3z"/> + <path d="M112.7,87.3c-6.6,0-12.7-2.5-17.3-7.2c-4.6-4.6-7.2-10.8-7.2-17.3c0-6.6,2.5-12.7,7.2-17.3c7.9-7.9,20.2-9.5,29.8-3.8 + l-1,1.7c-8.8-5.3-20.1-3.8-27.4,3.5c-4.2,4.2-6.6,9.9-6.6,15.9s2.3,11.7,6.6,15.9s9.9,6.6,15.9,6.6c6,0,11.7-2.3,15.9-6.6 + c4.7-4.7,7.1-11.3,6.5-18l2-0.2c0.7,7.3-1.9,14.4-7.1,19.6C125.4,84.7,119.2,87.3,112.7,87.3z"/> + <path d="M112.5,43.5C101.8,43.5,93,52.3,93,63s8.7,19.5,19.5,19.5S132,73.7,132,63S123.2,43.5,112.5,43.5z M119,64h-6v6h-2v-6h-6 + v-2h6v-6h2v6h6V64z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-spinner/index.html b/third_party/polymer/v1_0/components/paper-spinner/index.html new file mode 100644 index 0000000..9874334 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/index.html @@ -0,0 +1,30 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> + <head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-spinner</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + </head> + <body> + + <iron-component-page></iron-component-page> + + </body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-spinner/paper-spinner.css b/third_party/polymer/v1_0/components/paper-spinner/paper-spinner.css new file mode 100644 index 0000000..30c4e7e --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/paper-spinner.css @@ -0,0 +1,325 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + +*/ +/**************************/ +/* STYLES FOR THE SPINNER */ +/**************************/ + +/* + * Constants: + * STROKEWIDTH = 3px + * ARCSIZE = 270 degrees (amount of circle the arc takes up) + * ARCTIME = 1333ms (time it takes to expand and contract arc) + * ARCSTARTROT = 216 degrees (how much the start location of the arc + * should rotate each time, 216 gives us a + * 5 pointed star shape (it's 360/5 * 3). + * For a 7 pointed star, we might do + * 360/7 * 3 = 154.286) + * CONTAINERWIDTH = 28px + * SHRINK_TIME = 400ms + */ + + :host { + display: inline-block; + position: relative; + width: 28px; /* CONTAINERWIDTH */ + height: 28px; /* CONTAINERWIDTH */ +} + +#spinnerContainer { + width: 100%; + height: 100%; +} + +#spinnerContainer.active { + /* duration: 360 * ARCTIME / (ARCSTARTROT + (360-ARCSIZE)) */ + -webkit-animation: container-rotate 1568ms linear infinite; + animation: container-rotate 1568ms linear infinite; +} + +@-webkit-keyframes container-rotate { + to { -webkit-transform: rotate(360deg) } +} + +@keyframes container-rotate { + to { transform: rotate(360deg) } +} + +.spinner-layer { + position: absolute; + width: 100%; + height: 100%; + opacity: 0; +} + +.layer-1 { + border-color: var(--paper-spinner-layer-1-color, --google-blue-500); +} + +.layer-2 { + border-color: var(--paper-spinner-layer-2-color, --google-red-500); +} + +.layer-3 { + border-color: var(--paper-spinner-layer-3-color, --google-yellow-500); +} + +.layer-4 { + border-color: var(--paper-spinner-layer-4-color, --google-blue-500); +} + +/** + * IMPORTANT NOTE ABOUT CSS ANIMATION PROPERTIES (keanulee): + * + * iOS Safari (tested on iOS 8.1) does not handle animation-delay very well - it doesn't + * guarantee that the animation will start _exactly_ after that value. So we avoid using + * animation-delay and instead set custom keyframes for each color (as layer-2undant as it + * seems). + * + * We write out each animation in full (instead of separating animation-name, + * animation-duration, etc.) because under the polyfill, Safari does not recognize those + * specific properties properly, treats them as -webkit-animation, and overrides the + * other animation rules. See https://github.com/Polymer/platform/issues/53. + */ +.active .spinner-layer.layer-1 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-1-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-1-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .spinner-layer.layer-2 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-2-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-2-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .spinner-layer.layer-3 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-3-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-3-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .spinner-layer.layer-4 { + /* durations: 4 * ARCTIME */ + -webkit-animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-4-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: fill-unfill-rotate 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both, layer-4-fade-in-out 5332ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +@-webkit-keyframes fill-unfill-rotate { + 12.5% { -webkit-transform: rotate(135deg); } /* 0.5 * ARCSIZE */ + 25% { -webkit-transform: rotate(270deg); } /* 1 * ARCSIZE */ + 37.5% { -webkit-transform: rotate(405deg); } /* 1.5 * ARCSIZE */ + 50% { -webkit-transform: rotate(540deg); } /* 2 * ARCSIZE */ + 62.5% { -webkit-transform: rotate(675deg); } /* 2.5 * ARCSIZE */ + 75% { -webkit-transform: rotate(810deg); } /* 3 * ARCSIZE */ + 87.5% { -webkit-transform: rotate(945deg); } /* 3.5 * ARCSIZE */ + to { -webkit-transform: rotate(1080deg); } /* 4 * ARCSIZE */ +} + +@keyframes fill-unfill-rotate { + 12.5% { transform: rotate(135deg); } /* 0.5 * ARCSIZE */ + 25% { transform: rotate(270deg); } /* 1 * ARCSIZE */ + 37.5% { transform: rotate(405deg); } /* 1.5 * ARCSIZE */ + 50% { transform: rotate(540deg); } /* 2 * ARCSIZE */ + 62.5% { transform: rotate(675deg); } /* 2.5 * ARCSIZE */ + 75% { transform: rotate(810deg); } /* 3 * ARCSIZE */ + 87.5% { transform: rotate(945deg); } /* 3.5 * ARCSIZE */ + to { transform: rotate(1080deg); } /* 4 * ARCSIZE */ +} + +/** + * HACK: Even though the intention is to have the current .spinner-layer at + * `opacity: 1`, we set it to `opacity: 0.99` instead since this forces Chrome + * to do proper subpixel rendering for the elements being animated. This is + * especially visible in Chrome 39 on Ubuntu 14.04. See: + * + * - https://github.com/Polymer/paper-spinner/issues/9 + * - https://code.google.com/p/chromium/issues/detail?id=436255 + */ +@-webkit-keyframes layer-1-fade-in-out { + from { opacity: 0.99; } + 25% { opacity: 0.99; } + 26% { opacity: 0; } + 89% { opacity: 0; } + 90% { opacity: 0.99; } + 100% { opacity: 0.99; } +} + +@keyframes layer-1-fade-in-out { + from { opacity: 0.99; } + 25% { opacity: 0.99; } + 26% { opacity: 0; } + 89% { opacity: 0; } + 90% { opacity: 0.99; } + 100% { opacity: 0.99; } +} + +@-webkit-keyframes layer-2-fade-in-out { + from { opacity: 0; } + 15% { opacity: 0; } + 25% { opacity: 0.99; } + 50% { opacity: 0.99; } + 51% { opacity: 0; } +} + +@keyframes layer-2-fade-in-out { + from { opacity: 0; } + 15% { opacity: 0; } + 25% { opacity: 0.99; } + 50% { opacity: 0.99; } + 51% { opacity: 0; } +} + +@-webkit-keyframes layer-3-fade-in-out { + from { opacity: 0; } + 40% { opacity: 0; } + 50% { opacity: 0.99; } + 75% { opacity: 0.99; } + 76% { opacity: 0; } +} + +@keyframes layer-3-fade-in-out { + from { opacity: 0; } + 40% { opacity: 0; } + 50% { opacity: 0.99; } + 75% { opacity: 0.99; } + 76% { opacity: 0; } +} + +@-webkit-keyframes layer-4-fade-in-out { + from { opacity: 0; } + 65% { opacity: 0; } + 75% { opacity: 0.99; } + 90% { opacity: 0.99; } + 100% { opacity: 0; } +} + +@keyframes layer-4-fade-in-out { + from { opacity: 0; } + 65% { opacity: 0; } + 75% { opacity: 0.99; } + 90% { opacity: 0.99; } + 100% { opacity: 0; } +} + +/** + * Patch the gap that appear between the two adjacent div.circle-clipper while the + * spinner is rotating (appears on Chrome 38, Safari 7.1, and IE 11). + * + * Update: the gap no longer appears on Chrome when .spinner-layer's opacity is 0.99, + * but still does on Safari and IE. + */ +.gap-patch { + position: absolute; + box-sizing: border-box; + top: 0; + left: 45%; + width: 10%; + height: 100%; + overflow: hidden; + border-color: inherit; +} + +.gap-patch .circle { + width: 1000%; + left: -450%; +} + +.circle-clipper { + display: inline-block; + position: relative; + width: 50%; + height: 100%; + overflow: hidden; + border-color: inherit; +} + +.circle-clipper .circle { + width: 200%; +} + +.circle { + box-sizing: border-box; + height: 100%; + border-width: 3px; /* STROKEWIDTH */ + border-style: solid; + border-color: inherit; + border-bottom-color: transparent !important; + border-radius: 50%; + -webkit-animation: none; + animation: none; + + @apply(--layout-fit); +} + +.circle-clipper.left .circle { + border-right-color: transparent !important; + -webkit-transform: rotate(129deg); + transform: rotate(129deg); +} + +.circle-clipper.right .circle { + left: -100%; + border-left-color: transparent !important; + -webkit-transform: rotate(-129deg); + transform: rotate(-129deg); +} + +.active .circle-clipper.left .circle { + /* duration: ARCTIME */ + -webkit-animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: left-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +.active .circle-clipper.right .circle { + /* duration: ARCTIME */ + -webkit-animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; + animation: right-spin 1333ms cubic-bezier(0.4, 0.0, 0.2, 1) infinite both; +} + +@-webkit-keyframes left-spin { + from { -webkit-transform: rotate(130deg); } + 50% { -webkit-transform: rotate(-5deg); } + to { -webkit-transform: rotate(130deg); } +} + +@keyframes left-spin { + from { transform: rotate(130deg); } + 50% { transform: rotate(-5deg); } + to { transform: rotate(130deg); } +} + +@-webkit-keyframes right-spin { + from { -webkit-transform: rotate(-130deg); } + 50% { -webkit-transform: rotate(5deg); } + to { -webkit-transform: rotate(-130deg); } +} + +@keyframes right-spin { + from { transform: rotate(-130deg); } + 50% { transform: rotate(5deg); } + to { transform: rotate(-130deg); } +} + +#spinnerContainer.cooldown { + /* duration: SHRINK_TIME */ + -webkit-animation: container-rotate 1568ms linear infinite, fade-out 400ms cubic-bezier(0.4, 0.0, 0.2, 1); + animation: container-rotate 1568ms linear infinite, fade-out 400ms cubic-bezier(0.4, 0.0, 0.2, 1); +} + +@-webkit-keyframes fade-out { + from { opacity: 0.99; } + to { opacity: 0; } +} + +@keyframes fade-out { + from { opacity: 0.99; } + to { opacity: 0; } +} diff --git a/third_party/polymer/v1_0/components/paper-spinner/paper-spinner.html b/third_party/polymer/v1_0/components/paper-spinner/paper-spinner.html new file mode 100644 index 0000000..b5503cc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-spinner/paper-spinner.html @@ -0,0 +1,222 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/color.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> + +<!-- +Element providing material design circular spinner. + + <paper-spinner active></paper-spinner> + +The default spinner cycles between four layers of colors; by default they are +blue, red, yellow and green. It can be customized so that it uses one color only +by setting all the layer colors to the same value. + +### Accessibility + +Alt attribute should be set to provide adequate context for accessibility. If not provided, +it defaults to 'loading'. +Empty alt can be provided to mark the element as decorative if alternative content is provided +in another form (e.g. a text block following the spinner). + + <paper-spinner alt="Loading contacts list" active></paper-spinner> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-spinner-layer-1-color` | Color of the first spinner rotation | `--google-blue-500` +`--paper-spinner-layer-2-color` | Color of the second spinner rotation | `--google-red-500` +`--paper-spinner-layer-3-color` | Color of the third spinner rotation | `--google-yellow-500` +`--paper-spinner-layer-4-color` | Color of the fourth spinner rotation | `--google-green-500` + +@group Paper Elements +@element paper-spinner +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-spinner"> + + <link rel="import" type="css" href="paper-spinner.css"> + + <template> + + <div id="spinnerContainer" class-name="[[_spinnerContainerClassName]]"> + <div class="spinner-layer layer-1"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + + <div class="spinner-layer layer-2"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + + <div class="spinner-layer layer-3"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + + <div class="spinner-layer layer-4"> + <div class="circle-clipper left"> + <div class="circle"></div> + </div><div class="gap-patch"> + <div class="circle"></div> + </div><div class="circle-clipper right"> + <div class="circle"></div> + </div> + </div> + </div> + + </template> + + <script> + + (function() { + + 'use strict'; + + function classNames(obj) { + var classNames = []; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key]) { + classNames.push(key); + } + } + + return classNames.join(' '); + } + + Polymer({ + + is: 'paper-spinner', + + listeners: { + 'animationend': 'reset', + 'webkitAnimationEnd': 'reset' + }, + + properties: { + + /** + * Displays the spinner. + * + * @attribute active + * @type boolean + * @default false + */ + active: { + observer: '_activeChanged', + type: Boolean, + value: false + }, + + /** + * Alternative text content for accessibility support. + * If alt is present, it will add an aria-label whose content matches alt when active. + * If alt is not present, it will default to 'loading' as the alt value. + * + * @attribute alt + * @type string + * @default 'loading' + */ + alt: { + observer: '_altChanged', + type: String, + value: 'loading' + }, + + /** + * True when the spinner is going from active to inactive. This is represented by a fade + * to 0% opacity to the user. + */ + _coolingDown: { + type: Boolean, + value: false + }, + + _spinnerContainerClassName: { + type: String, + computed: '_computeSpinnerContainerClassName(active, _coolingDown)' + } + + }, + + _computeSpinnerContainerClassName: function(active, _coolingDown) { + return classNames({ + active: active || _coolingDown, + cooldown: _coolingDown + }); + }, + + ready: function() { + // Allow user-provided `aria-label` take preference to any other text alternative. + if (this.hasAttribute('aria-label')) { + this.alt = this.getAttribute('aria-label'); + } else { + this.setAttribute('aria-label', this.alt); + } + + if (!this.active) { + this.setAttribute('aria-hidden', 'true'); + } + }, + + _activeChanged: function() { + if (this.active) { + this.removeAttribute('aria-hidden'); + } else { + this._coolingDown = true; + this.setAttribute('aria-hidden', 'true'); + } + }, + + _altChanged: function() { + if (this.alt === '') { + this.setAttribute('aria-hidden', 'true'); + } else { + this.removeAttribute('aria-hidden'); + } + + this.setAttribute('aria-label', this.alt); + }, + + reset: function() { + this.active = false; + this._coolingDown = false; + } + + }); + + }()); + + </script> + +</dom-module> diff --git a/third_party/polymer/v1_0/components/paper-styles/.bower.json b/third_party/polymer/v1_0/components/paper-styles/.bower.json new file mode 100644 index 0000000..46a6457 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-styles", + "version": "1.0.3", + "description": "Common (global) styles for Material Design elements.", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "style" + ], + "main": "paper-styles.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/polymerelements/paper-styles/", + "ignore": [ + "/.*", + "/demo/" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.3", + "_resolution": { + "type": "version", + "tag": "v1.0.3", + "commit": "64adbb4e15214cdc0e5df1ac4b8f2d9e2eca6076" + }, + "_source": "git://github.com/PolymerElements/paper-styles.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-styles" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-styles/README.md b/third_party/polymer/v1_0/components/paper-styles/README.md new file mode 100644 index 0000000..82a7847 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/README.md @@ -0,0 +1,3 @@ +# paper-styles + +Material design CSS styles. diff --git a/third_party/polymer/v1_0/components/paper-styles/bower.json b/third_party/polymer/v1_0/components/paper-styles/bower.json new file mode 100644 index 0000000..c818d34 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/bower.json @@ -0,0 +1,27 @@ +{ + "name": "paper-styles", + "version": "1.0.3", + "description": "Common (global) styles for Material Design elements.", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-component", + "polymer", + "style" + ], + "main": "paper-styles.html", + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/polymerelements/paper-styles/", + "ignore": [ + "/.*", + "/demo/" + ], + "dependencies": { + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-styles/classes/global.html b/third_party/polymer/v1_0/components/paper-styles/classes/global.html new file mode 100644 index 0000000..6f0d5dd --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/classes/global.html @@ -0,0 +1,96 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<link rel="import" href="../paper-styles-classes.html"> + +<!-- +A set of base styles that are applied to the document and standard elements that +match the Material Design spec. +--> +<style> +/* +Note that there is a lot of style duplication here. The hope is that the Polymer +0.8 styling solution will allow for inheritance of properties so that we can +eventually avoid it. +*/ + +/* Mixins */ + +/* [paper-font] */ +body { + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; /* OS X subpixel AA bleed bug */ +} + +/* [paper-font=display2] */ +h1 { + font-size: 45px; + font-weight: 400; + letter-spacing: -.018em; + line-height: 48px; +} + +/* [paper-font=display1] */ +h2 { + font-size: 34px; + font-weight: 400; + letter-spacing: -.01em; + line-height: 40px; +} + +/* [paper-font=headline] */ +h3 { + font-size: 24px; + font-weight: 400; + letter-spacing: -.012em; + line-height: 32px; +} + +/* [paper-font=subhead] */ +h4 { + font-size: 16px; + font-weight: 400; + line-height: 24px; +} + +/* [paper-font=body2] */ +h5, h6 { + font-size: 14px; + font-weight: 500; + line-height: 24px; +} + +/* [paper-font=button] */ +a { + font-size: 14px; + font-weight: 500; + letter-spacing: 0.018em; + line-height: 24px; + text-transform: uppercase; +} + +/* Overrides */ + +body, a { + color: #212121; +} + +h1, h2, h3, h4, h5, h6, p { + margin: 0 0 20px 0; +} + +h1, h2, h3, h4, h5, h6, a { + text-rendering: optimizeLegibility; +} + +a { + text-decoration: none; +} + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/classes/shadow-layout.html b/third_party/polymer/v1_0/components/paper-styles/classes/shadow-layout.html new file mode 100644 index 0000000..c42067a --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/classes/shadow-layout.html @@ -0,0 +1,302 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<style> + + /******************************* + Flex Layout + *******************************/ + + html /deep/ .layout.horizontal, + html /deep/ .layout.horizontal-reverse, + html /deep/ .layout.vertical, + html /deep/ .layout.vertical-reverse { + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + } + + html /deep/ .layout.inline { + display: -ms-inline-flexbox; + display: -webkit-inline-flex; + display: inline-flex; + } + + html /deep/ .layout.horizontal { + -ms-flex-direction: row; + -webkit-flex-direction: row; + flex-direction: row; + } + + html /deep/ .layout.horizontal-reverse { + -ms-flex-direction: row-reverse; + -webkit-flex-direction: row-reverse; + flex-direction: row-reverse; + } + + html /deep/ .layout.vertical { + -ms-flex-direction: column; + -webkit-flex-direction: column; + flex-direction: column; + } + + html /deep/ .layout.vertical-reverse { + -ms-flex-direction: column-reverse; + -webkit-flex-direction: column-reverse; + flex-direction: column-reverse; + } + + html /deep/ .layout.wrap { + -ms-flex-wrap: wrap; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + } + + html /deep/ .layout.wrap-reverse { + -ms-flex-wrap: wrap-reverse; + -webkit-flex-wrap: wrap-reverse; + flex-wrap: wrap-reverse; + } + + html /deep/ .flex-auto { + -ms-flex: 1 1 auto; + -webkit-flex: 1 1 auto; + flex: 1 1 auto; + } + + html /deep/ .flex-none { + -ms-flex: none; + -webkit-flex: none; + flex: none; + } + + html /deep/ .flex, + html /deep/ .flex-1 { + -ms-flex: 1; + -webkit-flex: 1; + flex: 1; + } + + html /deep/ .flex-2 { + -ms-flex: 2; + -webkit-flex: 2; + flex: 2; + } + + html /deep/ .flex-3 { + -ms-flex: 3; + -webkit-flex: 3; + flex: 3; + } + + html /deep/ .flex-4 { + -ms-flex: 4; + -webkit-flex: 4; + flex: 4; + } + + html /deep/ .flex-5 { + -ms-flex: 5; + -webkit-flex: 5; + flex: 5; + } + + html /deep/ .flex-6 { + -ms-flex: 6; + -webkit-flex: 6; + flex: 6; + } + + html /deep/ .flex-7 { + -ms-flex: 7; + -webkit-flex: 7; + flex: 7; + } + + html /deep/ .flex-8 { + -ms-flex: 8; + -webkit-flex: 8; + flex: 8; + } + + html /deep/ .flex-9 { + -ms-flex: 9; + -webkit-flex: 9; + flex: 9; + } + + html /deep/ .flex-10 { + -ms-flex: 10; + -webkit-flex: 10; + flex: 10; + } + + html /deep/ .flex-11 { + -ms-flex: 11; + -webkit-flex: 11; + flex: 11; + } + + html /deep/ .flex-12 { + -ms-flex: 12; + -webkit-flex: 12; + flex: 12; + } + + /* alignment in cross axis */ + + html /deep/ .layout.start { + -ms-flex-align: start; + -webkit-align-items: flex-start; + align-items: flex-start; + } + + html /deep/ .layout.center, + html /deep/ .layout.center-center { + -ms-flex-align: center; + -webkit-align-items: center; + align-items: center; + } + + html /deep/ .layout.end { + -ms-flex-align: end; + -webkit-align-items: flex-end; + align-items: flex-end; + } + + /* alignment in main axis */ + + html /deep/ .layout.start-justified { + -ms-flex-pack: start; + -webkit-justify-content: flex-start; + justify-content: flex-start; + } + + html /deep/ .layout.center-justified, + html /deep/ .layout.center-center { + -ms-flex-pack: center; + -webkit-justify-content: center; + justify-content: center; + } + + html /deep/ .layout.end-justified { + -ms-flex-pack: end; + -webkit-justify-content: flex-end; + justify-content: flex-end; + } + + html /deep/ .layout.around-justified { + -ms-flex-pack: around; + -webkit-justify-content: space-around; + justify-content: space-around; + } + + html /deep/ .layout.justified { + -ms-flex-pack: justify; + -webkit-justify-content: space-between; + justify-content: space-between; + } + + /* self alignment */ + + html /deep/ .self-start { + -ms-align-self: flex-start; + -webkit-align-self: flex-start; + align-self: flex-start; + } + + html /deep/ .self-center { + -ms-align-self: center; + -webkit-align-self: center; + align-self: center; + } + + html /deep/ .self-end { + -ms-align-self: flex-end; + -webkit-align-self: flex-end; + align-self: flex-end; + } + + html /deep/ .self-stretch { + -ms-align-self: stretch; + -webkit-align-self: stretch; + align-self: stretch; + } + + /******************************* + Other Layout + *******************************/ + + html /deep/ .block { + display: block; + } + + /* IE 10 support for HTML5 hidden attr */ + html /deep/ [hidden] { + display: none !important; + } + + html /deep/ .invisible { + visibility: hidden !important; + } + + html /deep/ .relative { + position: relative; + } + + html /deep/ .fit { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + + body.fullbleed { + margin: 0; + height: 100vh; + } + + html /deep/ .scroll { + -webkit-overflow-scrolling: touch; + overflow: auto; + } + + .fixed-bottom, + .fixed-left, + .fixed-right, + .fixed-top { + position: fixed; + } + + html /deep/ .fixed-top { + top: 0; + left: 0; + right: 0; + } + + html /deep/ .fixed-right { + top: 0; + right: 0; + botttom: 0; + } + + html /deep/ .fixed-bottom { + right: 0; + bottom: 0; + left: 0; + } + + html /deep/ .fixed-left { + top: 0; + botttom: 0; + left: 0; + } + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/classes/shadow.html b/third_party/polymer/v1_0/components/paper-styles/classes/shadow.html new file mode 100644 index 0000000..b4c340d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/classes/shadow.html @@ -0,0 +1,39 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<style> +.shadow-transition { + transition: box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1); +} + +.shadow-elevation-1 { + box-shadow: 0 1px 4px 0 rgba(0, 0, 0, 0.37); +} + +.shadow-elevation-2 { + box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.2), + 0 6px 10px 0 rgba(0, 0, 0, 0.3); +} + +.shadow-elevation-3 { + box-shadow: 0 11px 7px 0 rgba(0, 0, 0, 0.19), + 0 13px 25px 0 rgba(0, 0, 0, 0.3); +} + +.shadow-elevation-4 { + box-shadow: 0 14px 12px 0 rgba(0, 0, 0, 0.17), + 0 20px 40px 0 rgba(0, 0, 0, 0.3); +} + +.shadow-elevation-5 { + box-shadow: 0 17px 17px 0 rgba(0, 0, 0, 0.15), + 0 27px 55px 0 rgba(0, 0, 0, 0.3); +} +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/classes/typography.html b/third_party/polymer/v1_0/components/paper-styles/classes/typography.html new file mode 100644 index 0000000..5514abb --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/classes/typography.html @@ -0,0 +1,171 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!-- TODO(nevir): Should we upgrade Polymer/font-roboto to the final font? --> +<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto:400,300,300italic,400italic,500,500italic,700,700italic"> +<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Inconsolata:400,700"> + +<!-- +Typographic styles are provided matching the Material Design standard styles: +http://www.google.com/design/spec/style/typography.html#typography-standard-styles + +To make use of them, apply a `paper-font-<style>` class to elements, matching +the font style you wish it to inherit. + + <header class="paper-font-display2">Hey there!</header> + +Note that these are English/Latin centric styles. You may need to further adjust +line heights and weights for CJK typesetting. See the notes in the Material +Design typography section. +--> +<style> + +.paper-font-display4, +.paper-font-display3, +.paper-font-display2, +.paper-font-display1, +.paper-font-headline, +.paper-font-title, +.paper-font-subhead, +.paper-font-body2, +.paper-font-body1, +.paper-font-caption, +.paper-font-menu, +.paper-font-button { + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; /* OS X subpixel AA bleed bug */ +} + +.paper-font-code2, +.paper-font-code1 { + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; /* OS X subpixel AA bleed bug */ +} + +/* Opt for better kerning for headers & other short labels. */ +.paper-font-display4, +.paper-font-display3, +.paper-font-display2, +.paper-font-display1, +.paper-font-headline, +.paper-font-title, +.paper-font-subhead, +.paper-font-menu, +.paper-font-button { + text-rendering: optimizeLegibility; +} + +/* +"Line wrapping only applies to Body, Subhead, Headline, and the smaller Display +styles. All other styles should exist as single lines." +*/ +.paper-font-display4, +.paper-font-display3, +.paper-font-title, +.paper-font-caption, +.paper-font-menu, +.paper-font-button { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.paper-font-display4 { + font-size: 112px; + font-weight: 300; + letter-spacing: -.044em; + line-height: 120px; +} + +.paper-font-display3 { + font-size: 56px; + font-weight: 400; + letter-spacing: -.026em; + line-height: 60px; +} + +.paper-font-display2 { + font-size: 45px; + font-weight: 400; + letter-spacing: -.018em; + line-height: 48px; +} + +.paper-font-display1 { + font-size: 34px; + font-weight: 400; + letter-spacing: -.01em; + line-height: 40px; +} + +.paper-font-headline { + font-size: 24px; + font-weight: 400; + letter-spacing: -.012em; + line-height: 32px; +} + +.paper-font-title { + font-size: 20px; + font-weight: 500; + line-height: 28px; +} + +.paper-font-subhead { + font-size: 16px; + font-weight: 400; + line-height: 24px; +} + +.paper-font-body2 { + font-size: 14px; + font-weight: 500; + line-height: 24px; +} + +.paper-font-body1 { + font-size: 14px; + font-weight: 400; + line-height: 20px; +} + +.paper-font-caption { + font-size: 12px; + font-weight: 400; + letter-spacing: 0.011em; + line-height: 20px; +} + +.paper-font-menu { + font-size: 13px; + font-weight: 500; + line-height: 24px; +} + +.paper-font-button { + font-size: 14px; + font-weight: 500; + letter-spacing: 0.018em; + line-height: 24px; + text-transform: uppercase; +} + +.paper-font-code2 { + font-size: 14px; + font-weight: 700; + line-height: 20px; +} + +.paper-font-code1 { + font-size: 14px; + font-weight: 700; + line-height: 20px; +} + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/color.html b/third_party/polymer/v1_0/components/paper-styles/color.html new file mode 100644 index 0000000..5f8f887 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/color.html @@ -0,0 +1,333 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + /* Material Design color palette for Google products */ + + --google-red-100: #f4c7c3; + --google-red-300: #e67c73; + --google-red-500: #db4437; + --google-red-700: #c53929; + + --google-blue-100: #c6dafc; + --google-blue-300: #7baaf7; + --google-blue-500: #4285f4; + --google-blue-700: #3367d6; + + --google-green-100: #b7e1cd; + --google-green-300: #57bb8a; + --google-green-500: #0f9d58; + --google-green-700: #0b8043; + + --google-yellow-100: #fce8b2; + --google-yellow-300: #f7cb4d; + --google-yellow-500: #f4b400; + --google-yellow-700: #f09300; + + --google-grey-100: #f5f5f5; + --google-grey-300: #e0e0e0; + --google-grey-500: #9e9e9e; + --google-grey-700: #616161; + + /* Material Design color palette from online spec document */ + + --paper-red-50: #ffebee; + --paper-red-100: #ffcdd2; + --paper-red-200: #ef9a9a; + --paper-red-300: #e57373; + --paper-red-400: #ef5350; + --paper-red-500: #f44336; + --paper-red-600: #e53935; + --paper-red-700: #d32f2f; + --paper-red-800: #c62828; + --paper-red-900: #b71c1c; + --paper-red-a100: #ff8a80; + --paper-red-a200: #ff5252; + --paper-red-a400: #ff1744; + --paper-red-a700: #d50000; + + --paper-pink-50: #fce4ec; + --paper-pink-100: #f8bbd0; + --paper-pink-200: #f48fb1; + --paper-pink-300: #f06292; + --paper-pink-400: #ec407a; + --paper-pink-500: #e91e63; + --paper-pink-600: #d81b60; + --paper-pink-700: #c2185b; + --paper-pink-800: #ad1457; + --paper-pink-900: #880e4f; + --paper-pink-a100: #ff80ab; + --paper-pink-a200: #ff4081; + --paper-pink-a400: #f50057; + --paper-pink-a700: #c51162; + + --paper-purple-50: #f3e5f5; + --paper-purple-100: #e1bee7; + --paper-purple-200: #ce93d8; + --paper-purple-300: #ba68c8; + --paper-purple-400: #ab47bc; + --paper-purple-500: #9c27b0; + --paper-purple-600: #8e24aa; + --paper-purple-700: #7b1fa2; + --paper-purple-800: #6a1b9a; + --paper-purple-900: #4a148c; + --paper-purple-a100: #ea80fc; + --paper-purple-a200: #e040fb; + --paper-purple-a400: #d500f9; + --paper-purple-a700: #aa00ff; + + --paper-deep-purple-50: #ede7f6; + --paper-deep-purple-100: #d1c4e9; + --paper-deep-purple-200: #b39ddb; + --paper-deep-purple-300: #9575cd; + --paper-deep-purple-400: #7e57c2; + --paper-deep-purple-500: #673ab7; + --paper-deep-purple-600: #5e35b1; + --paper-deep-purple-700: #512da8; + --paper-deep-purple-800: #4527a0; + --paper-deep-purple-900: #311b92; + --paper-deep-purple-a100: #b388ff; + --paper-deep-purple-a200: #7c4dff; + --paper-deep-purple-a400: #651fff; + --paper-deep-purple-a700: #6200ea; + + --paper-indigo-50: #e8eaf6; + --paper-indigo-100: #c5cae9; + --paper-indigo-200: #9fa8da; + --paper-indigo-300: #7986cb; + --paper-indigo-400: #5c6bc0; + --paper-indigo-500: #3f51b5; + --paper-indigo-600: #3949ab; + --paper-indigo-700: #303f9f; + --paper-indigo-800: #283593; + --paper-indigo-900: #1a237e; + --paper-indigo-a100: #8c9eff; + --paper-indigo-a200: #536dfe; + --paper-indigo-a400: #3d5afe; + --paper-indigo-a700: #304ffe; + + --paper-blue-50: #e3f2fd; + --paper-blue-100: #bbdefb; + --paper-blue-200: #90caf9; + --paper-blue-300: #64b5f6; + --paper-blue-400: #42a5f5; + --paper-blue-500: #2196f3; + --paper-blue-600: #1e88e5; + --paper-blue-700: #1976d2; + --paper-blue-800: #1565c0; + --paper-blue-900: #0d47a1; + --paper-blue-a100: #82b1ff; + --paper-blue-a200: #448aff; + --paper-blue-a400: #2979ff; + --paper-blue-a700: #2962ff; + + --paper-light-blue-50: #e1f5fe; + --paper-light-blue-100: #b3e5fc; + --paper-light-blue-200: #81d4fa; + --paper-light-blue-300: #4fc3f7; + --paper-light-blue-400: #29b6f6; + --paper-light-blue-500: #03a9f4; + --paper-light-blue-600: #039be5; + --paper-light-blue-700: #0288d1; + --paper-light-blue-800: #0277bd; + --paper-light-blue-900: #01579b; + --paper-light-blue-a100: #80d8ff; + --paper-light-blue-a200: #40c4ff; + --paper-light-blue-a400: #00b0ff; + --paper-light-blue-a700: #0091ea; + + --paper-cyan-50: #e0f7fa; + --paper-cyan-100: #b2ebf2; + --paper-cyan-200: #80deea; + --paper-cyan-300: #4dd0e1; + --paper-cyan-400: #26c6da; + --paper-cyan-500: #00bcd4; + --paper-cyan-600: #00acc1; + --paper-cyan-700: #0097a7; + --paper-cyan-800: #00838f; + --paper-cyan-900: #006064; + --paper-cyan-a100: #84ffff; + --paper-cyan-a200: #18ffff; + --paper-cyan-a400: #00e5ff; + --paper-cyan-a700: #00b8d4; + + --paper-teal-50: #e0f2f1; + --paper-teal-100: #b2dfdb; + --paper-teal-200: #80cbc4; + --paper-teal-300: #4db6ac; + --paper-teal-400: #26a69a; + --paper-teal-500: #009688; + --paper-teal-600: #00897b; + --paper-teal-700: #00796b; + --paper-teal-800: #00695c; + --paper-teal-900: #004d40; + --paper-teal-a100: #a7ffeb; + --paper-teal-a200: #64ffda; + --paper-teal-a400: #1de9b6; + --paper-teal-a700: #00bfa5; + + --paper-green-50: #e8f5e9; + --paper-green-100: #c8e6c9; + --paper-green-200: #a5d6a7; + --paper-green-300: #81c784; + --paper-green-400: #66bb6a; + --paper-green-500: #4caf50; + --paper-green-600: #43a047; + --paper-green-700: #388e3c; + --paper-green-800: #2e7d32; + --paper-green-900: #1b5e20; + --paper-green-a100: #b9f6ca; + --paper-green-a200: #69f0ae; + --paper-green-a400: #00e676; + --paper-green-a700: #00c853; + + --paper-light-green-50: #f1f8e9; + --paper-light-green-100: #dcedc8; + --paper-light-green-200: #c5e1a5; + --paper-light-green-300: #aed581; + --paper-light-green-400: #9ccc65; + --paper-light-green-500: #8bc34a; + --paper-light-green-600: #7cb342; + --paper-light-green-700: #689f38; + --paper-light-green-800: #558b2f; + --paper-light-green-900: #33691e; + --paper-light-green-a100: #ccff90; + --paper-light-green-a200: #b2ff59; + --paper-light-green-a400: #76ff03; + --paper-light-green-a700: #64dd17; + + --paper-lime-50: #f9fbe7; + --paper-lime-100: #f0f4c3; + --paper-lime-200: #e6ee9c; + --paper-lime-300: #dce775; + --paper-lime-400: #d4e157; + --paper-lime-500: #cddc39; + --paper-lime-600: #c0ca33; + --paper-lime-700: #afb42b; + --paper-lime-800: #9e9d24; + --paper-lime-900: #827717; + --paper-lime-a100: #f4ff81; + --paper-lime-a200: #eeff41; + --paper-lime-a400: #c6ff00; + --paper-lime-a700: #aeea00; + + --paper-yellow-50: #fffde7; + --paper-yellow-100: #fff9c4; + --paper-yellow-200: #fff59d; + --paper-yellow-300: #fff176; + --paper-yellow-400: #ffee58; + --paper-yellow-500: #ffeb3b; + --paper-yellow-600: #fdd835; + --paper-yellow-700: #fbc02d; + --paper-yellow-800: #f9a825; + --paper-yellow-900: #f57f17; + --paper-yellow-a100: #ffff8d; + --paper-yellow-a200: #ffff00; + --paper-yellow-a400: #ffea00; + --paper-yellow-a700: #ffd600; + + --paper-amber-50: #fff8e1; + --paper-amber-100: #ffecb3; + --paper-amber-200: #ffe082; + --paper-amber-300: #ffd54f; + --paper-amber-400: #ffca28; + --paper-amber-500: #ffc107; + --paper-amber-600: #ffb300; + --paper-amber-700: #ffa000; + --paper-amber-800: #ff8f00; + --paper-amber-900: #ff6f00; + --paper-amber-a100: #ffe57f; + --paper-amber-a200: #ffd740; + --paper-amber-a400: #ffc400; + --paper-amber-a700: #ffab00; + + --paper-orange-50: #fff3e0; + --paper-orange-100: #ffe0b2; + --paper-orange-200: #ffcc80; + --paper-orange-300: #ffb74d; + --paper-orange-400: #ffa726; + --paper-orange-500: #ff9800; + --paper-orange-600: #fb8c00; + --paper-orange-700: #f57c00; + --paper-orange-800: #ef6c00; + --paper-orange-900: #e65100; + --paper-orange-a100: #ffd180; + --paper-orange-a200: #ffab40; + --paper-orange-a400: #ff9100; + --paper-orange-a700: #ff6500; + + --paper-deep-orange-50: #ff5722; + --paper-deep-orange-100: #fbe9e7; + --paper-deep-orange-200: #ffccbc; + --paper-deep-orange-300: #ff8a65; + --paper-deep-orange-400: #ff7043; + --paper-deep-orange-500: #ff5722; + --paper-deep-orange-600: #f4511e; + --paper-deep-orange-700: #e64a19; + --paper-deep-orange-800: #d84315; + --paper-deep-orange-900: #bf360c; + --paper-deep-orange-a100: #ff9e80; + --paper-deep-orange-a200: #ff6e40; + --paper-deep-orange-a400: #ff3d00; + --paper-deep-orange-a700: #dd2c00; + + --paper-brown-50: #795548; + --paper-brown-100: #efebe9; + --paper-brown-200: #d7ccc8; + --paper-brown-300: #a1887f; + --paper-brown-400: #8d6e63; + --paper-brown-500: #795548; + --paper-brown-600: #6d4c41; + --paper-brown-700: #5d4037; + --paper-brown-800: #4e342e; + --paper-brown-900: #3e2723; + + --paper-grey-50: #fafafa; + --paper-grey-100: #f5f5f5; + --paper-grey-200: #eeeeee; + --paper-grey-300: #e0e0e0; + --paper-grey-400: #bdbdbd; + --paper-grey-500: #9e9e9e; + --paper-grey-600: #757575; + --paper-grey-700: #616161; + --paper-grey-800: #424242; + --paper-grey-900: #212121; + + --paper-blue-grey-50: #eceff1; + --paper-blue-grey-100: #cfd8dc; + --paper-blue-grey-200: #b0bec5; + --paper-blue-grey-300: #90a4ae; + --paper-blue-grey-400: #78909c; + --paper-blue-grey-500: #607d8b; + --paper-blue-grey-600: #546e7a; + --paper-blue-grey-700: #455a64; + --paper-blue-grey-800: #37474f; + --paper-blue-grey-900: #263238; + + /* opacity for dark text on a light background */ + --dark-divider-opacity: 0.12; + --dark-disabled-opacity: 0.26; /* or hint text */ + --dark-secondary-opacity: 0.54; /* or icon */ + --dark-primary-opacity: 0.87; + + /* opacity for light text on a dark background */ + --light-divider-opacity: 0.12; + --light-disabled-opacity: 0.3; /* or hint text */ + --light-secondary-opacity: 0.7; /* or icon */ + --light-primary-opacity: 1.0; + + } + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/default-theme.html b/third_party/polymer/v1_0/components/paper-styles/default-theme.html new file mode 100644 index 0000000..add581c --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/default-theme.html @@ -0,0 +1,39 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + --dark-primary-color: #303f9f; + + --default-primary-color: #3f51b5; + + --light-primary-color: #c5cae9; + + --text-primary-color: #ffffff; + + --accent-color: #ff4081; + + --primary-background-color: #ffffff; + + --primary-text-color: #212121; + + --secondary-text-color: #757575; + + --disabled-text-color: #bdbdbd; + + --divider-color: #e0e0e0; + + } + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/demo-pages.html b/third_party/polymer/v1_0/components/paper-styles/demo-pages.html new file mode 100644 index 0000000..9fc5739 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/demo-pages.html @@ -0,0 +1,64 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="color.html"> +<link rel="import" href="shadow.html"> + +<style is="custom-style"> + + body { + font-family: 'Roboto', 'Noto', sans-serif; + font-size: 14px; + margin: 0; + padding: 24px; + background-color: var(--paper-grey-50); + } + + .horizontal-section-container { + @apply(--layout-horizontal); + @apply(--layout-center-justified); + @apply(--layout-wrap); + } + + .vertical-section-container { + @apply(--layout-vertical); + @apply(--center-justified); + } + + .horizontal-section { + background-color: white; + padding: 24px; + margin-right: 24px; + min-width: 200px; + + @apply(--shadow-elevation-2dp); + } + + .vertical-section { + background-color: white; + padding: 24px; + margin: 0 24px 24px 24px; + + @apply(--shadow-elevation-2dp); + } + + .centered { + max-width: 400px; + margin-left: auto; + margin-right: auto; + } + + /* TODO: remove this hack and use horizontal-section-container instead */ + body > div.layout.horizontal.center-justified { + @apply(--layout-wrap); + } + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/demo.css b/third_party/polymer/v1_0/components/paper-styles/demo.css new file mode 100644 index 0000000..efd8b47 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/demo.css @@ -0,0 +1,25 @@ +/** +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt + +*/ +body { + font-family: 'Roboto', 'Noto', sans-serif; + font-size: 14px; + margin: 0; + padding: 24px; +} + +section { + padding: 20px 0; +} + +section > div { + padding: 14px; + font-size: 16px; +} diff --git a/third_party/polymer/v1_0/components/paper-styles/paper-styles-classes.html b/third_party/polymer/v1_0/components/paper-styles/paper-styles-classes.html new file mode 100644 index 0000000..ae315a5 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/paper-styles-classes.html @@ -0,0 +1,14 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<link rel="import" href="classes/typography.html"> +<link rel="import" href="classes/shadow.html"> diff --git a/third_party/polymer/v1_0/components/paper-styles/paper-styles.html b/third_party/polymer/v1_0/components/paper-styles/paper-styles.html new file mode 100644 index 0000000..1e4fce5 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/paper-styles.html @@ -0,0 +1,17 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> + +<link rel="import" href="color.html"> +<link rel="import" href="default-theme.html"> +<link rel="import" href="shadow.html"> +<link rel="import" href="typography.html"> diff --git a/third_party/polymer/v1_0/components/paper-styles/shadow.html b/third_party/polymer/v1_0/components/paper-styles/shadow.html new file mode 100644 index 0000000..7339d8e --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/shadow.html @@ -0,0 +1,61 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + --shadow-transition: { + transition: box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1); + }; + + /* from http://codepen.io/shyndman/pen/c5394ddf2e8b2a5c9185904b57421cdb */ + + --shadow-elevation-2dp: { + box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.14), + 0 1px 5px 0 rgba(0, 0, 0, 0.12), + 0 3px 1px -2px rgba(0, 0, 0, 0.2); + }; + + --shadow-elevation-3dp: { + box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.14), + 0 1px 8px 0 rgba(0, 0, 0, 0.12), + 0 3px 3px -2px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-4dp: { + box-shadow: 0 4px 5px 0 rgba(0, 0, 0, 0.14), + 0 1px 10px 0 rgba(0, 0, 0, 0.12), + 0 2px 4px -1px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-6dp: { + box-shadow: 0 6px 10px 0 rgba(0, 0, 0, 0.14), + 0 1px 18px 0 rgba(0, 0, 0, 0.12), + 0 3px 5px -1px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-8dp: { + box-shadow: 0 8px 10px 1px rgba(0, 0, 0, 0.14), + 0 3px 14px 2px rgba(0, 0, 0, 0.12), + 0 5px 5px -3px rgba(0, 0, 0, 0.4); + }; + + --shadow-elevation-16dp: { + box-shadow: 0 16px 24px 2px rgba(0, 0, 0, 0.14), + 0 6px 30px 5px rgba(0, 0, 0, 0.12), + 0 8px 10px -5px rgba(0, 0, 0, 0.4); + }; + + } + +</style> diff --git a/third_party/polymer/v1_0/components/paper-styles/typography.html b/third_party/polymer/v1_0/components/paper-styles/typography.html new file mode 100644 index 0000000..a37cd34 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-styles/typography.html @@ -0,0 +1,240 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<!-- TODO(nevir): Should we upgrade Polymer/font-roboto to the final font? --> +<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto:400,300,300italic,400italic,500,500italic,700,700italic"> + +<link rel="import" href="../polymer/polymer.html"> + +<style is="custom-style"> + + :root { + + /* Shared Styles */ + + /* + Unfortunately, we can't make use of these yet - sibling properties aren't + evaluated. See https://github.com/Polymer/polymer/issues/1399 + + --paper-font-common-base: { + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + }; + + --paper-font-common-code: { + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; + }; + + --paper-font-common-expensive-kerning: { + text-rendering: optimizeLegibility; + }; + + --paper-font-common-nowrap: { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + }; + */ + + /* Material Font Styles */ + + --paper-font-display4: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 112px; + font-weight: 300; + letter-spacing: -.044em; + line-height: 120px; + }; + + --paper-font-display3: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 56px; + font-weight: 400; + letter-spacing: -.026em; + line-height: 60px; + }; + + --paper-font-display2: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 45px; + font-weight: 400; + letter-spacing: -.018em; + line-height: 48px; + }; + + --paper-font-display1: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 34px; + font-weight: 400; + letter-spacing: -.01em; + line-height: 40px; + }; + + --paper-font-headline: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 24px; + font-weight: 400; + letter-spacing: -.012em; + line-height: 32px; + }; + + --paper-font-title: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 20px; + font-weight: 500; + line-height: 28px; + }; + + --paper-font-subhead: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + + font-size: 16px; + font-weight: 400; + line-height: 24px; + }; + + --paper-font-body2: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 500; + line-height: 24px; + }; + + --paper-font-body1: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 400; + line-height: 20px; + }; + + --paper-font-caption: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 12px; + font-weight: 400; + letter-spacing: 0.011em; + line-height: 20px; + }; + + --paper-font-menu: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 13px; + font-weight: 500; + line-height: 24px; + }; + + --paper-font-button: { + /* @apply(--paper-font-common-base) */ + font-family: 'Roboto', 'Noto', sans-serif; + -webkit-font-smoothing: antialiased; + /* @apply(--paper-font-common-expensive-kerning); */ + text-rendering: optimizeLegibility; + /* @apply(--paper-font-common-nowrap); */ + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + font-size: 14px; + font-weight: 500; + letter-spacing: 0.018em; + line-height: 24px; + text-transform: uppercase; + }; + + --paper-font-code2: { + /* @apply(--paper-font-common-code); */ + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 700; + line-height: 20px; + }; + + --paper-font-code1: { + /* @apply(--paper-font-common-code); */ + font-family: 'Inconsolata', 'Consolas', 'Source Code Pro', 'Monaco', 'Menlo', monospace; + -webkit-font-smoothing: antialiased; + + font-size: 14px; + font-weight: 500; + line-height: 20px; + }; + + } + +</style> diff --git a/third_party/polymer/v1_0/components/paper-tabs/.bower.json b/third_party/polymer/v1_0/components/paper-tabs/.bower.json new file mode 100644 index 0000000..0b9b4e2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/.bower.json @@ -0,0 +1,47 @@ +{ + "name": "paper-tabs", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Material design tabs", + "private": true, + "main": "paper-tabs.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "tabs", + "control" + ], + "repository": "https://github.com/PolymerElements/paper-tabs.git", + "dependencies": { + "iron-behaviors": "polymerelements/iron-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "iron-menu-behavior": "polymerelements/iron-menu-behavior#^1.0.0", + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "paper-icon-button": "polymerelements/paper-icon-button#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-toolbar": "polymerelements/paper-toolbar#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + }, + "homepage": "https://github.com/PolymerElements/paper-tabs", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "af6820e55f73fc5aa8c8e4d5294085e46374c7ca" + }, + "_source": "git://github.com/PolymerElements/paper-tabs.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-tabs" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-tabs/.gitignore b/third_party/polymer/v1_0/components/paper-tabs/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-tabs/README.md b/third_party/polymer/v1_0/components/paper-tabs/README.md new file mode 100644 index 0000000..d4744e2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/README.md @@ -0,0 +1,56 @@ +paper-tabs +============ + +`paper-tabs` makes it easy to explore and switch between different views or functional aspects of +an app, or to browse categorized data sets. + +Use `selected` property to get or set the selected tab. + +Example: + +```html +<paper-tabs selected="0"> + <paper-tab>TAB 1</paper-tab> + <paper-tab>TAB 2</paper-tab> + <paper-tab>TAB 3</paper-tab> +</paper-tabs> +``` + +See <a href="#paper-tab">paper-tab</a> for more information about +`paper-tab`. + +A common usage for `paper-tabs` is to use it along with `iron-pages` to switch +between different views. + +```html +<paper-tabs selected="{{selected}}"> + <paper-tab>Tab 1</paper-tab> + <paper-tab>Tab 2</paper-tab> + <paper-tab>Tab 3</paper-tab> +</paper-tabs> + +<iron-pages selected="{{selected}}"> + <div>Page 1</div> + <div>Page 2</div> + <div>Page 3</div> +</iron-pages> +``` + +To use links in tabs, add `link` attribute to `paper-tab` and put an `<a>` +element in `paper-tab`. + +Example: + +```html +<paper-tabs selected="0"> + <paper-tab link> + <a href="#link1" class="horizontal center-center layout">TAB ONE</a> + </paper-tab> + <paper-tab link> + <a href="#link2" class="horizontal center-center layout">TAB TWO</a> + </paper-tab> + <paper-tab link> + <a href="#link3" class="horizontal center-center layout">TAB THREE</a> + </paper-tab> +</paper-tabs> +``` diff --git a/third_party/polymer/v1_0/components/paper-tabs/bower.json b/third_party/polymer/v1_0/components/paper-tabs/bower.json new file mode 100644 index 0000000..cff76e9 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/bower.json @@ -0,0 +1,37 @@ +{ + "name": "paper-tabs", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "Material design tabs", + "private": true, + "main": "paper-tabs.html", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "tabs", + "control" + ], + "repository": "https://github.com/PolymerElements/paper-tabs.git", + "dependencies": { + "iron-behaviors": "polymerelements/iron-behaviors#^1.0.0", + "iron-flex-layout": "polymerelements/iron-flex-layout#^1.0.0", + "iron-icon": "polymerelements/iron-icon#^1.0.0", + "iron-iconset-svg": "polymerelements/iron-iconset-svg#^1.0.0", + "iron-menu-behavior": "polymerelements/iron-menu-behavior#^1.0.0", + "iron-resizable-behavior": "polymerelements/iron-resizable-behavior#^1.0.0", + "paper-ripple": "polymerelements/paper-ripple#^1.0.0", + "paper-styles": "polymerelements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "paper-icon-button": "polymerelements/paper-icon-button#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "paper-toolbar": "polymerelements/paper-toolbar#^1.0.0", + "test-fixture": "polymerelements/test-fixture#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0", + "web-component-tester": "*" + } +} diff --git a/third_party/polymer/v1_0/components/paper-tabs/hero.svg b/third_party/polymer/v1_0/components/paper-tabs/hero.svg new file mode 100644 index 0000000..bfcbdac --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/hero.svg @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M188,78H37V44h151V78z M39,76h147V46H39V76z"/> + <polygon points="66,64.8 60.6,56.8 55.3,64.8 49.2,55.6 50.8,54.4 55.3,61.2 60.6,53.2 66,61.2 71.3,53.2 77.4,62.4 75.8,63.6 + 71.3,56.8 "/> + <rect x="149" y="58" width="26" height="2"/> + <rect x="99" y="58" width="26" height="2"/> + <rect x="38" y="72" width="50" height="4"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-tabs/index.html b/third_party/polymer/v1_0/components/paper-tabs/index.html new file mode 100644 index 0000000..98ab07d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/index.html @@ -0,0 +1,25 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <title>paper-tabs</title> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"> + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page sources='["paper-tabs.html", "paper-tab.html"]'></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-tabs/paper-tab.html b/third_party/polymer/v1_0/components/paper-tabs/paper-tab.html new file mode 100644 index 0000000..4737ec8 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/paper-tab.html @@ -0,0 +1,158 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-behaviors/iron-control-state.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> + +<!-- +`paper-tab` is styled to look like a tab. It should be used in conjunction with +`paper-tabs`. + +Example: + + <paper-tabs selected="0"> + <paper-tab>TAB 1</paper-tab> + <paper-tab>TAB 2</paper-tab> + <paper-tab>TAB 3</paper-tab> + </paper-tabs> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-tab-ink` | Ink color | `--paper-yellow-a100` +`--paper-tab` | Mixin applied to the tab | `{}` +`--paper-tab-content` | Mixin applied to the tab content | `{}` + +--> + +<dom-module id="paper-tab"> + + <style> + + :host { + @apply(--layout-inline); + @apply(--layout-center); + @apply(--layout-center-justified); + @apply(--layout-flex); + + position: relative; + padding: 0 12px; + overflow: hidden; + cursor: pointer; + + @apply(--paper-tab); + } + + :host(:focus) { + outline: none; + } + + :host([link]) { + padding: 0; + } + + .tab-content { + height: 100%; + -webkit-transform: translateZ(0); + transform: translateZ(0); + transition: opacity 0.1s cubic-bezier(0.4, 0.0, 1, 1); + + @apply(--paper-tab-content); + } + + :host(:not(.iron-selected)) > .tab-content { + opacity: 0.8; + } + + :host(:focus) .tab-content { + opacity: 1; + font-weight: 700; + } + + #ink { + color: var(--paper-tab-ink, --paper-yellow-a100); + pointer-events: none; + } + + .tab-content > ::content > a { + height: 100%; + /* flex */ + -ms-flex: 1 1 0.000000001px; + -webkit-flex: 1; + flex: 1; + -webkit-flex-basis: 0.000000001px; + flex-basis: 0.000000001px; + } + + </style> + + <template> + + <div class="tab-content flex-auto center-center horizontal layout"> + <content></content> + </div> + + <template is="dom-if" if="[[!noink]]"> + <paper-ripple id="ink" initial-opacity="0.95" opacity-decay-velocity="0.98"></paper-ripple> + </template> + + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'paper-tab', + + behaviors: [ + Polymer.IronControlState + ], + + properties: { + + /** + * If true, ink ripple effect is disabled. + * + * @attribute noink + */ + noink: { + type: Boolean, + value: false + } + + }, + + hostAttributes: { + role: 'tab' + }, + + listeners: { + down: '_onDown' + }, + + get _parentNoink () { + var parent = Polymer.dom(this).parentNode; + return !!parent && !!parent.noink; + }, + + _onDown: function(e) { + this.noink = !!this.noink || !!this._parentNoink; + } + }); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-tabs/paper-tabs-icons.html b/third_party/polymer/v1_0/components/paper-tabs/paper-tabs-icons.html new file mode 100644 index 0000000..c299046 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/paper-tabs-icons.html @@ -0,0 +1,18 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../iron-iconset-svg/iron-iconset-svg.html"> + +<iron-iconset-svg name="paper-tabs" size="24"> +<svg><defs> +<g id="chevron-left"><path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/></g> +<g id="chevron-right"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></g> +</defs></svg> +</iron-iconset-svg> diff --git a/third_party/polymer/v1_0/components/paper-tabs/paper-tabs.html b/third_party/polymer/v1_0/components/paper-tabs/paper-tabs.html new file mode 100644 index 0000000..ca648df --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-tabs/paper-tabs.html @@ -0,0 +1,483 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../iron-flex-layout/iron-flex-layout.html"> +<link rel="import" href="../iron-flex-layout/classes/iron-flex-layout.html"> +<link rel="import" href="../iron-resizable-behavior/iron-resizable-behavior.html"> +<link rel="import" href="../iron-menu-behavior/iron-menubar-behavior.html"> +<link rel="import" href="../iron-icon/iron-icon.html"> +<link rel="import" href="../paper-icon-button/paper-icon-button.html"> +<link rel="import" href="../paper-styles/color.html"> +<link rel="import" href="paper-tabs-icons.html"> +<link rel="import" href="paper-tab.html"> + +<!-- +`paper-tabs` makes it easy to explore and switch between different views or functional aspects of +an app, or to browse categorized data sets. + +Use `selected` property to get or set the selected tab. + +Example: + + <paper-tabs selected="0"> + <paper-tab>TAB 1</paper-tab> + <paper-tab>TAB 2</paper-tab> + <paper-tab>TAB 3</paper-tab> + </paper-tabs> + +See <a href="#paper-tab">paper-tab</a> for more information about +`paper-tab`. + +A common usage for `paper-tabs` is to use it along with `iron-pages` to switch +between different views. + + <paper-tabs selected="{{selected}}"> + <paper-tab>Tab 1</paper-tab> + <paper-tab>Tab 2</paper-tab> + <paper-tab>Tab 3</paper-tab> + </paper-tabs> + + <iron-pages selected="{{selected}}"> + <div>Page 1</div> + <div>Page 2</div> + <div>Page 3</div> + </iron-pages> + + +To use links in tabs, add `link` attribute to `paper-tab` and put an `<a>` +element in `paper-tab`. + +Example: + + <paper-tabs selected="0"> + <paper-tab link> + <a href="#link1" class="horizontal center-center layout">TAB ONE</a> + </paper-tab> + <paper-tab link> + <a href="#link2" class="horizontal center-center layout">TAB TWO</a> + </paper-tab> + <paper-tab link> + <a href="#link3" class="horizontal center-center layout">TAB THREE</a> + </paper-tab> + </paper-tabs> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-tabs-selection-bar-color` | Color for the selection bar | `--paper-yellow-a100` +`--paper-tabs` | Mixin applied to the tabs | `{}` + +@hero hero.svg +@demo demo/index.html +--> + +<dom-module id="paper-tabs"> + + <style> + + :host { + @apply(--layout); + @apply(--layout-center); + + height: 48px; + font-size: 14px; + font-weight: 500; + overflow: hidden; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + -webkit-tap-highlight-color: rgba(0,0,0,0); + + @apply(--paper-tabs); + } + + #tabsContainer { + position: relative; + height: 100%; + white-space: nowrap; + overflow: hidden; + } + + #tabsContent { + height: 100%; + } + + #tabsContent.scrollable { + position: absolute; + white-space: nowrap; + } + + .hidden { + display: none; + } + + .not-visible { + opacity: 0; + } + + paper-icon-button { + width: 24px; + padding: 16px; + } + + #selectionBar { + position: absolute; + height: 2px; + bottom: 0; + left: 0; + right: 0; + background-color: var(--paper-tabs-selection-bar-color, --paper-yellow-a100); + -webkit-transform-origin: left center; + transform-origin: left center; + -webkit-transform: scale(0); + transform: scale(0); + transition: -webkit-transform; + transition: transform; + + @apply(--paper-tabs-selection-bar); + } + + #selectionBar.align-bottom { + top: 0; + bottom: auto; + } + + #selectionBar.expand { + transition-duration: 0.15s; + transition-timing-function: cubic-bezier(0.4, 0.0, 1, 1); + } + + #selectionBar.contract { + transition-duration: 0.18s; + transition-timing-function: cubic-bezier(0.0, 0.0, 0.2, 1); + } + + #tabsContent > ::content > *:not(#selectionBar) { + height: 100%; + } + + </style> + + <template> + + <paper-icon-button icon="paper-tabs:chevron-left" class$="[[_computeScrollButtonClass(_leftHidden, scrollable, hideScrollButtons)]]" on-up="_onScrollButtonUp" on-down="_onLeftScrollButtonDown"></paper-icon-button> + + <div id="tabsContainer" class="flex" on-scroll="_scroll"> + + <div id="tabsContent" class$="[[_computeTabsContentClass(scrollable)]]"> + + <content select="*"></content> + + <div id="selectionBar" class$="[[_computeSelectionBarClass(noBar, alignBottom)]]" + on-transitionend="_onBarTransitionEnd"></div> + + </div> + + </div> + + <paper-icon-button icon="paper-tabs:chevron-right" class$="[[_computeScrollButtonClass(_rightHidden, scrollable, hideScrollButtons)]]" on-up="_onScrollButtonUp" on-down="_onRightScrollButtonDown"></paper-icon-button> + + </template> + +</dom-module> + +<script> + + Polymer({ + + is: 'paper-tabs', + + behaviors: [ + Polymer.IronResizableBehavior, + Polymer.IronMenubarBehavior + ], + + properties: { + + /** + * If true, ink ripple effect is disabled. + */ + noink: { + type: Boolean, + value: false + }, + + /** + * If true, the bottom bar to indicate the selected tab will not be shown. + */ + noBar: { + type: Boolean, + value: false + }, + + /** + * If true, the slide effect for the bottom bar is disabled. + */ + noSlide: { + type: Boolean, + value: false + }, + + /** + * If true, tabs are scrollable and the tab width is based on the label width. + */ + scrollable: { + type: Boolean, + value: false + }, + + /** + * If true, dragging on the tabs to scroll is disabled. + */ + disableDrag: { + type: Boolean, + value: false + }, + + /** + * If true, scroll buttons (left/right arrow) will be hidden for scrollable tabs. + */ + hideScrollButtons: { + type: Boolean, + value: false + }, + + /** + * If true, the tabs are aligned to bottom (the selection bar appears at the top). + */ + alignBottom: { + type: Boolean, + value: false + }, + + /** + * Gets or sets the selected element. The default is to use the index of the item. + */ + selected: { + type: String, + notify: true + }, + + selectable: { + type: String, + value: 'paper-tab' + }, + + _step: { + type: Number, + value: 10 + }, + + _holdDelay: { + type: Number, + value: 1 + }, + + _leftHidden: { + type: Boolean, + value: false + }, + + _rightHidden: { + type: Boolean, + value: false + }, + + _previousTab: { + type: Object + } + }, + + hostAttributes: { + role: 'tablist' + }, + + listeners: { + 'iron-resize': '_onResize', + 'iron-select': '_onIronSelect', + 'iron-deselect': '_onIronDeselect' + }, + + _computeScrollButtonClass: function(hideThisButton, scrollable, hideScrollButtons) { + if (!scrollable || hideScrollButtons) { + return 'hidden'; + } + + if (hideThisButton) { + return 'not-visible'; + } + + return ''; + }, + + _computeTabsContentClass: function(scrollable) { + return scrollable ? 'scrollable' : 'horizontal layout'; + }, + + _computeSelectionBarClass: function(noBar, alignBottom) { + if (noBar) { + return 'hidden'; + } else if (alignBottom) { + return 'align-bottom'; + } + }, + + // TODO(cdata): Add `track` response back in when gesture lands. + + _onResize: function() { + this.debounce('_onResize', function() { + this._scroll(); + this._tabChanged(this.selectedItem); + }, 10); + }, + + _onIronSelect: function(event) { + this._tabChanged(event.detail.item, this._previousTab); + this._previousTab = event.detail.item; + this.cancelDebouncer('tab-changed'); + }, + + _onIronDeselect: function(event) { + this.debounce('tab-changed', function() { + this._tabChanged(null, this._previousTab); + // See polymer/polymer#1305 + }, 1); + }, + + get _tabContainerScrollSize () { + return Math.max( + 0, + this.$.tabsContainer.scrollWidth - + this.$.tabsContainer.offsetWidth + ); + }, + + _scroll: function() { + var scrollLeft; + + if (!this.scrollable) { + return; + } + + scrollLeft = this.$.tabsContainer.scrollLeft; + + this._leftHidden = scrollLeft === 0; + this._rightHidden = scrollLeft === this._tabContainerScrollSize; + }, + + _onLeftScrollButtonDown: function() { + this._holdJob = setInterval(this._scrollToLeft.bind(this), this._holdDelay); + }, + + _onRightScrollButtonDown: function() { + this._holdJob = setInterval(this._scrollToRight.bind(this), this._holdDelay); + }, + + _onScrollButtonUp: function() { + clearInterval(this._holdJob); + this._holdJob = null; + }, + + _scrollToLeft: function() { + this.$.tabsContainer.scrollLeft -= this._step; + }, + + _scrollToRight: function() { + this.$.tabsContainer.scrollLeft += this._step; + }, + + _tabChanged: function(tab, old) { + if (!tab) { + this._positionBar(0, 0); + return; + } + + var r = this.$.tabsContent.getBoundingClientRect(); + var w = r.width; + var tabRect = tab.getBoundingClientRect(); + var tabOffsetLeft = tabRect.left - r.left; + + this._pos = { + width: this._calcPercent(tabRect.width, w), + left: this._calcPercent(tabOffsetLeft, w) + }; + + if (this.noSlide || old == null) { + // position bar directly without animation + this._positionBar(this._pos.width, this._pos.left); + return; + } + + var oldRect = old.getBoundingClientRect(); + var oldIndex = this.items.indexOf(old); + var index = this.items.indexOf(tab); + var m = 5; + + // bar animation: expand + this.$.selectionBar.classList.add('expand'); + + if (oldIndex < index) { + this._positionBar(this._calcPercent(tabRect.left + tabRect.width - oldRect.left, w) - m, + this._left); + } else { + this._positionBar(this._calcPercent(oldRect.left + oldRect.width - tabRect.left, w) - m, + this._calcPercent(tabOffsetLeft, w) + m); + } + + if (this.scrollable) { + this._scrollToSelectedIfNeeded(tabRect.width, tabOffsetLeft); + } + }, + + _scrollToSelectedIfNeeded: function(tabWidth, tabOffsetLeft) { + var l = tabOffsetLeft - this.$.tabsContainer.scrollLeft; + if (l < 0) { + this.$.tabsContainer.scrollLeft += l; + } else { + l += (tabWidth - this.$.tabsContainer.offsetWidth); + if (l > 0) { + this.$.tabsContainer.scrollLeft += l; + } + } + }, + + _calcPercent: function(w, w0) { + return 100 * w / w0; + }, + + _positionBar: function(width, left) { + this._width = width; + this._left = left; + this.transform( + 'translate3d(' + left + '%, 0, 0) scaleX(' + (width / 100) + ')', + this.$.selectionBar); + }, + + _onBarTransitionEnd: function(e) { + var cl = this.$.selectionBar.classList; + // bar animation: expand -> contract + if (cl.contains('expand')) { + cl.remove('expand'); + cl.add('contract'); + this._positionBar(this._pos.width, this._pos.left); + // bar animation done + } else if (cl.contains('contract')) { + cl.remove('contract'); + } + } + + }); + +</script> diff --git a/third_party/polymer/v1_0/components/paper-toast/.bower.json b/third_party/polymer/v1_0/components/paper-toast/.bower.json new file mode 100644 index 0000000..3c32c49d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/.bower.json @@ -0,0 +1,38 @@ +{ + "name": "paper-toast", + "version": "1.0.0", + "description": "A material design notification toast", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toast", + "notification" + ], + "main": "paper-toast.html", + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-announcer": "polymerelements/iron-a11y-announcer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-toast", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "71e6c327f7aafe9c71010c83d4c4571f63990072" + }, + "_source": "git://github.com/PolymerElements/paper-toast.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-toast" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-toast/.gitignore b/third_party/polymer/v1_0/components/paper-toast/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-toast/README.md b/third_party/polymer/v1_0/components/paper-toast/README.md new file mode 100644 index 0000000..722ec35 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/README.md @@ -0,0 +1,4 @@ +paper-toast +============ + +A material design notification toast. diff --git a/third_party/polymer/v1_0/components/paper-toast/bower.json b/third_party/polymer/v1_0/components/paper-toast/bower.json new file mode 100644 index 0000000..a4fd51a --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/bower.json @@ -0,0 +1,28 @@ +{ + "name": "paper-toast", + "version": "1.0.0", + "description": "A material design notification toast", + "private": true, + "license": "http://polymer.github.io/LICENSE.txt", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toast", + "notification" + ], + "main": "paper-toast.html", + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0", + "iron-a11y-announcer": "polymerelements/iron-a11y-announcer#^1.0.0" + }, + "devDependencies": { + "iron-component-page": "polymerelements/iron-component-page#^1.0.0", + "paper-button": "polymerelements/paper-button#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-toast/hero.svg b/third_party/polymer/v1_0/components/paper-toast/hero.svg new file mode 100644 index 0000000..bfdc180 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/hero.svg @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <path d="M164,114H13V88h151V114z M15,112h147V90H15V112z"/> + <rect x="26" y="100" width="79" height="2"/> + <rect x="135" y="100" width="16" height="2"/> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-toast/index.html b/third_party/polymer/v1_0/components/paper-toast/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-toast/paper-toast.html b/third_party/polymer/v1_0/components/paper-toast/paper-toast.html new file mode 100644 index 0000000..5afdae3 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toast/paper-toast.html @@ -0,0 +1,164 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/typography.html"> +<link rel="import" href="../iron-a11y-announcer/iron-a11y-announcer.html"> + +<!-- +`paper-toast` provides a subtle notification toast. + +@group Paper Elements +@element paper-toast +@demo demo/index.html +@hero hero.svg +--> +<dom-module id="paper-toast"> + <style> + :host { + display: inline-block; + position: fixed; + + background: #323232; + color: #f1f1f1; + min-height: 48px; + min-width: 288px; + padding: 16px 24px 12px; + box-sizing: border-box; + box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); + border-radius: 2px; + bottom: 12px; + left: 12px; + font-size: 14px; + cursor: default; + + -webkit-transition: visibility 0.3s, -webkit-transform 0.3s; + transition: visibility 0.3s, transform 0.3s; + + -webkit-transform: translateY(100px); + transform: translateY(100px); + + visibility: hidden; + } + + :host(.capsule) { + border-radius: 24px; + } + + :host(.fit-bottom) { + bottom: 0; + left: 0; + width: 100%; + min-width: 0; + border-radius: 0; + } + + :host(.paper-toast-open){ + visibility: visible; + + -webkit-transform: translateY(0px); + transform: translateY(0px); + } + </style> + <template> + <span id="label">{{text}}</span> + <content></content> + </template> +</dom-module> +<script> +(function() { + + var PaperToast = Polymer({ + is: 'paper-toast', + + properties: { + /** + * The duration in milliseconds to show the toast. + */ + duration: { + type: Number, + value: 3000 + }, + + /** + * The text to display in the toast. + */ + text: { + type: String, + value: "" + }, + + /** + * True if the toast is currently visible. + */ + visible: { + type: Boolean, + readOnly: true, + value: false, + observer: '_visibleChanged' + } + }, + + created: function() { + Polymer.IronA11yAnnouncer.requestAvailability(); + }, + + ready: function() { + this.async(function() { + this.hide(); + }); + }, + + /** + * Show the toast. + * @method show + */ + show: function() { + if (PaperToast.currentToast) { + PaperToast.currentToast.hide(); + } + PaperToast.currentToast = this; + this.removeAttribute('aria-hidden'); + this._setVisible(true); + this.fire('iron-announce', { + text: this.text + }); + this.debounce('hide', this.hide, this.duration); + }, + + /** + * Hide the toast + */ + hide: function() { + this.setAttribute('aria-hidden', 'true'); + this._setVisible(false); + }, + + /** + * Toggle the opened state of the toast. + * @method toggle + */ + toggle: function() { + if (!this.visible) { + this.show(); + } else { + this.hide(); + } + }, + + _visibleChanged: function(visible) { + this.toggleClass('paper-toast-open', visible); + } + }); + + PaperToast.currentToast = null; + +})(); +</script> diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/.bower.json b/third_party/polymer/v1_0/components/paper-toggle-button/.bower.json new file mode 100644 index 0000000..dae78ed --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-toggle-button", + "version": "1.0.1", + "description": "A material design toggle button control", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toggle", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toggle-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-toggle-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "_release": "1.0.1", + "_resolution": { + "type": "version", + "tag": "v1.0.1", + "commit": "577b045eea2d8e7623fcce40001a2d9e7008bd60" + }, + "_source": "git://github.com/PolymerElements/paper-toggle-button.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-toggle-button" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/.gitignore b/third_party/polymer/v1_0/components/paper-toggle-button/.gitignore new file mode 100644 index 0000000..8d4ae25 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/.gitignore @@ -0,0 +1 @@ +bower_components diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/README.md b/third_party/polymer/v1_0/components/paper-toggle-button/README.md new file mode 100644 index 0000000..0924fe2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/README.md @@ -0,0 +1,26 @@ +paper-toggle-button +=================== + +`paper-toggle-button` provides a ON/OFF switch that user can toggle the state +by tapping or by dragging the swtich. + +Example: + +```html +<paper-toggle-button></paper-toggle-button> +``` + +Styling toggle-button: + +```html +<style is="custom-style"> + * { + --paper-toggle-button-unchecked-bar-color: #FF4081; + --paper-toggle-button-unchecked-button-color: #9c27b0; + --paper-toggle-button-unchecked-ink-color: #009688; + --paper-toggle-button-checked-bar-color: #5677fc; + --paper-toggle-button-checked-button-color: #ff4081; + --paper-toggle-button-checked-ink-color: #ff4081; + } +</style> +``` diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/bower.json b/third_party/polymer/v1_0/components/paper-toggle-button/bower.json new file mode 100644 index 0000000..f7404f2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/bower.json @@ -0,0 +1,36 @@ +{ + "name": "paper-toggle-button", + "version": "1.0.1", + "description": "A material design toggle button control", + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toggle", + "control" + ], + "private": true, + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toggle-button" + }, + "license": "http://polymer.github.io/LICENSE.txt", + "homepage": "https://github.com/PolymerElements/paper-toggle-button", + "ignore": [], + "dependencies": { + "paper-ripple": "PolymerElements/paper-ripple#^1.0.0", + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "paper-behaviors": "PolymerElements/paper-behaviors#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "web-component-tester": "*", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.0.0", + "iron-flex-layout": "PolymerElements/iron-flex-layout#^1.0.0", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/hero.svg b/third_party/polymer/v1_0/components/paper-toggle-button/hero.svg new file mode 100644 index 0000000..21607b2 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/hero.svg @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Generator: Adobe Illustrator 17.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> +<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" + viewBox="0 0 225 126" enable-background="new 0 0 225 126" xml:space="preserve"> +<g id="background" display="none"> + <rect display="inline" fill="#B0BEC5" width="225" height="126"/> +</g> +<g id="label"> +</g> +<g id="art"> + <g> + <circle cx="123.8" cy="63" r="15.7"/> + <path d="M123,77H98.5c-7.7,0-14-6.3-14-14s6.3-14,14-14H123c7.7,0,14,6.3,14,14S130.7,77,123,77z M98.5,51c-6.6,0-12,5.4-12,12 + s5.4,12,12,12H123c6.6,0,12-5.4,12-12s-5.4-12-12-12H98.5z"/> + </g> + <g id="ic_x5F_add_x0D_"> + </g> +</g> +<g id="Guides"> +</g> +</svg> diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/index.html b/third_party/polymer/v1_0/components/paper-toggle-button/index.html new file mode 100644 index 0000000..e871f17 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/index.html @@ -0,0 +1,26 @@ +<!doctype html> +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE +The complete set of authors may be found at http://polymer.github.io/AUTHORS +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/paper-toggle-button.css b/third_party/polymer/v1_0/components/paper-toggle-button/paper-toggle-button.css new file mode 100644 index 0000000..8eb9d2d --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/paper-toggle-button.css @@ -0,0 +1,108 @@ +/* +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +*/ + +:host { + display: inline-block; +} + +:host([disabled]) { + pointer-events: none; +} + +:host(:focus) { + outline:none; +} + +:host .toggle-bar { + background-color: var(--paper-toggle-button-unchecked-bar-color); +} + +:host .toggle-button { + background-color: var(--paper-toggle-button-unchecked-button-color); +} + +:host([checked]) .toggle-bar { + background-color: var(--paper-toggle-button-checked-bar-color); +} + +:host([checked]) .toggle-button { + background-color: var(--paper-toggle-button-checked-button-color); +} + +:host .toggle-ink { + color: var(--paper-toggle-button-unchecked-ink-color); +} + +:host([checked]) .toggle-ink { + color: var(--paper-toggle-button-checked-ink-color); +} + +/* ID selectors should not be overriden by users. */ + +#toggleContainer { + position: relative; + width: 36px; + height: 14px; +} + +#toggleBar { + position: absolute; + height: 100%; + width: 100%; + border-radius: 8px; + pointer-events: none; + opacity: 0.4; + transition: background-color linear .08s; +} + +:host([checked]) #toggleBar { + opacity: 0.5; +} + +:host([disabled]) #toggleBar { + background-color: #000; + opacity: 0.12; +} + +#toggleButton { + position: absolute; + top: -3px; + height: 20px; + width: 20px; + border-radius: 50%; + box-shadow: 0 1px 5px 0 rgba(0, 0, 0, 0.6); + transition: -webkit-transform linear .08s, background-color linear .08s; + transition: transform linear .08s, background-color linear .08s; + will-change: transform; +} + +#toggleButton.dragging { + -webkit-transition: none; + transition: none; +} + +:host([checked]) #toggleButton { + -webkit-transform: translate(16px, 0); + transform: translate(16px, 0); +} + +:host([disabled]) #toggleButton { + background-color: #bdbdbd; + opacity: 1; +} + +#ink { + position: absolute; + top: -14px; + left: -14px; + width: 48px; + height: 48px; + opacity: 0.5; +} diff --git a/third_party/polymer/v1_0/components/paper-toggle-button/paper-toggle-button.html b/third_party/polymer/v1_0/components/paper-toggle-button/paper-toggle-button.html new file mode 100644 index 0000000..8e9eee4 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toggle-button/paper-toggle-button.html @@ -0,0 +1,183 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-ripple/paper-ripple.html"> +<link rel="import" href="../paper-behaviors/paper-radio-button-behavior.html"> + +<!-- +`paper-toggle-button` provides a ON/OFF switch that user can toggle the state +by tapping or by dragging the switch. + +Example: + + <paper-toggle-button></paper-toggle-button> + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-toggle-button-unchecked-bar-color` | Slider color when the input is not checked | `#000000` +`--paper-toggle-button-unchecked-button-color` | Button color when the input is not checked | `--paper-grey-50` +`--paper-toggle-button-unchecked-ink-color` | Selected/focus ripple color when the input is not checked | `--dark-primary-color` +`--paper-toggle-button-checked-bar-color` | Slider button color when the input is checked | `--google-green-500` +`--paper-toggle-button-checked-button-color` | Button color when the input is checked | `--google-green-500` +`--paper-toggle-button-checked-ink-color` | Selected/focus ripple color when the input is checked | `--google-green-500` + +@group Paper Elements +@element paper-toggle-button +@hero hero.svg +@demo demo/index.html +--> +<style is="custom-style"> + :root { + --paper-toggle-button-unchecked-bar-color: #000000; + --paper-toggle-button-unchecked-button-color: var(--paper-grey-50); + --paper-toggle-button-unchecked-ink-color: var(--dark-primary-color); + + --paper-toggle-button-checked-bar-color: var(--google-green-500); + --paper-toggle-button-checked-button-color: var(--google-green-500); + --paper-toggle-button-checked-ink-color: var(--google-green-500); + } +</style> + +<dom-module id="paper-toggle-button"> + + <link rel="import" type="css" href="paper-toggle-button.css"> + + <template> + + <div id="toggleContainer"> + <div id="toggleBar" class="toggle-bar"></div> + <div id="toggleButton" class="toggle-button"> + <paper-ripple id="ink" class="toggle-ink circle" recenters></paper-ripple> + </div> + </div> + + </template> + + <script> + Polymer({ + is: 'paper-toggle-button', + + behaviors: [ + Polymer.PaperRadioButtonBehavior + ], + + hostAttributes: { + role: 'button', + 'aria-pressed': 'false', + tabindex: 0 + }, + + properties: { + /** + * Fired when the checked state changes due to user interaction. + * + * @event change + */ + /** + * Fired when the checked state changes. + * + * @event iron-change + */ + /** + * Gets or sets the state, `true` is checked and `false` is unchecked. + * + * @attribute checked + * @type boolean + * @default false + */ + checked: { + type: Boolean, + value: false, + reflectToAttribute: true, + notify: true, + observer: '_checkedChanged' + }, + + /** + * If true, the button toggles the active state with each tap or press + * of the spacebar. + * + * @attribute toggles + * @type boolean + * @default true + */ + toggles: { + type: Boolean, + value: true, + reflectToAttribute: true + } + }, + + listeners: { + track: '_ontrack' + }, + + ready: function() { + this._isReady = true; + }, + + // button-behavior hook + _buttonStateChanged: function() { + if (this.disabled) { + return; + } + if (this._isReady) { + this.checked = this.active; + } + }, + + _checkedChanged: function(checked) { + this.active = this.checked; + this.fire('iron-change'); + }, + + _ontrack: function(event) { + var track = event.detail; + if (track.state === 'start') { + this._trackStart(track); + } else if (track.state === 'track') { + this._trackMove(track); + } else if (track.state === 'end') { + this._trackEnd(track); + } + }, + + _trackStart: function(track) { + this._width = this.$.toggleBar.offsetWidth / 2; + /* + * keep an track-only check state to keep the dragging behavior smooth + * while toggling activations + */ + this._trackChecked = this.checked; + this.$.toggleButton.classList.add('dragging'); + }, + + _trackMove: function(track) { + var dx = track.dx; + this._x = Math.min(this._width, + Math.max(0, this._trackChecked ? this._width + dx : dx)); + this.translate3d(this._x + 'px', 0, 0, this.$.toggleButton); + this._userActivate(this._x > (this._width / 2)); + }, + + _trackEnd: function(track) { + this.$.toggleButton.classList.remove('dragging'); + this.transform('', this.$.toggleButton); + } + + }); + </script> + +</dom-module> diff --git a/third_party/polymer/v1_0/components/paper-toolbar/.bower.json b/third_party/polymer/v1_0/components/paper-toolbar/.bower.json new file mode 100644 index 0000000..ac01bd5 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toolbar/.bower.json @@ -0,0 +1,45 @@ +{ + "name": "paper-toolbar", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design toolbar that is easily customizable", + "private": true, + "main": [ + "paper-toolbar.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toolbar", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toolbar.git" + }, + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + }, + "homepage": "https://github.com/PolymerElements/paper-toolbar", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "6d0a50375e529a5f750c3a30324d5de8a8824fd1" + }, + "_source": "git://github.com/PolymerElements/paper-toolbar.git", + "_target": "^1.0.0", + "_originalSource": "PolymerElements/paper-toolbar" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/paper-toolbar/.gitignore b/third_party/polymer/v1_0/components/paper-toolbar/.gitignore new file mode 100644 index 0000000..fbe05fc --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toolbar/.gitignore @@ -0,0 +1 @@ +bower_components/ diff --git a/third_party/polymer/v1_0/components/paper-toolbar/README.md b/third_party/polymer/v1_0/components/paper-toolbar/README.md new file mode 100644 index 0000000..d9f7c05 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toolbar/README.md @@ -0,0 +1,51 @@ +paper-toolbar +============ + +`paper-toolbar` is a horizontal bar containing items that can be used for +label, navigation, search and actions. The items place inside the +`paper-toolbar` are projected into a `class="horizontal center layout"` container inside of +`paper-toolbar`'s Shadow DOM. You can use flex attributes to control the items' +sizing. + +Example: + +```html +<paper-toolbar> + <paper-icon-button icon="menu" on-tap="{{menuAction}}"></paper-icon-button> + <div title>Title</div> + <paper-icon-button icon="more" on-tap="{{moreAction}}"></paper-icon-button> +</paper-toolbar> +``` + +`paper-toolbar` has a standard height, but can made be taller by setting `tall` +class on the `paper-toolbar`. This will make the toolbar 3x the normal height. + +```html +<paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> +</paper-toolbar> +``` + +Apply `medium-tall` class to make the toolbar medium tall. This will make the +toolbar 2x the normal height. + +```html +<paper-toolbar class="medium-tall"> + <paper-icon-button icon="menu"></paper-icon-button> +</paper-toolbar> +``` + +When `tall`, items can pin to either the top (default), middle or bottom. Use +`middle` class for middle content and `bottom` class for bottom content. + +```html +<paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> + <div title class="middle">Middle Title</div> + <div title class="bottom">Bottom Title</div> +</paper-toolbar> +``` + +For `medium-tall` toolbar, the middle and bottom contents overlap and are +pinned to the bottom. But `middleJustify` and `bottomJustify` attributes are +still honored separately. diff --git a/third_party/polymer/v1_0/components/paper-toolbar/bower.json b/third_party/polymer/v1_0/components/paper-toolbar/bower.json new file mode 100644 index 0000000..3c26395 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toolbar/bower.json @@ -0,0 +1,35 @@ +{ + "name": "paper-toolbar", + "version": "1.0.0", + "license": "http://polymer.github.io/LICENSE.txt", + "description": "A material design toolbar that is easily customizable", + "private": true, + "main": [ + "paper-toolbar.html" + ], + "authors": [ + "The Polymer Authors" + ], + "keywords": [ + "web-components", + "polymer", + "toolbar", + "layout" + ], + "repository": { + "type": "git", + "url": "git://github.com/PolymerElements/paper-toolbar.git" + }, + "dependencies": { + "paper-styles": "PolymerElements/paper-styles#^1.0.0", + "polymer": "Polymer/polymer#^1.0.0" + }, + "devDependencies": { + "iron-icons": "PolymerElements/iron-icons#^1.0.0", + "paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0", + "iron-component-page": "PolymerElements/iron-component-page#^1.0.0", + "test-fixture": "PolymerElements/test-fixture#^1.0.0", + "web-component-tester": "*", + "webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0" + } +} diff --git a/third_party/polymer/v1_0/components/paper-toolbar/index.html b/third_party/polymer/v1_0/components/paper-toolbar/index.html new file mode 100644 index 0000000..6533b73 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toolbar/index.html @@ -0,0 +1,38 @@ +<!doctype html> +<!-- + @license + Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt + The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt + The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt + Code distributed by Google as part of the polymer project is also + subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> +<html> +<head> + + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes"> + + <title>paper-toolbar</title> + + <script src="../webcomponentsjs/webcomponents-lite.js"></script> + + <link rel="import" href="../polymer/polymer.html"> + <link rel="import" href="../iron-component-page/iron-component-page.html"> + + <style> + + body { + margin: 16px; + } + + </style> + +</head> +<body> + + <iron-component-page></iron-component-page> + +</body> +</html> diff --git a/third_party/polymer/v1_0/components/paper-toolbar/paper-toolbar.html b/third_party/polymer/v1_0/components/paper-toolbar/paper-toolbar.html new file mode 100644 index 0000000..1bee9c3 --- /dev/null +++ b/third_party/polymer/v1_0/components/paper-toolbar/paper-toolbar.html @@ -0,0 +1,375 @@ +<!-- +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--> + +<link rel="import" href="../polymer/polymer.html"> +<link rel="import" href="../paper-styles/paper-styles.html"> + +<!-- +`paper-toolbar` is a horizontal bar containing items that can be used for +label, navigation, search and actions. The items place inside the +`paper-toolbar` are projected into a `class="horizontal center layout"` container inside of +`paper-toolbar`'s Shadow DOM. You can use flex attributes to control the items' +sizing. + +Example: + + <paper-toolbar> + <paper-icon-button icon="menu" on-tap="menuAction"></paper-icon-button> + <div title>Title</div> + <paper-icon-button icon="more" on-tap="moreAction"></paper-icon-button> + </paper-toolbar> + +`paper-toolbar` has a standard height, but can made be taller by setting `tall` +class on the `paper-toolbar`. This will make the toolbar 3x the normal height. + + <paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> + </paper-toolbar> + +Apply `medium-tall` class to make the toolbar medium tall. This will make the +toolbar 2x the normal height. + + <paper-toolbar class="medium-tall"> + <paper-icon-button icon="menu"></paper-icon-button> + </paper-toolbar> + +When `tall`, items can pin to either the top (default), middle or bottom. Use +`middle` class for middle content and `bottom` class for bottom content. + + <paper-toolbar class="tall"> + <paper-icon-button icon="menu"></paper-icon-button> + <div title class="middle">Middle Title</div> + <div title class="bottom">Bottom Title</div> + </paper-toolbar> + +For `medium-tall` toolbar, the middle and bottom contents overlap and are +pinned to the bottom. But `middleJustify` and `bottomJustify` attributes are +still honored separately. + +### Styling + +The following custom properties and mixins are available for styling: + +Custom property | Description | Default +----------------|-------------|---------- +`--paper-toolbar-background` | Toolbar background color | `--default-primary-color` +`--paper-toolbar-color` | Toolbar foreground color | `--text-primary-color` +`--paper-toolbar` | Mixin applied to the toolbar | `{}` + +### Accessibility + +`<paper-toolbar>` has `role="toolbar"` by default. Any elements with the `title` attribute will +be used as the label of the toolbar via `aria-labelledby`. + +@demo demo/index.html +--> + +<dom-module id="paper-toolbar"> + + <style> + :host { + /* technical */ + display: block; + position: relative; + box-sizing: border-box; + -moz-box-sizing: border-box; + + /* size */ + height: 64px; + + background: var(--paper-toolbar-background, --default-primary-color); + color: var(--paper-toolbar-color, --text-primary-color); + + @apply(--paper-toolbar); + } + + :host(.animate) { + /* transition */ + transition: height 0.18s ease-in; + } + + :host(.medium-tall) { + height: 128px; + } + + :host(.tall) { + height: 192px; + } + + .toolbar-tools { + position: relative; + height: 64px; + padding: 0 16px; + pointer-events: none; + } + + /* + * TODO: Where should media query breakpoints live so they can be shared between elements? + */ + + @media (max-width: 639px) { + :host { + height: 56px; + } + + :host(.medium-tall) { + height: 112px; + } + + :host(.tall) { + height: 168px; + } + + .toolbar-tools { + height: 56px; + } + } + + #topBar { + position: relative; + z-index: 1; + } + + /* middle bar */ + #middleBar { + position: absolute; + top: 0; + right: 0; + left: 0; + z-index: 2; + } + + :host(.tall) #middleBar, + :host(.medium-tall) #middleBar { + -webkit-transform: translateY(100%); + transform: translateY(100%); + } + + /* bottom bar */ + #bottomBar { + position: absolute; + right: 0; + bottom: 0; + left: 0; + z-index: 1; + } + + /* + * make elements (e.g. buttons) respond to mouse/touch events + * + * `.toolbar-tools` disables touch events so multiple toolbars can stack and not + * absorb events. All children must have pointer events re-enabled to work as + * expected. + */ + .toolbar-tools > ::content > *:not([disabled]) { + pointer-events: auto; + } + + .toolbar-tools > ::content [title] { + @apply(--paper-font-title); + @apply(--layout-flex); + + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; + + /* + * Polymer/polymer/issues/1525 + * --paper-font-title defines a `font-weight` + * let's override its value, but we need `important!` + * because all mixins are resolved in rule's selector that has higher precedence + * than the current selector. + */ + font-weight: 400 !important; + } + + /** + * TODO: Refactor these selectors + * Work in progress. + */ + .toolbar-tools > ::content paper-icon-button[icon=menu] { + margin-left: -8px; + margin-right: 24px; + } + + .toolbar-tools > ::content paper-icon-button + paper-icon-button { + margin-right: -8px; + } + + .toolbar-tools > ::content > [title], + .toolbar-tools > ::content[select=".middle"] > [title], + .toolbar-tools > ::content[select=".bottom"] > [title] { + margin-left: 56px; + } + + .toolbar-tools > ::content > paper-icon-button + [title], + .toolbar-tools > ::content[select=".middle"] paper-icon-button + [title], + .toolbar-tools > ::content[select=".bottom"] paper-icon-button + [title] { + margin-left: 0; + } + </style> + + <template> + + <div id="topBar" class$="[[_computeBarClassName(justify)]]"> + <content select=":not(.middle):not(.bottom)"></content> + </div> + + <div id="middleBar" class$="[[_computeBarClassName(middleJustify)]]"> + <content select=".middle"></content> + </div> + + <div id="bottomBar" class$="[[_computeBarClassName(bottomJustify)]]"> + <content select=".bottom"></content> + </div> + + </template> + +</dom-module> + +<script> + + (function() { + + 'use strict'; + + function classNames(obj) { + var classNames = []; + for (var key in obj) { + if (obj.hasOwnProperty(key) && obj[key]) { + classNames.push(key); + } + } + + return classNames.join(' '); + } + + Polymer({ + + is: 'paper-toolbar', + + hostAttributes: { + 'role': 'toolbar' + }, + + properties: { + + /** + * Controls how the items are aligned horizontally when they are placed + * at the bottom. + * Options are `start`, `center`, `end`, `justified` and `around`. + * + * @attribute bottomJustify + * @type string + * @default '' + */ + bottomJustify: { + type: String, + value: '' + }, + + /** + * Controls how the items are aligned horizontally. + * Options are `start`, `center`, `end`, `justified` and `around`. + * + * @attribute justify + * @type string + * @default '' + */ + justify: { + type: String, + value: '' + }, + + /** + * Controls how the items are aligned horizontally when they are placed + * in the middle. + * Options are `start`, `center`, `end`, `justified` and `around`. + * + * @attribute middleJustify + * @type string + * @default '' + */ + middleJustify: { + type: String, + value: '' + } + + }, + + attached: function() { + this._observer = this._observe(this); + this._updateAriaLabelledBy(); + }, + + detached: function() { + if (this._observer) { + this._observer.disconnect(); + } + }, + + _observe: function(node) { + var observer = new MutationObserver(function() { + this._updateAriaLabelledBy(); + }.bind(this)); + observer.observe(node, { + childList: true, + subtree: true + }); + return observer; + }, + + _updateAriaLabelledBy: function() { + var labelledBy = []; + var contents = Polymer.dom(this.root).querySelectorAll('content'); + for (var content, index = 0; content = contents[index]; index++) { + var nodes = Polymer.dom(content).getDistributedNodes(); + for (var node, jndex = 0; node = nodes[jndex]; jndex++) { + if (node.hasAttribute && node.hasAttribute('title')) { + if (node.id) { + labelledBy.push(node.id); + } else { + var id = 'paper-toolbar-label-' + Math.floor(Math.random() * 10000); + node.id = id; + labelledBy.push(id); + } + } + } + } + if (labelledBy.length > 0) { + this.setAttribute('aria-labelledby', labelledBy.join(' ')); + } + }, + + _computeBarClassName: function(barJustify) { + var classObj = { + center: true, + horizontal: true, + layout: true, + 'toolbar-tools': true + }; + + // If a blank string or any falsy value is given, no other class name is + // added. + if (barJustify) { + var justifyClassName = (barJustify === 'justified') ? + barJustify : + barJustify + '-justified'; + + classObj[justifyClassName] = true; + } + + return classNames(classObj); + } + + }); + + }()); + +</script> diff --git a/third_party/polymer/v1_0/components/polymer-externs/.bower.json b/third_party/polymer/v1_0/components/polymer-externs/.bower.json new file mode 100644 index 0000000..3b1c1de --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer-externs/.bower.json @@ -0,0 +1,14 @@ +{ + "name": "polymer-externs", + "homepage": "https://github.com/PolymerLabs/polymer-externs", + "version": "1.0.0", + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "1f2d54817701edfd0ded01e88ae0549e48efac49" + }, + "_source": "git://github.com/PolymerLabs/polymer-externs.git", + "_target": "~1.0.0", + "_originalSource": "PolymerLabs/polymer-externs" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/polymer-externs/polymer.externs.js b/third_party/polymer/v1_0/components/polymer-externs/polymer.externs.js new file mode 100644 index 0000000..d07a15b --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer-externs/polymer.externs.js @@ -0,0 +1,342 @@ +/** + * @fileoverview Closure compiler externs for the Polymer library. + * + * @externs + * @license + * Copyright (c) 2015 The Polymer Project Authors. All rights reserved. + * This code may only be used under the BSD style license found at + * http://polymer.github.io/LICENSE.txt. The complete set of authors may be + * found at http://polymer.github.io/AUTHORS.txt. The complete set of + * contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt. Code + * distributed by Google as part of the polymer project is also subject to an + * additional IP rights grant found at http://polymer.github.io/PATENTS.txt. + */ + +/** + * @param {!{is: string}} descriptor The Polymer descriptor of the element. + * @see https://github.com/Polymer/polymer/blob/0.8-preview/PRIMER.md#custom-element-registration + */ +var Polymer = function(descriptor) {}; + + +/** @constructor @extends {HTMLElement} */ +var PolymerElement = function() {}; + +/** + * A mapping from ID to element in this Polymer Element's local DOM. + * @type {!Object} + */ +PolymerElement.prototype.$; + +/** + * True if the element has been attached to the DOM. + * @type {boolean} + */ +PolymerElement.prototype.isAttached; + +/** + * The root node of the element. + * @type {!Node} + */ +PolymerElement.prototype.root; + +/** + * Returns the first node in this element’s local DOM that matches selector. + * @param {string} selector + */ +PolymerElement.prototype.$$ = function(selector) {}; + +/** @type {string} The Custom element tag name. */ +PolymerElement.prototype.is; + +/** @type {string} The native element this element extends. */ +PolymerElement.prototype.extends; + +/** + * An array of objects whose properties get mixed in to this element. + * + * @type {!Array<!Object>|undefined} + */ +PolymerElement.prototype.mixins; + +/** + * A string-separated list of dependent properties that should result in a + * change function being called. These observers differ from single-property + * observers in that the change handler is called asynchronously. + * + * @type {!Object<string, string>|undefined} + */ +PolymerElement.prototype.observers; + +/** On create callback. */ +PolymerElement.prototype.created = function() {}; +/** On ready callback. */ +PolymerElement.prototype.ready = function() {}; +/** On attached to the DOM callback. */ +PolymerElement.prototype.attached = function() {}; +/** On detached from the DOM callback. */ +PolymerElement.prototype.detached = function() {}; + +/** + * Callback fired when an attribute on the element has been changed. + * + * @param {string} name The name of the attribute that changed. + */ +PolymerElement.prototype.attributeChanged = function(name) {}; + +/** @typedef {!{ + * type: !Function, + * reflectToAttribute: (boolean|undefined), + * readOnly: (boolean|undefined), + * notify: (boolean|undefined), + * value: *, + * computed: (string|undefined), + * observer: (string|undefined) + * }} */ +PolymerElement.PropertyConfig; + +/** @typedef {!Object<string, (!Function|!PolymerElement.PropertyConfig)>} */ +PolymerElement.Properties; + +/** @type {!PolymerElement.Properties} */ +PolymerElement.prototype.properties; + +/** @type {!Object<string, *>} */ +PolymerElement.prototype.hostAttributes; + +/** + * An object that maps events to event handler function names. + * @type {!Object<string, string>} + */ +PolymerElement.prototype.listeners; + +/** + * Notifies the event binding system of a change to a property. + * @param {string} path The path to set. + * @param {*} value The value to send in the update notification. + */ +PolymerElement.prototype.notifyPath = function(path, value) {}; + +/** + * Shorthand for setting a property, then calling notifyPath. + * @param {string} path The path to set. + * @param {*} value The new value. + */ +PolymerElement.prototype.setPathValue = function(path, value) {}; + +/** + * Fire an event. + * + * @param {string} type An event name. + * @param {Object=} detail + * @param {{ + * bubbles: (boolean|undefined), + * cancelable: (boolean|undefined), + * node: (!HTMLElement|undefined)}=} options + * @return {Object} event + */ +PolymerElement.prototype.fire = function(type, detail, options) {}; + +/** + * Toggles the named boolean class on the host element, adding the class if + * bool is truthy and removing it if bool is falsey. If node is specified, sets + * the class on node instead of the host element. + * @param {string} name + * @param {boolean} bool + * @param {HTMLElement=} node + */ +PolymerElement.prototype.toggleClass = function(name, bool, node) {}; + +/** + * Toggles the named boolean attribute on the host element, adding the attribute + * if bool is truthy and removing it if bool is falsey. If node is specified, + * sets the attribute on node instead of the host element. + * @param {string} name + * @param {boolean} bool + * @param {HTMLElement=} node + */ +PolymerElement.prototype.toggleAttribute = function(name, bool, node) {}; + +/** + * Moves a boolean attribute from oldNode to newNode, unsetting the attribute + * (if set) on oldNode and setting it on newNode. + * @param {string} name + * @param {!HTMLElement} newNode + * @param {!HTMLElement} oldNode + */ +PolymerElement.prototype.attributeFollows = function(name, newNode, oldNode) {}; + +/** + * @param {!Function} method + * @param {number=} wait + * @return {number} A handle which can be used to cancel the job. + */ +PolymerElement.prototype.async = function(method, wait) {}; + +/** + * @param {number} handle + */ +PolymerElement.prototype.cancelAsync = function(handle) {}; + +/** + * Call debounce to collapse multiple requests for a named task into one + * invocation, which is made after the wait time has elapsed with no new + * request. If no wait time is given, the callback is called at microtask timing + * (guaranteed to be before paint). + * @param {string} jobName + * @param {!Function} callback + * @param {number=} wait + */ +PolymerElement.prototype.debounce = function(jobName, callback, wait) {}; + +/** + * Cancels an active debouncer without calling the callback. + * @param {string} jobName + */ +PolymerElement.prototype.cancelDebouncer = function(jobName) {}; + +/** + * Calls the debounced callback immediately and cancels the debouncer. + * @param {string} jobName + */ +PolymerElement.prototype.flushDebouncer = function(jobName) {}; + +/** + * @param {string} jobName + * @return {boolean} True if the named debounce task is waiting to run. + */ +PolymerElement.prototype.isDebouncerActive = function(jobName) {}; + + +/** + * Applies a CSS transform to the specified node, or this element if no node is + * specified. transform is specified as a string. + * @param {string} transform + * @param {HTMLElement=} node + */ +PolymerElement.prototype.transform = function(transform, node) {}; + +/** + * Transforms the specified node, or this element if no node is specified. + * @param {string} x + * @param {string} y + * @param {string} z + * @param {HTMLElement=} node + */ +PolymerElement.prototype.translate3d = function(x, y, z, node) {}; + +/** + * Dynamically imports an HTML document. + * @param {string} href + * @param {Function=} onload + * @param {Function=} onerror + */ +PolymerElement.prototype.importHref = function(href, onload, onerror) {}; + +/** + * Delete an element from an array. + * @param {!Array} array + * @param {*} item + */ +PolymerElement.prototype.arrayDelete = function(array, item) {}; + +/** + * Resolve a url to make it relative to the current doc. + * @param {string} url + * @return {string} + */ +PolymerElement.prototype.resolveUrl = function(url) {}; + + +/** + * A Polymer DOM API for manipulating DOM such that local DOM and light DOM + * trees are properly maintained. + * + * @constructor + */ +var PolymerDomApi = function() {}; + +/** @param {!Node} node */ +PolymerDomApi.prototype.appendChild = function(node) {}; + +/** + * @param {!Node} node + * @param {!Node} beforeNode + */ +PolymerDomApi.prototype.insertBefore = function(node, beforeNode) {}; + +/** @param {!Node} node */ +PolymerDomApi.prototype.removeChild = function(node) {}; + +/** @type {!Array<!Node>} */ +PolymerDomApi.prototype.childNodes; + +/** @type {?Node} */ +PolymerDomApi.prototype.parentNode; + +/** @type {?Node} */ +PolymerDomApi.prototype.firstChild; + +/** @type {?Node} */ +PolymerDomApi.prototype.lastChild; + +/** @type {?HTMLElement} */ +PolymerDomApi.prototype.firstElementChild; + +/** @type {?HTMLElement} */ +PolymerDomApi.prototype.lastElementChild; + +/** @type {?Node} */ +PolymerDomApi.prototype.previousSibling; + +/** @type {?Node} */ +PolymerDomApi.prototype.nextSibling; + +/** @type {string} */ +PolymerDomApi.prototype.textContent; + +/** @type {string} */ +PolymerDomApi.prototype.innerHTML; + +/** + * @param {string} selector + * @return {?HTMLElement} + */ +PolymerDomApi.prototype.querySelector = function(selector) {}; + +/** + * @param {string} selector + * @return {!Array<?HTMLElement>} + */ +PolymerDomApi.prototype.querySelectorAll = function(selector) {}; + +/** @return {!Array<!Node>} */ +PolymerDomApi.prototype.getDistributedNodes = function() {}; + +/** @return {!Array<!Node>} */ +PolymerDomApi.prototype.getDestinationInsertionPoints = function() {}; + +/** + * @param {string} attribute + * @param {string|number|boolean} value Values are converted to strings with + * ToString, so we accept number and boolean since both convert easily to + * strings. + */ +PolymerDomApi.prototype.setAttribute = function(attribute, value) {}; + +/** @param {string} attribute */ +PolymerDomApi.prototype.removeAttribute = function(attribute) {}; + +/** @type {?DOMTokenList} */ +PolymerDomApi.prototype.classList; + +/** + * Returns a Polymer-friendly API for manipulating DOM of a specified node. + * + * @param {?Node} node + * @return {!PolymerDomApi} + */ +Polymer.dom = function(node) {}; + +Polymer.dom.flush = function() {}; + diff --git a/third_party/polymer/v1_0/components/polymer/.bower.json b/third_party/polymer/v1_0/components/polymer/.bower.json new file mode 100644 index 0000000..5ba173d --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/.bower.json @@ -0,0 +1,36 @@ +{ + "name": "polymer", + "version": "1.0.2", + "main": [ + "polymer.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "/.*", + "/test/" + ], + "authors": [ + "The Polymer Authors (http://polymer.github.io/AUTHORS.txt)" + ], + "repository": { + "type": "git", + "url": "https://github.com/Polymer/polymer.git" + }, + "dependencies": { + "webcomponentsjs": "^0.7.2" + }, + "devDependencies": { + "web-component-tester": "*" + }, + "private": true, + "homepage": "https://github.com/Polymer/polymer", + "_release": "1.0.2", + "_resolution": { + "type": "version", + "tag": "v1.0.2", + "commit": "63f3bf1babfeaba5649345569b1bd9f3d61a88ae" + }, + "_source": "git://github.com/Polymer/polymer.git", + "_target": "~v1.0.0", + "_originalSource": "Polymer/polymer" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/polymer/LICENSE.txt b/third_party/polymer/v1_0/components/polymer/LICENSE.txt new file mode 100644 index 0000000..95987ba --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/LICENSE.txt @@ -0,0 +1,27 @@ +// Copyright (c) 2014 The Polymer Authors. All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/third_party/polymer/v1_0/components/polymer/bower.json b/third_party/polymer/v1_0/components/polymer/bower.json new file mode 100644 index 0000000..9c4f5c9 --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/bower.json @@ -0,0 +1,26 @@ +{ + "name": "polymer", + "version": "1.0.2", + "main": [ + "polymer.html" + ], + "license": "http://polymer.github.io/LICENSE.txt", + "ignore": [ + "/.*", + "/test/" + ], + "authors": [ + "The Polymer Authors (http://polymer.github.io/AUTHORS.txt)" + ], + "repository": { + "type": "git", + "url": "https://github.com/Polymer/polymer.git" + }, + "dependencies": { + "webcomponentsjs": "^0.7.2" + }, + "devDependencies": { + "web-component-tester": "*" + }, + "private": true +} diff --git a/third_party/polymer/v1_0/components/polymer/build.log b/third_party/polymer/v1_0/components/polymer/build.log new file mode 100644 index 0000000..736b31c --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/build.log @@ -0,0 +1,26 @@ +BUILD LOG +--------- +Build Time: 2015-05-28T22:23:07-0700 + +NODEJS INFORMATION +================== +nodejs: v2.0.2 +del: 1.2.0 +gulp: 3.8.11 +gulp-audit: 1.0.0 +gulp-rename: 1.2.2 +gulp-replace: 0.5.3 +gulp-vulcanize: 6.0.0 +lazypipe: 0.2.3 +polyclean: 1.1.0 +run-sequence: 1.1.0 + +REPO REVISIONS +============== +polymer: 3b0d10b4da804703d493da7bd0b5c22fc6f7b173 + +BUILD HASHES +============ +polymer-mini.html: 6643b7ca3675fd7247fb1894a51435e0e1256e32 +polymer-micro.html: 9dda81fc6d99a1bc3c044543c4cad106042930a8 +polymer.html: f9f247c99df9ac2c7fb610aabfe3fcdcbbdbc9f9
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/polymer/polymer-micro.html b/third_party/polymer/v1_0/components/polymer/polymer-micro.html new file mode 100644 index 0000000..1dd6123 --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/polymer-micro.html @@ -0,0 +1,544 @@ +<!-- +@license +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><script>(function() { +function resolve() { +document.body.removeAttribute("unresolved"); +} +if (window.WebComponents) { +addEventListener("WebComponentsReady", resolve); +} else { +resolve(); +} +})(); + +Polymer = { +Settings: function() { +var user = window.Polymer || {}; +location.search.slice(1).split("&").forEach(function(o) { +o = o.split("="); +o[0] && (user[o[0]] = o[1] || true); +}); +var wantShadow = user.dom === "shadow"; +var hasShadow = Boolean(Element.prototype.createShadowRoot); +var nativeShadow = hasShadow && !window.ShadowDOMPolyfill; +var useShadow = wantShadow && hasShadow; +var hasNativeImports = Boolean("import" in document.createElement("link")); +var useNativeImports = hasNativeImports; +var useNativeCustomElements = !window.CustomElements || window.CustomElements.useNative; +return { +wantShadow: wantShadow, +hasShadow: hasShadow, +nativeShadow: nativeShadow, +useShadow: useShadow, +useNativeShadow: useShadow && nativeShadow, +useNativeImports: useNativeImports, +useNativeCustomElements: useNativeCustomElements +}; +}() +}; + +(function() { +var userPolymer = window.Polymer; +window.Polymer = function(prototype) { +var ctor = desugar(prototype); +prototype = ctor.prototype; +var options = { +prototype: prototype +}; +if (prototype.extends) { +options.extends = prototype.extends; +} +Polymer.telemetry._registrate(prototype); +document.registerElement(prototype.is, options); +return ctor; +}; +var desugar = function(prototype) { +prototype = Polymer.Base.chainObject(prototype, Polymer.Base); +prototype.registerCallback(); +return prototype.constructor; +}; +window.Polymer = Polymer; +if (userPolymer) { +for (var i in userPolymer) { +Polymer[i] = userPolymer[i]; +} +} +Polymer.Class = desugar; +})(); + +Polymer.telemetry = { +registrations: [], +_regLog: function(prototype) { +console.log("[" + prototype.is + "]: registered"); +}, +_registrate: function(prototype) { +this.registrations.push(prototype); +Polymer.log && this._regLog(prototype); +}, +dumpRegistrations: function() { +this.registrations.forEach(this._regLog); +} +}; + +Object.defineProperty(window, "currentImport", { +enumerable: true, +configurable: true, +get: function() { +return (document._currentScript || document.currentScript).ownerDocument; +} +}); + +Polymer.Base = { +_addFeature: function(feature) { +this.extend(this, feature); +}, +registerCallback: function() { +this._registerFeatures(); +this._doBehavior("registered"); +}, +createdCallback: function() { +Polymer.telemetry.instanceCount++; +this.root = this; +this._doBehavior("created"); +this._initFeatures(); +}, +attachedCallback: function() { +this.isAttached = true; +this._doBehavior("attached"); +}, +detachedCallback: function() { +this.isAttached = false; +this._doBehavior("detached"); +}, +attributeChangedCallback: function(name) { +this._setAttributeToProperty(this, name); +this._doBehavior("attributeChanged", arguments); +}, +extend: function(prototype, api) { +if (prototype && api) { +Object.getOwnPropertyNames(api).forEach(function(n) { +this.copyOwnProperty(n, api, prototype); +}, this); +} +return prototype || api; +}, +copyOwnProperty: function(name, source, target) { +var pd = Object.getOwnPropertyDescriptor(source, name); +if (pd) { +Object.defineProperty(target, name, pd); +} +}, +_log: console.log.apply.bind(console.log, console), +_warn: console.warn.apply.bind(console.warn, console), +_error: console.error.apply.bind(console.error, console), +_logf: function() { +return this._logPrefix.concat([ this.is ]).concat(Array.prototype.slice.call(arguments, 0)); +} +}; + +Polymer.Base._logPrefix = function() { +var color = window.chrome || /firefox/i.test(navigator.userAgent); +return color ? [ "%c[%s::%s]:", "font-weight: bold; background-color:#EEEE00;" ] : [ "[%s::%s]:" ]; +}(); + +Polymer.Base.chainObject = function(object, inherited) { +if (object && inherited && object !== inherited) { +if (!Object.__proto__) { +object = Polymer.Base.extend(Object.create(inherited), object); +} +object.__proto__ = inherited; +} +return object; +}; + +Polymer.Base = Polymer.Base.chainObject(Polymer.Base, HTMLElement.prototype); + +Polymer.telemetry.instanceCount = 0; + +(function() { +var modules = {}; +var DomModule = function() { +return document.createElement("dom-module"); +}; +DomModule.prototype = Object.create(HTMLElement.prototype); +DomModule.prototype.constructor = DomModule; +DomModule.prototype.createdCallback = function() { +var id = this.id || this.getAttribute("name") || this.getAttribute("is"); +if (id) { +this.id = id; +modules[id] = this; +} +}; +DomModule.prototype.import = function(id, slctr) { +var m = modules[id]; +if (!m) { +forceDocumentUpgrade(); +m = modules[id]; +} +if (m && slctr) { +m = m.querySelector(slctr); +} +return m; +}; +var cePolyfill = window.CustomElements && !CustomElements.useNative; +if (cePolyfill) { +var ready = CustomElements.ready; +CustomElements.ready = true; +} +document.registerElement("dom-module", DomModule); +if (cePolyfill) { +CustomElements.ready = ready; +} +function forceDocumentUpgrade() { +if (cePolyfill) { +var script = document._currentScript || document.currentScript; +if (script) { +CustomElements.upgradeAll(script.ownerDocument); +} +} +} +})(); + +Polymer.Base._addFeature({ +_prepIs: function() { +if (!this.is) { +var module = (document._currentScript || document.currentScript).parentNode; +if (module.localName === "dom-module") { +var id = module.id || module.getAttribute("name") || module.getAttribute("is"); +this.is = id; +} +} +} +}); + +Polymer.Base._addFeature({ +behaviors: [], +_prepBehaviors: function() { +if (this.behaviors.length) { +this.behaviors = this._flattenBehaviorsList(this.behaviors); +} +this._prepAllBehaviors(this.behaviors); +}, +_flattenBehaviorsList: function(behaviors) { +var flat = []; +behaviors.forEach(function(b) { +if (b instanceof Array) { +flat = flat.concat(this._flattenBehaviorsList(b)); +} else if (b) { +flat.push(b); +} else { +this._warn(this._logf("_flattenBehaviorsList", "behavior is null, check for missing or 404 import")); +} +}, this); +return flat; +}, +_prepAllBehaviors: function(behaviors) { +for (var i = behaviors.length - 1; i >= 0; i--) { +this._mixinBehavior(behaviors[i]); +} +for (var i = 0, l = behaviors.length; i < l; i++) { +this._prepBehavior(behaviors[i]); +} +this._prepBehavior(this); +}, +_mixinBehavior: function(b) { +Object.getOwnPropertyNames(b).forEach(function(n) { +switch (n) { +case "hostAttributes": +case "registered": +case "properties": +case "observers": +case "listeners": +case "created": +case "attached": +case "detached": +case "attributeChanged": +case "configure": +case "ready": +break; + +default: +if (!this.hasOwnProperty(n)) { +this.copyOwnProperty(n, b, this); +} +break; +} +}, this); +}, +_doBehavior: function(name, args) { +this.behaviors.forEach(function(b) { +this._invokeBehavior(b, name, args); +}, this); +this._invokeBehavior(this, name, args); +}, +_invokeBehavior: function(b, name, args) { +var fn = b[name]; +if (fn) { +fn.apply(this, args || Polymer.nar); +} +}, +_marshalBehaviors: function() { +this.behaviors.forEach(function(b) { +this._marshalBehavior(b); +}, this); +this._marshalBehavior(this); +} +}); + +Polymer.Base._addFeature({ +_prepExtends: function() { +if (this.extends) { +this.__proto__ = this._getExtendedPrototype(this.extends); +} +}, +_getExtendedPrototype: function(tag) { +return this._getExtendedNativePrototype(tag); +}, +_nativePrototypes: {}, +_getExtendedNativePrototype: function(tag) { +var p = this._nativePrototypes[tag]; +if (!p) { +var np = this.getNativePrototype(tag); +p = this.extend(Object.create(np), Polymer.Base); +this._nativePrototypes[tag] = p; +} +return p; +}, +getNativePrototype: function(tag) { +return Object.getPrototypeOf(document.createElement(tag)); +} +}); + +Polymer.Base._addFeature({ +_prepConstructor: function() { +this._factoryArgs = this.extends ? [ this.extends, this.is ] : [ this.is ]; +var ctor = function() { +return this._factory(arguments); +}; +if (this.hasOwnProperty("extends")) { +ctor.extends = this.extends; +} +Object.defineProperty(this, "constructor", { +value: ctor, +writable: true, +configurable: true +}); +ctor.prototype = this; +}, +_factory: function(args) { +var elt = document.createElement.apply(document, this._factoryArgs); +if (this.factoryImpl) { +this.factoryImpl.apply(elt, args); +} +return elt; +} +}); + +Polymer.nob = Object.create(null); + +Polymer.Base._addFeature({ +properties: {}, +getPropertyInfo: function(property) { +var info = this._getPropertyInfo(property, this.properties); +if (!info) { +this.behaviors.some(function(b) { +return info = this._getPropertyInfo(property, b.properties); +}, this); +} +return info || Polymer.nob; +}, +_getPropertyInfo: function(property, properties) { +var p = properties && properties[property]; +if (typeof p === "function") { +p = properties[property] = { +type: p +}; +} +if (p) { +p.defined = true; +} +return p; +} +}); + +Polymer.CaseMap = { +_caseMap: {}, +dashToCamelCase: function(dash) { +var mapped = Polymer.CaseMap._caseMap[dash]; +if (mapped) { +return mapped; +} +if (dash.indexOf("-") < 0) { +return Polymer.CaseMap._caseMap[dash] = dash; +} +return Polymer.CaseMap._caseMap[dash] = dash.replace(/-([a-z])/g, function(m) { +return m[1].toUpperCase(); +}); +}, +camelToDashCase: function(camel) { +var mapped = Polymer.CaseMap._caseMap[camel]; +if (mapped) { +return mapped; +} +return Polymer.CaseMap._caseMap[camel] = camel.replace(/([a-z][A-Z])/g, function(g) { +return g[0] + "-" + g[1].toLowerCase(); +}); +} +}; + +Polymer.Base._addFeature({ +_prepAttributes: function() { +this._aggregatedAttributes = {}; +}, +_addHostAttributes: function(attributes) { +if (attributes) { +this.mixin(this._aggregatedAttributes, attributes); +} +}, +_marshalHostAttributes: function() { +this._applyAttributes(this, this._aggregatedAttributes); +}, +_applyAttributes: function(node, attr$) { +for (var n in attr$) { +if (!this.hasAttribute(n) && n !== "class") { +this.serializeValueToAttribute(attr$[n], n, this); +} +} +}, +_marshalAttributes: function() { +this._takeAttributesToModel(this); +}, +_takeAttributesToModel: function(model) { +for (var i = 0, l = this.attributes.length; i < l; i++) { +this._setAttributeToProperty(model, this.attributes[i].name); +} +}, +_setAttributeToProperty: function(model, attrName) { +if (!this._serializing) { +var propName = Polymer.CaseMap.dashToCamelCase(attrName); +var info = this.getPropertyInfo(propName); +if (info.defined || this._propertyEffects && this._propertyEffects[propName]) { +var val = this.getAttribute(attrName); +model[propName] = this.deserialize(val, info.type); +} +} +}, +_serializing: false, +reflectPropertyToAttribute: function(name) { +this._serializing = true; +this.serializeValueToAttribute(this[name], Polymer.CaseMap.camelToDashCase(name)); +this._serializing = false; +}, +serializeValueToAttribute: function(value, attribute, node) { +var str = this.serialize(value); +(node || this)[str === undefined ? "removeAttribute" : "setAttribute"](attribute, str); +}, +deserialize: function(value, type) { +switch (type) { +case Number: +value = Number(value); +break; + +case Boolean: +value = value !== null; +break; + +case Object: +try { +value = JSON.parse(value); +} catch (x) {} +break; + +case Array: +try { +value = JSON.parse(value); +} catch (x) { +value = null; +console.warn("Polymer::Attributes: couldn`t decode Array as JSON"); +} +break; + +case Date: +value = new Date(value); +break; + +case String: +default: +break; +} +return value; +}, +serialize: function(value) { +switch (typeof value) { +case "boolean": +return value ? "" : undefined; + +case "object": +if (value instanceof Date) { +return value; +} else if (value) { +try { +return JSON.stringify(value); +} catch (x) { +return ""; +} +} + +default: +return value != null ? value : undefined; +} +} +}); + +Polymer.Base._addFeature({ +_setupDebouncers: function() { +this._debouncers = {}; +}, +debounce: function(jobName, callback, wait) { +this._debouncers[jobName] = Polymer.Debounce.call(this, this._debouncers[jobName], callback, wait); +}, +isDebouncerActive: function(jobName) { +var debouncer = this._debouncers[jobName]; +return debouncer && debouncer.finish; +}, +flushDebouncer: function(jobName) { +var debouncer = this._debouncers[jobName]; +if (debouncer) { +debouncer.complete(); +} +}, +cancelDebouncer: function(jobName) { +var debouncer = this._debouncers[jobName]; +if (debouncer) { +debouncer.stop(); +} +} +}); + +Polymer.version = "1.0.2"; + +Polymer.Base._addFeature({ +_registerFeatures: function() { +this._prepIs(); +this._prepAttributes(); +this._prepBehaviors(); +this._prepExtends(); +this._prepConstructor(); +}, +_prepBehavior: function(b) { +this._addHostAttributes(b.hostAttributes); +}, +_marshalBehavior: function(b) {}, +_initFeatures: function() { +this._marshalHostAttributes(); +this._setupDebouncers(); +this._marshalBehaviors(); +} +});</script> + diff --git a/third_party/polymer/v1_0/components/polymer/polymer-mini.html b/third_party/polymer/v1_0/components/polymer/polymer-mini.html new file mode 100644 index 0000000..853b3cf --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/polymer-mini.html @@ -0,0 +1,1323 @@ +<!-- +@license +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><link rel="import" href="polymer-micro.html"> + +<script>Polymer.Base._addFeature({ +_prepTemplate: function() { +this._template = this._template || Polymer.DomModule.import(this.is, "template"); +if (!this._template) { +var script = document._currentScript || document.currentScript; +var prev = script && script.previousElementSibling; +if (prev && prev.localName === "template") { +this._template = prev; +} +} +if (this._template && this._template.hasAttribute("is")) { +this._warn(this._logf("_prepTemplate", "top-level Polymer template " + "must not be a type-extension, found", this._template, "Move inside simple <template>.")); +} +}, +_stampTemplate: function() { +if (this._template) { +this.root = this.instanceTemplate(this._template); +} +}, +instanceTemplate: function(template) { +var dom = document.importNode(template._content || template.content, true); +return dom; +} +}); + +(function() { +var baseAttachedCallback = Polymer.Base.attachedCallback; +Polymer.Base._addFeature({ +_hostStack: [], +ready: function() {}, +_pushHost: function(host) { +this.dataHost = host = host || Polymer.Base._hostStack[Polymer.Base._hostStack.length - 1]; +if (host && host._clients) { +host._clients.push(this); +} +this._beginHost(); +}, +_beginHost: function() { +Polymer.Base._hostStack.push(this); +if (!this._clients) { +this._clients = []; +} +}, +_popHost: function() { +Polymer.Base._hostStack.pop(); +}, +_tryReady: function() { +if (this._canReady()) { +this._ready(); +} +}, +_canReady: function() { +return !this.dataHost || this.dataHost._clientsReadied; +}, +_ready: function() { +this._beforeClientsReady(); +this._setupRoot(); +this._readyClients(); +this._afterClientsReady(); +this._readySelf(); +}, +_readyClients: function() { +this._beginDistribute(); +var c$ = this._clients; +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +c._ready(); +} +this._finishDistribute(); +this._clientsReadied = true; +this._clients = null; +}, +_readySelf: function() { +this._doBehavior("ready"); +this._readied = true; +if (this._attachedPending) { +this._attachedPending = false; +this.attachedCallback(); +} +}, +_beforeClientsReady: function() {}, +_afterClientsReady: function() {}, +_beforeAttached: function() {}, +attachedCallback: function() { +if (this._readied) { +this._beforeAttached(); +baseAttachedCallback.call(this); +} else { +this._attachedPending = true; +} +} +}); +})(); + +Polymer.ArraySplice = function() { +function newSplice(index, removed, addedCount) { +return { +index: index, +removed: removed, +addedCount: addedCount +}; +} +var EDIT_LEAVE = 0; +var EDIT_UPDATE = 1; +var EDIT_ADD = 2; +var EDIT_DELETE = 3; +function ArraySplice() {} +ArraySplice.prototype = { +calcEditDistances: function(current, currentStart, currentEnd, old, oldStart, oldEnd) { +var rowCount = oldEnd - oldStart + 1; +var columnCount = currentEnd - currentStart + 1; +var distances = new Array(rowCount); +for (var i = 0; i < rowCount; i++) { +distances[i] = new Array(columnCount); +distances[i][0] = i; +} +for (var j = 0; j < columnCount; j++) distances[0][j] = j; +for (var i = 1; i < rowCount; i++) { +for (var j = 1; j < columnCount; j++) { +if (this.equals(current[currentStart + j - 1], old[oldStart + i - 1])) distances[i][j] = distances[i - 1][j - 1]; else { +var north = distances[i - 1][j] + 1; +var west = distances[i][j - 1] + 1; +distances[i][j] = north < west ? north : west; +} +} +} +return distances; +}, +spliceOperationsFromEditDistances: function(distances) { +var i = distances.length - 1; +var j = distances[0].length - 1; +var current = distances[i][j]; +var edits = []; +while (i > 0 || j > 0) { +if (i == 0) { +edits.push(EDIT_ADD); +j--; +continue; +} +if (j == 0) { +edits.push(EDIT_DELETE); +i--; +continue; +} +var northWest = distances[i - 1][j - 1]; +var west = distances[i - 1][j]; +var north = distances[i][j - 1]; +var min; +if (west < north) min = west < northWest ? west : northWest; else min = north < northWest ? north : northWest; +if (min == northWest) { +if (northWest == current) { +edits.push(EDIT_LEAVE); +} else { +edits.push(EDIT_UPDATE); +current = northWest; +} +i--; +j--; +} else if (min == west) { +edits.push(EDIT_DELETE); +i--; +current = west; +} else { +edits.push(EDIT_ADD); +j--; +current = north; +} +} +edits.reverse(); +return edits; +}, +calcSplices: function(current, currentStart, currentEnd, old, oldStart, oldEnd) { +var prefixCount = 0; +var suffixCount = 0; +var minLength = Math.min(currentEnd - currentStart, oldEnd - oldStart); +if (currentStart == 0 && oldStart == 0) prefixCount = this.sharedPrefix(current, old, minLength); +if (currentEnd == current.length && oldEnd == old.length) suffixCount = this.sharedSuffix(current, old, minLength - prefixCount); +currentStart += prefixCount; +oldStart += prefixCount; +currentEnd -= suffixCount; +oldEnd -= suffixCount; +if (currentEnd - currentStart == 0 && oldEnd - oldStart == 0) return []; +if (currentStart == currentEnd) { +var splice = newSplice(currentStart, [], 0); +while (oldStart < oldEnd) splice.removed.push(old[oldStart++]); +return [ splice ]; +} else if (oldStart == oldEnd) return [ newSplice(currentStart, [], currentEnd - currentStart) ]; +var ops = this.spliceOperationsFromEditDistances(this.calcEditDistances(current, currentStart, currentEnd, old, oldStart, oldEnd)); +var splice = undefined; +var splices = []; +var index = currentStart; +var oldIndex = oldStart; +for (var i = 0; i < ops.length; i++) { +switch (ops[i]) { +case EDIT_LEAVE: +if (splice) { +splices.push(splice); +splice = undefined; +} +index++; +oldIndex++; +break; + +case EDIT_UPDATE: +if (!splice) splice = newSplice(index, [], 0); +splice.addedCount++; +index++; +splice.removed.push(old[oldIndex]); +oldIndex++; +break; + +case EDIT_ADD: +if (!splice) splice = newSplice(index, [], 0); +splice.addedCount++; +index++; +break; + +case EDIT_DELETE: +if (!splice) splice = newSplice(index, [], 0); +splice.removed.push(old[oldIndex]); +oldIndex++; +break; +} +} +if (splice) { +splices.push(splice); +} +return splices; +}, +sharedPrefix: function(current, old, searchLength) { +for (var i = 0; i < searchLength; i++) if (!this.equals(current[i], old[i])) return i; +return searchLength; +}, +sharedSuffix: function(current, old, searchLength) { +var index1 = current.length; +var index2 = old.length; +var count = 0; +while (count < searchLength && this.equals(current[--index1], old[--index2])) count++; +return count; +}, +calculateSplices: function(current, previous) { +return this.calcSplices(current, 0, current.length, previous, 0, previous.length); +}, +equals: function(currentValue, previousValue) { +return currentValue === previousValue; +} +}; +return new ArraySplice(); +}(); + +Polymer.EventApi = function() { +var Settings = Polymer.Settings; +var EventApi = function(event) { +this.event = event; +}; +if (Settings.useShadow) { +EventApi.prototype = { +get rootTarget() { +return this.event.path[0]; +}, +get localTarget() { +return this.event.target; +}, +get path() { +return this.event.path; +} +}; +} else { +EventApi.prototype = { +get rootTarget() { +return this.event.target; +}, +get localTarget() { +var current = this.event.currentTarget; +var currentRoot = current && Polymer.dom(current).getOwnerRoot(); +var p$ = this.path; +for (var i = 0; i < p$.length; i++) { +if (Polymer.dom(p$[i]).getOwnerRoot() === currentRoot) { +return p$[i]; +} +} +}, +get path() { +if (!this.event._path) { +var path = []; +var o = this.rootTarget; +while (o) { +path.push(o); +o = Polymer.dom(o).parentNode || o.host; +} +path.push(window); +this.event._path = path; +} +return this.event._path; +} +}; +} +var factory = function(event) { +if (!event.__eventApi) { +event.__eventApi = new EventApi(event); +} +return event.__eventApi; +}; +return { +factory: factory +}; +}(); + +Polymer.domInnerHTML = function() { +var escapeAttrRegExp = /[&\u00A0"]/g; +var escapeDataRegExp = /[&\u00A0<>]/g; +function escapeReplace(c) { +switch (c) { +case "&": +return "&"; + +case "<": +return "<"; + +case ">": +return ">"; + +case '"': +return """; + +case "\u00A0": +return " "; +} +} +function escapeAttr(s) { +return s.replace(escapeAttrRegExp, escapeReplace); +} +function escapeData(s) { +return s.replace(escapeDataRegExp, escapeReplace); +} +function makeSet(arr) { +var set = {}; +for (var i = 0; i < arr.length; i++) { +set[arr[i]] = true; +} +return set; +} +var voidElements = makeSet([ "area", "base", "br", "col", "command", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr" ]); +var plaintextParents = makeSet([ "style", "script", "xmp", "iframe", "noembed", "noframes", "plaintext", "noscript" ]); +function getOuterHTML(node, parentNode, composed) { +switch (node.nodeType) { +case Node.ELEMENT_NODE: +var tagName = node.localName; +var s = "<" + tagName; +var attrs = node.attributes; +for (var i = 0, attr; attr = attrs[i]; i++) { +s += " " + attr.name + '="' + escapeAttr(attr.value) + '"'; +} +s += ">"; +if (voidElements[tagName]) { +return s; +} +return s + getInnerHTML(node, composed) + "</" + tagName + ">"; + +case Node.TEXT_NODE: +var data = node.data; +if (parentNode && plaintextParents[parentNode.localName]) { +return data; +} +return escapeData(data); + +case Node.COMMENT_NODE: +return "<!--" + node.data + "-->"; + +default: +console.error(node); +throw new Error("not implemented"); +} +} +function getInnerHTML(node, composed) { +if (node instanceof HTMLTemplateElement) node = node.content; +var s = ""; +var c$ = Polymer.dom(node).childNodes; +c$ = composed ? node._composedChildren : c$; +for (var i = 0, l = c$.length, child; i < l && (child = c$[i]); i++) { +s += getOuterHTML(child, node, composed); +} +return s; +} +return { +getInnerHTML: getInnerHTML +}; +}(); + +Polymer.DomApi = function() { +"use strict"; +var Settings = Polymer.Settings; +var getInnerHTML = Polymer.domInnerHTML.getInnerHTML; +var nativeInsertBefore = Element.prototype.insertBefore; +var nativeRemoveChild = Element.prototype.removeChild; +var nativeAppendChild = Element.prototype.appendChild; +var dirtyRoots = []; +var DomApi = function(node) { +this.node = node; +if (this.patch) { +this.patch(); +} +}; +DomApi.prototype = { +flush: function() { +for (var i = 0, host; i < dirtyRoots.length; i++) { +host = dirtyRoots[i]; +host.flushDebouncer("_distribute"); +} +dirtyRoots = []; +}, +_lazyDistribute: function(host) { +if (host.shadyRoot && host.shadyRoot._distributionClean) { +host.shadyRoot._distributionClean = false; +host.debounce("_distribute", host._distributeContent); +dirtyRoots.push(host); +} +}, +appendChild: function(node) { +var distributed; +this._removeNodeFromHost(node); +if (this._nodeIsInLogicalTree(this.node)) { +var host = this._hostForNode(this.node); +this._addLogicalInfo(node, this.node, host && host.shadyRoot); +this._addNodeToHost(node); +if (host) { +distributed = this._maybeDistribute(node, this.node, host); +} +} +if (!distributed && !this._tryRemoveUndistributedNode(node)) { +var container = this.node._isShadyRoot ? this.node.host : this.node; +nativeAppendChild.call(container, node); +addToComposedParent(container, node); +} +return node; +}, +insertBefore: function(node, ref_node) { +if (!ref_node) { +return this.appendChild(node); +} +var distributed; +this._removeNodeFromHost(node); +if (this._nodeIsInLogicalTree(this.node)) { +saveLightChildrenIfNeeded(this.node); +var children = this.childNodes; +var index = children.indexOf(ref_node); +if (index < 0) { +throw Error("The ref_node to be inserted before is not a child " + "of this node"); +} +var host = this._hostForNode(this.node); +this._addLogicalInfo(node, this.node, host && host.shadyRoot, index); +this._addNodeToHost(node); +if (host) { +distributed = this._maybeDistribute(node, this.node, host); +} +} +if (!distributed && !this._tryRemoveUndistributedNode(node)) { +ref_node = ref_node.localName === CONTENT ? this._firstComposedNode(ref_node) : ref_node; +var container = this.node._isShadyRoot ? this.node.host : this.node; +nativeInsertBefore.call(container, node, ref_node); +addToComposedParent(container, node, ref_node); +} +return node; +}, +removeChild: function(node) { +if (factory(node).parentNode !== this.node) { +console.warn("The node to be removed is not a child of this node", node); +} +var distributed; +if (this._nodeIsInLogicalTree(this.node)) { +var host = this._hostForNode(this.node); +distributed = this._maybeDistribute(node, this.node, host); +this._removeNodeFromHost(node); +} +if (!distributed) { +var container = this.node._isShadyRoot ? this.node.host : this.node; +if (container === node.parentNode) { +nativeRemoveChild.call(container, node); +removeFromComposedParent(container, node); +} +} +return node; +}, +replaceChild: function(node, ref_node) { +this.insertBefore(node, ref_node); +this.removeChild(ref_node); +return node; +}, +getOwnerRoot: function() { +return this._ownerShadyRootForNode(this.node); +}, +_ownerShadyRootForNode: function(node) { +if (!node) { +return; +} +if (node._ownerShadyRoot === undefined) { +var root; +if (node._isShadyRoot) { +root = node; +} else { +var parent = Polymer.dom(node).parentNode; +if (parent) { +root = parent._isShadyRoot ? parent : this._ownerShadyRootForNode(parent); +} else { +root = null; +} +} +node._ownerShadyRoot = root; +} +return node._ownerShadyRoot; +}, +_maybeDistribute: function(node, parent, host) { +var nodeNeedsDistribute = this._nodeNeedsDistribution(node); +var distribute = this._parentNeedsDistribution(parent) || nodeNeedsDistribute; +if (nodeNeedsDistribute) { +this._updateInsertionPoints(host); +} +if (distribute) { +this._lazyDistribute(host); +} +return distribute; +}, +_tryRemoveUndistributedNode: function(node) { +if (this.node.shadyRoot) { +if (node.parentNode) { +nativeRemoveChild.call(node.parentNode, node); +} +return true; +} +}, +_updateInsertionPoints: function(host) { +host.shadyRoot._insertionPoints = factory(host.shadyRoot).querySelectorAll(CONTENT); +}, +_nodeIsInLogicalTree: function(node) { +return Boolean(node._lightParent || node._isShadyRoot || this._ownerShadyRootForNode(node) || node.shadyRoot); +}, +_hostForNode: function(node) { +var root = node.shadyRoot || (node._isShadyRoot ? node : this._ownerShadyRootForNode(node)); +return root && root.host; +}, +_parentNeedsDistribution: function(parent) { +return parent && parent.shadyRoot && hasInsertionPoint(parent.shadyRoot); +}, +_nodeNeedsDistribution: function(node) { +return node.localName === CONTENT || node.nodeType === Node.DOCUMENT_FRAGMENT_NODE && node.querySelector(CONTENT); +}, +_removeNodeFromHost: function(node) { +if (node._lightParent) { +var root = this._ownerShadyRootForNode(node); +if (root) { +root.host._elementRemove(node); +} +this._removeLogicalInfo(node, node._lightParent); +} +this._removeOwnerShadyRoot(node); +}, +_addNodeToHost: function(node) { +var checkNode = node.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? node.firstChild : node; +var root = this._ownerShadyRootForNode(checkNode); +if (root) { +root.host._elementAdd(node); +} +}, +_addLogicalInfo: function(node, container, root, index) { +saveLightChildrenIfNeeded(container); +var children = factory(container).childNodes; +index = index === undefined ? children.length : index; +if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) { +var c$ = Array.prototype.slice.call(node.childNodes); +for (var i = 0, n; i < c$.length && (n = c$[i]); i++) { +children.splice(index++, 0, n); +n._lightParent = container; +} +} else { +children.splice(index, 0, node); +node._lightParent = container; +} +}, +_removeLogicalInfo: function(node, container) { +var children = factory(container).childNodes; +var index = children.indexOf(node); +if (index < 0 || container !== node._lightParent) { +throw Error("The node to be removed is not a child of this node"); +} +children.splice(index, 1); +node._lightParent = null; +}, +_removeOwnerShadyRoot: function(node) { +var hasCachedRoot = factory(node).getOwnerRoot() !== undefined; +if (hasCachedRoot) { +var c$ = factory(node).childNodes; +for (var i = 0, l = c$.length, n; i < l && (n = c$[i]); i++) { +this._removeOwnerShadyRoot(n); +} +} +node._ownerShadyRoot = undefined; +}, +_firstComposedNode: function(content) { +var n$ = factory(content).getDistributedNodes(); +for (var i = 0, l = n$.length, n, p$; i < l && (n = n$[i]); i++) { +p$ = factory(n).getDestinationInsertionPoints(); +if (p$[p$.length - 1] === content) { +return n; +} +} +}, +querySelector: function(selector) { +return this.querySelectorAll(selector)[0]; +}, +querySelectorAll: function(selector) { +return this._query(function(n) { +return matchesSelector.call(n, selector); +}, this.node); +}, +_query: function(matcher, node) { +node = node || this.node; +var list = []; +this._queryElements(factory(node).childNodes, matcher, list); +return list; +}, +_queryElements: function(elements, matcher, list) { +for (var i = 0, l = elements.length, c; i < l && (c = elements[i]); i++) { +if (c.nodeType === Node.ELEMENT_NODE) { +this._queryElement(c, matcher, list); +} +} +}, +_queryElement: function(node, matcher, list) { +if (matcher(node)) { +list.push(node); +} +this._queryElements(factory(node).childNodes, matcher, list); +}, +getDestinationInsertionPoints: function() { +return this.node._destinationInsertionPoints || []; +}, +getDistributedNodes: function() { +return this.node._distributedNodes || []; +}, +queryDistributedElements: function(selector) { +var c$ = this.childNodes; +var list = []; +this._distributedFilter(selector, c$, list); +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +if (c.localName === CONTENT) { +this._distributedFilter(selector, factory(c).getDistributedNodes(), list); +} +} +return list; +}, +_distributedFilter: function(selector, list, results) { +results = results || []; +for (var i = 0, l = list.length, d; i < l && (d = list[i]); i++) { +if (d.nodeType === Node.ELEMENT_NODE && d.localName !== CONTENT && matchesSelector.call(d, selector)) { +results.push(d); +} +} +return results; +}, +_clear: function() { +while (this.childNodes.length) { +this.removeChild(this.childNodes[0]); +} +}, +setAttribute: function(name, value) { +this.node.setAttribute(name, value); +this._distributeParent(); +}, +removeAttribute: function(name) { +this.node.removeAttribute(name); +this._distributeParent(); +}, +_distributeParent: function() { +if (this._parentNeedsDistribution(this.parentNode)) { +this._lazyDistribute(this.parentNode); +} +} +}; +Object.defineProperty(DomApi.prototype, "classList", { +get: function() { +if (!this._classList) { +this._classList = new DomApi.ClassList(this); +} +return this._classList; +}, +configurable: true +}); +DomApi.ClassList = function(host) { +this.domApi = host; +this.node = host.node; +}; +DomApi.ClassList.prototype = { +add: function() { +this.node.classList.add.apply(this.node.classList, arguments); +this.domApi._distributeParent(); +}, +remove: function() { +this.node.classList.remove.apply(this.node.classList, arguments); +this.domApi._distributeParent(); +}, +toggle: function() { +this.node.classList.toggle.apply(this.node.classList, arguments); +this.domApi._distributeParent(); +} +}; +if (!Settings.useShadow) { +Object.defineProperties(DomApi.prototype, { +childNodes: { +get: function() { +var c$ = getLightChildren(this.node); +return Array.isArray(c$) ? c$ : Array.prototype.slice.call(c$); +}, +configurable: true +}, +children: { +get: function() { +return Array.prototype.filter.call(this.childNodes, function(n) { +return n.nodeType === Node.ELEMENT_NODE; +}); +}, +configurable: true +}, +parentNode: { +get: function() { +return this.node._lightParent || (this.node.__patched ? this.node._composedParent : this.node.parentNode); +}, +configurable: true +}, +firstChild: { +get: function() { +return this.childNodes[0]; +}, +configurable: true +}, +lastChild: { +get: function() { +var c$ = this.childNodes; +return c$[c$.length - 1]; +}, +configurable: true +}, +nextSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).childNodes; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) + 1]; +} +}, +configurable: true +}, +previousSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).childNodes; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) - 1]; +} +}, +configurable: true +}, +firstElementChild: { +get: function() { +return this.children[0]; +}, +configurable: true +}, +lastElementChild: { +get: function() { +var c$ = this.children; +return c$[c$.length - 1]; +}, +configurable: true +}, +nextElementSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).children; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) + 1]; +} +}, +configurable: true +}, +previousElementSibling: { +get: function() { +var c$ = this.parentNode && factory(this.parentNode).children; +if (c$) { +return c$[Array.prototype.indexOf.call(c$, this.node) - 1]; +} +}, +configurable: true +}, +textContent: { +get: function() { +if (this.node.nodeType === Node.TEXT_NODE) { +return this.node.textContent; +} else { +return Array.prototype.map.call(this.childNodes, function(c) { +return c.textContent; +}).join(""); +} +}, +set: function(text) { +this._clear(); +if (text) { +this.appendChild(document.createTextNode(text)); +} +}, +configurable: true +}, +innerHTML: { +get: function() { +if (this.node.nodeType === Node.TEXT_NODE) { +return null; +} else { +return getInnerHTML(this.node); +} +}, +set: function(text) { +if (this.node.nodeType !== Node.TEXT_NODE) { +this._clear(); +var d = document.createElement("div"); +d.innerHTML = text; +for (var e = d.firstChild; e; e = e.nextSibling) { +this.appendChild(e); +} +} +}, +configurable: true +} +}); +DomApi.prototype._getComposedInnerHTML = function() { +return getInnerHTML(this.node, true); +}; +} else { +DomApi.prototype.querySelectorAll = function(selector) { +return Array.prototype.slice.call(this.node.querySelectorAll(selector)); +}; +DomApi.prototype.getOwnerRoot = function() { +var n = this.node; +while (n) { +if (n.nodeType === Node.DOCUMENT_FRAGMENT_NODE && n.host) { +return n; +} +n = n.parentNode; +} +}; +DomApi.prototype.getDestinationInsertionPoints = function() { +var n$ = this.node.getDestinationInsertionPoints(); +return n$ ? Array.prototype.slice.call(n$) : []; +}; +DomApi.prototype.getDistributedNodes = function() { +var n$ = this.node.getDistributedNodes(); +return n$ ? Array.prototype.slice.call(n$) : []; +}; +DomApi.prototype._distributeParent = function() {}; +Object.defineProperties(DomApi.prototype, { +childNodes: { +get: function() { +return Array.prototype.slice.call(this.node.childNodes); +}, +configurable: true +}, +children: { +get: function() { +return Array.prototype.slice.call(this.node.children); +}, +configurable: true +}, +textContent: { +get: function() { +return this.node.textContent; +}, +set: function(value) { +return this.node.textContent = value; +}, +configurable: true +}, +innerHTML: { +get: function() { +return this.node.innerHTML; +}, +set: function(value) { +return this.node.innerHTML = value; +}, +configurable: true +} +}); +var forwards = [ "parentNode", "firstChild", "lastChild", "nextSibling", "previousSibling", "firstElementChild", "lastElementChild", "nextElementSibling", "previousElementSibling" ]; +forwards.forEach(function(name) { +Object.defineProperty(DomApi.prototype, name, { +get: function() { +return this.node[name]; +}, +configurable: true +}); +}); +} +var CONTENT = "content"; +var factory = function(node, patch) { +node = node || document; +if (!node.__domApi) { +node.__domApi = new DomApi(node, patch); +} +return node.__domApi; +}; +Polymer.dom = function(obj, patch) { +if (obj instanceof Event) { +return Polymer.EventApi.factory(obj); +} else { +return factory(obj, patch); +} +}; +Polymer.dom.flush = DomApi.prototype.flush; +function getLightChildren(node) { +var children = node._lightChildren; +return children ? children : node.childNodes; +} +function getComposedChildren(node) { +if (!node._composedChildren) { +node._composedChildren = Array.prototype.slice.call(node.childNodes); +} +return node._composedChildren; +} +function addToComposedParent(parent, node, ref_node) { +var children = getComposedChildren(parent); +var i = ref_node ? children.indexOf(ref_node) : -1; +if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) { +var fragChildren = getComposedChildren(node); +fragChildren.forEach(function(c) { +addNodeToComposedChildren(c, parent, children, i); +}); +} else { +addNodeToComposedChildren(node, parent, children, i); +} +} +function addNodeToComposedChildren(node, parent, children, i) { +node._composedParent = parent; +if (i >= 0) { +children.splice(i, 0, node); +} else { +children.push(node); +} +} +function removeFromComposedParent(parent, node) { +node._composedParent = null; +if (parent) { +var children = getComposedChildren(parent); +var i = children.indexOf(node); +if (i >= 0) { +children.splice(i, 1); +} +} +} +function saveLightChildrenIfNeeded(node) { +if (!node._lightChildren) { +var c$ = Array.prototype.slice.call(node.childNodes); +for (var i = 0, l = c$.length, child; i < l && (child = c$[i]); i++) { +child._lightParent = child._lightParent || node; +} +node._lightChildren = c$; +} +} +function hasInsertionPoint(root) { +return Boolean(root._insertionPoints.length); +} +var p = Element.prototype; +var matchesSelector = p.matches || p.matchesSelector || p.mozMatchesSelector || p.msMatchesSelector || p.oMatchesSelector || p.webkitMatchesSelector; +return { +getLightChildren: getLightChildren, +getComposedChildren: getComposedChildren, +removeFromComposedParent: removeFromComposedParent, +saveLightChildrenIfNeeded: saveLightChildrenIfNeeded, +matchesSelector: matchesSelector, +hasInsertionPoint: hasInsertionPoint, +ctor: DomApi, +factory: factory +}; +}(); + +(function() { +Polymer.Base._addFeature({ +_prepShady: function() { +this._useContent = this._useContent || Boolean(this._template); +if (this._useContent) { +this._template._hasInsertionPoint = this._template.content.querySelector("content"); +} +}, +_poolContent: function() { +if (this._useContent) { +saveLightChildrenIfNeeded(this); +} +}, +_setupRoot: function() { +if (this._useContent) { +this._createLocalRoot(); +if (!this.dataHost) { +upgradeLightChildren(this._lightChildren); +} +} +}, +_createLocalRoot: function() { +this.shadyRoot = this.root; +this.shadyRoot._distributionClean = false; +this.shadyRoot._isShadyRoot = true; +this.shadyRoot._dirtyRoots = []; +this.shadyRoot._insertionPoints = this._template._hasInsertionPoint ? this.shadyRoot.querySelectorAll("content") : []; +saveLightChildrenIfNeeded(this.shadyRoot); +this.shadyRoot.host = this; +}, +get domHost() { +var root = Polymer.dom(this).getOwnerRoot(); +return root && root.host; +}, +distributeContent: function() { +if (this.shadyRoot) { +var host = getTopDistributingHost(this); +Polymer.dom(this)._lazyDistribute(host); +} +}, +_distributeContent: function() { +if (this._useContent && !this.shadyRoot._distributionClean) { +this._beginDistribute(); +this._distributeDirtyRoots(); +this._finishDistribute(); +} +}, +_beginDistribute: function() { +if (this._useContent && hasInsertionPoint(this.shadyRoot)) { +this._resetDistribution(); +this._distributePool(this.shadyRoot, this._collectPool()); +} +}, +_distributeDirtyRoots: function() { +var c$ = this.shadyRoot._dirtyRoots; +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +c._distributeContent(); +} +this.shadyRoot._dirtyRoots = []; +}, +_finishDistribute: function() { +if (this._useContent) { +if (hasInsertionPoint(this.shadyRoot)) { +this._composeTree(); +} else { +if (!this.shadyRoot._hasDistributed) { +this.textContent = ""; +this.appendChild(this.shadyRoot); +} else { +var children = this._composeNode(this); +this._updateChildNodes(this, children); +} +} +this.shadyRoot._hasDistributed = true; +this.shadyRoot._distributionClean = true; +} +}, +elementMatches: function(selector, node) { +node = node || this; +return matchesSelector.call(node, selector); +}, +_resetDistribution: function() { +var children = getLightChildren(this); +for (var i = 0; i < children.length; i++) { +var child = children[i]; +if (child._destinationInsertionPoints) { +child._destinationInsertionPoints = undefined; +} +if (isInsertionPoint(child)) { +clearDistributedDestinationInsertionPoints(child); +} +} +var root = this.shadyRoot; +var p$ = root._insertionPoints; +for (var j = 0; j < p$.length; j++) { +p$[j]._distributedNodes = []; +} +}, +_collectPool: function() { +var pool = []; +var children = getLightChildren(this); +for (var i = 0; i < children.length; i++) { +var child = children[i]; +if (isInsertionPoint(child)) { +pool.push.apply(pool, child._distributedNodes); +} else { +pool.push(child); +} +} +return pool; +}, +_distributePool: function(node, pool) { +var p$ = node._insertionPoints; +for (var i = 0, l = p$.length, p; i < l && (p = p$[i]); i++) { +this._distributeInsertionPoint(p, pool); +maybeRedistributeParent(p, this); +} +}, +_distributeInsertionPoint: function(content, pool) { +var anyDistributed = false; +for (var i = 0, l = pool.length, node; i < l; i++) { +node = pool[i]; +if (!node) { +continue; +} +if (this._matchesContentSelect(node, content)) { +distributeNodeInto(node, content); +pool[i] = undefined; +anyDistributed = true; +} +} +if (!anyDistributed) { +var children = getLightChildren(content); +for (var j = 0; j < children.length; j++) { +distributeNodeInto(children[j], content); +} +} +}, +_composeTree: function() { +this._updateChildNodes(this, this._composeNode(this)); +var p$ = this.shadyRoot._insertionPoints; +for (var i = 0, l = p$.length, p, parent; i < l && (p = p$[i]); i++) { +parent = p._lightParent || p.parentNode; +if (!parent._useContent && parent !== this && parent !== this.shadyRoot) { +this._updateChildNodes(parent, this._composeNode(parent)); +} +} +}, +_composeNode: function(node) { +var children = []; +var c$ = getLightChildren(node.shadyRoot || node); +for (var i = 0; i < c$.length; i++) { +var child = c$[i]; +if (isInsertionPoint(child)) { +var distributedNodes = child._distributedNodes; +for (var j = 0; j < distributedNodes.length; j++) { +var distributedNode = distributedNodes[j]; +if (isFinalDestination(child, distributedNode)) { +children.push(distributedNode); +} +} +} else { +children.push(child); +} +} +return children; +}, +_updateChildNodes: function(container, children) { +var composed = getComposedChildren(container); +var splices = Polymer.ArraySplice.calculateSplices(children, composed); +for (var i = 0, d = 0, s; i < splices.length && (s = splices[i]); i++) { +for (var j = 0, n; j < s.removed.length && (n = s.removed[j]); j++) { +remove(n); +composed.splice(s.index + d, 1); +} +d -= s.addedCount; +} +for (var i = 0, s, next; i < splices.length && (s = splices[i]); i++) { +next = composed[s.index]; +for (var j = s.index, n; j < s.index + s.addedCount; j++) { +n = children[j]; +insertBefore(container, n, next); +composed.splice(j, 0, n); +} +} +}, +_matchesContentSelect: function(node, contentElement) { +var select = contentElement.getAttribute("select"); +if (!select) { +return true; +} +select = select.trim(); +if (!select) { +return true; +} +if (!(node instanceof Element)) { +return false; +} +var validSelectors = /^(:not\()?[*.#[a-zA-Z_|]/; +if (!validSelectors.test(select)) { +return false; +} +return this.elementMatches(select, node); +}, +_elementAdd: function() {}, +_elementRemove: function() {} +}); +var saveLightChildrenIfNeeded = Polymer.DomApi.saveLightChildrenIfNeeded; +var getLightChildren = Polymer.DomApi.getLightChildren; +var matchesSelector = Polymer.DomApi.matchesSelector; +var hasInsertionPoint = Polymer.DomApi.hasInsertionPoint; +var getComposedChildren = Polymer.DomApi.getComposedChildren; +var removeFromComposedParent = Polymer.DomApi.removeFromComposedParent; +function distributeNodeInto(child, insertionPoint) { +insertionPoint._distributedNodes.push(child); +var points = child._destinationInsertionPoints; +if (!points) { +child._destinationInsertionPoints = [ insertionPoint ]; +} else { +points.push(insertionPoint); +} +} +function clearDistributedDestinationInsertionPoints(content) { +var e$ = content._distributedNodes; +for (var i = 0; i < e$.length; i++) { +var d = e$[i]._destinationInsertionPoints; +if (d) { +d.splice(d.indexOf(content) + 1, d.length); +} +} +} +function maybeRedistributeParent(content, host) { +var parent = content._lightParent; +if (parent && parent.shadyRoot && hasInsertionPoint(parent.shadyRoot) && parent.shadyRoot._distributionClean) { +parent.shadyRoot._distributionClean = false; +host.shadyRoot._dirtyRoots.push(parent); +} +} +function isFinalDestination(insertionPoint, node) { +var points = node._destinationInsertionPoints; +return points && points[points.length - 1] === insertionPoint; +} +function isInsertionPoint(node) { +return node.localName == "content"; +} +var nativeInsertBefore = Element.prototype.insertBefore; +var nativeRemoveChild = Element.prototype.removeChild; +function insertBefore(parentNode, newChild, refChild) { +var newChildParent = getComposedParent(newChild); +if (newChildParent !== parentNode) { +removeFromComposedParent(newChildParent, newChild); +} +remove(newChild); +saveLightChildrenIfNeeded(parentNode); +nativeInsertBefore.call(parentNode, newChild, refChild || null); +newChild._composedParent = parentNode; +} +function remove(node) { +var parentNode = getComposedParent(node); +if (parentNode) { +saveLightChildrenIfNeeded(parentNode); +node._composedParent = null; +nativeRemoveChild.call(parentNode, node); +} +} +function getComposedParent(node) { +return node.__patched ? node._composedParent : node.parentNode; +} +function getTopDistributingHost(host) { +while (host && hostNeedsRedistribution(host)) { +host = host.domHost; +} +return host; +} +function hostNeedsRedistribution(host) { +var c$ = Polymer.dom(host).children; +for (var i = 0, c; i < c$.length; i++) { +c = c$[i]; +if (c.localName === "content") { +return host.domHost; +} +} +} +var needsUpgrade = window.CustomElements && !CustomElements.useNative; +function upgradeLightChildren(children) { +if (needsUpgrade && children) { +for (var i = 0; i < children.length; i++) { +CustomElements.upgrade(children[i]); +} +} +} +})(); + +if (Polymer.Settings.useShadow) { +Polymer.Base._addFeature({ +_poolContent: function() {}, +_beginDistribute: function() {}, +distributeContent: function() {}, +_distributeContent: function() {}, +_finishDistribute: function() {}, +_createLocalRoot: function() { +this.createShadowRoot(); +this.shadowRoot.appendChild(this.root); +this.root = this.shadowRoot; +} +}); +} + +Polymer.DomModule = document.createElement("dom-module"); + +Polymer.Base._addFeature({ +_registerFeatures: function() { +this._prepIs(); +this._prepAttributes(); +this._prepBehaviors(); +this._prepExtends(); +this._prepConstructor(); +this._prepTemplate(); +this._prepShady(); +}, +_prepBehavior: function(b) { +this._addHostAttributes(b.hostAttributes); +}, +_initFeatures: function() { +this._poolContent(); +this._pushHost(); +this._stampTemplate(); +this._popHost(); +this._marshalHostAttributes(); +this._setupDebouncers(); +this._marshalBehaviors(); +this._tryReady(); +}, +_marshalBehavior: function(b) {} +});</script> + diff --git a/third_party/polymer/v1_0/components/polymer/polymer.html b/third_party/polymer/v1_0/components/polymer/polymer.html new file mode 100644 index 0000000..8eec9b4 --- /dev/null +++ b/third_party/polymer/v1_0/components/polymer/polymer.html @@ -0,0 +1,3779 @@ +<!-- +@license +Copyright (c) 2015 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><!-- +@license +Copyright (c) 2014 The Polymer Project Authors. All rights reserved. +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt +Code distributed by Google as part of the polymer project is also +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt +--><link rel="import" href="polymer-mini.html"> + +<script>Polymer.nar = []; + +Polymer.Annotations = { +parseAnnotations: function(template) { +var list = []; +var content = template._content || template.content; +this._parseNodeAnnotations(content, list); +return list; +}, +_parseNodeAnnotations: function(node, list) { +return node.nodeType === Node.TEXT_NODE ? this._parseTextNodeAnnotation(node, list) : this._parseElementAnnotations(node, list); +}, +_testEscape: function(value) { +var escape = value.slice(0, 2); +if (escape === "{{" || escape === "[[") { +return escape; +} +}, +_parseTextNodeAnnotation: function(node, list) { +var v = node.textContent; +var escape = this._testEscape(v); +if (escape) { +node.textContent = " "; +var annote = { +bindings: [ { +kind: "text", +mode: escape[0], +value: v.slice(2, -2).trim() +} ] +}; +list.push(annote); +return annote; +} +}, +_parseElementAnnotations: function(element, list) { +var annote = { +bindings: [], +events: [] +}; +this._parseChildNodesAnnotations(element, annote, list); +if (element.attributes) { +this._parseNodeAttributeAnnotations(element, annote, list); +if (this.prepElement) { +this.prepElement(element); +} +} +if (annote.bindings.length || annote.events.length || annote.id) { +list.push(annote); +} +return annote; +}, +_parseChildNodesAnnotations: function(root, annote, list, callback) { +if (root.firstChild) { +for (var i = 0, node = root.firstChild; node; node = node.nextSibling, i++) { +if (node.localName === "template" && !node.hasAttribute("preserve-content")) { +this._parseTemplate(node, i, list, annote); +} +var childAnnotation = this._parseNodeAnnotations(node, list, callback); +if (childAnnotation) { +childAnnotation.parent = annote; +childAnnotation.index = i; +} +} +} +}, +_parseTemplate: function(node, index, list, parent) { +var content = document.createDocumentFragment(); +content._notes = this.parseAnnotations(node); +content.appendChild(node.content); +list.push({ +bindings: Polymer.nar, +events: Polymer.nar, +templateContent: content, +parent: parent, +index: index +}); +}, +_parseNodeAttributeAnnotations: function(node, annotation) { +for (var i = node.attributes.length - 1, a; a = node.attributes[i]; i--) { +var n = a.name, v = a.value; +if (n === "id" && !this._testEscape(v)) { +annotation.id = v; +} else if (n.slice(0, 3) === "on-") { +node.removeAttribute(n); +annotation.events.push({ +name: n.slice(3), +value: v +}); +} else { +var b = this._parseNodeAttributeAnnotation(node, n, v); +if (b) { +annotation.bindings.push(b); +} +} +} +}, +_parseNodeAttributeAnnotation: function(node, n, v) { +var escape = this._testEscape(v); +if (escape) { +var customEvent; +var name = n; +var mode = escape[0]; +v = v.slice(2, -2).trim(); +var not = false; +if (v[0] == "!") { +v = v.substring(1); +not = true; +} +var kind = "property"; +if (n[n.length - 1] == "$") { +name = n.slice(0, -1); +kind = "attribute"; +} +var notifyEvent, colon; +if (mode == "{" && (colon = v.indexOf("::")) > 0) { +notifyEvent = v.substring(colon + 2); +v = v.substring(0, colon); +customEvent = true; +} +if (node.localName == "input" && n == "value") { +node.setAttribute(n, ""); +} +node.removeAttribute(n); +if (kind === "property") { +name = Polymer.CaseMap.dashToCamelCase(name); +} +return { +kind: kind, +mode: mode, +name: name, +value: v, +negate: not, +event: notifyEvent, +customEvent: customEvent +}; +} +}, +_localSubTree: function(node, host) { +return node === host ? node.childNodes : node._lightChildren || node.childNodes; +}, +findAnnotatedNode: function(root, annote) { +var parent = annote.parent && Polymer.Annotations.findAnnotatedNode(root, annote.parent); +return !parent ? root : Polymer.Annotations._localSubTree(parent, root)[annote.index]; +} +}; + +(function() { +function resolveCss(cssText, ownerDocument) { +return cssText.replace(CSS_URL_RX, function(m, pre, url, post) { +return pre + "'" + resolve(url.replace(/["']/g, ""), ownerDocument) + "'" + post; +}); +} +function resolveAttrs(element, ownerDocument) { +for (var name in URL_ATTRS) { +var a$ = URL_ATTRS[name]; +for (var i = 0, l = a$.length, a, at, v; i < l && (a = a$[i]); i++) { +if (name === "*" || element.localName === name) { +at = element.attributes[a]; +v = at && at.value; +if (v && v.search(BINDING_RX) < 0) { +at.value = a === "style" ? resolveCss(v, ownerDocument) : resolve(v, ownerDocument); +} +} +} +} +} +function resolve(url, ownerDocument) { +var resolver = getUrlResolver(ownerDocument); +resolver.href = url; +return resolver.href || url; +} +var tempDoc; +var tempDocBase; +function resolveUrl(url, baseUri) { +if (!tempDoc) { +tempDoc = document.implementation.createHTMLDocument("temp"); +tempDocBase = tempDoc.createElement("base"); +tempDoc.head.appendChild(tempDocBase); +} +tempDocBase.href = baseUri; +return resolve(url, tempDoc); +} +function getUrlResolver(ownerDocument) { +return ownerDocument.__urlResolver || (ownerDocument.__urlResolver = ownerDocument.createElement("a")); +} +var CSS_URL_RX = /(url\()([^)]*)(\))/g; +var URL_ATTRS = { +"*": [ "href", "src", "style", "url" ], +form: [ "action" ] +}; +var BINDING_RX = /\{\{|\[\[/; +Polymer.ResolveUrl = { +resolveCss: resolveCss, +resolveAttrs: resolveAttrs, +resolveUrl: resolveUrl +}; +})(); + +Polymer.Base._addFeature({ +_prepAnnotations: function() { +if (!this._template) { +this._notes = []; +} else { +Polymer.Annotations.prepElement = this._prepElement.bind(this); +this._notes = Polymer.Annotations.parseAnnotations(this._template); +this._processAnnotations(this._notes); +Polymer.Annotations.prepElement = null; +} +}, +_processAnnotations: function(notes) { +for (var i = 0; i < notes.length; i++) { +var note = notes[i]; +for (var j = 0; j < note.bindings.length; j++) { +var b = note.bindings[j]; +b.signature = this._parseMethod(b.value); +if (!b.signature) { +b.model = this._modelForPath(b.value); +} +} +if (note.templateContent) { +this._processAnnotations(note.templateContent._notes); +var pp = note.templateContent._parentProps = this._discoverTemplateParentProps(note.templateContent._notes); +var bindings = []; +for (var prop in pp) { +bindings.push({ +index: note.index, +kind: "property", +mode: "{", +name: "_parent_" + prop, +model: prop, +value: prop +}); +} +note.bindings = note.bindings.concat(bindings); +} +} +}, +_discoverTemplateParentProps: function(notes) { +var pp = {}; +notes.forEach(function(n) { +n.bindings.forEach(function(b) { +if (b.signature) { +var args = b.signature.args; +for (var k = 0; k < args.length; k++) { +pp[args[k].model] = true; +} +} else { +pp[b.model] = true; +} +}); +if (n.templateContent) { +var tpp = n.templateContent._parentProps; +Polymer.Base.mixin(pp, tpp); +} +}); +return pp; +}, +_prepElement: function(element) { +Polymer.ResolveUrl.resolveAttrs(element, this._template.ownerDocument); +}, +_findAnnotatedNode: Polymer.Annotations.findAnnotatedNode, +_marshalAnnotationReferences: function() { +if (this._template) { +this._marshalIdNodes(); +this._marshalAnnotatedNodes(); +this._marshalAnnotatedListeners(); +} +}, +_configureAnnotationReferences: function() { +this._configureTemplateContent(); +}, +_configureTemplateContent: function() { +this._notes.forEach(function(note, i) { +if (note.templateContent) { +this._nodes[i]._content = note.templateContent; +} +}, this); +}, +_marshalIdNodes: function() { +this.$ = {}; +this._notes.forEach(function(a) { +if (a.id) { +this.$[a.id] = this._findAnnotatedNode(this.root, a); +} +}, this); +}, +_marshalAnnotatedNodes: function() { +if (this._nodes) { +this._nodes = this._nodes.map(function(a) { +return this._findAnnotatedNode(this.root, a); +}, this); +} +}, +_marshalAnnotatedListeners: function() { +this._notes.forEach(function(a) { +if (a.events && a.events.length) { +var node = this._findAnnotatedNode(this.root, a); +a.events.forEach(function(e) { +this.listen(node, e.name, e.value); +}, this); +} +}, this); +} +}); + +Polymer.Base._addFeature({ +listeners: {}, +_listenListeners: function(listeners) { +var node, name, key; +for (key in listeners) { +if (key.indexOf(".") < 0) { +node = this; +name = key; +} else { +name = key.split("."); +node = this.$[name[0]]; +name = name[1]; +} +this.listen(node, name, listeners[key]); +} +}, +listen: function(node, eventName, methodName) { +this._listen(node, eventName, this._createEventHandler(node, eventName, methodName)); +}, +_createEventHandler: function(node, eventName, methodName) { +var host = this; +return function(e) { +if (host[methodName]) { +host[methodName](e, e.detail); +} else { +host._warn(host._logf("_createEventHandler", "listener method `" + methodName + "` not defined")); +} +}; +}, +_listen: function(node, eventName, handler) { +node.addEventListener(eventName, handler); +} +}); + +(function() { +"use strict"; +var HAS_NATIVE_TA = typeof document.head.style.touchAction === "string"; +var GESTURE_KEY = "__polymerGestures"; +var HANDLED_OBJ = "__polymerGesturesHandled"; +var TOUCH_ACTION = "__polymerGesturesTouchAction"; +var TAP_DISTANCE = 25; +var TRACK_DISTANCE = 5; +var TRACK_LENGTH = 2; +var MOUSE_TIMEOUT = 2500; +var MOUSE_EVENTS = [ "mousedown", "mousemove", "mouseup", "click" ]; +var mouseCanceller = function(mouseEvent) { +mouseEvent[HANDLED_OBJ] = { +skip: true +}; +if (mouseEvent.type === "click") { +var path = Polymer.dom(mouseEvent).path; +for (var i = 0; i < path.length; i++) { +if (path[i] === POINTERSTATE.mouse.target) { +return; +} +} +mouseEvent.preventDefault(); +mouseEvent.stopPropagation(); +} +}; +function setupTeardownMouseCanceller(setup) { +for (var i = 0, en; i < MOUSE_EVENTS.length; i++) { +en = MOUSE_EVENTS[i]; +if (setup) { +document.addEventListener(en, mouseCanceller, true); +} else { +document.removeEventListener(en, mouseCanceller, true); +} +} +} +function ignoreMouse() { +if (!POINTERSTATE.mouse.mouseIgnoreJob) { +setupTeardownMouseCanceller(true); +} +var unset = function() { +setupTeardownMouseCanceller(); +POINTERSTATE.mouse.target = null; +POINTERSTATE.mouse.mouseIgnoreJob = null; +}; +POINTERSTATE.mouse.mouseIgnoreJob = Polymer.Debounce(POINTERSTATE.mouse.mouseIgnoreJob, unset, MOUSE_TIMEOUT); +} +var POINTERSTATE = { +tapPrevented: false, +mouse: { +target: null, +mouseIgnoreJob: null +}, +touch: { +x: 0, +y: 0, +id: -1, +scrollDecided: false +} +}; +function firstTouchAction(ev) { +var path = Polymer.dom(ev).path; +var ta = "auto"; +for (var i = 0, n; i < path.length; i++) { +n = path[i]; +if (n[TOUCH_ACTION]) { +ta = n[TOUCH_ACTION]; +break; +} +} +return ta; +} +var Gestures = { +gestures: {}, +recognizers: [], +deepTargetFind: function(x, y) { +var node = document.elementFromPoint(x, y); +var next = node; +while (next && next.shadowRoot) { +next = next.shadowRoot.elementFromPoint(x, y); +if (next) { +node = next; +} +} +return node; +}, +handleNative: function(ev) { +var handled; +var type = ev.type; +var node = ev.currentTarget; +var gobj = node[GESTURE_KEY]; +var gs = gobj[type]; +if (!gs) { +return; +} +if (!ev[HANDLED_OBJ]) { +ev[HANDLED_OBJ] = {}; +if (type.slice(0, 5) === "touch") { +var t = ev.changedTouches[0]; +if (type === "touchstart") { +if (ev.touches.length === 1) { +POINTERSTATE.touch.id = t.identifier; +} +} +if (POINTERSTATE.touch.id !== t.identifier) { +return; +} +if (!HAS_NATIVE_TA) { +if (type === "touchstart" || type === "touchmove") { +Gestures.handleTouchAction(ev); +} +} +if (type === "touchend") { +POINTERSTATE.mouse.target = Polymer.dom(ev).rootTarget; +ignoreMouse(true); +} +} +} +handled = ev[HANDLED_OBJ]; +if (handled.skip) { +return; +} +var recognizers = Gestures.recognizers; +for (var i = 0, r; i < recognizers.length; i++) { +r = recognizers[i]; +if (gs[r.name] && !handled[r.name]) { +handled[r.name] = true; +r[type](ev); +} +} +}, +handleTouchAction: function(ev) { +var t = ev.changedTouches[0]; +var type = ev.type; +if (type === "touchstart") { +POINTERSTATE.touch.x = t.clientX; +POINTERSTATE.touch.y = t.clientY; +POINTERSTATE.touch.scrollDecided = false; +} else if (type === "touchmove") { +if (POINTERSTATE.touch.scrollDecided) { +return; +} +POINTERSTATE.touch.scrollDecided = true; +var ta = firstTouchAction(ev); +var prevent = false; +var dx = Math.abs(POINTERSTATE.touch.x - t.clientX); +var dy = Math.abs(POINTERSTATE.touch.y - t.clientY); +if (!ev.cancelable) {} else if (ta === "none") { +prevent = true; +} else if (ta === "pan-x") { +prevent = dy > dx; +} else if (ta === "pan-y") { +prevent = dx > dy; +} +if (prevent) { +ev.preventDefault(); +} +} +}, +add: function(node, evType, handler) { +var recognizer = this.gestures[evType]; +var deps = recognizer.deps; +var name = recognizer.name; +var gobj = node[GESTURE_KEY]; +if (!gobj) { +node[GESTURE_KEY] = gobj = {}; +} +for (var i = 0, dep, gd; i < deps.length; i++) { +dep = deps[i]; +gd = gobj[dep]; +if (!gd) { +gobj[dep] = gd = {}; +node.addEventListener(dep, this.handleNative); +} +gd[name] = (gd[name] || 0) + 1; +} +node.addEventListener(evType, handler); +if (recognizer.touchAction) { +this.setTouchAction(node, recognizer.touchAction); +} +}, +register: function(recog) { +this.recognizers.push(recog); +for (var i = 0; i < recog.emits.length; i++) { +this.gestures[recog.emits[i]] = recog; +} +}, +setTouchAction: function(node, value) { +if (HAS_NATIVE_TA) { +node.style.touchAction = value; +} +node[TOUCH_ACTION] = value; +}, +fire: function(target, type, detail) { +var ev = new CustomEvent(type, { +detail: detail, +bubbles: true, +cancelable: true +}); +target.dispatchEvent(ev); +} +}; +Gestures.register({ +name: "downup", +deps: [ "mousedown", "touchstart", "touchend" ], +emits: [ "down", "up" ], +mousedown: function(e) { +var t = e.currentTarget; +var self = this; +var upfn = function upfn(e) { +self.fire("up", t, e); +document.removeEventListener("mouseup", upfn); +}; +document.addEventListener("mouseup", upfn); +this.fire("down", t, e); +}, +touchstart: function(e) { +this.fire("down", e.currentTarget, e.changedTouches[0]); +}, +touchend: function(e) { +this.fire("up", e.currentTarget, e.changedTouches[0]); +}, +fire: function(type, target, event) { +Gestures.fire(target, type, { +x: event.clientX, +y: event.clientY, +sourceEvent: event +}); +} +}); +Gestures.register({ +name: "track", +touchAction: "none", +deps: [ "mousedown", "touchstart", "touchmove", "touchend" ], +emits: [ "track" ], +info: { +x: 0, +y: 0, +state: "start", +started: false, +moves: [], +addMove: function(move) { +if (this.moves.length > TRACK_LENGTH) { +this.moves.shift(); +} +this.moves.push(move); +} +}, +clearInfo: function() { +this.info.state = "start"; +this.info.started = false; +this.info.moves = []; +this.info.x = 0; +this.info.y = 0; +}, +hasMovedEnough: function(x, y) { +if (this.info.started) { +return true; +} +var dx = Math.abs(this.info.x - x); +var dy = Math.abs(this.info.y - y); +return dx >= TRACK_DISTANCE || dy >= TRACK_DISTANCE; +}, +mousedown: function(e) { +var t = e.currentTarget; +var self = this; +var movefn = function movefn(e) { +var x = e.clientX, y = e.clientY; +if (self.hasMovedEnough(x, y)) { +self.info.state = self.info.started ? e.type === "mouseup" ? "end" : "track" : "start"; +self.info.addMove({ +x: x, +y: y +}); +self.fire(t, e); +e.preventDefault(); +self.info.started = true; +} +}; +var upfn = function upfn(e) { +if (self.info.started) { +POINTERSTATE.tapPrevented = true; +movefn(e); +} +self.clearInfo(); +document.removeEventListener("mousemove", movefn); +document.removeEventListener("mouseup", upfn); +}; +document.addEventListener("mousemove", movefn); +document.addEventListener("mouseup", upfn); +this.info.x = e.clientX; +this.info.y = e.clientY; +}, +touchstart: function(e) { +var ct = e.changedTouches[0]; +this.info.x = ct.clientX; +this.info.y = ct.clientY; +}, +touchmove: function(e) { +var t = e.currentTarget; +var ct = e.changedTouches[0]; +var x = ct.clientX, y = ct.clientY; +if (this.hasMovedEnough(x, y)) { +this.info.addMove({ +x: x, +y: y +}); +this.fire(t, ct); +this.info.state = "track"; +this.info.started = true; +} +}, +touchend: function(e) { +var t = e.currentTarget; +var ct = e.changedTouches[0]; +if (this.info.started) { +POINTERSTATE.tapPrevented = true; +this.info.state = "end"; +this.info.addMove({ +x: ct.clientX, +y: ct.clientY +}); +this.fire(t, ct); +} +this.clearInfo(); +}, +fire: function(target, touch) { +var secondlast = this.info.moves[this.info.moves.length - 2]; +var lastmove = this.info.moves[this.info.moves.length - 1]; +var dx = lastmove.x - this.info.x; +var dy = lastmove.y - this.info.y; +var ddx, ddy = 0; +if (secondlast) { +ddx = lastmove.x - secondlast.x; +ddy = lastmove.y - secondlast.y; +} +return Gestures.fire(target, "track", { +state: this.info.state, +x: touch.clientX, +y: touch.clientY, +dx: dx, +dy: dy, +ddx: ddx, +ddy: ddy, +sourceEvent: touch, +hover: function() { +return Gestures.deepTargetFind(touch.clientX, touch.clientY); +} +}); +} +}); +Gestures.register({ +name: "tap", +deps: [ "mousedown", "click", "touchstart", "touchend" ], +emits: [ "tap" ], +start: { +x: NaN, +y: NaN +}, +reset: function() { +this.start.x = NaN; +this.start.y = NaN; +}, +save: function(e) { +this.start.x = e.clientX; +this.start.y = e.clientY; +}, +mousedown: function(e) { +POINTERSTATE.tapPrevented = false; +this.save(e); +}, +click: function(e) { +this.forward(e); +}, +touchstart: function(e) { +POINTERSTATE.tapPrevented = false; +this.save(e.changedTouches[0]); +}, +touchend: function(e) { +this.forward(e.changedTouches[0]); +}, +forward: function(e) { +var dx = Math.abs(e.clientX - this.start.x); +var dy = Math.abs(e.clientY - this.start.y); +if (isNaN(dx) || isNaN(dy) || dx <= TAP_DISTANCE && dy <= TAP_DISTANCE) { +if (!POINTERSTATE.tapPrevented) { +Gestures.fire(e.target, "tap", { +x: e.clientX, +y: e.clientY, +sourceEvent: e +}); +} +} +this.reset(); +} +}); +var DIRECTION_MAP = { +x: "pan-x", +y: "pan-y", +none: "none", +all: "auto" +}; +Polymer.Base._addFeature({ +_listen: function(node, eventName, handler) { +if (Gestures.gestures[eventName]) { +Gestures.add(node, eventName, handler); +} else { +node.addEventListener(eventName, handler); +} +}, +setScrollDirection: function(direction, node) { +node = node || this; +Gestures.setTouchAction(node, DIRECTION_MAP[direction] || "auto"); +} +}); +Polymer.Gestures = Gestures; +})(); + +Polymer.Async = function() { +var currVal = 0; +var lastVal = 0; +var callbacks = []; +var twiddle = document.createTextNode(""); +function runAsync(callback, waitTime) { +if (waitTime > 0) { +return ~setTimeout(callback, waitTime); +} else { +twiddle.textContent = currVal++; +callbacks.push(callback); +return currVal - 1; +} +} +function cancelAsync(handle) { +if (handle < 0) { +clearTimeout(~handle); +} else { +var idx = handle - lastVal; +if (idx >= 0) { +if (!callbacks[idx]) { +throw "invalid async handle: " + handle; +} +callbacks[idx] = null; +} +} +} +function atEndOfMicrotask() { +var len = callbacks.length; +for (var i = 0; i < len; i++) { +var cb = callbacks[i]; +if (cb) { +cb(); +} +} +callbacks.splice(0, len); +lastVal += len; +} +new (window.MutationObserver || JsMutationObserver)(atEndOfMicrotask).observe(twiddle, { +characterData: true +}); +return { +run: runAsync, +cancel: cancelAsync +}; +}(); + +Polymer.Debounce = function() { +var Async = Polymer.Async; +var Debouncer = function(context) { +this.context = context; +this.boundComplete = this.complete.bind(this); +}; +Debouncer.prototype = { +go: function(callback, wait) { +var h; +this.finish = function() { +Async.cancel(h); +}; +h = Async.run(this.boundComplete, wait); +this.callback = callback; +}, +stop: function() { +if (this.finish) { +this.finish(); +this.finish = null; +} +}, +complete: function() { +if (this.finish) { +this.stop(); +this.callback.call(this.context); +} +} +}; +function debounce(debouncer, callback, wait) { +if (debouncer) { +debouncer.stop(); +} else { +debouncer = new Debouncer(this); +} +debouncer.go(callback, wait); +return debouncer; +} +return debounce; +}(); + +Polymer.Base._addFeature({ +$$: function(slctr) { +return Polymer.dom(this.root).querySelector(slctr); +}, +toggleClass: function(name, bool, node) { +node = node || this; +if (arguments.length == 1) { +bool = !node.classList.contains(name); +} +if (bool) { +Polymer.dom(node).classList.add(name); +} else { +Polymer.dom(node).classList.remove(name); +} +}, +toggleAttribute: function(name, bool, node) { +node = node || this; +if (arguments.length == 1) { +bool = !node.hasAttribute(name); +} +if (bool) { +Polymer.dom(node).setAttribute(name, ""); +} else { +Polymer.dom(node).removeAttribute(name); +} +}, +classFollows: function(name, toElement, fromElement) { +if (fromElement) { +Polymer.dom(fromElement).classList.remove(name); +} +if (toElement) { +Polymer.dom(toElement).classList.add(name); +} +}, +attributeFollows: function(name, toElement, fromElement) { +if (fromElement) { +Polymer.dom(fromElement).removeAttribute(name); +} +if (toElement) { +Polymer.dom(toElement).setAttribute(name, ""); +} +}, +getContentChildNodes: function(slctr) { +return Polymer.dom(Polymer.dom(this.root).querySelector(slctr || "content")).getDistributedNodes(); +}, +getContentChildren: function(slctr) { +return this.getContentChildNodes(slctr).filter(function(n) { +return n.nodeType === Node.ELEMENT_NODE; +}); +}, +fire: function(type, detail, options) { +options = options || Polymer.nob; +var node = options.node || this; +var detail = detail === null || detail === undefined ? Polymer.nob : detail; +var bubbles = options.bubbles === undefined ? true : options.bubbles; +var event = new CustomEvent(type, { +bubbles: Boolean(bubbles), +cancelable: Boolean(options.cancelable), +detail: detail +}); +node.dispatchEvent(event); +return event; +}, +async: function(callback, waitTime) { +return Polymer.Async.run(callback.bind(this), waitTime); +}, +cancelAsync: function(handle) { +Polymer.Async.cancel(handle); +}, +arrayDelete: function(path, item) { +var index; +if (Array.isArray(path)) { +index = path.indexOf(item); +if (index >= 0) { +return path.splice(index, 1); +} +} else { +var arr = this.get(path); +index = arr.indexOf(item); +if (index >= 0) { +return this.splice(path, index, 1); +} +} +}, +transform: function(transform, node) { +node = node || this; +node.style.webkitTransform = transform; +node.style.transform = transform; +}, +translate3d: function(x, y, z, node) { +node = node || this; +this.transform("translate3d(" + x + "," + y + "," + z + ")", node); +}, +importHref: function(href, onload, onerror) { +var l = document.createElement("link"); +l.rel = "import"; +l.href = href; +if (onload) { +l.onload = onload.bind(this); +} +if (onerror) { +l.onerror = onerror.bind(this); +} +document.head.appendChild(l); +return l; +}, +create: function(tag, props) { +var elt = document.createElement(tag); +if (props) { +for (var n in props) { +elt[n] = props[n]; +} +} +return elt; +}, +mixin: function(target, source) { +for (var i in source) { +target[i] = source[i]; +} +} +}); + +Polymer.Bind = { +prepareModel: function(model) { +model._propertyEffects = {}; +model._bindListeners = []; +var api = this._modelApi; +for (var n in api) { +model[n] = api[n]; +} +}, +_modelApi: { +_notifyChange: function(property) { +var eventName = Polymer.CaseMap.camelToDashCase(property) + "-changed"; +this.fire(eventName, { +value: this[property] +}, { +bubbles: false +}); +}, +_propertySet: function(property, value, effects) { +var old = this.__data__[property]; +if (old !== value) { +this.__data__[property] = value; +if (typeof value == "object") { +this._clearPath(property); +} +if (this._propertyChanged) { +this._propertyChanged(property, value, old); +} +if (effects) { +this._effectEffects(property, value, effects, old); +} +} +return old; +}, +_effectEffects: function(property, value, effects, old) { +effects.forEach(function(fx) { +var fn = Polymer.Bind["_" + fx.kind + "Effect"]; +if (fn) { +fn.call(this, property, value, fx.effect, old); +} +}, this); +}, +_clearPath: function(path) { +for (var prop in this.__data__) { +if (prop.indexOf(path + ".") === 0) { +this.__data__[prop] = undefined; +} +} +} +}, +ensurePropertyEffects: function(model, property) { +var fx = model._propertyEffects[property]; +if (!fx) { +fx = model._propertyEffects[property] = []; +} +return fx; +}, +addPropertyEffect: function(model, property, kind, effect) { +var fx = this.ensurePropertyEffects(model, property); +fx.push({ +kind: kind, +effect: effect +}); +}, +createBindings: function(model) { +var fx$ = model._propertyEffects; +if (fx$) { +for (var n in fx$) { +var fx = fx$[n]; +fx.sort(this._sortPropertyEffects); +this._createAccessors(model, n, fx); +} +} +}, +_sortPropertyEffects: function() { +var EFFECT_ORDER = { +compute: 0, +annotation: 1, +computedAnnotation: 2, +reflect: 3, +notify: 4, +observer: 5, +complexObserver: 6, +"function": 7 +}; +return function(a, b) { +return EFFECT_ORDER[a.kind] - EFFECT_ORDER[b.kind]; +}; +}(), +_createAccessors: function(model, property, effects) { +var defun = { +get: function() { +return this.__data__[property]; +} +}; +var setter = function(value) { +this._propertySet(property, value, effects); +}; +if (model.getPropertyInfo && model.getPropertyInfo(property).readOnly) { +model["_set" + this.upper(property)] = setter; +} else { +defun.set = setter; +} +Object.defineProperty(model, property, defun); +}, +upper: function(name) { +return name[0].toUpperCase() + name.substring(1); +}, +_addAnnotatedListener: function(model, index, property, path, event) { +var fn = this._notedListenerFactory(property, path, this._isStructured(path), this._isEventBogus); +var eventName = event || Polymer.CaseMap.camelToDashCase(property) + "-changed"; +model._bindListeners.push({ +index: index, +property: property, +path: path, +changedFn: fn, +event: eventName +}); +}, +_isStructured: function(path) { +return path.indexOf(".") > 0; +}, +_isEventBogus: function(e, target) { +return e.path && e.path[0] !== target; +}, +_notedListenerFactory: function(property, path, isStructured, bogusTest) { +return function(e, target) { +if (!bogusTest(e, target)) { +if (e.detail && e.detail.path) { +this.notifyPath(this._fixPath(path, property, e.detail.path), e.detail.value); +} else { +var value = target[property]; +if (!isStructured) { +this[path] = target[property]; +} else { +if (this.__data__[path] != value) { +this.set(path, value); +} +} +} +} +}; +}, +prepareInstance: function(inst) { +inst.__data__ = Object.create(null); +}, +setupBindListeners: function(inst) { +inst._bindListeners.forEach(function(info) { +var node = inst._nodes[info.index]; +node.addEventListener(info.event, inst._notifyListener.bind(inst, info.changedFn)); +}); +} +}; + +Polymer.Base.extend(Polymer.Bind, { +_shouldAddListener: function(effect) { +return effect.name && effect.mode === "{" && !effect.negate && effect.kind != "attribute"; +}, +_annotationEffect: function(source, value, effect) { +if (source != effect.value) { +value = this.get(effect.value); +this.__data__[effect.value] = value; +} +var calc = effect.negate ? !value : value; +if (!effect.customEvent || this._nodes[effect.index][effect.name] !== calc) { +return this._applyEffectValue(calc, effect); +} +}, +_reflectEffect: function(source) { +this.reflectPropertyToAttribute(source); +}, +_notifyEffect: function(source) { +this._notifyChange(source); +}, +_functionEffect: function(source, value, fn, old) { +fn.call(this, source, value, old); +}, +_observerEffect: function(source, value, effect, old) { +var fn = this[effect.method]; +if (fn) { +fn.call(this, value, old); +} else { +this._warn(this._logf("_observerEffect", "observer method `" + effect.method + "` not defined")); +} +}, +_complexObserverEffect: function(source, value, effect) { +var fn = this[effect.method]; +if (fn) { +var args = Polymer.Bind._marshalArgs(this.__data__, effect, source, value); +if (args) { +fn.apply(this, args); +} +} else { +this._warn(this._logf("_complexObserverEffect", "observer method `" + effect.method + "` not defined")); +} +}, +_computeEffect: function(source, value, effect) { +var args = Polymer.Bind._marshalArgs(this.__data__, effect, source, value); +if (args) { +var fn = this[effect.method]; +if (fn) { +this[effect.property] = fn.apply(this, args); +} else { +this._warn(this._logf("_computeEffect", "compute method `" + effect.method + "` not defined")); +} +} +}, +_annotatedComputationEffect: function(source, value, effect) { +var computedHost = this._rootDataHost || this; +var fn = computedHost[effect.method]; +if (fn) { +var args = Polymer.Bind._marshalArgs(this.__data__, effect, source, value); +if (args) { +var computedvalue = fn.apply(computedHost, args); +if (effect.negate) { +computedvalue = !computedvalue; +} +this._applyEffectValue(computedvalue, effect); +} +} else { +computedHost._warn(computedHost._logf("_annotatedComputationEffect", "compute method `" + effect.method + "` not defined")); +} +}, +_marshalArgs: function(model, effect, path, value) { +var values = []; +var args = effect.args; +for (var i = 0, l = args.length; i < l; i++) { +var arg = args[i]; +var name = arg.name; +if (arg.literal) { +v = arg.value; +} else if (arg.structured) { +v = Polymer.Base.get(name, model); +} else { +v = model[name]; +} +if (args.length > 1 && v === undefined) { +return; +} +if (arg.wildcard) { +var baseChanged = name.indexOf(path + ".") === 0; +var matches = effect.trigger.name.indexOf(name) === 0 && !baseChanged; +values[i] = { +path: matches ? path : name, +value: matches ? value : v, +base: v +}; +} else { +values[i] = v; +} +} +return values; +} +}); + +Polymer.Base._addFeature({ +_addPropertyEffect: function(property, kind, effect) { +Polymer.Bind.addPropertyEffect(this, property, kind, effect); +}, +_prepEffects: function() { +Polymer.Bind.prepareModel(this); +this._addAnnotationEffects(this._notes); +}, +_prepBindings: function() { +Polymer.Bind.createBindings(this); +}, +_addPropertyEffects: function(properties) { +if (properties) { +for (var p in properties) { +var prop = properties[p]; +if (prop.observer) { +this._addObserverEffect(p, prop.observer); +} +if (prop.computed) { +this._addComputedEffect(p, prop.computed); +} +if (prop.notify) { +this._addPropertyEffect(p, "notify"); +} +if (prop.reflectToAttribute) { +this._addPropertyEffect(p, "reflect"); +} +if (prop.readOnly) { +Polymer.Bind.ensurePropertyEffects(this, p); +} +} +} +}, +_addComputedEffect: function(name, expression) { +var sig = this._parseMethod(expression); +sig.args.forEach(function(arg) { +this._addPropertyEffect(arg.model, "compute", { +method: sig.method, +args: sig.args, +trigger: arg, +property: name +}); +}, this); +}, +_addObserverEffect: function(property, observer) { +this._addPropertyEffect(property, "observer", { +method: observer, +property: property +}); +}, +_addComplexObserverEffects: function(observers) { +if (observers) { +observers.forEach(function(observer) { +this._addComplexObserverEffect(observer); +}, this); +} +}, +_addComplexObserverEffect: function(observer) { +var sig = this._parseMethod(observer); +sig.args.forEach(function(arg) { +this._addPropertyEffect(arg.model, "complexObserver", { +method: sig.method, +args: sig.args, +trigger: arg +}); +}, this); +}, +_addAnnotationEffects: function(notes) { +this._nodes = []; +notes.forEach(function(note) { +var index = this._nodes.push(note) - 1; +note.bindings.forEach(function(binding) { +this._addAnnotationEffect(binding, index); +}, this); +}, this); +}, +_addAnnotationEffect: function(note, index) { +if (Polymer.Bind._shouldAddListener(note)) { +Polymer.Bind._addAnnotatedListener(this, index, note.name, note.value, note.event); +} +if (note.signature) { +this._addAnnotatedComputationEffect(note, index); +} else { +note.index = index; +this._addPropertyEffect(note.model, "annotation", note); +} +}, +_addAnnotatedComputationEffect: function(note, index) { +var sig = note.signature; +if (sig.static) { +this.__addAnnotatedComputationEffect("__static__", index, note, sig, null); +} else { +sig.args.forEach(function(arg) { +if (!arg.literal) { +this.__addAnnotatedComputationEffect(arg.model, index, note, sig, arg); +} +}, this); +} +}, +__addAnnotatedComputationEffect: function(property, index, note, sig, trigger) { +this._addPropertyEffect(property, "annotatedComputation", { +index: index, +kind: note.kind, +property: note.name, +negate: note.negate, +method: sig.method, +args: sig.args, +trigger: trigger +}); +}, +_parseMethod: function(expression) { +var m = expression.match(/(\w*)\((.*)\)/); +if (m) { +var sig = { +method: m[1], +"static": true +}; +if (m[2].trim()) { +var args = m[2].replace(/\\,/g, ",").split(","); +return this._parseArgs(args, sig); +} else { +sig.args = Polymer.nar; +return sig; +} +} +}, +_parseArgs: function(argList, sig) { +sig.args = argList.map(function(rawArg) { +var arg = this._parseArg(rawArg); +if (!arg.literal) { +sig.static = false; +} +return arg; +}, this); +return sig; +}, +_parseArg: function(rawArg) { +var arg = rawArg.trim().replace(/,/g, ",").replace(/\\(.)/g, "$1"); +var a = { +name: arg, +model: this._modelForPath(arg) +}; +var fc = arg[0]; +if (fc >= "0" && fc <= "9") { +fc = "#"; +} +switch (fc) { +case "'": +case '"': +a.value = arg.slice(1, -1); +a.literal = true; +break; + +case "#": +a.value = Number(arg); +a.literal = true; +break; +} +if (!a.literal) { +a.structured = arg.indexOf(".") > 0; +if (a.structured) { +a.wildcard = arg.slice(-2) == ".*"; +if (a.wildcard) { +a.name = arg.slice(0, -2); +} +} +} +return a; +}, +_marshalInstanceEffects: function() { +Polymer.Bind.prepareInstance(this); +Polymer.Bind.setupBindListeners(this); +}, +_applyEffectValue: function(value, info) { +var node = this._nodes[info.index]; +var property = info.property || info.name || "textContent"; +if (info.kind == "attribute") { +this.serializeValueToAttribute(value, property, node); +} else { +if (property === "className") { +value = this._scopeElementClass(node, value); +} +if (property === "textContent" || node.localName == "input" && property == "value") { +value = value == undefined ? "" : value; +} +return node[property] = value; +} +}, +_executeStaticEffects: function() { +if (this._propertyEffects.__static__) { +this._effectEffects("__static__", null, this._propertyEffects.__static__); +} +} +}); + +Polymer.Base._addFeature({ +_setupConfigure: function(initialConfig) { +this._config = initialConfig || {}; +this._handlers = []; +}, +_marshalAttributes: function() { +this._takeAttributesToModel(this._config); +}, +_configValue: function(name, value) { +this._config[name] = value; +}, +_beforeClientsReady: function() { +this._configure(); +}, +_configure: function() { +this._configureAnnotationReferences(); +var config = {}; +this.behaviors.forEach(function(b) { +this._configureProperties(b.properties, config); +}, this); +this._configureProperties(this.properties, config); +this._mixinConfigure(config, this._config); +this._config = config; +this._distributeConfig(this._config); +}, +_configureProperties: function(properties, config) { +for (var i in properties) { +var c = properties[i]; +if (c.value !== undefined) { +var value = c.value; +if (typeof value == "function") { +value = value.call(this, this._config); +} +config[i] = value; +} +} +}, +_mixinConfigure: function(a, b) { +for (var prop in b) { +if (!this.getPropertyInfo(prop).readOnly) { +a[prop] = b[prop]; +} +} +}, +_distributeConfig: function(config) { +var fx$ = this._propertyEffects; +if (fx$) { +for (var p in config) { +var fx = fx$[p]; +if (fx) { +for (var i = 0, l = fx.length, x; i < l && (x = fx[i]); i++) { +if (x.kind === "annotation") { +var node = this._nodes[x.effect.index]; +if (node._configValue) { +var value = p === x.effect.value ? config[p] : this.get(x.effect.value, config); +node._configValue(x.effect.name, value); +} +} +} +} +} +} +}, +_afterClientsReady: function() { +this._executeStaticEffects(); +this._applyConfig(this._config); +this._flushHandlers(); +}, +_applyConfig: function(config) { +for (var n in config) { +if (this[n] === undefined) { +var effects = this._propertyEffects[n]; +if (effects) { +this._propertySet(n, config[n], effects); +} else { +this[n] = config[n]; +} +} +} +}, +_notifyListener: function(fn, e) { +if (!this._clientsReadied) { +this._queueHandler([ fn, e, e.target ]); +} else { +return fn.call(this, e, e.target); +} +}, +_queueHandler: function(args) { +this._handlers.push(args); +}, +_flushHandlers: function() { +var h$ = this._handlers; +for (var i = 0, l = h$.length, h; i < l && (h = h$[i]); i++) { +h[0].call(this, h[1], h[2]); +} +} +}); + +(function() { +"use strict"; +Polymer.Base._addFeature({ +notifyPath: function(path, value, fromAbove) { +var old = this._propertySet(path, value); +if (old !== value) { +this._pathEffector(path, value); +if (!fromAbove) { +this._notifyPath(path, value); +} +} +}, +_getPathParts: function(path) { +if (Array.isArray(path)) { +var parts = []; +for (var i = 0; i < path.length; i++) { +var args = path[i].toString().split("."); +for (var j = 0; j < args.length; j++) { +parts.push(args[j]); +} +} +return parts; +} else { +return path.toString().split("."); +} +}, +set: function(path, value, root) { +var prop = root || this; +var parts = this._getPathParts(path); +var array; +var last = parts[parts.length - 1]; +if (parts.length > 1) { +for (var i = 0; i < parts.length - 1; i++) { +prop = prop[parts[i]]; +if (array) { +parts[i] = Polymer.Collection.get(array).getKey(prop); +} +if (!prop) { +return; +} +array = Array.isArray(prop) ? prop : null; +} +prop[last] = value; +if (!root) { +this.notifyPath(parts.join("."), value); +} +} else { +prop[path] = value; +} +}, +get: function(path, root) { +var prop = root || this; +var parts = this._getPathParts(path); +var last = parts.pop(); +while (parts.length) { +prop = prop[parts.shift()]; +if (!prop) { +return; +} +} +return prop[last]; +}, +_pathEffector: function(path, value) { +var model = this._modelForPath(path); +var fx$ = this._propertyEffects[model]; +if (fx$) { +fx$.forEach(function(fx) { +var fxFn = this["_" + fx.kind + "PathEffect"]; +if (fxFn) { +fxFn.call(this, path, value, fx.effect); +} +}, this); +} +if (this._boundPaths) { +this._notifyBoundPaths(path, value); +} +}, +_annotationPathEffect: function(path, value, effect) { +if (effect.value === path || effect.value.indexOf(path + ".") === 0) { +Polymer.Bind._annotationEffect.call(this, path, value, effect); +} else if (path.indexOf(effect.value + ".") === 0 && !effect.negate) { +var node = this._nodes[effect.index]; +if (node && node.notifyPath) { +var p = this._fixPath(effect.name, effect.value, path); +node.notifyPath(p, value, true); +} +} +}, +_complexObserverPathEffect: function(path, value, effect) { +if (this._pathMatchesEffect(path, effect)) { +Polymer.Bind._complexObserverEffect.call(this, path, value, effect); +} +}, +_computePathEffect: function(path, value, effect) { +if (this._pathMatchesEffect(path, effect)) { +Polymer.Bind._computeEffect.call(this, path, value, effect); +} +}, +_annotatedComputationPathEffect: function(path, value, effect) { +if (this._pathMatchesEffect(path, effect)) { +Polymer.Bind._annotatedComputationEffect.call(this, path, value, effect); +} +}, +_pathMatchesEffect: function(path, effect) { +var effectArg = effect.trigger.name; +return effectArg == path || effectArg.indexOf(path + ".") === 0 || effect.trigger.wildcard && path.indexOf(effectArg) === 0; +}, +linkPaths: function(to, from) { +this._boundPaths = this._boundPaths || {}; +if (from) { +this._boundPaths[to] = from; +} else { +this.unbindPath(to); +} +}, +unlinkPaths: function(path) { +if (this._boundPaths) { +delete this._boundPaths[path]; +} +}, +_notifyBoundPaths: function(path, value) { +var from, to; +for (var a in this._boundPaths) { +var b = this._boundPaths[a]; +if (path.indexOf(a + ".") == 0) { +from = a; +to = b; +break; +} +if (path.indexOf(b + ".") == 0) { +from = b; +to = a; +break; +} +} +if (from && to) { +var p = this._fixPath(to, from, path); +this.notifyPath(p, value); +} +}, +_fixPath: function(property, root, path) { +return property + path.slice(root.length); +}, +_notifyPath: function(path, value) { +var rootName = this._modelForPath(path); +var dashCaseName = Polymer.CaseMap.camelToDashCase(rootName); +var eventName = dashCaseName + this._EVENT_CHANGED; +this.fire(eventName, { +path: path, +value: value +}, { +bubbles: false +}); +}, +_modelForPath: function(path) { +var dot = path.indexOf("."); +return dot < 0 ? path : path.slice(0, dot); +}, +_EVENT_CHANGED: "-changed", +_notifySplice: function(array, path, index, added, removed) { +var splices = [ { +index: index, +addedCount: added, +removed: removed, +object: array, +type: "splice" +} ]; +var change = { +keySplices: Polymer.Collection.get(array).applySplices(splices), +indexSplices: splices +}; +this.set(path + ".splices", change); +if (added != removed.length) { +this.notifyPath(path + ".length", array.length); +} +change.keySplices = null; +change.indexSplices = null; +}, +push: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var len = array.length; +var ret = array.push.apply(array, args); +this._notifySplice(array, path, len, args.length, []); +return ret; +}, +pop: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var rem = array.slice(-1); +var ret = array.pop.apply(array, args); +this._notifySplice(array, path, array.length, 0, rem); +return ret; +}, +splice: function(path, start, deleteCount) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var rem = array.slice(start, start + deleteCount); +var ret = array.splice.apply(array, args); +this._notifySplice(array, path, start, args.length - 2, rem); +return ret; +}, +shift: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var ret = array.shift.apply(array, args); +this._notifySplice(array, path, 0, 0, [ ret ]); +return ret; +}, +unshift: function(path) { +var array = this.get(path); +var args = Array.prototype.slice.call(arguments, 1); +var ret = array.unshift.apply(array, args); +this._notifySplice(array, path, 0, args.length, []); +return ret; +} +}); +})(); + +Polymer.Base._addFeature({ +resolveUrl: function(url) { +var module = Polymer.DomModule.import(this.is); +var root = ""; +if (module) { +var assetPath = module.getAttribute("assetpath") || ""; +root = Polymer.ResolveUrl.resolveUrl(assetPath, module.ownerDocument.baseURI); +} +return Polymer.ResolveUrl.resolveUrl(url, root); +} +}); + +Polymer.CssParse = function() { +var api = { +parse: function(text) { +text = this._clean(text); +return this._parseCss(this._lex(text), text); +}, +_clean: function(cssText) { +return cssText.replace(rx.comments, "").replace(rx.port, ""); +}, +_lex: function(text) { +var root = { +start: 0, +end: text.length +}; +var n = root; +for (var i = 0, s = 0, l = text.length; i < l; i++) { +switch (text[i]) { +case this.OPEN_BRACE: +if (!n.rules) { +n.rules = []; +} +var p = n; +var previous = p.rules[p.rules.length - 1]; +n = { +start: i + 1, +parent: p, +previous: previous +}; +p.rules.push(n); +break; + +case this.CLOSE_BRACE: +n.end = i + 1; +n = n.parent || root; +break; +} +} +return root; +}, +_parseCss: function(node, text) { +var t = text.substring(node.start, node.end - 1); +node.parsedCssText = node.cssText = t.trim(); +if (node.parent) { +var ss = node.previous ? node.previous.end : node.parent.start; +t = text.substring(ss, node.start - 1); +t = t.substring(t.lastIndexOf(";") + 1); +var s = node.parsedSelector = node.selector = t.trim(); +node.atRule = s.indexOf(AT_START) === 0; +if (node.atRule) { +if (s.indexOf(MEDIA_START) === 0) { +node.type = this.types.MEDIA_RULE; +} else if (s.match(rx.keyframesRule)) { +node.type = this.types.KEYFRAMES_RULE; +} +} else { +if (s.indexOf(VAR_START) === 0) { +node.type = this.types.MIXIN_RULE; +} else { +node.type = this.types.STYLE_RULE; +} +} +} +var r$ = node.rules; +if (r$) { +for (var i = 0, l = r$.length, r; i < l && (r = r$[i]); i++) { +this._parseCss(r, text); +} +} +return node; +}, +stringify: function(node, preserveProperties, text) { +text = text || ""; +var cssText = ""; +if (node.cssText || node.rules) { +var r$ = node.rules; +if (r$ && (preserveProperties || !hasMixinRules(r$))) { +for (var i = 0, l = r$.length, r; i < l && (r = r$[i]); i++) { +cssText = this.stringify(r, preserveProperties, cssText); +} +} else { +cssText = preserveProperties ? node.cssText : removeCustomProps(node.cssText); +cssText = cssText.trim(); +if (cssText) { +cssText = " " + cssText + "\n"; +} +} +} +if (cssText) { +if (node.selector) { +text += node.selector + " " + this.OPEN_BRACE + "\n"; +} +text += cssText; +if (node.selector) { +text += this.CLOSE_BRACE + "\n\n"; +} +} +return text; +}, +types: { +STYLE_RULE: 1, +KEYFRAMES_RULE: 7, +MEDIA_RULE: 4, +MIXIN_RULE: 1e3 +}, +OPEN_BRACE: "{", +CLOSE_BRACE: "}" +}; +function hasMixinRules(rules) { +return rules[0].selector.indexOf(VAR_START) >= 0; +} +function removeCustomProps(cssText) { +return cssText.replace(rx.customProp, "").replace(rx.mixinProp, "").replace(rx.mixinApply, "").replace(rx.varApply, ""); +} +var VAR_START = "--"; +var MEDIA_START = "@media"; +var AT_START = "@"; +var rx = { +comments: /\/\*[^*]*\*+([^\/*][^*]*\*+)*\//gim, +port: /@import[^;]*;/gim, +customProp: /(?:^|[\s;])--[^;{]*?:[^{};]*?;/gim, +mixinProp: /(?:^|[\s;])--[^;{]*?:[^{;]*?{[^}]*?};?/gim, +mixinApply: /@apply[\s]*\([^)]*?\)[\s]*;/gim, +varApply: /[^;:]*?:[^;]*var[^;]*;/gim, +keyframesRule: /^@[^\s]*keyframes/ +}; +return api; +}(); + +Polymer.StyleUtil = function() { +return { +MODULE_STYLES_SELECTOR: "style, link[rel=import][type~=css]", +toCssText: function(rules, callback, preserveProperties) { +if (typeof rules === "string") { +rules = this.parser.parse(rules); +} +if (callback) { +this.forEachStyleRule(rules, callback); +} +return this.parser.stringify(rules, preserveProperties); +}, +forRulesInStyles: function(styles, callback) { +for (var i = 0, l = styles.length, s; i < l && (s = styles[i]); i++) { +this.forEachStyleRule(this.rulesForStyle(s), callback); +} +}, +rulesForStyle: function(style) { +if (!style.__cssRules) { +style.__cssRules = this.parser.parse(style.textContent); +} +return style.__cssRules; +}, +clearStyleRules: function(style) { +style.__cssRules = null; +}, +forEachStyleRule: function(node, callback) { +var s = node.selector; +var skipRules = false; +if (node.type === this.ruleTypes.STYLE_RULE) { +callback(node); +} else if (node.type === this.ruleTypes.KEYFRAMES_RULE || node.type === this.ruleTypes.MIXIN_RULE) { +skipRules = true; +} +var r$ = node.rules; +if (r$ && !skipRules) { +for (var i = 0, l = r$.length, r; i < l && (r = r$[i]); i++) { +this.forEachStyleRule(r, callback); +} +} +}, +applyCss: function(cssText, moniker, target, afterNode) { +var style = document.createElement("style"); +if (moniker) { +style.setAttribute("scope", moniker); +} +style.textContent = cssText; +target = target || document.head; +if (!afterNode) { +var n$ = target.querySelectorAll("style[scope]"); +afterNode = n$[n$.length - 1]; +} +target.insertBefore(style, afterNode && afterNode.nextSibling || target.firstChild); +return style; +}, +cssFromModule: function(moduleId) { +var m = Polymer.DomModule.import(moduleId); +if (m && !m._cssText) { +var cssText = ""; +var e$ = Array.prototype.slice.call(m.querySelectorAll(this.MODULE_STYLES_SELECTOR)); +for (var i = 0, e; i < e$.length; i++) { +e = e$[i]; +if (e.localName === "style") { +e = e.__appliedElement || e; +e.parentNode.removeChild(e); +} else { +e = e.import && e.import.body; +} +if (e) { +cssText += Polymer.ResolveUrl.resolveCss(e.textContent, e.ownerDocument); +} +} +m._cssText = cssText; +} +return m && m._cssText || ""; +}, +parser: Polymer.CssParse, +ruleTypes: Polymer.CssParse.types +}; +}(); + +Polymer.StyleTransformer = function() { +var nativeShadow = Polymer.Settings.useNativeShadow; +var styleUtil = Polymer.StyleUtil; +var api = { +dom: function(node, scope, useAttr, shouldRemoveScope) { +this._transformDom(node, scope || "", useAttr, shouldRemoveScope); +}, +_transformDom: function(node, selector, useAttr, shouldRemoveScope) { +if (node.setAttribute) { +this.element(node, selector, useAttr, shouldRemoveScope); +} +var c$ = Polymer.dom(node).childNodes; +for (var i = 0; i < c$.length; i++) { +this._transformDom(c$[i], selector, useAttr, shouldRemoveScope); +} +}, +element: function(element, scope, useAttr, shouldRemoveScope) { +if (useAttr) { +if (shouldRemoveScope) { +element.removeAttribute(SCOPE_NAME); +} else { +element.setAttribute(SCOPE_NAME, scope); +} +} else { +if (scope) { +if (element.classList) { +if (shouldRemoveScope) { +element.classList.remove(SCOPE_NAME); +element.classList.remove(scope); +} else { +element.classList.add(SCOPE_NAME); +element.classList.add(scope); +} +} else if (element.getAttribute) { +var c = element.getAttribute(CLASS); +if (shouldRemoveScope) { +if (c) { +element.setAttribute(CLASS, c.replace(SCOPE_NAME, "").replace(scope, "")); +} +} else { +element.setAttribute(CLASS, c + (c ? " " : "") + SCOPE_NAME + " " + scope); +} +} +} +} +}, +elementStyles: function(element, callback) { +var styles = element._styles; +var cssText = ""; +for (var i = 0, l = styles.length, s, text; i < l && (s = styles[i]); i++) { +var rules = styleUtil.rulesForStyle(s); +cssText += nativeShadow ? styleUtil.toCssText(rules, callback) : this.css(rules, element.is, element.extends, callback, element._scopeCssViaAttr) + "\n\n"; +} +return cssText.trim(); +}, +css: function(rules, scope, ext, callback, useAttr) { +var hostScope = this._calcHostScope(scope, ext); +scope = this._calcElementScope(scope, useAttr); +var self = this; +return styleUtil.toCssText(rules, function(rule) { +if (!rule.isScoped) { +self.rule(rule, scope, hostScope); +rule.isScoped = true; +} +if (callback) { +callback(rule, scope, hostScope); +} +}); +}, +_calcElementScope: function(scope, useAttr) { +if (scope) { +return useAttr ? CSS_ATTR_PREFIX + scope + CSS_ATTR_SUFFIX : CSS_CLASS_PREFIX + scope; +} else { +return ""; +} +}, +_calcHostScope: function(scope, ext) { +return ext ? "[is=" + scope + "]" : scope; +}, +rule: function(rule, scope, hostScope) { +this._transformRule(rule, this._transformComplexSelector, scope, hostScope); +}, +_transformRule: function(rule, transformer, scope, hostScope) { +var p$ = rule.selector.split(COMPLEX_SELECTOR_SEP); +for (var i = 0, l = p$.length, p; i < l && (p = p$[i]); i++) { +p$[i] = transformer.call(this, p, scope, hostScope); +} +rule.selector = p$.join(COMPLEX_SELECTOR_SEP); +}, +_transformComplexSelector: function(selector, scope, hostScope) { +var stop = false; +var self = this; +selector = selector.replace(SIMPLE_SELECTOR_SEP, function(m, c, s) { +if (!stop) { +var o = self._transformCompoundSelector(s, c, scope, hostScope); +if (o.stop) { +stop = true; +} +c = o.combinator; +s = o.value; +} +return c + s; +}); +return selector; +}, +_transformCompoundSelector: function(selector, combinator, scope, hostScope) { +var jumpIndex = selector.search(SCOPE_JUMP); +if (selector.indexOf(HOST) >= 0) { +selector = selector.replace(HOST_PAREN, function(m, host, paren) { +return hostScope + paren; +}); +selector = selector.replace(HOST, hostScope); +} else if (jumpIndex !== 0) { +selector = scope ? this._transformSimpleSelector(selector, scope) : selector; +} +if (selector.indexOf(CONTENT) >= 0) { +combinator = ""; +} +var stop; +if (jumpIndex >= 0) { +selector = selector.replace(SCOPE_JUMP, " "); +stop = true; +} +return { +value: selector, +combinator: combinator, +stop: stop +}; +}, +_transformSimpleSelector: function(selector, scope) { +var p$ = selector.split(PSEUDO_PREFIX); +p$[0] += scope; +return p$.join(PSEUDO_PREFIX); +}, +rootRule: function(rule) { +this._transformRule(rule, this._transformRootSelector); +}, +_transformRootSelector: function(selector) { +return selector.match(SCOPE_JUMP) ? this._transformComplexSelector(selector) : selector.trim() + SCOPE_ROOT_SELECTOR; +}, +SCOPE_NAME: "style-scope" +}; +var SCOPE_NAME = api.SCOPE_NAME; +var SCOPE_ROOT_SELECTOR = ":not([" + SCOPE_NAME + "])" + ":not(." + SCOPE_NAME + ")"; +var COMPLEX_SELECTOR_SEP = ","; +var SIMPLE_SELECTOR_SEP = /(^|[\s>+~]+)([^\s>+~]+)/g; +var HOST = ":host"; +var HOST_PAREN = /(\:host)(?:\(((?:\([^)(]*\)|[^)(]*)+?)\))/g; +var CONTENT = "::content"; +var SCOPE_JUMP = /\:\:content|\:\:shadow|\/deep\//; +var CSS_CLASS_PREFIX = "."; +var CSS_ATTR_PREFIX = "[" + SCOPE_NAME + "~="; +var CSS_ATTR_SUFFIX = "]"; +var PSEUDO_PREFIX = ":"; +var CLASS = "class"; +return api; +}(); + +Polymer.StyleExtends = function() { +var styleUtil = Polymer.StyleUtil; +return { +hasExtends: function(cssText) { +return Boolean(cssText.match(this.rx.EXTEND)); +}, +transform: function(style) { +var rules = styleUtil.rulesForStyle(style); +var self = this; +styleUtil.forEachStyleRule(rules, function(rule) { +var map = self._mapRule(rule); +if (rule.parent) { +var m; +while (m = self.rx.EXTEND.exec(rule.cssText)) { +var extend = m[1]; +var extendor = self._findExtendor(extend, rule); +if (extendor) { +self._extendRule(rule, extendor); +} +} +} +rule.cssText = rule.cssText.replace(self.rx.EXTEND, ""); +}); +return styleUtil.toCssText(rules, function(rule) { +if (rule.selector.match(self.rx.STRIP)) { +rule.cssText = ""; +} +}, true); +}, +_mapRule: function(rule) { +if (rule.parent) { +var map = rule.parent.map || (rule.parent.map = {}); +var parts = rule.selector.split(","); +for (var i = 0, p; i < parts.length; i++) { +p = parts[i]; +map[p.trim()] = rule; +} +return map; +} +}, +_findExtendor: function(extend, rule) { +return rule.parent && rule.parent.map && rule.parent.map[extend] || this._findExtendor(extend, rule.parent); +}, +_extendRule: function(target, source) { +if (target.parent !== source.parent) { +this._cloneAndAddRuleToParent(source, target.parent); +} +target.extends = target.extends || (target.extends = []); +target.extends.push(source); +source.selector = source.selector.replace(this.rx.STRIP, ""); +source.selector = (source.selector && source.selector + ",\n") + target.selector; +if (source.extends) { +source.extends.forEach(function(e) { +this._extendRule(target, e); +}, this); +} +}, +_cloneAndAddRuleToParent: function(rule, parent) { +rule = Object.create(rule); +rule.parent = parent; +if (rule.extends) { +rule.extends = rule.extends.slice(); +} +parent.rules.push(rule); +}, +rx: { +EXTEND: /@extends\(([^)]*)\)\s*?;/gim, +STRIP: /%[^,]*$/ +} +}; +}(); + +(function() { +var prepElement = Polymer.Base._prepElement; +var nativeShadow = Polymer.Settings.useNativeShadow; +var styleUtil = Polymer.StyleUtil; +var styleTransformer = Polymer.StyleTransformer; +var styleExtends = Polymer.StyleExtends; +Polymer.Base._addFeature({ +_prepElement: function(element) { +if (this._encapsulateStyle) { +styleTransformer.element(element, this.is, this._scopeCssViaAttr); +} +prepElement.call(this, element); +}, +_prepStyles: function() { +if (this._encapsulateStyle === undefined) { +this._encapsulateStyle = !nativeShadow && Boolean(this._template); +} +this._styles = this._collectStyles(); +var cssText = styleTransformer.elementStyles(this); +if (cssText && this._template) { +var style = styleUtil.applyCss(cssText, this.is, nativeShadow ? this._template.content : null); +if (!nativeShadow) { +this._scopeStyle = style; +} +} +}, +_collectStyles: function() { +var styles = []; +var cssText = "", m$ = this.styleModules; +if (m$) { +for (var i = 0, l = m$.length, m; i < l && (m = m$[i]); i++) { +cssText += styleUtil.cssFromModule(m); +} +} +cssText += styleUtil.cssFromModule(this.is); +if (cssText) { +var style = document.createElement("style"); +style.textContent = cssText; +if (styleExtends.hasExtends(style.textContent)) { +cssText = styleExtends.transform(style); +} +styles.push(style); +} +return styles; +}, +_elementAdd: function(node) { +if (this._encapsulateStyle && !node.__styleScoped) { +styleTransformer.dom(node, this.is, this._scopeCssViaAttr); +} +}, +_elementRemove: function(node) { +if (this._encapsulateStyle) { +styleTransformer.dom(node, this.is, this._scopeCssViaAttr, true); +} +}, +scopeSubtree: function(container, shouldObserve) { +if (nativeShadow) { +return; +} +var self = this; +var scopify = function(node) { +if (node.nodeType === Node.ELEMENT_NODE) { +node.className = self._scopeElementClass(node, node.className); +var n$ = node.querySelectorAll("*"); +Array.prototype.forEach.call(n$, function(n) { +n.className = self._scopeElementClass(n, n.className); +}); +} +}; +scopify(container); +if (shouldObserve) { +var mo = new MutationObserver(function(mxns) { +mxns.forEach(function(m) { +if (m.addedNodes) { +for (var i = 0; i < m.addedNodes.length; i++) { +scopify(m.addedNodes[i]); +} +} +}); +}); +mo.observe(container, { +childList: true, +subtree: true +}); +return mo; +} +} +}); +})(); + +Polymer.StyleProperties = function() { +var nativeShadow = Polymer.Settings.useNativeShadow; +var matchesSelector = Polymer.DomApi.matchesSelector; +var styleUtil = Polymer.StyleUtil; +var styleTransformer = Polymer.StyleTransformer; +return { +decorateStyles: function(styles) { +var self = this, props = {}; +styleUtil.forRulesInStyles(styles, function(rule) { +self.decorateRule(rule); +self.collectPropertiesInCssText(rule.propertyInfo.cssText, props); +}); +var names = []; +for (var i in props) { +names.push(i); +} +return names; +}, +decorateRule: function(rule) { +if (rule.propertyInfo) { +return rule.propertyInfo; +} +var info = {}, properties = {}; +var hasProperties = this.collectProperties(rule, properties); +if (hasProperties) { +info.properties = properties; +rule.rules = null; +} +info.cssText = this.collectCssText(rule); +rule.propertyInfo = info; +return info; +}, +collectProperties: function(rule, properties) { +var info = rule.propertyInfo; +if (info) { +if (info.properties) { +Polymer.Base.mixin(properties, info.properties); +return true; +} +} else { +var m, rx = this.rx.VAR_ASSIGN; +var cssText = rule.parsedCssText; +var any; +while (m = rx.exec(cssText)) { +properties[m[1]] = (m[2] || m[3]).trim(); +any = true; +} +return any; +} +}, +collectCssText: function(rule) { +var customCssText = ""; +var cssText = rule.parsedCssText; +cssText = cssText.replace(this.rx.BRACKETED, "").replace(this.rx.VAR_ASSIGN, ""); +var parts = cssText.split(";"); +for (var i = 0, p; i < parts.length; i++) { +p = parts[i]; +if (p.match(this.rx.MIXIN_MATCH) || p.match(this.rx.VAR_MATCH)) { +customCssText += p + ";\n"; +} +} +return customCssText; +}, +collectPropertiesInCssText: function(cssText, props) { +var m; +while (m = this.rx.VAR_CAPTURE.exec(cssText)) { +props[m[1]] = true; +} +}, +reify: function(props) { +var names = Object.getOwnPropertyNames(props); +for (var i = 0, n; i < names.length; i++) { +n = names[i]; +props[n] = this.valueForProperty(props[n], props); +} +}, +valueForProperty: function(property, props) { +if (property) { +if (property.indexOf(";") >= 0) { +property = this.valueForProperties(property, props); +} else { +var self = this; +var fn = function(all, prefix, value, fallback) { +var propertyValue = self.valueForProperty(props[value], props) || (props[fallback] ? self.valueForProperty(props[fallback], props) : fallback); +return prefix + (propertyValue || ""); +}; +property = property.replace(this.rx.VAR_MATCH, fn); +} +} +return property && property.trim() || ""; +}, +valueForProperties: function(property, props) { +var parts = property.split(";"); +for (var i = 0, p, m; i < parts.length && (p = parts[i]); i++) { +m = p.match(this.rx.MIXIN_MATCH); +if (m) { +p = this.valueForProperty(props[m[1]], props); +} else { +var pp = p.split(":"); +if (pp[1]) { +pp[1] = pp[1].trim(); +pp[1] = this.valueForProperty(pp[1], props) || pp[1]; +} +p = pp.join(":"); +} +parts[i] = p && p.lastIndexOf(";") === p.length - 1 ? p.slice(0, -1) : p || ""; +} +return parts.join(";"); +}, +applyProperties: function(rule, props) { +var output = ""; +if (!rule.properties) { +this.decorateRule(rule); +} +if (rule.propertyInfo.cssText) { +output = this.valueForProperties(rule.propertyInfo.cssText, props); +} +rule.cssText = output; +}, +propertyDataFromStyles: function(styles, element) { +var props = {}, self = this; +var o = [], i = 0; +styleUtil.forRulesInStyles(styles, function(rule) { +if (!rule.propertyInfo) { +self.decorateRule(rule); +} +if (element && rule.propertyInfo.properties && matchesSelector.call(element, rule.selector)) { +self.collectProperties(rule, props); +addToBitMask(i, o); +} +i++; +}); +return { +properties: props, +key: o +}; +}, +scopePropertiesFromStyles: function(styles) { +if (!styles._scopeStyleProperties) { +styles._scopeStyleProperties = this.selectedPropertiesFromStyles(styles, this.SCOPE_SELECTORS); +} +return styles._scopeStyleProperties; +}, +hostPropertiesFromStyles: function(styles) { +if (!styles._hostStyleProperties) { +styles._hostStyleProperties = this.selectedPropertiesFromStyles(styles, this.HOST_SELECTORS); +} +return styles._hostStyleProperties; +}, +selectedPropertiesFromStyles: function(styles, selectors) { +var props = {}, self = this; +styleUtil.forRulesInStyles(styles, function(rule) { +if (!rule.propertyInfo) { +self.decorateRule(rule); +} +for (var i = 0; i < selectors.length; i++) { +if (rule.parsedSelector === selectors[i]) { +self.collectProperties(rule, props); +return; +} +} +}); +return props; +}, +transformStyles: function(element, properties, scopeSelector) { +var self = this; +var hostRx = new RegExp(this.rx.HOST_PREFIX + element.is + this.rx.HOST_SUFFIX); +return styleTransformer.elementStyles(element, function(rule) { +self.applyProperties(rule, properties); +if (rule.cssText && !nativeShadow) { +self._scopeSelector(rule, hostRx, element.is, element._scopeCssViaAttr, scopeSelector); +} +}); +}, +_scopeSelector: function(rule, hostRx, is, viaAttr, scopeId) { +rule.transformedSelector = rule.transformedSelector || rule.selector; +var selector = rule.transformedSelector; +var scope = viaAttr ? "[" + styleTransformer.SCOPE_NAME + "~=" + scopeId + "]" : "." + scopeId; +var parts = selector.split(","); +for (var i = 0, l = parts.length, p; i < l && (p = parts[i]); i++) { +parts[i] = p.match(hostRx) ? p.replace(is, is + scope) : scope + " " + p; +} +rule.selector = parts.join(","); +}, +applyElementScopeSelector: function(element, selector, old, viaAttr) { +var c = viaAttr ? element.getAttribute(styleTransformer.SCOPE_NAME) : element.className; +v = old ? c.replace(old, selector) : (c ? c + " " : "") + this.XSCOPE_NAME + " " + selector; +if (c !== v) { +if (viaAttr) { +element.setAttribute(styleTransformer.SCOPE_NAME, v); +} else { +element.className = v; +} +} +}, +applyElementStyle: function(element, properties, selector, style) { +var cssText = style ? style.textContent || "" : this.transformStyles(element, properties, selector); +var s = element._customStyle; +if (s && !nativeShadow && s !== style) { +s._useCount--; +if (s._useCount <= 0) { +s.parentNode.removeChild(s); +} +} +if (nativeShadow || (!style || !style.parentNode)) { +if (nativeShadow && element._customStyle) { +element._customStyle.textContent = cssText; +style = element._customStyle; +} else if (cssText) { +style = styleUtil.applyCss(cssText, selector, nativeShadow ? element.root : null, element._scopeStyle); +} +} +if (style) { +style._useCount = style._useCount || 0; +if (element._customStyle != style) { +style._useCount++; +} +element._customStyle = style; +} +return style; +}, +rx: { +VAR_ASSIGN: /(?:^|;\s*)(--[^\:;]*?):\s*?(?:([^;{]*?)|{([^}]*)})(?=;)/gim, +MIXIN_MATCH: /(?:^|\W+)@apply[\s]*\(([^)]*)\);?/im, +VAR_MATCH: /(^|\W+)var\([\s]*([^,)]*)[\s]*,?[\s]*((?:[^,)]*)|(?:[^;]*\([^;)]*\)))[\s]*?\)/gim, +VAR_CAPTURE: /\([\s]*(--[^,\s)]*)(?:,[\s]*(--[^,\s)]*))?(?:\)|,)/gim, +BRACKETED: /\{[^}]*\}/g, +HOST_PREFIX: "(?:^|[^.])", +HOST_SUFFIX: "($|[.:[\\s>+~])" +}, +HOST_SELECTORS: [ ":host" ], +SCOPE_SELECTORS: [ ":root" ], +XSCOPE_NAME: "x-scope" +}; +function addToBitMask(n, bits) { +var o = parseInt(n / 32); +var v = 1 << n % 32; +bits[o] = (bits[o] || 0) | v; +} +}(); + +Polymer.StyleDefaults = function() { +var styleProperties = Polymer.StyleProperties; +var styleUtil = Polymer.StyleUtil; +var style = document.createElement("style"); +var api = { +style: style, +_styles: [ style ], +_properties: null, +applyCss: function(cssText) { +this.style.textContent += cssText; +styleUtil.clearStyleRules(this.style); +this._properties = null; +}, +get _styleProperties() { +if (!this._properties) { +styleProperties.decorateStyles(this._styles); +this._styles._scopeStyleProperties = null; +this._properties = styleProperties.scopePropertiesFromStyles(this._styles); +} +return this._properties; +}, +_needsStyleProperties: function() {}, +_computeStyleProperties: function() { +return this._styleProperties; +} +}; +return api; +}(); + +(function() { +Polymer.StyleCache = function() { +this.cache = {}; +}; +Polymer.StyleCache.prototype = { +MAX: 100, +store: function(is, data, keyValues, keyStyles) { +data.keyValues = keyValues; +data.styles = keyStyles; +var s$ = this.cache[is] = this.cache[is] || []; +s$.push(data); +if (s$.length > this.MAX) { +s$.shift(); +} +}, +retrieve: function(is, keyValues, keyStyles) { +var cache = this.cache[is]; +if (cache) { +for (var i = cache.length - 1, data; i >= 0; i--) { +data = cache[i]; +if (keyStyles === data.styles && this._objectsEqual(keyValues, data.keyValues)) { +return data; +} +} +} +}, +clear: function() { +this.cache = {}; +}, +_objectsEqual: function(target, source) { +for (var i in target) { +if (target[i] !== source[i]) { +return false; +} +} +if (Array.isArray(target)) { +return target.length === source.length; +} +return true; +} +}; +})(); + +(function() { +var serializeValueToAttribute = Polymer.Base.serializeValueToAttribute; +var propertyUtils = Polymer.StyleProperties; +var styleTransformer = Polymer.StyleTransformer; +var styleUtil = Polymer.StyleUtil; +var styleDefaults = Polymer.StyleDefaults; +var nativeShadow = Polymer.Settings.useNativeShadow; +Polymer.Base._addFeature({ +_prepStyleProperties: function() { +this._ownStylePropertyNames = this._styles ? propertyUtils.decorateStyles(this._styles) : []; +}, +_setupStyleProperties: function() { +this.customStyle = {}; +}, +_needsStyleProperties: function() { +return Boolean(this._ownStylePropertyNames && this._ownStylePropertyNames.length); +}, +_beforeAttached: function() { +if (!this._scopeSelector && this._needsStyleProperties()) { +this._updateStyleProperties(); +} +}, +_updateStyleProperties: function() { +var info, scope = this.domHost || styleDefaults; +if (!scope._styleCache) { +scope._styleCache = new Polymer.StyleCache(); +} +var scopeData = propertyUtils.propertyDataFromStyles(scope._styles, this); +info = scope._styleCache.retrieve(this.is, scopeData.key, this._styles); +var scopeCached = Boolean(info); +if (scopeCached) { +this._styleProperties = info._styleProperties; +} else { +this._computeStyleProperties(scopeData.properties); +} +this._computeOwnStyleProperties(); +if (!scopeCached) { +info = styleCache.retrieve(this.is, this._ownStyleProperties, this._styles); +} +var globalCached = Boolean(info) && !scopeCached; +style = this._applyStyleProperties(info); +if (!scopeCached) { +var cacheableStyle = style; +if (nativeShadow) { +cacheableStyle = style.cloneNode ? style.cloneNode(true) : Object.create(style || null); +} +info = { +style: cacheableStyle, +_scopeSelector: this._scopeSelector, +_styleProperties: this._styleProperties +}; +scope._styleCache.store(this.is, info, scopeData.key, this._styles); +if (!globalCached) { +styleCache.store(this.is, Object.create(info), this._ownStyleProperties, this._styles); +} +} +}, +_computeStyleProperties: function(scopeProps) { +var scope = this.domHost || styleDefaults; +if (!scope._styleProperties) { +scope._computeStyleProperties(); +} +var props = Object.create(scope._styleProperties); +this.mixin(props, propertyUtils.hostPropertiesFromStyles(this._styles)); +scopeProps = scopeProps || propertyUtils.propertyDataFromStyles(scope._styles, this).properties; +this.mixin(props, scopeProps); +this.mixin(props, propertyUtils.scopePropertiesFromStyles(this._styles)); +this.mixin(props, this.customStyle); +propertyUtils.reify(props); +this._styleProperties = props; +}, +_computeOwnStyleProperties: function() { +var props = {}; +for (var i = 0, n; i < this._ownStylePropertyNames.length; i++) { +n = this._ownStylePropertyNames[i]; +props[n] = this._styleProperties[n]; +} +this._ownStyleProperties = props; +}, +_scopeCount: 0, +_applyStyleProperties: function(info) { +var oldScopeSelector = this._scopeSelector; +this._scopeSelector = info ? info._scopeSelector : this.is + "-" + this.__proto__._scopeCount++; +style = propertyUtils.applyElementStyle(this, this._styleProperties, this._scopeSelector, info && info.style); +if ((style || oldScopeSelector) && !nativeShadow) { +propertyUtils.applyElementScopeSelector(this, this._scopeSelector, oldScopeSelector, this._scopeCssViaAttr); +} +return style || {}; +}, +serializeValueToAttribute: function(value, attribute, node) { +node = node || this; +if (attribute === "class") { +var host = node === this ? this.domHost || this.dataHost : this; +if (host) { +value = host._scopeElementClass(node, value); +} +} +node = Polymer.dom(node); +serializeValueToAttribute.call(this, value, attribute, node); +}, +_scopeElementClass: function(element, selector) { +if (!nativeShadow && !this._scopeCssViaAttr) { +selector += (selector ? " " : "") + SCOPE_NAME + " " + this.is + (element._scopeSelector ? " " + XSCOPE_NAME + " " + element._scopeSelector : ""); +} +return selector; +}, +updateStyles: function() { +if (this.isAttached) { +if (this._needsStyleProperties()) { +this._updateStyleProperties(); +} else { +this._styleProperties = null; +} +if (this._styleCache) { +this._styleCache.clear(); +} +this._updateRootStyles(); +} +}, +_updateRootStyles: function(root) { +root = root || this.root; +var c$ = Polymer.dom(root)._query(function(e) { +return e.shadyRoot || e.shadowRoot; +}); +for (var i = 0, l = c$.length, c; i < l && (c = c$[i]); i++) { +if (c.updateStyles) { +c.updateStyles(); +} +} +} +}); +Polymer.updateStyles = function() { +styleDefaults._styleCache.clear(); +Polymer.Base._updateRootStyles(document); +}; +var styleCache = new Polymer.StyleCache(); +Polymer.customStyleCache = styleCache; +var SCOPE_NAME = styleTransformer.SCOPE_NAME; +var XSCOPE_NAME = propertyUtils.XSCOPE_NAME; +})(); + +Polymer.Base._addFeature({ +_registerFeatures: function() { +this._prepIs(); +this._prepAttributes(); +this._prepExtends(); +this._prepConstructor(); +this._prepTemplate(); +this._prepStyles(); +this._prepStyleProperties(); +this._prepAnnotations(); +this._prepEffects(); +this._prepBehaviors(); +this._prepBindings(); +this._prepShady(); +}, +_prepBehavior: function(b) { +this._addPropertyEffects(b.properties); +this._addComplexObserverEffects(b.observers); +this._addHostAttributes(b.hostAttributes); +}, +_initFeatures: function() { +this._poolContent(); +this._setupConfigure(); +this._setupStyleProperties(); +this._pushHost(); +this._stampTemplate(); +this._popHost(); +this._marshalAnnotationReferences(); +this._marshalHostAttributes(); +this._setupDebouncers(); +this._marshalInstanceEffects(); +this._marshalBehaviors(); +this._marshalAttributes(); +this._tryReady(); +}, +_marshalBehavior: function(b) { +this._listenListeners(b.listeners); +} +}); + +(function() { +var nativeShadow = Polymer.Settings.useNativeShadow; +var propertyUtils = Polymer.StyleProperties; +var styleUtil = Polymer.StyleUtil; +var styleDefaults = Polymer.StyleDefaults; +Polymer({ +is: "custom-style", +"extends": "style", +created: function() { +this._appliesToDocument = this.parentNode.localName !== "dom-module"; +if (this._appliesToDocument) { +var e = this.__appliedElement || this; +var rules = styleUtil.rulesForStyle(e); +propertyUtils.decorateStyles([ e ]); +this._rulesToDefaultProperties(rules); +this.async(this._applyStyle); +} +}, +_applyStyle: function() { +var e = this.__appliedElement || this; +this._computeStyleProperties(); +var props = this._styleProperties; +var self = this; +e.textContent = styleUtil.toCssText(styleUtil.rulesForStyle(e), function(rule) { +if (rule.selector === ":root") { +rule.selector = "body"; +} +var css = rule.cssText = rule.parsedCssText; +if (rule.propertyInfo.cssText) { +css = css.replace(propertyUtils.rx.VAR_ASSIGN, ""); +rule.cssText = propertyUtils.valueForProperties(css, props); +} +if (!nativeShadow) { +Polymer.StyleTransformer.rootRule(rule); +} +}); +}, +_rulesToDefaultProperties: function(rules) { +styleUtil.forEachStyleRule(rules, function(rule) { +if (!rule.propertyInfo.properties) { +rule.cssText = ""; +} +}); +var cssText = styleUtil.parser.stringify(rules, true); +if (cssText) { +styleDefaults.applyCss(cssText); +} +} +}); +})(); + +Polymer.Templatizer = { +properties: { +_hideTemplateChildren: { +observer: "_hideTemplateChildrenChanged" +} +}, +_templatizerStatic: { +count: 0, +callbacks: {}, +debouncer: null +}, +_instanceProps: Polymer.nob, +created: function() { +this._templatizerId = this._templatizerStatic.count++; +}, +templatize: function(template) { +if (!template._content) { +template._content = template.content; +} +if (template._content._ctor) { +this.ctor = template._content._ctor; +this._prepParentProperties(this.ctor.prototype, template); +return; +} +var archetype = Object.create(Polymer.Base); +this._customPrepAnnotations(archetype, template); +archetype._prepEffects(); +this._customPrepEffects(archetype); +archetype._prepBehaviors(); +archetype._prepBindings(); +this._prepParentProperties(archetype, template); +archetype._notifyPath = this._notifyPathImpl; +archetype._scopeElementClass = this._scopeElementClassImpl; +archetype.listen = this._listenImpl; +var _constructor = this._constructorImpl; +var ctor = function TemplateInstance(model, host) { +_constructor.call(this, model, host); +}; +ctor.prototype = archetype; +archetype.constructor = ctor; +template._content._ctor = ctor; +this.ctor = ctor; +}, +_getRootDataHost: function() { +return this.dataHost && this.dataHost._rootDataHost || this.dataHost; +}, +_hideTemplateChildrenChanged: function(hidden) { +if (this._hideChildren) { +this._hideChildren(hidden); +} +}, +_debounceTemplate: function(fn) { +this._templatizerStatic.callbacks[this._templatizerId] = fn.bind(this); +this._templatizerStatic.debouncer = Polymer.Debounce(this._templatizerStatic.debouncer, this._flushTemplates.bind(this, true)); +}, +_flushTemplates: function(debouncerExpired) { +var db = this._templatizerStatic.debouncer; +while (debouncerExpired || db && db.finish) { +db.stop(); +var cbs = this._templatizerStatic.callbacks; +this._templatizerStatic.callbacks = {}; +for (var id in cbs) { +cbs[id](); +} +debouncerExpired = false; +} +}, +_customPrepEffects: function(archetype) { +var parentProps = archetype._parentProps; +for (var prop in parentProps) { +archetype._addPropertyEffect(prop, "function", this._createHostPropEffector(prop)); +} +}, +_customPrepAnnotations: function(archetype, template) { +archetype._template = template; +var c = template._content; +if (!c._notes) { +var rootDataHost = archetype._rootDataHost; +if (rootDataHost) { +Polymer.Annotations.prepElement = rootDataHost._prepElement.bind(rootDataHost); +} +c._notes = Polymer.Annotations.parseAnnotations(template); +Polymer.Annotations.prepElement = null; +this._processAnnotations(c._notes); +} +archetype._notes = c._notes; +archetype._parentProps = c._parentProps; +}, +_prepParentProperties: function(archetype, template) { +var parentProps = this._parentProps = archetype._parentProps; +if (this._forwardParentProp && parentProps) { +var proto = archetype._parentPropProto; +var prop; +if (!proto) { +for (prop in this._instanceProps) { +delete parentProps[prop]; +} +proto = archetype._parentPropProto = Object.create(null); +if (template != this) { +Polymer.Bind.prepareModel(proto); +} +for (prop in parentProps) { +var parentProp = "_parent_" + prop; +var effects = [ { +kind: "function", +effect: this._createForwardPropEffector(prop) +}, { +kind: "notify" +} ]; +Polymer.Bind._createAccessors(proto, parentProp, effects); +} +} +if (template != this) { +Polymer.Bind.prepareInstance(template); +template._forwardParentProp = this._forwardParentProp.bind(this); +} +this._extendTemplate(template, proto); +} +}, +_createForwardPropEffector: function(prop) { +return function(source, value) { +this._forwardParentProp(prop, value); +}; +}, +_createHostPropEffector: function(prop) { +return function(source, value) { +this.dataHost["_parent_" + prop] = value; +}; +}, +_extendTemplate: function(template, proto) { +Object.getOwnPropertyNames(proto).forEach(function(n) { +var val = template[n]; +var pd = Object.getOwnPropertyDescriptor(proto, n); +Object.defineProperty(template, n, pd); +if (val !== undefined) { +template._propertySet(n, val); +} +}); +}, +_forwardInstancePath: function(inst, path, value) {}, +_notifyPathImpl: function(path, value) { +var dataHost = this.dataHost; +var dot = path.indexOf("."); +var root = dot < 0 ? path : path.slice(0, dot); +dataHost._forwardInstancePath.call(dataHost, this, path, value); +if (root in dataHost._parentProps) { +dataHost.notifyPath("_parent_" + path, value); +} +}, +_pathEffector: function(path, value, fromAbove) { +if (this._forwardParentPath) { +if (path.indexOf("_parent_") === 0) { +this._forwardParentPath(path.substring(8), value); +} +} +Polymer.Base._pathEffector.apply(this, arguments); +}, +_constructorImpl: function(model, host) { +this._rootDataHost = host._getRootDataHost(); +this._setupConfigure(model); +this._pushHost(host); +this.root = this.instanceTemplate(this._template); +this.root.__styleScoped = true; +this._popHost(); +this._marshalAnnotatedNodes(); +this._marshalInstanceEffects(); +this._marshalAnnotatedListeners(); +var children = []; +for (var n = this.root.firstChild; n; n = n.nextSibling) { +children.push(n); +n._templateInstance = this; +} +this._children = children; +this._tryReady(); +}, +_listenImpl: function(node, eventName, methodName) { +var model = this; +var host = this._rootDataHost; +var handler = host._createEventHandler(node, eventName, methodName); +var decorated = function(e) { +e.model = model; +handler(e); +}; +host._listen(node, eventName, decorated); +}, +_scopeElementClassImpl: function(node, value) { +var host = this._rootDataHost; +if (host) { +return host._scopeElementClass(node, value); +} +}, +stamp: function(model) { +model = model || {}; +if (this._parentProps) { +for (var prop in this._parentProps) { +model[prop] = this["_parent_" + prop]; +} +} +return new this.ctor(model, this); +} +}; + +Polymer({ +is: "dom-template", +"extends": "template", +behaviors: [ Polymer.Templatizer ], +ready: function() { +this.templatize(this); +} +}); + +Polymer._collections = new WeakMap(); + +Polymer.Collection = function(userArray) { +Polymer._collections.set(userArray, this); +this.userArray = userArray; +this.store = userArray.slice(); +this.initMap(); +}; + +Polymer.Collection.prototype = { +constructor: Polymer.Collection, +initMap: function() { +var omap = this.omap = new WeakMap(); +var pmap = this.pmap = {}; +var s = this.store; +for (var i = 0; i < s.length; i++) { +var item = s[i]; +if (item && typeof item == "object") { +omap.set(item, i); +} else { +pmap[item] = i; +} +} +}, +add: function(item) { +var key = this.store.push(item) - 1; +if (item && typeof item == "object") { +this.omap.set(item, key); +} else { +this.pmap[item] = key; +} +return key; +}, +removeKey: function(key) { +this._removeFromMap(this.store[key]); +delete this.store[key]; +}, +_removeFromMap: function(item) { +if (typeof item == "object") { +this.omap.delete(item); +} else { +delete this.pmap[item]; +} +}, +remove: function(item) { +var key = this.getKey(item); +this.removeKey(key); +return key; +}, +getKey: function(item) { +if (typeof item == "object") { +return this.omap.get(item); +} else { +return this.pmap[item]; +} +}, +getKeys: function() { +return Object.keys(this.store); +}, +setItem: function(key, value) { +this.store[key] = value; +}, +getItem: function(key) { +return this.store[key]; +}, +getItems: function() { +var items = [], store = this.store; +for (var key in store) { +items.push(store[key]); +} +return items; +}, +applySplices: function(splices) { +var keySplices = []; +for (var i = 0; i < splices.length; i++) { +var j, o, key, s = splices[i]; +var removed = []; +for (j = 0; j < s.removed.length; j++) { +o = s.removed[j]; +key = this.remove(o); +removed.push(key); +} +var added = []; +for (j = 0; j < s.addedCount; j++) { +o = this.userArray[s.index + j]; +key = this.add(o); +added.push(key); +} +keySplices.push({ +index: s.index, +removed: removed, +removedItems: s.removed, +added: added +}); +} +return keySplices; +} +}; + +Polymer.Collection.get = function(userArray) { +return Polymer._collections.get(userArray) || new Polymer.Collection(userArray); +}; + +Polymer({ +is: "dom-repeat", +"extends": "template", +properties: { +items: { +type: Array +}, +as: { +type: String, +value: "item" +}, +indexAs: { +type: String, +value: "index" +}, +sort: { +type: Function, +observer: "_sortChanged" +}, +filter: { +type: Function, +observer: "_filterChanged" +}, +observe: { +type: String, +observer: "_observeChanged" +}, +delay: Number +}, +behaviors: [ Polymer.Templatizer ], +observers: [ "_itemsChanged(items.*)" ], +detached: function() { +if (this.rows) { +for (var i = 0; i < this.rows.length; i++) { +this._detachRow(i); +} +} +this.rows = null; +}, +ready: function() { +this._instanceProps = { +__key__: true +}; +this._instanceProps[this.as] = true; +this._instanceProps[this.indexAs] = true; +if (!this.ctor) { +this.templatize(this); +} +}, +_sortChanged: function() { +var dataHost = this._getRootDataHost(); +var sort = this.sort; +this._sortFn = sort && (typeof sort == "function" ? sort : function() { +return dataHost[sort].apply(dataHost, arguments); +}); +this._fullRefresh = true; +if (this.items) { +this._debounceTemplate(this._render); +} +}, +_filterChanged: function() { +var dataHost = this._getRootDataHost(); +var filter = this.filter; +this._filterFn = filter && (typeof filter == "function" ? filter : function() { +return dataHost[filter].apply(dataHost, arguments); +}); +this._fullRefresh = true; +if (this.items) { +this._debounceTemplate(this._render); +} +}, +_observeChanged: function() { +this._observePaths = this.observe && this.observe.replace(".*", ".").split(" "); +}, +_itemsChanged: function(change) { +if (change.path == "items") { +if (Array.isArray(this.items)) { +this.collection = Polymer.Collection.get(this.items); +} else if (!this.items) { +this.collection = null; +} else { +this._error(this._logf("dom-repeat", "expected array for `items`," + " found", this.items)); +} +this._splices = []; +this._fullRefresh = true; +this._debounceTemplate(this._render); +} else if (change.path == "items.splices") { +this._splices = this._splices.concat(change.value.keySplices); +this._debounceTemplate(this._render); +} else { +var subpath = change.path.slice(6); +this._forwardItemPath(subpath, change.value); +this._checkObservedPaths(subpath); +} +}, +_checkObservedPaths: function(path) { +if (this._observePaths) { +path = path.substring(path.indexOf(".") + 1); +var paths = this._observePaths; +for (var i = 0; i < paths.length; i++) { +if (path.indexOf(paths[i]) === 0) { +this._fullRefresh = true; +if (this.delay) { +this.debounce("render", this._render, this.delay); +} else { +this._debounceTemplate(this._render); +} +return; +} +} +} +}, +render: function() { +this._fullRefresh = true; +this.debounce("render", this._render); +this._flushTemplates(); +}, +_render: function() { +var c = this.collection; +if (!this._fullRefresh) { +if (this._sortFn) { +this._applySplicesViewSort(this._splices); +} else { +if (this._filterFn) { +this._fullRefresh = true; +} else { +this._applySplicesArraySort(this._splices); +} +} +} +if (this._fullRefresh) { +this._sortAndFilter(); +this._fullRefresh = false; +} +this._splices = []; +var rowForKey = this._rowForKey = {}; +var keys = this._orderedKeys; +this.rows = this.rows || []; +for (var i = 0; i < keys.length; i++) { +var key = keys[i]; +var item = c.getItem(key); +var row = this.rows[i]; +rowForKey[key] = i; +if (!row) { +this.rows.push(row = this._insertRow(i, null, item)); +} +row[this.as] = item; +row.__key__ = key; +row[this.indexAs] = i; +} +for (;i < this.rows.length; i++) { +this._detachRow(i); +} +this.rows.splice(keys.length, this.rows.length - keys.length); +this.fire("dom-change"); +}, +_sortAndFilter: function() { +var c = this.collection; +if (!this._sortFn) { +this._orderedKeys = []; +var items = this.items; +if (items) { +for (var i = 0; i < items.length; i++) { +this._orderedKeys.push(c.getKey(items[i])); +} +} +} else { +this._orderedKeys = c ? c.getKeys() : []; +} +if (this._filterFn) { +this._orderedKeys = this._orderedKeys.filter(function(a) { +return this._filterFn(c.getItem(a)); +}, this); +} +if (this._sortFn) { +this._orderedKeys.sort(function(a, b) { +return this._sortFn(c.getItem(a), c.getItem(b)); +}.bind(this)); +} +}, +_keySort: function(a, b) { +return this.collection.getKey(a) - this.collection.getKey(b); +}, +_applySplicesViewSort: function(splices) { +var c = this.collection; +var keys = this._orderedKeys; +var rows = this.rows; +var removedRows = []; +var addedKeys = []; +var pool = []; +var sortFn = this._sortFn || this._keySort.bind(this); +splices.forEach(function(s) { +for (var i = 0; i < s.removed.length; i++) { +var idx = this._rowForKey[s.removed[i]]; +if (idx != null) { +removedRows.push(idx); +} +} +for (var i = 0; i < s.added.length; i++) { +addedKeys.push(s.added[i]); +} +}, this); +if (removedRows.length) { +removedRows.sort(); +for (var i = removedRows.length - 1; i >= 0; i--) { +var idx = removedRows[i]; +pool.push(this._detachRow(idx)); +rows.splice(idx, 1); +keys.splice(idx, 1); +} +} +if (addedKeys.length) { +if (this._filterFn) { +addedKeys = addedKeys.filter(function(a) { +return this._filterFn(c.getItem(a)); +}, this); +} +addedKeys.sort(function(a, b) { +return this._sortFn(c.getItem(a), c.getItem(b)); +}.bind(this)); +var start = 0; +for (var i = 0; i < addedKeys.length; i++) { +start = this._insertRowIntoViewSort(start, addedKeys[i], pool); +} +} +}, +_insertRowIntoViewSort: function(start, key, pool) { +var c = this.collection; +var item = c.getItem(key); +var end = this.rows.length - 1; +var idx = -1; +var sortFn = this._sortFn || this._keySort.bind(this); +while (start <= end) { +var mid = start + end >> 1; +var midKey = this._orderedKeys[mid]; +var cmp = sortFn(c.getItem(midKey), item); +if (cmp < 0) { +start = mid + 1; +} else if (cmp > 0) { +end = mid - 1; +} else { +idx = mid; +break; +} +} +if (idx < 0) { +idx = end + 1; +} +this._orderedKeys.splice(idx, 0, key); +this.rows.splice(idx, 0, this._insertRow(idx, pool, c.getItem(key))); +return idx; +}, +_applySplicesArraySort: function(splices) { +var keys = this._orderedKeys; +var pool = []; +splices.forEach(function(s) { +for (var i = 0; i < s.removed.length; i++) { +pool.push(this._detachRow(s.index + i)); +} +this.rows.splice(s.index, s.removed.length); +}, this); +var c = this.collection; +splices.forEach(function(s) { +var args = [ s.index, s.removed.length ].concat(s.added); +keys.splice.apply(keys, args); +for (var i = 0; i < s.added.length; i++) { +var item = c.getItem(s.added[i]); +var row = this._insertRow(s.index + i, pool, item); +this.rows.splice(s.index + i, 0, row); +} +}, this); +}, +_detachRow: function(idx) { +var row = this.rows[idx]; +var parentNode = Polymer.dom(this).parentNode; +for (var i = 0; i < row._children.length; i++) { +var el = row._children[i]; +Polymer.dom(row.root).appendChild(el); +} +return row; +}, +_insertRow: function(idx, pool, item) { +var row = pool && pool.pop() || this._generateRow(idx, item); +var beforeRow = this.rows[idx]; +var beforeNode = beforeRow ? beforeRow._children[0] : this; +var parentNode = Polymer.dom(this).parentNode; +Polymer.dom(parentNode).insertBefore(row.root, beforeNode); +return row; +}, +_generateRow: function(idx, item) { +var model = { +__key__: this.collection.getKey(item) +}; +model[this.as] = item; +model[this.indexAs] = idx; +var row = this.stamp(model); +return row; +}, +_hideChildren: function(hidden) { +if (this.rows) { +for (var i = 0; i < this.rows.length; i++) { +var c$ = this.rows[i]._children; +for (var j = 0; j < c$.length; j++) { +var c = c$[j]; +if (c.style) { +c.style.display = hidden ? "none" : ""; +} +c._hideTemplateChildren = hidden; +} +} +} +}, +_forwardInstancePath: function(row, path, value) { +if (path.indexOf(this.as + ".") === 0) { +this.notifyPath("items." + row.__key__ + "." + path.slice(this.as.length + 1), value); +return true; +} +}, +_forwardParentProp: function(prop, value) { +if (this.rows) { +this.rows.forEach(function(row) { +row[prop] = value; +}, this); +} +}, +_forwardParentPath: function(path, value) { +if (this.rows) { +this.rows.forEach(function(row) { +row.notifyPath(path, value, true); +}, this); +} +}, +_forwardItemPath: function(path, value) { +if (this._rowForKey) { +var dot = path.indexOf("."); +var key = path.substring(0, dot < 0 ? path.length : dot); +var idx = this._rowForKey[key]; +var row = this.rows[idx]; +if (row) { +if (dot >= 0) { +path = this.as + "." + path.substring(dot + 1); +row.notifyPath(path, value, true); +} else { +row[this.as] = value; +} +} +} +}, +modelForElement: function(el) { +var model; +while (el) { +if (model = el._templateInstance) { +if (model.dataHost != this) { +el = model.dataHost; +} else { +return model; +} +} else { +el = el.parentNode; +} +} +}, +itemForElement: function(el) { +var instance = this.modelForElement(el); +return instance && instance[this.as]; +}, +keyForElement: function(el) { +var instance = this.modelForElement(el); +return instance && instance.__key__; +}, +indexForElement: function(el) { +var instance = this.modelForElement(el); +return instance && instance[this.indexAs]; +} +}); + +Polymer({ +is: "array-selector", +properties: { +items: { +type: Array, +observer: "_itemsChanged" +}, +selected: { +type: Object, +notify: true +}, +toggle: Boolean, +multi: Boolean +}, +_itemsChanged: function() { +if (Array.isArray(this.selected)) { +for (var i = 0; i < this.selected.length; i++) { +this.unlinkPaths("selected." + i); +} +} else { +this.unlinkPaths("selected"); +} +if (this.multi) { +this.selected = []; +} else { +this.selected = null; +} +}, +deselect: function(item) { +if (this.multi) { +var scol = Polymer.Collection.get(this.selected); +var sidx = this.selected.indexOf(item); +if (sidx >= 0) { +var skey = scol.getKey(item); +this.splice("selected", sidx, 1); +this.unlinkPaths("selected." + skey); +return true; +} +} else { +this.selected = null; +this.unlinkPaths("selected"); +} +}, +select: function(item) { +var icol = Polymer.Collection.get(this.items); +var key = icol.getKey(item); +if (this.multi) { +var scol = Polymer.Collection.get(this.selected); +var skey = scol.getKey(item); +if (skey >= 0) { +this.deselect(item); +} else if (this.toggle) { +this.push("selected", item); +this.async(function() { +skey = scol.getKey(item); +this.linkPaths("selected." + skey, "items." + key); +}); +} +} else { +if (this.toggle && item == this.selected) { +this.deselect(); +} else { +this.linkPaths("selected", "items." + key); +this.selected = item; +} +} +} +}); + +Polymer({ +is: "dom-if", +"extends": "template", +properties: { +"if": { +type: Boolean, +value: false +}, +restamp: { +type: Boolean, +value: false +} +}, +behaviors: [ Polymer.Templatizer ], +observers: [ "_queueRender(if, restamp)" ], +_queueRender: function() { +this._debounceTemplate(this._render); +}, +detached: function() { +this._teardownInstance(); +}, +attached: function() { +if (this.if && this.ctor) { +this.async(this._ensureInstance); +} +}, +render: function() { +this._flushTemplates(); +}, +_render: function() { +if (this.if) { +if (!this.ctor) { +this._wrapTextNodes(this._content || this.content); +this.templatize(this); +} +this._ensureInstance(); +this._hideTemplateChildren = false; +} else if (this.restamp) { +this._teardownInstance(); +} +if (!this.restamp && this._instance) { +this._hideTemplateChildren = !this.if; +} +if (this.if != this._lastIf) { +this.fire("dom-change"); +this._lastIf = this.if; +} +}, +_ensureInstance: function() { +if (!this._instance) { +this._instance = this.stamp(); +var root = this._instance.root; +var parent = Polymer.dom(Polymer.dom(this).parentNode); +parent.insertBefore(root, this); +} +}, +_teardownInstance: function() { +if (this._instance) { +var c = this._instance._children; +if (c) { +var parent = Polymer.dom(Polymer.dom(c[0]).parentNode); +c.forEach(function(n) { +parent.removeChild(n); +}); +} +this._instance = null; +} +}, +_wrapTextNodes: function(root) { +for (var n = root.firstChild; n; n = n.nextSibling) { +if (n.nodeType === Node.TEXT_NODE) { +var s = document.createElement("span"); +root.insertBefore(s, n); +s.appendChild(n); +n = s; +} +} +}, +_hideChildren: function(hidden) { +if (this._instance) { +var c$ = this._instance._children; +for (var i = 0; i < c$.length; i++) { +var c = c$[i]; +c.style.display = hidden ? "none" : ""; +c._hideTemplateChildren = hidden; +} +} +}, +_forwardParentProp: function(prop, value) { +if (this._instance) { +this._instance[prop] = value; +} +}, +_forwardParentPath: function(path, value) { +if (this._instance) { +this._instance.notifyPath(path, value, true); +} +} +}); + +Polymer.ImportStatus = { +_ready: false, +_callbacks: [], +whenLoaded: function(cb) { +if (this._ready) { +cb(); +} else { +this._callbacks.push(cb); +} +}, +_importsLoaded: function() { +this._ready = true; +this._callbacks.forEach(function(cb) { +cb(); +}); +this._callbacks = []; +} +}; + +window.addEventListener("load", function() { +Polymer.ImportStatus._importsLoaded(); +}); + +if (window.HTMLImports) { +HTMLImports.whenReady(function() { +Polymer.ImportStatus._importsLoaded(); +}); +} + +Polymer({ +is: "dom-bind", +"extends": "template", +created: function() { +Polymer.ImportStatus.whenLoaded(this._readySelf.bind(this)); +}, +_registerFeatures: function() { +this._prepExtends(); +this._prepConstructor(); +}, +_insertChildren: function() { +var parentDom = Polymer.dom(Polymer.dom(this).parentNode); +parentDom.insertBefore(this.root, this); +}, +_removeChildren: function() { +if (this._children) { +for (var i = 0; i < this._children.length; i++) { +this.root.appendChild(this._children[i]); +} +} +}, +_initFeatures: function() {}, +_scopeElementClass: function(element, selector) { +if (this.dataHost) { +return this.dataHost._scopeElementClass(element, selector); +} else { +return selector; +} +}, +_prepConfigure: function() { +var config = {}; +for (var prop in this._propertyEffects) { +config[prop] = this[prop]; +} +this._setupConfigure = this._setupConfigure.bind(this, config); +}, +attached: function() { +if (!this._children) { +this._template = this; +this._prepAnnotations(); +this._prepEffects(); +this._prepBehaviors(); +this._prepConfigure(); +this._prepBindings(); +Polymer.Base._initFeatures.call(this); +this._children = Array.prototype.slice.call(this.root.childNodes); +} +this._insertChildren(); +this.fire("dom-change"); +}, +detached: function() { +this._removeChildren(); +} +});</script> diff --git a/third_party/polymer/v1_0/components/promise-polyfill/.bower.json b/third_party/polymer/v1_0/components/promise-polyfill/.bower.json new file mode 100644 index 0000000..ee0f467 --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/.bower.json @@ -0,0 +1,40 @@ +{ + "name": "promise-polyfill", + "version": "1.0.0", + "homepage": "https://github.com/taylorhakes/promise-polyfill", + "authors": [ + "Taylor Hakes" + ], + "description": "Lightweight promise polyfill for the browser and node. A+ Compliant.", + "main": "Promise.js", + "moduleType": [ + "globals", + "node" + ], + "keywords": [ + "promise", + "es6", + "polyfill", + "html5" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + }, + "_release": "1.0.0", + "_resolution": { + "type": "version", + "tag": "v1.0.0", + "commit": "2ef7dada161cae30e69ffff918485c57121d4b88" + }, + "_source": "git://github.com/polymerlabs/promise-polyfill.git", + "_target": "^1.0.0", + "_originalSource": "polymerlabs/promise-polyfill" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/promise-polyfill/Gruntfile.js b/third_party/polymer/v1_0/components/promise-polyfill/Gruntfile.js new file mode 100644 index 0000000..3138444 --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/Gruntfile.js @@ -0,0 +1,40 @@ +module.exports = function(grunt) { + + grunt.initConfig({ + pkg: grunt.file.readJSON('package.json'), + + uglify: { + options: { + banner: '/*! <%= pkg.name %> <%= pkg.version %> */\n' + }, + dist: { + files: { + 'Promise.min.uglify.js': ['Promise.js'] + } + } + }, + + closurecompiler: { + options: { + compilation_level: 'ADVANCED_OPTIMIZATIONS', + }, + dist: { + files: { + 'Promise.min.js': ['Promise.js'] + } + } + }, + + bytesize: { + dist: { + src: ['Promise*.js'] + } + } + }); + + grunt.loadNpmTasks('grunt-contrib-uglify'); + grunt.loadNpmTasks('grunt-closurecompiler'); + grunt.loadNpmTasks('grunt-bytesize'); + + grunt.registerTask('build', ['closurecompiler', 'bytesize']); +}; diff --git a/third_party/polymer/v1_0/components/promise-polyfill/LICENSE b/third_party/polymer/v1_0/components/promise-polyfill/LICENSE new file mode 100644 index 0000000..94b9dac --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2014 Taylor Hakes +Copyright (c) 2014 Forbes Lindesay + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE.
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/promise-polyfill/Promise-Statics.js b/third_party/polymer/v1_0/components/promise-polyfill/Promise-Statics.js new file mode 100644 index 0000000..7ce402eb --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/Promise-Statics.js @@ -0,0 +1,37 @@ +Promise.all = Promise.all || function () { + var args = Array.prototype.slice.call(arguments.length === 1 && Array.isArray(arguments[0]) ? arguments[0] : arguments); + + return new Promise(function (resolve, reject) { + if (args.length === 0) return resolve([]); + var remaining = args.length; + function res(i, val) { + try { + if (val && (typeof val === 'object' || typeof val === 'function')) { + var then = val.then; + if (typeof then === 'function') { + then.call(val, function (val) { res(i, val) }, reject); + return; + } + } + args[i] = val; + if (--remaining === 0) { + resolve(args); + } + } catch (ex) { + reject(ex); + } + } + for (var i = 0; i < args.length; i++) { + res(i, args[i]); + } + }); +}; + +Promise.race = Promise.race || function (values) { + return new Promise(function (resolve, reject) { + for(var i = 0, len = values.length; i < len; i++) { + values[i].then(resolve, reject); + } + }); +}; + diff --git a/third_party/polymer/v1_0/components/promise-polyfill/Promise.js b/third_party/polymer/v1_0/components/promise-polyfill/Promise.js new file mode 100644 index 0000000..dc6f58f --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/Promise.js @@ -0,0 +1,128 @@ +function MakePromise (asap) { + function Promise(fn) { + if (typeof this !== 'object' || typeof fn !== 'function') throw new TypeError(); + this._state = null; + this._value = null; + this._deferreds = [] + + doResolve(fn, resolve.bind(this), reject.bind(this)); + } + + function handle(deferred) { + var me = this; + if (this._state === null) { + this._deferreds.push(deferred); + return + } + asap(function() { + var cb = me._state ? deferred.onFulfilled : deferred.onRejected + if (typeof cb !== 'function') { + (me._state ? deferred.resolve : deferred.reject)(me._value); + return; + } + var ret; + try { + ret = cb(me._value); + } + catch (e) { + deferred.reject(e); + return; + } + deferred.resolve(ret); + }) + } + + function resolve(newValue) { + try { //Promise Resolution Procedure: https://github.com/promises-aplus/promises-spec#the-promise-resolution-procedure + if (newValue === this) throw new TypeError(); + if (newValue && (typeof newValue === 'object' || typeof newValue === 'function')) { + var then = newValue.then; + if (typeof then === 'function') { + doResolve(then.bind(newValue), resolve.bind(this), reject.bind(this)); + return; + } + } + this._state = true; + this._value = newValue; + finale.call(this); + } catch (e) { reject.call(this, e); } + } + + function reject(newValue) { + this._state = false; + this._value = newValue; + finale.call(this); + } + + function finale() { + for (var i = 0, len = this._deferreds.length; i < len; i++) { + handle.call(this, this._deferreds[i]); + } + this._deferreds = null; + } + + /** + * Take a potentially misbehaving resolver function and make sure + * onFulfilled and onRejected are only called once. + * + * Makes no guarantees about asynchrony. + */ + function doResolve(fn, onFulfilled, onRejected) { + var done = false; + try { + fn(function (value) { + if (done) return; + done = true; + onFulfilled(value); + }, function (reason) { + if (done) return; + done = true; + onRejected(reason); + }) + } catch (ex) { + if (done) return; + done = true; + onRejected(ex); + } + } + + Promise.prototype['catch'] = function (onRejected) { + return this.then(null, onRejected); + }; + + Promise.prototype.then = function(onFulfilled, onRejected) { + var me = this; + return new Promise(function(resolve, reject) { + handle.call(me, { + onFulfilled: onFulfilled, + onRejected: onRejected, + resolve: resolve, + reject: reject + }); + }) + }; + + Promise.resolve = function (value) { + if (value && typeof value === 'object' && value.constructor === Promise) { + return value; + } + + return new Promise(function (resolve) { + resolve(value); + }); + }; + + Promise.reject = function (value) { + return new Promise(function (resolve, reject) { + reject(value); + }); + }; + + + return Promise; +} + +if (typeof module !== 'undefined') { + module.exports = MakePromise; +} + diff --git a/third_party/polymer/v1_0/components/promise-polyfill/Promise.min.js b/third_party/polymer/v1_0/components/promise-polyfill/Promise.min.js new file mode 100644 index 0000000..f37c6af --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/Promise.min.js @@ -0,0 +1,3 @@ +function m(n){function b(a){if("object"!==typeof this||"function"!==typeof a)throw new TypeError;this.c=this.a=null;this.b=[];g(a,h.bind(this),d.bind(this))}function k(a){var c=this;null===this.a?this.b.push(a):n(function(){var f=c.a?a.d:a.e;if("function"!==typeof f)(c.a?a.resolve:a.reject)(c.c);else{var e;try{e=f(c.c)}catch(b){a.reject(b);return}a.resolve(e)}})}function h(a){try{if(a===this)throw new TypeError;if(a&&("object"===typeof a||"function"===typeof a)){var c=a.then;if("function"===typeof c){g(c.bind(a), +h.bind(this),d.bind(this));return}}this.a=!0;this.c=a;l.call(this)}catch(b){d.call(this,b)}}function d(a){this.a=!1;this.c=a;l.call(this)}function l(){for(var a=0,c=this.b.length;a<c;a++)k.call(this,this.b[a]);this.b=null}function g(a,c,b){var e=!1;try{a(function(a){e||(e=!0,c(a))},function(a){e||(e=!0,b(a))})}catch(d){e||(e=!0,b(d))}}b.prototype["catch"]=function(a){return this.then(null,a)};b.prototype.then=function(a,c){var f=this;return new b(function(b,d){k.call(f,{d:a,e:c,resolve:b,reject:d})})}; +b.resolve=function(a){return a&&"object"===typeof a&&a.constructor===b?a:new b(function(b){b(a)})};b.reject=function(a){return new b(function(b,d){d(a)})};return b}"undefined"!==typeof module&&(module.f=m); diff --git a/third_party/polymer/v1_0/components/promise-polyfill/README.md b/third_party/polymer/v1_0/components/promise-polyfill/README.md new file mode 100644 index 0000000..de6806b --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/README.md @@ -0,0 +1,13 @@ +# Promise Polyfill + +Note: this is an unsolicited fork of [taylorhakes/promise-polyfill](https://github.com/taylorhakes/promise-polyfill) +and should be considered experimental and unstable compared to upstream. + +## Testing +``` +npm install +npm test +``` + +## License +MIT diff --git a/third_party/polymer/v1_0/components/promise-polyfill/bower.json b/third_party/polymer/v1_0/components/promise-polyfill/bower.json new file mode 100644 index 0000000..fad59640 --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/bower.json @@ -0,0 +1,31 @@ +{ + "name": "promise-polyfill", + "version": "1.0.0", + "homepage": "https://github.com/taylorhakes/promise-polyfill", + "authors": [ + "Taylor Hakes" + ], + "description": "Lightweight promise polyfill for the browser and node. A+ Compliant.", + "main": "Promise.js", + "moduleType": [ + "globals", + "node" + ], + "keywords": [ + "promise", + "es6", + "polyfill", + "html5" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ], + "dependencies": { + "polymer": "polymer/polymer#^1.0.0" + } +} diff --git a/third_party/polymer/v1_0/components/promise-polyfill/package.json b/third_party/polymer/v1_0/components/promise-polyfill/package.json new file mode 100644 index 0000000..5360534 --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/package.json @@ -0,0 +1,35 @@ +{ + "name": "promise-polyfill", + "version": "2.0.0", + "description": "Lightweight promise polyfill. A+ compliant", + "main": "Promise.js", + "scripts": { + "test": "./node_modules/.bin/promises-aplus-tests tests/adapter.js; ./node_modules/.bin/promises-es6-tests tests/adapter.js" + }, + "repository": { + "type": "git", + "url": "https://taylorhakes@github.com/taylorhakes/promise-polyfill.git" + }, + "author": "Taylor Hakes", + "license": "MIT", + "bugs": { + "url": "https://github.com/taylorhakes/promise-polyfill/issues" + }, + "homepage": "https://github.com/taylorhakes/promise-polyfill", + "devDependencies": { + "grunt": "^0.4.5", + "grunt-bytesize": "^0.1.1", + "grunt-closurecompiler": "^0.9.9", + "grunt-contrib-uglify": "^0.4.0", + "mocha": "^2.2.1", + "promises-aplus-tests": "*", + "promises-es6-tests": "^0.5.0" + }, + "keywords": [ + "promise", + "promise-polyfill", + "ES6", + "promises-aplus" + ], + "dependencies": {} +} diff --git a/third_party/polymer/v1_0/components/promise-polyfill/promise-polyfill-lite.html b/third_party/polymer/v1_0/components/promise-polyfill/promise-polyfill-lite.html new file mode 100644 index 0000000..87f5e75 --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/promise-polyfill-lite.html @@ -0,0 +1,7 @@ +<link rel="import" href="../polymer/polymer.html"> +<script src='./Promise.js'></script> +<script> +if (!window.Promise) { + window.Promise = MakePromise(Polymer.Base.async); +} +</script> diff --git a/third_party/polymer/v1_0/components/promise-polyfill/promise-polyfill.html b/third_party/polymer/v1_0/components/promise-polyfill/promise-polyfill.html new file mode 100644 index 0000000..94d2d2c --- /dev/null +++ b/third_party/polymer/v1_0/components/promise-polyfill/promise-polyfill.html @@ -0,0 +1,2 @@ +<link rel="import" href="./promise-polyfill-lite.html"> +<script src='./Promise-Statics.js'></script> diff --git a/third_party/polymer/v1_0/components/web-animations-js/.bower.json b/third_party/polymer/v1_0/components/web-animations-js/.bower.json new file mode 100644 index 0000000..f3e3715 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/.bower.json @@ -0,0 +1,41 @@ +{ + "name": "web-animations-js", + "description": "JavaScript implementation of the Web Animations API", + "homepage": "https://github.com/web-animations/web-animations-js", + "main": "web-animations.min.js", + "moduleType": [ + "globals" + ], + "keywords": [ + "animations", + "polyfill" + ], + "license": "Apache-2.0", + "ignore": [ + "**/.*", + "node_modules", + "templates", + "test", + "src", + "Gruntfile.js", + "package.json", + "target-config.js", + "target-loader.js", + "web-animations.dev.html", + "web-animations.dev.js", + "web-animations-next.dev.html", + "web-animations-next.dev.js", + "web-animations-next-lite.dev.html", + "web-animations-next-lite.dev.js" + ], + "version": "2.0.0", + "_release": "2.0.0", + "_resolution": { + "type": "version", + "tag": "2.0.0", + "commit": "8a3bb632f39f8b5072c77a502eb43e880b08d94c" + }, + "_source": "git://github.com/web-animations/web-animations-js.git", + "_target": "^2.0.0", + "_originalSource": "web-animations/web-animations-js" +}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/web-animations-js/COPYING b/third_party/polymer/v1_0/components/web-animations-js/COPYING new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/COPYING @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/third_party/polymer/v1_0/components/web-animations-js/History.md b/third_party/polymer/v1_0/components/web-animations-js/History.md new file mode 100644 index 0000000..4c50afa --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/History.md @@ -0,0 +1,108 @@ +### 2.0.0 - *April 5 2015* + + * Improve behavior of group Animation playback rate. + * Rename Animation to KeyframeEffect. + * Rename AnimationSequence to SequenceEffect. + * Rename AnimationGroup to GroupEffect. + * Rename AnimationPlayer to Animation. + * Remove KeyframeEffect.effect and add KeyframeEffect.getFrames. + * Rename Animation.source to Animation.effect. + * Rename Timeline.getAnimationPlayers to Timeline.getAnimations. + * Rename Element.getAnimationPlayers to Element.getAnimations. + +### 1.0.7 - *March 10 2015* + + * Improve performance of constructing groups and sequences. + * Remove support for animating zoom. + * Add bower file. + +### 1.0.6 - *February 5 2015* + + * Implement playbackRate setter for group players. + * Fix pausing a group player before its first tick. + * Fix cancelling a group player before its first tick. + * Fix excess CPU use on idle pages where custom effects and groups were used. + * Suppress AnimationTiming.playbackRate deprecation warning for cases where AnimationTiming.playbackRate == 1. + +### 1.0.5 - *January 6 2015* + + * Fix loading the polyfill in an SVG document + * Fix a problem where groups didn't take effect in their first frame + * Don't rely on performance.now + +### 1.0.4 - *December 8 2014* + + * Fix a critical bug where deprecation logic wasn't being loaded + when `web-animations-next` and `web-animations-next-lite` were + executed on top of a native `element.animate`. + +### 1.0.3 - *December 4 2014* + + * Fix a critical bug on iOS 7 and Safari <= 6. Due to limitations, + inline style patching is not supported on these platforms. + +### 1.0.2 - *November 28 2014* + + * Deprecated `AnimationTiming.playbackRate`. + + For example, this is no longer supported: + + var player = element.animate( + keyframes, + {duration: 1000, playbackRate: 2}); + + Use `AnimationPlayer.playbackRate` instead: + + var player = element.animate( + keyframes, + {duration: 1000}); + player.playbackRate = 2; + + If you have any feedback on this change, please start a discussion + on the public-fx mailing list: + http://lists.w3.org/Archives/Public/public-fx/ + + Or file an issue against the specification on GitHub: + https://github.com/w3c/web-animations/issues/new + +### 1.0.1 - *November 26 2014* + + * Players should be constructed in idle state + * `play()` and `reverse()` should not force a start times + * Add `requestAnimationFrame` ids and `cancelAnimationFrame` + +### 1.0.0 — *November 21 2014* + + The web-animations-js hackers are pleased to announce the release of + a new codebase for the Web Animations Polyfill: + https://github.com/web-animations/web-animations-js + + The previous polyfill has been moved to: + https://github.com/web-animations/web-animations-js-legacy + + The new codebase is focused on code-size -- our smallest target is + now only 33kb or 11kb after gzip. + + We've implemented native fallback. If the target browser provides + Web Animations features natively, the Polyfill will use them. + + We now provide three different build targets: + + `web-animations.min.js` - Tracks the Web Animations features that + are supported natively in browsers. Today that means Element.animate + and Playback Control in Chrome. If you’re not sure what features you + will need, start with this. + + `web-animations-next.min.js` - All of web-animations.min.js plus + features that are still undergoing discussion or have yet to be + implemented natively. + + `web-animations-next-lite.min.js` - A cut down version of + web-animations-next, removes several lesser used property handlers + and some of the larger and less used features such as matrix + interpolation/decomposition. + + Not all features of the previous polyfill have been ported to the + new codebase; most notably mutation of Animations and Groups and + Additive Animations are not yet supported. These features are still + important and will be implemented in the coming weeks. diff --git a/third_party/polymer/v1_0/components/web-animations-js/README.md b/third_party/polymer/v1_0/components/web-animations-js/README.md new file mode 100644 index 0000000..e3e7d53 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/README.md @@ -0,0 +1,161 @@ + +Quick Start +----------- + +To provide native Chrome Web Animation features (`Element.animate` and Playback +Control) in other browsers, use `web-animations.min.js`. To explore all of the +proposed Web Animations API, use `web-animations-next.min.js`. + +What is Web Animations? +----------------------- + +Web Animations is a new JavaScript API for driving animated content on the web. +By unifying the animation features of SVG and CSS, Web Animations unlocks +features previously only usable declaratively, and exposes powerful, +high-performance animation capabilities to developers. + +For more details see the +[W3C specification](http://w3c.github.io/web-animations/). + +What is the polyfill? +--------------------- + +The polyfill is a JavaScript implementation of the Web Animations API. It works +on modern versions of all major browsers. For more details about browser +support see <https://www.polymer-project.org/resources/compatibility.html>. + +Getting Started +--------------- + +Here's a simple example of an animation that scales and changes the opacity of +a `<div>` over 0.5 seconds. The animation alternates producing a pulsing +effect. + + <script src="web-animations.min.js"></script> + <div class="pulse" style="width:150px;">Hello world!</div> + <script> + var elem = document.querySelector('.pulse'); + var animation = elem.animate([ + {opacity: 0.5, transform: "scale(0.5)"}, + {opacity: 1.0, transform: "scale(1)"} + ], { + direction: 'alternate', + duration: 500, + iterations: Infinity + }); + </script> + +Web Animations supports off-main-thread animations, and also allows procedural +generation of animations and fine-grained control of animation playback. See +<http://web-animations.github.io> for ideas and inspiration! + +Native Fallback +--------------- + +When the polyfill runs on a browser that implements `Element.animate` and +`Animation` Playback Control it will detect and use the underlying native +features. + +Different Build Targets +----------------------- + +### web-animations.min.js + +Tracks the Web Animations features that are supported natively in browsers. +Today that means Element.animate and Playback Control in Chrome. If you’re not +sure what features you will need, start with this. + +### web-animations-next.min.js + +Contains all of web-animations.min.js plus features that are still undergoing +discussion or have yet to be implemented natively. + +### web-animations-next-lite.min.js + +A cut down version of web-animations-next, it removes several lesser used +property handlers and some of the larger and less used features such as matrix +interpolation/decomposition. + +### Build Target Comparison + +| | web-animations | web-animations-next | web-animations-next-lite | +|------------------------|:--------------:|:-------------------:|:------------------------:| +|Size (gzipped) | 12.5kb | 14kb | 10.5kb | +|Element.animate | ✔ | ✔ | ✔ | +|Timing input (easings, duration, fillMode, etc.) for animation effects| ✔ | ✔ | ✔ | +|Playback control | ✔ | ✔ | ✔ | +|Support for animating lengths, transforms and opacity| ✔ | ✔ | ✔ | +|Support for animating other CSS properties| ✔ | ✔ | 🚫 | +|Matrix fallback for transform animations | ✔ | ✔ | 🚫 | +|KeyframeEffect constructor | 🚫 | ✔ | ✔ | +|Simple GroupEffects & SequenceEffects | 🚫 | ✔ | ✔ | +|Custom Effects | 🚫 | ✔ | ✔ | +|Timing input (easings, duration, fillMode, etc.) for groups</div>| 🚫 | 🚫\* | 🚫 | +|Additive animation | 🚫 | 🚫\* | 🚫 | +|Motion path | 🚫\* | 🚫\* | 🚫 | +|Modifiable keyframe effect timing| 🚫 | 🚫\* | 🚫\* | +|Modifiable group timing | 🚫 | 🚫\* | 🚫\* | +|Usable inline style\*\* | ✔ | ✔ | 🚫 | + +\* support is planned for these features. +\*\* see inline style caveat below. + +Caveats +------- + +Some things won’t ever be faithful to the native implementation due to browser +and CSS API limitations. These include: + +### Inline Style + +Inline style modification is the mechanism used by the polyfill to animate +properties. Both web-animations and web-animations-next incorporate a module +that emulates a vanilla inline style object, so that style modification from +JavaScript can still work in the presence of animations. However, to keep the +size of web-animations-next-lite as small as possible, the style emulation +module is not included. When using this version of the polyfill, JavaScript +inline style modification will be overwritten by animations. +Due to browser constraints inline style modification is not supported on iOS 7 +or Safari 6 (or earlier versions). + +### Prefix handling + +The polyfill will automatically detect the correctly prefixed name to use when +writing animated properties back to the platform. Where possible, the polyfill +will only accept unprefixed versions of experimental features. For example: + + var effect = new KeyframeEffect(elem, {"transform": "translate(100px, 100px)"}, 2000); + +will work in all browsers that implement a conforming version of transform, but + + var effect = new KeyframeEffect(elem, {"-webkit-transform": "translate(100px, 100px)"}, 2000); + +will not work anywhere. + +API and Specification Feedback +------------------------------ + +File an issue on GitHub: <https://github.com/w3c/web-animations/issues/new>. +Alternatively, send an email to <public-fx@w3.org> with subject line +“[web-animations] … message topic …” +([archives](http://lists.w3.org/Archives/Public/public-fx/)). + +Polyfill Issues +--------------- + +Report any issues with this implementation on GitHub: +<https://github.com/web-animations/web-animations-next/issues/new>. + +Breaking changes +---------------- + +When we make a potentially breaking change to the polyfill's API +surface (like a rename) we will, where possible, continue supporting the +old version, deprecated, for three months, and ensure that there are +console warnings to indicate that a change is pending. After three +months, the old version of the API surface (e.g. the old version of a +function name) will be removed. *If you see deprecation warnings you +can't avoid it by not updating*. + +We also announce anything that isn't a bug fix on +[web-animations-changes@googlegroups.com](https://groups.google.com/forum/#!forum/web-animations-changes). diff --git a/third_party/polymer/v1_0/components/web-animations-js/bower.json b/third_party/polymer/v1_0/components/web-animations-js/bower.json new file mode 100644 index 0000000..22f26b5 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/bower.json @@ -0,0 +1,31 @@ +{ + "name": "web-animations-js", + "description": "JavaScript implementation of the Web Animations API", + "homepage": "https://github.com/web-animations/web-animations-js", + "main": "web-animations.min.js", + "moduleType": [ + "globals" + ], + "keywords": [ + "animations", + "polyfill" + ], + "license": "Apache-2.0", + "ignore": [ + "**/.*", + "node_modules", + "templates", + "test", + "src", + "Gruntfile.js", + "package.json", + "target-config.js", + "target-loader.js", + "web-animations.dev.html", + "web-animations.dev.js", + "web-animations-next.dev.html", + "web-animations-next.dev.js", + "web-animations-next-lite.dev.html", + "web-animations-next-lite.dev.js" + ] +} diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations-next-lite.min.js b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next-lite.min.js new file mode 100644 index 0000000..ad13084 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next-lite.min.js @@ -0,0 +1,17 @@ +// Copyright 2014 Google Inc. All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +!function(a,b){b["true"]=a;var c={},d={},e={},f=null;!function(a){function b(b,c){var d={delay:0,endDelay:0,fill:c?"both":"none",iterationStart:0,iterations:1,duration:c?"auto":0,playbackRate:1,direction:"normal",easing:"linear"};return"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof d[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==p.indexOf(b[c]))return;if("direction"==c&&-1==q.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;d[c]=b[c]}}):d.duration=b,d}function c(a,c){var d=b(a,c);return d.easing=f(d.easing),d}function d(a,b,c,d){return 0>a||a>1||0>c||c>1?y:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}for(var g=0,h=1;;){var i=(g+h)/2,j=f(a,c,i);if(Math.abs(e-j)<.001)return f(b,d,i);e>j?g=i:h=i}}}function e(a,b){return function(c){if(c>=1)return 1;var d=1/a;return c+=b*d,c-c%d}}function f(a){var b=w.exec(a);if(b)return d.apply(this,b.slice(1).map(Number));var c=x.exec(a);if(c)return e(Number(c[1]),{start:r,middle:s,end:t}[c[2]]);var f=u[a];return f?f:y}function g(a){return Math.abs(h(a)/a.playbackRate)}function h(a){return a.duration*a.iterations}function i(a,b,c){return null==b?z:b<c.delay?A:b>=c.delay+a?B:C}function j(a,b,c,d,e){switch(d){case A:return"backwards"==b||"both"==b?0:null;case C:return c-e;case B:return"forwards"==b||"both"==b?a:null;case z:return null}}function k(a,b,c,d){return(d.playbackRate<0?b-a:b)*d.playbackRate+c}function l(a,b,c,d,e){return 1/0===c||c===-1/0||c-d==b&&e.iterations&&(e.iterations+e.iterationStart)%1==0?a:c%a}function m(a,b,c,d){return 0===c?0:b==a?d.iterationStart+d.iterations-1:Math.floor(c/a)}function n(a,b,c,d){var e=a%2>=1,f="normal"==d.direction||d.direction==(e?"alternate-reverse":"alternate"),g=f?c:b-c,h=g/b;return b*d.easing(h)}function o(a,b,c){var d=i(a,b,c),e=j(a,c.fill,b,d,c.delay);if(null===e)return null;if(0===a)return d===A?0:1;var f=c.iterationStart*c.duration,g=k(a,e,f,c),o=l(c.duration,h(c),g,f,c),p=m(c.duration,o,g,c);return n(p,c.duration,o,c)/c.duration}var p="backwards|forwards|both|none".split("|"),q="reverse|alternate|alternate-reverse".split("|"),r=1,s=.5,t=0,u={ease:d(.25,.1,.25,1),"ease-in":d(.42,0,1,1),"ease-out":d(0,0,.58,1),"ease-in-out":d(.42,0,.58,1),"step-start":e(1,r),"step-middle":e(1,s),"step-end":e(1,t)},v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",w=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),x=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,y=function(a){return a},z=0,A=1,B=2,C=3;a.makeTiming=b,a.normalizeTimingInput=c,a.calculateActiveDuration=g,a.calculateTimeFraction=o,a.calculatePhase=i,a.toTimingFunction=f}(c,f),function(a){function b(a,b){return a in h?h[a][b]||b:b}function c(a,c,d){var g=e[a];if(g){f.style[a]=c;for(var h in g){var i=g[h],j=f.style[i];d[i]=b(i,j)}}else d[a]=b(a,c)}function d(b){function d(){var a=e.length;null==e[a-1].offset&&(e[a-1].offset=1),a>1&&null==e[0].offset&&(e[0].offset=0);for(var b=0,c=e[0].offset,d=1;a>d;d++){var f=e[d].offset;if(null!=f){for(var g=1;d-b>g;g++)e[b+g].offset=c+(f-c)*g/(d-b);b=d,c=f}}}if(!Array.isArray(b)&&null!==b)throw new TypeError("Keyframes must be null or an array of keyframes");if(null==b)return[];for(var e=b.map(function(b){var d={};for(var e in b){var f=b[e];if("offset"==e){if(null!=f&&(f=Number(f),!isFinite(f)))throw new TypeError("keyframe offsets must be numbers.")}else{if("composite"==e)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};f="easing"==e?a.toTimingFunction(f):""+f}c(e,f,d)}return void 0==d.offset&&(d.offset=null),void 0==d.easing&&(d.easing=a.toTimingFunction("linear")),d}),f=!0,g=-1/0,h=0;h<e.length;h++){var i=e[h].offset;if(null!=i){if(g>i)throw{code:DOMException.INVALID_MODIFICATION_ERR,name:"InvalidModificationError",message:"Keyframes are not loosely sorted by offset. Sort or specify offsets."};g=i}else f=!1}return e=e.filter(function(a){return a.offset>=0&&a.offset<=1}),f||d(),e}var e={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},f=document.createElementNS("http://www.w3.org/1999/xhtml","div"),g={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:g,borderLeftWidth:g,borderRightWidth:g,borderTopWidth:g,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:g,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.normalizeKeyframes=d}(c,f),function(a){var b={};a.isDeprecated=function(a,c,d,e){var f=e?"are":"is",g=new Date,h=new Date(c);return h.setMonth(h.getMonth()+3),h>g?(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,!1):!0},a.deprecated=function(b,c,d,e){var f=e?"are":"is";if(a.isDeprecated(b,c,d,e))throw new Error(b+" "+f+" no longer supported. "+d)}}(c),function(){if(document.documentElement.animate){var a=document.documentElement.animate([],0),b=!0;if(a&&(b=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach(function(c){void 0===a[c]&&(b=!0)})),!b)return}!function(a,b){function c(a){for(var b={},c=0;c<a.length;c++)for(var d in a[c])if("offset"!=d&&"easing"!=d&&"composite"!=d){var e={offset:a[c].offset,easing:a[c].easing,value:a[c][d]};b[d]=b[d]||[],b[d].push(e)}for(var f in b){var g=b[f];if(0!=g[0].offset||1!=g[g.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return b}function d(a){var c=[];for(var d in a)for(var e=a[d],f=0;f<e.length-1;f++){var g=e[f].offset,h=e[f+1].offset,i=e[f].value,j=e[f+1].value;g==h&&(1==h?i=j:j=i),c.push({startTime:g,endTime:h,easing:e[f].easing,property:d,interpolation:b.propertyInterpolation(d,i,j)})}return c.sort(function(a,b){return a.startTime-b.startTime}),c}b.convertEffectInput=function(e){var f=a.normalizeKeyframes(e),g=c(f),h=d(g);return function(a,c){if(null!=c)h.filter(function(a){return 0>=c&&0==a.startTime||c>=1&&1==a.endTime||c>=a.startTime&&c<=a.endTime}).forEach(function(d){var e=c-d.startTime,f=d.endTime-d.startTime,g=0==f?0:d.easing(e/f);b.apply(a,d.property,d.interpolation(g))});else for(var d in g)"offset"!=d&&"easing"!=d&&"composite"!=d&&b.clear(a,d)}}}(c,d,f),function(a){function b(a,b,c){e[c]=e[c]||[],e[c].push([a,b])}function c(a,c,d){for(var e=0;e<d.length;e++){var f=d[e];b(a,c,f),/-/.test(f)&&b(a,c,f.replace(/-(.)/g,function(a,b){return b.toUpperCase()}))}}function d(b,c,d){for(var f=c==d?[]:e[b],g=0;f&&g<f.length;g++){var h=f[g][0](c),i=f[g][0](d);if(void 0!==h&&void 0!==i){var j=f[g][1](h,i);if(j){var k=a.Interpolation.apply(null,j);return function(a){return 0==a?c:1==a?d:k(a)}}}}return a.Interpolation(!1,!0,function(a){return a?d:c})}var e={};a.addPropertiesHandler=c,a.propertyInterpolation=d}(d,f),function(a,b){function c(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateTimeFraction(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d._isCurrent=function(d){var e=a.calculatePhase(c,d,b);return e===PhaseActive||e===PhaseBefore},d}b.KeyframeEffect=function(d,e,f){var g,h=c(a.normalizeTimingInput(f)),i=b.convertEffectInput(e),j=function(){i(d,g)};return j._update=function(a){return g=h(a),null!==g},j._clear=function(){i(d,null)},j._hasSameTarget=function(a){return d===a},j._isCurrent=h._isCurrent,j._totalDuration=h._totalDuration,j},b.NullEffect=function(a){var b=function(){a&&(a(),a=null)};return b._update=function(){return null},b._totalDuration=0,b._isCurrent=function(){return!1},b._hasSameTarget=function(){return!1},b}}(c,d,f),function(a){a.apply=function(b,c,d){b.style[a.propertyName(c)]=d},a.clear=function(b,c){b.style[a.propertyName(c)]=""}}(d,f),function(a){window.Element.prototype.animate=function(b,c){return a.timeline._play(a.KeyframeEffect(this,b,c))}}(d),function(a){function b(a,c,d){if("number"==typeof a&&"number"==typeof c)return a*(1-d)+c*d;if("boolean"==typeof a&&"boolean"==typeof c)return.5>d?a:c;if(a.length==c.length){for(var e=[],f=0;f<a.length;f++)e.push(b(a[f],c[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+c}a.Interpolation=function(a,c,d){return function(e){return d(b(a,c,e))}}}(d,f),function(a){var b=0,c=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};a.Animation=function(a){this._sequenceNumber=b++,this._currentTime=0,this._startTime=null,this.paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!1,this.onfinish=null,this._finishHandlers=[],this._effect=a,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},a.Animation.prototype={_ensureAlive:function(){this._inEffect=this._effect._update(this.playbackRate<0&&0===this.currentTime?-1:this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,a.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this.finished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(b){b=+b,isNaN(b)||(a.restart(),this.paused||null==this._startTime||(this._startTime=this._timeline.currentTime-b/this._playbackRate),this._currentTimePending=!1,this._currentTime!=b&&(this._tickCurrentTime(b,!0),a.invalidateEffects()))},get startTime(){return this._startTime},set startTime(b){b=+b,isNaN(b)||this.paused||this._idle||(this._startTime=b,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),a.invalidateEffects())},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var b=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!=b&&(this.currentTime=b)}},get finished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this.paused&&0!=this.playbackRate||this._currentTimePending?"pending":this.paused?"paused":this.finished?"finished":"running"},play:function(){this.paused=!1,(this.finished||this._idle)&&(this._currentTime=this._playbackRate>0?0:this._totalDuration,this._startTime=null,a.invalidateEffects()),this._finishedFlag=!1,a.restart(),this._idle=!1,this._ensureAlive()},pause:function(){this.finished||this.paused||this._idle||(this._currentTimePending=!0),this._startTime=null,this.paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1)},cancel:function(){this._inEffect=!1,this._idle=!0,this.currentTime=0,this._startTime=null},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(a,b){"function"==typeof b&&"finish"==a&&this._finishHandlers.push(b)},removeEventListener:function(a,b){if("finish"==a){var c=this._finishHandlers.indexOf(b);c>=0&&this._finishHandlers.splice(c,1)}},_fireEvents:function(a){var b=this.finished;if((b||this._idle)&&!this._finishedFlag){var d=new c(this,this._currentTime,a),e=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){e.forEach(function(a){a.call(d.target,d)})},0)}this._finishedFlag=b},_tick:function(a){return this._idle||this.paused||(null==this._startTime?this.startTime=a-this._currentTime/this.playbackRate:this.finished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),this._currentTimePending=!1,this._fireEvents(a),!this._idle&&(this._inEffect||!this._finishedFlag)}}}(d,f),function(a,b){function c(a){var b=i;i=[],g(a),b.forEach(function(b){b[1](a)}),m&&g(a),f()}function d(a,b){return a._sequenceNumber-b._sequenceNumber}function e(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function f(){n.forEach(function(a){a()}),n.length=0}function g(a){l=!1;var c=b.timeline;c.currentTime=a,c._animations.sort(d),k=!1;var e=c._animations;c._animations=[];var f=[],g=[];e=e.filter(function(b){return b._inTimeline=b._tick(a),b._inEffect?g.push(b._effect):f.push(b._effect),b.finished||b.paused||b._idle||(k=!0),b._inTimeline}),n.push.apply(n,f),n.push.apply(n,g),c._animations.push.apply(c._animations,e),m=!1,k&&requestAnimationFrame(function(){})}var h=window.requestAnimationFrame,i=[],j=0;window.requestAnimationFrame=function(a){var b=j++;return 0==i.length&&h(c),i.push([b,a]),b},window.cancelAnimationFrame=function(a){i.forEach(function(b){b[0]==a&&(b[1]=function(){})})},e.prototype={_play:function(c){c._timing=a.normalizeTimingInput(c.timing);var d=new b.Animation(c);return d._idle=!1,d._timeline=this,this._animations.push(d),b.restart(),b.invalidateEffects(),d}};var k=!1,l=!1;b.restart=function(){return k||(k=!0,requestAnimationFrame(function(){}),l=!0),l};var m=!1;b.invalidateEffects=function(){m=!0};var n=[],o=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){return m&&g(p.currentTime),f(),o.apply(this,arguments)}});var p=new e;b.timeline=p}(c,d,f),function(a){function b(a,b){var c=a.exec(b);return c?(c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]):void 0}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);return c?[c[0],c[1].replace(/^\s*/,"")]:void 0}function d(a,d,e){a=c.bind(null,a);for(var f=[];;){var g=a(e);if(!g)return[f,e];if(f.push(g[0]),e=g[1],g=b(d,e),!g||""==g[1])return[f,e];e=g[1]}}function e(a,b){for(var c=0,d=0;d<b.length&&(!/\s|,/.test(b[d])||0!=c);d++)if("("==b[d])c++;else if(")"==b[d]&&(c--,0==c&&d++,0>=c))break;var e=a(b.substr(0,d));return void 0==e?void 0:[e,b.substr(d)]}function f(a,b){for(var c=a,d=b;c&&d;)c>d?c%=d:d%=c;return c=a*b/(c+d)}function g(a){return function(b){var c=a(b);return c&&(c[0]=void 0),c}}function h(a,b){return function(c){var d=a(c);return d?d:[b,c]}}function i(b,c){for(var d=[],e=0;e<b.length;e++){var f=a.consumeTrimmed(b[e],c);if(!f||""==f[0])return;void 0!==f[0]&&d.push(f[0]),c=f[1]}return""==c?d:void 0}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;j>k;k++){var l=b(d[k%d.length],e[k%e.length]);if(!l)return;g.push(l[0]),h.push(l[1]),i.push(l[2])}return[g,h,function(b){var d=b.map(function(a,b){return i[b](a)}).join(c);return a?a(d):d}]}function k(a,b,c){for(var d=[],e=[],f=[],g=0,h=0;h<c.length;h++)if("function"==typeof c[h]){var i=c[h](a[g],b[g++]);d.push(i[0]),e.push(i[1]),f.push(i[2])}else!function(a){d.push(!1),e.push(!1),f.push(function(){return c[a]})}(h);return[d,e,function(a){for(var b="",c=0;c<a.length;c++)b+=f[c](a[c]);return b}]}a.consumeToken=b,a.consumeTrimmed=c,a.consumeRepeated=d,a.consumeParenthesised=e,a.ignore=g,a.optional=h,a.consumeList=i,a.mergeNestedRepeated=j.bind(null,null),a.mergeWrappedNestedRepeated=j,a.mergeList=k}(d),function(a){function b(b){function c(b){var c=a.consumeToken(/^inset/i,b);if(c)return d.inset=!0,c;var c=a.consumeLengthOrPercent(b);if(c)return d.lengths.push(c[0]),c;var c=a.consumeColor(b);return c?(d.color=c[0],c):void 0}var d={inset:!1,lengths:[],color:null},e=a.consumeRepeated(c,/^/,b);return e&&e[0].length?[d,e[1]]:void 0}function c(c){var d=a.consumeRepeated(b,/^,/,c);return d&&""==d[1]?d[0]:void 0}function d(b,c){for(;b.lengths.length<Math.max(b.lengths.length,c.lengths.length);)b.lengths.push({px:0});for(;c.lengths.length<Math.max(b.lengths.length,c.lengths.length);)c.lengths.push({px:0});if(b.inset==c.inset&&!!b.color==!!c.color){for(var d,e=[],f=[[],0],g=[[],0],h=0;h<b.lengths.length;h++){var i=a.mergeDimensions(b.lengths[h],c.lengths[h],2==h);f[0].push(i[0]),g[0].push(i[1]),e.push(i[2])}if(b.color&&c.color){var j=a.mergeColors(b.color,c.color);f[1]=j[0],g[1]=j[1],d=j[2]}return[f,g,function(a){for(var c=b.inset?"inset ":" ",f=0;f<e.length;f++)c+=e[f](a[0][f])+" ";return d&&(c+=d(a[1])),c}]}}function e(b,c,d,e){function f(a){return{inset:a,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var g=[],h=[],i=0;i<d.length||i<e.length;i++){var j=d[i]||f(e[i].inset),k=e[i]||f(d[i].inset);g.push(j),h.push(k)}return a.mergeNestedRepeated(b,c,g,h)}var f=e.bind(null,d,", ");a.addPropertiesHandler(c,f,["box-shadow","text-shadow"])}(d),function(a){function b(a){return a.toFixed(3).replace(".000","")}function c(a,b,c){return Math.min(b,Math.max(a,c))}function d(a){return/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a)?Number(a):void 0}function e(a,c){return[a,c,b]}function f(a,b){return 0!=a?h(0,1/0)(a,b):void 0}function g(a,b){return[a,b,function(a){return Math.round(c(1,1/0,a))}]}function h(a,d){return function(e,f){return[e,f,function(e){return b(c(a,d,e))}]}}function i(a,b){return[a,b,Math.round]}a.clamp=c,a.addPropertiesHandler(d,h(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(d,h(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(d,f,["flex-grow","flex-shrink"]),a.addPropertiesHandler(d,g,["orphans","widows"]),a.addPropertiesHandler(d,i,["z-index"]),a.parseNumber=d,a.mergeNumbers=e,a.numberToString=b}(d,f),function(a){function b(a,b){return"visible"==a||"visible"==b?[0,1,function(c){return 0>=c?a:c>=1?b:"visible"}]:void 0}a.addPropertiesHandler(String,b,["visibility"])}(d),function(a){function b(a){a=a.trim(),e.fillStyle="#000",e.fillStyle=a;var b=e.fillStyle;if(e.fillStyle="#fff",e.fillStyle=a,b==e.fillStyle){e.fillRect(0,0,1,1);var c=e.getImageData(0,0,1,1).data;e.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function c(b,c){return[b,c,function(b){function c(a){return Math.max(0,Math.min(255,a))}if(b[3])for(var d=0;3>d;d++)b[d]=Math.round(c(b[d]/b[3]));return b[3]=a.numberToString(a.clamp(0,1,b[3])),"rgba("+b.join(",")+")"}]}var d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=d.height=1;var e=d.getContext("2d");a.addPropertiesHandler(b,c,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,b),a.mergeColors=c}(d,f),function(a,b){function c(a,b){if(b=b.trim().toLowerCase(),"0"==b&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var c={};b=b.replace(a,function(a){return c[a]=null,"U"+a});for(var d="U("+a.source+")",e=b.replace(/[-+]?(\d*\.)?\d+/g,"N").replace(new RegExp("N"+d,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),f=[/N\*(D)/g,/(N|D)[*/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],g=0;g<f.length;)f[g].test(e)?(e=e.replace(f[g],"$1"),g=0):g++;if("D"==e){for(var h in c){var i=eval(b.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(d,"g"),"*0"));if(!isFinite(i))return;c[h]=i}return c}}}function d(a,b){return e(a,b,!0)}function e(b,c,d){var e,f=[];for(e in b)f.push(e);for(e in c)f.indexOf(e)<0&&f.push(e);return b=f.map(function(a){return b[a]||0}),c=f.map(function(a){return c[a]||0}),[b,c,function(b){var c=b.map(function(c,e){return 1==b.length&&d&&(c=Math.max(c,0)),a.numberToString(c)+f[e]}).join(" + ");return b.length>1?"calc("+c+")":c}]}var f="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",g=c.bind(null,new RegExp(f,"g")),h=c.bind(null,new RegExp(f+"|%","g")),i=c.bind(null,/deg|rad|grad|turn/g);a.parseLength=g,a.parseLengthOrPercent=h,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,h),a.parseAngle=i,a.mergeDimensions=e;var j=a.consumeParenthesised.bind(null,g),k=a.consumeRepeated.bind(void 0,j,/^/),l=a.consumeRepeated.bind(void 0,k,/^,/);a.consumeSizePairList=l;var m=function(a){var b=l(a);return b&&""==b[1]?b[0]:void 0},n=a.mergeNestedRepeated.bind(void 0,d," "),o=a.mergeNestedRepeated.bind(void 0,n,",");a.mergeNonNegativeSizePair=n,a.addPropertiesHandler(m,o,["background-size"]),a.addPropertiesHandler(h,d,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),a.addPropertiesHandler(h,e,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","text-indent","top","vertical-align","word-spacing"])}(d,f),function(a){function b(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function c(c){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,b,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],c);return d&&4==d[0].length?d[0]:void 0}function d(b,c){return"auto"==b||"auto"==c?[!0,!1,function(d){var e=d?b:c;if("auto"==e)return"auto";var f=a.mergeDimensions(e,e);return f[2](f[0])}]:a.mergeDimensions(b,c)}function e(a){return"rect("+a+")"}var f=a.mergeWrappedNestedRepeated.bind(null,e,d,", ");a.parseBox=c,a.mergeBoxes=f,a.addPropertiesHandler(c,f,["clip"])}(d,f),function(a){function b(a){return function(b){var c=0;return a.map(function(a){return a===j?b[c++]:a})}}function c(a){return a}function d(b){if(b=b.toLowerCase().trim(),"none"==b)return[];for(var c,d=/\s*(\w+)\(([^)]*)\)/g,e=[],f=0;c=d.exec(b);){if(c.index!=f)return;f=c.index+c[0].length;var g=c[1],h=m[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var n=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(p=q?{A:function(b){return"0"==b.trim()?l:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:l,n:n[0],t:k}[r],void 0===p)return;n.push(p)}if(e.push({t:g,d:n}),d.lastIndex==b.length)return e}}function e(a){return a.toFixed(6).replace(".000000","")}function f(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var f=a.makeMatrixDecomposition(c)}return null==d[0]||null==f[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),f[0].push(1),[d,f,function(b){var c=a.quat(d[0][3],f[0][3],b[5]),g=a.composeMatrix(b[0],b[1],b[2],c,b[4]),h=g.map(e).join(",");return h}])}function g(a){return a.replace(/[xy]/,"")}function h(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function i(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var i=0;i<b.length;i++){var j=b[i].t,k=b[i].d,l="scale"==j.substr(0,5)?1:0;c.push({t:j,d:k.map(function(a){if("number"==typeof a)return l;var b={};for(var c in a)b[c]=l;return b})})}}var n=function(a,b){return"perspective"==a&&"perspective"==b||("matrix"==a||"matrix3d"==a)&&("matrix"==b||"matrix3d"==b)},o=[],p=[],q=[];if(b.length!=c.length){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var i=0;i<b.length;i++){var j,s=b[i].t,t=c[i].t,u=b[i].d,v=c[i].d,w=m[s],x=m[t];if(n(s,t)){if(!d)return;var r=f([b[i]],[c[i]]);o.push(r[0]),p.push(r[1]),q.push(["matrix",[r[2]]])}else{if(s==t)j=s;else if(w[2]&&x[2]&&g(s)==g(t))j=g(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||h(s)!=h(t)){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=h(s),u=w[1](u),v=x[1](v)}for(var y=[],z=[],A=[],B=0;B<u.length;B++){var C="number"==typeof u[B]?a.mergeNumbers:a.mergeDimensions,r=C(u[B],v[B]);y[B]=r[0],z[B]=r[1],A.push(r[2])}o.push(y),p.push(z),q.push([j,A])}}if(e){var D=o;o=p,p=D}return[o,p,function(a){return a.map(function(a,b){var c=a.map(function(a,c){return q[b][1][c](a)}).join(",");return"matrix"==q[b][0]&&16==c.split(",").length&&(q[b][0]="matrix3d"),q[b][0]+"("+c+")"}).join(" ")}]}var j=null,k={px:0},l={deg:0},m={matrix:["NNNNNN",[j,j,0,0,j,j,0,0,0,0,1,0,j,j,0,1],c],matrix3d:["NNNNNNNNNNNNNNNN",c],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",b([j,j,1]),c],scalex:["N",b([j,1,1]),b([j,1])],scaley:["N",b([1,j,1]),b([1,j])],scalez:["N",b([1,1,j])],scale3d:["NNN",c],skew:["Aa",null,c],skewx:["A",null,b([j,l])],skewy:["A",null,b([l,j])],translate:["Tt",b([j,j,k]),c],translatex:["T",b([j,k,k]),b([j,k])],translatey:["T",b([k,j,k]),b([k,j])],translatez:["L",b([k,k,j])],translate3d:["TTL",c]};a.addPropertiesHandler(d,i,["transform"])}(d,f),function(a){function b(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(c[a]=b)})}var c={};b("transform",["webkitTransform","msTransform"]),b("transformOrigin",["webkitTransformOrigin"]),b("perspective",["webkitPerspective"]),b("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return c[a]||a}}(d,f)}(),!function(a,b){function c(a){var b=window.document.timeline;b.currentTime=a,b._discardAnimations(),0==b._animations.length?d=!1:requestAnimationFrame(c)}b.AnimationTimeline=function(){this._animations=[],this.currentTime=void 0},b.AnimationTimeline.prototype={getAnimations:function(){return this._discardAnimations(),this._animations.slice()},getAnimationPlayers:function(){return a.deprecated("AnimationTimeline.getAnimationPlayers","2015-03-23","Use AnimationTimeline.getAnimations instead."),this.getAnimations()},_discardAnimations:function(){this._animations=this._animations.filter(function(a){return"finished"!=a.playState&&"idle"!=a.playState})},play:function(a){var c=new b.Animation(a);return this._animations.push(c),b.restartWebAnimationsNextTick(),c._animation.play(),c}};var d=!1;b.restartWebAnimationsNextTick=function(){d||(d=!0,requestAnimationFrame(c))};var e=new b.AnimationTimeline;b.timeline=e;try{Object.defineProperty(window.document,"timeline",{configurable:!0,get:function(){return e}})}catch(f){}try{window.document.timeline=e}catch(f){}}(c,e,f),function(a,b){b.Animation=function(a){this.effect=a,a&&(a.animation=this),this._isGroup=!1,this._animation=null,this._childAnimations=[],this._callback=null,this._rebuildUnderlyingAnimation(),this._animation.cancel()},b.Animation.prototype={_rebuildUnderlyingAnimation:function(){this._animation&&(this._animation.cancel(),this._animation=null),(!this.effect||this.effect instanceof window.KeyframeEffect)&&(this._animation=b.newUnderlyingAnimationForKeyframeEffect(this.effect),b.bindAnimationForKeyframeEffect(this)),(this.effect instanceof window.SequenceEffect||this.effect instanceof window.GroupEffect)&&(this._animation=b.newUnderlyingAnimationForGroup(this.effect),b.bindAnimationForGroup(this))},_updateChildren:function(){if(this.effect&&"idle"!=this.playState){var a=this.effect._timing.delay;this._childAnimations.forEach(function(c){this._arrangeChildren(c,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c.effect))}.bind(this))}},_setExternalAnimation:function(a){if(this.effect&&this._isGroup)for(var b=0;b<this.effect.children.length;b++)this.effect.children[b].animation=a,this._childAnimations[b]._setExternalAnimation(a)},_constructChildren:function(){if(this.effect&&this._isGroup){var a=this.effect._timing.delay;this.effect.children.forEach(function(c){var d=window.document.timeline.play(c);this._childAnimations.push(d),d.playbackRate=this.playbackRate,this.paused&&d.pause(),c.animation=this.effect.animation,this._arrangeChildren(d,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c))}.bind(this))}},_arrangeChildren:function(a,b){null===this.startTime?(a.currentTime=this.currentTime-b/this.playbackRate,a._startTime=null):a.startTime!==this.startTime+b/this.playbackRate&&(a.startTime=this.startTime+b/this.playbackRate)},get paused(){return this._animation.paused},get playState(){return this._animation.playState},get onfinish(){return this._onfinish},set onfinish(a){"function"==typeof a?(this._onfinish=a,this._animation.onfinish=function(b){b.target=this,a.call(this,b)}.bind(this)):(this._animation.onfinish=a,this.onfinish=this._animation.onfinish)},get currentTime(){return this._animation.currentTime},set currentTime(a){this._animation.currentTime=a,this._register(),this._forEachChild(function(b,c){b.currentTime=a-c})},get startTime(){return this._animation.startTime},set startTime(a){this._animation.startTime=a,this._register(),this._forEachChild(function(b,c){b.startTime=a+c})},get playbackRate(){return this._animation.playbackRate},set playbackRate(a){var b=this.currentTime;this._animation.playbackRate=a,this._forEachChild(function(b){b.playbackRate=a}),"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!==b&&(this.currentTime=b)},get finished(){return this._animation.finished},get source(){return a.deprecated("Animation.source","2015-03-23","Use Animation.effect instead."),this.effect},play:function(){this._animation.play(),this._register(),b.awaitStartTime(this),this._forEachChild(function(a){var b=a.currentTime;a.play(),a.currentTime=b})},pause:function(){this._animation.pause(),this._register(),this._forEachChild(function(a){a.pause()})},finish:function(){this._animation.finish(),this._register()},cancel:function(){this._animation.cancel(),this._register(),this._removeChildren()},reverse:function(){var a=this.currentTime;this._animation.reverse(),this._forEachChild(function(a){a.reverse()}),null!==a&&(this.currentTime=a)},addEventListener:function(a,b){var c=b;"function"==typeof b&&(c=function(a){a.target=this,b.call(this,a)}.bind(this),b._wrapper=c),this._animation.addEventListener(a,c)},removeEventListener:function(a,b){this._animation.removeEventListener(a,b&&b._wrapper||b)},_removeChildren:function(){for(;this._childAnimations.length;)this._childAnimations.pop().cancel()},_forEachChild:function(b){var c=0;if(this.effect.children&&this._childAnimations.length<this.effect.children.length&&this._constructChildren(),this._childAnimations.forEach(function(a){b.call(this,a,c),this.effect instanceof window.SequenceEffect&&(c+=a.effect.activeDuration)}.bind(this)),"pending"!=this._animation.playState){var d=this.effect._timing,e=this._animation.currentTime;null!==e&&(e=a.calculateTimeFraction(a.calculateActiveDuration(d),e,d)),(null==e||isNaN(e))&&this._removeChildren()}}}}(c,e,f),function(a,b){function c(b){this._frames=a.normalizeKeyframes(b)}function d(){for(var a=!1;g.length;)g.shift()._updateChildren(),a=!0;return a}b.KeyframeEffect=function(b,d,e){return this.target=b,this._timingInput=e,this._timing=a.normalizeTimingInput(e),this.timing=a.makeTiming(e),this._normalizedKeyframes="function"==typeof d?d:new c(d),this._keyframes=d,this.activeDuration=a.calculateActiveDuration(this._timing),this +},b.KeyframeEffect.prototype={getFrames:function(){return"function"==typeof this._normalizedKeyframes?this._normalizedKeyframes:this._normalizedKeyframes._frames},get effect(){return a.deprecated("KeyframeEffect.effect","2015-03-23","Use KeyframeEffect.getFrames() instead."),this._normalizedKeyframes}};var e=Element.prototype.animate;Element.prototype.animate=function(a,c){return b.timeline.play(new b.KeyframeEffect(this,a,c))};var f=document.createElementNS("http://www.w3.org/1999/xhtml","div");b.newUnderlyingAnimationForKeyframeEffect=function(a){var b=a.target||f,c=a._keyframes;return"function"==typeof c&&(c=[]),e.apply(b,[c,a._timingInput])},b.bindAnimationForKeyframeEffect=function(a){a.effect&&"function"==typeof a.effect._normalizedKeyframes&&b.bindAnimationForCustomEffect(a)};var g=[];b.awaitStartTime=function(a){null===a.startTime&&a._isGroup&&(0==g.length&&requestAnimationFrame(d),g.push(a))};var h=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){var a=h.apply(this,arguments);return d()&&(a=h.apply(this,arguments)),a}}),window.KeyframeEffect=b.KeyframeEffect,window.Element.prototype.getAnimations=function(){return document.timeline.getAnimations().filter(function(a){return null!==a.effect&&a.effect.target==this}.bind(this))},window.Element.prototype.getAnimationPlayers=function(){return a.deprecated("Element.getAnimationPlayers","2015-03-23","Use Element.getAnimations instead."),this.getAnimations()},window.Animation=function(){a.deprecated("window.Animation","2015-03-23","Use window.KeyframeEffect instead."),window.KeyframeEffect.apply(this,arguments)},window.Animation.prototype=Object.create(window.KeyframeEffect.prototype),window.Animation.prototype.constructor=window.Animation}(c,e,f),function(a,b){function c(a){a._registered||(a._registered=!0,f.push(a),g||(g=!0,requestAnimationFrame(d)))}function d(){var a=f;f=[],a.sort(function(a,b){return a._sequenceNumber-b._sequenceNumber}),a=a.filter(function(a){a();var b=a._animation?a._animation.playState:"idle";return"running"!=b&&"pending"!=b&&(a._registered=!1),a._registered}),f.push.apply(f,a),f.length?(g=!0,requestAnimationFrame(d)):g=!1}var e=(document.createElementNS("http://www.w3.org/1999/xhtml","div"),0);b.bindAnimationForCustomEffect=function(b){var d=b.effect.target,f=b.effect._normalizedKeyframes,g=b.effect.timing,h=null;g=a.normalizeTimingInput(g);var i=function(){var c=i._animation?i._animation.currentTime:null;null!==c&&(c=a.calculateTimeFraction(a.calculateActiveDuration(g),c,g),isNaN(c)&&(c=null)),c!==h&&f(c,d,b.effect),h=c};i._animation=b,i._registered=!1,i._sequenceNumber=e++,b._callback=i,c(i)};var f=[],g=!1;b.Animation.prototype._register=function(){this._callback&&c(this._callback)}}(c,e,f),function(a,b){function c(a){return a._timing.delay+a.activeDuration+a._timing.endDelay}function d(b,c){this.children=b||[],this._timing=a.normalizeTimingInput(c,!0),this.timing=a.makeTiming(c,!0),"auto"===this._timing.duration&&(this._timing.duration=this.activeDuration)}window.SequenceEffect=function(){d.apply(this,arguments)},window.GroupEffect=function(){d.apply(this,arguments)},window.SequenceEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a+=c(b)}),Math.max(a,0)}},window.GroupEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a=Math.max(a,c(b))}),a}},b.newUnderlyingAnimationForGroup=function(c){var d,e=null,f=function(b){var c=d._wrapper;return"pending"!=c.playState&&c.effect?null==b?void c._removeChildren():0==b&&c.playbackRate<0&&(e||(e=a.normalizeTimingInput(c.effect.timing)),b=a.calculateTimeFraction(a.calculateActiveDuration(e),-1,e),isNaN(b)||null==b)?(c._forEachChild(function(a){a.currentTime=-1}),void c._removeChildren()):void 0:void 0};return d=b.timeline.play(new b.KeyframeEffect(null,f,c._timing))},b.bindAnimationForGroup=function(a){a._animation._wrapper=a,a._isGroup=!0,b.awaitStartTime(a),a._constructChildren(),a._setExternalAnimation(a)},b.groupChildDuration=c,window.AnimationSequence=function(){a.deprecated("window.AnimationSequence","2015-03-23","Use window.SequenceEffect instead."),window.SequenceEffect.apply(this,arguments)},window.AnimationSequence.prototype=Object.create(window.SequenceEffect.prototype),window.AnimationSequence.prototype.constructor=window.AnimationSequence,window.AnimationGroup=function(){a.deprecated("window.AnimationGroup","2015-03-23","Use window.GroupEffect instead."),window.GroupEffect.apply(this,arguments)},window.AnimationGroup.prototype=Object.create(window.GroupEffect.prototype),window.AnimationGroup.prototype.constructor=window.AnimationGroup}(c,e,f)}({},function(){return this}()); +//# sourceMappingURL=web-animations-next-lite.min.js.map
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations-next-lite.min.js.map b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next-lite.min.js.map new file mode 100644 index 0000000..51f503b --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next-lite.min.js.map @@ -0,0 +1 @@ +{"version":3,"file":"web-animations-next-lite.min.js","sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/timeline.js","src/web-animations-next-animation.js","src/keyframe-effect-constructor.js","src/effect-callback.js","src/group-constructors.js"],"names":["webAnimationsShared","webAnimations1","webAnimationsNext","webAnimationsTesting","shared","makeTiming","timingInput","forGroup","timing","delay","endDelay","fill","iterationStart","iterations","duration","playbackRate","direction","easing","isNaN","undefined","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","isDeprecated","normalizeTimingInput","toTimingFunction","cubic","a","b","c","d","linear","x","f","m","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","cubicData","cubicBezierRe","exec","apply","this","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","preset","presets","calculateActiveDuration","repeatedDuration","calculatePhase","activeDuration","localTime","PhaseNone","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateScaledActiveTime","activeTime","startOffset","calculateIterationTime","iterationDuration","scaledActiveTime","Infinity","calculateCurrentIteration","iterationTime","floor","calculateTransformedTime","currentIteration","currentIterationIsOdd","currentDirectionIsForwards","directedTime","timeFraction","calculateTimeFraction","split","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","value","aliases","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","style","i","longProperty","longhandValue","normalizeKeyframes","effectInput","spaceKeyframes","length","keyframes","offset","previousIndex","previousOffset","j","Array","isArray","TypeError","originalKeyframe","keyframe","member","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","code","INVALID_MODIFICATION_ERR","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","document","createElementNS","borderWidthAliases","thin","medium","thick","borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","fontSize","xx-small","x-small","small","large","x-large","xx-large","fontWeight","normal","bold","outlineWidth","textShadow","none","boxShadow","silenced","feature","date","advice","plural","auxVerb","today","Date","expiry","setMonth","getMonth","console","warn","toDateString","deprecated","Error","scope","webAnimationsNextTick","t","timeline","window","currentTime","_discardAnimations","_animations","ticking","requestAnimationFrame","AnimationTimeline","prototype","getAnimations","getAnimationPlayers","animation","playState","play","effect","Animation","push","restartWebAnimationsNextTick","_animation","defineProperty","configurable","get","e","_isGroup","_childAnimations","_callback","_rebuildUnderlyingAnimation","cancel","KeyframeEffect","newUnderlyingAnimationForKeyframeEffect","bindAnimationForKeyframeEffect","SequenceEffect","GroupEffect","newUnderlyingAnimationForGroup","bindAnimationForGroup","_updateChildren","_timing","childAnimation","_arrangeChildren","groupChildDuration","bind","_setExternalAnimation","children","_constructChildren","child","paused","pause","startTime","_startTime",{"end":{"file":"src/animation.js","comments_before":[],"nlb":false,"endpos":2465,"pos":2454,"col":8,"line":72,"value":"currentTime","type":"name"},"start":{"file":"src/animation.js","comments_before":[],"nlb":false,"endpos":2465,"pos":2454,"col":8,"line":72,"value":"currentTime","type":"name"},"name":"currentTime"},"onfinish","_onfinish","v","target","call","_register","_forEachChild","oldCurrentTime","finished","source","awaitStartTime","time","finish","_removeChildren","reverse","addEventListener","handler","wrapped","_wrapper","removeEventListener","pop","KeyframeList","_frames","updatePendingGroups","updated","pendingGroups","shift","_timingInput","_normalizedKeyframes","_keyframes","getFrames","originalElementAnimate","Element","animate","nullTarget","keyframeEffect","bindAnimationForCustomEffect","groupAnimation","originalGetComputedStyle","getComputedStyle","enumerable","arguments","create","constructor","register","callback","_registered","callbacks","tick","updating","sort","left","right","_sequenceNumber","sequenceNumber","effectFunction","last","node","total","max","group","underlyingAnimation","ticker","tf","AnimationSequence","AnimationGroup"],"mappings":"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"}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations-next.min.js b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next.min.js new file mode 100644 index 0000000..f163ff3 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next.min.js @@ -0,0 +1,17 @@ +// Copyright 2014 Google Inc. All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +!function(a,b){b["true"]=a;var c={},d={},e={},f=null;!function(a){function b(b,c){var d={delay:0,endDelay:0,fill:c?"both":"none",iterationStart:0,iterations:1,duration:c?"auto":0,playbackRate:1,direction:"normal",easing:"linear"};return"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof d[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==p.indexOf(b[c]))return;if("direction"==c&&-1==q.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;d[c]=b[c]}}):d.duration=b,d}function c(a,c){var d=b(a,c);return d.easing=f(d.easing),d}function d(a,b,c,d){return 0>a||a>1||0>c||c>1?y:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}for(var g=0,h=1;;){var i=(g+h)/2,j=f(a,c,i);if(Math.abs(e-j)<.001)return f(b,d,i);e>j?g=i:h=i}}}function e(a,b){return function(c){if(c>=1)return 1;var d=1/a;return c+=b*d,c-c%d}}function f(a){var b=w.exec(a);if(b)return d.apply(this,b.slice(1).map(Number));var c=x.exec(a);if(c)return e(Number(c[1]),{start:r,middle:s,end:t}[c[2]]);var f=u[a];return f?f:y}function g(a){return Math.abs(h(a)/a.playbackRate)}function h(a){return a.duration*a.iterations}function i(a,b,c){return null==b?z:b<c.delay?A:b>=c.delay+a?B:C}function j(a,b,c,d,e){switch(d){case A:return"backwards"==b||"both"==b?0:null;case C:return c-e;case B:return"forwards"==b||"both"==b?a:null;case z:return null}}function k(a,b,c,d){return(d.playbackRate<0?b-a:b)*d.playbackRate+c}function l(a,b,c,d,e){return 1/0===c||c===-1/0||c-d==b&&e.iterations&&(e.iterations+e.iterationStart)%1==0?a:c%a}function m(a,b,c,d){return 0===c?0:b==a?d.iterationStart+d.iterations-1:Math.floor(c/a)}function n(a,b,c,d){var e=a%2>=1,f="normal"==d.direction||d.direction==(e?"alternate-reverse":"alternate"),g=f?c:b-c,h=g/b;return b*d.easing(h)}function o(a,b,c){var d=i(a,b,c),e=j(a,c.fill,b,d,c.delay);if(null===e)return null;if(0===a)return d===A?0:1;var f=c.iterationStart*c.duration,g=k(a,e,f,c),o=l(c.duration,h(c),g,f,c),p=m(c.duration,o,g,c);return n(p,c.duration,o,c)/c.duration}var p="backwards|forwards|both|none".split("|"),q="reverse|alternate|alternate-reverse".split("|"),r=1,s=.5,t=0,u={ease:d(.25,.1,.25,1),"ease-in":d(.42,0,1,1),"ease-out":d(0,0,.58,1),"ease-in-out":d(.42,0,.58,1),"step-start":e(1,r),"step-middle":e(1,s),"step-end":e(1,t)},v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",w=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),x=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,y=function(a){return a},z=0,A=1,B=2,C=3;a.makeTiming=b,a.normalizeTimingInput=c,a.calculateActiveDuration=g,a.calculateTimeFraction=o,a.calculatePhase=i,a.toTimingFunction=f}(c,f),function(a){function b(a,b){return a in h?h[a][b]||b:b}function c(a,c,d){var g=e[a];if(g){f.style[a]=c;for(var h in g){var i=g[h],j=f.style[i];d[i]=b(i,j)}}else d[a]=b(a,c)}function d(b){function d(){var a=e.length;null==e[a-1].offset&&(e[a-1].offset=1),a>1&&null==e[0].offset&&(e[0].offset=0);for(var b=0,c=e[0].offset,d=1;a>d;d++){var f=e[d].offset;if(null!=f){for(var g=1;d-b>g;g++)e[b+g].offset=c+(f-c)*g/(d-b);b=d,c=f}}}if(!Array.isArray(b)&&null!==b)throw new TypeError("Keyframes must be null or an array of keyframes");if(null==b)return[];for(var e=b.map(function(b){var d={};for(var e in b){var f=b[e];if("offset"==e){if(null!=f&&(f=Number(f),!isFinite(f)))throw new TypeError("keyframe offsets must be numbers.")}else{if("composite"==e)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};f="easing"==e?a.toTimingFunction(f):""+f}c(e,f,d)}return void 0==d.offset&&(d.offset=null),void 0==d.easing&&(d.easing=a.toTimingFunction("linear")),d}),f=!0,g=-1/0,h=0;h<e.length;h++){var i=e[h].offset;if(null!=i){if(g>i)throw{code:DOMException.INVALID_MODIFICATION_ERR,name:"InvalidModificationError",message:"Keyframes are not loosely sorted by offset. Sort or specify offsets."};g=i}else f=!1}return e=e.filter(function(a){return a.offset>=0&&a.offset<=1}),f||d(),e}var e={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},f=document.createElementNS("http://www.w3.org/1999/xhtml","div"),g={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:g,borderLeftWidth:g,borderRightWidth:g,borderTopWidth:g,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:g,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.normalizeKeyframes=d}(c,f),function(a){var b={};a.isDeprecated=function(a,c,d,e){var f=e?"are":"is",g=new Date,h=new Date(c);return h.setMonth(h.getMonth()+3),h>g?(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,!1):!0},a.deprecated=function(b,c,d,e){var f=e?"are":"is";if(a.isDeprecated(b,c,d,e))throw new Error(b+" "+f+" no longer supported. "+d)}}(c),function(){if(document.documentElement.animate){var a=document.documentElement.animate([],0),b=!0;if(a&&(b=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach(function(c){void 0===a[c]&&(b=!0)})),!b)return}!function(a,b){function c(a){for(var b={},c=0;c<a.length;c++)for(var d in a[c])if("offset"!=d&&"easing"!=d&&"composite"!=d){var e={offset:a[c].offset,easing:a[c].easing,value:a[c][d]};b[d]=b[d]||[],b[d].push(e)}for(var f in b){var g=b[f];if(0!=g[0].offset||1!=g[g.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return b}function d(a){var c=[];for(var d in a)for(var e=a[d],f=0;f<e.length-1;f++){var g=e[f].offset,h=e[f+1].offset,i=e[f].value,j=e[f+1].value;g==h&&(1==h?i=j:j=i),c.push({startTime:g,endTime:h,easing:e[f].easing,property:d,interpolation:b.propertyInterpolation(d,i,j)})}return c.sort(function(a,b){return a.startTime-b.startTime}),c}b.convertEffectInput=function(e){var f=a.normalizeKeyframes(e),g=c(f),h=d(g);return function(a,c){if(null!=c)h.filter(function(a){return 0>=c&&0==a.startTime||c>=1&&1==a.endTime||c>=a.startTime&&c<=a.endTime}).forEach(function(d){var e=c-d.startTime,f=d.endTime-d.startTime,g=0==f?0:d.easing(e/f);b.apply(a,d.property,d.interpolation(g))});else for(var d in g)"offset"!=d&&"easing"!=d&&"composite"!=d&&b.clear(a,d)}}}(c,d,f),function(a){function b(a,b,c){e[c]=e[c]||[],e[c].push([a,b])}function c(a,c,d){for(var e=0;e<d.length;e++){var f=d[e];b(a,c,f),/-/.test(f)&&b(a,c,f.replace(/-(.)/g,function(a,b){return b.toUpperCase()}))}}function d(b,c,d){for(var f=c==d?[]:e[b],g=0;f&&g<f.length;g++){var h=f[g][0](c),i=f[g][0](d);if(void 0!==h&&void 0!==i){var j=f[g][1](h,i);if(j){var k=a.Interpolation.apply(null,j);return function(a){return 0==a?c:1==a?d:k(a)}}}}return a.Interpolation(!1,!0,function(a){return a?d:c})}var e={};a.addPropertiesHandler=c,a.propertyInterpolation=d}(d,f),function(a,b){function c(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateTimeFraction(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d._isCurrent=function(d){var e=a.calculatePhase(c,d,b);return e===PhaseActive||e===PhaseBefore},d}b.KeyframeEffect=function(d,e,f){var g,h=c(a.normalizeTimingInput(f)),i=b.convertEffectInput(e),j=function(){i(d,g)};return j._update=function(a){return g=h(a),null!==g},j._clear=function(){i(d,null)},j._hasSameTarget=function(a){return d===a},j._isCurrent=h._isCurrent,j._totalDuration=h._totalDuration,j},b.NullEffect=function(a){var b=function(){a&&(a(),a=null)};return b._update=function(){return null},b._totalDuration=0,b._isCurrent=function(){return!1},b._hasSameTarget=function(){return!1},b}}(c,d,f),function(a){function b(a,b,c){c.enumerable=!0,c.configurable=!0,Object.defineProperty(a,b,c)}function c(a){this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=a.style,this._length=0,this._isAnimatedProperty={};for(var b=0;b<this._style.length;b++){var c=this._style[b];this._surrogateStyle[c]=this._style[c]}this._updateIndices()}function d(a){if(!a._webAnimationsPatchedStyle){var d=new c(a);try{b(a,"style",{get:function(){return d}})}catch(e){a.style._set=function(b,c){a.style[b]=c},a.style._clear=function(b){a.style[b]=""}}a._webAnimationsPatchedStyle=a.style}}var e={cssText:1,length:1,parentRule:1},f={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},g={removeProperty:1,setProperty:1};c.prototype={get cssText(){return this._surrogateStyle.cssText},set cssText(a){for(var b={},c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;this._surrogateStyle.cssText=a,this._updateIndices();for(var c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;for(var d in b)this._isAnimatedProperty[d]||this._style.setProperty(d,this._surrogateStyle.getPropertyValue(d))},get length(){return this._surrogateStyle.length},get parentRule(){return this._style.parentRule},_updateIndices:function(){for(;this._length<this._surrogateStyle.length;)Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,get:function(a){return function(){return this._surrogateStyle[a]}}(this._length)}),this._length++;for(;this._length>this._surrogateStyle.length;)this._length--,Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,value:void 0})},_set:function(a,b){this._style[a]=b,this._isAnimatedProperty[a]=!0},_clear:function(a){this._style[a]=this._surrogateStyle[a],delete this._isAnimatedProperty[a]}};for(var h in f)c.prototype[h]=function(a,b){return function(){var c=this._surrogateStyle[a].apply(this._surrogateStyle,arguments);return b&&(this._isAnimatedProperty[arguments[0]]||this._style[a].apply(this._style,arguments),this._updateIndices()),c}}(h,h in g);for(var i in document.documentElement.style)i in e||i in f||!function(a){b(c.prototype,a,{get:function(){return this._surrogateStyle[a]},set:function(b){this._surrogateStyle[a]=b,this._updateIndices(),this._isAnimatedProperty[a]||(this._style[a]=b)}})}(i);a.apply=function(b,c,e){d(b),b.style._set(a.propertyName(c),e)},a.clear=function(b,c){b._webAnimationsPatchedStyle&&b.style._clear(a.propertyName(c))}}(d,f),function(a){window.Element.prototype.animate=function(b,c){return a.timeline._play(a.KeyframeEffect(this,b,c))}}(d),function(a){function b(a,c,d){if("number"==typeof a&&"number"==typeof c)return a*(1-d)+c*d;if("boolean"==typeof a&&"boolean"==typeof c)return.5>d?a:c;if(a.length==c.length){for(var e=[],f=0;f<a.length;f++)e.push(b(a[f],c[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+c}a.Interpolation=function(a,c,d){return function(e){return d(b(a,c,e))}}}(d,f),function(a){function b(a,b,c){return Math.max(Math.min(a,c),b)}function c(c,d,e){var f=a.dot(c,d);f=b(f,-1,1);var g=[];if(1===f)g=c;else for(var h=Math.acos(f),i=1*Math.sin(e*h)/Math.sqrt(1-f*f),j=0;4>j;j++)g.push(c[j]*(Math.cos(e*h)-f*i)+d[j]*i);return g}var d=function(){function a(a,b){for(var c=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],d=0;4>d;d++)for(var e=0;4>e;e++)for(var f=0;4>f;f++)c[d][e]+=b[d][f]*a[f][e];return c}function b(a){return 0==a[0][2]&&0==a[0][3]&&0==a[1][2]&&0==a[1][3]&&0==a[2][0]&&0==a[2][1]&&1==a[2][2]&&0==a[2][3]&&0==a[3][2]&&1==a[3][3]}function c(c,d,e,f,g){for(var h=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],i=0;4>i;i++)h[i][3]=g[i];for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[3][i]+=c[j]*h[j][i];var k=f[0],l=f[1],m=f[2],n=f[3],o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];o[0][0]=1-2*(l*l+m*m),o[0][1]=2*(k*l-m*n),o[0][2]=2*(k*m+l*n),o[1][0]=2*(k*l+m*n),o[1][1]=1-2*(k*k+m*m),o[1][2]=2*(l*m-k*n),o[2][0]=2*(k*m-l*n),o[2][1]=2*(l*m+k*n),o[2][2]=1-2*(k*k+l*l),h=a(h,o);var p=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];e[2]&&(p[2][1]=e[2],h=a(h,p)),e[1]&&(p[2][1]=0,p[2][0]=e[0],h=a(h,p)),e[0]&&(p[2][0]=0,p[1][0]=e[0],h=a(h,p));for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[i][j]*=d[i];return b(h)?[h[0][0],h[0][1],h[1][0],h[1][1],h[3][0],h[3][1]]:h[0].concat(h[1],h[2],h[3])}return c}();a.composeMatrix=d,a.quat=c}(d,f),function(a){var b=0,c=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};a.Animation=function(a){this._sequenceNumber=b++,this._currentTime=0,this._startTime=null,this.paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!1,this.onfinish=null,this._finishHandlers=[],this._effect=a,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},a.Animation.prototype={_ensureAlive:function(){this._inEffect=this._effect._update(this.playbackRate<0&&0===this.currentTime?-1:this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,a.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this.finished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(b){b=+b,isNaN(b)||(a.restart(),this.paused||null==this._startTime||(this._startTime=this._timeline.currentTime-b/this._playbackRate),this._currentTimePending=!1,this._currentTime!=b&&(this._tickCurrentTime(b,!0),a.invalidateEffects()))},get startTime(){return this._startTime},set startTime(b){b=+b,isNaN(b)||this.paused||this._idle||(this._startTime=b,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),a.invalidateEffects())},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var b=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!=b&&(this.currentTime=b)}},get finished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this.paused&&0!=this.playbackRate||this._currentTimePending?"pending":this.paused?"paused":this.finished?"finished":"running"},play:function(){this.paused=!1,(this.finished||this._idle)&&(this._currentTime=this._playbackRate>0?0:this._totalDuration,this._startTime=null,a.invalidateEffects()),this._finishedFlag=!1,a.restart(),this._idle=!1,this._ensureAlive()},pause:function(){this.finished||this.paused||this._idle||(this._currentTimePending=!0),this._startTime=null,this.paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1)},cancel:function(){this._inEffect=!1,this._idle=!0,this.currentTime=0,this._startTime=null},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(a,b){"function"==typeof b&&"finish"==a&&this._finishHandlers.push(b)},removeEventListener:function(a,b){if("finish"==a){var c=this._finishHandlers.indexOf(b);c>=0&&this._finishHandlers.splice(c,1)}},_fireEvents:function(a){var b=this.finished;if((b||this._idle)&&!this._finishedFlag){var d=new c(this,this._currentTime,a),e=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){e.forEach(function(a){a.call(d.target,d)})},0)}this._finishedFlag=b},_tick:function(a){return this._idle||this.paused||(null==this._startTime?this.startTime=a-this._currentTime/this.playbackRate:this.finished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),this._currentTimePending=!1,this._fireEvents(a),!this._idle&&(this._inEffect||!this._finishedFlag)}}}(d,f),function(a,b){function c(a){var b=i;i=[],g(a),b.forEach(function(b){b[1](a)}),m&&g(a),f()}function d(a,b){return a._sequenceNumber-b._sequenceNumber}function e(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function f(){n.forEach(function(a){a()}),n.length=0}function g(a){l=!1;var c=b.timeline;c.currentTime=a,c._animations.sort(d),k=!1;var e=c._animations;c._animations=[];var f=[],g=[];e=e.filter(function(b){return b._inTimeline=b._tick(a),b._inEffect?g.push(b._effect):f.push(b._effect),b.finished||b.paused||b._idle||(k=!0),b._inTimeline}),n.push.apply(n,f),n.push.apply(n,g),c._animations.push.apply(c._animations,e),m=!1,k&&requestAnimationFrame(function(){})}var h=window.requestAnimationFrame,i=[],j=0;window.requestAnimationFrame=function(a){var b=j++;return 0==i.length&&h(c),i.push([b,a]),b},window.cancelAnimationFrame=function(a){i.forEach(function(b){b[0]==a&&(b[1]=function(){})})},e.prototype={_play:function(c){c._timing=a.normalizeTimingInput(c.timing);var d=new b.Animation(c);return d._idle=!1,d._timeline=this,this._animations.push(d),b.restart(),b.invalidateEffects(),d}};var k=!1,l=!1;b.restart=function(){return k||(k=!0,requestAnimationFrame(function(){}),l=!0),l};var m=!1;b.invalidateEffects=function(){m=!0};var n=[],o=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){return m&&g(p.currentTime),f(),o.apply(this,arguments)}});var p=new e;b.timeline=p}(c,d,f),function(a){function b(a,b){for(var c=0,d=0;d<a.length;d++)c+=a[d]*b[d];return c}function c(a,b){return[a[0]*b[0]+a[4]*b[1]+a[8]*b[2]+a[12]*b[3],a[1]*b[0]+a[5]*b[1]+a[9]*b[2]+a[13]*b[3],a[2]*b[0]+a[6]*b[1]+a[10]*b[2]+a[14]*b[3],a[3]*b[0]+a[7]*b[1]+a[11]*b[2]+a[15]*b[3],a[0]*b[4]+a[4]*b[5]+a[8]*b[6]+a[12]*b[7],a[1]*b[4]+a[5]*b[5]+a[9]*b[6]+a[13]*b[7],a[2]*b[4]+a[6]*b[5]+a[10]*b[6]+a[14]*b[7],a[3]*b[4]+a[7]*b[5]+a[11]*b[6]+a[15]*b[7],a[0]*b[8]+a[4]*b[9]+a[8]*b[10]+a[12]*b[11],a[1]*b[8]+a[5]*b[9]+a[9]*b[10]+a[13]*b[11],a[2]*b[8]+a[6]*b[9]+a[10]*b[10]+a[14]*b[11],a[3]*b[8]+a[7]*b[9]+a[11]*b[10]+a[15]*b[11],a[0]*b[12]+a[4]*b[13]+a[8]*b[14]+a[12]*b[15],a[1]*b[12]+a[5]*b[13]+a[9]*b[14]+a[13]*b[15],a[2]*b[12]+a[6]*b[13]+a[10]*b[14]+a[14]*b[15],a[3]*b[12]+a[7]*b[13]+a[11]*b[14]+a[15]*b[15]]}function d(a){switch(a.t){case"rotatex":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,0,Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1];case"rotatey":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),0,-Math.sin(d),0,0,1,0,0,Math.sin(d),0,Math.cos(d),0,0,0,0,1];case"rotate":case"rotatez":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var e=a.d[0],f=a.d[1],g=a.d[2],b=a.d[3].rad||0,c=a.d[3].deg||0,d=c*Math.PI/180+b,h=e*e+f*f+g*g;if(0===h)e=1,f=0,g=0;else if(1!==h){var i=Math.sqrt(h);e/=i,f/=i,g/=i}var j=Math.sin(d/2),k=j*Math.cos(d/2),l=j*j;return[1-2*(f*f+g*g)*l,2*(e*f*l+g*k),2*(e*g*l-f*k),0,2*(e*f*l-g*k),1-2*(e*e+g*g)*l,2*(f*g*l+e*k),0,2*(e*g*l+f*k),2*(f*g*l-e*k),1-2*(e*e+f*f)*l,0,0,0,0,1];case"scale":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,1,0,0,0,0,1];case"scalex":return[a.d[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"scaley":return[1,0,0,0,0,a.d[0],0,0,0,0,1,0,0,0,0,1];case"scalez":return[1,0,0,0,0,1,0,0,0,0,a.d[0],0,0,0,0,1];case"scale3d":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,a.d[2],0,0,0,0,1];case"skew":var m=a.d[0].deg||0,n=a.d[0].rad||0,o=a.d[1].deg||0,p=a.d[1].rad||0,q=m*Math.PI/180+n,r=o*Math.PI/180+p;return[1,Math.tan(r),0,0,Math.tan(q),1,0,0,0,0,1,0,0,0,0,1];case"skewx":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,Math.tan(d),1,0,0,0,0,1,0,0,0,0,1];case"skewy":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,Math.tan(d),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":var e=a.d[0].px||0,f=a.d[1].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,0,1];case"translatex":var e=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,0,0,1];case"translatey":var f=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,f,0,1];case"translatez":var g=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,g,1];case"translate3d":var e=a.d[0].px||0,f=a.d[1].px||0,g=a.d[2].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,g,1];case"perspective":var s=a.d[0].px?-1/a.d[0].px:0;return[1,0,0,0,0,1,0,0,0,0,1,s,0,0,0,1];case"matrix":return[a.d[0],a.d[1],0,0,a.d[2],a.d[3],0,0,0,0,1,0,a.d[4],a.d[5],0,1];case"matrix3d":return a.d}}function e(a){return 0===a.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:a.map(d).reduce(c)}function f(a){return[g(e(a))]}var g=function(){function a(a){return a[0][0]*a[1][1]*a[2][2]+a[1][0]*a[2][1]*a[0][2]+a[2][0]*a[0][1]*a[1][2]-a[0][2]*a[1][1]*a[2][0]-a[1][2]*a[2][1]*a[0][0]-a[2][2]*a[0][1]*a[1][0]}function c(b){for(var c=1/a(b),d=b[0][0],e=b[0][1],f=b[0][2],g=b[1][0],h=b[1][1],i=b[1][2],j=b[2][0],k=b[2][1],l=b[2][2],m=[[(h*l-i*k)*c,(f*k-e*l)*c,(e*i-f*h)*c,0],[(i*j-g*l)*c,(d*l-f*j)*c,(f*g-d*i)*c,0],[(g*k-h*j)*c,(j*e-d*k)*c,(d*h-e*g)*c,0]],n=[],o=0;3>o;o++){for(var p=0,q=0;3>q;q++)p+=b[3][q]*m[q][o];n.push(p)}return n.push(1),m.push(n),m}function d(a){return[[a[0][0],a[1][0],a[2][0],a[3][0]],[a[0][1],a[1][1],a[2][1],a[3][1]],[a[0][2],a[1][2],a[2][2],a[3][2]],[a[0][3],a[1][3],a[2][3],a[3][3]]]}function e(a,b){for(var c=[],d=0;4>d;d++){for(var e=0,f=0;4>f;f++)e+=a[f]*b[f][d];c.push(e)}return c}function f(a){var b=g(a);return[a[0]/b,a[1]/b,a[2]/b]}function g(a){return Math.sqrt(a[0]*a[0]+a[1]*a[1]+a[2]*a[2])}function h(a,b,c,d){return[c*a[0]+d*b[0],c*a[1]+d*b[1],c*a[2]+d*b[2]]}function i(a,b){return[a[1]*b[2]-a[2]*b[1],a[2]*b[0]-a[0]*b[2],a[0]*b[1]-a[1]*b[0]]}function j(j){var k=[j.slice(0,4),j.slice(4,8),j.slice(8,12),j.slice(12,16)];if(1!==k[3][3])return null;for(var l=[],m=0;4>m;m++)l.push(k[m].slice());for(var m=0;3>m;m++)l[m][3]=0;if(0===a(l))return!1;var n,o=[];if(k[0][3]||k[1][3]||k[2][3]){o.push(k[0][3]),o.push(k[1][3]),o.push(k[2][3]),o.push(k[3][3]);var p=c(l),q=d(p);n=e(o,q)}else n=[0,0,0,1];var r=k[3].slice(0,3),s=[];s.push(k[0].slice(0,3));var t=[];t.push(g(s[0])),s[0]=f(s[0]);var u=[];s.push(k[1].slice(0,3)),u.push(b(s[0],s[1])),s[1]=h(s[1],s[0],1,-u[0]),t.push(g(s[1])),s[1]=f(s[1]),u[0]/=t[1],s.push(k[2].slice(0,3)),u.push(b(s[0],s[2])),s[2]=h(s[2],s[0],1,-u[1]),u.push(b(s[1],s[2])),s[2]=h(s[2],s[1],1,-u[2]),t.push(g(s[2])),s[2]=f(s[2]),u[1]/=t[2],u[2]/=t[2];var v=i(s[1],s[2]);if(b(s[0],v)<0)for(var m=0;3>m;m++)t[m]*=-1,s[m][0]*=-1,s[m][1]*=-1,s[m][2]*=-1;var w,x,y=s[0][0]+s[1][1]+s[2][2]+1;return y>1e-4?(w=.5/Math.sqrt(y),x=[(s[2][1]-s[1][2])*w,(s[0][2]-s[2][0])*w,(s[1][0]-s[0][1])*w,.25/w]):s[0][0]>s[1][1]&&s[0][0]>s[2][2]?(w=2*Math.sqrt(1+s[0][0]-s[1][1]-s[2][2]),x=[.25*w,(s[0][1]+s[1][0])/w,(s[0][2]+s[2][0])/w,(s[2][1]-s[1][2])/w]):s[1][1]>s[2][2]?(w=2*Math.sqrt(1+s[1][1]-s[0][0]-s[2][2]),x=[(s[0][1]+s[1][0])/w,.25*w,(s[1][2]+s[2][1])/w,(s[0][2]-s[2][0])/w]):(w=2*Math.sqrt(1+s[2][2]-s[0][0]-s[1][1]),x=[(s[0][2]+s[2][0])/w,(s[1][2]+s[2][1])/w,.25*w,(s[1][0]-s[0][1])/w]),[r,t,u,x,n]}return j}();a.dot=b,a.makeMatrixDecomposition=f}(d,f),function(a){function b(a,b){var c=a.exec(b);return c?(c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]):void 0}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);return c?[c[0],c[1].replace(/^\s*/,"")]:void 0}function d(a,d,e){a=c.bind(null,a);for(var f=[];;){var g=a(e);if(!g)return[f,e];if(f.push(g[0]),e=g[1],g=b(d,e),!g||""==g[1])return[f,e];e=g[1]}}function e(a,b){for(var c=0,d=0;d<b.length&&(!/\s|,/.test(b[d])||0!=c);d++)if("("==b[d])c++;else if(")"==b[d]&&(c--,0==c&&d++,0>=c))break;var e=a(b.substr(0,d));return void 0==e?void 0:[e,b.substr(d)]}function f(a,b){for(var c=a,d=b;c&&d;)c>d?c%=d:d%=c;return c=a*b/(c+d)}function g(a){return function(b){var c=a(b);return c&&(c[0]=void 0),c}}function h(a,b){return function(c){var d=a(c);return d?d:[b,c]}}function i(b,c){for(var d=[],e=0;e<b.length;e++){var f=a.consumeTrimmed(b[e],c);if(!f||""==f[0])return;void 0!==f[0]&&d.push(f[0]),c=f[1]}return""==c?d:void 0}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;j>k;k++){var l=b(d[k%d.length],e[k%e.length]);if(!l)return;g.push(l[0]),h.push(l[1]),i.push(l[2])}return[g,h,function(b){var d=b.map(function(a,b){return i[b](a)}).join(c);return a?a(d):d}]}function k(a,b,c){for(var d=[],e=[],f=[],g=0,h=0;h<c.length;h++)if("function"==typeof c[h]){var i=c[h](a[g],b[g++]);d.push(i[0]),e.push(i[1]),f.push(i[2])}else!function(a){d.push(!1),e.push(!1),f.push(function(){return c[a]})}(h);return[d,e,function(a){for(var b="",c=0;c<a.length;c++)b+=f[c](a[c]);return b}]}a.consumeToken=b,a.consumeTrimmed=c,a.consumeRepeated=d,a.consumeParenthesised=e,a.ignore=g,a.optional=h,a.consumeList=i,a.mergeNestedRepeated=j.bind(null,null),a.mergeWrappedNestedRepeated=j,a.mergeList=k}(d),function(a){function b(b){function c(b){var c=a.consumeToken(/^inset/i,b);if(c)return d.inset=!0,c;var c=a.consumeLengthOrPercent(b);if(c)return d.lengths.push(c[0]),c;var c=a.consumeColor(b);return c?(d.color=c[0],c):void 0}var d={inset:!1,lengths:[],color:null},e=a.consumeRepeated(c,/^/,b);return e&&e[0].length?[d,e[1]]:void 0}function c(c){var d=a.consumeRepeated(b,/^,/,c);return d&&""==d[1]?d[0]:void 0}function d(b,c){for(;b.lengths.length<Math.max(b.lengths.length,c.lengths.length);)b.lengths.push({px:0});for(;c.lengths.length<Math.max(b.lengths.length,c.lengths.length);)c.lengths.push({px:0});if(b.inset==c.inset&&!!b.color==!!c.color){for(var d,e=[],f=[[],0],g=[[],0],h=0;h<b.lengths.length;h++){var i=a.mergeDimensions(b.lengths[h],c.lengths[h],2==h);f[0].push(i[0]),g[0].push(i[1]),e.push(i[2])}if(b.color&&c.color){var j=a.mergeColors(b.color,c.color);f[1]=j[0],g[1]=j[1],d=j[2]}return[f,g,function(a){for(var c=b.inset?"inset ":" ",f=0;f<e.length;f++)c+=e[f](a[0][f])+" ";return d&&(c+=d(a[1])),c}]}}function e(b,c,d,e){function f(a){return{inset:a,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var g=[],h=[],i=0;i<d.length||i<e.length;i++){var j=d[i]||f(e[i].inset),k=e[i]||f(d[i].inset);g.push(j),h.push(k)}return a.mergeNestedRepeated(b,c,g,h)}var f=e.bind(null,d,", ");a.addPropertiesHandler(c,f,["box-shadow","text-shadow"])}(d),function(a){function b(a){return a.toFixed(3).replace(".000","")}function c(a,b,c){return Math.min(b,Math.max(a,c))}function d(a){return/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a)?Number(a):void 0}function e(a,c){return[a,c,b]}function f(a,b){return 0!=a?h(0,1/0)(a,b):void 0}function g(a,b){return[a,b,function(a){return Math.round(c(1,1/0,a))}]}function h(a,d){return function(e,f){return[e,f,function(e){return b(c(a,d,e))}]}}function i(a,b){return[a,b,Math.round]}a.clamp=c,a.addPropertiesHandler(d,h(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(d,h(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(d,f,["flex-grow","flex-shrink"]),a.addPropertiesHandler(d,g,["orphans","widows"]),a.addPropertiesHandler(d,i,["z-index"]),a.parseNumber=d,a.mergeNumbers=e,a.numberToString=b}(d,f),function(a){function b(a,b){return"visible"==a||"visible"==b?[0,1,function(c){return 0>=c?a:c>=1?b:"visible"}]:void 0}a.addPropertiesHandler(String,b,["visibility"])}(d),function(a){function b(a){a=a.trim(),e.fillStyle="#000",e.fillStyle=a;var b=e.fillStyle;if(e.fillStyle="#fff",e.fillStyle=a,b==e.fillStyle){e.fillRect(0,0,1,1);var c=e.getImageData(0,0,1,1).data;e.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function c(b,c){return[b,c,function(b){function c(a){return Math.max(0,Math.min(255,a))}if(b[3])for(var d=0;3>d;d++)b[d]=Math.round(c(b[d]/b[3]));return b[3]=a.numberToString(a.clamp(0,1,b[3])),"rgba("+b.join(",")+")"}]}var d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=d.height=1;var e=d.getContext("2d");a.addPropertiesHandler(b,c,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,b),a.mergeColors=c}(d,f),function(a,b){function c(a,b){if(b=b.trim().toLowerCase(),"0"==b&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var c={};b=b.replace(a,function(a){return c[a]=null,"U"+a});for(var d="U("+a.source+")",e=b.replace(/[-+]?(\d*\.)?\d+/g,"N").replace(new RegExp("N"+d,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),f=[/N\*(D)/g,/(N|D)[*/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],g=0;g<f.length;)f[g].test(e)?(e=e.replace(f[g],"$1"),g=0):g++;if("D"==e){for(var h in c){var i=eval(b.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(d,"g"),"*0"));if(!isFinite(i))return;c[h]=i}return c}}}function d(a,b){return e(a,b,!0)}function e(b,c,d){var e,f=[];for(e in b)f.push(e);for(e in c)f.indexOf(e)<0&&f.push(e);return b=f.map(function(a){return b[a]||0}),c=f.map(function(a){return c[a]||0}),[b,c,function(b){var c=b.map(function(c,e){return 1==b.length&&d&&(c=Math.max(c,0)),a.numberToString(c)+f[e]}).join(" + ");return b.length>1?"calc("+c+")":c}]}var f="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",g=c.bind(null,new RegExp(f,"g")),h=c.bind(null,new RegExp(f+"|%","g")),i=c.bind(null,/deg|rad|grad|turn/g);a.parseLength=g,a.parseLengthOrPercent=h,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,h),a.parseAngle=i,a.mergeDimensions=e;var j=a.consumeParenthesised.bind(null,g),k=a.consumeRepeated.bind(void 0,j,/^/),l=a.consumeRepeated.bind(void 0,k,/^,/);a.consumeSizePairList=l;var m=function(a){var b=l(a);return b&&""==b[1]?b[0]:void 0},n=a.mergeNestedRepeated.bind(void 0,d," "),o=a.mergeNestedRepeated.bind(void 0,n,",");a.mergeNonNegativeSizePair=n,a.addPropertiesHandler(m,o,["background-size"]),a.addPropertiesHandler(h,d,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),a.addPropertiesHandler(h,e,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","text-indent","top","vertical-align","word-spacing"])}(d,f),function(a){function b(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function c(c){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,b,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],c);return d&&4==d[0].length?d[0]:void 0}function d(b,c){return"auto"==b||"auto"==c?[!0,!1,function(d){var e=d?b:c;if("auto"==e)return"auto";var f=a.mergeDimensions(e,e);return f[2](f[0])}]:a.mergeDimensions(b,c)}function e(a){return"rect("+a+")"}var f=a.mergeWrappedNestedRepeated.bind(null,e,d,", ");a.parseBox=c,a.mergeBoxes=f,a.addPropertiesHandler(c,f,["clip"]) +}(d,f),function(a){function b(a){return function(b){var c=0;return a.map(function(a){return a===j?b[c++]:a})}}function c(a){return a}function d(b){if(b=b.toLowerCase().trim(),"none"==b)return[];for(var c,d=/\s*(\w+)\(([^)]*)\)/g,e=[],f=0;c=d.exec(b);){if(c.index!=f)return;f=c.index+c[0].length;var g=c[1],h=m[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var n=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(p=q?{A:function(b){return"0"==b.trim()?l:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:l,n:n[0],t:k}[r],void 0===p)return;n.push(p)}if(e.push({t:g,d:n}),d.lastIndex==b.length)return e}}function e(a){return a.toFixed(6).replace(".000000","")}function f(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var f=a.makeMatrixDecomposition(c)}return null==d[0]||null==f[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),f[0].push(1),[d,f,function(b){var c=a.quat(d[0][3],f[0][3],b[5]),g=a.composeMatrix(b[0],b[1],b[2],c,b[4]),h=g.map(e).join(",");return h}])}function g(a){return a.replace(/[xy]/,"")}function h(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function i(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var i=0;i<b.length;i++){var j=b[i].t,k=b[i].d,l="scale"==j.substr(0,5)?1:0;c.push({t:j,d:k.map(function(a){if("number"==typeof a)return l;var b={};for(var c in a)b[c]=l;return b})})}}var n=function(a,b){return"perspective"==a&&"perspective"==b||("matrix"==a||"matrix3d"==a)&&("matrix"==b||"matrix3d"==b)},o=[],p=[],q=[];if(b.length!=c.length){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var i=0;i<b.length;i++){var j,s=b[i].t,t=c[i].t,u=b[i].d,v=c[i].d,w=m[s],x=m[t];if(n(s,t)){if(!d)return;var r=f([b[i]],[c[i]]);o.push(r[0]),p.push(r[1]),q.push(["matrix",[r[2]]])}else{if(s==t)j=s;else if(w[2]&&x[2]&&g(s)==g(t))j=g(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||h(s)!=h(t)){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=h(s),u=w[1](u),v=x[1](v)}for(var y=[],z=[],A=[],B=0;B<u.length;B++){var C="number"==typeof u[B]?a.mergeNumbers:a.mergeDimensions,r=C(u[B],v[B]);y[B]=r[0],z[B]=r[1],A.push(r[2])}o.push(y),p.push(z),q.push([j,A])}}if(e){var D=o;o=p,p=D}return[o,p,function(a){return a.map(function(a,b){var c=a.map(function(a,c){return q[b][1][c](a)}).join(",");return"matrix"==q[b][0]&&16==c.split(",").length&&(q[b][0]="matrix3d"),q[b][0]+"("+c+")"}).join(" ")}]}var j=null,k={px:0},l={deg:0},m={matrix:["NNNNNN",[j,j,0,0,j,j,0,0,0,0,1,0,j,j,0,1],c],matrix3d:["NNNNNNNNNNNNNNNN",c],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",b([j,j,1]),c],scalex:["N",b([j,1,1]),b([j,1])],scaley:["N",b([1,j,1]),b([1,j])],scalez:["N",b([1,1,j])],scale3d:["NNN",c],skew:["Aa",null,c],skewx:["A",null,b([j,l])],skewy:["A",null,b([l,j])],translate:["Tt",b([j,j,k]),c],translatex:["T",b([j,k,k]),b([j,k])],translatey:["T",b([k,j,k]),b([k,j])],translatez:["L",b([k,k,j])],translate3d:["TTL",c]};a.addPropertiesHandler(d,i,["transform"])}(d,f),function(a){function b(a){var b=Number(a);return isNaN(b)||100>b||b>900||b%100!==0?void 0:b}function c(b){return b=100*Math.round(b/100),b=a.clamp(100,900,b),400===b?"normal":700===b?"bold":String(b)}function d(a,b){return[a,b,c]}a.addPropertiesHandler(b,d,["font-weight"])}(d),function(a){function b(a){var b={};for(var c in a)b[c]=-a[c];return b}function c(b){return a.consumeToken(/^(left|center|right|top|bottom)\b/i,b)||a.consumeLengthOrPercent(b)}function d(b,d){var e=a.consumeRepeated(c,/^/,d);if(e&&""==e[1]){var f=e[0];if(f[0]=f[0]||"center",f[1]=f[1]||"center",3==b&&(f[2]=f[2]||{px:0}),f.length==b){if(/top|bottom/.test(f[0])||/left|right/.test(f[1])){var h=f[0];f[0]=f[1],f[1]=h}if(/left|right|center|Object/.test(f[0])&&/top|bottom|center|Object/.test(f[1]))return f.map(function(a){return"object"==typeof a?a:g[a]})}}}function e(d){var e=a.consumeRepeated(c,/^/,d);if(e){for(var f=e[0],h=[{"%":50},{"%":50}],i=0,j=!1,k=0;k<f.length;k++){var l=f[k];"string"==typeof l?(j=/bottom|right/.test(l),i={left:0,right:0,center:i,top:1,bottom:1}[l],h[i]=g[l],"center"==l&&i++):(j&&(l=b(l),l["%"]=(l["%"]||0)+100),h[i]=l,i++,j=!1)}return[h,e[1]]}}function f(b){var c=a.consumeRepeated(e,/^,/,b);return c&&""==c[1]?c[0]:void 0}var g={left:{"%":0},center:{"%":50},right:{"%":100},top:{"%":0},bottom:{"%":100}},h=a.mergeNestedRepeated.bind(null,a.mergeDimensions," ");a.addPropertiesHandler(d.bind(null,3),h,["transform-origin"]),a.addPropertiesHandler(d.bind(null,2),h,["perspective-origin"]),a.consumePosition=e,a.mergeOffsetList=h;var i=a.mergeNestedRepeated.bind(null,h,", ");a.addPropertiesHandler(f,i,["background-position","object-position"])}(d),function(a){function b(b){var c=a.consumeToken(/^circle/,b);if(c&&c[0])return["circle"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),d,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],c[1]));var f=a.consumeToken(/^ellipse/,b);if(f&&f[0])return["ellipse"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),e,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],f[1]));var g=a.consumeToken(/^polygon/,b);return g&&g[0]?["polygon"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),a.optional(a.consumeToken.bind(void 0,/^nonzero\s*,|^evenodd\s*,/),"nonzero,"),a.consumeSizePairList,a.ignore(a.consumeToken.bind(void 0,/^\)/))],g[1])):void 0}function c(b,c){return b[0]===c[0]?"circle"==b[0]?a.mergeList(b.slice(1),c.slice(1),["circle(",a.mergeDimensions," at ",a.mergeOffsetList,")"]):"ellipse"==b[0]?a.mergeList(b.slice(1),c.slice(1),["ellipse(",a.mergeNonNegativeSizePair," at ",a.mergeOffsetList,")"]):"polygon"==b[0]&&b[1]==c[1]?a.mergeList(b.slice(2),c.slice(2),["polygon(",b[1],g,")"]):void 0:void 0}var d=a.consumeParenthesised.bind(null,a.parseLengthOrPercent),e=a.consumeRepeated.bind(void 0,d,/^/),f=a.mergeNestedRepeated.bind(void 0,a.mergeDimensions," "),g=a.mergeNestedRepeated.bind(void 0,f,",");a.addPropertiesHandler(b,c,["shape-outside"])}(d),function(a){function b(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(c[a]=b)})}var c={};b("transform",["webkitTransform","msTransform"]),b("transformOrigin",["webkitTransformOrigin"]),b("perspective",["webkitPerspective"]),b("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return c[a]||a}}(d,f)}(),!function(a,b){function c(a){var b=window.document.timeline;b.currentTime=a,b._discardAnimations(),0==b._animations.length?d=!1:requestAnimationFrame(c)}b.AnimationTimeline=function(){this._animations=[],this.currentTime=void 0},b.AnimationTimeline.prototype={getAnimations:function(){return this._discardAnimations(),this._animations.slice()},getAnimationPlayers:function(){return a.deprecated("AnimationTimeline.getAnimationPlayers","2015-03-23","Use AnimationTimeline.getAnimations instead."),this.getAnimations()},_discardAnimations:function(){this._animations=this._animations.filter(function(a){return"finished"!=a.playState&&"idle"!=a.playState})},play:function(a){var c=new b.Animation(a);return this._animations.push(c),b.restartWebAnimationsNextTick(),c._animation.play(),c}};var d=!1;b.restartWebAnimationsNextTick=function(){d||(d=!0,requestAnimationFrame(c))};var e=new b.AnimationTimeline;b.timeline=e;try{Object.defineProperty(window.document,"timeline",{configurable:!0,get:function(){return e}})}catch(f){}try{window.document.timeline=e}catch(f){}}(c,e,f),function(a,b){b.Animation=function(a){this.effect=a,a&&(a.animation=this),this._isGroup=!1,this._animation=null,this._childAnimations=[],this._callback=null,this._rebuildUnderlyingAnimation(),this._animation.cancel()},b.Animation.prototype={_rebuildUnderlyingAnimation:function(){this._animation&&(this._animation.cancel(),this._animation=null),(!this.effect||this.effect instanceof window.KeyframeEffect)&&(this._animation=b.newUnderlyingAnimationForKeyframeEffect(this.effect),b.bindAnimationForKeyframeEffect(this)),(this.effect instanceof window.SequenceEffect||this.effect instanceof window.GroupEffect)&&(this._animation=b.newUnderlyingAnimationForGroup(this.effect),b.bindAnimationForGroup(this))},_updateChildren:function(){if(this.effect&&"idle"!=this.playState){var a=this.effect._timing.delay;this._childAnimations.forEach(function(c){this._arrangeChildren(c,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c.effect))}.bind(this))}},_setExternalAnimation:function(a){if(this.effect&&this._isGroup)for(var b=0;b<this.effect.children.length;b++)this.effect.children[b].animation=a,this._childAnimations[b]._setExternalAnimation(a)},_constructChildren:function(){if(this.effect&&this._isGroup){var a=this.effect._timing.delay;this.effect.children.forEach(function(c){var d=window.document.timeline.play(c);this._childAnimations.push(d),d.playbackRate=this.playbackRate,this.paused&&d.pause(),c.animation=this.effect.animation,this._arrangeChildren(d,a),this.effect instanceof window.SequenceEffect&&(a+=b.groupChildDuration(c))}.bind(this))}},_arrangeChildren:function(a,b){null===this.startTime?(a.currentTime=this.currentTime-b/this.playbackRate,a._startTime=null):a.startTime!==this.startTime+b/this.playbackRate&&(a.startTime=this.startTime+b/this.playbackRate)},get paused(){return this._animation.paused},get playState(){return this._animation.playState},get onfinish(){return this._onfinish},set onfinish(a){"function"==typeof a?(this._onfinish=a,this._animation.onfinish=function(b){b.target=this,a.call(this,b)}.bind(this)):(this._animation.onfinish=a,this.onfinish=this._animation.onfinish)},get currentTime(){return this._animation.currentTime},set currentTime(a){this._animation.currentTime=a,this._register(),this._forEachChild(function(b,c){b.currentTime=a-c})},get startTime(){return this._animation.startTime},set startTime(a){this._animation.startTime=a,this._register(),this._forEachChild(function(b,c){b.startTime=a+c})},get playbackRate(){return this._animation.playbackRate},set playbackRate(a){var b=this.currentTime;this._animation.playbackRate=a,this._forEachChild(function(b){b.playbackRate=a}),"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!==b&&(this.currentTime=b)},get finished(){return this._animation.finished},get source(){return a.deprecated("Animation.source","2015-03-23","Use Animation.effect instead."),this.effect},play:function(){this._animation.play(),this._register(),b.awaitStartTime(this),this._forEachChild(function(a){var b=a.currentTime;a.play(),a.currentTime=b})},pause:function(){this._animation.pause(),this._register(),this._forEachChild(function(a){a.pause()})},finish:function(){this._animation.finish(),this._register()},cancel:function(){this._animation.cancel(),this._register(),this._removeChildren()},reverse:function(){var a=this.currentTime;this._animation.reverse(),this._forEachChild(function(a){a.reverse()}),null!==a&&(this.currentTime=a)},addEventListener:function(a,b){var c=b;"function"==typeof b&&(c=function(a){a.target=this,b.call(this,a)}.bind(this),b._wrapper=c),this._animation.addEventListener(a,c)},removeEventListener:function(a,b){this._animation.removeEventListener(a,b&&b._wrapper||b)},_removeChildren:function(){for(;this._childAnimations.length;)this._childAnimations.pop().cancel()},_forEachChild:function(b){var c=0;if(this.effect.children&&this._childAnimations.length<this.effect.children.length&&this._constructChildren(),this._childAnimations.forEach(function(a){b.call(this,a,c),this.effect instanceof window.SequenceEffect&&(c+=a.effect.activeDuration)}.bind(this)),"pending"!=this._animation.playState){var d=this.effect._timing,e=this._animation.currentTime;null!==e&&(e=a.calculateTimeFraction(a.calculateActiveDuration(d),e,d)),(null==e||isNaN(e))&&this._removeChildren()}}}}(c,e,f),function(a,b){function c(b){this._frames=a.normalizeKeyframes(b)}function d(){for(var a=!1;g.length;)g.shift()._updateChildren(),a=!0;return a}b.KeyframeEffect=function(b,d,e){return this.target=b,this._timingInput=e,this._timing=a.normalizeTimingInput(e),this.timing=a.makeTiming(e),this._normalizedKeyframes="function"==typeof d?d:new c(d),this._keyframes=d,this.activeDuration=a.calculateActiveDuration(this._timing),this},b.KeyframeEffect.prototype={getFrames:function(){return"function"==typeof this._normalizedKeyframes?this._normalizedKeyframes:this._normalizedKeyframes._frames},get effect(){return a.deprecated("KeyframeEffect.effect","2015-03-23","Use KeyframeEffect.getFrames() instead."),this._normalizedKeyframes}};var e=Element.prototype.animate;Element.prototype.animate=function(a,c){return b.timeline.play(new b.KeyframeEffect(this,a,c))};var f=document.createElementNS("http://www.w3.org/1999/xhtml","div");b.newUnderlyingAnimationForKeyframeEffect=function(a){var b=a.target||f,c=a._keyframes;return"function"==typeof c&&(c=[]),e.apply(b,[c,a._timingInput])},b.bindAnimationForKeyframeEffect=function(a){a.effect&&"function"==typeof a.effect._normalizedKeyframes&&b.bindAnimationForCustomEffect(a)};var g=[];b.awaitStartTime=function(a){null===a.startTime&&a._isGroup&&(0==g.length&&requestAnimationFrame(d),g.push(a))};var h=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){var a=h.apply(this,arguments);return d()&&(a=h.apply(this,arguments)),a}}),window.KeyframeEffect=b.KeyframeEffect,window.Element.prototype.getAnimations=function(){return document.timeline.getAnimations().filter(function(a){return null!==a.effect&&a.effect.target==this}.bind(this))},window.Element.prototype.getAnimationPlayers=function(){return a.deprecated("Element.getAnimationPlayers","2015-03-23","Use Element.getAnimations instead."),this.getAnimations()},window.Animation=function(){a.deprecated("window.Animation","2015-03-23","Use window.KeyframeEffect instead."),window.KeyframeEffect.apply(this,arguments)},window.Animation.prototype=Object.create(window.KeyframeEffect.prototype),window.Animation.prototype.constructor=window.Animation}(c,e,f),function(a,b){function c(a){a._registered||(a._registered=!0,f.push(a),g||(g=!0,requestAnimationFrame(d)))}function d(){var a=f;f=[],a.sort(function(a,b){return a._sequenceNumber-b._sequenceNumber}),a=a.filter(function(a){a();var b=a._animation?a._animation.playState:"idle";return"running"!=b&&"pending"!=b&&(a._registered=!1),a._registered}),f.push.apply(f,a),f.length?(g=!0,requestAnimationFrame(d)):g=!1}var e=(document.createElementNS("http://www.w3.org/1999/xhtml","div"),0);b.bindAnimationForCustomEffect=function(b){var d=b.effect.target,f=b.effect._normalizedKeyframes,g=b.effect.timing,h=null;g=a.normalizeTimingInput(g);var i=function(){var c=i._animation?i._animation.currentTime:null;null!==c&&(c=a.calculateTimeFraction(a.calculateActiveDuration(g),c,g),isNaN(c)&&(c=null)),c!==h&&f(c,d,b.effect),h=c};i._animation=b,i._registered=!1,i._sequenceNumber=e++,b._callback=i,c(i)};var f=[],g=!1;b.Animation.prototype._register=function(){this._callback&&c(this._callback)}}(c,e,f),function(a,b){function c(a){return a._timing.delay+a.activeDuration+a._timing.endDelay}function d(b,c){this.children=b||[],this._timing=a.normalizeTimingInput(c,!0),this.timing=a.makeTiming(c,!0),"auto"===this._timing.duration&&(this._timing.duration=this.activeDuration)}window.SequenceEffect=function(){d.apply(this,arguments)},window.GroupEffect=function(){d.apply(this,arguments)},window.SequenceEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a+=c(b)}),Math.max(a,0)}},window.GroupEffect.prototype={get activeDuration(){var a=0;return this.children.forEach(function(b){a=Math.max(a,c(b))}),a}},b.newUnderlyingAnimationForGroup=function(c){var d,e=null,f=function(b){var c=d._wrapper;return"pending"!=c.playState&&c.effect?null==b?void c._removeChildren():0==b&&c.playbackRate<0&&(e||(e=a.normalizeTimingInput(c.effect.timing)),b=a.calculateTimeFraction(a.calculateActiveDuration(e),-1,e),isNaN(b)||null==b)?(c._forEachChild(function(a){a.currentTime=-1}),void c._removeChildren()):void 0:void 0};return d=b.timeline.play(new b.KeyframeEffect(null,f,c._timing))},b.bindAnimationForGroup=function(a){a._animation._wrapper=a,a._isGroup=!0,b.awaitStartTime(a),a._constructChildren(),a._setExternalAnimation(a)},b.groupChildDuration=c,window.AnimationSequence=function(){a.deprecated("window.AnimationSequence","2015-03-23","Use window.SequenceEffect instead."),window.SequenceEffect.apply(this,arguments)},window.AnimationSequence.prototype=Object.create(window.SequenceEffect.prototype),window.AnimationSequence.prototype.constructor=window.AnimationSequence,window.AnimationGroup=function(){a.deprecated("window.AnimationGroup","2015-03-23","Use window.GroupEffect instead."),window.GroupEffect.apply(this,arguments)},window.AnimationGroup.prototype=Object.create(window.GroupEffect.prototype),window.AnimationGroup.prototype.constructor=window.AnimationGroup}(c,e,f)}({},function(){return this}()); +//# sourceMappingURL=web-animations-next.min.js.map
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations-next.min.js.map b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next.min.js.map new file mode 100644 index 0000000..67ffbe0 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations-next.min.js.map @@ -0,0 +1 @@ +{"version":3,"file":"web-animations-next.min.js","sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/keyframe-interpolations.js","src/property-interpolation.js","src/keyframe-effect.js","src/apply-preserving-inline-style.js","src/element-animatable.js","src/interpolation.js","src/matrix-interpolation.js","src/animation.js","src/tick.js","src/timeline.js","src/web-animations-next-animation.js","src/keyframe-effect-constructor.js","src/effect-callback.js","src/group-constructors.js"],"names":["webAnimationsShared","webAnimations1","webAnimationsNext","webAnimationsTesting","shared","makeTiming","timingInput","forGroup","timing","delay","endDelay","fill","iterationStart","iterations","duration","playbackRate","direction","easing","isNaN","undefined","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","isDeprecated","normalizeTimingInput","toTimingFunction","cubic","a","b","c","d","linear","x","f","m","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","cubicData","cubicBezierRe","exec","apply","this","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","preset","presets","calculateActiveDuration","repeatedDuration","calculatePhase","activeDuration","localTime","PhaseNone","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateScaledActiveTime","activeTime","startOffset","calculateIterationTime","iterationDuration","scaledActiveTime","Infinity","calculateCurrentIteration","iterationTime","floor","calculateTransformedTime","currentIteration","currentIterationIsOdd","currentDirectionIsForwards","directedTime","timeFraction","calculateTimeFraction","split","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","value","aliases","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","style","i","longProperty","longhandValue","normalizeKeyframes","effectInput","spaceKeyframes","length","keyframes","offset","previousIndex","previousOffset","j","Array","isArray","TypeError","originalKeyframe","keyframe","member","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","code","INVALID_MODIFICATION_ERR","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","document","createElementNS","borderWidthAliases","thin","medium","thick","borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","fontSize","xx-small","x-small","small","large","x-large","xx-large","fontWeight","normal","bold","outlineWidth","textShadow","none","boxShadow","silenced","feature","date","advice","plural","auxVerb","today","Date","expiry","setMonth","getMonth","console","warn","toDateString","deprecated","Error","scope","makePropertySpecificKeyframeGroups","propertySpecificKeyframeGroups","propertySpecificKeyframe","push","groupName","group","makeInterpolations","interpolations","endTime","startValue","endValue","startTime","propertyInterpolation","leftInterpolation","rightInterpolation","convertEffectInput","target","fraction","interpolation","offsetFraction","localDuration","scaledLocalTime","clear","addPropertyHandler","parser","merger","propertyHandlers","addPropertiesHandler","properties","replace","toUpperCase","right","handlers","parsedLeft","parsedRight","interpolationArgs","Interpolation","t","interp","bool","left","testing","EffectTime","effectTime","keyframeEffect","_clear","_hasSameTarget","otherTarget","_isCurrent","_totalDuration","NullEffect","nullEffect","_update","configureProperty","descriptor","enumerable","configurable","defineProperty","object","AnimatedCSSStyleDeclaration","element","_surrogateStyle","_style","_isAnimatedProperty","_updateIndices","ensureStyleIsPatched","_webAnimationsPatchedStyle","animatedStyle","styleAttributes","cssText","parentRule","styleMethods","getPropertyCSSValue","getPropertyPriority","getPropertyValue","removeProperty","setProperty","styleMutatingMethods",{"end":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"start":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"name":"cssText"},"isAffectedProperty","text","_length","index","_set","method","prototype","modifiesStyle","arguments","documentElement","set","propertyName","window","Element","animate","timeline","_play","KeyframeEffect","interpolate","from","to","r","convertToString","clamp","max","fromQ","toQ","product","quat","acos","theta","sqrt","w","composeMatrix","multiply","k","is2D","translate","skew","matrix","perspective","z","rotMatrix","y","temp","scale","concat","sequenceNumber","AnimationEvent","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","now","Animation","effect","_sequenceNumber","_currentTime","_startTime","_playbackRate","_inTimeline","_finishedFlag","onfinish","_finishHandlers","_effect","_inEffect","_idle","_currentTimePending","_ensureAlive","_animations","_tickCurrentTime","newTime","ignoreLimit","finished","restart","_timeline","invalidateEffects","paused","oldCurrentTime","playState","play","pause","cancel","reverse","addEventListener","handler","removeEventListener","splice","_fireEvents","baseTime","event","setTimeout","_tick","processRafCallbacks","processing","rafCallbacks","tick","entry","needsRetick","applyPendingEffects","compareAnimations","leftAnimation","rightAnimation","InternalTimeline","performance","pendingEffects","hasRestartedThisFrame","updatingAnimations","newPendingClears","newPendingEffects","webAnimationsNextTick","_discardAnimations","ticking","requestAnimationFrame","AnimationTimeline","getAnimations","getAnimationPlayers","animation","restartWebAnimationsNextTick","_animation","get","e","_isGroup","_childAnimations","_callback","_rebuildUnderlyingAnimation","newUnderlyingAnimationForKeyframeEffect","bindAnimationForKeyframeEffect","SequenceEffect","GroupEffect","newUnderlyingAnimationForGroup","bindAnimationForGroup","_updateChildren","_timing","childAnimation","_arrangeChildren","groupChildDuration","bind","_setExternalAnimation","children","_constructChildren","child","_onfinish","v","call","_register","_forEachChild","source","awaitStartTime","time","finish","_removeChildren","wrapped","_wrapper","pop","KeyframeList","_frames","updatePendingGroups","updated","pendingGroups","shift","_timingInput","_normalizedKeyframes","_keyframes","getFrames","originalElementAnimate","nullTarget","bindAnimationForCustomEffect","groupAnimation","originalGetComputedStyle","getComputedStyle","create","constructor","register","callback","_registered","callbacks","updating","sort","effectFunction","last","node","total","underlyingAnimation","ticker","tf","AnimationSequence","AnimationGroup"],"mappings":"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"}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations.html b/third_party/polymer/v1_0/components/web-animations-js/web-animations.html new file mode 100644 index 0000000..b5de36c --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations.html @@ -0,0 +1,50 @@ +<!-- + Copyright 2014 Google Inc. All rights reserved. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<!-- WARNING: This file is DEPRECATED, for development purposes use + web-animations*.dev.html instead or depend on + web-animations*.min.js in the web-animations-js + repository --> + +<script src="src/dev.js"></script> +<script src="src/scope.js"></script> +<script src="src/deprecation.js"></script> +<script src="src/timing-utilities.js"></script> +<script src="src/normalize-keyframes.js"></script> +<script src="src/animation-node.js"></script> +<script src="src/effect.js"></script> +<script src="src/property-interpolation.js"></script> +<script src="src/animation.js"></script> +<script src="src/apply.js"></script> +<script src="src/element-animatable.js"></script> +<script src="src/interpolation.js"></script> +<script src="src/player.js"></script> +<script src="src/tick.js"></script> +<script src="src/handler-utils.js"></script> +<script src="src/shadow-handler.js"></script> +<script src="src/number-handler.js"></script> +<script src="src/visibility-handler.js"></script> +<script src="src/color-handler.js"></script> +<script src="src/dimension-handler.js"></script> +<script src="src/box-handler.js"></script> +<script src="src/transform-handler.js"></script> +<script src="src/property-names.js"></script> +<script src="src/timeline.js"></script> +<script src="src/maxifill-player.js"></script> +<script src="src/animation-constructor.js"></script> +<script src="src/effect-callback.js"></script> +<script src="src/group-constructors.js"></script> + diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations.min.js b/third_party/polymer/v1_0/components/web-animations-js/web-animations.min.js new file mode 100644 index 0000000..1c46a84 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations.min.js @@ -0,0 +1,17 @@ +// Copyright 2014 Google Inc. All rights reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +!function(a,b){b["true"]=a,function(){if(document.documentElement.animate){var a=document.documentElement.animate([],0),b=!0;if(a&&(b=!1,"play|currentTime|pause|reverse|playbackRate|cancel|finish|startTime|playState".split("|").forEach(function(c){void 0===a[c]&&(b=!0)})),!b)return}var c={},d={},e={},f=null;!function(a){function b(b,c){var d={delay:0,endDelay:0,fill:c?"both":"none",iterationStart:0,iterations:1,duration:c?"auto":0,playbackRate:1,direction:"normal",easing:"linear"};return"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof d[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==p.indexOf(b[c]))return;if("direction"==c&&-1==q.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;d[c]=b[c]}}):d.duration=b,d}function c(a,c){var d=b(a,c);return d.easing=f(d.easing),d}function d(a,b,c,d){return 0>a||a>1||0>c||c>1?y:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}for(var g=0,h=1;;){var i=(g+h)/2,j=f(a,c,i);if(Math.abs(e-j)<.001)return f(b,d,i);e>j?g=i:h=i}}}function e(a,b){return function(c){if(c>=1)return 1;var d=1/a;return c+=b*d,c-c%d}}function f(a){var b=w.exec(a);if(b)return d.apply(this,b.slice(1).map(Number));var c=x.exec(a);if(c)return e(Number(c[1]),{start:r,middle:s,end:t}[c[2]]);var f=u[a];return f?f:y}function g(a){return Math.abs(h(a)/a.playbackRate)}function h(a){return a.duration*a.iterations}function i(a,b,c){return null==b?z:b<c.delay?A:b>=c.delay+a?B:C}function j(a,b,c,d,e){switch(d){case A:return"backwards"==b||"both"==b?0:null;case C:return c-e;case B:return"forwards"==b||"both"==b?a:null;case z:return null}}function k(a,b,c,d){return(d.playbackRate<0?b-a:b)*d.playbackRate+c}function l(a,b,c,d,e){return 1/0===c||c===-1/0||c-d==b&&e.iterations&&(e.iterations+e.iterationStart)%1==0?a:c%a}function m(a,b,c,d){return 0===c?0:b==a?d.iterationStart+d.iterations-1:Math.floor(c/a)}function n(a,b,c,d){var e=a%2>=1,f="normal"==d.direction||d.direction==(e?"alternate-reverse":"alternate"),g=f?c:b-c,h=g/b;return b*d.easing(h)}function o(a,b,c){var d=i(a,b,c),e=j(a,c.fill,b,d,c.delay);if(null===e)return null;if(0===a)return d===A?0:1;var f=c.iterationStart*c.duration,g=k(a,e,f,c),o=l(c.duration,h(c),g,f,c),p=m(c.duration,o,g,c);return n(p,c.duration,o,c)/c.duration}var p="backwards|forwards|both|none".split("|"),q="reverse|alternate|alternate-reverse".split("|"),r=1,s=.5,t=0,u={ease:d(.25,.1,.25,1),"ease-in":d(.42,0,1,1),"ease-out":d(0,0,.58,1),"ease-in-out":d(.42,0,.58,1),"step-start":e(1,r),"step-middle":e(1,s),"step-end":e(1,t)},v="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",w=new RegExp("cubic-bezier\\("+v+","+v+","+v+","+v+"\\)"),x=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,y=function(a){return a},z=0,A=1,B=2,C=3;a.makeTiming=b,a.normalizeTimingInput=c,a.calculateActiveDuration=g,a.calculateTimeFraction=o,a.calculatePhase=i,a.toTimingFunction=f}(c,f),function(a){function b(a,b){return a in h?h[a][b]||b:b}function c(a,c,d){var g=e[a];if(g){f.style[a]=c;for(var h in g){var i=g[h],j=f.style[i];d[i]=b(i,j)}}else d[a]=b(a,c)}function d(b){function d(){var a=e.length;null==e[a-1].offset&&(e[a-1].offset=1),a>1&&null==e[0].offset&&(e[0].offset=0);for(var b=0,c=e[0].offset,d=1;a>d;d++){var f=e[d].offset;if(null!=f){for(var g=1;d-b>g;g++)e[b+g].offset=c+(f-c)*g/(d-b);b=d,c=f}}}if(!Array.isArray(b)&&null!==b)throw new TypeError("Keyframes must be null or an array of keyframes");if(null==b)return[];for(var e=b.map(function(b){var d={};for(var e in b){var f=b[e];if("offset"==e){if(null!=f&&(f=Number(f),!isFinite(f)))throw new TypeError("keyframe offsets must be numbers.")}else{if("composite"==e)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};f="easing"==e?a.toTimingFunction(f):""+f}c(e,f,d)}return void 0==d.offset&&(d.offset=null),void 0==d.easing&&(d.easing=a.toTimingFunction("linear")),d}),f=!0,g=-1/0,h=0;h<e.length;h++){var i=e[h].offset;if(null!=i){if(g>i)throw{code:DOMException.INVALID_MODIFICATION_ERR,name:"InvalidModificationError",message:"Keyframes are not loosely sorted by offset. Sort or specify offsets."};g=i}else f=!1}return e=e.filter(function(a){return a.offset>=0&&a.offset<=1}),f||d(),e}var e={background:["backgroundImage","backgroundPosition","backgroundSize","backgroundRepeat","backgroundAttachment","backgroundOrigin","backgroundClip","backgroundColor"],border:["borderTopColor","borderTopStyle","borderTopWidth","borderRightColor","borderRightStyle","borderRightWidth","borderBottomColor","borderBottomStyle","borderBottomWidth","borderLeftColor","borderLeftStyle","borderLeftWidth"],borderBottom:["borderBottomWidth","borderBottomStyle","borderBottomColor"],borderColor:["borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"],borderLeft:["borderLeftWidth","borderLeftStyle","borderLeftColor"],borderRadius:["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"],borderRight:["borderRightWidth","borderRightStyle","borderRightColor"],borderTop:["borderTopWidth","borderTopStyle","borderTopColor"],borderWidth:["borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth"],flex:["flexGrow","flexShrink","flexBasis"],font:["fontFamily","fontSize","fontStyle","fontVariant","fontWeight","lineHeight"],margin:["marginTop","marginRight","marginBottom","marginLeft"],outline:["outlineColor","outlineStyle","outlineWidth"],padding:["paddingTop","paddingRight","paddingBottom","paddingLeft"]},f=document.createElementNS("http://www.w3.org/1999/xhtml","div"),g={thin:"1px",medium:"3px",thick:"5px"},h={borderBottomWidth:g,borderLeftWidth:g,borderRightWidth:g,borderTopWidth:g,fontSize:{"xx-small":"60%","x-small":"75%",small:"89%",medium:"100%",large:"120%","x-large":"150%","xx-large":"200%"},fontWeight:{normal:"400",bold:"700"},outlineWidth:g,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.normalizeKeyframes=d}(c,f),function(a){var b={};a.isDeprecated=function(a,c,d,e){var f=e?"are":"is",g=new Date,h=new Date(c);return h.setMonth(h.getMonth()+3),h>g?(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,!1):!0},a.deprecated=function(b,c,d,e){var f=e?"are":"is";if(a.isDeprecated(b,c,d,e))throw new Error(b+" "+f+" no longer supported. "+d)}}(c),function(a,b){function c(a){for(var b={},c=0;c<a.length;c++)for(var d in a[c])if("offset"!=d&&"easing"!=d&&"composite"!=d){var e={offset:a[c].offset,easing:a[c].easing,value:a[c][d]};b[d]=b[d]||[],b[d].push(e)}for(var f in b){var g=b[f];if(0!=g[0].offset||1!=g[g.length-1].offset)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"Partial keyframes are not supported"}}return b}function d(a){var c=[];for(var d in a)for(var e=a[d],f=0;f<e.length-1;f++){var g=e[f].offset,h=e[f+1].offset,i=e[f].value,j=e[f+1].value;g==h&&(1==h?i=j:j=i),c.push({startTime:g,endTime:h,easing:e[f].easing,property:d,interpolation:b.propertyInterpolation(d,i,j)})}return c.sort(function(a,b){return a.startTime-b.startTime}),c}b.convertEffectInput=function(e){var f=a.normalizeKeyframes(e),g=c(f),h=d(g);return function(a,c){if(null!=c)h.filter(function(a){return 0>=c&&0==a.startTime||c>=1&&1==a.endTime||c>=a.startTime&&c<=a.endTime}).forEach(function(d){var e=c-d.startTime,f=d.endTime-d.startTime,g=0==f?0:d.easing(e/f);b.apply(a,d.property,d.interpolation(g))});else for(var d in g)"offset"!=d&&"easing"!=d&&"composite"!=d&&b.clear(a,d)}}}(c,d,f),function(a){function b(a,b,c){e[c]=e[c]||[],e[c].push([a,b])}function c(a,c,d){for(var e=0;e<d.length;e++){var f=d[e];b(a,c,f),/-/.test(f)&&b(a,c,f.replace(/-(.)/g,function(a,b){return b.toUpperCase()}))}}function d(b,c,d){for(var f=c==d?[]:e[b],g=0;f&&g<f.length;g++){var h=f[g][0](c),i=f[g][0](d);if(void 0!==h&&void 0!==i){var j=f[g][1](h,i);if(j){var k=a.Interpolation.apply(null,j);return function(a){return 0==a?c:1==a?d:k(a)}}}}return a.Interpolation(!1,!0,function(a){return a?d:c})}var e={};a.addPropertiesHandler=c,a.propertyInterpolation=d}(d,f),function(a,b){function c(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateTimeFraction(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d._isCurrent=function(d){var e=a.calculatePhase(c,d,b);return e===PhaseActive||e===PhaseBefore},d}b.KeyframeEffect=function(d,e,f){var g,h=c(a.normalizeTimingInput(f)),i=b.convertEffectInput(e),j=function(){i(d,g)};return j._update=function(a){return g=h(a),null!==g},j._clear=function(){i(d,null)},j._hasSameTarget=function(a){return d===a},j._isCurrent=h._isCurrent,j._totalDuration=h._totalDuration,j},b.NullEffect=function(a){var b=function(){a&&(a(),a=null)};return b._update=function(){return null},b._totalDuration=0,b._isCurrent=function(){return!1},b._hasSameTarget=function(){return!1},b}}(c,d,f),function(a){function b(a,b,c){c.enumerable=!0,c.configurable=!0,Object.defineProperty(a,b,c)}function c(a){this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=a.style,this._length=0,this._isAnimatedProperty={};for(var b=0;b<this._style.length;b++){var c=this._style[b];this._surrogateStyle[c]=this._style[c]}this._updateIndices()}function d(a){if(!a._webAnimationsPatchedStyle){var d=new c(a);try{b(a,"style",{get:function(){return d}})}catch(e){a.style._set=function(b,c){a.style[b]=c},a.style._clear=function(b){a.style[b]=""}}a._webAnimationsPatchedStyle=a.style}}var e={cssText:1,length:1,parentRule:1},f={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},g={removeProperty:1,setProperty:1};c.prototype={get cssText(){return this._surrogateStyle.cssText},set cssText(a){for(var b={},c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;this._surrogateStyle.cssText=a,this._updateIndices();for(var c=0;c<this._surrogateStyle.length;c++)b[this._surrogateStyle[c]]=!0;for(var d in b)this._isAnimatedProperty[d]||this._style.setProperty(d,this._surrogateStyle.getPropertyValue(d))},get length(){return this._surrogateStyle.length},get parentRule(){return this._style.parentRule},_updateIndices:function(){for(;this._length<this._surrogateStyle.length;)Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,get:function(a){return function(){return this._surrogateStyle[a]}}(this._length)}),this._length++;for(;this._length>this._surrogateStyle.length;)this._length--,Object.defineProperty(this,this._length,{configurable:!0,enumerable:!1,value:void 0})},_set:function(a,b){this._style[a]=b,this._isAnimatedProperty[a]=!0},_clear:function(a){this._style[a]=this._surrogateStyle[a],delete this._isAnimatedProperty[a]}};for(var h in f)c.prototype[h]=function(a,b){return function(){var c=this._surrogateStyle[a].apply(this._surrogateStyle,arguments);return b&&(this._isAnimatedProperty[arguments[0]]||this._style[a].apply(this._style,arguments),this._updateIndices()),c}}(h,h in g);for(var i in document.documentElement.style)i in e||i in f||!function(a){b(c.prototype,a,{get:function(){return this._surrogateStyle[a]},set:function(b){this._surrogateStyle[a]=b,this._updateIndices(),this._isAnimatedProperty[a]||(this._style[a]=b)}})}(i);a.apply=function(b,c,e){d(b),b.style._set(a.propertyName(c),e)},a.clear=function(b,c){b._webAnimationsPatchedStyle&&b.style._clear(a.propertyName(c))}}(d,f),function(a){window.Element.prototype.animate=function(b,c){return a.timeline._play(a.KeyframeEffect(this,b,c))}}(d),function(a){function b(a,c,d){if("number"==typeof a&&"number"==typeof c)return a*(1-d)+c*d;if("boolean"==typeof a&&"boolean"==typeof c)return.5>d?a:c;if(a.length==c.length){for(var e=[],f=0;f<a.length;f++)e.push(b(a[f],c[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+c}a.Interpolation=function(a,c,d){return function(e){return d(b(a,c,e))}}}(d,f),function(a){function b(a,b,c){return Math.max(Math.min(a,c),b)}function c(c,d,e){var f=a.dot(c,d);f=b(f,-1,1);var g=[];if(1===f)g=c;else for(var h=Math.acos(f),i=1*Math.sin(e*h)/Math.sqrt(1-f*f),j=0;4>j;j++)g.push(c[j]*(Math.cos(e*h)-f*i)+d[j]*i);return g}var d=function(){function a(a,b){for(var c=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],d=0;4>d;d++)for(var e=0;4>e;e++)for(var f=0;4>f;f++)c[d][e]+=b[d][f]*a[f][e];return c}function b(a){return 0==a[0][2]&&0==a[0][3]&&0==a[1][2]&&0==a[1][3]&&0==a[2][0]&&0==a[2][1]&&1==a[2][2]&&0==a[2][3]&&0==a[3][2]&&1==a[3][3]}function c(c,d,e,f,g){for(var h=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],i=0;4>i;i++)h[i][3]=g[i];for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[3][i]+=c[j]*h[j][i];var k=f[0],l=f[1],m=f[2],n=f[3],o=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];o[0][0]=1-2*(l*l+m*m),o[0][1]=2*(k*l-m*n),o[0][2]=2*(k*m+l*n),o[1][0]=2*(k*l+m*n),o[1][1]=1-2*(k*k+m*m),o[1][2]=2*(l*m-k*n),o[2][0]=2*(k*m-l*n),o[2][1]=2*(l*m+k*n),o[2][2]=1-2*(k*k+l*l),h=a(h,o);var p=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];e[2]&&(p[2][1]=e[2],h=a(h,p)),e[1]&&(p[2][1]=0,p[2][0]=e[0],h=a(h,p)),e[0]&&(p[2][0]=0,p[1][0]=e[0],h=a(h,p));for(var i=0;3>i;i++)for(var j=0;3>j;j++)h[i][j]*=d[i];return b(h)?[h[0][0],h[0][1],h[1][0],h[1][1],h[3][0],h[3][1]]:h[0].concat(h[1],h[2],h[3])}return c}();a.composeMatrix=d,a.quat=c}(d,f),function(a){var b=0,c=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="finish",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()};a.Animation=function(a){this._sequenceNumber=b++,this._currentTime=0,this._startTime=null,this.paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!1,this.onfinish=null,this._finishHandlers=[],this._effect=a,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},a.Animation.prototype={_ensureAlive:function(){this._inEffect=this._effect._update(this.playbackRate<0&&0===this.currentTime?-1:this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,a.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this.finished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(b){b=+b,isNaN(b)||(a.restart(),this.paused||null==this._startTime||(this._startTime=this._timeline.currentTime-b/this._playbackRate),this._currentTimePending=!1,this._currentTime!=b&&(this._tickCurrentTime(b,!0),a.invalidateEffects()))},get startTime(){return this._startTime},set startTime(b){b=+b,isNaN(b)||this.paused||this._idle||(this._startTime=b,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),a.invalidateEffects())},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var b=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&this.play(),null!=b&&(this.currentTime=b)}},get finished(){return!this._idle&&(this._playbackRate>0&&this._currentTime>=this._totalDuration||this._playbackRate<0&&this._currentTime<=0)},get _totalDuration(){return this._effect._totalDuration},get playState(){return this._idle?"idle":null==this._startTime&&!this.paused&&0!=this.playbackRate||this._currentTimePending?"pending":this.paused?"paused":this.finished?"finished":"running"},play:function(){this.paused=!1,(this.finished||this._idle)&&(this._currentTime=this._playbackRate>0?0:this._totalDuration,this._startTime=null,a.invalidateEffects()),this._finishedFlag=!1,a.restart(),this._idle=!1,this._ensureAlive()},pause:function(){this.finished||this.paused||this._idle||(this._currentTimePending=!0),this._startTime=null,this.paused=!0},finish:function(){this._idle||(this.currentTime=this._playbackRate>0?this._totalDuration:0,this._startTime=this._totalDuration-this.currentTime,this._currentTimePending=!1)},cancel:function(){this._inEffect=!1,this._idle=!0,this.currentTime=0,this._startTime=null},reverse:function(){this.playbackRate*=-1,this.play()},addEventListener:function(a,b){"function"==typeof b&&"finish"==a&&this._finishHandlers.push(b)},removeEventListener:function(a,b){if("finish"==a){var c=this._finishHandlers.indexOf(b);c>=0&&this._finishHandlers.splice(c,1)}},_fireEvents:function(a){var b=this.finished;if((b||this._idle)&&!this._finishedFlag){var d=new c(this,this._currentTime,a),e=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){e.forEach(function(a){a.call(d.target,d)})},0)}this._finishedFlag=b},_tick:function(a){return this._idle||this.paused||(null==this._startTime?this.startTime=a-this._currentTime/this.playbackRate:this.finished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),this._currentTimePending=!1,this._fireEvents(a),!this._idle&&(this._inEffect||!this._finishedFlag)}}}(d,f),function(a,b){function c(a){var b=i;i=[],g(a),b.forEach(function(b){b[1](a)}),m&&g(a),f()}function d(a,b){return a._sequenceNumber-b._sequenceNumber}function e(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function f(){n.forEach(function(a){a()}),n.length=0}function g(a){l=!1;var c=b.timeline;c.currentTime=a,c._animations.sort(d),k=!1;var e=c._animations;c._animations=[];var f=[],g=[];e=e.filter(function(b){return b._inTimeline=b._tick(a),b._inEffect?g.push(b._effect):f.push(b._effect),b.finished||b.paused||b._idle||(k=!0),b._inTimeline}),n.push.apply(n,f),n.push.apply(n,g),c._animations.push.apply(c._animations,e),m=!1,k&&requestAnimationFrame(function(){})}var h=window.requestAnimationFrame,i=[],j=0;window.requestAnimationFrame=function(a){var b=j++;return 0==i.length&&h(c),i.push([b,a]),b},window.cancelAnimationFrame=function(a){i.forEach(function(b){b[0]==a&&(b[1]=function(){})})},e.prototype={_play:function(c){c._timing=a.normalizeTimingInput(c.timing);var d=new b.Animation(c);return d._idle=!1,d._timeline=this,this._animations.push(d),b.restart(),b.invalidateEffects(),d}};var k=!1,l=!1;b.restart=function(){return k||(k=!0,requestAnimationFrame(function(){}),l=!0),l};var m=!1;b.invalidateEffects=function(){m=!0};var n=[],o=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){return m&&g(p.currentTime),f(),o.apply(this,arguments)}});var p=new e;b.timeline=p}(c,d,f),function(a){function b(a,b){for(var c=0,d=0;d<a.length;d++)c+=a[d]*b[d];return c}function c(a,b){return[a[0]*b[0]+a[4]*b[1]+a[8]*b[2]+a[12]*b[3],a[1]*b[0]+a[5]*b[1]+a[9]*b[2]+a[13]*b[3],a[2]*b[0]+a[6]*b[1]+a[10]*b[2]+a[14]*b[3],a[3]*b[0]+a[7]*b[1]+a[11]*b[2]+a[15]*b[3],a[0]*b[4]+a[4]*b[5]+a[8]*b[6]+a[12]*b[7],a[1]*b[4]+a[5]*b[5]+a[9]*b[6]+a[13]*b[7],a[2]*b[4]+a[6]*b[5]+a[10]*b[6]+a[14]*b[7],a[3]*b[4]+a[7]*b[5]+a[11]*b[6]+a[15]*b[7],a[0]*b[8]+a[4]*b[9]+a[8]*b[10]+a[12]*b[11],a[1]*b[8]+a[5]*b[9]+a[9]*b[10]+a[13]*b[11],a[2]*b[8]+a[6]*b[9]+a[10]*b[10]+a[14]*b[11],a[3]*b[8]+a[7]*b[9]+a[11]*b[10]+a[15]*b[11],a[0]*b[12]+a[4]*b[13]+a[8]*b[14]+a[12]*b[15],a[1]*b[12]+a[5]*b[13]+a[9]*b[14]+a[13]*b[15],a[2]*b[12]+a[6]*b[13]+a[10]*b[14]+a[14]*b[15],a[3]*b[12]+a[7]*b[13]+a[11]*b[14]+a[15]*b[15]]}function d(a){switch(a.t){case"rotatex":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,0,Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1];case"rotatey":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),0,-Math.sin(d),0,0,1,0,0,Math.sin(d),0,Math.cos(d),0,0,0,0,1];case"rotate":case"rotatez":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[Math.cos(d),Math.sin(d),0,0,-Math.sin(d),Math.cos(d),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var e=a.d[0],f=a.d[1],g=a.d[2],b=a.d[3].rad||0,c=a.d[3].deg||0,d=c*Math.PI/180+b,h=e*e+f*f+g*g;if(0===h)e=1,f=0,g=0;else if(1!==h){var i=Math.sqrt(h);e/=i,f/=i,g/=i}var j=Math.sin(d/2),k=j*Math.cos(d/2),l=j*j;return[1-2*(f*f+g*g)*l,2*(e*f*l+g*k),2*(e*g*l-f*k),0,2*(e*f*l-g*k),1-2*(e*e+g*g)*l,2*(f*g*l+e*k),0,2*(e*g*l+f*k),2*(f*g*l-e*k),1-2*(e*e+f*f)*l,0,0,0,0,1];case"scale":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,1,0,0,0,0,1];case"scalex":return[a.d[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"scaley":return[1,0,0,0,0,a.d[0],0,0,0,0,1,0,0,0,0,1];case"scalez":return[1,0,0,0,0,1,0,0,0,0,a.d[0],0,0,0,0,1];case"scale3d":return[a.d[0],0,0,0,0,a.d[1],0,0,0,0,a.d[2],0,0,0,0,1];case"skew":var m=a.d[0].deg||0,n=a.d[0].rad||0,o=a.d[1].deg||0,p=a.d[1].rad||0,q=m*Math.PI/180+n,r=o*Math.PI/180+p;return[1,Math.tan(r),0,0,Math.tan(q),1,0,0,0,0,1,0,0,0,0,1];case"skewx":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,0,0,0,Math.tan(d),1,0,0,0,0,1,0,0,0,0,1];case"skewy":var b=a.d[0].rad||0,c=a.d[0].deg||0,d=c*Math.PI/180+b;return[1,Math.tan(d),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":var e=a.d[0].px||0,f=a.d[1].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,0,1];case"translatex":var e=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,0,0,1];case"translatey":var f=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,f,0,1];case"translatez":var g=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,g,1];case"translate3d":var e=a.d[0].px||0,f=a.d[1].px||0,g=a.d[2].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,e,f,g,1];case"perspective":var s=a.d[0].px?-1/a.d[0].px:0;return[1,0,0,0,0,1,0,0,0,0,1,s,0,0,0,1];case"matrix":return[a.d[0],a.d[1],0,0,a.d[2],a.d[3],0,0,0,0,1,0,a.d[4],a.d[5],0,1];case"matrix3d":return a.d}}function e(a){return 0===a.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:a.map(d).reduce(c)}function f(a){return[g(e(a))]}var g=function(){function a(a){return a[0][0]*a[1][1]*a[2][2]+a[1][0]*a[2][1]*a[0][2]+a[2][0]*a[0][1]*a[1][2]-a[0][2]*a[1][1]*a[2][0]-a[1][2]*a[2][1]*a[0][0]-a[2][2]*a[0][1]*a[1][0]}function c(b){for(var c=1/a(b),d=b[0][0],e=b[0][1],f=b[0][2],g=b[1][0],h=b[1][1],i=b[1][2],j=b[2][0],k=b[2][1],l=b[2][2],m=[[(h*l-i*k)*c,(f*k-e*l)*c,(e*i-f*h)*c,0],[(i*j-g*l)*c,(d*l-f*j)*c,(f*g-d*i)*c,0],[(g*k-h*j)*c,(j*e-d*k)*c,(d*h-e*g)*c,0]],n=[],o=0;3>o;o++){for(var p=0,q=0;3>q;q++)p+=b[3][q]*m[q][o];n.push(p)}return n.push(1),m.push(n),m}function d(a){return[[a[0][0],a[1][0],a[2][0],a[3][0]],[a[0][1],a[1][1],a[2][1],a[3][1]],[a[0][2],a[1][2],a[2][2],a[3][2]],[a[0][3],a[1][3],a[2][3],a[3][3]]]}function e(a,b){for(var c=[],d=0;4>d;d++){for(var e=0,f=0;4>f;f++)e+=a[f]*b[f][d];c.push(e)}return c}function f(a){var b=g(a);return[a[0]/b,a[1]/b,a[2]/b]}function g(a){return Math.sqrt(a[0]*a[0]+a[1]*a[1]+a[2]*a[2])}function h(a,b,c,d){return[c*a[0]+d*b[0],c*a[1]+d*b[1],c*a[2]+d*b[2]]}function i(a,b){return[a[1]*b[2]-a[2]*b[1],a[2]*b[0]-a[0]*b[2],a[0]*b[1]-a[1]*b[0]]}function j(j){var k=[j.slice(0,4),j.slice(4,8),j.slice(8,12),j.slice(12,16)];if(1!==k[3][3])return null;for(var l=[],m=0;4>m;m++)l.push(k[m].slice());for(var m=0;3>m;m++)l[m][3]=0;if(0===a(l))return!1;var n,o=[];if(k[0][3]||k[1][3]||k[2][3]){o.push(k[0][3]),o.push(k[1][3]),o.push(k[2][3]),o.push(k[3][3]);var p=c(l),q=d(p);n=e(o,q)}else n=[0,0,0,1];var r=k[3].slice(0,3),s=[];s.push(k[0].slice(0,3));var t=[];t.push(g(s[0])),s[0]=f(s[0]);var u=[];s.push(k[1].slice(0,3)),u.push(b(s[0],s[1])),s[1]=h(s[1],s[0],1,-u[0]),t.push(g(s[1])),s[1]=f(s[1]),u[0]/=t[1],s.push(k[2].slice(0,3)),u.push(b(s[0],s[2])),s[2]=h(s[2],s[0],1,-u[1]),u.push(b(s[1],s[2])),s[2]=h(s[2],s[1],1,-u[2]),t.push(g(s[2])),s[2]=f(s[2]),u[1]/=t[2],u[2]/=t[2];var v=i(s[1],s[2]);if(b(s[0],v)<0)for(var m=0;3>m;m++)t[m]*=-1,s[m][0]*=-1,s[m][1]*=-1,s[m][2]*=-1;var w,x,y=s[0][0]+s[1][1]+s[2][2]+1;return y>1e-4?(w=.5/Math.sqrt(y),x=[(s[2][1]-s[1][2])*w,(s[0][2]-s[2][0])*w,(s[1][0]-s[0][1])*w,.25/w]):s[0][0]>s[1][1]&&s[0][0]>s[2][2]?(w=2*Math.sqrt(1+s[0][0]-s[1][1]-s[2][2]),x=[.25*w,(s[0][1]+s[1][0])/w,(s[0][2]+s[2][0])/w,(s[2][1]-s[1][2])/w]):s[1][1]>s[2][2]?(w=2*Math.sqrt(1+s[1][1]-s[0][0]-s[2][2]),x=[(s[0][1]+s[1][0])/w,.25*w,(s[1][2]+s[2][1])/w,(s[0][2]-s[2][0])/w]):(w=2*Math.sqrt(1+s[2][2]-s[0][0]-s[1][1]),x=[(s[0][2]+s[2][0])/w,(s[1][2]+s[2][1])/w,.25*w,(s[1][0]-s[0][1])/w]),[r,t,u,x,n]}return j}();a.dot=b,a.makeMatrixDecomposition=f}(d,f),function(a){function b(a,b){var c=a.exec(b);return c?(c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]):void 0}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);return c?[c[0],c[1].replace(/^\s*/,"")]:void 0}function d(a,d,e){a=c.bind(null,a);for(var f=[];;){var g=a(e);if(!g)return[f,e];if(f.push(g[0]),e=g[1],g=b(d,e),!g||""==g[1])return[f,e];e=g[1]}}function e(a,b){for(var c=0,d=0;d<b.length&&(!/\s|,/.test(b[d])||0!=c);d++)if("("==b[d])c++;else if(")"==b[d]&&(c--,0==c&&d++,0>=c))break;var e=a(b.substr(0,d));return void 0==e?void 0:[e,b.substr(d)]}function f(a,b){for(var c=a,d=b;c&&d;)c>d?c%=d:d%=c;return c=a*b/(c+d)}function g(a){return function(b){var c=a(b);return c&&(c[0]=void 0),c}}function h(a,b){return function(c){var d=a(c);return d?d:[b,c]}}function i(b,c){for(var d=[],e=0;e<b.length;e++){var f=a.consumeTrimmed(b[e],c);if(!f||""==f[0])return;void 0!==f[0]&&d.push(f[0]),c=f[1]}return""==c?d:void 0}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;j>k;k++){var l=b(d[k%d.length],e[k%e.length]);if(!l)return;g.push(l[0]),h.push(l[1]),i.push(l[2])}return[g,h,function(b){var d=b.map(function(a,b){return i[b](a)}).join(c);return a?a(d):d}]}function k(a,b,c){for(var d=[],e=[],f=[],g=0,h=0;h<c.length;h++)if("function"==typeof c[h]){var i=c[h](a[g],b[g++]);d.push(i[0]),e.push(i[1]),f.push(i[2])}else!function(a){d.push(!1),e.push(!1),f.push(function(){return c[a]})}(h);return[d,e,function(a){for(var b="",c=0;c<a.length;c++)b+=f[c](a[c]);return b}]}a.consumeToken=b,a.consumeTrimmed=c,a.consumeRepeated=d,a.consumeParenthesised=e,a.ignore=g,a.optional=h,a.consumeList=i,a.mergeNestedRepeated=j.bind(null,null),a.mergeWrappedNestedRepeated=j,a.mergeList=k}(d),function(a){function b(b){function c(b){var c=a.consumeToken(/^inset/i,b);if(c)return d.inset=!0,c;var c=a.consumeLengthOrPercent(b);if(c)return d.lengths.push(c[0]),c;var c=a.consumeColor(b);return c?(d.color=c[0],c):void 0}var d={inset:!1,lengths:[],color:null},e=a.consumeRepeated(c,/^/,b);return e&&e[0].length?[d,e[1]]:void 0}function c(c){var d=a.consumeRepeated(b,/^,/,c);return d&&""==d[1]?d[0]:void 0}function d(b,c){for(;b.lengths.length<Math.max(b.lengths.length,c.lengths.length);)b.lengths.push({px:0});for(;c.lengths.length<Math.max(b.lengths.length,c.lengths.length);)c.lengths.push({px:0});if(b.inset==c.inset&&!!b.color==!!c.color){for(var d,e=[],f=[[],0],g=[[],0],h=0;h<b.lengths.length;h++){var i=a.mergeDimensions(b.lengths[h],c.lengths[h],2==h);f[0].push(i[0]),g[0].push(i[1]),e.push(i[2])}if(b.color&&c.color){var j=a.mergeColors(b.color,c.color);f[1]=j[0],g[1]=j[1],d=j[2]}return[f,g,function(a){for(var c=b.inset?"inset ":" ",f=0;f<e.length;f++)c+=e[f](a[0][f])+" ";return d&&(c+=d(a[1])),c}]}}function e(b,c,d,e){function f(a){return{inset:a,color:[0,0,0,0],lengths:[{px:0},{px:0},{px:0},{px:0}]}}for(var g=[],h=[],i=0;i<d.length||i<e.length;i++){var j=d[i]||f(e[i].inset),k=e[i]||f(d[i].inset);g.push(j),h.push(k)}return a.mergeNestedRepeated(b,c,g,h)}var f=e.bind(null,d,", ");a.addPropertiesHandler(c,f,["box-shadow","text-shadow"])}(d),function(a){function b(a){return a.toFixed(3).replace(".000","")}function c(a,b,c){return Math.min(b,Math.max(a,c))}function d(a){return/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a)?Number(a):void 0}function e(a,c){return[a,c,b]}function f(a,b){return 0!=a?h(0,1/0)(a,b):void 0}function g(a,b){return[a,b,function(a){return Math.round(c(1,1/0,a))}]}function h(a,d){return function(e,f){return[e,f,function(e){return b(c(a,d,e))}]}}function i(a,b){return[a,b,Math.round]}a.clamp=c,a.addPropertiesHandler(d,h(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(d,h(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(d,f,["flex-grow","flex-shrink"]),a.addPropertiesHandler(d,g,["orphans","widows"]),a.addPropertiesHandler(d,i,["z-index"]),a.parseNumber=d,a.mergeNumbers=e,a.numberToString=b}(d,f),function(a){function b(a,b){return"visible"==a||"visible"==b?[0,1,function(c){return 0>=c?a:c>=1?b:"visible"}]:void 0}a.addPropertiesHandler(String,b,["visibility"])}(d),function(a){function b(a){a=a.trim(),e.fillStyle="#000",e.fillStyle=a;var b=e.fillStyle;if(e.fillStyle="#fff",e.fillStyle=a,b==e.fillStyle){e.fillRect(0,0,1,1);var c=e.getImageData(0,0,1,1).data;e.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function c(b,c){return[b,c,function(b){function c(a){return Math.max(0,Math.min(255,a))}if(b[3])for(var d=0;3>d;d++)b[d]=Math.round(c(b[d]/b[3]));return b[3]=a.numberToString(a.clamp(0,1,b[3])),"rgba("+b.join(",")+")"}]}var d=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");d.width=d.height=1;var e=d.getContext("2d");a.addPropertiesHandler(b,c,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","outline-color","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,b),a.mergeColors=c}(d,f),function(a,b){function c(a,b){if(b=b.trim().toLowerCase(),"0"==b&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var c={};b=b.replace(a,function(a){return c[a]=null,"U"+a});for(var d="U("+a.source+")",e=b.replace(/[-+]?(\d*\.)?\d+/g,"N").replace(new RegExp("N"+d,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),f=[/N\*(D)/g,/(N|D)[*/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],g=0;g<f.length;)f[g].test(e)?(e=e.replace(f[g],"$1"),g=0):g++;if("D"==e){for(var h in c){var i=eval(b.replace(new RegExp("U"+h,"g"),"").replace(new RegExp(d,"g"),"*0"));if(!isFinite(i))return;c[h]=i}return c}}}function d(a,b){return e(a,b,!0)}function e(b,c,d){var e,f=[];for(e in b)f.push(e);for(e in c)f.indexOf(e)<0&&f.push(e);return b=f.map(function(a){return b[a]||0}),c=f.map(function(a){return c[a]||0}),[b,c,function(b){var c=b.map(function(c,e){return 1==b.length&&d&&(c=Math.max(c,0)),a.numberToString(c)+f[e]}).join(" + ");return b.length>1?"calc("+c+")":c}]}var f="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",g=c.bind(null,new RegExp(f,"g")),h=c.bind(null,new RegExp(f+"|%","g")),i=c.bind(null,/deg|rad|grad|turn/g);a.parseLength=g,a.parseLengthOrPercent=h,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,h),a.parseAngle=i,a.mergeDimensions=e;var j=a.consumeParenthesised.bind(null,g),k=a.consumeRepeated.bind(void 0,j,/^/),l=a.consumeRepeated.bind(void 0,k,/^,/);a.consumeSizePairList=l;var m=function(a){var b=l(a);return b&&""==b[1]?b[0]:void 0},n=a.mergeNestedRepeated.bind(void 0,d," "),o=a.mergeNestedRepeated.bind(void 0,n,",");a.mergeNonNegativeSizePair=n,a.addPropertiesHandler(m,o,["background-size"]),a.addPropertiesHandler(h,d,["border-bottom-width","border-image-width","border-left-width","border-right-width","border-top-width","flex-basis","font-size","height","line-height","max-height","max-width","outline-width","width"]),a.addPropertiesHandler(h,e,["border-bottom-left-radius","border-bottom-right-radius","border-top-left-radius","border-top-right-radius","bottom","left","letter-spacing","margin-bottom","margin-left","margin-right","margin-top","min-height","min-width","outline-offset","padding-bottom","padding-left","padding-right","padding-top","perspective","right","shape-margin","text-indent","top","vertical-align","word-spacing"])}(d,f),function(a){function b(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function c(c){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,b,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],c);return d&&4==d[0].length?d[0]:void 0}function d(b,c){return"auto"==b||"auto"==c?[!0,!1,function(d){var e=d?b:c;if("auto"==e)return"auto";var f=a.mergeDimensions(e,e);return f[2](f[0])}]:a.mergeDimensions(b,c)}function e(a){return"rect("+a+")"}var f=a.mergeWrappedNestedRepeated.bind(null,e,d,", ");a.parseBox=c,a.mergeBoxes=f,a.addPropertiesHandler(c,f,["clip"]) +}(d,f),function(a){function b(a){return function(b){var c=0;return a.map(function(a){return a===j?b[c++]:a})}}function c(a){return a}function d(b){if(b=b.toLowerCase().trim(),"none"==b)return[];for(var c,d=/\s*(\w+)\(([^)]*)\)/g,e=[],f=0;c=d.exec(b);){if(c.index!=f)return;f=c.index+c[0].length;var g=c[1],h=m[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var n=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(p=q?{A:function(b){return"0"==b.trim()?l:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:l,n:n[0],t:k}[r],void 0===p)return;n.push(p)}if(e.push({t:g,d:n}),d.lastIndex==b.length)return e}}function e(a){return a.toFixed(6).replace(".000000","")}function f(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var f=a.makeMatrixDecomposition(c)}return null==d[0]||null==f[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),f[0].push(1),[d,f,function(b){var c=a.quat(d[0][3],f[0][3],b[5]),g=a.composeMatrix(b[0],b[1],b[2],c,b[4]),h=g.map(e).join(",");return h}])}function g(a){return a.replace(/[xy]/,"")}function h(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function i(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var i=0;i<b.length;i++){var j=b[i].t,k=b[i].d,l="scale"==j.substr(0,5)?1:0;c.push({t:j,d:k.map(function(a){if("number"==typeof a)return l;var b={};for(var c in a)b[c]=l;return b})})}}var n=function(a,b){return"perspective"==a&&"perspective"==b||("matrix"==a||"matrix3d"==a)&&("matrix"==b||"matrix3d"==b)},o=[],p=[],q=[];if(b.length!=c.length){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var i=0;i<b.length;i++){var j,s=b[i].t,t=c[i].t,u=b[i].d,v=c[i].d,w=m[s],x=m[t];if(n(s,t)){if(!d)return;var r=f([b[i]],[c[i]]);o.push(r[0]),p.push(r[1]),q.push(["matrix",[r[2]]])}else{if(s==t)j=s;else if(w[2]&&x[2]&&g(s)==g(t))j=g(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||h(s)!=h(t)){if(!d)return;var r=f(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=h(s),u=w[1](u),v=x[1](v)}for(var y=[],z=[],A=[],B=0;B<u.length;B++){var C="number"==typeof u[B]?a.mergeNumbers:a.mergeDimensions,r=C(u[B],v[B]);y[B]=r[0],z[B]=r[1],A.push(r[2])}o.push(y),p.push(z),q.push([j,A])}}if(e){var D=o;o=p,p=D}return[o,p,function(a){return a.map(function(a,b){var c=a.map(function(a,c){return q[b][1][c](a)}).join(",");return"matrix"==q[b][0]&&16==c.split(",").length&&(q[b][0]="matrix3d"),q[b][0]+"("+c+")"}).join(" ")}]}var j=null,k={px:0},l={deg:0},m={matrix:["NNNNNN",[j,j,0,0,j,j,0,0,0,0,1,0,j,j,0,1],c],matrix3d:["NNNNNNNNNNNNNNNN",c],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",b([j,j,1]),c],scalex:["N",b([j,1,1]),b([j,1])],scaley:["N",b([1,j,1]),b([1,j])],scalez:["N",b([1,1,j])],scale3d:["NNN",c],skew:["Aa",null,c],skewx:["A",null,b([j,l])],skewy:["A",null,b([l,j])],translate:["Tt",b([j,j,k]),c],translatex:["T",b([j,k,k]),b([j,k])],translatey:["T",b([k,j,k]),b([k,j])],translatez:["L",b([k,k,j])],translate3d:["TTL",c]};a.addPropertiesHandler(d,i,["transform"])}(d,f),function(a){function b(a){var b=Number(a);return isNaN(b)||100>b||b>900||b%100!==0?void 0:b}function c(b){return b=100*Math.round(b/100),b=a.clamp(100,900,b),400===b?"normal":700===b?"bold":String(b)}function d(a,b){return[a,b,c]}a.addPropertiesHandler(b,d,["font-weight"])}(d),function(a){function b(a){var b={};for(var c in a)b[c]=-a[c];return b}function c(b){return a.consumeToken(/^(left|center|right|top|bottom)\b/i,b)||a.consumeLengthOrPercent(b)}function d(b,d){var e=a.consumeRepeated(c,/^/,d);if(e&&""==e[1]){var f=e[0];if(f[0]=f[0]||"center",f[1]=f[1]||"center",3==b&&(f[2]=f[2]||{px:0}),f.length==b){if(/top|bottom/.test(f[0])||/left|right/.test(f[1])){var h=f[0];f[0]=f[1],f[1]=h}if(/left|right|center|Object/.test(f[0])&&/top|bottom|center|Object/.test(f[1]))return f.map(function(a){return"object"==typeof a?a:g[a]})}}}function e(d){var e=a.consumeRepeated(c,/^/,d);if(e){for(var f=e[0],h=[{"%":50},{"%":50}],i=0,j=!1,k=0;k<f.length;k++){var l=f[k];"string"==typeof l?(j=/bottom|right/.test(l),i={left:0,right:0,center:i,top:1,bottom:1}[l],h[i]=g[l],"center"==l&&i++):(j&&(l=b(l),l["%"]=(l["%"]||0)+100),h[i]=l,i++,j=!1)}return[h,e[1]]}}function f(b){var c=a.consumeRepeated(e,/^,/,b);return c&&""==c[1]?c[0]:void 0}var g={left:{"%":0},center:{"%":50},right:{"%":100},top:{"%":0},bottom:{"%":100}},h=a.mergeNestedRepeated.bind(null,a.mergeDimensions," ");a.addPropertiesHandler(d.bind(null,3),h,["transform-origin"]),a.addPropertiesHandler(d.bind(null,2),h,["perspective-origin"]),a.consumePosition=e,a.mergeOffsetList=h;var i=a.mergeNestedRepeated.bind(null,h,", ");a.addPropertiesHandler(f,i,["background-position","object-position"])}(d),function(a){function b(b){var c=a.consumeToken(/^circle/,b);if(c&&c[0])return["circle"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),d,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],c[1]));var f=a.consumeToken(/^ellipse/,b);if(f&&f[0])return["ellipse"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),e,a.ignore(a.consumeToken.bind(void 0,/^at/)),a.consumePosition,a.ignore(a.consumeToken.bind(void 0,/^\)/))],f[1]));var g=a.consumeToken(/^polygon/,b);return g&&g[0]?["polygon"].concat(a.consumeList([a.ignore(a.consumeToken.bind(void 0,/^\(/)),a.optional(a.consumeToken.bind(void 0,/^nonzero\s*,|^evenodd\s*,/),"nonzero,"),a.consumeSizePairList,a.ignore(a.consumeToken.bind(void 0,/^\)/))],g[1])):void 0}function c(b,c){return b[0]===c[0]?"circle"==b[0]?a.mergeList(b.slice(1),c.slice(1),["circle(",a.mergeDimensions," at ",a.mergeOffsetList,")"]):"ellipse"==b[0]?a.mergeList(b.slice(1),c.slice(1),["ellipse(",a.mergeNonNegativeSizePair," at ",a.mergeOffsetList,")"]):"polygon"==b[0]&&b[1]==c[1]?a.mergeList(b.slice(2),c.slice(2),["polygon(",b[1],g,")"]):void 0:void 0}var d=a.consumeParenthesised.bind(null,a.parseLengthOrPercent),e=a.consumeRepeated.bind(void 0,d,/^/),f=a.mergeNestedRepeated.bind(void 0,a.mergeDimensions," "),g=a.mergeNestedRepeated.bind(void 0,f,",");a.addPropertiesHandler(b,c,["shape-outside"])}(d),function(a){function b(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(c[a]=b)})}var c={};b("transform",["webkitTransform","msTransform"]),b("transformOrigin",["webkitTransformOrigin"]),b("perspective",["webkitPerspective"]),b("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return c[a]||a}}(d,f)}()}({},function(){return this}()); +//# sourceMappingURL=web-animations.min.js.map
\ No newline at end of file diff --git a/third_party/polymer/v1_0/components/web-animations-js/web-animations.min.js.map b/third_party/polymer/v1_0/components/web-animations-js/web-animations.min.js.map new file mode 100644 index 0000000..fdf6c02 --- /dev/null +++ b/third_party/polymer/v1_0/components/web-animations-js/web-animations.min.js.map @@ -0,0 +1 @@ +{"version":3,"file":"web-animations.min.js","sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/keyframe-interpolations.js","src/property-interpolation.js","src/keyframe-effect.js","src/apply-preserving-inline-style.js","src/element-animatable.js","src/interpolation.js","src/matrix-interpolation.js","src/animation.js","src/tick.js"],"names":["webAnimationsShared","webAnimations1","webAnimationsNext","WEB_ANIMATIONS_TESTING","webAnimationsTesting","shared","testing","makeTiming","timingInput","timing","delay","endDelay","fill","forGroup","iterationStart","iterations","direction","isNaN","getOwnPropertyNames","forEach","property","fills","indexOf","directions","isDeprecated","duration","normalizeTimingInput","easing","toTimingFunction","cubic","c","a","linear","x","f","b","m","start","mid","end","xEst","Math","abs","step","count","pos","stepSize","cubicData","cubicBezierRe","exec","apply","Number","stepData","stepRe","Start","middle","Middle","End","preset","presets","calculateActiveDuration","repeatedDuration","playbackRate","calculatePhase","activeDuration","localTime","PhaseNone","PhaseBefore","PhaseAfter","calculateActiveTime","fillMode","PhaseActive","calculateScaledActiveTime","activeTime","startOffset","calculateIterationTime","iterationDuration","scaledActiveTime","Infinity","calculateCurrentIteration","iterationTime","floor","calculateTransformedTime","currentIteration","currentIterationIsOdd","currentDirectionIsForwards","directedTime","timeFraction","calculateTimeFraction","phase","split","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","value","aliases","expandShorthandAndAntiAlias","longProperties","shorthandToLonghand","shorthandExpanderElem","style","i","longProperty","longhandValue","result","normalizeKeyframes","effectInput","spaceKeyframes","length","keyframes","offset","previousIndex","previousOffset","j","isArray","TypeError","map","originalKeyframe","member","memberValue","type","DOMException","NOT_SUPPORTED_ERR","message","keyframe","undefined","everyFrameHasOffset","code","INVALID_MODIFICATION_ERR","name","filter","background","border","borderBottom","borderColor","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","document","createElementNS","borderWidthAliases","medium","borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","fontSize","xx-small","small","x-large","xx-large","fontWeight","outlineWidth","textShadow","none","boxShadow","silenced","feature","date","advice","plural","today","Date","setMonth","getMonth","warn","expiry","toDateString","deprecated","auxVerb","Error","makePropertySpecificKeyframeGroups","propertySpecificKeyframeGroups","propertySpecificKeyframe","groupName","group","makeInterpolations","interpolations","startTime","endTime","startValue","endValue","push","interpolation","scope","propertyInterpolation","leftInterpolation","rightInterpolation","convertEffectInput","target","fraction","offsetFraction","localDuration","scaledLocalTime","clear","addPropertyHandler","parser","merger","propertyHandlers","addPropertiesHandler","properties","replace","toUpperCase","right","handlers","left","parsedLeft","parsedRight","interpolationArgs","interp","Interpolation","t","bool","effectTime","_totalDuration","_isCurrent","KeyframeEffect","keyframeEffect","_update","_hasSameTarget","otherTarget","nullEffect","configureProperty","object","descriptor","enumerable","configurable","Object","defineProperty","AnimatedCSSStyleDeclaration","element","_surrogateStyle","this","_style","_length","_isAnimatedProperty","_updateIndices","ensureStyleIsPatched","_webAnimationsPatchedStyle","animatedStyle","get","_set","styleAttributes","cssText","parentRule","styleMethods","getPropertyCSSValue","getPropertyPriority","getPropertyValue","removeProperty","setProperty","styleMutatingMethods","prototype","text","isAffectedProperty",{"end":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"start":{"file":"src/apply-preserving-inline-style.js","comments_before":[],"nlb":false,"endpos":2110,"pos":2103,"col":8,"line":64,"value":"cssText","type":"name"},"name":"cssText"},"index","_clear","method","modifiesStyle","arguments","documentElement","set","propertyName","window","animate","timeline","_play","interpolate","from","r","to","convertToString","clamp","max","min","quat","toQ","dot","fromQ","product","theta","sin","sqrt","cos","composeMatrix","multiply","k","translate","scale","perspective","matrix","y","z","rotMatrix","w","temp","skew","is2D","concat","sequenceNumber","AnimationEvent","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","now","Animation","effect","_sequenceNumber","_currentTime","_startTime","paused","_playbackRate","_inTimeline","_finishedFlag","onfinish","_finishHandlers","_effect","_idle","_inEffect","_animations","_tickCurrentTime","newTime","ignoreLimit","finished","_ensureAlive","_currentTimePending","restart","_timeline","invalidateEffects","oldCurrentTime","playState","play","pause","finish","cancel","reverse","addEventListener","handler","removeEventListener","splice","_fireEvents","baseTime","setTimeout","call","event","processRafCallbacks","processing","rafCallbacks","tick","entry","needsRetick","applyPendingEffects","compareAnimations","leftAnimation","rightAnimation","InternalTimeline","performance","pendingEffects","hasRestartedThisFrame","sort","ticking","newPendingClears","newPendingEffects","updatingAnimations"],"mappings":"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"}
\ No newline at end of file diff --git a/third_party/polymer/v1_0/extract_inline_scripts.sh b/third_party/polymer/v1_0/extract_inline_scripts.sh new file mode 100755 index 0000000..91fc6ea --- /dev/null +++ b/third_party/polymer/v1_0/extract_inline_scripts.sh @@ -0,0 +1,49 @@ +#!/bin/bash + +# Copyright 2014 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +set -e + +if [ "$#" -ne 2 ] +then + echo "Usage: $0 <src_dir> <dst_dir>" + echo + echo "Copies <src_dir> to <dst_dir> and extracts all inline scripts from" \ + "Polymer HTML files found in the destination directory to separate JS" \ + "files. A JS file extracted from the file with name 'foo.html' will" \ + "have a name 'foo-extracted.js'. Inclusion of the script file will be" \ + "added to 'foo.html': '<script src=\"foo-extracted.js\"></script>'." + exit 1 +fi + +src="$1" +dst="$2" + +if [ -e "$dst" ] +then + echo "ERROR: '$dst' already exists. Please remove it before running the" \ + "script." 1>&2 + exit 1 +fi + +cp -r "$src" "$dst" +find "$dst" -name "*.html" \ + -not -path "*/demos/*" \ + -not -path "*/test/*" \ + -not -path "*/tests/*" \ + -not -name "demo*.html" \ + -not -name "index.html" \ + -not -name "metadata.html" | \ +xargs grep -l "<script>" | \ +while read original_html_name +do + dir=$(dirname "$original_html_name") + name=$(basename "$original_html_name" .html) + + html_without_js="$dir/$name-extracted.html" + extracted_js="$dir/$name-extracted.js" + crisper --source "$original_html_name" --html "$html_without_js" --js "$extracted_js" + mv "$html_without_js" "$original_html_name" +done diff --git a/third_party/polymer/v1_0/reproduce.sh b/third_party/polymer/v1_0/reproduce.sh new file mode 100755 index 0000000..8c2c350 --- /dev/null +++ b/third_party/polymer/v1_0/reproduce.sh @@ -0,0 +1,47 @@ +#!/bin/bash + +# Copyright 2014 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +# Reproduces the content of 'components' and 'components-chromium' using the +# list of dependencies from 'bower.json'. Downloads needed packages and makes +# Chromium specific modifications. To launch the script you need 'bower', +# 'crisper', and 'vulcanize' installed on your system. + +# IMPORTANT NOTE: The new vulcanize must be installed from +# https://github.com/Polymer/vulcanize/releases since it isn't on npm yet. + +set -e + +cd "$(dirname "$0")" + +rm -rf components components-chromium + +bower install + +# These components are needed only for demos and docs. +rm -rf components/{hydrolysis,marked,marked-element,prism,prism-element,\ +iron-component-page,iron-doc-viewer,webcomponentsjs} + +# Remove unused gzipped binary which causes git-cl problems. +rm components/web-animations-js/web-animations.min.js.gz + +# Test and demo directories aren't needed. +rm -rf components/*/{test,demo} +rm -rf components/polymer/explainer + +# Make checkperms.py happy. +find components/*/hero.svg -type f -exec chmod -x {} \; +find components/iron-selector -type f -exec chmod -x {} \; + +# Remove carriage returns to make CQ happy. +find components -type f \( -name \*.html -o -name \*.css -o -name \*.js\ + -o -name \*.md -o -name \*.sh -o -name \*.json -o -name \*.gitignore\ + -o -name \*.bat \) -print0 | xargs -0 sed -i -e $'s/\r$//g' + +# Resolve a unicode encoding issue in dom-innerHTML.html. +NBSP=$(python -c 'print u"\u00A0".encode("utf-8")') +sed -i 's/['"$NBSP"']/\\u00A0/g' components/polymer/polymer-mini.html + +./extract_inline_scripts.sh components components-chromium |