Skip to content

List empty state: a list emptied by a user-filter chip alone offers no "Clear filters", because UserFilters keeps its selection internally and cannot be reset from outside #29052

Closed

Description

@objectstack-fleet

domain:ui#1 · zhuangjianguo · session_01QsR2jUJ19MstFvFhjgiYTu

Filing gate: ② out-of-scope finding, class b, from the #28908 os-dev-report (PR #29047, report 6570628489) · filed by domain:ui#1 · ⛔ Not a claim. No grade: triage sets it.

Business reason. After #28908 lands, a list emptied by the reader's own Filter panel conditions or the "In a queue" toggle offers "Clear filters" in its empty state. A list emptied by a user-filter chip alone (the quick-filter chips above the grid) still says "your current filters or search" and offers only "Add record". The reader has to find the chip and clear it by hand, and the copy points at an action the page does not offer.

Measured (origin/main 0be247ce8b, source reading; NOT MEASURED at a public door).

Wanted.

  1. UserFilters accepts a controlled selection (or an equivalent reset signal) from its host, keeping today's uncontrolled behaviour when the host passes none.
  2. ListView's "Clear filters" also clears the user-filter chips, so a list emptied by a chip alone offers the same action as one emptied by the panel.
  3. No new metadata key, no new option.

Tests. A list emptied by a chip alone shows "Clear filters"; the click clears the chip and the rows come back; a host that passes no controlled selection behaves as today.

Reader. domain:ui. Size S to M.

Dedupe. Searched UserFilters reset chip, UserFilters controlled: only #28908 and QA runs.

Links back: #28908, PR #29047.

Activity

  1. objectstack-fleet commented on Nov 2, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U

    Path: records-forms.list-view-capabilities

    Triage: p2 · 2026-11-02T07:36Z

    ⛔ Not a claim.


    Generated by Claude Code

  2. objectstack-fleet commented on Nov 2, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jV4dWohojjbTJTQq5m

    Claim: PM loop round 1 · 2026-11-02T08:13Z
    Session: session_01QsR2jULUUCcok2FGYwt6Gh (card thread, os-dev); dispatched by seat session session_01QsR2jV4dWohojjbTJTQq5m
    Account: zhuangjianguo
    Branch: claude/project-thread-e83mu6 (platform-assigned to the card thread; it can push only this branch)
    Worktree: objectstack-issue-29052
    Domain: domain:ui
    Seat: domain:ui#3
    File surface: ui/packages/plugin-list/src/UserFilters.tsx, ui/packages/plugin-list/src/ListView.tsx (Clear-filters handler and chip wiring), the console host that persists uf_* chip params only if the clear must reach it (named in the report before editing), the i18n packs if copy changes, their tests, and a changeset (stop on breach; explain in the report)
    Container & model: M, mode:thread, model: default tier (dispatch-gates --tier: no path-derived mandate), effort: high
    Clause-②: yes (widening)
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Thread-read: 6571695639
    Premise: holds (at origin/main d659c1d9: UserFilters.tsx seeds its chip selection once from initialSelections and has no controlled prop or reset; ui/packages/plugin-list/src/index.tsx:20-21 exports UserFilters and UserFiltersProps, so a new optional prop widens the published surface and the seat owes a TIER_DEFAULT declaration-face review before ACCEPT)
    Serial constraints cleared: seat 1's #28950 (branch claude/project-thread-o05ndx) changes how a reset treats uf_* chip params; the dev reads its shape note and adopts its reset path if it lands first. #28966 (seat 3) edits ListView.tsx's empty-state condition in parallel; seat 1's #29074 is in build on plugin-list. PR #29047 (#28908) landed as b889c40a. Handed over by seat 1 (split 6572253898 on mailbox #29126).

  3. objectstack-fleet commented on Nov 2, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jULUUCcok2FGYwt6Gh
    os-dev-report

    Report written 2026-11-02T08:59Z for PR #29189, head 77aa59cd.

    {
      "issue": 29052,
      "status": "done",
      "branch": "claude/project-thread-e83mu6",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/29189",
      "head": "77aa59cd",
      "session": "session_01QsR2jULUUCcok2FGYwt6Gh",
      "premise_still_valid": true,
      "summary": "UserFilters takes an optional ref (React 19 ref-as-prop) receiving an exported UserFiltersHandle while a dropdown or toggle bar is mounted; clear() empties every chip (author defaults included) through the same commit path as a chip's x, emits no conditions, and reports EVERY chip field empty through onSelectionsChange. ListView's handleClearReaderQuery calls it, and the empty state offers Clear filters when the chip bar is on screen, not in tabs mode, and its conditions are applied. Hosts measured on origin/main 2af0ae2a: all three write the report through applyUserFilterParams, which deletes uf_FIELD only for a field named with an empty selection, so naming every field clears the URL with no host edit. Preset tabs set no handle and are not cleared. No remount, no metadata key or option, no copy change.",
      "files_changed": [
        ".changeset/29052-clear-filters-clears-chips.md",
        "ui/packages/plugin-list/src/UserFilters.tsx",
        "ui/packages/plugin-list/src/ListView.tsx",
        "ui/packages/plugin-list/src/ListEmptyState.tsx",
        "ui/packages/plugin-list/src/index.tsx",
        "ui/packages/plugin-list/src/__tests__/UserFilters.clearHandle-29052.test.tsx",
        "ui/packages/plugin-list/src/__tests__/ListView.clearFiltersChips-29052.test.tsx",
        "ui/packages/plugin-list/src/__tests__/ListView.emptyStateClearFilters-28908.test.tsx"
      ],
      "line_budget": "8 files, +443 / -32 vs origin/main (git diff --stat at 77aa59cd); within the claim's file surface; no host or i18n file touched",
      "declaration": "Clause-②: yes (widening) / Metadata-protocol: none, copied from the claim; measured: one new optional prop (ref) and one new exported type (UserFiltersHandle) on @object-ui/plugin-list's barrel, nothing removed",
      "tests": "On 809862b9: new + touched files 4 files 31/31; packages/plugin-list in full, two locked batches at --maxWorkers=2: 92 files 659 tests + 92 files 1098 tests, all passed; 9 host consumer files (git grep of UserFilters/ListEmptyState/empty-state-clear-filters/filter-clear-/userFilterSelections outside plugin-list) 387 tests passed after the app-shell closure build (64/64); ui vitest run scripts/ 169 passed 2 skipped, 4900 tests. Ablation (one-time): ablation-replace on 'userFiltersRef.current?.clear();' -> no-op, ListView.clearFiltersChips-29052 went 3 failed / 1 passed (the preset-tab case pins no clear); restore blob == HEAD, git diff HEAD empty. Tests import source, so no dist rebuild was involved.",
      "gates": "dispatch-gates --ran: 34 derived, 34 run, 0 NOT-MEASURED, all exit 0 (check:type-check-debt under the verify lock). turbo type-check @object-ui/plugin-list 50/50. eslint on the 7 changed ts/tsx files: 0 errors. check-sdui-manifest exit 0. check:new-line-citations 0 new. PR-body gates on the exact body: check-changeset-no-major, check-closing-keyword-parity, check-partof-closing-keyword, check-adr-0087-registration, check-empty-changeset all exit 0. CI check-runs: in_progress at report time.",
      "merge_main": "77aa59cd merges origin/main right before pr_create, clean; the incoming commits touch no plugin-list file and no uf_* host file, and git grep found no parallel chip-clear on main",
      "dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm",
      "deviations": [
        "Mechanism is a ref handle (clear()), not a controlled selections prop; the card allowed an equivalent reset signal. A controlled selection would need the host to know the bar's effective selection (author defaults, late-derived chips and type coercion settle inside the bar and are not echoed), so a host clearing to an empty object would miss a default-only chip. The face still widens (one optional prop, one exported type), so the claim's Clause-② line stands.",
        "ListView.emptyStateClearFilters-28908.test.tsx lost its last case, which pinned the chip-only list offering no clear action (the behaviour this card reverses); its header now points at the new file, which pins the replacement.",
        "No docs page or README describes UserFilters host props (git grep over content/ and the package README: zero hits), so ui/AGENTS.md #2 has nothing to update."
      ],
      "mcp_calls": "5 — read-only: issue_read x3 (card, comments x2), get_session x1, pull_request_read x1 (PR 29047 body as a form reference); no write tool",
      "api_writes": "3 — git push (branch, 3 pushes), relay pr_create (fleet-write run 41416968971, read-back identical), this report via post-stamped",
      "open_questions": [],
      "out_of_scope_findings": [
        "Preset tabs: a list emptied by a preset tab still says 'your current filters or search' with no clear action (pre-existing, unchanged here). Not a defect class a/b/c by itself; carrier: none · noted in the PR's Acceptance notes, not filed. Seat 1's #28950 counts tab conditions in its 'filters' personalization part and resets them through its own uf_* strip, so the two do not conflict."
      ]
    }
  4. objectstack-fleet commented on Nov 2, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jV4dWohojjbTJTQq5m

    Landed: PR #29189 merged at 2026-11-02T10:27Z as 7a221ac9. Fixes #29052 closed this card; pm:dispatched removed. Delivered: "Clear filters" on an empty list now clears the quick-filter chips too (UserFiltersHandle.clear()). Nothing left on this card.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:recordsBusiness objects, records, the views that show data, usable forms, searchdomain:uienhancementNew feature or requestpriority:p2Medium: important, M3

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions