Commits:
-
0ee701d3
by Dan Ballard at 2023-03-10T09:24:17+00:00
fixup! Bug 31286: Implementation of bridge, proxy, and firewall settings in about:preferences#connection
bug 41093: add 'learn more' beside bridge emoji
-
1206e7d0
by Dan Ballard at 2023-03-10T09:24:17+00:00
fixup! Add TorStrings module for localization
bug 41093: add 'learn more' beside bridge emoji
-
6b8aa1af
by Dan Ballard at 2023-03-10T09:24:17+00:00
fixup! fixup! Bug 31286: Implementation of bridge, proxy, and firewall settings in about:preferences#connection
bug 41093: fix css on 'what are these' links to not use .expanded but more precise :not syntax
5 changed files:
Changes:
browser/components/torpreferences/content/connectionPane.js
... |
... |
@@ -125,6 +125,7 @@ const gConnectionPane = (function() { |
125
|
125
|
cardTemplate: "#torPreferences-bridgeCard-template",
|
126
|
126
|
card: ".torPreferences-bridgeCard",
|
127
|
127
|
cardId: ".torPreferences-bridgeCard-id",
|
|
128
|
+ cardHeadingManualLink: ".torPreferences-bridgeCard-manualLink",
|
128
|
129
|
cardHeadingAddr: ".torPreferences-bridgeCard-headingAddr",
|
129
|
130
|
cardConnectedLabel: ".torPreferences-bridgeCard-connectedLabel",
|
130
|
131
|
cardOptions: ".torPreferences-bridgeCard-options",
|
... |
... |
@@ -458,6 +459,19 @@ const gConnectionPane = (function() { |
458
|
459
|
learnMore.setAttribute("useoriginprincipal", "true");
|
459
|
460
|
}
|
460
|
461
|
}
|
|
462
|
+ {
|
|
463
|
+ const manualLink = bridgeTemplate.querySelector(
|
|
464
|
+ selectors.bridges.cardHeadingManualLink
|
|
465
|
+ );
|
|
466
|
+ manualLink.setAttribute("value", TorStrings.settings.whatAreThese);
|
|
467
|
+ manualLink.setAttribute(
|
|
468
|
+ "href",
|
|
469
|
+ TorStrings.settings.learnMoreBridgesCardURL
|
|
470
|
+ );
|
|
471
|
+ if (TorStrings.settings.learnMoreBridgesCardURL.startsWith("about:")) {
|
|
472
|
+ manualLink.setAttribute("useoriginprincipal", "true");
|
|
473
|
+ }
|
|
474
|
+ }
|
461
|
475
|
bridgeTemplate.querySelector(
|
462
|
476
|
selectors.bridges.cardConnectedLabel
|
463
|
477
|
).textContent = TorStrings.settings.statusTorConnected;
|
browser/components/torpreferences/content/connectionPane.xhtml
... |
... |
@@ -106,6 +106,7 @@ |
106
|
106
|
<vbox id="torPreferences-bridgeCard-template" class="torPreferences-bridgeCard">
|
107
|
107
|
<hbox class="torPreferences-bridgeCard-heading">
|
108
|
108
|
<html:div class="torPreferences-bridgeCard-id"/>
|
|
109
|
+ <label class="torPreferences-bridgeCard-manualLink learnMore text-link stop-click" is="text-link"/>
|
109
|
110
|
<html:div class="torPreferences-bridgeCard-headingAddr"/>
|
110
|
111
|
<html:div class="torPreferences-bridgeCard-buttons">
|
111
|
112
|
<html:span class="torPreferences-bridgeCard-connectedBadge">
|
browser/components/torpreferences/content/torPreferences.css
... |
... |
@@ -260,6 +260,19 @@ html:dir(rtl) input[type="checkbox"].toggle-button::before { |
260
|
260
|
background: var(--in-content-box-background-odd);
|
261
|
261
|
}
|
262
|
262
|
|
|
263
|
+#torPreferences-currentBridges-cards:not(
|
|
264
|
+ .single-card
|
|
265
|
+) .torPreferences-bridgeCard:not(
|
|
266
|
+ .expanded,
|
|
267
|
+ .currently-connected
|
|
268
|
+) .torPreferences-bridgeCard-manualLink {
|
|
269
|
+ display: none;
|
|
270
|
+}
|
|
271
|
+
|
|
272
|
+.torPreferences-bridgeCard-manualLink {
|
|
273
|
+ margin: 0 8px;
|
|
274
|
+}
|
|
275
|
+
|
263
|
276
|
.torPreferences-bridgeCard-headingAddr {
|
264
|
277
|
/* flex extends the element when needed, but without setting a width (any) the
|
265
|
278
|
overflow + ellipses does not work. */
|
browser/modules/TorStrings.jsm
... |
... |
@@ -86,6 +86,7 @@ const Loader = { |
86
|
86
|
statusTorNotConnected: "Not Connected",
|
87
|
87
|
statusTorBlocked: "Potentially Blocked",
|
88
|
88
|
learnMore: "Learn more",
|
|
89
|
+ whatAreThese: "What are these?",
|
89
|
90
|
// Quickstart
|
90
|
91
|
quickstartHeading: "Quickstart",
|
91
|
92
|
quickstartDescription:
|
toolkit/torbutton/chrome/locale/en-US/settings.properties
... |
... |
@@ -40,6 +40,7 @@ settings.bridgeId=%1$S bridge: %2$S |
40
|
40
|
settings.remove=Remove
|
41
|
41
|
settings.bridgeDisableBuiltIn=Disable built-in bridges
|
42
|
42
|
settings.bridgeShare=Share this bridge using the QR code or by copying its address:
|
|
43
|
+settings.whatAreThese=What are these?
|
43
|
44
|
settings.bridgeCopy=Copy Bridge Address
|
44
|
45
|
settings.copied=Copied!
|
45
|
46
|
settings.bridgeShowAll=Show All Bridges
|
|