OLD | NEW |
1 | 1 |
2 | 2 |
3 Polymer({ | 3 Polymer({ |
4 | 4 |
5 is: 'iron-collapse', | 5 is: 'iron-collapse', |
6 | 6 |
7 properties: { | 7 properties: { |
8 | 8 |
9 /** | 9 /** |
10 * If true, the orientation is horizontal; otherwise is vertical. | 10 * If true, the orientation is horizontal; otherwise is vertical. |
(...skipping 15 matching lines...) Expand all Loading... |
26 type: Boolean, | 26 type: Boolean, |
27 value: false, | 27 value: false, |
28 notify: true, | 28 notify: true, |
29 observer: '_openedChanged' | 29 observer: '_openedChanged' |
30 } | 30 } |
31 | 31 |
32 }, | 32 }, |
33 | 33 |
34 hostAttributes: { | 34 hostAttributes: { |
35 role: 'group', | 35 role: 'group', |
36 'aria-expanded': 'false', | 36 'aria-expanded': 'false' |
37 tabindex: 0 | |
38 }, | 37 }, |
39 | 38 |
40 listeners: { | 39 listeners: { |
41 transitionend: '_transitionEnd' | 40 transitionend: '_transitionEnd' |
42 }, | 41 }, |
43 | 42 |
44 ready: function() { | 43 ready: function() { |
45 // Avoid transition at the beginning e.g. page loads and enable | 44 // Avoid transition at the beginning e.g. page loads and enable |
46 // transitions only after the element is rendered and ready. | 45 // transitions only after the element is rendered and ready. |
47 this._enableTransition = true; | 46 this._enableTransition = true; |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 this.enableTransition(false); | 107 this.enableTransition(false); |
109 }, | 108 }, |
110 | 109 |
111 _calcSize: function() { | 110 _calcSize: function() { |
112 return this.getBoundingClientRect()[this.dimension] + 'px'; | 111 return this.getBoundingClientRect()[this.dimension] + 'px'; |
113 }, | 112 }, |
114 | 113 |
115 | 114 |
116 }); | 115 }); |
117 | 116 |
OLD | NEW |