Skip to content

Persist Inbox "Show unread only" toggle across visits #3669

Description

@thevidarbob

Problem

The Inbox's Show unread only toggle resets to off whenever the Inbox view is remounted. Users who prefer an unread-only Inbox have to enable it again after navigating away, reopening the Inbox, or restarting Buzz.

The current Desktop implementation stores this only as component state and initializes it to false:

const [filter, setFilter] = React.useState<InboxFilter>("all");
const [unreadOnly, setUnreadOnly] = React.useState(false);

Steps to reproduce

  1. Open the Inbox.
  2. Enable Show unread only.
  3. Navigate away from the Inbox and return, or restart Buzz and reopen the Inbox.

Current behavior

Show unread only is off again.

Expected behavior

Buzz remembers the user's last choice and restores the toggle to the same checked or unchecked state the next time the Inbox opens.

Acceptance criteria

  • Enabling Show unread only remains effective after navigating away from and back to the Inbox.
  • The enabled state is restored after restarting Buzz.
  • Disabling the toggle updates the saved preference so it remains disabled on subsequent visits.
  • Users without a saved preference retain the current default of off.
  • Automated coverage verifies preference restoration and the default/fallback behavior.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions