| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 Polymer((function() { | 5 Polymer((function() { |
| 6 /** @const */ var ICON_COLORS = ['#F0B9CB', '#F0ACC3', '#F098B6', '#F084A9', | 6 /** @const */ var ICON_COLORS = ['#F0B9CB', '#F0ACC3', '#F098B6', '#F084A9', |
| 7 '#F06D99', '#F05287', '#F0467F', '#F03473', | 7 '#F06D99', '#F05287', '#F0467F', '#F03473', |
| 8 '#F01E65', '#F00051']; | 8 '#F01E65', '#F00051']; |
| 9 return { | 9 return { |
| 10 is: 'pairing-device-list', | 10 is: 'pairing-device-list', |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 for (var i = 0; i < name.length; ++i) | 33 for (var i = 0; i < name.length; ++i) |
| 34 hash = (name.charCodeAt(i) + 31 * hash) | 0; | 34 hash = (name.charCodeAt(i) + 31 * hash) | 0; |
| 35 return ICON_COLORS[hash % ICON_COLORS.length]; | 35 return ICON_COLORS[hash % ICON_COLORS.length]; |
| 36 } | 36 } |
| 37 }; | 37 }; |
| 38 })()); | 38 })()); |
| 39 | 39 |
| 40 Polymer({ | 40 Polymer({ |
| 41 is: 'controller-pairing-page', | 41 is: 'controller-pairing-page', |
| 42 | 42 |
| 43 behaviors: [ | 43 behaviors: [Polymer.NeonAnimatableBehavior], |
| 44 Polymer.NeonSharedElementAnimatableBehavior | |
| 45 ], | |
| 46 | 44 |
| 47 properties: { | 45 properties: { |
| 48 sharedElements: { | |
| 49 value: function() { | |
| 50 return { | |
| 51 'top-hero': this.$.top, | |
| 52 'bottom-hero': this.$.bottom | |
| 53 }; | |
| 54 } | |
| 55 }, | |
| 56 | |
| 57 animationConfig: { | 46 animationConfig: { |
| 58 value: function() { | 47 value: function() { |
| 59 return { | 48 return { |
| 60 'entry': [{ | 49 'entry': [{ |
| 61 name: 'hero-animation', | |
| 62 id: 'top-hero', | |
| 63 toPage: this | |
| 64 }, { | |
| 65 name: 'hero-animation', | |
| 66 id: 'bottom-hero', | |
| 67 toPage: this | |
| 68 }, { | |
| 69 name: 'fade-in-animation', | 50 name: 'fade-in-animation', |
| 70 node: this | 51 node: this |
| 71 }], | 52 }], |
| 72 | 53 |
| 73 'exit': [{ | 54 'exit': [{ |
| 74 name: 'hero-animation', | |
| 75 id: 'top-hero', | |
| 76 fromPage: this | |
| 77 }, { | |
| 78 name: 'hero-animation', | |
| 79 id: 'bottom-hero', | |
| 80 fromPage: this | |
| 81 }, { | |
| 82 name: 'fade-out-animation', | 55 name: 'fade-out-animation', |
| 83 node: this | 56 node: this |
| 84 }] | 57 }] |
| 85 }; | 58 }; |
| 86 } | 59 } |
| 87 } | 60 } |
| 88 } | 61 } |
| 89 }); | 62 }); |
| 90 | 63 |
| 91 Polymer((function() { | 64 Polymer((function() { |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 getHostEnrollmentStepTitle_: function(domain) { | 132 getHostEnrollmentStepTitle_: function(domain) { |
| 160 return this.i18n(['enrollmentInProgress', domain]); | 133 return this.i18n(['enrollmentInProgress', domain]); |
| 161 }, | 134 }, |
| 162 | 135 |
| 163 getSuccessMessage_: function(selectedDevice) { | 136 getSuccessMessage_: function(selectedDevice) { |
| 164 return this.i18n(['successText', selectedDevice]); | 137 return this.i18n(['successText', selectedDevice]); |
| 165 } | 138 } |
| 166 }; | 139 }; |
| 167 })()); | 140 })()); |
| 168 | 141 |
| OLD | NEW |