Unable to Copy Link to Highlight when a highlight is already applied
Categories
(Firefox :: Menus, defect)
Tracking
()
People
(Reporter: Dasha, Assigned: jjaschke)
References
Details
Attachments
(2 files)
🐞 Steps to Reproduce:
- Open Firefox Nightly 142+
- Visit a page and activate an existing link to highlight
- Right-click directly on the already-highlighted text
- Look for “Copy Link to Highlight” in the context menu
❌ Current Behaviour:
If a highlight is already applied, the “Copy Link to Highlight” option is not available in the context menu.
This makes it hard for users to re-copy or share a highlight once it's visible — they’re forced to make a brand new manual text selection first, which isn’t intuitive. This also is out of alignment with the UX spec provided last October.
💡 Expected Behaviour:
Users should be able to right-click an existing highlight and copy it again without needing to re-select the text manually.
This interaction should feel seamless — if a visible highlight is active, the context menu should still offer the CLTH option as expected.
| Reporter | ||
Updated•7 months ago
|
| Reporter | ||
Updated•7 months ago
|
| Assignee | ||
Comment 1•6 months ago
|
||
Other browsers provide the "copy link to highlight" context menu entry if the user right-clicks
onto an existing highlight (without selection). In this case, the created link contains all highlights
on the page. If a selection exists as well, it should take precedence.
This patch adapts to this behavior. When the context menu is opened, it is determined
whether there is a selection or an existing highlight range at the given point.
This has the side-effect that the "Copy Link to Highlight" option only shows up
if the user right-clicks on a selection or an existing highlight, but not anywhere else
(this also aligns behavior to Chrome).
Updated•6 months ago
|
Comment 4•6 months ago
•
|
||
Backed out for causing mochitest failures
- backout link
- push with failures
- failure log
- failure log
| Assignee | ||
Updated•6 months ago
|
Backed out for causing bc failures @browser_contextmenu.js.
Comment 10•6 months ago
|
||
Adding this to our QA scope for Nightly 143, wasn't ware of it.
Comment 11•6 months ago
|
||
| bugherder | ||
Updated•6 months ago
|
Updated•6 months ago
|
Comment 12•5 months ago
|
||
Reproducible on a 2025-06-25 Firefox Nightly build on Windows 10.
Verified as fixed on Firefox Nightly 144.0a1 and Firefox 143.0b1(with dom.text_fragments.create_text_fragment.enabled set on true) on Windows 10, Ubuntu 22, macOS 15.
‘Copy Link to Highlight’ and ‘Copy Clean Link to Highlight’ options are visible in the context menu when selecting an already-existing highlighted fragment.
Updated•3 months ago
|
Description
•