[tor-commits] [atlas/master] Switch flags icons to use new Tor icons (See: #24399)

irl at torproject.org irl at torproject.org
Sun Dec 17 19:25:02 UTC 2017


commit b45a1c4e93411d9d5f410386be0f6ad5eb733a7f
Author: Iain R. Learmonth <irl at fsfe.org>
Date:   Sun Dec 17 11:53:16 2017 +0000

    Switch flags icons to use new Tor icons (See: #24399)
---
 img/flags/authority.png                      | Bin 0 -> 325 bytes
 img/flags/award_stroke_8x16.png              | Bin 186 -> 0 bytes
 img/flags/badexit.png                        | Bin 0 -> 403 bytes
 img/flags/bolt_16x16.png                     | Bin 206 -> 0 bytes
 img/flags/book_14x16.png                     | Bin 181 -> 0 bytes
 img/flags/book_alt_16x16.png                 | Bin 180 -> 0 bytes
 img/flags/bridge.png                         | Bin 0 -> 273 bytes
 img/flags/cd_16x16.png                       | Bin 210 -> 0 bytes
 img/flags/check_alt_16x16.png                | Bin 223 -> 0 bytes
 img/flags/cloud_download_16x16.png           | Bin 224 -> 0 bytes
 img/flags/cog_16x16.png                      | Bin 236 -> 0 bytes
 img/flags/country.png                        | Bin 0 -> 291 bytes
 img/flags/denied_16x16.png                   | Bin 244 -> 0 bytes
 img/flags/exit.png                           | Bin 0 -> 321 bytes
 img/flags/fallbackdir.png                    | Bin 0 -> 458 bytes
 img/flags/fast.png                           | Bin 0 -> 295 bytes
 img/flags/fingerprint.png                    | Bin 0 -> 455 bytes
 img/flags/fork_14x16.png                     | Bin 200 -> 0 bytes
 img/flags/guard.png                          | Bin 0 -> 371 bytes
 img/flags/hibernating.png                    | Bin 0 -> 303 bytes
 img/flags/hsdir.png                          | Bin 0 -> 479 bytes
 img/flags/info_8x16.png                      | Bin 170 -> 0 bytes
 img/flags/ipv4.png                           | Bin 0 -> 396 bytes
 img/flags/ipv6.png                           | Bin 0 -> 406 bytes
 img/flags/ipv6exit.png                       | Bin 0 -> 364 bytes
 img/flags/noedconsensus.png                  | Bin 0 -> 350 bytes
 img/flags/notrecommended.png                 | Bin 0 -> 381 bytes
 img/flags/onion-alt.png                      | Bin 0 -> 411 bytes
 img/flags/onion.png                          | Bin 0 -> 352 bytes
 img/flags/question_mark_8x16.png             | Bin 210 -> 0 bytes
 img/flags/reachableipv4.png                  | Bin 0 -> 370 bytes
 img/flags/reachableipv6.png                  | Bin 0 -> 394 bytes
 img/flags/relay.png                          | Bin 0 -> 357 bytes
 img/flags/running.png                        | Bin 0 -> 244 bytes
 img/flags/share_16x16.png                    | Bin 210 -> 0 bytes
 img/flags/spin_14x16.png                     | Bin 243 -> 0 bytes
 img/flags/stable.png                         | Bin 0 -> 349 bytes
 img/flags/star_16x16.png                     | Bin 244 -> 0 bytes
 img/flags/tshirt.png                         | Bin 0 -> 321 bytes
 img/flags/unmeasured.png                     | Bin 0 -> 318 bytes
 img/flags/unreachableipv4.png                | Bin 0 -> 382 bytes
 img/flags/unreachableipv6.png                | Bin 0 -> 402 bytes
 img/flags/v2dir-alt.png                      | Bin 0 -> 485 bytes
 img/flags/v2dir.png                          | Bin 0 -> 280 bytes
 img/flags/valid.png                          | Bin 0 -> 373 bytes
 img/properties/fallbackdir_16x16.png         | Bin 247 -> 0 bytes
 img/properties/ipv6_exit_16x16.png           | Bin 470 -> 0 bytes
 img/properties/ipv6_or_16x16.png             | Bin 444 -> 0 bytes
 img/properties/ipv6_or_unreachable_16x16.png | Bin 518 -> 0 bytes
 img/properties/not_recommended_16x16.png     | Bin 323 -> 0 bytes
 img/properties/unmeasured_16x16.png          | Bin 199 -> 0 bytes
 js/models/relay.js                           |  47 ++++++++++++---------------
 templates/details/bridge.html                |   2 +-
 templates/details/router.html                |   2 +-
 templates/search/do.html                     |   2 +-
 55 files changed, 23 insertions(+), 30 deletions(-)

diff --git a/img/flags/authority.png b/img/flags/authority.png
new file mode 100644
index 0000000..ebd207b
Binary files /dev/null and b/img/flags/authority.png differ
diff --git a/img/flags/award_stroke_8x16.png b/img/flags/award_stroke_8x16.png
deleted file mode 100644
index d9014d3..0000000
Binary files a/img/flags/award_stroke_8x16.png and /dev/null differ
diff --git a/img/flags/badexit.png b/img/flags/badexit.png
new file mode 100644
index 0000000..b5d8a73
Binary files /dev/null and b/img/flags/badexit.png differ
diff --git a/img/flags/bolt_16x16.png b/img/flags/bolt_16x16.png
deleted file mode 100644
index 2bc9544..0000000
Binary files a/img/flags/bolt_16x16.png and /dev/null differ
diff --git a/img/flags/book_14x16.png b/img/flags/book_14x16.png
deleted file mode 100644
index 54170f9..0000000
Binary files a/img/flags/book_14x16.png and /dev/null differ
diff --git a/img/flags/book_alt_16x16.png b/img/flags/book_alt_16x16.png
deleted file mode 100644
index 0fa8062..0000000
Binary files a/img/flags/book_alt_16x16.png and /dev/null differ
diff --git a/img/flags/bridge.png b/img/flags/bridge.png
new file mode 100644
index 0000000..a0cbfa6
Binary files /dev/null and b/img/flags/bridge.png differ
diff --git a/img/flags/cd_16x16.png b/img/flags/cd_16x16.png
deleted file mode 100644
index 4805b21..0000000
Binary files a/img/flags/cd_16x16.png and /dev/null differ
diff --git a/img/flags/check_alt_16x16.png b/img/flags/check_alt_16x16.png
deleted file mode 100644
index 3bd1002..0000000
Binary files a/img/flags/check_alt_16x16.png and /dev/null differ
diff --git a/img/flags/cloud_download_16x16.png b/img/flags/cloud_download_16x16.png
deleted file mode 100644
index f5d5f80..0000000
Binary files a/img/flags/cloud_download_16x16.png and /dev/null differ
diff --git a/img/flags/cog_16x16.png b/img/flags/cog_16x16.png
deleted file mode 100644
index a72b619..0000000
Binary files a/img/flags/cog_16x16.png and /dev/null differ
diff --git a/img/flags/country.png b/img/flags/country.png
new file mode 100644
index 0000000..9eda2b2
Binary files /dev/null and b/img/flags/country.png differ
diff --git a/img/flags/denied_16x16.png b/img/flags/denied_16x16.png
deleted file mode 100644
index 4acbf6b..0000000
Binary files a/img/flags/denied_16x16.png and /dev/null differ
diff --git a/img/flags/exit.png b/img/flags/exit.png
new file mode 100644
index 0000000..6596e53
Binary files /dev/null and b/img/flags/exit.png differ
diff --git a/img/flags/fallbackdir.png b/img/flags/fallbackdir.png
new file mode 100644
index 0000000..0c25009
Binary files /dev/null and b/img/flags/fallbackdir.png differ
diff --git a/img/flags/fast.png b/img/flags/fast.png
new file mode 100644
index 0000000..7c65b9f
Binary files /dev/null and b/img/flags/fast.png differ
diff --git a/img/flags/fingerprint.png b/img/flags/fingerprint.png
new file mode 100644
index 0000000..b1b1ebf
Binary files /dev/null and b/img/flags/fingerprint.png differ
diff --git a/img/flags/fork_14x16.png b/img/flags/fork_14x16.png
deleted file mode 100644
index b000ca0..0000000
Binary files a/img/flags/fork_14x16.png and /dev/null differ
diff --git a/img/flags/guard.png b/img/flags/guard.png
new file mode 100644
index 0000000..1c55c39
Binary files /dev/null and b/img/flags/guard.png differ
diff --git a/img/flags/hibernating.png b/img/flags/hibernating.png
new file mode 100644
index 0000000..5e6e2d4
Binary files /dev/null and b/img/flags/hibernating.png differ
diff --git a/img/flags/hsdir.png b/img/flags/hsdir.png
new file mode 100644
index 0000000..19e3126
Binary files /dev/null and b/img/flags/hsdir.png differ
diff --git a/img/flags/info_8x16.png b/img/flags/info_8x16.png
deleted file mode 100644
index 1227d2f..0000000
Binary files a/img/flags/info_8x16.png and /dev/null differ
diff --git a/img/flags/ipv4.png b/img/flags/ipv4.png
new file mode 100644
index 0000000..d9e3de8
Binary files /dev/null and b/img/flags/ipv4.png differ
diff --git a/img/flags/ipv6.png b/img/flags/ipv6.png
new file mode 100644
index 0000000..1665726
Binary files /dev/null and b/img/flags/ipv6.png differ
diff --git a/img/flags/ipv6exit.png b/img/flags/ipv6exit.png
new file mode 100644
index 0000000..5603a4e
Binary files /dev/null and b/img/flags/ipv6exit.png differ
diff --git a/img/flags/noedconsensus.png b/img/flags/noedconsensus.png
new file mode 100644
index 0000000..e68495c
Binary files /dev/null and b/img/flags/noedconsensus.png differ
diff --git a/img/flags/notrecommended.png b/img/flags/notrecommended.png
new file mode 100644
index 0000000..f7a93d4
Binary files /dev/null and b/img/flags/notrecommended.png differ
diff --git a/img/flags/onion-alt.png b/img/flags/onion-alt.png
new file mode 100644
index 0000000..ace78cf
Binary files /dev/null and b/img/flags/onion-alt.png differ
diff --git a/img/flags/onion.png b/img/flags/onion.png
new file mode 100644
index 0000000..e738fda
Binary files /dev/null and b/img/flags/onion.png differ
diff --git a/img/flags/question_mark_8x16.png b/img/flags/question_mark_8x16.png
deleted file mode 100644
index 8059df9..0000000
Binary files a/img/flags/question_mark_8x16.png and /dev/null differ
diff --git a/img/flags/reachableipv4.png b/img/flags/reachableipv4.png
new file mode 100644
index 0000000..e929d87
Binary files /dev/null and b/img/flags/reachableipv4.png differ
diff --git a/img/flags/reachableipv6.png b/img/flags/reachableipv6.png
new file mode 100644
index 0000000..b4f6990
Binary files /dev/null and b/img/flags/reachableipv6.png differ
diff --git a/img/flags/relay.png b/img/flags/relay.png
new file mode 100644
index 0000000..ee171d4
Binary files /dev/null and b/img/flags/relay.png differ
diff --git a/img/flags/running.png b/img/flags/running.png
new file mode 100644
index 0000000..6d716cf
Binary files /dev/null and b/img/flags/running.png differ
diff --git a/img/flags/share_16x16.png b/img/flags/share_16x16.png
deleted file mode 100644
index a0df554..0000000
Binary files a/img/flags/share_16x16.png and /dev/null differ
diff --git a/img/flags/spin_14x16.png b/img/flags/spin_14x16.png
deleted file mode 100644
index f19b912..0000000
Binary files a/img/flags/spin_14x16.png and /dev/null differ
diff --git a/img/flags/stable.png b/img/flags/stable.png
new file mode 100644
index 0000000..172e618
Binary files /dev/null and b/img/flags/stable.png differ
diff --git a/img/flags/star_16x16.png b/img/flags/star_16x16.png
deleted file mode 100644
index 3b3952d..0000000
Binary files a/img/flags/star_16x16.png and /dev/null differ
diff --git a/img/flags/tshirt.png b/img/flags/tshirt.png
new file mode 100644
index 0000000..46384f0
Binary files /dev/null and b/img/flags/tshirt.png differ
diff --git a/img/flags/unmeasured.png b/img/flags/unmeasured.png
new file mode 100644
index 0000000..8b0e43a
Binary files /dev/null and b/img/flags/unmeasured.png differ
diff --git a/img/flags/unreachableipv4.png b/img/flags/unreachableipv4.png
new file mode 100644
index 0000000..497d4c6
Binary files /dev/null and b/img/flags/unreachableipv4.png differ
diff --git a/img/flags/unreachableipv6.png b/img/flags/unreachableipv6.png
new file mode 100644
index 0000000..db44b88
Binary files /dev/null and b/img/flags/unreachableipv6.png differ
diff --git a/img/flags/v2dir-alt.png b/img/flags/v2dir-alt.png
new file mode 100644
index 0000000..a68b7ee
Binary files /dev/null and b/img/flags/v2dir-alt.png differ
diff --git a/img/flags/v2dir.png b/img/flags/v2dir.png
new file mode 100644
index 0000000..c330702
Binary files /dev/null and b/img/flags/v2dir.png differ
diff --git a/img/flags/valid.png b/img/flags/valid.png
new file mode 100644
index 0000000..6de0737
Binary files /dev/null and b/img/flags/valid.png differ
diff --git a/img/properties/fallbackdir_16x16.png b/img/properties/fallbackdir_16x16.png
deleted file mode 100644
index dc05f4f..0000000
Binary files a/img/properties/fallbackdir_16x16.png and /dev/null differ
diff --git a/img/properties/ipv6_exit_16x16.png b/img/properties/ipv6_exit_16x16.png
deleted file mode 100644
index e47a791..0000000
Binary files a/img/properties/ipv6_exit_16x16.png and /dev/null differ
diff --git a/img/properties/ipv6_or_16x16.png b/img/properties/ipv6_or_16x16.png
deleted file mode 100644
index f6c4dc3..0000000
Binary files a/img/properties/ipv6_or_16x16.png and /dev/null differ
diff --git a/img/properties/ipv6_or_unreachable_16x16.png b/img/properties/ipv6_or_unreachable_16x16.png
deleted file mode 100644
index a17333c..0000000
Binary files a/img/properties/ipv6_or_unreachable_16x16.png and /dev/null differ
diff --git a/img/properties/not_recommended_16x16.png b/img/properties/not_recommended_16x16.png
deleted file mode 100644
index b8a3634..0000000
Binary files a/img/properties/not_recommended_16x16.png and /dev/null differ
diff --git a/img/properties/unmeasured_16x16.png b/img/properties/unmeasured_16x16.png
deleted file mode 100644
index 9db7a5e..0000000
Binary files a/img/properties/unmeasured_16x16.png and /dev/null differ
diff --git a/js/models/relay.js b/js/models/relay.js
index 1204544..813030d 100644
--- a/js/models/relay.js
+++ b/js/models/relay.js
@@ -10,49 +10,43 @@ define([
 	var relayModel = Backbone.Model.extend({
         baseurl: 'https://onionoo.torproject.org',
         fingerprint: '',
-        parseflags: function(flags, size) {
+        parseflags: function(flags) {
             var output = [];
             var model = this;
             _.each(flags, function(flag) {
                 if (flag == "Authority") {
-                    output.push([flag,"award_stroke_"+size[2], "This relay is a directory authority."]);
+                    output.push([flag, "authority", "This relay is a directory authority."]);
                 }
                 if (flag == "BadExit") {
                     model.set({badexit: true});
-                    output.push([flag, "denied_"+size[0], "This relay is believed to be useless as an exit node (because its ISP censors it, because it is behind a restrictive proxy, or for some similar reason)."]);
+                    output.push([flag, "badexit", "This relay is believed to be useless as an exit node (because its ISP censors it, because it is behind a restrictive proxy, or for some similar reason)."]);
                 }
                 if (flag == "Fast") {
-                    output.push([flag,"bolt_"+size[0], "This relay is suitable for high-bandwidth circuits."]);
+                    output.push([flag, "fast", "This relay is suitable for high-bandwidth circuits."]);
                 }
                 if (flag == "Guard") {
-                    output.push([flag,"share_"+size[0], "This relay is suitable for use as an entry guard."]);
+                    output.push([flag, "guard", "This relay is suitable for use as an entry guard."]);
                 }
                 if (flag == "HSDir") {
-                    output.push([flag,"book_alt_"+size[0], "This relay is considered a v2 hidden service directory."]);
-                }
-                if (flag == "Named") {
-                    output.push([flag,"info_"+size[2], "This relay's identity-nickname mapping is canonical, and this authority binds names."]);
+                    output.push([flag, "hsdir", "This relay is considered a v2 hidden service directory."]);
                 }
                 if (flag == "NoEdConsensus") {
-                    output.push([flag,"question_mark_"+size[2], "An Ed25519 key in the relay's descriptor or microdesriptor does not reflect authority consensus."]);
+                    output.push([flag, "noedconensus", "An Ed25519 key in the relay's descriptor or microdesriptor does not reflect authority consensus."]);
                 }
                 if (flag == "Running") {
-                    output.push([flag,"fork_"+size[1], "This relay is currently usable."]);
+                    output.push([flag, "running", "This relay is currently usable."]);
                 }
                 if (flag == "Stable") {
-                    output.push([flag,"cd_"+size[0], "This relay is suitable for long-lived circuits."]);
+                    output.push([flag, "stable", "This relay is suitable for long-lived circuits."]);
                 }
                 if (flag == "V2Dir") {
-                    output.push([flag,"book_"+size[1], "This relay implements the v2 directory protocol or higher."]);
+                    output.push([flag, "v2dir-alt", "This relay implements the v2 directory protocol or higher."]);
                 }
                 if (flag == "Valid") {
-                    output.push([flag,"check_alt_"+size[0], "This relay has been 'validated'."]);
-                }
-                if (flag == "Unnamed") {
-                    output.push([flag,"question_mark_"+size[2], "Another relay has bound the name used by this relay, and this authority binds names."]);
+                    output.push([flag, "valid", "This relay has been 'validated'."]);
                 }
                 if (flag == "Exit") {
-                    output.push([flag,"cloud_download_"+size[0], "This relay is more useful for building general-purpose exit circuits than for relay circuits."]);
+                    output.push([flag, "exit", "This relay is more useful for building general-purpose exit circuits than for relay circuits."]);
                 }
             });
             return output;
@@ -62,19 +56,19 @@ define([
             var model = this;
             _.each(flags, function(flag) {
                 if (flag == "Not Recommended") {
-                    output.push([flag,"not_recommended_16x16", "This relay is running a Tor version that is not recommended by the directory authorities and may contain known issues."]);
+                    output.push([flag,"notrecommended", "This relay is running a Tor version that is not recommended by the directory authorities and may contain known issues."]);
                 }
                 if (flag == "Unmeasured") {
-                    output.push([flag,"unmeasured_16x16", "This relay has not been measured by at least 3 bandwidth authorities and so its consensus weight is currently capped. This is expected for new relays."]);
+                    output.push([flag,"unmeasured", "This relay has not been measured by at least 3 bandwidth authorities and so its consensus weight is currently capped. This is expected for new relays."]);
                 }
                 if (flag == "FallbackDir") {
-                    output.push([flag,"fallbackdir_16x16", "Tor clients contact fallback directory mirrors during bootstrap, and download the consensus and authority certificates from them. We include a default list of mirrors in the Tor source code. These default mirrors need to be long-term stable, and on the same IPv4 and IPv6 addresses and ports."]);
+                    output.push([flag,"fallbackdir", "Tor clients contact fallback directory mirrors during bootstrap, and download the consensus and authority certificates from them. We include a default list of mirrors in the Tor source code. These default mirrors need to be long-term stable, and on the same IPv4 and IPv6 addresses and ports."]);
                 }
-                if (flag == "IPv6 ORPort") {
-                    output.push([flag,"ipv6_or_16x16", "This relay accepts OR connections using IPv6."]);
+                if (flag == "ReachableIPv6") {
+                    output.push([flag,"reachableipv6", "This relay accepts OR connections using IPv6."]);
                 }
                 if (flag == "IPv6 Exit") {
-                    output.push([flag,"ipv6_exit_16x16", "This relay allows exit connections using IPv6."]);
+                    output.push([flag, "ipv6exit", "This relay allows exit connections using IPv6."]);
                 }
             });
             return output;
@@ -223,15 +217,14 @@ define([
                     relay.transports = relay.transports ? relay.transports : null;
                     relay.fingerprint = relay.hashed_fingerprint ? relay.hashed_fingerprint : relay.fingerprint;
                     model.set({badexit: false});
-                    var size = ['16x16', '14x16', '8x16'];
-                    relay.flags = model.parseflags(relay.flags, size);
+                    relay.flags = model.parseflags(relay.flags);
 
                     /* Synthetic Additional Flags */
                     var additional_flags = []
                     if (!((typeof relay.recommended_version !== 'undefined') ? relay.recommended_version : true)) additional_flags.push("Not Recommended");
                     if (!((typeof relay.measured !== 'undefined') ? relay.measured : true)) additional_flags.push("Unmeasured");
                     if (IsFallbackDir(relay.fingerprint)) additional_flags.push("FallbackDir");
-                    if (relay.or_v6_addresses.length > 0) additional_flags.push("IPv6 ORPort");
+                    if (relay.or_v6_addresses.length > 0) additional_flags.push("ReachableIPv6");
                     if (relay.exit_policy_v6_summary !== null) additional_flags.push("IPv6 Exit");
 
                     relay.additional_flags = model.parseadditionalflags(additional_flags);
diff --git a/templates/details/bridge.html b/templates/details/bridge.html
index e74ce93..66fa8c1 100644
--- a/templates/details/bridge.html
+++ b/templates/details/bridge.html
@@ -61,7 +61,7 @@
         <% var propertyCount = 0; %>
         <% _.each(relay.get('additional_flags'), function(flag) { propertyCount++; %>
             <span class="tip flags" title="<%= flag[2] %>">
-                <img class="inline" alt="" src="img/properties/<%= flag[1] %>.png"/>
+                <img class="inline" alt="" src="img/flags/<%= flag[1] %>.png"/>
                 <span class="inline"><%= flag[0] %></span>
             </span>
         <% }); %>
diff --git a/templates/details/router.html b/templates/details/router.html
index 2aea6b2..b92d6ad 100644
--- a/templates/details/router.html
+++ b/templates/details/router.html
@@ -124,7 +124,7 @@
         <% var propertyCount = 0; %>
         <% _.each(relay.get('additional_flags'), function(flag) { propertyCount++; %>
             <span class="tip flags" title="<%= flag[2] %>">
-                <img class="inline" alt="" src="img/properties/<%= flag[1] %>.png"/>
+                <img class="inline" alt="" src="img/flags/<%= flag[1] %>.png"/>
                 <span class="inline"><%= flag[0] %></span>
             </span>
         <% }); %>
diff --git a/templates/search/do.html b/templates/search/do.html
index 5575c4c..7f98106 100644
--- a/templates/search/do.html
+++ b/templates/search/do.html
@@ -104,7 +104,7 @@
             <% _.each(relay.get('flags'), function(flag) { %><img class="tip flags" src="img/flags/<%= flag[1] %>.png" alt="<%= flag[0] %>" title="<%= flag[0] %><br /><%= flag[2] %>"/><% }); %>
             </td>
             <td>
-            <% _.each(relay.get('additional_flags'), function(flag) { %><img class="tip flags" src="img/properties/<%= flag[1] %>.png" alt="<%= flag[0] %>" title="<%= flag[0] %><br /><%= flag[2] %>"/><% }); %>
+            <% _.each(relay.get('additional_flags'), function(flag) { %><img class="tip flags" src="img/flags/<%= flag[1] %>.png" alt="<%= flag[0] %>" title="<%= flag[0] %><br /><%= flag[2] %>"/><% }); %>
             </td>
 			<td><%= relay.get('or_port') %></td>
 			<td><%= relay.get('dir_port') %></td>





More information about the tor-commits mailing list