Skip to content

fix(i18n): english base for the site schema, translated server messages and proofread texts - #197

Merged
BatLeDev merged 15 commits into
masterfrom
i18n-small-fixes
Nov 16, 2026
Merged

BatLeDev merged 15 commits into
masterfrom
i18n-small-fixes

Conversation

@BatLeDev

@BatLeDev BatLeDev commented Nov 13, 2026 •

Copy link
Copy Markdown
Member

Fix the FR/EN issues found by the platform-wide i18n audit, move the site schema to an English base, and proofread the messages in all 6 languages.

  • Site schema (api/types/site/schema.js, api/doc/sites/patch-req-body): English base texts, fr/de/es/it/pt kept in x-i18n-*, redundant en entries dropped. Generated type names follow the English titles; the imported types (Site, SitePost, SitePatch, OpenIDConnect, $defs) keep their names.
  • Server messages: user-facing errors that were hard-coded in French follow the request language (partner invitations, members quota, contact form, SSO role/department, OAuth email checks…). Where no request is at hand, a new I18nHttpError carries a message key, translated by i18nErrorMiddleware (and on the login page after an OAuth/SAML callback). Pure logs and internal errors are in English.
  • UI: hard-coded French strings of the admin pages moved to <i18n> keys, plural forms instead of "(s)", session locale for toLocaleString(), vue-i18n in composition mode with fallbackLocale: 'en', static lang="en" in index.html replaced by the session language through a watchEffect (unhead removed: it only set that attribute and the login page title, now document.title restored on unmount), fixed title of the downloaded 2FA recovery codes.
  • Proofreading: fr and en texts, then de/es/it/pt (one register per language, pt-BR, missing keys added so they no longer fall back to French). OAuth scopes are called "portées" in French.
  • Deps: lib-utils 1.15.0, lib-common-types 1.28.1, lib-vuetify 2.5.4 (the lib side of the fr/en pass, feat(i18n): localized field dates, english schema bases, i18n skill rules lib#70).

Why: consistent English/French (and other locales) across the platform, as part of the i18n audit.

Heads-up:

  • Displayed labels changed, so tests or docs that match French texts must follow. The e2e test of the site OAuth clients is updated to "Portées maximales".
  • API error texts changed (now translated, or in English for internal ones). Clients that match on the old French strings would break.
  • The de/es/it/pt texts are machine-assisted proofreading and deserve a native review.
  • Not in this PR: the language of the mails (invitations, deletion notices), which needs a stored user language.

BatLeDev and others added 10 commits November 13, 2026 15:25
- admin users: the identity provider sync notice reuses
  pages.organization.fromCache instead of a hard-coded French sentence
- admin site: the OIDC and SAML help slots use new pages.admin.site.oidcHelp,
  samlHelp and samlHelpLink keys (the SAML link goes through <i18n-t>)
- me: "unlimited" max created organizations uses a new common.unlimited key
- new keys are written in the 6 languages (fr, en, de, es, it, pt)
- pass the session locale to toLocaleString in delete-department-menu and
  admin organizations
- site schema: add x-i18n-title to the 4 titles that had none (OIDC color,
  credentials encoding mode, authorization method, body format) and
  x-i18n-description to the credentials encoding mode, following the schema's
  existing pattern (French base, override in the 6 languages)
- index.html: static lang="en" (App.vue sets it from the session via useHead)
- site schema and the patch-req-body layout: the English text moves to the base
  title / description / label / help / messages keywords (111 fields), the French
  one stays in x-i18n-*.fr with de, es, it, pt; the redundant en entries are dropped
- the root title keeps en: 'Site', the post / patch body schemas append a suffix
  to the base title to name their types
- generated type names of the site schema follow the English titles; the
  imported ones ($defs names, Site, OpenIDConnect, SitePost, SitePatch) are unchanged
- ui: fallbackLocale 'en' on createI18n
createI18n gets legacy: false, like the other services: vue-i18n 11 started in its
deprecated legacy mode, with a console warning.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Messages (fr, en):
- fr: missing commas after introductory clauses, "à 2 facteurs", "le mode admin",
  "a expiré", "non prise en charge", "bibliothèque", "connexion" instead of "login",
  "en lecture seule", "fournisseur d'identité", "code de récupération", typography of ":"
- fr: the SAML help reads "..., puis donnez-lui ce lien en retour"
- en: typos (approriate, apparence, mote, anly, attemps, Passordless, browers, Ths),
  "log in" as a verb, no space before "?" and ":", "terms of service", "mailbox",
  articles, comma splices and clumsy sentences of the doc, errors and mails
- labels shown at the start of a field, button or table cell get sentence case
- deleteDepartmentHasMembers, partnersQuotaPending and nhiConnectionsCount use
  vue-i18n plural forms in every locale instead of "(s)"; de had a portuguese text
- me.vue: the ":" after the maximum number of organizations moves into a new
  maxCreatedOrgsValue message, nbCreatedOrgs loses its space before ":" in en and de

Site schema:
- fr: "sur un autre de vos sites", "Valeurs de l'attribut", "département",
  "Contrôlez", "lui-même", "Métadonnées XML", "identifiants" instead of
  "crédentiels", "en-tête", "obsolète", "mot de passe", "inclut", "URI", commas
- en: "Warning: the configuration must...", clearer userInfoSource and redirect labels,
  "User management"
- option labels in sentence case in every locale

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The key lacked its pages.login. prefix: the downloaded file started with the raw key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- user-facing errors that were hardcoded in French go through the request
  language: partner invitations, the members quota of invitations, the
  contact form (spam and rate limit answers), the core identity provider
  conflict
- errors thrown where the request is not at hand (OAuth providers,
  mongo storage, account main site resolution, SSO member role and
  department) use a new I18nHttpError, translated by i18nErrorMiddleware
  before the error handler; its own message is the English text
- the intro of the forwarded contact mail follows the request language
- pure logs and internal errors (keepalive answers, session token checks,
  LDAP DN building, missing email from the provider) are in English
- the boot logs report color and main site warnings in English
- new keys in the 6 languages: errors.conflict2FA (used by the 2FA router
  but declared nowhere), oauthNoEmail, oauthEmailNotVerified,
  githubNoVerifiedEmail, facebookDisabled, partnerInvitationMismatch,
  partnerConflict, noPendingPartnerInvitation, memberOfParentOrg,
  memberOfDepartment, departmentUnknown, unknownOrgRole,
  missingDepartmentAttribute, otherCoreIdProvider, authOnlyOtherSiteChain,
  spamSuspected, rateLimitMessages and mails.contact.intro
- de, es, it and pt get the keys only fr and en had (mainSite.ignoredField,
  mainSite.ignoredCategory, pages.admin.site.mainSiteExplanation,
  pages.admin.sites.mainSite), so getMessage no longer falls back to French
UI:
- the app bar contact button uses pages.contact.title instead of a
  hardcoded "Nous contacter"
- admin organizations reuse pages.organization.fromCache with its
  {fromNow} placeholder; pages.admin.organizations.fromCache is removed
- nbCreatedOrgs takes a {count} placeholder instead of a concatenation
- createdOrgsLimit, pages.admin.organizations.members and
  passwordLists.subtitle use plural forms with the count passed to t()
- v-t on the partner invitation buttons becomes :text="$t()"
- "Creation not finalized" shown after a member or partner is put in
  parentheses

Messages:
- fr: "Attention : les données", missing commas, RSA "signature" keys,
  account creation mail caption, "adresse email" everywhere (dominant
  form), "portées" for OAuth scopes, French quotes, "deux fois",
  "à 2 facteurs" everywhere, deleteMyself without a dangling {name}
- en: "Log in" everywhere, missing commas, comma splices, "login request"
  instead of "identification request" in mails, account creation mail
  caption, noCreation mail "or has not been validated", plannedDeletion
  caption aligned with fr, a few clearer labels
- es, it, pt, de: sentence case already applied in fr and en (active,
  inactive, reject, tooLong, emailConfirmed, emailNotConfirmed,
  downloadCsv, no, yes, rememberMe, recovery2FACode, recovery2FADownload,
  createOrg, newOrgName, confirmMigration, deleteMyselfCheck), de
  rememberMe "Angemeldet bleiben", drop2FATitle with the {name} the UI
  passes, two broken de mail captions
- de: "Wenn die E-Mail-Adresse...", "Abteilung" instead of
  "Abteilungsmitglied", "keiner bekannten Rolle", "zum Abrufen", infinitive
  labels instead of imperatives, "E-Mail-Adresse", "Header", "Kennung",
  "oberste Ebene der Organisation"
- es, it, pt: translated "XML metadata", "Atención:" style warnings, articles
  in labels, "Correo electrónico completo", Brazilian pt (usuário, registro,
  logout, Logotipo)
- it: "dell'id_token", "dell'access_token", "e-mail non verificate",
  "e-mail" everywhere
- discovery description example uses my-provider in every non-French locale
- fr: "portées" for the OAuth scopes of providers and site clients
- the error redirected to the login page is in the request language,
  not the English message of I18nHttpError
…ages

- untranslated english and french values translated, wrong words and machine translation
  nonsense rewritten, mails reworked
- one register per language (Sie, usted, Lei, você), one term per concept
- portuguese aligned on pt-BR, like the site schema
- literal config values back to their literal form in the doc texts
- the sentence about an account created automatically, absent from en and fr, removed
  from the invitation mails
- keys, placeholders, plural forms and html tags identical to en
@BatLeDev BatLeDev changed the title refactor(i18n): site schema in english base, small fr/en fixes fix(i18n): english base for the site schema, translated server messages and proofread texts Nov 16, 2026
@github-actions github-actions Bot added the fix label Nov 16, 2026
BatLeDev and others added 3 commits November 16, 2026 08:51
unhead only set the lang attribute of the document and the title of the login page: a one
line watchEffect sets the lang, like the other services, and the login page sets document.title
and restores the previous title when it unmounts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
….5.4

The lib releases of the fr/en pass: dates in the session language for non French locales,
English byte units, English schema bases, translated search-address and date-match-filter.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added fix and removed fix labels Nov 16, 2026
BatLeDev and others added 2 commits November 16, 2026 11:51
…s 1.28.1

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ddleware

- api test: patching a member to an unknown department answers Département inconnu. without
  Accept-Language, Unknown department. in en and Unbekannte Abteilung. in de (it fails
  without the middleware)
- oauth and saml callbacks: the comment no longer says the English message is logged,
  returnError logs the translated one
@BatLeDev
BatLeDev merged commit 00492c3 into master Nov 16, 2026
6 checks passed
@BatLeDev
BatLeDev deleted the i18n-small-fixes branch November 16, 2026 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant