aboutsummaryrefslogtreecommitdiff
path: root/catapult/third_party/polymer/components/web-animations-js
diff options
context:
space:
mode:
Diffstat (limited to 'catapult/third_party/polymer/components/web-animations-js')
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/.bower.json40
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/CONTRIBUTING.md123
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/COPYING202
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/History.md265
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/README.md80
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/bower.json30
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/docs/examples.md241
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/docs/experimental.md58
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/docs/support.md69
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/externs/README.md10
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/externs/web-animations-next.js113
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/externs/web-animations.js126
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/animation.js279
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/apply-preserving-inline-style.js239
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/apply.js25
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/box-handler.js57
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/color-handler.js63
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/deprecation.js47
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/dev.js16
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/dimension-handler.js240
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/effect-callback.js98
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/element-animatable.js23
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/font-weight-handler.js42
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/group-constructors.js204
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/handler-utils.js177
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/interpolation.js49
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect-constructor.js183
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect.js57
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/keyframe-interpolations.js123
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/matrix-decomposition.js440
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/matrix-interpolation.js130
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/normalize-keyframes.js321
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/number-handler.js97
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/position-handler.js117
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/property-interpolation.js127
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/property-names.js40
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/scope.js20
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/shadow-handler.js108
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/shape-handler.js85
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/tick.js181
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/timeline.js101
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/timing-utilities.js420
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/transform-handler.js275
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/visibility-handler.js29
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-cancel-events.js83
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-object-form-keyframes.js63
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/src/web-animations-next-animation.js383
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.html1
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js16
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js.map1
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.html1
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js16
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js.map1
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations.html50
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations.min.html1
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations.min.js16
-rw-r--r--catapult/third_party/polymer/components/web-animations-js/web-animations.min.js.map1
57 files changed, 6403 insertions, 0 deletions
diff --git a/catapult/third_party/polymer/components/web-animations-js/.bower.json b/catapult/third_party/polymer/components/web-animations-js/.bower.json
new file mode 100644
index 00000000..1a699734
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/.bower.json
@@ -0,0 +1,40 @@
+{
+ "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",
+ "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.3.1",
+ "_release": "2.3.1",
+ "_resolution": {
+ "type": "version",
+ "tag": "2.3.1",
+ "commit": "a2dddad1c210c8abe5bc1c5a5e126e9946d44252"
+ },
+ "_source": "https://github.com/web-animations/web-animations-js.git",
+ "_target": "^2.2.0",
+ "_originalSource": "web-animations/web-animations-js"
+} \ No newline at end of file
diff --git a/catapult/third_party/polymer/components/web-animations-js/CONTRIBUTING.md b/catapult/third_party/polymer/components/web-animations-js/CONTRIBUTING.md
new file mode 100644
index 00000000..15142a7e
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/CONTRIBUTING.md
@@ -0,0 +1,123 @@
+## Developer instructions
+
+### Setup
+
+1. Fork web-animations/web-animations-js.
+1. `git clone git@github.com:$GITHUB_USER/web-animations-js.git`
+1. `git submodule update --init --recursive` (Necessary for running tests.)
+1. Install [node](https://nodejs.org/en/) and make sure `npm` is in your $PATH
+1. Run `npm install` in the respository to pull in development dependencies.
+1. Run `npm install -g grunt-cli` to get the build tools for the command line.
+
+### Contributing
+
+Note that development should occur against the `dev` branch, not `master`. This
+is the default target for pull requests.
+
+1. In your fork of web-animations-js, `git checkout dev` or create a new branch whose parent is dev.
+1. Run `grunt` to build the polyfill.
+1. Run `grunt test` to run polyfill and web-platform-tests tests.
+1. Commit changes to your fork.
+1. Create a pull request from your fork of web-animations-js to
+ [web-animations/web-animations-js/dev](https://github.com/web-animations/web-animations-js/tree/dev).
+1. Ensure that you've signed the [Google Contributor License Agreement](https://cla.developers.google.com/clas).
+
+
+## Debugging tests
+
+You can run the tests in an interactive mode with `grunt debug`. This starts the
+Karma server once for each polyfill target for each test framework.
+Navigate to `http://localhost:9876/debug.html` to open the test runner in your
+browser of choice, all test results appear in the Javascript console.
+Test failures can be accessed via `window.failures` and `window.formattedFailures`
+once the tests have completed.
+
+The polyfill target and tests can be specified as arguments to the `debug` task.
+Example: `grunt debug:web-animations-next:test/web-platform-tests/web-animations/animation/pause.html`
+Multiple test files may be listed with comma separation. Specifying files will output their URL in the command line.
+Example: `http://localhost:9876/base/test/web-platform-tests/web-animations/animation/pause.html`
+
+
+## Design notes
+
+[Design diagrams](https://drive.google.com/folderview?id=0B9rpPoIDv3vTNlZxOVp6a2tNa1E&usp=sharing)
+
+
+## Publishing a release
+
+1. Determine the version number for the release
+
+ * Increment the first number and reset others to 0 when there are large breaking changes
+ * Increment the second number and reset the third to 0 when there are significant new, but backwards compatible features
+ * Otherwise, increment the third number
+
+1. Add versioned release notes to `History.md`, for example:
+
+ ### 3.13.37 — *November 1, 2001*
+
+ * Fixed a bug where nothing worked
+
+ Use the following to generate a summary of commits, but edit the list to contain only
+ relevant information.
+
+ git log --first-parent `git describe --tags --abbrev=0 master`..dev --pretty=format:" * %s"
+
+1. Specify the new version inside `package.json` (for NPM), for example:
+
+ ```js
+ "version": "3.13.37",
+ ```
+
+1. Build the polyfill with `npm install && grunt` then update `docs/experimental.md`'s Build Target Comparison with the current gzipped sizes.
+
+1. Commit the above changes to web-animations-js/dev and merge to
+ web-animations-js/master.
+
+ ```sh
+ git checkout master
+ git merge dev --no-edit --quiet
+ ```
+
+1. Build and commit minified JavaScript files.
+
+ ```sh
+ npm install
+ grunt
+ # Optional "grunt test" to make sure everything still passes.
+ git add -f *.min.js{,.map}
+ git rm .gitignore
+ git commit -m 'Add build artifacts from '`cat .git/refs/heads/dev`
+ git push HEAD:refs/heads/master
+ ```
+
+1. Draft a [new release](https://github.com/web-animations/web-animations-js/releases) at the
+ commit pushed to web-animations-js in step #4. Copy the release notes from `History.md`
+ added in step #2.
+
+1. Once you've pushed to web-animations-js, run `npm publish` from that checked-out folder
+
+ To do this, you'll need to be a collaborator [on the NPM project](https://www.npmjs.com/package/web-animations-js), or have a collaborator help you.
+
+1. If there are any breaking changes to the API in this release you must notify web-animations-changes@googlegroups.com.
+
+ Only owners of the group may post to it so you may need to request ownership or ask someone to post it for you.
+
+## Testing architecture
+
+This is an overview of what happens when `grunt test` is run.
+
+1. Polyfill tests written in mocha and chai are run.
+ 1. grunt creates a karma config with mocha and chai adapters.
+ 1. grunt adds the test/js files as includes to the karma config.
+ 1. grunt starts the karma server with the config and waits for the result.
+ 1. The mocha adaptor runs the included tests and reports the results to karma.
+ 1. karma outputs results to the console and returns the final pass/fail result to grunt.
+1. web-platform-tests/web-animations tests written in testtharness.js are run.
+ 1. grunt creates a karma config with karma-testharness-adaptor.js included.
+ 1. grunt adds the web-platform-tests/web-animations files to the custom testharnessTests config in the karma config.
+ 1. grunt adds failure expectations to the custom testharnessTests config in the karma config.
+ 1. grunt starts the karma server with the config and waits for the result.
+ 1. The testharness.js adaptor runs the included tests (ignoring expected failures) and reports the results to karma.
+ 1. karma outputs results to the console and returns the final pass/fail result to grunt.
+1. grunt exits successfully if both test runs passed.
+
diff --git a/catapult/third_party/polymer/components/web-animations-js/COPYING b/catapult/third_party/polymer/components/web-animations-js/COPYING
new file mode 100644
index 00000000..d6456956
--- /dev/null
+++ b/catapult/third_party/polymer/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/catapult/third_party/polymer/components/web-animations-js/History.md b/catapult/third_party/polymer/components/web-animations-js/History.md
new file mode 100644
index 00000000..6deef415
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/History.md
@@ -0,0 +1,265 @@
+### 2.3.1 - *July 20 2017*
+
+ * Fix [https://github.com/web-animations/web-animations-js/issues/157](missing web-animations.min.js issue)
+
+### 2.3.0 - *July 20 2017*
+
+ * [Support IE/Edge SVG transforms.](https://github.com/web-animations/web-animations-js/pull/148)
+
+ * [Parse and evaluate calc expressions without eval.](https://github.com/web-animations/web-animations-js/pull/151)
+
+### 2.2.5 - *April 17 2017*
+
+ * Removed erroneously added *.gz files from release.
+
+### 2.2.4 - *April 14 2017*
+
+ * [Reverted adding 'use strict' to source files.](https://github.com/web-animations/web-animations-next/pull/124)
+
+### 2.2.3 - *April 13 2017*
+
+ * [Added HTML import targets.](https://github.com/web-animations/web-animations-js/pull/94)
+
+ * Added support for animating SVG related properties:
+ * [fill](https://github.com/web-animations/web-animations-next/pull/484)
+ * [floodColor](https://github.com/web-animations/web-animations-next/pull/484)
+ * [lightingColor](https://github.com/web-animations/web-animations-next/pull/484)
+ * [stopColor](https://github.com/web-animations/web-animations-next/pull/484)
+ * [strokeDashoffset](https://github.com/web-animations/web-animations-js/pull/96)
+ * [strokeDasharray](https://github.com/web-animations/web-animations-js/pull/120)
+
+ * [Fixed crash when animating non-invertable matrices.](https://github.com/web-animations/web-animations-js/pull/121)
+
+ * [Fixed source maps for Bower installs.](https://github.com/web-animations/web-animations-js/pull/93)
+
+ * [Updated README.md documentation structure.](https://github.com/web-animations/web-animations-next/pull/489)
+
+ * [Added 'use strict' to source files.](https://github.com/web-animations/web-animations-next/pull/488)
+
+### 2.2.2 - *August 3 2016*
+
+ * [Fixed handling of keyframes with overlapping offsets.](https://github.com/web-animations/web-animations-next/pull/470)
+
+ * [Throw TypeError on invalid keyframe input.](https://github.com/web-animations/web-animations-next/pull/471)
+
+ * [Fixed display and other animation properties being animated.](https://github.com/web-animations/web-animations-next/pull/474)
+
+ * [Throw InvalidStateError when calling play() on reversed infinite animation.](https://github.com/web-animations/web-animations-next/pull/475)
+
+ * [Fixed infinite loop in cubic-bezier timing function.](https://github.com/web-animations/web-animations-next/pull/476)
+
+ * [Fixed idle animations not becoming paused when seeked.](https://github.com/web-animations/web-animations-next/pull/479)
+
+ * [Fixed pause() not rewinding idl animations.](https://github.com/web-animations/web-animations-next/pull/480)
+
+ * [Extended cubic-bezier timing function domain from [0, 1] to (-Infinity, Infinity).](https://github.com/web-animations/web-animations-next/pull/481)
+
+ * [Fixed timing model to handle corner cases involving Infinity and 0 correctly.](https://github.com/web-animations/web-animations-next/pull/482)
+
+ * [Fixed source files missing from npm package.](https://github.com/web-animations/web-animations-next/pull/483)
+
+ * [Improved performance of starting and updating individual animations.](https://github.com/web-animations/web-animations-next/pull/485)
+
+### 2.2.1 - *April 28 2016*
+ * [Deprecated invalid timing inputs](https://github.com/web-animations/web-animations-next/pull/437) as they will soon throw [TypeErrors](https://github.com/web-animations/web-animations-next/pull/426) in native browsers.
+
+ For example, this is deprecated and will eventually throw a TypeError:
+
+ element.animate([], {
+ duration: -1,
+ iterationStart: -1,
+ iterations: -1,
+ easing: 'garbage string',
+ });
+
+ * [Fixed polyfill crash in browsers based on Chromium 36 to 46.](https://github.com/web-animations/web-animations-next/pull/434)
+
+ * [Increased cubic-bezier accuracy.](https://github.com/web-animations/web-animations-next/pull/428)
+
+ * [Added support for grad and turn units for angles.](https://github.com/web-animations/web-animations-next/pull/427)
+
+### 2.2.0 - *April 6 2016*
+ * Deprecated the use of hyphens in property names.
+
+ For example, this is deprecated:
+
+ element.animate([{'font-size': '0px'}, {'font-size': '10px'}]);
+
+ and this should be used instead:
+
+ element.animate([{fontSize: '0px'}, {fontSize: '10px'}]);
+
+ * Added arbitrary easing capitalisation.
+
+ * Added "id" effect option. (http://w3c.github.io/web-animations/#dom-keyframeanimationoptions-id)
+
+ * Added "oncancel" event handler.
+
+ * Added value list keyframe syntax.
+
+ As as alternative to:
+
+ element.animate([{color: 'red'}, {color: 'green'}, {color: 'blue'}]);
+
+ you can now use:
+
+ element.animate({color: ['red', 'green', 'blue']});
+
+ * Fixed easing TypeError in FireFox Nightly when using groups.
+
+ * Fixed delayed animation updates on Safari and Firefox
+
+ * Fixed infinite recursion when setting onfinish to null.
+
+### 2.1.4 - *December 1 2015*
+ * Use `Date.now()` instead of `performace.now()` for mobile Safari.
+
+### 2.1.3 - *October 12 2015*
+ * Removed web-animations.min.js.gz
+
+### 2.1.2 - *July 8 2015*
+ * Fix a bug where onfinish was being called for GroupEffects before they were finished.
+
+### 2.1.1 - *July 1 2015*
+ * Add Animation.timeline getter
+ * Add AnimationEffect.parent getter
+ * Make AnimationEffectTiming (returned by AnimationEffect.timing) attributes mutable
+ * Expose the Animation constructor
+ * Change custom effects from AnimationEffects to onsample functions. Custom effects should now be created by setting the onsample attribute of a KeyframeEffect.
+
+ For example, this is deprecated:
+
+ var myEffect = new KeyframeEffect(
+ element,
+ function(timeFraction, target, effect) {
+ target.style.opacity = timeFraction;
+ },
+ 1000);
+ var myAnimation = document.timeline.play(myEffect);
+
+ and this should be used insead:
+
+ var myEffect = new KeyframeEffect(element, [], 1000);
+ effect.onsample = function(timeFraction, effect, animation) {
+ effect.target.style.opacity = timeFraction;
+ };
+ var myAnimation = document.timeline.play(myEffect);
+
+### 2.1.0 - *June 15 2015*
+ * Fix bug affecting GroupEffects with infinite iteration children
+ * Add GroupEffect.firstChild and GroupEffect.lastChild
+ * Add initial values for most CSS properties
+ * Allow `timeline.play()` to be called with no arguments
+ * Add AnimationEffect.clone
+ * Add GroupEffect.append and GroupEffect.prepend
+ * Add AnimationEffect.remove
+ * Add Animation.ready and Animation.finished promises
+
+### 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/catapult/third_party/polymer/components/web-animations-js/README.md b/catapult/third_party/polymer/components/web-animations-js/README.md
new file mode 100644
index 00000000..e3410b61
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/README.md
@@ -0,0 +1,80 @@
+
+What is Web Animations?
+-----------------------
+
+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.
+
+What is in this repository?
+---------------------------
+
+A JavaScript implementation of the Web Animations API that provides Web
+Animation features in browsers that do not support it natively. The polyfill
+falls back to the native implementation when one is available.
+
+Quick start
+-----------
+
+Here's a simple example of an animation that fades and scales a `<div>`.
+[Try it as a live demo.](http://jsbin.com/yageyezabo/edit?html,js,output)
+
+```html
+<!-- Include the polyfill -->
+<script src="web-animations.min.js"></script>
+
+<!-- Set up a target to animate -->
+<div class="pulse" style="width: 150px;">Hello world!</div>
+
+<!-- Animate! -->
+<script>
+ var elem = document.querySelector('.pulse');
+ var animation = elem.animate({
+ opacity: [0.5, 1],
+ transform: ['scale(0.5)', 'scale(1)'],
+ }, {
+ direction: 'alternate',
+ duration: 500,
+ iterations: Infinity,
+ });
+</script>
+```
+
+Documentation
+-------------
+
+* [Codelab tutorial](https://github.com/web-animations/web-animations-codelabs)
+* [Examples of usage](/docs/examples.md)
+* [Live demos](https://web-animations.github.io/web-animations-demos)
+* [MDN reference](https://developer.mozilla.org/en-US/docs/Web/API/Element/animate)
+* [W3C specification](http://w3c.github.io/web-animations/)
+
+We love feedback!
+-----------------
+
+* For feedback on the API and the specification:
+ * 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/)).
+
+* For issues with the polyfill, report them on GitHub:
+<https://github.com/web-animations/web-animations-js/issues/new>.
+
+Keep up-to-date
+---------------
+
+Breaking polyfill changes will be announced on this low-volume mailing list:
+[web-animations-changes@googlegroups.com](https://groups.google.com/forum/#!forum/web-animations-changes).
+
+More info
+---------
+
+* [Technical details about the polyfill](/docs/support.md)
+ * [Browser support](/docs/support.md#browser-support)
+ * [Fallback to native](/docs/support.md#native-fallback)
+ * [Feature list](/docs/support.md#features)
+ * [Feature deprecation and removal processes](/docs/support.md#process-for-breaking-changes)
+* To test experimental API features, try one of the
+ [experimental targets](/docs/experimental.md)
diff --git a/catapult/third_party/polymer/components/web-animations-js/bower.json b/catapult/third_party/polymer/components/web-animations-js/bower.json
new file mode 100644
index 00000000..afa0f9e1
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/bower.json
@@ -0,0 +1,30 @@
+{
+ "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",
+ "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/catapult/third_party/polymer/components/web-animations-js/docs/examples.md b/catapult/third_party/polymer/components/web-animations-js/docs/examples.md
new file mode 100644
index 00000000..7957a29c
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/docs/examples.md
@@ -0,0 +1,241 @@
+#Examples of using Web Animations
+
+Property indexed keyframes syntax
+---------------------------------
+- Each CSS property specifies its keyframe values as a list, different properties may have differently sized lists.
+- The `easing` property applies its timing function to all keyframes.
+
+[**Live demo**](http://jsbin.com/qiyeriruru/edit?js,output)
+```javascript
+element.animate({
+ transform: [
+ 'scaleY(0.5)',
+ 'scaleX(0.5)',
+ 'scaleY(0.5)',
+ ],
+ background: [
+ 'red',
+ 'blue',
+ 'orange',
+ 'red',
+ ],
+ easing: 'ease-in-out',
+}, {
+ duration: 2000,
+ iterations: Infinity,
+});
+```
+
+Keyframe list syntax
+--------------------
+- Keyframes can be specified as a list of multiple CSS property values.
+- Individual keyframes can be given specific offsets and easings.
+- Not all properties need to be specified in every keyframe.
+- Offsets are implicitly distributed if not specified.
+
+[**Live demo**](http://jsbin.com/yajatoyere/edit?js,output)
+```javascript
+element.animate([
+ {
+ background: 'red',
+ transform: 'none',
+ easing: 'ease-out',
+ },
+ {
+ offset: 0.1,
+ transform: 'translateY(100px)',
+ easing: 'ease-in-out',
+ },
+ {
+ offset: 0.2,
+ transform: 'translate(100px, 100px)',
+ easing: 'ease-in-out',
+ },
+ {
+ offset: 0.4,
+ transform: 'translateX(100px)',
+ easing: 'ease-out',
+ },
+ {
+ background: 'blue',
+ transform: 'none',
+ },
+], {
+ duration: 4000,
+ iterations: Infinity,
+});
+```
+
+Timing parameters
+-----------------
+- Web Animations inherits many of its timing parameters from CSS Animations.
+- See the [specification](http://w3c.github.io/web-animations/#animationeffecttimingreadonly) for details on each parameter.
+
+[**Live demo**](http://jsbin.com/dabehipiyo/edit?js,output)
+```javascript
+element.animate({
+ transform: ['none', 'translateX(100px)'],
+ background: ['green', 'lime'],
+}, {
+ // Apply effect during delay.
+ fill: 'backwards',
+
+ // Delay starting by 500ms.
+ delay: 500,
+
+ // Iterations last for 2000ms.
+ duration: 2000,
+
+ // Start at 25% through an iteration.
+ iterationStart: 0.25,
+
+ // Run for 2 iterations.
+ iterations: 2,
+
+ // Play every second iteration backwards.
+ direction: 'alternate',
+
+ // Stop animating 500ms earlier.
+ endDelay: -500,
+
+ // The timing function to use with each iteration.
+ easing: 'ease-in-out',
+});
+```
+
+Playback controls
+-----------------
+- element.animate() returns an Animation object with basic playback controls.
+- See the [specification](http://w3c.github.io/web-animations/#the-animation-interface) for details on each method.
+
+[**Live demo**](http://jsbin.com/kutaqoxejo/edit?js,output)
+```javascript
+var animation = element.animate({
+ transform: ['none', 'translateX(200px)'],
+ background: ['red', 'orange'],
+}, {
+ duration: 4000,
+ fill: 'both',
+});
+animation.play();
+animation.reverse();
+animation.pause();
+animation.currentTime = 2000;
+animation.playbackRate += 0.25;
+animation.playbackRate -= 0.25;
+animation.finish();
+animation.cancel();
+```
+
+Transitioning states with element.animate()
+-------------------------------------------
+- This is an example of how to animate from one state to another using Web Animations.
+
+[**Live demo**](http://jsbin.com/musufiwule/edit?js,output)
+```javascript
+var isOpen = false;
+var openHeight = '100px';
+var closedHeight = '0px';
+var duration = 300;
+
+button.addEventListener('click', function() {
+ // Prevent clicks while we transition states.
+ button.disabled = true;
+ button.textContent = '...';
+
+ // Determine where we're animation from/to.
+ var fromHeight = isOpen ? openHeight : closedHeight;
+ var toHeight = isOpen ? closedHeight : openHeight;
+
+ // Start an animation transitioning from our current state to the final state.
+ var animation = element.animate({ height: [fromHeight, toHeight] }, duration);
+
+ // Update the button once the animation finishes.
+ animation.onfinish = function() {
+ isOpen = !isOpen;
+ button.textContent = isOpen ? 'Close' : 'Open';
+ button.disabled = false;
+ };
+
+ // Put our element in the final state.
+ // Inline styles are overridden by active animations.
+ // When the above animation finishes it will stop applying and
+ // the element's style will fall back onto this inline style value.
+ element.style.setProperty('height', toHeight);
+});
+```
+
+Generating animations
+---------------------
+- The Javascript API allows for procedurally generating a diverse range of interesting animations.
+
+[**Live demo**](http://jsbin.com/xolacasiyu/edit?js,output)
+```html
+<!DOCTYPE html>
+<script src="https://rawgit.com/web-animations/web-animations-js/master/web-animations.min.js"></script>
+
+<style>
+#perspective {
+ margin-left: 100px;
+ width: 300px;
+ height: 300px;
+ perspective: 600px;
+}
+
+#container {
+ width: 300px;
+ height: 300px;
+ line-height: 0;
+ transform-style: preserve-3d;
+}
+
+.box {
+ display: inline-block;
+ width: 20px;
+ height: 20px;
+ background: black;
+}
+</style>
+
+<div id="perspective">
+ <div id="container"></div>
+</div>
+
+<script>
+container.animate({
+ transform: [
+ 'rotateX(70deg) rotateZ(0deg)',
+ 'rotateX(70deg) rotateZ(360deg)',
+ ],
+}, {
+ duration: 20000,
+ iterations: Infinity,
+});
+
+for (var y = -7; y <= 7; y++) {
+ for (var x = -7; x <= 7; x++) {
+ var box = createBox();
+ box.animate({
+ transform: [
+ 'translateZ(0px)',
+ 'translateZ(20px)',
+ ],
+ opacity: [1, 0],
+ }, {
+ delay: (x*x + y*y) * 20,
+ duration: 2000,
+ iterations: Infinity,
+ direction: 'alternate',
+ easing: 'ease-in',
+ });
+ }
+}
+
+function createBox() {
+ var box = document.createElement('div');
+ box.className = 'box';
+ container.appendChild(box);
+ return box;
+}
+</script>
+```
diff --git a/catapult/third_party/polymer/components/web-animations-js/docs/experimental.md b/catapult/third_party/polymer/components/web-animations-js/docs/experimental.md
new file mode 100644
index 00000000..e3f22898
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/docs/experimental.md
@@ -0,0 +1,58 @@
+
+Experimental build targets
+--------------------------
+
+Most people should use the basic polyfill in `web-animations.min.js`. This
+tracks the Web Animations features that are supported natively in browsers.
+However, we also provide two additional build targets that contain experimental
+features.
+
+### 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) | 15KB | 19KB | 15KB |
+|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.
+
+Caveat: 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).
+
diff --git a/catapult/third_party/polymer/components/web-animations-js/docs/support.md b/catapult/third_party/polymer/components/web-animations-js/docs/support.md
new file mode 100644
index 00000000..ae07af76
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/docs/support.md
@@ -0,0 +1,69 @@
+
+Getting the polyfill
+--------------------
+
+There are three ways to get a copy of the polyfill:
+
+1. Download and use the `web-animations.min.js` file directly from this repository
+1. Using npm: Add [`web-animations-js`](https://www.npmjs.com/package/web-animations-js) to your `package.json`
+1. Using Bower: Add `web-animations/web-animations-js` to your `bower.json`
+
+Browser support
+---------------
+
+The polyfill is supported on modern versions of all major browsers, including:
+
+* Chrome 55+
+* Firefox 27+
+* IE10+ (including Edge)
+* Safari (iOS) 7.1+
+* Safari (Mac) 9+
+
+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 for better performance.
+
+Features
+--------
+
+The `web-animations.min.js` polyfill target tracks the Web Animations features
+that are supported natively in browsers. These include:
+
+* Element.animate()
+* Timing input (easings, duration, fillMode, etc.) for animation effects
+* Playback control (play, pause, reverse, currentTime, cancel, onfinish)
+* Support for animating CSS properties
+
+Caveat: 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:
+
+```js
+element.animate({transform: ['none', 'translateX(100px)']}, 1000);
+```
+
+will work in all browsers that implement a conforming version of transform, but
+
+```js
+element.animate({webkitTransform: ['none', 'translateX(100px)']}, 1000);
+```
+
+will not work anywhere.
+
+Process for 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 them by not updating*.
+
diff --git a/catapult/third_party/polymer/components/web-animations-js/externs/README.md b/catapult/third_party/polymer/components/web-animations-js/externs/README.md
new file mode 100644
index 00000000..3f16bf65
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/externs/README.md
@@ -0,0 +1,10 @@
+
+Closure Compiler Externs for Web Animations
+-------------------------------------------
+
+This folder contains externs for using the Web Animations API with the Closure
+Compiler. These externs aren't strictly part of the polyfill, as they can be
+used for either the native or polyfilled versions.
+
+web-animations-next requires that you also include web-animations.
+
diff --git a/catapult/third_party/polymer/components/web-animations-js/externs/web-animations-next.js b/catapult/third_party/polymer/components/web-animations-js/externs/web-animations-next.js
new file mode 100644
index 00000000..743a3ba5
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/externs/web-animations-next.js
@@ -0,0 +1,113 @@
+/*
+ * Copyright 2016 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.
+ */
+
+
+/**
+ * @fileoverview Basic externs for the Web Animations API (Level 2 / Groups).
+ * This is not intended to be exhaustive, and requires the base externs from
+ * web-animations.js.
+ * @externs
+ */
+
+
+/**
+ * @interface
+ */
+var AnimationEffectReadOnly = function() {};
+
+/** @type {!AnimationEffectTiming} */
+AnimationEffectReadOnly.prototype.timing;
+
+
+/**
+ * @param {Element} target
+ * @param {!Array<!Object>} frames
+ * @param {(number|AnimationEffectTimingProperties)=} opt_options
+ * @constructor
+ * @implements {AnimationEffectReadOnly}
+ */
+var KeyframeEffect = function(target, frames, opt_options) {};
+
+/**
+ * @return {!Array<!Object>}
+ */
+KeyframeEffect.prototype.getFrames = function() {};
+
+/** @type {!AnimationEffectTiming} */
+KeyframeEffect.prototype.timing;
+
+/** @type {Element} */
+KeyframeEffect.prototype.target;
+
+/** @type {?function(number, !KeyframeEffect, !Animation)} */
+KeyframeEffect.prototype.onsample;
+
+
+/**
+ * @param {!Array<!AnimationEffectReadOnly>} children
+ * @param {AnimationEffectTimingProperties=} opt_timing
+ * @constructor
+ * @implements {AnimationEffectReadOnly}
+ */
+var SequenceEffect = function(children, opt_timing) {};
+
+/** @type {!AnimationEffectTiming} */
+SequenceEffect.prototype.timing;
+
+/** @type {!Array<!AnimationEffectReadOnly>} */
+SequenceEffect.prototype.children;
+
+
+/**
+ * @param {!Array<!AnimationEffectReadOnly>} children
+ * @param {AnimationEffectTimingProperties=} opt_timing
+ * @constructor
+ * @implements {AnimationEffectReadOnly}
+ */
+var GroupEffect = function(children, opt_timing) {};
+
+/** @type {!AnimationEffectTiming} */
+GroupEffect.prototype.timing;
+
+/** @type {!Array<!AnimationEffectReadOnly>} */
+GroupEffect.prototype.children;
+
+
+/**
+ * @interface
+ */
+var AnimationTimeline = function() {};
+
+/** @type {?number} */
+AnimationTimeline.prototype.currentTime;
+
+/**
+ * @param {!AnimationEffectReadOnly} effect
+ * @return {!Animation}
+ */
+AnimationTimeline.prototype.play = function(effect) {};
+
+/**
+ * @interface
+ * @extends {AnimationTimeline}
+ */
+var DocumentTimeline = function() {};
+
+/** @type {AnimationEffectReadOnly|undefined} */
+Animation.prototype.effect;
+
+/** @type {!DocumentTimeline} */
+Document.prototype.timeline;
diff --git a/catapult/third_party/polymer/components/web-animations-js/externs/web-animations.js b/catapult/third_party/polymer/components/web-animations-js/externs/web-animations.js
new file mode 100644
index 00000000..7059b400
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/externs/web-animations.js
@@ -0,0 +1,126 @@
+/*
+ * Copyright 2016 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.
+ */
+
+
+/**
+ * @fileoverview Basic externs for the Web Animations API. This is not
+ * nessecarily exhaustive. For more information, see the spec-
+ * https://w3c.github.io/web-animations
+ * @externs
+ */
+
+
+/**
+ * @param {!Array<!Object>} frames
+ * @param {(number|AnimationEffectTimingProperties)=} opt_options
+ * @return {!Animation}
+ */
+Element.prototype.animate = function(frames, opt_options) {};
+
+
+/**
+ * @interface
+ * @extends {EventTarget}
+ */
+var Animation = function() {};
+
+/**
+ * @return {undefined}
+ */
+Animation.prototype.cancel = function() {};
+
+/**
+ * @return {undefined}
+ */
+Animation.prototype.finish = function() {};
+
+/**
+ * @return {undefined}
+ */
+Animation.prototype.reverse = function() {};
+
+/**
+ * @return {undefined}
+ */
+Animation.prototype.pause = function() {};
+
+/**
+ * @return {undefined}
+ */
+Animation.prototype.play = function() {};
+
+/** @type {number} */
+Animation.prototype.startTime;
+
+/** @type {number} */
+Animation.prototype.currentTime;
+
+/** @type {number} */
+Animation.prototype.playbackRate;
+
+/** @type {string} */
+Animation.prototype.playState;
+
+/** @type {?function(!Event)} */
+Animation.prototype.oncancel;
+
+/** @type {?function(!Event)} */
+Animation.prototype.onfinish;
+
+
+/**
+ * @typedef {{
+ * delay: (number|undefined),
+ * endDelay: (number|undefined),
+ * fillMode: (string|undefined),
+ * iterationStart: (number|undefined),
+ * iterations: (number|undefined),
+ * duration: (number|string|undefined),
+ * direction: (string|undefined),
+ * easing: (string|undefined)
+ * }}
+ */
+var AnimationEffectTimingProperties;
+
+
+/**
+ * @interface
+ */
+var AnimationEffectTiming = function() {};
+
+/** @type {number} */
+AnimationEffectTiming.prototype.delay;
+
+/** @type {number} */
+AnimationEffectTiming.prototype.endDelay;
+
+/** @type {string} */
+AnimationEffectTiming.prototype.fillMode;
+
+/** @type {number} */
+AnimationEffectTiming.prototype.iterationStart;
+
+/** @type {number} */
+AnimationEffectTiming.prototype.iterations;
+
+/** @type {number|string} */
+AnimationEffectTiming.prototype.duration;
+
+/** @type {string} */
+AnimationEffectTiming.prototype.direction;
+
+/** @type {string} */
+AnimationEffectTiming.prototype.easing;
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/animation.js b/catapult/third_party/polymer/components/web-animations-js/src/animation.js
new file mode 100644
index 00000000..e9f64826
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/animation.js
@@ -0,0 +1,279 @@
+// 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(shared, scope, testing) {
+
+ shared.sequenceNumber = 0;
+
+ var AnimationEvent = function(target, currentTime, timelineTime) {
+ this.target = target;
+ this.currentTime = currentTime;
+ this.timelineTime = timelineTime;
+
+ this.type = 'finish';
+ this.bubbles = false;
+ this.cancelable = false;
+ this.currentTarget = target;
+ this.defaultPrevented = false;
+ this.eventPhase = Event.AT_TARGET;
+ this.timeStamp = Date.now();
+ };
+
+ scope.Animation = function(effect) {
+ this.id = '';
+ if (effect && effect._id) {
+ this.id = effect._id;
+ }
+ this._sequenceNumber = shared.sequenceNumber++;
+ this._currentTime = 0;
+ this._startTime = null;
+ this._paused = false;
+ this._playbackRate = 1;
+ this._inTimeline = true;
+ this._finishedFlag = true;
+ this.onfinish = null;
+ this._finishHandlers = [];
+ this._effect = effect;
+ this._inEffect = this._effect._update(0);
+ this._idle = true;
+ this._currentTimePending = false;
+ };
+
+ scope.Animation.prototype = {
+ _ensureAlive: function() {
+ // If an animation is playing backwards and is not fill backwards/both
+ // then it should go out of effect when it reaches the start of its
+ // active interval (currentTime == 0).
+ if (this.playbackRate < 0 && this.currentTime === 0) {
+ this._inEffect = this._effect._update(-1);
+ } else {
+ this._inEffect = this._effect._update(this.currentTime);
+ }
+ if (!this._inTimeline && (this._inEffect || !this._finishedFlag)) {
+ this._inTimeline = true;
+ scope.timeline._animations.push(this);
+ }
+ },
+ _tickCurrentTime: function(newTime, ignoreLimit) {
+ if (newTime != this._currentTime) {
+ this._currentTime = newTime;
+ if (this._isFinished && !ignoreLimit)
+ this._currentTime = this._playbackRate > 0 ? this._totalDuration : 0;
+ this._ensureAlive();
+ }
+ },
+ get currentTime() {
+ if (this._idle || this._currentTimePending)
+ return null;
+ return this._currentTime;
+ },
+ set currentTime(newTime) {
+ newTime = +newTime;
+ if (isNaN(newTime))
+ return;
+ scope.restart();
+ if (!this._paused && this._startTime != null) {
+ this._startTime = this._timeline.currentTime - newTime / this._playbackRate;
+ }
+ this._currentTimePending = false;
+ if (this._currentTime == newTime)
+ return;
+ if (this._idle) {
+ this._idle = false;
+ this._paused = true;
+ }
+ this._tickCurrentTime(newTime, true);
+ scope.applyDirtiedAnimation(this);
+ },
+ get startTime() {
+ return this._startTime;
+ },
+ set startTime(newTime) {
+ newTime = +newTime;
+ if (isNaN(newTime))
+ return;
+ if (this._paused || this._idle)
+ return;
+ this._startTime = newTime;
+ this._tickCurrentTime((this._timeline.currentTime - this._startTime) * this.playbackRate);
+ scope.applyDirtiedAnimation(this);
+ },
+ get playbackRate() {
+ return this._playbackRate;
+ },
+ set playbackRate(value) {
+ if (value == this._playbackRate) {
+ return;
+ }
+ var oldCurrentTime = this.currentTime;
+ this._playbackRate = value;
+ this._startTime = null;
+ if (this.playState != 'paused' && this.playState != 'idle') {
+ this._finishedFlag = false;
+ this._idle = false;
+ this._ensureAlive();
+ scope.applyDirtiedAnimation(this);
+ }
+ if (oldCurrentTime != null) {
+ this.currentTime = oldCurrentTime;
+ }
+ },
+ get _isFinished() {
+ return !this._idle && (this._playbackRate > 0 && this._currentTime >= this._totalDuration ||
+ this._playbackRate < 0 && this._currentTime <= 0);
+ },
+ get _totalDuration() { return this._effect._totalDuration; },
+ get playState() {
+ if (this._idle)
+ return 'idle';
+ if ((this._startTime == null && !this._paused && this.playbackRate != 0) || this._currentTimePending)
+ return 'pending';
+ if (this._paused)
+ return 'paused';
+ if (this._isFinished)
+ return 'finished';
+ return 'running';
+ },
+ _rewind: function() {
+ if (this._playbackRate >= 0) {
+ this._currentTime = 0;
+ } else if (this._totalDuration < Infinity) {
+ this._currentTime = this._totalDuration;
+ } else {
+ throw new DOMException(
+ 'Unable to rewind negative playback rate animation with infinite duration',
+ 'InvalidStateError');
+ }
+ },
+ play: function() {
+ this._paused = false;
+ if (this._isFinished || this._idle) {
+ this._rewind();
+ this._startTime = null;
+ }
+ this._finishedFlag = false;
+ this._idle = false;
+ this._ensureAlive();
+ scope.applyDirtiedAnimation(this);
+ },
+ pause: function() {
+ if (!this._isFinished && !this._paused && !this._idle) {
+ this._currentTimePending = true;
+ } else if (this._idle) {
+ this._rewind();
+ this._idle = false;
+ }
+ this._startTime = null;
+ this._paused = true;
+ },
+ finish: function() {
+ if (this._idle)
+ return;
+ this.currentTime = this._playbackRate > 0 ? this._totalDuration : 0;
+ this._startTime = this._totalDuration - this.currentTime;
+ this._currentTimePending = false;
+ scope.applyDirtiedAnimation(this);
+ },
+ cancel: function() {
+ if (!this._inEffect)
+ return;
+ this._inEffect = false;
+ this._idle = true;
+ this._paused = false;
+ this._isFinished = true;
+ this._finishedFlag = true;
+ this._currentTime = 0;
+ this._startTime = null;
+ this._effect._update(null);
+ // effects are invalid after cancellation as the animation state
+ // needs to un-apply.
+ scope.applyDirtiedAnimation(this);
+ },
+ reverse: function() {
+ this.playbackRate *= -1;
+ this.play();
+ },
+ addEventListener: function(type, handler) {
+ if (typeof handler == 'function' && type == 'finish')
+ this._finishHandlers.push(handler);
+ },
+ removeEventListener: function(type, handler) {
+ if (type != 'finish')
+ return;
+ var index = this._finishHandlers.indexOf(handler);
+ if (index >= 0)
+ this._finishHandlers.splice(index, 1);
+ },
+ _fireEvents: function(baseTime) {
+ if (this._isFinished) {
+ if (!this._finishedFlag) {
+ var event = new AnimationEvent(this, this._currentTime, baseTime);
+ var handlers = this._finishHandlers.concat(this.onfinish ? [this.onfinish] : []);
+ setTimeout(function() {
+ handlers.forEach(function(handler) {
+ handler.call(event.target, event);
+ });
+ }, 0);
+ this._finishedFlag = true;
+ }
+ } else {
+ this._finishedFlag = false;
+ }
+ },
+ _tick: function(timelineTime, isAnimationFrame) {
+ if (!this._idle && !this._paused) {
+ if (this._startTime == null) {
+ if (isAnimationFrame) {
+ this.startTime = timelineTime - this._currentTime / this.playbackRate;
+ }
+ } else if (!this._isFinished) {
+ this._tickCurrentTime((timelineTime - this._startTime) * this.playbackRate);
+ }
+ }
+
+ if (isAnimationFrame) {
+ this._currentTimePending = false;
+ this._fireEvents(timelineTime);
+ }
+ },
+ get _needsTick() {
+ return (this.playState in {'pending': 1, 'running': 1}) || !this._finishedFlag;
+ },
+ _targetAnimations: function() {
+ var target = this._effect._target;
+ if (!target._activeAnimations) {
+ target._activeAnimations = [];
+ }
+ return target._activeAnimations;
+ },
+ _markTarget: function() {
+ var animations = this._targetAnimations();
+ if (animations.indexOf(this) === -1) {
+ animations.push(this);
+ }
+ },
+ _unmarkTarget: function() {
+ var animations = this._targetAnimations();
+ var index = animations.indexOf(this);
+ if (index !== -1) {
+ animations.splice(index, 1);
+ }
+ },
+ };
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.webAnimations1Animation = scope.Animation;
+ }
+
+})(webAnimationsShared, webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/apply-preserving-inline-style.js b/catapult/third_party/polymer/components/web-animations-js/src/apply-preserving-inline-style.js
new file mode 100644
index 00000000..4002a2f5
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/apply-preserving-inline-style.js
@@ -0,0 +1,239 @@
+// 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(scope, testing) {
+
+ var SVG_TRANSFORM_PROP = '_webAnimationsUpdateSvgTransformAttr';
+
+ /**
+ * IE/Edge do not support `transform` styles for SVG elements. Instead,
+ * `transform` attribute can be animated with some restrictions.
+ * See https://connect.microsoft.com/IE/feedback/details/811744/ie11-bug-with-implementation-of-css-transforms-in-svg,
+ * https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/1173754/,
+ * https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/101242/, etc.
+ * The same problem is exhibited by pre-Chrome Android browsers (ICS).
+ * Unfortunately, there's no easy way to feature-detect it.
+ */
+ function updateSvgTransformAttr(window, element) {
+ if (!element.namespaceURI || element.namespaceURI.indexOf('/svg') == -1) {
+ return false;
+ }
+ if (!(SVG_TRANSFORM_PROP in window)) {
+ window[SVG_TRANSFORM_PROP] =
+ /Trident|MSIE|IEMobile|Edge|Android 4/i.test(window.navigator.userAgent);
+ }
+ return window[SVG_TRANSFORM_PROP];
+ }
+
+ var styleAttributes = {
+ cssText: 1,
+ length: 1,
+ parentRule: 1,
+ };
+
+ var styleMethods = {
+ getPropertyCSSValue: 1,
+ getPropertyPriority: 1,
+ getPropertyValue: 1,
+ item: 1,
+ removeProperty: 1,
+ setProperty: 1,
+ };
+
+ var styleMutatingMethods = {
+ removeProperty: 1,
+ setProperty: 1,
+ };
+
+ function configureProperty(object, property, descriptor) {
+ descriptor.enumerable = true;
+ descriptor.configurable = true;
+ Object.defineProperty(object, property, descriptor);
+ }
+
+ function AnimatedCSSStyleDeclaration(element) {
+ WEB_ANIMATIONS_TESTING && console.assert(!(element.style instanceof AnimatedCSSStyleDeclaration),
+ 'Element must not already have an animated style attached.');
+
+ this._element = element;
+ // Stores the inline style of the element on its behalf while the
+ // polyfill uses the element's inline style to simulate web animations.
+ // This is needed to fake regular inline style CSSOM access on the element.
+ this._surrogateStyle = document.createElementNS('http://www.w3.org/1999/xhtml', 'div').style;
+ this._style = element.style;
+ this._length = 0;
+ this._isAnimatedProperty = {};
+ this._updateSvgTransformAttr = updateSvgTransformAttr(window, element);
+ this._savedTransformAttr = null;
+
+ // Copy the inline style contents over to the surrogate.
+ for (var i = 0; i < this._style.length; i++) {
+ var property = this._style[i];
+ this._surrogateStyle[property] = this._style[property];
+ }
+ this._updateIndices();
+ }
+
+ AnimatedCSSStyleDeclaration.prototype = {
+ get cssText() {
+ return this._surrogateStyle.cssText;
+ },
+ set cssText(text) {
+ var isAffectedProperty = {};
+ for (var i = 0; i < this._surrogateStyle.length; i++) {
+ isAffectedProperty[this._surrogateStyle[i]] = true;
+ }
+ this._surrogateStyle.cssText = text;
+ this._updateIndices();
+ for (var i = 0; i < this._surrogateStyle.length; i++) {
+ isAffectedProperty[this._surrogateStyle[i]] = true;
+ }
+ for (var property in isAffectedProperty) {
+ if (!this._isAnimatedProperty[property]) {
+ this._style.setProperty(property, this._surrogateStyle.getPropertyValue(property));
+ }
+ }
+ },
+ get length() {
+ return this._surrogateStyle.length;
+ },
+ get parentRule() {
+ return this._style.parentRule;
+ },
+ // Mirror the indexed getters and setters of the surrogate style.
+ _updateIndices: function() {
+ while (this._length < this._surrogateStyle.length) {
+ Object.defineProperty(this, this._length, {
+ configurable: true,
+ enumerable: false,
+ get: (function(index) {
+ return function() { return this._surrogateStyle[index]; };
+ })(this._length)
+ });
+ this._length++;
+ }
+ while (this._length > this._surrogateStyle.length) {
+ this._length--;
+ Object.defineProperty(this, this._length, {
+ configurable: true,
+ enumerable: false,
+ value: undefined
+ });
+ }
+ },
+ _set: function(property, value) {
+ this._style[property] = value;
+ this._isAnimatedProperty[property] = true;
+ if (this._updateSvgTransformAttr &&
+ scope.unprefixedPropertyName(property) == 'transform') {
+ // On IE/Edge, also set SVG element's `transform` attribute to 2d
+ // matrix of the transform. The `transform` style does not work, but
+ // `transform` attribute can be used instead.
+ // Notice, if the platform indeed supports SVG/CSS transforms the CSS
+ // declaration is supposed to override the attribute.
+ if (this._savedTransformAttr == null) {
+ this._savedTransformAttr = this._element.getAttribute('transform');
+ }
+ this._element.setAttribute('transform', scope.transformToSvgMatrix(value));
+ }
+ },
+ _clear: function(property) {
+ this._style[property] = this._surrogateStyle[property];
+ if (this._updateSvgTransformAttr &&
+ scope.unprefixedPropertyName(property) == 'transform') {
+ if (this._savedTransformAttr) {
+ this._element.setAttribute('transform', this._savedTransformAttr);
+ } else {
+ this._element.removeAttribute('transform');
+ }
+ this._savedTransformAttr = null;
+ }
+ delete this._isAnimatedProperty[property];
+ },
+ };
+
+ // Wrap the style methods.
+ for (var method in styleMethods) {
+ AnimatedCSSStyleDeclaration.prototype[method] = (function(method, modifiesStyle) {
+ return function() {
+ var result = this._surrogateStyle[method].apply(this._surrogateStyle, arguments);
+ if (modifiesStyle) {
+ if (!this._isAnimatedProperty[arguments[0]])
+ this._style[method].apply(this._style, arguments);
+ this._updateIndices();
+ }
+ return result;
+ }
+ })(method, method in styleMutatingMethods);
+ }
+
+ // Wrap the style.cssProperty getters and setters.
+ for (var property in document.documentElement.style) {
+ if (property in styleAttributes || property in styleMethods) {
+ continue;
+ }
+ (function(property) {
+ configureProperty(AnimatedCSSStyleDeclaration.prototype, property, {
+ get: function() {
+ return this._surrogateStyle[property];
+ },
+ set: function(value) {
+ this._surrogateStyle[property] = value;
+ this._updateIndices();
+ if (!this._isAnimatedProperty[property])
+ this._style[property] = value;
+ }
+ });
+ })(property);
+ }
+
+ function ensureStyleIsPatched(element) {
+ if (element._webAnimationsPatchedStyle)
+ return;
+
+ var animatedStyle = new AnimatedCSSStyleDeclaration(element);
+ try {
+ configureProperty(element, 'style', { get: function() { return animatedStyle; } });
+ } catch (_) {
+ // iOS and older versions of Safari (pre v7) do not support overriding an element's
+ // style object. Animations will clobber any inline styles as a result.
+ element.style._set = function(property, value) {
+ element.style[property] = value;
+ };
+ element.style._clear = function(property) {
+ element.style[property] = '';
+ };
+ }
+
+ // We must keep a handle on the patched style to prevent it from getting GC'd.
+ element._webAnimationsPatchedStyle = element.style;
+ }
+
+ scope.apply = function(element, property, value) {
+ ensureStyleIsPatched(element);
+ element.style._set(scope.propertyName(property), value);
+ };
+
+ scope.clear = function(element, property) {
+ if (element._webAnimationsPatchedStyle) {
+ element.style._clear(scope.propertyName(property));
+ }
+ };
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.ensureStyleIsPatched = ensureStyleIsPatched;
+ testing.updateSvgTransformAttr = updateSvgTransformAttr;
+ }
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/apply.js b/catapult/third_party/polymer/components/web-animations-js/src/apply.js
new file mode 100644
index 00000000..3200f967
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/apply.js
@@ -0,0 +1,25 @@
+// 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(scope, testing) {
+
+ scope.apply = function(element, property, value) {
+ element.style[scope.propertyName(property)] = value;
+ };
+
+ scope.clear = function(element, property) {
+ element.style[scope.propertyName(property)] = '';
+ };
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/box-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/box-handler.js
new file mode 100644
index 00000000..3399263a
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/box-handler.js
@@ -0,0 +1,57 @@
+// 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(scope, testing) {
+ function consumeLengthPercentOrAuto(string) {
+ return scope.consumeLengthOrPercent(string) || scope.consumeToken(/^auto/, string);
+ }
+ function parseBox(string) {
+ var result = scope.consumeList([
+ scope.ignore(scope.consumeToken.bind(null, /^rect/)),
+ scope.ignore(scope.consumeToken.bind(null, /^\(/)),
+ scope.consumeRepeated.bind(null, consumeLengthPercentOrAuto, /^,/),
+ scope.ignore(scope.consumeToken.bind(null, /^\)/)),
+ ], string);
+ if (result && result[0].length == 4) {
+ return result[0];
+ }
+ }
+
+ function mergeComponent(left, right) {
+ if (left == 'auto' || right == 'auto') {
+ return [true, false, function(t) {
+ var result = t ? left : right;
+ if (result == 'auto') {
+ return 'auto';
+ }
+ // FIXME: There's probably a better way to turn a dimension back into a string.
+ var merged = scope.mergeDimensions(result, result);
+ return merged[2](merged[0]);
+ }];
+ }
+ return scope.mergeDimensions(left, right);
+ }
+
+ function wrap(result) {
+ return 'rect(' + result + ')';
+ }
+
+ var mergeBoxes = scope.mergeWrappedNestedRepeated.bind(null, wrap, mergeComponent, ', ');
+
+ scope.parseBox = parseBox;
+ scope.mergeBoxes = mergeBoxes;
+
+ scope.addPropertiesHandler(parseBox, mergeBoxes, ['clip']);
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/color-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/color-handler.js
new file mode 100644
index 00000000..3a05bff0
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/color-handler.js
@@ -0,0 +1,63 @@
+// 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(scope, testing) {
+
+ var canvas = document.createElementNS('http://www.w3.org/1999/xhtml', 'canvas');
+ canvas.width = canvas.height = 1;
+ var context = canvas.getContext('2d');
+
+ function parseColor(string) {
+ string = string.trim();
+ // The context ignores invalid colors
+ context.fillStyle = '#000';
+ context.fillStyle = string;
+ var contextSerializedFillStyle = context.fillStyle;
+ context.fillStyle = '#fff';
+ context.fillStyle = string;
+ if (contextSerializedFillStyle != context.fillStyle)
+ return;
+ context.fillRect(0, 0, 1, 1);
+ var pixelColor = context.getImageData(0, 0, 1, 1).data;
+ context.clearRect(0, 0, 1, 1);
+ var alpha = pixelColor[3] / 255;
+ return [pixelColor[0] * alpha, pixelColor[1] * alpha, pixelColor[2] * alpha, alpha];
+ }
+
+ function mergeColors(left, right) {
+ return [left, right, function(x) {
+ function clamp(v) {
+ return Math.max(0, Math.min(255, v));
+ }
+ if (x[3]) {
+ for (var i = 0; i < 3; i++)
+ x[i] = Math.round(clamp(x[i] / x[3]));
+ }
+ x[3] = scope.numberToString(scope.clamp(0, 1, x[3]));
+ return 'rgba(' + x.join(',') + ')';
+ }];
+ }
+
+ scope.addPropertiesHandler(parseColor, mergeColors,
+ ['background-color', 'border-bottom-color', 'border-left-color', 'border-right-color',
+ 'border-top-color', 'color', 'fill', 'flood-color', 'lighting-color',
+ 'outline-color', 'stop-color', 'stroke', 'text-decoration-color']);
+ scope.consumeColor = scope.consumeParenthesised.bind(null, parseColor);
+ scope.mergeColors = mergeColors;
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.parseColor = parseColor;
+ }
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/deprecation.js b/catapult/third_party/polymer/components/web-animations-js/src/deprecation.js
new file mode 100644
index 00000000..6bdb4a22
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/deprecation.js
@@ -0,0 +1,47 @@
+// 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(shared) {
+
+ var silenced = {};
+
+ shared.isDeprecated = function(feature, date, advice, plural) {
+ if (WEB_ANIMATIONS_TESTING) {
+ return true;
+ }
+
+ var auxVerb = plural ? 'are' : 'is';
+ var today = new Date();
+ var expiry = new Date(date);
+ expiry.setMonth(expiry.getMonth() + 3); // 3 months grace period
+
+ if (today < expiry) {
+ if (!(feature in silenced)) {
+ console.warn('Web Animations: ' + feature + ' ' + auxVerb + ' deprecated and will stop working on ' + expiry.toDateString() + '. ' + advice);
+ }
+ silenced[feature] = true;
+ return false;
+ } else {
+ return true;
+ }
+ };
+
+ shared.deprecated = function(feature, date, advice, plural) {
+ var auxVerb = plural ? 'are' : 'is';
+ if (shared.isDeprecated(feature, date, advice, plural)) {
+ throw new Error(feature + ' ' + auxVerb + ' no longer supported. ' + advice);
+ }
+ };
+
+})(webAnimationsShared);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/dev.js b/catapult/third_party/polymer/components/web-animations-js/src/dev.js
new file mode 100644
index 00000000..a5e225c0
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/dev.js
@@ -0,0 +1,16 @@
+// 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.
+
+var WEB_ANIMATIONS_TESTING = false;
+var webAnimationsTesting = null;
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/dimension-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/dimension-handler.js
new file mode 100644
index 00000000..9e487f97
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/dimension-handler.js
@@ -0,0 +1,240 @@
+// 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(scope, testing) {
+
+ // Evaluates a calc expression.
+ // https://drafts.csswg.org/css-values-3/#calc-notation
+ function calculate(expression) {
+ // In calc expressions, white space is required on both sides of the
+ // + and - operators. https://drafts.csswg.org/css-values-3/#calc-notation
+ // Thus any + or - immediately adjacent to . or 0..9 is part of the number,
+ // e.g. -1.23e+45
+ // This regular expression matches ( ) * / + - and numbers.
+ var tokenRegularExpression = /([\+\-\w\.]+|[\(\)\*\/])/g;
+ var currentToken;
+ function consume() {
+ var matchResult = tokenRegularExpression.exec(expression);
+ if (matchResult)
+ currentToken = matchResult[0];
+ else
+ currentToken = undefined;
+ }
+ consume(); // Read the initial token.
+
+ function calcNumber() {
+ // https://drafts.csswg.org/css-values-3/#number-value
+ var result = Number(currentToken);
+ consume();
+ return result;
+ }
+
+ function calcValue() {
+ // <calc-value> = <number> | <dimension> | <percentage> | ( <calc-sum> )
+ if (currentToken !== '(')
+ return calcNumber();
+ consume();
+ var result = calcSum();
+ if (currentToken !== ')')
+ return NaN;
+ consume();
+ return result;
+ }
+
+ function calcProduct() {
+ // <calc-product> = <calc-value> [ '*' <calc-value> | '/' <calc-number-value> ]*
+ var left = calcValue();
+ while (currentToken === '*' || currentToken === '/') {
+ var operator = currentToken;
+ consume();
+ var right = calcValue();
+ if (operator === '*')
+ left *= right;
+ else
+ left /= right;
+ }
+ return left;
+ }
+
+ function calcSum() {
+ // <calc-sum> = <calc-product> [ [ '+' | '-' ] <calc-product> ]*
+ var left = calcProduct();
+ while (currentToken === '+' || currentToken === '-') {
+ var operator = currentToken;
+ consume();
+ var right = calcProduct();
+ if (operator === '+')
+ left += right;
+ else
+ left -= right;
+ }
+ return left;
+ }
+
+ // <calc()> = calc( <calc-sum> )
+ return calcSum();
+ }
+
+ function parseDimension(unitRegExp, string) {
+ string = string.trim().toLowerCase();
+
+ if (string == '0' && 'px'.search(unitRegExp) >= 0)
+ return {px: 0};
+
+ // If we have parenthesis, we're a calc and need to start with 'calc'.
+ if (!/^[^(]*$|^calc/.test(string))
+ return;
+ string = string.replace(/calc\(/g, '(');
+
+ // We tag units by prefixing them with 'U' (note that we are already
+ // lowercase) to prevent problems with types which are substrings of
+ // each other (although prefixes may be problematic!)
+ var matchedUnits = {};
+ string = string.replace(unitRegExp, function(match) {
+ matchedUnits[match] = null;
+ return 'U' + match;
+ });
+ var taggedUnitRegExp = 'U(' + unitRegExp.source + ')';
+
+ // Validating input is simply applying as many reductions as we can.
+ var typeCheck = string.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g, 'N')
+ .replace(new RegExp('N' + taggedUnitRegExp, 'g'), 'D')
+ .replace(/\s[+-]\s/g, 'O')
+ .replace(/\s/g, '');
+ var reductions = [/N\*(D)/g, /(N|D)[*/]N/g, /(N|D)O\1/g, /\((N|D)\)/g];
+ var i = 0;
+ while (i < reductions.length) {
+ if (reductions[i].test(typeCheck)) {
+ typeCheck = typeCheck.replace(reductions[i], '$1');
+ i = 0;
+ } else {
+ i++;
+ }
+ }
+ if (typeCheck != 'D')
+ return;
+
+ for (var unit in matchedUnits) {
+ var result = calculate(string.replace(new RegExp('U' + unit, 'g'), '').replace(new RegExp(taggedUnitRegExp, 'g'), '*0'));
+ if (!isFinite(result))
+ return;
+ matchedUnits[unit] = result;
+ }
+ return matchedUnits;
+ }
+
+ function mergeDimensionsNonNegative(left, right) {
+ return mergeDimensions(left, right, true);
+ }
+
+ function mergeDimensions(left, right, nonNegative) {
+ var units = [], unit;
+ for (unit in left)
+ units.push(unit);
+ for (unit in right) {
+ if (units.indexOf(unit) < 0)
+ units.push(unit);
+ }
+
+ left = units.map(function(unit) { return left[unit] || 0; });
+ right = units.map(function(unit) { return right[unit] || 0; });
+ return [left, right, function(values) {
+ var result = values.map(function(value, i) {
+ if (values.length == 1 && nonNegative) {
+ value = Math.max(value, 0);
+ }
+ // Scientific notation (e.g. 1e2) is not yet widely supported by browser vendors.
+ return scope.numberToString(value) + units[i];
+ }).join(' + ');
+ return values.length > 1 ? 'calc(' + result + ')' : result;
+ }];
+ }
+
+ var lengthUnits = 'px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc';
+ var parseLength = parseDimension.bind(null, new RegExp(lengthUnits, 'g'));
+ var parseLengthOrPercent = parseDimension.bind(null, new RegExp(lengthUnits + '|%', 'g'));
+ var parseAngle = parseDimension.bind(null, /deg|rad|grad|turn/g);
+
+ scope.parseLength = parseLength;
+ scope.parseLengthOrPercent = parseLengthOrPercent;
+ scope.consumeLengthOrPercent = scope.consumeParenthesised.bind(null, parseLengthOrPercent);
+ scope.parseAngle = parseAngle;
+ scope.mergeDimensions = mergeDimensions;
+
+ var consumeLength = scope.consumeParenthesised.bind(null, parseLength);
+ var consumeSizePair = scope.consumeRepeated.bind(undefined, consumeLength, /^/);
+ var consumeSizePairList = scope.consumeRepeated.bind(undefined, consumeSizePair, /^,/);
+ scope.consumeSizePairList = consumeSizePairList;
+
+ var parseSizePairList = function(input) {
+ var result = consumeSizePairList(input);
+ if (result && result[1] == '') {
+ return result[0];
+ }
+ };
+
+ var mergeNonNegativeSizePair = scope.mergeNestedRepeated.bind(undefined, mergeDimensionsNonNegative, ' ');
+ var mergeNonNegativeSizePairList = scope.mergeNestedRepeated.bind(undefined, mergeNonNegativeSizePair, ',');
+ scope.mergeNonNegativeSizePair = mergeNonNegativeSizePair;
+
+ scope.addPropertiesHandler(parseSizePairList, mergeNonNegativeSizePairList, [
+ 'background-size'
+ ]);
+
+ scope.addPropertiesHandler(parseLengthOrPercent, mergeDimensionsNonNegative, [
+ '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',
+ ]);
+
+ scope.addPropertiesHandler(parseLengthOrPercent, mergeDimensions, [
+ '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',
+ 'stroke-dashoffset',
+ 'text-indent',
+ 'top',
+ 'vertical-align',
+ 'word-spacing',
+ ]);
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/effect-callback.js b/catapult/third_party/polymer/components/web-animations-js/src/effect-callback.js
new file mode 100644
index 00000000..3051a593
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/effect-callback.js
@@ -0,0 +1,98 @@
+// 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(shared, scope, testing) {
+
+ var nullTarget = document.createElementNS('http://www.w3.org/1999/xhtml', 'div');
+
+ var sequenceNumber = 0;
+ scope.bindAnimationForCustomEffect = function(animation) {
+ var target = animation.effect.target;
+ var effectFunction;
+ var isKeyframeEffect = typeof animation.effect.getFrames() == 'function';
+ if (isKeyframeEffect) {
+ effectFunction = animation.effect.getFrames();
+ } else {
+ effectFunction = animation.effect._onsample;
+ }
+ var timing = animation.effect.timing;
+ var last = null;
+ timing = shared.normalizeTimingInput(timing);
+ var callback = function() {
+ var t = callback._animation ? callback._animation.currentTime : null;
+ if (t !== null) {
+ t = shared.calculateIterationProgress(shared.calculateActiveDuration(timing), t, timing);
+ if (isNaN(t))
+ t = null;
+ }
+ // FIXME: There are actually more conditions under which the effectFunction
+ // should be called.
+ if (t !== last) {
+ if (isKeyframeEffect) {
+ effectFunction(t, target, animation.effect);
+ } else {
+ effectFunction(t, animation.effect, animation.effect._animation);
+ }
+ }
+ last = t;
+ };
+
+ callback._animation = animation;
+ callback._registered = false;
+ callback._sequenceNumber = sequenceNumber++;
+ animation._callback = callback;
+ register(callback);
+ };
+
+ var callbacks = [];
+ var ticking = false;
+ function register(callback) {
+ if (callback._registered)
+ return;
+ callback._registered = true;
+ callbacks.push(callback);
+ if (!ticking) {
+ ticking = true;
+ requestAnimationFrame(tick);
+ }
+ }
+
+ function tick(t) {
+ var updating = callbacks;
+ callbacks = [];
+ updating.sort(function(left, right) {
+ return left._sequenceNumber - right._sequenceNumber;
+ });
+ updating = updating.filter(function(callback) {
+ callback();
+ var playState = callback._animation ? callback._animation.playState : 'idle';
+ if (playState != 'running' && playState != 'pending')
+ callback._registered = false;
+ return callback._registered;
+ });
+ callbacks.push.apply(callbacks, updating);
+
+ if (callbacks.length) {
+ ticking = true;
+ requestAnimationFrame(tick);
+ } else {
+ ticking = false;
+ }
+ }
+
+ scope.Animation.prototype._register = function() {
+ if (this._callback)
+ register(this._callback);
+ };
+
+})(webAnimationsShared, webAnimationsNext, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/element-animatable.js b/catapult/third_party/polymer/components/web-animations-js/src/element-animatable.js
new file mode 100644
index 00000000..765edf06
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/element-animatable.js
@@ -0,0 +1,23 @@
+// 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(scope) {
+ window.Element.prototype.animate = function(effectInput, options) {
+ var id = '';
+ if (options && options.id) {
+ id = options.id;
+ }
+ return scope.timeline._play(scope.KeyframeEffect(this, effectInput, options, id));
+ };
+})(webAnimations1);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/font-weight-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/font-weight-handler.js
new file mode 100644
index 00000000..4760486a
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/font-weight-handler.js
@@ -0,0 +1,42 @@
+// 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(scope) {
+ function parse(string) {
+ var out = Number(string);
+ if (isNaN(out) || out < 100 || out > 900 || out % 100 !== 0) {
+ return;
+ }
+ return out;
+ }
+
+ function toCss(value) {
+ value = Math.round(value / 100) * 100;
+ value = scope.clamp(100, 900, value);
+ if (value === 400) {
+ return 'normal';
+ }
+ if (value === 700) {
+ return 'bold';
+ }
+ return String(value);
+ }
+
+ function merge(left, right) {
+ return [left, right, toCss];
+ }
+
+ scope.addPropertiesHandler(parse, merge, ['font-weight']);
+
+})(webAnimations1);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/group-constructors.js b/catapult/third_party/polymer/components/web-animations-js/src/group-constructors.js
new file mode 100644
index 00000000..e5c0a102
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/group-constructors.js
@@ -0,0 +1,204 @@
+// 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(shared, scope, testing) {
+
+ function groupChildDuration(node) {
+ return node._timing.delay + node.activeDuration + node._timing.endDelay;
+ }
+
+ function constructor(children, timingInput, id) {
+ this._id = id;
+ this._parent = null;
+ this.children = children || [];
+ this._reparent(this.children);
+ timingInput = shared.numericTimingToObject(timingInput);
+ this._timingInput = shared.cloneTimingInput(timingInput);
+ this._timing = shared.normalizeTimingInput(timingInput, true);
+ this.timing = shared.makeTiming(timingInput, true, this);
+ this.timing._effect = this;
+
+ if (this._timing.duration === 'auto') {
+ this._timing.duration = this.activeDuration;
+ }
+ }
+
+ window.SequenceEffect = function() {
+ constructor.apply(this, arguments);
+ };
+
+ window.GroupEffect = function() {
+ constructor.apply(this, arguments);
+ };
+
+ constructor.prototype = {
+ _isAncestor: function(effect) {
+ var a = this;
+ while (a !== null) {
+ if (a == effect)
+ return true;
+ a = a._parent;
+ }
+ return false;
+ },
+ _rebuild: function() {
+ // Re-calculate durations for ancestors with specified duration 'auto'.
+ var node = this;
+ while (node) {
+ if (node.timing.duration === 'auto') {
+ node._timing.duration = node.activeDuration;
+ }
+ node = node._parent;
+ }
+ if (this._animation) {
+ this._animation._rebuildUnderlyingAnimation();
+ }
+ },
+ _reparent: function(newChildren) {
+ scope.removeMulti(newChildren);
+ for (var i = 0; i < newChildren.length; i++) {
+ newChildren[i]._parent = this;
+ }
+ },
+ _putChild: function(args, isAppend) {
+ var message = isAppend ? 'Cannot append an ancestor or self' : 'Cannot prepend an ancestor or self';
+ for (var i = 0; i < args.length; i++) {
+ if (this._isAncestor(args[i])) {
+ throw {
+ type: DOMException.HIERARCHY_REQUEST_ERR,
+ name: 'HierarchyRequestError',
+ message: message
+ };
+ }
+ }
+ var oldParents = [];
+ for (var i = 0; i < args.length; i++) {
+ isAppend ? this.children.push(args[i]) : this.children.unshift(args[i]);
+ }
+ this._reparent(args);
+ this._rebuild();
+ },
+ append: function() {
+ this._putChild(arguments, true);
+ },
+ prepend: function() {
+ this._putChild(arguments, false);
+ },
+ get parent() {
+ return this._parent;
+ },
+ get firstChild() {
+ return this.children.length ? this.children[0] : null;
+ },
+ get lastChild() {
+ return this.children.length ? this.children[this.children.length - 1] : null;
+ },
+ clone: function() {
+ var clonedTiming = shared.cloneTimingInput(this._timingInput);
+ var clonedChildren = [];
+ for (var i = 0; i < this.children.length; i++) {
+ clonedChildren.push(this.children[i].clone());
+ }
+ return (this instanceof GroupEffect) ?
+ new GroupEffect(clonedChildren, clonedTiming) :
+ new SequenceEffect(clonedChildren, clonedTiming);
+ },
+ remove: function() {
+ scope.removeMulti([this]);
+ }
+ };
+
+ window.SequenceEffect.prototype = Object.create(constructor.prototype);
+ Object.defineProperty(
+ window.SequenceEffect.prototype,
+ 'activeDuration',
+ {
+ get: function() {
+ var total = 0;
+ this.children.forEach(function(child) {
+ total += groupChildDuration(child);
+ });
+ return Math.max(total, 0);
+ }
+ });
+
+ window.GroupEffect.prototype = Object.create(constructor.prototype);
+ Object.defineProperty(
+ window.GroupEffect.prototype,
+ 'activeDuration',
+ {
+ get: function() {
+ var max = 0;
+ this.children.forEach(function(child) {
+ max = Math.max(max, groupChildDuration(child));
+ });
+ return max;
+ }
+ });
+
+ scope.newUnderlyingAnimationForGroup = function(group) {
+ var underlyingAnimation;
+ var timing = null;
+ var ticker = function(tf) {
+ var animation = underlyingAnimation._wrapper;
+ if (!animation) {
+ return;
+ }
+ if (animation.playState == 'pending') {
+ return;
+ }
+ if (!animation.effect) {
+ return;
+ }
+ if (tf == null) {
+ animation._removeChildAnimations();
+ return;
+ }
+
+ // If the group has a negative playback rate and is not fill backwards/both, then it should go
+ // out of effect when it reaches the start of its active interval (tf == 0). If it is fill
+ // backwards/both then it should stay in effect. calculateIterationProgress will return 0 in the
+ // backwards-filling case, and null otherwise.
+ if (tf == 0 && animation.playbackRate < 0) {
+ if (!timing) {
+ timing = shared.normalizeTimingInput(animation.effect.timing);
+ }
+ tf = shared.calculateIterationProgress(shared.calculateActiveDuration(timing), -1, timing);
+ if (isNaN(tf) || tf == null) {
+ animation._forEachChild(function(child) {
+ child.currentTime = -1;
+ });
+ animation._removeChildAnimations();
+ return;
+ }
+ }
+ };
+
+ var underlyingEffect = new KeyframeEffect(null, [], group._timing, group._id);
+ underlyingEffect.onsample = ticker;
+ underlyingAnimation = scope.timeline._play(underlyingEffect);
+ return underlyingAnimation;
+ };
+
+ scope.bindAnimationForGroup = function(animation) {
+ animation._animation._wrapper = animation;
+ animation._isGroup = true;
+ scope.awaitStartTime(animation);
+ animation._constructChildAnimations();
+ animation._setExternalAnimation(animation);
+ };
+
+ scope.groupChildDuration = groupChildDuration;
+
+})(webAnimationsShared, webAnimationsNext, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/handler-utils.js b/catapult/third_party/polymer/components/web-animations-js/src/handler-utils.js
new file mode 100644
index 00000000..d9f05e17
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/handler-utils.js
@@ -0,0 +1,177 @@
+// 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(scope) {
+
+ // consume* functions return a 2 value array of [parsed-data, '' or not-yet consumed input]
+
+ // Regex should be anchored with /^
+ function consumeToken(regex, string) {
+ var result = regex.exec(string);
+ if (result) {
+ result = regex.ignoreCase ? result[0].toLowerCase() : result[0];
+ return [result, string.substr(result.length)];
+ }
+ }
+
+ function consumeTrimmed(consumer, string) {
+ string = string.replace(/^\s*/, '');
+ var result = consumer(string);
+ if (result) {
+ return [result[0], result[1].replace(/^\s*/, '')];
+ }
+ }
+
+ function consumeRepeated(consumer, separator, string) {
+ consumer = consumeTrimmed.bind(null, consumer);
+ var list = [];
+ while (true) {
+ var result = consumer(string);
+ if (!result) {
+ return [list, string];
+ }
+ list.push(result[0]);
+ string = result[1];
+ result = consumeToken(separator, string);
+ if (!result || result[1] == '') {
+ return [list, string];
+ }
+ string = result[1];
+ }
+ }
+
+ // Consumes a token or expression with balanced parentheses
+ function consumeParenthesised(parser, string) {
+ var nesting = 0;
+ for (var n = 0; n < string.length; n++) {
+ if (/\s|,/.test(string[n]) && nesting == 0) {
+ break;
+ } else if (string[n] == '(') {
+ nesting++;
+ } else if (string[n] == ')') {
+ nesting--;
+ if (nesting == 0)
+ n++;
+ if (nesting <= 0)
+ break;
+ }
+ }
+ var parsed = parser(string.substr(0, n));
+ return parsed == undefined ? undefined : [parsed, string.substr(n)];
+ }
+
+ function lcm(a, b) {
+ var c = a;
+ var d = b;
+ while (c && d)
+ c > d ? c %= d : d %= c;
+ c = (a * b) / (c + d);
+ return c;
+ }
+
+ function ignore(value) {
+ return function(input) {
+ var result = value(input);
+ if (result)
+ result[0] = undefined;
+ return result;
+ }
+ }
+
+ function optional(value, defaultValue) {
+ return function(input) {
+ var result = value(input);
+ if (result)
+ return result;
+ return [defaultValue, input];
+ }
+ }
+
+ function consumeList(list, input) {
+ var output = [];
+ for (var i = 0; i < list.length; i++) {
+ var result = scope.consumeTrimmed(list[i], input);
+ if (!result || result[0] == '')
+ return;
+ if (result[0] !== undefined)
+ output.push(result[0]);
+ input = result[1];
+ }
+ if (input == '') {
+ return output;
+ }
+ }
+
+ function mergeWrappedNestedRepeated(wrap, nestedMerge, separator, left, right) {
+ var matchingLeft = [];
+ var matchingRight = [];
+ var reconsititution = [];
+ var length = lcm(left.length, right.length);
+ for (var i = 0; i < length; i++) {
+ var thing = nestedMerge(left[i % left.length], right[i % right.length]);
+ if (!thing) {
+ return;
+ }
+ matchingLeft.push(thing[0]);
+ matchingRight.push(thing[1]);
+ reconsititution.push(thing[2]);
+ }
+ return [matchingLeft, matchingRight, function(positions) {
+ var result = positions.map(function(position, i) {
+ return reconsititution[i](position);
+ }).join(separator);
+ return wrap ? wrap(result) : result;
+ }];
+ }
+
+ function mergeList(left, right, list) {
+ var lefts = [];
+ var rights = [];
+ var functions = [];
+ var j = 0;
+ for (var i = 0; i < list.length; i++) {
+ if (typeof list[i] == 'function') {
+ var result = list[i](left[j], right[j++]);
+ lefts.push(result[0]);
+ rights.push(result[1]);
+ functions.push(result[2]);
+ } else {
+ (function(pos) {
+ lefts.push(false);
+ rights.push(false);
+ functions.push(function() { return list[pos]; });
+ })(i);
+ }
+ }
+ return [lefts, rights, function(results) {
+ var result = '';
+ for (var i = 0; i < results.length; i++) {
+ result += functions[i](results[i]);
+ }
+ return result;
+ }];
+ }
+
+ scope.consumeToken = consumeToken;
+ scope.consumeTrimmed = consumeTrimmed;
+ scope.consumeRepeated = consumeRepeated;
+ scope.consumeParenthesised = consumeParenthesised;
+ scope.ignore = ignore;
+ scope.optional = optional;
+ scope.consumeList = consumeList;
+ scope.mergeNestedRepeated = mergeWrappedNestedRepeated.bind(null, null);
+ scope.mergeWrappedNestedRepeated = mergeWrappedNestedRepeated;
+ scope.mergeList = mergeList;
+
+})(webAnimations1);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/interpolation.js b/catapult/third_party/polymer/components/web-animations-js/src/interpolation.js
new file mode 100644
index 00000000..ba63ed35
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/interpolation.js
@@ -0,0 +1,49 @@
+// 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(scope, testing) {
+
+ function interpolate(from, to, f) {
+ if ((typeof from == 'number') && (typeof to == 'number')) {
+ return from * (1 - f) + to * f;
+ }
+ if ((typeof from == 'boolean') && (typeof to == 'boolean')) {
+ return f < 0.5 ? from : to;
+ }
+
+ WEB_ANIMATIONS_TESTING && console.assert(
+ Array.isArray(from) && Array.isArray(to),
+ 'If interpolation arguments are not numbers or bools they must be arrays');
+
+ if (from.length == to.length) {
+ var r = [];
+ for (var i = 0; i < from.length; i++) {
+ r.push(interpolate(from[i], to[i], f));
+ }
+ return r;
+ }
+ throw 'Mismatched interpolation arguments ' + from + ':' + to;
+ }
+
+ scope.Interpolation = function(from, to, convertToString) {
+ return function(f) {
+ return convertToString(interpolate(from, to, f));
+ }
+ };
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.interpolate = interpolate;
+ }
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect-constructor.js b/catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect-constructor.js
new file mode 100644
index 00000000..3d0f1bd6
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect-constructor.js
@@ -0,0 +1,183 @@
+// 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(shared, scope, testing) {
+
+ var disassociate = function(effect) {
+ effect._animation = undefined;
+ if (effect instanceof window.SequenceEffect || effect instanceof window.GroupEffect) {
+ for (var i = 0; i < effect.children.length; i++) {
+ disassociate(effect.children[i]);
+ }
+ }
+ };
+
+ scope.removeMulti = function(effects) {
+ var oldParents = [];
+ for (var i = 0; i < effects.length; i++) {
+ var effect = effects[i];
+ if (effect._parent) {
+ if (oldParents.indexOf(effect._parent) == -1) {
+ oldParents.push(effect._parent);
+ }
+ effect._parent.children.splice(effect._parent.children.indexOf(effect), 1);
+ effect._parent = null;
+ disassociate(effect);
+ } else if (effect._animation && (effect._animation.effect == effect)) {
+ effect._animation.cancel();
+ effect._animation.effect = new KeyframeEffect(null, []);
+ if (effect._animation._callback) {
+ effect._animation._callback._animation = null;
+ }
+ effect._animation._rebuildUnderlyingAnimation();
+ disassociate(effect);
+ }
+ }
+ for (i = 0; i < oldParents.length; i++) {
+ oldParents[i]._rebuild();
+ }
+ };
+
+ function KeyframeList(effectInput) {
+ this._frames = shared.normalizeKeyframes(effectInput);
+ }
+
+ scope.KeyframeEffect = function(target, effectInput, timingInput, id) {
+ this.target = target;
+ this._parent = null;
+
+ timingInput = shared.numericTimingToObject(timingInput);
+ this._timingInput = shared.cloneTimingInput(timingInput);
+ this._timing = shared.normalizeTimingInput(timingInput);
+
+ this.timing = shared.makeTiming(timingInput, false, this);
+ this.timing._effect = this;
+ if (typeof effectInput == 'function') {
+ shared.deprecated('Custom KeyframeEffect', '2015-06-22', 'Use KeyframeEffect.onsample instead.');
+ this._normalizedKeyframes = effectInput;
+ } else {
+ this._normalizedKeyframes = new KeyframeList(effectInput);
+ }
+ this._keyframes = effectInput;
+ this.activeDuration = shared.calculateActiveDuration(this._timing);
+ this._id = id;
+ return this;
+ };
+
+ scope.KeyframeEffect.prototype = {
+ getFrames: function() {
+ if (typeof this._normalizedKeyframes == 'function')
+ return this._normalizedKeyframes;
+ return this._normalizedKeyframes._frames;
+ },
+ set onsample(callback) {
+ if (typeof this.getFrames() == 'function') {
+ throw new Error('Setting onsample on custom effect KeyframeEffect is not supported.');
+ }
+ this._onsample = callback;
+ if (this._animation) {
+ this._animation._rebuildUnderlyingAnimation();
+ }
+ },
+ get parent() {
+ return this._parent;
+ },
+ clone: function() {
+ if (typeof this.getFrames() == 'function') {
+ throw new Error('Cloning custom effects is not supported.');
+ }
+ var clone = new KeyframeEffect(this.target, [], shared.cloneTimingInput(this._timingInput), this._id);
+ clone._normalizedKeyframes = this._normalizedKeyframes;
+ clone._keyframes = this._keyframes;
+ return clone;
+ },
+ remove: function() {
+ scope.removeMulti([this]);
+ }
+ };
+
+ var originalElementAnimate = Element.prototype.animate;
+ Element.prototype.animate = function(effectInput, options) {
+ var id = '';
+ if (options && options.id) {
+ id = options.id;
+ }
+ return scope.timeline._play(new scope.KeyframeEffect(this, effectInput, options, id));
+ };
+
+ var nullTarget = document.createElementNS('http://www.w3.org/1999/xhtml', 'div');
+ scope.newUnderlyingAnimationForKeyframeEffect = function(keyframeEffect) {
+ if (keyframeEffect) {
+ var target = keyframeEffect.target || nullTarget;
+ var keyframes = keyframeEffect._keyframes;
+ if (typeof keyframes == 'function') {
+ keyframes = [];
+ }
+ var options = keyframeEffect._timingInput;
+ options.id = keyframeEffect._id;
+ } else {
+ var target = nullTarget;
+ var keyframes = [];
+ var options = 0;
+ }
+ return originalElementAnimate.apply(target, [keyframes, options]);
+ };
+
+ // TODO: Remove this once we remove support for custom KeyframeEffects.
+ scope.bindAnimationForKeyframeEffect = function(animation) {
+ if (animation.effect && typeof animation.effect._normalizedKeyframes == 'function') {
+ scope.bindAnimationForCustomEffect(animation);
+ }
+ };
+
+ var pendingGroups = [];
+ scope.awaitStartTime = function(groupAnimation) {
+ if (groupAnimation.startTime !== null || !groupAnimation._isGroup)
+ return;
+ if (pendingGroups.length == 0) {
+ requestAnimationFrame(updatePendingGroups);
+ }
+ pendingGroups.push(groupAnimation);
+ };
+ function updatePendingGroups() {
+ var updated = false;
+ while (pendingGroups.length) {
+ var group = pendingGroups.shift();
+ group._updateChildren();
+ updated = true;
+ }
+ return updated;
+ }
+ var originalGetComputedStyle = window.getComputedStyle;
+ Object.defineProperty(window, 'getComputedStyle', {
+ configurable: true,
+ enumerable: true,
+ value: function() {
+ scope.timeline._updateAnimationsPromises();
+ var result = originalGetComputedStyle.apply(this, arguments);
+ if (updatePendingGroups())
+ result = originalGetComputedStyle.apply(this, arguments);
+ scope.timeline._updateAnimationsPromises();
+ return result;
+ },
+ });
+
+ window.KeyframeEffect = scope.KeyframeEffect;
+ window.Element.prototype.getAnimations = function() {
+ return document.timeline.getAnimations().filter(function(animation) {
+ return animation.effect !== null && animation.effect.target == this;
+ }.bind(this));
+ };
+
+}(webAnimationsShared, webAnimationsNext, webAnimationsTesting));
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect.js b/catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect.js
new file mode 100644
index 00000000..7775d585
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/keyframe-effect.js
@@ -0,0 +1,57 @@
+// 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(shared, scope, testing) {
+
+ function EffectTime(timing) {
+ var timeFraction = 0;
+ var activeDuration = shared.calculateActiveDuration(timing);
+ var effectTime = function(localTime) {
+ return shared.calculateIterationProgress(activeDuration, localTime, timing);
+ };
+ effectTime._totalDuration = timing.delay + activeDuration + timing.endDelay;
+ return effectTime;
+ }
+
+ scope.KeyframeEffect = function(target, effectInput, timingInput, id) {
+ var effectTime = EffectTime(shared.normalizeTimingInput(timingInput));
+ var interpolations = scope.convertEffectInput(effectInput);
+ var timeFraction;
+ var keyframeEffect = function() {
+ WEB_ANIMATIONS_TESTING && console.assert(typeof timeFraction !== 'undefined');
+ interpolations(target, timeFraction);
+ };
+ // Returns whether the keyframeEffect is in effect or not after the timing update.
+ keyframeEffect._update = function(localTime) {
+ timeFraction = effectTime(localTime);
+ return timeFraction !== null;
+ };
+ keyframeEffect._clear = function() {
+ interpolations(target, null);
+ };
+ keyframeEffect._hasSameTarget = function(otherTarget) {
+ return target === otherTarget;
+ };
+ keyframeEffect._target = target;
+ keyframeEffect._totalDuration = effectTime._totalDuration;
+ keyframeEffect._id = id;
+ return keyframeEffect;
+ };
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.webAnimations1KeyframeEffect = scope.KeyframeEffect;
+ testing.effectTime = EffectTime;
+ }
+
+})(webAnimationsShared, webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/keyframe-interpolations.js b/catapult/third_party/polymer/components/web-animations-js/src/keyframe-interpolations.js
new file mode 100644
index 00000000..cab801ed
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/keyframe-interpolations.js
@@ -0,0 +1,123 @@
+// 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(shared, scope, testing) {
+
+ scope.convertEffectInput = function(effectInput) {
+ var keyframes = shared.normalizeKeyframes(effectInput);
+ var propertySpecificKeyframeGroups = makePropertySpecificKeyframeGroups(keyframes);
+ var interpolations = makeInterpolations(propertySpecificKeyframeGroups);
+ return function(target, fraction) {
+ if (fraction != null) {
+ interpolations.filter(function(interpolation) {
+ return fraction >= interpolation.applyFrom && fraction < interpolation.applyTo;
+ }).forEach(function(interpolation) {
+ var offsetFraction = fraction - interpolation.startOffset;
+ var localDuration = interpolation.endOffset - interpolation.startOffset;
+ var scaledLocalTime = localDuration == 0 ? 0 : interpolation.easingFunction(offsetFraction / localDuration);
+ scope.apply(target, interpolation.property, interpolation.interpolation(scaledLocalTime));
+ });
+ } else {
+ for (var property in propertySpecificKeyframeGroups)
+ if (property != 'offset' && property != 'easing' && property != 'composite')
+ scope.clear(target, property);
+ }
+ };
+ };
+
+
+ function makePropertySpecificKeyframeGroups(keyframes) {
+ var propertySpecificKeyframeGroups = {};
+
+ for (var i = 0; i < keyframes.length; i++) {
+ for (var member in keyframes[i]) {
+ if (member != 'offset' && member != 'easing' && member != 'composite') {
+ var propertySpecificKeyframe = {
+ offset: keyframes[i].offset,
+ easing: keyframes[i].easing,
+ value: keyframes[i][member]
+ };
+ propertySpecificKeyframeGroups[member] = propertySpecificKeyframeGroups[member] || [];
+ propertySpecificKeyframeGroups[member].push(propertySpecificKeyframe);
+ }
+ }
+ }
+
+ for (var groupName in propertySpecificKeyframeGroups) {
+ var group = propertySpecificKeyframeGroups[groupName];
+ if (group[0].offset != 0 || group[group.length - 1].offset != 1) {
+ throw {
+ type: DOMException.NOT_SUPPORTED_ERR,
+ name: 'NotSupportedError',
+ message: 'Partial keyframes are not supported'
+ };
+ }
+ }
+ return propertySpecificKeyframeGroups;
+ }
+
+
+ function makeInterpolations(propertySpecificKeyframeGroups) {
+ var interpolations = [];
+ for (var groupName in propertySpecificKeyframeGroups) {
+ var keyframes = propertySpecificKeyframeGroups[groupName];
+ for (var i = 0; i < keyframes.length - 1; i++) {
+ var startIndex = i;
+ var endIndex = i + 1;
+ var startOffset = keyframes[startIndex].offset;
+ var endOffset = keyframes[endIndex].offset;
+ var applyFrom = startOffset;
+ var applyTo = endOffset;
+
+ if (i == 0) {
+ applyFrom = -Infinity;
+ WEB_ANIMATIONS_TESTING && console.assert(startOffset == 0);
+ if (endOffset == 0) {
+ endIndex = startIndex;
+ }
+ }
+ if (i == keyframes.length - 2) {
+ applyTo = Infinity;
+ WEB_ANIMATIONS_TESTING && console.assert(endOffset == 1);
+ if (startOffset == 1) {
+ startIndex = endIndex;
+ }
+ }
+
+ interpolations.push({
+ applyFrom: applyFrom,
+ applyTo: applyTo,
+ startOffset: keyframes[startIndex].offset,
+ endOffset: keyframes[endIndex].offset,
+ easingFunction: shared.parseEasingFunction(keyframes[startIndex].easing),
+ property: groupName,
+ interpolation: scope.propertyInterpolation(groupName,
+ keyframes[startIndex].value,
+ keyframes[endIndex].value)
+ });
+ }
+ }
+ interpolations.sort(function(leftInterpolation, rightInterpolation) {
+ return leftInterpolation.startOffset - rightInterpolation.startOffset;
+ });
+ return interpolations;
+ }
+
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.makePropertySpecificKeyframeGroups = makePropertySpecificKeyframeGroups;
+ testing.makeInterpolations = makeInterpolations;
+ }
+
+})(webAnimationsShared, webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/matrix-decomposition.js b/catapult/third_party/polymer/components/web-animations-js/src/matrix-decomposition.js
new file mode 100644
index 00000000..aa9cfe76
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/matrix-decomposition.js
@@ -0,0 +1,440 @@
+// 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(scope, testing) {
+ var decomposeMatrix = (function() {
+ function determinant(m) {
+ return m[0][0] * m[1][1] * m[2][2] +
+ m[1][0] * m[2][1] * m[0][2] +
+ m[2][0] * m[0][1] * m[1][2] -
+ m[0][2] * m[1][1] * m[2][0] -
+ m[1][2] * m[2][1] * m[0][0] -
+ m[2][2] * m[0][1] * m[1][0];
+ }
+
+ // from Wikipedia:
+ //
+ // [A B]^-1 = [A^-1 + A^-1B(D - CA^-1B)^-1CA^-1 -A^-1B(D - CA^-1B)^-1]
+ // [C D] [-(D - CA^-1B)^-1CA^-1 (D - CA^-1B)^-1 ]
+ //
+ // Therefore
+ //
+ // [A [0]]^-1 = [A^-1 [0]]
+ // [C 1 ] [ -CA^-1 1 ]
+ function inverse(m) {
+ var iDet = 1 / determinant(m);
+ var a = m[0][0], b = m[0][1], c = m[0][2];
+ var d = m[1][0], e = m[1][1], f = m[1][2];
+ var g = m[2][0], h = m[2][1], k = m[2][2];
+ var Ainv = [
+ [(e * k - f * h) * iDet, (c * h - b * k) * iDet,
+ (b * f - c * e) * iDet, 0],
+ [(f * g - d * k) * iDet, (a * k - c * g) * iDet,
+ (c * d - a * f) * iDet, 0],
+ [(d * h - e * g) * iDet, (g * b - a * h) * iDet,
+ (a * e - b * d) * iDet, 0]
+ ];
+ var lastRow = [];
+ for (var i = 0; i < 3; i++) {
+ var val = 0;
+ for (var j = 0; j < 3; j++) {
+ val += m[3][j] * Ainv[j][i];
+ }
+ lastRow.push(val);
+ }
+ lastRow.push(1);
+ Ainv.push(lastRow);
+ return Ainv;
+ }
+
+ function transposeMatrix4(m) {
+ return [[m[0][0], m[1][0], m[2][0], m[3][0]],
+ [m[0][1], m[1][1], m[2][1], m[3][1]],
+ [m[0][2], m[1][2], m[2][2], m[3][2]],
+ [m[0][3], m[1][3], m[2][3], m[3][3]]];
+ }
+
+ function multVecMatrix(v, m) {
+ var result = [];
+ for (var i = 0; i < 4; i++) {
+ var val = 0;
+ for (var j = 0; j < 4; j++) {
+ val += v[j] * m[j][i];
+ }
+ result.push(val);
+ }
+ return result;
+ }
+
+ function normalize(v) {
+ var len = length(v);
+ return [v[0] / len, v[1] / len, v[2] / len];
+ }
+
+ function length(v) {
+ return Math.sqrt(v[0] * v[0] + v[1] * v[1] + v[2] * v[2]);
+ }
+
+ function combine(v1, v2, v1s, v2s) {
+ return [v1s * v1[0] + v2s * v2[0], v1s * v1[1] + v2s * v2[1],
+ v1s * v1[2] + v2s * v2[2]];
+ }
+
+ function cross(v1, v2) {
+ return [v1[1] * v2[2] - v1[2] * v2[1],
+ v1[2] * v2[0] - v1[0] * v2[2],
+ v1[0] * v2[1] - v1[1] * v2[0]];
+ }
+
+ function decomposeMatrix(matrix) {
+ var m3d = [
+ matrix.slice(0, 4),
+ matrix.slice(4, 8),
+ matrix.slice(8, 12),
+ matrix.slice(12, 16)
+ ];
+
+ // skip normalization step as m3d[3][3] should always be 1
+ if (m3d[3][3] !== 1) {
+ return null;
+ }
+
+ var perspectiveMatrix = [];
+ for (var i = 0; i < 4; i++) {
+ perspectiveMatrix.push(m3d[i].slice());
+ }
+
+ for (var i = 0; i < 3; i++) {
+ perspectiveMatrix[i][3] = 0;
+ }
+
+ if (determinant(perspectiveMatrix) === 0) {
+ return null;
+ }
+
+ var rhs = [];
+
+ var perspective;
+ if (m3d[0][3] || m3d[1][3] || m3d[2][3]) {
+ rhs.push(m3d[0][3]);
+ rhs.push(m3d[1][3]);
+ rhs.push(m3d[2][3]);
+ rhs.push(m3d[3][3]);
+
+ var inversePerspectiveMatrix = inverse(perspectiveMatrix);
+ var transposedInversePerspectiveMatrix =
+ transposeMatrix4(inversePerspectiveMatrix);
+ perspective = multVecMatrix(rhs, transposedInversePerspectiveMatrix);
+ } else {
+ perspective = [0, 0, 0, 1];
+ }
+
+ var translate = m3d[3].slice(0, 3);
+
+ var row = [];
+ row.push(m3d[0].slice(0, 3));
+ var scale = [];
+ scale.push(length(row[0]));
+ row[0] = normalize(row[0]);
+
+ var skew = [];
+ row.push(m3d[1].slice(0, 3));
+ skew.push(dot(row[0], row[1]));
+ row[1] = combine(row[1], row[0], 1.0, -skew[0]);
+
+ scale.push(length(row[1]));
+ row[1] = normalize(row[1]);
+ skew[0] /= scale[1];
+
+ row.push(m3d[2].slice(0, 3));
+ skew.push(dot(row[0], row[2]));
+ row[2] = combine(row[2], row[0], 1.0, -skew[1]);
+ skew.push(dot(row[1], row[2]));
+ row[2] = combine(row[2], row[1], 1.0, -skew[2]);
+
+ scale.push(length(row[2]));
+ row[2] = normalize(row[2]);
+ skew[1] /= scale[2];
+ skew[2] /= scale[2];
+
+ var pdum3 = cross(row[1], row[2]);
+ if (dot(row[0], pdum3) < 0) {
+ for (var i = 0; i < 3; i++) {
+ scale[i] *= -1;
+ row[i][0] *= -1;
+ row[i][1] *= -1;
+ row[i][2] *= -1;
+ }
+ }
+
+ var t = row[0][0] + row[1][1] + row[2][2] + 1;
+ var s;
+ var quaternion;
+
+ if (t > 1e-4) {
+ s = 0.5 / Math.sqrt(t);
+ quaternion = [
+ (row[2][1] - row[1][2]) * s,
+ (row[0][2] - row[2][0]) * s,
+ (row[1][0] - row[0][1]) * s,
+ 0.25 / s
+ ];
+ } else if (row[0][0] > row[1][1] && row[0][0] > row[2][2]) {
+ s = Math.sqrt(1 + row[0][0] - row[1][1] - row[2][2]) * 2.0;
+ quaternion = [
+ 0.25 * s,
+ (row[0][1] + row[1][0]) / s,
+ (row[0][2] + row[2][0]) / s,
+ (row[2][1] - row[1][2]) / s
+ ];
+ } else if (row[1][1] > row[2][2]) {
+ s = Math.sqrt(1.0 + row[1][1] - row[0][0] - row[2][2]) * 2.0;
+ quaternion = [
+ (row[0][1] + row[1][0]) / s,
+ 0.25 * s,
+ (row[1][2] + row[2][1]) / s,
+ (row[0][2] - row[2][0]) / s
+ ];
+ } else {
+ s = Math.sqrt(1.0 + row[2][2] - row[0][0] - row[1][1]) * 2.0;
+ quaternion = [
+ (row[0][2] + row[2][0]) / s,
+ (row[1][2] + row[2][1]) / s,
+ 0.25 * s,
+ (row[1][0] - row[0][1]) / s
+ ];
+ }
+
+ return [translate, scale, skew, quaternion, perspective];
+ }
+ return decomposeMatrix;
+ })();
+
+ function dot(v1, v2) {
+ var result = 0;
+ for (var i = 0; i < v1.length; i++) {
+ result += v1[i] * v2[i];
+ }
+ return result;
+ }
+
+ function multiplyMatrices(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 toRadians(arg) {
+ var rads = arg.rad || 0;
+ var degs = arg.deg || 0;
+ var grads = arg.grad || 0;
+ var turns = arg.turn || 0;
+ var angle = (degs / 360 + grads / 400 + turns) * (2 * Math.PI) + rads;
+ return angle;
+ }
+
+ function convertItemToMatrix(item) {
+ switch (item.t) {
+ case 'rotatex':
+ var angle = toRadians(item.d[0]);
+ return [1, 0, 0, 0,
+ 0, Math.cos(angle), Math.sin(angle), 0,
+ 0, -Math.sin(angle), Math.cos(angle), 0,
+ 0, 0, 0, 1];
+ case 'rotatey':
+ var angle = toRadians(item.d[0]);
+ return [Math.cos(angle), 0, -Math.sin(angle), 0,
+ 0, 1, 0, 0,
+ Math.sin(angle), 0, Math.cos(angle), 0,
+ 0, 0, 0, 1];
+ case 'rotate':
+ case 'rotatez':
+ var angle = toRadians(item.d[0]);
+ return [Math.cos(angle), Math.sin(angle), 0, 0,
+ -Math.sin(angle), Math.cos(angle), 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, 0, 1];
+ case 'rotate3d':
+ var x = item.d[0];
+ var y = item.d[1];
+ var z = item.d[2];
+ var angle = toRadians(item.d[3]);
+
+ var sqrLength = x * x + y * y + z * z;
+ if (sqrLength === 0) {
+ x = 1;
+ y = 0;
+ z = 0;
+ } else if (sqrLength !== 1) {
+ var length = Math.sqrt(sqrLength);
+ x /= length;
+ y /= length;
+ z /= length;
+ }
+
+ var s = Math.sin(angle / 2);
+ var sc = s * Math.cos(angle / 2);
+ var sq = s * s;
+ return [
+ 1 - 2 * (y * y + z * z) * sq,
+ 2 * (x * y * sq + z * sc),
+ 2 * (x * z * sq - y * sc),
+ 0,
+
+ 2 * (x * y * sq - z * sc),
+ 1 - 2 * (x * x + z * z) * sq,
+ 2 * (y * z * sq + x * sc),
+ 0,
+
+ 2 * (x * z * sq + y * sc),
+ 2 * (y * z * sq - x * sc),
+ 1 - 2 * (x * x + y * y) * sq,
+ 0,
+
+ 0, 0, 0, 1
+ ];
+ case 'scale':
+ return [item.d[0], 0, 0, 0,
+ 0, item.d[1], 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, 0, 1];
+ case 'scalex':
+ return [item.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, item.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, item.d[0], 0,
+ 0, 0, 0, 1];
+ case 'scale3d':
+ return [item.d[0], 0, 0, 0,
+ 0, item.d[1], 0, 0,
+ 0, 0, item.d[2], 0,
+ 0, 0, 0, 1];
+ case 'skew':
+ var xAngle = toRadians(item.d[0]);
+ var yAngle = toRadians(item.d[1]);
+ return [1, Math.tan(yAngle), 0, 0,
+ Math.tan(xAngle), 1, 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, 0, 1];
+ case 'skewx':
+ var angle = toRadians(item.d[0]);
+ return [1, 0, 0, 0,
+ Math.tan(angle), 1, 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, 0, 1];
+ case 'skewy':
+ var angle = toRadians(item.d[0]);
+ return [1, Math.tan(angle), 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, 0, 1];
+ case 'translate':
+ var x = item.d[0].px || 0;
+ var y = item.d[1].px || 0;
+ return [1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ x, y, 0, 1];
+ case 'translatex':
+ var x = item.d[0].px || 0;
+ return [1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ x, 0, 0, 1];
+ case 'translatey':
+ var y = item.d[0].px || 0;
+ return [1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ 0, y, 0, 1];
+ case 'translatez':
+ var z = item.d[0].px || 0;
+ return [1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, z, 1];
+ case 'translate3d':
+ var x = item.d[0].px || 0;
+ var y = item.d[1].px || 0;
+ var z = item.d[2].px || 0;
+ return [1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ x, y, z, 1];
+ case 'perspective':
+ var p = item.d[0].px ? (-1 / item.d[0].px) : 0;
+ return [
+ 1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, p,
+ 0, 0, 0, 1];
+ case 'matrix':
+ return [item.d[0], item.d[1], 0, 0,
+ item.d[2], item.d[3], 0, 0,
+ 0, 0, 1, 0,
+ item.d[4], item.d[5], 0, 1];
+ case 'matrix3d':
+ return item.d;
+ default:
+ WEB_ANIMATIONS_TESTING && console.assert(false, 'Transform item type ' + item.t +
+ ' conversion to matrix not yet implemented.');
+ }
+ }
+
+ function convertToMatrix(transformList) {
+ if (transformList.length === 0) {
+ return [1, 0, 0, 0,
+ 0, 1, 0, 0,
+ 0, 0, 1, 0,
+ 0, 0, 0, 1];
+ }
+ return transformList.map(convertItemToMatrix).reduce(multiplyMatrices);
+ }
+
+ function makeMatrixDecomposition(transformList) {
+ return [decomposeMatrix(convertToMatrix(transformList))];
+ }
+
+ scope.dot = dot;
+ scope.makeMatrixDecomposition = makeMatrixDecomposition;
+ scope.transformListToMatrix = convertToMatrix;
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/matrix-interpolation.js b/catapult/third_party/polymer/components/web-animations-js/src/matrix-interpolation.js
new file mode 100644
index 00000000..9a35de3b
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/matrix-interpolation.js
@@ -0,0 +1,130 @@
+// 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(scope, testing) {
+ var composeMatrix = (function() {
+ function multiply(a, b) {
+ var result = [[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]];
+ for (var i = 0; i < 4; i++) {
+ for (var j = 0; j < 4; j++) {
+ for (var k = 0; k < 4; k++) {
+ result[i][j] += b[i][k] * a[k][j];
+ }
+ }
+ }
+ return result;
+ }
+
+ function is2D(m) {
+ return (
+ m[0][2] == 0 &&
+ m[0][3] == 0 &&
+ m[1][2] == 0 &&
+ m[1][3] == 0 &&
+ m[2][0] == 0 &&
+ m[2][1] == 0 &&
+ m[2][2] == 1 &&
+ m[2][3] == 0 &&
+ m[3][2] == 0 &&
+ m[3][3] == 1);
+ }
+
+ function composeMatrix(translate, scale, skew, quat, perspective) {
+ var matrix = [[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]];
+
+ for (var i = 0; i < 4; i++) {
+ matrix[i][3] = perspective[i];
+ }
+
+ for (var i = 0; i < 3; i++) {
+ for (var j = 0; j < 3; j++) {
+ matrix[3][i] += translate[j] * matrix[j][i];
+ }
+ }
+
+ var x = quat[0], y = quat[1], z = quat[2], w = quat[3];
+
+ var rotMatrix = [[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]];
+
+ rotMatrix[0][0] = 1 - 2 * (y * y + z * z);
+ rotMatrix[0][1] = 2 * (x * y - z * w);
+ rotMatrix[0][2] = 2 * (x * z + y * w);
+ rotMatrix[1][0] = 2 * (x * y + z * w);
+ rotMatrix[1][1] = 1 - 2 * (x * x + z * z);
+ rotMatrix[1][2] = 2 * (y * z - x * w);
+ rotMatrix[2][0] = 2 * (x * z - y * w);
+ rotMatrix[2][1] = 2 * (y * z + x * w);
+ rotMatrix[2][2] = 1 - 2 * (x * x + y * y);
+
+ matrix = multiply(matrix, rotMatrix);
+
+ var temp = [[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]];
+ if (skew[2]) {
+ temp[2][1] = skew[2];
+ matrix = multiply(matrix, temp);
+ }
+
+ if (skew[1]) {
+ temp[2][1] = 0;
+ temp[2][0] = skew[0];
+ matrix = multiply(matrix, temp);
+ }
+
+ if (skew[0]) {
+ temp[2][0] = 0;
+ temp[1][0] = skew[0];
+ matrix = multiply(matrix, temp);
+ }
+
+ for (var i = 0; i < 3; i++) {
+ for (var j = 0; j < 3; j++) {
+ matrix[i][j] *= scale[i];
+ }
+ }
+
+ if (is2D(matrix)) {
+ return [matrix[0][0], matrix[0][1], matrix[1][0], matrix[1][1], matrix[3][0], matrix[3][1]];
+ }
+ return matrix[0].concat(matrix[1], matrix[2], matrix[3]);
+ }
+ return composeMatrix;
+ })();
+
+ function clamp(x, min, max) {
+ return Math.max(Math.min(x, max), min);
+ };
+
+ function quat(fromQ, toQ, f) {
+ var product = scope.dot(fromQ, toQ);
+ product = clamp(product, -1.0, 1.0);
+
+ var quat = [];
+ if (product === 1.0) {
+ quat = fromQ;
+ } else {
+ var theta = Math.acos(product);
+ var w = Math.sin(f * theta) * 1 / Math.sqrt(1 - product * product);
+
+ for (var i = 0; i < 4; i++) {
+ quat.push(fromQ[i] * (Math.cos(f * theta) - product * w) +
+ toQ[i] * w);
+ }
+ }
+ return quat;
+ }
+
+ scope.composeMatrix = composeMatrix;
+ scope.quat = quat;
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/normalize-keyframes.js b/catapult/third_party/polymer/components/web-animations-js/src/normalize-keyframes.js
new file mode 100644
index 00000000..1fd02548
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/normalize-keyframes.js
@@ -0,0 +1,321 @@
+// 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(shared, testing) {
+ var shorthandToLonghand = {
+ 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'
+ ]
+ };
+
+ var shorthandExpanderElem = document.createElementNS('http://www.w3.org/1999/xhtml', 'div');
+
+ var borderWidthAliases = {
+ thin: '1px',
+ medium: '3px',
+ thick: '5px'
+ };
+
+ var aliases = {
+ borderBottomWidth: borderWidthAliases,
+ borderLeftWidth: borderWidthAliases,
+ borderRightWidth: borderWidthAliases,
+ borderTopWidth: borderWidthAliases,
+ 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: borderWidthAliases,
+ textShadow: {
+ none: '0px 0px 0px transparent'
+ },
+ boxShadow: {
+ none: '0px 0px 0px 0px transparent'
+ }
+ };
+
+ function antiAlias(property, value) {
+ if (property in aliases) {
+ return aliases[property][value] || value;
+ }
+ return value;
+ }
+
+ function isNotAnimatable(property) {
+ // https://w3c.github.io/web-animations/#concept-not-animatable
+ return property === 'display' || property.lastIndexOf('animation', 0) === 0 || property.lastIndexOf('transition', 0) === 0;
+ }
+
+ // This delegates parsing shorthand value syntax to the browser.
+ function expandShorthandAndAntiAlias(property, value, result) {
+ if (isNotAnimatable(property)) {
+ return;
+ }
+ var longProperties = shorthandToLonghand[property];
+ if (longProperties) {
+ shorthandExpanderElem.style[property] = value;
+ for (var i in longProperties) {
+ var longProperty = longProperties[i];
+ var longhandValue = shorthandExpanderElem.style[longProperty];
+ result[longProperty] = antiAlias(longProperty, longhandValue);
+ }
+ } else {
+ result[property] = antiAlias(property, value);
+ }
+ };
+
+ function convertToArrayForm(effectInput) {
+ var normalizedEffectInput = [];
+
+ for (var property in effectInput) {
+ if (property in ['easing', 'offset', 'composite']) {
+ continue;
+ }
+
+ var values = effectInput[property];
+ if (!Array.isArray(values)) {
+ values = [values];
+ }
+
+ var keyframe;
+ var numKeyframes = values.length;
+ for (var i = 0; i < numKeyframes; i++) {
+ keyframe = {};
+
+ if ('offset' in effectInput) {
+ keyframe.offset = effectInput.offset;
+ } else if (numKeyframes == 1) {
+ keyframe.offset = 1.0;
+ } else {
+ keyframe.offset = i / (numKeyframes - 1.0);
+ }
+
+ if ('easing' in effectInput) {
+ keyframe.easing = effectInput.easing;
+ }
+
+ if ('composite' in effectInput) {
+ keyframe.composite = effectInput.composite;
+ }
+
+ keyframe[property] = values[i];
+
+ normalizedEffectInput.push(keyframe);
+ }
+ }
+
+ normalizedEffectInput.sort(function(a, b) { return a.offset - b.offset; });
+ return normalizedEffectInput;
+ };
+
+ function normalizeKeyframes(effectInput) {
+ if (effectInput == null) {
+ return [];
+ }
+
+ if (window.Symbol && Symbol.iterator && Array.prototype.from && effectInput[Symbol.iterator]) {
+ // Handle custom iterables in most browsers by converting to an array
+ effectInput = Array.from(effectInput);
+ }
+
+ if (!Array.isArray(effectInput)) {
+ effectInput = convertToArrayForm(effectInput);
+ }
+
+ var keyframes = effectInput.map(function(originalKeyframe) {
+ var keyframe = {};
+ for (var member in originalKeyframe) {
+ var memberValue = originalKeyframe[member];
+ if (member == 'offset') {
+ if (memberValue != null) {
+ memberValue = Number(memberValue);
+ if (!isFinite(memberValue))
+ throw new TypeError('Keyframe offsets must be numbers.');
+ if (memberValue < 0 || memberValue > 1)
+ throw new TypeError('Keyframe offsets must be between 0 and 1.');
+ }
+ } else if (member == 'composite') {
+ if (memberValue == 'add' || memberValue == 'accumulate') {
+ throw {
+ type: DOMException.NOT_SUPPORTED_ERR,
+ name: 'NotSupportedError',
+ message: 'add compositing is not supported'
+ };
+ } else if (memberValue != 'replace') {
+ throw new TypeError('Invalid composite mode ' + memberValue + '.');
+ }
+ } else if (member == 'easing') {
+ memberValue = shared.normalizeEasing(memberValue);
+ } else {
+ memberValue = '' + memberValue;
+ }
+ expandShorthandAndAntiAlias(member, memberValue, keyframe);
+ }
+ if (keyframe.offset == undefined)
+ keyframe.offset = null;
+ if (keyframe.easing == undefined)
+ keyframe.easing = 'linear';
+ return keyframe;
+ });
+
+ var everyFrameHasOffset = true;
+ var looselySortedByOffset = true;
+ var previousOffset = -Infinity;
+ for (var i = 0; i < keyframes.length; i++) {
+ var offset = keyframes[i].offset;
+ if (offset != null) {
+ if (offset < previousOffset) {
+ throw new TypeError('Keyframes are not loosely sorted by offset. Sort or specify offsets.');
+ }
+ previousOffset = offset;
+ } else {
+ everyFrameHasOffset = false;
+ }
+ }
+
+ keyframes = keyframes.filter(function(keyframe) {
+ return keyframe.offset >= 0 && keyframe.offset <= 1;
+ });
+
+ function spaceKeyframes() {
+ var length = keyframes.length;
+ if (keyframes[length - 1].offset == null)
+ keyframes[length - 1].offset = 1;
+ if (length > 1 && keyframes[0].offset == null)
+ keyframes[0].offset = 0;
+
+ var previousIndex = 0;
+ var previousOffset = keyframes[0].offset;
+ for (var i = 1; i < length; i++) {
+ var offset = keyframes[i].offset;
+ if (offset != null) {
+ for (var j = 1; j < i - previousIndex; j++)
+ keyframes[previousIndex + j].offset = previousOffset + (offset - previousOffset) * j / (i - previousIndex);
+ previousIndex = i;
+ previousOffset = offset;
+ }
+ }
+ }
+ if (!everyFrameHasOffset)
+ spaceKeyframes();
+
+ return keyframes;
+ }
+
+ shared.convertToArrayForm = convertToArrayForm;
+ shared.normalizeKeyframes = normalizeKeyframes;
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.normalizeKeyframes = normalizeKeyframes;
+ }
+
+})(webAnimationsShared, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/number-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/number-handler.js
new file mode 100644
index 00000000..7d0e7f9b
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/number-handler.js
@@ -0,0 +1,97 @@
+// 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(scope, testing) {
+
+ function numberToString(x) {
+ return x.toFixed(3).replace(/0+$/, '').replace(/\.$/, '');
+ }
+
+ function clamp(min, max, x) {
+ return Math.min(max, Math.max(min, x));
+ }
+
+ function parseNumber(string) {
+ if (/^\s*[-+]?(\d*\.)?\d+\s*$/.test(string))
+ return Number(string);
+ }
+
+ function mergeNumbers(left, right) {
+ return [left, right, numberToString];
+ }
+
+ // FIXME: This should probably go in it's own handler.
+ function mergeFlex(left, right) {
+ if (left == 0)
+ return;
+ return clampedMergeNumbers(0, Infinity)(left, right);
+ }
+
+ function mergePositiveIntegers(left, right) {
+ return [left, right, function(x) {
+ return Math.round(clamp(1, Infinity, x));
+ }];
+ }
+
+ function clampedMergeNumbers(min, max) {
+ return function(left, right) {
+ return [left, right, function(x) {
+ return numberToString(clamp(min, max, x));
+ }];
+ };
+ }
+
+ function parseNumberList(string) {
+ var items = string.trim().split(/\s*[\s,]\s*/);
+ if (items.length === 0) {
+ return;
+ }
+ var result = [];
+ for (var i = 0; i < items.length; i++) {
+ var number = parseNumber(items[i]);
+ if (number === undefined) {
+ return;
+ }
+ result.push(number);
+ }
+ return result;
+ }
+
+ function mergeNumberLists(left, right) {
+ if (left.length != right.length) {
+ return;
+ }
+ return [left, right, function(numberList) {
+ return numberList.map(numberToString).join(' ');
+ }];
+ }
+
+ function round(left, right) {
+ return [left, right, Math.round];
+ }
+
+ scope.clamp = clamp;
+ scope.addPropertiesHandler(parseNumberList, mergeNumberLists, ['stroke-dasharray']);
+ scope.addPropertiesHandler(parseNumber, clampedMergeNumbers(0, Infinity), ['border-image-width', 'line-height']);
+ scope.addPropertiesHandler(parseNumber, clampedMergeNumbers(0, 1), ['opacity', 'shape-image-threshold']);
+ scope.addPropertiesHandler(parseNumber, mergeFlex, ['flex-grow', 'flex-shrink']);
+ scope.addPropertiesHandler(parseNumber, mergePositiveIntegers, ['orphans', 'widows']);
+ scope.addPropertiesHandler(parseNumber, round, ['z-index']);
+
+ scope.parseNumber = parseNumber;
+ scope.parseNumberList = parseNumberList;
+ scope.mergeNumbers = mergeNumbers;
+ scope.numberToString = numberToString;
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/position-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/position-handler.js
new file mode 100644
index 00000000..18cea438
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/position-handler.js
@@ -0,0 +1,117 @@
+// 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(scope) {
+
+ function negateDimension(dimension) {
+ var result = {};
+ for (var k in dimension) {
+ result[k] = -dimension[k];
+ }
+ return result;
+ }
+
+ function consumeOffset(string) {
+ return scope.consumeToken(/^(left|center|right|top|bottom)\b/i, string) || scope.consumeLengthOrPercent(string);
+ }
+
+ var offsetMap = {
+ left: {'%': 0},
+ center: {'%': 50},
+ right: {'%': 100},
+ top: {'%': 0},
+ bottom: {'%': 100},
+ };
+
+ function parseOrigin(slots, string) {
+ var result = scope.consumeRepeated(consumeOffset, /^/, string);
+ if (!result || result[1] != '') return;
+ var tokens = result[0];
+ tokens[0] = tokens[0] || 'center';
+ tokens[1] = tokens[1] || 'center';
+ if (slots == 3) {
+ tokens[2] = tokens[2] || {px: 0};
+ }
+ if (tokens.length != slots) {
+ return;
+ }
+ // Reorder so that the horizontal axis comes first.
+ if (/top|bottom/.test(tokens[0]) || /left|right/.test(tokens[1])) {
+ var tmp = tokens[0];
+ tokens[0] = tokens[1];
+ tokens[1] = tmp;
+ }
+ // Invalid if not horizontal then vertical.
+ if (!/left|right|center|Object/.test(tokens[0]))
+ return;
+ if (!/top|bottom|center|Object/.test(tokens[1]))
+ return;
+ return tokens.map(function(position) {
+ return typeof position == 'object' ? position : offsetMap[position];
+ });
+ }
+
+ var mergeOffsetList = scope.mergeNestedRepeated.bind(null, scope.mergeDimensions, ' ');
+ scope.addPropertiesHandler(parseOrigin.bind(null, 3), mergeOffsetList, ['transform-origin']);
+ scope.addPropertiesHandler(parseOrigin.bind(null, 2), mergeOffsetList, ['perspective-origin']);
+
+ function consumePosition(string) {
+ var result = scope.consumeRepeated(consumeOffset, /^/, string);
+ if (!result) {
+ return;
+ }
+
+ var tokens = result[0];
+ var out = [{'%': 50}, {'%': 50}];
+ var pos = 0;
+ var bottomOrRight = false;
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (typeof token == 'string') {
+ bottomOrRight = /bottom|right/.test(token);
+ pos = {left: 0, right: 0, center: pos, top: 1, bottom: 1}[token];
+ out[pos] = offsetMap[token];
+ if (token == 'center') {
+ // Center doesn't accept a length offset.
+ pos++;
+ }
+ } else {
+ if (bottomOrRight) {
+ // If bottom or right we need to subtract the length from 100%
+ token = negateDimension(token);
+ token['%'] = (token['%'] || 0) + 100;
+ }
+ out[pos] = token;
+ pos++;
+ bottomOrRight = false;
+ }
+ }
+ return [out, result[1]];
+ }
+
+ function parsePositionList(string) {
+ var result = scope.consumeRepeated(consumePosition, /^,/, string);
+ if (result && result[1] == '') {
+ return result[0];
+ }
+ }
+
+ scope.consumePosition = consumePosition;
+ scope.mergeOffsetList = mergeOffsetList;
+
+ var mergePositionList = scope.mergeNestedRepeated.bind(null, mergeOffsetList, ', ');
+ scope.addPropertiesHandler(parsePositionList, mergePositionList, ['background-position', 'object-position']);
+
+})(webAnimations1);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/property-interpolation.js b/catapult/third_party/polymer/components/web-animations-js/src/property-interpolation.js
new file mode 100644
index 00000000..b7e594f3
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/property-interpolation.js
@@ -0,0 +1,127 @@
+// 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(shared, scope, testing) {
+
+ var propertyHandlers = {};
+
+ function toCamelCase(property) {
+ return property.replace(/-(.)/g, function(_, c) {
+ return c.toUpperCase();
+ });
+ }
+
+ function addPropertyHandler(parser, merger, property) {
+ propertyHandlers[property] = propertyHandlers[property] || [];
+ propertyHandlers[property].push([parser, merger]);
+ }
+ function addPropertiesHandler(parser, merger, properties) {
+ for (var i = 0; i < properties.length; i++) {
+ var property = properties[i];
+ WEB_ANIMATIONS_TESTING && console.assert(property.toLowerCase() === property);
+ addPropertyHandler(parser, merger, toCamelCase(property));
+ }
+ }
+ scope.addPropertiesHandler = addPropertiesHandler;
+
+ var initialValues = {
+ backgroundColor: 'transparent',
+ backgroundPosition: '0% 0%',
+ borderBottomColor: 'currentColor',
+ borderBottomLeftRadius: '0px',
+ borderBottomRightRadius: '0px',
+ borderBottomWidth: '3px',
+ borderLeftColor: 'currentColor',
+ borderLeftWidth: '3px',
+ borderRightColor: 'currentColor',
+ borderRightWidth: '3px',
+ // Spec says this should be 0 but in practise it is 2px.
+ borderSpacing: '2px',
+ borderTopColor: 'currentColor',
+ borderTopLeftRadius: '0px',
+ borderTopRightRadius: '0px',
+ borderTopWidth: '3px',
+ bottom: 'auto',
+ clip: 'rect(0px, 0px, 0px, 0px)',
+ color: 'black', // Depends on user agent.
+ fontSize: '100%',
+ fontWeight: '400',
+ height: 'auto',
+ left: 'auto',
+ letterSpacing: 'normal',
+ lineHeight: '120%',
+ marginBottom: '0px',
+ marginLeft: '0px',
+ marginRight: '0px',
+ marginTop: '0px',
+ maxHeight: 'none',
+ maxWidth: 'none',
+ minHeight: '0px',
+ minWidth: '0px',
+ opacity: '1.0',
+ outlineColor: 'invert',
+ outlineOffset: '0px',
+ outlineWidth: '3px',
+ paddingBottom: '0px',
+ paddingLeft: '0px',
+ paddingRight: '0px',
+ paddingTop: '0px',
+ right: 'auto',
+ strokeDasharray: 'none',
+ strokeDashoffset: '0px',
+ textIndent: '0px',
+ textShadow: '0px 0px 0px transparent',
+ top: 'auto',
+ transform: '',
+ verticalAlign: '0px',
+ visibility: 'visible',
+ width: 'auto',
+ wordSpacing: 'normal',
+ zIndex: 'auto'
+ };
+
+ function propertyInterpolation(property, left, right) {
+ var ucProperty = property;
+ if (/-/.test(property) && !shared.isDeprecated('Hyphenated property names', '2016-03-22', 'Use camelCase instead.', true)) {
+ ucProperty = toCamelCase(property);
+ }
+ if (left == 'initial' || right == 'initial') {
+ if (left == 'initial')
+ left = initialValues[ucProperty];
+ if (right == 'initial')
+ right = initialValues[ucProperty];
+ }
+ var handlers = left == right ? [] : propertyHandlers[ucProperty];
+ for (var i = 0; handlers && i < handlers.length; i++) {
+ var parsedLeft = handlers[i][0](left);
+ var parsedRight = handlers[i][0](right);
+ if (parsedLeft !== undefined && parsedRight !== undefined) {
+ var interpolationArgs = handlers[i][1](parsedLeft, parsedRight);
+ if (interpolationArgs) {
+ var interp = scope.Interpolation.apply(null, interpolationArgs);
+ return function(t) {
+ if (t == 0) return left;
+ if (t == 1) return right;
+ return interp(t);
+ };
+ }
+ }
+ }
+ return scope.Interpolation(false, true, function(bool) {
+ return bool ? right : left;
+ });
+ }
+ scope.propertyInterpolation = propertyInterpolation;
+
+})(webAnimationsShared, webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/property-names.js b/catapult/third_party/polymer/components/web-animations-js/src/property-names.js
new file mode 100644
index 00000000..f106c066
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/property-names.js
@@ -0,0 +1,40 @@
+// 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(scope, testing) {
+
+ var prefixed = {};
+ var unprefixed = {};
+
+ function alias(name, aliases) {
+ aliases.concat([name]).forEach(function(candidate) {
+ if (candidate in document.documentElement.style) {
+ prefixed[name] = candidate;
+ }
+ unprefixed[candidate] = name;
+ });
+ }
+ alias('transform', ['webkitTransform', 'msTransform']);
+ alias('transformOrigin', ['webkitTransformOrigin']);
+ alias('perspective', ['webkitPerspective']);
+ alias('perspectiveOrigin', ['webkitPerspectiveOrigin']);
+
+ scope.propertyName = function(property) {
+ return prefixed[property] || property;
+ };
+ scope.unprefixedPropertyName = function(property) {
+ return unprefixed[property] || property;
+ };
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/scope.js b/catapult/third_party/polymer/components/web-animations-js/src/scope.js
new file mode 100644
index 00000000..c8248802
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/scope.js
@@ -0,0 +1,20 @@
+// 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.
+
+var webAnimationsShared = {};
+var webAnimations1 = {};
+var webAnimationsNext = {};
+
+if (!WEB_ANIMATIONS_TESTING)
+ var webAnimationsTesting = null;
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/shadow-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/shadow-handler.js
new file mode 100644
index 00000000..3f8201d8
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/shadow-handler.js
@@ -0,0 +1,108 @@
+// 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(scope) {
+
+ function consumeShadow(string) {
+ var shadow = {
+ inset: false,
+ lengths: [],
+ color: null,
+ };
+ function consumePart(string) {
+ var result = scope.consumeToken(/^inset/i, string);
+ if (result) {
+ shadow.inset = true;
+ return result;
+ }
+ var result = scope.consumeLengthOrPercent(string);
+ if (result) {
+ shadow.lengths.push(result[0]);
+ return result;
+ }
+ var result = scope.consumeColor(string);
+ if (result) {
+ shadow.color = result[0];
+ return result;
+ }
+ }
+ var result = scope.consumeRepeated(consumePart, /^/, string);
+ if (result && result[0].length) {
+ return [shadow, result[1]];
+ }
+ }
+
+ function parseShadowList(string) {
+ var result = scope.consumeRepeated(consumeShadow, /^,/, string);
+ if (result && result[1] == '') {
+ return result[0];
+ }
+ }
+
+ function mergeShadow(left, right) {
+ while (left.lengths.length < Math.max(left.lengths.length, right.lengths.length))
+ left.lengths.push({px: 0});
+ while (right.lengths.length < Math.max(left.lengths.length, right.lengths.length))
+ right.lengths.push({px: 0});
+
+ if (left.inset != right.inset || !!left.color != !!right.color) {
+ return;
+ }
+ var lengthReconstitution = [];
+ var colorReconstitution;
+ var matchingLeft = [[], 0];
+ var matchingRight = [[], 0];
+ for (var i = 0; i < left.lengths.length; i++) {
+ var mergedDimensions = scope.mergeDimensions(left.lengths[i], right.lengths[i], i == 2);
+ matchingLeft[0].push(mergedDimensions[0]);
+ matchingRight[0].push(mergedDimensions[1]);
+ lengthReconstitution.push(mergedDimensions[2]);
+ }
+ if (left.color && right.color) {
+ var mergedColor = scope.mergeColors(left.color, right.color);
+ matchingLeft[1] = mergedColor[0];
+ matchingRight[1] = mergedColor[1];
+ colorReconstitution = mergedColor[2];
+ }
+ return [matchingLeft, matchingRight, function(value) {
+ var result = left.inset ? 'inset ' : ' ';
+ for (var i = 0; i < lengthReconstitution.length; i++) {
+ result += lengthReconstitution[i](value[0][i]) + ' ';
+ }
+ if (colorReconstitution) {
+ result += colorReconstitution(value[1]);
+ }
+ return result;
+ }];
+ }
+
+ function mergeNestedRepeatedShadow(nestedMerge, separator, left, right) {
+ var leftCopy = [];
+ var rightCopy = [];
+ function defaultShadow(inset) {
+ return {inset: inset, color: [0, 0, 0, 0], lengths: [{px: 0}, {px: 0}, {px: 0}, {px: 0}]};
+ }
+ for (var i = 0; i < left.length || i < right.length; i++) {
+ var l = left[i] || defaultShadow(right[i].inset);
+ var r = right[i] || defaultShadow(left[i].inset);
+ leftCopy.push(l);
+ rightCopy.push(r);
+ }
+ return scope.mergeNestedRepeated(nestedMerge, separator, leftCopy, rightCopy);
+ }
+
+ var mergeShadowList = mergeNestedRepeatedShadow.bind(null, mergeShadow, ', ');
+ scope.addPropertiesHandler(parseShadowList, mergeShadowList, ['box-shadow', 'text-shadow']);
+
+})(webAnimations1);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/shape-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/shape-handler.js
new file mode 100644
index 00000000..6bbf79fe
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/shape-handler.js
@@ -0,0 +1,85 @@
+// 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(scope) {
+
+ var consumeLengthOrPercent = scope.consumeParenthesised.bind(null, scope.parseLengthOrPercent);
+ var consumeLengthOrPercentPair = scope.consumeRepeated.bind(undefined, consumeLengthOrPercent, /^/);
+
+ var mergeSizePair = scope.mergeNestedRepeated.bind(undefined, scope.mergeDimensions, ' ');
+ var mergeSizePairList = scope.mergeNestedRepeated.bind(undefined, mergeSizePair, ',');
+
+ function parseShape(input) {
+ var circle = scope.consumeToken(/^circle/, input);
+ if (circle && circle[0]) {
+ return ['circle'].concat(scope.consumeList([
+ scope.ignore(scope.consumeToken.bind(undefined, /^\(/)),
+ consumeLengthOrPercent,
+ scope.ignore(scope.consumeToken.bind(undefined, /^at/)),
+ scope.consumePosition,
+ scope.ignore(scope.consumeToken.bind(undefined, /^\)/))
+ ], circle[1]));
+ }
+ var ellipse = scope.consumeToken(/^ellipse/, input);
+ if (ellipse && ellipse[0]) {
+ return ['ellipse'].concat(scope.consumeList([
+ scope.ignore(scope.consumeToken.bind(undefined, /^\(/)),
+ consumeLengthOrPercentPair,
+ scope.ignore(scope.consumeToken.bind(undefined, /^at/)),
+ scope.consumePosition,
+ scope.ignore(scope.consumeToken.bind(undefined, /^\)/))
+ ], ellipse[1]));
+ }
+ var polygon = scope.consumeToken(/^polygon/, input);
+ if (polygon && polygon[0]) {
+ return ['polygon'].concat(scope.consumeList([
+ scope.ignore(scope.consumeToken.bind(undefined, /^\(/)),
+ scope.optional(scope.consumeToken.bind(undefined, /^nonzero\s*,|^evenodd\s*,/), 'nonzero,'),
+ scope.consumeSizePairList,
+ scope.ignore(scope.consumeToken.bind(undefined, /^\)/))
+ ], polygon[1]));
+ }
+ }
+
+ function mergeShapes(left, right) {
+ if (left[0] !== right[0])
+ return;
+ if (left[0] == 'circle') {
+ return scope.mergeList(left.slice(1), right.slice(1), [
+ 'circle(',
+ scope.mergeDimensions,
+ ' at ',
+ scope.mergeOffsetList,
+ ')']);
+ }
+ if (left[0] == 'ellipse') {
+ return scope.mergeList(left.slice(1), right.slice(1), [
+ 'ellipse(',
+ scope.mergeNonNegativeSizePair,
+ ' at ',
+ scope.mergeOffsetList,
+ ')']);
+ }
+ if (left[0] == 'polygon' && left[1] == right[1]) {
+ return scope.mergeList(left.slice(2), right.slice(2), [
+ 'polygon(',
+ left[1],
+ mergeSizePairList,
+ ')']);
+ }
+ }
+
+ scope.addPropertiesHandler(parseShape, mergeShapes, ['shape-outside']);
+
+})(webAnimations1);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/tick.js b/catapult/third_party/polymer/components/web-animations-js/src/tick.js
new file mode 100644
index 00000000..08b0a140
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/tick.js
@@ -0,0 +1,181 @@
+// 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(shared, scope, testing) {
+ var originalRequestAnimationFrame = window.requestAnimationFrame;
+ var rafCallbacks = [];
+ var rafId = 0;
+ window.requestAnimationFrame = function(f) {
+ var id = rafId++;
+ if (rafCallbacks.length == 0 && !WEB_ANIMATIONS_TESTING) {
+ originalRequestAnimationFrame(processRafCallbacks);
+ }
+ rafCallbacks.push([id, f]);
+ return id;
+ };
+
+ window.cancelAnimationFrame = function(id) {
+ rafCallbacks.forEach(function(entry) {
+ if (entry[0] == id) {
+ entry[1] = function() {};
+ }
+ });
+ };
+
+ function processRafCallbacks(t) {
+ var processing = rafCallbacks;
+ rafCallbacks = [];
+ if (t < timeline.currentTime)
+ t = timeline.currentTime;
+ timeline._animations.sort(compareAnimations);
+ timeline._animations = tick(t, true, timeline._animations)[0];
+ processing.forEach(function(entry) { entry[1](t); });
+ applyPendingEffects();
+ _now = undefined;
+ }
+
+ function compareAnimations(leftAnimation, rightAnimation) {
+ return leftAnimation._sequenceNumber - rightAnimation._sequenceNumber;
+ }
+
+ function InternalTimeline() {
+ this._animations = [];
+ // Android 4.3 browser has window.performance, but not window.performance.now
+ this.currentTime = window.performance && performance.now ? performance.now() : 0;
+ };
+
+ InternalTimeline.prototype = {
+ _play: function(effect) {
+ effect._timing = shared.normalizeTimingInput(effect.timing);
+ var animation = new scope.Animation(effect);
+ animation._idle = false;
+ animation._timeline = this;
+ this._animations.push(animation);
+ scope.restart();
+ scope.applyDirtiedAnimation(animation);
+ return animation;
+ }
+ };
+
+ var _now = undefined;
+
+ if (WEB_ANIMATIONS_TESTING) {
+ var now = function() { return timeline.currentTime; };
+ } else {
+ var now = function() {
+ if (_now == undefined)
+ _now = window.performance && performance.now ? performance.now() : Date.now();
+ return _now;
+ };
+ }
+
+ var ticking = false;
+ var hasRestartedThisFrame = false;
+
+ scope.restart = function() {
+ if (!ticking) {
+ ticking = true;
+ requestAnimationFrame(function() {});
+ hasRestartedThisFrame = true;
+ }
+ return hasRestartedThisFrame;
+ };
+
+ // RAF is supposed to be the last script to occur before frame rendering but not
+ // all browsers behave like this. This function is for synchonously updating an
+ // animation's effects whenever its state is mutated by script to work around
+ // incorrect script execution ordering by the browser.
+ scope.applyDirtiedAnimation = function(animation) {
+ if (inTick) {
+ return;
+ }
+ animation._markTarget();
+ var animations = animation._targetAnimations();
+ animations.sort(compareAnimations);
+ var inactiveAnimations = tick(scope.timeline.currentTime, false, animations.slice())[1];
+ inactiveAnimations.forEach(function(animation) {
+ var index = timeline._animations.indexOf(animation);
+ if (index !== -1) {
+ timeline._animations.splice(index, 1);
+ }
+ });
+ applyPendingEffects();
+ };
+
+ var pendingEffects = [];
+ function applyPendingEffects() {
+ pendingEffects.forEach(function(f) { f(); });
+ pendingEffects.length = 0;
+ }
+
+ var t60hz = 1000 / 60;
+
+ var inTick = false;
+ function tick(t, isAnimationFrame, updatingAnimations) {
+ inTick = true;
+ hasRestartedThisFrame = false;
+ var timeline = scope.timeline;
+
+ timeline.currentTime = t;
+ ticking = false;
+
+ var newPendingClears = [];
+ var newPendingEffects = [];
+ var activeAnimations = [];
+ var inactiveAnimations = [];
+ updatingAnimations.forEach(function(animation) {
+ animation._tick(t, isAnimationFrame);
+
+ if (!animation._inEffect) {
+ newPendingClears.push(animation._effect);
+ animation._unmarkTarget();
+ } else {
+ newPendingEffects.push(animation._effect);
+ animation._markTarget();
+ }
+
+ if (animation._needsTick)
+ ticking = true;
+
+ var alive = animation._inEffect || animation._needsTick;
+ animation._inTimeline = alive;
+ if (alive) {
+ activeAnimations.push(animation);
+ } else {
+ inactiveAnimations.push(animation);
+ }
+ });
+
+ // FIXME: Should remove dupliactes from pendingEffects.
+ pendingEffects.push.apply(pendingEffects, newPendingClears);
+ pendingEffects.push.apply(pendingEffects, newPendingEffects);
+
+ if (ticking)
+ requestAnimationFrame(function() {});
+
+ inTick = false;
+ return [activeAnimations, inactiveAnimations];
+ };
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.tick = function(t) { timeline.currentTime = t; processRafCallbacks(t); };
+ testing.isTicking = function() { return ticking; };
+ testing.setTicking = function(newVal) { ticking = newVal; };
+ }
+
+ var timeline = new InternalTimeline();
+ scope.timeline = timeline;
+
+})(webAnimationsShared, webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/timeline.js b/catapult/third_party/polymer/components/web-animations-js/src/timeline.js
new file mode 100644
index 00000000..2b213b55
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/timeline.js
@@ -0,0 +1,101 @@
+// 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(shared, scope, testing) {
+ var originalRequestAnimationFrame = window.requestAnimationFrame;
+ window.requestAnimationFrame = function(f) {
+ return originalRequestAnimationFrame(function(x) {
+ scope.timeline._updateAnimationsPromises();
+ f(x);
+ scope.timeline._updateAnimationsPromises();
+ });
+ };
+
+ scope.AnimationTimeline = function() {
+ this._animations = [];
+ this.currentTime = undefined;
+ };
+
+ scope.AnimationTimeline.prototype = {
+ getAnimations: function() {
+ this._discardAnimations();
+ return this._animations.slice();
+ },
+ _updateAnimationsPromises: function() {
+ scope.animationsWithPromises = scope.animationsWithPromises.filter(function(animation) {
+ return animation._updatePromises();
+ });
+ },
+ _discardAnimations: function() {
+ this._updateAnimationsPromises();
+ this._animations = this._animations.filter(function(animation) {
+ return animation.playState != 'finished' && animation.playState != 'idle';
+ });
+ },
+ _play: function(effect) {
+ var animation = new scope.Animation(effect, this);
+ this._animations.push(animation);
+ scope.restartWebAnimationsNextTick();
+ // Use animation._animation.play() here, NOT animation.play().
+ //
+ // Timeline.play calls new scope.Animation(effect) which (indirectly) calls Timeline.play on
+ // effect's children, and Animation.play is also recursive. We only need to call play on each
+ // animation in the tree once.
+ animation._updatePromises();
+ animation._animation.play();
+ animation._updatePromises();
+ return animation;
+ },
+ play: function(effect) {
+ if (effect) {
+ effect.remove();
+ }
+ return this._play(effect);
+ }
+ };
+
+ var ticking = false;
+
+ scope.restartWebAnimationsNextTick = function() {
+ if (!ticking) {
+ ticking = true;
+ requestAnimationFrame(webAnimationsNextTick);
+ }
+ };
+
+ function webAnimationsNextTick(t) {
+ var timeline = scope.timeline;
+ timeline.currentTime = t;
+ timeline._discardAnimations();
+ if (timeline._animations.length == 0)
+ ticking = false;
+ else
+ requestAnimationFrame(webAnimationsNextTick);
+ }
+
+ var timeline = new scope.AnimationTimeline();
+ scope.timeline = timeline;
+
+ try {
+ Object.defineProperty(window.document, 'timeline', {
+ configurable: true,
+ get: function() { return timeline; }
+ });
+ } catch (e) { }
+ try {
+ window.document.timeline = timeline;
+ } catch (e) { }
+
+})(webAnimationsShared, webAnimationsNext, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/timing-utilities.js b/catapult/third_party/polymer/components/web-animations-js/src/timing-utilities.js
new file mode 100644
index 00000000..2f16f3b1
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/timing-utilities.js
@@ -0,0 +1,420 @@
+// 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(shared, testing) {
+
+ var fills = 'backwards|forwards|both|none'.split('|');
+ var directions = 'reverse|alternate|alternate-reverse'.split('|');
+ var linear = function(x) { return x; };
+
+ function cloneTimingInput(timingInput) {
+ if (typeof timingInput == 'number') {
+ return timingInput;
+ }
+ var clone = {};
+ for (var m in timingInput) {
+ clone[m] = timingInput[m];
+ }
+ return clone;
+ }
+
+ function AnimationEffectTiming() {
+ this._delay = 0;
+ this._endDelay = 0;
+ this._fill = 'none';
+ this._iterationStart = 0;
+ this._iterations = 1;
+ this._duration = 0;
+ this._playbackRate = 1;
+ this._direction = 'normal';
+ this._easing = 'linear';
+ this._easingFunction = linear;
+ }
+
+ function isInvalidTimingDeprecated() {
+ return shared.isDeprecated('Invalid timing inputs', '2016-03-02', 'TypeError exceptions will be thrown instead.', true);
+ }
+
+ AnimationEffectTiming.prototype = {
+ _setMember: function(member, value) {
+ this['_' + member] = value;
+ if (this._effect) {
+ this._effect._timingInput[member] = value;
+ this._effect._timing = shared.normalizeTimingInput(this._effect._timingInput);
+ this._effect.activeDuration = shared.calculateActiveDuration(this._effect._timing);
+ if (this._effect._animation) {
+ this._effect._animation._rebuildUnderlyingAnimation();
+ }
+ }
+ },
+ get playbackRate() {
+ return this._playbackRate;
+ },
+ set delay(value) {
+ this._setMember('delay', value);
+ },
+ get delay() {
+ return this._delay;
+ },
+ set endDelay(value) {
+ this._setMember('endDelay', value);
+ },
+ get endDelay() {
+ return this._endDelay;
+ },
+ set fill(value) {
+ this._setMember('fill', value);
+ },
+ get fill() {
+ return this._fill;
+ },
+ set iterationStart(value) {
+ if ((isNaN(value) || value < 0) && isInvalidTimingDeprecated()) {
+ throw new TypeError('iterationStart must be a non-negative number, received: ' + timing.iterationStart);
+ }
+ this._setMember('iterationStart', value);
+ },
+ get iterationStart() {
+ return this._iterationStart;
+ },
+ set duration(value) {
+ if (value != 'auto' && (isNaN(value) || value < 0) && isInvalidTimingDeprecated()) {
+ throw new TypeError('duration must be non-negative or auto, received: ' + value);
+ }
+ this._setMember('duration', value);
+ },
+ get duration() {
+ return this._duration;
+ },
+ set direction(value) {
+ this._setMember('direction', value);
+ },
+ get direction() {
+ return this._direction;
+ },
+ set easing(value) {
+ this._easingFunction = parseEasingFunction(normalizeEasing(value));
+ this._setMember('easing', value);
+ },
+ get easing() {
+ return this._easing;
+ },
+ set iterations(value) {
+ if ((isNaN(value) || value < 0) && isInvalidTimingDeprecated()) {
+ throw new TypeError('iterations must be non-negative, received: ' + value);
+ }
+ this._setMember('iterations', value);
+ },
+ get iterations() {
+ return this._iterations;
+ }
+ };
+
+ function makeTiming(timingInput, forGroup, effect) {
+ var timing = new AnimationEffectTiming();
+ if (forGroup) {
+ timing.fill = 'both';
+ timing.duration = 'auto';
+ }
+ if (typeof timingInput == 'number' && !isNaN(timingInput)) {
+ timing.duration = timingInput;
+ } else if (timingInput !== undefined) {
+ Object.getOwnPropertyNames(timingInput).forEach(function(property) {
+ if (timingInput[property] != 'auto') {
+ if (typeof timing[property] == 'number' || property == 'duration') {
+ if (typeof timingInput[property] != 'number' || isNaN(timingInput[property])) {
+ return;
+ }
+ }
+ if ((property == 'fill') && (fills.indexOf(timingInput[property]) == -1)) {
+ return;
+ }
+ if ((property == 'direction') && (directions.indexOf(timingInput[property]) == -1)) {
+ return;
+ }
+ if (property == 'playbackRate' && timingInput[property] !== 1 && shared.isDeprecated('AnimationEffectTiming.playbackRate', '2014-11-28', 'Use Animation.playbackRate instead.')) {
+ return;
+ }
+ timing[property] = timingInput[property];
+ }
+ });
+ }
+ return timing;
+ }
+
+ function numericTimingToObject(timingInput) {
+ if (typeof timingInput == 'number') {
+ if (isNaN(timingInput)) {
+ timingInput = { duration: 0 };
+ } else {
+ timingInput = { duration: timingInput };
+ }
+ }
+ return timingInput;
+ }
+
+ function normalizeTimingInput(timingInput, forGroup) {
+ timingInput = shared.numericTimingToObject(timingInput);
+ return makeTiming(timingInput, forGroup);
+ }
+
+ function cubic(a, b, c, d) {
+ if (a < 0 || a > 1 || c < 0 || c > 1) {
+ return linear;
+ }
+ return function(x) {
+ if (x <= 0) {
+ var start_gradient = 0;
+ if (a > 0)
+ start_gradient = b / a;
+ else if (!b && c > 0)
+ start_gradient = d / c;
+ return start_gradient * x;
+ }
+ if (x >= 1) {
+ var end_gradient = 0;
+ if (c < 1)
+ end_gradient = (d - 1) / (c - 1);
+ else if (c == 1 && a < 1)
+ end_gradient = (b - 1) / (a - 1);
+ return 1 + end_gradient * (x - 1);
+ }
+
+ var start = 0, end = 1;
+ while (start < end) {
+ var mid = (start + end) / 2;
+ function f(a, b, m) { return 3 * a * (1 - m) * (1 - m) * m + 3 * b * (1 - m) * m * m + m * m * m};
+ var xEst = f(a, c, mid);
+ if (Math.abs(x - xEst) < 0.00001) {
+ return f(b, d, mid);
+ }
+ if (xEst < x) {
+ start = mid;
+ } else {
+ end = mid;
+ }
+ }
+ return f(b, d, mid);
+ }
+ }
+
+ var Start = 1;
+ var Middle = 0.5;
+ var End = 0;
+
+ function step(count, pos) {
+ return function(x) {
+ if (x >= 1) {
+ return 1;
+ }
+ var stepSize = 1 / count;
+ x += pos * stepSize;
+ return x - x % stepSize;
+ }
+ }
+
+ var presets = {
+ 'ease': cubic(0.25, 0.1, 0.25, 1),
+ 'ease-in': cubic(0.42, 0, 1, 1),
+ 'ease-out': cubic(0, 0, 0.58, 1),
+ 'ease-in-out': cubic(0.42, 0, 0.58, 1),
+ 'step-start': step(1, Start),
+ 'step-middle': step(1, Middle),
+ 'step-end': step(1, End)
+ };
+
+ var styleForCleaning = null;
+ var numberString = '\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*';
+ var cubicBezierRe = new RegExp('cubic-bezier\\(' + numberString + ',' + numberString + ',' + numberString + ',' + numberString + '\\)');
+ var stepRe = /steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/;
+
+ function normalizeEasing(easing) {
+ if (!styleForCleaning) {
+ styleForCleaning = document.createElement('div').style;
+ }
+ styleForCleaning.animationTimingFunction = '';
+ styleForCleaning.animationTimingFunction = easing;
+ var normalizedEasing = styleForCleaning.animationTimingFunction;
+ if (normalizedEasing == '' && isInvalidTimingDeprecated()) {
+ throw new TypeError(easing + ' is not a valid value for easing');
+ }
+ return normalizedEasing;
+ }
+
+ function parseEasingFunction(normalizedEasing) {
+ if (normalizedEasing == 'linear') {
+ return linear;
+ }
+ var cubicData = cubicBezierRe.exec(normalizedEasing);
+ if (cubicData) {
+ return cubic.apply(this, cubicData.slice(1).map(Number));
+ }
+ var stepData = stepRe.exec(normalizedEasing);
+ if (stepData) {
+ return step(Number(stepData[1]), {'start': Start, 'middle': Middle, 'end': End}[stepData[2]]);
+ }
+ var preset = presets[normalizedEasing];
+ if (preset) {
+ return preset;
+ }
+ // At this point none of our parse attempts succeeded; the easing is invalid.
+ // Fall back to linear in the interest of not crashing the page.
+ return linear;
+ }
+
+ function calculateActiveDuration(timing) {
+ return Math.abs(repeatedDuration(timing) / timing.playbackRate);
+ }
+
+ function repeatedDuration(timing) {
+ // https://w3c.github.io/web-animations/#calculating-the-active-duration
+ if (timing.duration === 0 || timing.iterations === 0) {
+ return 0;
+ }
+ return timing.duration * timing.iterations;
+ }
+
+ var PhaseNone = 0;
+ var PhaseBefore = 1;
+ var PhaseAfter = 2;
+ var PhaseActive = 3;
+
+ function calculatePhase(activeDuration, localTime, timing) {
+ // https://w3c.github.io/web-animations/#animation-effect-phases-and-states
+ if (localTime == null) {
+ return PhaseNone;
+ }
+
+ var endTime = timing.delay + activeDuration + timing.endDelay;
+ if (localTime < Math.min(timing.delay, endTime)) {
+ return PhaseBefore;
+ }
+ if (localTime >= Math.min(timing.delay + activeDuration, endTime)) {
+ return PhaseAfter;
+ }
+
+ return PhaseActive;
+ }
+
+ function calculateActiveTime(activeDuration, fillMode, localTime, phase, delay) {
+ // https://w3c.github.io/web-animations/#calculating-the-active-time
+ switch (phase) {
+ case PhaseBefore:
+ if (fillMode == 'backwards' || fillMode == 'both')
+ return 0;
+ return null;
+ case PhaseActive:
+ return localTime - delay;
+ case PhaseAfter:
+ if (fillMode == 'forwards' || fillMode == 'both')
+ return activeDuration;
+ return null;
+ case PhaseNone:
+ return null;
+ }
+ }
+
+ function calculateOverallProgress(iterationDuration, phase, iterations, activeTime, iterationStart) {
+ // https://w3c.github.io/web-animations/#calculating-the-overall-progress
+ var overallProgress = iterationStart;
+ if (iterationDuration === 0) {
+ if (phase !== PhaseBefore) {
+ overallProgress += iterations;
+ }
+ } else {
+ overallProgress += activeTime / iterationDuration;
+ }
+ return overallProgress;
+ }
+
+ function calculateSimpleIterationProgress(overallProgress, iterationStart, phase, iterations, activeTime, iterationDuration) {
+ // https://w3c.github.io/web-animations/#calculating-the-simple-iteration-progress
+
+ var simpleIterationProgress = (overallProgress === Infinity) ? iterationStart % 1 : overallProgress % 1;
+ if (simpleIterationProgress === 0 && phase === PhaseAfter && iterations !== 0 &&
+ (activeTime !== 0 || iterationDuration === 0)) {
+ simpleIterationProgress = 1;
+ }
+ return simpleIterationProgress;
+ }
+
+ function calculateCurrentIteration(phase, iterations, simpleIterationProgress, overallProgress) {
+ // https://w3c.github.io/web-animations/#calculating-the-current-iteration
+ if (phase === PhaseAfter && iterations === Infinity) {
+ return Infinity;
+ }
+ if (simpleIterationProgress === 1) {
+ return Math.floor(overallProgress) - 1;
+ }
+ return Math.floor(overallProgress);
+ }
+
+ function calculateDirectedProgress(playbackDirection, currentIteration, simpleIterationProgress) {
+ // https://w3c.github.io/web-animations/#calculating-the-directed-progress
+ var currentDirection = playbackDirection;
+ if (playbackDirection !== 'normal' && playbackDirection !== 'reverse') {
+ var d = currentIteration;
+ if (playbackDirection === 'alternate-reverse') {
+ d += 1;
+ }
+ currentDirection = 'normal';
+ if (d !== Infinity && d % 2 !== 0) {
+ currentDirection = 'reverse';
+ }
+ }
+ if (currentDirection === 'normal') {
+ return simpleIterationProgress;
+ }
+ return 1 - simpleIterationProgress;
+ }
+
+ function calculateIterationProgress(activeDuration, localTime, timing) {
+ var phase = calculatePhase(activeDuration, localTime, timing);
+ var activeTime = calculateActiveTime(activeDuration, timing.fill, localTime, phase, timing.delay);
+ if (activeTime === null)
+ return null;
+
+ var overallProgress = calculateOverallProgress(timing.duration, phase, timing.iterations, activeTime, timing.iterationStart);
+ var simpleIterationProgress = calculateSimpleIterationProgress(overallProgress, timing.iterationStart, phase, timing.iterations, activeTime, timing.duration);
+ var currentIteration = calculateCurrentIteration(phase, timing.iterations, simpleIterationProgress, overallProgress);
+ var directedProgress = calculateDirectedProgress(timing.direction, currentIteration, simpleIterationProgress);
+
+ // https://w3c.github.io/web-animations/#calculating-the-transformed-progress
+ // https://w3c.github.io/web-animations/#calculating-the-iteration-progress
+ return timing._easingFunction(directedProgress);
+ }
+
+ shared.cloneTimingInput = cloneTimingInput;
+ shared.makeTiming = makeTiming;
+ shared.numericTimingToObject = numericTimingToObject;
+ shared.normalizeTimingInput = normalizeTimingInput;
+ shared.calculateActiveDuration = calculateActiveDuration;
+ shared.calculateIterationProgress = calculateIterationProgress;
+ shared.calculatePhase = calculatePhase;
+ shared.normalizeEasing = normalizeEasing;
+ shared.parseEasingFunction = parseEasingFunction;
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.normalizeTimingInput = normalizeTimingInput;
+ testing.normalizeEasing = normalizeEasing;
+ testing.parseEasingFunction = parseEasingFunction;
+ testing.calculateActiveDuration = calculateActiveDuration;
+ testing.calculatePhase = calculatePhase;
+ testing.PhaseNone = PhaseNone;
+ testing.PhaseBefore = PhaseBefore;
+ testing.PhaseActive = PhaseActive;
+ testing.PhaseAfter = PhaseAfter;
+ }
+
+})(webAnimationsShared, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/transform-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/transform-handler.js
new file mode 100644
index 00000000..c6b4d934
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/transform-handler.js
@@ -0,0 +1,275 @@
+// 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(scope, testing) {
+
+ // This returns a function for converting transform functions to equivalent
+ // primitive functions, which will take an array of values from the
+ // derivative type and fill in the blanks (underscores) with them.
+ var _ = null;
+ function cast(pattern) {
+ return function(contents) {
+ var i = 0;
+ return pattern.map(function(x) { return x === _ ? contents[i++] : x; });
+ }
+ }
+
+ function id(x) { return x; }
+
+ var Opx = {px: 0};
+ var Odeg = {deg: 0};
+
+ // type: [argTypes, convertTo3D, convertTo2D]
+ // In the argument types string, lowercase characters represent optional arguments
+ var transformFunctions = {
+ matrix: ['NNNNNN', [_, _, 0, 0, _, _, 0, 0, 0, 0, 1, 0, _, _, 0, 1], id],
+ matrix3d: ['NNNNNNNNNNNNNNNN', id],
+ rotate: ['A'],
+ rotatex: ['A'],
+ rotatey: ['A'],
+ rotatez: ['A'],
+ rotate3d: ['NNNA'],
+ perspective: ['L'],
+ scale: ['Nn', cast([_, _, 1]), id],
+ scalex: ['N', cast([_, 1, 1]), cast([_, 1])],
+ scaley: ['N', cast([1, _, 1]), cast([1, _])],
+ scalez: ['N', cast([1, 1, _])],
+ scale3d: ['NNN', id],
+ skew: ['Aa', null, id],
+ skewx: ['A', null, cast([_, Odeg])],
+ skewy: ['A', null, cast([Odeg, _])],
+ translate: ['Tt', cast([_, _, Opx]), id],
+ translatex: ['T', cast([_, Opx, Opx]), cast([_, Opx])],
+ translatey: ['T', cast([Opx, _, Opx]), cast([Opx, _])],
+ translatez: ['L', cast([Opx, Opx, _])],
+ translate3d: ['TTL', id],
+ };
+
+ function parseTransform(string) {
+ string = string.toLowerCase().trim();
+ if (string == 'none')
+ return [];
+ // FIXME: Using a RegExp means calcs won't work here
+ var transformRegExp = /\s*(\w+)\(([^)]*)\)/g;
+ var result = [];
+ var match;
+ var prevLastIndex = 0;
+ while (match = transformRegExp.exec(string)) {
+ if (match.index != prevLastIndex)
+ return;
+ prevLastIndex = match.index + match[0].length;
+ var functionName = match[1];
+ var functionData = transformFunctions[functionName];
+ if (!functionData)
+ return;
+ var args = match[2].split(',');
+ var argTypes = functionData[0];
+ if (argTypes.length < args.length)
+ return;
+
+ var parsedArgs = [];
+ for (var i = 0; i < argTypes.length; i++) {
+ var arg = args[i];
+ var type = argTypes[i];
+ var parsedArg;
+ if (!arg)
+ parsedArg = ({a: Odeg,
+ n: parsedArgs[0],
+ t: Opx})[type];
+ else
+ parsedArg = ({A: function(s) { return s.trim() == '0' ? Odeg : scope.parseAngle(s); },
+ N: scope.parseNumber,
+ T: scope.parseLengthOrPercent,
+ L: scope.parseLength})[type.toUpperCase()](arg);
+ if (parsedArg === undefined)
+ return;
+ parsedArgs.push(parsedArg);
+ }
+ result.push({t: functionName, d: parsedArgs});
+
+ if (transformRegExp.lastIndex == string.length)
+ return result;
+ }
+ };
+
+ function numberToLongString(x) {
+ return x.toFixed(6).replace('.000000', '');
+ }
+
+ function mergeMatrices(left, right) {
+ if (left.decompositionPair !== right) {
+ left.decompositionPair = right;
+ var leftArgs = scope.makeMatrixDecomposition(left);
+ }
+ if (right.decompositionPair !== left) {
+ right.decompositionPair = left;
+ var rightArgs = scope.makeMatrixDecomposition(right);
+ }
+ if (leftArgs[0] == null || rightArgs[0] == null)
+ return [[false], [true], function(x) { return x ? right[0].d : left[0].d; }];
+ leftArgs[0].push(0);
+ rightArgs[0].push(1);
+ return [
+ leftArgs,
+ rightArgs,
+ function(list) {
+ var quat = scope.quat(leftArgs[0][3], rightArgs[0][3], list[5]);
+ var mat = scope.composeMatrix(list[0], list[1], list[2], quat, list[4]);
+ var stringifiedArgs = mat.map(numberToLongString).join(',');
+ return stringifiedArgs;
+ }
+ ];
+ }
+
+ function typeTo2D(type) {
+ return type.replace(/[xy]/, '');
+ }
+
+ function typeTo3D(type) {
+ return type.replace(/(x|y|z|3d)?$/, '3d');
+ }
+
+ function mergeTransforms(left, right) {
+ var matrixModulesLoaded = scope.makeMatrixDecomposition && true;
+
+ var flipResults = false;
+ if (!left.length || !right.length) {
+ if (!left.length) {
+ flipResults = true;
+ left = right;
+ right = [];
+ }
+ for (var i = 0; i < left.length; i++) {
+ var type = left[i].t;
+ var args = left[i].d;
+ var defaultValue = type.substr(0, 5) == 'scale' ? 1 : 0;
+ right.push({t: type, d: args.map(function(arg) {
+ if (typeof arg == 'number')
+ return defaultValue;
+ var result = {};
+ for (var unit in arg)
+ result[unit] = defaultValue;
+ return result;
+ })});
+ }
+ }
+
+ var isMatrixOrPerspective = function(lt, rt) {
+ return ((lt == 'perspective') && (rt == 'perspective')) ||
+ ((lt == 'matrix' || lt == 'matrix3d') && (rt == 'matrix' || rt == 'matrix3d'));
+ };
+ var leftResult = [];
+ var rightResult = [];
+ var types = [];
+
+ if (left.length != right.length) {
+ if (!matrixModulesLoaded)
+ return;
+ var merged = mergeMatrices(left, right);
+ leftResult = [merged[0]];
+ rightResult = [merged[1]];
+ types = [['matrix', [merged[2]]]];
+ } else {
+ for (var i = 0; i < left.length; i++) {
+ var leftType = left[i].t;
+ var rightType = right[i].t;
+ var leftArgs = left[i].d;
+ var rightArgs = right[i].d;
+
+ var leftFunctionData = transformFunctions[leftType];
+ var rightFunctionData = transformFunctions[rightType];
+
+ var type;
+ if (isMatrixOrPerspective(leftType, rightType)) {
+ if (!matrixModulesLoaded)
+ return;
+ var merged = mergeMatrices([left[i]], [right[i]]);
+ leftResult.push(merged[0]);
+ rightResult.push(merged[1]);
+ types.push(['matrix', [merged[2]]]);
+ continue;
+ } else if (leftType == rightType) {
+ type = leftType;
+ } else if (leftFunctionData[2] && rightFunctionData[2] && typeTo2D(leftType) == typeTo2D(rightType)) {
+ type = typeTo2D(leftType);
+ leftArgs = leftFunctionData[2](leftArgs);
+ rightArgs = rightFunctionData[2](rightArgs);
+ } else if (leftFunctionData[1] && rightFunctionData[1] && typeTo3D(leftType) == typeTo3D(rightType)) {
+ type = typeTo3D(leftType);
+ leftArgs = leftFunctionData[1](leftArgs);
+ rightArgs = rightFunctionData[1](rightArgs);
+ } else {
+ if (!matrixModulesLoaded)
+ return;
+ var merged = mergeMatrices(left, right);
+ leftResult = [merged[0]];
+ rightResult = [merged[1]];
+ types = [['matrix', [merged[2]]]];
+ break;
+ }
+
+ var leftArgsCopy = [];
+ var rightArgsCopy = [];
+ var stringConversions = [];
+ for (var j = 0; j < leftArgs.length; j++) {
+ var merge = typeof leftArgs[j] == 'number' ? scope.mergeNumbers : scope.mergeDimensions;
+ var merged = merge(leftArgs[j], rightArgs[j]);
+ leftArgsCopy[j] = merged[0];
+ rightArgsCopy[j] = merged[1];
+ stringConversions.push(merged[2]);
+ }
+ leftResult.push(leftArgsCopy);
+ rightResult.push(rightArgsCopy);
+ types.push([type, stringConversions]);
+ }
+ }
+
+ if (flipResults) {
+ var tmp = leftResult;
+ leftResult = rightResult;
+ rightResult = tmp;
+ }
+
+ return [leftResult, rightResult, function(list) {
+ return list.map(function(args, i) {
+ var stringifiedArgs = args.map(function(arg, j) {
+ return types[i][1][j](arg);
+ }).join(',');
+ if (types[i][0] == 'matrix' && stringifiedArgs.split(',').length == 16)
+ types[i][0] = 'matrix3d';
+ return types[i][0] + '(' + stringifiedArgs + ')';
+
+ }).join(' ');
+ }];
+ }
+
+ scope.addPropertiesHandler(parseTransform, mergeTransforms, ['transform']);
+
+ scope.transformToSvgMatrix = function(string) {
+ // matrix(<a> <b> <c> <d> <e> <f>)
+ var mat = scope.transformListToMatrix(parseTransform(string));
+ return 'matrix(' +
+ numberToLongString(mat[0]) + ' ' + // <a>
+ numberToLongString(mat[1]) + ' ' + // <b>
+ numberToLongString(mat[4]) + ' ' + // <c>
+ numberToLongString(mat[5]) + ' ' + // <d>
+ numberToLongString(mat[12]) + ' ' + // <e>
+ numberToLongString(mat[13]) + // <f>
+ ')';
+ };
+
+ if (WEB_ANIMATIONS_TESTING)
+ testing.parseTransform = parseTransform;
+
+})(webAnimations1, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/visibility-handler.js b/catapult/third_party/polymer/components/web-animations-js/src/visibility-handler.js
new file mode 100644
index 00000000..53f29535
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/visibility-handler.js
@@ -0,0 +1,29 @@
+// 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(scope, testing) {
+
+ function merge(left, right) {
+ if (left != 'visible' && right != 'visible') return;
+ return [0, 1, function(x) {
+ if (x <= 0) return left;
+ if (x >= 1) return right;
+ return 'visible';
+ }];
+ }
+
+ scope.addPropertiesHandler(String, merge, ['visibility']);
+
+})(webAnimations1);
+
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-cancel-events.js b/catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-cancel-events.js
new file mode 100644
index 00000000..3905496f
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-cancel-events.js
@@ -0,0 +1,83 @@
+// Copyright 2016 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() {
+
+ if (document.createElement('div').animate([]).oncancel !== undefined) {
+ return;
+ }
+
+ if (WEB_ANIMATIONS_TESTING) {
+ var now = function() { return webAnimations1.timeline.currentTime; };
+ } else if (window.performance && performance.now) {
+ var now = function() { return performance.now(); };
+ } else {
+ var now = function() { return Date.now(); };
+ }
+
+ var AnimationCancelEvent = function(target, currentTime, timelineTime) {
+ this.target = target;
+ this.currentTime = currentTime;
+ this.timelineTime = timelineTime;
+
+ this.type = 'cancel';
+ this.bubbles = false;
+ this.cancelable = false;
+ this.currentTarget = target;
+ this.defaultPrevented = false;
+ this.eventPhase = Event.AT_TARGET;
+ this.timeStamp = Date.now();
+ };
+
+ var originalElementAnimate = window.Element.prototype.animate;
+ window.Element.prototype.animate = function(effectInput, options) {
+ var animation = originalElementAnimate.call(this, effectInput, options);
+
+ animation._cancelHandlers = [];
+ animation.oncancel = null;
+
+ var originalCancel = animation.cancel;
+ animation.cancel = function() {
+ originalCancel.call(this);
+ var event = new AnimationCancelEvent(this, null, now());
+ var handlers = this._cancelHandlers.concat(this.oncancel ? [this.oncancel] : []);
+ setTimeout(function() {
+ handlers.forEach(function(handler) {
+ handler.call(event.target, event);
+ });
+ }, 0);
+ };
+
+ var originalAddEventListener = animation.addEventListener;
+ animation.addEventListener = function(type, handler) {
+ if (typeof handler == 'function' && type == 'cancel')
+ this._cancelHandlers.push(handler);
+ else
+ originalAddEventListener.call(this, type, handler);
+ };
+
+ var originalRemoveEventListener = animation.removeEventListener;
+ animation.removeEventListener = function(type, handler) {
+ if (type == 'cancel') {
+ var index = this._cancelHandlers.indexOf(handler);
+ if (index >= 0)
+ this._cancelHandlers.splice(index, 1);
+ } else {
+ originalRemoveEventListener.call(this, type, handler);
+ }
+ };
+
+ return animation;
+ };
+})();
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-object-form-keyframes.js b/catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-object-form-keyframes.js
new file mode 100644
index 00000000..c1b6ecdc
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/web-animations-bonus-object-form-keyframes.js
@@ -0,0 +1,63 @@
+// Copyright 2016 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(shared) {
+ // If the polyfill is being loaded in a context where Element.animate is
+ // supported but object-form syntax is not, then creating an animation
+ // using the new syntax will either have no effect or will throw an exception.
+ // In either case, we want to proceed to load this part of the polyfill.
+ //
+ // The test animation uses an opacity other than the one the element already
+ // has, and doesn't need to change during the animation for the test to work.
+ // After the test, the element's opacity will be left how we found it:
+ // - If the animation is not created, the test will leave the element's
+ // opacity untouched at originalOpacity.
+ // - If the animation is created, it will be cancelled, and leave the
+ // element's opacity at originalOpacity.
+ // - If the animation is somehow created and runs without being cancelled,
+ // when it finishes after 1ms, it will cease to have any effect (because
+ // fill is not specified), and opacity will again be left at originalOpacity.
+ var element = document.documentElement;
+ var animation = null;
+ var animated = false;
+ try {
+ var originalOpacity = getComputedStyle(element).getPropertyValue('opacity');
+ var testOpacity = originalOpacity == '0' ? '1' : '0';
+ animation = element.animate({'opacity': [testOpacity, testOpacity]},
+ {duration: 1});
+ animation.currentTime = 0;
+ animated = getComputedStyle(element).getPropertyValue('opacity') == testOpacity;
+ } catch (error) {
+ } finally {
+ if (animation)
+ animation.cancel();
+ }
+ if (animated) {
+ return;
+ }
+
+ var originalElementAnimate = window.Element.prototype.animate;
+ window.Element.prototype.animate = function(effectInput, options) {
+ if (window.Symbol && Symbol.iterator && Array.prototype.from && effectInput[Symbol.iterator]) {
+ // Handle custom iterables in most browsers by converting to an array
+ effectInput = Array.from(effectInput);
+ }
+
+ if (!Array.isArray(effectInput) && effectInput !== null) {
+ effectInput = shared.convertToArrayForm(effectInput);
+ }
+
+ return originalElementAnimate.call(this, effectInput, options);
+ };
+})(webAnimationsShared);
diff --git a/catapult/third_party/polymer/components/web-animations-js/src/web-animations-next-animation.js b/catapult/third_party/polymer/components/web-animations-js/src/web-animations-next-animation.js
new file mode 100644
index 00000000..698532cd
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/src/web-animations-next-animation.js
@@ -0,0 +1,383 @@
+// 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(shared, scope, testing) {
+ scope.animationsWithPromises = [];
+
+ scope.Animation = function(effect, timeline) {
+ this.id = '';
+ if (effect && effect._id) {
+ this.id = effect._id;
+ }
+ this.effect = effect;
+ if (effect) {
+ effect._animation = this;
+ }
+ if (!timeline) {
+ throw new Error('Animation with null timeline is not supported');
+ }
+ this._timeline = timeline;
+ this._sequenceNumber = shared.sequenceNumber++;
+ this._holdTime = 0;
+ this._paused = false;
+ this._isGroup = false;
+ this._animation = null;
+ this._childAnimations = [];
+ this._callback = null;
+ this._oldPlayState = 'idle';
+ this._rebuildUnderlyingAnimation();
+ // Animations are constructed in the idle state.
+ this._animation.cancel();
+ this._updatePromises();
+ };
+
+ scope.Animation.prototype = {
+ _updatePromises: function() {
+ var oldPlayState = this._oldPlayState;
+ var newPlayState = this.playState;
+ if (this._readyPromise && newPlayState !== oldPlayState) {
+ if (newPlayState == 'idle') {
+ this._rejectReadyPromise();
+ this._readyPromise = undefined;
+ } else if (oldPlayState == 'pending') {
+ this._resolveReadyPromise();
+ } else if (newPlayState == 'pending') {
+ this._readyPromise = undefined;
+ }
+ }
+ if (this._finishedPromise && newPlayState !== oldPlayState) {
+ if (newPlayState == 'idle') {
+ this._rejectFinishedPromise();
+ this._finishedPromise = undefined;
+ } else if (newPlayState == 'finished') {
+ this._resolveFinishedPromise();
+ } else if (oldPlayState == 'finished') {
+ this._finishedPromise = undefined;
+ }
+ }
+ this._oldPlayState = this.playState;
+ return (this._readyPromise || this._finishedPromise);
+ },
+ _rebuildUnderlyingAnimation: function() {
+ this._updatePromises();
+ var oldPlaybackRate;
+ var oldPaused;
+ var oldStartTime;
+ var oldCurrentTime;
+ var hadUnderlying = this._animation ? true : false;
+ if (hadUnderlying) {
+ oldPlaybackRate = this.playbackRate;
+ oldPaused = this._paused;
+ oldStartTime = this.startTime;
+ oldCurrentTime = this.currentTime;
+ this._animation.cancel();
+ this._animation._wrapper = null;
+ this._animation = null;
+ }
+
+ if (!this.effect || this.effect instanceof window.KeyframeEffect) {
+ this._animation = scope.newUnderlyingAnimationForKeyframeEffect(this.effect);
+ scope.bindAnimationForKeyframeEffect(this);
+ }
+ if (this.effect instanceof window.SequenceEffect || this.effect instanceof window.GroupEffect) {
+ this._animation = scope.newUnderlyingAnimationForGroup(this.effect);
+ scope.bindAnimationForGroup(this);
+ }
+ if (this.effect && this.effect._onsample) {
+ scope.bindAnimationForCustomEffect(this);
+ }
+ if (hadUnderlying) {
+ if (oldPlaybackRate != 1) {
+ this.playbackRate = oldPlaybackRate;
+ }
+ if (oldStartTime !== null) {
+ this.startTime = oldStartTime;
+ } else if (oldCurrentTime !== null) {
+ this.currentTime = oldCurrentTime;
+ } else if (this._holdTime !== null) {
+ this.currentTime = this._holdTime;
+ }
+ if (oldPaused) {
+ this.pause();
+ }
+ }
+ this._updatePromises();
+ },
+ _updateChildren: function() {
+ if (!this.effect || this.playState == 'idle')
+ return;
+
+ var offset = this.effect._timing.delay;
+ this._childAnimations.forEach(function(childAnimation) {
+ this._arrangeChildren(childAnimation, offset);
+ if (this.effect instanceof window.SequenceEffect)
+ offset += scope.groupChildDuration(childAnimation.effect);
+ }.bind(this));
+ },
+ _setExternalAnimation: function(animation) {
+ if (!this.effect || !this._isGroup)
+ return;
+ for (var i = 0; i < this.effect.children.length; i++) {
+ this.effect.children[i]._animation = animation;
+ this._childAnimations[i]._setExternalAnimation(animation);
+ }
+ },
+ _constructChildAnimations: function() {
+ if (!this.effect || !this._isGroup)
+ return;
+ var offset = this.effect._timing.delay;
+ this._removeChildAnimations();
+ this.effect.children.forEach(function(child) {
+ var childAnimation = scope.timeline._play(child);
+ this._childAnimations.push(childAnimation);
+ childAnimation.playbackRate = this.playbackRate;
+ if (this._paused)
+ childAnimation.pause();
+ child._animation = this.effect._animation;
+
+ this._arrangeChildren(childAnimation, offset);
+
+ if (this.effect instanceof window.SequenceEffect)
+ offset += scope.groupChildDuration(child);
+ }.bind(this));
+ },
+ _arrangeChildren: function(childAnimation, offset) {
+ if (this.startTime === null) {
+ childAnimation.currentTime = this.currentTime - offset / this.playbackRate;
+ } else if (childAnimation.startTime !== this.startTime + offset / this.playbackRate) {
+ childAnimation.startTime = this.startTime + offset / this.playbackRate;
+ }
+ },
+ get timeline() {
+ return this._timeline;
+ },
+ get playState() {
+ return this._animation ? this._animation.playState : 'idle';
+ },
+ get finished() {
+ if (!window.Promise) {
+ console.warn('Animation Promises require JavaScript Promise constructor');
+ return null;
+ }
+ if (!this._finishedPromise) {
+ if (scope.animationsWithPromises.indexOf(this) == -1) {
+ scope.animationsWithPromises.push(this);
+ }
+ this._finishedPromise = new Promise(
+ function(resolve, reject) {
+ this._resolveFinishedPromise = function() {
+ resolve(this);
+ };
+ this._rejectFinishedPromise = function() {
+ reject({type: DOMException.ABORT_ERR, name: 'AbortError'});
+ };
+ }.bind(this));
+ if (this.playState == 'finished') {
+ this._resolveFinishedPromise();
+ }
+ }
+ return this._finishedPromise;
+ },
+ get ready() {
+ if (!window.Promise) {
+ console.warn('Animation Promises require JavaScript Promise constructor');
+ return null;
+ }
+ if (!this._readyPromise) {
+ if (scope.animationsWithPromises.indexOf(this) == -1) {
+ scope.animationsWithPromises.push(this);
+ }
+ this._readyPromise = new Promise(
+ function(resolve, reject) {
+ this._resolveReadyPromise = function() {
+ resolve(this);
+ };
+ this._rejectReadyPromise = function() {
+ reject({type: DOMException.ABORT_ERR, name: 'AbortError'});
+ };
+ }.bind(this));
+ if (this.playState !== 'pending') {
+ this._resolveReadyPromise();
+ }
+ }
+ return this._readyPromise;
+ },
+ get onfinish() {
+ return this._animation.onfinish;
+ },
+ set onfinish(v) {
+ if (typeof v == 'function') {
+ this._animation.onfinish = (function(e) {
+ e.target = this;
+ v.call(this, e);
+ }).bind(this);
+ } else {
+ this._animation.onfinish = v;
+ }
+ },
+ get oncancel() {
+ return this._animation.oncancel;
+ },
+ set oncancel(v) {
+ if (typeof v == 'function') {
+ this._animation.oncancel = (function(e) {
+ e.target = this;
+ v.call(this, e);
+ }).bind(this);
+ } else {
+ this._animation.oncancel = v;
+ }
+ },
+ get currentTime() {
+ this._updatePromises();
+ var currentTime = this._animation.currentTime;
+ this._updatePromises();
+ return currentTime;
+ },
+ set currentTime(v) {
+ this._updatePromises();
+ this._animation.currentTime = isFinite(v) ? v : Math.sign(v) * Number.MAX_VALUE;
+ this._register();
+ this._forEachChild(function(child, offset) {
+ child.currentTime = v - offset;
+ });
+ this._updatePromises();
+ },
+ get startTime() {
+ return this._animation.startTime;
+ },
+ set startTime(v) {
+ this._updatePromises();
+ this._animation.startTime = isFinite(v) ? v : Math.sign(v) * Number.MAX_VALUE;
+ this._register();
+ this._forEachChild(function(child, offset) {
+ child.startTime = v + offset;
+ });
+ this._updatePromises();
+ },
+ get playbackRate() {
+ return this._animation.playbackRate;
+ },
+ set playbackRate(value) {
+ this._updatePromises();
+ var oldCurrentTime = this.currentTime;
+ this._animation.playbackRate = value;
+ this._forEachChild(function(childAnimation) {
+ childAnimation.playbackRate = value;
+ });
+ if (oldCurrentTime !== null) {
+ this.currentTime = oldCurrentTime;
+ }
+ this._updatePromises();
+ },
+ play: function() {
+ this._updatePromises();
+ this._paused = false;
+ this._animation.play();
+ if (this._timeline._animations.indexOf(this) == -1) {
+ this._timeline._animations.push(this);
+ }
+ this._register();
+ scope.awaitStartTime(this);
+ this._forEachChild(function(child) {
+ var time = child.currentTime;
+ child.play();
+ child.currentTime = time;
+ });
+ this._updatePromises();
+ },
+ pause: function() {
+ this._updatePromises();
+ if (this.currentTime) {
+ this._holdTime = this.currentTime;
+ }
+ this._animation.pause();
+ this._register();
+ this._forEachChild(function(child) {
+ child.pause();
+ });
+ this._paused = true;
+ this._updatePromises();
+ },
+ finish: function() {
+ this._updatePromises();
+ this._animation.finish();
+ this._register();
+ this._updatePromises();
+ },
+ cancel: function() {
+ this._updatePromises();
+ this._animation.cancel();
+ this._register();
+ this._removeChildAnimations();
+ this._updatePromises();
+ },
+ reverse: function() {
+ this._updatePromises();
+ var oldCurrentTime = this.currentTime;
+ this._animation.reverse();
+ this._forEachChild(function(childAnimation) {
+ childAnimation.reverse();
+ });
+ if (oldCurrentTime !== null) {
+ this.currentTime = oldCurrentTime;
+ }
+ this._updatePromises();
+ },
+ addEventListener: function(type, handler) {
+ var wrapped = handler;
+ if (typeof handler == 'function') {
+ wrapped = (function(e) {
+ e.target = this;
+ handler.call(this, e);
+ }).bind(this);
+ handler._wrapper = wrapped;
+ }
+ this._animation.addEventListener(type, wrapped);
+ },
+ removeEventListener: function(type, handler) {
+ this._animation.removeEventListener(type, (handler && handler._wrapper) || handler);
+ },
+ _removeChildAnimations: function() {
+ while (this._childAnimations.length)
+ this._childAnimations.pop().cancel();
+ },
+ _forEachChild: function(f) {
+ var offset = 0;
+ if (this.effect.children && this._childAnimations.length < this.effect.children.length)
+ this._constructChildAnimations();
+ this._childAnimations.forEach(function(child) {
+ f.call(this, child, offset);
+ if (this.effect instanceof window.SequenceEffect)
+ offset += child.effect.activeDuration;
+ }.bind(this));
+
+ if (this.playState == 'pending')
+ return;
+ var timing = this.effect._timing;
+ var t = this.currentTime;
+ if (t !== null)
+ t = shared.calculateIterationProgress(shared.calculateActiveDuration(timing), t, timing);
+ if (t == null || isNaN(t))
+ this._removeChildAnimations();
+ },
+ };
+
+ window.Animation = scope.Animation;
+
+ if (WEB_ANIMATIONS_TESTING) {
+ testing.webAnimationsNextAnimation = scope.Animation;
+ }
+
+})(webAnimationsShared, webAnimationsNext, webAnimationsTesting);
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.html b/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.html
new file mode 100644
index 00000000..3580355a
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.html
@@ -0,0 +1 @@
+<script src="./web-animations-next-lite.min.js"></script>
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js b/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js
new file mode 100644
index 00000000..965fcbb2
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js
@@ -0,0 +1,16 @@
+// 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){var c={},d={},e={};!function(a,b){function c(a){if("number"==typeof a)return a;var b={};for(var c in a)b[c]=a[c];return b}function d(){this._delay=0,this._endDelay=0,this._fill="none",this._iterationStart=0,this._iterations=1,this._duration=0,this._playbackRate=1,this._direction="normal",this._easing="linear",this._easingFunction=x}function e(){return a.isDeprecated("Invalid timing inputs","2016-03-02","TypeError exceptions will be thrown instead.",!0)}function f(b,c,e){var f=new d;return c&&(f.fill="both",f.duration="auto"),"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof f[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==v.indexOf(b[c]))return;if("direction"==c&&-1==w.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;f[c]=b[c]}}):f.duration=b,f}function g(a){return"number"==typeof a&&(a=isNaN(a)?{duration:0}:{duration:a}),a}function h(b,c){return b=a.numericTimingToObject(b),f(b,c)}function i(a,b,c,d){return a<0||a>1||c<0||c>1?x:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}if(e<=0){var g=0;return a>0?g=b/a:!b&&c>0&&(g=d/c),g*e}if(e>=1){var h=0;return c<1?h=(d-1)/(c-1):1==c&&a<1&&(h=(b-1)/(a-1)),1+h*(e-1)}for(var i=0,j=1;i<j;){var k=(i+j)/2,l=f(a,c,k);if(Math.abs(e-l)<1e-5)return f(b,d,k);l<e?i=k:j=k}return f(b,d,k)}}function j(a,b){return function(c){if(c>=1)return 1;var d=1/a;return(c+=b*d)-c%d}}function k(a){C||(C=document.createElement("div").style),C.animationTimingFunction="",C.animationTimingFunction=a;var b=C.animationTimingFunction;if(""==b&&e())throw new TypeError(a+" is not a valid value for easing");return b}function l(a){if("linear"==a)return x;var b=E.exec(a);if(b)return i.apply(this,b.slice(1).map(Number));var c=F.exec(a);return c?j(Number(c[1]),{start:y,middle:z,end:A}[c[2]]):B[a]||x}function m(a){return Math.abs(n(a)/a.playbackRate)}function n(a){return 0===a.duration||0===a.iterations?0:a.duration*a.iterations}function o(a,b,c){if(null==b)return G;var d=c.delay+a+c.endDelay;return b<Math.min(c.delay,d)?H:b>=Math.min(c.delay+a,d)?I:J}function p(a,b,c,d,e){switch(d){case H:return"backwards"==b||"both"==b?0:null;case J:return c-e;case I:return"forwards"==b||"both"==b?a:null;case G:return null}}function q(a,b,c,d,e){var f=e;return 0===a?b!==H&&(f+=c):f+=d/a,f}function r(a,b,c,d,e,f){var g=a===1/0?b%1:a%1;return 0!==g||c!==I||0===d||0===e&&0!==f||(g=1),g}function s(a,b,c,d){return a===I&&b===1/0?1/0:1===c?Math.floor(d)-1:Math.floor(d)}function t(a,b,c){var d=a;if("normal"!==a&&"reverse"!==a){var e=b;"alternate-reverse"===a&&(e+=1),d="normal",e!==1/0&&e%2!=0&&(d="reverse")}return"normal"===d?c:1-c}function u(a,b,c){var d=o(a,b,c),e=p(a,c.fill,b,d,c.delay);if(null===e)return null;var f=q(c.duration,d,c.iterations,e,c.iterationStart),g=r(f,c.iterationStart,d,c.iterations,e,c.duration),h=s(d,c.iterations,g,f),i=t(c.direction,h,g);return c._easingFunction(i)}var v="backwards|forwards|both|none".split("|"),w="reverse|alternate|alternate-reverse".split("|"),x=function(a){return a};d.prototype={_setMember:function(b,c){this["_"+b]=c,this._effect&&(this._effect._timingInput[b]=c,this._effect._timing=a.normalizeTimingInput(this._effect._timingInput),this._effect.activeDuration=a.calculateActiveDuration(this._effect._timing),this._effect._animation&&this._effect._animation._rebuildUnderlyingAnimation())},get playbackRate(){return this._playbackRate},set delay(a){this._setMember("delay",a)},get delay(){return this._delay},set endDelay(a){this._setMember("endDelay",a)},get endDelay(){return this._endDelay},set fill(a){this._setMember("fill",a)},get fill(){return this._fill},set iterationStart(a){if((isNaN(a)||a<0)&&e())throw new TypeError("iterationStart must be a non-negative number, received: "+timing.iterationStart);this._setMember("iterationStart",a)},get iterationStart(){return this._iterationStart},set duration(a){if("auto"!=a&&(isNaN(a)||a<0)&&e())throw new TypeError("duration must be non-negative or auto, received: "+a);this._setMember("duration",a)},get duration(){return this._duration},set direction(a){this._setMember("direction",a)},get direction(){return this._direction},set easing(a){this._easingFunction=l(k(a)),this._setMember("easing",a)},get easing(){return this._easing},set iterations(a){if((isNaN(a)||a<0)&&e())throw new TypeError("iterations must be non-negative, received: "+a);this._setMember("iterations",a)},get iterations(){return this._iterations}};var y=1,z=.5,A=0,B={ease:i(.25,.1,.25,1),"ease-in":i(.42,0,1,1),"ease-out":i(0,0,.58,1),"ease-in-out":i(.42,0,.58,1),"step-start":j(1,y),"step-middle":j(1,z),"step-end":j(1,A)},C=null,D="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",E=new RegExp("cubic-bezier\\("+D+","+D+","+D+","+D+"\\)"),F=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,G=0,H=1,I=2,J=3;a.cloneTimingInput=c,a.makeTiming=f,a.numericTimingToObject=g,a.normalizeTimingInput=h,a.calculateActiveDuration=m,a.calculateIterationProgress=u,a.calculatePhase=o,a.normalizeEasing=k,a.parseEasingFunction=l}(c),function(a,b){function c(a,b){return a in k?k[a][b]||b:b}function d(a){return"display"===a||0===a.lastIndexOf("animation",0)||0===a.lastIndexOf("transition",0)}function e(a,b,e){if(!d(a)){var f=h[a];if(f){i.style[a]=b;for(var g in f){var j=f[g],k=i.style[j];e[j]=c(j,k)}}else e[a]=c(a,b)}}function f(a){var b=[];for(var c in a)if(!(c in["easing","offset","composite"])){var d=a[c];Array.isArray(d)||(d=[d]);for(var e,f=d.length,g=0;g<f;g++)e={},e.offset="offset"in a?a.offset:1==f?1:g/(f-1),"easing"in a&&(e.easing=a.easing),"composite"in a&&(e.composite=a.composite),e[c]=d[g],b.push(e)}return b.sort(function(a,b){return a.offset-b.offset}),b}function g(b){function c(){var a=d.length;null==d[a-1].offset&&(d[a-1].offset=1),a>1&&null==d[0].offset&&(d[0].offset=0);for(var b=0,c=d[0].offset,e=1;e<a;e++){var f=d[e].offset;if(null!=f){for(var g=1;g<e-b;g++)d[b+g].offset=c+(f-c)*g/(e-b);b=e,c=f}}}if(null==b)return[];window.Symbol&&Symbol.iterator&&Array.prototype.from&&b[Symbol.iterator]&&(b=Array.from(b)),Array.isArray(b)||(b=f(b));for(var d=b.map(function(b){var c={};for(var d in b){var f=b[d];if("offset"==d){if(null!=f){if(f=Number(f),!isFinite(f))throw new TypeError("Keyframe offsets must be numbers.");if(f<0||f>1)throw new TypeError("Keyframe offsets must be between 0 and 1.")}}else if("composite"==d){if("add"==f||"accumulate"==f)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};if("replace"!=f)throw new TypeError("Invalid composite mode "+f+".")}else f="easing"==d?a.normalizeEasing(f):""+f;e(d,f,c)}return void 0==c.offset&&(c.offset=null),void 0==c.easing&&(c.easing="linear"),c}),g=!0,h=-1/0,i=0;i<d.length;i++){var j=d[i].offset;if(null!=j){if(j<h)throw new TypeError("Keyframes are not loosely sorted by offset. Sort or specify offsets.");h=j}else g=!1}return d=d.filter(function(a){return a.offset>=0&&a.offset<=1}),g||c(),d}var h={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"]},i=document.createElementNS("http://www.w3.org/1999/xhtml","div"),j={thin:"1px",medium:"3px",thick:"5px"},k={borderBottomWidth:j,borderLeftWidth:j,borderRightWidth:j,borderTopWidth:j,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:j,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.convertToArrayForm=f,a.normalizeKeyframes=g}(c),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),!(g<h&&(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,1))},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,c){function d(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 e(c){var d=[];for(var e in c)for(var f=c[e],g=0;g<f.length-1;g++){var h=g,i=g+1,j=f[h].offset,k=f[i].offset,l=j,m=k;0==g&&(l=-1/0,0==k&&(i=h)),g==f.length-2&&(m=1/0,1==j&&(h=i)),d.push({applyFrom:l,applyTo:m,startOffset:f[h].offset,endOffset:f[i].offset,easingFunction:a.parseEasingFunction(f[h].easing),property:e,interpolation:b.propertyInterpolation(e,f[h].value,f[i].value)})}return d.sort(function(a,b){return a.startOffset-b.startOffset}),d}b.convertEffectInput=function(c){var f=a.normalizeKeyframes(c),g=d(f),h=e(g);return function(a,c){if(null!=c)h.filter(function(a){return c>=a.applyFrom&&c<a.applyTo}).forEach(function(d){var e=c-d.startOffset,f=d.endOffset-d.startOffset,g=0==f?0:d.easingFunction(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),function(a,b,c){function d(a){return a.replace(/-(.)/g,function(a,b){return b.toUpperCase()})}function e(a,b,c){h[c]=h[c]||[],h[c].push([a,b])}function f(a,b,c){for(var f=0;f<c.length;f++){e(a,b,d(c[f]))}}function g(c,e,f){var g=c;/-/.test(c)&&!a.isDeprecated("Hyphenated property names","2016-03-22","Use camelCase instead.",!0)&&(g=d(c)),"initial"!=e&&"initial"!=f||("initial"==e&&(e=i[g]),"initial"==f&&(f=i[g]));for(var j=e==f?[]:h[g],k=0;j&&k<j.length;k++){var l=j[k][0](e),m=j[k][0](f);if(void 0!==l&&void 0!==m){var n=j[k][1](l,m);if(n){var o=b.Interpolation.apply(null,n);return function(a){return 0==a?e:1==a?f:o(a)}}}}return b.Interpolation(!1,!0,function(a){return a?f:e})}var h={};b.addPropertiesHandler=f;var i={backgroundColor:"transparent",backgroundPosition:"0% 0%",borderBottomColor:"currentColor",borderBottomLeftRadius:"0px",borderBottomRightRadius:"0px",borderBottomWidth:"3px",borderLeftColor:"currentColor",borderLeftWidth:"3px",borderRightColor:"currentColor",borderRightWidth:"3px",borderSpacing:"2px",borderTopColor:"currentColor",borderTopLeftRadius:"0px",borderTopRightRadius:"0px",borderTopWidth:"3px",bottom:"auto",clip:"rect(0px, 0px, 0px, 0px)",color:"black",fontSize:"100%",fontWeight:"400",height:"auto",left:"auto",letterSpacing:"normal",lineHeight:"120%",marginBottom:"0px",marginLeft:"0px",marginRight:"0px",marginTop:"0px",maxHeight:"none",maxWidth:"none",minHeight:"0px",minWidth:"0px",opacity:"1.0",outlineColor:"invert",outlineOffset:"0px",outlineWidth:"3px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",paddingTop:"0px",right:"auto",strokeDasharray:"none",strokeDashoffset:"0px",textIndent:"0px",textShadow:"0px 0px 0px transparent",top:"auto",transform:"",verticalAlign:"0px",visibility:"visible",width:"auto",wordSpacing:"normal",zIndex:"auto"};b.propertyInterpolation=g}(c,d),function(a,b,c){function d(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateIterationProgress(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d}b.KeyframeEffect=function(c,e,f,g){var h,i=d(a.normalizeTimingInput(f)),j=b.convertEffectInput(e),k=function(){j(c,h)};return k._update=function(a){return null!==(h=i(a))},k._clear=function(){j(c,null)},k._hasSameTarget=function(a){return c===a},k._target=c,k._totalDuration=i._totalDuration,k._id=g,k}}(c,d),function(a,b){a.apply=function(b,c,d){b.style[a.propertyName(c)]=d},a.clear=function(b,c){b.style[a.propertyName(c)]=""}}(d),function(a){window.Element.prototype.animate=function(b,c){var d="";return c&&c.id&&(d=c.id),a.timeline._play(a.KeyframeEffect(this,b,c,d))}}(d),function(a,b){function c(a,b,d){if("number"==typeof a&&"number"==typeof b)return a*(1-d)+b*d;if("boolean"==typeof a&&"boolean"==typeof b)return d<.5?a:b;if(a.length==b.length){for(var e=[],f=0;f<a.length;f++)e.push(c(a[f],b[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+b}a.Interpolation=function(a,b,d){return function(e){return d(c(a,b,e))}}}(d),function(a,b,c){a.sequenceNumber=0;var d=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()};b.Animation=function(b){this.id="",b&&b._id&&(this.id=b._id),this._sequenceNumber=a.sequenceNumber++,this._currentTime=0,this._startTime=null,this._paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!0,this.onfinish=null,this._finishHandlers=[],this._effect=b,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},b.Animation.prototype={_ensureAlive:function(){this.playbackRate<0&&0===this.currentTime?this._inEffect=this._effect._update(-1):this._inEffect=this._effect._update(this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,b.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this._isFinished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(a){a=+a,isNaN(a)||(b.restart(),this._paused||null==this._startTime||(this._startTime=this._timeline.currentTime-a/this._playbackRate),this._currentTimePending=!1,this._currentTime!=a&&(this._idle&&(this._idle=!1,this._paused=!0),this._tickCurrentTime(a,!0),b.applyDirtiedAnimation(this)))},get startTime(){return this._startTime},set startTime(a){a=+a,isNaN(a)||this._paused||this._idle||(this._startTime=a,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),b.applyDirtiedAnimation(this))},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var c=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&(this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),b.applyDirtiedAnimation(this)),null!=c&&(this.currentTime=c)}},get _isFinished(){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._isFinished?"finished":"running"},_rewind:function(){if(this._playbackRate>=0)this._currentTime=0;else{if(!(this._totalDuration<1/0))throw new DOMException("Unable to rewind negative playback rate animation with infinite duration","InvalidStateError");this._currentTime=this._totalDuration}},play:function(){this._paused=!1,(this._isFinished||this._idle)&&(this._rewind(),this._startTime=null),this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),b.applyDirtiedAnimation(this)},pause:function(){this._isFinished||this._paused||this._idle?this._idle&&(this._rewind(),this._idle=!1):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,b.applyDirtiedAnimation(this))},cancel:function(){this._inEffect&&(this._inEffect=!1,this._idle=!0,this._paused=!1,this._isFinished=!0,this._finishedFlag=!0,this._currentTime=0,this._startTime=null,this._effect._update(null),b.applyDirtiedAnimation(this))},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){if(this._isFinished){if(!this._finishedFlag){var b=new d(this,this._currentTime,a),c=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){c.forEach(function(a){a.call(b.target,b)})},0),this._finishedFlag=!0}}else this._finishedFlag=!1},_tick:function(a,b){this._idle||this._paused||(null==this._startTime?b&&(this.startTime=a-this._currentTime/this.playbackRate):this._isFinished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),b&&(this._currentTimePending=!1,this._fireEvents(a))},get _needsTick(){return this.playState in{pending:1,running:1}||!this._finishedFlag},_targetAnimations:function(){var a=this._effect._target;return a._activeAnimations||(a._activeAnimations=[]),a._activeAnimations},_markTarget:function(){var a=this._targetAnimations();-1===a.indexOf(this)&&a.push(this)},_unmarkTarget:function(){var a=this._targetAnimations(),b=a.indexOf(this);-1!==b&&a.splice(b,1)}}}(c,d),function(a,b,c){function d(a){var b=j;j=[],a<q.currentTime&&(a=q.currentTime),q._animations.sort(e),q._animations=h(a,!0,q._animations)[0],b.forEach(function(b){b[1](a)}),g(),l=void 0}function e(a,b){return a._sequenceNumber-b._sequenceNumber}function f(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function g(){o.forEach(function(a){a()}),o.length=0}function h(a,c,d){p=!0,n=!1,b.timeline.currentTime=a,m=!1;var e=[],f=[],g=[],h=[];return d.forEach(function(b){b._tick(a,c),b._inEffect?(f.push(b._effect),b._markTarget()):(e.push(b._effect),b._unmarkTarget()),b._needsTick&&(m=!0);var d=b._inEffect||b._needsTick;b._inTimeline=d,d?g.push(b):h.push(b)}),o.push.apply(o,e),o.push.apply(o,f),m&&requestAnimationFrame(function(){}),p=!1,[g,h]}var i=window.requestAnimationFrame,j=[],k=0;window.requestAnimationFrame=function(a){var b=k++;return 0==j.length&&i(d),j.push([b,a]),b},window.cancelAnimationFrame=function(a){j.forEach(function(b){b[0]==a&&(b[1]=function(){})})},f.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.applyDirtiedAnimation(d),d}};var l=void 0,m=!1,n=!1;b.restart=function(){return m||(m=!0,requestAnimationFrame(function(){}),n=!0),n},b.applyDirtiedAnimation=function(a){if(!p){a._markTarget();var c=a._targetAnimations();c.sort(e),h(b.timeline.currentTime,!1,c.slice())[1].forEach(function(a){var b=q._animations.indexOf(a);-1!==b&&q._animations.splice(b,1)}),g()}};var o=[],p=!1,q=new f;b.timeline=q}(c,d),function(a){function b(a,b){var c=a.exec(b);if(c)return c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);if(c)return[c[0],c[1].replace(/^\s*/,"")]}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[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++,c<=0))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){return a(c)||[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]}if(""==c)return d}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;k<j;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);if(e&&e[0].length)return[d,e[1]]}function c(c){var d=a.consumeRepeated(b,/^,/,c);if(d&&""==d[1])return d[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,b){function c(a){return a.toFixed(3).replace(/0+$/,"").replace(/\.$/,"")}function d(a,b,c){return Math.min(b,Math.max(a,c))}function e(a){if(/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a))return Number(a)}function f(a,b){return[a,b,c]}function g(a,b){if(0!=a)return i(0,1/0)(a,b)}function h(a,b){return[a,b,function(a){return Math.round(d(1,1/0,a))}]}function i(a,b){return function(e,f){return[e,f,function(e){return c(d(a,b,e))}]}}function j(a){var b=a.trim().split(/\s*[\s,]\s*/);if(0!==b.length){for(var c=[],d=0;d<b.length;d++){var f=e(b[d]);if(void 0===f)return;c.push(f)}return c}}function k(a,b){if(a.length==b.length)return[a,b,function(a){return a.map(c).join(" ")}]}function l(a,b){return[a,b,Math.round]}a.clamp=d,a.addPropertiesHandler(j,k,["stroke-dasharray"]),a.addPropertiesHandler(e,i(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(e,i(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(e,g,["flex-grow","flex-shrink"]),a.addPropertiesHandler(e,h,["orphans","widows"]),a.addPropertiesHandler(e,l,["z-index"]),a.parseNumber=e,a.parseNumberList=j,a.mergeNumbers=f,a.numberToString=c}(d),function(a,b){function c(a,b){if("visible"==a||"visible"==b)return[0,1,function(c){return c<=0?a:c>=1?b:"visible"}]}a.addPropertiesHandler(String,c,["visibility"])}(d),function(a,b){function c(a){a=a.trim(),f.fillStyle="#000",f.fillStyle=a;var b=f.fillStyle;if(f.fillStyle="#fff",f.fillStyle=a,b==f.fillStyle){f.fillRect(0,0,1,1);var c=f.getImageData(0,0,1,1).data;f.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function d(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;d<3;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 e=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");e.width=e.height=1;var f=e.getContext("2d");a.addPropertiesHandler(c,d,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","fill","flood-color","lighting-color","outline-color","stop-color","stroke","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,c),a.mergeColors=d}(d),function(a,b){function c(a){function b(){var b=h.exec(a);g=b?b[0]:void 0}function c(){var a=Number(g);return b(),a}function d(){if("("!==g)return c();b();var a=f();return")"!==g?NaN:(b(),a)}function e(){for(var a=d();"*"===g||"/"===g;){var c=g;b();var e=d();"*"===c?a*=e:a/=e}return a}function f(){for(var a=e();"+"===g||"-"===g;){var c=g;b();var d=e();"+"===c?a+=d:a-=d}return a}var g,h=/([\+\-\w\.]+|[\(\)\*\/])/g;return b(),f()}function d(a,b){if("0"==(b=b.trim().toLowerCase())&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var d={};b=b.replace(a,function(a){return d[a]=null,"U"+a});for(var e="U("+a.source+")",f=b.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g,"N").replace(new RegExp("N"+e,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),g=[/N\*(D)/g,/(N|D)[*\/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],h=0;h<g.length;)g[h].test(f)?(f=f.replace(g[h],"$1"),h=0):h++;if("D"==f){for(var i in d){var j=c(b.replace(new RegExp("U"+i,"g"),"").replace(new RegExp(e,"g"),"*0"));if(!isFinite(j))return;d[i]=j}return d}}}function e(a,b){return f(a,b,!0)}function f(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 g="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",h=d.bind(null,new RegExp(g,"g")),i=d.bind(null,new RegExp(g+"|%","g")),j=d.bind(null,/deg|rad|grad|turn/g);a.parseLength=h,a.parseLengthOrPercent=i,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,i),a.parseAngle=j,a.mergeDimensions=f;var k=a.consumeParenthesised.bind(null,h),l=a.consumeRepeated.bind(void 0,k,/^/),m=a.consumeRepeated.bind(void 0,l,/^,/);a.consumeSizePairList=m;var n=function(a){var b=m(a);if(b&&""==b[1])return b[0]},o=a.mergeNestedRepeated.bind(void 0,e," "),p=a.mergeNestedRepeated.bind(void 0,o,",");a.mergeNonNegativeSizePair=o,a.addPropertiesHandler(n,p,["background-size"]),a.addPropertiesHandler(i,e,["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(i,f,["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","stroke-dashoffset","text-indent","top","vertical-align","word-spacing"])}(d),function(a,b){function c(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function d(b){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,c,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],b);if(d&&4==d[0].length)return d[0]}function e(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 f(a){return"rect("+a+")"}var g=a.mergeWrappedNestedRepeated.bind(null,f,e,", ");a.parseBox=d,a.mergeBoxes=g,a.addPropertiesHandler(d,g,["clip"])}(d),function(a,b){function c(a){return function(b){var c=0;return a.map(function(a){return a===k?b[c++]:a})}}function d(a){return a}function e(b){if("none"==(b=b.toLowerCase().trim()))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=n[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var k=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(void 0===(p=q?{A:function(b){return"0"==b.trim()?m:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:m,n:k[0],t:l}[r]))return;k.push(p)}if(e.push({t:g,d:k}),d.lastIndex==b.length)return e}}function f(a){return a.toFixed(6).replace(".000000","")}function g(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var e=a.makeMatrixDecomposition(c)}return null==d[0]||null==e[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),e[0].push(1),[d,e,function(b){var c=a.quat(d[0][3],e[0][3],b[5]);return a.composeMatrix(b[0],b[1],b[2],c,b[4]).map(f).join(",")}])}function h(a){return a.replace(/[xy]/,"")}function i(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function j(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var f=0;f<b.length;f++){var j=b[f].t,k=b[f].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 m=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=g(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var f=0;f<b.length;f++){var j,s=b[f].t,t=c[f].t,u=b[f].d,v=c[f].d,w=n[s],x=n[t];if(m(s,t)){if(!d)return;var r=g([b[f]],[c[f]]);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]&&h(s)==h(t))j=h(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||i(s)!=i(t)){if(!d)return;var r=g(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=i(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 k=null,l={px:0},m={deg:0},n={matrix:["NNNNNN",[k,k,0,0,k,k,0,0,0,0,1,0,k,k,0,1],d],matrix3d:["NNNNNNNNNNNNNNNN",d],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",c([k,k,1]),d],scalex:["N",c([k,1,1]),c([k,1])],scaley:["N",c([1,k,1]),c([1,k])],scalez:["N",c([1,1,k])],scale3d:["NNN",d],skew:["Aa",null,d],skewx:["A",null,c([k,m])],skewy:["A",null,c([m,k])],translate:["Tt",c([k,k,l]),d],translatex:["T",c([k,l,l]),c([k,l])],translatey:["T",c([l,k,l]),c([l,k])],translatez:["L",c([l,l,k])],translate3d:["TTL",d]};a.addPropertiesHandler(e,j,["transform"]),a.transformToSvgMatrix=function(b){var c=a.transformListToMatrix(e(b));return"matrix("+f(c[0])+" "+f(c[1])+" "+f(c[4])+" "+f(c[5])+" "+f(c[12])+" "+f(c[13])+")"}}(d),function(a,b){function c(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(d[a]=b),e[b]=a})}var d={},e={};c("transform",["webkitTransform","msTransform"]),c("transformOrigin",["webkitTransformOrigin"]),c("perspective",["webkitPerspective"]),c("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return d[a]||a},a.unprefixedPropertyName=function(a){return e[a]||a}}(d)}(),function(){if(void 0===document.createElement("div").animate([]).oncancel){var a;if(window.performance&&performance.now)var a=function(){return performance.now()};else var a=function(){return Date.now()};var b=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="cancel",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()},c=window.Element.prototype.animate;window.Element.prototype.animate=function(d,e){var f=c.call(this,d,e);f._cancelHandlers=[],f.oncancel=null;var g=f.cancel;f.cancel=function(){g.call(this);var c=new b(this,null,a()),d=this._cancelHandlers.concat(this.oncancel?[this.oncancel]:[]);setTimeout(function(){d.forEach(function(a){a.call(c.target,c)})},0)};var h=f.addEventListener;f.addEventListener=function(a,b){"function"==typeof b&&"cancel"==a?this._cancelHandlers.push(b):h.call(this,a,b)};var i=f.removeEventListener;return f.removeEventListener=function(a,b){if("cancel"==a){var c=this._cancelHandlers.indexOf(b);c>=0&&this._cancelHandlers.splice(c,1)}else i.call(this,a,b)},f}}}(),function(a){var b=document.documentElement,c=null,d=!1;try{var e=getComputedStyle(b).getPropertyValue("opacity"),f="0"==e?"1":"0";c=b.animate({opacity:[f,f]},{duration:1}),c.currentTime=0,d=getComputedStyle(b).getPropertyValue("opacity")==f}catch(a){}finally{c&&c.cancel()}if(!d){var g=window.Element.prototype.animate;window.Element.prototype.animate=function(b,c){return window.Symbol&&Symbol.iterator&&Array.prototype.from&&b[Symbol.iterator]&&(b=Array.from(b)),Array.isArray(b)||null===b||(b=a.convertToArrayForm(b)),g.call(this,b,c)}}}(c),function(a,b,c){function d(a){var c=b.timeline;c.currentTime=a,c._discardAnimations(),0==c._animations.length?f=!1:requestAnimationFrame(d)}var e=window.requestAnimationFrame;window.requestAnimationFrame=function(a){return e(function(c){b.timeline._updateAnimationsPromises(),a(c),b.timeline._updateAnimationsPromises()})},b.AnimationTimeline=function(){this._animations=[],this.currentTime=void 0},b.AnimationTimeline.prototype={getAnimations:function(){return this._discardAnimations(),this._animations.slice()},_updateAnimationsPromises:function(){b.animationsWithPromises=b.animationsWithPromises.filter(function(a){return a._updatePromises()})},_discardAnimations:function(){this._updateAnimationsPromises(),this._animations=this._animations.filter(function(a){return"finished"!=a.playState&&"idle"!=a.playState})},_play:function(a){var c=new b.Animation(a,this);return this._animations.push(c),b.restartWebAnimationsNextTick(),c._updatePromises(),c._animation.play(),c._updatePromises(),c},play:function(a){return a&&a.remove(),this._play(a)}};var f=!1;b.restartWebAnimationsNextTick=function(){f||(f=!0,requestAnimationFrame(d))};var g=new b.AnimationTimeline;b.timeline=g;try{Object.defineProperty(window.document,"timeline",{configurable:!0,get:function(){return g}})}catch(a){}try{window.document.timeline=g}catch(a){}}(0,e),function(a,b,c){b.animationsWithPromises=[],b.Animation=function(b,c){if(this.id="",b&&b._id&&(this.id=b._id),this.effect=b,b&&(b._animation=this),!c)throw new Error("Animation with null timeline is not supported");this._timeline=c,this._sequenceNumber=a.sequenceNumber++,this._holdTime=0,this._paused=!1,this._isGroup=!1,this._animation=null,this._childAnimations=[],this._callback=null,this._oldPlayState="idle",this._rebuildUnderlyingAnimation(),this._animation.cancel(),this._updatePromises()},b.Animation.prototype={_updatePromises:function(){var a=this._oldPlayState,b=this.playState;return this._readyPromise&&b!==a&&("idle"==b?(this._rejectReadyPromise(),this._readyPromise=void 0):"pending"==a?this._resolveReadyPromise():"pending"==b&&(this._readyPromise=void 0)),this._finishedPromise&&b!==a&&("idle"==b?(this._rejectFinishedPromise(),this._finishedPromise=void 0):"finished"==b?this._resolveFinishedPromise():"finished"==a&&(this._finishedPromise=void 0)),this._oldPlayState=this.playState,this._readyPromise||this._finishedPromise},_rebuildUnderlyingAnimation:function(){this._updatePromises();var a,c,d,e,f=!!this._animation;f&&(a=this.playbackRate,c=this._paused,d=this.startTime,e=this.currentTime,this._animation.cancel(),this._animation._wrapper=null,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)),this.effect&&this.effect._onsample&&b.bindAnimationForCustomEffect(this),f&&(1!=a&&(this.playbackRate=a),null!==d?this.startTime=d:null!==e?this.currentTime=e:null!==this._holdTime&&(this.currentTime=this._holdTime),c&&this.pause()),this._updatePromises()},_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)},_constructChildAnimations:function(){if(this.effect&&this._isGroup){var a=this.effect._timing.delay;this._removeChildAnimations(),this.effect.children.forEach(function(c){var d=b.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!==this.startTime+b/this.playbackRate&&(a.startTime=this.startTime+b/this.playbackRate)},get timeline(){return this._timeline},get playState(){return this._animation?this._animation.playState:"idle"},get finished(){return window.Promise?(this._finishedPromise||(-1==b.animationsWithPromises.indexOf(this)&&b.animationsWithPromises.push(this),this._finishedPromise=new Promise(function(a,b){this._resolveFinishedPromise=function(){a(this)},this._rejectFinishedPromise=function(){b({type:DOMException.ABORT_ERR,name:"AbortError"})}}.bind(this)),"finished"==this.playState&&this._resolveFinishedPromise()),this._finishedPromise):(console.warn("Animation Promises require JavaScript Promise constructor"),null)},get ready(){return window.Promise?(this._readyPromise||(-1==b.animationsWithPromises.indexOf(this)&&b.animationsWithPromises.push(this),this._readyPromise=new Promise(function(a,b){this._resolveReadyPromise=function(){a(this)},this._rejectReadyPromise=function(){b({type:DOMException.ABORT_ERR,name:"AbortError"})}}.bind(this)),"pending"!==this.playState&&this._resolveReadyPromise()),this._readyPromise):(console.warn("Animation Promises require JavaScript Promise constructor"),null)},get onfinish(){return this._animation.onfinish},set onfinish(a){this._animation.onfinish="function"==typeof a?function(b){b.target=this,a.call(this,b)}.bind(this):a},get oncancel(){return this._animation.oncancel},set oncancel(a){this._animation.oncancel="function"==typeof a?function(b){b.target=this,a.call(this,b)}.bind(this):a},get currentTime(){this._updatePromises();var a=this._animation.currentTime;return this._updatePromises(),a},set currentTime(a){this._updatePromises(),this._animation.currentTime=isFinite(a)?a:Math.sign(a)*Number.MAX_VALUE,this._register(),this._forEachChild(function(b,c){b.currentTime=a-c}),this._updatePromises()},get startTime(){return this._animation.startTime},set startTime(a){this._updatePromises(),this._animation.startTime=isFinite(a)?a:Math.sign(a)*Number.MAX_VALUE,this._register(),this._forEachChild(function(b,c){b.startTime=a+c}),this._updatePromises()},get playbackRate(){return this._animation.playbackRate},set playbackRate(a){this._updatePromises();var b=this.currentTime;this._animation.playbackRate=a,this._forEachChild(function(b){b.playbackRate=a}),null!==b&&(this.currentTime=b),this._updatePromises()},play:function(){this._updatePromises(),this._paused=!1,this._animation.play(),-1==this._timeline._animations.indexOf(this)&&this._timeline._animations.push(this),this._register(),b.awaitStartTime(this),this._forEachChild(function(a){var b=a.currentTime;a.play(),a.currentTime=b}),this._updatePromises()},pause:function(){this._updatePromises(),this.currentTime&&(this._holdTime=this.currentTime),this._animation.pause(),this._register(),this._forEachChild(function(a){a.pause()}),this._paused=!0,this._updatePromises()},finish:function(){this._updatePromises(),this._animation.finish(),this._register(),this._updatePromises()},cancel:function(){this._updatePromises(),this._animation.cancel(),this._register(),this._removeChildAnimations(),this._updatePromises()},reverse:function(){this._updatePromises();var a=this.currentTime;this._animation.reverse(),this._forEachChild(function(a){a.reverse()}),null!==a&&(this.currentTime=a),this._updatePromises()},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)},_removeChildAnimations: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._constructChildAnimations(),this._childAnimations.forEach(function(a){b.call(this,a,c),this.effect instanceof window.SequenceEffect&&(c+=a.effect.activeDuration)}.bind(this)),"pending"!=this.playState){var d=this.effect._timing,e=this.currentTime;null!==e&&(e=a.calculateIterationProgress(a.calculateActiveDuration(d),e,d)),(null==e||isNaN(e))&&this._removeChildAnimations()}}},window.Animation=b.Animation}(c,e),function(a,b,c){function d(b){this._frames=a.normalizeKeyframes(b)}function e(){for(var a=!1;i.length;)i.shift()._updateChildren(),a=!0;return a}var f=function(a){if(a._animation=void 0,a instanceof window.SequenceEffect||a instanceof window.GroupEffect)for(var b=0;b<a.children.length;b++)f(a.children[b])};b.removeMulti=function(a){for(var b=[],c=0;c<a.length;c++){var d=a[c];d._parent?(-1==b.indexOf(d._parent)&&b.push(d._parent),d._parent.children.splice(d._parent.children.indexOf(d),1),d._parent=null,f(d)):d._animation&&d._animation.effect==d&&(d._animation.cancel(),d._animation.effect=new KeyframeEffect(null,[]),d._animation._callback&&(d._animation._callback._animation=null),d._animation._rebuildUnderlyingAnimation(),f(d))}for(c=0;c<b.length;c++)b[c]._rebuild()},b.KeyframeEffect=function(b,c,e,f){return this.target=b,this._parent=null,e=a.numericTimingToObject(e),this._timingInput=a.cloneTimingInput(e),this._timing=a.normalizeTimingInput(e),this.timing=a.makeTiming(e,!1,this),this.timing._effect=this,"function"==typeof c?(a.deprecated("Custom KeyframeEffect","2015-06-22","Use KeyframeEffect.onsample instead."),this._normalizedKeyframes=c):this._normalizedKeyframes=new d(c),this._keyframes=c,this.activeDuration=a.calculateActiveDuration(this._timing),this._id=f,this},b.KeyframeEffect.prototype={getFrames:function(){return"function"==typeof this._normalizedKeyframes?this._normalizedKeyframes:this._normalizedKeyframes._frames},set onsample(a){if("function"==typeof this.getFrames())throw new Error("Setting onsample on custom effect KeyframeEffect is not supported.");this._onsample=a,this._animation&&this._animation._rebuildUnderlyingAnimation()},get parent(){return this._parent},clone:function(){if("function"==typeof this.getFrames())throw new Error("Cloning custom effects is not supported.");var b=new KeyframeEffect(this.target,[],a.cloneTimingInput(this._timingInput),this._id);return b._normalizedKeyframes=this._normalizedKeyframes,b._keyframes=this._keyframes,b},remove:function(){b.removeMulti([this])}};var g=Element.prototype.animate;Element.prototype.animate=function(a,c){var d="";return c&&c.id&&(d=c.id),b.timeline._play(new b.KeyframeEffect(this,a,c,d))};var h=document.createElementNS("http://www.w3.org/1999/xhtml","div");b.newUnderlyingAnimationForKeyframeEffect=function(a){if(a){var b=a.target||h,c=a._keyframes;"function"==typeof c&&(c=[]);var d=a._timingInput;d.id=a._id}else var b=h,c=[],d=0;return g.apply(b,[c,d])},b.bindAnimationForKeyframeEffect=function(a){a.effect&&"function"==typeof a.effect._normalizedKeyframes&&b.bindAnimationForCustomEffect(a)};var i=[];b.awaitStartTime=function(a){null===a.startTime&&a._isGroup&&(0==i.length&&requestAnimationFrame(e),i.push(a))};var j=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){b.timeline._updateAnimationsPromises();var a=j.apply(this,arguments);return e()&&(a=j.apply(this,arguments)),b.timeline._updateAnimationsPromises(),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))}}(c,e),function(a,b,c){function d(a){a._registered||(a._registered=!0,g.push(a),h||(h=!0,requestAnimationFrame(e)))}function e(a){var b=g;g=[],b.sort(function(a,b){return a._sequenceNumber-b._sequenceNumber}),b=b.filter(function(a){a();var b=a._animation?a._animation.playState:"idle";return"running"!=b&&"pending"!=b&&(a._registered=!1),a._registered}),g.push.apply(g,b),g.length?(h=!0,requestAnimationFrame(e)):h=!1}var f=(document.createElementNS("http://www.w3.org/1999/xhtml","div"),0);b.bindAnimationForCustomEffect=function(b){var c,e=b.effect.target,g="function"==typeof b.effect.getFrames();c=g?b.effect.getFrames():b.effect._onsample;var h=b.effect.timing,i=null;h=a.normalizeTimingInput(h);var j=function(){var d=j._animation?j._animation.currentTime:null;null!==d&&(d=a.calculateIterationProgress(a.calculateActiveDuration(h),d,h),isNaN(d)&&(d=null)),d!==i&&(g?c(d,e,b.effect):c(d,b.effect,b.effect._animation)),i=d};j._animation=b,j._registered=!1,j._sequenceNumber=f++,b._callback=j,d(j)};var g=[],h=!1;b.Animation.prototype._register=function(){this._callback&&d(this._callback)}}(c,e),function(a,b,c){function d(a){return a._timing.delay+a.activeDuration+a._timing.endDelay}function e(b,c,d){this._id=d,this._parent=null,this.children=b||[],this._reparent(this.children),c=a.numericTimingToObject(c),this._timingInput=a.cloneTimingInput(c),this._timing=a.normalizeTimingInput(c,!0),this.timing=a.makeTiming(c,!0,this),this.timing._effect=this,"auto"===this._timing.duration&&(this._timing.duration=this.activeDuration)}window.SequenceEffect=function(){e.apply(this,arguments)},window.GroupEffect=function(){e.apply(this,arguments)},e.prototype={_isAncestor:function(a){for(var b=this;null!==b;){if(b==a)return!0;b=b._parent}return!1},_rebuild:function(){for(var a=this;a;)"auto"===a.timing.duration&&(a._timing.duration=a.activeDuration),a=a._parent;this._animation&&this._animation._rebuildUnderlyingAnimation()},_reparent:function(a){b.removeMulti(a);for(var c=0;c<a.length;c++)a[c]._parent=this},_putChild:function(a,b){for(var c=b?"Cannot append an ancestor or self":"Cannot prepend an ancestor or self",d=0;d<a.length;d++)if(this._isAncestor(a[d]))throw{type:DOMException.HIERARCHY_REQUEST_ERR,name:"HierarchyRequestError",message:c};for(var d=0;d<a.length;d++)b?this.children.push(a[d]):this.children.unshift(a[d]);this._reparent(a),this._rebuild()},append:function(){this._putChild(arguments,!0)},prepend:function(){this._putChild(arguments,!1)},get parent(){return this._parent},get firstChild(){return this.children.length?this.children[0]:null},get lastChild(){return this.children.length?this.children[this.children.length-1]:null},clone:function(){for(var b=a.cloneTimingInput(this._timingInput),c=[],d=0;d<this.children.length;d++)c.push(this.children[d].clone());return this instanceof GroupEffect?new GroupEffect(c,b):new SequenceEffect(c,b)},remove:function(){b.removeMulti([this])}},window.SequenceEffect.prototype=Object.create(e.prototype),Object.defineProperty(window.SequenceEffect.prototype,"activeDuration",{get:function(){var a=0;return this.children.forEach(function(b){a+=d(b)}),Math.max(a,0)}}),window.GroupEffect.prototype=Object.create(e.prototype),Object.defineProperty(window.GroupEffect.prototype,"activeDuration",{get:function(){var a=0;return this.children.forEach(function(b){a=Math.max(a,d(b))}),a}}),b.newUnderlyingAnimationForGroup=function(c){var d,e=null,f=function(b){var c=d._wrapper;if(c&&"pending"!=c.playState&&c.effect)return null==b?void c._removeChildAnimations():0==b&&c.playbackRate<0&&(e||(e=a.normalizeTimingInput(c.effect.timing)),b=a.calculateIterationProgress(a.calculateActiveDuration(e),-1,e),isNaN(b)||null==b)?(c._forEachChild(function(a){a.currentTime=-1}),void c._removeChildAnimations()):void 0},g=new KeyframeEffect(null,[],c._timing,c._id);return g.onsample=f,d=b.timeline._play(g)},b.bindAnimationForGroup=function(a){a._animation._wrapper=a,a._isGroup=!0,b.awaitStartTime(a),a._constructChildAnimations(),a._setExternalAnimation(a)},b.groupChildDuration=d}(c,e),b.true=a}({},function(){return this}());
+//# sourceMappingURL=web-animations-next-lite.min.js.map \ No newline at end of file
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js.map b/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js.map
new file mode 100644
index 00000000..2234d482
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations-next-lite.min.js.map
@@ -0,0 +1 @@
+{"version":3,"sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/web-animations-bonus-cancel-events.js","src/web-animations-bonus-object-form-keyframes.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","shared","testing","cloneTimingInput","timingInput","clone","m","AnimationEffectTiming","this","_delay","_endDelay","_fill","_iterationStart","_iterations","_duration","_playbackRate","_direction","_easing","_easingFunction","linear","isInvalidTimingDeprecated","isDeprecated","makeTiming","forGroup","effect","timing","fill","duration","isNaN","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","numericTimingToObject","normalizeTimingInput","cubic","a","b","c","d","x","f","start_gradient","end_gradient","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","normalizeEasing","easing","styleForCleaning","document","createElement","style","animationTimingFunction","normalizedEasing","TypeError","parseEasingFunction","cubicData","cubicBezierRe","exec","apply","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","presets","calculateActiveDuration","repeatedDuration","playbackRate","iterations","calculatePhase","activeDuration","localTime","PhaseNone","endTime","delay","endDelay","min","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateOverallProgress","iterationDuration","activeTime","iterationStart","overallProgress","calculateSimpleIterationProgress","simpleIterationProgress","Infinity","calculateCurrentIteration","floor","calculateDirectedProgress","playbackDirection","currentIteration","currentDirection","calculateIterationProgress","directedProgress","direction","split","prototype","_setMember","member","value","_effect","_timingInput","_timing","_animation","_rebuildUnderlyingAnimation","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","aliases","isNotAnimatable","lastIndexOf","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","i","longProperty","longhandValue","convertToArrayForm","effectInput","normalizedEffectInput","values","Array","isArray","keyframe","numKeyframes","length","offset","composite","push","sort","normalizeKeyframes","spaceKeyframes","keyframes","previousIndex","previousOffset","j","window","Symbol","iterator","from","originalKeyframe","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","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","animate","oncancel","now","performance","AnimationCancelEvent","target","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","originalElementAnimate","Element","options","animation","call","_cancelHandlers","originalCancel","cancel","event","handlers","concat","setTimeout","handler","originalAddEventListener","addEventListener","originalRemoveEventListener","removeEventListener","index","splice","element","documentElement","animated","originalOpacity","getComputedStyle","getPropertyValue","testOpacity","opacity","error","scope","webAnimationsNextTick","t","timeline","_discardAnimations","_animations","ticking","requestAnimationFrame","originalRequestAnimationFrame","_updateAnimationsPromises","AnimationTimeline","getAnimations","animationsWithPromises","_updatePromises","playState","_play","Animation","restartWebAnimationsNextTick","play","remove","defineProperty","configurable","get","e","id","_id","_timeline","_sequenceNumber","sequenceNumber","_holdTime","_paused","_isGroup","_childAnimations","_callback","_oldPlayState","oldPlayState","newPlayState","_readyPromise","_rejectReadyPromise","_resolveReadyPromise","_finishedPromise","_rejectFinishedPromise","_resolveFinishedPromise","oldPlaybackRate","oldPaused","oldStartTime","oldCurrentTime","hadUnderlying","startTime","_wrapper","KeyframeEffect","newUnderlyingAnimationForKeyframeEffect","bindAnimationForKeyframeEffect","SequenceEffect","GroupEffect","newUnderlyingAnimationForGroup","bindAnimationForGroup","_onsample","bindAnimationForCustomEffect","pause","_updateChildren","childAnimation","_arrangeChildren","groupChildDuration","bind","_setExternalAnimation","children","_constructChildAnimations","_removeChildAnimations","child","finished","Promise","resolve","reject","ABORT_ERR","ready","onfinish","v","sign","MAX_VALUE","_register","_forEachChild","awaitStartTime","time","finish","reverse","wrapped","pop","KeyframeList","_frames","updatePendingGroups","updated","pendingGroups","shift","disassociate","removeMulti","effects","oldParents","_parent","_rebuild","_normalizedKeyframes","_keyframes","getFrames","onsample","callback","parent","nullTarget","keyframeEffect","groupAnimation","originalGetComputedStyle","enumerable","arguments","register","_registered","callbacks","tick","updating","left","right","effectFunction","isKeyframeEffect","last","node","constructor","_reparent","_isAncestor","newChildren","_putChild","args","isAppend","HIERARCHY_REQUEST_ERR","unshift","append","prepend","firstChild","lastChild","clonedTiming","clonedChildren","create","total","max","group","underlyingAnimation","ticker","tf","underlyingEffect","exports","webAnimationsTesting"],"mappings":";;;;;;;;;;;;;;CAcA,SAAIA,EAAAA,GAAJ,GAAIA,MACAC,KACAC,MCFJ,SAAUC,EAAQC,GAMhB,QAASC,GAAiBC,GACxB,GAA0B,gBAAfA,GACT,MAAOA,EAET,IAAIC,KACJ,KAAK,GAAIC,KAAKF,GACZC,EAAMC,GAAKF,EAAYE,EAEzB,OAAOD,GAGT,QAASE,KACPC,KAAKC,OAAS,EACdD,KAAKE,UAAY,EACjBF,KAAKG,MAAQ,OACbH,KAAKI,gBAAkB,EACvBJ,KAAKK,YAAc,EACnBL,KAAKM,UAAY,EACjBN,KAAKO,cAAgB,EACrBP,KAAKQ,WAAa,SAClBR,KAAKS,QAAU,SACfT,KAAKU,gBAAkBC,EAGzB,QAASC,KACP,MAAOnB,GAAOoB,aAAa,wBAAyB,aAAc,gDAAA,GA8EpE,QAASC,GAAWlB,EAAamB,EAAUC,GACzC,GAAIC,GAAS,GAAIlB,EA4BjB,OA3BIgB,KACFE,EAAOC,KAAO,OACdD,EAAOE,SAAW,QAEM,gBAAfvB,IAA4BwB,MAAMxB,OAAAA,KAElCA,GACTyB,OAAOC,oBAAoB1B,GAAa2B,QAAQ,SAASC,GACvD,GAA6B,QAAzB5B,EA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QAASuS,EAAMpH,IAGzE,OAFAwH,GAAiB1C,SAAWwC,EAC5BD,EAAsB9I,EAAMG,SAASY,MAAMkI,IAI7CjJ,EAAMwD,sBAAwB,SAASjF,GACrCA,EAAUhI,WAAW0M,SAAW1E,EAChCA,EAAUwD,UAAAA,EACV/B,EAAMkF,eAAe3G,GACrBA,EAAU4F,4BACV5F,EAAU0F,sBAAsB1F,IAGlCyB,EAAM+D,mBAAqBA,GAE1BtV,EAAqBE,GV3LpBA,EAAAA,KAEJua,MACMC,WAAAA,MAAuBha","file":"web-animations-next-lite.min.js"} \ No newline at end of file
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.html b/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.html
new file mode 100644
index 00000000..536e092d
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.html
@@ -0,0 +1 @@
+<script src="./web-animations-next.min.js"></script>
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js b/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js
new file mode 100644
index 00000000..99e293f4
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js
@@ -0,0 +1,16 @@
+// 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){var c={},d={},e={};!function(a,b){function c(a){if("number"==typeof a)return a;var b={};for(var c in a)b[c]=a[c];return b}function d(){this._delay=0,this._endDelay=0,this._fill="none",this._iterationStart=0,this._iterations=1,this._duration=0,this._playbackRate=1,this._direction="normal",this._easing="linear",this._easingFunction=x}function e(){return a.isDeprecated("Invalid timing inputs","2016-03-02","TypeError exceptions will be thrown instead.",!0)}function f(b,c,e){var f=new d;return c&&(f.fill="both",f.duration="auto"),"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof f[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==v.indexOf(b[c]))return;if("direction"==c&&-1==w.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;f[c]=b[c]}}):f.duration=b,f}function g(a){return"number"==typeof a&&(a=isNaN(a)?{duration:0}:{duration:a}),a}function h(b,c){return b=a.numericTimingToObject(b),f(b,c)}function i(a,b,c,d){return a<0||a>1||c<0||c>1?x:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}if(e<=0){var g=0;return a>0?g=b/a:!b&&c>0&&(g=d/c),g*e}if(e>=1){var h=0;return c<1?h=(d-1)/(c-1):1==c&&a<1&&(h=(b-1)/(a-1)),1+h*(e-1)}for(var i=0,j=1;i<j;){var k=(i+j)/2,l=f(a,c,k);if(Math.abs(e-l)<1e-5)return f(b,d,k);l<e?i=k:j=k}return f(b,d,k)}}function j(a,b){return function(c){if(c>=1)return 1;var d=1/a;return(c+=b*d)-c%d}}function k(a){C||(C=document.createElement("div").style),C.animationTimingFunction="",C.animationTimingFunction=a;var b=C.animationTimingFunction;if(""==b&&e())throw new TypeError(a+" is not a valid value for easing");return b}function l(a){if("linear"==a)return x;var b=E.exec(a);if(b)return i.apply(this,b.slice(1).map(Number));var c=F.exec(a);return c?j(Number(c[1]),{start:y,middle:z,end:A}[c[2]]):B[a]||x}function m(a){return Math.abs(n(a)/a.playbackRate)}function n(a){return 0===a.duration||0===a.iterations?0:a.duration*a.iterations}function o(a,b,c){if(null==b)return G;var d=c.delay+a+c.endDelay;return b<Math.min(c.delay,d)?H:b>=Math.min(c.delay+a,d)?I:J}function p(a,b,c,d,e){switch(d){case H:return"backwards"==b||"both"==b?0:null;case J:return c-e;case I:return"forwards"==b||"both"==b?a:null;case G:return null}}function q(a,b,c,d,e){var f=e;return 0===a?b!==H&&(f+=c):f+=d/a,f}function r(a,b,c,d,e,f){var g=a===1/0?b%1:a%1;return 0!==g||c!==I||0===d||0===e&&0!==f||(g=1),g}function s(a,b,c,d){return a===I&&b===1/0?1/0:1===c?Math.floor(d)-1:Math.floor(d)}function t(a,b,c){var d=a;if("normal"!==a&&"reverse"!==a){var e=b;"alternate-reverse"===a&&(e+=1),d="normal",e!==1/0&&e%2!=0&&(d="reverse")}return"normal"===d?c:1-c}function u(a,b,c){var d=o(a,b,c),e=p(a,c.fill,b,d,c.delay);if(null===e)return null;var f=q(c.duration,d,c.iterations,e,c.iterationStart),g=r(f,c.iterationStart,d,c.iterations,e,c.duration),h=s(d,c.iterations,g,f),i=t(c.direction,h,g);return c._easingFunction(i)}var v="backwards|forwards|both|none".split("|"),w="reverse|alternate|alternate-reverse".split("|"),x=function(a){return a};d.prototype={_setMember:function(b,c){this["_"+b]=c,this._effect&&(this._effect._timingInput[b]=c,this._effect._timing=a.normalizeTimingInput(this._effect._timingInput),this._effect.activeDuration=a.calculateActiveDuration(this._effect._timing),this._effect._animation&&this._effect._animation._rebuildUnderlyingAnimation())},get playbackRate(){return this._playbackRate},set delay(a){this._setMember("delay",a)},get delay(){return this._delay},set endDelay(a){this._setMember("endDelay",a)},get endDelay(){return this._endDelay},set fill(a){this._setMember("fill",a)},get fill(){return this._fill},set iterationStart(a){if((isNaN(a)||a<0)&&e())throw new TypeError("iterationStart must be a non-negative number, received: "+timing.iterationStart);this._setMember("iterationStart",a)},get iterationStart(){return this._iterationStart},set duration(a){if("auto"!=a&&(isNaN(a)||a<0)&&e())throw new TypeError("duration must be non-negative or auto, received: "+a);this._setMember("duration",a)},get duration(){return this._duration},set direction(a){this._setMember("direction",a)},get direction(){return this._direction},set easing(a){this._easingFunction=l(k(a)),this._setMember("easing",a)},get easing(){return this._easing},set iterations(a){if((isNaN(a)||a<0)&&e())throw new TypeError("iterations must be non-negative, received: "+a);this._setMember("iterations",a)},get iterations(){return this._iterations}};var y=1,z=.5,A=0,B={ease:i(.25,.1,.25,1),"ease-in":i(.42,0,1,1),"ease-out":i(0,0,.58,1),"ease-in-out":i(.42,0,.58,1),"step-start":j(1,y),"step-middle":j(1,z),"step-end":j(1,A)},C=null,D="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",E=new RegExp("cubic-bezier\\("+D+","+D+","+D+","+D+"\\)"),F=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,G=0,H=1,I=2,J=3;a.cloneTimingInput=c,a.makeTiming=f,a.numericTimingToObject=g,a.normalizeTimingInput=h,a.calculateActiveDuration=m,a.calculateIterationProgress=u,a.calculatePhase=o,a.normalizeEasing=k,a.parseEasingFunction=l}(c),function(a,b){function c(a,b){return a in k?k[a][b]||b:b}function d(a){return"display"===a||0===a.lastIndexOf("animation",0)||0===a.lastIndexOf("transition",0)}function e(a,b,e){if(!d(a)){var f=h[a];if(f){i.style[a]=b;for(var g in f){var j=f[g],k=i.style[j];e[j]=c(j,k)}}else e[a]=c(a,b)}}function f(a){var b=[];for(var c in a)if(!(c in["easing","offset","composite"])){var d=a[c];Array.isArray(d)||(d=[d]);for(var e,f=d.length,g=0;g<f;g++)e={},e.offset="offset"in a?a.offset:1==f?1:g/(f-1),"easing"in a&&(e.easing=a.easing),"composite"in a&&(e.composite=a.composite),e[c]=d[g],b.push(e)}return b.sort(function(a,b){return a.offset-b.offset}),b}function g(b){function c(){var a=d.length;null==d[a-1].offset&&(d[a-1].offset=1),a>1&&null==d[0].offset&&(d[0].offset=0);for(var b=0,c=d[0].offset,e=1;e<a;e++){var f=d[e].offset;if(null!=f){for(var g=1;g<e-b;g++)d[b+g].offset=c+(f-c)*g/(e-b);b=e,c=f}}}if(null==b)return[];window.Symbol&&Symbol.iterator&&Array.prototype.from&&b[Symbol.iterator]&&(b=Array.from(b)),Array.isArray(b)||(b=f(b));for(var d=b.map(function(b){var c={};for(var d in b){var f=b[d];if("offset"==d){if(null!=f){if(f=Number(f),!isFinite(f))throw new TypeError("Keyframe offsets must be numbers.");if(f<0||f>1)throw new TypeError("Keyframe offsets must be between 0 and 1.")}}else if("composite"==d){if("add"==f||"accumulate"==f)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};if("replace"!=f)throw new TypeError("Invalid composite mode "+f+".")}else f="easing"==d?a.normalizeEasing(f):""+f;e(d,f,c)}return void 0==c.offset&&(c.offset=null),void 0==c.easing&&(c.easing="linear"),c}),g=!0,h=-1/0,i=0;i<d.length;i++){var j=d[i].offset;if(null!=j){if(j<h)throw new TypeError("Keyframes are not loosely sorted by offset. Sort or specify offsets.");h=j}else g=!1}return d=d.filter(function(a){return a.offset>=0&&a.offset<=1}),g||c(),d}var h={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"]},i=document.createElementNS("http://www.w3.org/1999/xhtml","div"),j={thin:"1px",medium:"3px",thick:"5px"},k={borderBottomWidth:j,borderLeftWidth:j,borderRightWidth:j,borderTopWidth:j,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:j,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.convertToArrayForm=f,a.normalizeKeyframes=g}(c),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),!(g<h&&(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,1))},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,c){function d(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 e(c){var d=[];for(var e in c)for(var f=c[e],g=0;g<f.length-1;g++){var h=g,i=g+1,j=f[h].offset,k=f[i].offset,l=j,m=k;0==g&&(l=-1/0,0==k&&(i=h)),g==f.length-2&&(m=1/0,1==j&&(h=i)),d.push({applyFrom:l,applyTo:m,startOffset:f[h].offset,endOffset:f[i].offset,easingFunction:a.parseEasingFunction(f[h].easing),property:e,interpolation:b.propertyInterpolation(e,f[h].value,f[i].value)})}return d.sort(function(a,b){return a.startOffset-b.startOffset}),d}b.convertEffectInput=function(c){var f=a.normalizeKeyframes(c),g=d(f),h=e(g);return function(a,c){if(null!=c)h.filter(function(a){return c>=a.applyFrom&&c<a.applyTo}).forEach(function(d){var e=c-d.startOffset,f=d.endOffset-d.startOffset,g=0==f?0:d.easingFunction(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),function(a,b,c){function d(a){return a.replace(/-(.)/g,function(a,b){return b.toUpperCase()})}function e(a,b,c){h[c]=h[c]||[],h[c].push([a,b])}function f(a,b,c){for(var f=0;f<c.length;f++){e(a,b,d(c[f]))}}function g(c,e,f){var g=c;/-/.test(c)&&!a.isDeprecated("Hyphenated property names","2016-03-22","Use camelCase instead.",!0)&&(g=d(c)),"initial"!=e&&"initial"!=f||("initial"==e&&(e=i[g]),"initial"==f&&(f=i[g]));for(var j=e==f?[]:h[g],k=0;j&&k<j.length;k++){var l=j[k][0](e),m=j[k][0](f);if(void 0!==l&&void 0!==m){var n=j[k][1](l,m);if(n){var o=b.Interpolation.apply(null,n);return function(a){return 0==a?e:1==a?f:o(a)}}}}return b.Interpolation(!1,!0,function(a){return a?f:e})}var h={};b.addPropertiesHandler=f;var i={backgroundColor:"transparent",backgroundPosition:"0% 0%",borderBottomColor:"currentColor",borderBottomLeftRadius:"0px",borderBottomRightRadius:"0px",borderBottomWidth:"3px",borderLeftColor:"currentColor",borderLeftWidth:"3px",borderRightColor:"currentColor",borderRightWidth:"3px",borderSpacing:"2px",borderTopColor:"currentColor",borderTopLeftRadius:"0px",borderTopRightRadius:"0px",borderTopWidth:"3px",bottom:"auto",clip:"rect(0px, 0px, 0px, 0px)",color:"black",fontSize:"100%",fontWeight:"400",height:"auto",left:"auto",letterSpacing:"normal",lineHeight:"120%",marginBottom:"0px",marginLeft:"0px",marginRight:"0px",marginTop:"0px",maxHeight:"none",maxWidth:"none",minHeight:"0px",minWidth:"0px",opacity:"1.0",outlineColor:"invert",outlineOffset:"0px",outlineWidth:"3px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",paddingTop:"0px",right:"auto",strokeDasharray:"none",strokeDashoffset:"0px",textIndent:"0px",textShadow:"0px 0px 0px transparent",top:"auto",transform:"",verticalAlign:"0px",visibility:"visible",width:"auto",wordSpacing:"normal",zIndex:"auto"};b.propertyInterpolation=g}(c,d),function(a,b,c){function d(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateIterationProgress(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d}b.KeyframeEffect=function(c,e,f,g){var h,i=d(a.normalizeTimingInput(f)),j=b.convertEffectInput(e),k=function(){j(c,h)};return k._update=function(a){return null!==(h=i(a))},k._clear=function(){j(c,null)},k._hasSameTarget=function(a){return c===a},k._target=c,k._totalDuration=i._totalDuration,k._id=g,k}}(c,d),function(a,b){function c(a,b){return!(!b.namespaceURI||-1==b.namespaceURI.indexOf("/svg"))&&(g in a||(a[g]=/Trident|MSIE|IEMobile|Edge|Android 4/i.test(a.navigator.userAgent)),a[g])}function d(a,b,c){c.enumerable=!0,c.configurable=!0,Object.defineProperty(a,b,c)}function e(a){this._element=a,this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=a.style,this._length=0,this._isAnimatedProperty={},this._updateSvgTransformAttr=c(window,a),this._savedTransformAttr=null;for(var b=0;b<this._style.length;b++){var d=this._style[b];this._surrogateStyle[d]=this._style[d]}this._updateIndices()}function f(a){if(!a._webAnimationsPatchedStyle){var b=new e(a);try{d(a,"style",{get:function(){return b}})}catch(b){a.style._set=function(b,c){a.style[b]=c},a.style._clear=function(b){a.style[b]=""}}a._webAnimationsPatchedStyle=a.style}}var g="_webAnimationsUpdateSvgTransformAttr",h={cssText:1,length:1,parentRule:1},i={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},j={removeProperty:1,setProperty:1};e.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(b,c){this._style[b]=c,this._isAnimatedProperty[b]=!0,this._updateSvgTransformAttr&&"transform"==a.unprefixedPropertyName(b)&&(null==this._savedTransformAttr&&(this._savedTransformAttr=this._element.getAttribute("transform")),this._element.setAttribute("transform",a.transformToSvgMatrix(c)))},_clear:function(b){this._style[b]=this._surrogateStyle[b],this._updateSvgTransformAttr&&"transform"==a.unprefixedPropertyName(b)&&(this._savedTransformAttr?this._element.setAttribute("transform",this._savedTransformAttr):this._element.removeAttribute("transform"),this._savedTransformAttr=null),delete this._isAnimatedProperty[b]}};for(var k in i)e.prototype[k]=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}}(k,k in j);for(var l in document.documentElement.style)l in h||l in i||function(a){d(e.prototype,a,{get:function(){return this._surrogateStyle[a]},set:function(b){this._surrogateStyle[a]=b,this._updateIndices(),this._isAnimatedProperty[a]||(this._style[a]=b)}})}(l);a.apply=function(b,c,d){f(b),b.style._set(a.propertyName(c),d)},a.clear=function(b,c){b._webAnimationsPatchedStyle&&b.style._clear(a.propertyName(c))}}(d),function(a){window.Element.prototype.animate=function(b,c){var d="";return c&&c.id&&(d=c.id),a.timeline._play(a.KeyframeEffect(this,b,c,d))}}(d),function(a,b){function c(a,b,d){if("number"==typeof a&&"number"==typeof b)return a*(1-d)+b*d;if("boolean"==typeof a&&"boolean"==typeof b)return d<.5?a:b;if(a.length==b.length){for(var e=[],f=0;f<a.length;f++)e.push(c(a[f],b[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+b}a.Interpolation=function(a,b,d){return function(e){return d(c(a,b,e))}}}(d),function(a,b){function c(a,b,c){return Math.max(Math.min(a,c),b)}function d(b,d,e){var f=a.dot(b,d);f=c(f,-1,1);var g=[];if(1===f)g=b;else for(var h=Math.acos(f),i=1*Math.sin(e*h)/Math.sqrt(1-f*f),j=0;j<4;j++)g.push(b[j]*(Math.cos(e*h)-f*i)+d[j]*i);return g}var e=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;d<4;d++)for(var e=0;e<4;e++)for(var f=0;f<4;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;i<4;i++)h[i][3]=g[i];for(var i=0;i<3;i++)for(var j=0;j<3;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;i<3;i++)for(var j=0;j<3;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=e,a.quat=d}(d),function(a,b,c){a.sequenceNumber=0;var d=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()};b.Animation=function(b){this.id="",b&&b._id&&(this.id=b._id),this._sequenceNumber=a.sequenceNumber++,this._currentTime=0,this._startTime=null,this._paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!0,this.onfinish=null,this._finishHandlers=[],this._effect=b,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},b.Animation.prototype={_ensureAlive:function(){this.playbackRate<0&&0===this.currentTime?this._inEffect=this._effect._update(-1):this._inEffect=this._effect._update(this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,b.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this._isFinished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(a){a=+a,isNaN(a)||(b.restart(),this._paused||null==this._startTime||(this._startTime=this._timeline.currentTime-a/this._playbackRate),this._currentTimePending=!1,this._currentTime!=a&&(this._idle&&(this._idle=!1,this._paused=!0),this._tickCurrentTime(a,!0),b.applyDirtiedAnimation(this)))},get startTime(){return this._startTime},set startTime(a){a=+a,isNaN(a)||this._paused||this._idle||(this._startTime=a,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),b.applyDirtiedAnimation(this))},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var c=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&(this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),b.applyDirtiedAnimation(this)),null!=c&&(this.currentTime=c)}},get _isFinished(){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._isFinished?"finished":"running"},_rewind:function(){if(this._playbackRate>=0)this._currentTime=0;else{if(!(this._totalDuration<1/0))throw new DOMException("Unable to rewind negative playback rate animation with infinite duration","InvalidStateError");this._currentTime=this._totalDuration}},play:function(){this._paused=!1,(this._isFinished||this._idle)&&(this._rewind(),this._startTime=null),this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),b.applyDirtiedAnimation(this)},pause:function(){this._isFinished||this._paused||this._idle?this._idle&&(this._rewind(),this._idle=!1):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,b.applyDirtiedAnimation(this))},cancel:function(){this._inEffect&&(this._inEffect=!1,this._idle=!0,this._paused=!1,this._isFinished=!0,this._finishedFlag=!0,this._currentTime=0,this._startTime=null,this._effect._update(null),b.applyDirtiedAnimation(this))},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){if(this._isFinished){if(!this._finishedFlag){var b=new d(this,this._currentTime,a),c=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){c.forEach(function(a){a.call(b.target,b)})},0),this._finishedFlag=!0}}else this._finishedFlag=!1},_tick:function(a,b){this._idle||this._paused||(null==this._startTime?b&&(this.startTime=a-this._currentTime/this.playbackRate):this._isFinished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),b&&(this._currentTimePending=!1,this._fireEvents(a))},get _needsTick(){return this.playState in{pending:1,running:1}||!this._finishedFlag},_targetAnimations:function(){var a=this._effect._target;return a._activeAnimations||(a._activeAnimations=[]),a._activeAnimations},_markTarget:function(){var a=this._targetAnimations();-1===a.indexOf(this)&&a.push(this)},_unmarkTarget:function(){var a=this._targetAnimations(),b=a.indexOf(this);-1!==b&&a.splice(b,1)}}}(c,d),function(a,b,c){function d(a){var b=j;j=[],a<q.currentTime&&(a=q.currentTime),q._animations.sort(e),q._animations=h(a,!0,q._animations)[0],b.forEach(function(b){b[1](a)}),g(),l=void 0}function e(a,b){return a._sequenceNumber-b._sequenceNumber}function f(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function g(){o.forEach(function(a){a()}),o.length=0}function h(a,c,d){p=!0,n=!1,b.timeline.currentTime=a,m=!1;var e=[],f=[],g=[],h=[];return d.forEach(function(b){b._tick(a,c),b._inEffect?(f.push(b._effect),b._markTarget()):(e.push(b._effect),b._unmarkTarget()),b._needsTick&&(m=!0);var d=b._inEffect||b._needsTick;b._inTimeline=d,d?g.push(b):h.push(b)}),o.push.apply(o,e),o.push.apply(o,f),m&&requestAnimationFrame(function(){}),p=!1,[g,h]}var i=window.requestAnimationFrame,j=[],k=0;window.requestAnimationFrame=function(a){var b=k++;return 0==j.length&&i(d),j.push([b,a]),b},window.cancelAnimationFrame=function(a){j.forEach(function(b){b[0]==a&&(b[1]=function(){})})},f.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.applyDirtiedAnimation(d),d}};var l=void 0,m=!1,n=!1;b.restart=function(){return m||(m=!0,requestAnimationFrame(function(){}),n=!0),n},b.applyDirtiedAnimation=function(a){if(!p){a._markTarget();var c=a._targetAnimations();c.sort(e),h(b.timeline.currentTime,!1,c.slice())[1].forEach(function(a){var b=q._animations.indexOf(a);-1!==b&&q._animations.splice(b,1)}),g()}};var o=[],p=!1,q=new f;b.timeline=q}(c,d),function(a,b){function c(a,b){for(var c=0,d=0;d<a.length;d++)c+=a[d]*b[d];return c}function d(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 e(a){var b=a.rad||0;return((a.deg||0)/360+(a.grad||0)/400+(a.turn||0))*(2*Math.PI)+b}function f(a){switch(a.t){case"rotatex":var b=e(a.d[0]);return[1,0,0,0,0,Math.cos(b),Math.sin(b),0,0,-Math.sin(b),Math.cos(b),0,0,0,0,1];case"rotatey":var b=e(a.d[0]);return[Math.cos(b),0,-Math.sin(b),0,0,1,0,0,Math.sin(b),0,Math.cos(b),0,0,0,0,1];case"rotate":case"rotatez":var b=e(a.d[0]);return[Math.cos(b),Math.sin(b),0,0,-Math.sin(b),Math.cos(b),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var c=a.d[0],d=a.d[1],f=a.d[2],b=e(a.d[3]),g=c*c+d*d+f*f;if(0===g)c=1,d=0,f=0;else if(1!==g){var h=Math.sqrt(g);c/=h,d/=h,f/=h}var i=Math.sin(b/2),j=i*Math.cos(b/2),k=i*i;return[1-2*(d*d+f*f)*k,2*(c*d*k+f*j),2*(c*f*k-d*j),0,2*(c*d*k-f*j),1-2*(c*c+f*f)*k,2*(d*f*k+c*j),0,2*(c*f*k+d*j),2*(d*f*k-c*j),1-2*(c*c+d*d)*k,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 l=e(a.d[0]),m=e(a.d[1]);return[1,Math.tan(m),0,0,Math.tan(l),1,0,0,0,0,1,0,0,0,0,1];case"skewx":var b=e(a.d[0]);return[1,0,0,0,Math.tan(b),1,0,0,0,0,1,0,0,0,0,1];case"skewy":var b=e(a.d[0]);return[1,Math.tan(b),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":var c=a.d[0].px||0,d=a.d[1].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,c,d,0,1];case"translatex":var c=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,c,0,0,1];case"translatey":var d=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,d,0,1];case"translatez":var f=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,f,1];case"translate3d":var c=a.d[0].px||0,d=a.d[1].px||0,f=a.d[2].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,c,d,f,1];case"perspective":return[1,0,0,0,0,1,0,0,0,0,1,a.d[0].px?-1/a.d[0].px:0,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 g(a){return 0===a.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:a.map(f).reduce(d)}function h(a){return[i(g(a))]}var i=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 b(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;o<3;o++){for(var p=0,q=0;q<3;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;d<4;d++){for(var e=0,f=0;f<4;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;m<4;m++)l.push(k[m].slice());for(var m=0;m<3;m++)l[m][3]=0;if(0===a(l))return null;var n,o=[];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]),n=e(o,d(b(l)))):n=[0,0,0,1];var p=k[3].slice(0,3),q=[];q.push(k[0].slice(0,3));var r=[];r.push(g(q[0])),q[0]=f(q[0]);var s=[];q.push(k[1].slice(0,3)),s.push(c(q[0],q[1])),q[1]=h(q[1],q[0],1,-s[0]),r.push(g(q[1])),q[1]=f(q[1]),s[0]/=r[1],q.push(k[2].slice(0,3)),s.push(c(q[0],q[2])),q[2]=h(q[2],q[0],1,-s[1]),s.push(c(q[1],q[2])),q[2]=h(q[2],q[1],1,-s[2]),r.push(g(q[2])),q[2]=f(q[2]),s[1]/=r[2],s[2]/=r[2];var t=i(q[1],q[2]);if(c(q[0],t)<0)for(var m=0;m<3;m++)r[m]*=-1,q[m][0]*=-1,q[m][1]*=-1,q[m][2]*=-1;var u,v,w=q[0][0]+q[1][1]+q[2][2]+1;return w>1e-4?(u=.5/Math.sqrt(w),v=[(q[2][1]-q[1][2])*u,(q[0][2]-q[2][0])*u,(q[1][0]-q[0][1])*u,.25/u]):q[0][0]>q[1][1]&&q[0][0]>q[2][2]?(u=2*Math.sqrt(1+q[0][0]-q[1][1]-q[2][2]),v=[.25*u,(q[0][1]+q[1][0])/u,(q[0][2]+q[2][0])/u,(q[2][1]-q[1][2])/u]):q[1][1]>q[2][2]?(u=2*Math.sqrt(1+q[1][1]-q[0][0]-q[2][2]),v=[(q[0][1]+q[1][0])/u,.25*u,(q[1][2]+q[2][1])/u,(q[0][2]-q[2][0])/u]):(u=2*Math.sqrt(1+q[2][2]-q[0][0]-q[1][1]),v=[(q[0][2]+q[2][0])/u,(q[1][2]+q[2][1])/u,.25*u,(q[1][0]-q[0][1])/u]),[p,r,s,v,n]}return j}();a.dot=c,a.makeMatrixDecomposition=h,a.transformListToMatrix=g}(d),function(a){function b(a,b){var c=a.exec(b);if(c)return c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);if(c)return[c[0],c[1].replace(/^\s*/,"")]}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[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++,c<=0))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){return a(c)||[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]}if(""==c)return d}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;k<j;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);if(e&&e[0].length)return[d,e[1]]}function c(c){var d=a.consumeRepeated(b,/^,/,c);if(d&&""==d[1])return d[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,b){function c(a){return a.toFixed(3).replace(/0+$/,"").replace(/\.$/,"")}function d(a,b,c){return Math.min(b,Math.max(a,c))}function e(a){if(/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a))return Number(a)}function f(a,b){return[a,b,c]}function g(a,b){if(0!=a)return i(0,1/0)(a,b)}function h(a,b){return[a,b,function(a){return Math.round(d(1,1/0,a))}]}function i(a,b){return function(e,f){return[e,f,function(e){return c(d(a,b,e))}]}}function j(a){var b=a.trim().split(/\s*[\s,]\s*/);if(0!==b.length){for(var c=[],d=0;d<b.length;d++){var f=e(b[d]);if(void 0===f)return;c.push(f)}return c}}function k(a,b){if(a.length==b.length)return[a,b,function(a){return a.map(c).join(" ")}]}function l(a,b){return[a,b,Math.round]}a.clamp=d,a.addPropertiesHandler(j,k,["stroke-dasharray"]),a.addPropertiesHandler(e,i(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(e,i(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(e,g,["flex-grow","flex-shrink"]),a.addPropertiesHandler(e,h,["orphans","widows"]),a.addPropertiesHandler(e,l,["z-index"]),a.parseNumber=e,a.parseNumberList=j,a.mergeNumbers=f,a.numberToString=c}(d),function(a,b){function c(a,b){if("visible"==a||"visible"==b)return[0,1,function(c){return c<=0?a:c>=1?b:"visible"}]}a.addPropertiesHandler(String,c,["visibility"])}(d),function(a,b){function c(a){a=a.trim(),f.fillStyle="#000",f.fillStyle=a;var b=f.fillStyle;if(f.fillStyle="#fff",f.fillStyle=a,b==f.fillStyle){f.fillRect(0,0,1,1);var c=f.getImageData(0,0,1,1).data;f.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function d(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;d<3;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 e=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");e.width=e.height=1;var f=e.getContext("2d");a.addPropertiesHandler(c,d,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","fill","flood-color","lighting-color","outline-color","stop-color","stroke","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,c),a.mergeColors=d}(d),function(a,b){function c(a){function b(){var b=h.exec(a);g=b?b[0]:void 0}function c(){var a=Number(g);return b(),a}function d(){if("("!==g)return c();b();var a=f();return")"!==g?NaN:(b(),a)}function e(){for(var a=d();"*"===g||"/"===g;){var c=g;b();var e=d();"*"===c?a*=e:a/=e}return a}function f(){for(var a=e();"+"===g||"-"===g;){var c=g;b();var d=e();"+"===c?a+=d:a-=d}return a}var g,h=/([\+\-\w\.]+|[\(\)\*\/])/g;return b(),f()}function d(a,b){if("0"==(b=b.trim().toLowerCase())&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var d={};b=b.replace(a,function(a){return d[a]=null,"U"+a});for(var e="U("+a.source+")",f=b.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g,"N").replace(new RegExp("N"+e,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),g=[/N\*(D)/g,/(N|D)[*\/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],h=0;h<g.length;)g[h].test(f)?(f=f.replace(g[h],"$1"),h=0):h++;if("D"==f){for(var i in d){var j=c(b.replace(new RegExp("U"+i,"g"),"").replace(new RegExp(e,"g"),"*0"));if(!isFinite(j))return;d[i]=j}return d}}}function e(a,b){return f(a,b,!0)}function f(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 g="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",h=d.bind(null,new RegExp(g,"g")),i=d.bind(null,new RegExp(g+"|%","g")),j=d.bind(null,/deg|rad|grad|turn/g);a.parseLength=h,a.parseLengthOrPercent=i,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,i),a.parseAngle=j,a.mergeDimensions=f;var k=a.consumeParenthesised.bind(null,h),l=a.consumeRepeated.bind(void 0,k,/^/),m=a.consumeRepeated.bind(void 0,l,/^,/);a.consumeSizePairList=m;var n=function(a){var b=m(a);if(b&&""==b[1])return b[0]},o=a.mergeNestedRepeated.bind(void 0,e," "),p=a.mergeNestedRepeated.bind(void 0,o,",");a.mergeNonNegativeSizePair=o,a.addPropertiesHandler(n,p,["background-size"]),a.addPropertiesHandler(i,e,["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(i,f,["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","stroke-dashoffset","text-indent","top","vertical-align","word-spacing"])}(d),function(a,b){function c(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function d(b){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,c,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],b);if(d&&4==d[0].length)return d[0]}function e(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 f(a){return"rect("+a+")"}var g=a.mergeWrappedNestedRepeated.bind(null,f,e,", ");a.parseBox=d,a.mergeBoxes=g,a.addPropertiesHandler(d,g,["clip"])}(d),function(a,b){function c(a){return function(b){var c=0;return a.map(function(a){return a===k?b[c++]:a})}}function d(a){return a}function e(b){if("none"==(b=b.toLowerCase().trim()))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=n[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var k=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(void 0===(p=q?{A:function(b){return"0"==b.trim()?m:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:m,n:k[0],t:l}[r]))return;k.push(p)}if(e.push({t:g,d:k}),d.lastIndex==b.length)return e}}function f(a){return a.toFixed(6).replace(".000000","")}function g(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var e=a.makeMatrixDecomposition(c)}return null==d[0]||null==e[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),e[0].push(1),[d,e,function(b){var c=a.quat(d[0][3],e[0][3],b[5]);return a.composeMatrix(b[0],b[1],b[2],c,b[4]).map(f).join(",")}])}function h(a){return a.replace(/[xy]/,"")}function i(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function j(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var f=0;f<b.length;f++){var j=b[f].t,k=b[f].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 m=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=g(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var f=0;f<b.length;f++){var j,s=b[f].t,t=c[f].t,u=b[f].d,v=c[f].d,w=n[s],x=n[t];if(m(s,t)){if(!d)return;var r=g([b[f]],[c[f]]);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]&&h(s)==h(t))j=h(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||i(s)!=i(t)){if(!d)return;var r=g(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=i(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 k=null,l={px:0},m={deg:0},n={matrix:["NNNNNN",[k,k,0,0,k,k,0,0,0,0,1,0,k,k,0,1],d],matrix3d:["NNNNNNNNNNNNNNNN",d],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",c([k,k,1]),d],scalex:["N",c([k,1,1]),c([k,1])],scaley:["N",c([1,k,1]),c([1,k])],scalez:["N",c([1,1,k])],scale3d:["NNN",d],skew:["Aa",null,d],skewx:["A",null,c([k,m])],skewy:["A",null,c([m,k])],translate:["Tt",c([k,k,l]),d],translatex:["T",c([k,l,l]),c([k,l])],translatey:["T",c([l,k,l]),c([l,k])],translatez:["L",c([l,l,k])],translate3d:["TTL",d]};a.addPropertiesHandler(e,j,["transform"]),a.transformToSvgMatrix=function(b){var c=a.transformListToMatrix(e(b));return"matrix("+f(c[0])+" "+f(c[1])+" "+f(c[4])+" "+f(c[5])+" "+f(c[12])+" "+f(c[13])+")"}}(d),function(a){function b(a){var b=Number(a);if(!(isNaN(b)||b<100||b>900||b%100!=0))return 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);if(c&&""==c[1])return c[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){if(b[0]===c[0])return"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}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,b){function c(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(d[a]=b),e[b]=a})}var d={},e={};c("transform",["webkitTransform","msTransform"]),c("transformOrigin",["webkitTransformOrigin"]),c("perspective",["webkitPerspective"]),c("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return d[a]||a},a.unprefixedPropertyName=function(a){return e[a]||a}}(d)}(),function(){if(void 0===document.createElement("div").animate([]).oncancel){var a;if(window.performance&&performance.now)var a=function(){return performance.now()};else var a=function(){return Date.now()};var b=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="cancel",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()},c=window.Element.prototype.animate;window.Element.prototype.animate=function(d,e){var f=c.call(this,d,e);f._cancelHandlers=[],f.oncancel=null;var g=f.cancel;f.cancel=function(){g.call(this);var c=new b(this,null,a()),d=this._cancelHandlers.concat(this.oncancel?[this.oncancel]:[]);setTimeout(function(){d.forEach(function(a){a.call(c.target,c)})},0)};var h=f.addEventListener;f.addEventListener=function(a,b){"function"==typeof b&&"cancel"==a?this._cancelHandlers.push(b):h.call(this,a,b)};var i=f.removeEventListener;return f.removeEventListener=function(a,b){if("cancel"==a){var c=this._cancelHandlers.indexOf(b);c>=0&&this._cancelHandlers.splice(c,1)}else i.call(this,a,b)},f}}}(),function(a){var b=document.documentElement,c=null,d=!1;try{var e=getComputedStyle(b).getPropertyValue("opacity"),f="0"==e?"1":"0";c=b.animate({opacity:[f,f]},{duration:1}),c.currentTime=0,d=getComputedStyle(b).getPropertyValue("opacity")==f}catch(a){}finally{c&&c.cancel()}if(!d){var g=window.Element.prototype.animate;window.Element.prototype.animate=function(b,c){return window.Symbol&&Symbol.iterator&&Array.prototype.from&&b[Symbol.iterator]&&(b=Array.from(b)),Array.isArray(b)||null===b||(b=a.convertToArrayForm(b)),g.call(this,b,c)}}}(c),function(a,b,c){function d(a){var c=b.timeline;c.currentTime=a,c._discardAnimations(),0==c._animations.length?f=!1:requestAnimationFrame(d)}var e=window.requestAnimationFrame;window.requestAnimationFrame=function(a){return e(function(c){b.timeline._updateAnimationsPromises(),a(c),b.timeline._updateAnimationsPromises()})},b.AnimationTimeline=function(){this._animations=[],this.currentTime=void 0},b.AnimationTimeline.prototype={getAnimations:function(){return this._discardAnimations(),this._animations.slice()},_updateAnimationsPromises:function(){b.animationsWithPromises=b.animationsWithPromises.filter(function(a){return a._updatePromises()})},_discardAnimations:function(){this._updateAnimationsPromises(),this._animations=this._animations.filter(function(a){return"finished"!=a.playState&&"idle"!=a.playState})},_play:function(a){var c=new b.Animation(a,this);return this._animations.push(c),b.restartWebAnimationsNextTick(),c._updatePromises(),c._animation.play(),c._updatePromises(),c},play:function(a){return a&&a.remove(),this._play(a)}};var f=!1;b.restartWebAnimationsNextTick=function(){f||(f=!0,requestAnimationFrame(d))};var g=new b.AnimationTimeline;b.timeline=g;try{Object.defineProperty(window.document,"timeline",{configurable:!0,get:function(){return g}})}catch(a){}try{window.document.timeline=g}catch(a){}}(0,e),function(a,b,c){b.animationsWithPromises=[],b.Animation=function(b,c){if(this.id="",b&&b._id&&(this.id=b._id),this.effect=b,b&&(b._animation=this),!c)throw new Error("Animation with null timeline is not supported");this._timeline=c,this._sequenceNumber=a.sequenceNumber++,this._holdTime=0,this._paused=!1,this._isGroup=!1,this._animation=null,this._childAnimations=[],this._callback=null,this._oldPlayState="idle",this._rebuildUnderlyingAnimation(),this._animation.cancel(),this._updatePromises()},b.Animation.prototype={_updatePromises:function(){var a=this._oldPlayState,b=this.playState;return this._readyPromise&&b!==a&&("idle"==b?(this._rejectReadyPromise(),this._readyPromise=void 0):"pending"==a?this._resolveReadyPromise():"pending"==b&&(this._readyPromise=void 0)),this._finishedPromise&&b!==a&&("idle"==b?(this._rejectFinishedPromise(),this._finishedPromise=void 0):"finished"==b?this._resolveFinishedPromise():"finished"==a&&(this._finishedPromise=void 0)),this._oldPlayState=this.playState,this._readyPromise||this._finishedPromise},_rebuildUnderlyingAnimation:function(){this._updatePromises();var a,c,d,e,f=!!this._animation;f&&(a=this.playbackRate,c=this._paused,d=this.startTime,e=this.currentTime,this._animation.cancel(),this._animation._wrapper=null,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)),this.effect&&this.effect._onsample&&b.bindAnimationForCustomEffect(this),f&&(1!=a&&(this.playbackRate=a),null!==d?this.startTime=d:null!==e?this.currentTime=e:null!==this._holdTime&&(this.currentTime=this._holdTime),c&&this.pause()),this._updatePromises()},_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)},_constructChildAnimations:function(){if(this.effect&&this._isGroup){var a=this.effect._timing.delay;this._removeChildAnimations(),this.effect.children.forEach(function(c){var d=b.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!==this.startTime+b/this.playbackRate&&(a.startTime=this.startTime+b/this.playbackRate)},get timeline(){return this._timeline},get playState(){return this._animation?this._animation.playState:"idle"},get finished(){return window.Promise?(this._finishedPromise||(-1==b.animationsWithPromises.indexOf(this)&&b.animationsWithPromises.push(this),this._finishedPromise=new Promise(function(a,b){this._resolveFinishedPromise=function(){a(this)},this._rejectFinishedPromise=function(){b({type:DOMException.ABORT_ERR,name:"AbortError"})}}.bind(this)),"finished"==this.playState&&this._resolveFinishedPromise()),this._finishedPromise):(console.warn("Animation Promises require JavaScript Promise constructor"),null)},get ready(){return window.Promise?(this._readyPromise||(-1==b.animationsWithPromises.indexOf(this)&&b.animationsWithPromises.push(this),this._readyPromise=new Promise(function(a,b){this._resolveReadyPromise=function(){a(this)},this._rejectReadyPromise=function(){b({type:DOMException.ABORT_ERR,name:"AbortError"})}}.bind(this)),"pending"!==this.playState&&this._resolveReadyPromise()),this._readyPromise):(console.warn("Animation Promises require JavaScript Promise constructor"),null)},get onfinish(){return this._animation.onfinish},set onfinish(a){this._animation.onfinish="function"==typeof a?function(b){b.target=this,a.call(this,b)}.bind(this):a},get oncancel(){return this._animation.oncancel},set oncancel(a){this._animation.oncancel="function"==typeof a?function(b){b.target=this,a.call(this,b)}.bind(this):a},get currentTime(){this._updatePromises();var a=this._animation.currentTime;return this._updatePromises(),a},set currentTime(a){this._updatePromises(),this._animation.currentTime=isFinite(a)?a:Math.sign(a)*Number.MAX_VALUE,this._register(),this._forEachChild(function(b,c){b.currentTime=a-c}),this._updatePromises()},get startTime(){return this._animation.startTime},set startTime(a){this._updatePromises(),this._animation.startTime=isFinite(a)?a:Math.sign(a)*Number.MAX_VALUE,this._register(),this._forEachChild(function(b,c){b.startTime=a+c}),this._updatePromises()},get playbackRate(){return this._animation.playbackRate},set playbackRate(a){this._updatePromises();var b=this.currentTime;this._animation.playbackRate=a,this._forEachChild(function(b){b.playbackRate=a}),null!==b&&(this.currentTime=b),this._updatePromises()},play:function(){this._updatePromises(),this._paused=!1,this._animation.play(),-1==this._timeline._animations.indexOf(this)&&this._timeline._animations.push(this),this._register(),b.awaitStartTime(this),this._forEachChild(function(a){var b=a.currentTime;a.play(),a.currentTime=b}),this._updatePromises()},pause:function(){this._updatePromises(),this.currentTime&&(this._holdTime=this.currentTime),this._animation.pause(),this._register(),this._forEachChild(function(a){a.pause()}),this._paused=!0,this._updatePromises()},finish:function(){this._updatePromises(),this._animation.finish(),this._register(),this._updatePromises()},cancel:function(){this._updatePromises(),this._animation.cancel(),this._register(),this._removeChildAnimations(),this._updatePromises()},reverse:function(){this._updatePromises();var a=this.currentTime;this._animation.reverse(),this._forEachChild(function(a){a.reverse()}),null!==a&&(this.currentTime=a),this._updatePromises()},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)},_removeChildAnimations: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._constructChildAnimations(),this._childAnimations.forEach(function(a){b.call(this,a,c),this.effect instanceof window.SequenceEffect&&(c+=a.effect.activeDuration)}.bind(this)),"pending"!=this.playState){var d=this.effect._timing,e=this.currentTime;null!==e&&(e=a.calculateIterationProgress(a.calculateActiveDuration(d),e,d)),(null==e||isNaN(e))&&this._removeChildAnimations()}}},window.Animation=b.Animation}(c,e),function(a,b,c){function d(b){this._frames=a.normalizeKeyframes(b)}function e(){for(var a=!1;i.length;)i.shift()._updateChildren(),a=!0;return a}var f=function(a){if(a._animation=void 0,a instanceof window.SequenceEffect||a instanceof window.GroupEffect)for(var b=0;b<a.children.length;b++)f(a.children[b])};b.removeMulti=function(a){for(var b=[],c=0;c<a.length;c++){var d=a[c];d._parent?(-1==b.indexOf(d._parent)&&b.push(d._parent),d._parent.children.splice(d._parent.children.indexOf(d),1),d._parent=null,f(d)):d._animation&&d._animation.effect==d&&(d._animation.cancel(),d._animation.effect=new KeyframeEffect(null,[]),d._animation._callback&&(d._animation._callback._animation=null),d._animation._rebuildUnderlyingAnimation(),f(d))}for(c=0;c<b.length;c++)b[c]._rebuild()},b.KeyframeEffect=function(b,c,e,f){return this.target=b,this._parent=null,e=a.numericTimingToObject(e),this._timingInput=a.cloneTimingInput(e),this._timing=a.normalizeTimingInput(e),this.timing=a.makeTiming(e,!1,this),this.timing._effect=this,"function"==typeof c?(a.deprecated("Custom KeyframeEffect","2015-06-22","Use KeyframeEffect.onsample instead."),this._normalizedKeyframes=c):this._normalizedKeyframes=new d(c),this._keyframes=c,this.activeDuration=a.calculateActiveDuration(this._timing),this._id=f,this},b.KeyframeEffect.prototype={getFrames:function(){return"function"==typeof this._normalizedKeyframes?this._normalizedKeyframes:this._normalizedKeyframes._frames},set onsample(a){if("function"==typeof this.getFrames())throw new Error("Setting onsample on custom effect KeyframeEffect is not supported.");this._onsample=a,this._animation&&this._animation._rebuildUnderlyingAnimation()},get parent(){return this._parent},clone:function(){if("function"==typeof this.getFrames())throw new Error("Cloning custom effects is not supported.");var b=new KeyframeEffect(this.target,[],a.cloneTimingInput(this._timingInput),this._id);return b._normalizedKeyframes=this._normalizedKeyframes,b._keyframes=this._keyframes,b},remove:function(){b.removeMulti([this])}};var g=Element.prototype.animate;Element.prototype.animate=function(a,c){var d="";return c&&c.id&&(d=c.id),b.timeline._play(new b.KeyframeEffect(this,a,c,d))};var h=document.createElementNS("http://www.w3.org/1999/xhtml","div");b.newUnderlyingAnimationForKeyframeEffect=function(a){if(a){var b=a.target||h,c=a._keyframes;"function"==typeof c&&(c=[]);var d=a._timingInput;d.id=a._id}else var b=h,c=[],d=0;return g.apply(b,[c,d])},b.bindAnimationForKeyframeEffect=function(a){a.effect&&"function"==typeof a.effect._normalizedKeyframes&&b.bindAnimationForCustomEffect(a)};var i=[];b.awaitStartTime=function(a){null===a.startTime&&a._isGroup&&(0==i.length&&requestAnimationFrame(e),i.push(a))};var j=window.getComputedStyle;Object.defineProperty(window,"getComputedStyle",{configurable:!0,enumerable:!0,value:function(){b.timeline._updateAnimationsPromises();var a=j.apply(this,arguments);return e()&&(a=j.apply(this,arguments)),b.timeline._updateAnimationsPromises(),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))}}(c,e),function(a,b,c){function d(a){a._registered||(a._registered=!0,g.push(a),h||(h=!0,requestAnimationFrame(e)))}function e(a){var b=g;g=[],b.sort(function(a,b){return a._sequenceNumber-b._sequenceNumber}),b=b.filter(function(a){a();var b=a._animation?a._animation.playState:"idle";return"running"!=b&&"pending"!=b&&(a._registered=!1),a._registered}),g.push.apply(g,b),g.length?(h=!0,requestAnimationFrame(e)):h=!1}var f=(document.createElementNS("http://www.w3.org/1999/xhtml","div"),0);b.bindAnimationForCustomEffect=function(b){var c,e=b.effect.target,g="function"==typeof b.effect.getFrames();c=g?b.effect.getFrames():b.effect._onsample;var h=b.effect.timing,i=null;h=a.normalizeTimingInput(h);var j=function(){var d=j._animation?j._animation.currentTime:null;null!==d&&(d=a.calculateIterationProgress(a.calculateActiveDuration(h),d,h),isNaN(d)&&(d=null)),d!==i&&(g?c(d,e,b.effect):c(d,b.effect,b.effect._animation)),i=d};j._animation=b,j._registered=!1,j._sequenceNumber=f++,b._callback=j,d(j)};var g=[],h=!1;b.Animation.prototype._register=function(){this._callback&&d(this._callback)}}(c,e),function(a,b,c){function d(a){return a._timing.delay+a.activeDuration+a._timing.endDelay}function e(b,c,d){this._id=d,this._parent=null,this.children=b||[],this._reparent(this.children),c=a.numericTimingToObject(c),this._timingInput=a.cloneTimingInput(c),this._timing=a.normalizeTimingInput(c,!0),this.timing=a.makeTiming(c,!0,this),this.timing._effect=this,"auto"===this._timing.duration&&(this._timing.duration=this.activeDuration)}window.SequenceEffect=function(){e.apply(this,arguments)},window.GroupEffect=function(){e.apply(this,arguments)},e.prototype={_isAncestor:function(a){for(var b=this;null!==b;){if(b==a)return!0;b=b._parent}return!1},_rebuild:function(){for(var a=this;a;)"auto"===a.timing.duration&&(a._timing.duration=a.activeDuration),a=a._parent;this._animation&&this._animation._rebuildUnderlyingAnimation()},_reparent:function(a){b.removeMulti(a);for(var c=0;c<a.length;c++)a[c]._parent=this},_putChild:function(a,b){for(var c=b?"Cannot append an ancestor or self":"Cannot prepend an ancestor or self",d=0;d<a.length;d++)if(this._isAncestor(a[d]))throw{type:DOMException.HIERARCHY_REQUEST_ERR,name:"HierarchyRequestError",message:c};for(var d=0;d<a.length;d++)b?this.children.push(a[d]):this.children.unshift(a[d]);this._reparent(a),this._rebuild()},append:function(){this._putChild(arguments,!0)},prepend:function(){this._putChild(arguments,!1)},get parent(){return this._parent},get firstChild(){return this.children.length?this.children[0]:null},get lastChild(){return this.children.length?this.children[this.children.length-1]:null},clone:function(){for(var b=a.cloneTimingInput(this._timingInput),c=[],d=0;d<this.children.length;d++)c.push(this.children[d].clone());return this instanceof GroupEffect?new GroupEffect(c,b):new SequenceEffect(c,b)},remove:function(){b.removeMulti([this])}},window.SequenceEffect.prototype=Object.create(e.prototype),Object.defineProperty(window.SequenceEffect.prototype,"activeDuration",{get:function(){var a=0;return this.children.forEach(function(b){a+=d(b)}),Math.max(a,0)}}),window.GroupEffect.prototype=Object.create(e.prototype),Object.defineProperty(window.GroupEffect.prototype,"activeDuration",{get:function(){var a=0;return this.children.forEach(function(b){a=Math.max(a,d(b))}),a}}),b.newUnderlyingAnimationForGroup=function(c){var d,e=null,f=function(b){var c=d._wrapper;if(c&&"pending"!=c.playState&&c.effect)return null==b?void c._removeChildAnimations():0==b&&c.playbackRate<0&&(e||(e=a.normalizeTimingInput(c.effect.timing)),b=a.calculateIterationProgress(a.calculateActiveDuration(e),-1,e),isNaN(b)||null==b)?(c._forEachChild(function(a){a.currentTime=-1}),void c._removeChildAnimations()):void 0},g=new KeyframeEffect(null,[],c._timing,c._id);return g.onsample=f,d=b.timeline._play(g)},b.bindAnimationForGroup=function(a){a._animation._wrapper=a,a._isGroup=!0,b.awaitStartTime(a),a._constructChildAnimations(),a._setExternalAnimation(a)},b.groupChildDuration=d}(c,e),b.true=a}({},function(){return this}());
+//# sourceMappingURL=web-animations-next.min.js.map \ No newline at end of file
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js.map b/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js.map
new file mode 100644
index 00000000..0646f1cf
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations-next.min.js.map
@@ -0,0 +1 @@
+{"version":3,"sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/web-animations-bonus-cancel-events.js","src/web-animations-bonus-object-form-keyframes.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","shared","testing","cloneTimingInput","timingInput","clone","m","AnimationEffectTiming","this","_delay","_endDelay","_fill","_iterationStart","_iterations","_duration","_playbackRate","_direction","_easing","_easingFunction","linear","isInvalidTimingDeprecated","isDeprecated","makeTiming","forGroup","effect","timing","fill","duration","isNaN","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","numericTimingToObject","normalizeTimingInput","cubic","a","b","c","d","x","f","start_gradient","end_gradient","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","normalizeEasing","easing","styleForCleaning","document","createElement","style","animationTimingFunction","normalizedEasing","TypeError","parseEasingFunction","cubicData","cubicBezierRe","exec","apply","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","presets","calculateActiveDuration","repeatedDuration","playbackRate","iterations","calculatePhase","activeDuration","localTime","PhaseNone","endTime","delay","endDelay","min","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateOverallProgress","iterationDuration","activeTime","iterationStart","overallProgress","calculateSimpleIterationProgress","simpleIterationProgress","Infinity","calculateCurrentIteration","floor","calculateDirectedProgress","playbackDirection","currentIteration","currentDirection","calculateIterationProgress","directedProgress","direction","split","prototype","_setMember","member","value","_effect","_timingInput","_timing","_animation","_rebuildUnderlyingAnimation","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","aliases","isNotAnimatable","lastIndexOf","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","i","longProperty","longhandValue","convertToArrayForm","effectInput","normalizedEffectInput","values","Array","isArray","keyframe","numKeyframes","length","offset","composite","push","sort","normalizeKeyframes","spaceKeyframes","keyframes","previousIndex","previousOffset","j","window","Symbol","iterator","from","originalKeyframe","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","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","animate","oncancel","now","performance","AnimationCancelEvent","target","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","originalElementAnimate","Element","options","animation","call","_cancelHandlers","originalCancel","cancel","event","handlers","concat","setTimeout","handler","originalAddEventListener","addEventListener","originalRemoveEventListener","removeEventListener","index","splice","element","documentElement","animated","originalOpacity","getComputedStyle","getPropertyValue","testOpacity","opacity","error","scope","webAnimationsNextTick","t","timeline","_discardAnimations","_animations","ticking","requestAnimationFrame","originalRequestAnimationFrame","_updateAnimationsPromises","AnimationTimeline","getAnimations","animationsWithPromises","_updatePromises","playState","_play","Animation","restartWebAnimationsNextTick","play","remove","defineProperty","configurable","get","e","id","_id","_timeline","_sequenceNumber","sequenceNumber","_holdTime","_paused","_isGroup","_childAnimations","_callback","_oldPlayState","oldPlayState","newPlayState","_readyPromise","_rejectReadyPromise","_resolveReadyPromise","_finishedPromise","_rejectFinishedPromise","_resolveFinishedPromise","oldPlaybackRate","oldPaused","oldStartTime","oldCurrentTime","hadUnderlying","startTime","_wrapper","KeyframeEffect","newUnderlyingAnimationForKeyframeEffect","bindAnimationForKeyframeEffect","SequenceEffect","GroupEffect","newUnderlyingAnimationForGroup","bindAnimationForGroup","_onsample","bindAnimationForCustomEffect","pause","_updateChildren","childAnimation","_arrangeChildren","groupChildDuration","bind","_setExternalAnimation","children","_constructChildAnimations","_removeChildAnimations","child","finished","Promise","resolve","reject","ABORT_ERR","ready","onfinish","v","sign","MAX_VALUE","_register","_forEachChild","awaitStartTime","time","finish","reverse","wrapped","pop","KeyframeList","_frames","updatePendingGroups","updated","pendingGroups","shift","disassociate","removeMulti","effects","oldParents","_parent","_rebuild","_normalizedKeyframes","_keyframes","getFrames","onsample","callback","parent","nullTarget","keyframeEffect","groupAnimation","originalGetComputedStyle","enumerable","arguments","register","_registered","callbacks","tick","updating","left","right","effectFunction","isKeyframeEffect","last","node","constructor","_reparent","_isAncestor","newChildren","_putChild","args","isAppend","HIERARCHY_REQUEST_ERR","unshift","append","prepend","firstChild","lastChild","clonedTiming","clonedChildren","create","total","max","group","underlyingAnimation","ticker","tf","underlyingEffect","exports","webAnimationsTesting"],"mappings":";;;;;;;;;;;;;;CAcA,SAAIA,EAAAA,GAAJ,GAAIA,MACAC,KACAC,MCFJ,SAAUC,EAAQC,GAMhB,QAASC,GAAiBC,GACxB,GAA0B,gBAAfA,GACT,MAAOA,EAET,IAAIC,KACJ,KAAK,GAAIC,KAAKF,GACZC,EAAMC,GAAKF,EAAYE,EAEzB,OAAOD,GAGT,QAASE,KACPC,KAAKC,OAAS,EACdD,KAAKE,UAAY,EACjBF,KAAKG,MAAQ,OACbH,KAAKI,gBAAkB,EACvBJ,KAAKK,YAAc,EACnBL,KAAKM,UAAY,EACjBN,KAAKO,cAAgB,EACrBP,KAAKQ,WAAa,SAClBR,KAAKS,QAAU,SACfT,KAAKU,gBAAkBC,EAGzB,QAASC,KACP,MAAOnB,GAAOoB,aAAa,wBAAyB,aAAc,gDAAA,GA8EpE,QAASC,GAAWlB,EAAamB,EAAUC,GACzC,GAAIC,GAAS,GAAIlB,EA4BjB,OA3BIgB,KACFE,EAAOC,KAAO,OACdD,EAAOE,SAAW,QAEM,gBAAfvB,IAA4BwB,MAAMxB,OAAAA,KAElCA,GACTyB,OAAOC,oBAAoB1B,GAAa2B,QAAQ,SAASC,GACvD,GAA6B,QAAzB5B,EAAY4B,GAAqB,CACnC,IAA+B,gBAApBP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AiB1C,SAAWwC,EAC5BD,EAAsB9I,EAAMG,SAASY,MAAMkI,IAI7CjJ,EAAMwD,sBAAwB,SAASjF,GACrCA,EAAUhI,WAAW0M,SAAW1E,EAChCA,EAAUwD,UAAAA,EACV/B,EAAMkF,eAAe3G,GACrBA,EAAU4F,4BACV5F,EAAU0F,sBAAsB1F,IAGlCyB,EAAM+D,mBAAqBA,GAE1BtV,EAAqBE,GV3LpBA,EAAAA,KAEJua,MACMC,WAAAA,MAAuBha","file":"web-animations-next.min.js"} \ No newline at end of file
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations.html b/catapult/third_party/polymer/components/web-animations-js/web-animations.html
new file mode 100644
index 00000000..b5de36c8
--- /dev/null
+++ b/catapult/third_party/polymer/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/catapult/third_party/polymer/components/web-animations-js/web-animations.min.html b/catapult/third_party/polymer/components/web-animations-js/web-animations.min.html
new file mode 100644
index 00000000..b36940d3
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations.min.html
@@ -0,0 +1 @@
+<script src="./web-animations.min.js"></script>
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations.min.js b/catapult/third_party/polymer/components/web-animations-js/web-animations.min.js
new file mode 100644
index 00000000..46156b20
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations.min.js
@@ -0,0 +1,16 @@
+// 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){var c={},d={};!function(a,b){function c(a){if("number"==typeof a)return a;var b={};for(var c in a)b[c]=a[c];return b}function d(){this._delay=0,this._endDelay=0,this._fill="none",this._iterationStart=0,this._iterations=1,this._duration=0,this._playbackRate=1,this._direction="normal",this._easing="linear",this._easingFunction=x}function e(){return a.isDeprecated("Invalid timing inputs","2016-03-02","TypeError exceptions will be thrown instead.",!0)}function f(b,c,e){var f=new d;return c&&(f.fill="both",f.duration="auto"),"number"!=typeof b||isNaN(b)?void 0!==b&&Object.getOwnPropertyNames(b).forEach(function(c){if("auto"!=b[c]){if(("number"==typeof f[c]||"duration"==c)&&("number"!=typeof b[c]||isNaN(b[c])))return;if("fill"==c&&-1==v.indexOf(b[c]))return;if("direction"==c&&-1==w.indexOf(b[c]))return;if("playbackRate"==c&&1!==b[c]&&a.isDeprecated("AnimationEffectTiming.playbackRate","2014-11-28","Use Animation.playbackRate instead."))return;f[c]=b[c]}}):f.duration=b,f}function g(a){return"number"==typeof a&&(a=isNaN(a)?{duration:0}:{duration:a}),a}function h(b,c){return b=a.numericTimingToObject(b),f(b,c)}function i(a,b,c,d){return a<0||a>1||c<0||c>1?x:function(e){function f(a,b,c){return 3*a*(1-c)*(1-c)*c+3*b*(1-c)*c*c+c*c*c}if(e<=0){var g=0;return a>0?g=b/a:!b&&c>0&&(g=d/c),g*e}if(e>=1){var h=0;return c<1?h=(d-1)/(c-1):1==c&&a<1&&(h=(b-1)/(a-1)),1+h*(e-1)}for(var i=0,j=1;i<j;){var k=(i+j)/2,l=f(a,c,k);if(Math.abs(e-l)<1e-5)return f(b,d,k);l<e?i=k:j=k}return f(b,d,k)}}function j(a,b){return function(c){if(c>=1)return 1;var d=1/a;return(c+=b*d)-c%d}}function k(a){C||(C=document.createElement("div").style),C.animationTimingFunction="",C.animationTimingFunction=a;var b=C.animationTimingFunction;if(""==b&&e())throw new TypeError(a+" is not a valid value for easing");return b}function l(a){if("linear"==a)return x;var b=E.exec(a);if(b)return i.apply(this,b.slice(1).map(Number));var c=F.exec(a);return c?j(Number(c[1]),{start:y,middle:z,end:A}[c[2]]):B[a]||x}function m(a){return Math.abs(n(a)/a.playbackRate)}function n(a){return 0===a.duration||0===a.iterations?0:a.duration*a.iterations}function o(a,b,c){if(null==b)return G;var d=c.delay+a+c.endDelay;return b<Math.min(c.delay,d)?H:b>=Math.min(c.delay+a,d)?I:J}function p(a,b,c,d,e){switch(d){case H:return"backwards"==b||"both"==b?0:null;case J:return c-e;case I:return"forwards"==b||"both"==b?a:null;case G:return null}}function q(a,b,c,d,e){var f=e;return 0===a?b!==H&&(f+=c):f+=d/a,f}function r(a,b,c,d,e,f){var g=a===1/0?b%1:a%1;return 0!==g||c!==I||0===d||0===e&&0!==f||(g=1),g}function s(a,b,c,d){return a===I&&b===1/0?1/0:1===c?Math.floor(d)-1:Math.floor(d)}function t(a,b,c){var d=a;if("normal"!==a&&"reverse"!==a){var e=b;"alternate-reverse"===a&&(e+=1),d="normal",e!==1/0&&e%2!=0&&(d="reverse")}return"normal"===d?c:1-c}function u(a,b,c){var d=o(a,b,c),e=p(a,c.fill,b,d,c.delay);if(null===e)return null;var f=q(c.duration,d,c.iterations,e,c.iterationStart),g=r(f,c.iterationStart,d,c.iterations,e,c.duration),h=s(d,c.iterations,g,f),i=t(c.direction,h,g);return c._easingFunction(i)}var v="backwards|forwards|both|none".split("|"),w="reverse|alternate|alternate-reverse".split("|"),x=function(a){return a};d.prototype={_setMember:function(b,c){this["_"+b]=c,this._effect&&(this._effect._timingInput[b]=c,this._effect._timing=a.normalizeTimingInput(this._effect._timingInput),this._effect.activeDuration=a.calculateActiveDuration(this._effect._timing),this._effect._animation&&this._effect._animation._rebuildUnderlyingAnimation())},get playbackRate(){return this._playbackRate},set delay(a){this._setMember("delay",a)},get delay(){return this._delay},set endDelay(a){this._setMember("endDelay",a)},get endDelay(){return this._endDelay},set fill(a){this._setMember("fill",a)},get fill(){return this._fill},set iterationStart(a){if((isNaN(a)||a<0)&&e())throw new TypeError("iterationStart must be a non-negative number, received: "+timing.iterationStart);this._setMember("iterationStart",a)},get iterationStart(){return this._iterationStart},set duration(a){if("auto"!=a&&(isNaN(a)||a<0)&&e())throw new TypeError("duration must be non-negative or auto, received: "+a);this._setMember("duration",a)},get duration(){return this._duration},set direction(a){this._setMember("direction",a)},get direction(){return this._direction},set easing(a){this._easingFunction=l(k(a)),this._setMember("easing",a)},get easing(){return this._easing},set iterations(a){if((isNaN(a)||a<0)&&e())throw new TypeError("iterations must be non-negative, received: "+a);this._setMember("iterations",a)},get iterations(){return this._iterations}};var y=1,z=.5,A=0,B={ease:i(.25,.1,.25,1),"ease-in":i(.42,0,1,1),"ease-out":i(0,0,.58,1),"ease-in-out":i(.42,0,.58,1),"step-start":j(1,y),"step-middle":j(1,z),"step-end":j(1,A)},C=null,D="\\s*(-?\\d+\\.?\\d*|-?\\.\\d+)\\s*",E=new RegExp("cubic-bezier\\("+D+","+D+","+D+","+D+"\\)"),F=/steps\(\s*(\d+)\s*,\s*(start|middle|end)\s*\)/,G=0,H=1,I=2,J=3;a.cloneTimingInput=c,a.makeTiming=f,a.numericTimingToObject=g,a.normalizeTimingInput=h,a.calculateActiveDuration=m,a.calculateIterationProgress=u,a.calculatePhase=o,a.normalizeEasing=k,a.parseEasingFunction=l}(c),function(a,b){function c(a,b){return a in k?k[a][b]||b:b}function d(a){return"display"===a||0===a.lastIndexOf("animation",0)||0===a.lastIndexOf("transition",0)}function e(a,b,e){if(!d(a)){var f=h[a];if(f){i.style[a]=b;for(var g in f){var j=f[g],k=i.style[j];e[j]=c(j,k)}}else e[a]=c(a,b)}}function f(a){var b=[];for(var c in a)if(!(c in["easing","offset","composite"])){var d=a[c];Array.isArray(d)||(d=[d]);for(var e,f=d.length,g=0;g<f;g++)e={},e.offset="offset"in a?a.offset:1==f?1:g/(f-1),"easing"in a&&(e.easing=a.easing),"composite"in a&&(e.composite=a.composite),e[c]=d[g],b.push(e)}return b.sort(function(a,b){return a.offset-b.offset}),b}function g(b){function c(){var a=d.length;null==d[a-1].offset&&(d[a-1].offset=1),a>1&&null==d[0].offset&&(d[0].offset=0);for(var b=0,c=d[0].offset,e=1;e<a;e++){var f=d[e].offset;if(null!=f){for(var g=1;g<e-b;g++)d[b+g].offset=c+(f-c)*g/(e-b);b=e,c=f}}}if(null==b)return[];window.Symbol&&Symbol.iterator&&Array.prototype.from&&b[Symbol.iterator]&&(b=Array.from(b)),Array.isArray(b)||(b=f(b));for(var d=b.map(function(b){var c={};for(var d in b){var f=b[d];if("offset"==d){if(null!=f){if(f=Number(f),!isFinite(f))throw new TypeError("Keyframe offsets must be numbers.");if(f<0||f>1)throw new TypeError("Keyframe offsets must be between 0 and 1.")}}else if("composite"==d){if("add"==f||"accumulate"==f)throw{type:DOMException.NOT_SUPPORTED_ERR,name:"NotSupportedError",message:"add compositing is not supported"};if("replace"!=f)throw new TypeError("Invalid composite mode "+f+".")}else f="easing"==d?a.normalizeEasing(f):""+f;e(d,f,c)}return void 0==c.offset&&(c.offset=null),void 0==c.easing&&(c.easing="linear"),c}),g=!0,h=-1/0,i=0;i<d.length;i++){var j=d[i].offset;if(null!=j){if(j<h)throw new TypeError("Keyframes are not loosely sorted by offset. Sort or specify offsets.");h=j}else g=!1}return d=d.filter(function(a){return a.offset>=0&&a.offset<=1}),g||c(),d}var h={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"]},i=document.createElementNS("http://www.w3.org/1999/xhtml","div"),j={thin:"1px",medium:"3px",thick:"5px"},k={borderBottomWidth:j,borderLeftWidth:j,borderRightWidth:j,borderTopWidth:j,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:j,textShadow:{none:"0px 0px 0px transparent"},boxShadow:{none:"0px 0px 0px 0px transparent"}};a.convertToArrayForm=f,a.normalizeKeyframes=g}(c),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),!(g<h&&(a in b||console.warn("Web Animations: "+a+" "+f+" deprecated and will stop working on "+h.toDateString()+". "+d),b[a]=!0,1))},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,c){function d(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 e(c){var d=[];for(var e in c)for(var f=c[e],g=0;g<f.length-1;g++){var h=g,i=g+1,j=f[h].offset,k=f[i].offset,l=j,m=k;0==g&&(l=-1/0,0==k&&(i=h)),g==f.length-2&&(m=1/0,1==j&&(h=i)),d.push({applyFrom:l,applyTo:m,startOffset:f[h].offset,endOffset:f[i].offset,easingFunction:a.parseEasingFunction(f[h].easing),property:e,interpolation:b.propertyInterpolation(e,f[h].value,f[i].value)})}return d.sort(function(a,b){return a.startOffset-b.startOffset}),d}b.convertEffectInput=function(c){var f=a.normalizeKeyframes(c),g=d(f),h=e(g);return function(a,c){if(null!=c)h.filter(function(a){return c>=a.applyFrom&&c<a.applyTo}).forEach(function(d){var e=c-d.startOffset,f=d.endOffset-d.startOffset,g=0==f?0:d.easingFunction(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),function(a,b,c){function d(a){return a.replace(/-(.)/g,function(a,b){return b.toUpperCase()})}function e(a,b,c){h[c]=h[c]||[],h[c].push([a,b])}function f(a,b,c){for(var f=0;f<c.length;f++){e(a,b,d(c[f]))}}function g(c,e,f){var g=c;/-/.test(c)&&!a.isDeprecated("Hyphenated property names","2016-03-22","Use camelCase instead.",!0)&&(g=d(c)),"initial"!=e&&"initial"!=f||("initial"==e&&(e=i[g]),"initial"==f&&(f=i[g]));for(var j=e==f?[]:h[g],k=0;j&&k<j.length;k++){var l=j[k][0](e),m=j[k][0](f);if(void 0!==l&&void 0!==m){var n=j[k][1](l,m);if(n){var o=b.Interpolation.apply(null,n);return function(a){return 0==a?e:1==a?f:o(a)}}}}return b.Interpolation(!1,!0,function(a){return a?f:e})}var h={};b.addPropertiesHandler=f;var i={backgroundColor:"transparent",backgroundPosition:"0% 0%",borderBottomColor:"currentColor",borderBottomLeftRadius:"0px",borderBottomRightRadius:"0px",borderBottomWidth:"3px",borderLeftColor:"currentColor",borderLeftWidth:"3px",borderRightColor:"currentColor",borderRightWidth:"3px",borderSpacing:"2px",borderTopColor:"currentColor",borderTopLeftRadius:"0px",borderTopRightRadius:"0px",borderTopWidth:"3px",bottom:"auto",clip:"rect(0px, 0px, 0px, 0px)",color:"black",fontSize:"100%",fontWeight:"400",height:"auto",left:"auto",letterSpacing:"normal",lineHeight:"120%",marginBottom:"0px",marginLeft:"0px",marginRight:"0px",marginTop:"0px",maxHeight:"none",maxWidth:"none",minHeight:"0px",minWidth:"0px",opacity:"1.0",outlineColor:"invert",outlineOffset:"0px",outlineWidth:"3px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",paddingTop:"0px",right:"auto",strokeDasharray:"none",strokeDashoffset:"0px",textIndent:"0px",textShadow:"0px 0px 0px transparent",top:"auto",transform:"",verticalAlign:"0px",visibility:"visible",width:"auto",wordSpacing:"normal",zIndex:"auto"};b.propertyInterpolation=g}(c,d),function(a,b,c){function d(b){var c=a.calculateActiveDuration(b),d=function(d){return a.calculateIterationProgress(c,d,b)};return d._totalDuration=b.delay+c+b.endDelay,d}b.KeyframeEffect=function(c,e,f,g){var h,i=d(a.normalizeTimingInput(f)),j=b.convertEffectInput(e),k=function(){j(c,h)};return k._update=function(a){return null!==(h=i(a))},k._clear=function(){j(c,null)},k._hasSameTarget=function(a){return c===a},k._target=c,k._totalDuration=i._totalDuration,k._id=g,k}}(c,d),function(a,b){function c(a,b){return!(!b.namespaceURI||-1==b.namespaceURI.indexOf("/svg"))&&(g in a||(a[g]=/Trident|MSIE|IEMobile|Edge|Android 4/i.test(a.navigator.userAgent)),a[g])}function d(a,b,c){c.enumerable=!0,c.configurable=!0,Object.defineProperty(a,b,c)}function e(a){this._element=a,this._surrogateStyle=document.createElementNS("http://www.w3.org/1999/xhtml","div").style,this._style=a.style,this._length=0,this._isAnimatedProperty={},this._updateSvgTransformAttr=c(window,a),this._savedTransformAttr=null;for(var b=0;b<this._style.length;b++){var d=this._style[b];this._surrogateStyle[d]=this._style[d]}this._updateIndices()}function f(a){if(!a._webAnimationsPatchedStyle){var b=new e(a);try{d(a,"style",{get:function(){return b}})}catch(b){a.style._set=function(b,c){a.style[b]=c},a.style._clear=function(b){a.style[b]=""}}a._webAnimationsPatchedStyle=a.style}}var g="_webAnimationsUpdateSvgTransformAttr",h={cssText:1,length:1,parentRule:1},i={getPropertyCSSValue:1,getPropertyPriority:1,getPropertyValue:1,item:1,removeProperty:1,setProperty:1},j={removeProperty:1,setProperty:1};e.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(b,c){this._style[b]=c,this._isAnimatedProperty[b]=!0,this._updateSvgTransformAttr&&"transform"==a.unprefixedPropertyName(b)&&(null==this._savedTransformAttr&&(this._savedTransformAttr=this._element.getAttribute("transform")),this._element.setAttribute("transform",a.transformToSvgMatrix(c)))},_clear:function(b){this._style[b]=this._surrogateStyle[b],this._updateSvgTransformAttr&&"transform"==a.unprefixedPropertyName(b)&&(this._savedTransformAttr?this._element.setAttribute("transform",this._savedTransformAttr):this._element.removeAttribute("transform"),this._savedTransformAttr=null),delete this._isAnimatedProperty[b]}};for(var k in i)e.prototype[k]=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}}(k,k in j);for(var l in document.documentElement.style)l in h||l in i||function(a){d(e.prototype,a,{get:function(){return this._surrogateStyle[a]},set:function(b){this._surrogateStyle[a]=b,this._updateIndices(),this._isAnimatedProperty[a]||(this._style[a]=b)}})}(l);a.apply=function(b,c,d){f(b),b.style._set(a.propertyName(c),d)},a.clear=function(b,c){b._webAnimationsPatchedStyle&&b.style._clear(a.propertyName(c))}}(d),function(a){window.Element.prototype.animate=function(b,c){var d="";return c&&c.id&&(d=c.id),a.timeline._play(a.KeyframeEffect(this,b,c,d))}}(d),function(a,b){function c(a,b,d){if("number"==typeof a&&"number"==typeof b)return a*(1-d)+b*d;if("boolean"==typeof a&&"boolean"==typeof b)return d<.5?a:b;if(a.length==b.length){for(var e=[],f=0;f<a.length;f++)e.push(c(a[f],b[f],d));return e}throw"Mismatched interpolation arguments "+a+":"+b}a.Interpolation=function(a,b,d){return function(e){return d(c(a,b,e))}}}(d),function(a,b){function c(a,b,c){return Math.max(Math.min(a,c),b)}function d(b,d,e){var f=a.dot(b,d);f=c(f,-1,1);var g=[];if(1===f)g=b;else for(var h=Math.acos(f),i=1*Math.sin(e*h)/Math.sqrt(1-f*f),j=0;j<4;j++)g.push(b[j]*(Math.cos(e*h)-f*i)+d[j]*i);return g}var e=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;d<4;d++)for(var e=0;e<4;e++)for(var f=0;f<4;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;i<4;i++)h[i][3]=g[i];for(var i=0;i<3;i++)for(var j=0;j<3;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;i<3;i++)for(var j=0;j<3;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=e,a.quat=d}(d),function(a,b,c){a.sequenceNumber=0;var d=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()};b.Animation=function(b){this.id="",b&&b._id&&(this.id=b._id),this._sequenceNumber=a.sequenceNumber++,this._currentTime=0,this._startTime=null,this._paused=!1,this._playbackRate=1,this._inTimeline=!0,this._finishedFlag=!0,this.onfinish=null,this._finishHandlers=[],this._effect=b,this._inEffect=this._effect._update(0),this._idle=!0,this._currentTimePending=!1},b.Animation.prototype={_ensureAlive:function(){this.playbackRate<0&&0===this.currentTime?this._inEffect=this._effect._update(-1):this._inEffect=this._effect._update(this.currentTime),this._inTimeline||!this._inEffect&&this._finishedFlag||(this._inTimeline=!0,b.timeline._animations.push(this))},_tickCurrentTime:function(a,b){a!=this._currentTime&&(this._currentTime=a,this._isFinished&&!b&&(this._currentTime=this._playbackRate>0?this._totalDuration:0),this._ensureAlive())},get currentTime(){return this._idle||this._currentTimePending?null:this._currentTime},set currentTime(a){a=+a,isNaN(a)||(b.restart(),this._paused||null==this._startTime||(this._startTime=this._timeline.currentTime-a/this._playbackRate),this._currentTimePending=!1,this._currentTime!=a&&(this._idle&&(this._idle=!1,this._paused=!0),this._tickCurrentTime(a,!0),b.applyDirtiedAnimation(this)))},get startTime(){return this._startTime},set startTime(a){a=+a,isNaN(a)||this._paused||this._idle||(this._startTime=a,this._tickCurrentTime((this._timeline.currentTime-this._startTime)*this.playbackRate),b.applyDirtiedAnimation(this))},get playbackRate(){return this._playbackRate},set playbackRate(a){if(a!=this._playbackRate){var c=this.currentTime;this._playbackRate=a,this._startTime=null,"paused"!=this.playState&&"idle"!=this.playState&&(this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),b.applyDirtiedAnimation(this)),null!=c&&(this.currentTime=c)}},get _isFinished(){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._isFinished?"finished":"running"},_rewind:function(){if(this._playbackRate>=0)this._currentTime=0;else{if(!(this._totalDuration<1/0))throw new DOMException("Unable to rewind negative playback rate animation with infinite duration","InvalidStateError");this._currentTime=this._totalDuration}},play:function(){this._paused=!1,(this._isFinished||this._idle)&&(this._rewind(),this._startTime=null),this._finishedFlag=!1,this._idle=!1,this._ensureAlive(),b.applyDirtiedAnimation(this)},pause:function(){this._isFinished||this._paused||this._idle?this._idle&&(this._rewind(),this._idle=!1):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,b.applyDirtiedAnimation(this))},cancel:function(){this._inEffect&&(this._inEffect=!1,this._idle=!0,this._paused=!1,this._isFinished=!0,this._finishedFlag=!0,this._currentTime=0,this._startTime=null,this._effect._update(null),b.applyDirtiedAnimation(this))},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){if(this._isFinished){if(!this._finishedFlag){var b=new d(this,this._currentTime,a),c=this._finishHandlers.concat(this.onfinish?[this.onfinish]:[]);setTimeout(function(){c.forEach(function(a){a.call(b.target,b)})},0),this._finishedFlag=!0}}else this._finishedFlag=!1},_tick:function(a,b){this._idle||this._paused||(null==this._startTime?b&&(this.startTime=a-this._currentTime/this.playbackRate):this._isFinished||this._tickCurrentTime((a-this._startTime)*this.playbackRate)),b&&(this._currentTimePending=!1,this._fireEvents(a))},get _needsTick(){return this.playState in{pending:1,running:1}||!this._finishedFlag},_targetAnimations:function(){var a=this._effect._target;return a._activeAnimations||(a._activeAnimations=[]),a._activeAnimations},_markTarget:function(){var a=this._targetAnimations();-1===a.indexOf(this)&&a.push(this)},_unmarkTarget:function(){var a=this._targetAnimations(),b=a.indexOf(this);-1!==b&&a.splice(b,1)}}}(c,d),function(a,b,c){function d(a){var b=j;j=[],a<q.currentTime&&(a=q.currentTime),q._animations.sort(e),q._animations=h(a,!0,q._animations)[0],b.forEach(function(b){b[1](a)}),g(),l=void 0}function e(a,b){return a._sequenceNumber-b._sequenceNumber}function f(){this._animations=[],this.currentTime=window.performance&&performance.now?performance.now():0}function g(){o.forEach(function(a){a()}),o.length=0}function h(a,c,d){p=!0,n=!1,b.timeline.currentTime=a,m=!1;var e=[],f=[],g=[],h=[];return d.forEach(function(b){b._tick(a,c),b._inEffect?(f.push(b._effect),b._markTarget()):(e.push(b._effect),b._unmarkTarget()),b._needsTick&&(m=!0);var d=b._inEffect||b._needsTick;b._inTimeline=d,d?g.push(b):h.push(b)}),o.push.apply(o,e),o.push.apply(o,f),m&&requestAnimationFrame(function(){}),p=!1,[g,h]}var i=window.requestAnimationFrame,j=[],k=0;window.requestAnimationFrame=function(a){var b=k++;return 0==j.length&&i(d),j.push([b,a]),b},window.cancelAnimationFrame=function(a){j.forEach(function(b){b[0]==a&&(b[1]=function(){})})},f.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.applyDirtiedAnimation(d),d}};var l=void 0,m=!1,n=!1;b.restart=function(){return m||(m=!0,requestAnimationFrame(function(){}),n=!0),n},b.applyDirtiedAnimation=function(a){if(!p){a._markTarget();var c=a._targetAnimations();c.sort(e),h(b.timeline.currentTime,!1,c.slice())[1].forEach(function(a){var b=q._animations.indexOf(a);-1!==b&&q._animations.splice(b,1)}),g()}};var o=[],p=!1,q=new f;b.timeline=q}(c,d),function(a,b){function c(a,b){for(var c=0,d=0;d<a.length;d++)c+=a[d]*b[d];return c}function d(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 e(a){var b=a.rad||0;return((a.deg||0)/360+(a.grad||0)/400+(a.turn||0))*(2*Math.PI)+b}function f(a){switch(a.t){case"rotatex":var b=e(a.d[0]);return[1,0,0,0,0,Math.cos(b),Math.sin(b),0,0,-Math.sin(b),Math.cos(b),0,0,0,0,1];case"rotatey":var b=e(a.d[0]);return[Math.cos(b),0,-Math.sin(b),0,0,1,0,0,Math.sin(b),0,Math.cos(b),0,0,0,0,1];case"rotate":case"rotatez":var b=e(a.d[0]);return[Math.cos(b),Math.sin(b),0,0,-Math.sin(b),Math.cos(b),0,0,0,0,1,0,0,0,0,1];case"rotate3d":var c=a.d[0],d=a.d[1],f=a.d[2],b=e(a.d[3]),g=c*c+d*d+f*f;if(0===g)c=1,d=0,f=0;else if(1!==g){var h=Math.sqrt(g);c/=h,d/=h,f/=h}var i=Math.sin(b/2),j=i*Math.cos(b/2),k=i*i;return[1-2*(d*d+f*f)*k,2*(c*d*k+f*j),2*(c*f*k-d*j),0,2*(c*d*k-f*j),1-2*(c*c+f*f)*k,2*(d*f*k+c*j),0,2*(c*f*k+d*j),2*(d*f*k-c*j),1-2*(c*c+d*d)*k,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 l=e(a.d[0]),m=e(a.d[1]);return[1,Math.tan(m),0,0,Math.tan(l),1,0,0,0,0,1,0,0,0,0,1];case"skewx":var b=e(a.d[0]);return[1,0,0,0,Math.tan(b),1,0,0,0,0,1,0,0,0,0,1];case"skewy":var b=e(a.d[0]);return[1,Math.tan(b),0,0,0,1,0,0,0,0,1,0,0,0,0,1];case"translate":var c=a.d[0].px||0,d=a.d[1].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,c,d,0,1];case"translatex":var c=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,c,0,0,1];case"translatey":var d=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,d,0,1];case"translatez":var f=a.d[0].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,f,1];case"translate3d":var c=a.d[0].px||0,d=a.d[1].px||0,f=a.d[2].px||0;return[1,0,0,0,0,1,0,0,0,0,1,0,c,d,f,1];case"perspective":return[1,0,0,0,0,1,0,0,0,0,1,a.d[0].px?-1/a.d[0].px:0,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 g(a){return 0===a.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:a.map(f).reduce(d)}function h(a){return[i(g(a))]}var i=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 b(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;o<3;o++){for(var p=0,q=0;q<3;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;d<4;d++){for(var e=0,f=0;f<4;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;m<4;m++)l.push(k[m].slice());for(var m=0;m<3;m++)l[m][3]=0;if(0===a(l))return null;var n,o=[];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]),n=e(o,d(b(l)))):n=[0,0,0,1];var p=k[3].slice(0,3),q=[];q.push(k[0].slice(0,3));var r=[];r.push(g(q[0])),q[0]=f(q[0]);var s=[];q.push(k[1].slice(0,3)),s.push(c(q[0],q[1])),q[1]=h(q[1],q[0],1,-s[0]),r.push(g(q[1])),q[1]=f(q[1]),s[0]/=r[1],q.push(k[2].slice(0,3)),s.push(c(q[0],q[2])),q[2]=h(q[2],q[0],1,-s[1]),s.push(c(q[1],q[2])),q[2]=h(q[2],q[1],1,-s[2]),r.push(g(q[2])),q[2]=f(q[2]),s[1]/=r[2],s[2]/=r[2];var t=i(q[1],q[2]);if(c(q[0],t)<0)for(var m=0;m<3;m++)r[m]*=-1,q[m][0]*=-1,q[m][1]*=-1,q[m][2]*=-1;var u,v,w=q[0][0]+q[1][1]+q[2][2]+1;return w>1e-4?(u=.5/Math.sqrt(w),v=[(q[2][1]-q[1][2])*u,(q[0][2]-q[2][0])*u,(q[1][0]-q[0][1])*u,.25/u]):q[0][0]>q[1][1]&&q[0][0]>q[2][2]?(u=2*Math.sqrt(1+q[0][0]-q[1][1]-q[2][2]),v=[.25*u,(q[0][1]+q[1][0])/u,(q[0][2]+q[2][0])/u,(q[2][1]-q[1][2])/u]):q[1][1]>q[2][2]?(u=2*Math.sqrt(1+q[1][1]-q[0][0]-q[2][2]),v=[(q[0][1]+q[1][0])/u,.25*u,(q[1][2]+q[2][1])/u,(q[0][2]-q[2][0])/u]):(u=2*Math.sqrt(1+q[2][2]-q[0][0]-q[1][1]),v=[(q[0][2]+q[2][0])/u,(q[1][2]+q[2][1])/u,.25*u,(q[1][0]-q[0][1])/u]),[p,r,s,v,n]}return j}();a.dot=c,a.makeMatrixDecomposition=h,a.transformListToMatrix=g}(d),function(a){function b(a,b){var c=a.exec(b);if(c)return c=a.ignoreCase?c[0].toLowerCase():c[0],[c,b.substr(c.length)]}function c(a,b){b=b.replace(/^\s*/,"");var c=a(b);if(c)return[c[0],c[1].replace(/^\s*/,"")]}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[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++,c<=0))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){return a(c)||[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]}if(""==c)return d}function j(a,b,c,d,e){for(var g=[],h=[],i=[],j=f(d.length,e.length),k=0;k<j;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);if(e&&e[0].length)return[d,e[1]]}function c(c){var d=a.consumeRepeated(b,/^,/,c);if(d&&""==d[1])return d[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,b){function c(a){return a.toFixed(3).replace(/0+$/,"").replace(/\.$/,"")}function d(a,b,c){return Math.min(b,Math.max(a,c))}function e(a){if(/^\s*[-+]?(\d*\.)?\d+\s*$/.test(a))return Number(a)}function f(a,b){return[a,b,c]}function g(a,b){if(0!=a)return i(0,1/0)(a,b)}function h(a,b){return[a,b,function(a){return Math.round(d(1,1/0,a))}]}function i(a,b){return function(e,f){return[e,f,function(e){return c(d(a,b,e))}]}}function j(a){var b=a.trim().split(/\s*[\s,]\s*/);if(0!==b.length){for(var c=[],d=0;d<b.length;d++){var f=e(b[d]);if(void 0===f)return;c.push(f)}return c}}function k(a,b){if(a.length==b.length)return[a,b,function(a){return a.map(c).join(" ")}]}function l(a,b){return[a,b,Math.round]}a.clamp=d,a.addPropertiesHandler(j,k,["stroke-dasharray"]),a.addPropertiesHandler(e,i(0,1/0),["border-image-width","line-height"]),a.addPropertiesHandler(e,i(0,1),["opacity","shape-image-threshold"]),a.addPropertiesHandler(e,g,["flex-grow","flex-shrink"]),a.addPropertiesHandler(e,h,["orphans","widows"]),a.addPropertiesHandler(e,l,["z-index"]),a.parseNumber=e,a.parseNumberList=j,a.mergeNumbers=f,a.numberToString=c}(d),function(a,b){function c(a,b){if("visible"==a||"visible"==b)return[0,1,function(c){return c<=0?a:c>=1?b:"visible"}]}a.addPropertiesHandler(String,c,["visibility"])}(d),function(a,b){function c(a){a=a.trim(),f.fillStyle="#000",f.fillStyle=a;var b=f.fillStyle;if(f.fillStyle="#fff",f.fillStyle=a,b==f.fillStyle){f.fillRect(0,0,1,1);var c=f.getImageData(0,0,1,1).data;f.clearRect(0,0,1,1);var d=c[3]/255;return[c[0]*d,c[1]*d,c[2]*d,d]}}function d(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;d<3;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 e=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");e.width=e.height=1;var f=e.getContext("2d");a.addPropertiesHandler(c,d,["background-color","border-bottom-color","border-left-color","border-right-color","border-top-color","color","fill","flood-color","lighting-color","outline-color","stop-color","stroke","text-decoration-color"]),a.consumeColor=a.consumeParenthesised.bind(null,c),a.mergeColors=d}(d),function(a,b){function c(a){function b(){var b=h.exec(a);g=b?b[0]:void 0}function c(){var a=Number(g);return b(),a}function d(){if("("!==g)return c();b();var a=f();return")"!==g?NaN:(b(),a)}function e(){for(var a=d();"*"===g||"/"===g;){var c=g;b();var e=d();"*"===c?a*=e:a/=e}return a}function f(){for(var a=e();"+"===g||"-"===g;){var c=g;b();var d=e();"+"===c?a+=d:a-=d}return a}var g,h=/([\+\-\w\.]+|[\(\)\*\/])/g;return b(),f()}function d(a,b){if("0"==(b=b.trim().toLowerCase())&&"px".search(a)>=0)return{px:0};if(/^[^(]*$|^calc/.test(b)){b=b.replace(/calc\(/g,"(");var d={};b=b.replace(a,function(a){return d[a]=null,"U"+a});for(var e="U("+a.source+")",f=b.replace(/[-+]?(\d*\.)?\d+([Ee][-+]?\d+)?/g,"N").replace(new RegExp("N"+e,"g"),"D").replace(/\s[+-]\s/g,"O").replace(/\s/g,""),g=[/N\*(D)/g,/(N|D)[*\/]N/g,/(N|D)O\1/g,/\((N|D)\)/g],h=0;h<g.length;)g[h].test(f)?(f=f.replace(g[h],"$1"),h=0):h++;if("D"==f){for(var i in d){var j=c(b.replace(new RegExp("U"+i,"g"),"").replace(new RegExp(e,"g"),"*0"));if(!isFinite(j))return;d[i]=j}return d}}}function e(a,b){return f(a,b,!0)}function f(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 g="px|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc",h=d.bind(null,new RegExp(g,"g")),i=d.bind(null,new RegExp(g+"|%","g")),j=d.bind(null,/deg|rad|grad|turn/g);a.parseLength=h,a.parseLengthOrPercent=i,a.consumeLengthOrPercent=a.consumeParenthesised.bind(null,i),a.parseAngle=j,a.mergeDimensions=f;var k=a.consumeParenthesised.bind(null,h),l=a.consumeRepeated.bind(void 0,k,/^/),m=a.consumeRepeated.bind(void 0,l,/^,/);a.consumeSizePairList=m;var n=function(a){var b=m(a);if(b&&""==b[1])return b[0]},o=a.mergeNestedRepeated.bind(void 0,e," "),p=a.mergeNestedRepeated.bind(void 0,o,",");a.mergeNonNegativeSizePair=o,a.addPropertiesHandler(n,p,["background-size"]),a.addPropertiesHandler(i,e,["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(i,f,["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","stroke-dashoffset","text-indent","top","vertical-align","word-spacing"])}(d),function(a,b){function c(b){return a.consumeLengthOrPercent(b)||a.consumeToken(/^auto/,b)}function d(b){var d=a.consumeList([a.ignore(a.consumeToken.bind(null,/^rect/)),a.ignore(a.consumeToken.bind(null,/^\(/)),a.consumeRepeated.bind(null,c,/^,/),a.ignore(a.consumeToken.bind(null,/^\)/))],b);if(d&&4==d[0].length)return d[0]}function e(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 f(a){return"rect("+a+")"}var g=a.mergeWrappedNestedRepeated.bind(null,f,e,", ");a.parseBox=d,a.mergeBoxes=g,a.addPropertiesHandler(d,g,["clip"])}(d),function(a,b){function c(a){return function(b){var c=0;return a.map(function(a){return a===k?b[c++]:a})}}function d(a){return a}function e(b){if("none"==(b=b.toLowerCase().trim()))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=n[g];if(!h)return;var i=c[2].split(","),j=h[0];if(j.length<i.length)return;for(var k=[],o=0;o<j.length;o++){var p,q=i[o],r=j[o];if(void 0===(p=q?{A:function(b){return"0"==b.trim()?m:a.parseAngle(b)},N:a.parseNumber,T:a.parseLengthOrPercent,L:a.parseLength}[r.toUpperCase()](q):{a:m,n:k[0],t:l}[r]))return;k.push(p)}if(e.push({t:g,d:k}),d.lastIndex==b.length)return e}}function f(a){return a.toFixed(6).replace(".000000","")}function g(b,c){if(b.decompositionPair!==c){b.decompositionPair=c;var d=a.makeMatrixDecomposition(b)}if(c.decompositionPair!==b){c.decompositionPair=b;var e=a.makeMatrixDecomposition(c)}return null==d[0]||null==e[0]?[[!1],[!0],function(a){return a?c[0].d:b[0].d}]:(d[0].push(0),e[0].push(1),[d,e,function(b){var c=a.quat(d[0][3],e[0][3],b[5]);return a.composeMatrix(b[0],b[1],b[2],c,b[4]).map(f).join(",")}])}function h(a){return a.replace(/[xy]/,"")}function i(a){return a.replace(/(x|y|z|3d)?$/,"3d")}function j(b,c){var d=a.makeMatrixDecomposition&&!0,e=!1;if(!b.length||!c.length){b.length||(e=!0,b=c,c=[]);for(var f=0;f<b.length;f++){var j=b[f].t,k=b[f].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 m=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=g(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]]}else for(var f=0;f<b.length;f++){var j,s=b[f].t,t=c[f].t,u=b[f].d,v=c[f].d,w=n[s],x=n[t];if(m(s,t)){if(!d)return;var r=g([b[f]],[c[f]]);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]&&h(s)==h(t))j=h(s),u=w[2](u),v=x[2](v);else{if(!w[1]||!x[1]||i(s)!=i(t)){if(!d)return;var r=g(b,c);o=[r[0]],p=[r[1]],q=[["matrix",[r[2]]]];break}j=i(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 k=null,l={px:0},m={deg:0},n={matrix:["NNNNNN",[k,k,0,0,k,k,0,0,0,0,1,0,k,k,0,1],d],matrix3d:["NNNNNNNNNNNNNNNN",d],rotate:["A"],rotatex:["A"],rotatey:["A"],rotatez:["A"],rotate3d:["NNNA"],perspective:["L"],scale:["Nn",c([k,k,1]),d],scalex:["N",c([k,1,1]),c([k,1])],scaley:["N",c([1,k,1]),c([1,k])],scalez:["N",c([1,1,k])],scale3d:["NNN",d],skew:["Aa",null,d],skewx:["A",null,c([k,m])],skewy:["A",null,c([m,k])],translate:["Tt",c([k,k,l]),d],translatex:["T",c([k,l,l]),c([k,l])],translatey:["T",c([l,k,l]),c([l,k])],translatez:["L",c([l,l,k])],translate3d:["TTL",d]};a.addPropertiesHandler(e,j,["transform"]),a.transformToSvgMatrix=function(b){var c=a.transformListToMatrix(e(b));return"matrix("+f(c[0])+" "+f(c[1])+" "+f(c[4])+" "+f(c[5])+" "+f(c[12])+" "+f(c[13])+")"}}(d),function(a){function b(a){var b=Number(a);if(!(isNaN(b)||b<100||b>900||b%100!=0))return 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);if(c&&""==c[1])return c[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){if(b[0]===c[0])return"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}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,b){function c(a,b){b.concat([a]).forEach(function(b){b in document.documentElement.style&&(d[a]=b),e[b]=a})}var d={},e={};c("transform",["webkitTransform","msTransform"]),c("transformOrigin",["webkitTransformOrigin"]),c("perspective",["webkitPerspective"]),c("perspectiveOrigin",["webkitPerspectiveOrigin"]),a.propertyName=function(a){return d[a]||a},a.unprefixedPropertyName=function(a){return e[a]||a}}(d)}(),function(){if(void 0===document.createElement("div").animate([]).oncancel){var a;if(window.performance&&performance.now)var a=function(){return performance.now()};else var a=function(){return Date.now()};var b=function(a,b,c){this.target=a,this.currentTime=b,this.timelineTime=c,this.type="cancel",this.bubbles=!1,this.cancelable=!1,this.currentTarget=a,this.defaultPrevented=!1,this.eventPhase=Event.AT_TARGET,this.timeStamp=Date.now()},c=window.Element.prototype.animate;window.Element.prototype.animate=function(d,e){var f=c.call(this,d,e);f._cancelHandlers=[],f.oncancel=null;var g=f.cancel;f.cancel=function(){g.call(this);var c=new b(this,null,a()),d=this._cancelHandlers.concat(this.oncancel?[this.oncancel]:[]);setTimeout(function(){d.forEach(function(a){a.call(c.target,c)})},0)};var h=f.addEventListener;f.addEventListener=function(a,b){"function"==typeof b&&"cancel"==a?this._cancelHandlers.push(b):h.call(this,a,b)};var i=f.removeEventListener;return f.removeEventListener=function(a,b){if("cancel"==a){var c=this._cancelHandlers.indexOf(b);c>=0&&this._cancelHandlers.splice(c,1)}else i.call(this,a,b)},f}}}(),function(a){var b=document.documentElement,c=null,d=!1;try{var e=getComputedStyle(b).getPropertyValue("opacity"),f="0"==e?"1":"0";c=b.animate({opacity:[f,f]},{duration:1}),c.currentTime=0,d=getComputedStyle(b).getPropertyValue("opacity")==f}catch(a){}finally{c&&c.cancel()}if(!d){var g=window.Element.prototype.animate;window.Element.prototype.animate=function(b,c){return window.Symbol&&Symbol.iterator&&Array.prototype.from&&b[Symbol.iterator]&&(b=Array.from(b)),Array.isArray(b)||null===b||(b=a.convertToArrayForm(b)),g.call(this,b,c)}}}(c),b.true=a}({},function(){return this}());
+//# sourceMappingURL=web-animations.min.js.map \ No newline at end of file
diff --git a/catapult/third_party/polymer/components/web-animations-js/web-animations.min.js.map b/catapult/third_party/polymer/components/web-animations-js/web-animations.min.js.map
new file mode 100644
index 00000000..c78ace0f
--- /dev/null
+++ b/catapult/third_party/polymer/components/web-animations-js/web-animations.min.js.map
@@ -0,0 +1 @@
+{"version":3,"sources":["src/scope.js","src/timing-utilities.js","src/normalize-keyframes.js","src/deprecation.js","src/web-animations-bonus-cancel-events.js","src/web-animations-bonus-object-form-keyframes.js"],"names":["webAnimationsShared","webAnimations1","shared","testing","cloneTimingInput","timingInput","clone","m","AnimationEffectTiming","this","_delay","_endDelay","_fill","_iterationStart","_iterations","_duration","_playbackRate","_direction","_easing","_easingFunction","linear","isInvalidTimingDeprecated","isDeprecated","makeTiming","forGroup","effect","timing","fill","duration","isNaN","Object","getOwnPropertyNames","forEach","property","fills","indexOf","directions","numericTimingToObject","normalizeTimingInput","cubic","a","b","c","d","x","f","start_gradient","end_gradient","start","end","mid","xEst","Math","abs","step","count","pos","stepSize","normalizeEasing","easing","styleForCleaning","document","createElement","style","animationTimingFunction","normalizedEasing","TypeError","parseEasingFunction","cubicData","cubicBezierRe","exec","apply","slice","map","Number","stepData","stepRe","Start","middle","Middle","End","presets","calculateActiveDuration","repeatedDuration","playbackRate","iterations","calculatePhase","activeDuration","localTime","PhaseNone","endTime","delay","endDelay","min","PhaseBefore","PhaseAfter","PhaseActive","calculateActiveTime","fillMode","phase","calculateOverallProgress","iterationDuration","activeTime","iterationStart","overallProgress","calculateSimpleIterationProgress","simpleIterationProgress","Infinity","calculateCurrentIteration","floor","calculateDirectedProgress","playbackDirection","currentIteration","currentDirection","calculateIterationProgress","directedProgress","direction","split","prototype","_setMember","member","value","_effect","_timingInput","_timing","_animation","_rebuildUnderlyingAnimation","ease","ease-in","ease-out","ease-in-out","step-start","step-middle","step-end","numberString","RegExp","antiAlias","aliases","isNotAnimatable","lastIndexOf","expandShorthandAndAntiAlias","result","longProperties","shorthandToLonghand","shorthandExpanderElem","i","longProperty","longhandValue","convertToArrayForm","effectInput","normalizedEffectInput","values","Array","isArray","keyframe","numKeyframes","length","offset","composite","push","sort","normalizeKeyframes","spaceKeyframes","keyframes","previousIndex","previousOffset","j","window","Symbol","iterator","from","originalKeyframe","memberValue","isFinite","type","DOMException","NOT_SUPPORTED_ERR","name","message","everyFrameHasOffset","filter","background","border","borderBottom","borderColor","borderLeft","borderRadius","borderRight","borderTop","borderWidth","flex","font","margin","outline","padding","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","animate","oncancel","now","performance","AnimationCancelEvent","target","currentTime","timelineTime","bubbles","cancelable","currentTarget","defaultPrevented","eventPhase","Event","AT_TARGET","timeStamp","originalElementAnimate","Element","options","animation","call","_cancelHandlers","originalCancel","cancel","event","handlers","concat","setTimeout","handler","originalAddEventListener","addEventListener","originalRemoveEventListener","removeEventListener","index","splice","element","documentElement","animated","originalOpacity","getComputedStyle","getPropertyValue","testOpacity","opacity","error","webAnimationsNext","exports","webAnimationsTesting"],"mappings":";;;;;;;;;;;;;;CAcA,SAAIA,EAAAA,GAAJ,GAAIA,MACAC,MCDJ,SAAUC,EAAQC,GAMhB,QAASC,GAAiBC,GACxB,GAA0B,gBAAfA,GACT,MAAOA,EAET,IAAIC,KACJ,KAAK,GAAIC,KAAKF,GACZC,EAAMC,GAAKF,EAAYE,EAEzB,OAAOD,GAGT,QAASE,KACPC,KAAKC,OAAS,EACdD,KAAKE,UAAY,EACjBF,KAAKG,MAAQ,OACbH,KAAKI,gBAAkB,EACvBJ,KAAKK,YAAc,EACnBL,KAAKM,UAAY,EACjBN,KAAKO,cAAgB,EACrBP,KAAKQ,WAAa,SAClBR,KAAKS,QAAU,SACfT,KAAKU,gBAAkBC,EAGzB,QAASC,KACP,MAAOnB,GAAOoB,aAAa,wBAAyB,aAAc,gDAAA,GA8EpE,QAASC,GAAWlB,EAAamB,EAAUC,GACzC,GAAIC,GAAS,GAAIlB,EA4BjB,OA3BIgB,KACFE,EAAOC,KAAO,OACdD,EAAOE,SAAW,QAEM,gBAAfvB,IAA4BwB,MAAMxB,OAAAA,KAElCA,GACTyB,OAAOC,oBAAoB1B,GAAa2B,QAAQ,SAASC,GACvD,GAA6B,QAAzB5B,EAAY4B,GAAqB,CACnC,IAA+B,gBAApBP,GAAOO,IAAqC,YAAZA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