feat: i18n

This commit is contained in:
ulleo
2025-08-06 10:07:31 +08:00
parent 6b5f9a0202
commit 9b76925032
3 changed files with 6 additions and 1 deletions
+1
View File
@@ -537,6 +537,7 @@
"data_predict": "Data Prediction",
"ds_is_invalid": "Datasource is invalid",
"error": "Error",
"no_data": "No Data",
"show_error_detail": "Show error info"
},
"about": {
+1
View File
@@ -537,6 +537,7 @@
"data_predict": "数据预测",
"ds_is_invalid": "数据源无效",
"error": "错误",
"no_data": "暂无数据",
"show_error_detail": "查看具体信息"
},
"about": {
@@ -3,6 +3,7 @@ import ChartComponent from '@/views/chat/component/ChartComponent.vue'
import type { ChatMessage } from '@/api/chat.ts'
import { computed, nextTick, ref } from 'vue'
import type { ChartTypes } from '@/views/chat/component/BaseChart.ts'
import { useI18n } from 'vue-i18n'
const props = defineProps<{
id?: number | string
@@ -11,6 +12,8 @@ const props = defineProps<{
data: Array<{ [key: string]: any }>
}>()
const { t } = useI18n()
const chartObject = computed<{
type: ChartTypes
title: string
@@ -91,7 +94,7 @@ defineExpose({
:series="series"
:data="data"
/>
<el-empty v-else description="No Data" />
<el-empty v-else :description="t('chat.no_data')" />
</div>
</template>