Commit 93f5f005 authored by dgozman's avatar dgozman Committed by Commit bot

[DevTools] Remove SidebarTreeElement from SecurityPanel.

This is a step towards removing SidebarTreeElement, and moving
all tree outlines into shadow dom.

BUG=none

Review-Url: https://codereview.chromium.org/2347483002
Cr-Commit-Position: refs/heads/master@{#419062}
parent 5c77780d
...@@ -5,12 +5,13 @@ InspectorTest.preloadPanel("security"); ...@@ -5,12 +5,13 @@ InspectorTest.preloadPanel("security");
InspectorTest.dumpSecurityPanelSidebarOrigins = function() { InspectorTest.dumpSecurityPanelSidebarOrigins = function() {
for (var key in WebInspector.SecurityPanelSidebarTree.OriginGroupName) { for (var key in WebInspector.SecurityPanelSidebarTree.OriginGroupName) {
var originGroupName = WebInspector.SecurityPanelSidebarTree.OriginGroupName[key]; var originGroupName = WebInspector.SecurityPanelSidebarTree.OriginGroupName[key];
var originTitles = WebInspector.SecurityPanel._instance()._sidebarTree._originGroups.get(originGroupName).childrenListElement.getElementsByClassName("title"); var originGroup = WebInspector.SecurityPanel._instance()._sidebarTree._originGroups.get(originGroupName);
if (originTitles.length > 0) { if (originGroup.hidden)
InspectorTest.addResult("Group: " + originGroupName); continue;
for (var originTitle of originTitles) InspectorTest.addResult("Group: " + originGroupName);
InspectorTest.dumpDeepInnerHTML(originTitle); var originTitles = originGroup.childrenListElement.getElementsByClassName("title");
} for (var originTitle of originTitles)
InspectorTest.dumpDeepInnerHTML(originTitle);
} }
} }
......
Tests that blank origins aren't shown in the security panel origins list. Tests that blank origins aren't shown in the security panel origins list.
Group: Main Origin Group: Main Origin
<SPAN class=title >
Reload to view details
</SPAN>
Group: Unknown / Canceled Group: Unknown / Canceled
<SPAN class=title > <SPAN class=title >
https://foo.test https://foo.test
......
Tests that origins with failed requests are shown correctly in the security panel origins list. Tests that origins with failed requests are shown correctly in the security panel origins list.
Group: Main Origin Group: Main Origin
<SPAN class=title >
Reload to view details
</SPAN>
Group: Secure Origins Group: Secure Origins
<SPAN class=title > <SPAN class=title >
https://foo.test https://foo.test
......
Tests that the sidebar origin list disappears and appers when an interstitial is shown or hidden. Tests that the sidebar origin list disappears and appers when an interstitial is shown or hidden.
Before interstitial is shown: Before interstitial is shown:
<DIV class=sidebar-tree > <DIV >
<#document-fragment > <#document-fragment >
<STYLE type=text/css > <STYLE type=text/css >
</STYLE> </STYLE>
...@@ -11,26 +11,18 @@ Before interstitial is shown: ...@@ -11,26 +11,18 @@ Before interstitial is shown:
</STYLE> </STYLE>
<DIV class=tree-outline-disclosure > <DIV class=tree-outline-disclosure >
<OL class=tree-outline tabindex=0 > <OL class=tree-outline tabindex=0 >
<LI class=sidebar-tree-item security-main-view-sidebar-tree-item selected > <LI class=security-main-view-sidebar-tree-item selected >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon lock-icon lock-icon-unknown > <DIV class=icon lock-icon lock-icon-unknown >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
Overview Overview
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section > <LI class=parent expanded security-sidebar-origins >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -38,27 +30,17 @@ Main Origin ...@@ -38,27 +30,17 @@ Main Origin
</SPAN> </SPAN>
</LI> </LI>
<OL class=children expanded > <OL class=children expanded >
<LI class=sidebar-tree-item security-main-view-reload-message > <LI class=security-main-view-reload-message >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon > <SPAN class=tree-element-title >
</DIV>
<DIV class=status >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
Reload to view details Reload to view details
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section hidden > <LI class=parent expanded security-sidebar-origins hidden >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -67,7 +49,7 @@ Non-Secure Origins ...@@ -67,7 +49,7 @@ Non-Secure Origins
</LI> </LI>
<OL class=children expanded hidden > <OL class=children expanded hidden >
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section > <LI class=parent expanded security-sidebar-origins >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -75,46 +57,30 @@ Secure Origins ...@@ -75,46 +57,30 @@ Secure Origins
</SPAN> </SPAN>
</LI> </LI>
<OL class=children expanded > <OL class=children expanded >
<LI class=sidebar-tree-item security-sidebar-tree-item > <LI class=security-sidebar-tree-item >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon security-property security-property-secure > <DIV class=icon security-property security-property-secure >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
https://foo.test https://foo.test
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
<LI class=sidebar-tree-item security-sidebar-tree-item > <LI class=security-sidebar-tree-item >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon security-property security-property-secure > <DIV class=icon security-property security-property-secure >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
https://bar.test https://bar.test
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section hidden > <LI class=parent expanded security-sidebar-origins hidden >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -132,7 +98,7 @@ Unknown / Canceled ...@@ -132,7 +98,7 @@ Unknown / Canceled
</#document-fragment> </#document-fragment>
</DIV> </DIV>
After interstitial is shown: After interstitial is shown:
<DIV class=sidebar-tree > <DIV >
<#document-fragment > <#document-fragment >
<STYLE type=text/css > <STYLE type=text/css >
</STYLE> </STYLE>
...@@ -142,26 +108,18 @@ After interstitial is shown: ...@@ -142,26 +108,18 @@ After interstitial is shown:
</STYLE> </STYLE>
<DIV class=tree-outline-disclosure > <DIV class=tree-outline-disclosure >
<OL class=tree-outline tabindex=0 > <OL class=tree-outline tabindex=0 >
<LI class=sidebar-tree-item security-main-view-sidebar-tree-item selected > <LI class=security-main-view-sidebar-tree-item selected >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon lock-icon lock-icon-unknown > <DIV class=icon lock-icon lock-icon-unknown >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
Overview Overview
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section hidden > <LI class=parent expanded security-sidebar-origins hidden >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -169,27 +127,17 @@ Main Origin ...@@ -169,27 +127,17 @@ Main Origin
</SPAN> </SPAN>
</LI> </LI>
<OL class=children expanded hidden > <OL class=children expanded hidden >
<LI class=sidebar-tree-item security-main-view-reload-message > <LI class=security-main-view-reload-message >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon > <SPAN class=tree-element-title >
</DIV>
<DIV class=status >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
Reload to view details Reload to view details
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section hidden > <LI class=parent expanded security-sidebar-origins hidden >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -198,7 +146,7 @@ Non-Secure Origins ...@@ -198,7 +146,7 @@ Non-Secure Origins
</LI> </LI>
<OL class=children expanded hidden > <OL class=children expanded hidden >
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section hidden > <LI class=parent expanded security-sidebar-origins hidden >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -206,46 +154,30 @@ Secure Origins ...@@ -206,46 +154,30 @@ Secure Origins
</SPAN> </SPAN>
</LI> </LI>
<OL class=children expanded hidden > <OL class=children expanded hidden >
<LI class=sidebar-tree-item security-sidebar-tree-item > <LI class=security-sidebar-tree-item >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon security-property security-property-secure > <DIV class=icon security-property security-property-secure >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
https://foo.test https://foo.test
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
<LI class=sidebar-tree-item security-sidebar-tree-item > <LI class=security-sidebar-tree-item >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon security-property security-property-secure > <DIV class=icon security-property security-property-secure >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
https://bar.test https://bar.test
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section hidden > <LI class=parent expanded security-sidebar-origins hidden >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -263,7 +195,7 @@ Unknown / Canceled ...@@ -263,7 +195,7 @@ Unknown / Canceled
</#document-fragment> </#document-fragment>
</DIV> </DIV>
After interstitial is hidden: After interstitial is hidden:
<DIV class=sidebar-tree > <DIV >
<#document-fragment > <#document-fragment >
<STYLE type=text/css > <STYLE type=text/css >
</STYLE> </STYLE>
...@@ -273,26 +205,18 @@ After interstitial is hidden: ...@@ -273,26 +205,18 @@ After interstitial is hidden:
</STYLE> </STYLE>
<DIV class=tree-outline-disclosure > <DIV class=tree-outline-disclosure >
<OL class=tree-outline tabindex=0 > <OL class=tree-outline tabindex=0 >
<LI class=sidebar-tree-item security-main-view-sidebar-tree-item selected > <LI class=security-main-view-sidebar-tree-item selected >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon lock-icon lock-icon-unknown > <DIV class=icon lock-icon lock-icon-unknown >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
Overview Overview
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section > <LI class=parent expanded security-sidebar-origins >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -300,27 +224,17 @@ Main Origin ...@@ -300,27 +224,17 @@ Main Origin
</SPAN> </SPAN>
</LI> </LI>
<OL class=children expanded > <OL class=children expanded >
<LI class=sidebar-tree-item security-main-view-reload-message > <LI class=security-main-view-reload-message >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon > <SPAN class=tree-element-title >
</DIV>
<DIV class=status >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
Reload to view details Reload to view details
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section > <LI class=parent expanded security-sidebar-origins >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -329,7 +243,7 @@ Non-Secure Origins ...@@ -329,7 +243,7 @@ Non-Secure Origins
</LI> </LI>
<OL class=children expanded > <OL class=children expanded >
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section > <LI class=parent expanded security-sidebar-origins >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
...@@ -337,46 +251,30 @@ Secure Origins ...@@ -337,46 +251,30 @@ Secure Origins
</SPAN> </SPAN>
</LI> </LI>
<OL class=children expanded > <OL class=children expanded >
<LI class=sidebar-tree-item security-sidebar-tree-item > <LI class=security-sidebar-tree-item >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon security-property security-property-secure > <DIV class=icon security-property security-property-secure >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
https://foo.test https://foo.test
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
<LI class=sidebar-tree-item security-sidebar-tree-item > <LI class=security-sidebar-tree-item >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<DIV class=icon security-property security-property-secure > <DIV class=icon security-property security-property-secure >
</DIV> </DIV>
<DIV class=status > <SPAN class=title >
</DIV>
<DIV class=titles no-subtitle >
<SPAN class=title-container >
<SPAN class=title >
https://bar.test https://bar.test
</SPAN> </SPAN>
</SPAN>
<SPAN class=subtitle >
</SPAN>
</DIV>
</LI> </LI>
<OL class=children > <OL class=children >
</OL> </OL>
</OL> </OL>
<LI class=parent expanded security-sidebar-origins sidebar-tree-section > <LI class=parent expanded security-sidebar-origins >
<DIV class=selection fill > <DIV class=selection fill >
</DIV> </DIV>
<SPAN class=tree-element-title > <SPAN class=tree-element-title >
......
Tests that requests to unresolved origins result in unknown security state and show up in the sidebar origin list. Tests that requests to unresolved origins result in unknown security state and show up in the sidebar origin list.
Group: Main Origin Group: Main Origin
<SPAN class=title >
Reload to view details
</SPAN>
Group: Unknown / Canceled Group: Unknown / Canceled
<SPAN class=title > <SPAN class=title >
http://unknown http://unknown
......
...@@ -381,18 +381,19 @@ WebInspector.SecurityPanelSidebarTree = function(mainViewElement, showOriginInPa ...@@ -381,18 +381,19 @@ WebInspector.SecurityPanelSidebarTree = function(mainViewElement, showOriginInPa
this._mainOrigin = null; this._mainOrigin = null;
TreeOutlineInShadow.call(this); TreeOutlineInShadow.call(this);
this.element.classList.add("sidebar-tree");
this.registerRequiredCSS("security/sidebar.css"); this.registerRequiredCSS("security/sidebar.css");
this.registerRequiredCSS("security/lockIcon.css"); this.registerRequiredCSS("security/lockIcon.css");
this.appendChild(mainViewElement); this.appendChild(mainViewElement);
/** @type {!Map<!WebInspector.SecurityPanelSidebarTree.OriginGroupName, !WebInspector.SidebarSectionTreeElement>} */ /** @type {!Map<!WebInspector.SecurityPanelSidebarTree.OriginGroupName, !TreeElement>} */
this._originGroups = new Map(); this._originGroups = new Map();
for (var key in WebInspector.SecurityPanelSidebarTree.OriginGroupName) { for (var key in WebInspector.SecurityPanelSidebarTree.OriginGroupName) {
var originGroupName = WebInspector.SecurityPanelSidebarTree.OriginGroupName[key]; var originGroupName = WebInspector.SecurityPanelSidebarTree.OriginGroupName[key];
var originGroup = new WebInspector.SidebarSectionTreeElement(WebInspector.UIString(originGroupName)); var originGroup = new TreeElement(originGroupName, true);
originGroup.selectable = false;
originGroup.expand();
originGroup.listItemElement.classList.add("security-sidebar-origins"); originGroup.listItemElement.classList.add("security-sidebar-origins");
this._originGroups.set(originGroupName, originGroup); this._originGroups.set(originGroupName, originGroup);
this.appendChild(originGroup); this.appendChild(originGroup);
...@@ -400,8 +401,9 @@ WebInspector.SecurityPanelSidebarTree = function(mainViewElement, showOriginInPa ...@@ -400,8 +401,9 @@ WebInspector.SecurityPanelSidebarTree = function(mainViewElement, showOriginInPa
this._clearOriginGroups(); this._clearOriginGroups();
// This message will be removed by clearOrigins() during the first new page load after the panel was opened. // This message will be removed by clearOrigins() during the first new page load after the panel was opened.
var mainViewReloadMessage = new WebInspector.SidebarTreeElement("security-main-view-reload-message", WebInspector.UIString("Reload to view details")); var mainViewReloadMessage = new TreeElement(WebInspector.UIString("Reload to view details"));
mainViewReloadMessage.selectable = false; mainViewReloadMessage.selectable = false;
mainViewReloadMessage.listItemElement.classList.add("security-main-view-reload-message");
this._originGroups.get(WebInspector.SecurityPanelSidebarTree.OriginGroupName.MainOrigin).appendChild(mainViewReloadMessage); this._originGroups.get(WebInspector.SecurityPanelSidebarTree.OriginGroupName.MainOrigin).appendChild(mainViewReloadMessage);
/** @type {!Map<!WebInspector.SecurityPanel.Origin, !WebInspector.SecurityPanelSidebarTreeElement>} */ /** @type {!Map<!WebInspector.SecurityPanel.Origin, !WebInspector.SecurityPanelSidebarTreeElement>} */
...@@ -506,16 +508,16 @@ WebInspector.SecurityPanelSidebarTree.prototype = { ...@@ -506,16 +508,16 @@ WebInspector.SecurityPanelSidebarTree.prototype = {
* @enum {string} * @enum {string}
*/ */
WebInspector.SecurityPanelSidebarTree.OriginGroupName = { WebInspector.SecurityPanelSidebarTree.OriginGroupName = {
MainOrigin: "Main Origin", MainOrigin: WebInspector.UIString("Main Origin"),
NonSecure: "Non-Secure Origins", NonSecure: WebInspector.UIString("Non-Secure Origins"),
Secure: "Secure Origins", Secure: WebInspector.UIString("Secure Origins"),
Unknown: "Unknown / Canceled" Unknown: WebInspector.UIString("Unknown / Canceled")
} }
/** /**
* @constructor * @constructor
* @extends {WebInspector.SidebarTreeElement} * @extends {TreeElement}
* @param {string} text * @param {string} text
* @param {function()} selectCallback * @param {function()} selectCallback
* @param {string} className * @param {string} className
...@@ -523,12 +525,13 @@ WebInspector.SecurityPanelSidebarTree.OriginGroupName = { ...@@ -523,12 +525,13 @@ WebInspector.SecurityPanelSidebarTree.OriginGroupName = {
*/ */
WebInspector.SecurityPanelSidebarTreeElement = function(text, selectCallback, className, cssPrefix) WebInspector.SecurityPanelSidebarTreeElement = function(text, selectCallback, className, cssPrefix)
{ {
TreeElement.call(this, "", false);
this._selectCallback = selectCallback; this._selectCallback = selectCallback;
this._cssPrefix = cssPrefix; this._cssPrefix = cssPrefix;
this.listItemElement.classList.add(className);
WebInspector.SidebarTreeElement.call(this, className, text); this._iconElement = this.listItemElement.createChild("div", "icon");
this.iconElement.classList.add(this._cssPrefix); this._iconElement.classList.add(this._cssPrefix);
this.listItemElement.createChild("span", "title").textContent = text;
this.setSecurityState(SecurityAgent.SecurityState.Unknown); this.setSecurityState(SecurityAgent.SecurityState.Unknown);
} }
...@@ -539,10 +542,10 @@ WebInspector.SecurityPanelSidebarTreeElement.prototype = { ...@@ -539,10 +542,10 @@ WebInspector.SecurityPanelSidebarTreeElement.prototype = {
setSecurityState: function(newSecurityState) setSecurityState: function(newSecurityState)
{ {
if (this._securityState) if (this._securityState)
this.iconElement.classList.remove(this._cssPrefix + "-" + this._securityState) this._iconElement.classList.remove(this._cssPrefix + "-" + this._securityState);
this._securityState = newSecurityState; this._securityState = newSecurityState;
this.iconElement.classList.add(this._cssPrefix + "-" + newSecurityState); this._iconElement.classList.add(this._cssPrefix + "-" + newSecurityState);
}, },
/** /**
...@@ -563,7 +566,7 @@ WebInspector.SecurityPanelSidebarTreeElement.prototype = { ...@@ -563,7 +566,7 @@ WebInspector.SecurityPanelSidebarTreeElement.prototype = {
return true; return true;
}, },
__proto__: WebInspector.SidebarTreeElement.prototype __proto__: TreeElement.prototype
} }
/** /**
......
...@@ -11,6 +11,11 @@ ...@@ -11,6 +11,11 @@
display: flex; display: flex;
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;
padding: 2px 5px;
overflow: hidden;
margin: 2px 0;
border-top: 1px solid transparent;
white-space: nowrap;
} }
.tree-outline:focus li.selected .lock-icon, .tree-outline:focus li.selected .lock-icon,
...@@ -24,11 +29,14 @@ ...@@ -24,11 +29,14 @@
padding: 16px 0; padding: 16px 0;
} }
.tree-outline .security-sidebar-origins { .tree-outline li.security-sidebar-origins {
padding: 1px 8px 6px 8px; padding: 1px 8px 1px 13px;
margin-top: 1em; margin-top: 1em;
margin-bottom: 0.5em; margin-bottom: 0.5em;
color: rgb(90, 90, 90); color: rgb(90, 90, 90);
border-top: none;
line-height: 16px;
text-shadow: rgba(255, 255, 255, 0.75) 0 1px 0;
} }
.tree-outline ol { .tree-outline ol {
...@@ -41,12 +49,12 @@ ...@@ -41,12 +49,12 @@
.tree-outline .security-main-view-sidebar-tree-item, .tree-outline .security-main-view-sidebar-tree-item,
.tree-outline .security-sidebar-origins, .tree-outline .security-sidebar-origins,
.tree-outline .sidebar-tree-section + .children > .sidebar-tree-item { .tree-outline li.security-sidebar-origins + .children > li {
padding-left: 16px; padding-left: 16px;
} }
.tree-outline .sidebar-tree-item .lock-icon, .tree-outline .lock-icon,
.tree-outline .sidebar-tree-item .security-property { .tree-outline .security-property {
margin-right: 4px; margin-right: 4px;
flex: none; flex: none;
} }
...@@ -55,12 +63,12 @@ ...@@ -55,12 +63,12 @@
padding: 2px 0; padding: 2px 0;
} }
.security-sidebar-tree-item .titles { .security-sidebar-tree-item .title {
overflow: hidden; overflow: hidden;
margin-right: 5px; margin-right: 5px;
} }
.sidebar-tree-item.security-main-view-reload-message .title { .security-main-view-reload-message .tree-element-title {
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
padding-left: 8px; padding-left: 8px;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment