From 95891013d15789723f49eafe7380a73f36abae9b Mon Sep 17 00:00:00 2001 From: Kiyomichi Kosaka Date: Sat, 14 Jun 2025 23:52:10 +0200 Subject: [PATCH] Fix input centering and smooth clock hand --- clock.js | 6 +++--- script.js | 5 +++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/clock.js b/clock.js index f2f082d..389fcb9 100644 --- a/clock.js +++ b/clock.js @@ -89,9 +89,9 @@ function updateClock() { const now = new Date(); const cob = toCobiets(now); - const xf = (cob % COBIE_UNITS.quantic) / COBIE_UNITS.quantic; - const qf = (cob % COBIE_UNITS.chronon) / COBIE_UNITS.chronon; - const cf = (cob % COBIE_UNITS.eonstrip) / COBIE_UNITS.eonstrip; + const xf = cob / COBIE_UNITS.quantic; + const qf = cob / COBIE_UNITS.chronon; + const cf = cob / COBIE_UNITS.eonstrip; document.getElementById('handXeno').style.transform = `rotate(${xf * 360}deg)`; document.getElementById('handQuantic').style.transform = `rotate(${qf * 360}deg)`; document.getElementById('handChronon').style.transform = `rotate(${cf * 360}deg)`; diff --git a/script.js b/script.js index c786c47..ef10ef9 100644 --- a/script.js +++ b/script.js @@ -949,10 +949,11 @@ function enterEdit() { input.style.border = 'none'; input.style.color = 'inherit'; input.style.textAlign = 'center'; - input.style.width = '12ch'; + input.style.width = '100%'; + input.style.boxSizing = 'border-box'; // keep the input visually centered like the original span input.style.display = 'block'; - input.style.margin = '0 auto'; + input.style.margin = '10px 0'; span.replaceWith(input); input.focus(); input.setSelectionRange(1, val.length);