Skip to content

MorphSurface refresh: first-morph flash fix + anchor/absorption/spring props#10

Merged
yousefh409 merged 1 commit into
mainfrom
yousefh409/refresh-morph
Jul 3, 2026
Merged

MorphSurface refresh: first-morph flash fix + anchor/absorption/spring props#10
yousefh409 merged 1 commit into
mainfrom
yousefh409/refresh-morph

Conversation

@yousefh409

Copy link
Copy Markdown
Collaborator

Summary

  • Fix a one-frame flash on every open flip: the declarative path/speculars props jumped to the target scene before the spring loop took over (and a resync effect with a stale settling flag did the same via the imperative handle). Declarative props now track the current spring frame mid-morph; the resync is guarded by a synchronously-set ref.
  • New anchor prop: "top" pins the top edge so the panel pours downward out of the pill (faces reposition to match). Default "center" unchanged.
  • New absorption prop: "pull" moves satellites at full size and swallows them over the last stretch of travel (radius derived from position, so drops re-emerge on close). Default "shrink" unchanged.
  • New bodySpring / satelliteSpring overrides, resolved live via refs so preset switches apply to the next morph.
  • Showcase page: anchor / absorption / spring-preset controls; snippet reflects non-default choices.

No src/liquid/ engine changes — all component-local.

Test Plan

  • npm run typecheck and npx tsc --noEmit -p playground/tsconfig.json pass
  • Full vitest suite green: 329/329 (including all engine tests)
  • Live-verified on the showcase page: no first-morph flash, all knob combinations morph cleanly, no console errors

https://claude.ai/code/session_01EsufuYzyhES9JwrhNz34qC

…nd spring props

- Fix one-frame flash on every open flip: declarative path/speculars now
  track the current spring frame mid-morph (not the target scene), and the
  static-scene resync effect is guarded by a synchronously-set ref
- anchor="top" pins the top edge so the panel pours downward from the pill
- absorption="pull" moves satellites at full size and swallows them at the
  edge (radius derived from travel, so drops re-emerge on close)
- bodySpring/satelliteSpring overrides, resolved live via refs
- Showcase page: anchor/absorption/spring-preset controls, honest snippet

Claude-Session: https://claude.ai/code/session_01EsufuYzyhES9JwrhNz34qC
@yousefh409 yousefh409 merged commit b22692e into main Jul 3, 2026
2 checks passed
yousefh409 added a commit that referenced this pull request Jul 3, 2026
The parallel refreshes (PRs #10-14) grew the measured core bundle from
12.39 kB to 15.18 kB while the pin stayed at 14.9 kB — each branch fit
alone, the merge result didn't. Re-pinned at +20% headroom per the
documented convention.

Claude-Session: https://claude.ai/code/session_01CFzWWbVjWefJo5At65oS3p
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