From 257f05a546705d3f7167087448aaa2afd28b73cb Mon Sep 17 00:00:00 2001 From: Brian Picciano Date: Mon, 22 Nov 2021 08:42:17 -0700 Subject: [PATCH] fix radix link, block width, and make fuckItUp better --- index.html | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index bd17b2f..d389ab8 100644 --- a/index.html +++ b/index.html @@ -19,7 +19,7 @@ a:visited { color:#bada55; font-weight: normal; } a:hover { color:#bada55; text-decoration: none; } .fuck-it-up { font-family:Courier,monospace; font-size:8pt; line-height:4pt; color:#bada55; } - .block { padding:3rem 0 3rem 3rem; float:left; min-width:40vw; } + .block { padding:3rem 0 3rem 3rem; float:left; } @@ -126,7 +126,7 @@

Projects

@@ -139,6 +139,22 @@ const fuckItUpEls = document.querySelectorAll(".fuck-it-up"); + // right-pad the lines in each fuck-it-up + fuckItUpEls.forEach((pre) => { + + const lines = pre.innerText.split('\n'); + + let maxL = 0; + lines.forEach((line) => { + maxL = maxL > line.length ? maxL : line.length; + }); + + pre.innerText = lines.map((line) => + line + " ".repeat(maxL - line.length) + ).join('\n'); + + }); + function fuckItUp() { fuckItUpEls.forEach((pre) => { while (true) { @@ -151,7 +167,6 @@ var bChar = txt.charAt(b); if ( - aChar == " " || bChar == " " || aChar == "\n" || bChar == "\n" ) continue;