kyverno: Enable i18n — generated en catalog + headlamp.i18n declaration - #1241
Open
productiondown wants to merge 1 commit into
Open
kyverno: Enable i18n — generated en catalog + headlamp.i18n declaration#1241productiondown wants to merge 1 commit into
productiondown wants to merge 1 commit into
Conversation
Fixes the plugin rendering raw i18next placeholders ('{{pct}}% compliant',
'Pass: {{count}}', ...) in the compliance badge and everywhere else it
interpolates: the release ships no locale catalog and declares no
headlamp.i18n, so the frontend's plugin i18n loader (which only fetches
locales a plugin declares, per #4854's scoping) never loads resources and
interpolation never runs.
Both files are the verbatim output of the repo's own tooling:
`npm run i18n en` (registers the locale in package.json and extracts the
155-key en catalog from the t() call sites, with _one/_other plural
variants). `headlamp-plugin package` includes locales/ in the artifact
automatically — verified by packaging.
lint/tsc/test/build green on Node 20, matching CI. Rendered on Headlamp
v0.45.0 in-cluster: the badge shows numbers with these two files present
and raw placeholders without them.
Fixes headlamp-k8s#1239
Signed-off-by: productiondown <productiondown@users.noreply.github.com>
productiondown
requested review from
ashu8912,
illume,
joaquimrocha,
skoeva,
sniok,
vyncent-t and
yolossn
as code owners
August 24, 2026 21:06
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1239 — the kyverno plugin renders raw i18next placeholders (
{{pct}}% compliant,Pass: {{count}}, …) because it ships no locale catalog and declares noheadlamp.i18n, so the plugin i18n loader (frontend/src/plugin/pluginI18n.ts, #4854 scoping) never loads resources and interpolation never runs.The change is the verbatim output of this repo's own tooling —
npm run i18n eninkyverno/:kyverno/locales/en/translation.json— 155 keys extracted from thet()call sites (identity mapping;_one/_otherplural variants for the{{count}}keys), same shape as the flux plugin's catalogkyverno/package.json—"headlamp": {"i18n": ["en"]}, same shape and position as flux'sVerified:
npm run lint/tsc/test/buildgreen on Node 20 (matching CI)headlamp-plugin packageincludeslocales/in the artifact automatically — no packaging change neededNotes for review:
enis declared, matching flux — each declared locale is fetched per #4854, so locales are added as their files are.