forked from mirrors/gecko-dev
Backed out 2 changesets (bug 1814261) as per request. CLOSED TREE
Backed out changeset 8640c4a18d9e (bug 1814261) Backed out changeset c00c8fc88dbd (bug 1814261)
This commit is contained in:
parent
f50455a504
commit
fd43043337
6 changed files with 20 additions and 69 deletions
|
|
@ -166,7 +166,6 @@ var gIdentityHandler = {
|
|||
|
||||
_popupInitialized: false,
|
||||
_initializePopup() {
|
||||
window.ensureCustomElements("moz-support-link");
|
||||
if (!this._popupInitialized) {
|
||||
let wrapper = document.getElementById("template-identity-popup");
|
||||
wrapper.replaceWith(wrapper.content);
|
||||
|
|
@ -929,6 +928,9 @@ 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",
|
||||
|
|
|
|||
|
|
@ -147,25 +147,25 @@
|
|||
|
||||
<!-- Active Mixed Content Blocked -->
|
||||
<description class="identity-popup-warning-box identity-popup-warning-gray"
|
||||
when-mixedcontent="active-blocked">
|
||||
<label data-l10n-id="identity-description-active-blocked2"/>
|
||||
<html:a is="moz-support-link" class="identity-popup-mcb-learn-more" support-page="mixed-content"/>
|
||||
when-mixedcontent="active-blocked"
|
||||
data-l10n-id="identity-description-active-blocked">
|
||||
<label data-l10n-name="link" is="text-link" class="identity-popup-mcb-learn-more"/>
|
||||
</description>
|
||||
|
||||
<!-- Passive Mixed Content Loaded -->
|
||||
<description when-mixedcontent="passive-loaded" data-l10n-id="identity-description-passive-loaded"></description>
|
||||
<description class="identity-popup-warning-box identity-popup-warning-yellow"
|
||||
when-mixedcontent="passive-loaded">
|
||||
<label data-l10n-id="identity-description-passive-loaded-insecure2"/>
|
||||
<html:a is="moz-support-link" class="identity-popup-mcb-learn-more" support-page="mixed-content"/>
|
||||
when-mixedcontent="passive-loaded"
|
||||
data-l10n-id="identity-description-passive-loaded-insecure">
|
||||
<label data-l10n-name="link" is="text-link" class="identity-popup-mcb-learn-more"/>
|
||||
</description>
|
||||
|
||||
<!-- Passive Mixed Content Loaded, Active Mixed Content Blocked -->
|
||||
<description when-mixedcontent="passive-loaded active-blocked" data-l10n-id="identity-description-passive-loaded"></description>
|
||||
<description when-mixedcontent="passive-loaded active-blocked"
|
||||
class="identity-popup-warning-box identity-popup-warning-yellow">
|
||||
<label data-l10n-id="identity-description-passive-loaded-mixed2"/>
|
||||
<html:a is="moz-support-link" class="identity-popup-mcb-learn-more" support-page="mixed-content"/>
|
||||
class="identity-popup-warning-box identity-popup-warning-yellow"
|
||||
data-l10n-id="identity-description-passive-loaded-mixed">
|
||||
<label data-l10n-name="link" is="text-link" class="identity-popup-mcb-learn-more"/>
|
||||
</description>
|
||||
|
||||
<!-- Active Mixed Content Blocking Disabled -->
|
||||
|
|
@ -174,8 +174,8 @@
|
|||
<description when-mixedcontent="active-loaded"
|
||||
data-l10n-id="identity-description-active-loaded-insecure"></description>
|
||||
<hbox>
|
||||
<html:a is="moz-support-link" when-mixedcontent="active-loaded"
|
||||
and-when-loginforms="secure" class="identity-popup-mcb-learn-more" support-page="mixed-content"/>
|
||||
<label when-mixedcontent="active-loaded"
|
||||
and-when-loginforms="secure" is="text-link" class="identity-popup-mcb-learn-more" data-l10n-id="identity-learn-more"/>
|
||||
</hbox>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -408,12 +408,14 @@ 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-blocked2 = { -brand-short-name } has blocked parts of this page that are not secure.
|
||||
identity-description-active-blocked = { -brand-short-name } has blocked parts of this page that are not secure. <label data-l10n-name="link">Learn More</label>
|
||||
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-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-passive-loaded-insecure = This website contains content that is not secure (such as images). <label data-l10n-name="link">Learn More</label>
|
||||
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). <label data-l10n-name="link">Learn More</label>
|
||||
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
|
||||
|
|
|
|||
|
|
@ -268,10 +268,6 @@
|
|||
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;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,49 +0,0 @@
|
|||
# Any copyright is dedicated to the Public Domain.
|
||||
# http://creativecommons.org/publicdomain/zero/1.0/
|
||||
|
||||
import fluent.syntax.ast as FTL
|
||||
|
||||
from fluent.migrate.transforms import TransformPattern
|
||||
|
||||
|
||||
class STRIP_LEARNMORE(TransformPattern):
|
||||
# Used to remove `<a data-l10n-name="link">SOME TEXT</a>` from a string
|
||||
def visit_TextElement(self, node):
|
||||
link_start = node.value.find('<label data-l10n-name="link">')
|
||||
if link_start != -1:
|
||||
# Replace string up to the link, remove remaining spaces afterwards.
|
||||
# Removing an extra character directly is not safe, as it could be
|
||||
# punctuation.
|
||||
node.value = node.value[:link_start].rstrip()
|
||||
|
||||
return node
|
||||
|
||||
|
||||
def migrate(ctx):
|
||||
"""Bug 1814261 - Use moz-support-link in the mixed-content section of the identity panel, part {index}."""
|
||||
|
||||
browser_ftl = "browser/browser/browser.ftl"
|
||||
ctx.add_transforms(
|
||||
browser_ftl,
|
||||
browser_ftl,
|
||||
[
|
||||
FTL.Message(
|
||||
id=FTL.Identifier("identity-description-active-blocked2"),
|
||||
value=STRIP_LEARNMORE(
|
||||
browser_ftl, "identity-description-active-blocked"
|
||||
),
|
||||
),
|
||||
FTL.Message(
|
||||
id=FTL.Identifier("identity-description-passive-loaded-insecure2"),
|
||||
value=STRIP_LEARNMORE(
|
||||
browser_ftl, "identity-description-passive-loaded-insecure"
|
||||
),
|
||||
),
|
||||
FTL.Message(
|
||||
id=FTL.Identifier("identity-description-passive-loaded-mixed2"),
|
||||
value=STRIP_LEARNMORE(
|
||||
browser_ftl, "identity-description-passive-loaded-mixed"
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
|
|
@ -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() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue