You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 15, 2026. It is now read-only.
The link "tile" that shows a URL's domain with a link glyph appears throughout the UI, but there's no way to copy the underlying URL — you can only click through to open it. We should add a small click-to-copy icon + behavior so the URL can be grabbed without navigating.
This is the same component shown in a message transcript (the github.com chip under a link) and on the Media → Links tab.
Where it renders
Transcript link pill — internal/web/templates/partials.html (the msg-links block):
Reuse the existing copy affordance so there's no new JS or CSP change:
internal/web/static/copy.js already powers copy buttons via data-copy-target + a .copy-btn with a copy→check icon swap (see the MCP blocks in internal/web/templates/settings.html). It reads the target element's text.
Add a small .copy-btn (icon-only, icon-copy) beside the link tile that copies the full URL. Because copy.js copies the target element's text, either point it at an element holding the full {{.URL}} or extend copy.js to accept a data-copy-value attribute for cases where the visible text is just the domain (the transcript pill shows {{.Domain}}, not the full URL).
Acceptance criteria
A copy icon appears on the link tile (transcript pill + Media Links row), keyboard-operable with an aria-label (e.g. "Copy link").
Clicking it copies the full URL to the clipboard (not just the domain), with the existing copy→check confirmation and the #copy-announce aria-live announcement.
No inline JS / no CSP change (reuse copy.js; script-src 'self').
Works in both light and dark themes and doesn't break the tile's click-through-to-open behavior.
Context
The link "tile" that shows a URL's domain with a link glyph appears throughout the UI, but there's no way to copy the underlying URL — you can only click through to open it. We should add a small click-to-copy icon + behavior so the URL can be grabbed without navigating.
This is the same component shown in a message transcript (the
github.comchip under a link) and on the Media → Links tab.Where it renders
internal/web/templates/partials.html(themsg-linksblock):internal/web/templates/gallery.html:Proposed solution
Reuse the existing copy affordance so there's no new JS or CSP change:
internal/web/static/copy.jsalready powers copy buttons viadata-copy-target+ a.copy-btnwith a copy→check icon swap (see the MCP blocks ininternal/web/templates/settings.html). It reads the target element's text..copy-btn(icon-only,icon-copy) beside the link tile that copies the full URL. Becausecopy.jscopies the target element's text, either point it at an element holding the full{{.URL}}or extendcopy.jsto accept adata-copy-valueattribute for cases where the visible text is just the domain (the transcript pill shows{{.Domain}}, not the full URL).Acceptance criteria
aria-label(e.g. "Copy link").#copy-announcearia-live announcement.copy.js;script-src 'self').