Skip to content

Add a "Copy link" button to resultset headers - #99

Open
audiodude wants to merge 3 commits into
mainfrom
copy-result-link
Open

Add a "Copy link" button to resultset headers#99
audiodude wants to merge 3 commits into
mainfrom
copy-result-link

Conversation

@audiodude

@audiodude audiodude commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Adds a Copy link dropdown next to Download data in each resultset header, offering the same formats as download. Clicking a format copies the absolute result URL to the clipboard and shows a confirmation link.

This is a frontend change only and uses the same public links as "download data", simply exposing them in the UI.

🤖 Generated with Claude Code
Manually reviewed by @audiodude

The py3-black check fails on this branch. It fails on main too, for every open PR, and is unrelated to this change: the tox black environment is unpinned, so a new black release reformatted code nobody touched. Tracked in T434789 with a fix in #100 — that PR is independent of this one and can merge in either order.

@audiodude
audiodude changed the base branch from main to fix-ci-black August 13, 2026 13:31
@audiodude
audiodude requested a review from supertassu August 13, 2026 13:32
@audiodude
audiodude force-pushed the copy-result-link branch 2 times, most recently from 43bd9a7 to c7dd119 Compare August 13, 2026 13:38
@audiodude
audiodude force-pushed the copy-result-link branch 2 times, most recently from 59ed8e7 to 460ff1a Compare August 13, 2026 13:48
audiodude and others added 2 commits August 13, 2026 06:50
The result output URLs (/run/<id>/output/<resultset>/<format>) are already
unauthenticated and serve Access-Control-Allow-Origin: *, so they can be
consumed from outside Quarry - a spreadsheet's import-from-URL, a bot, a
notebook. Until now the only way to get one was to right-click a "Download
data" entry and copy the link address.

Add a "Copy link" dropdown beside "Download data", offering the same six
formats. It copies the absolute URL to the clipboard and shows a transient
"Copied to clipboard" confirmation in the resultset header. The download
links are unchanged.

The confirmation appears immediately and fades over 1.5s via a CSS
transition; jQuery's .fadeOut() is disallowed by eslint (no-jquery/no-fade).

compiled.js is regenerated with `npm run build`.

This patch was written with AI assistance (Claude Code). It has been
reviewed and tested by hand: eslint passes, and the button was verified in
a browser against a local docker-compose instance, including a query with
multiple resultsets.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Bug: T434787
Downloading is the primary action for most people looking at a resultset,
so it keeps btn-info and the rightmost position. "Copy link" is the
secondary action and moves to its left as btn-default.

The right-alignment on the dropdown menu moves with it, so it is the
rightmost menu that stays inside the column.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Bug: T434787
@audiodude
audiodude changed the base branch from fix-ci-black to main August 13, 2026 13:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant