@volter/game-editor 0.5.91 → 0.5.92
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.
- package/BUNDLED_NOTICES +22 -22
- package/catalog/entries/blender.json +2 -2
- package/catalog/entries/music.json +2 -2
- package/dist/.vite/manifest.json +2133 -2133
- package/dist/assets/{AssetBudgetPanel-DoHols3L.js → AssetBudgetPanel-DeJukdzT.js} +3 -3
- package/dist/assets/{AudioViewer-DJpWQMh1.js → AudioViewer-m9jtkgYo.js} +1 -1
- package/dist/assets/{CanvasBoardDocument-DUkSFZ3M.js → CanvasBoardDocument-DooBGHPq.js} +1 -1
- package/dist/assets/{CanvasSceneViewport-lY7d92L2.js → CanvasSceneViewport-CoFzzJfs.js} +1 -1
- package/dist/assets/{ColorInput-7cF4Leq3.js → ColorInput-NuZ1WtIR.js} +1 -1
- package/dist/assets/{ColorPicker-B2gSkOna.js → ColorPicker-DYngmfYK.js} +1 -1
- package/dist/assets/{EntityModelDocument-DFLHmO4x.js → EntityModelDocument-P3FihIlT.js} +1 -1
- package/dist/assets/{EnvironmentAssetDocument-C_10a-a0.js → EnvironmentAssetDocument-UW9Fz8gy.js} +1 -1
- package/dist/assets/{GameplaySessionTimeline-BMz5GHq5.js → GameplaySessionTimeline-CPMUudKc.js} +1 -1
- package/dist/assets/{ImageViewer-CEtC82uC.js → ImageViewer-C2TMh_cS.js} +1 -1
- package/dist/assets/InspectorObjectPreview-K6qqzlCF.js +1 -0
- package/dist/assets/{JsonAssetDocument-BjmItF9c.js → JsonAssetDocument-ChhlRvdh.js} +1 -1
- package/dist/assets/{LiveModuleDocument-DxsfqWPz.js → LiveModuleDocument-BBpws-_t.js} +1 -1
- package/dist/assets/{LutAssetDocument-BWgoofXc.js → LutAssetDocument-DYvPXEBg.js} +1 -1
- package/dist/assets/{ModelAssetDocument-CCOUnfNZ.js → ModelAssetDocument-OhbJGtHY.js} +1 -1
- package/dist/assets/{NonThreeAuthoringBootstrap-U8pDO_5y.js → NonThreeAuthoringBootstrap-DACaW5Vs.js} +1 -1
- package/dist/assets/{Object3DDocumentToolbar-CJE4T3cC.js → Object3DDocumentToolbar-CW5xzjh7.js} +1 -1
- package/dist/assets/Object3DDocumentViewport-C6qwIfnP.js +2 -0
- package/dist/assets/{Object3DPreview-CbcdszHX.js → Object3DPreview-DtiKkA9J.js} +1 -1
- package/dist/assets/{OnlineAssetDetail-BaW-VQoM.js → OnlineAssetDetail-CW7WV3OO.js} +1 -1
- package/dist/assets/{PlayBar-Dt55-XQi.js → PlayBar-B_Lni0-H.js} +1 -1
- package/dist/assets/{QuarksAssetDocument-B6NS06Qk.js → QuarksAssetDocument-CG9QU-_U.js} +1 -1
- package/dist/assets/{ReactCanvasControls-B3DU4o7S.js → ReactCanvasControls-CVmKmPCB.js} +1 -1
- package/dist/assets/{RootSelectionOverlay-DGhqE3ru.js → RootSelectionOverlay-BBPSUpGw.js} +1 -1
- package/dist/assets/{ShaderAssetDocument-C6ew-WgT.js → ShaderAssetDocument-Cf8KU6yA.js} +1 -1
- package/dist/assets/{ShadowEditor-BTWOn0NH.js → ShadowEditor-axHBX3ZT.js} +1 -1
- package/dist/assets/{SourceAssetViewer-BHIPNJyW.js → SourceAssetViewer-mb-qv2H4.js} +1 -1
- package/dist/assets/{StageHost-CgQvlJ6q.js → StageHost-CltfMwcG.js} +2 -2
- package/dist/assets/{StoryPreviewMount-BODkiKx5.js → StoryPreviewMount-CN9Jjj_B.js} +1 -1
- package/dist/assets/{ThreeBoardDocument-2Hape4Gq.js → ThreeBoardDocument-CP2sAfro.js} +2 -2
- package/dist/assets/{ThreeIsolationSceneContent-DmeEOKni.js → ThreeIsolationSceneContent-CHm48Iwq.js} +1 -1
- package/dist/assets/{ToolObject3DPreview-BLUyNI0a.js → ToolObject3DPreview-BMGfohlr.js} +1 -1
- package/dist/assets/{Toolbar-BaTvvAae.js → Toolbar-By5RmjZA.js} +1 -1
- package/dist/assets/{TransientHint-Bf1GHsWL.js → TransientHint-DvlYI-GB.js} +1 -1
- package/dist/assets/{VideoViewer-D_aUwqjA.js → VideoViewer-C_Ypqrhs.js} +1 -1
- package/dist/assets/{ViewportShadingMenu-C3thhpMD.js → ViewportShadingMenu-DnqUmVm4.js} +1 -1
- package/dist/assets/{active-ingest-CPY5d7Ae.js → active-ingest-BEQcTdnB.js} +2 -2
- package/dist/assets/{animation-clock-BUG7-Hj6.js → animation-clock-DdJoDJut.js} +1 -1
- package/dist/assets/{animation-mixers.service-UqRHpBS5.js → animation-mixers.service-Cwwx5Rk1.js} +1 -1
- package/dist/assets/{animation-timeline.utility-vjZNsvAC.js → animation-timeline.utility-COGKHdbx.js} +1 -1
- package/dist/assets/{asset-budget-asset.menu-Btshx1dW.js → asset-budget-asset.menu-Dnh4Og48.js} +1 -1
- package/dist/assets/{asset-budget.action-Jb6hBA39.js → asset-budget.action-CWMJY1nK.js} +1 -1
- package/dist/assets/{asset-budget.document-BFWXwNI0.js → asset-budget.document-D0eHpYEa.js} +1 -1
- package/dist/assets/{asset-budget.menu-BTPSwcMa.js → asset-budget.menu-BEOvkmkJ.js} +1 -1
- package/dist/assets/{asset-editor-persistence-CL-0YalT.js → asset-editor-persistence-Bk2mBIUR.js} +1 -1
- package/dist/assets/{asset-loaders-nDvCLina.js → asset-loaders-CtCb12Wy.js} +1 -1
- package/dist/assets/{asset-preview-BqLvTtnb.js → asset-preview-DLr3X2Ff.js} +1 -1
- package/dist/assets/{audio-unlock.service-DnCb3tjQ.js → audio-unlock.service-g6nZnyKt.js} +1 -1
- package/dist/assets/{audio.utility-DlkiEBfp.js → audio.utility-qHaPxVG5.js} +1 -1
- package/dist/assets/autoplay.service-CQBU7J4-.js +1 -0
- package/dist/assets/{babylon-authoring-adapter-CnxkYjhp.js → babylon-authoring-adapter-Bflf5oll.js} +1 -1
- package/dist/assets/{binding-resolver-cWcQuwXj.js → binding-resolver-Cp64QEEm.js} +2 -2
- package/dist/assets/{blender-node-editor.document-DIAjTz4F.js → blender-node-editor.document-BS6XiYdy.js} +1 -1
- package/dist/assets/{blender-properties-tab-DXuz6Cpg.js → blender-properties-tab-DPGcP6sE.js} +1 -1
- package/dist/assets/{blender-runtime-host-CJwNrADC.js → blender-runtime-host-CbZll4j6.js} +1 -1
- package/dist/assets/{blender-runtime-skin-6IzekhAd.js → blender-runtime-skin-CU4ON8U6.js} +2 -2
- package/dist/assets/{blender-runtime.document-Rf7NwTan.js → blender-runtime.document-DFk6LfKL.js} +2 -2
- package/dist/assets/{blender-screenshot.menu-CZagx_wX.js → blender-screenshot.menu-Zh-gSLyF.js} +1 -1
- package/dist/assets/{blender-timeline.document-DzhgQIDL.js → blender-timeline.document-DNGYxSVR.js} +1 -1
- package/dist/assets/{blender-uv-editor.document-ClearI2D.js → blender-uv-editor.document-DPeAgCdu.js} +1 -1
- package/dist/assets/{blender-version.status-BkFPoDDf.js → blender-version.status-Csf1NdCu.js} +1 -1
- package/dist/assets/{blender.command-BrtEn062.js → blender.command-zra5rClU.js} +1 -1
- package/dist/assets/{board-guides-D-k2cJcJ.js → board-guides-Dr7UmPbr.js} +1 -1
- package/dist/assets/{bridge.command-CgLcpLfB.js → bridge.command-Bx4V0CGQ.js} +3 -3
- package/dist/assets/{browserAll-CGgcubIt.js → browserAll-Dq7w5Sua.js} +1 -1
- package/dist/assets/{build-player.document-DhIDZKN-.js → build-player.document-CNQbxiwV.js} +1 -1
- package/dist/assets/{build-profiles.document-3r5ZhcB2.js → build-profiles.document-BPB32ZWV.js} +1 -1
- package/dist/assets/{build-progress.status-B1PXTSq7.js → build-progress.status-rSsHAPQ2.js} +1 -1
- package/dist/assets/{build-session-ulklRzSk.js → build-session-DNW4mFav.js} +1 -1
- package/dist/assets/{build.action-B5miC2Fi.js → build.action-Dyk6sukW.js} +1 -1
- package/dist/assets/{build.command-Cys5G5ZA.js → build.command-BtNjabOw.js} +1 -1
- package/dist/assets/{build.header-BJLJN9mP.js → build.header-DcJSZtCO.js} +1 -1
- package/dist/assets/{build.menu-bi39YVfp.js → build.menu-NxQtwHgd.js} +1 -1
- package/dist/assets/{build.service-DC4h7GhW.js → build.service-7Up4tNeR.js} +1 -1
- package/dist/assets/{camera-B9Y3RW7X.js → camera-lGstadDR.js} +1 -1
- package/dist/assets/{camera-runtime.inspector-D22mhDzD.js → camera-runtime.inspector-DclViJea.js} +1 -1
- package/dist/assets/{canvas-design-mount-Bp3K3717.js → canvas-design-mount-eCCv2or-.js} +3 -3
- package/dist/assets/{canvas-entry-runtime-BHOqndB_.js → canvas-entry-runtime-BT12lNQT.js} +2 -2
- package/dist/assets/{canvas-preview-frames-2tJZVdS2.js → canvas-preview-frames-CIiSC8-I.js} +1 -1
- package/dist/assets/{canvas-story-capture.service-DANEGQnC.js → canvas-story-capture.service-DmVs5hJt.js} +2 -2
- package/dist/assets/{capability-coverage-BOaPg0KC.js → capability-coverage-D_4ewfIt.js} +1 -1
- package/dist/assets/{collaboration-presence-CaATXsiz.js → collaboration-presence-B6A41ctS.js} +1 -1
- package/dist/assets/{collider-DZkp1rvK.js → collider-UIoHvnAV.js} +1 -1
- package/dist/assets/{component-board.service-Bba7cD7r.js → component-board.service-BY1eTL_6.js} +2 -2
- package/dist/assets/{component-board.service-CwKm1aEc.js → component-board.service-Cqv0Cqk8.js} +2 -2
- package/dist/assets/{component-board.service-CDeqmtPt.js → component-board.service-ymaR5Gc6.js} +2 -2
- package/dist/assets/{component-contracts.service-kh4-IF8j.js → component-contracts.service-BnuCkosG.js} +1 -1
- package/dist/assets/{component-instance-root-JAQpC4Pi.js → component-instance-root-CPMZslj8.js} +1 -1
- package/dist/assets/{component-verbs.command-DNG8KytX.js → component-verbs.command-BE_JeIuS.js} +1 -1
- package/dist/assets/{component-verbs.service-CQCmsdNk.js → component-verbs.service-1VQEboWj.js} +1 -1
- package/dist/assets/{config-D8XyIZPl.js → config-BbIJR-Td.js} +2 -2
- package/dist/assets/{configurations-Bzh9kmrk.js → configurations-CAI-raMi.js} +1 -1
- package/dist/assets/{connection.status-ChQR4f5Y.js → connection.status-MORY2ecq.js} +1 -1
- package/dist/assets/{constraints.inspector-Ddo1UQNJ.js → constraints.inspector-yAWUn_QN.js} +1 -1
- package/dist/assets/{content-bounds-B_xPBrsP.js → content-bounds-DbjVwafW.js} +1 -1
- package/dist/assets/{contract-system-adapters-C1oaetXB.js → contract-system-adapters-B7HjmMU3.js} +1 -1
- package/dist/assets/{coverage.service-DIQXHW6Q.js → coverage.service-BpHkqGqx.js} +1 -1
- package/dist/assets/{create-runtime-BQdKNIfc.js → create-runtime-CMdnacgk.js} +1 -1
- package/dist/assets/{curve-BEKFgt87.js → curve-W-sfW-YV.js} +1 -1
- package/dist/assets/{data-asset-BZA163so.js → data-asset-BwavdNYa.js} +1 -1
- package/dist/assets/{data-ref-BUMaOgK6.js → data-ref-BKAuxnNn.js} +1 -1
- package/dist/assets/{debug-bridge-B8Do4Q6K.js → debug-bridge-Ce2BNh0c.js} +1 -1
- package/dist/assets/{debug-registry-CoiJ_gHM.js → debug-registry-Cs16f-aE.js} +1 -1
- package/dist/assets/{deferred-ingest-play-DJeWQ-He.js → deferred-ingest-play-i3TXIcol.js} +2 -2
- package/dist/assets/{design-time-canvas-mount-B_5sxSjq.js → design-time-canvas-mount-DRuLuHb8.js} +2 -2
- package/dist/assets/{design-time-layers-Bspf2qH5.js → design-time-layers-CIQmpekh.js} +1 -1
- package/dist/assets/{design-time-mount.service-BE5vpW1Y.js → design-time-mount.service-CVTv4ycX.js} +2 -2
- package/dist/assets/{design-time-mount.service-038G1MnB.js → design-time-mount.service-FXHDWVCG.js} +2 -2
- package/dist/assets/{design-time-react-mount--CifCE6t.js → design-time-react-mount-BctXdzCd.js} +1 -1
- package/dist/assets/{document-preview-three-D46Hv_l-.js → document-preview-three-B2MgbkoT.js} +1 -1
- package/dist/assets/{dom-authoring-adapter-CI_qQmaE.js → dom-authoring-adapter-DIVIU5iS.js} +1 -1
- package/dist/assets/{draco3d-FJXe8NCw.js → draco3d-DqB07Xwz.js} +1 -1
- package/dist/assets/{edit-mode-audio.service-qKdc6y7a.js → edit-mode-audio.service-BdMtawvV.js} +1 -1
- package/dist/assets/{edit-mode-authoring-C0sf0ewd.js → edit-mode-authoring-BYKTzHxo.js} +1 -1
- package/dist/assets/{edit-mode-networking.service-D-eLZBVJ.js → edit-mode-networking.service-BMgRT6VZ.js} +1 -1
- package/dist/assets/{editor-api-DeTJ2F2f.js → editor-api-MVTYddFN.js} +1 -1
- package/dist/assets/{editor-layers-B43PZgUF.js → editor-layers-DB2HoNYg.js} +1 -1
- package/dist/assets/{editor-shell-store-CW9Fjab9.js → editor-shell-store-B_3I8rkh.js} +1 -1
- package/dist/assets/{entity-object-C40NpVSX.js → entity-object-Btp4Cm7a.js} +1 -1
- package/dist/assets/{extend-CB1ggOZp.js → extend-BBPSDBSg.js} +1 -1
- package/dist/assets/{fork-menu-ByAv7gfK.js → fork-menu-igGxVTU5.js} +1 -1
- package/dist/assets/{frame-debugger-store-BOL6rL6i.js → frame-debugger-store-CGTQsnpN.js} +1 -1
- package/dist/assets/{game-contract-seams-Dq1YiGya.js → game-contract-seams-CqP5-7QG.js} +1 -1
- package/dist/assets/{game-css-scope-transform-zF8z1rZz.js → game-css-scope-transform-BLyGDsn5.js} +1 -1
- package/dist/assets/{game-document.service-DlSkuYvA.js → game-document.service-BMXhV4k0.js} +1 -1
- package/dist/assets/{game-eval.command-Cnr70bCU.js → game-eval.command-BBdWh7r4.js} +1 -1
- package/dist/assets/{game-module-access-Pz5cgPiz.js → game-module-access-DB-3_dQL.js} +1 -1
- package/dist/assets/{game-network-D8nKKSRC.js → game-network-CjxVSmyx.js} +3 -3
- package/dist/assets/{gameplay-export-FFcX1OzU.js → gameplay-export-CKg7Tr5V.js} +1 -1
- package/dist/assets/{gameplay-replay-CVwLaTax.js → gameplay-replay-BKk0MkWw.js} +1 -1
- package/dist/assets/{gameplay.command-64STQYm4.js → gameplay.command-BzuqC2M4.js} +1 -1
- package/dist/assets/{generation-jobs-BOOUx41p.js → generation-jobs-Bc9aPUjo.js} +1 -1
- package/dist/assets/{generation.service-BJn-hOAW.js → generation.service-Ctq8vDs8.js} +1 -1
- package/dist/assets/{generations-BuBWfmYF.js → generations-v6wlWOxc.js} +1 -1
- package/dist/assets/{generations.status-Cw7FBmHO.js → generations.status-D23nC6DT.js} +1 -1
- package/dist/assets/{hierarchy-marks-r1SCnl92.js → hierarchy-marks-BUq91mYX.js} +1 -1
- package/dist/assets/{hosted-asset-materialization-CCfM8rX8.js → hosted-asset-materialization-B1mfxDMA.js} +1 -1
- package/dist/assets/{index-tsU_SOUL.js → index-BWkADFm_.js} +1 -1
- package/dist/assets/{index-DNuUwvUR.js → index-Bi11wn2O.js} +1 -1
- package/dist/assets/{index-BTlpcjdl.js → index-COGWs_Hz.js} +2 -2
- package/dist/assets/{index-CiKYIRrk.js → index-CPn7DYN1.js} +1 -1
- package/dist/assets/{index-C5X85WM3.js → index-C_Y18gyB.js} +1 -1
- package/dist/assets/{index-DnZE2Fb2.js → index-Cq5IOeJJ.js} +1 -1
- package/dist/assets/{index-CRFTAXpT.js → index-Da25n7KE.js} +1 -1
- package/dist/assets/{index-EO6Vl92s.js → index-DyTgGJaV.js} +265 -265
- package/dist/assets/{index-CDTbPbQM.js → index-YE-BLlXn.js} +1 -1
- package/dist/assets/{inference-diagnostics-18bkEAju.js → inference-diagnostics--P59uVfZ.js} +1 -1
- package/dist/assets/{ingest-boot-viewport-BuSUroou.js → ingest-boot-viewport-CG06rhnI.js} +1 -1
- package/dist/assets/{ingest-siblings-B3ExLPmT.js → ingest-siblings-lud-fBi3.js} +1 -1
- package/dist/assets/{ingest-source-persistence-C2eN6TUG.js → ingest-source-persistence-Dlr1NuFz.js} +1 -1
- package/dist/assets/{ingest.service-DPCT2mkC.js → ingest.service--OsL8JsR.js} +1 -1
- package/dist/assets/{inspect-BqpAh85y.js → inspect-DuE1D5UR.js} +1 -1
- package/dist/assets/instances.command-Dzidr8Yl.js +1 -0
- package/dist/assets/{json-history-resource-BjCvVkMa.js → json-history-resource-IKUe_-vd.js} +1 -1
- package/dist/assets/{layered-pick-Ciu7uLFh.js → layered-pick-BtIxP5aF.js} +1 -1
- package/dist/assets/{light-CXcgEBDG.js → light-CWgqDXEE.js} +1 -1
- package/dist/assets/{live-project-verbs-BBbF8usb.js → live-project-verbs-CHp_aQ8s.js} +1 -1
- package/dist/assets/{machine.document-Bdci5A4S.js → machine.document-DnI8qlb5.js} +1 -1
- package/dist/assets/{machines.finder-CvEKAnGk.js → machines.finder-bsxZB24L.js} +1 -1
- package/dist/assets/{material-factory-Df67vZ1z.js → material-factory-Bl4Vy50a.js} +1 -1
- package/dist/assets/{material-ClpgTT47.js → material-t5AUiIjm.js} +1 -1
- package/dist/assets/{mesh-DkaFE4sY.js → mesh-D0ARI7DT.js} +1 -1
- package/dist/assets/{model-asset-sections.service-CBOHxNFe.js → model-asset-sections.service-BcfL914J.js} +1 -1
- package/dist/assets/{model-inspection-DcL5cH7Y.js → model-inspection-BinpX_8X.js} +1 -1
- package/dist/assets/{model-thumbnail-C6YzkBEi.js → model-thumbnail-D5m5B4yc.js} +1 -1
- package/dist/assets/{models.finder-DfEs64WT.js → models.finder-BbLyybE3.js} +1 -1
- package/dist/assets/{module-mode-f-SD3z04.js → module-mode-CX71o-Qn.js} +2 -2
- package/dist/assets/{mount-canvas-ingest-root-BnxcPl2U.js → mount-canvas-ingest-root-BL4ma7EJ.js} +2 -2
- package/dist/assets/{mount-dom-ingest-root-CfwImvJz.js → mount-dom-ingest-root-BFN7fuIH.js} +2 -2
- package/dist/assets/{mount-ingest-root-Dh6Z1uso.js → mount-ingest-root-CCtls9Pm.js} +2 -2
- package/dist/assets/{mount-manifest-CAxRLPYT.js → mount-manifest-CesgcqbR.js} +1 -1
- package/dist/assets/{mount-three-ingest-root-CoqxTpZB.js → mount-three-ingest-root-CO7xNkMs.js} +1 -1
- package/dist/assets/{mounted-authoring-DfEm9qgt.js → mounted-authoring-D5zJIfVC.js} +1 -1
- package/dist/assets/{mounted-story-viewport-source-WBFaoqod.js → mounted-story-viewport-source-Cacn-FrZ.js} +1 -1
- package/dist/assets/{native-debug-module-piwWLOP6.js → native-debug-module-Cexnkzpz.js} +1 -1
- package/dist/assets/{navigation-DYa_HSby.js → navigation-C04dv_AE.js} +1 -1
- package/dist/assets/{navmesh.menu-B0MJEIPE.js → navmesh.menu-BR3qfEFi.js} +1 -1
- package/dist/assets/{navmesh.service-BpsPIRLZ.js → navmesh.service-cZZp_aWp.js} +1 -1
- package/dist/assets/network-observer.service-DbrkhWzR.js +1 -0
- package/dist/assets/{network.utility-DMr-AxKs.js → network.utility-DUizYX_I.js} +1 -1
- package/dist/assets/{object3d-document-session-registry-3YUZT4RT.js → object3d-document-session-registry-DkPO8z-D.js} +2 -2
- package/dist/assets/{oid-transform-DsAJ1P8o.js → oid-transform-CTTG13hx.js} +1 -1
- package/dist/assets/{particles-vZ9UmSDz.js → particles-Cl0uw7lL.js} +1 -1
- package/dist/assets/{pixi-authoring-adapter-QT0kN-JP.js → pixi-authoring-adapter-Bqfxw_3m.js} +1 -1
- package/dist/assets/{pixi-live-write-target-DM9cdS1_.js → pixi-live-write-target-DBVljmfv.js} +1 -1
- package/dist/assets/{play.command-DH2eNjdZ.js → play.command-BPWKJOEz.js} +2 -2
- package/dist/assets/{presentation-VcgXp-GO.js → presentation-BmRLRj9u.js} +1 -1
- package/dist/assets/{product-x_cfmfQ9.js → product-CkPQ3Ux6.js} +1 -1
- package/dist/assets/{profiler.action-C3xlnyom.js → profiler.action-DJPQHO0O.js} +1 -1
- package/dist/assets/{profiler.menu-DSUi8xT3.js → profiler.menu-DWjSnHVe.js} +1 -1
- package/dist/assets/{profiler.utility-BRSMJoGZ.js → profiler.utility-Y6h6m2t-.js} +1 -1
- package/dist/assets/{project-authoring-session-CwEQV0bP.js → project-authoring-session-DBF7pYCM.js} +2 -2
- package/dist/assets/{properties-bone-constraints.inspector-Ct1jO5Ue.js → properties-bone-constraints.inspector-DEdkTEo5.js} +1 -1
- package/dist/assets/{properties-bone.inspector-DxGQlndA.js → properties-bone.inspector-H-BBVZ8o.js} +1 -1
- package/dist/assets/{properties-collection.inspector-lK30X7Jh.js → properties-collection.inspector-BcsCcAvS.js} +1 -1
- package/dist/assets/{properties-constraints.inspector-Da8piE2V.js → properties-constraints.inspector-CUu-cNQ6.js} +1 -1
- package/dist/assets/{properties-data.inspector-WI4fuv2D.js → properties-data.inspector-BUel_GUU.js} +1 -1
- package/dist/assets/{properties-material.inspector-CQwIjVw1.js → properties-material.inspector-CIDoVmLo.js} +1 -1
- package/dist/assets/{properties-modifiers.inspector-BzQAh_u0.js → properties-modifiers.inspector--4LrHaeK.js} +1 -1
- package/dist/assets/{properties-object.inspector-Du6jNcII.js → properties-object.inspector-B8EgTfAi.js} +1 -1
- package/dist/assets/{properties-output.inspector-BQzIXPdl.js → properties-output.inspector-De86chrb.js} +1 -1
- package/dist/assets/{properties-particles.inspector-C-lSFNSf.js → properties-particles.inspector-Tcr6I9r6.js} +1 -1
- package/dist/assets/{properties-physics.inspector-CwC0aupw.js → properties-physics.inspector-B1e-ODZG.js} +1 -1
- package/dist/assets/{properties-render.inspector-D0P3nYYJ.js → properties-render.inspector-C8UodgyN.js} +1 -1
- package/dist/assets/{properties-scene.inspector-bM362PAU.js → properties-scene.inspector-D51KNWsk.js} +1 -1
- package/dist/assets/{properties-texture.inspector-8ucuWCLj.js → properties-texture.inspector-BclKARti.js} +1 -1
- package/dist/assets/{properties-view-layer.inspector-DWOu3YE3.js → properties-view-layer.inspector-BzRfWdvM.js} +1 -1
- package/dist/assets/{properties-world.inspector-BDTb__xL.js → properties-world.inspector-XxcFLmWg.js} +1 -1
- package/dist/assets/{r3f-design-session-gQuaJFCS.js → r3f-design-session-_2tBNT-r.js} +2 -2
- package/dist/assets/{r3f-physics-binding-CFwn2dZ0.js → r3f-physics-binding-DyvJAWJ4.js} +1 -1
- package/dist/assets/{r3f-source-authoring-adapter-DhFdCSs7.js → r3f-source-authoring-adapter-Ds3u5Oet.js} +1 -1
- package/dist/assets/{react-canvas-navigation-VKHmF9L9.js → react-canvas-navigation-DDNw2mVf.js} +1 -1
- package/dist/assets/{react-inspector.service-DheFnb_w.js → react-inspector.service-BOa9W_rc.js} +1 -1
- package/dist/assets/{react-story-board-BdHhG7gL.js → react-story-board-DnBISTPF.js} +1 -1
- package/dist/assets/{react-three-rapier.esm-W_y4UeT-.js → react-three-rapier.esm-C7mV19Rd.js} +1 -1
- package/dist/assets/{react-world-authoring-adapter-Cey0R-Ml.js → react-world-authoring-adapter-COQGilV0.js} +1 -1
- package/dist/assets/{realm-services-Bw73w74M.js → realm-services-BVbgboYj.js} +1 -1
- package/dist/assets/{reflection-probe-capture.inspector-Dqj4TwMY.js → reflection-probe-capture.inspector-9PURKnEk.js} +1 -1
- package/dist/assets/{registry-DCdpQPdB.js → registry-BKnWLREo.js} +1 -1
- package/dist/assets/{relative-import-specifier-DjG-Lv03.js → relative-import-specifier-DSTZtgN9.js} +1 -1
- package/dist/assets/{render-env-D12b4e03.js → render-env-B-xiPHul.js} +1 -1
- package/dist/assets/{render-features-w9Z-Cv_p.js → render-features-D6cEaZG_.js} +1 -1
- package/dist/assets/{render-settings-CGDwkhhL.js → render-settings-7qvwHFf7.js} +1 -1
- package/dist/assets/{resolve-three-Bl4aEdGL.js → resolve-three-BD3-wAF-.js} +3 -3
- package/dist/assets/{root-seam-contract-Dx597Ute.js → root-seam-contract-Dc0xW5J5.js} +1 -1
- package/dist/assets/{run-selection-D-nxwjch.js → run-selection-_aAcIhA1.js} +1 -1
- package/dist/assets/{scene-capture-BYzNQlcZ.js → scene-capture-dVfR7MjE.js} +1 -1
- package/dist/assets/{scene-document.service-DvdbtjUB.js → scene-document.service-CnUCT9fC.js} +2 -2
- package/dist/assets/{scene-framing-zyo6Dgey.js → scene-framing-C7gr65sn.js} +1 -1
- package/dist/assets/{seeded-random-BcjdE8-O.js → seeded-random-C1JwJC9g.js} +1 -1
- package/dist/assets/{setup-renderer-BoEjWIJ6.js → setup-renderer-CRrjb8S9.js} +1 -1
- package/dist/assets/{source-object3d-authoring-adapter-D-mc1Hsq.js → source-object3d-authoring-adapter-CJ9_kgH4.js} +1 -1
- package/dist/assets/{source-persistence-backend-DPS956_W.js → source-persistence-backend-BdjiG8o9.js} +1 -1
- package/dist/assets/{stage-keyboard-DD-47U0X.js → stage-keyboard-CtMpQmTO.js} +1 -1
- package/dist/assets/{stage-overlay-set-jLin7LCZ.js → stage-overlay-set-CL7TBswp.js} +1 -1
- package/dist/assets/{stage-presence-markers-BzL60lxC.js → stage-presence-markers-Dkrf-OpF.js} +1 -1
- package/dist/assets/{stage-transform-tools-CXEtn6e_.js → stage-transform-tools-IQWWdhuo.js} +1 -1
- package/dist/assets/{standard-viewport-dressing-DzgsLMqH.js → standard-viewport-dressing-TKOcIR28.js} +1 -1
- package/dist/assets/{state-watch.action-C0r205X2.js → state-watch.action-Py4YF3Vd.js} +1 -1
- package/dist/assets/{state-watch.menu-CIOq9XcQ.js → state-watch.menu-D7XAVt6T.js} +1 -1
- package/dist/assets/{state-watch.utility-B5Mps4k8.js → state-watch.utility-CdT0mIIq.js} +1 -1
- package/dist/assets/{story-capture-BL_OEjAJ.js → story-capture-D_XIHNG7.js} +1 -1
- package/dist/assets/{story-documents-uyxMmUzs.js → story-documents-CRrYBLbv.js} +1 -1
- package/dist/assets/{story-documents.service-L9mW5dVf.js → story-documents.service-C-IYLdxc.js} +1 -1
- package/dist/assets/{story-documents.service-Cu17YnfS.js → story-documents.service-CCMjjodb.js} +1 -1
- package/dist/assets/{story-media-presence-CsYCXCgg.js → story-media-presence-Bw1o6E62.js} +1 -1
- package/dist/assets/{story-pixi-preview-BaS3gW36.js → story-pixi-preview-5WqHTgoT.js} +1 -1
- package/dist/assets/{story-presentation-Inb0tF8V.js → story-presentation-B4xwjorS.js} +1 -1
- package/dist/assets/{story-three-preview-N78COIhD.js → story-three-preview-CfJiHAyJ.js} +2 -2
- package/dist/assets/{studio-environment-BRMTYTp1.js → studio-environment-BTgaAUb4.js} +1 -1
- package/dist/assets/{surface-state-l4D0tVlT.js → surface-state-mdcl-Ho-.js} +1 -1
- package/dist/assets/{syntactic-prop-specs-DOQMV1SJ.js → syntactic-prop-specs-BcjoSr_8.js} +1 -1
- package/dist/assets/{team-playtest.service-CHIX8ZaT.js → team-playtest.service-gdwlVptm.js} +1 -1
- package/dist/assets/{three-DItubEyv.js → three-CnFqjv_X.js} +1 -1
- package/dist/assets/{three-authoring-adapter-jGnbMYIc.js → three-authoring-adapter-DwCMnivG.js} +1 -1
- package/dist/assets/three-authoring.service-D6PIh-T5.js +2 -0
- package/dist/assets/{three-ingest-runtime-DlApOywz.js → three-ingest-runtime-2OKIJvOp.js} +1 -1
- package/dist/assets/{three-integration-lFHyckTb.js → three-integration-Bc5bObpY.js} +2 -2
- package/dist/assets/three-integration.service-DKjGhYsk.js +1 -0
- package/dist/assets/{three-projection-core-Bsu421K7.js → three-projection-core-BH7eWjmL.js} +1 -1
- package/dist/assets/{three-state-15gXjQ51.js → three-state-Beoor2qe.js} +1 -1
- package/dist/assets/{three-story-capture.service-B369fV1j.js → three-story-capture.service-D_d_HJUY.js} +2 -2
- package/dist/assets/{three-story-model-D8xXaW4_.js → three-story-model-m26ngwoa.js} +1 -1
- package/dist/assets/{three-viewport-presentation-DlCyoe_E.js → three-viewport-presentation-Dv139ZhF.js} +1 -1
- package/dist/assets/{transform-mode-request-BT4Zmx_G.js → transform-mode-request-DP_ObjSV.js} +1 -1
- package/dist/assets/{transport-strip-DHbAk_5x.js → transport-strip-0nwKohqK.js} +1 -1
- package/dist/assets/transport.header-CbCAtj5s.js +1 -0
- package/dist/assets/{tuples-BcU64Mu6.js → tuples-DhXwxLo-.js} +1 -1
- package/dist/assets/{ui-board-document-CptsO8E6.js → ui-board-document-iOzWO-IY.js} +2 -2
- package/dist/assets/{user-data-DnahhlAD.js → user-data-W4XQSuJh.js} +1 -1
- package/dist/assets/{utility-view-state-GfzV3cfg.js → utility-view-state-VNkuk8W4.js} +1 -1
- package/dist/assets/{viewport-door-Dbl8EH3p.js → viewport-door-BAOv87Fs.js} +1 -1
- package/dist/assets/{viewport-root-presentation-CG43sAj5.js → viewport-root-presentation-Ba-vx6UG.js} +1 -1
- package/dist/assets/{viewport-surface-status-C9vuKKQB.js → viewport-surface-status-qvgNJYzx.js} +1 -1
- package/dist/assets/{webworkerAll-DE92JZIw.js → webworkerAll-CiO0kb-H.js} +1 -1
- package/dist/assets/{workspace-arrangement-COs530TA.js → workspace-arrangement-Dl7Q2V4T.js} +1 -1
- package/dist/assets/{world-documents-80AAIyS9.js → world-documents-DNFr2sNk.js} +1 -1
- package/dist/assets/{world-root-stage-binding-umHFwInD.js → world-root-stage-binding-DMyedsHY.js} +1 -1
- package/dist/assets/{xstate-animation-binding-_aMqz-nR.js → xstate-animation-binding-bEAsNebg.js} +1 -1
- package/dist/assets/{xstate-animation-meta-CzxfXjaY.js → xstate-animation-meta-NEG890lY.js} +1 -1
- package/dist-node/cli.js +16 -16
- package/package.json +16 -16
- package/dist/assets/InspectorObjectPreview-CO8cF8ht.js +0 -1
- package/dist/assets/Object3DDocumentViewport-CmgIuzQv.js +0 -2
- package/dist/assets/autoplay.service-CJv46a1s.js +0 -1
- package/dist/assets/instances.command-BTMfzHFj.js +0 -1
- package/dist/assets/network-observer.service-CBgzPOhw.js +0 -1
- package/dist/assets/three-authoring.service-UK1utJDS.js +0 -2
- package/dist/assets/three-integration.service-CvbLexeR.js +0 -1
- package/dist/assets/transport.header-D6MQXDZh.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ab as a}from"./index-
|
|
1
|
+
import{ab as a}from"./index-DyTgGJaV.js";import{s as n,n as s}from"./command-results-CUQD49AB.js";import{g as m,a as p}from"./game-network-CjxVSmyx.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";import"./index-OZVqp6xS.js";import"./index-Da9JhEvW.js";import"./native-debug-module-Cexnkzpz.js";import"./native-entry-surface-BE8LJNdu.js";import"./debug-registry-Cs16f-aE.js";import"./contract-system-adapters-B7HjmMU3.js";import"./game-contract-seams-CqP5-7QG.js";import"./seeded-random-C1JwJC9g.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-CHp_aQ8s.js";import"./capability-coverage-D_4ewfIt.js";import"./edit-mode-authoring-BYKTzHxo.js";import"./json-history-resource-IKUe_-vd.js";import"./binding-resolver-Cp64QEEm.js";import"./adapter-surface-Y37Nzcyw.js";import"./structural-signature-Dc7skRiy.js";import"./webgl-frame-capture-DdJkM2mi.js";import"./realm-services-BVbgboYj.js";import"./canvas-entry-runtime-BT12lNQT.js";import"./three-ingest-runtime-2OKIJvOp.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-BEQcTdnB.js";import"./ingest-source-persistence-Dlr1NuFz.js";import"./pixi-story-model-DNkfnWUV.js";import"./surface-content-Dg9Kkazf.js";import"./viewport-root-presentation-Ba-vx6UG.js";import"./mounted-authoring-D5zJIfVC.js";import"./entity-object-Btp4Cm7a.js";import"./user-data-W4XQSuJh.js";import"./workspace-arrangement-Dl7Q2V4T.js";import"./three-contract-Dkt6PmWY.js";import"./three-CnFqjv_X.js";import"./editor-layers-DB2HoNYg.js";import"./component-instance-root-CPMZslj8.js";import"./viewport-editor-controls-BYaAZ_Ku.js";import"./three-authoring-adapter-DwCMnivG.js";import"./source-persistence-backend-BdjiG8o9.js";import"./three-projection-core-BH7eWjmL.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-DyvJAWJ4.js";import"./deferred-ingest-play-i3TXIcol.js";import"./rrweb-Cd2ifIRP.js";import"./react-world-authoring-adapter-COQGilV0.js";import"./board-guides-Dr7UmPbr.js";import"./relative-import-specifier-DSTZtgN9.js";import"./story-arg-descriptors-Ek86ExX7.js";import"./inspect-DuE1D5UR.js";import"./inference-diagnostics--P59uVfZ.js";import"./writer-tw6EcuVO.js";import"./three-state-Beoor2qe.js";import"./editor-shell-store-B_3I8rkh.js";import"./output-pass-HurwNl0G.js";import"./viewport-door-BAOv87Fs.js";import"./game-surface-defaults-D8S4cRxi.js";const Le="workspace.command",Ue={"list-gameplay-state":{derivedRefresh:"if-content-changed",handle:()=>{const e=a().debug;return e?{ok:!0,data:{providers:e.providers()}}:p()?{ok:!0,data:{providers:[]}}:s()}},"inspect-gameplay-state":{derivedRefresh:"if-content-changed",handle:e=>{const t=a().debug;if(!t)return p()?{ok:!0,data:{state:null}}:s();const r=e.keys;try{const o={};if(r&&r.length>0)for(const i of r)o[i]=t.state(i);else Object.assign(o,t.stateAll());return{ok:!0,data:{state:o}}}catch(o){return n(o)}}},"list-debug-commands":{derivedRefresh:"if-content-changed",handle:()=>{const e=a().debug;return e?{ok:!0,data:{commands:e.commands()}}:p()?{ok:!0,data:{commands:[]}}:s()}},"invoke-debug-command":{derivedRefresh:"always",handle:async e=>{const t=a().debug;if(!t)return p()?{ok:!1,error:`debug: no command registered under "${e.name}" — this game exposes no debug adapter`,data:{code:"DEBUG_COMMAND_NOT_REGISTERED",registered:[]}}:s();try{return{ok:!0,data:{result:await t.invoke(e.name,e.args??[])}}}catch(r){return n(r)}}},"inject-input":{derivedRefresh:"none",handle:e=>{const t=m();if(!t)return{ok:!1,error:"not in play mode — start play before injecting input"};let r;try{r=t.getInputTarget(e.worldId)}catch(o){return n(o)}if(!r)return{ok:!1,error:"this play session has no input door: no root entry exports `debug.input`"};try{if(e.kind==="action"){const i=e.atTick;return typeof i=="number"?(r.scheduleActionAtTick(i,e.action,e.value),{ok:!0,data:{scheduled:!0,tick:i}}):{ok:!0,data:r.setVirtualAction(e.action,e.value)}}const o=e.sourceId;switch(e.kind){case"axis":r.injectAxis(o,e.value);break;case"vector2":r.injectVector2(o,e.value);break;case"pointerDelta":r.injectPointerDelta(o,e.value);break;case"pointerPosition":r.injectPointerPosition(o,e.value);break;default:return{ok:!1,error:`unknown injection kind "${e.kind}"`}}return{ok:!0,data:{delivered:!0}}}catch(o){return n(o)}}},"set-time-scale":{derivedRefresh:"none",handle:e=>{const t=m();return t?(t.loop.timeScale=e.timeScale,{ok:!0,data:{timeScale:t.loop.timeScale}}):{ok:!1,error:"not in play mode — start play before setting time-scale"}}},"set-seed":{derivedRefresh:"none",handle:e=>{const t=m();return t?t.determinismDeclared?t.random?(t.random.reseed(e.seed),{ok:!0,data:{seed:t.random.seed}}):{ok:!1,error:"this play session has no first-party ctx.random to reseed"}:{ok:!1,error:"this project's manifest does not declare determinism.seededRandom — play.seed.set has no documented contract to reseed against (D15)",data:{code:"DETERMINISM_NOT_DECLARED"}}:{ok:!1,error:"not in play mode — start play before setting the seed"}}},"run-ticks":{derivedRefresh:"none",handle:async e=>{const t=m();if(!t)return{ok:!1,error:"not in play mode — start play before running ticks"};if(!t.runTicks)return{ok:!1,error:"this play session has no first-party Game to run ticks on",data:{code:"RUN_TICKS_UNAVAILABLE"}};try{const r=e.n,o=e.render;return t.runTicksSettled?await t.runTicksSettled(r,o?{render:o}:void 0):t.runTicks(r,o?{render:o}:void 0),{ok:!0}}catch(r){return n(r)}}}};export{Ue as commands,Le as point};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a3 as l,a4 as a,ac as c}from"./index-
|
|
1
|
+
import{a3 as l,a4 as a,ac as c}from"./index-DyTgGJaV.js";const g={version:1,jobs:[]};let u=g,i=null,s=0,o=!1;const r=new Set;function w(e,n=null){u=e,i=n,s++;for(const d of r)d()}function J(){return u}function v(){return i}function E(){return s}function y(e){return r.add(e),()=>r.delete(e)}function p(e){return e.status==="queued"||e.status==="running"}function h(e){return!p(e)&&(!e.readAt||Date.parse(e.readAt)<Date.parse(e.updatedAt))}function b(e){return e.filter(h).length}async function t(){try{const e=await fetch("/__editor/generations");w(await l(e,"Generation activity request failed"))}catch(e){i=e instanceof Error?e.message:String(e),s++;for(const n of r)n()}}async function G(){if(!o){o=!0;try{const e=await fetch("/__editor/generations/reconcile",{method:"POST"});a(e,"Generation reconciliation failed"),await t()}finally{o=!1}}}async function _(e){const n=await c(e.poll.tool,e.poll.input);if(!n.ok)throw new Error(n.error.message);if(n.generationWarning)throw new Error(n.generationWarning);return await t(),await f(e.id),n.data}async function S(e){if(!e.accept)throw new Error("This completed generation has no project asset to add.");const n=await c(e.accept.tool,e.accept.input,{confirm:!0});if(!n.ok)throw new Error(n.error.message);if(n.generationWarning)throw new Error(n.generationWarning);await t(),await f(e.id)}async function f(e){const n=await fetch(`/__editor/generations/${encodeURIComponent(e)}/read`,{method:"POST"});a(n,"Mark generation read failed"),await t()}async function T(e){const n=await fetch(`/__editor/generations/${encodeURIComponent(e)}`,{method:"DELETE"});a(n,"Forget generation job failed"),await t()}function A(){t();const e=window.setInterval(()=>void t(),2e3);return()=>{window.clearInterval(e)}}export{b as a,p as b,S as c,v as d,h as e,T as f,J as g,A as h,_ as i,E as j,f as m,G as p,t as r,y as s};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jn as K,jo as Q,fc as I,dN as O,h2 as E,jp as Y,jq as A,aN as X,a6 as g,h4 as Z,fo as H,jr as ee,js as te,jt as w,ju as ne,jv as re,jw as oe,jx as ae,jy as se,jz as ie,bv as le,aL as h,hV as ce,eB as P,hF as R,bQ as B,Z as de,a7 as _,gi as ue,jA as me,jB as pe,jC as ge,g$ as ve,jD as fe,b7 as he,jE as xe,f6 as je,ad as ye,f8 as Ne}from"./index-EO6Vl92s.js";import{a as t}from"./jsx-runtime-DPjLkJKQ.js";import{r as u}from"./index-nmcBqr7Y.js";import{m as Ce}from"./model-thumbnail-C6YzkBEi.js";import"./index-CtzuWnCS.js";import{s as T,g as x,c as z,f as M,i as Ee,b as F,p as Se,r as J,d as ke,e as Te,m as $e,h as be,j as Ae,a as we}from"./generation-jobs-BOOUx41p.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./renderer-ownership-BovSEcLv.js";import"./studio-environment-BRMTYTp1.js";import"./user-data-DnahhlAD.js";import"./workspace-arrangement-COs530TA.js";import"./KTX2Loader-CaqVE6nY.js";import"./three.module-BLhyNg0e.js";import"./three.core-3arARmh6.js";import"./GLTFLoader-KeoruJgS.js";import"./BufferGeometryUtils-B22h7jo4.js";import"./environment-Dg-YaLsA.js";import"./RoomEnvironment-BkknvS_I.js";import"./EXRLoader-CITMBvGd.js";import"./HDRLoader-BTGuGhVo.js";function j(e){switch(e.status){case"queued":return"queued";case"running":return"running";case"failed":return"failed";case"cancelled":return"cancelled";default:return e.acceptedAt?"ready":e.accept?e.pollError?"save-failed":"saving":"no-asset"}}function L(e){const n=j(e);return n!=="queued"&&n!=="running"&&n!=="saving"}function U(e,n){return e.status==="succeeded"&&!!e.accept&&!e.acceptedAt&&!!(e.pollError??n)}const $={queued:"Queued",running:"Running",saving:"Saving","save-failed":"Couldn't save",ready:"In project","no-asset":"No file",failed:"Failed",cancelled:"Cancelled"},Re=new Map([...["png","jpg","jpeg","webp","gif","avif","svg","bmp"].map(e=>[e,"image"]),...["mp4","webm","ogv","mov","m4v"].map(e=>[e,"video"]),...["mp3","wav","ogg","oga","m4a","flac","aac"].map(e=>[e,"audio"]),...["glb","gltf","fbx","obj","stl","ply","dae","3ds","usdz","spz"].map(e=>[e,"model"])]);function De(e){const n=e.slice(e.lastIndexOf("/")+1).toLowerCase(),r=n.lastIndexOf(".");return r>0?n.slice(r+1):""}function q(e){return(e.outputPaths??[]).map(n=>{const r=K.find(o=>n.startsWith(`${o}/`)),a=r?Q(r,n.slice(r.length+1)):null;return{path:n,name:n.slice(n.lastIndexOf("/")+1),kind:Re.get(De(n))??"file",url:a}})}function D(e,n){const r=e.trim();return r.length<=n?r:`${r.slice(0,n-1).trimEnd()}…`}function C(e){const n=Oe(e);if(n)return n;const r=q(e);if(r.length===0)return D(e.label,64);const a=r[0],o=Ie(a.path);return r.length>1?o?`${o} · ${r.length} files`:`${r.length} files`:Ge.test(a.name)?o?`${o}/${a.name}`:D(e.label,64):a.name}const Ge=/^(image|video|audio|model|panorama|output)(-\d+)?\./;function Ie(e){const n=e.split("/").slice(-2,-1)[0];return n?/^[0-9a-f]{8,}$/i.test(n)||/^[0-9a-f-]{16,}$/i.test(n)?null:n:null}function Oe(e){const n=e.accept?.input;if(!n||typeof n!="object")return null;const r=n.outputName;return typeof r=="string"&&r.trim().length>0?r.trim():null}function Pe(e){for(const n of[e.accept?.input,e.poll.input]){const r=W(n,0);if(r)return r}return null}function W(e,n){if(n>3||typeof e!="object"||e===null)return null;const r=e,a=r.prompt;if(typeof a=="string"&&a.trim().length>0)return a.trim();for(const o of Object.values(r)){const l=W(o,n+1);if(l)return l}return null}function G(e){return e.operation}function Be(e){return e.mode==="managed"?"Volter subscription":e.mode==="direct"?"Your provider key":"Mock"}function _e(e){return e.route==="mock"?"Free · mock":e.route==="managed"?e.settledCredits!==void 0?`${e.settledCredits} credits`:e.estimatedCredits!==void 0?`Up to ${e.estimatedCredits} credits`:"Credit estimate unavailable":e.settledAmount!==void 0?`$${e.settledAmount.toFixed(3)}`:e.estimatedAmount!==void 0?`Up to $${e.estimatedAmount.toFixed(3)}`:"USD estimate unavailable"}function ze(e){return e.route==="mock"?!0:e.route==="managed"?e.settledCredits!==void 0:e.settledAmount!==void 0}function Me(e){const n=Math.floor((Date.now()-Date.parse(e))/6e4);if(!Number.isFinite(n)||n<1)return"just now";if(n<60)return`${n}m ago`;const r=Math.floor(n/60);if(r<24)return`${r}h ago`;const a=Math.floor(r/24);return a<7?`${a}d ago`:`${Math.floor(a/7)}w ago`}const S="generation:",Fe="generation:create";function Je(e){return e.route==="mock"?"Free mock":e.route==="managed"?e.settledCredits!==void 0?`${e.settledCredits} credits settled`:e.estimatedCredits!==void 0?`Up to ${e.estimatedCredits} credits`:"Volter subscription · estimate unavailable":e.settledAmount!==void 0?`$${e.settledAmount.toFixed(3)} settled`:e.estimatedAmount!==void 0?`Up to $${e.estimatedAmount.toFixed(3)}`:"BYOK · estimate unavailable"}function V(e){return I({id:`${S}${e.id}`,title:e.label,kind:"generation",workspaceRole:"authored-subject",provenance:{origin:`${e.provider}:${e.externalId}`},Content:qe,closeable:!0,presentation:()=>({kind:"generation",id:e.id})})}function k(){return I({id:Fe,title:"Create Asset",kind:"generation",workspaceRole:"workspace-task",provenance:{origin:"registered generation tools"},Content:Le,closeable:!0,presentation:()=>({kind:"generation",id:"create"})})}function Le(){u.useSyncExternalStore(O,E),u.useSyncExternalStore(Y,A,A);const e=ee(),[n,r]=u.useState(""),a=n.trim().toLowerCase(),o=E().filter(i=>i.point==="workspace.document"&&i.tool?.generation?.role==="submit").filter(i=>a?[i.title,i.tool?.generation?.provider,i.tool?.summary,i.tool?.description].filter(Boolean).some(c=>String(c).toLowerCase().includes(a)):!0),l=new Map;for(const i of o){const c=i.tool?.generation?.provider??"other";l.set(c,[...l.get(c)??[],i])}return t.jsxs("div",{className:"volter-tool-page","data-testid":"generation-create-catalog",children:[t.jsxs("header",{className:"volter-tool-header",children:[t.jsx("div",{className:"volter-tool-eyebrow",children:"Installed provider extensions"}),t.jsx("h2",{className:"volter-tool-title",children:"Create an asset"}),t.jsxs("p",{className:"volter-tool-description",children:["Choose a native provider operation. Mock, managed, and BYOK execution remain explicit in the operation you open. Current default: ",e.preferredRoute,"."]})]}),t.jsx(X,{type:"search","aria-label":"Search generation tools",placeholder:"Search operations or providers…",value:n,onChange:i=>r(i.target.value)}),[...l.entries()].map(([i,c])=>t.jsxs("section",{className:"volter-tool-card",children:[t.jsx("h3",{className:"volter-tool-section-title",children:i}),t.jsx("div",{className:"volter-generation-create-grid",children:c.map(m=>t.jsxs(g,{variant:"ghost",className:"volter-generation-create-card",onClick:()=>Z(m.id),children:[t.jsx("strong",{children:m.title}),t.jsx("span",{children:m.tool?.summary})]},m.id))})]},i)),o.length===0&&t.jsx("div",{className:"volter-generation-document-empty",children:"No installed generation operation matches this search."})]})}function Ue({job:e,result:n,documentId:r,active:a}){u.useSyncExternalStore(O,E),u.useSyncExternalStore(te,w,w);const o=ne(e.poll.tool,e,n);if(!o)return t.jsx("pre",{className:"volter-generation-native-result",children:JSON.stringify(n,null,2)});const l=o.Component;return t.jsx(re,{file:o.file,children:t.jsx(l,{tool:o.tool,contributionId:o.id,client:ie(),surfaces:oe,account:se(),play:ae(),documentId:r,active:a,job:e,result:n})})}function qe({documentId:e,active:n}){const{jobs:r}=u.useSyncExternalStore(T,x,x),a=e.startsWith(S)?e.slice(S.length):e,o=r.find(d=>d.id===a),[l,i]=u.useState(),[c,m]=u.useState(!1),[s,p]=u.useState(null),[v,f]=u.useState(!1),y=async d=>{m(!0),p(null);try{i(await Ee(d))}catch(N){p(N instanceof Error?N.message:String(N))}finally{m(!1)}};if(u.useEffect(()=>{o&&y(o)},[o?.id,o?.status]),!o)return t.jsx("div",{className:"volter-generation-document-empty",children:"This generation is no longer in project activity."});const b=s??(j(o)==="save-failed"?`Could not save into the project: ${o.pollError}`:null);return t.jsxs("div",{className:"volter-generation-document","data-status":o.status,children:[t.jsxs("header",{className:"volter-generation-document-header",children:[t.jsxs("div",{children:[t.jsxs("div",{className:"volter-tool-eyebrow",children:[o.provider," · ",o.operation]}),t.jsx("h2",{className:"volter-tool-title",children:o.label}),t.jsxs("div",{className:"volter-generation-job-meta",children:[$[j(o)]," · ",Je(o.billing)]})]}),t.jsxs("div",{className:"volter-tool-actions",children:[t.jsx(g,{size:"compact",variant:"ghost",disabled:c,onClick:()=>void y(o),children:c?"Refreshing…":"Refresh"}),U(o,s)&&t.jsx(g,{size:"compact",variant:"primary",disabled:v,onClick:()=>{f(!0),p(null),z(o).catch(d=>p(d instanceof Error?d.message:String(d))).finally(()=>f(!1))},children:v?"Saving…":"Retry save"})]})]}),o.message&&t.jsx("div",{className:"volter-tool-status",children:o.message}),b&&t.jsx("div",{className:"volter-tool-status","data-tone":"error",role:"alert",children:b}),t.jsx("section",{className:"volter-generation-result","aria-label":"Generation result",children:l===void 0?t.jsx("div",{className:"volter-generation-document-empty",children:c?"Loading provider result…":"No provider result is available yet."}):t.jsx(Ue,{job:o,result:l,documentId:e,active:n})}),o.outputPaths&&o.outputPaths.length>0&&t.jsxs("section",{className:"volter-generation-output-paths",children:[t.jsx("strong",{children:"Project assets"}),o.outputPaths.map(d=>t.jsx("code",{children:d},d))]}),L(o)&&t.jsx("div",{className:"volter-generation-document-footer",children:t.jsx(g,{size:"compact",variant:"ghost",disabled:v,onClick:()=>{f(!0),M(o.id).then(()=>H(e)).catch(d=>p(d instanceof Error?d.message:String(d))).finally(()=>f(!1))},children:"Remove from activity"})})]})}function We({output:e,onOpen:n}){const r=e.url;if(r&&e.kind==="image"){const a=t.jsx("img",{className:"volter-generation-output-media",src:r,alt:e.name,loading:"lazy"});return n?t.jsx(g,{variant:"ghost",className:"volter-generation-output-open",onClick:n,"aria-label":`Open ${e.name}`,children:a}):a}return r&&e.kind==="video"?t.jsx("video",{className:"volter-generation-output-media",src:r,controls:!0,preload:"metadata",playsInline:!0,title:e.name}):r&&e.kind==="audio"?t.jsxs("div",{className:"volter-generation-output-audio",children:[t.jsx(me,{url:r,name:e.name}),t.jsx("audio",{src:r,controls:!0,preload:"metadata",title:e.name})]}):e.url&&e.kind==="model"&&Ce(e.url)?t.jsx(pe,{url:e.url}):t.jsxs("div",{className:"volter-generation-output-file",children:[t.jsx(_,{icon:e.kind==="model"?ge:ve}),t.jsx(h,{variant:"caption",tone:"muted",children:e.name}),n&&t.jsx(g,{size:"compact",variant:"ghost",onClick:n,children:"Open file"})]})}const Ve={queued:"loading",running:"loading",saving:"loading","save-failed":"error",ready:"success","no-asset":"neutral",failed:"error",cancelled:"neutral"},Ke={queued:e=>e.queuePosition===void 0?"Waiting for the provider to start.":`Position ${e.queuePosition} in the provider queue.`,running:e=>e.message??"The provider is working on it.",saving:()=>"Downloading the finished output into this project.","save-failed":e=>e.pollError??"The finished output could not be saved.",ready:()=>"Saved into this project.","no-asset":()=>"The operation finished without a file this project can hold.",failed:e=>e.message??"The provider reported a failure.",cancelled:()=>"This generation was cancelled."};function Qe({job:e,state:n}){const r=n==="queued"||n==="running"||n==="saving",a=n==="failed"||n==="save-failed";return t.jsxs("div",{className:"volter-generation-state-media","data-state":n,children:[t.jsx(P,{compact:!0,tone:Ve[n],...a?{icon:t.jsx(_,{icon:ue})}:{},title:$[n],description:Ke[n](e)}),r&&t.jsx("progress",{className:"volter-generation-progress","aria-label":`${e.label} progress`,...n==="running"&&e.progress!==void 0?{value:e.progress,max:1}:{}})]})}function Ye({job:e,busy:n,error:r,run:a}){return t.jsxs("div",{className:"volter-generation-card-actions",children:[U(e,r)&&t.jsx(g,{size:"compact",variant:"primary",disabled:n,onClick:()=>a(()=>z(e)),children:n?"Saving…":"Retry save"}),t.jsx(g,{size:"compact",variant:"ghost",onClick:()=>V(e),children:"Details"}),L(e)&&t.jsx(g,{size:"compact",variant:"ghost",disabled:n,onClick:()=>a(()=>M(e.id)),children:"Remove"})]})}function Xe({job:e,busy:n,error:r,run:a}){const o=j(e),l=q(e),i=Pe(e),c=Te(e),m=s=>{if(!s.url)return;const p=fe(he(s.name));if(p)return()=>xe(s.url,p)};return t.jsxs("article",{className:"volter-generation-card","data-state":o,"aria-busy":F(e),"aria-label":C(e),onClickCapture:()=>{c&&$e(e.id).catch(s=>{de.warn(`Could not mark generation as seen: ${s instanceof Error?s.message:String(s)}`,"generations")})},children:[t.jsx("div",{className:"volter-generation-card-media","data-outputs":Math.min(l.length,4),children:l.length===0?t.jsx(Qe,{job:e,state:o}):l.map(s=>t.jsx("div",{className:"volter-generation-output",title:s.path,children:t.jsx(We,{output:s,onOpen:m(s)})},s.path))}),t.jsxs("div",{className:"volter-generation-card-body",children:[t.jsxs("div",{className:"volter-generation-card-heading",children:[t.jsx(h,{variant:"label",truncate:!0,title:C(e),children:C(e)}),t.jsxs(R,{className:"volter-generation-chip","data-state":o,children:[$[o],o==="running"&&e.progress!==void 0?` · ${Math.round(e.progress*100)}%`:""]}),c&&t.jsx(R,{className:"volter-generation-chip","data-state":"new",children:"New"})]}),t.jsxs(h,{variant:"caption",tone:"muted",truncate:!0,title:G(e),children:[e.provider," · ",G(e)]}),t.jsxs(h,{variant:"caption",tone:"dim",children:[_e(e.billing),ze(e.billing)?"":" (est.)"," · ",Be(e)," ·"," ",Me(e.updatedAt)]}),i&&t.jsx("p",{className:"volter-generation-card-prompt",title:i,children:i}),(r??e.pollError)&&t.jsx(B,{tone:r||o==="save-failed"?"error":"warning",className:"volter-generation-card-alert",children:r??(o==="save-failed"?`Could not save into the project: ${e.pollError}`:`Polling will retry: ${e.pollError}`)}),t.jsx(Ye,{job:e,busy:n,error:r,run:a})]})]})}function Ze(){const{jobs:e}=u.useSyncExternalStore(T,x,x),[n,r]=u.useState(null),[a,o]=u.useState({}),l=e.filter(F).length,i=e.filter(s=>j(s)==="saving").length,c=async(s,p)=>{r(s),o(v=>{const f={...v};return delete f[s],f});try{await p()}catch(v){const f=v instanceof Error?v.message:String(v);o(y=>({...y,[s]:f}))}finally{r(null)}},m=ke();return t.jsxs("div",{className:"volter-generation-gallery",children:[t.jsxs(le,{label:"Generations",compact:!0,className:"volter-generation-gallery-bar",children:[t.jsx(h,{variant:"label",children:"Generations"}),t.jsxs(h,{variant:"caption",tone:"muted",children:[e.length," ",e.length===1?"generation":"generations",l>0?` · ${l} running`:"",i>0?` · ${i} saving`:""]}),t.jsx(ce,{}),t.jsx(g,{size:"compact",variant:"ghost",onClick:()=>void Se().then(J),children:"Refresh"}),t.jsx(g,{size:"compact",variant:"primary",onClick:()=>k(),children:"New asset"})]}),m&&t.jsx(B,{tone:"error",className:"volter-generation-gallery-alert",children:m}),e.length===0?t.jsx(P,{className:"volter-generation-gallery-empty",title:"No generated assets yet",description:"Preview generated images, video, audio and models here. Create an asset to get started.",action:t.jsx(g,{size:"compact",variant:"primary",onClick:()=>k(),children:"New asset"})}):t.jsx("section",{className:"volter-generation-grid","aria-label":"Generated assets",children:e.map(s=>t.jsx(Xe,{job:s,busy:n===s.id,error:a[s.id]??null,run:p=>void c(s.id,p)},s.id))})]})}const kt="workspace.service",He="generation";function et(){const e=we(x().jobs);return e>0?{count:e,severity:"info"}:null}function Tt(){const e=[be(),je({...ye.generations,order:15,Content:Ze,badge:et,subscribeBadge:T,badgeSnapshot:Ae,visibleByDefault:!1,closeable:!0}),Ne({id:He,owner:"@volter/editor-game/generation",open:(n,r)=>{if(r.id==="create")return k();const a=x().jobs.find(o=>o.id===r.id);return a?V(a):null},settle:J})];return()=>{for(const n of e)n()}}export{kt as point,Tt as start};
|
|
1
|
+
import{jn as K,jo as Q,fc as I,dN as O,h2 as E,jp as Y,jq as A,aN as X,a6 as g,h4 as Z,fo as H,jr as ee,js as te,jt as w,ju as ne,jv as re,jw as oe,jx as ae,jy as se,jz as ie,bv as le,aL as h,hV as ce,eB as P,hF as R,bQ as B,Z as de,a7 as _,gi as ue,jA as me,jB as pe,jC as ge,g$ as ve,jD as fe,b7 as he,jE as xe,f6 as je,ad as ye,f8 as Ne}from"./index-DyTgGJaV.js";import{a as t}from"./jsx-runtime-DPjLkJKQ.js";import{r as u}from"./index-nmcBqr7Y.js";import{m as Ce}from"./model-thumbnail-D5m5B4yc.js";import"./index-CtzuWnCS.js";import{s as T,g as x,c as z,f as M,i as Ee,b as F,p as Se,r as J,d as ke,e as Te,m as $e,h as be,j as Ae,a as we}from"./generation-jobs-Bc9aPUjo.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";import"./renderer-ownership-BovSEcLv.js";import"./studio-environment-BTgaAUb4.js";import"./user-data-W4XQSuJh.js";import"./workspace-arrangement-Dl7Q2V4T.js";import"./KTX2Loader-CaqVE6nY.js";import"./three.module-BLhyNg0e.js";import"./three.core-3arARmh6.js";import"./GLTFLoader-KeoruJgS.js";import"./BufferGeometryUtils-B22h7jo4.js";import"./environment-Dg-YaLsA.js";import"./RoomEnvironment-BkknvS_I.js";import"./EXRLoader-CITMBvGd.js";import"./HDRLoader-BTGuGhVo.js";function j(e){switch(e.status){case"queued":return"queued";case"running":return"running";case"failed":return"failed";case"cancelled":return"cancelled";default:return e.acceptedAt?"ready":e.accept?e.pollError?"save-failed":"saving":"no-asset"}}function L(e){const n=j(e);return n!=="queued"&&n!=="running"&&n!=="saving"}function U(e,n){return e.status==="succeeded"&&!!e.accept&&!e.acceptedAt&&!!(e.pollError??n)}const $={queued:"Queued",running:"Running",saving:"Saving","save-failed":"Couldn't save",ready:"In project","no-asset":"No file",failed:"Failed",cancelled:"Cancelled"},Re=new Map([...["png","jpg","jpeg","webp","gif","avif","svg","bmp"].map(e=>[e,"image"]),...["mp4","webm","ogv","mov","m4v"].map(e=>[e,"video"]),...["mp3","wav","ogg","oga","m4a","flac","aac"].map(e=>[e,"audio"]),...["glb","gltf","fbx","obj","stl","ply","dae","3ds","usdz","spz"].map(e=>[e,"model"])]);function De(e){const n=e.slice(e.lastIndexOf("/")+1).toLowerCase(),r=n.lastIndexOf(".");return r>0?n.slice(r+1):""}function q(e){return(e.outputPaths??[]).map(n=>{const r=K.find(o=>n.startsWith(`${o}/`)),a=r?Q(r,n.slice(r.length+1)):null;return{path:n,name:n.slice(n.lastIndexOf("/")+1),kind:Re.get(De(n))??"file",url:a}})}function D(e,n){const r=e.trim();return r.length<=n?r:`${r.slice(0,n-1).trimEnd()}…`}function C(e){const n=Oe(e);if(n)return n;const r=q(e);if(r.length===0)return D(e.label,64);const a=r[0],o=Ie(a.path);return r.length>1?o?`${o} · ${r.length} files`:`${r.length} files`:Ge.test(a.name)?o?`${o}/${a.name}`:D(e.label,64):a.name}const Ge=/^(image|video|audio|model|panorama|output)(-\d+)?\./;function Ie(e){const n=e.split("/").slice(-2,-1)[0];return n?/^[0-9a-f]{8,}$/i.test(n)||/^[0-9a-f-]{16,}$/i.test(n)?null:n:null}function Oe(e){const n=e.accept?.input;if(!n||typeof n!="object")return null;const r=n.outputName;return typeof r=="string"&&r.trim().length>0?r.trim():null}function Pe(e){for(const n of[e.accept?.input,e.poll.input]){const r=W(n,0);if(r)return r}return null}function W(e,n){if(n>3||typeof e!="object"||e===null)return null;const r=e,a=r.prompt;if(typeof a=="string"&&a.trim().length>0)return a.trim();for(const o of Object.values(r)){const l=W(o,n+1);if(l)return l}return null}function G(e){return e.operation}function Be(e){return e.mode==="managed"?"Volter subscription":e.mode==="direct"?"Your provider key":"Mock"}function _e(e){return e.route==="mock"?"Free · mock":e.route==="managed"?e.settledCredits!==void 0?`${e.settledCredits} credits`:e.estimatedCredits!==void 0?`Up to ${e.estimatedCredits} credits`:"Credit estimate unavailable":e.settledAmount!==void 0?`$${e.settledAmount.toFixed(3)}`:e.estimatedAmount!==void 0?`Up to $${e.estimatedAmount.toFixed(3)}`:"USD estimate unavailable"}function ze(e){return e.route==="mock"?!0:e.route==="managed"?e.settledCredits!==void 0:e.settledAmount!==void 0}function Me(e){const n=Math.floor((Date.now()-Date.parse(e))/6e4);if(!Number.isFinite(n)||n<1)return"just now";if(n<60)return`${n}m ago`;const r=Math.floor(n/60);if(r<24)return`${r}h ago`;const a=Math.floor(r/24);return a<7?`${a}d ago`:`${Math.floor(a/7)}w ago`}const S="generation:",Fe="generation:create";function Je(e){return e.route==="mock"?"Free mock":e.route==="managed"?e.settledCredits!==void 0?`${e.settledCredits} credits settled`:e.estimatedCredits!==void 0?`Up to ${e.estimatedCredits} credits`:"Volter subscription · estimate unavailable":e.settledAmount!==void 0?`$${e.settledAmount.toFixed(3)} settled`:e.estimatedAmount!==void 0?`Up to $${e.estimatedAmount.toFixed(3)}`:"BYOK · estimate unavailable"}function V(e){return I({id:`${S}${e.id}`,title:e.label,kind:"generation",workspaceRole:"authored-subject",provenance:{origin:`${e.provider}:${e.externalId}`},Content:qe,closeable:!0,presentation:()=>({kind:"generation",id:e.id})})}function k(){return I({id:Fe,title:"Create Asset",kind:"generation",workspaceRole:"workspace-task",provenance:{origin:"registered generation tools"},Content:Le,closeable:!0,presentation:()=>({kind:"generation",id:"create"})})}function Le(){u.useSyncExternalStore(O,E),u.useSyncExternalStore(Y,A,A);const e=ee(),[n,r]=u.useState(""),a=n.trim().toLowerCase(),o=E().filter(i=>i.point==="workspace.document"&&i.tool?.generation?.role==="submit").filter(i=>a?[i.title,i.tool?.generation?.provider,i.tool?.summary,i.tool?.description].filter(Boolean).some(c=>String(c).toLowerCase().includes(a)):!0),l=new Map;for(const i of o){const c=i.tool?.generation?.provider??"other";l.set(c,[...l.get(c)??[],i])}return t.jsxs("div",{className:"volter-tool-page","data-testid":"generation-create-catalog",children:[t.jsxs("header",{className:"volter-tool-header",children:[t.jsx("div",{className:"volter-tool-eyebrow",children:"Installed provider extensions"}),t.jsx("h2",{className:"volter-tool-title",children:"Create an asset"}),t.jsxs("p",{className:"volter-tool-description",children:["Choose a native provider operation. Mock, managed, and BYOK execution remain explicit in the operation you open. Current default: ",e.preferredRoute,"."]})]}),t.jsx(X,{type:"search","aria-label":"Search generation tools",placeholder:"Search operations or providers…",value:n,onChange:i=>r(i.target.value)}),[...l.entries()].map(([i,c])=>t.jsxs("section",{className:"volter-tool-card",children:[t.jsx("h3",{className:"volter-tool-section-title",children:i}),t.jsx("div",{className:"volter-generation-create-grid",children:c.map(m=>t.jsxs(g,{variant:"ghost",className:"volter-generation-create-card",onClick:()=>Z(m.id),children:[t.jsx("strong",{children:m.title}),t.jsx("span",{children:m.tool?.summary})]},m.id))})]},i)),o.length===0&&t.jsx("div",{className:"volter-generation-document-empty",children:"No installed generation operation matches this search."})]})}function Ue({job:e,result:n,documentId:r,active:a}){u.useSyncExternalStore(O,E),u.useSyncExternalStore(te,w,w);const o=ne(e.poll.tool,e,n);if(!o)return t.jsx("pre",{className:"volter-generation-native-result",children:JSON.stringify(n,null,2)});const l=o.Component;return t.jsx(re,{file:o.file,children:t.jsx(l,{tool:o.tool,contributionId:o.id,client:ie(),surfaces:oe,account:se(),play:ae(),documentId:r,active:a,job:e,result:n})})}function qe({documentId:e,active:n}){const{jobs:r}=u.useSyncExternalStore(T,x,x),a=e.startsWith(S)?e.slice(S.length):e,o=r.find(d=>d.id===a),[l,i]=u.useState(),[c,m]=u.useState(!1),[s,p]=u.useState(null),[v,f]=u.useState(!1),y=async d=>{m(!0),p(null);try{i(await Ee(d))}catch(N){p(N instanceof Error?N.message:String(N))}finally{m(!1)}};if(u.useEffect(()=>{o&&y(o)},[o?.id,o?.status]),!o)return t.jsx("div",{className:"volter-generation-document-empty",children:"This generation is no longer in project activity."});const b=s??(j(o)==="save-failed"?`Could not save into the project: ${o.pollError}`:null);return t.jsxs("div",{className:"volter-generation-document","data-status":o.status,children:[t.jsxs("header",{className:"volter-generation-document-header",children:[t.jsxs("div",{children:[t.jsxs("div",{className:"volter-tool-eyebrow",children:[o.provider," · ",o.operation]}),t.jsx("h2",{className:"volter-tool-title",children:o.label}),t.jsxs("div",{className:"volter-generation-job-meta",children:[$[j(o)]," · ",Je(o.billing)]})]}),t.jsxs("div",{className:"volter-tool-actions",children:[t.jsx(g,{size:"compact",variant:"ghost",disabled:c,onClick:()=>void y(o),children:c?"Refreshing…":"Refresh"}),U(o,s)&&t.jsx(g,{size:"compact",variant:"primary",disabled:v,onClick:()=>{f(!0),p(null),z(o).catch(d=>p(d instanceof Error?d.message:String(d))).finally(()=>f(!1))},children:v?"Saving…":"Retry save"})]})]}),o.message&&t.jsx("div",{className:"volter-tool-status",children:o.message}),b&&t.jsx("div",{className:"volter-tool-status","data-tone":"error",role:"alert",children:b}),t.jsx("section",{className:"volter-generation-result","aria-label":"Generation result",children:l===void 0?t.jsx("div",{className:"volter-generation-document-empty",children:c?"Loading provider result…":"No provider result is available yet."}):t.jsx(Ue,{job:o,result:l,documentId:e,active:n})}),o.outputPaths&&o.outputPaths.length>0&&t.jsxs("section",{className:"volter-generation-output-paths",children:[t.jsx("strong",{children:"Project assets"}),o.outputPaths.map(d=>t.jsx("code",{children:d},d))]}),L(o)&&t.jsx("div",{className:"volter-generation-document-footer",children:t.jsx(g,{size:"compact",variant:"ghost",disabled:v,onClick:()=>{f(!0),M(o.id).then(()=>H(e)).catch(d=>p(d instanceof Error?d.message:String(d))).finally(()=>f(!1))},children:"Remove from activity"})})]})}function We({output:e,onOpen:n}){const r=e.url;if(r&&e.kind==="image"){const a=t.jsx("img",{className:"volter-generation-output-media",src:r,alt:e.name,loading:"lazy"});return n?t.jsx(g,{variant:"ghost",className:"volter-generation-output-open",onClick:n,"aria-label":`Open ${e.name}`,children:a}):a}return r&&e.kind==="video"?t.jsx("video",{className:"volter-generation-output-media",src:r,controls:!0,preload:"metadata",playsInline:!0,title:e.name}):r&&e.kind==="audio"?t.jsxs("div",{className:"volter-generation-output-audio",children:[t.jsx(me,{url:r,name:e.name}),t.jsx("audio",{src:r,controls:!0,preload:"metadata",title:e.name})]}):e.url&&e.kind==="model"&&Ce(e.url)?t.jsx(pe,{url:e.url}):t.jsxs("div",{className:"volter-generation-output-file",children:[t.jsx(_,{icon:e.kind==="model"?ge:ve}),t.jsx(h,{variant:"caption",tone:"muted",children:e.name}),n&&t.jsx(g,{size:"compact",variant:"ghost",onClick:n,children:"Open file"})]})}const Ve={queued:"loading",running:"loading",saving:"loading","save-failed":"error",ready:"success","no-asset":"neutral",failed:"error",cancelled:"neutral"},Ke={queued:e=>e.queuePosition===void 0?"Waiting for the provider to start.":`Position ${e.queuePosition} in the provider queue.`,running:e=>e.message??"The provider is working on it.",saving:()=>"Downloading the finished output into this project.","save-failed":e=>e.pollError??"The finished output could not be saved.",ready:()=>"Saved into this project.","no-asset":()=>"The operation finished without a file this project can hold.",failed:e=>e.message??"The provider reported a failure.",cancelled:()=>"This generation was cancelled."};function Qe({job:e,state:n}){const r=n==="queued"||n==="running"||n==="saving",a=n==="failed"||n==="save-failed";return t.jsxs("div",{className:"volter-generation-state-media","data-state":n,children:[t.jsx(P,{compact:!0,tone:Ve[n],...a?{icon:t.jsx(_,{icon:ue})}:{},title:$[n],description:Ke[n](e)}),r&&t.jsx("progress",{className:"volter-generation-progress","aria-label":`${e.label} progress`,...n==="running"&&e.progress!==void 0?{value:e.progress,max:1}:{}})]})}function Ye({job:e,busy:n,error:r,run:a}){return t.jsxs("div",{className:"volter-generation-card-actions",children:[U(e,r)&&t.jsx(g,{size:"compact",variant:"primary",disabled:n,onClick:()=>a(()=>z(e)),children:n?"Saving…":"Retry save"}),t.jsx(g,{size:"compact",variant:"ghost",onClick:()=>V(e),children:"Details"}),L(e)&&t.jsx(g,{size:"compact",variant:"ghost",disabled:n,onClick:()=>a(()=>M(e.id)),children:"Remove"})]})}function Xe({job:e,busy:n,error:r,run:a}){const o=j(e),l=q(e),i=Pe(e),c=Te(e),m=s=>{if(!s.url)return;const p=fe(he(s.name));if(p)return()=>xe(s.url,p)};return t.jsxs("article",{className:"volter-generation-card","data-state":o,"aria-busy":F(e),"aria-label":C(e),onClickCapture:()=>{c&&$e(e.id).catch(s=>{de.warn(`Could not mark generation as seen: ${s instanceof Error?s.message:String(s)}`,"generations")})},children:[t.jsx("div",{className:"volter-generation-card-media","data-outputs":Math.min(l.length,4),children:l.length===0?t.jsx(Qe,{job:e,state:o}):l.map(s=>t.jsx("div",{className:"volter-generation-output",title:s.path,children:t.jsx(We,{output:s,onOpen:m(s)})},s.path))}),t.jsxs("div",{className:"volter-generation-card-body",children:[t.jsxs("div",{className:"volter-generation-card-heading",children:[t.jsx(h,{variant:"label",truncate:!0,title:C(e),children:C(e)}),t.jsxs(R,{className:"volter-generation-chip","data-state":o,children:[$[o],o==="running"&&e.progress!==void 0?` · ${Math.round(e.progress*100)}%`:""]}),c&&t.jsx(R,{className:"volter-generation-chip","data-state":"new",children:"New"})]}),t.jsxs(h,{variant:"caption",tone:"muted",truncate:!0,title:G(e),children:[e.provider," · ",G(e)]}),t.jsxs(h,{variant:"caption",tone:"dim",children:[_e(e.billing),ze(e.billing)?"":" (est.)"," · ",Be(e)," ·"," ",Me(e.updatedAt)]}),i&&t.jsx("p",{className:"volter-generation-card-prompt",title:i,children:i}),(r??e.pollError)&&t.jsx(B,{tone:r||o==="save-failed"?"error":"warning",className:"volter-generation-card-alert",children:r??(o==="save-failed"?`Could not save into the project: ${e.pollError}`:`Polling will retry: ${e.pollError}`)}),t.jsx(Ye,{job:e,busy:n,error:r,run:a})]})]})}function Ze(){const{jobs:e}=u.useSyncExternalStore(T,x,x),[n,r]=u.useState(null),[a,o]=u.useState({}),l=e.filter(F).length,i=e.filter(s=>j(s)==="saving").length,c=async(s,p)=>{r(s),o(v=>{const f={...v};return delete f[s],f});try{await p()}catch(v){const f=v instanceof Error?v.message:String(v);o(y=>({...y,[s]:f}))}finally{r(null)}},m=ke();return t.jsxs("div",{className:"volter-generation-gallery",children:[t.jsxs(le,{label:"Generations",compact:!0,className:"volter-generation-gallery-bar",children:[t.jsx(h,{variant:"label",children:"Generations"}),t.jsxs(h,{variant:"caption",tone:"muted",children:[e.length," ",e.length===1?"generation":"generations",l>0?` · ${l} running`:"",i>0?` · ${i} saving`:""]}),t.jsx(ce,{}),t.jsx(g,{size:"compact",variant:"ghost",onClick:()=>void Se().then(J),children:"Refresh"}),t.jsx(g,{size:"compact",variant:"primary",onClick:()=>k(),children:"New asset"})]}),m&&t.jsx(B,{tone:"error",className:"volter-generation-gallery-alert",children:m}),e.length===0?t.jsx(P,{className:"volter-generation-gallery-empty",title:"No generated assets yet",description:"Preview generated images, video, audio and models here. Create an asset to get started.",action:t.jsx(g,{size:"compact",variant:"primary",onClick:()=>k(),children:"New asset"})}):t.jsx("section",{className:"volter-generation-grid","aria-label":"Generated assets",children:e.map(s=>t.jsx(Xe,{job:s,busy:n===s.id,error:a[s.id]??null,run:p=>void c(s.id,p)},s.id))})]})}const kt="workspace.service",He="generation";function et(){const e=we(x().jobs);return e>0?{count:e,severity:"info"}:null}function Tt(){const e=[be(),je({...ye.generations,order:15,Content:Ze,badge:et,subscribeBadge:T,badgeSnapshot:Ae,visibleByDefault:!1,closeable:!0}),Ne({id:He,owner:"@volter/editor-game/generation",open:(n,r)=>{if(r.id==="create")return k();const a=x().jobs.find(o=>o.id===r.id);return a?V(a):null},settle:J})];return()=>{for(const n of e)n()}}export{kt as point,Tt as start};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{dZ as p,u as o,x as n,c6 as e,v as l,w as t,c4 as d,e1 as c}from"./index-
|
|
1
|
+
import{dZ as p,u as o,x as n,c6 as e,v as l,w as t,c4 as d,e1 as c}from"./index-DyTgGJaV.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 u=d(["queued","running","succeeded","failed","cancelled"]),g=p("route",[o({route:n("mock")}).strict(),o({route:n("managed"),estimatedCredits:e().nonnegative().optional(),settledCredits:e().nonnegative().optional()}).strict(),o({route:n("byok"),currency:n("USD"),estimatedAmount:e().nonnegative().optional(),settledAmount:e().nonnegative().optional()}).strict()]),r=o({tool:t().min(1),input:c()}).strict(),v=o({id:t().min(1),provider:t().min(1),externalId:t().min(1),label:t().min(1),operation:t().min(1),mode:d(["mock","direct","managed"]),status:u,createdAt:t().datetime(),updatedAt:t().datetime(),progress:e().min(0).max(1).optional(),providerStatus:t().optional(),queuePosition:e().int().nonnegative().optional(),message:t().optional(),lastPolledAt:t().datetime().optional(),lastProviderChangeAt:t().datetime().optional(),pollError:t().optional(),pollErrorAt:t().datetime().optional(),pollFailureCount:e().int().nonnegative().optional(),nextPollAt:t().datetime().optional(),billing:g,poll:r,cancel:r.optional(),accept:r.optional(),acceptedAt:t().datetime().optional(),readAt:t().datetime().optional(),provenanceOperationId:t().optional(),outputPaths:l(t()).optional()}).strict(),k=o({version:n(1),jobs:l(v)}).strict();function y(m,s){if(m!=="managed")return{};const{estimatedCredits:i,settledCredits:a}=s;return i===void 0&&a===void 0?{}:{billing:{route:"managed",...i===void 0?{}:{estimatedCredits:i},...a===void 0?{}:{settledCredits:a}}}}export{g as GenerationBillingSchema,v as GenerationJobSchema,u as GenerationJobStatusSchema,k as GenerationJobsDocumentSchema,y as managedBilling};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as s}from"./jsx-runtime-DPjLkJKQ.js";import{a6 as r,r as a,ad as i}from"./index-
|
|
1
|
+
import{a as s}from"./jsx-runtime-DPjLkJKQ.js";import{a6 as r,r as a,ad as i}from"./index-DyTgGJaV.js";import{r as u}from"./index-nmcBqr7Y.js";import"./index-CtzuWnCS.js";import{s as c,g as o,a as p,b as m}from"./generation-jobs-Bc9aPUjo.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";const I="workspace.status",$="Generations",C="left",T=24;function U(){const{jobs:e}=u.useSyncExternalStore(c,o,o),n=p(e),t=e.filter(m).length;return s.jsxs(r,{type:"button",variant:"ghost",size:"compact",className:"volter-status-action","data-testid":"status-generations","aria-label":`Generations, ${n} unseen, ${t} running`,title:`${n} unseen generation results, ${t} running — open Generations`,onClick:()=>a().workspace.showUtility(i.generations.id),children:["Generations · ",n,t>0?` · ${t} running`:""]})}export{C as align,U as default,T as order,I as point,$ as title};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as n}from"./workspace-arrangement-
|
|
1
|
+
import{g as n}from"./workspace-arrangement-Dl7Q2V4T.js";function r(t){const o=n(t,"volterComponentRoot");return typeof o=="string"&&o?o:void 0}function i(t){return n(t,"volterBuiltInternal")===!0}export{r as c,i};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{kE as E,w as l,u as y,kF as P,v as b,b3 as T}from"./index-
|
|
1
|
+
import{kE as E,w as l,u as y,kF as P,v as b,b3 as T}from"./index-DyTgGJaV.js";import{i as x}from"./relative-path-guard-GiM7Lsz8.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=".volter/assets.json",k=y({key:l().min(1),license:l().min(1).optional(),sourceHash:l().regex(/^sha256-[a-f0-9]{64}$/,'sourceHash must be "sha256-<64 hex>"').optional(),materializedAt:l().datetime()}).strict(),O=E(l().min(1),k);function z(e){if(!/^[a-f0-9]{64}$/.test(e))throw new Error(`Not a sha256 digest, refusing to record it as a sourceHash: ${e}`);return`sha256-${e}`}function m(e){const t=e.replaceAll("\\","/").replace(/^\.\//,"").replace(/^\/+/,"");if(!t)throw new Error("An asset ledger path cannot be empty.");if(!x(t))throw new Error(`An asset ledger path cannot escape the project: ${e}`);return t}function _(e){return O.parse(e)}function D(e){if(e==null||e.trim()==="")return{};let t;try{t=JSON.parse(e)}catch(s){throw new Error(`${d} is not valid JSON: ${String(s)}`)}return _(t)}function I(e,t,s){const r=m(t),n=k.parse(s),a={...e,[r]:n},i={};for(const u of Object.keys(a).sort())i[u]=a[u];return i}function M(e){const t={};for(const s of Object.keys(e).sort())t[s]=e[s];return`${JSON.stringify(t,null,2)}
|
|
2
2
|
`}function U(e,t,s){const r=globalThis.navigator?.locks;return r?r.request(`volter:${e}:${P(t)}`,s):s()}const H=1e4,N=15;function j(){return globalThis.crypto?.randomUUID?.()??`${Date.now()}-${Math.random()}`}async function R(e,t,s={}){const r=s.staleAfterMs??H,n=s.retryDelayMs??N,a=s.now??Date.now,i=s.sleep??(o=>new Promise(c=>setTimeout(c,o))),u=s.token??j;for(;;){const o=JSON.stringify({at:a(),owner:s.owner??"unknown",token:u()});if(await e.createIfAbsent(o))try{return await t()}finally{await e.removeIfHeldBy(o)}const c=await e.read();if(c!==null){if(a()-B(c)>r){await e.removeIfHeldBy(c);continue}await i(n)}}}function B(e){try{const t=JSON.parse(e);return typeof t.at=="number"?t.at:0}catch{return 0}}function F(){const e=new Map;return(t,s)=>{const n=(e.get(t)??Promise.resolve()).then(s,s),a=n.then(()=>{},()=>{});return e.set(t,a),a.then(()=>{e.get(t)===a&&e.delete(t)}),n}}async function S(e){return await e.exists(d)?D(await e.read(d)):{}}async function J(e,t){await e.write(d,M(t))}const f=`${d}.lock`,C=F(),A=new WeakMap;let $=0;function K(e){const t=A.get(e);if(t!==void 0)return t;$+=1;const s=`${e.id}#${$}`;return A.set(e,s),s}async function W(e,t){const s={key:t.key,...t.license?{license:t.license}:{},...t.sourceSha256?{sourceHash:z(t.sourceSha256)}:{},materializedAt:t.materializedAt??new Date().toISOString()};await C(K(e),()=>R({createIfAbsent:r=>e.writeIfAbsent(f,r),read:async()=>await e.exists(f)?e.read(f):null,removeIfHeldBy:r=>U(e.id,f,async()=>{await e.exists(f)&&await e.read(f)===r&&await e.remove(f)})},async()=>{const r=await S(e);await J(e,I(r,m(t.destPath),s))},{owner:e.id}))}const G=y({key:l().regex(/^[^:]+:.+$/,'An asset key must be "source:id"'),dest:l().min(1),sha256:l().regex(/^[a-f0-9]{64}$/,"A pack entry must pin the sha256 of its bytes as 64 lowercase hex digits")}).strict(),Y=y({packs:E(l().min(1),b(G))}).strict();function q(e){return Y.parse(e)}function V(e){const t=[],s=new Map;for(const[r,n]of Object.entries(e.packs))for(const a of n){const i=s.get(a.dest);if(i!==void 0)throw new Error(`Two packs declare the same destination "${a.dest}": "${i}" and "${r}".`);s.set(a.dest,r),t.push({...a,pack:r})}return t}const w="asset-manifest.json",v="https://volter-asset-library.aaron-0ed.workers.dev";function L(e){return(e.baseUrl??v).replace(/\/+$/,"")}function Q(e){return e.signal?{signal:e.signal}:{}}async function X(e,t={}){const s=L(t),r=await fetch(`${s}/v1/assets/${encodeURIComponent(e)}`,Q(t));if(!r.ok)return null;const n=await r.json();return!n||typeof n!="object"||!Array.isArray(n.files)?null:n}function Z(e,t,s,r){return`${L(e?{baseUrl:e}:{})}/v1/assets/${encodeURIComponent(t)}/files/${s}`}async function he(e,t={}){const s=await ee(e),r={declared:s.length,materialized:[],alreadyPresent:[],failed:[]};if(s.length===0)return r;const n=await S(e);for(const a of s){if(t.signal?.aborted)break;if(n[m(a.dest)]&&await e.exists(a.dest)){r.alreadyPresent.push(a),t.onProgress?.(a,"already-present");continue}try{await te(e,a,t),r.materialized.push(a),t.onProgress?.(a,"materialized")}catch(i){r.failed.push({entry:a,reason:i instanceof Error?i.message:String(i)}),t.onProgress?.(a,"failed")}}return r}async function ee(e){if(!await e.exists(w))return[];const t=await e.read(w);let s;try{s=JSON.parse(t)}catch(r){throw new Error(`${w} is not valid JSON: ${r instanceof Error?r.message:String(r)}`)}return V(q(s))}async function te(e,t,s){const r=await se(t,s);await e.write(t.dest,r.bytes),await W(e,{destPath:t.dest,key:t.key,license:r.license,sourceSha256:t.sha256})}async function se(e,t={}){const s=e.key.indexOf(":");if(s<0)throw new Error(`Malformed asset key "${e.key}" (expected "source:id").`);const r=e.key.slice(0,s),n=e.key.slice(s+1);if(r!=="local")throw new Error(`Asset key "${e.key}": only the "local" (cloud-hosted) source can be materialized from the cloud worker.`);const a=t.baseUrl??v,i=t.signal?{baseUrl:a,signal:t.signal}:{baseUrl:a},u=await X(n,i);if(!u)throw new Error(`"${e.key}" is not hosted by the cloud asset library.`);const o=u.files[0];if(!o)throw new Error(`"${e.key}" has no files in the cloud library.`);if(o.dependencies.length>0)throw new Error(`"${e.key}" has ${o.dependencies.length} dependency file(s) — a pack entry names exactly one destination file.`);if(o.main.sha256!==e.sha256)throw new Error(`"${e.key}" → ${e.dest}: the cloud library reports sha256:${o.main.sha256} but ${w} pins sha256:${e.sha256}. Nothing was fetched or written; the pin is only re-cut by a reviewed change to the declaration.`);const c=Z(a,n,0),h=await fetch(c,t.signal?{signal:t.signal}:{});if(!h.ok)throw new Error(`${c} returned ${h.status} ${h.statusText}.`);const p=new Uint8Array(await h.arrayBuffer()),g=await T(p);if(g!==e.sha256)throw new Error(`"${e.key}" → ${e.dest}: ${c} delivered sha256:${g} but the declaration pins sha256:${e.sha256}. Nothing was written.`);return{bytes:p,license:u.license}}export{w as ASSET_MANIFEST_PATH,se as fetchVerifiedPackEntry,he as materializeDeclaredAssetPacks};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{CameraDescriptorSchema as f}from"./camera-
|
|
1
|
+
import{CameraDescriptorSchema as f}from"./camera-lGstadDR.js";import{ColliderDescriptorSchema as x}from"./collider-UIoHvnAV.js";import{LightDescriptorSchema as l}from"./light-CWgqDXEE.js";import{MaterialDescriptorSchema as M}from"./material-t5AUiIjm.js";import{MeshDescriptorSchema as d}from"./mesh-D0ARI7DT.js";import{ParticlesDescriptorSchema as T}from"./particles-Cl0uw7lL.js";import{PostProcessingDescriptorSchema as v,RenderEnvironmentSchema as E,ToneMappingDescriptorSchema as L}from"./render-env-B-xiPHul.js";import{QuatSchema as R,TransformSchema as V,Vec3Schema as b}from"./tuples-DhXwxLo-.js";import"./index-DyTgGJaV.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";import"./render-features-D6cEaZG_.js";export{f as CameraDescriptorSchema,x as ColliderDescriptorSchema,l as LightDescriptorSchema,M as MaterialDescriptorSchema,d as MeshDescriptorSchema,T as ParticlesDescriptorSchema,v as PostProcessingDescriptorSchema,R as QuatSchema,E as RenderEnvironmentSchema,L as ToneMappingDescriptorSchema,V as TransformSchema,b as Vec3Schema};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{bA as nt,aN as st,al as ot,e4 as E,dV as U,a6 as at,e6 as rt,e5 as it}from"./index-EO6Vl92s.js";import{hp as wt,hq as Rt,hr as Nt,aS as _t,dX as Ct,hs as Ft,ht as Ot,hu as kt,hv as Lt,hw as jt,hx as Bt,hy as Gt,eJ as Pt,hz as Ht,e_ as $t,hA as zt,hB as Wt,hC as Vt,hD as Kt,hE as Jt,dz as Ut,hF as qt,bQ as Yt,a7 as Qt,eq as Xt,bP as Zt,h1 as te,hG as ee,hH as ne,bv as se,hI as oe,hJ as ae,hK as re,eY as ie,fe as ce,hL as ue,ff as le,hM as de,d9 as pe,hN as fe,aM as he,df as me,hO as xe,hP as Ee,hQ as ge,dg as Se,f1 as Te,fz as be,bB as De,bC as Me,fN as ye,hR as Ae,hS as Ie,aT as ve,hT as we,hU as Re,aU as Ne,bH as _e,hV as Ce,db as Fe,de as Oe,eB as ke,hW as Le,hX as je,aL as Be,e$ as Ge,hY as Pe,hZ as He,gK as $e,h_ as ze,bw as We,h$ as Ve,i0 as Ke,es as Je,i1 as Ue,i2 as qe,i3 as Ye,i4 as Qe,i5 as Xe,eo as Ze,ep as tn,i6 as en,i7 as nn,i8 as sn,i9 as on,ev as an,ia as rn,ib as cn,ic as un,id as ln,ie as dn,a8 as pn,ig as fn,ih as hn,ii as mn,ij as xn,ik as En,il as gn,ew as Sn,im as Tn,io as bn,et as Dn,ip as Mn,iq as yn,ir as An,dA as In,is as vn,it as wn,iu as Rn,iv as Nn,iw as _n,ix as Cn,iy as Fn,eW as On,iz as kn,iA as Ln,iB as jn,iC as Bn,iD as Gn,iE as Pn,ex as Hn,iF as $n,iG as zn,iH as Wn,f0 as Vn,iI as Kn,iJ as Jn,iK as Un,iL as qn,dq as Yn,er as Qn,iM as Xn,iN as Zn,iO as ts,eu as es,iP as ns,aZ as ss,dW as os,iQ as as,iR as rs,iS as is,dp as cs}from"./index-EO6Vl92s.js";import{C as ls}from"./ColorInput-7cF4Leq3.js";import{a as p}from"./jsx-runtime-DPjLkJKQ.js";import{r as b}from"./index-nmcBqr7Y.js";import{A as ps,k as fs,B as hs,a as ms,D as xs,l as Es,F as gs,h as Ss,G as Ts,m as bs,Q as Ds,S as Ms,f as ys,n as As,T as Is,d as vs,c as ws,g as Rs,i as Ns,j as _s,b as Cs,p as Fs,e as Os,u as ks,o as Ls}from"./ShadowEditor-BTWOn0NH.js";import{a as Bs,C as Gs,h as Ps,p as Hs,t as $s}from"./ColorPicker-B2gSkOna.js";import"./index-CtzuWnCS.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";function Dt({preview:t,children:e,...r}){const[o,a]=b.useState(!1),l=b.useRef(null),c=b.useId(),s=()=>a(!1),d=i=>{l.current=i,a(!0)};let m=e;if(b.isValidElement(e)){const i=[e.props["aria-describedby"],o?c:null].filter(Boolean).join(" ");m=b.cloneElement(e,i?{"aria-describedby":i}:{})}return p.jsxs("span",{className:"volter-tooltip-anchor",onMouseEnter:i=>d(i.currentTarget),onMouseLeave:s,onFocusCapture:i=>d(i.currentTarget),onBlurCapture:i=>{i.currentTarget.contains(i.relatedTarget)||s()},onKeyDown:i=>{i.key!=="Escape"||!o||(i.preventDefault(),i.stopPropagation(),s())},children:[m,o&&l.current&&p.jsx(nt,{...r,anchorRef:l,id:c,role:"tooltip",autoFocusFirst:!1,onDismiss:s,children:t})]})}function Mt({value:t,onCommit:e,style:r,disabled:o=!1}){const a=t===void 0?"":JSON.stringify(t),[l,c]=b.useState(a),[s,d]=b.useState(!1),m=b.useRef(!1);b.useEffect(()=>{c(a),d(!1)},[a]);const i=()=>{if(m.current){m.current=!1;return}if(l===a){d(!1);return}let h;try{h=JSON.parse(l)}catch{d(!0);return}d(!1),e(h)};return p.jsxs("div",{children:[p.jsx(st,{"data-testid":"json-input","aria-invalid":s||void 0,"data-tone":s?"danger":void 0,disabled:o,value:l,onChange:h=>{c(h.target.value),s&&d(!1)},onBlur:i,onKeyDown:h=>{h.key==="Enter"?i():h.key==="Escape"&&(m.current=!0,c(a),d(!1),h.target.blur())},style:r,title:s?"Not valid JSON — nothing written. Fix the JSON or press Escape to revert.":void 0}),s&&p.jsx("div",{"data-testid":"json-input-error",style:{fontSize:"var(--volter-font-sm)",color:ot.semantic.danger,marginTop:2},children:"Not valid JSON — nothing written. Fix the JSON or press Escape to revert."})]})}function v(t,e){return e+1<t.length?t[e+1].start:1}function ct(t){const e=t.map(o=>({time:o.start,value:o.function.p0})),r=t[t.length-1];return r&&e.push({time:1,value:r.function.p3}),e}function G(t){return t.map(e=>({start:e.start,function:{...e.function}}))}const B=.01;function C(t,e,r,o){const a=G(t),l=a.length;if(e<0||e>l)return a;if(e<l){const c=a[e],s=o-c.function.p0;if(c.function.p0=o,c.function.p1+=s,e>0){const d=a[e-1],m=o-d.function.p3;d.function.p3=o,d.function.p2+=m;const i=d.start+B,h=v(a,e)-B;c.start=Math.min(h,Math.max(i,r))}}else{const c=a[l-1],s=o-c.function.p3;c.function.p3=o,c.function.p2+=s}return a}function q(t,e,r,o){const a=G(t);return r==="out"&&e<a.length?a[e].function.p1=o:r==="in"&&e>0&&e<=a.length&&(a[e-1].function.p2=o),a}function M(t,e,r){return t+(e-t)*r}function yt(t,e){for(let r=0;r<t.length;r++){const o=t[r].start,a=v(t,r);if(e>=o&&e<=a){const l=a>o?(e-o)/(a-o):0,{p0:c,p1:s,p2:d,p3:m}=t[r].function,i=M(c,s,l),h=M(s,d,l),g=M(d,m,l),A=M(i,h,l),I=M(h,g,l);return M(A,I,l)}}return 0}function ut(t,e){for(let r=0;r<t.length;r++){const o=t[r].start,a=v(t,r);if(e<=o+B||e>=a-B||e<o||e>a)continue;const l=(e-o)/(a-o),{p0:c,p1:s,p2:d,p3:m}=t[r].function,i=M(c,s,l),h=M(s,d,l),g=M(d,m,l),A=M(i,h,l),I=M(h,g,l),D=M(A,I,l),S=G(t);return S.splice(r,1,{start:o,function:{p0:c,p1:i,p2:A,p3:D}},{start:e,function:{p0:D,p1:I,p2:g,p3:m}}),S}return t}function Y(t,e){if(e<=0||e>=t.length)return t;const r=t[e-1],o=t[e],a=o.start-r.start,l=v(t,e)-o.start,c=a+l;if(c<=0)return t;const s=r.function,d=o.function,m={start:r.start,function:{p0:s.p0,p1:s.p0+(s.p1-s.p0)*(a>0?c/a:1),p2:d.p3+(d.p2-d.p3)*(l>0?c/l:1),p3:d.p3}},i=G(t);return i.splice(e-1,2,m),i}function lt(t){let e=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;for(const o of t)for(const a of[o.function.p0,o.function.p1,o.function.p2,o.function.p3])a<e&&(e=a),a>r&&(r=a);return!Number.isFinite(e)||!Number.isFinite(r)?{min:0,max:1}:{min:e,max:r}}const F=34,Q=6,V=6,dt=14,j=260;function pt(t){return Math.abs(t)>=100?t.toFixed(0):Math.abs(t)>=1?String(Math.round(t*100)/100):String(Math.round(t*1e3)/1e3)}function At({value:t,onChange:e,onChangeEnd:r,disabled:o,height:a=90,color:l,testId:c="curve-editor"}){const[s,d]=b.useState(0),m=b.useRef(null),i=b.useRef(null),h=b.useMemo(()=>ct(t),[t]),g=b.useMemo(()=>{const{min:n,max:u}=lt(t);if(u-n<1e-6)return{min:n-1,max:u+1};const f=(u-n)*.1;return{min:n-f,max:u+f}},[t]),A=j-F-Q,I=a-V-dt,D=n=>F+n*A,S=n=>V+(1-(n-g.min)/(g.max-g.min))*I,X=n=>Math.max(0,Math.min(1,(n-F)/A)),Z=n=>g.min+(1-(n-V)/I)*(g.max-g.min),P=n=>{const u=m.current?.getBoundingClientRect();if(!u)return{t:0,v:0};const f=(n.clientX-u.left)/u.width*j,T=(n.clientY-u.top)/u.height*a;return{t:X(f),v:Z(T)}},tt=b.useMemo(()=>{if(t.length===0)return"";let n=`M ${D(t[0].start)} ${S(t[0].function.p0)}`;for(let u=0;u<t.length;u++){const f=t[u],T=v(t,u),y=T-f.start;n+=` C ${D(f.start+y/3)} ${S(f.function.p1)}, ${D(f.start+2*y/3)} ${S(f.function.p2)}, ${D(T)} ${S(f.function.p3)}`}return n},[t,g,a]),w=n=>rt({onChange:e,onChangeEnd:r},n),H=n=>it({onChange:e},n),$=(n,u)=>{if(o)return;n.preventDefault(),n.stopPropagation(),i.current=t;const f=y=>{const{t:_,v:W}=P(y),L=u(i.current??t,_,W);i.current=L,H(L)},T=y=>{const{t:_,v:W}=P(y),L=u(i.current??t,_,W);i.current=null,w(L),window.removeEventListener("pointermove",f),window.removeEventListener("pointerup",T)};window.addEventListener("pointermove",f),window.addEventListener("pointerup",T)},K=l??E.accent,J=t.length,x=h[s],z=s>0&&s<J,O=s<J?t[s]:void 0,k=s>0?t[s-1]:void 0,R=O?{x:D(O.start+(v(t,s)-O.start)/3),y:S(O.function.p1)}:null,N=k?{x:D(k.start+(v(t,s-1)-k.start)*2/3),y:S(k.function.p2)}:null,et=[g.min,(g.min+g.max)/2,g.max];return p.jsxs("div",{"data-testid":c,children:[p.jsxs("svg",{ref:m,"data-testid":`${c}-plot`,viewBox:`0 0 ${j} ${a}`,style:{width:"100%",height:a,display:"block",background:E.inputBg,border:`1px solid ${E.border}`,borderRadius:E.radiusSmall,touchAction:"none",outline:"none"},tabIndex:0,role:"application","aria-label":"Curve editor",onKeyDown:n=>{(n.key==="Delete"||n.key==="Backspace")&&z&&!o&&(n.preventDefault(),w(Y(t,s)),d(Math.max(0,s-1)))},onDoubleClick:n=>{if(o)return;const{t:u}=P(n),f=ut(t,u);f!==t&&(w(f),d(f.findIndex(T=>Math.abs(T.start-u)<1e-6)))},children:[et.map(n=>p.jsxs("g",{children:[p.jsx("line",{x1:F,x2:j-Q,y1:S(n),y2:S(n),stroke:E.border,strokeWidth:.5}),p.jsx("text",{x:F-3,y:S(n)+2.5,fontSize:7,fill:E.textMuted,textAnchor:"end",children:pt(n)})]},n)),[0,.5,1].map(n=>p.jsx("text",{x:D(n),y:a-3,fontSize:7,fill:E.textMuted,textAnchor:"middle",children:n},n)),p.jsx("path",{d:tt,fill:"none",stroke:K,strokeWidth:1.5}),x&&R&&p.jsxs("g",{children:[p.jsx("line",{x1:D(x.time),y1:S(x.value),x2:R.x,y2:R.y,stroke:E.textMuted,strokeDasharray:"2 2",strokeWidth:.75}),p.jsx("circle",{"data-testid":`${c}-tangent-out`,cx:R.x,cy:R.y,r:3,fill:E.surface,stroke:E.textMuted,style:{cursor:o?"not-allowed":"ns-resize"},onPointerDown:n=>$(n,(u,f,T)=>q(u,s,"out",T))})]}),x&&N&&p.jsxs("g",{children:[p.jsx("line",{x1:D(x.time),y1:S(x.value),x2:N.x,y2:N.y,stroke:E.textMuted,strokeDasharray:"2 2",strokeWidth:.75}),p.jsx("circle",{"data-testid":`${c}-tangent-in`,cx:N.x,cy:N.y,r:3,fill:E.surface,stroke:E.textMuted,style:{cursor:o?"not-allowed":"ns-resize"},onPointerDown:n=>$(n,(u,f,T)=>q(u,s,"in",T))})]}),h.map((n,u)=>p.jsx("circle",{"data-testid":`${c}-key-${u}`,cx:D(n.time),cy:S(n.value),r:4,fill:u===s?E.accent:E.surface,stroke:u===s?E.onAccent:K,strokeWidth:1.25,style:{cursor:o?"not-allowed":"move"},onPointerDown:f=>{d(u),$(f,(T,y,_)=>C(T,u,y,_))}},u))]}),p.jsxs("div",{style:{display:"flex",gap:4,alignItems:"center",marginTop:3},children:[p.jsxs("span",{style:{fontSize:9,color:E.textMuted,flex:"0 0 auto"},children:["Key ",s+1,"/",h.length]}),p.jsx(U,{label:"t",value:x?Math.round(x.time*1e3)/1e3:null,step:.05,testId:`${c}-key-time`,onChange:n=>{x&&H(C(t,s,n,x.value))},onChangeEnd:n=>{x&&w(C(t,s,n,x.value))}}),p.jsx(U,{label:"v",value:x?Math.round(x.value*1e3)/1e3:null,step:.05,testId:`${c}-key-value`,onChange:n=>{x&&H(C(t,s,x.time,n))},onChangeEnd:n=>{x&&w(C(t,s,x.time,n))}}),p.jsx(at,{type:"button",variant:"ghost",size:"compact","data-testid":`${c}-delete-key`,disabled:!z||o===!0,"aria-label":"Delete curve key",title:z?"Delete key":"Endpoint keys cannot be deleted",onClick:()=>{w(Y(t,s)),d(Math.max(0,s-1))},children:"×"})]})]})}export{wt as Actions,ps as AlignmentGrid,fs as AnchorPresets,nt as AnchoredMenu,Rt as AssetSlotPicker,hs as BorderEditor,ms as BorderRadiusEditor,at as Button,Nt as CLASSIC_MATERIAL,_t as Checkbox,ls as ColorInput,Bs as ColorPicker,Gs as ColorSwatch,Ct as ColorSwatchInput,At as CurveEditor,Ft as DEFAULT_ICON_SET_ID,xs as DEFAULT_SHADOW,Es as DEFAULT_TEXT_SHADOW,Ot as Dialog,kt as DialogBody,Lt as DialogField,jt as DialogFieldLabel,Bt as DialogFooter,Gt as DialogHeader,Pt as DisclosureIcon,Ht as Divider,$t as DraftTextInput,zt as DropIndicator,Wt as EDITOR_CATEGORY_NAMES,Vt as EDITOR_MATERIALS,Kt as EDITOR_MATERIAL_IDS,Jt as EDITOR_REGION_NAMES,Ut as EDITOR_THEME_CLASS,qt as EditorBadge,Yt as EditorBanner,Qt as EditorIcon,Xt as EditorListButton,Zt as EditorPopover,te as EditorSurface,ee as EditorTab,ne as EditorTabList,se as EditorToolbar,oe as EditorTree,ae as EditorTreeRow,re as FONT,ie as FONT_MONO,ce as FieldGroup,ue as FieldLabel,le as FieldRow,de as FileInput,gs as FilterEditor,pe as FloatingToolbar,Ss as FontPicker,fe as GLASS_MATERIAL,Ts as GradientEditor,bs as GradientStopsTrack,Dt as HoverPreview,he as IconButton,me as Inline,xe as InteractiveEditScopeContext,Ee as JoinedField,ge as JoinedFieldSuffix,Mt as JsonInput,Se as Keycap,Te as LABEL_COL_WIDTH,be as Menu,De as MenuItem,Me as MenuSeparator,ye as MenuSubmenu,Ae as MenuTrigger,U as NumberInput,Ie as Panel,Ds as QuarksGradientEditor,ve as RangeInput,we as ResizeHandle,Re as STAGE_WORD_MODES,Ms as ScrubbableInput,Ne as SectionHeader,_e as Select,ys as ShadowEditor,As as ShadowListEditor,Ce as Spacer,Fe as SplitButtonGroup,Oe as Stack,ke as StateSurface,E as THEME,Le as TONE_ERROR,je as TONE_WARNING,Be as Text,Ge as TextArea,st as TextInput,Is as TextShadowEditor,Pe as ThemeRootPortal,He as ToggleButton,$e as ToolbarDivider,ze as ToolbarGroup,We as Tooltip,Ve as TreeDisclosureIcon,Ke as Vec3Input,Je as accent,Ue as accentMuted,qe as activeIconGlyph,Ye as activeIconSetSnapshot,Qe as applyEditorTheme,Xe as areaEmbossValue,Ze as bg,tn as border,en as chromeSize,nn as clampRectToViewport,sn as composeEditorAppearance,vs as composeFilter,ws as composeGradient,Rs as composeShadows,on as controlSize,ct as curveKeys,lt as curveValueRange,an as danger,rn as dangerFaint,cn as dangerMuted,Y as deleteKey,un as dynamic,ln as dynamicBg,dn as editorIconSets,pn as editorIcons,fn as editorMaterials,hn as editorThemeVariables,mn as editorThemes,xn as fieldLabelStyle,it as fireChange,rt as fireEnd,En as focusFirstMenuItem,gn as focusRing,Sn as fontMono,Tn as fontSans,bn as fontSize,Dn as fontSizeVar,Mn as fontWeight,yn as glassDarkEditorTheme,An as glassDarkLiteEditorTheme,In as graphiteDarkEditorTheme,vn as graphiteNeutralEditorTheme,wn as groupLabelStyle,Ps as hexToRgb,Rn as iconSize,Nn as isEditorIconSetId,_n as isEditorMaterialId,Cn as isEditorThemeId,Ns as isUniformBorder,_s as isUniformRadius,Fn as lineHeight,On as lineHeightVar,kn as liquidGlassEditorTheme,Ln as liquidGlassLiteEditorTheme,jn as midnightHighContrastEditorTheme,Bn as motion,Gn as motionVar,C as moveKey,q as moveTangent,Hs as parseAlpha,Cs as parseFilterFunctions,Fs as parseGradient,Pn as parseNumericValue,Os as parseShadows,Hn as radius,$n as regionRowAltValue,zn as registerContributedIconSet,Wn as registerContributedMaterial,Vn as rowStyle,yt as sampleCurve,Kn as scrim,v as segmentEnd,Jn as selection,Un as setActiveIconSet,qn as shadow,Yn as space,Qn as spaceVar,ut as splitAt,Xn as strokeWidth,Zn as subscribeEditorMaterials,ts as subscribeIconSets,es as success,ns as successMuted,ss as text,ot as themeVars,$s as toHex,ks as uniformBorder,Ls as uniformRadius,os as useInteractiveEditScope,as as usesGlassMaterial,rs as warn,is as warnMuted,cs as zIndex};
|
|
1
|
+
import{bA as nt,aN as st,al as ot,e4 as E,dV as U,a6 as at,e6 as rt,e5 as it}from"./index-DyTgGJaV.js";import{hp as wt,hq as Rt,hr as Nt,aS as _t,dX as Ct,hs as Ft,ht as Ot,hu as kt,hv as Lt,hw as jt,hx as Bt,hy as Gt,eJ as Pt,hz as Ht,e_ as $t,hA as zt,hB as Wt,hC as Vt,hD as Kt,hE as Jt,dz as Ut,hF as qt,bQ as Yt,a7 as Qt,eq as Xt,bP as Zt,h1 as te,hG as ee,hH as ne,bv as se,hI as oe,hJ as ae,hK as re,eY as ie,fe as ce,hL as ue,ff as le,hM as de,d9 as pe,hN as fe,aM as he,df as me,hO as xe,hP as Ee,hQ as ge,dg as Se,f1 as Te,fz as be,bB as De,bC as Me,fN as ye,hR as Ae,hS as Ie,aT as ve,hT as we,hU as Re,aU as Ne,bH as _e,hV as Ce,db as Fe,de as Oe,eB as ke,hW as Le,hX as je,aL as Be,e$ as Ge,hY as Pe,hZ as He,gK as $e,h_ as ze,bw as We,h$ as Ve,i0 as Ke,es as Je,i1 as Ue,i2 as qe,i3 as Ye,i4 as Qe,i5 as Xe,eo as Ze,ep as tn,i6 as en,i7 as nn,i8 as sn,i9 as on,ev as an,ia as rn,ib as cn,ic as un,id as ln,ie as dn,a8 as pn,ig as fn,ih as hn,ii as mn,ij as xn,ik as En,il as gn,ew as Sn,im as Tn,io as bn,et as Dn,ip as Mn,iq as yn,ir as An,dA as In,is as vn,it as wn,iu as Rn,iv as Nn,iw as _n,ix as Cn,iy as Fn,eW as On,iz as kn,iA as Ln,iB as jn,iC as Bn,iD as Gn,iE as Pn,ex as Hn,iF as $n,iG as zn,iH as Wn,f0 as Vn,iI as Kn,iJ as Jn,iK as Un,iL as qn,dq as Yn,er as Qn,iM as Xn,iN as Zn,iO as ts,eu as es,iP as ns,aZ as ss,dW as os,iQ as as,iR as rs,iS as is,dp as cs}from"./index-DyTgGJaV.js";import{C as ls}from"./ColorInput-NuZ1WtIR.js";import{a as p}from"./jsx-runtime-DPjLkJKQ.js";import{r as b}from"./index-nmcBqr7Y.js";import{A as ps,k as fs,B as hs,a as ms,D as xs,l as Es,F as gs,h as Ss,G as Ts,m as bs,Q as Ds,S as Ms,f as ys,n as As,T as Is,d as vs,c as ws,g as Rs,i as Ns,j as _s,b as Cs,p as Fs,e as Os,u as ks,o as Ls}from"./ShadowEditor-axHBX3ZT.js";import{a as Bs,C as Gs,h as Ps,p as Hs,t as $s}from"./ColorPicker-DYngmfYK.js";import"./index-CtzuWnCS.js";import"./index-FUuS4qwW.js";import"./client-DNXj_opT.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./index-D_NuPfjr.js";import"./index-CinJrH5C.js";function Dt({preview:t,children:e,...r}){const[o,a]=b.useState(!1),l=b.useRef(null),c=b.useId(),s=()=>a(!1),d=i=>{l.current=i,a(!0)};let m=e;if(b.isValidElement(e)){const i=[e.props["aria-describedby"],o?c:null].filter(Boolean).join(" ");m=b.cloneElement(e,i?{"aria-describedby":i}:{})}return p.jsxs("span",{className:"volter-tooltip-anchor",onMouseEnter:i=>d(i.currentTarget),onMouseLeave:s,onFocusCapture:i=>d(i.currentTarget),onBlurCapture:i=>{i.currentTarget.contains(i.relatedTarget)||s()},onKeyDown:i=>{i.key!=="Escape"||!o||(i.preventDefault(),i.stopPropagation(),s())},children:[m,o&&l.current&&p.jsx(nt,{...r,anchorRef:l,id:c,role:"tooltip",autoFocusFirst:!1,onDismiss:s,children:t})]})}function Mt({value:t,onCommit:e,style:r,disabled:o=!1}){const a=t===void 0?"":JSON.stringify(t),[l,c]=b.useState(a),[s,d]=b.useState(!1),m=b.useRef(!1);b.useEffect(()=>{c(a),d(!1)},[a]);const i=()=>{if(m.current){m.current=!1;return}if(l===a){d(!1);return}let h;try{h=JSON.parse(l)}catch{d(!0);return}d(!1),e(h)};return p.jsxs("div",{children:[p.jsx(st,{"data-testid":"json-input","aria-invalid":s||void 0,"data-tone":s?"danger":void 0,disabled:o,value:l,onChange:h=>{c(h.target.value),s&&d(!1)},onBlur:i,onKeyDown:h=>{h.key==="Enter"?i():h.key==="Escape"&&(m.current=!0,c(a),d(!1),h.target.blur())},style:r,title:s?"Not valid JSON — nothing written. Fix the JSON or press Escape to revert.":void 0}),s&&p.jsx("div",{"data-testid":"json-input-error",style:{fontSize:"var(--volter-font-sm)",color:ot.semantic.danger,marginTop:2},children:"Not valid JSON — nothing written. Fix the JSON or press Escape to revert."})]})}function v(t,e){return e+1<t.length?t[e+1].start:1}function ct(t){const e=t.map(o=>({time:o.start,value:o.function.p0})),r=t[t.length-1];return r&&e.push({time:1,value:r.function.p3}),e}function G(t){return t.map(e=>({start:e.start,function:{...e.function}}))}const B=.01;function C(t,e,r,o){const a=G(t),l=a.length;if(e<0||e>l)return a;if(e<l){const c=a[e],s=o-c.function.p0;if(c.function.p0=o,c.function.p1+=s,e>0){const d=a[e-1],m=o-d.function.p3;d.function.p3=o,d.function.p2+=m;const i=d.start+B,h=v(a,e)-B;c.start=Math.min(h,Math.max(i,r))}}else{const c=a[l-1],s=o-c.function.p3;c.function.p3=o,c.function.p2+=s}return a}function q(t,e,r,o){const a=G(t);return r==="out"&&e<a.length?a[e].function.p1=o:r==="in"&&e>0&&e<=a.length&&(a[e-1].function.p2=o),a}function M(t,e,r){return t+(e-t)*r}function yt(t,e){for(let r=0;r<t.length;r++){const o=t[r].start,a=v(t,r);if(e>=o&&e<=a){const l=a>o?(e-o)/(a-o):0,{p0:c,p1:s,p2:d,p3:m}=t[r].function,i=M(c,s,l),h=M(s,d,l),g=M(d,m,l),A=M(i,h,l),I=M(h,g,l);return M(A,I,l)}}return 0}function ut(t,e){for(let r=0;r<t.length;r++){const o=t[r].start,a=v(t,r);if(e<=o+B||e>=a-B||e<o||e>a)continue;const l=(e-o)/(a-o),{p0:c,p1:s,p2:d,p3:m}=t[r].function,i=M(c,s,l),h=M(s,d,l),g=M(d,m,l),A=M(i,h,l),I=M(h,g,l),D=M(A,I,l),S=G(t);return S.splice(r,1,{start:o,function:{p0:c,p1:i,p2:A,p3:D}},{start:e,function:{p0:D,p1:I,p2:g,p3:m}}),S}return t}function Y(t,e){if(e<=0||e>=t.length)return t;const r=t[e-1],o=t[e],a=o.start-r.start,l=v(t,e)-o.start,c=a+l;if(c<=0)return t;const s=r.function,d=o.function,m={start:r.start,function:{p0:s.p0,p1:s.p0+(s.p1-s.p0)*(a>0?c/a:1),p2:d.p3+(d.p2-d.p3)*(l>0?c/l:1),p3:d.p3}},i=G(t);return i.splice(e-1,2,m),i}function lt(t){let e=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;for(const o of t)for(const a of[o.function.p0,o.function.p1,o.function.p2,o.function.p3])a<e&&(e=a),a>r&&(r=a);return!Number.isFinite(e)||!Number.isFinite(r)?{min:0,max:1}:{min:e,max:r}}const F=34,Q=6,V=6,dt=14,j=260;function pt(t){return Math.abs(t)>=100?t.toFixed(0):Math.abs(t)>=1?String(Math.round(t*100)/100):String(Math.round(t*1e3)/1e3)}function At({value:t,onChange:e,onChangeEnd:r,disabled:o,height:a=90,color:l,testId:c="curve-editor"}){const[s,d]=b.useState(0),m=b.useRef(null),i=b.useRef(null),h=b.useMemo(()=>ct(t),[t]),g=b.useMemo(()=>{const{min:n,max:u}=lt(t);if(u-n<1e-6)return{min:n-1,max:u+1};const f=(u-n)*.1;return{min:n-f,max:u+f}},[t]),A=j-F-Q,I=a-V-dt,D=n=>F+n*A,S=n=>V+(1-(n-g.min)/(g.max-g.min))*I,X=n=>Math.max(0,Math.min(1,(n-F)/A)),Z=n=>g.min+(1-(n-V)/I)*(g.max-g.min),P=n=>{const u=m.current?.getBoundingClientRect();if(!u)return{t:0,v:0};const f=(n.clientX-u.left)/u.width*j,T=(n.clientY-u.top)/u.height*a;return{t:X(f),v:Z(T)}},tt=b.useMemo(()=>{if(t.length===0)return"";let n=`M ${D(t[0].start)} ${S(t[0].function.p0)}`;for(let u=0;u<t.length;u++){const f=t[u],T=v(t,u),y=T-f.start;n+=` C ${D(f.start+y/3)} ${S(f.function.p1)}, ${D(f.start+2*y/3)} ${S(f.function.p2)}, ${D(T)} ${S(f.function.p3)}`}return n},[t,g,a]),w=n=>rt({onChange:e,onChangeEnd:r},n),H=n=>it({onChange:e},n),$=(n,u)=>{if(o)return;n.preventDefault(),n.stopPropagation(),i.current=t;const f=y=>{const{t:_,v:W}=P(y),L=u(i.current??t,_,W);i.current=L,H(L)},T=y=>{const{t:_,v:W}=P(y),L=u(i.current??t,_,W);i.current=null,w(L),window.removeEventListener("pointermove",f),window.removeEventListener("pointerup",T)};window.addEventListener("pointermove",f),window.addEventListener("pointerup",T)},K=l??E.accent,J=t.length,x=h[s],z=s>0&&s<J,O=s<J?t[s]:void 0,k=s>0?t[s-1]:void 0,R=O?{x:D(O.start+(v(t,s)-O.start)/3),y:S(O.function.p1)}:null,N=k?{x:D(k.start+(v(t,s-1)-k.start)*2/3),y:S(k.function.p2)}:null,et=[g.min,(g.min+g.max)/2,g.max];return p.jsxs("div",{"data-testid":c,children:[p.jsxs("svg",{ref:m,"data-testid":`${c}-plot`,viewBox:`0 0 ${j} ${a}`,style:{width:"100%",height:a,display:"block",background:E.inputBg,border:`1px solid ${E.border}`,borderRadius:E.radiusSmall,touchAction:"none",outline:"none"},tabIndex:0,role:"application","aria-label":"Curve editor",onKeyDown:n=>{(n.key==="Delete"||n.key==="Backspace")&&z&&!o&&(n.preventDefault(),w(Y(t,s)),d(Math.max(0,s-1)))},onDoubleClick:n=>{if(o)return;const{t:u}=P(n),f=ut(t,u);f!==t&&(w(f),d(f.findIndex(T=>Math.abs(T.start-u)<1e-6)))},children:[et.map(n=>p.jsxs("g",{children:[p.jsx("line",{x1:F,x2:j-Q,y1:S(n),y2:S(n),stroke:E.border,strokeWidth:.5}),p.jsx("text",{x:F-3,y:S(n)+2.5,fontSize:7,fill:E.textMuted,textAnchor:"end",children:pt(n)})]},n)),[0,.5,1].map(n=>p.jsx("text",{x:D(n),y:a-3,fontSize:7,fill:E.textMuted,textAnchor:"middle",children:n},n)),p.jsx("path",{d:tt,fill:"none",stroke:K,strokeWidth:1.5}),x&&R&&p.jsxs("g",{children:[p.jsx("line",{x1:D(x.time),y1:S(x.value),x2:R.x,y2:R.y,stroke:E.textMuted,strokeDasharray:"2 2",strokeWidth:.75}),p.jsx("circle",{"data-testid":`${c}-tangent-out`,cx:R.x,cy:R.y,r:3,fill:E.surface,stroke:E.textMuted,style:{cursor:o?"not-allowed":"ns-resize"},onPointerDown:n=>$(n,(u,f,T)=>q(u,s,"out",T))})]}),x&&N&&p.jsxs("g",{children:[p.jsx("line",{x1:D(x.time),y1:S(x.value),x2:N.x,y2:N.y,stroke:E.textMuted,strokeDasharray:"2 2",strokeWidth:.75}),p.jsx("circle",{"data-testid":`${c}-tangent-in`,cx:N.x,cy:N.y,r:3,fill:E.surface,stroke:E.textMuted,style:{cursor:o?"not-allowed":"ns-resize"},onPointerDown:n=>$(n,(u,f,T)=>q(u,s,"in",T))})]}),h.map((n,u)=>p.jsx("circle",{"data-testid":`${c}-key-${u}`,cx:D(n.time),cy:S(n.value),r:4,fill:u===s?E.accent:E.surface,stroke:u===s?E.onAccent:K,strokeWidth:1.25,style:{cursor:o?"not-allowed":"move"},onPointerDown:f=>{d(u),$(f,(T,y,_)=>C(T,u,y,_))}},u))]}),p.jsxs("div",{style:{display:"flex",gap:4,alignItems:"center",marginTop:3},children:[p.jsxs("span",{style:{fontSize:9,color:E.textMuted,flex:"0 0 auto"},children:["Key ",s+1,"/",h.length]}),p.jsx(U,{label:"t",value:x?Math.round(x.time*1e3)/1e3:null,step:.05,testId:`${c}-key-time`,onChange:n=>{x&&H(C(t,s,n,x.value))},onChangeEnd:n=>{x&&w(C(t,s,n,x.value))}}),p.jsx(U,{label:"v",value:x?Math.round(x.value*1e3)/1e3:null,step:.05,testId:`${c}-key-value`,onChange:n=>{x&&H(C(t,s,x.time,n))},onChangeEnd:n=>{x&&w(C(t,s,x.time,n))}}),p.jsx(at,{type:"button",variant:"ghost",size:"compact","data-testid":`${c}-delete-key`,disabled:!z||o===!0,"aria-label":"Delete curve key",title:z?"Delete key":"Endpoint keys cannot be deleted",onClick:()=>{w(Y(t,s)),d(Math.max(0,s-1))},children:"×"})]})]})}export{wt as Actions,ps as AlignmentGrid,fs as AnchorPresets,nt as AnchoredMenu,Rt as AssetSlotPicker,hs as BorderEditor,ms as BorderRadiusEditor,at as Button,Nt as CLASSIC_MATERIAL,_t as Checkbox,ls as ColorInput,Bs as ColorPicker,Gs as ColorSwatch,Ct as ColorSwatchInput,At as CurveEditor,Ft as DEFAULT_ICON_SET_ID,xs as DEFAULT_SHADOW,Es as DEFAULT_TEXT_SHADOW,Ot as Dialog,kt as DialogBody,Lt as DialogField,jt as DialogFieldLabel,Bt as DialogFooter,Gt as DialogHeader,Pt as DisclosureIcon,Ht as Divider,$t as DraftTextInput,zt as DropIndicator,Wt as EDITOR_CATEGORY_NAMES,Vt as EDITOR_MATERIALS,Kt as EDITOR_MATERIAL_IDS,Jt as EDITOR_REGION_NAMES,Ut as EDITOR_THEME_CLASS,qt as EditorBadge,Yt as EditorBanner,Qt as EditorIcon,Xt as EditorListButton,Zt as EditorPopover,te as EditorSurface,ee as EditorTab,ne as EditorTabList,se as EditorToolbar,oe as EditorTree,ae as EditorTreeRow,re as FONT,ie as FONT_MONO,ce as FieldGroup,ue as FieldLabel,le as FieldRow,de as FileInput,gs as FilterEditor,pe as FloatingToolbar,Ss as FontPicker,fe as GLASS_MATERIAL,Ts as GradientEditor,bs as GradientStopsTrack,Dt as HoverPreview,he as IconButton,me as Inline,xe as InteractiveEditScopeContext,Ee as JoinedField,ge as JoinedFieldSuffix,Mt as JsonInput,Se as Keycap,Te as LABEL_COL_WIDTH,be as Menu,De as MenuItem,Me as MenuSeparator,ye as MenuSubmenu,Ae as MenuTrigger,U as NumberInput,Ie as Panel,Ds as QuarksGradientEditor,ve as RangeInput,we as ResizeHandle,Re as STAGE_WORD_MODES,Ms as ScrubbableInput,Ne as SectionHeader,_e as Select,ys as ShadowEditor,As as ShadowListEditor,Ce as Spacer,Fe as SplitButtonGroup,Oe as Stack,ke as StateSurface,E as THEME,Le as TONE_ERROR,je as TONE_WARNING,Be as Text,Ge as TextArea,st as TextInput,Is as TextShadowEditor,Pe as ThemeRootPortal,He as ToggleButton,$e as ToolbarDivider,ze as ToolbarGroup,We as Tooltip,Ve as TreeDisclosureIcon,Ke as Vec3Input,Je as accent,Ue as accentMuted,qe as activeIconGlyph,Ye as activeIconSetSnapshot,Qe as applyEditorTheme,Xe as areaEmbossValue,Ze as bg,tn as border,en as chromeSize,nn as clampRectToViewport,sn as composeEditorAppearance,vs as composeFilter,ws as composeGradient,Rs as composeShadows,on as controlSize,ct as curveKeys,lt as curveValueRange,an as danger,rn as dangerFaint,cn as dangerMuted,Y as deleteKey,un as dynamic,ln as dynamicBg,dn as editorIconSets,pn as editorIcons,fn as editorMaterials,hn as editorThemeVariables,mn as editorThemes,xn as fieldLabelStyle,it as fireChange,rt as fireEnd,En as focusFirstMenuItem,gn as focusRing,Sn as fontMono,Tn as fontSans,bn as fontSize,Dn as fontSizeVar,Mn as fontWeight,yn as glassDarkEditorTheme,An as glassDarkLiteEditorTheme,In as graphiteDarkEditorTheme,vn as graphiteNeutralEditorTheme,wn as groupLabelStyle,Ps as hexToRgb,Rn as iconSize,Nn as isEditorIconSetId,_n as isEditorMaterialId,Cn as isEditorThemeId,Ns as isUniformBorder,_s as isUniformRadius,Fn as lineHeight,On as lineHeightVar,kn as liquidGlassEditorTheme,Ln as liquidGlassLiteEditorTheme,jn as midnightHighContrastEditorTheme,Bn as motion,Gn as motionVar,C as moveKey,q as moveTangent,Hs as parseAlpha,Cs as parseFilterFunctions,Fs as parseGradient,Pn as parseNumericValue,Os as parseShadows,Hn as radius,$n as regionRowAltValue,zn as registerContributedIconSet,Wn as registerContributedMaterial,Vn as rowStyle,yt as sampleCurve,Kn as scrim,v as segmentEnd,Jn as selection,Un as setActiveIconSet,qn as shadow,Yn as space,Qn as spaceVar,ut as splitAt,Xn as strokeWidth,Zn as subscribeEditorMaterials,ts as subscribeIconSets,es as success,ns as successMuted,ss as text,ot as themeVars,$s as toHex,ks as uniformBorder,Ls as uniformRadius,os as useInteractiveEditScope,as as usesGlassMaterial,rs as warn,is as warnMuted,cs as zIndex};
|