Tweak aesthetics
dkl9

dkl9 commited on 2025-361 18:06:56
Showing 2 changed files, with 7 additions and 5 deletions.

... ...
@@ -11,7 +11,7 @@
11 11
             #mobile td { min-width: min(16vw, 5rem); height: min(16vw, 5rem); text-align: center; }
12 12
             #plot { border: 1px solid grey; flex-shrink: 0; width: min(90vw, 25em); height: min(90vw, 25em); flex-shrink: 0; }
13 13
             #grid { border-collapse: separate; border-spacing: 3px 12px; margin-top: 10px; }
14
-            #grid td { min-width: min(13vw, 4rem); height: min(13vw, 4rem); border: 1px solid #ccc; text-align: center; vertical-align: middle; font-weight: bold; transition: transform 0.3s ease; }
14
+            #grid td { min-width: min(13vw, 5rem); height: min(13vw, 5rem); border: 1px solid #ccc; text-align: center; vertical-align: middle; font-weight: bold; transition: transform 0.3s ease; padding: 0; }
15 15
             .grey { background: #787c7e; }
16 16
             .yellow { background: #c9b458; }
17 17
             .green { background: #6aaa64; }
... ...
@@ -19,10 +19,11 @@ switch (host) {
19 19
             const score = localStorage.getItem("score").split("\n");
20 20
             if (playedToday(score)) {
21 21
                 const [g, m] = score[0].split(" ")[2].split("/");
22
-                const note = elemText(`You already played today and `);
22
+                const note = elemText(`You already played today and `, "section");
23 23
                 note.textContent += (g <= m) ? `got it in ${g} guess${g == 1 ? "" : "es"}` : `didn't figure it out`;
24 24
                 note.textContent += ". Come back tomorrow. Full score on clipboard.";
25
-                container.prepend(note);
25
+                note.classList.add("side");
26
+                grid.parentElement.before(note);
26 27
                 navigator.clipboard.writeText(score.join("\n"));
27 28
             }
28 29
         })();
... ...
@@ -265,8 +266,9 @@ function winMessage() {
265 266
     b.type = "button";
266 267
     b.addEventListener("click", () => navigator.clipboard.writeText(boast));
267 268
     w.append(b);
268
-    w.append(" Come back tomorrow for the next function.");
269
-    container.prepend(w);
269
+    w.append("\nCome back tomorrow for the next function.");
270
+    w.classList.add("side");
271
+    grid.parentElement.before(w);
270 272
 }
271 273
 
272 274
 function loseMessage() {
273 275