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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/elements/ComputedStyleWidget.js

Issue 1739183002: DevTools: [CSSP] do not wrap computed properties. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebaseline test Created 4 years, 9 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) 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2007 Apple Inc. All rights reserved.
3 * Copyright (C) 2009 Joseph Pecoraro 3 * Copyright (C) 2009 Joseph Pecoraro
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 var renderer = new WebInspector.StylesSidebarPropertyRenderer(null, nodeStyle.node, propertyName, /** @type {string} */(propertyValue)); 160 var renderer = new WebInspector.StylesSidebarPropertyRenderer(null, nodeStyle.node, propertyName, /** @type {string} */(propertyValue));
161 renderer.setColorHandler(this._processColor.bind(this)); 161 renderer.setColorHandler(this._processColor.bind(this));
162 var propertyNameElement = renderer.renderName(); 162 var propertyNameElement = renderer.renderName();
163 propertyNameElement.classList.add("property-name"); 163 propertyNameElement.classList.add("property-name");
164 propertyElement.appendChild(propertyNameElement); 164 propertyElement.appendChild(propertyNameElement);
165 165
166 var colon = createElementWithClass("span", "delimeter"); 166 var colon = createElementWithClass("span", "delimeter");
167 colon.textContent = ":"; 167 colon.textContent = ":";
168 propertyNameElement.appendChild(colon); 168 propertyNameElement.appendChild(colon);
169 169
170 var propertyValueElement = renderer.renderValue(); 170 var propertyValueElement = propertyElement.createChild("span", "prop erty-value");
171 propertyValueElement.classList.add("property-value"); 171
172 propertyElement.appendChild(propertyValueElement); 172 var propertyValueText = renderer.renderValue();
173 propertyValueText.classList.add("property-value-text");
174 propertyValueElement.appendChild(propertyValueText);
173 175
174 var semicolon = createElementWithClass("span", "delimeter"); 176 var semicolon = createElementWithClass("span", "delimeter");
175 semicolon.textContent = ";"; 177 semicolon.textContent = ";";
176 propertyValueElement.appendChild(semicolon); 178 propertyValueElement.appendChild(semicolon);
177 179
178 var treeElement = new TreeElement(); 180 var treeElement = new TreeElement();
179 treeElement.selectable = false; 181 treeElement.selectable = false;
180 treeElement.title = propertyElement; 182 treeElement.title = propertyElement;
181 treeElement[WebInspector.ComputedStyleWidget._propertySymbol] = { 183 treeElement[WebInspector.ComputedStyleWidget._propertySymbol] = {
182 name: propertyName, 184 name: propertyName,
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 var children = this._propertiesOutline.rootElement().children(); 333 var children = this._propertiesOutline.rootElement().children();
332 for (var child of children) { 334 for (var child of children) {
333 var property = child[WebInspector.ComputedStyleWidget._propertySymbo l]; 335 var property = child[WebInspector.ComputedStyleWidget._propertySymbo l];
334 var matched = !regex || regex.test(property.name) || regex.test(prop erty.value); 336 var matched = !regex || regex.test(property.name) || regex.test(prop erty.value);
335 child.hidden = !matched; 337 child.hidden = !matched;
336 } 338 }
337 }, 339 },
338 340
339 __proto__: WebInspector.ThrottledWidget.prototype 341 __proto__: WebInspector.ThrottledWidget.prototype
340 } 342 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698