Skip to content

Distinguish group selection in the slides overlay#303

Merged
hackerwins merged 10 commits into
mainfrom
slides-group-selection-ui
May 25, 2026
Merged

Distinguish group selection in the slides overlay#303
hackerwins merged 10 commits into
mainfrom
slides-group-selection-ui

Conversation

@hackerwins

@hackerwins hackerwins commented May 25, 2026

Copy link
Copy Markdown
Collaborator

Summary

The slides selection overlay painted the same box + handles for a single
object, a selected group, and a child selected after drilling into a
group, so a grouped pair of shapes was indistinguishable from one shape.

This makes the three states visually distinct (PowerPoint / Google Slides
hybrid), as an overlay-only change — no selection-state, hit-test, or
interaction edits (drill-in stays double-click; Esc pops out):

  • Group selected → solid box + handles, plus a faint dashed outline
    on each direct member
    (PowerPoint-style member preview).
  • Drilled-in child → solid box + handles on the child, plus a faint
    dashed context box
    around the enclosing group (Google Slides-style).
  • Single object → unchanged.

Implemented in three layers:

  • frame-space.ts — pure groupOverlayFrames(slide, selectedIds, scope)
    computing world frames for member outlines + the context box, reusing
    the existing toWorldFrame / applyGroupTransform / worldTightFrame
    math.
  • overlay.tsOverlayOptions.memberOutlines / contextBox + a shared
    handle-less dashed-rectangle renderer (appendOutline), painted beneath
    the handles.
  • editor.tsrepaintOverlay computes and forwards the frames.

Design: docs/design/slides/slides-group-selection-ui.md.

Test plan

  • pnpm verify:fast (lint + typecheck + unit tests across packages)
  • pnpm slides test test/view/editor/ — incl. new tests:
    • groupOverlayFrames unit tests (member outlines, context box,
      multi-select / non-group guards, nested-scope world coords)
    • overlay DOM tests (dashed handle-less outlines, scale, rotation,
      z-order under handles, combined context+members, default-none)
    • editor integration: group select renders member outlines + keeps
      handles; drill-in (double-click) renders the context box
  • Manual smoke in pnpm dev: select a group → member outlines;
    double-click a member → context box; Esc pops out; lone shape
    unchanged; Korean IME still composes in a grouped text box
  • Optional: pnpm verify:browser:docker to refresh visual baselines

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented May 25, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@hackerwins, we couldn't start this review because you've used your available PR reviews for now.

Your plan includes 1 review of capacity. Refill in 12 minutes and 27 seconds.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more review capacity refills, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than trial, open-source, and free plans. In all cases, review capacity refills continuously over time.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 74e3f0c7-a76e-42bd-9252-63fc14fa7978

📥 Commits

Reviewing files that changed from the base of the PR and between 1781df0 and 3461578.

📒 Files selected for processing (12)
  • docs/design/README.md
  • docs/design/slides/slides-group-selection-ui.md
  • docs/design/slides/slides-group.md
  • docs/tasks/README.md
  • docs/tasks/active/20260526-slides-group-selection-ui-lessons.md
  • docs/tasks/active/20260526-slides-group-selection-ui-todo.md
  • packages/slides/src/view/editor/editor.ts
  • packages/slides/src/view/editor/frame-space.ts
  • packages/slides/src/view/editor/overlay.ts
  • packages/slides/test/view/editor/editor.test.ts
  • packages/slides/test/view/editor/frame-space.test.ts
  • packages/slides/test/view/editor/overlay.test.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch slides-group-selection-ui

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions

github-actions Bot commented May 25, 2026

Copy link
Copy Markdown
Contributor

Verification: verify:self

Result: ✅ PASS in 223.6s

Lane Status Duration
tokens:build ✅ pass 2.3s
sheets:build ✅ pass 12.6s
docs:build ✅ pass 11.1s
slides:build ✅ pass 12.8s
verify:fast ✅ pass 143.6s
frontend:build ✅ pass 17.8s
verify:frontend:chunks ✅ pass 0.3s
backend:build ✅ pass 4.8s
cli:build ✅ pass 2.0s
verify:entropy ✅ pass 16.3s

Verification: verify:integration

Result: ✅ PASS

hackerwins and others added 10 commits May 26, 2026 01:08
The slides selection overlay paints the same box and handles for a
single object, a selected group, and a drilled-in child, so a grouped
pair of shapes is indistinguishable from one shape. This spec describes
an overlay-only change: faint dashed member outlines when a group is
selected (PowerPoint-style) and a faint dashed context box around the
enclosing group during drill-in (Google Slides-style), reusing the
world-frame math the editor already computes. Interaction and selection
state are unchanged.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Three-task TDD plan: a pure groupOverlayFrames helper, overlay
rendering of member outlines plus the drill-in context box, and the
repaintOverlay wiring. Overlay-only change, no interaction edits.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Pure helper computing world frames for a selected group's member
outlines and the drilled-in group's context box, reusing the existing
world/local frame math. No rendering yet.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Clarify that worldTightFrame returns parent-space coords, and cover
member outlines lifted through two group levels (drill-in).

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
renderOverlay gains optional memberOutlines and contextBox frames,
drawn as faint dashed handle-less rectangles beneath the selection
handles via a shared appendOutline helper.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Match renderRotatedHandles' rotation guard for consistency, and cover
a rotated context box plus the additive context-box+member-outline
case (drilled-in sub-group).

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
repaintOverlay computes member outlines and the drill-in context box
via groupOverlayFrames and forwards them to renderOverlay, so a
selected group and a drilled-in child are now visually distinct from a
single object.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Extract allSelectedIds so the intentionally-unfiltered argument to
groupOverlayFrames is explicit, and add an afterEach to the new
group-visuals describe block matching the file's pattern.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Fix the outline accent to rgba(51,170,119,0.5) so it actually equals
#3a7 (#33aa77); clarify the raw-selection comment; add an editor-level
drill-in test asserting the context box renders and member outlines do
not. Update the spec's color reference to match.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Coordinate-space pitfalls, the #3a7 color arithmetic bug, the 80-char
commit-body hook, and subagent-driven execution notes.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@codecov

codecov Bot commented May 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@hackerwins
hackerwins force-pushed the slides-group-selection-ui branch from 6d29584 to 3461578 Compare May 25, 2026 16:11
@hackerwins
hackerwins merged commit 448a711 into main May 25, 2026
1 check passed
@hackerwins
hackerwins deleted the slides-group-selection-ui branch May 25, 2026 16:12
hackerwins added a commit that referenced this pull request May 31, 2026
PRs #257/#301/#303/#304/#305/#306/#307/#309/#315/#316/#317/#321/#322
shipped between v0.4.2 and the v0.4.3 cut, leaving their paired todo
files in active with the process checkboxes still open. Flip the
remaining boxes for the work that landed, then move the paired
todo/lessons into docs/tasks/archive/2026/05/ via pnpm tasks:archive.
Active count drops from 17 to 6; archive count grows by 21 files.

Patch release covering 29 commits since v0.4.2. Headline theme is
Slides editing & UX polish toward Google Slides / PowerPoint parity:
smart guides (equal-spacing / distance / size), Shift drag modifiers,
text inside shapes, a Format options right panel, tier-1 universal
toolbar controls, text autofit (shrink + grow), group-selection
visuals, and several smaller text-box / selection fixes. PPTX import
gained paragraph-level bullet styles, body anchor (vertical
alignment), and stretched blipFill cover-crop.

Docs added a pending-inline-style at collapsed caret, a caret that
tracks the resolved text color, bullet indent on Tab / Shift+Tab,
font / size / line-spacing / clear formatting toolbar controls, an
inline-style-attribute clear that actually lands in the CRDT, and a
polished toolbar trigger / color swatch pass shared across docs /
sheets / slides. Sheets gained .xlsx import.

Infrastructure: Docker images now build on native arm64 runners,
fixing the release hang seen on v0.4.2. No Prisma migration, no new
backend env vars — the devops bump is a routine image-tag change.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
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.

1 participant