Skip to content

Author filter chip removal doesn't reset page to 0 #158

@Grizouforever

Description

@Grizouforever

Description

In src/components/miners/MinerPRsTable.tsx (~line 249), the author filter chip's onDelete handler only calls setSelectedAuthor(null) but does not call setPage(0):

<Chip
  variant="filter"
  label={`Author: ${selectedAuthor}`}
  onDelete={() => setSelectedAuthor(null)}
/>

Every other filter control (status filter buttons: All, Open, Merged, Closed) correctly resets the page:

onClick={() => {
  setStatusFilter('all');
  setPage(0);
}}

Steps to Reproduce

  1. Navigate to a miner's PR list with multiple pages.
  2. Navigate to page 2 or beyond.
  3. Type/select an author filter so fewer results show.
  4. Delete the author filter chip.
  5. The table may show an empty page because the page index is now out of range.

Expected Behavior

Removing the author filter chip should reset the page to 0, consistent with all other filter controls.

Actual Behavior

The page index is not reset, potentially leaving the user on an empty page.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions