Conversation
There was a problem hiding this comment.
Pull request overview
This PR reduces Zustand usage by removing the custom toast Zustand store/components and migrating toast notifications to Base UI’s toast manager, updating call sites across the app accordingly.
Changes:
- Remove the Zustand-backed toast store and the custom toast item component/types.
- Introduce a shared
toastManager(Base UI) and switch existing notification call sites totoastManager.add(...). - Regenerate/update Lingui
.pofiles (source line reference updates).
Reviewed changes
Copilot reviewed 19 out of 19 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/types/museeks.ts | Removes legacy toast-related types. |
| src/stores/useToastsStore.ts | Deletes Zustand toast store (no longer used). |
| src/lib/toast-manager.ts | Adds shared Base UI toast manager singleton. |
| src/lib/utils.ts | Routes error notifications through toastManager instead of toast store. |
| src/stores/useLibraryStore.ts | Uses toastManager for scan/reset success messages. |
| src/stores/SettingsAPI.ts | Uses toastManager for update-check success messages. |
| src/stores/PlaylistsAPI.ts | Uses toastManager for playlist creation messages. |
| src/components/Toasts.tsx | Replaces custom toast list rendering with Base UI Toast Provider/Viewport/Root. |
| src/elements/Toast.tsx | Removes legacy toast item component styling/rendering. |
| src/components/TrackList.tsx | Uses toastManager for “added to playlist” feedback. |
| src/components/PlayerEvents.tsx | Uses toastManager for audio error notifications and removes hook dep. |
| src/components/DropzoneImport.tsx | Uses toastManager for import warnings/success and removes hook dep. |
| src/translations/en.po | Updates extracted source references (line numbers). |
| src/translations/es.po | Updates extracted source references (line numbers). |
| src/translations/fr.po | Updates extracted source references (line numbers). |
| src/translations/ja.po | Updates extracted source references (line numbers). |
| src/translations/ru.po | Updates extracted source references (line numbers). |
| src/translations/zh-CN.po | Updates extracted source references (line numbers). |
| src/translations/zh-TW.po | Updates extracted source references (line numbers). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 19 out of 19 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 19 out of 19 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Uh oh!
There was an error while loading. Please reload this page.