fix(dashboard): clear logs search via Escape or empty box, not just ×#3095
fix(dashboard): clear logs search via Escape or empty box, not just ×#3095simplesagar wants to merge 1 commit into
Conversation
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
985d443 to
c92100e
Compare
|
Superseded by #3096, which now bundles this LogFilterBar fix together with the shared SearchBar Escape-to-clear change. |
What
Follow-up to #3093 (AGE-2594). On the MCP Server Logs page, the filter search bar could only be cleared by clicking the
×button — pressing Escape or deleting the text out of the box left the results still filtered.Why
LogFilterBartracks the livesearchInputseparately from the parent's appliedsearchQuery(which drives the data fetch). They only sync on submit. The×button calledonSearchSubmit("")to clear the applied query, but:onSearchSubmit, so the applied query lingered (and it was gated behind the popover being open).searchInputto""but never re-submitted, sosearchQuerystayed set and results remained filtered until an explicit submit.So
×was the only way to actually clear the search — the same "stuck filter" class of bug as the parent ticket.How
×: clears the input, resets the flow, and callsonSearchSubmit(""). In the operator step it still just cancels the in-progress filter build without touching an applied search.onSearchSubmit("")so results refresh as soon as the query is gone.Clearing when nothing is applied is a no-op (
searchQueryis already null → no refetch).Scope
Frontend-only, single file. No backend, migration, or SDK changes.
Testing
tsc -p tsconfig.app.json --noEmit— clean.eslint— clean.