-
Notifications
You must be signed in to change notification settings - Fork 187
feat: save starred navigation item open state #3499
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
base: master
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
c0fac52 to
1dfd750
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds persistent state management for the starred navigation item's open/collapsed state, building on the grouped starred items feature from #3148. Previously, the starred section would revert to its default state on page refresh; now the user's preferred open/collapsed state is saved and restored.
Key changes:
- Added
starredOpenStateto the Vuex store with getter and mutation - Replaced the temporary
wasStarredVisitedapproach with persistent storage via provisioning API - Updated backend to include
starredOpenStatein user settings - Added comprehensive unit tests for the new functionality
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| src/store/app.ts | Added starredOpenState boolean to store state, with getter and mutation for managing the open/collapsed state |
| src/components/Sidebar.vue | Implemented toggleStarredOpenState method to persist state via API, replaced wasStarredVisited with isStarredOpen computed property, bound to @update:open event |
| lib/Controller/PageController.php | Added starredOpenState to the list of user settings loaded on page initialization |
| tests/javascript/unit/store/app.spec.ts | Added tests for the new getter and mutation |
| tests/javascript/unit/components/Sidebar.spec.ts | Added tests for toggle functionality, removed obsolete wasStarredVisited tests, improved test setup with proper mocks |
Signed-off-by: Wolfgang <[email protected]>
1dfd750 to
212b1d0
Compare
Summary
This PR adds saving the open state to the new starred group feature introduced in #3148
Checklist