Move some assertions to options application selectors

Repository details (talkie)
Project page
talkie
Project log category
(708 entries)
Repository
@joelpurra/talkie
Owner
@joelpurra
Contributors
Contributors on Github
Project status
⏲️ This project has had recent commits.
📂 This project is open.
🌠 This project is popular.
Repository activity period
🗓
Commits
751 commits
Stars
72 stars
Commit details (3cf2fd27)
Author
Authored at
Committer
Joel Purra
Committed at

Commit message

Move some assertions to options application selectors

  • To see/set voice settings on the options page, the user drills down via language groups, dialects, and voices.
  • Some "levels" expect the previous the previous levels to provide valid choices.
  • To simplify the lower levels, some type assertions were moved to selectors.
  • Can be further improved by splitting the voices slice into language groups, dialects, voices.
    • Splitting should reduce the need to assert values on each layers.
    • Splitting should also simplify each slice.
    • Should consider a .../features/... type directories, where slices/selectors/components/API/styling are grouped together by feature/functionality.
Raw text
Move some assertions to options application selectors

- To see/set voice settings on the options page, the user drills down via language groups, dialects, and voices.
- Some "levels" expect the previous the previous levels to provide valid choices.
- To simplify the lower levels, some type assertions were moved to selectors.
- Can be further improved by splitting the `voices` slice into language groups, dialects, voices.
  - Splitting should reduce the need to assert values on each layers.
  - Splitting should also simplify each slice.
  - Should consider a `.../features/...` type directories, where slices/selectors/components/API/styling are grouped together by feature/functionality.

Changed files (6)

Path Additions Deletions
code/packages/options-application/src/containers/voices/dialect-container.tsx +5 -30
code/packages/options-application/src/containers/voices/dialect-voice-options-container.tsx +18 -56
code/packages/options-application/src/containers/voices/language-group-container.tsx +4 -8
code/packages/options-application/src/containers/voices/voices-container.tsx +2 -0
code/packages/options-application/src/selectors/voices.mts +48 -12
code/packages/options-application/src/slices/voices.mts +16 -16

Commit categories (3)