1 <!doctype html> 2 <!-- 3 @license 4 Copyright (c) 2015 The Polymer Project Authors. All rights reserved. 5 This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt 6 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt 7 The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt 8 Code distributed by Google as part of the polymer project is also 9 subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt 10 --> 11 <html> 12 <head> 13 <title>neon-animated-pages demo: tiles</title> 14 15 <meta charset="utf-8"> 16 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> 17 <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"> 18 19 <script src="../../../webcomponentsjs/webcomponents-lite.js"></script> 20 21 <link rel="import" href="../../../iron-flex-layout/iron-flex-layout.html"> 22 <link rel="import" href="../../neon-animated-pages.html"> 23 <link rel="import" href="../../neon-animations.html"> 24 <link rel="import" href="../../../paper-styles/color.html"> 25 <link rel="import" href="circles-page.html"> 26 <link rel="import" href="squares-page.html"> 27 28 <style is="custom-style"> 29 body { 30 overflow: hidden; 31 @apply(--layout-fullbleed); 32 } 33 neon-animated-pages { 34 height: 100%; 35 } 36 37 :root { 38 --color-one: var(--paper-cyan-300); 39 --color-two: var(--paper-orange-500); 40 } 41 </style> 42 43 </head> 44 <body> 45 46 <template is="dom-bind"> 47 48 <neon-animated-pages id="pages" selected="0"> 49 <circles-page on-circle-click="_onCircleClick"></circles-page> 50 <squares-page on-click="_onSquaresClick"></squares-page> 51 </neon-animated-pages> 52 53 </template> 54 55 <script> 56 57 var scope = document.querySelector('template[is="dom-bind"]'); 58 59 scope._onCircleClick = function(event) { 60 this.$.pages.selected = 1; 61 }; 62 63 scope._onSquaresClick = function(event) { 64 this.$.pages.selected = 0; 65 }; 66 67 </script> 68 69 </body> 70 </html> 71