Conversation
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
|
@copilot which plan is better? Especially considering we will be using AI to generate the translations later on, automatically, whenever a new slug is added. |
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Plan B is the better fit for an AI-driven workflow. I've added a detailed breakdown in Plan A (overlay) is awkward for AI because the AI must know which fields to omit from the overlay ( Plan B (full replacement) is ideal because:
The recommended automation loop is: detect new/changed English slug → AI translates → schema validation → commit to |
|
@copilot ok let's get rid of Plan A, and focus on Plan B. |
…an focus Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Done (commit |
|
@copilot rewrite Plan B as Internationalization Spec. |
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Done (commit |
|
The specification suggests using the Python script, but the copilot-instructions.md in this repo are strictly pointing at the Java-based generator (triggered with jbang). If the instructions are not clear, make it so. |
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Fixed in commit |
…string keys Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Done in commit |
There was a problem hiding this comment.
Pull request overview
This PR introduces a comprehensive internationalization (i18n) specification for the java.evolved static site. The specification defines a two-layer architecture for supporting multiple languages: UI strings with per-key fallback and full-replacement translated content files.
Changes:
- Added
specs/i18n/i18n-spec.mddocumenting the complete i18n architecture, including directory layout, translation file schemas, generator resolution order, template changes, navigation updates, and an AI-driven translation workflow - Specification uses
jbang html-generators/generate.javaas the canonical build command throughout - Defined per-key English fallback mechanism for missing UI string keys with warning-only behavior (no build failures)
Comments suppressed due to low confidence (1)
specs/i18n/i18n-spec.md:328
- Use "Localized" instead of "Localised" to maintain consistency with American English spelling used throughout the codebase.
Localised strings consumed by JavaScript are embedded as a `<script>` block by
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
@copilot is this specification covering how language selector will be displayed on the website? My preference is a globe/world icon next to the dark/light theme selector button, where a dropdown list shows up and allows the user to change the language. |
…anguage selector Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
The old spec used a plain |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.
Comments suppressed due to low confidence (1)
specs/i18n/i18n-spec.md:345
- The Portuguese example shows "Buscar padrões..." (line 345) but to be consistent with the English "Search snippets..." terminology actually used in the site (templates/index.html:290), this should be "Buscar snippets..." or "Buscar trechos..." instead.
searchPlaceholder: "Buscar padrões...",
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…tory layout Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
specs/i18n/directory with initial i18n proposalsspecs/i18n/i18n-spec.md(Internationalization Specification)python3 html-generators/generate.pyreferences in the spec withjbang html-generators/generate.javato match the project's canonical build tooling[WARN]for each missing key and always completes the build — no page is ever left with a blank string<select>language picker with a 🌐 globe icon button placed next to the theme toggle in.nav-right, opening an accessible dropdown list of locales (persisted tolocalStorage)Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.