[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [Git][tpo/applications/tor-browser][tor-browser-115.9.0esr-13.5-1] 3 commits: fixup! Bug 31286: Implementation of bridge, proxy, and firewall settings in...



Title: GitLab

richard pushed to branch tor-browser-115.9.0esr-13.5-1 at The Tor Project / Applications / Tor Browser

Commits:

  • cdfc3cf2
    by Henry Wilkes at 2024-03-14T16:38:30+00:00
    fixup! Bug 31286: Implementation of bridge, proxy, and firewall settings in about:preferences#connection
    
    Bug 42446: Improve accessible description of built-in radio options.
    
  • 0a704bcc
    by Henry Wilkes at 2024-03-14T16:38:30+00:00
    fixup! Tor Browser strings
    
    Bug 42446: Add ending-punctuation to the "Current bridge" accessible
    name to separate it from the rest of the built-bridge description.
    
  • 018c552b
    by Henry Wilkes at 2024-03-14T16:38:30+00:00
    fixup! Add TorStrings module for localization
    
    Bug 42446: Drop old "Current bridge" string.
    

5 changed files:

Changes:

  • browser/components/torpreferences/content/builtinBridgeDialog.js
    ... ... @@ -57,18 +57,27 @@ const gBuiltinBridgeDialog = {
    57 57
           const type = radio.value;
    
    58 58
           optionEl.hidden = !TorSettings.builtinBridgeTypes.includes(type);
    
    59 59
           radio.label = typeStrings[type].label;
    
    60
    -      optionEl.querySelector(
    
    60
    +      const descriptionEl = optionEl.querySelector(
    
    61 61
             ".builtin-bridges-option-description"
    
    62
    -      ).textContent = typeStrings[type].descr;
    
    63
    -      optionEl.querySelector(
    
    64
    -        ".torPreferences-current-bridge-label"
    
    65
    -      ).textContent = TorStrings.settings.currentBridge;
    
    66
    -      optionEl
    
    67
    -        .querySelector(".bridge-status-badge")
    
    68
    -        .classList.toggle(
    
    69
    -          "bridge-status-current-built-in",
    
    70
    -          type === currentBuiltinType
    
    62
    +      );
    
    63
    +      descriptionEl.textContent = typeStrings[type].descr;
    
    64
    +      const currentBadge = optionEl.querySelector(".bridge-status-badge");
    
    65
    +      if (type === currentBuiltinType) {
    
    66
    +        const currentLabelEl = optionEl.querySelector(
    
    67
    +          ".torPreferences-current-bridge-label"
    
    71 68
             );
    
    69
    +        // Described by both the current badge and the full description.
    
    70
    +        // These will be concatenated together in the screen reader output.
    
    71
    +        radio.setAttribute(
    
    72
    +          "aria-describedby",
    
    73
    +          `${currentLabelEl.id} ${descriptionEl.id}`
    
    74
    +        );
    
    75
    +        // Make visible.
    
    76
    +        currentBadge.classList.add("bridge-status-current-built-in");
    
    77
    +      } else {
    
    78
    +        // No visible badge.
    
    79
    +        radio.setAttribute("aria-describedby", descriptionEl.id);
    
    80
    +      }
    
    72 81
         }
    
    73 82
     
    
    74 83
         if (currentBuiltinType) {
    

  • browser/components/torpreferences/content/builtinBridgeDialog.xhtml
    ... ... @@ -9,6 +9,10 @@
    9 9
       xmlns:html="http://www.w3.org/1999/xhtml"
    
    10 10
     >
    
    11 11
       <dialog id="torPreferences-builtinBridge-dialog" buttons="accept,cancel">
    
    12
    +    <linkset>
    
    13
    +      <html:link rel="localization" href="">"browser/tor-browser.ftl" />
    
    14
    +    </linkset>
    
    15
    +
    
    12 16
         <script src="">"chrome://browser/content/torpreferences/builtinBridgeDialog.js" />
    
    13 17
     
    
    14 18
         <description id="torPreferences-builtinBridge-description"> </description>
    
    ... ... @@ -18,15 +22,13 @@
    18 22
               <!-- The radio option is described by both the "Current bridge" label
    
    19 23
               - and the full description. If the "Connected" label is hidden, then
    
    20 24
                - only the latter description should contribute. -->
    
    21
    -          <radio
    
    22
    -            aria-describedby="obfs-bridges-current obfs-bridges-description"
    
    23
    -            value="obfs4"
    
    24
    -          />
    
    25
    +          <radio value="obfs4" />
    
    25 26
               <html:span class="bridge-status-badge">
    
    26 27
                 <html:div class="bridge-status-icon"></html:div>
    
    27 28
                 <html:span
    
    28 29
                   id="obfs-bridges-current"
    
    29 30
                   class="torPreferences-current-bridge-label"
    
    31
    +              data-l10n-id="built-in-dialog-current-bridge-label"
    
    30 32
                 >
    
    31 33
                 </html:span>
    
    32 34
               </html:span>
    
    ... ... @@ -39,15 +41,13 @@
    39 41
           </vbox>
    
    40 42
           <vbox class="builtin-bridges-option">
    
    41 43
             <hbox>
    
    42
    -          <radio
    
    43
    -            aria-describedby="snowflake-bridges-current snowflake-bridges-description"
    
    44
    -            value="snowflake"
    
    45
    -          />
    
    44
    +          <radio value="snowflake" />
    
    46 45
               <html:span class="bridge-status-badge">
    
    47 46
                 <html:div class="bridge-status-icon"></html:div>
    
    48 47
                 <html:span
    
    49 48
                   id="snowflake-bridges-current"
    
    50 49
                   class="torPreferences-current-bridge-label"
    
    50
    +              data-l10n-id="built-in-dialog-current-bridge-label"
    
    51 51
                 >
    
    52 52
                 </html:span>
    
    53 53
               </html:span>
    
    ... ... @@ -60,15 +60,13 @@
    60 60
           </vbox>
    
    61 61
           <vbox class="builtin-bridges-option">
    
    62 62
             <hbox>
    
    63
    -          <radio
    
    64
    -            aria-describedby="meek-bridges-current meek-bridges-description"
    
    65
    -            value="meek-azure"
    
    66
    -          />
    
    63
    +          <radio value="meek-azure" />
    
    67 64
               <html:span class="bridge-status-badge">
    
    68 65
                 <html:div class="bridge-status-icon"></html:div>
    
    69 66
                 <html:span
    
    70 67
                   id="meek-bridges-current"
    
    71 68
                   class="torPreferences-current-bridge-label"
    
    69
    +              data-l10n-id="built-in-dialog-current-bridge-label"
    
    72 70
                 >
    
    73 71
                 </html:span>
    
    74 72
               </html:span>
    

  • browser/locales/en-US/browser/tor-browser.ftl
    ... ... @@ -297,3 +297,10 @@ user-provide-bridge-dialog-result-invite = The following bridges were shared wit
    297 297
     user-provide-bridge-dialog-result-addresses = The following bridges were entered by you.
    
    298 298
     user-provide-bridge-dialog-next-button =
    
    299 299
         .label = Next
    
    300
    +
    
    301
    +## Built-in bridges dialog.
    
    302
    +
    
    303
    +# Label attached to the built-in bridge option that is already in use.
    
    304
    +# The "aria-label" should use the same text, but include some ending punctuation to separate it from the sentence that follows. This is used for screen reader users.
    
    305
    +built-in-dialog-current-bridge-label = Current bridge
    
    306
    +    .aria-label = Current bridge.

  • toolkit/modules/TorStrings.sys.mjs
    ... ... @@ -98,7 +98,6 @@ const Loader = {
    98 98
           bridgeLocationFrequent: "Frequently selected locations",
    
    99 99
           bridgeLocationOther: "Other locations",
    
    100 100
           bridgeChooseForMe: "Choose a Bridge For Me…",
    
    101
    -      currentBridge: "Current bridge",
    
    102 101
           remove: "Remove",
    
    103 102
           bridgeDisableBuiltIn: "Disable built-in bridges",
    
    104 103
           copied: "Copied!",
    

  • toolkit/torbutton/chrome/locale/en-US/settings.properties
    ... ... @@ -33,7 +33,6 @@ settings.bridgeLocationFrequent=Frequently selected locations
    33 33
     settings.bridgeLocationOther=Other locations
    
    34 34
     settings.bridgeChooseForMe=Choose a Bridge For Me…
    
    35 35
     
    
    36
    -settings.currentBridge=Current bridge
    
    37 36
     settings.remove=Remove
    
    38 37
     settings.bridgeDisableBuiltIn=Disable built-in bridges
    
    39 38
     settings.copied=Copied!
    

  • _______________________________________________
    tor-commits mailing list
    tor-commits@xxxxxxxxxxxxxxxxxxxx
    https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits