Skip to content

feat(minimize): collapse the chat to a floating mascot with edge-aware restore#187

Merged
quiet-node merged 27 commits into
mainfrom
worktree-wondrous-stirring-willow
May 22, 2026
Merged

feat(minimize): collapse the chat to a floating mascot with edge-aware restore#187
quiet-node merged 27 commits into
mainfrom
worktree-wondrous-stirring-willow

Conversation

@quiet-node
Copy link
Copy Markdown
Owner

@quiet-node quiet-node commented May 22, 2026

Overview

Adds minimize / restore to the overlay. Instead of dismissing the chat (which cancels generation and starts a fresh session), the user can park an in-progress conversation as a small floating mascot icon and bring it back later, with the response still streaming in the background. The transition is one connected morph: the chat dissolves into the mascot on collapse and blooms back on restore, running as a GPU transform while the native window only snap-resizes at the endpoints.

Highlights

  • Park, don't lose. Minimize keeps the conversation and its in-flight stream alive; a jewel dot on the mascot lights when a reply finishes while parked.
  • Edge-aware restore. The chat unfolds into open screen space, flipping its anchor and clamping to the monitor so it never opens off-screen, wherever the icon was dragged.
  • Hotkey-aware. While minimized, double-tap-Control restores instead of starting fresh, and tray/close paths leave the parked chat intact.

How it works

A morphPhase state machine (idle → collapsing → minimized → expanding → idle) in App.tsx drives Framer Motion; positioning math lives in a pure morphGeometry.ts. An OVERLAY_MINIMIZED atomic in lib.rs routes activations to a restore while parked and is kept in sync with the React phase at every transition.

Testing

bun run test:all:coverage and bun run validate-build pass clean. Frontend is at 100% coverage (lines/branches/functions/statements); new suites cover the full lifecycle, edge-aware geometry, the unseen indicator, and focus wiring.

Note: lib.rs is excluded from the Rust coverage gate, so its &AppHandle window/visibility functions are exercised via the frontend integration tests. One unreachable-in-jsdom guard carries a justified /* v8 ignore */.

quiet-node added 27 commits May 18, 2026 15:33
…d command

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…owControls

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…dicator

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…mize

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…rver mechanism

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…he window snap

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…s as a morph not a cut

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…the handoff is clean

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…e jump and tiny-chat

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…of the bare corner

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…ossfade

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
… not clipped

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…verlay

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…hout jumping

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
… handoff

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
…typewriter

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
… 8px gaps

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
… cases

Signed-off-by: Logan Nguyen <lg.131.dev@gmail.com>
@quiet-node quiet-node changed the title fix(minimize): resolve minimize/restore state-machine desync and edge cases feat(minimize): collapse the chat to a floating mascot with edge-aware restore May 22, 2026
@quiet-node quiet-node merged commit 23507c0 into main May 22, 2026
3 checks passed
@quiet-node quiet-node deleted the worktree-wondrous-stirring-willow branch May 22, 2026 22:34
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