Skip to content

Commit

Permalink
✨ feat(intl): add more intl
Browse files Browse the repository at this point in the history
  • Loading branch information
summerscar committed Oct 30, 2024
1 parent 11a432f commit 1115f64
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
8 changes: 4 additions & 4 deletions app/components/home-drawer/dict-menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,16 @@ const DictMenu = ({
};

const createWord = async () => {
const word = prompt(tHome("createWord"), "안녕");
const word = prompt(tHome("createWord"), tHome("exampleWord"));
if (word) {
const removeInfoToast = createToast({
type: "info",
delay: 60 * 1000 * 5,
message: (
<span>
<span className="loading loading-spinner loading-sm" />{" "}
<div className="flex items-center">
<span className="loading loading-spinner loading-sm mr-2" />
{tHome("generating")}
</span>
</div>
),
});

Expand Down
3 changes: 2 additions & 1 deletion messages/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"Home": {
"viewList": "View list",
"tipsEnter": "Press<enter></enter>to type!",
"createWord": "Please input words, separated by commas. For example: Hello,안녕",
"createWord": "Please input words or meanings, multiple words are separated by commas. For example: 안녕,thank you",
"exampleWord": "안녕,thank you",
"generating": "Generating...",
"generated": "Generated successfully!",
"generateError": "Failed to generate. Please try again.",
Expand Down
3 changes: 2 additions & 1 deletion messages/ja.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"Home": {
"viewList": "リストを見る",
"tipsEnter": "<enter></enter>を押してから入力してください",
"createWord": "単語を入力してください。例:こんにちは,안녕",
"createWord": "単語もしくわ単語の意味を入力してください、複数の単語はカンマで区切ってください。例:안녕,ありがとう",
"exampleWord": "안녕,ありがとう",
"generating": "生成中...",
"generated": "生成に成功しました!",
"generateError": "生成に失敗しました。もう一度お試しください。",
Expand Down
3 changes: 2 additions & 1 deletion messages/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"Home": {
"viewList": "查看列表",
"tipsEnter": "按下<enter></enter>键输入",
"createWord": "请输入单词或单词解释,用逗号分隔 例如:안녕,你好",
"createWord": "请输入单词或单词解释,多个单词用逗号分隔 例如:안녕,谢谢",
"exampleWord": "안녕,谢谢",
"generating": "生成中...",
"generated": "生成成功!",
"generateError": "生成失败,请重试。",
Expand Down

0 comments on commit 1115f64

Please sign in to comment.