You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Also needs button-like <input>: is there more to it than this? input[type=button], input[type=file], input[type=image], input[type=reset], input[type=submit] { user-select: none; }
The document selection stringifier also interacts with the default quotes on the <q> element in a weird way, although only in Firefox: w3c/csswg-drafts#12565
TL;DR: Despite those being unselectable ::before and ::after pseudos from the UA stylesheet, Firefox does insert quotation marks into the string for them.
Although I highly doubt it's necessary for Servo to care about that at current time and there is no spec for it.
Oh, and here's a manual test file I made for myself back when implementing this in Ladybird:
<!DOCTYPE html><style>#containerlandspan{border:2px solid black;margin:.5em;display: inline-block;}</style>
An example of <spanstyle="user-select: text;">user-select:<span></span>text</span> is this.<br>
An example of <spanstyle="user-select: all;">user-select:<span></span>all</span> is this.<br>
An example of <spanstyle="user-select: none;">user-select:<span></span>none</span> is this.<br>
An example of <spanstyle="user-select: contain;">user-select:<span></span>contain</span> is this.
<h1>Containerland:</h1><divid="containerland">
start <span>foo <span>bar <spanstyle="user-select: contain; border-color: red;">baz <span>blah</span></span></span><span>bang <spanstyle="user-select: contain; border-color: red;">boom</span></span> hey</span> end
</div>
CSS UI spec says “the parent of this element”, “if this element has descendants on which”, “outside of this element”, etc. How does this interact with Shadow DOM? Gecko determines the used value based on the nsIFrame parent
Activity
Psychpsyo commentedon Sep 8, 2026
The document selection stringifier also interacts with the default quotes on the
<q>element in a weird way, although only in Firefox:w3c/csswg-drafts#12565
TL;DR: Despite those being unselectable
::beforeand::afterpseudos from the UA stylesheet, Firefox does insert quotation marks into the string for them.Although I highly doubt it's necessary for Servo to care about that at current time and there is no spec for it.
Psychpsyo commentedon Sep 8, 2026
Oh, and here's a manual test file I made for myself back when implementing this in Ladybird:
SimonSapin commentedon Sep 8, 2026
CSS UI spec says “the parent of this element”, “if this element has descendants on which”, “outside of this element”, etc. How does this interact with Shadow DOM? Gecko determines the used value based on the
nsIFrameparentAdd initial support for the `user-select` property (servo#48137)
Add initial support for the `user-select` property (servo#48137)
Add initial support for the `user-select` property (servo#48137)