Text-Fragments: Set first text directive as `:target`
Categories
(Core :: DOM: Navigation, task)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox129 | --- | fixed |
People
(Reporter: jjaschke, Assigned: jjaschke)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
The first text directive needs to be set as :target element.
| Assignee | ||
Comment 1•2 years ago
|
||
This bug is being worked on in parallel to bug 1897942, which depends on this bug.
| Assignee | ||
Comment 2•2 years ago
|
||
| Assignee | ||
Comment 3•2 years ago
|
||
This patch makes some adjustments to follow the spec more strictly by
separating highlighting a text fragment (ie. adding the ranges to a eTargetText Selection)
from scrolling to it.
Scrolling to the text fragment now follows the steps given in 0 more closely,
in particular now the closest common ancestor of the target range is being used
as :target element.
This change also sets the focus to the start of the first text fragment, as indicated by the spec.
This resets the normal selection on the page.
The wpt test in /css/css-pseudo/target-text-005.html is based on the idea of having a same-doc
text fragment navigation with a selection.
This test fails with this patch applied, because the selection is reset.
It is currently unclear what behavior is correct here, thus the test is kept for now.
Comment 5•2 years ago
|
||
Backed out 4 changesets (bug 1898321, bug 1897942, bug 1897956) for causing multiple failures.
Comment 7•2 years ago
|
||
| bugherder | ||
| Assignee | ||
Updated•2 years ago
|
Description
•