@felbrasil/dreamy 0.0.0-stage → 0.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 (450) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +69 -2
  3. package/dist/api.d.ts +1 -0
  4. package/dist/api.js +2 -0
  5. package/dist/api.js.map +7 -0
  6. package/dist/chunks/chunk-72DMUKP3.js +1470 -0
  7. package/dist/chunks/chunk-72DMUKP3.js.map +7 -0
  8. package/dist/chunks/chunk-VZMBE5MV.js +5936 -0
  9. package/dist/chunks/chunk-VZMBE5MV.js.map +7 -0
  10. package/dist/chunks/chunk-ZU72KKME.js +8600 -0
  11. package/dist/chunks/chunk-ZU72KKME.js.map +7 -0
  12. package/dist/core.d.ts +1 -0
  13. package/dist/core.js +34 -0
  14. package/dist/core.js.map +7 -0
  15. package/dist/dreamy_evaluator.wasm +0 -0
  16. package/dist/evaluator.d.ts +1 -0
  17. package/dist/evaluator.js +52 -0
  18. package/dist/evaluator.js.map +7 -0
  19. package/dist/index.d.ts +1 -0
  20. package/dist/index.js +7280 -0
  21. package/dist/index.js.map +7 -0
  22. package/dist/styles.css +1 -0
  23. package/dist/types/api/src/commands/command.d.ts +7 -0
  24. package/dist/types/api/src/commands/decal-commands.d.ts +35 -0
  25. package/dist/types/api/src/commands/palette-commands.d.ts +14 -0
  26. package/dist/types/api/src/commands/rig-commands.d.ts +229 -0
  27. package/dist/types/api/src/commands/scene-commands.d.ts +64 -0
  28. package/dist/types/api/src/commands/sculpt-commands.d.ts +111 -0
  29. package/dist/types/api/src/commands/stamp-spec.d.ts +3 -0
  30. package/dist/types/api/src/commands/target.d.ts +8 -0
  31. package/dist/types/api/src/creation-api.d.ts +52 -0
  32. package/dist/types/api/src/events/creation-event.d.ts +7 -0
  33. package/dist/types/api/src/events/decal-events.d.ts +20 -0
  34. package/dist/types/api/src/events/event-of.d.ts +6 -0
  35. package/dist/types/api/src/events/palette-events.d.ts +8 -0
  36. package/dist/types/api/src/events/rig-events.d.ts +161 -0
  37. package/dist/types/api/src/events/scene-events.d.ts +34 -0
  38. package/dist/types/api/src/events/sculpt-events.d.ts +53 -0
  39. package/dist/types/api/src/id.d.ts +1 -0
  40. package/dist/types/api/src/index.d.ts +31 -0
  41. package/dist/types/api/src/model/creation.d.ts +22 -0
  42. package/dist/types/api/src/model/decal.d.ts +48 -0
  43. package/dist/types/api/src/model/look.d.ts +56 -0
  44. package/dist/types/api/src/model/math.d.ts +18 -0
  45. package/dist/types/api/src/model/palette.d.ts +11 -0
  46. package/dist/types/api/src/model/rig.d.ts +125 -0
  47. package/dist/types/api/src/model/scene-object.d.ts +22 -0
  48. package/dist/types/api/src/model/sculpt.d.ts +13 -0
  49. package/dist/types/api/src/model/stamp.d.ts +53 -0
  50. package/dist/types/api/src/model/wing.d.ts +35 -0
  51. package/dist/types/api/src/ports/basic-ports.d.ts +7 -0
  52. package/dist/types/api/src/ports/evaluator.d.ts +62 -0
  53. package/dist/types/api/src/ports/persistence.d.ts +89 -0
  54. package/dist/types/api/src/ports/viewport.d.ts +125 -0
  55. package/dist/types/core/src/apply/body-part-added.d.ts +2 -0
  56. package/dist/types/core/src/apply/body-part-removed.d.ts +2 -0
  57. package/dist/types/core/src/apply/bone-removed.d.ts +3 -0
  58. package/dist/types/core/src/apply/bone-renamed.d.ts +2 -0
  59. package/dist/types/core/src/apply/bone-reparented.d.ts +2 -0
  60. package/dist/types/core/src/apply/bone-sizes-set.d.ts +3 -0
  61. package/dist/types/core/src/apply/bone-tags-set.d.ts +2 -0
  62. package/dist/types/core/src/apply/bone-transforms-set.d.ts +6 -0
  63. package/dist/types/core/src/apply/bones-added.d.ts +2 -0
  64. package/dist/types/core/src/apply/creature-generated.d.ts +3 -0
  65. package/dist/types/core/src/apply/decal-removed.d.ts +2 -0
  66. package/dist/types/core/src/apply/decals-added.d.ts +2 -0
  67. package/dist/types/core/src/apply/design-deleted.d.ts +2 -0
  68. package/dist/types/core/src/apply/design-saved.d.ts +2 -0
  69. package/dist/types/core/src/apply/flat-wings-set.d.ts +2 -0
  70. package/dist/types/core/src/apply/object-renamed.d.ts +2 -0
  71. package/dist/types/core/src/apply/object-reparented.d.ts +2 -0
  72. package/dist/types/core/src/apply/object-transforms-set.d.ts +2 -0
  73. package/dist/types/core/src/apply/objects-deleted.d.ts +2 -0
  74. package/dist/types/core/src/apply/objects-duplicated.d.ts +3 -0
  75. package/dist/types/core/src/apply/palette-color-set.d.ts +2 -0
  76. package/dist/types/core/src/apply/palette-reset.d.ts +2 -0
  77. package/dist/types/core/src/apply/part-grafted.d.ts +3 -0
  78. package/dist/types/core/src/apply/part-slot-swapped.d.ts +3 -0
  79. package/dist/types/core/src/apply/pivot-set.d.ts +2 -0
  80. package/dist/types/core/src/apply/pose-preset-applied.d.ts +3 -0
  81. package/dist/types/core/src/apply/pose-reset.d.ts +3 -0
  82. package/dist/types/core/src/apply/premade-applied.d.ts +3 -0
  83. package/dist/types/core/src/apply/region-blend-set.d.ts +3 -0
  84. package/dist/types/core/src/apply/rig-created.d.ts +2 -0
  85. package/dist/types/core/src/apply/rig-mirror-set.d.ts +2 -0
  86. package/dist/types/core/src/apply/rig-mode-set.d.ts +2 -0
  87. package/dist/types/core/src/apply/sculpt-created.d.ts +2 -0
  88. package/dist/types/core/src/apply/sculpt-look-set.d.ts +3 -0
  89. package/dist/types/core/src/apply/smear-group-set.d.ts +2 -0
  90. package/dist/types/core/src/apply/stamp-placements-set.d.ts +2 -0
  91. package/dist/types/core/src/apply/stamp-props-set.d.ts +2 -0
  92. package/dist/types/core/src/apply/stamps-added.d.ts +2 -0
  93. package/dist/types/core/src/apply/stamps-removed.d.ts +2 -0
  94. package/dist/types/core/src/apply/symmetry-set-for-all.d.ts +2 -0
  95. package/dist/types/core/src/atoms/check/check.d.ts +7 -0
  96. package/dist/types/core/src/atoms/decal/decal-limits.d.ts +6 -0
  97. package/dist/types/core/src/atoms/decal/decal-problem.d.ts +4 -0
  98. package/dist/types/core/src/atoms/decal/design-problem.d.ts +4 -0
  99. package/dist/types/core/src/atoms/look/catalogs.d.ts +9 -0
  100. package/dist/types/core/src/atoms/look/default-look.d.ts +4 -0
  101. package/dist/types/core/src/atoms/look/look-problem.d.ts +7 -0
  102. package/dist/types/core/src/atoms/look/merge-look.d.ts +3 -0
  103. package/dist/types/core/src/atoms/math/mat4.d.ts +14 -0
  104. package/dist/types/core/src/atoms/math/quat.d.ts +18 -0
  105. package/dist/types/core/src/atoms/math/transform.d.ts +7 -0
  106. package/dist/types/core/src/atoms/math/vec3.d.ts +18 -0
  107. package/dist/types/core/src/atoms/palette/default-palette.d.ts +4 -0
  108. package/dist/types/core/src/atoms/palette/is-color-ref.d.ts +2 -0
  109. package/dist/types/core/src/atoms/palette/poc-color-ref.d.ts +6 -0
  110. package/dist/types/core/src/atoms/rig/bone-matrices.d.ts +8 -0
  111. package/dist/types/core/src/atoms/rig/bone-region.d.ts +8 -0
  112. package/dist/types/core/src/atoms/rig/bone-role.d.ts +11 -0
  113. package/dist/types/core/src/atoms/rig/bone-size.d.ts +7 -0
  114. package/dist/types/core/src/atoms/rig/compose-local.d.ts +6 -0
  115. package/dist/types/core/src/atoms/rig/find-rig.d.ts +11 -0
  116. package/dist/types/core/src/atoms/rig/mirror-partner.d.ts +3 -0
  117. package/dist/types/core/src/atoms/rig/mirror-sculpt.d.ts +9 -0
  118. package/dist/types/core/src/atoms/rig/mirror-transform.d.ts +9 -0
  119. package/dist/types/core/src/atoms/rig/partner-target.d.ts +3 -0
  120. package/dist/types/core/src/atoms/rig/pose-presets.d.ts +11 -0
  121. package/dist/types/core/src/atoms/rig/pose-rule.d.ts +48 -0
  122. package/dist/types/core/src/atoms/rig/pose-template-rules.d.ts +8 -0
  123. package/dist/types/core/src/atoms/rig/rebase-pose.d.ts +6 -0
  124. package/dist/types/core/src/atoms/rig/resize-bones.d.ts +12 -0
  125. package/dist/types/core/src/atoms/rig/rig-extent.d.ts +3 -0
  126. package/dist/types/core/src/atoms/rig/side-from-name.d.ts +7 -0
  127. package/dist/types/core/src/atoms/rig/size-frame.d.ts +18 -0
  128. package/dist/types/core/src/atoms/rig/with-slot-parts.d.ts +9 -0
  129. package/dist/types/core/src/atoms/scene/copy-with-new-ids.d.ts +7 -0
  130. package/dist/types/core/src/atoms/scene/object-tree.d.ts +8 -0
  131. package/dist/types/core/src/atoms/scene/place-in-order.d.ts +7 -0
  132. package/dist/types/core/src/atoms/scene/unique-name.d.ts +4 -0
  133. package/dist/types/core/src/atoms/scene/world-matrix.d.ts +4 -0
  134. package/dist/types/core/src/atoms/sculpt/all-sculpts.d.ts +3 -0
  135. package/dist/types/core/src/atoms/sculpt/is-wing-target.d.ts +3 -0
  136. package/dist/types/core/src/atoms/sculpt/target-sculpt.d.ts +10 -0
  137. package/dist/types/core/src/atoms/sculpt/update-target.d.ts +8 -0
  138. package/dist/types/core/src/atoms/stamp/apply-stamp-props.d.ts +11 -0
  139. package/dist/types/core/src/atoms/stamp/clamp-symmetry.d.ts +11 -0
  140. package/dist/types/core/src/atoms/stamp/clean-props.d.ts +3 -0
  141. package/dist/types/core/src/atoms/stamp/emptied-groups.d.ts +3 -0
  142. package/dist/types/core/src/atoms/stamp/move-locked-groups.d.ts +12 -0
  143. package/dist/types/core/src/atoms/stamp/normalize-base.d.ts +6 -0
  144. package/dist/types/core/src/atoms/stamp/resolve-stamp-props.d.ts +14 -0
  145. package/dist/types/core/src/atoms/stamp/smear.d.ts +15 -0
  146. package/dist/types/core/src/atoms/stamp/stamp-problem.d.ts +7 -0
  147. package/dist/types/core/src/atoms/wing/wing-problem.d.ts +6 -0
  148. package/dist/types/core/src/create-creation-api.d.ts +12 -0
  149. package/dist/types/core/src/decide.d.ts +4 -0
  150. package/dist/types/core/src/empty-creation.d.ts +2 -0
  151. package/dist/types/core/src/fold.d.ts +6 -0
  152. package/dist/types/core/src/index.d.ts +9 -0
  153. package/dist/types/core/src/molecules/add-body-part.d.ts +8 -0
  154. package/dist/types/core/src/molecules/add-bone.d.ts +8 -0
  155. package/dist/types/core/src/molecules/add-decals.d.ts +4 -0
  156. package/dist/types/core/src/molecules/add-stamps.d.ts +8 -0
  157. package/dist/types/core/src/molecules/apply-pose-preset.d.ts +4 -0
  158. package/dist/types/core/src/molecules/apply-premade.d.ts +9 -0
  159. package/dist/types/core/src/molecules/auto-tag-sides.d.ts +4 -0
  160. package/dist/types/core/src/molecules/create-rig.d.ts +4 -0
  161. package/dist/types/core/src/molecules/create-sculpt.d.ts +4 -0
  162. package/dist/types/core/src/molecules/delete-design.d.ts +4 -0
  163. package/dist/types/core/src/molecules/delete-objects.d.ts +4 -0
  164. package/dist/types/core/src/molecules/duplicate-objects.d.ts +6 -0
  165. package/dist/types/core/src/molecules/generate-creature.d.ts +7 -0
  166. package/dist/types/core/src/molecules/graft-part.d.ts +4 -0
  167. package/dist/types/core/src/molecules/mirror-objects.d.ts +7 -0
  168. package/dist/types/core/src/molecules/molecule.d.ts +17 -0
  169. package/dist/types/core/src/molecules/remove-body-part.d.ts +3 -0
  170. package/dist/types/core/src/molecules/remove-bone.d.ts +4 -0
  171. package/dist/types/core/src/molecules/remove-decal.d.ts +3 -0
  172. package/dist/types/core/src/molecules/remove-smear-group.d.ts +4 -0
  173. package/dist/types/core/src/molecules/remove-stamps.d.ts +4 -0
  174. package/dist/types/core/src/molecules/rename-bone.d.ts +3 -0
  175. package/dist/types/core/src/molecules/rename-object.d.ts +3 -0
  176. package/dist/types/core/src/molecules/reparent-bone.d.ts +4 -0
  177. package/dist/types/core/src/molecules/reparent-object.d.ts +4 -0
  178. package/dist/types/core/src/molecules/reset-palette.d.ts +3 -0
  179. package/dist/types/core/src/molecules/reset-pose.d.ts +3 -0
  180. package/dist/types/core/src/molecules/save-design.d.ts +4 -0
  181. package/dist/types/core/src/molecules/set-bone-sizes.d.ts +8 -0
  182. package/dist/types/core/src/molecules/set-bone-tags.d.ts +4 -0
  183. package/dist/types/core/src/molecules/set-bone-transforms.d.ts +7 -0
  184. package/dist/types/core/src/molecules/set-flat-wings.d.ts +4 -0
  185. package/dist/types/core/src/molecules/set-object-transforms.d.ts +3 -0
  186. package/dist/types/core/src/molecules/set-palette-color.d.ts +3 -0
  187. package/dist/types/core/src/molecules/set-pivot.d.ts +3 -0
  188. package/dist/types/core/src/molecules/set-region-blend.d.ts +4 -0
  189. package/dist/types/core/src/molecules/set-rig-mirror.d.ts +3 -0
  190. package/dist/types/core/src/molecules/set-rig-mode.d.ts +3 -0
  191. package/dist/types/core/src/molecules/set-sculpt-look.d.ts +7 -0
  192. package/dist/types/core/src/molecules/set-smear-group.d.ts +4 -0
  193. package/dist/types/core/src/molecules/set-stamp-placements.d.ts +4 -0
  194. package/dist/types/core/src/molecules/set-stamp-props.d.ts +3 -0
  195. package/dist/types/core/src/molecules/set-symmetry-for-all.d.ts +4 -0
  196. package/dist/types/core/src/molecules/swap-part-slot.d.ts +7 -0
  197. package/dist/types/core/src/premades/ant-bake.d.ts +2 -0
  198. package/dist/types/core/src/premades/bake-authoring.d.ts +35 -0
  199. package/dist/types/core/src/premades/bake-types.d.ts +65 -0
  200. package/dist/types/core/src/premades/baked-part-for.d.ts +11 -0
  201. package/dist/types/core/src/premades/bee-bake.d.ts +2 -0
  202. package/dist/types/core/src/premades/bird-bake.d.ts +2 -0
  203. package/dist/types/core/src/premades/body-stamps-for-bone.d.ts +14 -0
  204. package/dist/types/core/src/premades/bone-tree.d.ts +15 -0
  205. package/dist/types/core/src/premades/build-premade-rig.d.ts +23 -0
  206. package/dist/types/core/src/premades/build-template.d.ts +6 -0
  207. package/dist/types/core/src/premades/centipede-bake.d.ts +2 -0
  208. package/dist/types/core/src/premades/coat-stamps.d.ts +3 -0
  209. package/dist/types/core/src/premades/crab-bake.d.ts +2 -0
  210. package/dist/types/core/src/premades/dragon-bake.d.ts +2 -0
  211. package/dist/types/core/src/premades/face-decals.d.ts +17 -0
  212. package/dist/types/core/src/premades/fish-bake.d.ts +2 -0
  213. package/dist/types/core/src/premades/fit-part-slot.d.ts +21 -0
  214. package/dist/types/core/src/premades/generate-creature.d.ts +21 -0
  215. package/dist/types/core/src/premades/gorilla-bake.d.ts +2 -0
  216. package/dist/types/core/src/premades/graft-slot.d.ts +34 -0
  217. package/dist/types/core/src/premades/humanoid-bake.d.ts +2 -0
  218. package/dist/types/core/src/premades/insect6-bake.d.ts +2 -0
  219. package/dist/types/core/src/premades/jellyfish-bake.d.ts +2 -0
  220. package/dist/types/core/src/premades/lizard-bake.d.ts +2 -0
  221. package/dist/types/core/src/premades/make-baked-part.d.ts +9 -0
  222. package/dist/types/core/src/premades/make-body-part.d.ts +9 -0
  223. package/dist/types/core/src/premades/make-flat-part.d.ts +13 -0
  224. package/dist/types/core/src/premades/part-context.d.ts +20 -0
  225. package/dist/types/core/src/premades/part-kits.d.ts +36 -0
  226. package/dist/types/core/src/premades/part-slots.d.ts +17 -0
  227. package/dist/types/core/src/premades/part-stamp.d.ts +13 -0
  228. package/dist/types/core/src/premades/part-styles.d.ts +44 -0
  229. package/dist/types/core/src/premades/premade-fit.d.ts +18 -0
  230. package/dist/types/core/src/premades/premade-infos.d.ts +3 -0
  231. package/dist/types/core/src/premades/reseat-attachments.d.ts +31 -0
  232. package/dist/types/core/src/premades/rig-builder.d.ts +51 -0
  233. package/dist/types/core/src/premades/rodent-bake.d.ts +2 -0
  234. package/dist/types/core/src/premades/scorpion-bake.d.ts +2 -0
  235. package/dist/types/core/src/premades/shark-bake.d.ts +2 -0
  236. package/dist/types/core/src/premades/sitter-bake.d.ts +3 -0
  237. package/dist/types/core/src/premades/skeleton-bakes.d.ts +4 -0
  238. package/dist/types/core/src/premades/snake-bake.d.ts +2 -0
  239. package/dist/types/core/src/premades/spider-bake.d.ts +2 -0
  240. package/dist/types/core/src/premades/stamps-box.d.ts +9 -0
  241. package/dist/types/core/src/premades/style-for-bone.d.ts +7 -0
  242. package/dist/types/core/src/premades/swap-slot.d.ts +13 -0
  243. package/dist/types/core/src/premades/template-catalog.d.ts +20 -0
  244. package/dist/types/core/src/premades/template-color.d.ts +9 -0
  245. package/dist/types/core/src/premades/turtle-bake.d.ts +2 -0
  246. package/dist/types/core/src/premades/variants/aquatic-variants.d.ts +16 -0
  247. package/dist/types/core/src/premades/variants/coat-variants.d.ts +7 -0
  248. package/dist/types/core/src/premades/variants/ear-variants.d.ts +8 -0
  249. package/dist/types/core/src/premades/variants/fantasy-more-variants.d.ts +3 -0
  250. package/dist/types/core/src/premades/variants/fantasy-variants.d.ts +17 -0
  251. package/dist/types/core/src/premades/variants/head-variants.d.ts +9 -0
  252. package/dist/types/core/src/premades/variants/horn-variants.d.ts +7 -0
  253. package/dist/types/core/src/premades/variants/index.d.ts +10 -0
  254. package/dist/types/core/src/premades/variants/land-variants.d.ts +3 -0
  255. package/dist/types/core/src/premades/variants/leg-variants.d.ts +7 -0
  256. package/dist/types/core/src/premades/variants/part-variant.d.ts +14 -0
  257. package/dist/types/core/src/premades/variants/tail-variants.d.ts +6 -0
  258. package/dist/types/core/src/premades/variants/variant-authoring.d.ts +29 -0
  259. package/dist/types/core/src/premades/whale-bake.d.ts +2 -0
  260. package/dist/types/core/src/premades/wing-defaults.d.ts +4 -0
  261. package/dist/types/core/src/premades/wing-frame.d.ts +10 -0
  262. package/dist/types/core/src/premades/wolf-bake.d.ts +2 -0
  263. package/dist/types/core/src/premades/worm-bake.d.ts +2 -0
  264. package/dist/types/evaluator/src/abi.d.ts +64 -0
  265. package/dist/types/evaluator/src/chunks.d.ts +53 -0
  266. package/dist/types/evaluator/src/index.d.ts +11 -0
  267. package/dist/types/evaluator/src/prep/colors.d.ts +11 -0
  268. package/dist/types/evaluator/src/prep/mat3.d.ts +13 -0
  269. package/dist/types/evaluator/src/prep/pack.d.ts +23 -0
  270. package/dist/types/evaluator/src/prep/props.d.ts +16 -0
  271. package/dist/types/evaluator/src/prep/symmetry.d.ts +23 -0
  272. package/dist/types/evaluator/src/reference/core.d.ts +3 -0
  273. package/dist/types/evaluator/src/reference/mesher.d.ts +22 -0
  274. package/dist/types/evaluator/src/reference/skin.d.ts +8 -0
  275. package/dist/types/evaluator/src/session.d.ts +21 -0
  276. package/dist/types/evaluator/src/wasm/core.d.ts +9 -0
  277. package/dist/types/evaluator/src/worker/client.d.ts +28 -0
  278. package/dist/types/evaluator/src/worker/host.d.ts +8 -0
  279. package/dist/types/evaluator/src/worker/protocol.d.ts +39 -0
  280. package/dist/types/evaluator/src/worker/spawn.d.ts +6 -0
  281. package/dist/types/evaluator/src/worker/worker-inline.d.ts +1 -0
  282. package/dist/types/evaluator/src/worker/worker.d.ts +1 -0
  283. package/dist/types/module/src/index.d.ts +2 -0
  284. package/dist/types/module/src/ui/atoms/action-button.d.ts +10 -0
  285. package/dist/types/module/src/ui/atoms/badge.d.ts +9 -0
  286. package/dist/types/module/src/ui/atoms/checkbox.d.ts +6 -0
  287. package/dist/types/module/src/ui/atoms/color-input.d.ts +10 -0
  288. package/dist/types/module/src/ui/atoms/hex-chip.d.ts +5 -0
  289. package/dist/types/module/src/ui/atoms/icon-button.d.ts +14 -0
  290. package/dist/types/module/src/ui/atoms/icon.d.ts +8 -0
  291. package/dist/types/module/src/ui/atoms/kbd.d.ts +4 -0
  292. package/dist/types/module/src/ui/atoms/match-button.d.ts +10 -0
  293. package/dist/types/module/src/ui/atoms/number-input.d.ts +11 -0
  294. package/dist/types/module/src/ui/atoms/pill-button.d.ts +11 -0
  295. package/dist/types/module/src/ui/atoms/range-input.d.ts +17 -0
  296. package/dist/types/module/src/ui/atoms/select-input.d.ts +12 -0
  297. package/dist/types/module/src/ui/atoms/separator.d.ts +2 -0
  298. package/dist/types/module/src/ui/atoms/side-button.d.ts +13 -0
  299. package/dist/types/module/src/ui/atoms/swatch.d.ts +13 -0
  300. package/dist/types/module/src/ui/atoms/tool-button.d.ts +22 -0
  301. package/dist/types/module/src/ui/hooks/editor-actions.d.ts +50 -0
  302. package/dist/types/module/src/ui/hooks/editor-context.d.ts +37 -0
  303. package/dist/types/module/src/ui/hooks/use-compact.d.ts +2 -0
  304. package/dist/types/module/src/ui/hooks/use-editor-controller.d.ts +17 -0
  305. package/dist/types/module/src/ui/hooks/use-keyboard.d.ts +11 -0
  306. package/dist/types/module/src/ui/lib/catalog.d.ts +76 -0
  307. package/dist/types/module/src/ui/lib/colors.d.ts +15 -0
  308. package/dist/types/module/src/ui/lib/decals.d.ts +6 -0
  309. package/dist/types/module/src/ui/lib/design-geometry.d.ts +60 -0
  310. package/dist/types/module/src/ui/lib/math.d.ts +18 -0
  311. package/dist/types/module/src/ui/lib/placement.d.ts +8 -0
  312. package/dist/types/module/src/ui/lib/scene.d.ts +51 -0
  313. package/dist/types/module/src/ui/lib/symmetry.d.ts +5 -0
  314. package/dist/types/module/src/ui/lib/targets.d.ts +28 -0
  315. package/dist/types/module/src/ui/lib/view-state.d.ts +74 -0
  316. package/dist/types/module/src/ui/molecules/axis-pill.d.ts +7 -0
  317. package/dist/types/module/src/ui/molecules/color-field.d.ts +14 -0
  318. package/dist/types/module/src/ui/molecules/count-stepper.d.ts +9 -0
  319. package/dist/types/module/src/ui/molecules/floating-panel.d.ts +26 -0
  320. package/dist/types/module/src/ui/molecules/help-row.d.ts +8 -0
  321. package/dist/types/module/src/ui/molecules/inline-edit.d.ts +9 -0
  322. package/dist/types/module/src/ui/molecules/list-row.d.ts +25 -0
  323. package/dist/types/module/src/ui/molecules/modal.d.ts +11 -0
  324. package/dist/types/module/src/ui/molecules/mode-pill.d.ts +7 -0
  325. package/dist/types/module/src/ui/molecules/scroll-row.d.ts +10 -0
  326. package/dist/types/module/src/ui/molecules/slider-row.d.ts +16 -0
  327. package/dist/types/module/src/ui/molecules/swatch-row.d.ts +11 -0
  328. package/dist/types/module/src/ui/molecules/tab-bar.d.ts +9 -0
  329. package/dist/types/module/src/ui/molecules/toolbar-pill.d.ts +7 -0
  330. package/dist/types/module/src/ui/molecules/toolbar.d.ts +10 -0
  331. package/dist/types/module/src/ui/molecules/vec3-field.d.ts +10 -0
  332. package/dist/types/module/src/ui/organisms/bone-panel.d.ts +2 -0
  333. package/dist/types/module/src/ui/organisms/bone-size-sliders.d.ts +9 -0
  334. package/dist/types/module/src/ui/organisms/category-bar.d.ts +2 -0
  335. package/dist/types/module/src/ui/organisms/decal-bar.d.ts +2 -0
  336. package/dist/types/module/src/ui/organisms/decal-editor.d.ts +2 -0
  337. package/dist/types/module/src/ui/organisms/fleck-style-tab.d.ts +7 -0
  338. package/dist/types/module/src/ui/organisms/git-sync-panel.d.ts +10 -0
  339. package/dist/types/module/src/ui/organisms/help-panel.d.ts +2 -0
  340. package/dist/types/module/src/ui/organisms/material-tab.d.ts +3 -0
  341. package/dist/types/module/src/ui/organisms/object-list-panel.d.ts +2 -0
  342. package/dist/types/module/src/ui/organisms/palette-panel.d.ts +2 -0
  343. package/dist/types/module/src/ui/organisms/parts-tab.d.ts +26 -0
  344. package/dist/types/module/src/ui/organisms/pattern-tab.d.ts +3 -0
  345. package/dist/types/module/src/ui/organisms/pose-tab.d.ts +8 -0
  346. package/dist/types/module/src/ui/organisms/premade-picker.d.ts +2 -0
  347. package/dist/types/module/src/ui/organisms/properties-panel.d.ts +2 -0
  348. package/dist/types/module/src/ui/organisms/region-blends.d.ts +5 -0
  349. package/dist/types/module/src/ui/organisms/rendering-bar.d.ts +5 -0
  350. package/dist/types/module/src/ui/organisms/rig-bar.d.ts +2 -0
  351. package/dist/types/module/src/ui/organisms/scenes-modal.d.ts +2 -0
  352. package/dist/types/module/src/ui/organisms/select-hint.d.ts +2 -0
  353. package/dist/types/module/src/ui/organisms/shape-list-panel.d.ts +2 -0
  354. package/dist/types/module/src/ui/organisms/side-dock.d.ts +4 -0
  355. package/dist/types/module/src/ui/organisms/stamp-bar.d.ts +2 -0
  356. package/dist/types/module/src/ui/organisms/stamp-props-panel.d.ts +2 -0
  357. package/dist/types/module/src/ui/organisms/stamp-size-panel.d.ts +4 -0
  358. package/dist/types/module/src/ui/organisms/stats-badge.d.ts +2 -0
  359. package/dist/types/module/src/ui/organisms/style-bar.d.ts +2 -0
  360. package/dist/types/module/src/ui/organisms/symmetry-bar.d.ts +2 -0
  361. package/dist/types/module/src/ui/organisms/toast.d.ts +2 -0
  362. package/dist/types/module/src/ui/organisms/token-guide.d.ts +5 -0
  363. package/dist/types/module/src/ui/organisms/touch-mods.d.ts +2 -0
  364. package/dist/types/module/src/ui/organisms/transform-bar.d.ts +2 -0
  365. package/dist/types/module/src/ui/organisms/transform-tab.d.ts +2 -0
  366. package/dist/types/module/src/ui/organisms/utilities-bar.d.ts +2 -0
  367. package/dist/types/module/src/ui/organisms/viewport-host.d.ts +2 -0
  368. package/dist/types/module/src/ui/organisms/voxel-panel.d.ts +2 -0
  369. package/dist/types/module/src/ui/organisms/wing-tab.d.ts +10 -0
  370. package/dist/types/module/src/ui/pages/editor-page.d.ts +9 -0
  371. package/dist/types/module/src/ui/templates/editor-shell.d.ts +2 -0
  372. package/dist/types/studio/src/browser-files.d.ts +3 -0
  373. package/dist/types/studio/src/clock.d.ts +2 -0
  374. package/dist/types/studio/src/creation-file.d.ts +21 -0
  375. package/dist/types/studio/src/git-remote.d.ts +36 -0
  376. package/dist/types/studio/src/git-sync.d.ts +33 -0
  377. package/dist/types/studio/src/ids.d.ts +3 -0
  378. package/dist/types/studio/src/index.d.ts +15 -0
  379. package/dist/types/studio/src/indexed-db-library.d.ts +2 -0
  380. package/dist/types/studio/src/library-persistence.d.ts +29 -0
  381. package/dist/types/studio/src/library-sync.d.ts +29 -0
  382. package/dist/types/studio/src/preferences.d.ts +9 -0
  383. package/dist/types/studio/src/seed.d.ts +3 -0
  384. package/dist/types/studio/src/studio.d.ts +17 -0
  385. package/dist/types/viewport/src/create-viewport.d.ts +10 -0
  386. package/dist/types/viewport/src/decals/builtin-art.d.ts +19 -0
  387. package/dist/types/viewport/src/decals/builtin-docs.d.ts +7 -0
  388. package/dist/types/viewport/src/decals/decal-atlas.d.ts +37 -0
  389. package/dist/types/viewport/src/decals/decal-catalog.d.ts +17 -0
  390. package/dist/types/viewport/src/decals/decal-glsl.d.ts +2 -0
  391. package/dist/types/viewport/src/decals/decal-limits.d.ts +11 -0
  392. package/dist/types/viewport/src/decals/decal-uniforms.d.ts +40 -0
  393. package/dist/types/viewport/src/decals/design-raster.d.ts +8 -0
  394. package/dist/types/viewport/src/decals/interior-thumbs.d.ts +6 -0
  395. package/dist/types/viewport/src/index.d.ts +1 -0
  396. package/dist/types/viewport/src/interaction/bone-tool.d.ts +13 -0
  397. package/dist/types/viewport/src/interaction/bones-visible.d.ts +7 -0
  398. package/dist/types/viewport/src/interaction/cursor.d.ts +3 -0
  399. package/dist/types/viewport/src/interaction/decal-tool.d.ts +18 -0
  400. package/dist/types/viewport/src/interaction/esc-hold.d.ts +13 -0
  401. package/dist/types/viewport/src/interaction/ghost-geometry.d.ts +6 -0
  402. package/dist/types/viewport/src/interaction/gizmo.d.ts +34 -0
  403. package/dist/types/viewport/src/interaction/interaction-context.d.ts +41 -0
  404. package/dist/types/viewport/src/interaction/marquee.d.ts +8 -0
  405. package/dist/types/viewport/src/interaction/pivot-helper.d.ts +13 -0
  406. package/dist/types/viewport/src/interaction/select-tool.d.ts +30 -0
  407. package/dist/types/viewport/src/interaction/selection-boxes.d.ts +11 -0
  408. package/dist/types/viewport/src/interaction/stamp-tool.d.ts +41 -0
  409. package/dist/types/viewport/src/interaction/stamp-wires.d.ts +18 -0
  410. package/dist/types/viewport/src/interaction/surface-hit.d.ts +14 -0
  411. package/dist/types/viewport/src/materials/fleck-material.d.ts +69 -0
  412. package/dist/types/viewport/src/materials/global-uniforms.d.ts +15 -0
  413. package/dist/types/viewport/src/materials/skin.d.ts +18 -0
  414. package/dist/types/viewport/src/materials/wing-material.d.ts +21 -0
  415. package/dist/types/viewport/src/math/colors.d.ts +29 -0
  416. package/dist/types/viewport/src/math/convert.d.ts +15 -0
  417. package/dist/types/viewport/src/math/decal-pose.d.ts +7 -0
  418. package/dist/types/viewport/src/math/lod.d.ts +16 -0
  419. package/dist/types/viewport/src/math/picking.d.ts +32 -0
  420. package/dist/types/viewport/src/math/pixel-palette.d.ts +15 -0
  421. package/dist/types/viewport/src/math/screen.d.ts +26 -0
  422. package/dist/types/viewport/src/math/skeleton-math.d.ts +32 -0
  423. package/dist/types/viewport/src/math/smear.d.ts +20 -0
  424. package/dist/types/viewport/src/math/symmetry.d.ts +21 -0
  425. package/dist/types/viewport/src/objects/default-look.d.ts +3 -0
  426. package/dist/types/viewport/src/objects/mesh-driver.d.ts +26 -0
  427. package/dist/types/viewport/src/objects/mesh-key.d.ts +8 -0
  428. package/dist/types/viewport/src/objects/rig-view.d.ts +31 -0
  429. package/dist/types/viewport/src/objects/scene-views.d.ts +53 -0
  430. package/dist/types/viewport/src/objects/sculpt-view.d.ts +66 -0
  431. package/dist/types/viewport/src/objects/view-context.d.ts +19 -0
  432. package/dist/types/viewport/src/objects/wing-view.d.ts +27 -0
  433. package/dist/types/viewport/src/rig/bone-viz.d.ts +13 -0
  434. package/dist/types/viewport/src/scene/camera-motion.d.ts +10 -0
  435. package/dist/types/viewport/src/scene/camera-sun.d.ts +3 -0
  436. package/dist/types/viewport/src/scene/environment.d.ts +3 -0
  437. package/dist/types/viewport/src/scene/frame-camera.d.ts +10 -0
  438. package/dist/types/viewport/src/scene/play-mode.d.ts +9 -0
  439. package/dist/types/viewport/src/scene/render-pipeline.d.ts +26 -0
  440. package/dist/types/viewport/src/scene/render-settings.d.ts +18 -0
  441. package/dist/types/viewport/src/scene/resolve-frag.d.ts +3 -0
  442. package/dist/types/viewport/src/scene/stage.d.ts +38 -0
  443. package/dist/types/viewport/src/scene/stress-test.d.ts +6 -0
  444. package/dist/types/viewport/src/wings/wing-mesh.d.ts +19 -0
  445. package/dist/types/viewport/src/wings/wing-outlines.d.ts +32 -0
  446. package/dist/types/viewport/src/wings/wing-pattern.d.ts +7 -0
  447. package/dist/viewport.d.ts +1 -0
  448. package/dist/viewport.js +8 -0
  449. package/dist/viewport.js.map +7 -0
  450. package/package.json +74 -4
@@ -0,0 +1 @@
1
+ @import"https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css";@import"https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&display=swap";.dreamy-studio{--glass-bg: rgba(255, 255, 255, .35);--glass-border: rgba(255, 255, 255, .6);--glass-shadow: 0 12px 35px rgba(0, 0, 0, .15);--cat-transform: linear-gradient(135deg, #bae1ff, #93c5fd);--cat-shape: linear-gradient(135deg, #fef08a, #fde047);--cat-art: linear-gradient(135deg, #ffb3ba, #f9a8d4);--cat-mode: linear-gradient(135deg, #baffc9, #86efac)}.dreamy-studio,.dreamy-studio *{box-sizing:border-box}.dreamy-studio{margin:0;padding:0;overflow:hidden;font-family:Nunito,sans-serif;background-color:#aecbf7;user-select:none;-webkit-user-select:none}.dreamy-studio #canvas-container{position:absolute;top:0;left:0;width:100vw;height:100vh;height:100dvh;z-index:1}.dreamy-studio #canvas-container canvas{display:block;touch-action:none}.dreamy-studio #ui-layer{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none;z-index:50;display:flex;flex-direction:column;align-items:center;padding-top:18px}.dreamy-studio #main-toolbar{position:relative;z-index:60}.dreamy-studio .toolbar-group{display:flex;flex-direction:column;align-items:center;gap:10px;pointer-events:auto}.dreamy-studio .toolbar{display:flex;gap:10px;background:var(--glass-bg);padding:8px 20px;border-radius:40px;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);box-shadow:var(--glass-shadow);border:1.5px solid var(--glass-border);transition:all .25s cubic-bezier(.4,0,.2,1);align-items:center}.dreamy-studio .sub-toolbar{display:none;animation:slideDown .25s cubic-bezier(.175,.885,.32,1.275) forwards;background:#ffffff73;border-radius:30px;padding:6px 14px;z-index:40}.dreamy-studio .sub-toolbar.active{display:flex}.dreamy-studio .sub-toolbar{max-width:94vw}.dreamy-studio .tb-sep{width:2px;height:28px;margin:0 4px;background:#0000001a;flex-shrink:0}.dreamy-studio .tb-section{display:flex;align-items:center;gap:10px;flex-shrink:0}.dreamy-studio .sub-toolbar>.tool-btn,.dreamy-studio .sub-toolbar>.mode-badge,.dreamy-studio .sub-toolbar>.stamp-stepper{flex-shrink:0}.dreamy-studio .tb-scroll-wrap{position:relative;display:flex;flex:0 1 auto;min-width:140px}.dreamy-studio .tb-scroll{position:relative;display:flex;align-items:center;gap:10px;flex:1 1 auto;min-width:0;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;padding:10px 6px;margin:-10px -6px;--fade-l: 0px;--fade-r: 0px;-webkit-mask-image:linear-gradient(to right,transparent 0,#000 var(--fade-l),#000 calc(100% - var(--fade-r)),transparent 100%);mask-image:linear-gradient(to right,transparent 0,#000 var(--fade-l),#000 calc(100% - var(--fade-r)),transparent 100%)}.dreamy-studio .tb-scroll::-webkit-scrollbar{display:none}.dreamy-studio .tb-scroll>*{flex-shrink:0}.dreamy-studio .tb-scroll-wrap.can-left .tb-scroll{--fade-l: 34px}.dreamy-studio .tb-scroll-wrap.can-right .tb-scroll{--fade-r: 34px}.dreamy-studio .tb-scroll .tooltip{display:none}.dreamy-studio .tb-chev{position:absolute;top:50%;width:22px;height:22px;margin-top:-11px;padding:0;border:none;border-radius:50%;background:#ffffffeb;color:#334155;font-size:11px;box-shadow:0 2px 6px #00000040;cursor:pointer;display:none;align-items:center;justify-content:center;z-index:2;transition:transform .15s,background .15s}.dreamy-studio .tb-chev:hover{background:#fff;transform:scale(1.12)}.dreamy-studio .tb-chev.left{left:-4px}.dreamy-studio .tb-chev.right{right:-4px}.dreamy-studio .tb-scroll-wrap.can-left .tb-chev.left,.dreamy-studio .tb-scroll-wrap.can-right .tb-chev.right{display:flex}.dreamy-studio #tb-tip{position:fixed;z-index:300;pointer-events:none;background:#0f172ad9;color:#fff;padding:4px 10px;border-radius:8px;font-size:11px;font-weight:700;white-space:nowrap;opacity:0;transition:opacity .15s;transform:translate(-50%)}.dreamy-studio #tb-tip.show{opacity:1}@keyframes slideDown{0%{opacity:0;transform:translateY(-8px) scale(.96)}to{opacity:1;transform:translateY(0) scale(1)}}.dreamy-studio .tool-btn{width:46px;height:46px;border-radius:50%;border:3px solid transparent;cursor:pointer;display:flex;justify-content:center;align-items:center;font-size:19px;color:var(--tool-fg, #2d3748);box-shadow:inset 0 -3px 6px #0000001a,0 4px 8px #0000001f;transition:all .18s cubic-bezier(.4,0,.2,1);position:relative;background:var(--tool-bg, white)}.dreamy-studio .cat-transform{background:var(--cat-transform)}.dreamy-studio .cat-shape{background:var(--cat-shape)}.dreamy-studio .cat-style{background:var(--cat-art)}.dreamy-studio .cat-mode{background:var(--cat-mode)}.dreamy-studio .cat-utils{background:linear-gradient(135deg,#ddd6fe,#c4b5fd)}.dreamy-studio .cat-skeleton{background:linear-gradient(135deg,#fde68a,#fcd34d)}.dreamy-studio .tool-btn:hover{transform:translateY(-2px) scale(1.08);box-shadow:inset 0 -3px 6px #0000001a,0 8px 16px #0003}.dreamy-studio .tool-btn:active{transform:scale(.94) translateY(1px)}.dreamy-studio .tool-btn.active-cat,.dreamy-studio .tool-btn.active-tool{border-color:#fff;transform:scale(1.12);box-shadow:0 0 16px #fffffff2,inset 0 -3px 6px #0000001a}.dreamy-studio .tooltip{position:absolute;bottom:-32px;background:#0f172ad9;color:#fff;padding:4px 10px;border-radius:8px;font-size:11px;font-weight:700;opacity:0;transition:opacity .15s;pointer-events:none;white-space:nowrap;z-index:200}.dreamy-studio .tool-btn:hover .tooltip{opacity:1}.dreamy-studio #side-dock{position:absolute;right:18px;top:50%;transform:translateY(-50%);display:flex;flex-direction:column;gap:12px;pointer-events:auto;z-index:25}.dreamy-studio .side-action-btn{width:52px;height:52px;border-radius:50%;background:#ffffffd9;backdrop-filter:blur(14px);display:flex;align-items:center;justify-content:center;font-size:22px;color:#1e293b;cursor:pointer;border:2px solid white;box-shadow:0 8px 24px #00000029;transition:all .2s cubic-bezier(.175,.885,.32,1.275);position:relative}.dreamy-studio .side-action-btn:hover{transform:scale(1.12) translate(-4px);box-shadow:0 12px 28px #00000038}.dreamy-studio .side-action-btn.scope-in-btn{background:linear-gradient(135deg,#fef08a,#facc15);color:#713f12;display:none}.dreamy-studio .side-action-btn.scope-out-btn{background:linear-gradient(135deg,#86efac,#22c55e);color:#fff;display:none}.dreamy-studio .side-action-btn:hover .tooltip{opacity:1;right:60px;bottom:auto}.dreamy-studio .stats-display{position:absolute;top:18px;left:18px;z-index:30;pointer-events:none;background:#0f172abf;color:#86efac;padding:8px 12px;border-radius:10px;font-family:monospace;font-size:12px;font-weight:700;box-shadow:0 4px 12px #0003;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);border:1px solid rgba(255,255,255,.1)}.dreamy-studio .mode-badge{background:#ffffff8c;backdrop-filter:blur(12px);border:1px solid var(--glass-border);padding:8px 16px;border-radius:20px;font-weight:800;font-size:13px;color:#1e293b;cursor:pointer;box-shadow:var(--glass-shadow);transition:all .18s ease;display:flex;align-items:center;gap:8px}.dreamy-studio .mode-badge:hover{background:#fff;transform:translateY(-2px)}.dreamy-studio .mode-badge.play-active{background:#22c55e;color:#fff}.dreamy-studio .sculpt-mode-pill{display:flex;align-items:center;background:#fff9;padding:4px;border-radius:24px;gap:4px}.dreamy-studio .mode-pill-btn{width:32px;height:32px;border-radius:50%;border:none;background:transparent;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:13px;font-weight:800;color:#475569;transition:all .15s}.dreamy-studio .mode-pill-btn.active{background:#fff;color:#2563eb;box-shadow:0 2px 6px #00000026;transform:scale(1.08)}.dreamy-studio .sculpt-blend-pill{display:flex;align-items:center;gap:8px;background:#fff9;padding:4px 12px;border-radius:20px;font-size:11px;font-weight:800;color:#334155;text-transform:uppercase}.dreamy-studio .sculpt-blend-pill input[type=range]{width:75px;height:6px}.dreamy-studio #inspector-modal{position:absolute;top:90px;right:80px;width:330px;background:#ffffffa6;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #0003,inset 0 0 0 1.5px #ffffffb3;pointer-events:auto;display:none;flex-direction:column;overflow:hidden;z-index:26}.dreamy-studio #bone-tree{overflow-y:auto;flex:1}.dreamy-studio .bone-empty{padding:16px;font-size:12px;color:#64748b;line-height:1.5}.dreamy-studio #inspector-header{background:linear-gradient(90deg,#ffffffe6,#f0f4ffe6);padding:10px 16px;font-weight:800;color:#334155;cursor:grab;display:flex;justify-content:space-between;align-items:center}.dreamy-studio .tab-header{display:flex;background:#fff6;border-bottom:1px solid rgba(0,0,0,.05)}.dreamy-studio .tab-btn{flex:1;padding:9px;border:none;background:transparent;cursor:pointer;font-weight:800;font-size:12px;color:#64748b}.dreamy-studio .tab-btn.active{background:#fff;color:#2563eb;box-shadow:inset 0 -2px #3b82f6}.dreamy-studio .tab-content{display:none;flex-direction:column;gap:10px;padding:14px;max-height:480px;overflow-y:auto}.dreamy-studio .tab-content.active{display:flex}.dreamy-studio .prop-group{display:flex;flex-direction:column;gap:3px}.dreamy-studio .prop-group label,.dreamy-studio .slider-group label{font-size:11px;font-weight:800;color:#475569;text-transform:uppercase;letter-spacing:.5px;display:flex;justify-content:space-between}.dreamy-studio .vector-inputs{display:flex;gap:5px}.dreamy-studio .vector-inputs input{width:100%;background:#fff;border:1px solid #cbd5e1;border-radius:8px;padding:5px;font-size:12px;font-weight:700;text-align:center;color:#1e293b}.dreamy-studio input[type=range]{width:100%;cursor:pointer;accent-color:#3b82f6}.dreamy-studio .fleck-shape-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}.dreamy-studio .fleck-shape-btn{border:1px solid #cbd5e1;background:#fff;border-radius:8px;padding:6px;font-weight:800;font-size:11px;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:4px;color:#475569;transition:all .15s}.dreamy-studio .fleck-shape-btn.active{background:#eff6ff;border-color:#3b82f6;color:#2563eb}.dreamy-studio .color-picker-grid{display:grid;grid-template-columns:repeat(9,1fr);gap:4px}.dreamy-studio .swatch-row{display:flex;align-items:center;gap:5px}.dreamy-studio .color-swatch.fixed{box-shadow:0 0 0 1.5px #0f172a59,0 2px 5px #00000026}.dreamy-studio .color-swatch{width:100%;aspect-ratio:1;border-radius:50%;cursor:pointer;border:2px solid white;box-shadow:0 2px 5px #00000026;transition:transform .15s}.dreamy-studio .color-swatch:hover{transform:scale(1.18)}.dreamy-studio .color-swatch.brush-active{outline:2px solid #22d3ee;outline-offset:1px}.dreamy-studio .brush-color-chip{display:flex;align-items:center;gap:6px;margin-left:8px}.dreamy-studio .hex-chip{font-size:11px;color:#475569;background:#fff;border:1px solid #cbd5e1;border-radius:6px;padding:3px 6px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace}.dreamy-studio .match-btn{background:#fff;border:1px solid #cbd5e1;border-radius:6px;padding:4px 8px;font-size:10px;font-weight:800;color:#2563eb;cursor:pointer;transition:all .15s}.dreamy-studio .match-btn:hover{background:#eff6ff;border-color:#3b82f6}.dreamy-studio #toast{position:absolute;bottom:24px;left:50%;transform:translate(-50%) translateY(40px);background:#0f172ae0;color:#fff;padding:9px 20px;border-radius:20px;font-weight:700;font-size:13px;opacity:0;transition:all .25s cubic-bezier(.175,.885,.32,1.275);pointer-events:none;z-index:100;box-shadow:0 10px 25px #0003}.dreamy-studio #toast.show{opacity:1;transform:translate(-50%) translateY(0)}.dreamy-studio .stamp-stepper{display:flex;align-items:center;background:#fff9;padding:2px 8px;border-radius:16px;gap:6px;font-weight:800;font-size:12px;color:#334155}.dreamy-studio .stepper-btn{background:none;border:none;cursor:pointer;font-size:12px;color:#2563eb;padding:2px 4px}.dreamy-studio #stamp-list-toggle:hover .tooltip{right:auto;left:60px}.dreamy-studio #left-stack{position:absolute;left:18px;bottom:24px;display:flex;flex-direction:column;align-items:flex-start;gap:12px;pointer-events:none;z-index:70;max-height:calc(100vh - 48px)}.dreamy-studio #stamp-panel{position:relative;width:286px;max-height:calc(100vh - 140px);background:#ffffffa6;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #0003,inset 0 0 0 1.5px #ffffffb3;pointer-events:auto;display:none;flex-direction:column;overflow:hidden;z-index:25}.dreamy-studio #bone-panel{position:relative;width:286px;max-height:calc(100vh - 400px);background:#ffffffa6;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #0003,inset 0 0 0 1.5px #ffffffb3;pointer-events:auto;display:none;flex-direction:column;overflow:hidden;z-index:26}.dreamy-studio #bone-info{display:flex;flex-direction:column;gap:6px;padding:0 12px 12px;font-size:11px;font-weight:700;color:#475569}.dreamy-studio #object-panel{position:relative;width:250px;max-height:250px;background:#ffffffa6;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #0003,inset 0 0 0 1.5px #ffffffb3;pointer-events:auto;display:none;flex-direction:column;overflow:hidden;z-index:24}.dreamy-studio #object-tree{display:flex;flex-direction:column;gap:5px;padding:10px;overflow-y:auto}.dreamy-studio .chev{width:14px;text-align:center;color:#64748b;font-size:10px;cursor:pointer;flex-shrink:0}.dreamy-studio #object-toggle:hover .tooltip,.dreamy-studio #bone-toggle:hover .tooltip{right:auto;left:60px}.dreamy-studio .sp-header{background:linear-gradient(90deg,#ffffffe6,#f0f4ffe6);padding:10px 16px;font-weight:800;color:#334155;display:flex;justify-content:space-between;align-items:center}.dreamy-studio .sp-header i.clickable{cursor:pointer;color:#64748b}.dreamy-studio .sp-header i.clickable:hover{color:#1e293b}.dreamy-studio #stamp-list{display:flex;flex-direction:column;gap:6px;padding:10px;overflow-y:auto}.dreamy-studio .stamp-row{display:flex;align-items:center;gap:7px;padding:6px 8px;border-radius:14px;background:#ffffffb3;border:2px solid transparent;cursor:pointer;font-weight:800;font-size:12px;color:#334155;transition:all .15s}.dreamy-studio .stamp-row:hover{background:#fff}.dreamy-studio .stamp-row.selected{border-color:#3b82f6;background:#eff6ff}.dreamy-studio .stamp-row.drop-target,.dreamy-studio #object-panel.drop-target{outline:2px dashed #3b82f6;outline-offset:-2px}.dreamy-studio .stamp-ico{width:26px;height:26px;border-radius:50%;background:#fef08a;display:flex;align-items:center;justify-content:center;font-size:12px;flex-shrink:0}.dreamy-studio .stamp-name{flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dreamy-studio .stamp-mode{min-width:20px;height:20px;border-radius:10px;color:#fff;font-size:11px;display:flex;align-items:center;justify-content:center;padding:0 5px}.dreamy-studio .stamp-dot{width:16px;height:16px;border-radius:50%;border:2px solid white;box-shadow:0 1px 4px #00000040;flex-shrink:0}.dreamy-studio .stamp-btn{width:26px;height:26px;border-radius:50%;border:none;background:#e2e8f0;color:#475569;cursor:pointer;font-size:11px;display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:all .15s}.dreamy-studio .stamp-btn:hover{background:#bfdbfe;color:#1d4ed8}.dreamy-studio .stamp-btn.del:hover{background:#fecaca;color:#b91c1c}.dreamy-studio #stamp-props{position:absolute;left:322px;top:90px;width:260px;background:#ffffffb3;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #0003,inset 0 0 0 1.5px #ffffffb3;pointer-events:auto;display:none;flex-direction:column;overflow:hidden;z-index:26}.dreamy-studio .sp-body{display:flex;flex-direction:column;gap:10px;padding:14px}.dreamy-studio .sp-body label{font-size:11px;font-weight:800;color:#475569;text-transform:uppercase;letter-spacing:.5px;display:flex;justify-content:space-between}.dreamy-studio .sp-delete{border:none;border-radius:12px;padding:8px;background:#fecaca;color:#b91c1c;font-weight:800;font-size:12px;cursor:pointer}.dreamy-studio .sp-delete:hover{background:#fca5a5}.dreamy-studio .stamp-row.group{background:#fbcfe88c}.dreamy-studio .stamp-row.group:hover{background:#fbcfe8d9}.dreamy-studio .stamp-row.group.selected{background:#fdf2f8;border-color:#ec4899}.dreamy-studio .stamp-row.member{margin-left:18px;padding:4px 8px;background:#ffffff80;font-size:11px}.dreamy-studio .stamp-row.member .stamp-ico{width:22px;height:22px;font-size:10px}.dreamy-studio .sp-lock{flex:1;border:none;border-radius:12px;padding:8px;background:#fce7f3;color:#be185d;font-weight:800;font-size:12px;cursor:pointer}.dreamy-studio .sp-lock:hover{background:#fbcfe8}.dreamy-studio #marquee{position:fixed;display:none;pointer-events:none;z-index:15;border:1.5px dashed #2563eb;background:#3b82f629;border-radius:4px;box-shadow:0 0 0 1px #ffffff8c}.dreamy-studio #select-hint{display:none;pointer-events:none;background:#0f172acc;color:#fff;padding:6px 14px;border-radius:14px;font-size:12px;font-weight:700;white-space:nowrap;box-shadow:0 6px 16px #0003}.dreamy-studio #select-hint.show{display:block}.dreamy-studio #select-hint kbd{background:#fff3;border-radius:5px;padding:1px 6px;font-family:inherit;font-weight:800}.dreamy-studio #rig-modal{position:fixed;inset:0;display:none;align-items:center;justify-content:center;background:#0f172a59;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);z-index:10000;pointer-events:auto}.dreamy-studio .rig-card{width:min(560px,94vw);max-height:90vh;overflow-y:auto;background:#ffffffbf;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #00000040,inset 0 0 0 1.5px #ffffffb3}.dreamy-studio #rig-grid{display:grid;grid-template-columns:repeat(6,1fr);gap:12px 6px}.dreamy-studio .rig-opt{display:flex;flex-direction:column;align-items:center;gap:5px;cursor:pointer}.dreamy-studio .rig-opt .tool-btn{width:54px;height:54px;font-size:26px}.dreamy-studio .rig-opt span{font-size:11px;font-weight:800;color:#475569;text-align:center;line-height:1.1}.dreamy-studio .rig-opt.selected .tool-btn{border-color:#3b82f6;transform:scale(1.12);box-shadow:0 0 16px #3b82f68c,inset 0 -3px 6px #0000001a}.dreamy-studio .rig-opt.selected span{color:#2563eb}.dreamy-studio #rig-info{background:#fff9;border-radius:14px;padding:10px 12px;font-size:12px;font-weight:700;color:#475569;min-height:62px}.dreamy-studio #rig-info b{color:#1e293b;font-size:13px}.dreamy-studio .cat-decal{background:linear-gradient(135deg,#fecaca,#fda4af)}.dreamy-studio .tool-btn img{pointer-events:none}.dreamy-studio #help-btn{position:fixed;right:18px;bottom:18px;width:46px;height:46px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:18px;color:#334155;background:#ffffffbf;backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:2px solid white;box-shadow:0 8px 24px #00000029;cursor:pointer;pointer-events:auto;z-index:30;transition:transform .2s cubic-bezier(.175,.885,.32,1.275),background .15s}.dreamy-studio #help-btn:hover{transform:scale(1.1);background:#fff}.dreamy-studio #help-btn.active{background:#bfdbfe}.dreamy-studio #help-panel{position:fixed;right:18px;bottom:76px;width:380px;max-width:calc(100vw - 36px);max-height:min(70vh,640px);flex-direction:column;background:#ffffffc7;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border:2px solid white;border-radius:22px;box-shadow:0 16px 40px #0003;overflow:hidden;pointer-events:auto;z-index:71;font-size:12px;color:#334155}.dreamy-studio #help-body{overflow-y:auto;padding:6px 14px 14px}.dreamy-studio .help-section{margin:12px 0 4px;font-weight:900;font-size:11px;letter-spacing:.06em;text-transform:uppercase;color:#64748b}.dreamy-studio .help-row{display:flex;gap:10px;padding:4px 0;border-bottom:1px solid rgba(0,0,0,.05);align-items:baseline}.dreamy-studio .help-keys{flex:0 0 44%;font-weight:800}.dreamy-studio .help-desc{flex:1;font-weight:600}.dreamy-studio #help-panel kbd{display:inline-block;min-width:18px;padding:1px 6px;margin:0 2px 2px 0;border-radius:6px;border:1px solid #cbd5e1;border-bottom-width:2px;background:#fff;font-family:inherit;font-size:11px;font-weight:800;text-align:center;color:#1e293b}.dreamy-studio .esc-hint{position:absolute;right:62px;top:50%;transform:translateY(-50%);padding:6px 12px 8px;border-radius:14px;background:#0f172ad9;box-shadow:0 6px 16px #0003;color:#fff;font-size:12px;font-weight:700;white-space:nowrap;pointer-events:none;transition:opacity .15s}.dreamy-studio .esc-hint kbd{background:#fff3;border-radius:5px;padding:1px 6px;font-family:inherit;font-weight:800}.dreamy-studio .esc-hint-bar{margin-top:5px;height:4px;border-radius:2px;background:#ffffff40;overflow:hidden}.dreamy-studio .esc-hint-bar i{display:block;width:0;height:100%;background:#86efac}.dreamy-studio .esc-hint.holding{background:#15803deb}.dreamy-studio #scope-out-side-btn:hover .esc-hint{opacity:0}.dreamy-studio.hints-off #select-hint,.dreamy-studio.hints-off #help-btn,.dreamy-studio.hints-off .esc-hint:not(.holding){display:none!important}.dreamy-studio .tb-bar-wrap{flex:1 1 auto;min-width:0}.dreamy-studio .tb-bar-wrap>.tb-chev.left{left:-10px}.dreamy-studio .tb-bar-wrap>.tb-chev.right{right:-10px}.dreamy-studio .tb-scroll>.tb-scroll-wrap:not(.tb-bar-wrap){flex-shrink:1}@media(hover:none){.dreamy-studio #tb-tip{display:none}}.dreamy-studio #touch-mods{display:none;gap:8px;justify-content:center;pointer-events:auto}.dreamy-studio{--bars-h: 130px}.dreamy-studio.compact #ui-layer{justify-content:flex-end;padding:0 0 calc(8px + env(safe-area-inset-bottom,0px))}.dreamy-studio.compact .toolbar-group{flex-direction:column-reverse;width:100%;padding:0 6px;gap:6px;pointer-events:none}.dreamy-studio.compact .toolbar,.dreamy-studio.compact #touch-mods.show{pointer-events:auto}.dreamy-studio.compact #touch-mods.show{display:flex}.dreamy-studio.compact .toolbar{width:100%;max-width:100%;padding:4px 12px;border-radius:26px;gap:6px}.dreamy-studio.compact .sub-toolbar{padding:4px 12px}.dreamy-studio.compact .tb-scroll{gap:6px}.dreamy-studio.compact .tb-scroll-wrap:not(.tb-bar-wrap),.dreamy-studio.compact .tb-scroll:not(.tb-whole){display:contents}.dreamy-studio.compact .tb-whole>*,.dreamy-studio.compact .tb-whole .tb-scroll>*{flex-shrink:0}.dreamy-studio.compact .tb-whole>:first-child{margin-left:auto}.dreamy-studio.compact .tb-whole>:last-child{margin-right:auto}.dreamy-studio.compact .tb-chev{display:none!important}.dreamy-studio.compact .tool-btn{width:42px;height:42px;font-size:17px}.dreamy-studio.compact #select-hint,.dreamy-studio.compact .esc-hint{display:none!important}.dreamy-studio.compact #left-stack{left:8px;bottom:calc(var(--bars-h) + 8px);max-height:none}.dreamy-studio.compact #side-dock{top:auto;right:8px;bottom:calc(var(--bars-h) + 8px);transform:none;flex-direction:row-reverse;gap:8px}.dreamy-studio.compact .side-action-btn{width:46px;height:46px;font-size:18px}.dreamy-studio.compact #stamp-size-panel{left:50%!important;right:auto!important;top:auto!important;bottom:calc(var(--bars-h) + 62px)!important;transform:translate(-50%);flex-direction:row!important;padding:6px 12px!important;gap:8px!important;border-radius:26px!important}.dreamy-studio.compact #stamp-size-panel #stamp-size-down{order:1}.dreamy-studio.compact #stamp-size-panel #stamp-size-v{order:2;writing-mode:horizontal-tb!important;direction:ltr!important;width:120px!important;height:10px!important;margin:0 4px!important}.dreamy-studio.compact #stamp-size-panel #stamp-size-up{order:3}.dreamy-studio.compact #stamp-size-panel #stamp-size-val{order:4;min-width:30px;text-align:center}.dreamy-studio.compact #help-btn{top:calc(10px + env(safe-area-inset-top,0px));bottom:auto;right:10px;width:40px;height:40px;font-size:16px}.dreamy-studio.compact #toast{top:calc(12px + env(safe-area-inset-top,0px));bottom:auto;transform:translate(-50%) translateY(-30px);max-width:calc(100vw - 80px);text-align:center}.dreamy-studio.compact #toast.show{transform:translate(-50%) translateY(0)}.dreamy-studio.compact #inspector-modal,.dreamy-studio.compact #stamp-panel,.dreamy-studio.compact #bone-panel,.dreamy-studio.compact #object-panel,.dreamy-studio.compact #stamp-props,.dreamy-studio.compact #palette-panel,.dreamy-studio.compact #help-panel,.dreamy-studio.compact #voxel-panel{position:fixed!important;left:6px!important;right:6px!important;top:auto!important;bottom:calc(var(--bars-h) + 8px)!important;width:auto!important;max-width:none!important;margin:0!important;transform:none!important;max-height:min(48vh,calc(100dvh - var(--bars-h) - 70px))!important;overflow-y:auto!important;z-index:80!important}.dreamy-studio.compact .sheet-hidden{display:none!important}.dreamy-studio.compact .sp-header,.dreamy-studio.compact #inspector-header{position:sticky;top:0;z-index:3;cursor:default}.dreamy-studio.compact #stamp-list,.dreamy-studio.compact #bone-tree,.dreamy-studio.compact #object-tree,.dreamy-studio.compact .tab-content{max-height:none;overflow:visible}.dreamy-studio.compact.sheet-open #side-dock,.dreamy-studio.compact.sheet-open #stamp-size-panel,.dreamy-studio.compact.sheet-open #left-stack>.side-action-btn{display:none!important}.dreamy-studio .decal-edit{position:absolute;top:-5px;right:-5px;width:18px;height:18px;border-radius:50%;background:#fff;color:#475569;font-size:9px;display:flex;align-items:center;justify-content:center;box-shadow:0 1px 4px #0000004d}.dreamy-studio .decal-edit:hover{background:#bfdbfe;color:#1e3a8a}.dreamy-studio.compact .decal-edit{width:24px;height:24px;top:-7px;right:-7px;font-size:11px}.dreamy-studio #toast{z-index:10100}.dreamy-studio #decal-editor{position:fixed;inset:0;display:none;align-items:center;justify-content:center;background:#0f172a73;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);z-index:10000;pointer-events:auto;user-select:none;-webkit-user-select:none}.dreamy-studio .de-card{width:min(1000px,96vw);height:min(660px,94vh);display:flex;flex-direction:column;background:#ffffffdb;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #00000040,inset 0 0 0 1.5px #ffffffb3;overflow:hidden}.dreamy-studio .de-head,.dreamy-studio .de-foot{display:flex;align-items:center;gap:8px;padding:10px 14px;background:linear-gradient(90deg,#ffffffe6,#f0f4ffe6);flex-shrink:0}.dreamy-studio .de-title{font-weight:800;color:#334155;white-space:nowrap}.dreamy-studio .de-title i{margin-right:6px}.dreamy-studio #de-name{flex:1;min-width:0;border:1.5px solid #cbd5e1;border-radius:10px;padding:6px 10px;font-weight:700;font-size:13px;font-family:inherit;color:#1e293b;background:#fff;user-select:text;-webkit-user-select:text}.dreamy-studio .de-body{flex:1;min-height:0;display:grid;grid-template-columns:52px minmax(0,1fr) 236px;gap:10px;padding:10px}.dreamy-studio .de-tools{display:flex;flex-direction:column;align-items:center;gap:6px;overflow-y:auto}.dreamy-studio .de-sep{width:24px;height:1.5px;background:#cbd5e1;flex-shrink:0;margin:2px 0}.dreamy-studio .de-btn{width:40px;height:40px;flex-shrink:0;border:2px solid transparent;border-radius:12px;background:#fff;color:#334155;display:flex;align-items:center;justify-content:center;cursor:pointer;font-size:16px;box-shadow:0 2px 6px #0000001f;padding:0;transition:transform .12s,background .12s}.dreamy-studio .de-btn:hover:not(:disabled){background:#eff6ff}.dreamy-studio .de-btn:active:not(:disabled){transform:scale(.93)}.dreamy-studio .de-btn:disabled{opacity:.35;cursor:default}.dreamy-studio .de-btn.on{background:#bfdbfe;border-color:#3b82f6;color:#1e3a8a}.dreamy-studio .de-btn.sm{width:34px;height:34px;font-size:14px;border-radius:10px}.dreamy-studio .de-btn.de-done{background:#bbf7d0;color:#166534}.dreamy-studio .de-btn svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linejoin:round;stroke-linecap:round}.dreamy-studio .de-btn.sm svg{width:18px;height:18px}.dreamy-studio .de-stage{position:relative;min-width:0;min-height:0;display:flex;align-items:center;justify-content:center;padding:22px 22px 30px}.dreamy-studio #de-svg{height:100%;max-width:100%;aspect-ratio:1;overflow:visible;touch-action:none;border-radius:6px;box-shadow:0 4px 18px #0f172a38;cursor:crosshair;background:#fff}.dreamy-studio #de-hint{position:absolute;left:0;right:0;bottom:4px;text-align:center;font-size:11px;font-weight:700;color:#64748b;pointer-events:none}.dreamy-studio .de-side{display:flex;flex-direction:column;gap:8px;overflow-y:auto;padding-right:2px}.dreamy-studio .de-sec{background:#ffffffa6;border-radius:14px;padding:8px 10px;display:flex;flex-direction:column;gap:8px}.dreamy-studio .de-row{display:flex;align-items:center;gap:6px}.dreamy-studio .de-row.wrap{flex-wrap:wrap}.dreamy-studio .de-lbl{font-size:11px;font-weight:800;color:#475569;display:flex;flex-direction:column;gap:3px;flex:1;min-width:0}.dreamy-studio .de-lbl b{color:#1e293b}.dreamy-studio .de-lbl select,.dreamy-studio .de-lbl input[type=number]{border:1.5px solid #cbd5e1;border-radius:8px;padding:4px 6px;font-weight:700;font-size:12px;font-family:inherit;background:#fff;width:100%}.dreamy-studio .de-target{flex:1;display:flex;align-items:center;gap:6px;border:2px solid transparent;border-radius:10px;background:#fff;padding:4px 8px;font-weight:800;font-size:12px;font-family:inherit;color:#334155;cursor:pointer;box-shadow:0 2px 6px #0000001f}.dreamy-studio .de-target.on{border-color:#3b82f6;background:#eff6ff}.dreamy-studio .de-chip{width:18px;height:18px;border-radius:50%;border:2px solid #fff;box-shadow:0 0 0 1.5px #94a3b8;flex-shrink:0}.dreamy-studio .de-chip.none{background:linear-gradient(135deg,#fff 44%,#ef4444 44% 56%,#fff 56%)}.dreamy-studio .de-swatches{flex-wrap:wrap}.dreamy-studio .de-pv{flex-direction:row;align-items:center;gap:10px}.dreamy-studio #de-preview{width:72px;height:72px;flex-shrink:0;border-radius:10px;background:#cbd5e1;image-rendering:auto}.dreamy-studio #de-count{font-size:11px;font-weight:800;color:#64748b}.dreamy-studio .de-foot{justify-content:flex-start}.dreamy-studio .de-act{border:none;border-radius:12px;padding:9px 16px;font-weight:800;font-size:13px;font-family:inherit;cursor:pointer;background:#fff;color:#334155;box-shadow:0 2px 6px #00000024}.dreamy-studio .de-act:hover{background:#eff6ff}.dreamy-studio .de-act.primary{background:#3b82f6;color:#fff}.dreamy-studio .de-act.primary:hover{background:#2563eb}.dreamy-studio .de-act.danger{color:#b91c1c}.dreamy-studio .de-act.danger:hover{background:#fee2e2}.dreamy-studio .de-selbox{fill:none;stroke:#3b82f6;stroke-width:1.5;stroke-dasharray:5 3}.dreamy-studio .de-handle{fill:#fff;stroke:#3b82f6;stroke-width:1.5;pointer-events:all}.dreamy-studio .de-handle.h-rot{fill:#bfdbfe;cursor:grab}.dreamy-studio .de-handle.h-nw,.dreamy-studio .de-handle.h-se{cursor:nwse-resize}.dreamy-studio .de-handle.h-ne,.dreamy-studio .de-handle.h-sw{cursor:nesw-resize}.dreamy-studio .de-handle.h-n,.dreamy-studio .de-handle.h-s{cursor:ns-resize}.dreamy-studio .de-handle.h-e,.dreamy-studio .de-handle.h-w{cursor:ew-resize}.dreamy-studio .de-node{fill:#fff;stroke:#0f172a;stroke-width:1.5;cursor:move;pointer-events:all}.dreamy-studio .de-node.on{fill:#facc15}.dreamy-studio .de-ctrl{fill:none;stroke:#94a3b8;stroke-width:1;stroke-dasharray:3 3}.dreamy-studio .de-draft{stroke:#0ea5e9;stroke-width:1.5;stroke-dasharray:5 3;fill:none}.dreamy-studio .de-dot{fill:#fff;stroke:#0ea5e9;stroke-width:1.5}.dreamy-studio .de-dot.first{fill:#bae6fd}.dreamy-studio .de-marquee{fill:#3b82f61f;stroke:#3b82f6;stroke-width:1;stroke-dasharray:4 3}.dreamy-studio.compact .de-card{width:100vw;height:100vh;height:100dvh;border-radius:0;padding-top:env(safe-area-inset-top,0px);padding-bottom:env(safe-area-inset-bottom,0px);box-sizing:border-box}.dreamy-studio.compact .de-body{display:flex;flex-direction:column;padding:6px;gap:6px}.dreamy-studio.compact .de-stage{order:1;flex:1 1 auto;min-height:170px;padding:18px 18px 22px}.dreamy-studio.compact .de-tools{order:2;flex-direction:row;overflow-x:auto;overflow-y:hidden;flex-shrink:0;padding-bottom:2px}.dreamy-studio.compact .de-sep{width:1.5px;height:24px;margin:0 2px}.dreamy-studio.compact .de-side{order:3;max-height:32vh;flex-shrink:0}.dreamy-studio.compact .de-btn{width:44px;height:44px}.dreamy-studio.compact .de-btn.sm{width:40px;height:40px}.dreamy-studio.compact #de-preview{width:64px;height:64px}.dreamy-studio.compact #de-hint{display:none}.dreamy-studio.compact .de-act{padding:11px 14px}.dreamy-studio .tool-btn.play-active{background:#22c55e;color:#fff}.dreamy-studio #scenes-modal{position:fixed;inset:0;display:none;align-items:center;justify-content:center;background:#0f172a73;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);z-index:10000;pointer-events:auto}.dreamy-studio .scn-card{width:min(640px,94vw);max-height:86vh;display:flex;flex-direction:column;background:#ffffffe0;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #00000040,inset 0 0 0 1.5px #ffffffb3;overflow:hidden}.dreamy-studio #scn-name{flex:1;min-width:0;border:1.5px solid #cbd5e1;border-radius:10px;padding:6px 10px;font-weight:700;font-size:13px;font-family:inherit;color:#1e293b;background:#fff}.dreamy-studio .scn-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px 14px 4px}.dreamy-studio .scn-note{font-size:11px;font-weight:700;color:#64748b}.dreamy-studio #scn-list{overflow-y:auto;padding:8px 14px 14px;display:flex;flex-direction:column;gap:8px}.dreamy-studio .scn-item{display:flex;align-items:center;gap:10px;background:#fffc;border:2px solid transparent;border-radius:14px;padding:6px}.dreamy-studio .scn-item.current{border-color:#3b82f6}.dreamy-studio .scn-thumb{width:96px;height:60px;flex-shrink:0;border-radius:10px;background:#cbd5e1 center / cover;display:flex;align-items:center;justify-content:center;color:#94a3b8;font-size:22px;cursor:pointer}.dreamy-studio .scn-info{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px;cursor:pointer}.dreamy-studio .scn-info b{font-size:14px;color:#1e293b;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dreamy-studio .scn-info span{font-size:11px;font-weight:700;color:#64748b}.dreamy-studio .scn-acts{display:flex;gap:4px;flex-shrink:0}.dreamy-studio .scn-empty{text-align:center;color:#64748b;font-weight:700;padding:24px}.dreamy-studio.compact .scn-card{width:100vw;max-height:100vh;height:100dvh;border-radius:0}.dreamy-studio.compact .scn-acts{flex-wrap:wrap;width:84px}.dreamy-studio.compact .scn-thumb{width:64px;height:48px}.dreamy-studio .cat-rendering{background:linear-gradient(135deg,#a7f3d0,#67e8f9)}.dreamy-studio .render-select{border:none;border-radius:14px;padding:6px 10px;font-size:12px;font-weight:800;color:#334155;background:#fff;cursor:pointer;outline:none}.dreamy-studio{position:fixed;inset:0;color:#1e293b}.dreamy-studio button,.dreamy-studio input,.dreamy-studio select{font-family:inherit}.dreamy-studio .sp-count{color:#64748b;font-weight:700}.dreamy-studio .sp-title-icon{margin-right:8px}.dreamy-studio .sp-header .clickable{background:none;border:none;padding:0;font-size:inherit;cursor:pointer;color:#64748b}.dreamy-studio .sp-header .clickable:hover{color:#1e293b}.dreamy-studio .glass-panel{position:absolute;top:150px;left:50%;transform:translate(-50%);flex-direction:column;z-index:45;pointer-events:auto;background:#ffffffb3;backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border-radius:22px;box-shadow:0 15px 35px #0003,inset 0 0 0 1.5px #ffffffb3;overflow:hidden}.dreamy-studio #voxel-panel{width:320px}.dreamy-studio #palette-inputs{display:flex;flex-wrap:wrap;gap:8px;max-width:320px}.dreamy-studio .palette-input{width:44px;height:44px;border:none;border-radius:50%;cursor:pointer;padding:0;background:none}.dreamy-studio .palette-fixed-label{flex-basis:100%;font-size:11px;font-weight:800;color:#475569;text-transform:uppercase;letter-spacing:.5px;margin-top:2px}.dreamy-studio .palette-fixed{width:44px;height:44px;border-radius:50%;border:2px solid white;box-shadow:0 2px 5px #0003;display:flex;align-items:center;justify-content:center;font-size:11px;color:#ffffffd9;text-shadow:0 0 3px rgba(0,0,0,.6)}.dreamy-studio .slot-picker{width:40px;height:34px;border:none;border-radius:6px;cursor:pointer;flex-shrink:0}.dreamy-studio .slot-picker.sm{width:30px;height:30px;background:none}.dreamy-studio .color-field-row{display:flex;gap:8px;align-items:center}.dreamy-studio .color-field-row .color-picker-grid{flex:1}.dreamy-studio .voxel-presets{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;margin-top:4px}.dreamy-studio .match-btn.active{background:#eff6ff;border-color:#3b82f6}.dreamy-studio .panel-note{font-size:11px;font-weight:700;color:#64748b;line-height:1.4;margin-top:4px}.dreamy-studio #stamp-size-panel{position:absolute;right:18px;bottom:84px;display:flex;flex-direction:column;align-items:center;gap:6px;pointer-events:auto;z-index:30;background:#fff9;backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:1px solid var(--glass-border);padding:8px 6px;border-radius:18px;box-shadow:var(--glass-shadow)}.dreamy-studio #stamp-size-panel .side-action-btn{width:38px;height:38px;font-size:16px}.dreamy-studio #stamp-size-v{writing-mode:vertical-lr;direction:rtl;width:10px;height:110px;margin:4px 0}.dreamy-studio #stamp-size-val{font-size:10px;font-weight:800;color:#334155}.dreamy-studio .slider-group{display:flex;flex-direction:column;gap:3px}.dreamy-studio .slider-group.off{opacity:.4}.dreamy-studio .region-blends{padding:10px 14px;background:#ffffff73;border-top:1px solid rgba(0,0,0,.06)}.dreamy-studio .region-blends-title{font-size:11px;font-weight:800;color:#334155;text-transform:uppercase;margin-bottom:6px}.dreamy-studio .region-blends .slider-group{margin-bottom:4px}.dreamy-studio .inspector-blends{margin-top:8px;padding-top:10px;border-top:1.5px solid rgba(0,0,0,.08)}.dreamy-studio .inspector-blends>label{color:#2563eb;font-weight:900;margin-bottom:4px}.dreamy-studio .row-inline{display:flex;gap:6px;align-items:center}.dreamy-studio .row-inline>.grow{flex:1;min-width:0}.dreamy-studio .row-inline.wrap{flex-wrap:wrap}.dreamy-studio .render-select.boxed{border:1.5px solid #cbd5e1}.dreamy-studio .render-select.grow{flex:1}.dreamy-studio .wing-seed{width:64px;border:1px solid #cbd5e1;border-radius:8px;padding:5px;font-weight:700}.dreamy-studio .wing-chip{width:14px;height:14px;border-radius:50%;display:inline-block;border:1px solid #cbd5e1;margin-right:6px}.dreamy-studio .inline-edit{flex:1;min-width:0;border:1.5px solid #3b82f6;border-radius:8px;padding:2px 6px;font-weight:800;font-size:12px;color:#1e293b;background:#fff;user-select:text;-webkit-user-select:text}.dreamy-studio .muted{color:#64748b;font-weight:700}.dreamy-studio .sym-row{display:flex;align-items:center;gap:6px;margin-bottom:6px}.dreamy-studio .sym-hint{font-weight:400;color:#64748b;font-size:10px;text-transform:none}.dreamy-studio .sym-note{font-size:10px;color:#64748b}.dreamy-studio .mode-pill-btn.wide{width:auto;padding:0 12px;border-radius:16px}.dreamy-studio .mode-pill-btn:disabled,.dreamy-studio .tool-btn:disabled{opacity:.4;cursor:default}.dreamy-studio .rig-body-row{display:flex;align-items:center;gap:8px;font-size:12px;font-weight:800;color:#475569}.dreamy-studio .rig-actions{display:flex;gap:8px}.dreamy-studio .decal-depth{display:flex;align-items:center;gap:4px;font-size:11px;font-weight:700;color:#475569}.dreamy-studio .decal-depth input{width:80px}.dreamy-studio .tool-btn .decal-thumb{width:30px;height:30px}.dreamy-studio .de-preview-svg{width:72px;height:72px;flex-shrink:0;border-radius:10px;background:#cbd5e1}.dreamy-studio.compact .de-preview-svg{width:64px;height:64px}.dreamy-studio .de-btn.confirm{background:#fecaca;color:#b91c1c}.dreamy-studio .stamp-ico svg{width:16px;height:16px}.dreamy-studio .tool-btn>svg{width:20px;height:20px}.dreamy-studio .tool-btn.on-state{background:#22c55e;color:#fff}.dreamy-studio .scn-git-toggle{position:relative}.dreamy-studio .scn-git-toggle.active{background:#eff6ff;box-shadow:inset 0 0 0 2px #3b82f6}.dreamy-studio .scn-git-dot{position:absolute;top:5px;right:5px;width:7px;height:7px;border-radius:50%;background:#22c55e}.dreamy-studio .scn-git-dot.syncing{background:#f59e0b}.dreamy-studio .scn-git-dot.error{background:#ef4444}.dreamy-studio .scn-git{margin:8px 14px 2px;padding:10px 12px;display:flex;flex-direction:column;gap:8px;background:#ffffffbf;border-radius:14px;box-shadow:inset 0 0 0 1.5px #e2e8f0}.dreamy-studio .scn-git-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:13px;color:#1e293b}.dreamy-studio .scn-git-row>span{font-size:11px;font-weight:700;color:#64748b}.dreamy-studio .scn-git-tab{border:none;border-radius:10px;padding:6px 14px;font:inherit;font-size:12px;font-weight:800;cursor:pointer;background:#f1f5f9;color:#475569}.dreamy-studio .scn-git-tab.active{background:#3b82f6;color:#fff}.dreamy-studio .scn-git-field{display:flex;flex-direction:column;gap:3px;min-width:0;font-size:11px;font-weight:800;color:#64748b}.dreamy-studio .scn-git-field.grow{flex:1}.dreamy-studio .scn-git-field input{border:1.5px solid #cbd5e1;border-radius:10px;padding:6px 10px;font:inherit;font-size:13px;font-weight:700;color:#1e293b;background:#fff;min-width:0}.dreamy-studio .scn-git-hint{font-size:11px;font-weight:600;color:#64748b}.dreamy-studio .scn-git-hint a{color:#2563eb}.dreamy-studio .scn-git-status{font-size:12px;font-weight:700;color:#475569}.dreamy-studio .scn-git-status.error{color:#b91c1c}.dreamy-studio .scn-git button[disabled]{opacity:.55;cursor:default}.dreamy-studio .tg-toggle{border:none;background:none;padding:0;font:inherit;font-weight:800;color:#2563eb;cursor:pointer}.dreamy-studio .token-guide{display:flex;flex-direction:column;gap:8px;padding:10px;border-radius:12px;background:#f8fafc;box-shadow:inset 0 0 0 1.5px #e2e8f0;font-size:12px;color:#334155;max-height:46vh;overflow-y:auto}.dreamy-studio .tg-tabs{display:flex;flex-wrap:wrap;gap:6px}.dreamy-studio .tg-tab{border:none;border-radius:9px;padding:5px 10px;font:inherit;font-size:11px;font-weight:800;cursor:pointer;background:#e2e8f0;color:#475569}.dreamy-studio .tg-tab.active{background:#6366f1;color:#fff}.dreamy-studio .tg-table-wrap{overflow-x:auto}.dreamy-studio .tg-table{width:100%;border-collapse:collapse;font-size:11px}.dreamy-studio .tg-table th,.dreamy-studio .tg-table td{text-align:left;padding:5px 6px;border-bottom:1px solid #e2e8f0;vertical-align:top}.dreamy-studio .tg-table th{color:#64748b;font-weight:800}.dreamy-studio .tg-step{display:flex;flex-direction:column;gap:4px;padding:8px 10px;border-radius:10px;background:#fff;box-shadow:inset 0 0 0 1px #e2e8f0}.dreamy-studio .tg-step+.tg-step{margin-top:6px}.dreamy-studio .tg-head{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}.dreamy-studio .tg-link{font-weight:800;color:#2563eb;white-space:nowrap}.dreamy-studio .token-guide ol{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:3px}.dreamy-studio .token-guide code{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:11px;padding:0 4px;border-radius:4px;background:#ecfdf5;color:#047857}.dreamy-studio .tg-note{margin:4px 0 0;color:#475569}.dreamy-studio .tg-warn{margin-top:4px;padding:7px 9px;border-radius:8px;background:#fffbeb;box-shadow:inset 0 0 0 1px #fcd34d;color:#78350f}.dreamy-studio .tg-perms{margin:4px 0 0;font-size:11px}.dreamy-studio .tg-perms dt{margin-top:6px;font-weight:800;color:#b45309}.dreamy-studio .tg-perms dd{margin:2px 0 0 10px}
@@ -0,0 +1,7 @@
1
+ import type { DecalCommand } from "./decal-commands.js";
2
+ import type { PaletteCommand } from "./palette-commands.js";
3
+ import type { RigCommand } from "./rig-commands.js";
4
+ import type { SceneCommand } from "./scene-commands.js";
5
+ import type { SculptCommand } from "./sculpt-commands.js";
6
+ /** An intent. Dispatch accepts it (appending events) or rejects it with a reason. */
7
+ export type Command = SceneCommand | SculptCommand | DecalCommand | PaletteCommand | RigCommand;
@@ -0,0 +1,35 @@
1
+ import type { Id } from "../id.js";
2
+ import type { Decal, DesignShape } from "../model/decal.js";
3
+ import type { SculptTarget } from "./target.js";
4
+ /** Places decals (one click, or a premade's face). The core assigns ids and enforces the limits. */
5
+ export type AddDecals = {
6
+ readonly type: "AddDecals";
7
+ readonly payload: {
8
+ readonly target: SculptTarget;
9
+ readonly decals: readonly Omit<Decal, "id">[];
10
+ };
11
+ };
12
+ export type RemoveDecal = {
13
+ readonly type: "RemoveDecal";
14
+ readonly payload: {
15
+ readonly target: SculptTarget;
16
+ readonly decalId: Id;
17
+ };
18
+ };
19
+ /** Creates a design (no id) or replaces one (with id). */
20
+ export type SaveDesign = {
21
+ readonly type: "SaveDesign";
22
+ readonly payload: {
23
+ readonly designId?: Id;
24
+ readonly name: string;
25
+ readonly shapes: readonly DesignShape[];
26
+ };
27
+ };
28
+ /** Rejected while a decal still uses the design. */
29
+ export type DeleteDesign = {
30
+ readonly type: "DeleteDesign";
31
+ readonly payload: {
32
+ readonly designId: Id;
33
+ };
34
+ };
35
+ export type DecalCommand = AddDecals | RemoveDecal | SaveDesign | DeleteDesign;
@@ -0,0 +1,14 @@
1
+ import type { PaletteSlot, Rgb } from "../model/palette.js";
2
+ export type SetPaletteColor = {
3
+ readonly type: "SetPaletteColor";
4
+ readonly payload: {
5
+ readonly slot: PaletteSlot;
6
+ readonly color: Rgb;
7
+ };
8
+ };
9
+ /** Back to the default palette. */
10
+ export type ResetPalette = {
11
+ readonly type: "ResetPalette";
12
+ readonly payload: Record<string, never>;
13
+ };
14
+ export type PaletteCommand = SetPaletteColor | ResetPalette;
@@ -0,0 +1,229 @@
1
+ import type { Id } from "../id.js";
2
+ import type { Transform, Vec3 } from "../model/math.js";
3
+ import type { BodyRegion, CreatureRecipe, CreatureTheme, GraftSlot, PartSlot, PosePresetId, RigMode } from "../model/rig.js";
4
+ import type { FlatWing } from "../model/wing.js";
5
+ /** An empty rig, ready for bones. */
6
+ export type CreateRig = {
7
+ readonly type: "CreateRig";
8
+ readonly payload: {
9
+ readonly name?: string;
10
+ readonly transform: Transform;
11
+ };
12
+ };
13
+ /**
14
+ * Applies a premade skeleton: a new rig at a spot, or the selected object's skeleton replaced and fitted to
15
+ * its bounds (`fit`: the content's center and half-size in the object's space). `withBody` builds the
16
+ * template's body parts (generated or baked) and face decals.
17
+ */
18
+ export type ApplyPremade = {
19
+ readonly type: "ApplyPremade";
20
+ readonly payload: {
21
+ readonly templateId: string;
22
+ readonly target: {
23
+ readonly kind: "new";
24
+ readonly transform: Transform;
25
+ } | {
26
+ readonly kind: "object";
27
+ readonly objectId: Id;
28
+ readonly fit: {
29
+ readonly center: Vec3;
30
+ readonly halfSize: Vec3;
31
+ };
32
+ };
33
+ readonly withBody: boolean;
34
+ };
35
+ };
36
+ /** Adds a bone whose head sits at `head` (rig space, bind pose). With mirror on, the partner is added too. */
37
+ export type AddBone = {
38
+ readonly type: "AddBone";
39
+ readonly payload: {
40
+ readonly rigId: Id;
41
+ readonly parentId?: Id;
42
+ readonly name?: string;
43
+ readonly head: Vec3;
44
+ };
45
+ };
46
+ /** Removes a bone; its children move to its parent. Its part goes with it. */
47
+ export type RemoveBone = {
48
+ readonly type: "RemoveBone";
49
+ readonly payload: {
50
+ readonly rigId: Id;
51
+ readonly boneId: Id;
52
+ };
53
+ };
54
+ export type ReparentBone = {
55
+ readonly type: "ReparentBone";
56
+ readonly payload: {
57
+ readonly rigId: Id;
58
+ readonly boneId: Id;
59
+ readonly parentId: Id | null;
60
+ };
61
+ };
62
+ export type RenameBone = {
63
+ readonly type: "RenameBone";
64
+ readonly payload: {
65
+ readonly rigId: Id;
66
+ readonly boneId: Id;
67
+ readonly name: string;
68
+ };
69
+ };
70
+ export type SetBoneTags = {
71
+ readonly type: "SetBoneTags";
72
+ readonly payload: {
73
+ readonly rigId: Id;
74
+ readonly boneId: Id;
75
+ readonly tags: readonly string[];
76
+ };
77
+ };
78
+ /** Names like "Arm L", "Left Arm" become side + mirror tags. */
79
+ export type AutoTagSides = {
80
+ readonly type: "AutoTagSides";
81
+ readonly payload: {
82
+ readonly rigId: Id;
83
+ };
84
+ };
85
+ /**
86
+ * One bone drag (move, rotate or scale), in the current mode: rig mode writes the bind, pose mode the
87
+ * pose. With mirror on, the core writes the partners too.
88
+ */
89
+ export type SetBoneTransforms = {
90
+ readonly type: "SetBoneTransforms";
91
+ readonly payload: {
92
+ readonly rigId: Id;
93
+ readonly changes: readonly {
94
+ readonly boneId: Id;
95
+ readonly transform: Transform;
96
+ }[];
97
+ };
98
+ };
99
+ export type ResetPose = {
100
+ readonly type: "ResetPose";
101
+ readonly payload: {
102
+ readonly rigId: Id;
103
+ };
104
+ };
105
+ export type SetRigMode = {
106
+ readonly type: "SetRigMode";
107
+ readonly payload: {
108
+ readonly rigId: Id;
109
+ readonly mode: RigMode;
110
+ };
111
+ };
112
+ export type SetRigMirror = {
113
+ readonly type: "SetRigMirror";
114
+ readonly payload: {
115
+ readonly rigId: Id;
116
+ readonly mirror: boolean;
117
+ };
118
+ };
119
+ export type SetRegionBlend = {
120
+ readonly type: "SetRegionBlend";
121
+ readonly payload: {
122
+ readonly rigId: Id;
123
+ readonly region: BodyRegion;
124
+ readonly blend: number;
125
+ };
126
+ };
127
+ /** Gives a bone a generated part (a knob to sculpt from, or a flat wing for a wing chain root). */
128
+ export type AddBodyPart = {
129
+ readonly type: "AddBodyPart";
130
+ readonly payload: {
131
+ readonly rigId: Id;
132
+ readonly boneId: Id;
133
+ };
134
+ };
135
+ export type RemoveBodyPart = {
136
+ readonly type: "RemoveBodyPart";
137
+ readonly payload: {
138
+ readonly rigId: Id;
139
+ readonly boneId: Id;
140
+ };
141
+ };
142
+ /** Wing tab edits: the patch goes to every listed wing (and their mirror twins when mirror is on). */
143
+ export type SetFlatWings = {
144
+ readonly type: "SetFlatWings";
145
+ readonly payload: {
146
+ readonly rigId: Id;
147
+ readonly boneIds: readonly Id[];
148
+ readonly wing: Partial<Omit<FlatWing, "frame">>;
149
+ };
150
+ };
151
+ /**
152
+ * Poses a premade rig from its presets: `a`, or `a` blended toward `b` by `t` (0–1). Writes every bone's pose and
153
+ * remembers the choice on the rig. Custom needs a hand-posed pose to exist.
154
+ */
155
+ export type ApplyPosePreset = {
156
+ readonly type: "ApplyPosePreset";
157
+ readonly payload: {
158
+ readonly rigId: Id;
159
+ readonly a: PosePresetId;
160
+ readonly b?: PosePresetId;
161
+ readonly t: number;
162
+ };
163
+ };
164
+ /**
165
+ * Bone proportions (slider releases): each change sets a bone's length and / or thickness (0.4–2.5; a head 1–2.5).
166
+ * Length moves the bone's child joints; with mirror on, partners get the same size.
167
+ */
168
+ export type SetBoneSizes = {
169
+ readonly type: "SetBoneSizes";
170
+ readonly payload: {
171
+ readonly rigId: Id;
172
+ readonly changes: readonly {
173
+ readonly boneId: Id;
174
+ readonly length?: number;
175
+ readonly thickness?: number;
176
+ }[];
177
+ };
178
+ };
179
+ /**
180
+ * Gives a premade rig's slot the parts of another premade (`kit`: its template id; the rig's own template restores
181
+ * its own parts) or of a part variant (`kit`: its id, e.g. "head:tiger"). The parts are fitted to the rig's bones: chains by direction and length, a head by its size.
182
+ */
183
+ export type SwapPartSlot = {
184
+ readonly type: "SwapPartSlot";
185
+ readonly payload: {
186
+ readonly rigId: Id;
187
+ readonly slot: PartSlot;
188
+ readonly kit: string;
189
+ };
190
+ };
191
+ /**
192
+ * Grafts a slot the premade rig's skeleton lacks: `kit`'s bone chains for it (wings on the back, horns on the head, a
193
+ * tail on the hips) are added where they sit on that premade, scaled to this rig's torso or head, with their parts.
194
+ * A new kit replaces an earlier graft; no `kit` removes it.
195
+ */
196
+ export type GraftPart = {
197
+ readonly type: "GraftPart";
198
+ readonly payload: {
199
+ readonly rigId: Id;
200
+ readonly slot: GraftSlot;
201
+ readonly kit?: string;
202
+ };
203
+ };
204
+ /**
205
+ * Generates a creature from the premades: a new rig at `transform`, or the given generated / premade rig remade in
206
+ * place. Everything in `keep` stays as given; the rest is rolled from `seed`: the base premade, each slot's premade
207
+ * (its family's, or any with `chimera`), each size group (head ≥ 1; `variety` 0–1 says how far sizes stray) and the
208
+ * eye and mouth art. A slot the base lacks may be grafted (more often with more variety); a kept kit for such a slot
209
+ * is always grafted. Re-rolling one slot keeps the rest of the recipe.
210
+ */
211
+ export type GenerateCreature = {
212
+ readonly type: "GenerateCreature";
213
+ readonly payload: {
214
+ readonly target: {
215
+ readonly kind: "new";
216
+ readonly transform: Transform;
217
+ } | {
218
+ readonly kind: "rig";
219
+ readonly rigId: Id;
220
+ };
221
+ readonly seed: number;
222
+ readonly chimera: boolean;
223
+ readonly variety: number;
224
+ /** Builds the whole creature from one made-up kind: every slot it has a part for takes one (kept parts stay). */
225
+ readonly theme?: CreatureTheme;
226
+ readonly keep?: Partial<Pick<CreatureRecipe, "base" | "kits" | "sizes" | "eyes" | "mouth">>;
227
+ };
228
+ };
229
+ export type RigCommand = CreateRig | ApplyPremade | AddBone | RemoveBone | ReparentBone | RenameBone | SetBoneTags | AutoTagSides | SetBoneTransforms | ResetPose | ApplyPosePreset | SetBoneSizes | SwapPartSlot | GraftPart | GenerateCreature | SetRigMode | SetRigMirror | SetRegionBlend | AddBodyPart | RemoveBodyPart | SetFlatWings;
@@ -0,0 +1,64 @@
1
+ import type { Id } from "../id.js";
2
+ import type { SculptLook } from "../model/look.js";
3
+ import type { Transform } from "../model/math.js";
4
+ import type { StampSpec } from "./stamp-spec.js";
5
+ /** Stamping in assembly mode: a new sculpt whose base solid is one stamp. */
6
+ export type CreateSculpt = {
7
+ readonly type: "CreateSculpt";
8
+ readonly payload: {
9
+ readonly name?: string;
10
+ readonly parentId?: Id;
11
+ readonly transform: Transform;
12
+ readonly stamp: StampSpec;
13
+ readonly look?: Partial<SculptLook>;
14
+ };
15
+ };
16
+ /** Deletes each object with its subtree. */
17
+ export type DeleteObjects = {
18
+ readonly type: "DeleteObjects";
19
+ readonly payload: {
20
+ readonly objectIds: readonly Id[];
21
+ };
22
+ };
23
+ export type RenameObject = {
24
+ readonly type: "RenameObject";
25
+ readonly payload: {
26
+ readonly objectId: Id;
27
+ readonly name: string;
28
+ };
29
+ };
30
+ /** Moves an object under another (keeping its world placement), or to the root. A cycle is rejected. */
31
+ export type ReparentObject = {
32
+ readonly type: "ReparentObject";
33
+ readonly payload: {
34
+ readonly objectId: Id;
35
+ readonly parentId: Id | null;
36
+ readonly index?: number;
37
+ };
38
+ };
39
+ /** One gizmo drag, a multi-selection drag, or a Properties edit: every listed object at once. */
40
+ export type SetObjectTransforms = {
41
+ readonly type: "SetObjectTransforms";
42
+ readonly payload: {
43
+ readonly changes: readonly {
44
+ readonly objectId: Id;
45
+ readonly transform: Transform;
46
+ }[];
47
+ };
48
+ };
49
+ /** Copies the objects (with subtrees) beside the originals. */
50
+ export type DuplicateObjects = {
51
+ readonly type: "DuplicateObjects";
52
+ readonly payload: {
53
+ readonly objectIds: readonly Id[];
54
+ };
55
+ };
56
+ /** Flips the objects across their own center on one axis. */
57
+ export type MirrorObjects = {
58
+ readonly type: "MirrorObjects";
59
+ readonly payload: {
60
+ readonly objectIds: readonly Id[];
61
+ readonly axis: "x" | "z";
62
+ };
63
+ };
64
+ export type SceneCommand = CreateSculpt | DeleteObjects | RenameObject | ReparentObject | SetObjectTransforms | DuplicateObjects | MirrorObjects;
@@ -0,0 +1,111 @@
1
+ import type { Id } from "../id.js";
2
+ import type { Pivot, SculptLook } from "../model/look.js";
3
+ import type { Quaternion, Vec3 } from "../model/math.js";
4
+ import type { ColorRef } from "../model/palette.js";
5
+ import type { MaterialOverrides, StampMode, Symmetry } from "../model/stamp.js";
6
+ import type { StampSpec } from "./stamp-spec.js";
7
+ import type { SculptTarget } from "./target.js";
8
+ /**
9
+ * One click stamps one shape; one smear stroke adds all its dabs at once as a new smear group.
10
+ * The core assigns ids.
11
+ */
12
+ export type AddStamps = {
13
+ readonly type: "AddStamps";
14
+ readonly payload: {
15
+ readonly target: SculptTarget;
16
+ readonly stamps: readonly StampSpec[];
17
+ readonly smear?: {
18
+ readonly mode: StampMode;
19
+ readonly color: ColorRef;
20
+ readonly blend: number;
21
+ readonly symmetry?: Symmetry;
22
+ };
23
+ };
24
+ };
25
+ /** Removes stamps (and smear groups left empty). The last stamp of a sculpt is never removed. */
26
+ export type RemoveStamps = {
27
+ readonly type: "RemoveStamps";
28
+ readonly payload: {
29
+ readonly target: SculptTarget;
30
+ readonly stampIds: readonly Id[];
31
+ };
32
+ };
33
+ /** One gizmo drag over one or more stamps (a locked smear group moves as one). */
34
+ export type SetStampPlacements = {
35
+ readonly type: "SetStampPlacements";
36
+ readonly payload: {
37
+ readonly target: SculptTarget;
38
+ readonly changes: readonly {
39
+ readonly stampId: Id;
40
+ readonly position: Vec3;
41
+ readonly rotation: Quaternion;
42
+ readonly scale: Vec3;
43
+ }[];
44
+ };
45
+ };
46
+ /** `null` clears an override back to the sculpt's value. */
47
+ export type StampPropsPatch = {
48
+ readonly mode?: StampMode;
49
+ readonly color?: ColorRef | null;
50
+ readonly foundationColor?: ColorRef | null;
51
+ readonly blend?: number | null;
52
+ readonly material?: MaterialOverrides | null;
53
+ readonly symmetry?: Symmetry | null;
54
+ };
55
+ export type SetStampProps = {
56
+ readonly type: "SetStampProps";
57
+ readonly payload: {
58
+ readonly target: SculptTarget;
59
+ readonly stampIds: readonly Id[];
60
+ readonly props: StampPropsPatch;
61
+ };
62
+ };
63
+ export type SetSmearGroup = {
64
+ readonly type: "SetSmearGroup";
65
+ readonly payload: {
66
+ readonly target: SculptTarget;
67
+ readonly groupId: Id;
68
+ readonly props: StampPropsPatch & {
69
+ readonly unlocked?: boolean;
70
+ readonly name?: string;
71
+ };
72
+ };
73
+ };
74
+ /** Deletes a smear group with its stamps (never the sculpt's last stamp). */
75
+ export type RemoveSmearGroup = {
76
+ readonly type: "RemoveSmearGroup";
77
+ readonly payload: {
78
+ readonly target: SculptTarget;
79
+ readonly groupId: Id;
80
+ };
81
+ };
82
+ export type SculptLookPatch = {
83
+ readonly [K in keyof SculptLook]?: SculptLook[K] extends object ? Partial<SculptLook[K]> : SculptLook[K];
84
+ };
85
+ /**
86
+ * Properties edits: one patch applied to every listed sculpt (a rig's parts, a multi-selection).
87
+ * A flat wing part accepts the `material` part of the patch (its material); other fields are rejected for it.
88
+ */
89
+ export type SetSculptLook = {
90
+ readonly type: "SetSculptLook";
91
+ readonly payload: {
92
+ readonly targets: readonly SculptTarget[];
93
+ readonly look: SculptLookPatch;
94
+ };
95
+ };
96
+ export type SetPivot = {
97
+ readonly type: "SetPivot";
98
+ readonly payload: {
99
+ readonly target: SculptTarget;
100
+ readonly pivot: Pivot;
101
+ };
102
+ };
103
+ /** "Apply to all shapes": every stamp and smear group of the sculpt gets this symmetry. */
104
+ export type SetSymmetryForAll = {
105
+ readonly type: "SetSymmetryForAll";
106
+ readonly payload: {
107
+ readonly target: SculptTarget;
108
+ readonly symmetry: Symmetry | null;
109
+ };
110
+ };
111
+ export type SculptCommand = AddStamps | RemoveStamps | SetStampPlacements | SetStampProps | SetSmearGroup | RemoveSmearGroup | SetSculptLook | SetPivot | SetSymmetryForAll;
@@ -0,0 +1,3 @@
1
+ import type { Stamp } from "../model/stamp.js";
2
+ /** A stamp before the core gives it an id. */
3
+ export type StampSpec = Omit<Stamp, "id" | "smearGroupId">;
@@ -0,0 +1,8 @@
1
+ import type { Id } from "../id.js";
2
+ /** A sculpt to edit: a sculpt object, or the body part a rig's bone owns. */
3
+ export type SculptTarget = {
4
+ readonly objectId: Id;
5
+ } | {
6
+ readonly objectId: Id;
7
+ readonly boneId: Id;
8
+ };
@@ -0,0 +1,52 @@
1
+ import type { CreatureFamily, PartSlot, PosePresetId } from "./model/rig.js";
2
+ import type { Command } from "./commands/command.js";
3
+ import type { Creation, CreationLog } from "./model/creation.js";
4
+ export type DispatchResult = {
5
+ readonly ok: true;
6
+ readonly creation: Creation;
7
+ } | {
8
+ readonly ok: false;
9
+ readonly reason: string;
10
+ };
11
+ /** A premade skeleton the core can apply (the picker lists these). */
12
+ export type PremadeInfo = {
13
+ readonly id: string;
14
+ readonly name: string;
15
+ /** An emoji. */
16
+ readonly icon: string;
17
+ readonly description: string;
18
+ readonly boneCount: number;
19
+ /** Its creature family, and the part slots it can give to other premades. */
20
+ readonly family: CreatureFamily;
21
+ readonly slots: readonly PartSlot[];
22
+ /** The pose presets its rigs offer, in picker order (Custom is offered by the rig once it has one). */
23
+ readonly poses: readonly {
24
+ readonly id: PosePresetId;
25
+ readonly name: string;
26
+ }[];
27
+ };
28
+ /** A body part variant (a tiger head, elephant ears…) that can fill a slot of a premade rig, like a premade's own parts. */
29
+ export type PartVariantInfo = {
30
+ /** `slot:name`, e.g. "head:tiger"; used as a slot's kit. */
31
+ readonly id: string;
32
+ readonly slot: PartSlot;
33
+ readonly name: string;
34
+ /** An emoji. */
35
+ readonly icon: string;
36
+ /** Offered to its family's creatures, or to any with Chimera. */
37
+ readonly family: CreatureFamily;
38
+ };
39
+ /** Seam between UI and logic. Persistence, the evaluator and the viewport are injected beside it. */
40
+ export interface CreationApi {
41
+ log(): CreationLog;
42
+ creation(): Creation;
43
+ /** The premade skeletons, in picker order. */
44
+ premades(): readonly PremadeInfo[];
45
+ /** The body part variants, by slot then picker order. */
46
+ partVariants(): readonly PartVariantInfo[];
47
+ dispatch(command: Command): DispatchResult;
48
+ canUndo(): boolean;
49
+ canRedo(): boolean;
50
+ undo(): void;
51
+ redo(): void;
52
+ }
@@ -0,0 +1,7 @@
1
+ import type { DecalEvent } from "./decal-events.js";
2
+ import type { PaletteEvent } from "./palette-events.js";
3
+ import type { RigEvent } from "./rig-events.js";
4
+ import type { SceneEvent } from "./scene-events.js";
5
+ import type { SculptEvent } from "./sculpt-events.js";
6
+ /** An appended fact. The creation is the fold of these, in order. */
7
+ export type CreationEvent = SceneEvent | SculptEvent | DecalEvent | PaletteEvent | RigEvent;
@@ -0,0 +1,20 @@
1
+ import type { SculptTarget } from "../commands/target.js";
2
+ import type { Id } from "../id.js";
3
+ import type { Decal, Design } from "../model/decal.js";
4
+ import type { EventOf } from "./event-of.js";
5
+ export type DecalsAdded = EventOf<"DecalsAdded", {
6
+ readonly target: SculptTarget;
7
+ readonly decals: readonly Decal[];
8
+ }>;
9
+ export type DecalRemoved = EventOf<"DecalRemoved", {
10
+ readonly target: SculptTarget;
11
+ readonly decalId: Id;
12
+ }>;
13
+ /** New or replaced design (full content). */
14
+ export type DesignSaved = EventOf<"DesignSaved", {
15
+ readonly design: Design;
16
+ }>;
17
+ export type DesignDeleted = EventOf<"DesignDeleted", {
18
+ readonly designId: Id;
19
+ }>;
20
+ export type DecalEvent = DecalsAdded | DecalRemoved | DesignSaved | DesignDeleted;
@@ -0,0 +1,6 @@
1
+ /** Every event: a past-tense fact with the clock time it was accepted. */
2
+ export type EventOf<Type extends string, Payload> = {
3
+ readonly type: Type;
4
+ readonly at: number;
5
+ readonly payload: Payload;
6
+ };