diff --git a/app/components/post/Alert.vue b/app/components/post/Alert.vue new file mode 100644 index 0000000..86100ea --- /dev/null +++ b/app/components/post/Alert.vue @@ -0,0 +1,39 @@ + + + + + +{ + "en": { + "alert": { + "title": "Translations alert!", + "description": "For time reasons, all article translations will only be available in English. Thank you for your understanding." + } + }, + "fr": { + "alert": { + "title": "Attention aux traductions !", + "description": "Pour des raisons de temps, toutes les traductions d'articles ne seront disponibles qu'en anglais. Merci de votre compréhension." + } + }, + "es": { + "alert": { + "title": "¡Atención a las traducciones!", + "description": "Por razones de tiempo, todas las traducciones de los artículos estarán disponibles solo en inglés. Gracias por su comprensión." + } + } +} + diff --git a/app/components/PostFooter.vue b/app/components/post/Footer.vue similarity index 67% rename from app/components/PostFooter.vue rename to app/components/post/Footer.vue index fa29e8a..4a22c38 100644 --- a/app/components/PostFooter.vue +++ b/app/components/post/Footer.vue @@ -5,46 +5,46 @@ const { t } = useI18n({ @@ -65,4 +65,4 @@ const { t } = useI18n({ "name": "Arthur" } } - \ No newline at end of file + diff --git a/app/pages/projects/[slug].vue b/app/pages/projects/[slug].vue index 744016a..23372f0 100644 --- a/app/pages/projects/[slug].vue +++ b/app/pages/projects/[slug].vue @@ -3,7 +3,7 @@ const route = useRoute() const { data: project } = await useAsyncData(`projects/${route.params.slug}`, () => queryCollection('projects').path(`/projects/${route.params.slug}`).first()) -const { t, locale } = useI18n({ +const { t } = useI18n({ useScope: 'local', }) @@ -90,15 +90,7 @@ const { copy, copied } = useClipboard({ class="my-4" icon="i-ph-pencil-line-duotone" /> - + { "en": { - "alert": { - "title": "Translations alert!", - "description": "Due to time constraints, all article translations will be available only in English. Thank you for your understanding." - }, "back": "Go back", "link": { "copied": "Link copied", @@ -173,10 +161,6 @@ html { }, "fr": { - "alert": { - "title": "Attentions aux traductions!", - "description": "Par soucis de temps, toutes les traductions des articles seront disponibles uniquement en anglais. Merci de votre compréhension." - }, "back": "Retourner en arrière", "link": { "copied": "Lien copié", @@ -185,10 +169,6 @@ html { "top": "Remonter en haut" }, "es": { - "alert": { - "title": "Cuidado con las traducciones!", - "description": " Por problemas de tiempo, los artículos solo están disponibles en inglés. Gracias por vuestra comprensión.ug ñeóicula." - }, "back": "Volver atrás", "link": { "copied": "Link copiado", diff --git a/app/pages/projects/index.vue b/app/pages/projects/index.vue index afdd16f..3a1c7d8 100644 --- a/app/pages/projects/index.vue +++ b/app/pages/projects/index.vue @@ -23,6 +23,7 @@ const { data: projects } = await useAsyncData('all-projects', () => { :description="t('description')" :title="t('title')" /> +
    $fetch(`/api/posts/${route.params.slug}`, { method: 'POST' })) -const { t, locale } = useI18n({ +const { t } = useI18n({ useScope: 'local', }) @@ -79,15 +79,7 @@ function scrollToSection(id: string) { {{ t('back') }} - +

    {{ getDetails().likes }}

    · @@ -243,10 +235,6 @@ html { "one": "view", "many": "views" }, - "alert": { - "title": "Translations alert!", - "description": "Due to time constraints, all article translations will be available only in English. Thank you for your understanding." - }, "link": { "copied": "Link copied", "copy": "Copy link" @@ -264,10 +252,6 @@ html { "one": "vue", "many": "vues" }, - "alert": { - "title": "Attentions aux traductions!", - "description": "Par soucis de temps, toutes les traductions des articles seront disponibles uniquement en anglais. Merci de votre compréhension." - }, "link": { "copied": "Lien copié", "copy": "Copier le lien" @@ -285,10 +269,6 @@ html { "one": "view", "many": "views" }, - "alert": { - "title": "Cuidado con las traducciones!", - "description": "Por problemas de tiempo, los artículos solo están disponibles en inglés. Gracias por vuestra comprensión.ug ñeóicula." - }, "link": { "copied": "Link copiado", "copy": "Copiar link" diff --git a/app/pages/writings/index.vue b/app/pages/writings/index.vue index 580e157..9ff260b 100644 --- a/app/pages/writings/index.vue +++ b/app/pages/writings/index.vue @@ -1,7 +1,7 @@