Skip to content

docs(sdk-playground): accurate README with stage coverage and CanResult#1429

Open
vanceingalls wants to merge 2 commits into
06-14-feat_sdk_stage_4_canundo_canredo_removeelement_gsap_cascade_override-set_cleanupfrom
06-13-docs_sdk-playground_accurate_readme_with_stage_coverage_and_canresult
Open

docs(sdk-playground): accurate README with stage coverage and CanResult#1429
vanceingalls wants to merge 2 commits into
06-14-feat_sdk_stage_4_canundo_canredo_removeelement_gsap_cascade_override-set_cleanupfrom
06-13-docs_sdk-playground_accurate_readme_with_stage_coverage_and_canresult

Conversation

@vanceingalls

@vanceingalls vanceingalls commented Jun 14, 2026

Copy link
Copy Markdown
Collaborator

What

Rewrites packages/sdk-playground/README.md to accurately document what the playground does, what SDK stages it exercises, and what's still unimplemented.

Why

The original README had several inaccuracies that would mislead reviewers:

  • Wrong ops table rowmoveElement listed comp.moveElement(id, { parent, index }) but that method/signature doesn't exist. Drag-to-reposition uses comp.setStyle(id, { left, top }) internally. No explicit moveElement button in the ops panel.
  • Outdated can() docs — described as returning a plain boolean; it now returns CanResult {ok: boolean, code?: string, message?: string, hint?: string} (landed in PR feat(sdk): can() returns CanResult; T4 dispatch-boundary tests #1426).
  • Missing stage map — no explanation of which SDK stages the playground actually exercises, making it hard for reviewers to assess coverage.
  • Keyframe ops not called outaddGsapKeyframe, setGsapKeyframe, removeGsapKeyframe are implemented in the SDK but have no UI in the playground; the old README omitted this gap.

Changes

  • Added "What this demonstrates" table mapping playground features → SDK stages (3a session API, 3b GSAP engine, 4 partial: can/getOverrides/selection/find, 5 partial: FsAdapter/FileAdapter/PlaygroundPreview)
  • Fixed ops panel table: removed incorrect moveElement row; added combined setGsapTween / removeGsapTween row; fixed addLabel/removeLabel dispatch syntax
  • Updated can() docs to show CanResult shape with example
  • Added Event log section (patch/undo/redo/selectionchange/persist:error all logged with full payload — useful for verifying RFC 6902 patch shape)
  • Moved keyframe ops to Planned / not yet wired with note that SDK impls exist

Test plan

  • README renders correctly on GitHub (tables, code spans)
  • All ops panel table rows correspond to actual buttons in the playground (bun run --cwd packages/sdk-playground dev → Ops tab)
  • "Planned" section accurately reflects what has no UI button

@vanceingalls vanceingalls force-pushed the 06-13-docs_sdk-playground_accurate_readme_with_stage_coverage_and_canresult branch from edb9a98 to 79044aa Compare June 14, 2026 07:31
@vanceingalls vanceingalls changed the base branch from 06-13-feat_sdk_can_returns_canresult_t4_dispatch-boundary_tests to 06-14-feat_sdk_stage_4_canundo_canredo_removeelement_gsap_cascade_override-set_cleanup June 14, 2026 07:31
…nt cascade

- header undo/redo buttons disabled when canUndo()/canRedo() returns false
- History/inspect op section shows live canUndo/canRedo badges (update on every patch)
- removeElement logs override-set after removal to demonstrate cascade + orphan cleanup
- README: stage 4 row updated to full coverage; Danger section + Ops table annotated
- mutate.ts: add fallow-ignore-file code-duplication (structural handler boilerplate)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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