-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Let document.caretPositionFromPoint work correctly in text control.
If the point is inside input/text area element, the `CaretPosition` should have `offsetNode` pointing to the text control element instead of the inner editor element inside the user-agent shadow tree. The behavior is also defined in step 4 of the spec[1]. [1]: https://drafts.csswg.org/cssom-view/#dom-document-caretpositionfrompoint Bug: 41487363 Change-Id: I1c024bdf6ce9620905a28487c8c91383f2086a54 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5531199 Reviewed-by: Koji Ishii <kojii@chromium.org> Reviewed-by: Sanket Joshi <sajos@microsoft.com> Reviewed-by: Mason Freed <masonf@chromium.org> Commit-Queue: Siye Liu <siliu@microsoft.com> Cr-Commit-Position: refs/heads/main@{#1301622}
- Loading branch information
1 parent
f23e47a
commit dd39fe6
Showing
1 changed file
with
70 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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