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

Side by Side Diff: third_party/polymer/v1_0/components-chromium/paper-toolbar/paper-toolbar-extracted.js

Issue 1187823002: Update Polymer components and re-run reproduce.sh (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 6 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 2
3 (function() { 3 (function() {
4 4
5 'use strict'; 5 'use strict';
6 6
7 function classNames(obj) { 7 function classNames(obj) {
8 var classNames = []; 8 var classNames = [];
9 for (var key in obj) { 9 for (var key in obj) {
10 if (obj.hasOwnProperty(key) && obj[key]) { 10 if (obj.hasOwnProperty(key) && obj[key]) {
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 }); 89 });
90 return observer; 90 return observer;
91 }, 91 },
92 92
93 _updateAriaLabelledBy: function() { 93 _updateAriaLabelledBy: function() {
94 var labelledBy = []; 94 var labelledBy = [];
95 var contents = Polymer.dom(this.root).querySelectorAll('content'); 95 var contents = Polymer.dom(this.root).querySelectorAll('content');
96 for (var content, index = 0; content = contents[index]; index++) { 96 for (var content, index = 0; content = contents[index]; index++) {
97 var nodes = Polymer.dom(content).getDistributedNodes(); 97 var nodes = Polymer.dom(content).getDistributedNodes();
98 for (var node, jndex = 0; node = nodes[jndex]; jndex++) { 98 for (var node, jndex = 0; node = nodes[jndex]; jndex++) {
99 if (node.hasAttribute && node.hasAttribute('title')) { 99 if (node.classList && node.classList.contains('title')) {
100 if (node.id) { 100 if (node.id) {
101 labelledBy.push(node.id); 101 labelledBy.push(node.id);
102 } else { 102 } else {
103 var id = 'paper-toolbar-label-' + Math.floor(Math.random() * 100 00); 103 var id = 'paper-toolbar-label-' + Math.floor(Math.random() * 100 00);
104 node.id = id; 104 node.id = id;
105 labelledBy.push(id); 105 labelledBy.push(id);
106 } 106 }
107 } 107 }
108 } 108 }
109 } 109 }
(...skipping 20 matching lines...) Expand all
130 classObj[justifyClassName] = true; 130 classObj[justifyClassName] = true;
131 } 131 }
132 132
133 return classNames(classObj); 133 return classNames(classObj);
134 } 134 }
135 135
136 }); 136 });
137 137
138 }()); 138 }());
139 139
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698