feat: 添加全局键盘快捷键和更新故居数据,提升用户体验

- 在 main.tsx 中添加全局键盘快捷键功能,允许用户通过 Ctrl+Shift+R 重置所有缓存。
- 更新多个故居的拼图数据,增加黄炎培和鲁迅的相关信息,丰富学习内容。
- 调整 ResidenceLayout 组件以支持新的故居,确保数据一致性。
- 清理不再使用的拼图布局配置文件,提升代码整洁性。
This commit is contained in:
zhongyidian committed 2026-01-28 15:08:28 +08:00
1 parent 8ba36a4a1a
commit a365964f54
155 files changed
+1387 -348

No files matched your search

+6
View File
@@ -18,6 +18,8 @@ interface ClueStore {
getSceneClues: (sceneId: string) => Clue[];
// 重置指定场景的线索
resetSceneClues: (sceneId: string) => void;
// 重置所有线索
resetAll: () => void;
}
export const useClueStore = create<ClueStore>()(
@@ -68,6 +70,10 @@ export const useClueStore = create<ClueStore>()(
clues: clues.filter((c) => !c.id.startsWith(sceneId)),
});
},
resetAll: () => {
set({ clues: [] });
},
}),
{
name: "clue-storage", // localStorage key