feat(inbox): add "Any" option to Source and Priority filters#3493
Conversation
The inbox Source and Priority filter popovers had no explicit way to go
back to "no filter" — you had to manually unselect each choice. Add an
"Any" row at the top of each popover that is checked when nothing else is
selected and clears that filter when clicked. Unselecting the last option
already collapses to the same empty ("Any") state.
Generated-By: PostHog Code
Task-Id: 97aa95fe-d9a3-4651-aa9b-9f636fc84832
|
😎 Merged successfully - details. |
|
React Doctor found no issues in the changed files. 🎉 Reviewed by React Doctor for commit |
pauldambra
left a comment
There was a problem hiding this comment.
Note
🤖 Automated comment by QA Swarm — not written by a human
Multi-perspective review (paul-reviewer, xp-reviewer, security-audit; qa-team unavailable in this environment). Verdict: ✅ APPROVE WITH NITS — no correctness or security issues, only nit/low suggestions inline.
|
Note 🤖 Automated comment by QA Swarm — not written by a human Multi-perspective review: paul-reviewer, xp-reviewer, security-audit (qa-team unavailable in this environment) Verdict: ✅ APPROVE WITH NITSSmall, focused change that does exactly one thing: makes the already-documented "empty = Any" filter state reachable from the UI. No correctness bugs, no security surface, store actions are tested. Key findings
ConvergenceTwo findings were flagged independently by both paul and xp (higher confidence): the always- Reviewer summaries
Automated by QA Swarm — not a human review |
Generated-By: PostHog Code Task-Id: 97aa95fe-d9a3-4651-aa9b-9f636fc84832
…iorityFilter([]) simplify pass: setPriorityFilter([]) already expresses "clear priority to Any", so the dedicated clearPriorityFilter action was pure duplication. clearSourceProductFilter is kept since the source filter has no equivalent setter. Generated-By: PostHog Code Task-Id: 97aa95fe-d9a3-4651-aa9b-9f636fc84832
Merge activity
|
Ports #3493 to the mobile filter sheet. Adds an "Any" row at the top of the Source and Priority sections that reads as selected when the filter is empty and clears the filter back to empty when tapped. Source clears via a new clearSourceProductFilter store action; Priority reuses setPriorityFilter([]). Generated-By: PostHog Code Task-Id: be78b0df-c31b-4e0e-8d37-feaf22a054d0
Problem
In the inbox toolbar, the Source and Priority filter dropdowns had no explicit way to get back to "no filter". Once you picked one or more values, the only way to clear was to manually unselect each one — there was no "Any" affordance, which is unintuitive (raised in the Slack thread linked below).
Changes
clearSourceProductFilter,clearPriorityFilter); empty array still means "all", so no query/serialization changes.Note: the mobile
FilterSheetuses a different paradigm (a sheet with a global "Reset" button), so it's left as-is; we can mirror the per-select "Any" there as a follow-up if desired.How did you test this?
pnpm --filter @posthog/ui test inboxSignalsFilterStore— 14 tests pass, including new cases forclearPriorityFilter,clearSourceProductFilter, and "toggling off the last source is equivalent to Any".pnpm --filter @posthog/ui typecheck— clean.biome linton the changed files — clean.Automatic notifications
Created with PostHog from a Slack thread