Repository navigation
[6.x] Fix table row hover sticking in Safari - #15638
Merged
Merged
Conversation
Use `tr:hover` instead of `tr:has(:hover)`. In Safari the flattened `:has(:hover)` selector from the production build doesn't clear when the pointer leaves, so rows stayed highlighted. Plain `:hover` covers the same rows and is cheaper.
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.
Description of the Problem
Closes #15632
In Safari, table rows in the CP stay highlighted after you've hovered over them, so moving down a listing leaves a trail of grey rows behind.
The
:has(:hover)selector has been there since #12233 and hasn't changed in any v6 release, so this looks like a change in Safari 27 rather than something we broke.What this PR Does
Swaps
tr:has(:hover) tdfortr:hover td. Safari doesn't always clear the:has(:hover)match when the pointer leaves the row. A row is already:hoverwhenever anything inside it is hovered, so this highlights exactly the same rows, and it's a cheaper selector too.How to Reproduce
/cp/collectionswith a few collections