Replies: 2 comments
-
My proposal would be to add an opt-in pseudo selector variant ( <p class="selection:text-white selection:bg-black">Select this text.</p> /** For each text color it adds a class */
.selection:text-white::selection {
color: #fff;
}
/** For each background color it adds a class */
.selection:bg-black::selection {
color: #000;
} |
Beta Was this translation helpful? Give feedback.
0 replies
-
I would have needed it today. I think background color and text color are needed for both dark and bright selections. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
It would be nice to be able to custimize the pseudo-selector
::selection
I imagine this to be added as a variant that can be added for the supported properties.
By default this should be disabled for all properties (or maybe only enabled for
background-color
)I could take a stab at this if this would be something that could be added.
Beta Was this translation helpful? Give feedback.
All reactions