Add selection range checks to updateSelection, updateText and EditContext constructor. - #144
Conversation
…text constructor.
72105f8 to
b6986db
Compare
|
Hmm actually, checking the bounds in |
| <ol> | ||
| <li> | ||
| If |rangeStart| is greater than the length of [=text=], | ||
| set |rangeStart| to the length of [=text=]. |
There was a problem hiding this comment.
Still, let's add steps here to make it clear that it's intended behaviour that these can be > text.length
|
We'll need to add some telemetry to Chromium to verify to what degree this will run into compatibility problems. If that data shows it can be done, I'd be in favor of this. If Monaco turns out to be the only ones who'd have problems with the change to updateText, we could potentially reach out to them to see if they'd be willing to make a change. It'd be nice to have updateText be consistent with the rest. |
|
Yes I agree it'd be better to have |
Fixes #88. I'm hoping it's not too late to change this. :)
For normative changes, the following tasks have been completed:
Editing WG resolution on the proposed changes, with at least two implementers participating and not objecting:
For browsers that are shipping the feature, implementation bugs are filed for the proposed changes (link to bug, or write "Not Implementing"):