Skip to content

Add custom named groups to Code view - #100

Open
braedonsaunders wants to merge 2 commits into
mainfrom
cursor/code-named-groups-db67
Open

Add custom named groups to Code view#100
braedonsaunders wants to merge 2 commits into
mainfrom
cursor/code-named-groups-db67

Conversation

@braedonsaunders

@braedonsaunders braedonsaunders commented Sep 2, 2026

Copy link
Copy Markdown
Owner

Leftover ask from closed #82: Code view already auto-groups cards by directory. This adds user-defined named parent hulls on top, without a second product or new dependencies.

How to use

  1. Analyze a repo, switch the visualization to Code, and open a few file cards.
  2. In the Code prefs (same toolbar as Expand All, Wrap Text, and Load Files), click New Group. An in-app modal asks for the name — no browser prompt().
  3. The new group is placed at the current canvas / minimap focus so it is visible immediately (empty groups get a dashed placeholder hull). If an open card is selected and already in view, it is added in place; if that card is off-screen, it is moved into the viewport.
  4. Use the No group menu on any card header to add or remove membership.
  5. The named hull wraps its members with the custom title (dashed stroke). Directory hulls keep leftover cards that are not in a named group.
  6. Drag the named hull to move members together. Drag a card clearly outside the remaining members to drop it from the group (or set the card menu back to No group).
  7. Click the group name in prefs (or click the hull without dragging) to rename in the same in-app modal. Click ×, then Confirm? to delete. Cards stay open.
  8. Groups persist in localStorage for the current analysis session (sourceType:sourceKey), including the group origin so empty hulls stay findable.

Named membership wins for hull parenting so directory auto-groups and user groups do not fight. Hulls still rebuild on release / ticks, not on every pointermove. No new npm packages.

Tests

Extends tests/code-canvas.test.mjs for create/rename/delete, exclusive membership, hull parenting, drag-out, session persistence, the in-app name dialog (no window.prompt), and viewport placement of new / empty groups. npm test is green.

Open in Web Open in Cursor 

Let Code view create, rename, and delete named parent hulls, add or
remove open cards, and persist those groups per analysis session.
Named membership wins over directory auto-groups; dragging a card out
drops it, and group drags move members without rebuilding hulls on
pointermove.

Co-authored-by: Braedon Saunders <braedonsaunders@users.noreply.github.com>
@vercel

vercel Bot commented Sep 2, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
codeflow Ready Ready Preview Sep 4, 2026 2:13am UTC

Request Review

@braedonsaunders
braedonsaunders marked this pull request as ready for review September 2, 2026 18:18
@braedonsaunders

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

1 similar comment
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

New Group and Rename now use a Codeflow modal instead of window.prompt.
Empty and off-screen groups are created at the current canvas viewport so
they are visible immediately, including a placeholder hull on the minimap.

Co-authored-by: Braedon Saunders <braedonsaunders@users.noreply.github.com>
@cursor

cursor Bot commented Sep 4, 2026

Copy link
Copy Markdown

Retest fixes on this branch (no merge):

  • New Group and Rename no longer use the browser prompt(). Both open the existing Codeflow modal (name field, Cancel / Create or Rename, Esc / overlay to dismiss).
  • New groups are created at the current canvas / minimap focus. Empty groups get a dashed placeholder hull there; if the selected open card is off-screen it is moved into view so the hull is visible immediately.

npm test is green (216). Scoped to named-groups UX only.

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.

Feature Request: Code Canvas

2 participants