From c18d4ffb71166f4cb8a0a951e0d2d20eda189c75 Mon Sep 17 00:00:00 2001 From: Doxa Maps Date: Sun, 27 Sep 2026 20:33:29 +0000 Subject: [PATCH] Drop eleven English fallbacks now their keys have landed MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit tOr() rendered English while a key was in flight. All eleven keys it guarded are on main, so it is gone and every call site reads the catalogue: nParts, engineMissing, sheet.loading, guide.wayInAll/wayInSome/wayInWhat, legend.hnrTip, guide.howNumbersMade, guide.isSignLanguage, sheet.linkCopied, sheet.share. I compared each default against the catalogue before deleting it, rather than assuming they matched — deleting a fallback silently changes what a reader sees. Ten were identical. The eleventh was not: gospel.sheet.share held my "Share this card" against the catalogue's "Share". The catalogue wins, because it is translated in eleven locales where my phrase was not and a button inside a card need not restate its container, so THE SHARE BUTTON NOW READS "Share" — a visible change, deliberate, and the shorter label suits the 390px screen where those tap targets were just fixed. The four parameterised calls needed doing by hand: my regex for tOr(key, english, params) stopped at the first ")" inside fmt(...), so it silently converted seven of eleven and left four. Counted the remainder instead of trusting the count it printed. gates:pre 11/11, ENGLISH-LEAKS PASS, and the built bundle no longer contains the inline English. --- .../gospel-resources/resources-map.vue | 36 +++++++-------- public/dx-maps/doxa-maps-spa/manifest.json | 12 ++--- .../gospel-resources/charts/index.html | 2 +- .../gospel-resources/data-tables/index.html | 2 +- .../gospel-dashboard/index.html | 2 +- .../gospel-resources/gospel-resources.js | 44 +++++++++---------- .../resources-list/index.html | 2 +- .../gospel-resources/resources-map/index.html | 2 +- public/dx-maps/manifest.json | 12 ++--- 9 files changed, 56 insertions(+), 58 deletions(-) diff --git a/plugin-designs/gospel-resources/resources-map.vue b/plugin-designs/gospel-resources/resources-map.vue index 61cabe017..86d7862a5 100644 --- a/plugin-designs/gospel-resources/resources-map.vue +++ b/plugin-designs/gospel-resources/resources-map.vue @@ -373,7 +373,7 @@ const sxScope = (sx) => { they are the same keys. Only the part count needed a new one. */ const name = n === 66 ? t('gospel.charts.fullBible') : n === 27 ? t('gospel.charts.newTestament') - : n ? tOr('gospel.res.nParts', '{n} parts', { n: fmt(n) }) + : n ? t('gospel.res.nParts', { n: fmt(n) }) : '' return name ? `${name} — ${sx.src}` : sx.src } @@ -902,14 +902,12 @@ const isEnglish = (() => { const readerLang = () => { try { return String(useI18n().locale.value || 'en') } catch { return 'en' } } -/* A TRANSLATION WHERE ONE EXISTS, TODAY'S ENGLISH WHERE IT DOES NOT — never the key name. - t() falls back to the key when a catalogue has no entry, which on a `title` attribute would - put "gospel.legend.hnrTip" in a tooltip: worse than the English it replaced. This keeps the - English in the template until the key lands, and switches the moment it does. */ -const tOr = (key, english, params) => { - const v = t(key, params) - return v && v !== key ? v : fill(english, params) -} +/* tOr() IS GONE, and what it hid is worth recording. It rendered English while a key was in + flight, and all eleven keys it guarded have landed — each compared against the catalogue one by + one rather than assumed. Ten were identical. The eleventh was not: gospel.sheet.share held my + inline "Share this card" against the catalogue's "Share", which is translated in eleven locales + where my phrase was not, so the catalogue wins and that button now reads Share. Deleting a + fallback silently changes what a reader sees, so this one was measured before it was deleted. */ const SE_KIND = { PDF: 'PDF', audio: 'audio', sab: 'app', study: 'study notes', viewer: 'read online' } const seKinds = (k) => (Array.isArray(k) ? k : []).map((x) => SE_KIND[x] || x).join(', ') @@ -1659,7 +1657,7 @@ onMounted(async () => { /* The console line stays English on purpose — it is for whoever is debugging the page, not for the reader. The line the READER sees goes through the catalogue. */ console.warn(`[gospel-resources] the ${grProvider} engine global never loaded — refusing to substitute another engine, because that would hand a keyless page the engine that needs a token.`) - err.value = tOr('messages.engineMissing', 'The {engine} map engine did not load.', { engine: providerLabel(grProvider) }) + err.value = t('messages.engineMissing', { engine: providerLabel(grProvider) }) return } if (!mapEl.value) return @@ -2160,7 +2158,7 @@ useShadowStyles( a card that is loading must look like one, and a card that failed must say so. -->
{{ err }} - {{ tOr('gospel.sheet.loading', 'Loading resources…') }} + {{ t('gospel.sheet.loading') }}
{{ pinTally.wayIn === pinTally.none - ? tOr('gospel.guide.wayInAll', 'Every one of those {n}', { n: fmt(pinTally.none) }) - : tOr('gospel.guide.wayInSome', '{n} of those {total}', { n: fmt(pinTally.wayIn), total: fmt(pinTally.none) }) }} - {{ tOr('gospel.guide.wayInWhat', 'has a way in — a bridge language, or SUN for a Deaf group. Tap one to see it.') }} + ? t('gospel.guide.wayInAll', { n: fmt(pinTally.none) }) + : t('gospel.guide.wayInSome', { n: fmt(pinTally.wayIn), total: fmt(pinTally.none) }) }} + {{ t('gospel.guide.wayInWhat') }}

@@ -2332,7 +2330,7 @@ useShadowStyles(
{{ t('gospel.guide.noneFoundShort') }}
{{ t('gospel.guide.tapCountry') }}
- {{ tOr('gospel.guide.howNumbersMade', 'How these numbers are made') }} + {{ t('gospel.guide.howNumbersMade') }}
A way in is not the gospel in someone's own language; the gap it is counted against is unchanged by it. @@ -2928,7 +2926,7 @@ useShadowStyles(

- {{ tOr('gospel.guide.isSignLanguage', 'This is a sign language.') }} A Deaf group cannot be reached by a text + {{ t('gospel.guide.isSignLanguage') }} A Deaf group cannot be reached by a text translation, so eBible's silence here is not an absence of Scripture — it is a text pool that was never the right place to look. What counts is Scripture filmed in this sign language. Of {{ fmt(signTally.langs) }} sign languages @@ -2992,7 +2990,7 @@ useShadowStyles( WhatsApp or SMS — and the clipboard is the desktop fallback. A cancelled share is not an error and must not look like one. --> ", - "script": "\n\n" + "script": "\n\n" } }, { @@ -760,7 +760,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n" + "script": "\n\n" } }, { @@ -775,7 +775,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n\n\n" + "script": "\n\n\n\n" } }, { @@ -790,7 +790,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n" + "script": "\n\n" } }, { @@ -805,7 +805,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n\n\n" + "script": "\n\n\n\n" } } ] diff --git a/public/dx-maps/gospel-resources/charts/index.html b/public/dx-maps/gospel-resources/charts/index.html index 2a0f976f9..6aea1df88 100644 --- a/public/dx-maps/gospel-resources/charts/index.html +++ b/public/dx-maps/gospel-resources/charts/index.html @@ -32,7 +32,7 @@ - + - + - + - + - + \n\n" + "script": "\n\n" } }, { @@ -760,7 +760,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n" + "script": "\n\n" } }, { @@ -775,7 +775,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n\n\n" + "script": "\n\n\n\n" } }, { @@ -790,7 +790,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n" + "script": "\n\n" } }, { @@ -805,7 +805,7 @@ "scriptUrl": "./gospel-resources/gospel-resources.js", "embed": { "iframe": "", - "script": "\n\n\n\n" + "script": "\n\n\n\n" } } ]