From ab7a17c971a47ceeecd7ea42cd565aceeedbcb79 Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 24 May 2026 16:58:15 +0000 Subject: [PATCH] Set date input .value property directly so picker opens to the correct month setAttribute only sets the defaultValue attribute; the browser date picker uses the .value property to determine which month to show on open. https://claude.ai/code/session_01MbwfxnjLA9KdFTrfzB55HM --- app/index.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/index.html b/app/index.html index b7391d2..0d42c68 100644 --- a/app/index.html +++ b/app/index.html @@ -368,7 +368,8 @@ function renderLine(ln, item) { const baseCur = state.baseCurrency; // Row 1: Date, Vendor, Currency, FX Rate - const dateIn = el('input', {type:'date', value: ln.date, style:{width:'150px'}}); + const dateIn = el('input', {type:'date', style:{width:'150px'}}); + if (ln.date) dateIn.value = ln.date; if (ln.date && !isDateInPeriod(ln.date)) dateIn.classList.add('input-warn'); dateIn.addEventListener('change', async () => { ln.date = dateIn.value;