mirror of
https://github.com/Donkie/Spoolman.git
synced 2026-10-22 10:02:17 -05:00
Weblate writes an empty string for every untranslated key. Paraglide compiles a present-but-empty value into a message function that returns "", so the site rendered a blank instead of falling back to English. A key that is absent from a locale, by contrast, is re-exported from the base locale and falls back correctly. Add scripts/strip-empty-locales.mjs to delete empty/whitespace-only leaves from the non-base locales/*/common.json before paraglide compiles them, turning "present-but-empty" into "absent". Idempotent, base en untouched, key order and formatting preserved. Wired as predev/prebuild so builds stay correct if empties reappear from a later Weblate sync; deliberately not a lint/CI gate, since empties are a benign expected input to be neutralised, not forbidden. Cleans 125 existing empties across 10 locales. Claude-Session: https://claude.ai/code/session_014Cwk5Yyze9yPvkYkUtMAP4