Text-Fragments: Replace find algorithm with nsfind
Categories
(Core :: DOM: Navigation, task)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox129 | --- | fixed |
People
(Reporter: jjaschke, Assigned: jjaschke)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
nsFind is a much more robust and fast way of finding a string in a web page, which should replace the find algorithm given in the text fragments spec. Some small adjustments need to be made (nsFind only respects word boundaries on both ends, text fragments needs to set this separately).
| Assignee | ||
Comment 1•2 years ago
|
||
This patch depends on bug 1897956, which contains some prerequisite code that needs to land to allow the tests here to pass.
Here is a try run with this patch rebased on top of the patch of bug 1897956.
| Assignee | ||
Comment 2•2 years ago
|
||
nsFind is updated in this patch to allow checking for word boundaries at the beginning and the end of the match pattern instead of only allowing to specify whether a whole word should be searched (ie., word boundary at start and end), or not (ie., no word boundary required at start and end).
This change does not affect the IDL interface and is only available from C++. It is tested by the scroll-to-text-fragment WPTs.
This patch also introduces some more verbose debug logging for the algorithm to find a text directive.
Comment 5•2 years ago
|
||
Backed out 4 changesets (bug 1898321, bug 1897942, bug 1897956) for causing multiple failures.
Comment 8•2 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/cc2126bec6e6
https://hg.mozilla.org/mozilla-central/rev/95850130fec8
| Assignee | ||
Updated•2 years ago
|
Updated•2 years ago
|
Description
•