Closed Bug 1239664 Opened 10 years ago Closed 10 years ago

(-moz-)user-select: none not working with contenteditable

Categories

(Core :: DOM: Editor, defect)

43 Branch
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: cyril.auburtin, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.106 Safari/537.36 Steps to reproduce: demo: http://jsfiddle.net/crl/ksgutpn1/4/ there shouldn't be any visible selection with editor.contentEditable='false' and editor.classList.add('noselection') Actual results: the text selection still appears Expected results: there should be no selection
Component: Untriaged → Editor
It seems you have misunderstood what the 'user-select' property is for. As the name suggests, it's for controlling what the *user* can select on the page. The page author can still select any part of the page using script, as you did in the example. The 'user-select' property doesn't affect script at all. Let me know if I misunderstood what you are trying to demonstrate with the example.
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → INVALID
oh ok, I see thanks
You need to log in before you can comment on or make changes to this bug.