Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(133)

Side by Side Diff: polymer_0.5.0/bower_components/core-iconset-svg/core-iconset-svg.html

Issue 786953007: npm_modules: Fork bower_components into Polymer 0.4.0 and 0.5.0 versions (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!-- 1 <!--
2 Copyright (c) 2014 The Polymer Project Authors. All rights reserved. 2 Copyright (c) 2014 The Polymer Project Authors. All rights reserved.
3 This code may only be used under the BSD style license found at http://polymer.g ithub.io/LICENSE.txt 3 This code may only be used under the BSD style license found at http://polymer.g ithub.io/LICENSE.txt
4 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt 4 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
5 The complete set of contributors may be found at http://polymer.github.io/CONTRI BUTORS.txt 5 The complete set of contributors may be found at http://polymer.github.io/CONTRI BUTORS.txt
6 Code distributed by Google as part of the polymer project is also 6 Code distributed by Google as part of the polymer project is also
7 subject to an additional IP rights grant found at http://polymer.github.io/PATEN TS.txt 7 subject to an additional IP rights grant found at http://polymer.github.io/PATEN TS.txt
8 --> 8 -->
9 9
10 <!-- 10 <!--
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 created: function() { 69 created: function() {
70 this._icons = {}; 70 this._icons = {};
71 }, 71 },
72 72
73 ready: function() { 73 ready: function() {
74 this.super(); 74 this.super();
75 this.updateIcons(); 75 this.updateIcons();
76 }, 76 },
77 77
78 iconById: function(id) { 78 iconById: function(id) {
79 return this._icons[id] || (this._icons[id] = this.querySelector('#' + id )); 79 return this._icons[id] || (this._icons[id] = this.querySelector('[id="' + id +'"]'));
80 }, 80 },
81 81
82 cloneIcon: function(id) { 82 cloneIcon: function(id) {
83 var icon = this.iconById(id); 83 var icon = this.iconById(id);
84 if (icon) { 84 if (icon) {
85 var content = icon.cloneNode(true); 85 var content = icon.cloneNode(true);
86 content.removeAttribute('id'); 86 content.removeAttribute('id');
87 var svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg' ); 87 var svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg' );
88 svg.setAttribute('viewBox', '0 0 ' + this.iconSize + ' ' + 88 svg.setAttribute('viewBox', '0 0 ' + this.iconSize + ' ' +
89 this.iconSize); 89 this.iconSize);
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 } 159 }
160 } 160 }
161 } 161 }
162 162
163 163
164 }); 164 });
165 165
166 </script> 166 </script>
167 167
168 </polymer-element> 168 </polymer-element>
OLDNEW
« no previous file with comments | « polymer_0.5.0/bower_components/core-iconset-svg/bower.json ('k') | polymer_0.5.0/bower_components/core-iconset-svg/demo.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698