From 47b283c6e9cf7730e5422b1f6e81b3c7518230de Mon Sep 17 00:00:00 2001 From: Noah Date: Thu, 6 Apr 2023 06:00:16 +0000 Subject: [PATCH] Bug 1814261 - Use moz-support-link in Mixed Content Blocking. r=tgiles,flod Differential Revision: https://phabricator.services.mozilla.com/D173620 --- browser/base/content/browser-siteIdentity.js | 4 +--- .../content/identityPanel.inc.xhtml | 22 +++++++++---------- browser/locales/en-US/browser/browser.ftl | 8 +++---- browser/themes/shared/controlcenter/panel.css | 4 ++++ .../moz-support-link/moz-support-link.mjs | 2 +- 5 files changed, 20 insertions(+), 20 deletions(-) diff --git a/browser/base/content/browser-siteIdentity.js b/browser/base/content/browser-siteIdentity.js index 868e066c0190..e71311ce33f2 100644 --- a/browser/base/content/browser-siteIdentity.js +++ b/browser/base/content/browser-siteIdentity.js @@ -166,6 +166,7 @@ var gIdentityHandler = { _popupInitialized: false, _initializePopup() { + window.ensureCustomElements("moz-support-link"); if (!this._popupInitialized) { let wrapper = document.getElementById("template-identity-popup"); wrapper.replaceWith(wrapper.content); @@ -928,9 +929,6 @@ var gIdentityHandler = { // Update "Learn More" for Mixed Content Blocking and Insecure Login Forms. let baseURL = Services.urlFormatter.formatURLPref("app.support.baseURL"); - this._identityPopupMixedContentLearnMore.forEach(e => - e.setAttribute("href", baseURL + "mixed-content") - ); this._identityPopupCustomRootLearnMore.setAttribute( "href", diff --git a/browser/components/controlcenter/content/identityPanel.inc.xhtml b/browser/components/controlcenter/content/identityPanel.inc.xhtml index 3a8e689e579c..00ddc77e619b 100644 --- a/browser/components/controlcenter/content/identityPanel.inc.xhtml +++ b/browser/components/controlcenter/content/identityPanel.inc.xhtml @@ -147,25 +147,25 @@ - - - @@ -174,8 +174,8 @@ - diff --git a/browser/locales/en-US/browser/browser.ftl b/browser/locales/en-US/browser/browser.ftl index 710e52485579..7a92656e3afb 100644 --- a/browser/locales/en-US/browser/browser.ftl +++ b/browser/locales/en-US/browser/browser.ftl @@ -408,14 +408,12 @@ identity-description-insecure = Your connection to this site is not private. Inf identity-description-insecure-login-forms = The login information you enter on this page is not secure and could be compromised. identity-description-weak-cipher-intro = Your connection to this website uses weak encryption and is not private. identity-description-weak-cipher-risk = Other people can view your information or modify the website’s behavior. -identity-description-active-blocked = { -brand-short-name } has blocked parts of this page that are not secure. +identity-description-active-blocked2 = { -brand-short-name } has blocked parts of this page that are not secure. identity-description-passive-loaded = Your connection is not private and information you share with the site could be viewed by others. -identity-description-passive-loaded-insecure = This website contains content that is not secure (such as images). -identity-description-passive-loaded-mixed = Although { -brand-short-name } has blocked some content, there is still content on the page that is not secure (such as images). +identity-description-passive-loaded-insecure2 = This website contains content that is not secure (such as images). +identity-description-passive-loaded-mixed2 = Although { -brand-short-name } has blocked some content, there is still content on the page that is not secure (such as images). identity-description-active-loaded = This website contains content that is not secure (such as scripts) and your connection to it is not private. identity-description-active-loaded-insecure = Information you share with this site could be viewed by others (like passwords, messages, credit cards, etc.). -identity-learn-more = - .value = Learn More identity-disable-mixed-content-blocking = .label = Disable protection for now .accesskey = D diff --git a/browser/themes/shared/controlcenter/panel.css b/browser/themes/shared/controlcenter/panel.css index 8392040e3c4d..fc2362674237 100644 --- a/browser/themes/shared/controlcenter/panel.css +++ b/browser/themes/shared/controlcenter/panel.css @@ -268,6 +268,10 @@ font-weight: 600; } +#identity-popup-securityView-extended-info > .identity-popup-warning-box > label { + display: inline-block; +} + #identity-popup-securityView-extended-info > button { margin-inline: 0; } diff --git a/toolkit/content/widgets/moz-support-link/moz-support-link.mjs b/toolkit/content/widgets/moz-support-link/moz-support-link.mjs index bd07ccfb7948..c344bd56a40e 100644 --- a/toolkit/content/widgets/moz-support-link/moz-support-link.mjs +++ b/toolkit/content/widgets/moz-support-link/moz-support-link.mjs @@ -53,8 +53,8 @@ export default class MozSupportLink extends HTMLAnchorElement { this.addEventListener("click", this); if (!this.getAttribute("data-l10n-id")) { document.l10n.setAttributes(this, "moz-support-link-text"); - document.l10n.translateFragment(this); } + document.l10n.translateFragment(this); } disconnectedCallback() {