Skip to content

feat(sql-editor): copy cell, headers, or a selected range - #247

Merged
cursor[bot] merged 1 commit into
mainfrom
cursor/grid-copy-selection-847b
Aug 13, 2026
Merged

feat(sql-editor): copy cell, headers, or a selected range#247
cursor[bot] merged 1 commit into
mainfrom
cursor/grid-copy-selection-847b

Conversation

@huyplb

@huyplb huyplb commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Problem

Copy on a result grid always dumped every row. There was no way to copy a single cell, headers only, or a selected block of values together with those column names.

Change

  • Click a cell to select it; drag or Shift-click to select a rectangle (row-number click selects the whole row).
  • Copy cell (right-click) copies that value.
  • Copy headers copies column names only (selection, or the whole grid).
  • Copy with headers copies the selected cells plus those column headers (Excel/Sheets-friendly TSV).
  • Cmd/Ctrl-C copies the selection; Cmd/Ctrl-Shift-C includes headers. Escape clears the selection so copy returns to the full grid.
  • Right-click a column header: copy header / column / column with header.

sliceGridRange in copyGrid.ts is the shared slicer (display order, inverted drags, clamping).

Tests

Unit coverage for single-cell, block+headers, inverted drag, and reordered columns. E2E copy suite updated for cell copy, selected-with-headers, and headers-only.

Open in Web Open in Cursor 

Result grids could only dump every row. Click/drag (or Shift-click) now
selects a rectangle of cells. Copy cell copies one value; Copy headers
copies names only; Copy with headers pastes the selection plus those
column names. Cmd/Ctrl-C follows the selection; Escape restores a
whole-grid copy.

Co-authored-by: huy.phan9 <huyplb@users.noreply.github.com>
@huyplb
huyplb marked this pull request as ready for review August 13, 2026 06:24
@cursor

cursor Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_fa2debb6-0325-4449-99c8-6e95bf0e0169)

@cursor
cursor Bot merged commit 16502ec into main Aug 13, 2026
11 checks passed
@cursor
cursor Bot deleted the cursor/grid-copy-selection-847b branch August 13, 2026 06:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants