create-presmium 0.0.0-stage → 1.0.0-rc.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 (561) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +47 -2
  3. package/bin/create-presmium.mjs +6 -0
  4. package/package.json +51 -3
  5. package/src/cli.ts +116 -0
  6. package/src/create.ts +160 -0
  7. package/src/messages.ts +318 -0
  8. package/src/templates.ts +43 -0
  9. package/templates/README.md +7 -0
  10. package/templates/document/default/lecture.json +75 -0
  11. package/templates/plugin/AGENTS.md +38 -0
  12. package/templates/plugin/README.md +41 -0
  13. package/templates/plugin/components/GreetingCard.css +32 -0
  14. package/templates/plugin/components/GreetingCard.tsx +27 -0
  15. package/templates/plugin/example/lecture.json +169 -0
  16. package/templates/plugin/gitignore +11 -0
  17. package/templates/plugin/package.json +47 -0
  18. package/templates/plugin/pnpm-workspace.yaml +10 -0
  19. package/templates/plugin/src/domain/index.ts +44 -0
  20. package/templates/plugin/src/node/presmium.ts +44 -0
  21. package/templates/plugin/test/plugin.test.ts +60 -0
  22. package/templates/plugin/tsconfig.json +19 -0
  23. package/templates/plugin/vitest.config.ts +10 -0
  24. package/templates/site/.github/workflows/pages.yml +56 -0
  25. package/templates/site/intro/lecture.json +187 -0
  26. package/templates/site/presmium.workspace.yaml +17 -0
  27. package/templates/site/site/home.json +43 -0
  28. package/templates/skills/presmium-animate/SKILL.md +50 -0
  29. package/templates/skills/presmium-animate/gallery/algorithms/lecture.json +5165 -0
  30. package/templates/skills/presmium-animate/gallery/algorithms/scenes/anime/binary-set.ts +2 -0
  31. package/templates/skills/presmium-animate/gallery/algorithms/scenes/anime/bubble-swap.ts +2 -0
  32. package/templates/skills/presmium-animate/gallery/algorithms/scenes/anime/graph-bfs.ts +2 -0
  33. package/templates/skills/presmium-animate/gallery/algorithms/scenes/anime/hash-scramble.ts +2 -0
  34. package/templates/skills/presmium-animate/gallery/algorithms/scenes/dc/code-diff.ts +2 -0
  35. package/templates/skills/presmium-animate/gallery/algorithms/scenes/dc/code-focus.ts +2 -0
  36. package/templates/skills/presmium-animate/gallery/algorithms/scenes/dc/code-morph.ts +2 -0
  37. package/templates/skills/presmium-animate/gallery/algorithms/scenes/dc/code-typing.ts +2 -0
  38. package/templates/skills/presmium-animate/gallery/algorithms/scenes/dc/decision-tree.ts +2 -0
  39. package/templates/skills/presmium-animate/gallery/algorithms/scenes/dc/terminal-run.ts +2 -0
  40. package/templates/skills/presmium-animate/gallery/algorithms/scenes/gsap/draw-svg.ts +2 -0
  41. package/templates/skills/presmium-animate/gallery/algorithms/scenes/gsap/keyframes.ts +2 -0
  42. package/templates/skills/presmium-animate/gallery/algorithms/scenes/gsap/merge.ts +2 -0
  43. package/templates/skills/presmium-animate/gallery/algorithms/scenes/gsap/nested.ts +2 -0
  44. package/templates/skills/presmium-animate/gallery/algorithms/scenes/gsap/swap-arc.ts +2 -0
  45. package/templates/skills/presmium-animate/gallery/algorithms/scenes/motion/packet.ts +2 -0
  46. package/templates/skills/presmium-animate/gallery/algorithms/scenes/motion/reorder.ts +2 -0
  47. package/templates/skills/presmium-animate/gallery/algorithms/scenes/motion/scan.ts +2 -0
  48. package/templates/skills/presmium-animate/gallery/algorithms/scenes/motion/spring-tree.ts +2 -0
  49. package/templates/skills/presmium-animate/gallery/algorithms/scenes/remotion/swap.ts +2 -0
  50. package/templates/skills/presmium-animate/gallery/algorithms/scenes/three/hanoi.ts +2 -0
  51. package/templates/skills/presmium-animate/gallery/anime/scenes/attention-heat.ts +49 -0
  52. package/templates/skills/presmium-animate/gallery/anime/scenes/ball-keyframes.ts +53 -0
  53. package/templates/skills/presmium-animate/gallery/anime/scenes/binary-set.ts +40 -0
  54. package/templates/skills/presmium-animate/gallery/anime/scenes/bubble-swap.ts +50 -0
  55. package/templates/skills/presmium-animate/gallery/anime/scenes/descent-canvas.ts +95 -0
  56. package/templates/skills/presmium-animate/gallery/anime/scenes/draw-curve.ts +40 -0
  57. package/templates/skills/presmium-animate/gallery/anime/scenes/draw-fill.ts +36 -0
  58. package/templates/skills/presmium-animate/gallery/anime/scenes/easing-lanes.ts +39 -0
  59. package/templates/skills/presmium-animate/gallery/anime/scenes/flip-cards.ts +25 -0
  60. package/templates/skills/presmium-animate/gallery/anime/scenes/graph-bfs.ts +48 -0
  61. package/templates/skills/presmium-animate/gallery/anime/scenes/grid-ripple.ts +33 -0
  62. package/templates/skills/presmium-animate/gallery/anime/scenes/hash-scramble.ts +51 -0
  63. package/templates/skills/presmium-animate/gallery/anime/scenes/kmeans-seeded.ts +62 -0
  64. package/templates/skills/presmium-animate/gallery/anime/scenes/nn-sync.ts +44 -0
  65. package/templates/skills/presmium-animate/gallery/anime/scenes/packet-path.ts +40 -0
  66. package/templates/skills/presmium-animate/gallery/anime/scenes/param-counter.ts +36 -0
  67. package/templates/skills/presmium-animate/gallery/anime/scenes/taylor-morph.ts +60 -0
  68. package/templates/skills/presmium-animate/gallery/anime/scenes/token-split.ts +29 -0
  69. package/templates/skills/presmium-animate/gallery/anime/scenes/wave-loop.ts +27 -0
  70. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/agent-cursor.ts +117 -0
  71. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/callout.ts +103 -0
  72. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/click-trail.ts +132 -0
  73. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/keyword-marks.ts +117 -0
  74. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/lib/backdrop.ts +142 -0
  75. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/lib/ink.ts +256 -0
  76. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/lib/pointer.ts +68 -0
  77. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/lib/time.ts +22 -0
  78. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/pen-annotate.ts +110 -0
  79. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/sketch-checklist.ts +94 -0
  80. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/sketch-flow.ts +68 -0
  81. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/speech-bubble.ts +74 -0
  82. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/spotlight.ts +77 -0
  83. package/templates/skills/presmium-animate/gallery/catalog/annotate-cursor/scenes/text-select.ts +99 -0
  84. package/templates/skills/presmium-animate/gallery/catalog/carry/scenes/one-dot.ts +255 -0
  85. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/chart-story.ts +168 -0
  86. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/code-diff.ts +76 -0
  87. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/code-focus.ts +100 -0
  88. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/code-morph.ts +106 -0
  89. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/code-typing.ts +79 -0
  90. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/decision-tree.ts +110 -0
  91. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/lib/code.ts +153 -0
  92. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/oscilloscope.ts +149 -0
  93. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/terminal-run.ts +83 -0
  94. package/templates/skills/presmium-animate/gallery/catalog/data-code/scenes/tile-map.ts +113 -0
  95. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/card-grid.ts +61 -0
  96. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/carousel.ts +87 -0
  97. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/checklist.ts +70 -0
  98. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/confetti.ts +68 -0
  99. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/focus-words.ts +36 -0
  100. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/hub-spokes.ts +89 -0
  101. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/lib/motion.ts +15 -0
  102. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/outline-callout.ts +79 -0
  103. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/pendulum-settle.ts +97 -0
  104. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/physical-exit.ts +79 -0
  105. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/stat-gauge.ts +76 -0
  106. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/stop-motion.ts +92 -0
  107. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/surround.ts +78 -0
  108. package/templates/skills/presmium-animate/gallery/catalog/motion-showcase/scenes/whiteboard-sketch.ts +128 -0
  109. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/ai-answer.ts +116 -0
  110. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/before-after.ts +66 -0
  111. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/chat-thread.ts +75 -0
  112. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/context-menu.ts +96 -0
  113. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/cursor-zoom.ts +73 -0
  114. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/device-frame.ts +68 -0
  115. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/device-splay.ts +48 -0
  116. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/drag-drop.ts +80 -0
  117. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/lib/ui.ts +131 -0
  118. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/modal-morph.ts +60 -0
  119. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/notification-stack.ts +66 -0
  120. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/onboarding-stepper.ts +96 -0
  121. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/screen-flow.ts +66 -0
  122. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/settings-toggle.ts +67 -0
  123. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/signup-form.ts +107 -0
  124. package/templates/skills/presmium-animate/gallery/catalog/product-ui/scenes/testimonial.ts +66 -0
  125. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/before-after.ts +158 -0
  126. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/figure-ring.ts +156 -0
  127. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/lib/figures.ts +146 -0
  128. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/lib/grain.ts +58 -0
  129. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/lib/images.ts +32 -0
  130. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/lib/overlay.ts +13 -0
  131. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/noise-to-marble.ts +180 -0
  132. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/paper-grain.ts +56 -0
  133. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/sample-sphere.ts +151 -0
  134. package/templates/skills/presmium-animate/gallery/catalog/shader-3d-bg/scenes/wave-interference.ts +131 -0
  135. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/camera-caption.ts +78 -0
  136. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/captions.ts +87 -0
  137. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/glyph-slam.ts +73 -0
  138. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/lib/text.ts +84 -0
  139. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/lower-third.ts +148 -0
  140. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/scramble-reveal.ts +86 -0
  141. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/slot-swap.ts +75 -0
  142. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/strike-replace.ts +78 -0
  143. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/text-match-cut.ts +73 -0
  144. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/text-reveal.ts +97 -0
  145. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/title-card.ts +60 -0
  146. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/versus-cards.ts +64 -0
  147. package/templates/skills/presmium-animate/gallery/catalog/text-captions/scenes/weight-wave.ts +55 -0
  148. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/dolly-zoom.ts +68 -0
  149. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/fade-through.ts +44 -0
  150. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/flip.ts +49 -0
  151. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/grid-wipe.ts +54 -0
  152. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/iris.ts +54 -0
  153. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/lib/stage.ts +90 -0
  154. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/match-cut.ts +68 -0
  155. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/pan-stations.ts +73 -0
  156. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/pull-back.ts +70 -0
  157. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/push-in.ts +40 -0
  158. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/rack-focus.ts +53 -0
  159. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/slide-wipe.ts +74 -0
  160. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/split-compare.ts +87 -0
  161. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/velocity-cut.ts +64 -0
  162. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/whip-pan.ts +59 -0
  163. package/templates/skills/presmium-animate/gallery/catalog/transitions-camera/scenes/zoom-through.ts +71 -0
  164. package/templates/skills/presmium-animate/gallery/craft/lecture.json +3238 -0
  165. package/templates/skills/presmium-animate/gallery/craft/scenes/anime/ball-keyframes.ts +2 -0
  166. package/templates/skills/presmium-animate/gallery/craft/scenes/anime/easing-lanes.ts +2 -0
  167. package/templates/skills/presmium-animate/gallery/craft/scenes/gsap/utils.ts +2 -0
  168. package/templates/skills/presmium-animate/gallery/craft/scenes/motion/cssvar.ts +2 -0
  169. package/templates/skills/presmium-animate/gallery/craft/scenes/motion/easings.ts +2 -0
  170. package/templates/skills/presmium-animate/gallery/craft/scenes/motion/spring-compare.ts +2 -0
  171. package/templates/skills/presmium-animate/gallery/craft/scenes/remotion/beam-prune.ts +2 -0
  172. package/templates/skills/presmium-animate/gallery/craft/scenes/remotion/easing.ts +2 -0
  173. package/templates/skills/presmium-animate/gallery/craft/scenes/remotion/freeze.ts +2 -0
  174. package/templates/skills/presmium-animate/gallery/craft/scenes/remotion/posterize.ts +2 -0
  175. package/templates/skills/presmium-animate/gallery/craft/scenes/remotion/spring-chain.ts +2 -0
  176. package/templates/skills/presmium-animate/gallery/craft/scenes/show/confetti.ts +2 -0
  177. package/templates/skills/presmium-animate/gallery/craft/scenes/show/physical-exit.ts +2 -0
  178. package/templates/skills/presmium-animate/gallery/craft/scenes/show/stop-motion.ts +2 -0
  179. package/templates/skills/presmium-animate/gallery/d3/scenes/axis-zoom.ts +46 -0
  180. package/templates/skills/presmium-animate/gallery/d3/scenes/bar-race.ts +66 -0
  181. package/templates/skills/presmium-animate/gallery/d3/scenes/chord.ts +48 -0
  182. package/templates/skills/presmium-animate/gallery/d3/scenes/contour-density.ts +32 -0
  183. package/templates/skills/presmium-animate/gallery/d3/scenes/data-join.ts +60 -0
  184. package/templates/skills/presmium-animate/gallery/d3/scenes/force-path.ts +71 -0
  185. package/templates/skills/presmium-animate/gallery/d3/scenes/globe.ts +58 -0
  186. package/templates/skills/presmium-animate/gallery/d3/scenes/heatmap-scales.ts +43 -0
  187. package/templates/skills/presmium-animate/gallery/d3/scenes/histogram.ts +47 -0
  188. package/templates/skills/presmium-animate/gallery/d3/scenes/kit/fields.ts +21 -0
  189. package/templates/skills/presmium-animate/gallery/d3/scenes/kit/stage.ts +35 -0
  190. package/templates/skills/presmium-animate/gallery/d3/scenes/line-draw.ts +49 -0
  191. package/templates/skills/presmium-animate/gallery/d3/scenes/pack-zoom.ts +37 -0
  192. package/templates/skills/presmium-animate/gallery/d3/scenes/pie-arcs.ts +44 -0
  193. package/templates/skills/presmium-animate/gallery/d3/scenes/quadtree-find.ts +36 -0
  194. package/templates/skills/presmium-animate/gallery/d3/scenes/stack-stream.ts +58 -0
  195. package/templates/skills/presmium-animate/gallery/d3/scenes/sunburst-zoom.ts +49 -0
  196. package/templates/skills/presmium-animate/gallery/d3/scenes/tree-morph.ts +79 -0
  197. package/templates/skills/presmium-animate/gallery/d3/scenes/treemap-tiling.ts +47 -0
  198. package/templates/skills/presmium-animate/gallery/d3/scenes/voronoi-lloyd.ts +38 -0
  199. package/templates/skills/presmium-animate/gallery/data/lecture.json +7795 -0
  200. package/templates/skills/presmium-animate/gallery/data/scenes/anime/param-counter.ts +2 -0
  201. package/templates/skills/presmium-animate/gallery/data/scenes/d3/axis-zoom.ts +2 -0
  202. package/templates/skills/presmium-animate/gallery/data/scenes/d3/bar-race.ts +2 -0
  203. package/templates/skills/presmium-animate/gallery/data/scenes/d3/chord.ts +2 -0
  204. package/templates/skills/presmium-animate/gallery/data/scenes/d3/contour-density.ts +2 -0
  205. package/templates/skills/presmium-animate/gallery/data/scenes/d3/data-join.ts +2 -0
  206. package/templates/skills/presmium-animate/gallery/data/scenes/d3/force-path.ts +2 -0
  207. package/templates/skills/presmium-animate/gallery/data/scenes/d3/globe.ts +2 -0
  208. package/templates/skills/presmium-animate/gallery/data/scenes/d3/heatmap-scales.ts +2 -0
  209. package/templates/skills/presmium-animate/gallery/data/scenes/d3/histogram.ts +2 -0
  210. package/templates/skills/presmium-animate/gallery/data/scenes/d3/line-draw.ts +2 -0
  211. package/templates/skills/presmium-animate/gallery/data/scenes/d3/pack-zoom.ts +2 -0
  212. package/templates/skills/presmium-animate/gallery/data/scenes/d3/pie-arcs.ts +2 -0
  213. package/templates/skills/presmium-animate/gallery/data/scenes/d3/quadtree-find.ts +2 -0
  214. package/templates/skills/presmium-animate/gallery/data/scenes/d3/stack-stream.ts +2 -0
  215. package/templates/skills/presmium-animate/gallery/data/scenes/d3/sunburst-zoom.ts +2 -0
  216. package/templates/skills/presmium-animate/gallery/data/scenes/d3/tree-morph.ts +2 -0
  217. package/templates/skills/presmium-animate/gallery/data/scenes/d3/treemap-tiling.ts +2 -0
  218. package/templates/skills/presmium-animate/gallery/data/scenes/d3/voronoi-lloyd.ts +2 -0
  219. package/templates/skills/presmium-animate/gallery/data/scenes/dc/chart-story.ts +2 -0
  220. package/templates/skills/presmium-animate/gallery/data/scenes/dc/oscilloscope.ts +2 -0
  221. package/templates/skills/presmium-animate/gallery/data/scenes/dc/tile-map.ts +2 -0
  222. package/templates/skills/presmium-animate/gallery/data/scenes/gsap/counter.ts +2 -0
  223. package/templates/skills/presmium-animate/gallery/data/scenes/motion/bars.ts +2 -0
  224. package/templates/skills/presmium-animate/gallery/data/scenes/motion/counter.ts +2 -0
  225. package/templates/skills/presmium-animate/gallery/data/scenes/motion/ring.ts +2 -0
  226. package/templates/skills/presmium-animate/gallery/data/scenes/remotion/bar-chart.ts +2 -0
  227. package/templates/skills/presmium-animate/gallery/data/scenes/remotion/counter.ts +2 -0
  228. package/templates/skills/presmium-animate/gallery/data/scenes/show/stat-gauge.ts +2 -0
  229. package/templates/skills/presmium-animate/gallery/emphasis/lecture.json +4266 -0
  230. package/templates/skills/presmium-animate/gallery/emphasis/scenes/gsap/emphasis.ts +2 -0
  231. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/callout.ts +2 -0
  232. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/keyword-marks.ts +2 -0
  233. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/pen-annotate.ts +2 -0
  234. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/sketch-checklist.ts +2 -0
  235. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/sketch-flow.ts +2 -0
  236. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/speech-bubble.ts +2 -0
  237. package/templates/skills/presmium-animate/gallery/emphasis/scenes/mark/spotlight.ts +2 -0
  238. package/templates/skills/presmium-animate/gallery/emphasis/scenes/motion/blur.ts +2 -0
  239. package/templates/skills/presmium-animate/gallery/emphasis/scenes/motion/emphasis.ts +2 -0
  240. package/templates/skills/presmium-animate/gallery/emphasis/scenes/motion/pulse.ts +2 -0
  241. package/templates/skills/presmium-animate/gallery/emphasis/scenes/remotion/loop-pulse.ts +2 -0
  242. package/templates/skills/presmium-animate/gallery/emphasis/scenes/show/outline-callout.ts +2 -0
  243. package/templates/skills/presmium-animate/gallery/emphasis/scenes/show/whiteboard-sketch.ts +2 -0
  244. package/templates/skills/presmium-animate/gallery/films/lecture.json +5352 -0
  245. package/templates/skills/presmium-animate/gallery/films/scenes/10s/data-story.ts +2 -0
  246. package/templates/skills/presmium-animate/gallery/films/scenes/10s/method.ts +2 -0
  247. package/templates/skills/presmium-animate/gallery/films/scenes/10s/problem-solution.ts +2 -0
  248. package/templates/skills/presmium-animate/gallery/films/scenes/1s/swap.ts +2 -0
  249. package/templates/skills/presmium-animate/gallery/films/scenes/5s/attention.ts +2 -0
  250. package/templates/skills/presmium-animate/gallery/films/scenes/5s/feature-click.ts +2 -0
  251. package/templates/skills/presmium-animate/gallery/films/scenes/5s/key-result.ts +2 -0
  252. package/templates/skills/presmium-animate/gallery/films/scenes/5s/kinetic.ts +2 -0
  253. package/templates/skills/presmium-animate/gallery/films/scenes/5s/logo-sting.ts +2 -0
  254. package/templates/skills/presmium-animate/gallery/films/scenes/5s/turntable.ts +2 -0
  255. package/templates/skills/presmium-animate/gallery/films/scenes/film/cta.ts +2 -0
  256. package/templates/skills/presmium-animate/gallery/films/scenes/film/rnn-chain.ts +2 -0
  257. package/templates/skills/presmium-animate/gallery/films/scenes/film/title-card.ts +2 -0
  258. package/templates/skills/presmium-animate/gallery/films/scenes/fx/anime/submit-burst.ts +2 -0
  259. package/templates/skills/presmium-animate/gallery/films/scenes/fx/gsap/comet-stroke.ts +2 -0
  260. package/templates/skills/presmium-animate/gallery/films/scenes/fx/gsap/morph-anticipation.ts +2 -0
  261. package/templates/skills/presmium-animate/gallery/films/scenes/fx/gsap/odometer.ts +2 -0
  262. package/templates/skills/presmium-animate/gallery/gsap/scenes/counter.ts +35 -0
  263. package/templates/skills/presmium-animate/gallery/gsap/scenes/css-vars.ts +48 -0
  264. package/templates/skills/presmium-animate/gallery/gsap/scenes/draw-svg.ts +47 -0
  265. package/templates/skills/presmium-animate/gallery/gsap/scenes/emphasis.ts +39 -0
  266. package/templates/skills/presmium-animate/gallery/gsap/scenes/flip-3d.ts +32 -0
  267. package/templates/skills/presmium-animate/gallery/gsap/scenes/flip-fit.ts +40 -0
  268. package/templates/skills/presmium-animate/gallery/gsap/scenes/keyframes.ts +48 -0
  269. package/templates/skills/presmium-animate/gallery/gsap/scenes/merge.ts +35 -0
  270. package/templates/skills/presmium-animate/gallery/gsap/scenes/morph-svg.ts +57 -0
  271. package/templates/skills/presmium-animate/gallery/gsap/scenes/motion-path.ts +43 -0
  272. package/templates/skills/presmium-animate/gallery/gsap/scenes/nested.ts +49 -0
  273. package/templates/skills/presmium-animate/gallery/gsap/scenes/physics.ts +39 -0
  274. package/templates/skills/presmium-animate/gallery/gsap/scenes/seeded.ts +61 -0
  275. package/templates/skills/presmium-animate/gallery/gsap/scenes/split-text.ts +32 -0
  276. package/templates/skills/presmium-animate/gallery/gsap/scenes/stagger-grid.ts +26 -0
  277. package/templates/skills/presmium-animate/gallery/gsap/scenes/swap-arc.ts +29 -0
  278. package/templates/skills/presmium-animate/gallery/gsap/scenes/text-plugin.ts +34 -0
  279. package/templates/skills/presmium-animate/gallery/gsap/scenes/utils.ts +36 -0
  280. package/templates/skills/presmium-animate/gallery/lengths/lecture.json +15855 -0
  281. package/templates/skills/presmium-animate/gallery/lengths/scenes/10s/data-story.ts +82 -0
  282. package/templates/skills/presmium-animate/gallery/lengths/scenes/10s/fourier.ts +226 -0
  283. package/templates/skills/presmium-animate/gallery/lengths/scenes/10s/method.ts +67 -0
  284. package/templates/skills/presmium-animate/gallery/lengths/scenes/10s/problem-solution.ts +74 -0
  285. package/templates/skills/presmium-animate/gallery/lengths/scenes/1s/enter.ts +16 -0
  286. package/templates/skills/presmium-animate/gallery/lengths/scenes/1s/loop.ts +21 -0
  287. package/templates/skills/presmium-animate/gallery/lengths/scenes/1s/replace.ts +21 -0
  288. package/templates/skills/presmium-animate/gallery/lengths/scenes/1s/swap.ts +21 -0
  289. package/templates/skills/presmium-animate/gallery/lengths/scenes/1s/type.ts +19 -0
  290. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/attention.ts +49 -0
  291. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/feature-click.ts +67 -0
  292. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/key-result.ts +70 -0
  293. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/kinetic.ts +36 -0
  294. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/leaderboard.ts +141 -0
  295. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/logo-sting.ts +35 -0
  296. package/templates/skills/presmium-animate/gallery/lengths/scenes/5s/turntable.ts +82 -0
  297. package/templates/skills/presmium-animate/gallery/lengths/scenes/film/cta.ts +34 -0
  298. package/templates/skills/presmium-animate/gallery/lengths/scenes/film/rnn-chain.ts +65 -0
  299. package/templates/skills/presmium-animate/gallery/lengths/scenes/film/title-card.ts +36 -0
  300. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/anime/gooey-split.ts +64 -0
  301. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/anime/neon-trace.ts +65 -0
  302. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/anime/shockwave-lens.ts +56 -0
  303. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/anime/submit-burst.ts +93 -0
  304. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/d3/bend-into-donut.ts +92 -0
  305. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/d3/comet-draw.ts +100 -0
  306. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/d3/frontier-push.ts +106 -0
  307. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/d3/threshold-ignite.ts +94 -0
  308. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/gsap/comet-stroke.ts +88 -0
  309. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/gsap/hinge-lines.ts +39 -0
  310. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/gsap/morph-anticipation.ts +58 -0
  311. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/gsap/odometer.ts +87 -0
  312. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/motion/border-beam.ts +90 -0
  313. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/motion/emphasize-marker.ts +43 -0
  314. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/motion/exploded-layers.ts +103 -0
  315. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/motion/tilt-glare.ts +78 -0
  316. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/remotion/device-hero.ts +63 -0
  317. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/remotion/impact-slam.ts +72 -0
  318. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/remotion/pop-burst.ts +74 -0
  319. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/remotion/whip-pan.ts +49 -0
  320. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/three/ai-orb.ts +137 -0
  321. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/three/glass-card.ts +182 -0
  322. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/three/neural-signal.ts +263 -0
  323. package/templates/skills/presmium-animate/gallery/lengths/scenes/fx/three/particle-logo.ts +225 -0
  324. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/anime-fx.ts +45 -0
  325. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/atoms.ts +104 -0
  326. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/d3-fx.ts +103 -0
  327. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fourier.ts +137 -0
  328. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/frame.ts +45 -0
  329. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/camera.ts +94 -0
  330. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/defs.ts +25 -0
  331. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/ids.ts +8 -0
  332. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/moves.ts +130 -0
  333. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/noise.ts +18 -0
  334. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/paths.ts +55 -0
  335. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/random.ts +36 -0
  336. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/sample.ts +58 -0
  337. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/theme.ts +19 -0
  338. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/time.ts +111 -0
  339. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/fx/trail.ts +10 -0
  340. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/icons.ts +22 -0
  341. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/motion-fx.ts +53 -0
  342. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/remotion-fx.ts +60 -0
  343. package/templates/skills/presmium-animate/gallery/lengths/scenes/kit/three-fx.ts +209 -0
  344. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/anthropic.svg +1 -0
  345. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/claude-color.svg +1 -0
  346. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/deepseek-color.svg +1 -0
  347. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/google-color.svg +1 -0
  348. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/kimi-color.svg +1 -0
  349. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/meta-color.svg +1 -0
  350. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/openai.svg +1 -0
  351. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/qwen-color.svg +1 -0
  352. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/stepfun.svg +1 -0
  353. package/templates/skills/presmium-animate/gallery/lengths/scenes/logos/zai.svg +1 -0
  354. package/templates/skills/presmium-animate/gallery/math-ml/lecture.json +7220 -0
  355. package/templates/skills/presmium-animate/gallery/math-ml/scenes/anime/attention-heat.ts +2 -0
  356. package/templates/skills/presmium-animate/gallery/math-ml/scenes/anime/descent-canvas.ts +2 -0
  357. package/templates/skills/presmium-animate/gallery/math-ml/scenes/anime/kmeans-seeded.ts +2 -0
  358. package/templates/skills/presmium-animate/gallery/math-ml/scenes/anime/nn-sync.ts +2 -0
  359. package/templates/skills/presmium-animate/gallery/math-ml/scenes/anime/taylor-morph.ts +2 -0
  360. package/templates/skills/presmium-animate/gallery/math-ml/scenes/anime/wave-loop.ts +2 -0
  361. package/templates/skills/presmium-animate/gallery/math-ml/scenes/fx/wave-interference.ts +2 -0
  362. package/templates/skills/presmium-animate/gallery/math-ml/scenes/gsap/css-vars.ts +2 -0
  363. package/templates/skills/presmium-animate/gallery/math-ml/scenes/gsap/morph-svg.ts +2 -0
  364. package/templates/skills/presmium-animate/gallery/math-ml/scenes/gsap/physics.ts +2 -0
  365. package/templates/skills/presmium-animate/gallery/math-ml/scenes/gsap/seeded.ts +2 -0
  366. package/templates/skills/presmium-animate/gallery/math-ml/scenes/motion/canvas.ts +2 -0
  367. package/templates/skills/presmium-animate/gallery/math-ml/scenes/motion/draw.ts +2 -0
  368. package/templates/skills/presmium-animate/gallery/math-ml/scenes/motion/heatmap.ts +2 -0
  369. package/templates/skills/presmium-animate/gallery/math-ml/scenes/motion/matrix.ts +2 -0
  370. package/templates/skills/presmium-animate/gallery/math-ml/scenes/motion/morph.ts +2 -0
  371. package/templates/skills/presmium-animate/gallery/math-ml/scenes/remotion/monte-carlo.ts +2 -0
  372. package/templates/skills/presmium-animate/gallery/math-ml/scenes/remotion/wobble.ts +2 -0
  373. package/templates/skills/presmium-animate/gallery/math-ml/scenes/show/pendulum-settle.ts +2 -0
  374. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/clusters.ts +2 -0
  375. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/descent.ts +2 -0
  376. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/hull.ts +2 -0
  377. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/lathe.ts +2 -0
  378. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/lorenz.ts +2 -0
  379. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/matrix.ts +2 -0
  380. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/projection.ts +2 -0
  381. package/templates/skills/presmium-animate/gallery/math-ml/scenes/three/surfaces.ts +2 -0
  382. package/templates/skills/presmium-animate/gallery/motion/scenes/bars.ts +59 -0
  383. package/templates/skills/presmium-animate/gallery/motion/scenes/blur.ts +41 -0
  384. package/templates/skills/presmium-animate/gallery/motion/scenes/canvas.ts +92 -0
  385. package/templates/skills/presmium-animate/gallery/motion/scenes/counter.ts +44 -0
  386. package/templates/skills/presmium-animate/gallery/motion/scenes/cssvar.ts +35 -0
  387. package/templates/skills/presmium-animate/gallery/motion/scenes/draw.ts +58 -0
  388. package/templates/skills/presmium-animate/gallery/motion/scenes/easings.ts +41 -0
  389. package/templates/skills/presmium-animate/gallery/motion/scenes/emphasis.ts +41 -0
  390. package/templates/skills/presmium-animate/gallery/motion/scenes/flip.ts +37 -0
  391. package/templates/skills/presmium-animate/gallery/motion/scenes/flow.ts +50 -0
  392. package/templates/skills/presmium-animate/gallery/motion/scenes/heatmap.ts +67 -0
  393. package/templates/skills/presmium-animate/gallery/motion/scenes/labels.ts +38 -0
  394. package/templates/skills/presmium-animate/gallery/motion/scenes/matrix.ts +63 -0
  395. package/templates/skills/presmium-animate/gallery/motion/scenes/morph.ts +56 -0
  396. package/templates/skills/presmium-animate/gallery/motion/scenes/packet.ts +47 -0
  397. package/templates/skills/presmium-animate/gallery/motion/scenes/pulse.ts +36 -0
  398. package/templates/skills/presmium-animate/gallery/motion/scenes/reorder.ts +44 -0
  399. package/templates/skills/presmium-animate/gallery/motion/scenes/ring.ts +41 -0
  400. package/templates/skills/presmium-animate/gallery/motion/scenes/ripple.ts +41 -0
  401. package/templates/skills/presmium-animate/gallery/motion/scenes/scan.ts +67 -0
  402. package/templates/skills/presmium-animate/gallery/motion/scenes/spring-compare.ts +37 -0
  403. package/templates/skills/presmium-animate/gallery/motion/scenes/spring-tree.ts +38 -0
  404. package/templates/skills/presmium-animate/gallery/motion/scenes/wipe.ts +57 -0
  405. package/templates/skills/presmium-animate/gallery/package.json +19 -0
  406. package/templates/skills/presmium-animate/gallery/paths-3d/lecture.json +5030 -0
  407. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/anime/draw-curve.ts +2 -0
  408. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/anime/packet-path.ts +2 -0
  409. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/fx/before-after.ts +2 -0
  410. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/fx/figure-ring.ts +2 -0
  411. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/fx/noise-to-marble.ts +2 -0
  412. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/fx/paper-grain.ts +2 -0
  413. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/fx/sample-sphere.ts +2 -0
  414. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/gsap/motion-path.ts +2 -0
  415. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/motion/flow.ts +2 -0
  416. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/remotion/path-draw.ts +2 -0
  417. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/three/galaxy.ts +2 -0
  418. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/three/materials.ts +2 -0
  419. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/three/route.ts +2 -0
  420. package/templates/skills/presmium-animate/gallery/paths-3d/scenes/three/shadows.ts +2 -0
  421. package/templates/skills/presmium-animate/gallery/product/lecture.json +8530 -0
  422. package/templates/skills/presmium-animate/gallery/product/public/screen-lesson.webp +0 -0
  423. package/templates/skills/presmium-animate/gallery/product/scenes/mark/agent-cursor.ts +2 -0
  424. package/templates/skills/presmium-animate/gallery/product/scenes/mark/click-trail.ts +2 -0
  425. package/templates/skills/presmium-animate/gallery/product/scenes/mark/text-select.ts +2 -0
  426. package/templates/skills/presmium-animate/gallery/product/scenes/ui/ai-answer.ts +2 -0
  427. package/templates/skills/presmium-animate/gallery/product/scenes/ui/before-after.ts +2 -0
  428. package/templates/skills/presmium-animate/gallery/product/scenes/ui/chat-thread.ts +2 -0
  429. package/templates/skills/presmium-animate/gallery/product/scenes/ui/context-menu.ts +2 -0
  430. package/templates/skills/presmium-animate/gallery/product/scenes/ui/cursor-zoom.ts +2 -0
  431. package/templates/skills/presmium-animate/gallery/product/scenes/ui/device-frame.ts +2 -0
  432. package/templates/skills/presmium-animate/gallery/product/scenes/ui/device-splay.ts +2 -0
  433. package/templates/skills/presmium-animate/gallery/product/scenes/ui/drag-drop.ts +2 -0
  434. package/templates/skills/presmium-animate/gallery/product/scenes/ui/modal-morph.ts +2 -0
  435. package/templates/skills/presmium-animate/gallery/product/scenes/ui/notification-stack.ts +2 -0
  436. package/templates/skills/presmium-animate/gallery/product/scenes/ui/onboarding-stepper.ts +2 -0
  437. package/templates/skills/presmium-animate/gallery/product/scenes/ui/screen-flow.ts +2 -0
  438. package/templates/skills/presmium-animate/gallery/product/scenes/ui/settings-toggle.ts +2 -0
  439. package/templates/skills/presmium-animate/gallery/product/scenes/ui/signup-form.ts +2 -0
  440. package/templates/skills/presmium-animate/gallery/product/scenes/ui/testimonial.ts +2 -0
  441. package/templates/skills/presmium-animate/gallery/remotion/scenes/bar-chart.ts +39 -0
  442. package/templates/skills/presmium-animate/gallery/remotion/scenes/beam-prune.ts +37 -0
  443. package/templates/skills/presmium-animate/gallery/remotion/scenes/counter.ts +31 -0
  444. package/templates/skills/presmium-animate/gallery/remotion/scenes/easing.ts +45 -0
  445. package/templates/skills/presmium-animate/gallery/remotion/scenes/freeze.ts +46 -0
  446. package/templates/skills/presmium-animate/gallery/remotion/scenes/kinetic-type.ts +32 -0
  447. package/templates/skills/presmium-animate/gallery/remotion/scenes/loop-pulse.ts +44 -0
  448. package/templates/skills/presmium-animate/gallery/remotion/scenes/lower-third.ts +34 -0
  449. package/templates/skills/presmium-animate/gallery/remotion/scenes/monte-carlo.ts +36 -0
  450. package/templates/skills/presmium-animate/gallery/remotion/scenes/path-draw.ts +43 -0
  451. package/templates/skills/presmium-animate/gallery/remotion/scenes/posterize.ts +36 -0
  452. package/templates/skills/presmium-animate/gallery/remotion/scenes/sequence-steps.ts +35 -0
  453. package/templates/skills/presmium-animate/gallery/remotion/scenes/series-transition.ts +46 -0
  454. package/templates/skills/presmium-animate/gallery/remotion/scenes/spring-chain.ts +35 -0
  455. package/templates/skills/presmium-animate/gallery/remotion/scenes/spring-pop.ts +37 -0
  456. package/templates/skills/presmium-animate/gallery/remotion/scenes/swap.ts +37 -0
  457. package/templates/skills/presmium-animate/gallery/remotion/scenes/typewriter.ts +40 -0
  458. package/templates/skills/presmium-animate/gallery/remotion/scenes/wipe.ts +32 -0
  459. package/templates/skills/presmium-animate/gallery/remotion/scenes/wobble.ts +39 -0
  460. package/templates/skills/presmium-animate/gallery/remotion/scenes/word-highlight.ts +34 -0
  461. package/templates/skills/presmium-animate/gallery/story/lecture.json +1111 -0
  462. package/templates/skills/presmium-animate/gallery/story/scenes/data/flow-matching.json +1 -0
  463. package/templates/skills/presmium-animate/gallery/story/scenes/data/flow-matching.py +197 -0
  464. package/templates/skills/presmium-animate/gallery/story/scenes/flow-matching.ts +702 -0
  465. package/templates/skills/presmium-animate/gallery/structure/lecture.json +4302 -0
  466. package/templates/skills/presmium-animate/gallery/structure/scenes/anime/draw-fill.ts +2 -0
  467. package/templates/skills/presmium-animate/gallery/structure/scenes/anime/flip-cards.ts +2 -0
  468. package/templates/skills/presmium-animate/gallery/structure/scenes/anime/grid-ripple.ts +2 -0
  469. package/templates/skills/presmium-animate/gallery/structure/scenes/gsap/flip-3d.ts +2 -0
  470. package/templates/skills/presmium-animate/gallery/structure/scenes/gsap/flip-fit.ts +2 -0
  471. package/templates/skills/presmium-animate/gallery/structure/scenes/gsap/stagger-grid.ts +2 -0
  472. package/templates/skills/presmium-animate/gallery/structure/scenes/motion/flip.ts +2 -0
  473. package/templates/skills/presmium-animate/gallery/structure/scenes/motion/labels.ts +2 -0
  474. package/templates/skills/presmium-animate/gallery/structure/scenes/motion/ripple.ts +2 -0
  475. package/templates/skills/presmium-animate/gallery/structure/scenes/remotion/sequence-steps.ts +2 -0
  476. package/templates/skills/presmium-animate/gallery/structure/scenes/remotion/spring-pop.ts +2 -0
  477. package/templates/skills/presmium-animate/gallery/structure/scenes/show/card-grid.ts +2 -0
  478. package/templates/skills/presmium-animate/gallery/structure/scenes/show/carousel.ts +2 -0
  479. package/templates/skills/presmium-animate/gallery/structure/scenes/show/checklist.ts +2 -0
  480. package/templates/skills/presmium-animate/gallery/structure/scenes/show/hub-spokes.ts +2 -0
  481. package/templates/skills/presmium-animate/gallery/structure/scenes/show/surround.ts +2 -0
  482. package/templates/skills/presmium-animate/gallery/text/lecture.json +5934 -0
  483. package/templates/skills/presmium-animate/gallery/text/scenes/anime/token-split.ts +2 -0
  484. package/templates/skills/presmium-animate/gallery/text/scenes/gsap/split-text.ts +2 -0
  485. package/templates/skills/presmium-animate/gallery/text/scenes/gsap/text-plugin.ts +2 -0
  486. package/templates/skills/presmium-animate/gallery/text/scenes/remotion/kinetic-type.ts +2 -0
  487. package/templates/skills/presmium-animate/gallery/text/scenes/remotion/lower-third.ts +2 -0
  488. package/templates/skills/presmium-animate/gallery/text/scenes/remotion/typewriter.ts +2 -0
  489. package/templates/skills/presmium-animate/gallery/text/scenes/remotion/word-highlight.ts +2 -0
  490. package/templates/skills/presmium-animate/gallery/text/scenes/show/focus-words.ts +2 -0
  491. package/templates/skills/presmium-animate/gallery/text/scenes/tx/camera-caption.ts +2 -0
  492. package/templates/skills/presmium-animate/gallery/text/scenes/tx/captions.ts +2 -0
  493. package/templates/skills/presmium-animate/gallery/text/scenes/tx/glyph-slam.ts +2 -0
  494. package/templates/skills/presmium-animate/gallery/text/scenes/tx/lower-third.ts +2 -0
  495. package/templates/skills/presmium-animate/gallery/text/scenes/tx/scramble-reveal.ts +2 -0
  496. package/templates/skills/presmium-animate/gallery/text/scenes/tx/slot-swap.ts +2 -0
  497. package/templates/skills/presmium-animate/gallery/text/scenes/tx/strike-replace.ts +2 -0
  498. package/templates/skills/presmium-animate/gallery/text/scenes/tx/text-match-cut.ts +2 -0
  499. package/templates/skills/presmium-animate/gallery/text/scenes/tx/text-reveal.ts +2 -0
  500. package/templates/skills/presmium-animate/gallery/text/scenes/tx/title-card.ts +2 -0
  501. package/templates/skills/presmium-animate/gallery/text/scenes/tx/versus-cards.ts +2 -0
  502. package/templates/skills/presmium-animate/gallery/text/scenes/tx/weight-wave.ts +2 -0
  503. package/templates/skills/presmium-animate/gallery/three/scenes/clusters.ts +104 -0
  504. package/templates/skills/presmium-animate/gallery/three/scenes/descent.ts +111 -0
  505. package/templates/skills/presmium-animate/gallery/three/scenes/galaxy.ts +110 -0
  506. package/templates/skills/presmium-animate/gallery/three/scenes/hanoi.ts +136 -0
  507. package/templates/skills/presmium-animate/gallery/three/scenes/hull.ts +87 -0
  508. package/templates/skills/presmium-animate/gallery/three/scenes/lathe.ts +101 -0
  509. package/templates/skills/presmium-animate/gallery/three/scenes/lorenz.ts +109 -0
  510. package/templates/skills/presmium-animate/gallery/three/scenes/materials.ts +100 -0
  511. package/templates/skills/presmium-animate/gallery/three/scenes/matrix.ts +115 -0
  512. package/templates/skills/presmium-animate/gallery/three/scenes/projection.ts +108 -0
  513. package/templates/skills/presmium-animate/gallery/three/scenes/route.ts +102 -0
  514. package/templates/skills/presmium-animate/gallery/three/scenes/shadows.ts +92 -0
  515. package/templates/skills/presmium-animate/gallery/three/scenes/surfaces.ts +87 -0
  516. package/templates/skills/presmium-animate/gallery/timeline/lecture.json +2409 -0
  517. package/templates/skills/presmium-animate/gallery/timeline/scenes/bubble.ts +38 -0
  518. package/templates/skills/presmium-animate/gallery/timeline/scenes/steps.ts +10 -0
  519. package/templates/skills/presmium-animate/gallery/transitions/lecture.json +8147 -0
  520. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/dolly-zoom.ts +2 -0
  521. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/fade-through.ts +2 -0
  522. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/flip.ts +2 -0
  523. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/grid-wipe.ts +2 -0
  524. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/iris.ts +2 -0
  525. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/match-cut.ts +2 -0
  526. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/pan-stations.ts +2 -0
  527. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/pull-back.ts +2 -0
  528. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/push-in.ts +2 -0
  529. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/rack-focus.ts +2 -0
  530. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/slide-wipe.ts +2 -0
  531. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/split-compare.ts +2 -0
  532. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/velocity-cut.ts +2 -0
  533. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/whip-pan.ts +2 -0
  534. package/templates/skills/presmium-animate/gallery/transitions/scenes/cam/zoom-through.ts +2 -0
  535. package/templates/skills/presmium-animate/gallery/transitions/scenes/carry/one-dot.ts +2 -0
  536. package/templates/skills/presmium-animate/gallery/transitions/scenes/motion/wipe.ts +2 -0
  537. package/templates/skills/presmium-animate/gallery/transitions/scenes/remotion/series-transition.ts +2 -0
  538. package/templates/skills/presmium-animate/gallery/transitions/scenes/remotion/wipe.ts +2 -0
  539. package/templates/skills/presmium-animate/references/lengths.md +193 -0
  540. package/templates/skills/presmium-animate/references/libraries.md +332 -0
  541. package/templates/skills/presmium-animate/references/procedural.md +99 -0
  542. package/templates/skills/presmium-animate/references/scenarios.md +159 -0
  543. package/templates/skills/presmium-animate/references/story.md +231 -0
  544. package/templates/skills/presmium-animate/references/storyboards.md +607 -0
  545. package/templates/skills/presmium-animate/references/timeline.md +11 -0
  546. package/templates/skills/presmium-author/SKILL.md +46 -0
  547. package/templates/skills/presmium-author/references/assistance.md +33 -0
  548. package/templates/skills/presmium-author/references/code.md +23 -0
  549. package/templates/skills/presmium-author/references/document.md +21 -0
  550. package/templates/skills/presmium-author/references/publishing.md +55 -0
  551. package/templates/skills/presmium-author/references/writing.md +13 -0
  552. package/templates/skills/presmium-develop/SKILL.md +41 -0
  553. package/templates/skills/presmium-develop/references/plugin.md +476 -0
  554. package/templates/skills/presmium-develop/references/testing.md +131 -0
  555. package/templates/skills/presmium-present/SKILL.md +35 -0
  556. package/templates/skills/presmium-present/references/classroom.md +64 -0
  557. package/templates/skills/presmium-present/references/delivery.md +122 -0
  558. package/templates/skills/presmium-present/references/lecture.md +74 -0
  559. package/templates/workspace/gitignore +14 -0
  560. package/templates/workspace/pnpm-workspace.yaml +10 -0
  561. package/templates/workspace/presmium.workspace.yaml +15 -0
package/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/README.md CHANGED
@@ -1,3 +1,48 @@
1
- # Temporary Holding Version
1
+ # create-presmium
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Starts a new [Presmium](https://github.com/Lincyaw/presmium) project: a lecture, a workspace, a themed site or a plugin. `presmium new` (from `pnpm add -g @lincyaw/presmium`) runs it; so does `pnpm create presmium`.
4
+
5
+ ```sh
6
+ presmium new
7
+ presmium new my-lecture --type lecture --title "Tokenization"
8
+ presmium new my-course --type workspace --title "Data structures"
9
+ presmium new my-site --type site --theme course --title "My course"
10
+ presmium new presmium-plugin-greeting --type plugin --name presmium-plugin-greeting
11
+ ```
12
+
13
+ Without arguments it asks for the kind of project, the directory and the title (or, for a plugin, the package name).
14
+
15
+ | Option | What |
16
+ |---|---|
17
+ | `--type <kind>` | `lecture` (one document), `workspace` (documents previewed with `presmium serve`), `site` (a themed workspace with a homepage and GitHub Pages workflow) or `plugin` |
18
+ | `--theme <name>` | For `site`: `course` (default), `docs` or `showcase` |
19
+ | `--title <text>` | The lecture's or the workspace's title (default: the directory's name) |
20
+ | `--name <name>` | The plugin's package name (default: the directory's name) |
21
+ | `--no-git` | Do not run `git init` |
22
+ | `-h`, `--help` | Show the help |
23
+
24
+ - A lecture: `lecture.json`; `presmium dev`, `presmium check`, `presmium build`.
25
+ - A workspace: `presmium.workspace.yaml` and a first document in `intro/`; `presmium serve`.
26
+ - A site: `presmium.workspace.yaml`, an independent homepage in `site/home.json`, a teaching document in `intro/lecture.json`, and `.github/workflows/pages.yml`; `pnpm install`, `pnpm serve`, `pnpm build`.
27
+ - A plugin: a directive, a React component shown in the web page and the slides, a server route, text in Chinese and English, an example document and integration tests; `pnpm install`, `pnpm test`, `pnpm dev`.
28
+
29
+ Lectures, workspaces and sites list `presmium` at create-presmium's own version as a dev dependency, so `pnpm install` pins it; without it the global `presmium` builds them. Each project gets an `AGENTS.md` (`CLAUDE.md` links to it) and copies of the Presmium skills for coding agents in `.agents/skills`. The text of the questions and of the new files follows the system's language (Chinese or English).
30
+
31
+ ## Themed site
32
+
33
+ ```sh
34
+ presmium new my-site --type site --theme showcase --title 'My work'
35
+ cd my-site
36
+ pnpm install
37
+ pnpm serve
38
+ ```
39
+
40
+ Edit `site/home.json` to design the homepage and `intro/lecture.json` for the first teaching document. `site.landing.source` selects the homepage file; homepage content has its own structure, while teaching documents retain `lecture.json` as their sole content authority. Change `site.theme` and `site.params` in `presmium.workspace.yaml` to personalize the site. `pnpm build` exports `dist/web/`.
41
+
42
+ For your own HTML, CSS and JavaScript, replace the landing configuration with `site.landing: { template: './site/home.html' }`. The HTML entry and its local assets are bundled for static hosting; `script#presmium-site-data` provides the site's public document links. Refresh the homepage to rebuild that template during `pnpm serve`; template hot updates are not provided.
43
+
44
+ Push the project to a GitHub repository, select **GitHub Actions** in **Settings → Pages → Build and deployment → Source**, then run the generated Pages workflow or push to its configured branch. It reads the repository's Pages base path, builds the site and deploys `dist/web/`. The build remains an ordinary static site that can be hosted elsewhere.
45
+
46
+ See the [site theme guide](https://github.com/Lincyaw/presmium/blob/main/docs/site-themes.md) for the three presets, supported parameters and page layouts.
47
+
48
+ License: Apache-2.0.
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env node
2
+ import { createJiti } from 'jiti'
3
+
4
+ const jiti = createJiti(import.meta.url)
5
+ const { main } = await jiti.import('../src/cli.ts')
6
+ process.exitCode = await main(process.argv.slice(2))
package/package.json CHANGED
@@ -1,6 +1,54 @@
1
1
  {
2
2
  "name": "create-presmium",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
3
+ "version": "1.0.0-rc.1",
4
+ "description": "presmium new, or pnpm create presmium: a new Presmium lecture, workspace or plugin",
5
+ "license": "Apache-2.0",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+https://github.com/Lincyaw/presmium.git",
9
+ "directory": "packages/create-presmium"
10
+ },
11
+ "homepage": "https://github.com/Lincyaw/presmium/tree/main/packages/create-presmium#readme",
12
+ "bugs": "https://github.com/Lincyaw/presmium/issues",
13
+ "keywords": [
14
+ "presmium",
15
+ "create",
16
+ "template",
17
+ "document-ir",
18
+ "slides"
19
+ ],
20
+ "type": "module",
21
+ "engines": {
22
+ "node": ">=22.19"
23
+ },
24
+ "publishConfig": {
25
+ "access": "public"
26
+ },
27
+ "bin": {
28
+ "create-presmium": "./bin/create-presmium.mjs"
29
+ },
30
+ "exports": {
31
+ ".": "./src/cli.ts",
32
+ "./package.json": "./package.json"
33
+ },
34
+ "files": [
35
+ "bin",
36
+ "src",
37
+ "templates"
38
+ ],
39
+ "dependencies": {
40
+ "jiti": "^2.7.0",
41
+ "@lincyaw/kernel": "1.0.0-rc.1"
42
+ },
43
+ "devDependencies": {
44
+ "@lincyaw/cli": "1.0.0-rc.1"
45
+ },
46
+ "presmium": {
47
+ "generated": [
48
+ "templates"
49
+ ]
50
+ },
51
+ "scripts": {
52
+ "templates": "node scripts/templates.ts"
53
+ }
6
54
  }
package/src/cli.ts ADDED
@@ -0,0 +1,116 @@
1
+ import { createInterface } from 'node:readline'
2
+ import type { Interface } from 'node:readline'
3
+ import { basename, relative, resolve } from 'node:path'
4
+ import { parseArgs } from 'node:util'
5
+ import { assertEmpty, createProject, CreateError, isValidPackageName, KINDS, packageNameFor, SITE_THEMES } from './create.ts'
6
+ import type { ProjectKind, SiteTheme } from './create.ts'
7
+ import { MESSAGES, systemLocale } from './messages.ts'
8
+ import type { Messages } from './messages.ts'
9
+
10
+ const DEFAULT_DIRS: Record<ProjectKind, string> = {
11
+ lecture: 'my-lecture',
12
+ workspace: 'my-course',
13
+ site: 'my-site',
14
+ plugin: 'presmium-plugin-greeting',
15
+ }
16
+
17
+ export async function main(argv: string[]): Promise<number> {
18
+ const t = MESSAGES[systemLocale()]
19
+ let args: ReturnType<typeof parse>
20
+ try {
21
+ args = parse(argv, t)
22
+ } catch (error) {
23
+ process.stderr.write(`create-presmium: ${(error as Error).message}\n\n${t.usage}\n`)
24
+ return 2
25
+ }
26
+ if (args.values.help) {
27
+ process.stdout.write(`${t.usage}\n`)
28
+ return 0
29
+ }
30
+ const questions = new Questions(t)
31
+ try {
32
+ const asking = args.values.type === undefined || args.positionals[0] === undefined
33
+ const kind = args.values.type ?? await questions.kind()
34
+ if (!KINDS.includes(kind as ProjectKind)) throw new CreateError(t.badKind(kind), true)
35
+ const project = kind as ProjectKind
36
+ if (args.values.theme !== undefined && project !== 'site') throw new CreateError(t.themeOnlyForSite, true)
37
+ const theme = args.values.theme ?? 'course'
38
+ if (!SITE_THEMES.includes(theme as SiteTheme)) throw new CreateError(t.badTheme(theme), true)
39
+ const dir = resolve(args.positionals[0] ?? await questions.ask(t.dirQuestion, DEFAULT_DIRS[project]))
40
+ assertEmpty(dir, t)
41
+ const folder = relative(process.cwd(), dir) || '.'
42
+ const title = args.values.title ?? (asking && project !== 'plugin' ? await questions.ask(t.titleQuestion, basename(dir)) : basename(dir))
43
+ const name = args.values.name ?? (asking && project === 'plugin' ? await questions.ask(t.nameQuestion, packageNameFor(dir)) : packageNameFor(dir))
44
+ if (!isValidPackageName(name)) throw new CreateError(t.badName(name))
45
+ questions.close()
46
+ // The project's content is written in the title's language: a Chinese title gets Chinese pages whatever the system says.
47
+ const lang = /\p{Script=Han}/u.test(title) ? 'zh-CN' : systemLocale()
48
+ createProject({ kind: project, dir, title, name, git: args.values.git, theme: theme as SiteTheme, t, content: MESSAGES[lang], lang })
49
+ const steps = [...folder === '.' ? [] : [`cd ${/[\s'"]/.test(folder) ? JSON.stringify(folder) : folder}`], ...project === 'plugin' ? ['pnpm install', 'pnpm test', 'pnpm dev'] : project === 'site' ? ['pnpm install', 'pnpm serve'] : [`presmium ${project === 'lecture' ? 'dev' : 'serve'}`]]
50
+ process.stdout.write(`${t.created(project, folder)}\n\n${t.next}\n${steps.map(step => ` ${step}\n`).join('')}\n${t.agents}\n`)
51
+ return 0
52
+ } catch (error) {
53
+ if (!(error instanceof CreateError)) throw error
54
+ process.stderr.write(`create-presmium: ${error.message}\n`)
55
+ return error.usage ? 2 : 1
56
+ } finally {
57
+ questions.close()
58
+ }
59
+ }
60
+
61
+ function parse(argv: string[], t: Messages) {
62
+ const parsed = parseArgs({
63
+ args: argv,
64
+ allowPositionals: true,
65
+ allowNegative: true,
66
+ options: {
67
+ type: { type: 'string', short: 't' },
68
+ title: { type: 'string' },
69
+ theme: { type: 'string' },
70
+ name: { type: 'string' },
71
+ git: { type: 'boolean', default: true },
72
+ help: { type: 'boolean', short: 'h', default: false },
73
+ },
74
+ })
75
+ if (parsed.positionals.length > 1) throw new Error(t.tooManyDirectories(parsed.positionals.length))
76
+ return parsed
77
+ }
78
+
79
+ class Questions {
80
+ #lines?: AsyncIterator<string>
81
+ #reader?: Interface
82
+ readonly t: Messages
83
+
84
+ constructor(t: Messages) {
85
+ this.t = t
86
+ }
87
+
88
+ async ask(question: string, answer: string): Promise<string> {
89
+ const terminal = process.stdin.isTTY === true
90
+ this.#reader ??= createInterface({ input: process.stdin, terminal, output: terminal ? process.stdout : undefined })
91
+ this.#lines ??= this.#reader[Symbol.asyncIterator]()
92
+ const prompt = `${question} (${answer}): `
93
+ if (terminal) {
94
+ this.#reader.setPrompt(prompt)
95
+ this.#reader.prompt()
96
+ } else {
97
+ process.stdout.write(prompt)
98
+ }
99
+ const next = await this.#lines.next()
100
+ if (next.done) throw new CreateError(this.t.noAnswer, true)
101
+ if (!process.stdin.isTTY) process.stdout.write('\n')
102
+ return next.value.trim() || answer
103
+ }
104
+
105
+ async kind(): Promise<string> {
106
+ process.stdout.write(`${this.t.kindQuestion}\n${KINDS.map((kind, i) => ` ${i + 1}. ${this.t.kinds[kind]}\n`).join('')}`)
107
+ const answer = await this.ask(this.t.numberQuestion, '1')
108
+ return KINDS[Number(answer) - 1] ?? answer
109
+ }
110
+
111
+ close(): void {
112
+ this.#reader?.close()
113
+ this.#reader = undefined
114
+ }
115
+ }
116
+
package/src/create.ts ADDED
@@ -0,0 +1,160 @@
1
+ import { randomUUID } from 'node:crypto'
2
+ import { DOCUMENT_ENTRY } from '@lincyaw/kernel'
3
+ import type { TeachingDocument } from '@lincyaw/kernel'
4
+ import { spawnSync } from 'node:child_process'
5
+ import { cpSync, existsSync, mkdirSync, readdirSync, readFileSync, symlinkSync, writeFileSync } from 'node:fs'
6
+ import { basename, dirname, join } from 'node:path'
7
+ import type { Locale, Messages } from './messages.ts'
8
+ import { projectPath, templateDir, templateFiles } from './templates.ts'
9
+
10
+ export type ProjectKind = 'lecture' | 'workspace' | 'plugin' | 'site'
11
+ export type SiteTheme = 'course' | 'docs' | 'showcase'
12
+
13
+ export const KINDS: readonly ProjectKind[] = ['lecture', 'workspace', 'plugin', 'site']
14
+ export const SITE_THEMES: readonly SiteTheme[] = ['course', 'docs', 'showcase']
15
+
16
+ export const VERSION = (JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8')) as { version: string }).version
17
+
18
+ const SKILLS: Record<ProjectKind, string[]> = {
19
+ lecture: ['presmium-author', 'presmium-animate', 'presmium-present'],
20
+ workspace: ['presmium-author', 'presmium-animate', 'presmium-present'],
21
+ site: ['presmium-author', 'presmium-animate', 'presmium-present'],
22
+ plugin: ['presmium-develop', 'presmium-author'],
23
+ }
24
+
25
+ export const FIRST_DOCUMENT = 'intro'
26
+
27
+ const PACKAGE_NAME = /^(?:@[a-z0-9][a-z0-9._~-]*\/)?[a-z0-9][a-z0-9._~-]*$/
28
+
29
+ export interface ProjectOptions {
30
+ kind: ProjectKind
31
+ dir: string
32
+ title: string
33
+ name: string
34
+ git: boolean
35
+ theme?: SiteTheme
36
+ t: Messages
37
+ /** The messages the project's own files are written in, and their language; the command's messages when absent. */
38
+ content?: Messages
39
+ lang?: Locale
40
+ }
41
+
42
+ export class CreateError extends Error {
43
+ usage: boolean
44
+
45
+ constructor(message: string, usage = false) {
46
+ super(message)
47
+ this.usage = usage
48
+ }
49
+ }
50
+
51
+ export function isValidPackageName(name: string): boolean {
52
+ return name.length <= 214 && PACKAGE_NAME.test(name)
53
+ }
54
+
55
+ export function packageNameFor(dir: string): string {
56
+ const name = basename(dir).toLowerCase().replace(/[^a-z0-9._~-]+/g, '-').replace(/^[._~-]+/, '')
57
+ return name || 'presmium-project'
58
+ }
59
+
60
+ export function pluginIdFor(packageName: string): string {
61
+ return packageName.replace(/^@/, '').replace('/', '.')
62
+ }
63
+
64
+ export function assertEmpty(dir: string, t: Messages): void {
65
+ if (existsSync(dir) && readdirSync(dir).length > 0) throw new CreateError(t.notEmpty(dir))
66
+ }
67
+
68
+ export function createProject(options: ProjectOptions): void {
69
+ const { kind, dir, title, name, t } = options
70
+ const c = options.content ?? t
71
+ assertEmpty(dir, t)
72
+ if (!isValidPackageName(name)) throw new CreateError(t.badName(name))
73
+ mkdirSync(dir, { recursive: true })
74
+ const document = (to: string, documentTitle: string) => {
75
+ copyTemplate('document/default', to, (path, text) => {
76
+ if (path !== DOCUMENT_ENTRY) return text
77
+ const value = JSON.parse(text) as TeachingDocument
78
+ value.id = randomUUID()
79
+ value.metadata.title = documentTitle
80
+ if (options.lang) value.metadata.lang = options.lang
81
+ for (const section of Object.values(value.sections)) if (section.title === '{{title}}') section.title = documentTitle
82
+ return `${JSON.stringify(value, null, 2)}\n`
83
+ })
84
+ }
85
+ if (kind === 'lecture') {
86
+ document(dir, title)
87
+ copyTemplate('workspace', dir, unchanged, path => path === '.gitignore' || path === 'pnpm-workspace.yaml')
88
+ writePackage(dir, { name, private: true, type: 'module', scripts: { dev: 'presmium dev', check: 'presmium check', build: 'presmium build' }, devDependencies: { '@lincyaw/presmium': `^${VERSION}` } })
89
+ } else if (kind === 'workspace') {
90
+ copyTemplate('workspace', dir, (path, text) => path === 'presmium.workspace.yaml' ? text.replace(/^title: .*$/m, () => `title: ${JSON.stringify(title)}`) : text)
91
+ document(join(dir, FIRST_DOCUMENT), c.firstDocument)
92
+ writePackage(dir, { name, private: true, type: 'module', scripts: { serve: 'presmium serve', check: `presmium check ${FIRST_DOCUMENT}`, build: 'presmium build' }, devDependencies: { '@lincyaw/presmium': `^${VERSION}` } })
93
+ } else if (kind === 'site') {
94
+ copyTemplate('workspace', dir, unchanged, path => path === '.gitignore' || path === 'pnpm-workspace.yaml')
95
+ const theme = options.theme ?? 'course'
96
+ const params = theme === 'showcase'
97
+ ? { accent: 'violet', typography: 'sans', contentWidth: 'wide' }
98
+ : { accent: 'teal', typography: 'reading', contentWidth: 'comfortable' }
99
+ const strings: Record<string, string> = { ...c.site, title, theme, ...params }
100
+ copyTemplate('site', dir, (path, text) => {
101
+ if (path.endsWith('.json')) {
102
+ const value = JSON.parse(text, (_key, value: unknown) => typeof value === 'string' ? value.replace(/\{\{(\w+)\}\}/g, (token, key: string) => strings[key] ?? token) : value) as Record<string, unknown>
103
+ if (path.endsWith(DOCUMENT_ENTRY)) value.id = randomUUID()
104
+ return `${JSON.stringify(value, null, 2)}\n`
105
+ }
106
+ if (path === 'presmium.workspace.yaml') return text.replace(/\{\{(\w+)\}\}/g, (token, key: string) => key in strings ? JSON.stringify(strings[key]) : token)
107
+ return text
108
+ })
109
+ writePackage(dir, { name, private: true, type: 'module', scripts: { serve: 'presmium serve', check: 'presmium check intro', build: 'presmium build' }, devDependencies: { '@lincyaw/presmium': `^${VERSION}` } })
110
+ } else {
111
+ copyTemplate('plugin', dir, (path, text) => text.replaceAll('{{name}}', () => name).replaceAll('{{id}}', () => pluginIdFor(name)).replaceAll('{{version}}', () => VERSION))
112
+ }
113
+ if (kind !== 'plugin') {
114
+ writeFileSync(join(dir, 'README.md'), c.readme(kind, title))
115
+ writeFileSync(join(dir, 'AGENTS.md'), c.agentsFile(kind, title))
116
+ }
117
+ agentFiles(dir, SKILLS[kind])
118
+ if (options.git) gitInit(dir)
119
+ }
120
+
121
+ const unchanged = (_path: string, text: string): string => text
122
+
123
+ const TEXT = /(?:\.(?:md|tsx?|mts|jsx?|mjs|json|ya?ml|css|html|txt)|(?:^|[\\/])\.gitignore)$/
124
+
125
+ function copyTemplate(template: string, to: string, edit: (path: string, text: string) => string, only: (path: string) => boolean = () => true): void {
126
+ const from = templateDir(template)
127
+ if (!existsSync(from)) throw new Error(`${from} is missing`)
128
+ for (const stored of templateFiles(from)) {
129
+ const path = projectPath(stored)
130
+ if (!only(path)) continue
131
+ const content = readFileSync(join(from, stored))
132
+ mkdirSync(dirname(join(to, path)), { recursive: true })
133
+ writeFileSync(join(to, path), TEXT.test(path) ? edit(path, content.toString('utf8')) : content)
134
+ }
135
+ }
136
+
137
+ function writePackage(dir: string, pkg: Record<string, unknown>): void {
138
+ writeFileSync(join(dir, 'package.json'), `${JSON.stringify(pkg, null, 2)}\n`)
139
+ }
140
+
141
+ function agentFiles(dir: string, skills: string[]): void {
142
+ for (const skill of skills) copyTemplate(join('skills', skill), join(dir, '.agents/skills', skill), unchanged)
143
+ mkdirSync(join(dir, '.claude'), { recursive: true })
144
+ try {
145
+ symlinkSync('../.agents/skills', join(dir, '.claude/skills'), 'dir')
146
+ } catch {
147
+ cpSync(join(dir, '.agents/skills'), join(dir, '.claude/skills'), { recursive: true })
148
+ }
149
+ try {
150
+ symlinkSync('AGENTS.md', join(dir, 'CLAUDE.md'))
151
+ } catch {
152
+ writeFileSync(join(dir, 'CLAUDE.md'), '@AGENTS.md\n')
153
+ }
154
+ }
155
+
156
+ function gitInit(dir: string): void {
157
+ const inside = spawnSync('git', ['rev-parse', '--is-inside-work-tree'], { cwd: dir, encoding: 'utf8' })
158
+ if (inside.error || inside.stdout.trim() === 'true') return
159
+ spawnSync('git', ['init', '--quiet'], { cwd: dir, stdio: 'ignore' })
160
+ }