Add a language switcher with English, Italian, Spanish and French

The interface is translated through @nuxtjs/i18n: strings live in
i18n/locales/*.json, routes are prefixed except for the default English, and
useLocaleHead emits the lang attribute, the hreflang alternates and og:locale.

The switcher is a native select rather than a custom dropdown: keyboard
support, the platform picker on mobile and correct labelling come for free.

Article content stays single-language — this translates the site chrome only.
This commit is contained in:
2026-08-25 14:23:09 +02:00
parent f5639111f9
commit c08f53ca69
21 changed files with 3197 additions and 87 deletions
+50
View File
@@ -0,0 +1,50 @@
{
"site": {
"tagline": "Articles, guides and analysis.",
"skipToContent": "Skip to content",
"mainNavigation": "Main navigation",
"languageLabel": "Language",
"allArticles": "All articles",
"home": "Home",
"browse": "Browse",
"categories": "Categories",
"contact": "Contact",
"noCategories": "Nothing published yet",
"rights": "All rights reserved."
},
"home": {
"latest": "Latest",
"readArticle": "Read the article",
"moreStories": "More stories",
"viewAll": "View all articles"
},
"list": {
"archive": "The archive",
"articles": "Articles",
"articlesPage": "Articles — page {page}",
"archiveDescription": "Every article published on the blog.",
"category": "Category",
"categoryDescription": "Every article in the {name} category.",
"loading": "Loading…",
"empty": "Nothing has been published yet.",
"categoryEmpty": "There are no articles in this category.",
"failed": "Articles could not be loaded. Please try again later."
},
"pagination": {
"label": "Pagination",
"previous": "Previous page",
"next": "Next page",
"position": "Page {page} of {total}"
},
"article": {
"breadcrumb": "Breadcrumb",
"back": "Back to all articles"
},
"error": {
"notFoundTitle": "Page not found",
"notFoundBody": "The page you are looking for does not exist or has moved.",
"genericTitle": "Something went wrong",
"genericBody": "Please try again in a moment.",
"backHome": "Back to home"
}
}