chore(frontend): QandA i18n
This commit is contained in:
parent
e6706d1750
commit
fe397c54e3
5 changed files with 16 additions and 8 deletions
|
@ -1,6 +1,9 @@
|
|||
<script setup lang="ts">
|
||||
import type { QuestionDTO } from "@dwengo-1/common/interfaces/question";
|
||||
import SingleQuestion from "./SingleQuestion.vue";
|
||||
import { useI18n } from 'vue-i18n';
|
||||
|
||||
const { t } = useI18n();
|
||||
|
||||
defineProps<{
|
||||
questions: QuestionDTO[];
|
||||
|
@ -8,16 +11,17 @@
|
|||
</script>
|
||||
<template>
|
||||
<div class="space-y-4">
|
||||
<div
|
||||
v-if="questions.length !=0"
|
||||
v-for="question in questions"
|
||||
:key="(question.sequenceNumber, question.content)"
|
||||
class="border rounded-2xl p-4 shadow-sm bg-white"
|
||||
>
|
||||
<SingleQuestion :question="question"></SingleQuestion>
|
||||
<div v-if="questions.length != 0">
|
||||
<div
|
||||
v-for="question in questions"
|
||||
:key="(question.sequenceNumber, question.content)"
|
||||
class="border rounded-2xl p-4 shadow-sm bg-white"
|
||||
>
|
||||
<SingleQuestion :question="question"></SingleQuestion>
|
||||
</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
<p class="no-questions">No questions asked yet</p>
|
||||
<p class="no-questions">{{t("no-questions")}}</p>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue