solid-motion-experiments docs research solid-layout-timing-map.md
1.3 kB · 39 lines
Markdown
at main

Solid Layout Timing Map #

Purpose #

Define a testable timing model for layout projection in Solid before full implementation.

FLIP Target Sequence #

  1. First: capture previous box.
  2. Last: capture next box.
  3. Invert: apply transform delta.
  4. Play: animate back to identity.

Key Risk #

Capturing "First" before DOM mutation is the hardest seam with fine-grained updates.

Milestone 0 Policy #

  • Start with explicit invalidation only:
    • layoutDependency
    • explicit trigger APIs (if needed)
  • Do not default to observer-driven invalidation in M0.

Timing Candidates To Validate #

  • Render-phase dirty marking: createRenderEffect.
  • Post-render measurement: createEffect / mount-gated effects.
  • Post-paint corrections: frame/RAF scheduling when needed.

Required Prototype Outcomes #

  • Tab underline probe works.
  • List reorder probe works.
  • Read/write phases are separated.
  • No SSR-time layout reads.
  • Browser spot checks pass in Chromium, Firefox, WebKit.

Adapter Implications #

  • Layout API must tolerate explicit dependency-first semantics.
  • Automatic observer model remains post-MVP until timing confidence is proven.

Open Risks #

  • Pre-mutation snapshot reliability under batched updates.
  • Scroll/fixed ancestor compensation timing.