Skip to content

Commit

Permalink
Add mixed-mode SSL styling
Browse files Browse the repository at this point in the history
  • Loading branch information
Lootyhoof committed May 3, 2021
1 parent 0798fff commit d6a1282
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 90 deletions.
15 changes: 12 additions & 3 deletions src/chrome/browser/browser.css
Original file line number Diff line number Diff line change
Expand Up @@ -842,7 +842,8 @@ html|*.urlbar-input:-moz-lwtheme:-moz-placeholder,

#urlbar[pageproxystate="valid"] > #identity-box.chromeUI,
#urlbar[pageproxystate="valid"] > #identity-box.verifiedIdentity,
#urlbar[pageproxystate="valid"] > #identity-box.verifiedDomain {
#urlbar[pageproxystate="valid"] > #identity-box.verifiedDomain,
#urlbar[pageproxystate="valid"] > #identity-box.mixedContent {
margin-inline-end: 4px;
}

Expand Down Expand Up @@ -882,15 +883,17 @@ html|*.urlbar-input:-moz-lwtheme:-moz-placeholder,

#urlbar[pageproxystate="valid"] > #identity-box.chromeUI,
#urlbar[pageproxystate="valid"] > #identity-box.verifiedIdentity,
#urlbar[pageproxystate="valid"] > #identity-box.verifiedDomain {
#urlbar[pageproxystate="valid"] > #identity-box.verifiedDomain,
#urlbar[pageproxystate="valid"] > #identity-box.mixedContent {
background-position: right;
background-size: 1px;
background-repeat: no-repeat;
}

#urlbar[pageproxystate="valid"] > #identity-box.chromeUI:-moz-locale-dir(rtl),
#urlbar[pageproxystate="valid"] > #identity-box.verifiedIdentity:-moz-locale-dir(rtl),
#urlbar[pageproxystate="valid"] > #identity-box.verifiedDomain:-moz-locale-dir(rtl) {
#urlbar[pageproxystate="valid"] > #identity-box.verifiedDomain:-moz-locale-dir(rtl),
#urlbar[pageproxystate="valid"] > #identity-box.mixedContent:-moz-locale-dir(rtl) {
background-position: left;
}

Expand All @@ -911,6 +914,12 @@ html|*.urlbar-input:-moz-lwtheme:-moz-placeholder,
hsla(0,0%,0%,.13));
}

#urlbar[pageproxystate="valid"] > #identity-box.mixedContent {
color: rgb(156,156,0);
background-image: linear-gradient(hsla(0,0%,0%,.13),
hsla(0,0%,0%,.13));
}

/* page proxy icon */

#page-proxy-favicon {
Expand Down
27 changes: 27 additions & 0 deletions src/chrome/browser/identity-low-secure.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
117 changes: 30 additions & 87 deletions src/chrome/browser/padlock/padlock.css
Original file line number Diff line number Diff line change
@@ -1,108 +1,51 @@
#padlock-ib[padshow="ib-trans-bg"][level="ev"] {
list-style-image: url("chrome://browser/skin/identity-secure.svg") !important;
background-color: transparent;
#padlock-ib,
#padlock-ib-left,
#padlock-ub-right,
#padlock-sb,
#padlock-tab {
background-color: transparent !important;
}

#padlock-ib[padshow="ib-trans-bg"][level="high"] {
list-style-image: url("chrome://browser/skin/identity-domain-secure.svg") !important;
background-color: transparent;
#padlock-ib-left[padshow="ib-left"] {
padding: 2px;
}

#padlock-ib[padshow="ib-trans-bg"][level="low"],
#padlock-ib[padshow="ib-trans-bg"][level="mixed"] {
list-style-image: url("chrome://browser/skin/identity-mixed-passive-loaded.svg") !important;
background-color: transparent;
}

#padlock-ib[padshow="ib-trans-bg"][level="broken"] {
list-style-image: url("chrome://browser/skin/identity-mixed-active-loaded.svg") !important;
background-color: transparent;
}

#padlock-ib-left[padshow="ib-left"][level="ev"] {
#padlock-ib[padshow="ib-trans-bg"][level="ev"],
#padlock-ib-left[padshow="ib-left"][level="ev"],
#padlock-ub-right[padshow="ub-right"][level="ev"],
#padlock-sb[padshow="statbar"][level="ev"],
#padlock-tab[padshow="tabs-bar"][level="ev"] {
list-style-image: url("chrome://browser/skin/identity-secure.svg") !important;
padding:2px;
background-color: transparent;
}

#padlock-ib-left[padshow="ib-left"][level="high"] {
#padlock-ib[padshow="ib-trans-bg"][level="high"],
#padlock-ib-left[padshow="ib-left"][level="high"],
#padlock-ub-right[padshow="ub-right"][level="high"],
#padlock-sb[padshow="statbar"][level="high"],
#padlock-tab[padshow="tabs-bar"][level="high"] {
list-style-image: url("chrome://browser/skin/identity-domain-secure.svg") !important;
padding:2px;
background-color: transparent;
}

#padlock-ib[padshow="ib-trans-bg"][level="low"],
#padlock-ib-left[padshow="ib-left"][level="low"],
#padlock-ib-left[padshow="ib-left"][level="mixed"] {
list-style-image: url("chrome://browser/skin/identity-mixed-passive-loaded.svg") !important;
padding:2px;
background-color: transparent;
}

#padlock-ib-left[padshow="ib-left"][level="broken"] {
list-style-image: url("chrome://browser/skin/identity-mixed-active-loaded.svg") !important;
padding:2px;
background-color: transparent;
}

#padlock-ub-right[padshow="ub-right"][level="ev"] {
list-style-image: url("chrome://browser/skin/identity-secure.svg") !important;
background-color: transparent;
}

#padlock-ub-right[padshow="ub-right"][level="high"] {
list-style-image: url("chrome://browser/skin/identity-domain-secure.svg") !important;
background-color: transparent;
}

#padlock-ub-right[padshow="ub-right"][level="low"],
#padlock-ub-right[padshow="ub-right"][level="mixed"] {
list-style-image: url("chrome://browser/skin/identity-mixed-passive-loaded.svg") !important;
background-color: transparent;
}

#padlock-ub-right[padshow="ub-right"][level="broken"] {
list-style-image: url("chrome://browser/skin/identity-mixed-active-loaded.svg") !important;
background-color: transparent;
}

#padlock-sb[padshow="statbar"][level="ev"] {
list-style-image: url("chrome://browser/skin/identity-secure.svg") !important;
background-color: transparent;
}

#padlock-sb[padshow="statbar"][level="high"] {
list-style-image: url("chrome://browser/skin/identity-domain-secure.svg") !important;
background-color: transparent;
}

#padlock-sb[padshow="statbar"][level="low"],
#padlock-sb[padshow="statbar"][level="mixed"] {
list-style-image: url("chrome://browser/skin/identity-mixed-passive-loaded.svg") !important;
background-color: transparent;
#padlock-tab[padshow="tabs-bar"][level="low"] {
list-style-image: url("chrome://browser/skin/identity-low-secure.svg") !important;
}

#padlock-sb[padshow="statbar"][level="broken"] {
list-style-image: url("chrome://browser/skin/identity-mixed-active-loaded.svg") !important;
background-color: transparent;
}

#padlock-tab[padshow="tabs-bar"][level="ev"] {
list-style-image: url("chrome://browser/skin/identity-secure.svg") !important;
background-color: transparent;
}

#padlock-tab[padshow="tabs-bar"][level="high"] {
list-style-image: url("chrome://browser/skin/identity-domain-secure.svg") !important;
background-color: transparent;
}

#padlock-tab[padshow="tabs-bar"][level="low"],
#padlock-ib[padshow="ib-trans-bg"][level="mixed"],
#padlock-ib-left[padshow="ib-left"][level="mixed"],
#padlock-ub-right[padshow="ub-right"][level="mixed"],
#padlock-sb[padshow="statbar"][level="mixed"],
#padlock-tab[padshow="tabs-bar"][level="mixed"] {
list-style-image: url("chrome://browser/skin/identity-mixed-passive-loaded.svg") !important;
background-color: transparent;
}

#padlock-ib[padshow="ib-trans-bg"][level="broken"],
#padlock-ib-left[padshow="ib-left"][level="broken"],
#padlock-ub-right[padshow="ub-right"][level="broken"],
#padlock-sb[padshow="statbar"][level="broken"],
#padlock-tab[padshow="tabs-bar"][level="broken"] {
list-style-image: url("chrome://browser/skin/identity-mixed-active-loaded.svg") !important;
background-color: transparent;
}
}

0 comments on commit d6a1282

Please sign in to comment.