Compare commits

...

12 Commits

Author SHA1 Message Date
fish 662590027b 新增家具分类,涵盖坐卧、收纳、桌台等 16 个常用词汇
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 23:06:52 +08:00
fish c24b09ddc4 新增场所分类,涵盖城市建筑、交通出行、居住户外等 28 个常用词汇
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 23:05:17 +08:00
fish e2f3e5549a 刷新动效改为逐行渐入,增加从上到下依次出现的过渡效果
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 23:00:46 +08:00
fish a01207ae00 刷新按钮添加淡入淡出动效
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:58:51 +08:00
fish 0cdc3c49a3 刷新按钮打乱子分类顺序及内部单词
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:57:39 +08:00
fish ef0acbecc3 单词列表页导航栏新增刷新按钮,支持随机重排单词顺序
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:56:12 +08:00
fish 0a133593e5 五个动物分类合并为单一动物分类,采用子分类分组展示
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:54:08 +08:00
fish d86566d7ed 餐食新增上午茶、下午茶、夜宵,soup 移至其他分组
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:52:04 +08:00
fish 3d2466edba 饮食分类支持子分类分组,WordCategory 新增 subcategories 字段实现单词分层展示
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:49:50 +08:00
fish 0ed88622af 新增饮食分类,涵盖主食、肉类、蔬菜、饮品、调料、餐食、零食等 40 个常用词汇
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:46:03 +08:00
fish 76096c0786 修复 Word 解码失败:自定义 CodingKeys 排除 categoryId,避免 JSON 解析报错
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:42:39 +08:00
fish bbce352309 家庭分类新增 family、child、couple、姻亲关系等 16 个常用词汇
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-07-20 22:40:27 +08:00
4 changed files with 437 additions and 116 deletions
+11 -1
View File
@@ -9,7 +9,13 @@ struct WordCategory: Codable, Identifiable, Hashable {
let id: String let id: String
let name: String let name: String
let icon: String let icon: String
let words: [Word] var words: [Word]
var subcategories: [Subcategory]?
}
struct Subcategory: Codable, Hashable {
let name: String
var words: [Word]
} }
struct Word: Codable, Identifiable, Hashable { struct Word: Codable, Identifiable, Hashable {
@@ -20,4 +26,8 @@ struct Word: Codable, Identifiable, Hashable {
let meaning: String let meaning: String
let example: String let example: String
let exampleMeaning: String let exampleMeaning: String
enum CodingKeys: String, CodingKey {
case word, phonetic, meaning, example, exampleMeaning
}
} }
+346 -103
View File
@@ -49,109 +49,107 @@
] ]
}, },
{ {
"id": "land_animals", "id": "animals",
"name": "陆地动物", "name": "动物",
"icon": "pawprint.fill", "icon": "pawprint.fill",
"words": [ "words": [],
{ "word": "cat", "phonetic": "/kæt/", "meaning": "猫", "example": "The cat is cute.", "exampleMeaning": "这只猫很可爱。" }, "subcategories": [
{ "word": "dog", "phonetic": "/dɔːɡ/", "meaning": "狗", "example": "The dog is running.", "exampleMeaning": "狗在跑。" }, {
{ "word": "rabbit", "phonetic": "/ˈræbɪt/", "meaning": "兔子", "example": "The rabbit likes carrots.", "exampleMeaning": "兔子喜欢胡萝卜。" }, "name": "陆地动物",
{ "word": "tiger", "phonetic": "/ˈtaɪɡər/", "meaning": "老虎", "example": "The tiger is strong.", "exampleMeaning": "老虎很强壮。" }, "words": [
{ "word": "elephant", "phonetic": "/ˈelɪfənt/", "meaning": "大象", "example": "The elephant has a long nose.", "exampleMeaning": "大象有长长的鼻子。" }, { "word": "cat", "phonetic": "/t/", "meaning": "", "example": "The cat is cute.", "exampleMeaning": "这只猫很可爱。" },
{ "word": "monkey", "phonetic": "/ˈmʌŋki/", "meaning": "猴子", "example": "The monkey eats bananas.", "exampleMeaning": "猴子吃香蕉。" }, { "word": "dog", "phonetic": "/dɔːɡ/", "meaning": "", "example": "The dog is running.", "exampleMeaning": "狗在跑。" },
{ "word": "panda", "phonetic": "/ˈpændə/", "meaning": "熊猫", "example": "The panda is black and white.", "exampleMeaning": "熊猫是黑白相间的。" }, { "word": "rabbit", "phonetic": "/ˈræbɪt/", "meaning": "兔子", "example": "The rabbit likes carrots.", "exampleMeaning": "兔子喜欢胡萝卜。" },
{ "word": "lion", "phonetic": "/ˈlaɪən/", "meaning": "狮子", "example": "The lion is the king of animals.", "exampleMeaning": "狮子是动物之王。" }, { "word": "tiger", "phonetic": "/ˈtaɪɡər/", "meaning": "老虎", "example": "The tiger is strong.", "exampleMeaning": "老虎很强壮。" },
{ "word": "horse", "phonetic": "/hɔːrs/", "meaning": "", "example": "The horse runs fast.", "exampleMeaning": "马跑得很快。" }, { "word": "elephant", "phonetic": "/ˈelɪfənt/", "meaning": "大象", "example": "The elephant has a long nose.", "exampleMeaning": "大象有长长的鼻子。" },
{ "word": "sheep", "phonetic": "/ʃiːp/", "meaning": "绵羊", "example": "The sheep eats grass.", "exampleMeaning": "绵羊吃草。" }, { "word": "monkey", "phonetic": "/ˈmʌŋki/", "meaning": "猴子", "example": "The monkey eats bananas.", "exampleMeaning": "猴子吃香蕉。" },
{ "word": "pig", "phonetic": "/pɪɡ/", "meaning": "", "example": "The pig is fat.", "exampleMeaning": "这头猪很胖。" }, { "word": "panda", "phonetic": "/ˈpændə/", "meaning": "熊猫", "example": "The panda is black and white.", "exampleMeaning": "熊猫是黑白相间的。" },
{ "word": "cow", "phonetic": "/kaʊ/", "meaning": "奶牛", "example": "The cow gives milk.", "exampleMeaning": "奶牛产奶。" }, { "word": "lion", "phonetic": "/ˈlaɪən/", "meaning": "狮子", "example": "The lion is the king of animals.", "exampleMeaning": "狮子是动物之王。" },
{ "word": "chicken", "phonetic": "/ˈtʃɪkɪn/", "meaning": "", "example": "The chicken lays eggs.", "exampleMeaning": "母鸡下蛋。" }, { "word": "horse", "phonetic": "/hɔːrs/", "meaning": "", "example": "The horse runs fast.", "exampleMeaning": "马跑得很快。" },
{ "word": "mouse", "phonetic": "/maʊs/", "meaning": "老鼠", "example": "The mouse likes cheese.", "exampleMeaning": "老鼠喜欢奶酪。" }, { "word": "sheep", "phonetic": "/ʃiːp/", "meaning": "绵羊", "example": "The sheep eats grass.", "exampleMeaning": "绵羊吃草。" },
{ "word": "snake", "phonetic": "/sneɪk/", "meaning": "", "example": "The snake has no legs.", "exampleMeaning": "蛇没有腿。" }, { "word": "pig", "phonetic": "/pɪɡ/", "meaning": "", "example": "The pig is fat.", "exampleMeaning": "这头猪很胖。" },
{ "word": "bear", "phonetic": "/ber/", "meaning": "", "example": "The bear sleeps in winter.", "exampleMeaning": "熊在冬天睡觉。" }, { "word": "cow", "phonetic": "/kaʊ/", "meaning": "奶牛", "example": "The cow gives milk.", "exampleMeaning": "奶牛产奶。" },
{ "word": "giraffe", "phonetic": "/dʒəˈræf/", "meaning": "长颈鹿", "example": "The giraffe is tall.", "exampleMeaning": "长颈鹿很高。" }, { "word": "chicken", "phonetic": "/ˈtʃɪkɪn/", "meaning": "", "example": "The chicken lays eggs.", "exampleMeaning": "母鸡下蛋。" },
{ "word": "zebra", "phonetic": "/ˈziːbrə/", "meaning": "斑马", "example": "The zebra has stripes.", "exampleMeaning": "斑马身上有条纹。" }, { "word": "mouse", "phonetic": "/maʊs/", "meaning": "老鼠", "example": "The mouse likes cheese.", "exampleMeaning": "老鼠喜欢奶酪。" },
{ "word": "wolf", "phonetic": "/wʊlf/", "meaning": "", "example": "The wolf howls at night.", "exampleMeaning": "狼在夜里嚎叫。" }, { "word": "snake", "phonetic": "/sneɪk/", "meaning": "", "example": "The snake has no legs.", "exampleMeaning": "蛇没有腿。" },
{ "word": "fox", "phonetic": "/fɑːks/", "meaning": "狐狸", "example": "The fox is clever.", "exampleMeaning": "狐狸很聪明。" }, { "word": "bear", "phonetic": "/ber/", "meaning": "", "example": "The bear sleeps in winter.", "exampleMeaning": "熊在冬天睡觉。" },
{ "word": "deer", "phonetic": "/dɪr/", "meaning": "鹿", "example": "The deer runs fast.", "exampleMeaning": "鹿跑得很快。" }, { "word": "giraffe", "phonetic": "/dʒəˈræf/", "meaning": "长颈鹿", "example": "The giraffe is tall.", "exampleMeaning": "长颈鹿很高。" },
{ "word": "squirrel", "phonetic": "/ˈskwɜːl/", "meaning": "松鼠", "example": "The squirrel likes nuts.", "exampleMeaning": "松鼠喜欢坚果。" }, { "word": "zebra", "phonetic": "/ˈziːbrə/", "meaning": "斑马", "example": "The zebra has stripes.", "exampleMeaning": "斑马身上有条纹。" },
{ "word": "turtle", "phonetic": "/ˈtɜːrtl/", "meaning": "乌龟", "example": "The turtle walks slowly.", "exampleMeaning": "乌龟走得很慢。" }, { "word": "wolf", "phonetic": "/wʊlf/", "meaning": "", "example": "The wolf howls at night.", "exampleMeaning": "狼在夜里嚎叫。" },
{ "word": "ant", "phonetic": "/ænt/", "meaning": "蚂蚁", "example": "The ant carries food.", "exampleMeaning": "蚂蚁搬运食物。" }, { "word": "fox", "phonetic": "/fɑːks/", "meaning": "狐狸", "example": "The fox is clever.", "exampleMeaning": "狐狸很聪明。" },
{ "word": "spider", "phonetic": "/ˈspaɪr/", "meaning": "蜘蛛", "example": "The spider makes a web.", "exampleMeaning": "蜘蛛织网。" }, { "word": "deer", "phonetic": "/dɪr/", "meaning": "鹿", "example": "The deer runs fast.", "exampleMeaning": "鹿跑得很快。" },
{ "word": "kangaroo", "phonetic": "/ˌkæŋɡəˈruː/", "meaning": "鼠", "example": "The kangaroo jumps high.", "exampleMeaning": "袋鼠跳得很高。" }, { "word": "squirrel", "phonetic": "/ˈskwɜːrəl/", "meaning": "鼠", "example": "The squirrel likes nuts.", "exampleMeaning": "松鼠喜欢坚果。" },
{ "word": "koala", "phonetic": "/koʊˈɑːlə/", "meaning": "考拉", "example": "The koala sleeps a lot.", "exampleMeaning": "考拉睡很多觉。" }, { "word": "turtle", "phonetic": "/ˈtɜːrtl/", "meaning": "乌龟", "example": "The turtle walks slowly.", "exampleMeaning": "乌龟走得很慢。" },
{ "word": "crocodile", "phonetic": "/ˈkrɑːkədaɪl/", "meaning": "鳄鱼", "example": "The crocodile has a big mouth.", "exampleMeaning": "鳄鱼有一张大嘴。" }, { "word": "ant", "phonetic": "/ænt/", "meaning": "蚂蚁", "example": "The ant carries food.", "exampleMeaning": "蚂蚁搬运食物。" },
{ "word": "camel", "phonetic": "/ˈkæml/", "meaning": "骆驼", "example": "The camel lives in the desert.", "exampleMeaning": "骆驼生活在沙漠里。" } { "word": "spider", "phonetic": "/ˈspaɪdər/", "meaning": "蜘蛛", "example": "The spider makes a web.", "exampleMeaning": "蜘蛛织网。" },
] { "word": "kangaroo", "phonetic": "/ˌkæŋɡəˈruː/", "meaning": "袋鼠", "example": "The kangaroo jumps high.", "exampleMeaning": "袋鼠跳得很高。" },
}, { "word": "koala", "phonetic": "/koʊˈɑːlə/", "meaning": "考拉", "example": "The koala sleeps a lot.", "exampleMeaning": "考拉睡很多觉。" },
{ { "word": "crocodile", "phonetic": "/ˈkrɑːkədaɪl/", "meaning": "鳄鱼", "example": "The crocodile has a big mouth.", "exampleMeaning": "鳄鱼有一张大嘴。" },
"id": "flying_animals", { "word": "camel", "phonetic": "/ˈkæml/", "meaning": "骆驼", "example": "The camel lives in the desert.", "exampleMeaning": "骆驼生活在沙漠里。" }
"name": "飞翔动物", ]
"icon": "bird.fill", },
"words": [ {
{ "word": "bird", "phonetic": "/bɜːrd/", "meaning": "鸟", "example": "The bird can fly.", "exampleMeaning": "鸟会飞。" }, "name": "飞翔动物",
{ "word": "owl", "phonetic": "/aʊl/", "meaning": "猫头鹰", "example": "The owl sleeps in the day.", "exampleMeaning": "猫头鹰白天睡觉。" }, "words": [
{ "word": "bee", "phonetic": "/biː/", "meaning": "蜜蜂", "example": "The bee makes honey.", "exampleMeaning": "蜜蜂酿蜜。" }, { "word": "bird", "phonetic": "/bɜːrd/", "meaning": "", "example": "The bird can fly.", "exampleMeaning": "鸟会飞。" },
{ "word": "butterfly", "phonetic": "/ˈbʌtərflaɪ/", "meaning": "蝴蝶", "example": "The butterfly is beautiful.", "exampleMeaning": "蝴蝶很漂亮。" }, { "word": "owl", "phonetic": "/aʊl/", "meaning": "猫头鹰", "example": "The owl sleeps in the day.", "exampleMeaning": "猫头鹰白天睡觉。" },
{ "word": "eagle", "phonetic": "/ˈiːɡl/", "meaning": "", "example": "The eagle flies high.", "exampleMeaning": "鹰飞得很高。" }, { "word": "bee", "phonetic": "/biː/", "meaning": "蜜蜂", "example": "The bee makes honey.", "exampleMeaning": "蜜蜂酿蜜。" },
{ "word": "crow", "phonetic": "/kroʊ/", "meaning": "乌鸦", "example": "The crow is black.", "exampleMeaning": "乌鸦是黑色的。" }, { "word": "butterfly", "phonetic": "/ˈbʌtərflaɪ/", "meaning": "蝴蝶", "example": "The butterfly is beautiful.", "exampleMeaning": "蝴蝶很漂亮。" },
{ "word": "pigeon", "phonetic": "/ˈpɪdʒɪn/", "meaning": "鸽子", "example": "The pigeon lives in the city.", "exampleMeaning": "鸽子生活在城市里。" }, { "word": "eagle", "phonetic": "/ˈiːɡl/", "meaning": "", "example": "The eagle flies high.", "exampleMeaning": "鹰飞得很高。" },
{ "word": "parrot", "phonetic": "/ˈpærət/", "meaning": "鹦鹉", "example": "The parrot can talk.", "exampleMeaning": "鹦鹉会说话。" }, { "word": "crow", "phonetic": "/kroʊ/", "meaning": "乌鸦", "example": "The crow is black.", "exampleMeaning": "乌鸦是黑色的。" },
{ "word": "sparrow", "phonetic": "/ˈspæroʊ/", "meaning": "麻雀", "example": "The sparrow is small.", "exampleMeaning": "麻雀很小。" }, { "word": "pigeon", "phonetic": "/ˈpɪdʒɪn/", "meaning": "鸽子", "example": "The pigeon lives in the city.", "exampleMeaning": "鸽子生活在城市里。" },
{ "word": "swallow", "phonetic": "/ˈswɑːloʊ/", "meaning": "燕子", "example": "The swallow flies fast.", "exampleMeaning": "燕子飞得很快。" }, { "word": "parrot", "phonetic": "/ˈpærət/", "meaning": "鹦鹉", "example": "The parrot can talk.", "exampleMeaning": "鹦鹉会说话。" },
{ "word": "bat", "phonetic": "/bæt/", "meaning": "蝙蝠", "example": "The bat flies at night.", "exampleMeaning": "蝙蝠在夜里飞。" }, { "word": "sparrow", "phonetic": "/ˈspæroʊ/", "meaning": "麻雀", "example": "The sparrow is small.", "exampleMeaning": "麻雀很小。" },
{ "word": "seagull", "phonetic": "/ˈsiːɡʌl/", "meaning": "海鸥", "example": "The seagull flies over the sea.", "exampleMeaning": "海鸥飞过海面。" }, { "word": "swallow", "phonetic": "/ˈswɑːloʊ/", "meaning": "燕子", "example": "The swallow flies fast.", "exampleMeaning": "燕子飞得很快。" },
{ "word": "hawk", "phonetic": "/hɔːk/", "meaning": "", "example": "The hawk can see far.", "exampleMeaning": "隼能看得很远。" }, { "word": "bat", "phonetic": "/bæt/", "meaning": "蝙蝠", "example": "The bat flies at night.", "exampleMeaning": "蝙蝠在夜里飞。" },
{ "word": "woodpecker", "phonetic": "/ˈwʊdpekər/", "meaning": "啄木鸟", "example": "The woodpecker pecks trees.", "exampleMeaning": "啄木鸟啄树。" }, { "word": "seagull", "phonetic": "/ˈsiːɡʌl/", "meaning": "海鸥", "example": "The seagull flies over the sea.", "exampleMeaning": "海鸥飞过海面。" },
{ "word": "dragonfly", "phonetic": "/ˈdræɡənflaɪ/", "meaning": "蜻蜓", "example": "The dragonfly has four wings.", "exampleMeaning": "蜻蜓有四只翅膀。" }, { "word": "hawk", "phonetic": "/hɔːk/", "meaning": "", "example": "The hawk can see far.", "exampleMeaning": "隼能看得很远。" },
{ "word": "mosquito", "phonetic": "/məˈskiːtoʊ/", "meaning": "蚊子", "example": "The mosquito bites me.", "exampleMeaning": "蚊子咬我。" } { "word": "woodpecker", "phonetic": "/ˈwʊdpekər/", "meaning": "啄木鸟", "example": "The woodpecker pecks trees.", "exampleMeaning": "啄木鸟啄树。" },
] { "word": "dragonfly", "phonetic": "/ˈdræɡənflaɪ/", "meaning": "蜻蜓", "example": "The dragonfly has four wings.", "exampleMeaning": "蜻蜓有四只翅膀。" },
}, { "word": "mosquito", "phonetic": "/məˈskiːtoʊ/", "meaning": "蚊子", "example": "The mosquito bites me.", "exampleMeaning": "蚊子咬我。" }
{ ]
"id": "waterfowl_animals", },
"name": "水禽", {
"icon": "bird", "name": "水禽",
"words": [ "words": [
{ "word": "duck", "phonetic": "/dʌk/", "meaning": "鸭子", "example": "The duck swims in the pond.", "exampleMeaning": "鸭子在池塘里游泳。" }, { "word": "duck", "phonetic": "/dʌk/", "meaning": "鸭子", "example": "The duck swims in the pond.", "exampleMeaning": "鸭子在池塘里游泳。" },
{ "word": "swan", "phonetic": "/swɑːn/", "meaning": "天鹅", "example": "The swan is white.", "exampleMeaning": "天鹅是白色的。" }, { "word": "swan", "phonetic": "/swɑːn/", "meaning": "天鹅", "example": "The swan is white.", "exampleMeaning": "天鹅是白色的。" },
{ "word": "penguin", "phonetic": "/ˈpeŋɡwɪn/", "meaning": "企鹅", "example": "The penguin cannot fly.", "exampleMeaning": "企鹅不会飞。" }, { "word": "penguin", "phonetic": "/ˈpeŋɡwɪn/", "meaning": "企鹅", "example": "The penguin cannot fly.", "exampleMeaning": "企鹅不会飞。" },
{ "word": "heron", "phonetic": "/ˈhɛrən/", "meaning": "苍鹭", "example": "The heron stands in the river.", "exampleMeaning": "苍鹭站在河里。" } { "word": "heron", "phonetic": "/ˈhɛrən/", "meaning": "苍鹭", "example": "The heron stands in the river.", "exampleMeaning": "苍鹭站在河里。" }
] ]
}, },
{ {
"id": "amphibious_animals", "name": "两栖动物",
"name": "两栖动物", "words": [
"icon": "leaf.arrow.triangle.circlepath", { "word": "frog", "phonetic": "/frɔːɡ/", "meaning": "青蛙", "example": "The frog can jump high.", "exampleMeaning": "青蛙能跳得很高。" },
"words": [ { "word": "tadpole", "phonetic": "/ˈtædpoʊl/", "meaning": "蝌蚪", "example": "The tadpole will become a frog.", "exampleMeaning": "蝌蚪会变成青蛙。" },
{ "word": "frog", "phonetic": "/frɔːɡ/", "meaning": "青蛙", "example": "The frog can jump high.", "exampleMeaning": "青蛙能跳得很高。" }, { "word": "newt", "phonetic": "/nuːt/", "meaning": "蝾螈", "example": "The newt lives in the pond.", "exampleMeaning": "蝾螈生活在池塘里。" }
{ "word": "tadpole", "phonetic": "/ˈtædpoʊl/", "meaning": "蝌蚪", "example": "The tadpole will become a frog.", "exampleMeaning": "蝌蚪会变成青蛙。" }, ]
{ "word": "newt", "phonetic": "/nuːt/", "meaning": "蝾螈", "example": "The newt lives in the pond.", "exampleMeaning": "蝾螈生活在池塘里。" } },
] {
}, "name": "水中动物",
{ "words": [
"id": "aquatic_animals", { "word": "fish", "phonetic": "/fɪʃ/", "meaning": "鱼", "example": "The fish swims fast.", "exampleMeaning": "鱼游得很快。" },
"name": "水中动物", { "word": "crayfish", "phonetic": "/ˈkreɪfɪʃ/", "meaning": "小龙虾", "example": "The crayfish lives in the river.", "exampleMeaning": "小龙虾生活在河里。" },
"icon": "fish.fill", { "word": "loach", "phonetic": "/loʊtʃ/", "meaning": "泥鳅", "example": "The loach hides in the mud.", "exampleMeaning": "泥鳅躲在泥里。" },
"words": [ { "word": "carp", "phonetic": "/kɑːrp/", "meaning": "鲤鱼", "example": "The carp swims in the pond.", "exampleMeaning": "鲤鱼在池塘里游泳。" },
{ "word": "fish", "phonetic": "/fɪʃ/", "meaning": "鱼", "example": "The fish swims fast.", "exampleMeaning": "鱼游得很快。" }, { "word": "goldfish", "phonetic": "/ˈɡoʊldfɪʃ/", "meaning": "鱼", "example": "The goldfish is orange.", "exampleMeaning": "金鱼是橙色的。" },
{ "word": "crayfish", "phonetic": "/ˈkreɪfɪʃ/", "meaning": "小龙虾", "example": "The crayfish lives in the river.", "exampleMeaning": "小龙虾生活在河里。" }, { "word": "eel", "phonetic": "/iːl/", "meaning": "鳗鱼", "example": "The eel is long and thin.", "exampleMeaning": "鳗鱼又长又细。" },
{ "word": "loach", "phonetic": "/loʊtʃ/", "meaning": "泥鳅", "example": "The loach hides in the mud.", "exampleMeaning": "泥鳅躲在泥里。" }, { "word": "crab", "phonetic": "/kræb/", "meaning": "螃蟹", "example": "The crab walks sideways.", "exampleMeaning": "螃蟹横着走。" },
{ "word": "carp", "phonetic": "/kɑːrp/", "meaning": "鲤鱼", "example": "The carp swims in the pond.", "exampleMeaning": "鲤鱼在池塘里游泳。" }, { "word": "shrimp", "phonetic": "/ʃrɪmp/", "meaning": "", "example": "The shrimp is small.", "exampleMeaning": "虾很小。" },
{ "word": "goldfish", "phonetic": "/ˈɡoʊldfɪʃ/", "meaning": "金鱼", "example": "The goldfish is orange.", "exampleMeaning": "金鱼是橙色的。" }, { "word": "otter", "phonetic": "/ˈɑːtər/", "meaning": "水獭", "example": "The otter swims in the river.", "exampleMeaning": "水獭在河里游泳。" },
{ "word": "eel", "phonetic": "/iːl/", "meaning": "鳗鱼", "example": "The eel is long and thin.", "exampleMeaning": "鳗鱼又长又细。" }, { "word": "beaver", "phonetic": "/ˈbiːvər/", "meaning": "河狸", "example": "The beaver builds a dam.", "exampleMeaning": "河狸筑水坝。" },
{ "word": "crab", "phonetic": "/kræb/", "meaning": "螃蟹", "example": "The crab walks sideways.", "exampleMeaning": "螃蟹横着走。" }, { "word": "catfish", "phonetic": "/ˈkætfɪʃ/", "meaning": "鲶鱼", "example": "The catfish has whiskers.", "exampleMeaning": "鲶鱼有胡须。" },
{ "word": "shrimp", "phonetic": "/ʃrɪmp/", "meaning": "", "example": "The shrimp is small.", "exampleMeaning": "虾很小。" }, { "word": "trout", "phonetic": "/traʊt/", "meaning": "鳟鱼", "example": "The trout swims upstream.", "exampleMeaning": "鳟鱼往上游。" },
{ "word": "otter", "phonetic": "/ˈɑːtər/", "meaning": "水獭", "example": "The otter swims in the river.", "exampleMeaning": "水獭在河里游泳。" }, { "word": "salmon", "phonetic": "/ˈsæmən/", "meaning": "鲑鱼", "example": "The salmon swims up the river.", "exampleMeaning": "鲑鱼游到上游。" },
{ "word": "beaver", "phonetic": "/ˈbiːvər/", "meaning": "河狸", "example": "The beaver builds a dam.", "exampleMeaning": "河狸筑水坝。" }, { "word": "leech", "phonetic": "/liː/", "meaning": "水蛭", "example": "The leech lives in the water.", "exampleMeaning": "水蛭生活在水里。" },
{ "word": "catfish", "phonetic": "/ˈkætfɪʃ/", "meaning": "鲶鱼", "example": "The catfish has whiskers.", "exampleMeaning": "鲶鱼有胡须。" }, { "word": "clam", "phonetic": "/klæm/", "meaning": "", "example": "The clam has a shell.", "exampleMeaning": "蚌有壳。" },
{ "word": "trout", "phonetic": "/traʊt/", "meaning": "鱼", "example": "The trout swims upstream.", "exampleMeaning": "鳟鱼往上游。" }, { "word": "sturgeon", "phonetic": "/ˈstɜːrdʒən/", "meaning": "鱼", "example": "The sturgeon is a big fish.", "exampleMeaning": "鲟鱼是一种大鱼。" },
{ "word": "salmon", "phonetic": "/ˈsæmən/", "meaning": "鲑鱼", "example": "The salmon swims up the river.", "exampleMeaning": "鲑鱼游到上游。" }, { "word": "dolphin", "phonetic": "/ˈdɑːlfɪn/", "meaning": "海豚", "example": "The dolphin swims fast.", "exampleMeaning": "海豚游得很快。" },
{ "word": "leech", "phonetic": "/liː/", "meaning": "水蛭", "example": "The leech lives in the water.", "exampleMeaning": "水蛭生活在水里。" }, { "word": "whale", "phonetic": "/weɪl/", "meaning": "鲸鱼", "example": "The whale is very big.", "exampleMeaning": "鲸鱼非常大。" },
{ "word": "clam", "phonetic": "/klæm/", "meaning": "", "example": "The clam has a shell.", "exampleMeaning": "蚌有壳。" }, { "word": "shark", "phonetic": "/ʃɑːrk/", "meaning": "鲨鱼", "example": "The shark has sharp teeth.", "exampleMeaning": "鲨鱼有锋利的牙齿。" }
{ "word": "sturgeon", "phonetic": "/ˈstɜːrdʒən/", "meaning": "鲟鱼", "example": "The sturgeon is a big fish.", "exampleMeaning": "鲟鱼是一种大鱼。" }, ]
{ "word": "dolphin", "phonetic": "/ˈdɑːlfɪn/", "meaning": "海豚", "example": "The dolphin swims fast.", "exampleMeaning": "海豚游得很快。" }, }
{ "word": "whale", "phonetic": "/weɪl/", "meaning": "鲸鱼", "example": "The whale is very big.", "exampleMeaning": "鲸鱼非常大。" },
{ "word": "shark", "phonetic": "/ʃɑːrk/", "meaning": "鲨鱼", "example": "The shark has sharp teeth.", "exampleMeaning": "鲨鱼有锋利的牙齿。" }
] ]
}, },
{ {
@@ -267,7 +265,252 @@
{ "word": "granddaughter", "phonetic": "/ˈɡrændɔːtər/", "meaning": "孙女/外孙女", "example": "His granddaughter can sing.", "exampleMeaning": "他的孙女会唱歌。" }, { "word": "granddaughter", "phonetic": "/ˈɡrændɔːtər/", "meaning": "孙女/外孙女", "example": "His granddaughter can sing.", "exampleMeaning": "他的孙女会唱歌。" },
{ "word": "nephew", "phonetic": "/ˈnefjuː/", "meaning": "侄子/外甥", "example": "My nephew is ten.", "exampleMeaning": "我侄子十岁。" }, { "word": "nephew", "phonetic": "/ˈnefjuː/", "meaning": "侄子/外甥", "example": "My nephew is ten.", "exampleMeaning": "我侄子十岁。" },
{ "word": "niece", "phonetic": "/niːs/", "meaning": "侄女/外甥女", "example": "My niece likes drawing.", "exampleMeaning": "我侄女喜欢画画。" }, { "word": "niece", "phonetic": "/niːs/", "meaning": "侄女/外甥女", "example": "My niece likes drawing.", "exampleMeaning": "我侄女喜欢画画。" },
{ "word": "grandparent", "phonetic": "/ˈɡrænperənt/", "meaning": "祖父母/外祖父母", "example": "My grandparents live in the country.", "exampleMeaning": "我的祖父母住在乡下。" } { "word": "grandparent", "phonetic": "/ˈɡrænperənt/", "meaning": "祖父母/外祖父母", "example": "My grandparents live in the country.", "exampleMeaning": "我的祖父母住在乡下。" },
{ "word": "family", "phonetic": "/ˈfæməli/", "meaning": "家庭", "example": "I love my family.", "exampleMeaning": "我爱我的家庭。" },
{ "word": "child", "phonetic": "/tʃaɪld/", "meaning": "孩子", "example": "The child is playing.", "exampleMeaning": "孩子在玩。" },
{ "word": "children", "phonetic": "/ˈtʃɪldrən/", "meaning": "孩子们", "example": "The children are at school.", "exampleMeaning": "孩子们在学校。" },
{ "word": "sibling", "phonetic": "/ˈsɪblɪŋ/", "meaning": "兄弟姐妹", "example": "I have two siblings.", "exampleMeaning": "我有两个兄弟姐妹。" },
{ "word": "relative", "phonetic": "/ˈrelətɪv/", "meaning": "亲戚", "example": "We visit relatives during the holiday.", "exampleMeaning": "我们假期走亲戚。" },
{ "word": "couple", "phonetic": "/ˈkʌpl/", "meaning": "夫妻", "example": "The couple is walking hand in hand.", "exampleMeaning": "那对夫妻手牵手散步。" },
{ "word": "spouse", "phonetic": "/spaʊs/", "meaning": "配偶", "example": "My spouse and I like to travel.", "exampleMeaning": "我和我配偶喜欢旅行。" },
{ "word": "boyfriend", "phonetic": "/ˈbɔɪfrend/", "meaning": "男朋友", "example": "Her boyfriend is kind.", "exampleMeaning": "她男朋友很友善。" },
{ "word": "girlfriend", "phonetic": "/ˈɡɜːrlfrend/", "meaning": "女朋友", "example": "His girlfriend is a nurse.", "exampleMeaning": "他女朋友是一名护士。" },
{ "word": "father-in-law", "phonetic": "/ˈfɑːðər ɪn lɔː/", "meaning": "岳父/公公", "example": "My father-in-law is retired.", "exampleMeaning": "我岳父退休了。" },
{ "word": "mother-in-law", "phonetic": "/ˈmʌðər ɪn lɔː/", "meaning": "岳母/婆婆", "example": "My mother-in-law is a great cook.", "exampleMeaning": "我婆婆做饭很好吃。" },
{ "word": "brother-in-law", "phonetic": "/ˈbrʌðər ɪn lɔː/", "meaning": "姐夫/妹夫/大舅子", "example": "My brother-in-law works in Shanghai.", "exampleMeaning": "我姐夫在上海工作。" },
{ "word": "sister-in-law", "phonetic": "/ˈsɪstər ɪn lɔː/", "meaning": "嫂子/弟媳/大姑子", "example": "My sister-in-law teaches English.", "exampleMeaning": "我嫂子教英语。" },
{ "word": "twin", "phonetic": "/twɪn/", "meaning": "双胞胎", "example": "The twins look the same.", "exampleMeaning": "这对双胞胎长得一样。" },
{ "word": "stepfather", "phonetic": "/ˈstepfɑːðər/", "meaning": "继父", "example": "My stepfather is very caring.", "exampleMeaning": "我的继父很体贴。" },
{ "word": "stepmother", "phonetic": "/ˈstepmʌðər/", "meaning": "继母", "example": "Her stepmother is nice to her.", "exampleMeaning": "她的继母对她很好。" }
]
},
{
"id": "food_drink",
"name": "饮食",
"icon": "fork.knife",
"words": [],
"subcategories": [
{
"name": "主食",
"words": [
{ "word": "rice", "phonetic": "/raɪs/", "meaning": "米饭", "example": "I eat rice every day.", "exampleMeaning": "我每天吃米饭。" },
{ "word": "bread", "phonetic": "/bred/", "meaning": "面包", "example": "I have bread for breakfast.", "exampleMeaning": "我早餐吃面包。" },
{ "word": "noodle", "phonetic": "/ˈnuːdl/", "meaning": "面条", "example": "I like beef noodles.", "exampleMeaning": "我喜欢牛肉面。" },
{ "word": "dumpling", "phonetic": "/ˈdʌmplɪŋ/", "meaning": "饺子", "example": "We make dumplings together.", "exampleMeaning": "我们一起包饺子。" }
]
},
{
"name": "肉类",
"words": [
{ "word": "meat", "phonetic": "/miːt/", "meaning": "肉", "example": "I like to eat meat.", "exampleMeaning": "我喜欢吃肉。" },
{ "word": "beef", "phonetic": "/biːf/", "meaning": "牛肉", "example": "The beef is tender.", "exampleMeaning": "牛肉很嫩。" },
{ "word": "pork", "phonetic": "/pɔːrk/", "meaning": "猪肉", "example": "I don't eat pork.", "exampleMeaning": "我不吃猪肉。" },
{ "word": "chicken", "phonetic": "/ˈtʃɪkɪn/", "meaning": "鸡肉", "example": "Fried chicken is popular.", "exampleMeaning": "炸鸡很受欢迎。" },
{ "word": "egg", "phonetic": "/eɡ/", "meaning": "鸡蛋", "example": "I have an egg for breakfast.", "exampleMeaning": "我早餐吃一个鸡蛋。" }
]
},
{
"name": "蔬菜",
"words": [
{ "word": "vegetable", "phonetic": "/ˈvedʒtəbl/", "meaning": "蔬菜", "example": "Eat more vegetables.", "exampleMeaning": "多吃蔬菜。" },
{ "word": "carrot", "phonetic": "/ˈkærət/", "meaning": "胡萝卜", "example": "Rabbits like carrots.", "exampleMeaning": "兔子喜欢胡萝卜。" },
{ "word": "tomato", "phonetic": "/təˈmeɪtoʊ/", "meaning": "番茄", "example": "The tomato is red.", "exampleMeaning": "番茄是红色的。" },
{ "word": "potato", "phonetic": "/pəˈteɪtoʊ/", "meaning": "土豆", "example": "Potatoes grow underground.", "exampleMeaning": "土豆长在地下。" },
{ "word": "onion", "phonetic": "/ˈʌnjən/", "meaning": "洋葱", "example": "The onion makes me cry.", "exampleMeaning": "洋葱让我流泪。" },
{ "word": "cucumber", "phonetic": "/ˈkjuːkʌmbər/", "meaning": "黄瓜", "example": "The cucumber is fresh.", "exampleMeaning": "黄瓜很新鲜。" },
{ "word": "cabbage", "phonetic": "/ˈkæbɪdʒ/", "meaning": "卷心菜", "example": "Cabbage is good for health.", "exampleMeaning": "卷心菜对健康有好处。" }
]
},
{
"name": "饮品",
"words": [
{ "word": "water", "phonetic": "/ˈwɔːtər/", "meaning": "水", "example": "I drink water every day.", "exampleMeaning": "我每天喝水。" },
{ "word": "milk", "phonetic": "/mɪlk/", "meaning": "牛奶", "example": "I drink a glass of milk.", "exampleMeaning": "我喝一杯牛奶。" },
{ "word": "juice", "phonetic": "/dʒuːs/", "meaning": "果汁", "example": "Orange juice is sweet.", "exampleMeaning": "橙汁很甜。" },
{ "word": "tea", "phonetic": "/tiː/", "meaning": "茶", "example": "I drink tea in the afternoon.", "exampleMeaning": "我下午喝茶。" },
{ "word": "coffee", "phonetic": "/ˈkɔːfi/", "meaning": "咖啡", "example": "I need a cup of coffee.", "exampleMeaning": "我需要一杯咖啡。" },
{ "word": "beer", "phonetic": "/bɪr/", "meaning": "啤酒", "example": "He drinks beer with friends.", "exampleMeaning": "他和朋友喝啤酒。" },
{ "word": "wine", "phonetic": "/waɪn/", "meaning": "葡萄酒", "example": "Red wine is good for health.", "exampleMeaning": "红酒对健康有好处。" }
]
},
{
"name": "调料",
"words": [
{ "word": "salt", "phonetic": "/sɔːlt/", "meaning": "盐", "example": "Don't add too much salt.", "exampleMeaning": "不要加太多盐。" },
{ "word": "sugar", "phonetic": "/ˈʃʊɡər/", "meaning": "糖", "example": "I put sugar in my coffee.", "exampleMeaning": "我在咖啡里加糖。" },
{ "word": "oil", "phonetic": "/ɔɪl/", "meaning": "油", "example": "Add some oil to the pan.", "exampleMeaning": "往锅里加点油。" },
{ "word": "sauce", "phonetic": "/sɔːs/", "meaning": "酱", "example": "The sauce is delicious.", "exampleMeaning": "这个酱很好吃。" }
]
},
{
"name": "餐食",
"words": [
{ "word": "breakfast", "phonetic": "/ˈbrekfəst/", "meaning": "早餐", "example": "Breakfast is the most important meal.", "exampleMeaning": "早餐是最重要的一餐。" },
{ "word": "lunch", "phonetic": "/lʌntʃ/", "meaning": "午餐", "example": "I have lunch at twelve.", "exampleMeaning": "我十二点吃午餐。" },
{ "word": "dinner", "phonetic": "/ˈdɪnər/", "meaning": "晚餐", "example": "We have dinner at six.", "exampleMeaning": "我们六点吃晚餐。" },
{ "word": "morning tea", "phonetic": "/ˈmɔːrnɪŋ tiː/", "meaning": "上午茶", "example": "We had morning tea at ten.", "exampleMeaning": "我们十点喝上午茶。" },
{ "word": "afternoon tea", "phonetic": "/ˌæftərˈnuːn tiː/", "meaning": "下午茶", "example": "Afternoon tea is a British tradition.", "exampleMeaning": "下午茶是英国传统。" },
{ "word": "midnight snack", "phonetic": "/ˈmɪdnaɪt snæk/", "meaning": "夜宵", "example": "I had a midnight snack before bed.", "exampleMeaning": "我睡前吃了夜宵。" }
]
},
{
"name": "零食甜品",
"words": [
{ "word": "cake", "phonetic": "/keɪk/", "meaning": "蛋糕", "example": "I like chocolate cake.", "exampleMeaning": "我喜欢巧克力蛋糕。" },
{ "word": "cookie", "phonetic": "/ˈkʊki/", "meaning": "饼干", "example": "The cookie is crunchy.", "exampleMeaning": "饼干很脆。" },
{ "word": "ice cream", "phonetic": "/ˌaɪs ˈkriːm/", "meaning": "冰淇淋", "example": "Ice cream is cold and sweet.", "exampleMeaning": "冰淇淋又冰又甜。" },
{ "word": "chocolate", "phonetic": "/ˈtʃɔːklət/", "meaning": "巧克力", "example": "I love dark chocolate.", "exampleMeaning": "我爱黑巧克力。" },
{ "word": "candy", "phonetic": "/ˈkændi/", "meaning": "糖果", "example": "The child likes candy.", "exampleMeaning": "小孩喜欢糖果。" }
]
},
{
"name": "其他",
"words": [
{ "word": "sandwich", "phonetic": "/ˈsænwɪtʃ/", "meaning": "三明治", "example": "I made a sandwich for lunch.", "exampleMeaning": "我做了三明治当午餐。" },
{ "word": "pizza", "phonetic": "/ˈpiːtsə/", "meaning": "披萨", "example": "Pizza is from Italy.", "exampleMeaning": "披萨来自意大利。" },
{ "word": "hamburger", "phonetic": "/ˈhæmbɜːrɡər/", "meaning": "汉堡", "example": "The hamburger is big.", "exampleMeaning": "这个汉堡很大。" },
{ "word": "cheese", "phonetic": "/tʃiːz/", "meaning": "奶酪", "example": "Cheese is made from milk.", "exampleMeaning": "奶酪是用牛奶做的。" },
{ "word": "butter", "phonetic": "/ˈbʌtər/", "meaning": "黄油", "example": "I spread butter on bread.", "exampleMeaning": "我在面包上涂黄油。" },
{ "word": "soup", "phonetic": "/suːp/", "meaning": "汤", "example": "The soup is hot.", "exampleMeaning": "汤是热的。" }
]
}
]
},
{
"id": "direction",
"name": "方位",
"icon": "location.north.line",
"words": [],
"subcategories": [
{
"name": "罗盘方向",
"words": [
{ "word": "north", "phonetic": "/nɔːrθ/", "meaning": "北", "example": "The wind blows from the north.", "exampleMeaning": "风从北边吹来。" },
{ "word": "south", "phonetic": "/saʊθ/", "meaning": "南", "example": "Birds fly south in winter.", "exampleMeaning": "鸟儿冬天飞向南方。" },
{ "word": "east", "phonetic": "/iːst/", "meaning": "东", "example": "The sun rises in the east.", "exampleMeaning": "太阳从东边升起。" },
{ "word": "west", "phonetic": "/west/", "meaning": "西", "example": "The sun sets in the west.", "exampleMeaning": "太阳从西边落下。" },
{ "word": "northeast", "phonetic": "/ˌnɔːrθˈiːst/", "meaning": "东北", "example": "The wind comes from the northeast.", "exampleMeaning": "风从东北方向吹来。" },
{ "word": "northwest", "phonetic": "/ˌnɔːrθˈwest/", "meaning": "西北", "example": "The mountain is northwest of the city.", "exampleMeaning": "山在城市的西北方向。" },
{ "word": "southeast", "phonetic": "/ˌsaʊθˈiːst/", "meaning": "东南", "example": "The river flows to the southeast.", "exampleMeaning": "河流向东南方。" },
{ "word": "southwest", "phonetic": "/ˌsaʊθˈwest/", "meaning": "西南", "example": "The desert is southwest of here.", "exampleMeaning": "沙漠在这儿的西南方。" }
]
},
{
"name": "相对方位",
"words": [
{ "word": "front", "phonetic": "/frʌnt/", "meaning": "前面", "example": "Please stand at the front.", "exampleMeaning": "请站在前面。" },
{ "word": "back", "phonetic": "/bæk/", "meaning": "后面", "example": "The garden is at the back.", "exampleMeaning": "花园在后面。" },
{ "word": "left", "phonetic": "/left/", "meaning": "左", "example": "Turn left at the corner.", "exampleMeaning": "在拐角处左转。" },
{ "word": "right", "phonetic": "/raɪt/", "meaning": "右", "example": "Turn right at the light.", "exampleMeaning": "在红绿灯处右转。" },
{ "word": "up", "phonetic": "/ʌp/", "meaning": "上", "example": "Look up at the sky.", "exampleMeaning": "抬头看天空。" },
{ "word": "down", "phonetic": "/daʊn/", "meaning": "下", "example": "Go down the stairs.", "exampleMeaning": "走下楼梯。" },
{ "word": "top", "phonetic": "/tɑːp/", "meaning": "顶部", "example": "The cat is on top of the table.", "exampleMeaning": "猫在桌子顶部。" },
{ "word": "bottom", "phonetic": "/ˈbɑːtəm/", "meaning": "底部", "example": "The shoes are at the bottom.", "exampleMeaning": "鞋子在底部。" }
]
},
{
"name": "位置关系",
"words": [
{ "word": "inside", "phonetic": "/ˌɪnˈsaɪd/", "meaning": "里面", "example": "It is warm inside the house.", "exampleMeaning": "房子里面很暖和。" },
{ "word": "outside", "phonetic": "/ˌaʊtˈsaɪd/", "meaning": "外面", "example": "Let's play outside.", "exampleMeaning": "我们去外面玩吧。" },
{ "word": "middle", "phonetic": "/ˈmɪdl/", "meaning": "中间", "example": "The ball is in the middle.", "exampleMeaning": "球在中间。" },
{ "word": "center", "phonetic": "/ˈsentər/", "meaning": "中心", "example": "The statue is at the center.", "exampleMeaning": "雕像在中心。" },
{ "word": "side", "phonetic": "/saɪd/", "meaning": "旁边", "example": "He sat by my side.", "exampleMeaning": "他坐在我旁边。" },
{ "word": "near", "phonetic": "/nɪr/", "meaning": "附近", "example": "The school is near my house.", "exampleMeaning": "学校在我家附近。" },
{ "word": "far", "phonetic": "/fɑːr/", "meaning": "远处", "example": "The mountain is far away.", "exampleMeaning": "山在远处。" },
{ "word": "opposite", "phonetic": "/ˈɑːpəzɪt/", "meaning": "对面", "example": "The bank is opposite the park.", "exampleMeaning": "银行在公园对面。" }
]
}
]
},
{
"id": "places",
"name": "场所",
"icon": "building.2.fill",
"words": [],
"subcategories": [
{
"name": "城市建筑",
"words": [
{ "word": "building", "phonetic": "/ˈbɪldɪŋ/", "meaning": "建筑", "example": "That building is very tall.", "exampleMeaning": "那栋建筑非常高。" },
{ "word": "office", "phonetic": "/ˈɔːfɪs/", "meaning": "办公室", "example": "I work in an office.", "exampleMeaning": "我在办公室工作。" },
{ "word": "hospital", "phonetic": "/ˈhɑːspɪtl/", "meaning": "医院", "example": "The hospital is near my house.", "exampleMeaning": "医院在我家附近。" },
{ "word": "school", "phonetic": "/skuːl/", "meaning": "学校", "example": "The children go to school.", "exampleMeaning": "孩子们去上学。" },
{ "word": "library", "phonetic": "/ˈlaɪbreri/", "meaning": "图书馆", "example": "I study at the library.", "exampleMeaning": "我在图书馆学习。" },
{ "word": "museum", "phonetic": "/mjuˈziːəm/", "meaning": "博物馆", "example": "The museum has many old things.", "exampleMeaning": "博物馆有很多古老的东西。" },
{ "word": "bank", "phonetic": "/bæŋk/", "meaning": "银行", "example": "I need to go to the bank.", "exampleMeaning": "我需要去银行。" },
{ "word": "supermarket", "phonetic": "/ˈsuːpərmɑːrkɪt/", "meaning": "超市", "example": "I buy food at the supermarket.", "exampleMeaning": "我在超市买食物。" },
{ "word": "mall", "phonetic": "/mɔːl/", "meaning": "商场", "example": "Let's go shopping at the mall.", "exampleMeaning": "我们去商场购物吧。" },
{ "word": "restaurant", "phonetic": "/ˈrestərɑːnt/", "meaning": "餐厅", "example": "We had dinner at a restaurant.", "exampleMeaning": "我们在餐厅吃了晚饭。" },
{ "word": "hotel", "phonetic": "/hoʊˈtel/", "meaning": "酒店", "example": "We stayed at a nice hotel.", "exampleMeaning": "我们住了一家不错的酒店。" },
{ "word": "cinema", "phonetic": "/ˈsɪnəmə/", "meaning": "电影院", "example": "Let's watch a movie at the cinema.", "exampleMeaning": "我们去电影院看电影吧。" },
{ "word": "gym", "phonetic": "/dʒɪm/", "meaning": "健身房", "example": "I exercise at the gym.", "exampleMeaning": "我在健身房锻炼。" },
{ "word": "church", "phonetic": "/tʃɜːrtʃ/", "meaning": "教堂", "example": "The church is very old.", "exampleMeaning": "这座教堂很古老。" },
{ "word": "factory", "phonetic": "/ˈfæktəri/", "meaning": "工厂", "example": "He works in a factory.", "exampleMeaning": "他在工厂工作。" }
]
},
{
"name": "交通出行",
"words": [
{ "word": "airport", "phonetic": "/ˈerpɔːrt/", "meaning": "机场", "example": "We arrived at the airport early.", "exampleMeaning": "我们早早到了机场。" },
{ "word": "station", "phonetic": "/ˈsteɪʃn/", "meaning": "车站", "example": "The train station is crowded.", "exampleMeaning": "火车站很拥挤。" },
{ "word": "bridge", "phonetic": "/brɪdʒ/", "meaning": "桥", "example": "The bridge is very long.", "exampleMeaning": "这座桥很长。" },
{ "word": "bus stop", "phonetic": "/bʌs stɑːp/", "meaning": "公交站", "example": "I wait at the bus stop.", "exampleMeaning": "我在公交站等车。" },
{ "word": "port", "phonetic": "/pɔːrt/", "meaning": "港口", "example": "The ship arrived at the port.", "exampleMeaning": "船到港了。" }
]
},
{
"name": "居住户外",
"words": [
{ "word": "house", "phonetic": "/haʊs/", "meaning": "房子", "example": "I live in a big house.", "exampleMeaning": "我住在一所大房子里。" },
{ "word": "apartment", "phonetic": "/əˈpɑːrtmənt/", "meaning": "公寓", "example": "My apartment is on the 5th floor.", "exampleMeaning": "我的公寓在五楼。" },
{ "word": "home", "phonetic": "/hoʊm/", "meaning": "家", "example": "I want to go home.", "exampleMeaning": "我想回家。" },
{ "word": "park", "phonetic": "/pɑːrk/", "meaning": "公园", "example": "We walk in the park.", "exampleMeaning": "我们在公园散步。" },
{ "word": "square", "phonetic": "/skwer/", "meaning": "广场", "example": "People dance at the square.", "exampleMeaning": "人们在广场跳舞。" },
{ "word": "garden", "phonetic": "/ˈɡɑːrdn/", "meaning": "花园", "example": "The flowers in the garden are beautiful.", "exampleMeaning": "花园里的花很美。" },
{ "word": "playground", "phonetic": "/ˈpleɪɡraʊnd/", "meaning": "游乐场", "example": "The kids are at the playground.", "exampleMeaning": "孩子们在游乐场。" },
{ "word": "market", "phonetic": "/ˈmɑːrkɪt/", "meaning": "市场", "example": "I bought fresh fish at the market.", "exampleMeaning": "我在市场买了新鲜的鱼。" }
]
}
]
},
{
"id": "furniture",
"name": "家具",
"icon": "chair.fill",
"words": [],
"subcategories": [
{
"name": "坐卧",
"words": [
{ "word": "sofa", "phonetic": "/ˈsoʊfə/", "meaning": "沙发", "example": "We sit on the sofa.", "exampleMeaning": "我们坐在沙发上。" },
{ "word": "bed", "phonetic": "/bed/", "meaning": "床", "example": "I go to bed at ten.", "exampleMeaning": "我十点上床睡觉。" },
{ "word": "chair", "phonetic": "/tʃer/", "meaning": "椅子", "example": "Please sit on the chair.", "exampleMeaning": "请坐在椅子上。" },
{ "word": "armchair", "phonetic": "/ˈɑːrmtʃer/", "meaning": "扶手椅", "example": "He fell asleep in the armchair.", "exampleMeaning": "他在扶手椅上睡着了。" },
{ "word": "stool", "phonetic": "/stuːl/", "meaning": "凳子", "example": "The child sits on a stool.", "exampleMeaning": "小孩坐在凳子上。" }
]
},
{
"name": "收纳",
"words": [
{ "word": "wardrobe", "phonetic": "/ˈwɔːrdroʊb/", "meaning": "衣柜", "example": "I hang my clothes in the wardrobe.", "exampleMeaning": "我把衣服挂在衣柜里。" },
{ "word": "cabinet", "phonetic": "/ˈkæbɪnət/", "meaning": "柜子", "example": "The plates are in the cabinet.", "exampleMeaning": "盘子在柜子里。" },
{ "word": "bookshelf", "phonetic": "/ˈbʊkʃelf/", "meaning": "书架", "example": "The bookshelf is full of books.", "exampleMeaning": "书架上摆满了书。" },
{ "word": "dresser", "phonetic": "/ˈdresər/", "meaning": "梳妆台", "example": "She sits at the dresser.", "exampleMeaning": "她坐在梳妆台前。" },
{ "word": "cupboard", "phonetic": "/ˈkʌbərd/", "meaning": "碗柜", "example": "The cups are in the cupboard.", "exampleMeaning": "杯子在碗柜里。" },
{ "word": "drawer", "phonetic": "/drɔːr/", "meaning": "抽屉", "example": "The pen is in the drawer.", "exampleMeaning": "笔在抽屉里。" }
]
},
{
"name": "桌台",
"words": [
{ "word": "table", "phonetic": "/ˈteɪbl/", "meaning": "桌子", "example": "The book is on the table.", "exampleMeaning": "书在桌子上。" },
{ "word": "desk", "phonetic": "/desk/", "meaning": "书桌", "example": "I study at my desk.", "exampleMeaning": "我在书桌前学习。" },
{ "word": "dining table", "phonetic": "/ˈdaɪnɪŋ ˈteɪbl/", "meaning": "餐桌", "example": "We eat at the dining table.", "exampleMeaning": "我们在餐桌吃饭。" },
{ "word": "coffee table", "phonetic": "/ˈkɔːfi ˈteɪbl/", "meaning": "茶几", "example": "The magazine is on the coffee table.", "exampleMeaning": "杂志在茶几上。" },
{ "word": "nightstand", "phonetic": "/ˈnaɪtstænd/", "meaning": "床头柜", "example": "I put my phone on the nightstand.", "exampleMeaning": "我把手机放在床头柜上。" }
]
}
] ]
} }
] ]
@@ -28,22 +28,29 @@ final class WordStore {
let data = try Data(contentsOf: url) let data = try Data(contentsOf: url)
let decoded = try JSONDecoder().decode(WordBank.self, from: data) let decoded = try JSONDecoder().decode(WordBank.self, from: data)
let categories = decoded.categories.map { category -> WordCategory in let categories = decoded.categories.map { category -> WordCategory in
var cat = category
let source: [Word]
if let subs = cat.subcategories, !subs.isEmpty {
source = subs.flatMap { $0.words }
} else {
source = cat.words
}
let tagged: [Word] let tagged: [Word]
if category.id == "numbers" { if category.id == "numbers" {
var words = NumberWords.makeWords(atoms: category.words) var words = NumberWords.makeWords(atoms: source)
let extras = category.words.filter { NumberWords.atomNumbers[$0.word] == nil } let extras = source.filter { NumberWords.atomNumbers[$0.word] == nil }
words.append(contentsOf: extras) words.append(contentsOf: extras)
tagged = words tagged = words
} else { } else {
tagged = category.words tagged = source
} }
let words = tagged.map { word -> Word in let words = tagged.map { word -> Word in
var w = word var w = word
w.categoryId = category.id w.categoryId = category.id
return w return w
} }
return WordCategory(id: category.id, name: category.name, icon: category.icon, cat.words = words
words: words) return cat
} }
bank = WordBank(version: decoded.version, categories: categories) bank = WordBank(version: decoded.version, categories: categories)
} catch { } catch {
@@ -3,14 +3,22 @@ import UIKit
final class WordListViewController: UIViewController { final class WordListViewController: UIViewController {
private let category: WordCategory private let category: WordCategory
private let colorIndex: Int private let colorIndex: Int
private var words: [Word]
private var subcategories: [Subcategory]?
private let tableView = UITableView(frame: .zero, style: .plain) private let tableView = UITableView(frame: .zero, style: .plain)
private let ctaBackground = UIVisualEffectView(effect: UIBlurEffect(style: .systemMaterial)) private let ctaBackground = UIVisualEffectView(effect: UIBlurEffect(style: .systemMaterial))
private let quizButton = UIButton(type: .system) private let quizButton = UIButton(type: .system)
private var speechObserver: NSObjectProtocol? private var speechObserver: NSObjectProtocol?
private var displaySubcategories: [Subcategory]? {
subcategories.flatMap { $0.isEmpty ? nil : $0 }
}
init(category: WordCategory, colorIndex: Int) { init(category: WordCategory, colorIndex: Int) {
self.category = category self.category = category
self.colorIndex = colorIndex self.colorIndex = colorIndex
self.words = category.words
self.subcategories = category.subcategories
super.init(nibName: nil, bundle: nil) super.init(nibName: nil, bundle: nil)
} }
@@ -27,6 +35,12 @@ final class WordListViewController: UIViewController {
super.viewDidLoad() super.viewDidLoad()
title = category.name title = category.name
navigationItem.largeTitleDisplayMode = .never navigationItem.largeTitleDisplayMode = .never
navigationItem.rightBarButtonItem = UIBarButtonItem(
image: UIImage(systemName: "arrow.triangle.2.circlepath"),
style: .plain,
target: self,
action: #selector(shuffleWords)
)
view.backgroundColor = .systemBackground view.backgroundColor = .systemBackground
tableView.dataSource = self tableView.dataSource = self
@@ -119,16 +133,41 @@ final class WordListViewController: UIViewController {
private func startQuiz() { private func startQuiz() {
Haptics.selection() Haptics.selection()
let words: [Word] let quizWords: [Word]
if category.id == "numbers" { if category.id == "numbers" {
words = NumberWords.randomWords(count: 50) quizWords = NumberWords.randomWords(count: 50)
} else { } else {
words = category.words quizWords = words
} }
let request = QuizSetupRequest(words: words) let request = QuizSetupRequest(words: quizWords)
navigationController?.pushViewController(QuizSetupViewController(request: request), animated: true) navigationController?.pushViewController(QuizSetupViewController(request: request), animated: true)
} }
@objc private func shuffleWords() {
Haptics.selection()
if var subs = subcategories {
subs = subs.shuffled().map { sub in
var s = sub
s.words = sub.words.shuffled()
return s
}
subcategories = subs
} else {
words.shuffle()
}
tableView.reloadData()
let cells = tableView.visibleCells
for (i, cell) in cells.enumerated() {
cell.alpha = 0
cell.transform = CGAffineTransform(translationX: 0, y: 12)
UIView.animate(withDuration: 0.3, delay: Double(i) * 0.03,
options: [.curveEaseOut, .allowUserInteraction]) {
cell.alpha = 1
cell.transform = .identity
}
}
}
private func updateVisibleSpeakers() { private func updateVisibleSpeakers() {
for cell in tableView.visibleCells.compactMap({ $0 as? WordCardCell }) { for cell in tableView.visibleCells.compactMap({ $0 as? WordCardCell }) {
cell.updateSpeakerState() cell.updateSpeakerState()
@@ -137,13 +176,29 @@ final class WordListViewController: UIViewController {
} }
extension WordListViewController: UITableViewDataSource, UITableViewDelegate { extension WordListViewController: UITableViewDataSource, UITableViewDelegate {
func numberOfSections(in tableView: UITableView) -> Int {
displaySubcategories?.count ?? 1
}
func tableView(_ tableView: UITableView, titleForHeaderInSection section: Int) -> String? {
displaySubcategories?[section].name
}
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
category.words.count if let subs = displaySubcategories {
return subs[section].words.count
}
return words.count
} }
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) as! WordCardCell let cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) as! WordCardCell
let word = category.words[indexPath.row] let word: Word
if let subs = displaySubcategories {
word = subs[indexPath.section].words[indexPath.row]
} else {
word = words[indexPath.row]
}
cell.configure(with: word) cell.configure(with: word)
cell.onSpeak = { word in cell.onSpeak = { word in
SpeechService.shared.speak(word.word) SpeechService.shared.speak(word.word)
@@ -158,7 +213,13 @@ extension WordListViewController: UITableViewDataSource, UITableViewDelegate {
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
Haptics.selection() Haptics.selection()
let detail = WordDetailViewController(word: category.words[indexPath.row], categoryName: category.name) let word: Word
if let subs = displaySubcategories {
word = subs[indexPath.section].words[indexPath.row]
} else {
word = words[indexPath.row]
}
let detail = WordDetailViewController(word: word, categoryName: category.name)
navigationController?.pushViewController(detail, animated: true) navigationController?.pushViewController(detail, animated: true)
} }
} }