Skip to content

Commit

Permalink
Add the patch
Browse files Browse the repository at this point in the history
Signed-off-by: Olga Bulat <[email protected]>

Add locales if fewer than 5 (for testing)

Signed-off-by: Olga Bulat <[email protected]>
  • Loading branch information
obulat committed May 15, 2024
1 parent cfcb1d4 commit f1935e3
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions frontend/justfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ export FRONTEND_PNPM_VERSION := `grep 'packageManager' ../package.json | awk -F'
# Build the frontend Docker image
build-img tag="openverse-frontend:local" target="app":
docker build \
--load \
--target {{ target }} \
--build-context 'repo_root=..' \
--build-arg FRONTEND_NODE_VERSION=$(just node-version) \
Expand Down
4 changes: 3 additions & 1 deletion frontend/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ const favicons = [
},
]

const additionalLocales = locales && locales.length < 5 ? locales : []

const openverseLocales = [
{
/* Nuxt i18n fields */
Expand All @@ -43,7 +45,7 @@ const openverseLocales = [
name: "English",
nativeName: "English",
},
...(locales ?? []),
...additionalLocales,
].filter((l) => Boolean(l.iso)) as LocaleObject[]

const isProdNotPlaywright = isProd && !(process.env.PW === "true")
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/components/VHomepageContent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
>
{{ $t("hero.subtitle") }}
</h1>
<!-- eslint-disable @intlify/vue-i18n/no-raw-text -->
<p class="sr-only">Testing Nuxt 3</p>
<!-- eslint-enable -->

<p class="text-base leading-relaxed">
{{ $t("hero.description") }}
Expand Down

0 comments on commit f1935e3

Please sign in to comment.