Ticket: HEL-686
Date: 2026-04-08
pages/_V1/ (30 files, dead weight)V1 deletion: Archived pages still compile in every Evidence build, adding Vite bundle overhead and sidebar clutter.
AR grey flash: Root cause is ButtonGroup, not slow queries. Git history shows this exact issue was diagnosed and fixed in b5c8493: "ButtonGroup's store update pattern doesn't properly propagate through Evidence's setTrackProxy/hasUnsetValues reactive query system in production builds, causing dependent queries to be held indefinitely after clicking." ButtonGroup was re-introduced in 785c6e7 for "cleaner navigation" and the bug came back. Dropdown uses Evidence's recommended input pattern and propagates correctly.
rm -rf pages/_V1/
In pages/Finance/accounts_receivable.md:
<!-- Before -->
<ButtonGroup name=selected_month data={ar_months} value=month_start label=month_label defaultValue={default_dates[0].current_month_start} title="View Month"/>
<!-- After -->
<Dropdown name=selected_month data={ar_months} value=month_start label=month_label order=month_start defaultValue={default_dates[0].current_month_start} title="View Month"/>
order=month_start keeps months in calendar order (not alphabetical).
.value accessor in all SQL queries — Dropdown exposes inputs.selected_month.value, ButtonGroup exposed inputs.selected_month directly. Update every reference in daily_ar_month and student_payment_details:-- Before (ButtonGroup)
'${inputs.selected_month}'
-- After (Dropdown)
'${inputs.selected_month.value}'
Keep the COALESCE fallbacks added in 785c6e7 — those fixed a real separate issue with empty string casting on first page load.
pages/_V1/ — delete entire directorypages/Finance/accounts_receivable.md — swap ButtonGroup → Dropdown; restore .value accessor (affects daily_ar_month × 2 refs, student_payment_details × 2 refs, heading interpolation)pages/_V1/ does not existnpm run build passes clean