Open Bug 1422017 Opened 8 years ago Updated 3 years ago

Selection node object anchorOffset and anchorNode properties do not return expected results

Categories

(Core :: DOM: Selection, defect, P3)

56 Branch
defect

Tracking

()

UNCONFIRMED

People

(Reporter: cornichonche, Unassigned)

Details

Attachments

(1 file)

Attached file test2.html
User Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:56.0) Gecko/20100101 Firefox/56.0 Build ID: 20171024165158 Steps to reproduce: I selected a text to retrieve the parent of anchor and focusNode and some other datas in order to test JavaScript behavior. The selection contains 2 paragraphs with a button between them. The button is causing the bug. I joined a file where everything is ready to test. Actual results: The parent anchorNode returns BODY and anchorOffset of the selection is 0. Expected results: The anchorNode property should return P and anchorOffset 6.
Component: Untriaged → DOM: Core & HTML
Product: Firefox → Core
Component: DOM: Core & HTML → Selection
Priority: -- → P1
Priority: P1 → P3
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: