home · contact · privacy
Fix minor link formatting bug.
authorChristian Heller <c.heller@plomlompom.de>
Fri, 27 Nov 2020 02:16:01 +0000 (03:16 +0100)
committerChristian Heller <c.heller@plomlompom.de>
Fri, 27 Nov 2020 02:16:01 +0000 (03:16 +0100)
rogue_chat.html

index 74d3a2e774ec797c9de5f6e3b02eeb3d0e97a19b..381825429fb4240e7aa521c881e9e4157073df4d 100644 (file)
@@ -814,6 +814,10 @@ let tui = {
               if (in_link) {
                   push_inner_link(y, chunk.length);
                   url_start_x = 0;
+                  if (url_ends[0] == i) {
+                      in_link = false;
+                      url_ends.shift();
+                  }
               };
               lines.push(chunk);
               chunk = "";
@@ -830,7 +834,8 @@ let tui = {
               url_start_x = x;
               url = link_data[i];
               in_link = true;
-          } else if (url_ends.includes(i)) {
+          } else if (url_ends[0] == i) {
+              url_ends.shift();
               push_inner_link(y, x);
               in_link = false;
           }