Remember sorting preferences when viewing your own game list #981

Open
opened 2026-10-16 16:09:49 -05:00 by Codex · 0 comments
Member

Follow up on #784 and PR #980 by remembering a member's game-list sort preferences when they sort their own list. Sorting another member's list should remain temporary and apply only to the current view/URL.

Expected behavior

  • Remember the authenticated owner's selected sort field and direction when they use sorting controls on their own list.
  • Restore that preference on later visits to their own list when the URL does not explicitly specify a sort order.
  • Apply the same behavior to /list and the owner's direct /list/{username} page.
  • Keep sorting on friends' and other members' lists temporary. It must not change the list owner's preference or overwrite the viewer's saved preference for their own list.
  • Continue honoring explicit sort parameters in URLs so bookmarked/shared sorted views work.

Acceptance criteria

  • All six existing fields and both directions can be remembered: Name, Rating, Date Added, Priority, Ownership Type, and Platform.
  • A saved preference is used consistently across status tabs, All sections, desktop tables, mobile cards, and load-more requests.
  • Only sorting one's own list updates the saved preference; guest views and views of other members' lists do not persist changes.
  • Members without a saved preference retain the existing Name A–Z default.
  • Invalid or obsolete saved values fall back safely to the existing defaults.
  • Existing privacy rules and owner-only edit/delete actions remain intact.

Test coverage

  • Save and restore an owner's field/direction on both owner-facing routes.
  • Confirm another member or guest cannot update the owner's preference.
  • Confirm sorting a friend's list does not overwrite the viewer's own saved preference.
  • Cover explicit URL overrides, default/fallback behavior, status tabs, and load-more state.

Progress checklist

  • Add owner-only preference persistence and restoration
  • Preserve temporary sorting for other members' lists
  • Integrate with the existing shared sorting and URL behavior
  • Add focused regression coverage
  • Run relevant tests and formatting checks
Follow up on #784 and PR #980 by remembering a member's game-list sort preferences when they sort their own list. Sorting another member's list should remain temporary and apply only to the current view/URL. ## Expected behavior - Remember the authenticated owner's selected sort field and direction when they use sorting controls on their own list. - Restore that preference on later visits to their own list when the URL does not explicitly specify a sort order. - Apply the same behavior to `/list` and the owner's direct `/list/{username}` page. - Keep sorting on friends' and other members' lists temporary. It must not change the list owner's preference or overwrite the viewer's saved preference for their own list. - Continue honoring explicit sort parameters in URLs so bookmarked/shared sorted views work. ## Acceptance criteria - All six existing fields and both directions can be remembered: Name, Rating, Date Added, Priority, Ownership Type, and Platform. - A saved preference is used consistently across status tabs, All sections, desktop tables, mobile cards, and load-more requests. - Only sorting one's own list updates the saved preference; guest views and views of other members' lists do not persist changes. - Members without a saved preference retain the existing Name A–Z default. - Invalid or obsolete saved values fall back safely to the existing defaults. - Existing privacy rules and owner-only edit/delete actions remain intact. ## Test coverage - Save and restore an owner's field/direction on both owner-facing routes. - Confirm another member or guest cannot update the owner's preference. - Confirm sorting a friend's list does not overwrite the viewer's own saved preference. - Cover explicit URL overrides, default/fallback behavior, status tabs, and load-more state. ## Progress checklist - [ ] Add owner-only preference persistence and restoration - [ ] Preserve temporary sorting for other members' lists - [ ] Integrate with the existing shared sorting and URL behavior - [ ] Add focused regression coverage - [ ] Run relevant tests and formatting checks
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MyVideoGameList/myvideogamelist.com#981
No description provided.