Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 添加设置中可选的错误处理方式 #947

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AnyaReese
Copy link

添加了用户个人习惯选择:虽然在 readme 说每次清空是为了不形成错误的肌肉记忆,但有时每次重新开始确实会影响学习心态,所以添加了一个可选选项。另外,为了避免形成错误的记忆,并不显示错误输入的字母,普通模式只显示正确字母为红色,默写模式则只显示红色下划线。
相关 Issue: #926

功能描述:

  • 增加了错误输入处理方式的可选设置,用户可在两种模式间切换:
  • 错误后继续输入:输入错误时允许继续输入并修改
  • 错误后清空重新输入:传统模式,输入错误时需完全重新开始

实现细节:

  • store/index.ts 中添加 errorHandleConfigAtom 配置,默认设置为传统模式(clear)
  • 修改了 WordComponent 中的错误处理逻辑,根据用户选择执行不同行为,并且在高级设置页面添加错误处理模式选项,使用开关控件保持与其他设置一致的UI风格。
  • 修复了相关的ESLint错误(引号转义)src › pages › Typing › components › Setting > AdvancedSetting.tsx > Line115

Copy link

vercel bot commented Mar 7, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
qwerty-learner ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 7, 2025 9:49am

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant