@volter/game-editor 0.5.80 → 0.5.82

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 (328) hide show
  1. package/BUNDLED_NOTICES +22 -22
  2. package/catalog/entries/blender.json +2 -2
  3. package/catalog/entries/music.json +2 -2
  4. package/dist/.vite/manifest.json +2115 -2114
  5. package/dist/assets/{AssetBudgetPanel-C-RNso12.js → AssetBudgetPanel-Iip49rxI.js} +3 -3
  6. package/dist/assets/{AudioViewer-BQ4yQJmw.js → AudioViewer-DmkOvskF.js} +1 -1
  7. package/dist/assets/{CanvasBoardDocument-D1_2Ahx7.js → CanvasBoardDocument-DCS8uzQo.js} +1 -1
  8. package/dist/assets/CanvasSceneViewport-CfOuQiQ0.js +1 -0
  9. package/dist/assets/{ColorInput-B-GRGKwB.js → ColorInput-7CPpl8MI.js} +1 -1
  10. package/dist/assets/EntityModelDocument-CplmAib0.js +1 -0
  11. package/dist/assets/{EnvironmentAssetDocument-BbWPrmTc.js → EnvironmentAssetDocument-DlS6KFJu.js} +1 -1
  12. package/dist/assets/{GameplaySessionTimeline-Bi_Z_lDm.js → GameplaySessionTimeline-C3zH6edi.js} +1 -1
  13. package/dist/assets/{ImageViewer-CVYDgTSj.js → ImageViewer-C0lQ6YO0.js} +1 -1
  14. package/dist/assets/InspectorObjectPreview-Bjc1Tn-I.js +1 -0
  15. package/dist/assets/{JsonAssetDocument-O-o1eVJB.js → JsonAssetDocument-DjmH9CQH.js} +1 -1
  16. package/dist/assets/{LiveModuleDocument-CCpe63vw.js → LiveModuleDocument-Hiot8Q5L.js} +1 -1
  17. package/dist/assets/{LutAssetDocument-C_QGvjj7.js → LutAssetDocument-6bBwNMOn.js} +1 -1
  18. package/dist/assets/{ModelAssetDocument-DKyxph4r.js → ModelAssetDocument-G6ajiV51.js} +1 -1
  19. package/dist/assets/{NonThreeAuthoringBootstrap-DkfIBzMs.js → NonThreeAuthoringBootstrap-DpieYAMC.js} +1 -1
  20. package/dist/assets/Object3DDocumentToolbar-BtZkDxKa.js +1 -0
  21. package/dist/assets/Object3DDocumentViewport-BhH8afDi.js +2 -0
  22. package/dist/assets/{Object3DPreview-DI7aoPKe.js → Object3DPreview-DdrYVJUZ.js} +1 -1
  23. package/dist/assets/{OnlineAssetDetail-BIRXvQsJ.js → OnlineAssetDetail-D06eTe3y.js} +1 -1
  24. package/dist/assets/{PlayBar-BYVJHvd5.js → PlayBar-BbzjgLFJ.js} +1 -1
  25. package/dist/assets/{QuarksAssetDocument-DEcSmewA.js → QuarksAssetDocument-wGHNt4ov.js} +1 -1
  26. package/dist/assets/{ReactCanvasControls-DplBODky.js → ReactCanvasControls-BL2tOUj6.js} +1 -1
  27. package/dist/assets/{RootSelectionOverlay-BzEZwAaO.js → RootSelectionOverlay-C6Wu8nIs.js} +1 -1
  28. package/dist/assets/{ShaderAssetDocument-ysUJR4Np.js → ShaderAssetDocument-BDi8iNLA.js} +4 -4
  29. package/dist/assets/{ShadowEditor-BKz_sq1R.js → ShadowEditor-C3L0UWSH.js} +1 -1
  30. package/dist/assets/{SourceAssetViewer-DhoQonvP.js → SourceAssetViewer-D832bARo.js} +1 -1
  31. package/dist/assets/StageHost-Bor1eHEO.js +2 -0
  32. package/dist/assets/{StoryPreviewMount-BF6vqmhx.js → StoryPreviewMount-CmOEFzZY.js} +1 -1
  33. package/dist/assets/{ThreeBoardDocument-vedTeiN9.js → ThreeBoardDocument-BtBMGtiQ.js} +2 -2
  34. package/dist/assets/{ThreeIsolationSceneContent-TT4T-ehp.js → ThreeIsolationSceneContent-BEHNSEsi.js} +1 -1
  35. package/dist/assets/{ToolObject3DPreview-C52QCJAO.js → ToolObject3DPreview-76LMkfin.js} +1 -1
  36. package/dist/assets/{Toolbar-Bo-l61Lo.js → Toolbar-BEBQdxRz.js} +1 -1
  37. package/dist/assets/{TransientHint-DFAcEEFI.js → TransientHint-CzsdY8W6.js} +1 -1
  38. package/dist/assets/{VideoViewer-BM_9gSgl.js → VideoViewer-Ckrawyuq.js} +1 -1
  39. package/dist/assets/{ViewportShadingMenu-CWutLX1G.js → ViewportShadingMenu-BofQt6_4.js} +1 -1
  40. package/dist/assets/{active-ingest-BuNeO4Mb.js → active-ingest-D_ryI_R4.js} +2 -2
  41. package/dist/assets/{animation-clock-B-fl-HTL.js → animation-clock-QjtJDIsR.js} +1 -1
  42. package/dist/assets/{animation-mixers.service-DgxB7R_k.js → animation-mixers.service-BInUs1US.js} +1 -1
  43. package/dist/assets/{animation-timeline.utility-RWwRwQvM.js → animation-timeline.utility-DUrfNSwn.js} +1 -1
  44. package/dist/assets/{asset-budget-asset.menu-D2Tdwqxf.js → asset-budget-asset.menu-DVQEksFp.js} +1 -1
  45. package/dist/assets/{asset-budget.action-WMiFAlTi.js → asset-budget.action-C-ENAa52.js} +1 -1
  46. package/dist/assets/{asset-budget.document-CckPEzno.js → asset-budget.document-Bb1PyL3H.js} +1 -1
  47. package/dist/assets/{asset-budget.menu-DPMPOTSo.js → asset-budget.menu-CPi2yjBA.js} +1 -1
  48. package/dist/assets/{asset-editor-persistence-DttxUta0.js → asset-editor-persistence-Duoq7o22.js} +1 -1
  49. package/dist/assets/{asset-loaders-9M6lxMew.js → asset-loaders-BftJ2m7-.js} +1 -1
  50. package/dist/assets/{asset-preview-C36PaXvM.js → asset-preview-BS71mXsZ.js} +1 -1
  51. package/dist/assets/{audio-unlock.service-BeHFOKOB.js → audio-unlock.service-C3ygvDjU.js} +1 -1
  52. package/dist/assets/{audio.utility-HRjVG-Co.js → audio.utility-DF55sgHW.js} +1 -1
  53. package/dist/assets/autoplay.service-DaonKf7O.js +1 -0
  54. package/dist/assets/{babylon-authoring-adapter-BHQY7yIy.js → babylon-authoring-adapter-CmeehOBt.js} +1 -1
  55. package/dist/assets/{binding-resolver-TD7-fKuX.js → binding-resolver-DUz8C8Fs.js} +2 -2
  56. package/dist/assets/{blender-emscripten-engine-CieQeF-r.js → blender-emscripten-engine-DQljvfR7.js} +1 -1
  57. package/dist/assets/{blender-node-editor.document-Bw2QbNTV.js → blender-node-editor.document-B8S2TVMM.js} +1 -1
  58. package/dist/assets/{blender-properties-tab-BnIbJN4f.js → blender-properties-tab-y-_BeZDx.js} +1 -1
  59. package/dist/assets/blender-runtime-host-CUH6peXj.js +4 -0
  60. package/dist/assets/{blender-runtime-skin-CwXXiusi.js → blender-runtime-skin-B1tYITn2.js} +36 -36
  61. package/dist/assets/blender-runtime.document-DnSl0twI.js +12 -0
  62. package/dist/assets/{blender-timeline.document-CESN0FrA.js → blender-timeline.document-CeCylyXB.js} +1 -1
  63. package/dist/assets/{blender-uv-editor.document-BdIUMC5X.js → blender-uv-editor.document-DEllMw3a.js} +1 -1
  64. package/dist/assets/{blender-version.status-CBKgGtQ0.js → blender-version.status-CrT9NqK-.js} +1 -1
  65. package/dist/assets/{blender-wali-engine-KWIxfB_o.js → blender-wali-engine-CO-jG_ik.js} +1 -1
  66. package/dist/assets/{blender.command-ChUV_DJE.js → blender.command-GIjMG1-m.js} +1 -1
  67. package/dist/assets/{board-guides-ClHJXXuu.js → board-guides-B6TEPOPi.js} +1 -1
  68. package/dist/assets/{bridge.command-DK8zE8yt.js → bridge.command-D6qTcgje.js} +3 -3
  69. package/dist/assets/{browserAll-Be-P25YM.js → browserAll-k35XRFil.js} +1 -1
  70. package/dist/assets/build-player.document-CHxj4P8q.js +1 -0
  71. package/dist/assets/{build-profiles.document-CNZvcPor.js → build-profiles.document-CZCk1HYA.js} +2 -2
  72. package/dist/assets/{build-progress.status-BMfffkUW.js → build-progress.status-BNwBxP2a.js} +1 -1
  73. package/dist/assets/{build-session-BHUOWzok.js → build-session-CW2UyYFF.js} +1 -1
  74. package/dist/assets/{build.action-BGriOSGD.js → build.action-EmCcMu47.js} +1 -1
  75. package/dist/assets/{build.command-BU7Wcsn5.js → build.command-CzEckGcR.js} +1 -1
  76. package/dist/assets/{build.header-B6KRt0O_.js → build.header-CsYLpZbh.js} +1 -1
  77. package/dist/assets/{build.menu-CpxN2aww.js → build.menu-CaDkDQuy.js} +1 -1
  78. package/dist/assets/{build.service-LRCZ0vL7.js → build.service-BcKtbU0-.js} +1 -1
  79. package/dist/assets/{camera-D8fxcMUB.js → camera-BwWZUyKt.js} +1 -1
  80. package/dist/assets/{camera-runtime.inspector-5RS6wvw2.js → camera-runtime.inspector-CJyi3zmp.js} +1 -1
  81. package/dist/assets/{canvas-design-mount-CoKGVZii.js → canvas-design-mount-B_uwZkEU.js} +6 -6
  82. package/dist/assets/{canvas-entry-runtime-Do5zL9dN.js → canvas-entry-runtime-DskaohHK.js} +2 -2
  83. package/dist/assets/{canvas-preview-frames-Jsd4Gi5S.js → canvas-preview-frames-BzLeTumX.js} +1 -1
  84. package/dist/assets/{canvas-story-capture.service-0SYz8LrL.js → canvas-story-capture.service-C80CsS8r.js} +2 -2
  85. package/dist/assets/{capability-coverage-BqCZSu0R.js → capability-coverage-wd6bAhv3.js} +2 -2
  86. package/dist/assets/{collaboration-presence-WWC9ZQsq.js → collaboration-presence-DcPhahtF.js} +1 -1
  87. package/dist/assets/{collider-DsdfCyWG.js → collider-Dw2iWV3F.js} +1 -1
  88. package/dist/assets/{component-board.service-6JDsY08Z.js → component-board.service-CH99sgj0.js} +2 -2
  89. package/dist/assets/component-board.service-Cd1c9oSN.js +2 -0
  90. package/dist/assets/{component-board.service-DZWOfhbB.js → component-board.service-XAxyLCnM.js} +2 -2
  91. package/dist/assets/{component-contracts.service-DXfwve-4.js → component-contracts.service-DerT0BP-.js} +1 -1
  92. package/dist/assets/{component-instance-root-pq7uyyej.js → component-instance-root-Cw_-ajBX.js} +1 -1
  93. package/dist/assets/{component-verbs.command-Cd_-gQ-Z.js → component-verbs.command-BHK9M2Rk.js} +1 -1
  94. package/dist/assets/component-verbs.service-DsxhVcvk.js +1 -0
  95. package/dist/assets/{config-CnqnR-iz.js → config-1rCvm02z.js} +3 -3
  96. package/dist/assets/configurations-CRTYw0r9.js +1 -0
  97. package/dist/assets/{connection.status-BkhMFG12.js → connection.status-D4fjnH24.js} +1 -1
  98. package/dist/assets/{constraints.inspector-CPWFDlY8.js → constraints.inspector-BgnafOLf.js} +1 -1
  99. package/dist/assets/{content-bounds-Ax7CFkXJ.js → content-bounds-D5pXeHJN.js} +1 -1
  100. package/dist/assets/{contract-system-adapters-0Odxcy6d.js → contract-system-adapters-rVGdworX.js} +1 -1
  101. package/dist/assets/{coverage.service-CcKdk7iJ.js → coverage.service-BNme5Agb.js} +1 -1
  102. package/dist/assets/{create-runtime-BhdSylT1.js → create-runtime-CcuQTSfy.js} +2 -2
  103. package/dist/assets/{curve-DiuqWf0-.js → curve-DorFv33R.js} +1 -1
  104. package/dist/assets/{data-asset-BiqUYQnI.js → data-asset-CAE35Emh.js} +1 -1
  105. package/dist/assets/{data-ref-mo1ecq_T.js → data-ref-DXqRnZsJ.js} +1 -1
  106. package/dist/assets/{debug-bridge-BN4INYe7.js → debug-bridge-DdCJSEni.js} +1 -1
  107. package/dist/assets/{debug-registry-BW5cue8V.js → debug-registry-xQJcVubm.js} +1 -1
  108. package/dist/assets/deferred-ingest-play-CEnsC3uN.js +2 -0
  109. package/dist/assets/{design-time-canvas-mount-mhxQlHHP.js → design-time-canvas-mount-CPRrCPFA.js} +2 -2
  110. package/dist/assets/design-time-layers-hmGqBp06.js +1 -0
  111. package/dist/assets/{design-time-mount.service-Cs_mT_-d.js → design-time-mount.service-CEmJjRIJ.js} +2 -2
  112. package/dist/assets/{design-time-mount.service-DPEpO4ny.js → design-time-mount.service-CLL-1Za4.js} +2 -2
  113. package/dist/assets/{design-time-react-mount-RdZmD9Dp.js → design-time-react-mount-DmXi3GBy.js} +1 -1
  114. package/dist/assets/{document-preview-three-D4M5qFH3.js → document-preview-three-B4j_zNef.js} +1 -1
  115. package/dist/assets/{dom-authoring-adapter-B97hwEwz.js → dom-authoring-adapter-BklRbjZB.js} +1 -1
  116. package/dist/assets/{draco3d-B_PtVdzj.js → draco3d-CFWI1XDT.js} +1 -1
  117. package/dist/assets/{edit-mode-audio.service-BZxbnyf-.js → edit-mode-audio.service-SUzv0nHs.js} +1 -1
  118. package/dist/assets/{edit-mode-authoring-CVKwIPOy.js → edit-mode-authoring-CSt3zzmS.js} +1 -1
  119. package/dist/assets/{edit-mode-networking.service-2aXyBwkO.js → edit-mode-networking.service-D6UohrCr.js} +1 -1
  120. package/dist/assets/editor-api-WeHVNlEo.js +1 -0
  121. package/dist/assets/{editor-layers-DI1Wkr8F.js → editor-layers-CjeYrUlm.js} +1 -1
  122. package/dist/assets/{editor-shell-store-DlGykD-E.js → editor-shell-store-DckLm6m8.js} +1 -1
  123. package/dist/assets/{entity-object-C374JqRs.js → entity-object-V13bGmay.js} +1 -1
  124. package/dist/assets/{extend-BOaYynPp.js → extend-BQeRA-aV.js} +1 -1
  125. package/dist/assets/{fork-menu-DGjsgL8L.js → fork-menu-Bthg9viY.js} +1 -1
  126. package/dist/assets/{frame-debugger-store-Czy2FTqO.js → frame-debugger-store-DDxWlDPK.js} +1 -1
  127. package/dist/assets/{game-contract-seams-GoIZaA0s.js → game-contract-seams-DrYyE5PX.js} +1 -1
  128. package/dist/assets/{game-css-scope-transform-9t97Smqk.js → game-css-scope-transform-D5hQWaci.js} +1 -1
  129. package/dist/assets/game-document.service-cJ1yKc2V.js +1 -0
  130. package/dist/assets/{game-eval.command-BYEEWjUv.js → game-eval.command-CKo-W17_.js} +1 -1
  131. package/dist/assets/{game-module-access-BqevF7uR.js → game-module-access-DuptGLGx.js} +1 -1
  132. package/dist/assets/game-network-CAH_Jsh6.js +22 -0
  133. package/dist/assets/gameplay-export-B-JE4uSD.js +1 -0
  134. package/dist/assets/gameplay-replay-WyopKGyB.js +1 -0
  135. package/dist/assets/{gameplay.command-BrleMyQK.js → gameplay.command-D4cY3nOq.js} +1 -1
  136. package/dist/assets/generation-jobs-CcCrhKLM.js +1 -0
  137. package/dist/assets/{generation.service-nVpgwKEB.js → generation.service-CQwmLAOQ.js} +1 -1
  138. package/dist/assets/{generations-AU4LkWAl.js → generations-qfhCRH8C.js} +1 -1
  139. package/dist/assets/{generations.status-CSeb5inI.js → generations.status-CcbR2OfF.js} +1 -1
  140. package/dist/assets/{hierarchy-marks-EEQa08In.js → hierarchy-marks-B1jSqxSv.js} +1 -1
  141. package/dist/assets/{hosted-asset-materialization-DZlaRGkJ.js → hosted-asset-materialization-BZf-8JA1.js} +1 -1
  142. package/dist/assets/{index-ynpEqujB.js → index-CHa43s2p.js} +1 -1
  143. package/dist/assets/{index-N4BP9b5x.js → index-Cj_b0Ygc.js} +1 -1
  144. package/dist/assets/{index-CUBra63E.js → index-D-RMHSzb.js} +1 -1
  145. package/dist/assets/{index-BpXj_ZfC.js → index-DXtfej3G.js} +1 -1
  146. package/dist/assets/{index-BHccVo52.js → index-D_ViOFCz.js} +2 -2
  147. package/dist/assets/{index-DlFjiZgV.js → index-DrEVdQvN.js} +1 -1
  148. package/dist/assets/{index-flxMlfV4.js → index-V4J7xfRg.js} +7 -7
  149. package/dist/assets/{index-OlF4eBxk.js → index-aREcGExk.js} +1 -1
  150. package/dist/assets/index-yXSK_qPW.js +1 -0
  151. package/dist/assets/{inference-diagnostics-MWqnRUsN.js → inference-diagnostics-DoZQ1mpg.js} +1 -1
  152. package/dist/assets/{ingest-boot-viewport-CT1eaWqO.js → ingest-boot-viewport-DWdOtGGE.js} +1 -1
  153. package/dist/assets/ingest-siblings-DyvasVDH.js +1 -0
  154. package/dist/assets/{ingest-source-persistence-CJGE5-AU.js → ingest-source-persistence-CQOJeGhj.js} +1 -1
  155. package/dist/assets/{ingest.service-2TRoiqQ8.js → ingest.service-CqIcydem.js} +1 -1
  156. package/dist/assets/{inspect-Dl5bH02T.js → inspect-DiSjB-N1.js} +1 -1
  157. package/dist/assets/instances.command-COw2QpbN.js +1 -0
  158. package/dist/assets/{json-history-resource-DTUpacfx.js → json-history-resource-CH2nzMZh.js} +1 -1
  159. package/dist/assets/{layered-pick-DKNj5L29.js → layered-pick-BUr1U8lU.js} +1 -1
  160. package/dist/assets/{light-CX-83nBK.js → light-CxiGIJma.js} +1 -1
  161. package/dist/assets/live-project-verbs-CnknlUlT.js +1 -0
  162. package/dist/assets/{machine.document-DE8aRbOi.js → machine.document-D7jMrzXt.js} +1 -1
  163. package/dist/assets/{machines.finder-CZ3P0odZ.js → machines.finder-Dor3O0uf.js} +1 -1
  164. package/dist/assets/{material-f1KOKE_r.js → material-B6cH1Oqw.js} +1 -1
  165. package/dist/assets/{material-factory-DkCPSCLt.js → material-factory-BN3Lax5C.js} +1 -1
  166. package/dist/assets/{mesh-DM3TH9xS.js → mesh-Cj-CYroI.js} +1 -1
  167. package/dist/assets/{model-asset-sections.service-CL4Rlwvc.js → model-asset-sections.service-mC4WJFTA.js} +1 -1
  168. package/dist/assets/{model-inspection-BS3uYvYU.js → model-inspection-8o57YSZW.js} +1 -1
  169. package/dist/assets/{model-thumbnail-WJb6B3qQ.js → model-thumbnail-chePRlH7.js} +1 -1
  170. package/dist/assets/{models.finder-BXJhCiw9.js → models.finder-CKkT5ZdU.js} +1 -1
  171. package/dist/assets/{module-mode-CtoVZDhp.js → module-mode-BMiMhHI3.js} +2 -2
  172. package/dist/assets/{mount-canvas-ingest-root-DI8iSEV4.js → mount-canvas-ingest-root-B1swVIUJ.js} +2 -2
  173. package/dist/assets/{mount-dom-ingest-root-n4tbYw-j.js → mount-dom-ingest-root-B8hO5mht.js} +2 -2
  174. package/dist/assets/{mount-ingest-root-pyV6jEkB.js → mount-ingest-root-Cbnh-mSw.js} +2 -2
  175. package/dist/assets/{mount-manifest-DsGMOkm4.js → mount-manifest-B7oL1Abg.js} +1 -1
  176. package/dist/assets/{mount-three-ingest-root-CeH_uOP0.js → mount-three-ingest-root-BdUJx6ix.js} +1 -1
  177. package/dist/assets/{mounted-authoring-BHpx-z2Y.js → mounted-authoring-C47L5H5t.js} +1 -1
  178. package/dist/assets/{mounted-story-viewport-source-D8kOfa96.js → mounted-story-viewport-source-CyEK_vaq.js} +1 -1
  179. package/dist/assets/{native-debug-module-lR1oG4Vd.js → native-debug-module-JJOFtIVz.js} +1 -1
  180. package/dist/assets/{navigation-DvTw5hJ4.js → navigation-ROJM2w84.js} +1 -1
  181. package/dist/assets/{navmesh.menu-BaBNScgJ.js → navmesh.menu-DjefqtkI.js} +1 -1
  182. package/dist/assets/{navmesh.service-BK6BlOz3.js → navmesh.service-BPqjEQiq.js} +1 -1
  183. package/dist/assets/network-observer.service-GFzXuBMb.js +1 -0
  184. package/dist/assets/{network.utility-BJ3bZOCQ.js → network.utility-6Y5u53n8.js} +1 -1
  185. package/dist/assets/object3d-document-session-registry-DNCOGA3i.js +2 -0
  186. package/dist/assets/{oid-transform-RlofQ4tU.js → oid-transform-DQzN_Gl_.js} +1 -1
  187. package/dist/assets/{particles-CjR9Po6N.js → particles-DGdUmqOr.js} +1 -1
  188. package/dist/assets/{pixi-authoring-adapter-B_mXxWkJ.js → pixi-authoring-adapter-BRktdcIz.js} +1 -1
  189. package/dist/assets/{pixi-live-write-target-tm5yHKss.js → pixi-live-write-target-Dg0mdLaa.js} +1 -1
  190. package/dist/assets/play.command-4IDAqR5W.js +2 -0
  191. package/dist/assets/{presentation-gTgwItzD.js → presentation-8m-RDKIS.js} +1 -1
  192. package/dist/assets/{product-Cmel9X9k.js → product-t6tauO7R.js} +1 -1
  193. package/dist/assets/{profiler.action-DSM2uSYR.js → profiler.action-CXA4IkQB.js} +1 -1
  194. package/dist/assets/{profiler.menu-CcYyqUfU.js → profiler.menu-BgIBv4-I.js} +1 -1
  195. package/dist/assets/{profiler.utility-CQtqdQgC.js → profiler.utility-BYoRbfIK.js} +1 -1
  196. package/dist/assets/{project-authoring-session-BqZuntp2.js → project-authoring-session-DkekCxNv.js} +2 -2
  197. package/dist/assets/{properties-bone-constraints.inspector-D3XrqptB.js → properties-bone-constraints.inspector-DXpiCtf9.js} +1 -1
  198. package/dist/assets/{properties-bone.inspector-CmVamAC6.js → properties-bone.inspector-wIDsP4c5.js} +1 -1
  199. package/dist/assets/{properties-collection.inspector-BGi5eXmI.js → properties-collection.inspector-5SRPbqfM.js} +1 -1
  200. package/dist/assets/{properties-constraints.inspector-C62EOuWg.js → properties-constraints.inspector-DIjKz692.js} +1 -1
  201. package/dist/assets/{properties-data.inspector-qDFtLdw8.js → properties-data.inspector-DE6i8biZ.js} +1 -1
  202. package/dist/assets/{properties-material.inspector-B--PD0se.js → properties-material.inspector-Cu1UCPY4.js} +1 -1
  203. package/dist/assets/{properties-modifiers.inspector-1tdk1EKp.js → properties-modifiers.inspector-DsQzA638.js} +1 -1
  204. package/dist/assets/{properties-object.inspector-CYH5w2un.js → properties-object.inspector-C57X0GJq.js} +1 -1
  205. package/dist/assets/{properties-output.inspector-C78QuVlY.js → properties-output.inspector-DzrcFuRM.js} +1 -1
  206. package/dist/assets/{properties-particles.inspector-DyDiMjmC.js → properties-particles.inspector-DGqSnelN.js} +1 -1
  207. package/dist/assets/{properties-physics.inspector-DG5GOyLE.js → properties-physics.inspector-DIjhtiLe.js} +1 -1
  208. package/dist/assets/{properties-render.inspector-D8ldGTdq.js → properties-render.inspector-CX0orwn9.js} +1 -1
  209. package/dist/assets/{properties-scene.inspector-Cf_KBWbv.js → properties-scene.inspector-DaHNL_sq.js} +1 -1
  210. package/dist/assets/{properties-texture.inspector-BznU5kNc.js → properties-texture.inspector-B5hmxPRy.js} +1 -1
  211. package/dist/assets/{properties-view-layer.inspector-pnRv91FS.js → properties-view-layer.inspector-C7hdJgei.js} +1 -1
  212. package/dist/assets/{properties-world.inspector-CzUtvYuC.js → properties-world.inspector-EWTC6jNw.js} +1 -1
  213. package/dist/assets/r3f-design-session-CXlGV9hp.js +2 -0
  214. package/dist/assets/{r3f-physics-binding-D6DKTgwF.js → r3f-physics-binding-DZSIB0d_.js} +1 -1
  215. package/dist/assets/{r3f-source-authoring-adapter-nqn_PR3m.js → r3f-source-authoring-adapter-GR97EmII.js} +1 -1
  216. package/dist/assets/{react-canvas-navigation-WxI8Mxyc.js → react-canvas-navigation-L_mOnybL.js} +1 -1
  217. package/dist/assets/{react-inspector.service-C1Prvq6u.js → react-inspector.service-B4P3UnSY.js} +1 -1
  218. package/dist/assets/{react-story-board-BRUE9hN1.js → react-story-board-CT1_3sk_.js} +1 -1
  219. package/dist/assets/{react-three-rapier.esm-CA7vFsM3.js → react-three-rapier.esm-DyMNYoA_.js} +1 -1
  220. package/dist/assets/{react-world-authoring-adapter-DVNps-az.js → react-world-authoring-adapter-OR1SW2jI.js} +1 -1
  221. package/dist/assets/{realm-services-CL4ih5gp.js → realm-services-u0mnjXU9.js} +1 -1
  222. package/dist/assets/{reflection-probe-capture.inspector-C9mzBLI7.js → reflection-probe-capture.inspector-CTNlSaGW.js} +1 -1
  223. package/dist/assets/{registry-N8Uqh2X-.js → registry-wqakYaDW.js} +1 -1
  224. package/dist/assets/{relative-import-specifier-cRtWQWmH.js → relative-import-specifier-DXWVQf0o.js} +1 -1
  225. package/dist/assets/{render-env-xu-q_sLG.js → render-env-CN09NtDf.js} +1 -1
  226. package/dist/assets/{render-features-BMOBYkLQ.js → render-features-HCEupUJ6.js} +1 -1
  227. package/dist/assets/{render-settings-Cnd69vhe.js → render-settings-Clt6d05o.js} +1 -1
  228. package/dist/assets/{resolve-three-C9OlnFHx.js → resolve-three-CLzKVMx2.js} +13 -13
  229. package/dist/assets/{root-seam-contract-BoD0NaOZ.js → root-seam-contract-D2uQHWF9.js} +1 -1
  230. package/dist/assets/{run-selection-DL0vJV6z.js → run-selection-AyelFc9T.js} +1 -1
  231. package/dist/assets/{scene-capture-CoTN4qOO.js → scene-capture-WbPcLfJl.js} +1 -1
  232. package/dist/assets/{scene-document.service-kgtsh1r2.js → scene-document.service-4U6rDhCp.js} +2 -2
  233. package/dist/assets/{scene-framing-CljHc6tN.js → scene-framing-DzSL2Cld.js} +1 -1
  234. package/dist/assets/{seeded-random-BlGWBUER.js → seeded-random-tpdJjdqy.js} +1 -1
  235. package/dist/assets/{session-BMie6EFt.js → session-kSIjcXJT.js} +47 -8
  236. package/dist/assets/{setup-renderer-jOQdnmo7.js → setup-renderer-B5vZmCyu.js} +1 -1
  237. package/dist/assets/{source-object3d-authoring-adapter-qg_NN2PX.js → source-object3d-authoring-adapter-BQnQ3Qzg.js} +1 -1
  238. package/dist/assets/{source-persistence-backend-DoNJeJa8.js → source-persistence-backend-uyd6NiWD.js} +1 -1
  239. package/dist/assets/stage-keyboard-B2yrk2zu.js +1 -0
  240. package/dist/assets/stage-overlay-set-Cqtz3s06.js +1 -0
  241. package/dist/assets/{stage-presence-markers-Bu9mH0m_.js → stage-presence-markers-BgLs0Aj5.js} +1 -1
  242. package/dist/assets/stage-transform-tools-BHcz53td.js +1 -0
  243. package/dist/assets/{standard-viewport-dressing-B8VpmbHt.js → standard-viewport-dressing-uhv_3JvQ.js} +2 -2
  244. package/dist/assets/{state-watch.action-Dhb9xQb9.js → state-watch.action-BJ08HgcO.js} +1 -1
  245. package/dist/assets/{state-watch.menu-xf7oO-4l.js → state-watch.menu-rAULwijr.js} +1 -1
  246. package/dist/assets/{state-watch.utility-DnGO08TW.js → state-watch.utility-eEbQcj8t.js} +1 -1
  247. package/dist/assets/{story-capture-CyeAHem-.js → story-capture-B8wfSf5s.js} +1 -1
  248. package/dist/assets/{story-documents-DUm0LUTp.js → story-documents-Cm4jCkW5.js} +2 -2
  249. package/dist/assets/{story-documents.service-BWBSUjBO.js → story-documents.service-BDvQCslK.js} +1 -1
  250. package/dist/assets/{story-documents.service-DOvAnwES.js → story-documents.service-Cgtg6rXn.js} +1 -1
  251. package/dist/assets/story-media-presence-SGlp_afL.js +1 -0
  252. package/dist/assets/{story-pixi-preview-DHtzdru2.js → story-pixi-preview-D62Q_vIW.js} +1 -1
  253. package/dist/assets/{story-presentation-BpfNrI6t.js → story-presentation-CofUdEU7.js} +1 -1
  254. package/dist/assets/{story-three-preview-pzhR44fH.js → story-three-preview-B9O1wapP.js} +2 -2
  255. package/dist/assets/{studio-environment-Dw2FBct5.js → studio-environment-BIhqrtFc.js} +1 -1
  256. package/dist/assets/{surface-state-NwiDDkWI.js → surface-state-DrM3wsrr.js} +1 -1
  257. package/dist/assets/{syntactic-prop-specs-_Yk2QtpW.js → syntactic-prop-specs-BGz0N7Dg.js} +1 -1
  258. package/dist/assets/{team-playtest.service-DdUlOcrk.js → team-playtest.service-CiE8UJAe.js} +1 -1
  259. package/dist/assets/{three-2yjp9YMj.js → three-BQfhEwUz.js} +1 -1
  260. package/dist/assets/{three-authoring-adapter-B5h6dxvp.js → three-authoring-adapter-COBwREQO.js} +1 -1
  261. package/dist/assets/three-authoring.service-C0azvoq8.js +2 -0
  262. package/dist/assets/{three-ingest-runtime-B9surImB.js → three-ingest-runtime-BnRF_nJN.js} +1 -1
  263. package/dist/assets/three-integration-DeWYFf1x.js +2 -0
  264. package/dist/assets/three-integration.service-CoWCBTmg.js +1 -0
  265. package/dist/assets/{three-projection-core-xgnaC08N.js → three-projection-core-PQm-CO61.js} +1 -1
  266. package/dist/assets/{three-state-DVnNjIbQ.js → three-state-C7khRIQE.js} +1 -1
  267. package/dist/assets/{three-story-capture.service-DgVUrOW6.js → three-story-capture.service-B0oiGIfp.js} +2 -2
  268. package/dist/assets/three-story-model-D7g2pqfJ.js +1 -0
  269. package/dist/assets/{three-viewport-presentation-C5wGhMgD.js → three-viewport-presentation-B_tBudM-.js} +5 -5
  270. package/dist/assets/transform-mode-request-DWM6BdRA.js +1 -0
  271. package/dist/assets/{transport-strip-Dvkyjqwq.js → transport-strip-vgXGDgkI.js} +1 -1
  272. package/dist/assets/transport.header-CfVHXjrT.js +1 -0
  273. package/dist/assets/{tuples-tlEYpiUU.js → tuples-BnYrlQqS.js} +1 -1
  274. package/dist/assets/ui-board-document-B_-K9luq.js +2 -0
  275. package/dist/assets/{user-data-C8dmlLGA.js → user-data-CifDDvSr.js} +1 -1
  276. package/dist/assets/{utility-view-state-8ikycS0_.js → utility-view-state-BPl8Asup.js} +1 -1
  277. package/dist/assets/{viewport-door-Brt6-rPp.js → viewport-door-BCXEYmon.js} +1 -1
  278. package/dist/assets/{viewport-root-presentation-DEm3C1-i.js → viewport-root-presentation-DJLpUuf0.js} +1 -1
  279. package/dist/assets/{viewport-surface-status-Dbc5Yxun.js → viewport-surface-status-jwLhIK_M.js} +1 -1
  280. package/dist/assets/{webworkerAll-qWuefF-u.js → webworkerAll-P6jePa6X.js} +1 -1
  281. package/dist/assets/{worker-Gtu-EAm9.js → worker-CJIsrsP6.js} +1 -1
  282. package/dist/assets/{workspace-arrangement-BnGzBm57.js → workspace-arrangement-B_OcbQbj.js} +1 -1
  283. package/dist/assets/{world-documents-DH7drgx-.js → world-documents-Bx3j867R.js} +1 -1
  284. package/dist/assets/{world-root-stage-binding-DIigD-mK.js → world-root-stage-binding-LEhjWDkn.js} +1 -1
  285. package/dist/assets/{xstate-animation-binding-BpYb4mXT.js → xstate-animation-binding-Dionc_fC.js} +1 -1
  286. package/dist/assets/{xstate-animation-meta-0RXvMgDk.js → xstate-animation-meta-XEmD_qc_.js} +1 -1
  287. package/dist-node/cli.js +16 -16
  288. package/package.json +16 -16
  289. package/dist/assets/CanvasSceneViewport-BdHcsAyR.js +0 -1
  290. package/dist/assets/EntityModelDocument-BkRbfE7C.js +0 -1
  291. package/dist/assets/InspectorObjectPreview-BooanIbq.js +0 -1
  292. package/dist/assets/Object3DDocumentToolbar-BGkgzg_Y.js +0 -1
  293. package/dist/assets/Object3DDocumentViewport-C81c8PFJ.js +0 -2
  294. package/dist/assets/StageHost-CSw286Im.js +0 -2
  295. package/dist/assets/autoplay.service-EjNkSGFD.js +0 -1
  296. package/dist/assets/blender-runtime-host-W_QVh8pY.js +0 -4
  297. package/dist/assets/blender-runtime.document-CxTCG8RI.js +0 -12
  298. package/dist/assets/build-player.document-Clkf52m6.js +0 -1
  299. package/dist/assets/component-board.service-Dj_INzxs.js +0 -2
  300. package/dist/assets/component-verbs.service-Do8eBA--.js +0 -1
  301. package/dist/assets/configurations-DFYaoXBK.js +0 -1
  302. package/dist/assets/deferred-ingest-play-C6qytzjB.js +0 -2
  303. package/dist/assets/design-time-layers-CCEX-9ul.js +0 -1
  304. package/dist/assets/editor-api-B0aNu3G5.js +0 -1
  305. package/dist/assets/game-document.service-DBSsz8Ne.js +0 -1
  306. package/dist/assets/game-network-DtzKFtge.js +0 -22
  307. package/dist/assets/gameplay-export-BNVUERuW.js +0 -1
  308. package/dist/assets/gameplay-replay-DEKg9ROx.js +0 -1
  309. package/dist/assets/generation-jobs-Bmm6k_GH.js +0 -1
  310. package/dist/assets/index-PKSmixoy.js +0 -1
  311. package/dist/assets/ingest-siblings-BJ66Uen_.js +0 -1
  312. package/dist/assets/instances.command-2QbcHvH-.js +0 -1
  313. package/dist/assets/live-project-verbs-nmQ1saHI.js +0 -1
  314. package/dist/assets/network-observer.service-CskzAy97.js +0 -1
  315. package/dist/assets/object3d-document-session-registry-DI9WfJDy.js +0 -2
  316. package/dist/assets/play.command-BmsyGtu0.js +0 -2
  317. package/dist/assets/r3f-design-session-Dwqxg13i.js +0 -2
  318. package/dist/assets/stage-keyboard-jfRYkBwZ.js +0 -1
  319. package/dist/assets/stage-overlay-set-Bo-JC6N0.js +0 -1
  320. package/dist/assets/stage-transform-tools-CSnDpsY3.js +0 -1
  321. package/dist/assets/story-media-presence-7Tbl7-hO.js +0 -1
  322. package/dist/assets/three-authoring.service-CIVEDuMV.js +0 -2
  323. package/dist/assets/three-integration-K2zwKa-Z.js +0 -2
  324. package/dist/assets/three-integration.service-kjZ0g0er.js +0 -1
  325. package/dist/assets/three-story-model-B0qnMa7M.js +0 -1
  326. package/dist/assets/transform-mode-request-COfeHSRX.js +0 -1
  327. package/dist/assets/transport.header-CFTM9Q_n.js +0 -1
  328. package/dist/assets/ui-board-document-BlKR5Cyh.js +0 -2
@@ -0,0 +1 @@
1
+ import{dq as c,dr as u,ds as l,dt as f,du as m}from"./index-V4J7xfRg.js";function g(t,r){if(t.setTransformMode(r),r==="select")return;const n=[...t.selectedEntityIds];if(n.length===0)return;const s=c(t),a=((s===null?null:u(s)?.adapter)??l(t).adapter).transforms?.editability;if(!a)return;let e;for(const i of n){const o=f(d=>a(i,d));if(!o.locked)return;e??=o.reason}e&&m(e)}export{g as r};
@@ -1 +1 @@
1
- import{a as l}from"./jsx-runtime-DPjLkJKQ.js";import{r as c}from"./index-nmcBqr7Y.js";import"./index-CtzuWnCS.js";import{af as b,aL as v,a1 as x,a2 as r,aM as j,aK as i}from"./index-flxMlfV4.js";const S=[.25,.5,1,2];function f(a,s){const t=Math.round(a*s);return`${a.toFixed(2)}s · f${t}`}function E({transport:a}){const s=c.useSyncExternalStore(c.useCallback(e=>a?a.subscribe(e):()=>{},[a]),c.useCallback(()=>a?.snapshot()??null,[a]));if(!a||!s||s.activeSubject===null)return null;const t=s.driver==="world",n=s.playbackState==="playing",{start:h,end:m,fps:o,loop:g}=s.range,d=s.subjects.find(e=>e.id===s.activeSubject),p=s.subjects.length>1?s.subjects:null,u=a.activeClips();return l.jsxs("section",{"aria-label":"Transport","data-testid":"stage-transport-strip",style:{display:"flex",alignItems:"center",gap:"var(--volter-space-2)",padding:"var(--volter-space-1) var(--volter-space-3)",borderTop:`var(--volter-stroke-resting) solid ${b.boundary.default}`,background:b.surface.raised},children:[l.jsx(v,{size:"compact","aria-label":n?"Pause":"Play",disabled:t,onClick:()=>n?a.pause():a.play(),children:l.jsx(x,{icon:n?r.transport.pause:r.transport.play})}),l.jsx(v,{size:"compact","aria-label":"Stop",disabled:t,onClick:()=>a.stop(),children:l.jsx(x,{icon:r.transport.stop})}),l.jsx(j,{"aria-label":"Playhead",type:"range",min:h,max:m,step:1/o,value:s.time,disabled:t,onChange:e=>a.seek(Number(e.target.value)),style:{flex:1}}),l.jsx(i,{as:"span",variant:"caption",children:f(s.time,o)}),p?l.jsx("select",{"aria-label":"Subject",value:s.activeSubject,disabled:t,onChange:e=>a.setActiveSubject(e.target.value),children:p.map(e=>l.jsx("option",{value:e.id,children:e.label},e.id))}):null,u?l.jsx("select",{"aria-label":"Clip",disabled:t,onChange:e=>a.setActiveClip(e.target.value),children:u.map(e=>l.jsx("option",{value:e.id,children:e.label},e.id))}):null,l.jsxs("label",{style:{display:"flex",alignItems:"center",gap:"var(--volter-space-1)"},children:[l.jsx("input",{type:"checkbox",checked:g,disabled:t,onChange:e=>a.setLoop(e.target.checked)}),l.jsx(i,{as:"span",variant:"caption",children:"Loop"})]}),l.jsx("select",{"aria-label":"Speed",value:String(s.timeScale),disabled:t,onChange:e=>a.setTimeScale(Number(e.target.value)),children:S.map(e=>l.jsxs("option",{value:String(e),children:[e,"×"]},e))}),t?l.jsx(i,{as:"span",variant:"caption",children:"The world is driving time (Play); pause the game to scrub"}):d?l.jsx(i,{as:"span",variant:"caption",children:d.label}):null]})}export{E as T};
1
+ import{a as l}from"./jsx-runtime-DPjLkJKQ.js";import{r as c}from"./index-nmcBqr7Y.js";import"./index-CtzuWnCS.js";import{ak as b,aL as v,a6 as x,a7 as r,aM as j,aK as i}from"./index-V4J7xfRg.js";const S=[.25,.5,1,2];function y(a,s){const t=Math.round(a*s);return`${a.toFixed(2)}s · f${t}`}function E({transport:a}){const s=c.useSyncExternalStore(c.useCallback(e=>a?a.subscribe(e):()=>{},[a]),c.useCallback(()=>a?.snapshot()??null,[a]));if(!a||!s||s.activeSubject===null)return null;const t=s.driver==="world",n=s.playbackState==="playing",{start:h,end:m,fps:o,loop:g}=s.range,d=s.subjects.find(e=>e.id===s.activeSubject),p=s.subjects.length>1?s.subjects:null,u=a.activeClips();return l.jsxs("section",{"aria-label":"Transport","data-testid":"stage-transport-strip",style:{display:"flex",alignItems:"center",gap:"var(--volter-space-2)",padding:"var(--volter-space-1) var(--volter-space-3)",borderTop:`var(--volter-stroke-resting) solid ${b.boundary.default}`,background:b.surface.raised},children:[l.jsx(v,{size:"compact","aria-label":n?"Pause":"Play",disabled:t,onClick:()=>n?a.pause():a.play(),children:l.jsx(x,{icon:n?r.transport.pause:r.transport.play})}),l.jsx(v,{size:"compact","aria-label":"Stop",disabled:t,onClick:()=>a.stop(),children:l.jsx(x,{icon:r.transport.stop})}),l.jsx(j,{"aria-label":"Playhead",type:"range",min:h,max:m,step:1/o,value:s.time,disabled:t,onChange:e=>a.seek(Number(e.target.value)),style:{flex:1}}),l.jsx(i,{as:"span",variant:"caption",children:y(s.time,o)}),p?l.jsx("select",{"aria-label":"Subject",value:s.activeSubject,disabled:t,onChange:e=>a.setActiveSubject(e.target.value),children:p.map(e=>l.jsx("option",{value:e.id,children:e.label},e.id))}):null,u?l.jsx("select",{"aria-label":"Clip",disabled:t,onChange:e=>a.setActiveClip(e.target.value),children:u.map(e=>l.jsx("option",{value:e.id,children:e.label},e.id))}):null,l.jsxs("label",{style:{display:"flex",alignItems:"center",gap:"var(--volter-space-1)"},children:[l.jsx("input",{type:"checkbox",checked:g,disabled:t,onChange:e=>a.setLoop(e.target.checked)}),l.jsx(i,{as:"span",variant:"caption",children:"Loop"})]}),l.jsx("select",{"aria-label":"Speed",value:String(s.timeScale),disabled:t,onChange:e=>a.setTimeScale(Number(e.target.value)),children:S.map(e=>l.jsxs("option",{value:String(e),children:[e,"×"]},e))}),t?l.jsx(i,{as:"span",variant:"caption",children:"The world is driving time (Play); pause the game to scrub"}):d?l.jsx(i,{as:"span",variant:"caption",children:d.label}):null]})}export{E as T};
@@ -0,0 +1 @@
1
+ import{a as o}from"./jsx-runtime-DPjLkJKQ.js";import{r as t}from"./index-V4J7xfRg.js";import{r as m}from"./index-nmcBqr7Y.js";import{P as p}from"./PlayBar-BbzjgLFJ.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-D_NuPfjr.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./configurations-CRTYw0r9.js";import"./run-selection-AyelFc9T.js";import"./game-network-CAH_Jsh6.js";import"./index-OZVqp6xS.js";import"./index-Da9JhEvW.js";import"./native-debug-module-JJOFtIVz.js";import"./native-entry-surface-BE8LJNdu.js";import"./debug-registry-xQJcVubm.js";import"./contract-system-adapters-rVGdworX.js";import"./game-contract-seams-DrYyE5PX.js";import"./seeded-random-tpdJjdqy.js";import"./game-audio-BeCyd0Ha.js";import"./rapier-physics-adapter-CaZqWLu0.js";import"./events-156d8d12.esm-CYeuVCYr.js";import"./three.module-BLhyNg0e.js";import"./three.core-3arARmh6.js";import"./index-bQE2NA0D.js";import"./live-project-verbs-CnknlUlT.js";import"./capability-coverage-wd6bAhv3.js";import"./edit-mode-authoring-CSt3zzmS.js";import"./json-history-resource-CH2nzMZh.js";import"./binding-resolver-DUz8C8Fs.js";import"./adapter-surface-Y37Nzcyw.js";import"./structural-signature-Dc7skRiy.js";import"./webgl-frame-capture-DdJkM2mi.js";import"./realm-services-u0mnjXU9.js";import"./canvas-entry-runtime-DskaohHK.js";import"./three-ingest-runtime-BnRF_nJN.js";import"./EffectComposer-BEAt0PtQ.js";import"./CopyShader-BzTUYzf6.js";import"./ShaderPass-DTnDQXm0.js";import"./Pass-D1MRT672.js";import"./CSS3DRenderer-BsAqfavI.js";import"./relative-path-guard-GiM7Lsz8.js";import"./react-root-BHA-cdrW.js";import"./editor-presentation-activity-CqJH4G9t.js";import"./active-ingest-D_ryI_R4.js";import"./ingest-source-persistence-CQOJeGhj.js";import"./pixi-story-model-DNkfnWUV.js";import"./surface-content-Dg9Kkazf.js";import"./viewport-root-presentation-DJLpUuf0.js";import"./mounted-authoring-C47L5H5t.js";import"./entity-object-V13bGmay.js";import"./user-data-CifDDvSr.js";import"./workspace-arrangement-B_OcbQbj.js";import"./three-contract-Dkt6PmWY.js";import"./three-BQfhEwUz.js";import"./editor-layers-CjeYrUlm.js";import"./component-instance-root-Cw_-ajBX.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./three-authoring-adapter-COBwREQO.js";import"./source-persistence-backend-uyd6NiWD.js";import"./three-projection-core-PQm-CO61.js";import"./body-marks-C1LxJtQb.js";import"./user-data-CODoGZqA.js";import"./object-marks-BnvSuCTt.js";import"./structural-ids-BOo2BRoY.js";import"./object3d-authoring-subject-XccsO0xG.js";import"./r3f-physics-binding-DZSIB0d_.js";import"./deferred-ingest-play-CEnsC3uN.js";import"./rrweb-Cd2ifIRP.js";import"./react-world-authoring-adapter-OR1SW2jI.js";import"./board-guides-B6TEPOPi.js";import"./relative-import-specifier-DXWVQf0o.js";import"./story-arg-descriptors-Ek86ExX7.js";import"./inspect-DiSjB-N1.js";import"./inference-diagnostics-DoZQ1mpg.js";import"./writer-tw6EcuVO.js";import"./three-state-C7khRIQE.js";import"./editor-shell-store-DckLm6m8.js";import"./output-pass-HurwNl0G.js";import"./viewport-door-BCXEYmon.js";import"./game-surface-defaults-D8S4cRxi.js";const Dr="workspace.header",Fr=0;function Gr(){const{project:r}=t();return m.useSyncExternalStore(r.subscribe,r.mounts,r.mounts)?o.jsx(p,{}):null}export{Gr as default,Fr as order,Dr as point};
@@ -1 +1 @@
1
- import{e1 as e,bA as o,t as r}from"./index-flxMlfV4.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const t=e([o(),o(),o()]).describe("3D vector as [x, y, z]"),i=e([o(),o(),o(),o()]).describe("Quaternion as [x, y, z, w]"),x=r({position:t.optional().describe("World-space position [x, y, z]"),rotation:i.optional().describe("Rotation quaternion [x, y, z, w]"),scale:t.optional().describe("Scale factor per axis [x, y, z]. Defaults to [1, 1, 1]")}).describe("Local transform relative to parent entity");export{i as QuatSchema,x as TransformSchema,t as Vec3Schema};
1
+ import{e1 as e,c5 as o,t as r}from"./index-V4J7xfRg.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const t=e([o(),o(),o()]).describe("3D vector as [x, y, z]"),i=e([o(),o(),o(),o()]).describe("Quaternion as [x, y, z, w]"),x=r({position:t.optional().describe("World-space position [x, y, z]"),rotation:i.optional().describe("Rotation quaternion [x, y, z, w]"),scale:t.optional().describe("Scale factor per axis [x, y, z]. Defaults to [1, 1, 1]")}).describe("Local transform relative to parent entity");export{i as QuatSchema,x as TransformSchema,t as Vec3Schema};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/story-capture-B8wfSf5s.js","assets/react-story-board-CT1_3sk_.js","assets/jsx-runtime-DPjLkJKQ.js","assets/_commonjsHelpers-D6-XlEtG.js","assets/index-nmcBqr7Y.js","assets/index-D_NuPfjr.js","assets/index-CtzuWnCS.js","assets/index-CinJrH5C.js","assets/index-V4J7xfRg.js","assets/index-FUuS4qwW.js","assets/client-DNXj_opT.js","assets/index-CPiRKiDC.css","assets/bitmap-label-Ct4k6ehY.js","assets/StoryPreviewMount-CmOEFzZY.js","assets/story-presentation-CofUdEU7.js"])))=>i.map(i=>d[i]);
2
+ import{dJ as m,ar as s,dK as a,aB as n,_ as c,b9 as d}from"./index-V4J7xfRg.js";import{a as u}from"./jsx-runtime-DPjLkJKQ.js";import{d as l,p as v,r as P}from"./design-time-layers-hmGqBp06.js";import{RootDocumentContent as _}from"./world-documents-Bx3j867R.js";import{U as w}from"./component-board.service-Cd1c9oSN.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./root-stacking-BEd9ZvxC.js";import"./edit-mode-authoring-CSt3zzmS.js";import"./design-time-mount-registry-DUpXCg1U.js";import"./react-story-board-CT1_3sk_.js";import"./game-surface-defaults-D8S4cRxi.js";import"./react-canvas-navigation-L_mOnybL.js";import"./component-board-registry-DrIa2csL.js";import"./surface-state-DrM3wsrr.js";import"./board-guides-B6TEPOPi.js";import"./CanvasSceneViewport-CfOuQiQ0.js";import"./RootSelectionOverlay-C6Wu8nIs.js";import"./eyedropper-session-bjPXnfeX.js";import"./layered-pick-BUr1U8lU.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./inspect-DiSjB-N1.js";import"./inference-diagnostics-DoZQ1mpg.js";import"./Toolbar-BEBQdxRz.js";import"./transform-mode-request-DWM6BdRA.js";import"./TransientHint-CzsdY8W6.js";import"./ReactCanvasControls-BL2tOUj6.js";import"./story-media-presence-SGlp_afL.js";const y={revision:()=>JSON.stringify(d().map(({id:i,modulePath:t})=>[i,t])),subscribe:s,capture:async({width:i,height:t})=>{const{captureDomStoryBoardPreview:o}=await c(async()=>{const{captureDomStoryBoardPreview:e}=await import("./story-capture-B8wfSf5s.js");return{captureDomStoryBoardPreview:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14]));return o(i,t)}};function Z({store:i,composite:t}){const o=l(t).find(r=>r.kind==="dom")??v(),e=r=>u.jsx(_,{...r,composite:t,descriptor:o,store:i});m({id:a,title:w,kind:"world",workspaceRole:"authored-subject",provenance:{rootId:o.worldId,...o.path?{sourcePath:o.path}:{}},Content:e,preview:y,presentation:()=>{const r=n()?.rootPath,p=r?P(r,o.worldId):void 0;return{kind:"workspace",id:a,...p?{story:p}:{}}}},{category:"canvas",default:!t.childAdapters().some(r=>r.kind==="three"||r.kind==="canvas")})}export{Z as installUiBoard};
@@ -1 +1 @@
1
- import{O as n}from"./workspace-arrangement-BnGzBm57.js";const r={...n,entityId:"entityId",forward:"forward",tags:"tags",attributes:"attributes",navRole:"navRole",pivot:"pivot",splineCurve:"splineCurve",splineControlPoint:"splineControlPoint",_camera:"_camera",_particleSystem:"_particleSystem",gaussianSplat:"gaussianSplat",__sharedGeometry:"__sharedGeometry",__shadeOrig:"__shadeOrig",__shadeUnlit:"__shadeUnlit",__ingest:"__ingest",__ingestNextId:"__ingestNextId",authoringRoot:"authoringRoot",authoringInstance:"authoringInstance",authoringLabel:"authoringLabel",authoringComponent:"authoringComponent",authoringDocument:"authoringDocument",authoringHierarchyId:"authoringHierarchyId",authoringHierarchyParentId:"authoringHierarchyParentId",authoringHierarchyOrder:"authoringHierarchyOrder",editorIcon:"editorIcon",envObject:"envObject",constraints:"constraints",authoringSubject:"authoringSubject",reflectionProbe:"reflectionProbe",triggerVolume:"triggerVolume",vcDirIdx:"vcDirIdx"};function o(t,e){return t?t.userData[r[e]]:void 0}function s(t,e,a){t.userData[r[e]]=a}function u(t,e){return t?t.userData[r[e]]!==void 0:!1}export{o as g,u as h,s};
1
+ import{O as n}from"./workspace-arrangement-B_OcbQbj.js";const r={...n,entityId:"entityId",forward:"forward",tags:"tags",attributes:"attributes",navRole:"navRole",pivot:"pivot",splineCurve:"splineCurve",splineControlPoint:"splineControlPoint",_camera:"_camera",_particleSystem:"_particleSystem",gaussianSplat:"gaussianSplat",__sharedGeometry:"__sharedGeometry",__shadeOrig:"__shadeOrig",__shadeUnlit:"__shadeUnlit",__ingest:"__ingest",__ingestNextId:"__ingestNextId",authoringRoot:"authoringRoot",authoringInstance:"authoringInstance",authoringLabel:"authoringLabel",authoringComponent:"authoringComponent",authoringDocument:"authoringDocument",authoringHierarchyId:"authoringHierarchyId",authoringHierarchyParentId:"authoringHierarchyParentId",authoringHierarchyOrder:"authoringHierarchyOrder",editorIcon:"editorIcon",envObject:"envObject",constraints:"constraints",authoringSubject:"authoringSubject",reflectionProbe:"reflectionProbe",triggerVolume:"triggerVolume",vcDirIdx:"vcDirIdx"};function o(t,e){return t?t.userData[r[e]]:void 0}function s(t,e,a){t.userData[r[e]]=a}function u(t,e){return t?t.userData[r[e]]!==void 0:!1}export{o as g,u as h,s};
@@ -1 +1 @@
1
- import{a4 as l}from"./index-flxMlfV4.js";function f(c,i){let t=i,s=0;const r=new Set,o=()=>{s++;for(const e of r)e()},n=e=>{t!==e&&(t=e,o())};return{subscribe(e){return r.add(e),()=>{r.delete(e)}},version:()=>s,active:()=>t,select:n,open(e){n(e),l(c)},notify:o,reset(){t=i,o()}}}const p=f("tool:profiler.utility","profiler");export{p};
1
+ import{a9 as l}from"./index-V4J7xfRg.js";function f(c,i){let t=i,s=0;const r=new Set,o=()=>{s++;for(const e of r)e()},n=e=>{t!==e&&(t=e,o())};return{subscribe(e){return r.add(e),()=>{r.delete(e)}},version:()=>s,active:()=>t,select:n,open(e){n(e),l(c)},notify:o,reset(){t=i,o()}}}const p=f("tool:profiler.utility","profiler");export{p};
@@ -1 +1 @@
1
- import{x as w}from"./index-flxMlfV4.js";const s=new Map,f=new Map;function g(e){let t=f.get(e);return t||(t={frameListeners:new Set,helpers:new Map},f.set(e,t)),t}const l=new Set,c=new Set;function i(){for(const t of s.values())if(t.presenting)return t;const e=w();if(e!==null){const t=s.get(e);if(t)return t}return s.values().next().value??null}let a=null;function p(){a=null;const e=v();for(const t of c)t(e)}function h(e,t){const n=g(e);return{documentId:e,rig:()=>s.get(e)?.rig??t,setHelper:(r,o)=>{n.helpers.set(r,o),s.get(e)?.setHelper(r,o)},onFrame:r=>(n.frameListeners.add(r),()=>{n.frameListeners.delete(r)})}}function S(e,t,n,r){const o=g(r.documentId),u={documentId:r.documentId,rig:e,present:t,setHelper:n,frameListeners:o.frameListeners,helpers:o.helpers,presenting:!1};s.set(r.documentId,u);for(const[d,m]of u.helpers)n(d,m);return p(),()=>{s.get(r.documentId)===u&&(s.delete(r.documentId),p())}}function I(e,t){const n=i();n&&(n.helpers.set(e,t),n.setHelper(e,t))}function V(){return i()?.rig??null}function F(e){const t=i();if(!t)return null;const n=t.present(e);if(!n)return null;t.presenting=!0;let r=!1;return{worldId:n.worldId,dispose:()=>{r||(r=!0,t.presenting=!1),n.dispose()}}}function x(e){return l.add(e),()=>{l.delete(e)}}function v(){return a||(a=[...s.values()].map(e=>h(e.documentId,e.rig))),a}function y(e){const t=f.get(e);return t?[...t.helpers].filter(([,n])=>n!==null).map(([n])=>n):[]}function H(e){return c.add(e),()=>{c.delete(e)}}function b(e,t){const n=s.get(e);if(n){for(const r of n.frameListeners)r(t);if(i()===n)for(const r of l)r(t)}}export{V as a,v as b,x as c,S as d,H as o,F as p,b as r,I as s,y as v};
1
+ import{x as w}from"./index-V4J7xfRg.js";const s=new Map,f=new Map;function g(e){let t=f.get(e);return t||(t={frameListeners:new Set,helpers:new Map},f.set(e,t)),t}const l=new Set,c=new Set;function i(){for(const t of s.values())if(t.presenting)return t;const e=w();if(e!==null){const t=s.get(e);if(t)return t}return s.values().next().value??null}let a=null;function p(){a=null;const e=v();for(const t of c)t(e)}function h(e,t){const n=g(e);return{documentId:e,rig:()=>s.get(e)?.rig??t,setHelper:(r,o)=>{n.helpers.set(r,o),s.get(e)?.setHelper(r,o)},onFrame:r=>(n.frameListeners.add(r),()=>{n.frameListeners.delete(r)})}}function S(e,t,n,r){const o=g(r.documentId),u={documentId:r.documentId,rig:e,present:t,setHelper:n,frameListeners:o.frameListeners,helpers:o.helpers,presenting:!1};s.set(r.documentId,u);for(const[d,m]of u.helpers)n(d,m);return p(),()=>{s.get(r.documentId)===u&&(s.delete(r.documentId),p())}}function I(e,t){const n=i();n&&(n.helpers.set(e,t),n.setHelper(e,t))}function V(){return i()?.rig??null}function F(e){const t=i();if(!t)return null;const n=t.present(e);if(!n)return null;t.presenting=!0;let r=!1;return{worldId:n.worldId,dispose:()=>{r||(r=!0,t.presenting=!1),n.dispose()}}}function x(e){return l.add(e),()=>{l.delete(e)}}function v(){return a||(a=[...s.values()].map(e=>h(e.documentId,e.rig))),a}function y(e){const t=f.get(e);return t?[...t.helpers].filter(([,n])=>n!==null).map(([n])=>n):[]}function H(e){return c.add(e),()=>{c.delete(e)}}function b(e,t){const n=s.get(e);if(n){for(const r of n.frameListeners)r(t);if(i()===n)for(const r of l)r(t)}}export{V as a,v as b,x as c,S as d,H as o,F as p,b as r,I as s,y as v};
@@ -1 +1 @@
1
- import{s}from"./mounted-authoring-BHpx-z2Y.js";import{s as u}from"./three-2yjp9YMj.js";import{t as m}from"./three-contract-Dkt6PmWY.js";function c(t,d){const e=d.find(i=>i.mounted.kind==="three");if(!e||e.mounted.kind!=="three")return null;const n=m(e.mounted).scene,o=e.mounted.authoring;o&&s(n,o),u(n,a(e.id)),t.enterPlayScene(n,e.mounted.rendererConfig);let r=!1;return{worldId:e.id,dispose(){r||(r=!0,t.releaseAdoptedScene(n))}}}function a(t){return t??"main"}export{a as l,c as p};
1
+ import{s}from"./mounted-authoring-C47L5H5t.js";import{s as u}from"./three-BQfhEwUz.js";import{t as m}from"./three-contract-Dkt6PmWY.js";function c(t,d){const e=d.find(i=>i.mounted.kind==="three");if(!e||e.mounted.kind!=="three")return null;const n=m(e.mounted).scene,o=e.mounted.authoring;o&&s(n,o),u(n,a(e.id)),t.enterPlayScene(n,e.mounted.rendererConfig);let r=!1;return{worldId:e.id,dispose(){r||(r=!0,t.releaseAdoptedScene(n))}}}function a(t){return t??"main"}export{a as l,c as p};
@@ -1 +1 @@
1
- import{a as r}from"./jsx-runtime-DPjLkJKQ.js";import"./index-nmcBqr7Y.js";import"./index-CtzuWnCS.js";import{af as i}from"./index-flxMlfV4.js";const m="Preparing the viewport…",n="Preparing 3D component previews…";function c(e){return!Number.isFinite(e)||e<1?n:e===1?"Preparing 1 component preview…":`Preparing ${e} component previews…`}function u({testId:e,children:t}){return r.jsx("div",{"data-testid":e,style:{position:"absolute",inset:0,padding:16,fontSize:12,color:i.content.muted,pointerEvents:"none"},children:t})}export{m as O,u as V,c as t};
1
+ import{a as r}from"./jsx-runtime-DPjLkJKQ.js";import"./index-nmcBqr7Y.js";import"./index-CtzuWnCS.js";import{ak as i}from"./index-V4J7xfRg.js";const m="Preparing the viewport…",n="Preparing 3D component previews…";function c(e){return!Number.isFinite(e)||e<1?n:e===1?"Preparing 1 component preview…":`Preparing ${e} component previews…`}function u({testId:e,children:t}){return r.jsx("div",{"data-testid":e,style:{position:"absolute",inset:0,padding:16,fontSize:12,color:i.content.muted,pointerEvents:"none"},children:t})}export{m as O,u as V,c as t};
@@ -1 +1 @@
1
- import{e as t,d as i,f as r,g as m}from"./index-BHccVo52.js";import"./index-flxMlfV4.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";t.add(i,r);t.add(m);
1
+ import{e as t,d as i,f as r,g as m}from"./index-D_ViOFCz.js";import"./index-V4J7xfRg.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";t.add(i,r);t.add(m);
@@ -1,2 +1,2 @@
1
- const d="/work/.volter-session",ae=`${d}/session.py`,se=[`${d}/in`,`${d}/reply`],P="/__editor/blender-wasm";function D(e){return new URL(`${P}/${e}`,import.meta.url).href}async function M(){const e=await fetch(D("status"));return e.ok?await e.json():{available:!1,skew:null,dir:null,sizes:{},encoded:{},missing:[`${P}/status answered ${e.status}`]}}async function J(e){const t=await M();if(!t.available)throw new Error(`The headless Blender WebAssembly build is not served by this editor: ${t.missing.join("; ")}`);if(t.skew==="wali"){const{startWaliBlenderEngine:n}=await import("./blender-wali-engine-KWIxfB_o.js");return n(e,t)}const{startEmscriptenBlenderEngine:r}=await import("./blender-emscripten-engine-CieQeF-r.js");return r(e,t)}function U(e){return e<200?1:e<5e3?5:25}const C=e=>new Promise(t=>setTimeout(t,e)),B=new TextDecoder;function ie(e,t,r){let n=0,a=0;const o=new Set;async function s(u){for(const l of o)u.has(`${l}.done`)||(await e.unlink(`${d}/reply/${l}.json`),await e.unlink(`${d}/reply/${l}.done`),o.delete(l))}async function i(){let u;try{u=await e.readdir(`${d}/ask`)}catch{return}const l=new Set(u.filter(w=>w.endsWith(".done")));await s(l);for(const w of l){const h=w.slice(0,-5);if(Number(h)<=a)continue;a=Number(h);const $=JSON.parse(B.decode(await e.readFile(`${d}/ask/${h}.json`)));let p;try{p=await t.ask($)}catch(S){p={error:S instanceof Error?S.message:String(S)}}await Promise.all([e.writeFile(`${d}/reply/${h}.json`,JSON.stringify(p??null)),e.writeFile(`${d}/reply/${h}.done`,"1")]),o.add(h)}}async function c(u){const l=String(++n);await Promise.all([e.writeFile(`${d}/in/${l}.json`,JSON.stringify(u)),e.writeFile(`${d}/in/${l}.done`,"1")]);const w=performance.now();for(;;){if(await i(),await e.stat(`${d}/out/${l}.done`)){const p=JSON.parse(B.decode(await e.readFile(`${d}/out/${l}.json`)));if(await e.unlink(`${d}/in/${l}.json`),await e.unlink(`${d}/in/${l}.done`),p.error)throw new Error(p.error);return p.result}const h=r?.();if(h)throw new Error(`Blender is gone, so this call will never be answered: ${h}. The session keeps its directory and its cached banner, so every later call would wait on the same missing answer; start a new program with \`blender-start {fresh: true}\` (\`VOLTER_BLENDER_FRESH_SESSION=1\` for the battery harness).`);const $=U(performance.now()-w);await(e.changed?e.changed($):C($))}}return{request:c}}const L=e=>typeof e=="object"&&e!==null&&typeof e.offset=="number"&&typeof e.length=="number"&&typeof e.dtype=="string"&&typeof e.count=="number"&&typeof e.stride=="number",W={f32:e=>new Float32Array(e.buffer,e.byteOffset,e.byteLength>>2),f64:e=>new Float64Array(e.buffer,e.byteOffset,e.byteLength>>3),u32:e=>new Uint32Array(e.buffer,e.byteOffset,e.byteLength>>2),i32:e=>new Int32Array(e.buffer,e.byteOffset,e.byteLength>>2),u16:e=>new Uint16Array(e.buffer,e.byteOffset,e.byteLength>>1),i16:e=>new Int16Array(e.buffer,e.byteOffset,e.byteLength>>1),u8:e=>e,i8:e=>new Int8Array(e.buffer,e.byteOffset,e.byteLength)};function z(e,t,r){const n=W[r.dtype];if(!n)throw new Error(`Blender frame column ${t}: unknown dtype ${r.dtype}`);const{offset:a,length:o}=r;if(a<0||o<0||a+o>e.byteLength)throw new Error(`Blender frame column ${t}: bytes ${a}..${a+o} lie outside the ${e.byteLength}-byte export arena`);const s=e.subarray(a,a+o).slice(),i=n(s),c=r.count*r.stride;if(i.length!==c)throw new Error(`Blender frame column ${t}: ${i.length} values, ${c} declared (${r.count} x ${r.stride})`);return i}function H(e,t){const r=(n,a)=>{if(L(n)){const o=z(e,a,n);return a==="co"?Float64Array.from(o):o}if(Array.isArray(n))return n.map(o=>r(o,a));if(typeof n=="object"&&n!==null){const o={};for(const[s,i]of Object.entries(n))o[s]=r(i,s);return o}return n};return r(t,"")}async function V(e,t){const r=async(n,a)=>{if(L(n)){const{offset:o,length:s,dtype:i}=n;if(o<0||s<0||o+s>e.byteLength)throw new Error(`Blender frame column ${a}: bytes ${o}..${o+s} lie outside the ${e.byteLength}-byte export arena`);const c=e.subarray(o,o+s).slice(),u=await crypto.subtle.digest("SHA-256",c),l=[...new Uint8Array(u)].map(w=>w.toString(16).padStart(2,"0")).join("");return{dtype:i,length:s,sha256:l}}if(Array.isArray(n))return Promise.all(n.map(o=>r(o,a)));if(typeof n=="object"&&n!==null){const o={};for(const[s,i]of Object.entries(n))o[s]=await r(i,s);return o}return n};return r(t,"")}const m=e=>self.postMessage(e),k=(e,t)=>m({op:"log",level:e,text:t});let b=null,v=null,G=0;const j=new Map;function K(e,t,r){const n=++G,a=[],o=e;for(const s of[o?.meshes??{},o?.images??{}])for(const i of Object.values(s))for(const c of Object.values(i))ArrayBuffer.isView(c)&&c.buffer instanceof ArrayBuffer&&!a.includes(c.buffer)&&a.push(c.buffer);return new Promise((s,i)=>{j.set(n,{resolve:s,reject:i}),self.postMessage({op:"present",id:n,frame:e,description:t,...r?{capture:r}:{}},a)})}let f=null,E=null,T=!1,A=Promise.resolve();function Q(e){const t=A.then(e);return A=t.catch(()=>{}),t}function N(e){T=e,m({op:"document-dirty",dirty:e})}async function R(){if(!f||E===null)return;const e=E;let t;try{t=await f.request({op:"save-document"})}catch(n){throw new Error(`The Blender document ${e} could not be saved: ${g(n)}`)}if(!t?.saved||typeof t.path!="string")throw new Error(`Blender did not save the document ${e}`);let r;try{r=await f.files.readFile(t.path)}catch(n){throw new Error(`The Blender document ${e} could not be read back out of the engine: ${g(n)}`)}y.delete(t.path);try{const n=await fetch(`/__editor/blender-document?path=${encodeURIComponent(e)}`,{method:"POST",headers:{"content-type":"application/octet-stream"},body:new Blob([r])});if(!n.ok){const a=await n.text().catch(()=>"");throw new Error(`HTTP ${n.status} ${a}`)}}catch(n){throw new Error(`The Blender document ${e} was not written to the project: ${g(n)}`)}N(!1),k("log",`@@VOLTER-DOCUMENT ${JSON.stringify({path:e,bytes:r.length})}`)}async function X(e,t){const r={engine:null},n=await J({project:e,log:k,ask:async({frame:o,capture:s,saveDue:i})=>{if(!r.engine)throw new Error("The Blender session presented before it started");i&&E!==null&&N(!0);const c=await r.engine.readArena(),u=await V(c,o),l=await K(H(c,o),u,s);return{...typeof l.capture=="object"&&l.capture!==null?l.capture:{},..."held"in l?{held:l.held}:{}}}});r.engine=n,f=n,t&&await _(n.files,e);const a=await n.request({op:"start",project:e,...t?{document:t}:{}});return t&&(E=t),b={start:async()=>a,execute:async o=>{const s=await n.request({op:"execute",code:o});return s.error?`Error executing code: ${s.error}`:`Code executed successfully: ${s.result}`},sceneInfo:async()=>JSON.stringify(await n.request({op:"scene-info"}),null,2),objectInfo:async o=>JSON.stringify(await n.request({op:"object-info",name:o}),null,2),screenshotView:async o=>(await n.request({op:"present",capture:{size:o}}),JSON.stringify({view:{size:o}}))},{...a,engine:"blender-wasm",skew:n.skew,bootMs:Math.round(n.bootMs),releasedPayloadMB:n.releasedPayloadBytes===null?null:Math.round(n.releasedPayloadBytes/1048576)}}async function Y(){try{const e=await fetch("/__editor/blender-wasm/status");return e.ok?await e.json():{available:!1,missing:[`status answered ${e.status}`]}}catch(e){return{available:!1,missing:[String(e)]}}}async function Z(e,t){if(b)throw new Error("The Blender session is already started");if(!e.startsWith("/"))throw new Error("The Blender session needs the project's absolute path");if(t!==void 0&&!q(t))throw new Error(`The Blender document must be a project-relative .blend path with no traversal (models/model.blend); got ${JSON.stringify(t)}`);const r=await Y();if(!r.available)throw new Error(`Headless Blender is not served by this editor, so there is no modeling engine: ${r.missing.join("; ")}. The engine is Blender compiled to WebAssembly (packages/blender-engine/wasm, or the directory VOLTER_BLENDER_WASM_DIR names); nothing stands in for it.`);return v=e,X(e,t)}function q(e){return!e.endsWith(".blend")||e.startsWith("/")||e.includes("\\")?!1:e.split("/").every(r=>r!==""&&r!=="."&&r!=="..")}const x=new Set;function O(e){x.has(e)||(x.add(e),k("error",e))}async function ee(e){const t=s=>(O(`The project's files are not readable from Python: ${s}`),null);let r;try{r=await fetch("/__editor/blender-project-index")}catch(s){return t(String(s))}if(!r.ok)return t(`/__editor/blender-project-index answered ${r.status}`);let n;try{if(n=await r.json(),typeof n?.root!="string"||!Array.isArray(n.files))return t("invalid project index")}catch(s){return t(String(s))}const{root:a,files:o}=n;return a!==e&&O(`The editor serving this tab has ${a} open, not ${e}; its files are mounted at ${e}, which is where Python is looking.`),o}const y=new Map;async function te(e,t){const r=await e.stat(t);return r?`${r.size}:${r.mtimeMs}`:""}async function _(e,t){const r=await ee(t);if(!r)return;const n=new Set(r.map(a=>`${t}/${a.path}`));for(const a of[...y.keys()])if(!n.has(a)){try{await e.unlink(a)}catch{}y.delete(a)}for(const a of r){const o=`${t}/${a.path}`,s=`${a.size}:${a.mtime}`;if(y.get(o)?.host===s||!y.has(o)&&await e.stat(o)!==null)continue;const i=await fetch(`/__editor/blender-project-file?path=${encodeURIComponent(a.path)}`);if(!i.ok){O(`${a.path}: HTTP ${i.status}`);continue}const c=o.slice(0,o.lastIndexOf("/"));c&&await e.mkdirTree(c),await e.writeFile(o,new Uint8Array(await i.arrayBuffer())),y.set(o,{host:s,engine:await te(e,o)})}}async function ne(e,t){const r=[],n=async a=>{let o;try{o=await e.readdir(a)}catch{return}for(const s of o){if(s==="."||s==="..")continue;const i=`${a.replace(/\/$/,"")}/${s}`,c=await e.stat(i);if(c){if((c.mode&61440)===16384){await n(i);continue}y.get(i)?.engine!==`${c.size}:${c.mtimeMs}`&&r.push({path:i,size:c.size,mtime:c.mtimeMs})}}};return await n(t),r}async function F(e){switch(e.op){case"start":return Z(e.project,e.document);case"present-result":{const n=j.get(e.id);j.delete(e.id),n&&(e.error?n.reject(new Error(e.error)):n.resolve({...e.capture===void 0?{}:{capture:e.capture},..."held"in e?{held:e.held}:{}}));return}}if(!b||!v||!f)throw new Error("The Blender session has not started");const t=f.files,r=f.request.bind(f);switch(e.op){case"flush-document":return T?(await R(),{saved:!0}):{saved:!1};case"history-begin":case"history-end":return r({op:e.op});case"history-step":return r({op:"history-step",token:e.token,direction:e.direction});case"execute":await _(t,v);{const n=await r({op:"execute",code:e.code,history:e.history??!0,label:e.label??"Blender Python"});return n.error?`Error executing code: ${n.error}`:`Code executed successfully: ${n.result}`}case"present":return r({op:"present"});case"scene-info":return b.sceneInfo();case"object-info":return b.objectInfo(e.name);case"rna":return r({op:"rna",path:e.path,...e.names===void 0?{}:{names:e.names}});case"rna-context":return r({op:"rna-context",...e.object===void 0?{}:{object:e.object},...e.collection===void 0?{}:{collection:e.collection}});case"rna-set":return r({op:"rna-set",history:e.history!==!1,path:e.path,property:e.property,value:e.value,...e.index===void 0?{}:{index:e.index}});case"outliner":return r({op:"outliner",...e.selected===void 0?{}:{selected:[...e.selected]}});case"node-tree":return r({op:"node-tree",...e.path===void 0?{}:{path:e.path},...e.material===void 0?{}:{material:e.material}});case"uv-layout":return r({op:"uv-layout",...e.object===void 0?{}:{object:e.object},...e.uvLayer===void 0?{}:{uvLayer:e.uvLayer}});case"rig":return r({op:"rig",...e.object===void 0?{}:{object:e.object}});case"action-clip":return r({op:"action-clip",...e.object===void 0?{}:{object:e.object},...e.bake===void 0?{}:{bake:e.bake}});case"outliner-set":return r({op:"outliner-set",path:e.path,column:e.column,value:e.value});case"screenshot-view":return JSON.parse(await b.screenshotView(e.maxSize));case"read-file":return t.readFile(e.path);case"write-file":{const n=e.path.slice(0,e.path.lastIndexOf("/"));n&&await t.mkdirTree(n),await t.writeFile(e.path,e.bytes),y.delete(e.path);return}case"list-files":return ne(t,e.path)}throw new Error(`Unknown Blender worker request ${e.op}`)}function g(e){if(e instanceof Error)return e.stack??`${e.name}: ${e.message}`;if(typeof e=="object"&&e!==null){const t=e;if(typeof t.message=="string")return typeof t.name=="string"?`${t.name}: ${t.message}`:t.message;try{return JSON.stringify(e)??Object.prototype.toString.call(e)}catch{return Object.prototype.toString.call(e)}}return String(e)}function re(){if(!f)return;const e=f.memoryBytes();e!==null&&m({op:"memory",bytes:e})}self.onmessage=e=>{const t=e.data;if(t.op==="present-result"){F(t);return}Q(()=>oe(t))};async function oe(e){try{const t=await F(e);T&&await R(),await I(),m({id:e.id,result:t})}catch(t){let r=g(t);try{await I()}catch(n){r+=`
1
+ const d="/work/.volter-session",ae=`${d}/session.py`,se=[`${d}/in`,`${d}/reply`],P="/__editor/blender-wasm";function D(e){return new URL(`${P}/${e}`,import.meta.url).href}async function M(){const e=await fetch(D("status"));return e.ok?await e.json():{available:!1,skew:null,dir:null,sizes:{},encoded:{},missing:[`${P}/status answered ${e.status}`]}}async function J(e){const t=await M();if(!t.available)throw new Error(`The headless Blender WebAssembly build is not served by this editor: ${t.missing.join("; ")}`);if(t.skew==="wali"){const{startWaliBlenderEngine:n}=await import("./blender-wali-engine-CO-jG_ik.js");return n(e,t)}const{startEmscriptenBlenderEngine:r}=await import("./blender-emscripten-engine-DQljvfR7.js");return r(e,t)}function U(e){return e<200?1:e<5e3?5:25}const C=e=>new Promise(t=>setTimeout(t,e)),B=new TextDecoder;function ie(e,t,r){let n=0,a=0;const o=new Set;async function s(u){for(const l of o)u.has(`${l}.done`)||(await e.unlink(`${d}/reply/${l}.json`),await e.unlink(`${d}/reply/${l}.done`),o.delete(l))}async function i(){let u;try{u=await e.readdir(`${d}/ask`)}catch{return}const l=new Set(u.filter(w=>w.endsWith(".done")));await s(l);for(const w of l){const h=w.slice(0,-5);if(Number(h)<=a)continue;a=Number(h);const $=JSON.parse(B.decode(await e.readFile(`${d}/ask/${h}.json`)));let p;try{p=await t.ask($)}catch(S){p={error:S instanceof Error?S.message:String(S)}}await Promise.all([e.writeFile(`${d}/reply/${h}.json`,JSON.stringify(p??null)),e.writeFile(`${d}/reply/${h}.done`,"1")]),o.add(h)}}async function c(u){const l=String(++n);await Promise.all([e.writeFile(`${d}/in/${l}.json`,JSON.stringify(u)),e.writeFile(`${d}/in/${l}.done`,"1")]);const w=performance.now();for(;;){if(await i(),await e.stat(`${d}/out/${l}.done`)){const p=JSON.parse(B.decode(await e.readFile(`${d}/out/${l}.json`)));if(await e.unlink(`${d}/in/${l}.json`),await e.unlink(`${d}/in/${l}.done`),p.error)throw new Error(p.error);return p.result}const h=r?.();if(h)throw new Error(`Blender is gone, so this call will never be answered: ${h}. The session keeps its directory and its cached banner, so every later call would wait on the same missing answer; start a new program with \`blender-start {fresh: true}\` (\`VOLTER_BLENDER_FRESH_SESSION=1\` for the battery harness).`);const $=U(performance.now()-w);await(e.changed?e.changed($):C($))}}return{request:c}}const L=e=>typeof e=="object"&&e!==null&&typeof e.offset=="number"&&typeof e.length=="number"&&typeof e.dtype=="string"&&typeof e.count=="number"&&typeof e.stride=="number",W={f32:e=>new Float32Array(e.buffer,e.byteOffset,e.byteLength>>2),f64:e=>new Float64Array(e.buffer,e.byteOffset,e.byteLength>>3),u32:e=>new Uint32Array(e.buffer,e.byteOffset,e.byteLength>>2),i32:e=>new Int32Array(e.buffer,e.byteOffset,e.byteLength>>2),u16:e=>new Uint16Array(e.buffer,e.byteOffset,e.byteLength>>1),i16:e=>new Int16Array(e.buffer,e.byteOffset,e.byteLength>>1),u8:e=>e,i8:e=>new Int8Array(e.buffer,e.byteOffset,e.byteLength)};function z(e,t,r){const n=W[r.dtype];if(!n)throw new Error(`Blender frame column ${t}: unknown dtype ${r.dtype}`);const{offset:a,length:o}=r;if(a<0||o<0||a+o>e.byteLength)throw new Error(`Blender frame column ${t}: bytes ${a}..${a+o} lie outside the ${e.byteLength}-byte export arena`);const s=e.subarray(a,a+o).slice(),i=n(s),c=r.count*r.stride;if(i.length!==c)throw new Error(`Blender frame column ${t}: ${i.length} values, ${c} declared (${r.count} x ${r.stride})`);return i}function H(e,t){const r=(n,a)=>{if(L(n)){const o=z(e,a,n);return a==="co"?Float64Array.from(o):o}if(Array.isArray(n))return n.map(o=>r(o,a));if(typeof n=="object"&&n!==null){const o={};for(const[s,i]of Object.entries(n))o[s]=r(i,s);return o}return n};return r(t,"")}async function V(e,t){const r=async(n,a)=>{if(L(n)){const{offset:o,length:s,dtype:i}=n;if(o<0||s<0||o+s>e.byteLength)throw new Error(`Blender frame column ${a}: bytes ${o}..${o+s} lie outside the ${e.byteLength}-byte export arena`);const c=e.subarray(o,o+s).slice(),u=await crypto.subtle.digest("SHA-256",c),l=[...new Uint8Array(u)].map(w=>w.toString(16).padStart(2,"0")).join("");return{dtype:i,length:s,sha256:l}}if(Array.isArray(n))return Promise.all(n.map(o=>r(o,a)));if(typeof n=="object"&&n!==null){const o={};for(const[s,i]of Object.entries(n))o[s]=await r(i,s);return o}return n};return r(t,"")}const m=e=>self.postMessage(e),k=(e,t)=>m({op:"log",level:e,text:t});let b=null,v=null,G=0;const j=new Map;function K(e,t,r){const n=++G,a=[],o=e;for(const s of[o?.meshes??{},o?.images??{}])for(const i of Object.values(s))for(const c of Object.values(i))ArrayBuffer.isView(c)&&c.buffer instanceof ArrayBuffer&&!a.includes(c.buffer)&&a.push(c.buffer);return new Promise((s,i)=>{j.set(n,{resolve:s,reject:i}),self.postMessage({op:"present",id:n,frame:e,description:t,...r?{capture:r}:{}},a)})}let f=null,E=null,T=!1,A=Promise.resolve();function Q(e){const t=A.then(e);return A=t.catch(()=>{}),t}function N(e){T=e,m({op:"document-dirty",dirty:e})}async function R(){if(!f||E===null)return;const e=E;let t;try{t=await f.request({op:"save-document"})}catch(n){throw new Error(`The Blender document ${e} could not be saved: ${g(n)}`)}if(!t?.saved||typeof t.path!="string")throw new Error(`Blender did not save the document ${e}`);let r;try{r=await f.files.readFile(t.path)}catch(n){throw new Error(`The Blender document ${e} could not be read back out of the engine: ${g(n)}`)}y.delete(t.path);try{const n=await fetch(`/__editor/blender-document?path=${encodeURIComponent(e)}`,{method:"POST",headers:{"content-type":"application/octet-stream"},body:new Blob([r])});if(!n.ok){const a=await n.text().catch(()=>"");throw new Error(`HTTP ${n.status} ${a}`)}}catch(n){throw new Error(`The Blender document ${e} was not written to the project: ${g(n)}`)}N(!1),k("log",`@@VOLTER-DOCUMENT ${JSON.stringify({path:e,bytes:r.length})}`)}async function X(e,t){const r={engine:null},n=await J({project:e,log:k,ask:async({frame:o,capture:s,saveDue:i})=>{if(!r.engine)throw new Error("The Blender session presented before it started");i&&E!==null&&N(!0);const c=await r.engine.readArena(),u=await V(c,o),l=await K(H(c,o),u,s);return{...typeof l.capture=="object"&&l.capture!==null?l.capture:{},..."held"in l?{held:l.held}:{}}}});r.engine=n,f=n,t&&await _(n.files,e);const a=await n.request({op:"start",project:e,...t?{document:t}:{}});return t&&(E=t),b={start:async()=>a,execute:async o=>{const s=await n.request({op:"execute",code:o});return s.error?`Error executing code: ${s.error}`:`Code executed successfully: ${s.result}`},sceneInfo:async()=>JSON.stringify(await n.request({op:"scene-info"}),null,2),objectInfo:async o=>JSON.stringify(await n.request({op:"object-info",name:o}),null,2),screenshotView:async o=>(await n.request({op:"present",capture:{size:o}}),JSON.stringify({view:{size:o}}))},{...a,engine:"blender-wasm",skew:n.skew,bootMs:Math.round(n.bootMs),releasedPayloadMB:n.releasedPayloadBytes===null?null:Math.round(n.releasedPayloadBytes/1048576)}}async function Y(){try{const e=await fetch("/__editor/blender-wasm/status");return e.ok?await e.json():{available:!1,missing:[`status answered ${e.status}`]}}catch(e){return{available:!1,missing:[String(e)]}}}async function Z(e,t){if(b)throw new Error("The Blender session is already started");if(!e.startsWith("/"))throw new Error("The Blender session needs the project's absolute path");if(t!==void 0&&!q(t))throw new Error(`The Blender document must be a project-relative .blend path with no traversal (models/model.blend); got ${JSON.stringify(t)}`);const r=await Y();if(!r.available)throw new Error(`Headless Blender is not served by this editor, so there is no modeling engine: ${r.missing.join("; ")}. The engine is Blender compiled to WebAssembly (packages/blender-engine/wasm, or the directory VOLTER_BLENDER_WASM_DIR names); nothing stands in for it.`);return v=e,X(e,t)}function q(e){return!e.endsWith(".blend")||e.startsWith("/")||e.includes("\\")?!1:e.split("/").every(r=>r!==""&&r!=="."&&r!=="..")}const x=new Set;function O(e){x.has(e)||(x.add(e),k("error",e))}async function ee(e){const t=s=>(O(`The project's files are not readable from Python: ${s}`),null);let r;try{r=await fetch("/__editor/blender-project-index")}catch(s){return t(String(s))}if(!r.ok)return t(`/__editor/blender-project-index answered ${r.status}`);let n;try{if(n=await r.json(),typeof n?.root!="string"||!Array.isArray(n.files))return t("invalid project index")}catch(s){return t(String(s))}const{root:a,files:o}=n;return a!==e&&O(`The editor serving this tab has ${a} open, not ${e}; its files are mounted at ${e}, which is where Python is looking.`),o}const y=new Map;async function te(e,t){const r=await e.stat(t);return r?`${r.size}:${r.mtimeMs}`:""}async function _(e,t){const r=await ee(t);if(!r)return;const n=new Set(r.map(a=>`${t}/${a.path}`));for(const a of[...y.keys()])if(!n.has(a)){try{await e.unlink(a)}catch{}y.delete(a)}for(const a of r){const o=`${t}/${a.path}`,s=`${a.size}:${a.mtime}`;if(y.get(o)?.host===s||!y.has(o)&&await e.stat(o)!==null)continue;const i=await fetch(`/__editor/blender-project-file?path=${encodeURIComponent(a.path)}`);if(!i.ok){O(`${a.path}: HTTP ${i.status}`);continue}const c=o.slice(0,o.lastIndexOf("/"));c&&await e.mkdirTree(c),await e.writeFile(o,new Uint8Array(await i.arrayBuffer())),y.set(o,{host:s,engine:await te(e,o)})}}async function ne(e,t){const r=[],n=async a=>{let o;try{o=await e.readdir(a)}catch{return}for(const s of o){if(s==="."||s==="..")continue;const i=`${a.replace(/\/$/,"")}/${s}`,c=await e.stat(i);if(c){if((c.mode&61440)===16384){await n(i);continue}y.get(i)?.engine!==`${c.size}:${c.mtimeMs}`&&r.push({path:i,size:c.size,mtime:c.mtimeMs})}}};return await n(t),r}async function F(e){switch(e.op){case"start":return Z(e.project,e.document);case"present-result":{const n=j.get(e.id);j.delete(e.id),n&&(e.error?n.reject(new Error(e.error)):n.resolve({...e.capture===void 0?{}:{capture:e.capture},..."held"in e?{held:e.held}:{}}));return}}if(!b||!v||!f)throw new Error("The Blender session has not started");const t=f.files,r=f.request.bind(f);switch(e.op){case"flush-document":return T?(await R(),{saved:!0}):{saved:!1};case"history-begin":case"history-end":return r({op:e.op});case"history-step":return r({op:"history-step",token:e.token,direction:e.direction});case"execute":await _(t,v);{const n=await r({op:"execute",code:e.code,history:e.history??!0,label:e.label??"Blender Python"});return n.error?`Error executing code: ${n.error}`:`Code executed successfully: ${n.result}`}case"present":return r({op:"present"});case"scene-info":return b.sceneInfo();case"object-info":return b.objectInfo(e.name);case"rna":return r({op:"rna",path:e.path,...e.names===void 0?{}:{names:e.names}});case"rna-context":return r({op:"rna-context",...e.object===void 0?{}:{object:e.object},...e.collection===void 0?{}:{collection:e.collection}});case"rna-set":return r({op:"rna-set",history:e.history!==!1,path:e.path,property:e.property,value:e.value,...e.index===void 0?{}:{index:e.index}});case"outliner":return r({op:"outliner",...e.selected===void 0?{}:{selected:[...e.selected]}});case"node-tree":return r({op:"node-tree",...e.path===void 0?{}:{path:e.path},...e.material===void 0?{}:{material:e.material}});case"uv-layout":return r({op:"uv-layout",...e.object===void 0?{}:{object:e.object},...e.uvLayer===void 0?{}:{uvLayer:e.uvLayer}});case"rig":return r({op:"rig",...e.object===void 0?{}:{object:e.object}});case"action-clip":return r({op:"action-clip",...e.object===void 0?{}:{object:e.object},...e.bake===void 0?{}:{bake:e.bake}});case"outliner-set":return r({op:"outliner-set",path:e.path,column:e.column,value:e.value});case"screenshot-view":return JSON.parse(await b.screenshotView(e.maxSize));case"read-file":return t.readFile(e.path);case"write-file":{const n=e.path.slice(0,e.path.lastIndexOf("/"));n&&await t.mkdirTree(n),await t.writeFile(e.path,e.bytes),y.delete(e.path);return}case"list-files":return ne(t,e.path)}throw new Error(`Unknown Blender worker request ${e.op}`)}function g(e){if(e instanceof Error)return e.stack??`${e.name}: ${e.message}`;if(typeof e=="object"&&e!==null){const t=e;if(typeof t.message=="string")return typeof t.name=="string"?`${t.name}: ${t.message}`:t.message;try{return JSON.stringify(e)??Object.prototype.toString.call(e)}catch{return Object.prototype.toString.call(e)}}return String(e)}function re(){if(!f)return;const e=f.memoryBytes();e!==null&&m({op:"memory",bytes:e})}self.onmessage=e=>{const t=e.data;if(t.op==="present-result"){F(t);return}Q(()=>oe(t))};async function oe(e){try{const t=await F(e);T&&await R(),await I(),m({id:e.id,result:t})}catch(t){let r=g(t);try{await I()}catch(n){r+=`
2
2
  Unable to deliver Blender history: ${g(n)}`}m({id:e.id,error:r})}re()}async function I(){if(!f||!b)return;const e=await f.request({op:"history-events"});e.length&&m({op:"history",entries:e})}export{P as A,se as P,d as S,D as a,ae as b,ie as o,C as s};
@@ -1 +1 @@
1
- import{tr as n,ts as l,tt as a,tu as _,tv as i,tw as s,tx as d,ty as u,tz as c,tA as b,tB as p}from"./index-flxMlfV4.js";const f=Object.freeze(Object.defineProperty({__proto__:null,EDITOR_VIEW_BUILT_IN_UTILITY_IDS:n,EDITOR_VIEW_DOCUMENT_KINDS:l,EDITOR_VIEW_KEYS:a,EDITOR_VIEW_TOOL_UTILITY_PREFIX:_,EDITOR_VIEW_WORKSPACE_DOCUMENT_IDS:i,EditorClient:s,EditorCommandError:d,editorViewFromUrl:u,editorViewUrl:c,isEditorViewDocumentKind:b,isEditorViewUtility:p},Symbol.toStringTag,{value:"Module"})),o={editorHelperType:"editorHelperType",skeletonVisible:"skeletonVisible",skeletonEnabled:"skeletonEnabled",engineInternal:"engineInternal",editorHelper:"editorHelper",volterComponentRoot:"volterComponentRoot",volterBuiltInternal:"volterBuiltInternal"};function y(e,t){return e?e.userData[o[t]]:void 0}function g(e,t,r){e.userData[o[t]]=r}const S=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),j=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),T=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),m=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),I=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),E=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),v=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),M=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),P=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),z=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),D=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),R=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),V=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));export{o as O,m as a,P as b,E as c,S as d,j as e,T as f,y as g,I as h,f as i,z as j,D as k,v as p,M as r,g as s,R as t,V as w};
1
+ import{tu as n,tv as l,tw as a,tx as _,ty as i,tz as s,tA as d,tB as u,tC as c,tD as b,tE as p}from"./index-V4J7xfRg.js";const f=Object.freeze(Object.defineProperty({__proto__:null,EDITOR_VIEW_BUILT_IN_UTILITY_IDS:n,EDITOR_VIEW_DOCUMENT_KINDS:l,EDITOR_VIEW_KEYS:a,EDITOR_VIEW_TOOL_UTILITY_PREFIX:_,EDITOR_VIEW_WORKSPACE_DOCUMENT_IDS:i,EditorClient:s,EditorCommandError:d,editorViewFromUrl:u,editorViewUrl:c,isEditorViewDocumentKind:b,isEditorViewUtility:p},Symbol.toStringTag,{value:"Module"})),o={editorHelperType:"editorHelperType",skeletonVisible:"skeletonVisible",skeletonEnabled:"skeletonEnabled",engineInternal:"engineInternal",editorHelper:"editorHelper",volterComponentRoot:"volterComponentRoot",volterBuiltInternal:"volterBuiltInternal"};function y(e,t){return e?e.userData[o[t]]:void 0}function g(e,t,r){e.userData[o[t]]=r}const S=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),j=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),T=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),m=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),I=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),E=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),v=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),M=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),P=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),z=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),D=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),R=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),C=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));export{o as O,m as a,P as b,E as c,S as d,j as e,T as f,y as g,I as h,f as i,z as j,D as k,v as p,M as r,g as s,R as t,C as w};
@@ -1 +1 @@
1
- import{a as c}from"./jsx-runtime-DPjLkJKQ.js";import{da as L,db as X,eS as j,fl as H,aE as C,fU as $,fV as K,cx as A,fW as q,cy as M,eB as P,dm as Z,x as J,fX as Q,aP as ee,fY as te,fZ as oe,f_ as ne,f$ as re,g0 as se,g1 as ae,fR as ie,cA as ce,g2 as le,ax as de,g3 as N,g4 as ue,dk as pe}from"./index-flxMlfV4.js";import{r as p}from"./index-nmcBqr7Y.js";import{d as fe,m as me}from"./design-time-layers-CCEX-9ul.js";import{I as xe,B as be}from"./edit-mode-authoring-CVKwIPOy.js";import{b as he,i as ve}from"./react-canvas-navigation-WxI8Mxyc.js";import{R as z,i as ge}from"./react-story-board-BRUE9hN1.js";import{s as ye,c as we,a as Se,b as ke}from"./component-board-registry-DrIa2csL.js";import{e as Re,S as Ee}from"./surface-state-NwiDDkWI.js";import"./index-CtzuWnCS.js";import{c as Ie,d as Ce,r as F,e as G,f as Ae,m as O,b as De,a as je,s as Be}from"./board-guides-ClHJXXuu.js";import{C as V,a as $e,b as Me}from"./CanvasSceneViewport-BdHcsAyR.js";import{R as _e}from"./ReactCanvasControls-DplBODky.js";import{R as ze}from"./RootSelectionOverlay-BzEZwAaO.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./root-stacking-BEd9ZvxC.js";import"./design-time-mount-registry-DUpXCg1U.js";import"./game-surface-defaults-D8S4cRxi.js";import"./Toolbar-Bo-l61Lo.js";import"./transform-mode-request-COfeHSRX.js";import"./TransientHint-DFAcEEFI.js";import"./layered-pick-DKNj5L29.js";import"./eyedropper-session-bjPXnfeX.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./inspect-Dl5bH02T.js";import"./inference-diagnostics-MWqnRUsN.js";const y=16,_="rgba(255, 82, 82, 0.9)",U="rgba(18, 22, 26, 0.92)",D="rgba(255, 255, 255, 0.28)";function Te(s){return[10,25,50,100,250,500,1e3,2500,5e3].find(n=>n*s>=60)??1e4}function W(s){return Math.abs(s)>=1e3?`${s/1e3}k`:String(s)}function Pe({docId:s,containerRef:l}){const n=p.useSyncExternalStore(L,X),b=p.useSyncExternalStore(Ie,()=>Ce(s)),[r,d]=p.useState(null),g=p.useRef(null);p.useEffect(()=>{const t=l.current;if(!t)return;const o=t.getBoundingClientRect();return F(s,{originX:o.left,originY:o.top,panX:n.x,panY:n.y,zoom:n.zoom}),()=>F(s,null)},[s,l,n.x,n.y,n.zoom]);const f=(t,o)=>Math.round((t-(o==="x"?n.x:n.y))/n.zoom),u=(t,o)=>(o==="x"?n.x:n.y)+t*n.zoom,m=t=>{const o=l.current?.getBoundingClientRect();return o?{x:t.clientX-o.left,y:t.clientY-o.top}:{x:0,y:0}},k=t=>o=>{o.preventDefault(),o.currentTarget.setPointerCapture(o.pointerId);const e=m(o);d({kind:"place",axis:t,id:null,at:t==="x"?e.x:e.y})},S=t=>o=>{o.preventDefault(),o.stopPropagation(),o.currentTarget.setPointerCapture(o.pointerId);const e=m(o);d({kind:"move",axis:t.axis,id:t.id,at:t.axis==="x"?e.x:e.y})},R=t=>{if(!r)return;const o=m(t),e=r.axis==="x"?o.x:o.y;d({...r,at:e}),r.kind==="move"&&r.id&&O(s,r.id,f(e,r.axis))},E=t=>{if(!r)return;const o=m(t),e=r.axis==="x"?o.x:o.y,i=e<=y;r.kind==="place"?i||Ae(s,r.axis,f(e,r.axis)):r.id&&(i?G(s,r.id):O(s,r.id,f(e,r.axis))),d(null)},a=t=>{const o=l.current,e=o?t==="x"?o.clientWidth:o.clientHeight:0,i=Te(n.zoom),v=Math.ceil(f(y,t)/i)*i,w=f(e,t),x=[];for(let I=v;I<=w&&x.length<200;I+=i)x.push(I);return x},h={position:"absolute",background:U,zIndex:61,userSelect:"none",touchAction:"none",overflow:"hidden"};return c.jsxs("div",{ref:g,"data-testid":"board-rulers",style:{position:"absolute",inset:0,pointerEvents:"none",zIndex:60},onPointerMove:R,onPointerUp:E,children:[b.map(t=>{const o=u(t.value,t.axis),e=t.axis==="x";return c.jsx("div",{"data-testid":`board-guide-${t.axis}-${t.value}`,title:`${t.axis} = ${t.value} — drag to move, drop on the ruler or double-click to remove`,onPointerDown:S(t),onPointerMove:R,onPointerUp:E,onDoubleClick:()=>G(s,t.id),style:{position:"absolute",pointerEvents:"auto",cursor:e?"col-resize":"row-resize",zIndex:60,...e?{left:o-2,top:0,bottom:0,width:5}:{top:o-2,left:0,right:0,height:5}},children:c.jsx("div",{style:{position:"absolute",background:_,...e?{left:2,top:0,bottom:0,width:1}:{top:2,left:0,right:0,height:1}}})},t.id)}),r&&c.jsx("div",{style:{position:"absolute",background:_,zIndex:62,...r.axis==="x"?{left:r.at,top:0,bottom:0,width:1}:{top:r.at,left:0,right:0,height:1}},children:c.jsx("span",{style:{position:"absolute",...r.axis==="x"?{top:y+4,left:4}:{left:y+4,top:4},fontSize:9,fontFamily:"ui-monospace, monospace",color:_,background:U,padding:"1px 3px",borderRadius:3,whiteSpace:"nowrap"},children:f(r.at,r.axis)})}),c.jsx("div",{"data-testid":"board-ruler-top",onPointerDown:k("y"),style:{...h,top:0,left:y,right:0,height:y,cursor:"row-resize",pointerEvents:"auto"},children:a("x").map(t=>c.jsx("span",{style:{position:"absolute",left:u(t,"x"),bottom:0,borderLeft:`1px solid ${D}`,height:5},children:c.jsx("span",{style:{position:"absolute",left:2,bottom:3,fontSize:8,color:D,fontFamily:"ui-monospace, monospace"},children:W(t)})},t))}),c.jsx("div",{"data-testid":"board-ruler-left",onPointerDown:k("x"),style:{...h,top:y,left:0,bottom:0,width:y,cursor:"col-resize",pointerEvents:"auto"},children:a("y").map(t=>c.jsx("span",{style:{position:"absolute",top:u(t,"y"),right:0,borderTop:`1px solid ${D}`,width:5},children:c.jsx("span",{style:{position:"absolute",top:1,right:3,fontSize:8,color:D,fontFamily:"ui-monospace, monospace",writingMode:"vertical-rl"},children:W(t)})},t))}),c.jsx(Ne,{}),c.jsx("div",{style:{...h,top:0,left:0,width:y,height:y,borderRight:`1px solid ${j.border}`,borderBottom:`1px solid ${j.border}`}})]})}function Ne(){const s=p.useSyncExternalStore(De,je);return s?c.jsxs("button",{type:"button","data-testid":"board-breakpoint-pill",title:"Style edits are scoped to this breakpoint — click to return to Base",onClick:()=>Be(null),style:{position:"absolute",top:y+8,right:12,zIndex:62,pointerEvents:"auto",background:"rgba(18, 22, 26, 0.92)",color:j.accent,border:`1px solid ${j.accent}`,borderRadius:999,fontSize:10,padding:"3px 10px",cursor:"pointer"},children:["@ ",s," · editing this breakpoint — click to clear"]}):null}const Fe="Scene";function Ge({active:s,composite:l,descriptor:n,documentId:b,store:r}){const d=p.useRef(null),g=p.useRef(null),[f]=p.useState(oe),u=n.kind==="canvas",m=u?f:ce;p.useSyncExternalStore(r.subscribe,r.getSnapshot);const k=p.useSyncExternalStore(ne,re),S=p.useSyncExternalStore(se,ae),[R,E]=p.useState(null),a=l.childAdapters().find(x=>x.worldId===n.worldId)?.adapter??R??void 0,h=u&&a?.provenance?.label==="babylon",t=a?.hierarchy.roots()??[],o=new Set(a?.rects?.emptyContainers?.().map(x=>x.id)??[]),e=t.some(x=>!o.has(x.id)),i=Re({surface:u?"Scene":n.kind==="dom"?"UI":"World",rootIds:[n.worldId],playSuspended:r.playState!=="stopped"&&(!a||a.provenance?.source==="boundary"),phase:!a||a.provenance?.source==="boundary"?"loading":"ready",content:!a||a.provenance?.source==="boundary"?"unknown":e?"present":"empty",readiness:k,failures:S,disclosure:a instanceof be?a.disclosure:null});p.useEffect(()=>{if(a)return ie(b,()=>({adapter:a,nodeId:[...r.selectedEntityIds].find(x=>a.hierarchy.node(x))??null}))},[l,a,b,r]),p.useEffect(()=>{const x=d.current;if(x&&!h)return u?he(x,m):ve(x,m)},[m,h,u]),p.useEffect(()=>{if(!s)return;if(!!!g.current&&d.current){g.current=me(d.current,l,r,[n],(Ve,Y)=>E(Y),u?{canvasSceneView:f}:void 0,b);return}let I=0,B=0;const T=()=>{if(I+=1,I<2){B=requestAnimationFrame(T);return}pe(b)};return B=requestAnimationFrame(T),()=>cancelAnimationFrame(B)},[s,f,l,n,b,u,r]),p.useEffect(()=>()=>{g.current?.(),g.current=null},[]);const v=le(de(r),r.selectedEntityIds),w=v?.worldId===n.worldId?v:a?.rects?{worldId:n.worldId,kind:"dom",adapter:a}:null;return c.jsxs("div",{ref:d,"data-testid":`world-document:${n.worldId}`,"data-volter-backdrop-color":s?h?"#111827":u?V:z:void 0,"data-volter-backdrop-policy":s?"dark-frost":void 0,onPointerDown:()=>ue("viewport"),style:{position:"absolute",inset:0,overflow:"hidden",pointerEvents:"auto",backgroundColor:h?"#111827":u?V:z,touchAction:"none"},children:[h?null:u?c.jsx($e,{view:f,documentId:b}):c.jsx(Oe,{}),c.jsx(ze,{...a?{adapter:a}:{},...u&&!h?{view:f,transformModeAware:!0,presentationId:b}:{}},`selection:${N(a)}`),c.jsx(Ee,{explanation:i,testId:`world-surface-status:${n.worldId}`,style:{zIndex:20}}),h?null:u?c.jsx(Me,{active:s,...a?{adapter:a}:{},containerRef:d,view:f,documentId:b},`controls:${N(a)}`):c.jsxs(c.Fragment,{children:[c.jsx(Pe,{docId:n.worldId,containerRef:d}),c.jsx(_e,{containerRef:d,context:w})]})]})}function Oe(){const s=p.useSyncExternalStore(L,X),l=Math.max(8,24*s.zoom),n=Math.max(.7,Math.min(1.4,s.zoom));return c.jsx("div",{"data-testid":"react-design-canvas-backdrop","aria-hidden":"true",style:{position:"absolute",inset:0,pointerEvents:"none",backgroundColor:z,backgroundImage:`radial-gradient(circle, ${ge} ${n}px, transparent ${n}px)`,backgroundPosition:`${s.x}px ${s.y}px`,backgroundSize:`${l}px ${l}px`}})}function gt(s,l){const n=J(),b=l.childAdapters().some(e=>e.role==="world"&&e.kind==="three"),r=l.childAdapters().some(e=>e.kind===xe);!b&&!r&&H(C,{discardDirty:!0});const d=new Set,g=[];let f=!1;for(const e of l.childAdapters())e.role==="world"&&e.kind==="three"&&g.push($(e.worldId,C));const u=fe(l),m=u.find(e=>e.kind==="canvas");m&&g.push($(m.worldId,A));const k=new Set([...l.childAdapters().filter(e=>e.role==="world"&&e.kind==="three"),...m?[m]:[]].map(e=>e.worldId)),S=new Map;function R(){for(const e of u){if(k.has(e.worldId)||S.has(e.worldId))continue;const i=Se(e.kind);if(!i)continue;const v=$(e.worldId,i.documentId),w=Q(e.worldId,()=>i.presence()==="absent"?`Root "${e.worldId}" has no document of its own: its design surface is the project's ${i.title} board (${i.documentId}). ${i.absentReason()}`:null);S.set(e.worldId,()=>{w(),v()})}}g.push(K(e=>{const i=ee();if(i.some(w=>w.descriptor.id===e))return null;const v=ke(e);return v?v.presence()==="absent"?v.absentReason():null:`No workspace document is named "${e}". Open in this session: ${i.map(w=>w.descriptor.id).join(", ")||"(none)"}. A component board is present only when the package that owns its medium says this project has one, so a board id can be absent for this project and present for another.`}));function E(e){const i=v=>c.jsx(Ge,{...v,composite:l,descriptor:e,store:s});Z({id:A,title:Fe,kind:"world",workspaceRole:"authored-subject",provenance:{rootId:e.worldId,...e.path?{sourcePath:e.path}:{}},Content:i,presentation:()=>({kind:"world",id:e.worldId})},{category:"scene",default:!b,rootId:e.worldId})}function a(e){d.add(e.documentId);const i=()=>{d.delete(e.documentId)};try{Promise.resolve(e.install({store:s,composite:l})).catch(i)}catch{i()}}function h(){if(!f){R();for(const e of we()){const i=e.presence();if(i===null)continue;const v=d.has(e.documentId);i==="present"!==v&&(i==="present"?a(e):(P(e.documentId),d.delete(e.documentId)))}}}m&&(E(m),d.add(A)),h();const t=ye(h),o=m?A:[...d][0];return te()||(!b&&o!==void 0&&(n===null||n===C||n===q)?M(o):n?M(n):b&&M(C)),()=>{f=!0,t();for(const e of g)e();for(const e of S.values())e();S.clear();for(const e of d)P(e)}}export{Ge as RootDocumentContent,gt as installRootDocuments};
1
+ import{a as c}from"./jsx-runtime-DPjLkJKQ.js";import{dA as W,dB as H,eS as B,fl as Y,aJ as I,fX as $,fY as K,d2 as A,fZ as q,d3 as M,eB as P,dJ as J,x as Z,f_ as Q,aP as ee,f$ as te,g0 as oe,g1 as ne,g2 as re,g3 as se,g4 as ae,fU as ie,d5 as ce,g5 as le,aC as de,g6 as N,g7 as ue,dH as pe}from"./index-V4J7xfRg.js";import{r as p}from"./index-nmcBqr7Y.js";import{d as fe,m as me}from"./design-time-layers-hmGqBp06.js";import{I as be,B as xe}from"./edit-mode-authoring-CSt3zzmS.js";import{b as he,i as ge}from"./react-canvas-navigation-L_mOnybL.js";import{R as z,i as ve}from"./react-story-board-CT1_3sk_.js";import{s as ye,c as we,a as Se,b as ke}from"./component-board-registry-DrIa2csL.js";import{e as Re,S as Ce}from"./surface-state-DrM3wsrr.js";import"./index-CtzuWnCS.js";import{c as Ee,d as Ie,r as F,e as G,f as Ae,m as O,b as De,a as Be,s as je}from"./board-guides-B6TEPOPi.js";import{C as U,a as $e,b as Me}from"./CanvasSceneViewport-CfOuQiQ0.js";import{R as _e}from"./ReactCanvasControls-BL2tOUj6.js";import{R as ze}from"./RootSelectionOverlay-C6Wu8nIs.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./root-stacking-BEd9ZvxC.js";import"./design-time-mount-registry-DUpXCg1U.js";import"./game-surface-defaults-D8S4cRxi.js";import"./Toolbar-BEBQdxRz.js";import"./transform-mode-request-DWM6BdRA.js";import"./TransientHint-CzsdY8W6.js";import"./layered-pick-BUr1U8lU.js";import"./eyedropper-session-bjPXnfeX.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./inspect-DiSjB-N1.js";import"./inference-diagnostics-DoZQ1mpg.js";const y=16,_="rgba(255, 82, 82, 0.9)",V="rgba(18, 22, 26, 0.92)",D="rgba(255, 255, 255, 0.28)";function Te(s){return[10,25,50,100,250,500,1e3,2500,5e3].find(n=>n*s>=60)??1e4}function L(s){return Math.abs(s)>=1e3?`${s/1e3}k`:String(s)}function Pe({docId:s,containerRef:l}){const n=p.useSyncExternalStore(W,H),x=p.useSyncExternalStore(Ee,()=>Ie(s)),[r,d]=p.useState(null),v=p.useRef(null);p.useEffect(()=>{const t=l.current;if(!t)return;const o=t.getBoundingClientRect();return F(s,{originX:o.left,originY:o.top,panX:n.x,panY:n.y,zoom:n.zoom}),()=>F(s,null)},[s,l,n.x,n.y,n.zoom]);const f=(t,o)=>Math.round((t-(o==="x"?n.x:n.y))/n.zoom),u=(t,o)=>(o==="x"?n.x:n.y)+t*n.zoom,m=t=>{const o=l.current?.getBoundingClientRect();return o?{x:t.clientX-o.left,y:t.clientY-o.top}:{x:0,y:0}},k=t=>o=>{o.preventDefault(),o.currentTarget.setPointerCapture(o.pointerId);const e=m(o);d({kind:"place",axis:t,id:null,at:t==="x"?e.x:e.y})},S=t=>o=>{o.preventDefault(),o.stopPropagation(),o.currentTarget.setPointerCapture(o.pointerId);const e=m(o);d({kind:"move",axis:t.axis,id:t.id,at:t.axis==="x"?e.x:e.y})},R=t=>{if(!r)return;const o=m(t),e=r.axis==="x"?o.x:o.y;d({...r,at:e}),r.kind==="move"&&r.id&&O(s,r.id,f(e,r.axis))},C=t=>{if(!r)return;const o=m(t),e=r.axis==="x"?o.x:o.y,i=e<=y;r.kind==="place"?i||Ae(s,r.axis,f(e,r.axis)):r.id&&(i?G(s,r.id):O(s,r.id,f(e,r.axis))),d(null)},a=t=>{const o=l.current,e=o?t==="x"?o.clientWidth:o.clientHeight:0,i=Te(n.zoom),g=Math.ceil(f(y,t)/i)*i,w=f(e,t),b=[];for(let E=g;E<=w&&b.length<200;E+=i)b.push(E);return b},h={position:"absolute",background:V,zIndex:61,userSelect:"none",touchAction:"none",overflow:"hidden"};return c.jsxs("div",{ref:v,"data-testid":"board-rulers",style:{position:"absolute",inset:0,pointerEvents:"none",zIndex:60},onPointerMove:R,onPointerUp:C,children:[x.map(t=>{const o=u(t.value,t.axis),e=t.axis==="x";return c.jsx("div",{"data-testid":`board-guide-${t.axis}-${t.value}`,title:`${t.axis} = ${t.value} — drag to move, drop on the ruler or double-click to remove`,onPointerDown:S(t),onPointerMove:R,onPointerUp:C,onDoubleClick:()=>G(s,t.id),style:{position:"absolute",pointerEvents:"auto",cursor:e?"col-resize":"row-resize",zIndex:60,...e?{left:o-2,top:0,bottom:0,width:5}:{top:o-2,left:0,right:0,height:5}},children:c.jsx("div",{style:{position:"absolute",background:_,...e?{left:2,top:0,bottom:0,width:1}:{top:2,left:0,right:0,height:1}}})},t.id)}),r&&c.jsx("div",{style:{position:"absolute",background:_,zIndex:62,...r.axis==="x"?{left:r.at,top:0,bottom:0,width:1}:{top:r.at,left:0,right:0,height:1}},children:c.jsx("span",{style:{position:"absolute",...r.axis==="x"?{top:y+4,left:4}:{left:y+4,top:4},fontSize:9,fontFamily:"ui-monospace, monospace",color:_,background:V,padding:"1px 3px",borderRadius:3,whiteSpace:"nowrap"},children:f(r.at,r.axis)})}),c.jsx("div",{"data-testid":"board-ruler-top",onPointerDown:k("y"),style:{...h,top:0,left:y,right:0,height:y,cursor:"row-resize",pointerEvents:"auto"},children:a("x").map(t=>c.jsx("span",{style:{position:"absolute",left:u(t,"x"),bottom:0,borderLeft:`1px solid ${D}`,height:5},children:c.jsx("span",{style:{position:"absolute",left:2,bottom:3,fontSize:8,color:D,fontFamily:"ui-monospace, monospace"},children:L(t)})},t))}),c.jsx("div",{"data-testid":"board-ruler-left",onPointerDown:k("x"),style:{...h,top:y,left:0,bottom:0,width:y,cursor:"col-resize",pointerEvents:"auto"},children:a("y").map(t=>c.jsx("span",{style:{position:"absolute",top:u(t,"y"),right:0,borderTop:`1px solid ${D}`,width:5},children:c.jsx("span",{style:{position:"absolute",top:1,right:3,fontSize:8,color:D,fontFamily:"ui-monospace, monospace",writingMode:"vertical-rl"},children:L(t)})},t))}),c.jsx(Ne,{}),c.jsx("div",{style:{...h,top:0,left:0,width:y,height:y,borderRight:`1px solid ${B.border}`,borderBottom:`1px solid ${B.border}`}})]})}function Ne(){const s=p.useSyncExternalStore(De,Be);return s?c.jsxs("button",{type:"button","data-testid":"board-breakpoint-pill",title:"Style edits are scoped to this breakpoint — click to return to Base",onClick:()=>je(null),style:{position:"absolute",top:y+8,right:12,zIndex:62,pointerEvents:"auto",background:"rgba(18, 22, 26, 0.92)",color:B.accent,border:`1px solid ${B.accent}`,borderRadius:999,fontSize:10,padding:"3px 10px",cursor:"pointer"},children:["@ ",s," · editing this breakpoint — click to clear"]}):null}const Fe="Scene";function Ge({active:s,composite:l,descriptor:n,documentId:x,store:r}){const d=p.useRef(null),v=p.useRef(null),[f]=p.useState(oe),u=n.kind==="canvas",m=u?f:ce;p.useSyncExternalStore(r.subscribe,r.getSnapshot);const k=p.useSyncExternalStore(ne,re),S=p.useSyncExternalStore(se,ae),[R,C]=p.useState(null),a=l.childAdapters().find(b=>b.worldId===n.worldId)?.adapter??R??void 0,h=u&&a?.provenance?.label==="babylon",t=a?.hierarchy.roots()??[],o=new Set(a?.rects?.emptyContainers?.().map(b=>b.id)??[]),e=t.some(b=>!o.has(b.id)),i=Re({surface:u?"Scene":n.kind==="dom"?"UI":"World",rootIds:[n.worldId],playSuspended:r.playState!=="stopped"&&(!a||a.provenance?.source==="boundary"),phase:!a||a.provenance?.source==="boundary"?"loading":"ready",content:!a||a.provenance?.source==="boundary"?"unknown":e?"present":"empty",readiness:k,failures:S,disclosure:a instanceof xe?a.disclosure:null});p.useEffect(()=>{if(a)return ie(x,()=>({adapter:a,nodeId:[...r.selectedEntityIds].find(b=>a.hierarchy.node(b))??null}))},[l,a,x,r]),p.useEffect(()=>{const b=d.current;if(b&&!h)return u?he(b,m):ge(b,m)},[m,h,u]),p.useEffect(()=>{if(!s)return;if(!!!v.current&&d.current){v.current=me(d.current,l,r,[n],(Ue,X)=>C(X),u?{canvasSceneView:f}:void 0,x);return}let E=0,j=0;const T=()=>{if(E+=1,E<2){j=requestAnimationFrame(T);return}pe(x)};return j=requestAnimationFrame(T),()=>cancelAnimationFrame(j)},[s,f,l,n,x,u,r]),p.useEffect(()=>()=>{v.current?.(),v.current=null},[]);const g=le(de(r),r.selectedEntityIds),w=g?.worldId===n.worldId?g:a?.rects?{worldId:n.worldId,kind:"dom",adapter:a}:null;return c.jsxs("div",{ref:d,"data-testid":`world-document:${n.worldId}`,"data-volter-backdrop-color":s?h?"#111827":u?U:z:void 0,"data-volter-backdrop-policy":s?"dark-frost":void 0,onPointerDown:()=>ue("viewport"),style:{position:"absolute",inset:0,overflow:"hidden",pointerEvents:"auto",backgroundColor:h?"#111827":u?U:z,touchAction:"none"},children:[h?null:u?c.jsx($e,{view:f,documentId:x}):c.jsx(Oe,{}),c.jsx(ze,{...a?{adapter:a}:{},...u&&!h?{view:f,transformModeAware:!0,presentationId:x}:{}},`selection:${N(a)}`),c.jsx(Ce,{explanation:i,testId:`world-surface-status:${n.worldId}`,style:{zIndex:20}}),h?null:u?c.jsx(Me,{active:s,...a?{adapter:a}:{},containerRef:d,view:f,documentId:x},`controls:${N(a)}`):c.jsxs(c.Fragment,{children:[c.jsx(Pe,{docId:n.worldId,containerRef:d}),c.jsx(_e,{containerRef:d,context:w})]})]})}function Oe(){const s=p.useSyncExternalStore(W,H),l=Math.max(8,24*s.zoom),n=Math.max(.7,Math.min(1.4,s.zoom));return c.jsx("div",{"data-testid":"react-design-canvas-backdrop","aria-hidden":"true",style:{position:"absolute",inset:0,pointerEvents:"none",backgroundColor:z,backgroundImage:`radial-gradient(circle, ${ve} ${n}px, transparent ${n}px)`,backgroundPosition:`${s.x}px ${s.y}px`,backgroundSize:`${l}px ${l}px`}})}function vt(s,l){const n=Z(),x=l.childAdapters().some(e=>e.role==="world"&&e.kind==="three"),r=l.childAdapters().some(e=>e.kind===be);!x&&!r&&Y(I,{discardDirty:!0});const d=new Set,v=[];let f=!1;for(const e of l.childAdapters())e.role==="world"&&e.kind==="three"&&v.push($(e.worldId,I));const u=fe(l),m=u.find(e=>e.kind==="canvas");m&&v.push($(m.worldId,A));const k=new Set([...l.childAdapters().filter(e=>e.role==="world"&&e.kind==="three"),...m?[m]:[]].map(e=>e.worldId)),S=new Map;function R(){for(const e of u){if(k.has(e.worldId)||S.has(e.worldId))continue;const i=Se(e.kind);if(!i)continue;const g=$(e.worldId,i.documentId),w=Q(e.worldId,()=>i.presence()==="absent"?`Root "${e.worldId}" has no document of its own: its design surface is the project's ${i.title} board (${i.documentId}). ${i.absentReason()}`:null);S.set(e.worldId,()=>{w(),g()})}}v.push(K(e=>{const i=ee();if(i.some(w=>w.descriptor.id===e))return null;const g=ke(e);return g?g.presence()==="absent"?g.absentReason():null:`No workspace document is named "${e}". Open in this session: ${i.map(w=>w.descriptor.id).join(", ")||"(none)"}. A component board is present only when the package that owns its medium says this project has one, so a board id can be absent for this project and present for another.`}));function C(e){const i=g=>c.jsx(Ge,{...g,composite:l,descriptor:e,store:s});J({id:A,title:Fe,kind:"world",workspaceRole:"authored-subject",provenance:{rootId:e.worldId,...e.path?{sourcePath:e.path}:{}},Content:i,presentation:()=>({kind:"world",id:e.worldId})},{category:"scene",default:!x,rootId:e.worldId})}function a(e){d.add(e.documentId);const i=()=>{d.delete(e.documentId)};try{Promise.resolve(e.install({store:s,composite:l})).catch(i)}catch{i()}}function h(){if(!f){R();for(const e of we()){const i=e.presence();if(i===null)continue;const g=d.has(e.documentId);i==="present"!==g&&(i==="present"?a(e):(P(e.documentId),d.delete(e.documentId)))}}}m&&(C(m),d.add(A)),h();const t=ye(h),o=m?A:[...d][0];return te()||(!x&&o!==void 0&&(n===null||n===I||n===q)?M(o):n?M(n):x&&M(I)),()=>{f=!0,t();for(const e of v)e();for(const e of S.values())e();S.clear();for(const e of d)P(e)}}export{Ge as RootDocumentContent,vt as installRootDocuments};
@@ -1 +1 @@
1
- import{a as i}from"./jsx-runtime-DPjLkJKQ.js";import{EDITOR_LAYER as Xe}from"./editor-layers-DI1Wkr8F.js";import{cM as Oe,a1 as V,dT as Je,aK as te,cE as Q,aL as G,kA as Ye,dS as Ze,cK as et,a0 as $,g_ as tt,hE as rt,jS as nt,kB as ot,O as j,B as st,bM as at,kC as Se,b$ as it,kD as ct,kE as lt,kF as ut,kG as Ce,kH as xe,ax as x,cm as dt,kI as mt,bU as pt,bZ as ft,kJ as Pe,kK as Ee,kL as je,kM as ht,af as gt,kN as bt,kO as ke,dk as vt,kP as wt,kQ as yt,jC as St,iU as Ct,iV as xt,gJ as Pt,gK as Et,j0 as jt,f_ as kt,f$ as Tt,g0 as At,g1 as Rt}from"./index-flxMlfV4.js";import{s as Mt,o as Vt}from"./object3d-document-session-registry-DI9WfJDy.js";import{R as Ot}from"./RootSelectionOverlay-BzEZwAaO.js";import{e as Lt,S as Ft}from"./surface-state-NwiDDkWI.js";import{r as f}from"./index-nmcBqr7Y.js";import{t as It}from"./surface-content-Dg9Kkazf.js";import"./index-CtzuWnCS.js";import{s as zt,d as Te,c as B,t as Wt,p as Le,v as Ae,b as _t,e as Dt,l as Nt,i as $t}from"./camera-authoring-DYjhU5Zp.js";import{c as Qt}from"./performance-profiler-CMbwGBuk.js";import{m as Gt}from"./renderer-ownership-BovSEcLv.js";import{applyWorldRendererConfig as Bt}from"./renderer-config-CaPR4dB_.js";import{getUserData as Fe}from"./user-data-CODoGZqA.js";import{detectKtx2Support as Ht}from"./loader-BTUKnX5Q.js";import{resolveRenderSettings as Ut}from"./render-settings-Cnd69vhe.js";import{createSoftParticleDepthPass as Kt}from"./soft-particle-depth-DNGwWJ8c.js";import{ViewportShadingRenderer as qt}from"./viewport-shading-D9BMDb1N.js";import{applyRendererSettings as Xt,applySceneRenderPipeline as Jt}from"./setup-renderer-jOQdnmo7.js";import{EffectComposer as Yt,EffectPass as Zt,BlendFunction as er,KernelSize as tr,OutlineEffect as rr}from"./index-DHhMOs_s.js";import{W as nr,T as or}from"./three.module-BLhyNg0e.js";import{d as sr}from"./design-time-mount-registry-DUpXCg1U.js";import{a as ar}from"./project-authoring-session-BqZuntp2.js";import"./three-integration-K2zwKa-Z.js";import{registerPresentedCanvasFrame as ir}from"./canvas-preview-frames-Jsd4Gi5S.js";import{i as cr}from"./editor-presentation-activity-CqJH4G9t.js";import{E as lr,s as ur,a as dr,t as mr,b as pr,c as fr,d as hr,r as gr,i as br}from"./three-viewport-presentation-C5wGhMgD.js";import{a as Z}from"./entity-object-C374JqRs.js";import{w as vr}from"./editor-shell-store-DlGykD-E.js";import{p as wr}from"./viewport-root-presentation-DEm3C1-i.js";import{d as yr}from"./asset-editor-persistence-DttxUta0.js";import{bindStagePresenceMarkers as Sr}from"./stage-presence-markers-Bu9mH0m_.js";import{el as Cr,_ as ee,fo as N,d7 as xr,dp as Re}from"./three.core-3arARmh6.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./workspace-arrangement-BnGzBm57.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./eyedropper-session-bjPXnfeX.js";import"./layered-pick-DKNj5L29.js";import"./root-stacking-BEd9ZvxC.js";import"./react-story-board-BRUE9hN1.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./inspect-Dl5bH02T.js";import"./inference-diagnostics-MWqnRUsN.js";import"./object-marks-BnvSuCTt.js";import"./KTX2Loader-CaqVE6nY.js";import"./GLTFLoader-KeoruJgS.js";import"./BufferGeometryUtils-B22h7jo4.js";import"./render-features-BMOBYkLQ.js";import"./matcap-texture-Dm2c-VQa.js";import"./defaults-DKiBJCPN.js";import"./edit-mode-authoring-CVKwIPOy.js";import"./host-hierarchy-objects-BV3WqU2w.js";import"./preview-renderer-BrYNFV1p.js";import"./environment-Dg-YaLsA.js";import"./RoomEnvironment-BkknvS_I.js";import"./EXRLoader-CITMBvGd.js";import"./HDRLoader-BTGuGhVo.js";import"./user-data-C8dmlLGA.js";import"./model-thumbnail-WJb6B3qQ.js";import"./studio-environment-Dw2FBct5.js";import"./three-state-DVnNjIbQ.js";import"./hierarchy-marks-EEQa08In.js";import"./component-instance-root-pq7uyyej.js";import"./three-contract-Dkt6PmWY.js";import"./viewport-door-Brt6-rPp.js";import"./content-bounds-Ax7CFkXJ.js";import"./asset-preview-C36PaXvM.js";import"./bitmap-label-Ct4k6ehY.js";import"./index-BHccVo52.js";import"./standard-viewport-dressing-B8VpmbHt.js";import"./clip-planes-CnAI6DZn.js";import"./three-2yjp9YMj.js";import"./model-inspection-BS3uYvYU.js";import"./OrbitControls-B13MKuwC.js";import"./LineSegments2-DN9pUfWA.js";import"./three.quarks.esm-C_HmSKXo.js";import"./live-gesture-lock-DJbrjOqf.js";import"./scene-framing-CljHc6tN.js";import"./live-mixers-B-bwLZ7c.js";import"./output-pass-HurwNl0G.js";import"./Pass-D1MRT672.js";import"./mounted-authoring-BHpx-z2Y.js";import"./collaboration-presence-WWC9ZQsq.js";function Pr({previewRef:r}){const{preview:e,previewPinned:s}=B(),[o,c]=f.useState(!1),a=f.useRef(null);if(f.useEffect(()=>{if(!o)return;const u=E=>{a.current?.contains(E.target)||c(!1)};return document.addEventListener("pointerdown",u),()=>document.removeEventListener("pointerdown",u)},[o]),!e)return null;const m=e.camera.isPerspectiveCamera&&Number.isFinite(e.camera.aspect)?e.camera.aspect:16/9;return i.jsxs("div",{className:"volter-camera-preview","data-testid":"camera-preview",children:[i.jsxs(Oe,{className:"volter-camera-preview-header",gap:4,align:"center",children:[i.jsx(V,{icon:Je,size:"sm"}),i.jsx(te,{variant:"label",truncate:!0,className:"volter-camera-preview-title",title:`${e.name} · ${e.lens}`,children:e.name}),i.jsx(Q,{text:s?"Unpin camera preview":"Pin camera preview",children:i.jsx(G,{"aria-label":s?"Unpin camera preview":"Pin camera preview","aria-pressed":s,size:"compact",onClick:Wt,children:i.jsx(V,{icon:Ye,size:"sm"})})}),i.jsxs("div",{ref:a,className:"volter-camera-preview-menu-anchor",children:[i.jsx(Q,{text:"Camera actions",children:i.jsx(G,{"aria-label":"Camera actions","aria-expanded":o,size:"compact",onClick:()=>c(u=>!u),children:i.jsx(V,{icon:Ze,size:"sm"})})}),o?i.jsxs(et,{className:"volter-camera-preview-menu",children:[i.jsx($,{variant:"ghost",size:"compact",disabled:!e.canAuthorPose,title:e.poseRefusal,onClick:()=>{c(!1),Le(e)},children:"Pilot Camera"}),i.jsx($,{variant:"ghost",size:"compact",onClick:()=>{c(!1),Ae(e)},children:"View Through Camera"}),i.jsx($,{variant:"ghost",size:"compact",disabled:!e.canAuthorPose,title:e.poseRefusal,onClick:()=>{c(!1),_t(e)},children:"Align Camera to Current View"})]}):null]})]}),i.jsx("div",{ref:r,className:"volter-camera-preview-image",style:{aspectRatio:String(Math.max(.5,Math.min(3,m)))},role:"img","aria-label":`Live view through ${e.name}`,onDoubleClick:()=>Ae(e)})]})}function Er(){return i.jsxs("div",{className:"volter-camera-guides","aria-hidden":"true",children:[i.jsx("div",{className:"volter-camera-guide volter-camera-guide-v1"}),i.jsx("div",{className:"volter-camera-guide volter-camera-guide-v2"}),i.jsx("div",{className:"volter-camera-guide volter-camera-guide-h1"}),i.jsx("div",{className:"volter-camera-guide volter-camera-guide-h2"}),i.jsx("div",{className:"volter-camera-safe-frame"}),i.jsx("div",{className:"volter-camera-center-mark"})]})}function jr(){const{view:r,guidesVisible:e}=B();if(!r)return null;const s=r.mode==="pilot";return i.jsxs(i.Fragment,{children:[e?i.jsx(Er,{}):null,i.jsx(tt,{variant:"overlay",border:!0,className:"volter-camera-view-banner volter-chrome-island volter-glass-island","data-testid":"camera-view-banner",children:i.jsxs(Oe,{gap:6,align:"center",children:[i.jsx(rt,{children:s?"PILOTING":"CAMERA VIEW"}),i.jsx(te,{variant:"label",children:r.subject.name}),i.jsx(te,{variant:"caption",tone:"muted",children:"Exact camera view"}),i.jsx(Q,{text:e?"Hide composition guides":"Show composition guides",children:i.jsx(G,{"aria-label":e?"Hide composition guides":"Show composition guides","aria-pressed":e,size:"compact",onClick:Dt,children:i.jsx(V,{icon:nt,size:"sm"})})}),s?null:i.jsx($,{size:"compact",variant:"primary",disabled:!r.subject.canAuthorPose,title:r.subject.poseRefusal,onClick:()=>Le(r.subject),children:"Pilot"}),i.jsx(Q,{text:"Exit camera view",children:i.jsx(G,{"aria-label":"Exit camera view",size:"compact",onClick:Nt,children:i.jsx(V,{icon:ot,size:"sm"})})})]})})]})}function kr({previewRef:r}){return f.useSyncExternalStore(zt,Te,Te),i.jsxs(i.Fragment,{children:[i.jsx(Pr,{previewRef:r}),i.jsx(jr,{})]})}function Tr(r){const e=r,s=e.getExtension("EXT_disjoint_timer_query_webgl2"),o=s!==null&&typeof e.createQuery=="function",c=[];let a=null,m=null;return{begin(){!o||a||(a=e.createQuery(),a&&e.beginQuery(s.TIME_ELAPSED_EXT,a))},end(){!o||!a||(e.endQuery(s.TIME_ELAPSED_EXT),c.push(a),a=null)},poll(){if(!o)return null;if(e.getParameter(s.GPU_DISJOINT_EXT)){for(const u of c.splice(0))e.deleteQuery(u);return null}for(;c.length>0;){const u=c[0];if(!e.getQueryParameter(u,e.QUERY_RESULT_AVAILABLE))break;c.shift(),m=e.getQueryParameter(u,e.QUERY_RESULT)/1e6,e.deleteQuery(u)}return m},dispose(){a&&(e.endQuery(s.TIME_ELAPSED_EXT),e.deleteQuery(a),a=null);for(const u of c.splice(0))e.deleteQuery(u)}}}const Ar=2e4,Rr=250,Mr=5e3;class Vr{#e=0;#t=0;#r=0;#n;constructor(e){this.#n=e}get pending(){return this.#e>0||this.#t>0}begin(e,s){this.#e=e+Ar,this.#t=s?e+Mr:0,this.#r=0,this.tick(e)}tick(e){if(!(!this.pending||e<this.#r)){if(this.#r=e+Rr,this.#t>0&&this.#n.seedFromGameCamera()){this.cancel();return}this.#e>0&&this.#n.frameContent()&&(this.#e=0),e>=this.#e&&(this.#e=0),e>=this.#t&&(this.#t=0)}}cancel(){this.#e=0,this.#t=0}}const Me=new WeakMap;function Or(r,e){if(!r)return e(),!0;if(Me.has(r))return!1;try{return e(),!0}catch(s){const o=s instanceof Error?s.message:String(s);return Me.set(r,o),j.warn(`The Scene view cannot draw this world with the editor's own renderer, and has stopped trying: ${o}. This world was built by a copy of three the editor did not make (a vendored bundle pins its own revision), and the editor draws it with ITS three — across a wide enough revision gap the two disagree about the renderer/material contract. The game itself is unaffected and still drawing: its own canvas is what the Game tab and ${st("screenshot")} show, and hierarchy, selection and inspection all still read the live world. It closes when the game resolves \`three\` to the host's instance — a bare, un-rewritten \`import 'three'\` in its own source.`,"ingest"),!1}}function Lr(){const r=at();r.addEventListener("server-log",s=>{try{Se(JSON.parse(s.data))}catch{}});let e=!1;return(async()=>{try{const s=await it();if(e)return;for(const o of s)Se(o)}catch{}})(),()=>{e=!0,r.close()}}const Ie="viewportPose";function Fr(){const r=ct(Ie);return r&&Array.isArray(r.position)&&r.position.length===3&&r.position.every(Number.isFinite)&&Array.isArray(r.target)&&r.target.length===3&&r.target.every(Number.isFinite)?r:null}function Ir(r,e){lt(Ie,{position:[r.position.x,r.position.y,r.position.z],target:[e.x,e.y,e.z]})}const Ve={id:"world",title:"World",lights:[{color:"#ffffff",intensity:1,direction:[-10,-20,-10],space:"world"}],ambient:{color:"#ffffff",intensity:.5},environmentIntensity:0};yt(Ve),St("world",{all:{lighting:{source:"studio",studioPreset:Ve.id,auto:{takeover:["light"],overridable:!0}}}});function zr(r,e,s){const o=document.createElement("canvas");o.setAttribute("aria-label",`${s} authoring viewport`),o.setAttribute("data-testid","editor-canvas"),o.setAttribute("aria-hidden","true"),o.tabIndex=-1,o.style.width="100%",o.style.height="100%",o.style.display="block",o.style.pointerEvents="auto",r.appendChild(o);const c=Math.max(1,e.clientWidth),a=Math.max(1,e.clientHeight),m=Math.min(window.devicePixelRatio||1,2);o.width=Math.ceil(c*m),o.height=Math.ceil(a*m);const u=Gt(new nr({canvas:o,antialias:!!Ut(void 0).antialias,powerPreference:"high-performance"}));return Xt(u,void 0,m),u.setSize(c,a),u.shadowMap.type=xr,u.info.autoReset=!1,Ht(u),{canvas:o,renderer:u,lease:null}}async function Wr(r){const e=pt(r.source,r.id);if(e)return e;let s=r.url,o=r.format??"gltf",c=r.includes;if(!s){const u=(await ft(r.source,r.id))[0];if(!u)return j.error(`No downloadable files for ${r.name}.`,"asset"),null;s=u.url,o=u.format,c=u.includes}const a={source:r.source,id:r.id,name:r.name,url:s,format:o};c&&(a.includes=c);const m=await yr(a);return m.ok&&m.path?`/${m.path}`:(j.error(`Could not download ${r.name}.`,"asset"),null)}function _r(r){if(r.isCamera)return r;const e=Fe(r,"_camera");return e?.isCamera?e:null}function Dr(r){const e=r;if(e.isPerspectiveCamera)return`${e.fov.toFixed(0)}° perspective`;const s=r;return s.isOrthographicCamera?`Orthographic · ${s.zoom.toFixed(2)}×`:r.type}function Nr(r,e){const s=r.transforms;if(!s)return{canAuthorPose:!1,poseRefusal:"This camera has no transform authoring path."};const o=s.editability?.(e,"position")??{writable:!0},c=s.editability?.(e,"rotation")??{writable:!0};return o.writable&&c.writable?{canAuthorPose:!0}:{canAuthorPose:!1,poseRefusal:o.reason??c.reason??"This camera pose is read-only."}}function $r(r,e,s){const o=e.get(s)??null;if(!o)return null;const c=_r(o);return c?{id:s,name:o.name||c.name||"Camera",camera:c,lens:Dr(c),...Nr(r,s)}:null}function Qr(r){const e=new Map;for(const[s,o]of r.objectMap){const c=Fe(o,"tags");Array.isArray(c)&&c.length>0&&e.set(s,c)}return e}function Gr(r){const{store:e,documentId:s,container:o,canvas:c,renderer:a,stats:m}=r,u=new Yt(a),E=Kt(),O=new qt,g=Qt(),L=Tr(a.getContext()),ze=t=>{g.enabled&&L.begin();try{t()}finally{L.end()}},We=()=>g.enabled?L.poll():null,_e=ut({id:s,label:"Scene viewport",kind:"scene",profiler:g}),b=new Cr,re=11184810;let H=Ce(c).background??re;b.background=new ee(H);const De=xe(c,()=>{const t=Ce(c).background??re,l=b.background;l instanceof ee&&l.getHex()===H&&(b.background=new ee(t)),H=t});e.bindScene(b,a);const n=new lr(c,b,e,o,{renderer:a,onlineAssetResolver:Wr,onProjectionChange:ur}),Ne=n.bindPresentation(s,"world");e.bindScene(b,a,n.batchedRenderer,n.camera),e.setOrbitTarget(n.orbitControls.target);const U=new N,F=new N,ne=new N,oe=()=>{const t=n.renderCamera;t.getWorldPosition(U),n.cameraViewMode==="pilot"?F.copy(n.orbitControls.target):n.cameraViewMode?(t.getWorldDirection(ne),F.copy(U).add(ne.multiplyScalar(10))):F.copy(n.orbitControls.target);const l=t.fov;return{position:U,target:F,fov:typeof l=="number"?l:0}},k=Sr({scene:b,store:e,documentId:s,container:o,canvas:c,viewport:n,readVisibleCameraPose:oe});let se="",K=null,h=null,S=null,I=null;const ae=()=>{h&&fr(h,ke(a.domElement))},$e=xe(a.domElement,ae),ie=()=>{if(!h)return;const t=x(e.shell),l=[...e.shell.selectedEntityIds].filter(d=>t.hierarchy.node(d)!==null).map(d=>Z(t,e.objectMap,d)).filter(d=>d!==null);hr(h,l);const p=h.selection.size>0;S&&(S.enabled=p,S.renderToScreen=p),I&&(I.renderToScreen=!p)};function T(){bt(e.shell),K?.(),K=null,h&&gr(a,h,S),h=null,S=null,I=null,Jt(u,a,e.scene??b,n.renderCamera,void 0,{basePixelRatio:Math.min(window.devicePixelRatio||1,2),objectMap:e.objectMap,entityTags:Qr(e)}),h=pr({BlendFunction:er,KernelSize:tr,OutlineEffect:rr},a,e.scene??b,n.renderCamera,ke(a.domElement)),ae(),I=u.passes.at(-1)??null,S=new Zt(n.renderCamera,h),S.enabled=!1,u.addPass(S),ie();const t=e.adoptedImageConfig;t&&(K=Bt(or,a,t))}const ce=()=>{n.setProjection(mr().projection),e.setViewportCamera(n.freeCamera),T()},Qe=dr(ce);ce();const q=t=>$r(x(e.shell),e.objectMap,t);let v=null;const A=()=>{v&&(je(x(e.shell),v),v=null)},le=()=>{const t=B().view;t?.mode!=="pilot"||!t.subject.canAuthorPose||(v=t.subject.id,Pe(x(e.shell),v))},ue=()=>{if(!v||n.cameraViewMode!=="pilot")return;const t=q(v),l=x(e.shell),p=l.transforms;if(!t||!p)return;let d;try{d=p.get(v)}catch(w){j.error(w instanceof Error?w.message:String(w),"camera-authoring"),A();return}Ee(l,v,{position:t.camera.position.toArray(),rotation:t.camera.quaternion.toArray(),scale:d.scale}),e.shell.notifyIngestEdit()};n.orbitControls.addEventListener("start",le),n.orbitControls.addEventListener("change",ue),n.orbitControls.addEventListener("end",A);const Ge=$t({active:()=>e.shell.playState==="stopped"&&e.shell.activeViewportTab==="edit",selected:()=>{const t=e.shell.selectedEntityId;return t?q(t):null},resolve:q,showView:(t,l)=>{A(),n.setCameraView(t.camera,l),T(),k.reportCamera()},leaveView:()=>{A(),n.clearCameraView(),T(),k.reportCamera()},alignToViewport:t=>{const l=x(e.shell),p=l.transforms;if(!p||!t.canAuthorPose)return;const d=e.objectMap.get(t.id)??null;if(!d)return;const w=n.camera.getWorldPosition(new N),C=n.camera.getWorldQuaternion(new Re),y=w.clone(),R=C.clone();if(d.parent){d.parent.updateWorldMatrix(!0,!1),d.parent.worldToLocal(y);const M=d.parent.getWorldQuaternion(new Re);R.premultiply(M.invert())}let ye;try{ye=p.get(t.id)}catch(M){j.error(M instanceof Error?M.message:String(M),"camera-authoring");return}Pe(l,t.id),Ee(l,t.id,{position:y.toArray(),rotation:R.toArray(),scale:ye.scale}),e.shell.notifyIngestEdit(),je(l,t.id)},subscribe:e.shell.subscribe});let de=null;const me=()=>{const t=ht(e.shell);t!==de&&(de=t,c.style.opacity=t?"1":"0",o.style.backgroundColor=t?"":gt.surface.raised,o.style.backgroundImage=t?"":"linear-gradient(45deg, #444649 25%, transparent 25%, transparent 75%, #444649 75%), linear-gradient(45deg, #444649 25%, transparent 25%, transparent 75%, #444649 75%)",o.style.backgroundPosition=t?"":"0 0, 8px 8px",o.style.backgroundSize=t?"":"16px 16px")};me();let pe=e.composerVersion;const Be=e.shell.subscribe(()=>{me();const t=e.scene;t&&t!==n.currentScene&&n.setScene(t),n.objectMap=e.objectMap,n.syncFromStore(),e.composerVersion!==pe?(pe=e.composerVersion,T()):ie()});let z=null;const X=new Vr({seedFromGameCamera:()=>{const t=z?.()??null;return!!t&&n.seedFromGameCamera(t)},frameContent:()=>n.focusOnScene()}),fe=()=>{X.cancel(),z=null};n.orbitControls.addEventListener("start",fe);const he=()=>Ir(n.camera,n.orbitControls.target);n.orbitControls.addEventListener("end",he);const He=e.shell.onViewportAction(t=>{switch(t.type){case"focus-entity":{const l=Z(x(e.shell),e.objectMap,t.id);l&&n.focusOn(l);break}case"focus-scene":{{const l=Fr();if(l){n.camera.position.set(...l.position),n.orbitControls.target.set(...l.target),n.orbitControls.update();break}}z=e.sceneCameraLookup,X.begin(performance.now(),z!==null);break}case"focus-selection":{const l=x(e.shell),p=[...e.shell.selectedEntityIds].map(d=>Z(l,e.objectMap,d)).filter(d=>d!==null);n.focusOnMultiple(p);break}case"snap-selection-to-floor":n.snapSelectionToFloor();break;case"set-view-preset":n.setViewPreset(t.preset);break;case"step-view":n.stepView(t.step);break;case"frame-all":n.focusOnScene();break;case"zoom-view":n.zoomStep(t.direction);break;case"set-camera-pose":n.setPose(t.position,t.target,t.fov);break}});Lr();const ge=new ResizeObserver(()=>{const t=Math.max(1,o.clientWidth),l=Math.max(1,o.clientHeight);a.setSize(t,l),u.setSize(t,l),n.resize(t,l)});ge.observe(o);let W=performance.now(),_=!0,P=!1,be=!1;function ve(t){return Or(n.currentScene,()=>{E.render(a,n.currentScene,n.renderCamera),n.renderWithInfrastructure(()=>{vr(n.currentScene,()=>O.render(n.currentScene,e.shadingMode,()=>u.render(t),br)),n.renderViewCube(a),n.renderCameraPreview(a,B().preview?.camera??null,r.cameraPreview())})})}const Ue=ir(c,async()=>{if(P||!cr()||!o.checkVisibility({visibilityProperty:!0,checkVisibilityCSS:!0})||!ve(0))return null;const t=document.createElement("canvas");return t.width=c.width,t.height=c.height,t.getContext("2d").drawImage(c,0,0),t}),J=()=>wt(e.shell)===e.shell;function Ke(t,l){if(P)return;if(l&&(W=t),!o.checkVisibility({visibilityProperty:!0,checkVisibilityCSS:!0})){W=t,_=!0,n.resolvePresentation();return}g.beginFrame();const p=t-W,d=p/1e3;J()&&(m.frameTime=p,m.fps=1e3/p),W=t,k.syncMarkers(d),X.tick(t),g.beginPhase(),n.update(d),r.runFrame(d),n.batchedRenderer.update(d),g.endPhase("editor"),g.beginPhase(),a.info.reset(),ze(()=>{ve(d)}),g.reportRender({gpuMs:We(),drawCalls:a.info.render.calls,triangles:a.info.render.triangles,geometries:a.info.memory.geometries,textures:a.info.memory.textures}),g.endPhase("render"),J()&&(m.drawCalls=a.info.render.calls,m.triangles=a.info.render.triangles),_&&be&&(_=!1,vt(s)),g.endFrame();const w=oe(),C=w.position,y=w.target;J()&&(m.cameraPosition.x=C.x,m.cameraPosition.y=C.y,m.cameraPosition.z=C.z,m.cameraTarget.x=y.x,m.cameraTarget.y=y.y,m.cameraTarget.z=y.z);const R=`${C.x},${C.y},${C.z},${y.x},${y.y},${y.z},${w.fov}`;R!==se&&(se=R,k.reportCamera())}n.objectMap=e.objectMap,n.syncFromStore(),T();let Y,D;async function qe(t){if(P)return;r.onMountStatus("mounting"),D?.(),D=void 0,Y=t,r.onRootIds(t.childAdapters().filter(d=>d.role==="world"&&d.kind==="three").map(d=>d.worldId));const l=sr("three");if(P||Y!==t)return;const p=l?await l.mountWorldRootSession({store:e,composite:t,renderer:a}):()=>{};if(P||Y!==t){p();return}D=p,P||r.onMountStatus("ready")}const we=ar(e.shell,qe);return we.ready.then(()=>dt(mt(e.shell))).catch(t=>{j.error(`Editor boot failed: ${t instanceof Error?t.message:String(t)}`,"scene"),r.onMountStatus("ready")}).finally(()=>{be=!0,_=!0}),{scene:b,viewport:n,frame:Ke,present:t=>wr(e,t),setHelper:(t,l)=>n.setHelper(t,l),dispose:()=>{P=!0,_e(),Ue(),ge.disconnect(),Be(),He(),Ge(),n.orbitControls.removeEventListener("start",le),n.orbitControls.removeEventListener("change",ue),n.orbitControls.removeEventListener("end",A),n.orbitControls.removeEventListener("start",fe),n.orbitControls.removeEventListener("end",he),we.dispose(),D?.(),k.dispose(),O.dispose(),L.dispose(),Qe(),$e(),De(),Ne(),h?.selection.clear(),E.dispose(),u.dispose()}}}function Br({store:r,rootIds:e,mountStatus:s}){f.useSyncExternalStore(r.shell.subscribe,r.shell.getSnapshot);const o=f.useSyncExternalStore(kt,Tt),c=f.useSyncExternalStore(At,Rt),a=r.scene?.background,m=a!==null&&!(a?.isColor===!0&&a.getHex()===11184810),u=f.useMemo(()=>!!(r.scene&&It(r.scene,{includeBackground:!1,ignoredLayer:Xe})),[r.scene,r.shell.contentVersion]),E=!!(r.scene&&(m||u)),O=Lt({surface:"Scene",rootIds:e,phase:s==="mounting"?"loading":"ready",content:E?"present":s==="mounting"?"unknown":"empty",readiness:o,failures:c});return i.jsx(Ft,{explanation:O,testId:"scene-viewport-status"})}function Hr({store:r,documentId:e,cameraPreviewRef:s,mountStatus:o,rootIds:c}){f.useSyncExternalStore(r.shell.subscribe,r.shell.getShellSnapshot??r.shell.getSnapshot),f.useSyncExternalStore(Ct,xt),f.useSyncExternalStore(Mt,Vt),f.useSyncExternalStore(Pt,Et);const a=jt(r.shell,e,"document");return i.jsxs(i.Fragment,{children:[a.surface!==null?i.jsx(Ot,{}):null,a.surface==="three"?i.jsx(kr,{previewRef:s}):null,i.jsx(Br,{store:r,rootIds:c,mountStatus:o})]})}const ko={mountWorldRootSurface:zr,installWorldRootStage:Gr,Overlays:Hr};export{ko as worldRootStageBinding};
1
+ import{a as i}from"./jsx-runtime-DPjLkJKQ.js";import{EDITOR_LAYER as Xe}from"./editor-layers-CjeYrUlm.js";import{de as Oe,a6 as V,bM as Je,aK as te,bv as G,aL as $,kE as Ye,bL as Ze,bO as et,a5 as Q,g_ as tt,hE as rt,jW as nt,kF as ot,Y as j,J as st,ch as at,kG as Se,cw as it,kH as ct,kI as lt,kJ as ut,kK as Ce,kL as xe,aC as x,cT as dt,kM as mt,cp as pt,cu as ft,kN as Pe,kO as Ee,kP as je,kQ as ht,ak as gt,kR as bt,kS as ke,dH as vt,kT as wt,kU as yt,j2 as St,iU as Ct,iV as xt,gJ as Pt,gK as Et,j0 as jt,g1 as kt,g2 as Tt,g3 as At,g4 as Rt}from"./index-V4J7xfRg.js";import{s as Mt,o as Vt}from"./object3d-document-session-registry-DNCOGA3i.js";import{R as Ot}from"./RootSelectionOverlay-C6Wu8nIs.js";import{e as Lt,S as Ft}from"./surface-state-DrM3wsrr.js";import{r as f}from"./index-nmcBqr7Y.js";import{t as It}from"./surface-content-Dg9Kkazf.js";import"./index-CtzuWnCS.js";import{s as zt,d as Te,c as H,t as Wt,p as Le,v as Ae,b as _t,e as Nt,l as Dt,i as Qt}from"./camera-authoring-DYjhU5Zp.js";import{c as Gt}from"./performance-profiler-CMbwGBuk.js";import{m as $t}from"./renderer-ownership-BovSEcLv.js";import{applyWorldRendererConfig as Ht}from"./renderer-config-CaPR4dB_.js";import{getUserData as Fe}from"./user-data-CODoGZqA.js";import{detectKtx2Support as Ut}from"./loader-BTUKnX5Q.js";import{resolveRenderSettings as Bt}from"./render-settings-Clt6d05o.js";import{createSoftParticleDepthPass as qt}from"./soft-particle-depth-DNGwWJ8c.js";import{ViewportShadingRenderer as Kt}from"./viewport-shading-D9BMDb1N.js";import{applyRendererSettings as Xt,applySceneRenderPipeline as Jt}from"./setup-renderer-B5vZmCyu.js";import{EffectComposer as Yt,EffectPass as Zt,BlendFunction as er,KernelSize as tr,OutlineEffect as rr}from"./index-DHhMOs_s.js";import{W as nr,T as or}from"./three.module-BLhyNg0e.js";import{d as sr}from"./design-time-mount-registry-DUpXCg1U.js";import{a as ar}from"./project-authoring-session-DkekCxNv.js";import"./three-integration-DeWYFf1x.js";import{registerPresentedCanvasFrame as ir}from"./canvas-preview-frames-BzLeTumX.js";import{i as cr}from"./editor-presentation-activity-CqJH4G9t.js";import{E as lr,s as ur,a as dr,t as mr,b as pr,c as fr,d as hr,r as gr,i as br}from"./three-viewport-presentation-B_tBudM-.js";import{a as Z}from"./entity-object-V13bGmay.js";import{w as vr}from"./editor-shell-store-DckLm6m8.js";import{p as wr}from"./viewport-root-presentation-DJLpUuf0.js";import{d as yr}from"./asset-editor-persistence-Duoq7o22.js";import{bindStagePresenceMarkers as Sr}from"./stage-presence-markers-BgLs0Aj5.js";import{el as Cr,_ as ee,fo as D,d7 as xr,dp as Re}from"./three.core-3arARmh6.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./workspace-arrangement-B_OcbQbj.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./eyedropper-session-bjPXnfeX.js";import"./layered-pick-BUr1U8lU.js";import"./root-stacking-BEd9ZvxC.js";import"./react-story-board-CT1_3sk_.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./inspect-DiSjB-N1.js";import"./inference-diagnostics-DoZQ1mpg.js";import"./object-marks-BnvSuCTt.js";import"./KTX2Loader-CaqVE6nY.js";import"./GLTFLoader-KeoruJgS.js";import"./BufferGeometryUtils-B22h7jo4.js";import"./render-features-HCEupUJ6.js";import"./matcap-texture-Dm2c-VQa.js";import"./defaults-DKiBJCPN.js";import"./edit-mode-authoring-CSt3zzmS.js";import"./host-hierarchy-objects-BV3WqU2w.js";import"./preview-renderer-BrYNFV1p.js";import"./environment-Dg-YaLsA.js";import"./RoomEnvironment-BkknvS_I.js";import"./EXRLoader-CITMBvGd.js";import"./HDRLoader-BTGuGhVo.js";import"./user-data-CifDDvSr.js";import"./model-thumbnail-chePRlH7.js";import"./studio-environment-BIhqrtFc.js";import"./three-state-C7khRIQE.js";import"./hierarchy-marks-B1jSqxSv.js";import"./component-instance-root-Cw_-ajBX.js";import"./three-contract-Dkt6PmWY.js";import"./viewport-door-BCXEYmon.js";import"./content-bounds-D5pXeHJN.js";import"./asset-preview-BS71mXsZ.js";import"./bitmap-label-Ct4k6ehY.js";import"./index-D_ViOFCz.js";import"./standard-viewport-dressing-uhv_3JvQ.js";import"./clip-planes-CnAI6DZn.js";import"./three-BQfhEwUz.js";import"./model-inspection-8o57YSZW.js";import"./OrbitControls-B13MKuwC.js";import"./LineSegments2-DN9pUfWA.js";import"./three.quarks.esm-C_HmSKXo.js";import"./live-gesture-lock-DJbrjOqf.js";import"./scene-framing-DzSL2Cld.js";import"./live-mixers-B-bwLZ7c.js";import"./output-pass-HurwNl0G.js";import"./Pass-D1MRT672.js";import"./mounted-authoring-C47L5H5t.js";import"./collaboration-presence-DcPhahtF.js";function Pr({previewRef:r}){const{preview:e,previewPinned:s}=H(),[o,c]=f.useState(!1),a=f.useRef(null);if(f.useEffect(()=>{if(!o)return;const u=E=>{a.current?.contains(E.target)||c(!1)};return document.addEventListener("pointerdown",u),()=>document.removeEventListener("pointerdown",u)},[o]),!e)return null;const m=e.camera.isPerspectiveCamera&&Number.isFinite(e.camera.aspect)?e.camera.aspect:16/9;return i.jsxs("div",{className:"volter-camera-preview","data-testid":"camera-preview",children:[i.jsxs(Oe,{className:"volter-camera-preview-header",gap:4,align:"center",children:[i.jsx(V,{icon:Je,size:"sm"}),i.jsx(te,{variant:"label",truncate:!0,className:"volter-camera-preview-title",title:`${e.name} · ${e.lens}`,children:e.name}),i.jsx(G,{text:s?"Unpin camera preview":"Pin camera preview",children:i.jsx($,{"aria-label":s?"Unpin camera preview":"Pin camera preview","aria-pressed":s,size:"compact",onClick:Wt,children:i.jsx(V,{icon:Ye,size:"sm"})})}),i.jsxs("div",{ref:a,className:"volter-camera-preview-menu-anchor",children:[i.jsx(G,{text:"Camera actions",children:i.jsx($,{"aria-label":"Camera actions","aria-expanded":o,size:"compact",onClick:()=>c(u=>!u),children:i.jsx(V,{icon:Ze,size:"sm"})})}),o?i.jsxs(et,{className:"volter-camera-preview-menu",children:[i.jsx(Q,{variant:"ghost",size:"compact",disabled:!e.canAuthorPose,title:e.poseRefusal,onClick:()=>{c(!1),Le(e)},children:"Pilot Camera"}),i.jsx(Q,{variant:"ghost",size:"compact",onClick:()=>{c(!1),Ae(e)},children:"View Through Camera"}),i.jsx(Q,{variant:"ghost",size:"compact",disabled:!e.canAuthorPose,title:e.poseRefusal,onClick:()=>{c(!1),_t(e)},children:"Align Camera to Current View"})]}):null]})]}),i.jsx("div",{ref:r,className:"volter-camera-preview-image",style:{aspectRatio:String(Math.max(.5,Math.min(3,m)))},role:"img","aria-label":`Live view through ${e.name}`,onDoubleClick:()=>Ae(e)})]})}function Er(){return i.jsxs("div",{className:"volter-camera-guides","aria-hidden":"true",children:[i.jsx("div",{className:"volter-camera-guide volter-camera-guide-v1"}),i.jsx("div",{className:"volter-camera-guide volter-camera-guide-v2"}),i.jsx("div",{className:"volter-camera-guide volter-camera-guide-h1"}),i.jsx("div",{className:"volter-camera-guide volter-camera-guide-h2"}),i.jsx("div",{className:"volter-camera-safe-frame"}),i.jsx("div",{className:"volter-camera-center-mark"})]})}function jr(){const{view:r,guidesVisible:e}=H();if(!r)return null;const s=r.mode==="pilot";return i.jsxs(i.Fragment,{children:[e?i.jsx(Er,{}):null,i.jsx(tt,{variant:"overlay",border:!0,className:"volter-camera-view-banner volter-chrome-island volter-glass-island","data-testid":"camera-view-banner",children:i.jsxs(Oe,{gap:6,align:"center",children:[i.jsx(rt,{children:s?"PILOTING":"CAMERA VIEW"}),i.jsx(te,{variant:"label",children:r.subject.name}),i.jsx(te,{variant:"caption",tone:"muted",children:"Exact camera view"}),i.jsx(G,{text:e?"Hide composition guides":"Show composition guides",children:i.jsx($,{"aria-label":e?"Hide composition guides":"Show composition guides","aria-pressed":e,size:"compact",onClick:Nt,children:i.jsx(V,{icon:nt,size:"sm"})})}),s?null:i.jsx(Q,{size:"compact",variant:"primary",disabled:!r.subject.canAuthorPose,title:r.subject.poseRefusal,onClick:()=>Le(r.subject),children:"Pilot"}),i.jsx(G,{text:"Exit camera view",children:i.jsx($,{"aria-label":"Exit camera view",size:"compact",onClick:Dt,children:i.jsx(V,{icon:ot,size:"sm"})})})]})})]})}function kr({previewRef:r}){return f.useSyncExternalStore(zt,Te,Te),i.jsxs(i.Fragment,{children:[i.jsx(Pr,{previewRef:r}),i.jsx(jr,{})]})}function Tr(r){const e=r,s=e.getExtension("EXT_disjoint_timer_query_webgl2"),o=s!==null&&typeof e.createQuery=="function",c=[];let a=null,m=null;return{begin(){!o||a||(a=e.createQuery(),a&&e.beginQuery(s.TIME_ELAPSED_EXT,a))},end(){!o||!a||(e.endQuery(s.TIME_ELAPSED_EXT),c.push(a),a=null)},poll(){if(!o)return null;if(e.getParameter(s.GPU_DISJOINT_EXT)){for(const u of c.splice(0))e.deleteQuery(u);return null}for(;c.length>0;){const u=c[0];if(!e.getQueryParameter(u,e.QUERY_RESULT_AVAILABLE))break;c.shift(),m=e.getQueryParameter(u,e.QUERY_RESULT)/1e6,e.deleteQuery(u)}return m},dispose(){a&&(e.endQuery(s.TIME_ELAPSED_EXT),e.deleteQuery(a),a=null);for(const u of c.splice(0))e.deleteQuery(u)}}}const Ar=2e4,Rr=250,Mr=5e3;class Vr{#e=0;#t=0;#r=0;#n;constructor(e){this.#n=e}get pending(){return this.#e>0||this.#t>0}begin(e,s){this.#e=e+Ar,this.#t=s?e+Mr:0,this.#r=0,this.tick(e)}tick(e){if(!(!this.pending||e<this.#r)){if(this.#r=e+Rr,this.#t>0&&this.#n.seedFromGameCamera()){this.cancel();return}this.#e>0&&this.#n.frameContent()&&(this.#e=0),e>=this.#e&&(this.#e=0),e>=this.#t&&(this.#t=0)}}cancel(){this.#e=0,this.#t=0}}const Me=new WeakMap;function Or(r,e){if(!r)return e(),!0;if(Me.has(r))return!1;try{return e(),!0}catch(s){const o=s instanceof Error?s.message:String(s);return Me.set(r,o),j.warn(`The Scene view cannot draw this world with the editor's own renderer, and has stopped trying: ${o}. This world was built by a copy of three the editor did not make (a vendored bundle pins its own revision), and the editor draws it with ITS three — across a wide enough revision gap the two disagree about the renderer/material contract. The game itself is unaffected and still drawing: its own canvas is what the Game tab and ${st("screenshot")} show, and hierarchy, selection and inspection all still read the live world. It closes when the game resolves \`three\` to the host's instance — a bare, un-rewritten \`import 'three'\` in its own source.`,"ingest"),!1}}function Lr(){const r=at();r.addEventListener("server-log",s=>{try{Se(JSON.parse(s.data))}catch{}});let e=!1;return(async()=>{try{const s=await it();if(e)return;for(const o of s)Se(o)}catch{}})(),()=>{e=!0,r.close()}}const Ie="viewportPose";function Fr(){const r=ct(Ie);return r&&Array.isArray(r.position)&&r.position.length===3&&r.position.every(Number.isFinite)&&Array.isArray(r.target)&&r.target.length===3&&r.target.every(Number.isFinite)?r:null}function Ir(r,e){lt(Ie,{position:[r.position.x,r.position.y,r.position.z],target:[e.x,e.y,e.z]})}const Ve={id:"world",title:"World",lights:[{color:"#ffffff",intensity:1,direction:[-10,-20,-10],space:"world"}],ambient:{color:"#ffffff",intensity:.5},environmentIntensity:0};yt(Ve),St("world",{all:{lighting:{source:"studio",studioPreset:Ve.id,auto:{takeover:["light"],overridable:!0}}}});function zr(r,e,s){const o=document.createElement("canvas");o.setAttribute("aria-label",`${s} authoring viewport`),o.setAttribute("data-testid","editor-canvas"),o.setAttribute("aria-hidden","true"),o.tabIndex=-1,o.style.width="100%",o.style.height="100%",o.style.display="block",o.style.pointerEvents="auto",r.appendChild(o);const c=Math.max(1,e.clientWidth),a=Math.max(1,e.clientHeight),m=Math.min(window.devicePixelRatio||1,2);o.width=Math.ceil(c*m),o.height=Math.ceil(a*m);const u=$t(new nr({canvas:o,antialias:!!Bt(void 0).antialias,powerPreference:"high-performance"}));return Xt(u,void 0,m),u.setSize(c,a),u.shadowMap.type=xr,u.info.autoReset=!1,Ut(u),{canvas:o,renderer:u,lease:null}}async function Wr(r){const e=pt(r.source,r.id);if(e)return e;let s=r.url,o=r.format??"gltf",c=r.includes;if(!s){const u=(await ft(r.source,r.id))[0];if(!u)return j.error(`No downloadable files for ${r.name}.`,"asset"),null;s=u.url,o=u.format,c=u.includes}const a={source:r.source,id:r.id,name:r.name,url:s,format:o};c&&(a.includes=c);const m=await yr(a);return m.ok&&m.path?`/${m.path}`:(j.error(`Could not download ${r.name}.`,"asset"),null)}function _r(r){if(r.isCamera)return r;const e=Fe(r,"_camera");return e?.isCamera?e:null}function Nr(r){const e=r;if(e.isPerspectiveCamera)return`${e.fov.toFixed(0)}° perspective`;const s=r;return s.isOrthographicCamera?`Orthographic · ${s.zoom.toFixed(2)}×`:r.type}function Dr(r,e){const s=r.transforms;if(!s)return{canAuthorPose:!1,poseRefusal:"This camera has no transform authoring path."};const o=s.editability?.(e,"position")??{writable:!0},c=s.editability?.(e,"rotation")??{writable:!0};return o.writable&&c.writable?{canAuthorPose:!0}:{canAuthorPose:!1,poseRefusal:o.reason??c.reason??"This camera pose is read-only."}}function Qr(r,e,s){const o=e.get(s)??null;if(!o)return null;const c=_r(o);return c?{id:s,name:o.name||c.name||"Camera",camera:c,lens:Nr(c),...Dr(r,s)}:null}function Gr(r){const e=new Map;for(const[s,o]of r.objectMap){const c=Fe(o,"tags");Array.isArray(c)&&c.length>0&&e.set(s,c)}return e}function $r(r){const{store:e,documentId:s,container:o,canvas:c,renderer:a,stats:m}=r,u=new Yt(a),E=qt(),O=new Kt,g=Gt(),L=Tr(a.getContext()),ze=t=>{g.enabled&&L.begin();try{t()}finally{L.end()}},We=()=>g.enabled?L.poll():null,_e=ut({id:s,label:"Scene viewport",kind:"scene",profiler:g}),b=new Cr,re=11184810;let U=Ce(c).background??re;b.background=new ee(U);const Ne=xe(c,()=>{const t=Ce(c).background??re,l=b.background;l instanceof ee&&l.getHex()===U&&(b.background=new ee(t)),U=t});e.bindScene(b,a);const n=new lr(c,b,e,o,{renderer:a,onlineAssetResolver:Wr,onProjectionChange:ur}),De=n.bindPresentation(s,"world");e.bindScene(b,a,n.batchedRenderer,n.camera),e.setOrbitTarget(n.orbitControls.target);const B=new D,F=new D,ne=new D,oe=()=>{const t=n.renderCamera;t.getWorldPosition(B),n.cameraViewMode==="pilot"?F.copy(n.orbitControls.target):n.cameraViewMode?(t.getWorldDirection(ne),F.copy(B).add(ne.multiplyScalar(10))):F.copy(n.orbitControls.target);const l=t.fov;return{position:B,target:F,fov:typeof l=="number"?l:0}},k=Sr({scene:b,store:e,documentId:s,container:o,canvas:c,viewport:n,readVisibleCameraPose:oe});let se="",q=null,h=null,S=null,I=null;const ae=()=>{h&&fr(h,ke(a.domElement))},Qe=xe(a.domElement,ae),ie=()=>{if(!h)return;const t=x(e.shell),l=[...e.shell.selectedEntityIds].filter(d=>t.hierarchy.node(d)!==null).map(d=>Z(t,e.objectMap,d)).filter(d=>d!==null);hr(h,l);const p=h.selection.size>0;S&&(S.enabled=p,S.renderToScreen=p),I&&(I.renderToScreen=!p)};function T(){bt(e.shell),q?.(),q=null,h&&gr(a,h,S),h=null,S=null,I=null,Jt(u,a,e.scene??b,n.renderCamera,void 0,{basePixelRatio:Math.min(window.devicePixelRatio||1,2),objectMap:e.objectMap,entityTags:Gr(e)}),h=pr({BlendFunction:er,KernelSize:tr,OutlineEffect:rr},a,e.scene??b,n.renderCamera,ke(a.domElement)),ae(),I=u.passes.at(-1)??null,S=new Zt(n.renderCamera,h),S.enabled=!1,u.addPass(S),ie();const t=e.adoptedImageConfig;t&&(q=Ht(or,a,t))}const ce=()=>{n.setProjection(mr().projection),e.setViewportCamera(n.freeCamera),T()},Ge=dr(ce);ce();const K=t=>Qr(x(e.shell),e.objectMap,t);let v=null;const A=()=>{v&&(je(x(e.shell),v),v=null)},le=()=>{const t=H().view;t?.mode!=="pilot"||!t.subject.canAuthorPose||(v=t.subject.id,Pe(x(e.shell),v))},ue=()=>{if(!v||n.cameraViewMode!=="pilot")return;const t=K(v),l=x(e.shell),p=l.transforms;if(!t||!p)return;let d;try{d=p.get(v)}catch(w){j.error(w instanceof Error?w.message:String(w),"camera-authoring"),A();return}Ee(l,v,{position:t.camera.position.toArray(),rotation:t.camera.quaternion.toArray(),scale:d.scale}),e.shell.notifyIngestEdit()};n.orbitControls.addEventListener("start",le),n.orbitControls.addEventListener("change",ue),n.orbitControls.addEventListener("end",A);const $e=Qt({active:()=>e.shell.playState==="stopped"&&e.shell.activeViewportTab==="edit",selected:()=>{const t=e.shell.selectedEntityId;return t?K(t):null},resolve:K,showView:(t,l)=>{A(),n.setCameraView(t.camera,l),T(),k.reportCamera()},leaveView:()=>{A(),n.clearCameraView(),T(),k.reportCamera()},alignToViewport:t=>{const l=x(e.shell),p=l.transforms;if(!p||!t.canAuthorPose)return;const d=e.objectMap.get(t.id)??null;if(!d)return;const w=n.camera.getWorldPosition(new D),C=n.camera.getWorldQuaternion(new Re),y=w.clone(),R=C.clone();if(d.parent){d.parent.updateWorldMatrix(!0,!1),d.parent.worldToLocal(y);const M=d.parent.getWorldQuaternion(new Re);R.premultiply(M.invert())}let ye;try{ye=p.get(t.id)}catch(M){j.error(M instanceof Error?M.message:String(M),"camera-authoring");return}Pe(l,t.id),Ee(l,t.id,{position:y.toArray(),rotation:R.toArray(),scale:ye.scale}),e.shell.notifyIngestEdit(),je(l,t.id)},subscribe:e.shell.subscribe});let de=null;const me=()=>{const t=ht(e.shell);t!==de&&(de=t,c.style.opacity=t?"1":"0",o.style.backgroundColor=t?"":gt.surface.raised,o.style.backgroundImage=t?"":"linear-gradient(45deg, #444649 25%, transparent 25%, transparent 75%, #444649 75%), linear-gradient(45deg, #444649 25%, transparent 25%, transparent 75%, #444649 75%)",o.style.backgroundPosition=t?"":"0 0, 8px 8px",o.style.backgroundSize=t?"":"16px 16px")};me();let pe=e.composerVersion;const He=e.shell.subscribe(()=>{me();const t=e.scene;t&&t!==n.currentScene&&n.setScene(t),n.objectMap=e.objectMap,n.syncFromStore(),e.composerVersion!==pe?(pe=e.composerVersion,T()):ie()});let z=null;const X=new Vr({seedFromGameCamera:()=>{const t=z?.()??null;return!!t&&n.seedFromGameCamera(t)},frameContent:()=>n.focusOnScene()}),fe=()=>{X.cancel(),z=null};n.orbitControls.addEventListener("start",fe);const he=()=>Ir(n.camera,n.orbitControls.target);n.orbitControls.addEventListener("end",he);const Ue=e.shell.onViewportAction(t=>{switch(t.type){case"focus-entity":{const l=Z(x(e.shell),e.objectMap,t.id);l&&n.focusOn(l);break}case"focus-scene":{{const l=Fr();if(l){n.camera.position.set(...l.position),n.orbitControls.target.set(...l.target),n.orbitControls.update();break}}z=e.sceneCameraLookup,X.begin(performance.now(),z!==null);break}case"focus-selection":{const l=x(e.shell),p=[...e.shell.selectedEntityIds].map(d=>Z(l,e.objectMap,d)).filter(d=>d!==null);n.focusOnMultiple(p);break}case"snap-selection-to-floor":n.snapSelectionToFloor();break;case"set-view-preset":n.setViewPreset(t.preset);break;case"step-view":n.stepView(t.step);break;case"frame-all":n.focusOnScene();break;case"zoom-view":n.zoomStep(t.direction);break;case"set-camera-pose":n.setPose(t.position,t.target,t.fov);break}});Lr();const ge=new ResizeObserver(()=>{const t=Math.max(1,o.clientWidth),l=Math.max(1,o.clientHeight);a.setSize(t,l),u.setSize(t,l),n.resize(t,l)});ge.observe(o);let W=performance.now(),_=!0,P=!1,be=!1;function ve(t){return Or(n.currentScene,()=>{E.render(a,n.currentScene,n.renderCamera),n.renderWithInfrastructure(()=>{vr(n.currentScene,()=>O.render(n.currentScene,e.shadingMode,()=>u.render(t),br)),n.renderViewCube(a),n.renderCameraPreview(a,H().preview?.camera??null,r.cameraPreview())})})}const Be=ir(c,async()=>{if(P||!cr()||!o.checkVisibility({visibilityProperty:!0,checkVisibilityCSS:!0})||!ve(0))return null;const t=document.createElement("canvas");return t.width=c.width,t.height=c.height,t.getContext("2d").drawImage(c,0,0),t}),J=()=>wt(e.shell)===e.shell;function qe(t,l){if(P)return;if(l&&(W=t),!o.checkVisibility({visibilityProperty:!0,checkVisibilityCSS:!0})){W=t,_=!0,n.resolvePresentation();return}g.beginFrame();const p=t-W,d=p/1e3;J()&&(m.frameTime=p,m.fps=1e3/p),W=t,k.syncMarkers(d),X.tick(t),g.beginPhase(),n.update(d),r.runFrame(d),n.batchedRenderer.update(d),g.endPhase("editor"),g.beginPhase(),a.info.reset(),ze(()=>{ve(d)}),g.reportRender({gpuMs:We(),drawCalls:a.info.render.calls,triangles:a.info.render.triangles,geometries:a.info.memory.geometries,textures:a.info.memory.textures}),g.endPhase("render"),J()&&(m.drawCalls=a.info.render.calls,m.triangles=a.info.render.triangles),_&&be&&(_=!1,vt(s)),g.endFrame();const w=oe(),C=w.position,y=w.target;J()&&(m.cameraPosition.x=C.x,m.cameraPosition.y=C.y,m.cameraPosition.z=C.z,m.cameraTarget.x=y.x,m.cameraTarget.y=y.y,m.cameraTarget.z=y.z);const R=`${C.x},${C.y},${C.z},${y.x},${y.y},${y.z},${w.fov}`;R!==se&&(se=R,k.reportCamera())}n.objectMap=e.objectMap,n.syncFromStore(),T();let Y,N;async function Ke(t){if(P)return;r.onMountStatus("mounting"),N?.(),N=void 0,Y=t,r.onRootIds(t.childAdapters().filter(d=>d.role==="world"&&d.kind==="three").map(d=>d.worldId));const l=sr("three");if(P||Y!==t)return;const p=l?await l.mountWorldRootSession({store:e,composite:t,renderer:a}):()=>{};if(P||Y!==t){p();return}N=p,P||r.onMountStatus("ready")}const we=ar(e.shell,Ke);return we.ready.then(()=>dt(mt(e.shell))).catch(t=>{j.error(`Editor boot failed: ${t instanceof Error?t.message:String(t)}`,"scene"),r.onMountStatus("ready")}).finally(()=>{be=!0,_=!0}),{scene:b,viewport:n,frame:qe,present:t=>wr(e,t),setHelper:(t,l)=>n.setHelper(t,l),dispose:()=>{P=!0,_e(),Be(),ge.disconnect(),He(),Ue(),$e(),n.orbitControls.removeEventListener("start",le),n.orbitControls.removeEventListener("change",ue),n.orbitControls.removeEventListener("end",A),n.orbitControls.removeEventListener("start",fe),n.orbitControls.removeEventListener("end",he),we.dispose(),N?.(),k.dispose(),O.dispose(),L.dispose(),Ge(),Qe(),Ne(),De(),h?.selection.clear(),E.dispose(),u.dispose()}}}function Hr({store:r,rootIds:e,mountStatus:s}){f.useSyncExternalStore(r.shell.subscribe,r.shell.getSnapshot);const o=f.useSyncExternalStore(kt,Tt),c=f.useSyncExternalStore(At,Rt),a=r.scene?.background,m=a!==null&&!(a?.isColor===!0&&a.getHex()===11184810),u=f.useMemo(()=>!!(r.scene&&It(r.scene,{includeBackground:!1,ignoredLayer:Xe})),[r.scene,r.shell.contentVersion]),E=!!(r.scene&&(m||u)),O=Lt({surface:"Scene",rootIds:e,phase:s==="mounting"?"loading":"ready",content:E?"present":s==="mounting"?"unknown":"empty",readiness:o,failures:c});return i.jsx(Ft,{explanation:O,testId:"scene-viewport-status"})}function Ur({store:r,documentId:e,cameraPreviewRef:s,mountStatus:o,rootIds:c}){f.useSyncExternalStore(r.shell.subscribe,r.shell.getShellSnapshot??r.shell.getSnapshot),f.useSyncExternalStore(Ct,xt),f.useSyncExternalStore(Mt,Vt),f.useSyncExternalStore(Pt,Et);const a=jt(r.shell,e,"document");return i.jsxs(i.Fragment,{children:[a.surface!==null?i.jsx(Ot,{}):null,a.surface==="three"?i.jsx(kr,{previewRef:s}):null,i.jsx(Hr,{store:r,rootIds:c,mountStatus:o})]})}const ko={mountWorldRootSurface:zr,installWorldRootStage:$r,Overlays:Ur};export{ko as worldRootStageBinding};
@@ -1 +1 @@
1
- import{collectMachineAnimationMeta as V,clipNamesOf as L,isBlendTreeAnimationMeta as S,asBlendTreeDef as z}from"./xstate-animation-meta-0RXvMgDk.js";import{cW as J,p as Z,c as _,cQ as ee,l as te,dk as ne,cf as ie,cd as oe}from"./three.core-3arARmh6.js";import"./index-flxMlfV4.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";class M extends Error{constructor(i,c){super(i),this.stateId=c,this.name="AnimationBindingError"}}function ae(n){const i=n.logic;if(i?.root)return i;const c=n.getSnapshot();if(c?.machine?.root)return c.machine;throw new M("[bindXStateAnimation] the actor exposes no state machine — only a state-machine actor carries the `meta.animation` this binder reads")}const W=n=>n.layer??"base",B=n=>n.weight??1,I=n=>n.blendMode??"override";function T(n){try{return ne.parseTrackName(n.name).nodeName??""}catch{const i=n.name.indexOf(".");return i<0?n.name:n.name.slice(0,i)}}function C(n,i,c){const o=new Set,l=[];for(const f of i){let u=!1;n.traverse(m=>{m.name===f&&(u=!0,m.traverse(d=>{d.name&&o.add(d.name)}))}),c.has(f)&&(u=!0,o.add(f)),u||l.push(f)}return{names:o,missing:l}}function se(n,i,c,o){const l=new Set(n.tracks.map(T)),f=i.include?C(c,i.include,l):void 0,u=i.exclude?C(c,i.exclude,l):void 0,m=[...f?.missing??[],...u?.missing??[]];if(m.length)throw new M(`[bindXStateAnimation] state "${o}" boneMask names unknown bones/objects: ${m.join(", ")}`,o);const d=n.tracks.filter(p=>{const w=T(p);return(!f||f.names.has(w))&&!u?.names.has(w)});if(d.length===0)throw new M(`[bindXStateAnimation] state "${o}" boneMask removes every track from clip "${n.name}"`,o);return new te(n.name,n.duration,d.map(p=>p.clone()))}function re(n){return n.reduce((i,c)=>c.weight>i.weight?c:i,n[0])}function Se(n,i,c,o={}){const l=i.getRoot(),f=o.root??(l instanceof J?l:void 0);if(!f)throw new M("[bindXStateAnimation] a THREE.Object3D `root` option is required when the mixer uses AnimationObjectGroup");const u=ae(n).root,m=V(u),d=new Map(m.map(t=>[t.stateId,t.meta]));for(const t of m)for(const e of L(t.meta))if(!c.has(e))throw new M(`[bindXStateAnimation] state "${t.stateId}" references clip "${e}", which is not present in the supplied clips map. Known clips: ${[...c.keys()].join(", ")||"(none)"}`,t.stateId);const p=new Map;function w(t,e,s){return W(e)!=="base"||!!e.boneMask||I(e)==="additive"?`${t}\0${s}`:s}for(const{stateId:t,meta:e}of m)for(const s of L(e)){const a=w(t,e,s);if(p.has(a))continue;const r=c.get(s);let h=e.boneMask?se(r,e.boneMask,f,t):r;(h!==r||a!==s)&&(h===r&&(h=r.clone()),h.name=`${r.name}@${W(e)}:${t}`),I(e)==="additive"?(Z.makeClipAdditive(h),h.blendMode=_):h.blendMode=ee,p.set(a,h)}const g=new Map;function K(t,e,s,a){let r=g.get(t);if(!r){const h=p.get(t);if(!h)throw new M(`[bindXStateAnimation] prepared clip "${t}" not found`);const v=i.clipAction(h);v.setEffectiveWeight(0),v.play(),r={action:v,clip:h},g.set(t,r)}return r.action.setLoop(e?ie:oe,1/0),r.action.clampWhenFinished=!e,r.action.timeScale=s,r.action.weight=a,r.action}function N(t){const e=o.selectParameters?o.selectParameters(t):t;return new Map(Object.entries(e??{}))}function D(t,e,s){return(S(e)?ce(z(e.blendTree),N(s)):[{clip:e.clip,weight:1}]).map(({clip:r,weight:h})=>({clip:r,weight:h,actionKey:w(t,e,r)}))}const y=new Map;let O=!1;function R(t,e,s){for(const a of t){if(a.actionKey===e)continue;const r=g.get(a.actionKey)?.action;r&&(s>0?r.fadeOut(s):r.setEffectiveWeight(0))}}function k(t,e){if(!S(t.meta))return;t.natural=D(t.stateId,t.meta,e);const s=B(t.meta);for(const a of t.natural)g.get(a.actionKey)?.action.setEffectiveWeight(a.weight*s)}function P(t,e,s){const a=W(e),r=y.get(a)??null,h=D(t,e,s),v=re(h),H=S(e)?!0:e.loop,Q=S(e)?1:e.speed,x=B(e);for(const b of h)K(b.actionKey,H,Q,x);const $=g.get(v.actionKey).action;$.reset().setEffectiveWeight(x);for(const b of h)b.actionKey!==v.actionKey&&g.get(b.actionKey).action.reset().setEffectiveWeight(0);const A=e.crossfade?.duration??0,U=e.crossfade?.warp??!1;if(!r)A>0&&$.fadeIn(A);else{R(r.natural,r.dominantActionKey,A);const b=g.get(r.dominantActionKey)?.action;b&&A>0?b.crossFadeTo($,A,U):(b?.setEffectiveWeight(0),$.setEffectiveWeight(x))}const j={layer:a,stateId:t,meta:e,natural:h,dominantActionKey:v.actionKey,crossfadeRemaining:A};y.set(a,j),S(e)&&A<=0&&k(j,s)}function q(t){return Object.keys(t.getMeta()).filter(e=>d.has(e))}function X(t){const e=new Map;for(const s of q(t)){const a=d.get(s),r=W(a),h=e.get(r);if(h)throw new M(`[bindXStateAnimation] animated states "${h}" and "${s}" are both active on layer "${r}". Give parallel regions distinct meta.animation.layer names.`,s);e.set(r,s)}for(const[s,a]of y)e.has(s)||(R(a.natural,void 0,0),y.delete(s));for(const[s,a]of e)y.get(s)?.stateId!==a&&P(a,d.get(a),t.context)}const F=n.getSnapshot();X(F);const G=n.subscribe(t=>{O||X(t)});function E(t){if(O)return;const e=t,s=n.getSnapshot().context;for(const a of y.values())a.crossfadeRemaining>0?(a.crossfadeRemaining=Math.max(0,a.crossfadeRemaining-e),a.crossfadeRemaining<=0&&k(a,s)):k(a,s);i.update(e)}const Y={tick:E,actor:n,getParameters:()=>N(n.getSnapshot().context),getActiveLayers:()=>[...y.values()].map(t=>({layer:t.layer,stateId:t.stateId,clips:t.natural.map(e=>e.clip),clipWeights:t.natural.map(e=>({clip:e.clip,weight:g.get(e.actionKey)?.action.getEffectiveWeight()??0})),weight:B(t.meta),blendMode:I(t.meta),...t.meta.boneMask?{boneMask:t.meta.boneMask}:{}})),dispose(){if(!O){O=!0,o.systems?.remove("animation",E),G.unsubscribe();for(const{action:t,clip:e}of g.values())t.stop(),i.uncacheAction(e,t.getRoot());g.clear(),y.clear()}}};return o.systems?.add("animation",E),Y}function ce(n,i){switch(n.type){case"1D":return le(n,i);case"2D":return fe(n,i);case"direct":return de(n);default:return n.children.map(c=>({clip:c.clip,weight:1/n.children.length}))}}function le(n,i){const c=Number(i.get(n.parameter)??0),o=[...n.children].sort((f,u)=>f.threshold-u.threshold),l=o.map(f=>({clip:f.clip,weight:0}));if(o.length===0)return l;if(o.length===1||c<=o[0].threshold)return l[0].weight=1,l;if(c>=o[o.length-1].threshold)return l[l.length-1].weight=1,l;for(let f=0;f<o.length-1;f++){const u=o[f],m=o[f+1];if(c>=u.threshold&&c<=m.threshold){const d=m.threshold-u.threshold,p=d>0?(c-u.threshold)/d:0;return l[f].weight=1-p,l[f+1].weight=p,l}}return l}function fe(n,i){const c=Number(i.get(n.parameter)??0),o=Number(i.get(n.parameterY??"")??0),l=n.children,f=l.map(d=>({clip:d.clip,weight:0}));let u=0;const m=[];for(const d of l){const p=c-d.threshold,w=o-(d.thresholdY??0),g=Math.sqrt(p*p+w*w),K=g<.001?1e3:1/g;m.push(K),u+=K}if(u>0)for(let d=0;d<f.length;d++)f[d].weight=m[d]/u;return f}function de(n){const i=n.children.map(o=>({clip:o.clip,weight:o.weight??0})),c=i.reduce((o,l)=>o+l.weight,0);if(c>0)for(const o of i)o.weight/=c;return i}export{M as AnimationBindingError,Se as bindXStateAnimation,ce as evaluateBlendTree,ae as machineOfXStateActor};
1
+ import{collectMachineAnimationMeta as V,clipNamesOf as L,isBlendTreeAnimationMeta as S,asBlendTreeDef as z}from"./xstate-animation-meta-XEmD_qc_.js";import{cW as J,p as Z,c as _,cQ as ee,l as te,dk as ne,cf as ie,cd as oe}from"./three.core-3arARmh6.js";import"./index-V4J7xfRg.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";class M extends Error{constructor(i,c){super(i),this.stateId=c,this.name="AnimationBindingError"}}function ae(n){const i=n.logic;if(i?.root)return i;const c=n.getSnapshot();if(c?.machine?.root)return c.machine;throw new M("[bindXStateAnimation] the actor exposes no state machine — only a state-machine actor carries the `meta.animation` this binder reads")}const W=n=>n.layer??"base",B=n=>n.weight??1,I=n=>n.blendMode??"override";function T(n){try{return ne.parseTrackName(n.name).nodeName??""}catch{const i=n.name.indexOf(".");return i<0?n.name:n.name.slice(0,i)}}function C(n,i,c){const o=new Set,l=[];for(const f of i){let u=!1;n.traverse(m=>{m.name===f&&(u=!0,m.traverse(d=>{d.name&&o.add(d.name)}))}),c.has(f)&&(u=!0,o.add(f)),u||l.push(f)}return{names:o,missing:l}}function se(n,i,c,o){const l=new Set(n.tracks.map(T)),f=i.include?C(c,i.include,l):void 0,u=i.exclude?C(c,i.exclude,l):void 0,m=[...f?.missing??[],...u?.missing??[]];if(m.length)throw new M(`[bindXStateAnimation] state "${o}" boneMask names unknown bones/objects: ${m.join(", ")}`,o);const d=n.tracks.filter(p=>{const w=T(p);return(!f||f.names.has(w))&&!u?.names.has(w)});if(d.length===0)throw new M(`[bindXStateAnimation] state "${o}" boneMask removes every track from clip "${n.name}"`,o);return new te(n.name,n.duration,d.map(p=>p.clone()))}function re(n){return n.reduce((i,c)=>c.weight>i.weight?c:i,n[0])}function Se(n,i,c,o={}){const l=i.getRoot(),f=o.root??(l instanceof J?l:void 0);if(!f)throw new M("[bindXStateAnimation] a THREE.Object3D `root` option is required when the mixer uses AnimationObjectGroup");const u=ae(n).root,m=V(u),d=new Map(m.map(t=>[t.stateId,t.meta]));for(const t of m)for(const e of L(t.meta))if(!c.has(e))throw new M(`[bindXStateAnimation] state "${t.stateId}" references clip "${e}", which is not present in the supplied clips map. Known clips: ${[...c.keys()].join(", ")||"(none)"}`,t.stateId);const p=new Map;function w(t,e,s){return W(e)!=="base"||!!e.boneMask||I(e)==="additive"?`${t}\0${s}`:s}for(const{stateId:t,meta:e}of m)for(const s of L(e)){const a=w(t,e,s);if(p.has(a))continue;const r=c.get(s);let h=e.boneMask?se(r,e.boneMask,f,t):r;(h!==r||a!==s)&&(h===r&&(h=r.clone()),h.name=`${r.name}@${W(e)}:${t}`),I(e)==="additive"?(Z.makeClipAdditive(h),h.blendMode=_):h.blendMode=ee,p.set(a,h)}const g=new Map;function K(t,e,s,a){let r=g.get(t);if(!r){const h=p.get(t);if(!h)throw new M(`[bindXStateAnimation] prepared clip "${t}" not found`);const v=i.clipAction(h);v.setEffectiveWeight(0),v.play(),r={action:v,clip:h},g.set(t,r)}return r.action.setLoop(e?ie:oe,1/0),r.action.clampWhenFinished=!e,r.action.timeScale=s,r.action.weight=a,r.action}function N(t){const e=o.selectParameters?o.selectParameters(t):t;return new Map(Object.entries(e??{}))}function D(t,e,s){return(S(e)?ce(z(e.blendTree),N(s)):[{clip:e.clip,weight:1}]).map(({clip:r,weight:h})=>({clip:r,weight:h,actionKey:w(t,e,r)}))}const y=new Map;let O=!1;function R(t,e,s){for(const a of t){if(a.actionKey===e)continue;const r=g.get(a.actionKey)?.action;r&&(s>0?r.fadeOut(s):r.setEffectiveWeight(0))}}function k(t,e){if(!S(t.meta))return;t.natural=D(t.stateId,t.meta,e);const s=B(t.meta);for(const a of t.natural)g.get(a.actionKey)?.action.setEffectiveWeight(a.weight*s)}function P(t,e,s){const a=W(e),r=y.get(a)??null,h=D(t,e,s),v=re(h),H=S(e)?!0:e.loop,Q=S(e)?1:e.speed,x=B(e);for(const b of h)K(b.actionKey,H,Q,x);const $=g.get(v.actionKey).action;$.reset().setEffectiveWeight(x);for(const b of h)b.actionKey!==v.actionKey&&g.get(b.actionKey).action.reset().setEffectiveWeight(0);const A=e.crossfade?.duration??0,U=e.crossfade?.warp??!1;if(!r)A>0&&$.fadeIn(A);else{R(r.natural,r.dominantActionKey,A);const b=g.get(r.dominantActionKey)?.action;b&&A>0?b.crossFadeTo($,A,U):(b?.setEffectiveWeight(0),$.setEffectiveWeight(x))}const j={layer:a,stateId:t,meta:e,natural:h,dominantActionKey:v.actionKey,crossfadeRemaining:A};y.set(a,j),S(e)&&A<=0&&k(j,s)}function q(t){return Object.keys(t.getMeta()).filter(e=>d.has(e))}function X(t){const e=new Map;for(const s of q(t)){const a=d.get(s),r=W(a),h=e.get(r);if(h)throw new M(`[bindXStateAnimation] animated states "${h}" and "${s}" are both active on layer "${r}". Give parallel regions distinct meta.animation.layer names.`,s);e.set(r,s)}for(const[s,a]of y)e.has(s)||(R(a.natural,void 0,0),y.delete(s));for(const[s,a]of e)y.get(s)?.stateId!==a&&P(a,d.get(a),t.context)}const F=n.getSnapshot();X(F);const G=n.subscribe(t=>{O||X(t)});function E(t){if(O)return;const e=t,s=n.getSnapshot().context;for(const a of y.values())a.crossfadeRemaining>0?(a.crossfadeRemaining=Math.max(0,a.crossfadeRemaining-e),a.crossfadeRemaining<=0&&k(a,s)):k(a,s);i.update(e)}const Y={tick:E,actor:n,getParameters:()=>N(n.getSnapshot().context),getActiveLayers:()=>[...y.values()].map(t=>({layer:t.layer,stateId:t.stateId,clips:t.natural.map(e=>e.clip),clipWeights:t.natural.map(e=>({clip:e.clip,weight:g.get(e.actionKey)?.action.getEffectiveWeight()??0})),weight:B(t.meta),blendMode:I(t.meta),...t.meta.boneMask?{boneMask:t.meta.boneMask}:{}})),dispose(){if(!O){O=!0,o.systems?.remove("animation",E),G.unsubscribe();for(const{action:t,clip:e}of g.values())t.stop(),i.uncacheAction(e,t.getRoot());g.clear(),y.clear()}}};return o.systems?.add("animation",E),Y}function ce(n,i){switch(n.type){case"1D":return le(n,i);case"2D":return fe(n,i);case"direct":return de(n);default:return n.children.map(c=>({clip:c.clip,weight:1/n.children.length}))}}function le(n,i){const c=Number(i.get(n.parameter)??0),o=[...n.children].sort((f,u)=>f.threshold-u.threshold),l=o.map(f=>({clip:f.clip,weight:0}));if(o.length===0)return l;if(o.length===1||c<=o[0].threshold)return l[0].weight=1,l;if(c>=o[o.length-1].threshold)return l[l.length-1].weight=1,l;for(let f=0;f<o.length-1;f++){const u=o[f],m=o[f+1];if(c>=u.threshold&&c<=m.threshold){const d=m.threshold-u.threshold,p=d>0?(c-u.threshold)/d:0;return l[f].weight=1-p,l[f+1].weight=p,l}}return l}function fe(n,i){const c=Number(i.get(n.parameter)??0),o=Number(i.get(n.parameterY??"")??0),l=n.children,f=l.map(d=>({clip:d.clip,weight:0}));let u=0;const m=[];for(const d of l){const p=c-d.threshold,w=o-(d.thresholdY??0),g=Math.sqrt(p*p+w*w),K=g<.001?1e3:1/g;m.push(K),u+=K}if(u>0)for(let d=0;d<f.length;d++)f[d].weight=m[d]/u;return f}function de(n){const i=n.children.map(o=>({clip:o.clip,weight:o.weight??0})),c=i.reduce((o,l)=>o+l.weight,0);if(c>0)for(const o of i)o.weight/=c;return i}export{M as AnimationBindingError,Se as bindXStateAnimation,ce as evaluateBlendTree,ae as machineOfXStateActor};
@@ -1 +1 @@
1
- import{dY as b,dZ as u,t as o,u as l,v as n,w as c,bA as r,bz as m,by as f}from"./index-flxMlfV4.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const d=o({clip:n().min(1).describe("Animation clip name this child plays"),threshold:r().describe("1D/2D blend position on the primary parameter axis"),thresholdY:r().optional().describe("2D blend position on the secondary parameter axis (2D blend trees only)"),weight:r().min(0).optional().describe('Explicit weight for "direct" blend trees (ignored by 1D/2D)')}).strict(),y=o({type:c("1D").describe("Interpolates linearly between sorted children by threshold"),parameter:n().min(1).describe("Context/selector value driving the blend"),children:l(d).min(2,"1D blend tree needs at least 2 children to interpolate between")}).strict(),v=o({type:c("2D").describe("Inverse-distance-weights children by (parameter, parameterY) position"),parameter:n().min(1).describe("Primary axis context/selector value"),parameterY:n().min(1).describe("Secondary axis context/selector value"),children:l(d.extend({thresholdY:r()})).min(1,"2D blend tree needs at least 1 child")}).strict(),A=o({type:c("direct").describe("Each child has an explicit weight, normalized to sum to 1"),parameter:n().default(""),children:l(d.extend({weight:r().min(0)})).min(1,"direct blend tree needs at least 1 child")}).strict(),g=b("type",[y,v,A]);function P(e){return e}const p=o({duration:r().min(0).default(0).describe("Seconds to blend from the previously active clip into this state on entry, applied via native `AnimationAction.crossFadeTo`/`fadeIn` (E2). 0 = instant activation, no fade."),warp:m().default(!1).describe("Passed through to AnimationAction.crossFadeTo's `warp` param — linearly warps timeScale across the two clips during the blend so differing clip lengths line up. Default false.")}).strict().describe("Blend-in/out/crossfade timing for entering this state"),x=o({include:l(n().min(1)).min(1).optional().describe("Bone/object names whose complete descendant subtrees are retained"),exclude:l(n().min(1)).min(1).optional().describe("Bone/object names whose complete descendant subtrees are removed")}).strict().refine(e=>!!(e.include?.length||e.exclude?.length),{message:"boneMask needs at least one include or exclude bone name"}).describe("Filters animation tracks by named Object3D/Bone subtrees"),h={layer:n().min(1).optional().describe("Composition layer name; omitted means the single base layer"),weight:r().min(0).max(1).optional().describe("Layer weight multiplier from 0 to 1; defaults to 1"),blendMode:f(["override","additive"]).optional().describe("Native Three normal/override or additive action blending; defaults to override"),boneMask:x.optional().describe("Optional include/exclude filter applied to every clip track in this state")},w=o({clip:n().min(1).describe("Single clip to play while this XState state is active"),loop:m().default(!0).describe("Loop the clip (THREE.LoopRepeat) vs play once (THREE.LoopOnce, clamped on last frame)"),speed:r().positive().default(1).describe("Playback speed multiplier (AnimationAction.timeScale)"),crossfade:p.optional(),...h}).strict(),S=o({blendTree:g.describe("Multiple clips blended by a live context/selector-driven parameter"),crossfade:p.optional(),...h}).strict(),D=u([w,S]);function M(e){return"clip"in e}function $(e){return"blendTree"in e}class T extends Error{constructor(a,i,t){super(a),this.stateId=i,this.issues=t,this.name="AnimationMetaValidationError"}}function B(e,a){const i=D.safeParse(a);if(!i.success){const t=i.error.issues.map(s=>`${s.path.length?s.path.join("."):"(root)"}: ${s.message}`).join("; ");throw new T(`[xstate-animation] invalid meta.animation for state "${e}": ${t}`,e,i.error.issues)}return i.data}function R(e){const a=[],i=t=>{t.meta&&"animation"in t.meta&&t.meta.animation!==void 0&&a.push({stateId:t.id,meta:B(t.id,t.meta.animation)});for(const s of Object.values(t.states??{}))i(s)};return i(e),a}function z(e){return M(e)?[e.clip]:e.blendTree.children.map(a=>a.clip)}export{g as AnimationBlendTreeSchema,T as AnimationMetaValidationError,D as StateAnimationMetaSchema,P as asBlendTreeDef,z as clipNamesOf,R as collectMachineAnimationMeta,$ as isBlendTreeAnimationMeta,M as isClipAnimationMeta,B as parseStateAnimationMeta};
1
+ import{dY as b,dZ as u,t as o,u as c,v as n,w as l,c5 as r,c4 as m,c3 as f}from"./index-V4J7xfRg.js";import"./index-nmcBqr7Y.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./jsx-runtime-DPjLkJKQ.js";import"./index-CtzuWnCS.js";import"./index-CinJrH5C.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";const d=o({clip:n().min(1).describe("Animation clip name this child plays"),threshold:r().describe("1D/2D blend position on the primary parameter axis"),thresholdY:r().optional().describe("2D blend position on the secondary parameter axis (2D blend trees only)"),weight:r().min(0).optional().describe('Explicit weight for "direct" blend trees (ignored by 1D/2D)')}).strict(),y=o({type:l("1D").describe("Interpolates linearly between sorted children by threshold"),parameter:n().min(1).describe("Context/selector value driving the blend"),children:c(d).min(2,"1D blend tree needs at least 2 children to interpolate between")}).strict(),v=o({type:l("2D").describe("Inverse-distance-weights children by (parameter, parameterY) position"),parameter:n().min(1).describe("Primary axis context/selector value"),parameterY:n().min(1).describe("Secondary axis context/selector value"),children:c(d.extend({thresholdY:r()})).min(1,"2D blend tree needs at least 1 child")}).strict(),g=o({type:l("direct").describe("Each child has an explicit weight, normalized to sum to 1"),parameter:n().default(""),children:c(d.extend({weight:r().min(0)})).min(1,"direct blend tree needs at least 1 child")}).strict(),A=b("type",[y,v,g]);function P(e){return e}const p=o({duration:r().min(0).default(0).describe("Seconds to blend from the previously active clip into this state on entry, applied via native `AnimationAction.crossFadeTo`/`fadeIn` (E2). 0 = instant activation, no fade."),warp:m().default(!1).describe("Passed through to AnimationAction.crossFadeTo's `warp` param — linearly warps timeScale across the two clips during the blend so differing clip lengths line up. Default false.")}).strict().describe("Blend-in/out/crossfade timing for entering this state"),x=o({include:c(n().min(1)).min(1).optional().describe("Bone/object names whose complete descendant subtrees are retained"),exclude:c(n().min(1)).min(1).optional().describe("Bone/object names whose complete descendant subtrees are removed")}).strict().refine(e=>!!(e.include?.length||e.exclude?.length),{message:"boneMask needs at least one include or exclude bone name"}).describe("Filters animation tracks by named Object3D/Bone subtrees"),h={layer:n().min(1).optional().describe("Composition layer name; omitted means the single base layer"),weight:r().min(0).max(1).optional().describe("Layer weight multiplier from 0 to 1; defaults to 1"),blendMode:f(["override","additive"]).optional().describe("Native Three normal/override or additive action blending; defaults to override"),boneMask:x.optional().describe("Optional include/exclude filter applied to every clip track in this state")},w=o({clip:n().min(1).describe("Single clip to play while this XState state is active"),loop:m().default(!0).describe("Loop the clip (THREE.LoopRepeat) vs play once (THREE.LoopOnce, clamped on last frame)"),speed:r().positive().default(1).describe("Playback speed multiplier (AnimationAction.timeScale)"),crossfade:p.optional(),...h}).strict(),S=o({blendTree:A.describe("Multiple clips blended by a live context/selector-driven parameter"),crossfade:p.optional(),...h}).strict(),D=u([w,S]);function M(e){return"clip"in e}function $(e){return"blendTree"in e}class T extends Error{constructor(a,i,t){super(a),this.stateId=i,this.issues=t,this.name="AnimationMetaValidationError"}}function B(e,a){const i=D.safeParse(a);if(!i.success){const t=i.error.issues.map(s=>`${s.path.length?s.path.join("."):"(root)"}: ${s.message}`).join("; ");throw new T(`[xstate-animation] invalid meta.animation for state "${e}": ${t}`,e,i.error.issues)}return i.data}function R(e){const a=[],i=t=>{t.meta&&"animation"in t.meta&&t.meta.animation!==void 0&&a.push({stateId:t.id,meta:B(t.id,t.meta.animation)});for(const s of Object.values(t.states??{}))i(s)};return i(e),a}function H(e){return M(e)?[e.clip]:e.blendTree.children.map(a=>a.clip)}export{A as AnimationBlendTreeSchema,T as AnimationMetaValidationError,D as StateAnimationMetaSchema,P as asBlendTreeDef,H as clipNamesOf,R as collectMachineAnimationMeta,$ as isBlendTreeAnimationMeta,M as isClipAnimationMeta,B as parseStateAnimationMeta};
package/dist-node/cli.js CHANGED
@@ -2310,7 +2310,7 @@ import { fileURLToPath as fileURLToPath2 } from "node:url";
2310
2310
  var package_default = {
2311
2311
  name: "@volter/game-editor",
2312
2312
  author: "Volter AI, Inc.",
2313
- version: "0.5.80",
2313
+ version: "0.5.82",
2314
2314
  publishConfig: {
2315
2315
  access: "public"
2316
2316
  },
@@ -2359,22 +2359,22 @@ var package_default = {
2359
2359
  }
2360
2360
  },
2361
2361
  dependencies: {
2362
- "@volter/editor-core": "0.5.80",
2363
- "@volter/editor-game": "0.5.80",
2364
- "@volter/editor-react": "0.5.80",
2365
- "@volter/editor-threejs": "0.5.80",
2366
- "@volter/editor-xstate": "0.5.80",
2367
- "@volter/editor-blender": "0.1.20",
2368
- "@volter/dawproject": "0.5.80",
2369
- "@volter/editor-dawproject": "0.5.80",
2370
- "@volter/blender-engine": "0.1.18",
2371
- "@volter/editor-project": "0.5.80",
2372
- "@volter/editor-sdk": "0.5.80",
2373
- "@volter/editor-live": "0.5.80",
2374
- "@volter/game-live": "0.5.80",
2362
+ "@volter/editor-core": "0.5.82",
2363
+ "@volter/editor-game": "0.5.82",
2364
+ "@volter/editor-react": "0.5.82",
2365
+ "@volter/editor-threejs": "0.5.82",
2366
+ "@volter/editor-xstate": "0.5.82",
2367
+ "@volter/editor-blender": "0.1.22",
2368
+ "@volter/dawproject": "0.5.82",
2369
+ "@volter/editor-dawproject": "0.5.82",
2370
+ "@volter/blender-engine": "0.1.20",
2371
+ "@volter/editor-project": "0.5.82",
2372
+ "@volter/editor-sdk": "0.5.82",
2373
+ "@volter/editor-live": "0.5.82",
2374
+ "@volter/game-live": "0.5.82",
2375
2375
  "@modelcontextprotocol/sdk": "1.30.0",
2376
- "@volter/game-runtime": "0.5.80",
2377
- "@volter/threejs-runtime": "0.5.80",
2376
+ "@volter/game-runtime": "0.5.82",
2377
+ "@volter/threejs-runtime": "0.5.82",
2378
2378
  undici: "7.29.1",
2379
2379
  typescript: "5.9.3",
2380
2380
  "@colyseus/schema": "^4.0.14",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@volter/game-editor",
3
3
  "author": "Volter AI, Inc.",
4
- "version": "0.5.80",
4
+ "version": "0.5.82",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -50,22 +50,22 @@
50
50
  }
51
51
  },
52
52
  "dependencies": {
53
- "@volter/editor-core": "0.5.80",
54
- "@volter/editor-game": "0.5.80",
55
- "@volter/editor-react": "0.5.80",
56
- "@volter/editor-threejs": "0.5.80",
57
- "@volter/editor-xstate": "0.5.80",
58
- "@volter/editor-blender": "0.1.20",
59
- "@volter/dawproject": "0.5.80",
60
- "@volter/editor-dawproject": "0.5.80",
61
- "@volter/blender-engine": "0.1.18",
62
- "@volter/editor-project": "0.5.80",
63
- "@volter/editor-sdk": "0.5.80",
64
- "@volter/editor-live": "0.5.80",
65
- "@volter/game-live": "0.5.80",
53
+ "@volter/editor-core": "0.5.82",
54
+ "@volter/editor-game": "0.5.82",
55
+ "@volter/editor-react": "0.5.82",
56
+ "@volter/editor-threejs": "0.5.82",
57
+ "@volter/editor-xstate": "0.5.82",
58
+ "@volter/editor-blender": "0.1.22",
59
+ "@volter/dawproject": "0.5.82",
60
+ "@volter/editor-dawproject": "0.5.82",
61
+ "@volter/blender-engine": "0.1.20",
62
+ "@volter/editor-project": "0.5.82",
63
+ "@volter/editor-sdk": "0.5.82",
64
+ "@volter/editor-live": "0.5.82",
65
+ "@volter/game-live": "0.5.82",
66
66
  "@modelcontextprotocol/sdk": "1.30.0",
67
- "@volter/game-runtime": "0.5.80",
68
- "@volter/threejs-runtime": "0.5.80",
67
+ "@volter/game-runtime": "0.5.82",
68
+ "@volter/threejs-runtime": "0.5.82",
69
69
  "undici": "7.29.1",
70
70
  "typescript": "5.9.3",
71
71
  "@colyseus/schema": "^4.0.14",