Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 66231fea23d9ec5263451b700d4b3f31ddaad358
https://github.com/WebKit/WebKit/commit/66231fea23d9ec5263451b700d4b3f31ddaad358
Author: Anuj Panta <[email protected]>
Date: 2026-05-20 (Wed, 20 May 2026)
Changed paths:
M Source/WebInspectorUI/UserInterface/Views/LogContentView.js
Log Message:
-----------
Clearing the Console tab search field does not dismiss the Clear Filters
button
https://bugs.webkit.org/show_bug.cgi?id=314204
rdar://176388155
Reviewed by BJ Burg and Devin Rousso.
The banner ("There are unread messages that have been filtered") stuck around
after clearing the search field because performSearch("") never touched
_immediatelyHiddenMessages.
We introduce _updateHiddenMessagesBanner() to centralize banner management.
It reconciles the Set against the current filter state before refreshing the
banner, so each call site doesn't have to do its own manual cleanup.
Hook it into all three performSearch exit paths (empty query, invalid regex,
valid regex) — all three can change filter state but none of them updated the
Set. The empty-query path is the bug.
The old inline _immediatelyHiddenMessages.delete() in _filterMessageElements
only checked scope visibility, not search, so a message still hidden by search
would drop out of the Set and hide the banner prematurely. The new method
handles removal and checks both dimensions.
Also, drop the now-redundant banner calls in _scopeBarSelectionDidChange and
_messageSourceBarSelectionDidChange, since _filterMessageElements already
calls performSearch which now reconciles.
* Source/WebInspectorUI/UserInterface/Views/LogContentView.js:
(WI.LogContentView.prototype.didAppendConsoleMessageView):
(WI.LogContentView.prototype._previousMessageRepeatCountUpdated):
(WI.LogContentView.prototype._logCleared):
(WI.LogContentView.prototype._messageSourceBarSelectionDidChange):
(WI.LogContentView.prototype._scopeBarSelectionDidChange):
(WI.LogContentView.prototype._filterMessageElements):
(WI.LogContentView.prototype.performSearch):
(WI.LogContentView.prototype._updateHiddenMessagesBanner):
(WI.LogContentView.prototype._showHiddenMessagesBannerIfNeeded): Deleted.
Canonical link: https://commits.webkit.org/313599@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications