Skip to content

Commit

Permalink
feat: add workshop i18n
Browse files Browse the repository at this point in the history
  • Loading branch information
KeJunMao committed Mar 16, 2023
1 parent c0fc20c commit 8502bfc
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 7 deletions.
5 changes: 2 additions & 3 deletions components/workshop/Header.vue
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
<template>
<div mb-8 flex flex-col justify-center gap-y-4 sm:gap-y-5>
<h2 text-4xl font-semibold sm:text-5xl text-gray-900 dark:text-gray-100>
Workshop
{{ $t("workshop.header.title") }}
</h2>
<div font-medium sm:text-lg text-gray-500 dark:text-gray-400 sm:max-w-lg>
Discover our list of tool to supercharge your AIAnything home page.
Created by the community.
{{ $t("workshop.header.desc") }}
</div>
</div>
</template>
2 changes: 1 addition & 1 deletion components/workshop/Search.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const { search } = useQuerySearch();
class="w-full sm:max-w-sm"
v-model="search"
type="search"
placeholder="Search Workshop Tool"
:placeholder="$t('workshop.search.placeholder')"
>
<template #prefix>
<el-icon class="i-carbon:search"></el-icon>
Expand Down
2 changes: 1 addition & 1 deletion components/workshop/ToolList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const list = computed(() => data.value?.list ?? []);
:description="
search === ''
? 'There is nothing here :)'
: `No '${search}' results found`
: $t('tool.list.empty.description.no-search-tool', [search])
"
></el-empty>
<el-pagination
Expand Down
5 changes: 4 additions & 1 deletion locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,5 +53,8 @@
"tool.search.placeholder": "Search Tool",
"tool.search.create": "Create",
"tool.search.workshop": "Workshop",
"tool.setting-dialog.title": "'{0}' GPT Options"
"tool.setting-dialog.title": "'{0}' GPT Options",
"workshop.header.title": "Workshop",
"workshop.header.desc": "Discover our list of tool to supercharge your AIAnything home page. Created by the community.",
"workshop.search.placeholder": "Search for tools from workshop"
}
5 changes: 4 additions & 1 deletion locales/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,5 +53,8 @@
"tool.search.create": "创建",
"tool.search.placeholder": "搜索工具",
"tool.search.workshop": "创意工坊",
"tool.setting-dialog.title": "'{0}' GPT 选项"
"tool.setting-dialog.title": "'{0}' GPT 选项",
"workshop.header.desc": "探索由社区创建的工具列表,以增强您的 AIAnything 主页。",
"workshop.header.title": "创意工坊",
"workshop.search.placeholder": "搜索来自创意工坊的工具"
}

0 comments on commit 8502bfc

Please sign in to comment.