sketchmark 2.1.0 → 2.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/package.json +1 -7
  2. package/ANIMATABLE_MATRIX.md +0 -177
  3. package/KERNEL_SPEC.md +0 -412
  4. package/PACKS.md +0 -81
  5. package/PRESETS.md +0 -182
  6. package/examples/1730642890464.jpg +0 -0
  7. package/examples/app-screen.svg +0 -1
  8. package/examples/app-screen.visual.json +0 -503
  9. package/examples/dashboard-table.svg +0 -1
  10. package/examples/dashboard-table.visual.json +0 -708
  11. package/examples/dev-docs.svg +0 -1
  12. package/examples/dev-docs.visual.json +0 -248
  13. package/examples/explainer.mp4 +0 -0
  14. package/examples/explainer.visual.json +0 -1713
  15. package/examples/group-origin-effects-lab-check.svg +0 -1
  16. package/examples/group-origin-effects-lab.visual.json +0 -1880
  17. package/examples/image-clip-radius.visual.json +0 -271
  18. package/examples/make-app-screen.cjs +0 -368
  19. package/examples/make-dashboard-table.cjs +0 -277
  20. package/examples/make-dev-docs.cjs +0 -233
  21. package/examples/make-explainer.cjs +0 -438
  22. package/examples/make-group-origin-effects-lab.cjs +0 -370
  23. package/examples/make-image-clip-radius.cjs +0 -169
  24. package/examples/make-modal-dialog.cjs +0 -355
  25. package/examples/make-origin-effects-lab.cjs +0 -311
  26. package/examples/make-preset-character-motion.cjs +0 -32
  27. package/examples/make-presets-demo.cjs +0 -30
  28. package/examples/make-pricing.cjs +0 -286
  29. package/examples/make-product-demo.cjs +0 -468
  30. package/examples/make-product-hero.cjs +0 -223
  31. package/examples/make-release-notes.cjs +0 -333
  32. package/examples/make-settings-panel.cjs +0 -435
  33. package/examples/make-split-preview.cjs +0 -248
  34. package/examples/make-storyboard.cjs +0 -215
  35. package/examples/make-transcript.cjs +0 -234
  36. package/examples/make-typography-test.cjs +0 -397
  37. package/examples/make-ui-demo-explainer.cjs +0 -1094
  38. package/examples/make-ui-flow.cjs +0 -762
  39. package/examples/make-walkthrough.cjs +0 -815
  40. package/examples/modal-dialog.svg +0 -1
  41. package/examples/modal-dialog.visual.json +0 -239
  42. package/examples/origin-effects-lab-check.svg +0 -1
  43. package/examples/origin-effects-lab.visual.json +0 -1412
  44. package/examples/preset-character-motion.visual.json +0 -949
  45. package/examples/presets-demo.visual.json +0 -787
  46. package/examples/pricing.svg +0 -1
  47. package/examples/pricing.visual.json +0 -652
  48. package/examples/product-demo.mp4 +0 -0
  49. package/examples/product-demo.visual.json +0 -866
  50. package/examples/product-hero.svg +0 -1
  51. package/examples/product-hero.visual.json +0 -242
  52. package/examples/release-notes.svg +0 -1
  53. package/examples/release-notes.visual.json +0 -467
  54. package/examples/settings-panel.svg +0 -1
  55. package/examples/settings-panel.visual.json +0 -501
  56. package/examples/split-preview.svg +0 -1
  57. package/examples/split-preview.visual.json +0 -124
  58. package/examples/storyboard.svg +0 -1
  59. package/examples/storyboard.visual.json +0 -312
  60. package/examples/transcript.svg +0 -1
  61. package/examples/transcript.visual.json +0 -407
  62. package/examples/typography-indent-check.svg +0 -1
  63. package/examples/typography-lineheight-0.svg +0 -1
  64. package/examples/typography-lineheight-2.svg +0 -1
  65. package/examples/typography-test-check.svg +0 -1
  66. package/examples/typography-test.svg +0 -1
  67. package/examples/typography-test.visual.json +0 -757
  68. package/examples/ui-demo-explainer-billing.svg +0 -1
  69. package/examples/ui-demo-explainer-check.svg +0 -1
  70. package/examples/ui-demo-explainer-save.svg +0 -1
  71. package/examples/ui-demo-explainer-toggle.svg +0 -1
  72. package/examples/ui-demo-explainer.mp4 +0 -0
  73. package/examples/ui-demo-explainer.visual.json +0 -2597
  74. package/examples/ui-flow.mp4 +0 -0
  75. package/examples/ui-flow.visual.json +0 -1211
  76. package/examples/walkthrough.mp4 +0 -0
  77. package/examples/walkthrough.visual.json +0 -1372
package/PRESETS.md DELETED
@@ -1,182 +0,0 @@
1
- # Sketchmark Presets
2
-
3
- Presets are Sketchmark's official authoring layer above the render kernel.
4
-
5
- They are reusable functions that compile to pure kernel elements and timelines. A preset may create shapes, characters, motion, effects, transitions, or scene fragments, but the final `.visual.json` must still contain only kernel fields.
6
-
7
- ## Layers
8
-
9
- - `kernel`: final render format
10
- - `presets`: reusable helpers that compile to kernel
11
- - `packs`: shareable collections of presets
12
-
13
- The root `sketchmark` export remains kernel-focused. Presets live in a separate entrypoint:
14
-
15
- ```js
16
- const { applyPresetFragments, shapes, motions, effects } = require("sketchmark/presets");
17
- ```
18
-
19
- When working inside this repo before publish, examples use:
20
-
21
- ```js
22
- const { applyPresetFragments, shapes } = require("../dist/src/presets");
23
- ```
24
-
25
- ## Fragments
26
-
27
- A preset returns a fragment:
28
-
29
- ```ts
30
- type PresetFragment = {
31
- elements?: VisualElement[];
32
- timelines?: Record<string, Record<string, TimelineTrack>>;
33
- };
34
- ```
35
-
36
- `elements` are appended to the document.
37
-
38
- `timelines` are keyed by target element ID and merged into each target's local kernel timeline.
39
-
40
- ```js
41
- const doc = {
42
- version: 1,
43
- canvas: { width: 960, height: 540, duration: 2, fps: 30 },
44
- elements: []
45
- };
46
-
47
- const visual = applyPresetFragments(doc, [
48
- shapes.roundedRect({
49
- id: "card",
50
- x: 80,
51
- y: 80,
52
- width: 260,
53
- height: 120,
54
- radius: 16,
55
- fill: "#ffffff",
56
- stroke: "#cbd5e1"
57
- }),
58
- motions.riseIn({
59
- id: "card",
60
- from: [80, 120],
61
- to: [80, 80],
62
- duration: 0.5
63
- }),
64
- effects.dropShadow({
65
- id: "card",
66
- dy: 10,
67
- blur: 24,
68
- opacity: 0.2
69
- })
70
- ]);
71
- ```
72
-
73
- The output is a normal kernel document. There is no preset metadata in `.visual.json`.
74
-
75
- ## Built-In Namespaces
76
-
77
- ### `shapes`
78
-
79
- - `rect`
80
- - `roundedRect`
81
- - `ellipse`
82
- - `circle`
83
- - `line`
84
- - `polyline`
85
- - `arrow`
86
- - `regularPolygon`
87
- - `star`
88
- - `speechBubble`
89
-
90
- Shapes compile to `path`, `text`, or `group`.
91
-
92
- ### `characters`
93
-
94
- - `stickPerson`
95
- - `talkingHead`
96
- - `simpleDog`
97
- - `simpleSpider`
98
- - `cursorHand`
99
- - `simpleMascot`
100
-
101
- Characters compile to groups with namespaced IDs such as `hero.head` and `dog.frontLeg`.
102
-
103
- ### `motions`
104
-
105
- - `fadeIn`
106
- - `fadeOut`
107
- - `slideIn`
108
- - `riseIn`
109
- - `scaleIn`
110
- - `pulse`
111
- - `bob`
112
- - `shake`
113
- - `drawOn`
114
- - `stagger`
115
-
116
- Motions compile to explicit object keyframes and curves. They do not emit legacy `ease` strings.
117
-
118
- ### `effects`
119
-
120
- - `dropShadow`
121
- - `softBlur`
122
- - `glow`
123
- - `dim`
124
- - `tintFill`
125
- - `gradientSweep`
126
- - `roundedImageClip`
127
- - `maskReveal`
128
-
129
- Effects compile to existing kernel properties such as `effects.*`, `fill`, `opacity`, `clip.d`, and `mask.d`.
130
-
131
- Rounded images are compiled to `clip.d`. Presets must not write `cornerRadius`.
132
-
133
- ### `transitions`
134
-
135
- - `crossfade`
136
- - `pushLeft`
137
- - `pushRight`
138
- - `slideUp`
139
- - `wipeLeft`
140
- - `wipeRight`
141
- - `zoomCut`
142
- - `fadeThroughBlack`
143
- - `irisIn`
144
- - `irisOut`
145
-
146
- Transitions coordinate timelines across one or more target elements.
147
-
148
- ### `scenes`
149
-
150
- - `titleCard`
151
- - `lowerThird`
152
- - `captionBubble`
153
- - `comparisonSplit`
154
- - `deviceFrame`
155
- - `gridBackground`
156
-
157
- Scenes create reusable layout fragments and may be combined with motions/effects.
158
-
159
- ## Composition Helpers
160
-
161
- ```ts
162
- applyPresetFragments(document, fragments, options?)
163
- mergePresetFragments(fragments)
164
- prefixPresetFragment(fragment, prefix)
165
- ```
166
-
167
- Use `prefixPresetFragment` when reusing the same preset more than once:
168
-
169
- ```js
170
- const a = prefixPresetFragment(shapes.rect({ id: "box", x: 0, y: 0, width: 40, height: 40 }), "a");
171
- const b = prefixPresetFragment(shapes.rect({ id: "box", x: 50, y: 0, width: 40, height: 40 }), "b");
172
- ```
173
-
174
- This produces `a.box` and `b.box`.
175
-
176
- ## Authoring Rules
177
-
178
- - Presets must output only kernel elements and timelines.
179
- - Presets must not write editor metadata, scene data, lock state, selection state, assets maps, or project state.
180
- - Presets should emit explicit `graph`, `cubicBezier`, or `hold` curves, not legacy `ease`.
181
- - Presets should use namespaced IDs for generated children.
182
- - If a concept does not map cleanly to the kernel, keep it in preset code and compile it away.
Binary file
@@ -1 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" width="1440" height="900" viewBox="0 0 1440 900" role="img"><rect x="0" y="0" width="1440" height="900" fill="#f1f5f9"/><path id="sidebar-bg" d="M 0 0 L 240 0 L 240 900 L 0 900 Z" fill="#1e293b" stroke="none" stroke-width="0"/><text id="sidebar-logo" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="16" font-weight="700" fill="#e2e8f0"><tspan x="24" y="32">Acme Studio</tspan></text><text id="ws-heading" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="10" font-weight="600" letter-spacing="1" fill="#94a3b8"><tspan x="24" y="77">WORKSPACE</tspan></text><text id="nav-dashboard" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="102.5">Dashboard</tspan></text><path id="nav-projects-active-bg" d="M 18 126 L 222 126 Q 228 126 228 132 L 228 150 Q 228 156 222 156 L 18 156 Q 12 156 12 150 L 12 132 Q 12 126 18 126 Z" fill="#334155" stroke="none" stroke-width="0"/><text id="nav-projects" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="500" fill="#e2e8f0"><tspan x="24" y="136.5">Projects</tspan></text><path id="nav-projects-indicator" d="M 4 130 L 4 148" fill="none" stroke="#2563eb" stroke-width="3" stroke-linecap="round"/><text id="nav-tasks" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="170.5">Tasks</tspan></text><text id="nav-calendar" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="204.5">Calendar</tspan></text><text id="an-heading" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="10" font-weight="600" letter-spacing="1" fill="#94a3b8"><tspan x="24" y="261">ANALYTICS</tspan></text><text id="nav-overview" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="286.5">Overview</tspan></text><text id="nav-reports" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="320.5">Reports</tspan></text><text id="nav-exports" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="354.5">Exports</tspan></text><text id="st-heading" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="10" font-weight="600" letter-spacing="1" fill="#94a3b8"><tspan x="24" y="411">SETTINGS</tspan></text><text id="nav-general" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="436.5">General</tspan></text><text id="nav-team" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="470.5">Team Members</tspan></text><text id="nav-billing" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="504.5">Billing</tspan></text><text id="nav-integrations" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#94a3b8"><tspan x="24" y="538.5">Integrations</tspan></text><text id="main-title" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="28" font-weight="700" fill="#0f172a"><tspan x="280" y="46">Projects</tspan></text><text id="main-summary" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="14" font-weight="400" fill="#475569"><tspan x="280" y="79">Track active projects across your workspace. Filter by status or team to narrow</tspan><tspan x="280" y="101.4">results. Each card shows the latest activity snapshot and assigned owner.</tspan></text><path id="chip-bg-0" d="M 295 124 L 319.5 124 Q 334.5 124 334.5 139 L 334.5 139 Q 334.5 154 319.5 154 L 295 154 Q 280 154 280 139 L 280 139 Q 280 124 295 124 Z" fill="#2563eb" stroke="none" stroke-width="0"/><text id="chip-text-0" text-anchor="middle" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="500" fill="#ffffff"><tspan x="307.25" y="139">All</tspan></text><path id="chip-bg-1" d="M 359.5 124 L 406.5 124 Q 421.5 124 421.5 139 L 421.5 139 Q 421.5 154 406.5 154 L 359.5 154 Q 344.5 154 344.5 139 L 344.5 139 Q 344.5 124 359.5 124 Z" fill="#ffffff" stroke="#cbd5e1" stroke-width="1"/><text id="chip-text-1" text-anchor="middle" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="500" fill="#334155"><tspan x="383" y="139">Active</tspan></text><path id="chip-bg-2" d="M 446.5 124 L 508.5 124 Q 523.5 124 523.5 139 L 523.5 139 Q 523.5 154 508.5 154 L 446.5 154 Q 431.5 154 431.5 139 L 431.5 139 Q 431.5 124 446.5 124 Z" fill="#ffffff" stroke="#cbd5e1" stroke-width="1"/><text id="chip-text-2" text-anchor="middle" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="500" fill="#334155"><tspan x="477.5" y="139">Archived</tspan></text><path id="chip-bg-3" d="M 548.5 124 L 603 124 Q 618 124 618 139 L 618 139 Q 618 154 603 154 L 548.5 154 Q 533.5 154 533.5 139 L 533.5 139 Q 533.5 124 548.5 124 Z" fill="#ffffff" stroke="#cbd5e1" stroke-width="1"/><text id="chip-text-3" text-anchor="middle" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="500" fill="#334155"><tspan x="575.75" y="139">My Team</tspan></text><text id="table-caption" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="12" font-weight="400" fill="#64748b"><tspan x="280" y="188">Showing 3 of 12 projects · Sorted by last activity</tspan></text><path id="card-a-bg" d="M 288 210 L 1392 210 Q 1400 210 1400 218 L 1400 322 Q 1400 330 1392 330 L 288 330 Q 280 330 280 322 L 280 218 Q 280 210 288 210 Z" fill="#ffffff" stroke="#e2e8f0" stroke-width="1"/><text id="card-a-title" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="16" font-weight="600" fill="#1e293b"><tspan x="300" y="234">Design System v3</tspan></text><text id="card-a-body" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#64748b"><tspan x="300" y="258.5">Component library refactor with updated tokens, accessibility</tspan><tspan x="300" y="278.65">improvements, and new layout primitives for dashboard views.</tspan></text><text id="card-a-meta" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="11" font-weight="400" fill="#94a3b8"><tspan x="300" y="313.5">Updated 2 hours ago · Sarah K.</tspan></text><path id="card-b-bg" d="M 288 346 L 1392 346 Q 1400 346 1400 354 L 1400 458 Q 1400 466 1392 466 L 288 466 Q 280 466 280 458 L 280 354 Q 280 346 288 346 Z" fill="#ffffff" stroke="#e2e8f0" stroke-width="1"/><text id="card-b-title" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="16" font-weight="600" fill="#1e293b"><tspan x="300" y="370">API Gateway Migration</tspan></text><text id="card-b-body" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#64748b"><tspan x="300" y="394.5">Moving from the legacy REST proxy to a new GraphQL federation</tspan><tspan x="300" y="414.65">layer with per-service schema ownership and rate limiting.</tspan></text><text id="card-b-meta" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="11" font-weight="400" fill="#94a3b8"><tspan x="300" y="449.5">Updated 1 day ago · Marcus T.</tspan></text><path id="card-c-bg" d="M 288 482 L 1392 482 Q 1400 482 1400 490 L 1400 594 Q 1400 602 1392 602 L 288 602 Q 280 602 280 594 L 280 490 Q 280 482 288 482 Z" fill="#ffffff" stroke="#e2e8f0" stroke-width="1"/><text id="card-c-title" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="16" font-weight="600" fill="#1e293b"><tspan x="300" y="506">Onboarding Flow Redesign</tspan></text><text id="card-c-body" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="13" font-weight="400" fill="#64748b"><tspan x="300" y="530.5">Streamlining the first-run experience with progressive disclosure,</tspan><tspan x="300" y="550.65">reduced form fields, and contextual help tooltips.</tspan></text><text id="card-c-meta" text-anchor="start" dominant-baseline="middle" font-family="Roboto, Arial, sans-serif" font-size="11" font-weight="400" fill="#94a3b8"><tspan x="300" y="585.5">Updated 3 days ago · Priya N.</tspan></text></svg>