Skip to content

feat(playground): integrate DialKit real-time tweaking (draft/exploratory) - #2

Draft
tanthehack wants to merge 1 commit into
feature/admin-panel-uifrom
feature/dialkit-playground
Draft

feat(playground): integrate DialKit real-time tweaking (draft/exploratory)#2
tanthehack wants to merge 1 commit into
feature/admin-panel-uifrom
feature/dialkit-playground

Conversation

@tanthehack

Copy link
Copy Markdown
Contributor

Draft — exploratory. Answers "can DialKit be worked into the playground?" (yes). Parking it to iterate later.
Based on feature/admin-panel-ui (#1), not main, so the diff is just the DialKit changes.

Summary

Integrates DialKit (real-time parameter tweaking) into the design-system playground as a new Motion → Interactive (DialKit) section. A live specimen card's radius / padding / accent / elevation / lift-spring are all driven by useDialKit + motion/react.

Verified

  • Installs & runs under Next 16 (Turbopack) + React 19 — no console errors, pnpm typecheck clean.
  • Dark-theme sync is automatic (theme="system").
  • Card tracks dial values exactly (Accent #84CC16 / radius 20 / padding 28).
  • Coexists with the existing token TweakPanel (DialKit starts as a corner launcher).

Key decisions (full write-up in components/playground/DIALKIT-NOTES.md)

  • Client-only render (next/dynamic({ ssr: false })) — DialKit reads a browser store; SSR would hydration-mismatch.
  • Cast the spring to motion's Transition (DialKit types it broadly; runtime is motion-compatible).
  • defaultOpen={false} — DialKit defaults to open and persists its state; forcing closed avoids overlapping the right-side TweakPanel.
  • Division of labor: TweakPanel owns persistent token overrides; DialKit owns transient per-component motion/prop exploration.

Open questions / follow-ups

  • Two right-anchored panels overlap if both are opened — auto-close one when the other opens, or move one to the opposite edge?
  • motion is now a dependency pulled in solely for this demo — keep only if we lean into DialKit for motion specs.
  • Add more DialKit specimens (buttons, badges) or keep it a single proof?
  • Set productionEnabled if the playground ever ships to prod.

Add a Motion > Interactive (DialKit) playground section: a live
specimen card whose radius/padding/accent/elevation/lift-spring are
driven by useDialKit + motion/react. Mount <DialRoot theme=system> as a
corner launcher so it coexists with the token TweakPanel, loaded
client-only to avoid SSR hydration mismatch. See DIALKIT-NOTES.md for
the prototype verdict.

Verified: typecheck clean, no console errors, dark-theme sync, card
tracks dial values, TweakPanel unobstructed.
@vercel

vercel Bot commented Jul 25, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
clover-admin Ready Ready Preview, Comment Jul 25, 2026 5:45pm

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