Mastodon theme: fix search, add cmd-k, style messages#651
Merged
Conversation
- Fix User_Query returning all WP users instead of only subscriptions by using `include => array(0)` to suppress the parent WP_User_Query - Add cmd-k/ctrl-k keyboard shortcut to focus the search input - Fix search autocomplete dropdown: override spectre flex/gap styles that broke inline <mark> highlighting and caused visual artifacts on hover/focus - Fix search input resizing during loading spinner animation - Add Mastodon-themed styling for the messages display
Contributor
Test this PR in WordPress PlaygroundYou can test this pull request directly in WordPress Playground: This will install and activate the plugin with the changes from this PR. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
User_Query::search(),all_subscriptions(), andstarred_friends_subscriptions()were usingnew self(array('number' => 0))which ran aWP_User_Querywith no role filter, returning all WordPress users alongside virtual subscriptions. Changed toarray('include' => array(0))to suppress the parent query.?help overlay.display: flexandgap: 10pxon.menu-item athat broke inline<mark>highlighting (text appeared spaced out). Fix hover/focus artifacts from spectre's padding/margin/background rules. Fix search input resizing during loading spinner.Changelog
Type
Message
Fix Mastodon theme search autocomplete styling and prevent User_Query from returning non-subscription WordPress users.
Test plan