i18n: progress on french translations
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
<div class="flex flex-col items-center justify-center mt-60">
|
<div class="flex flex-col items-center justify-center mt-60">
|
||||||
<GraduationCap class="size-10 mx-auto stroke-1 text-ink-gray-5" />
|
<GraduationCap class="size-10 mx-auto stroke-1 text-ink-gray-5" />
|
||||||
<div class="text-lg font-semibold text-ink-gray-7 mb-2.5">
|
<div class="text-lg font-semibold text-ink-gray-7 mb-2.5">
|
||||||
{{ __('No {0}').format(type?.toLowerCase()) }}
|
{{ __('No {0}').format(props.type) }}
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
class="leading-5 text-base w-2/5 text-base text-center text-ink-gray-7"
|
class="leading-5 text-base w-2/5 text-base text-center text-ink-gray-7"
|
||||||
@@ -10,15 +10,17 @@
|
|||||||
{{
|
{{
|
||||||
__(
|
__(
|
||||||
'There are no {0} currently. Keep an eye out, fresh learning experiences are on the way!'
|
'There are no {0} currently. Keep an eye out, fresh learning experiences are on the way!'
|
||||||
).format(type?.toLowerCase())
|
).format(props.type)
|
||||||
}}
|
}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
import { computed } from 'vue'
|
||||||
import { BookOpen, GraduationCap } from 'lucide-vue-next'
|
import { BookOpen, GraduationCap } from 'lucide-vue-next'
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
type: String,
|
type: String,
|
||||||
})
|
})
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
5
frontend/src/global.d.ts
vendored
5
frontend/src/global.d.ts
vendored
@@ -1,11 +1,12 @@
|
|||||||
export {}
|
export {}
|
||||||
|
|
||||||
declare global {
|
declare global {
|
||||||
function __(text: string): string
|
// May return string or an object with `.format(...)` when placeholders exist
|
||||||
|
function __(text: string): any
|
||||||
}
|
}
|
||||||
|
|
||||||
declare module 'vue' {
|
declare module 'vue' {
|
||||||
interface ComponentCustomProperties {
|
interface ComponentCustomProperties {
|
||||||
__: (text: string) => string
|
__: (text: string) => any
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -66,7 +66,7 @@
|
|||||||
<CourseCard :course="course" />
|
<CourseCard :course="course" />
|
||||||
</router-link>
|
</router-link>
|
||||||
</div>
|
</div>
|
||||||
<EmptyState v-else-if="!courses.list.loading" type="Courses" />
|
<EmptyState v-else-if="!courses.list.loading" :type="__('Courses').toLowerCase()" />
|
||||||
<div
|
<div
|
||||||
v-if="!courses.list.loading && courses.hasNextPage"
|
v-if="!courses.list.loading && courses.hasNextPage"
|
||||||
class="flex justify-center mt-5"
|
class="flex justify-center mt-5"
|
||||||
|
|||||||
Reference in New Issue
Block a user