@higgsfield/video-editor-mcp 1.0.7 → 1.1.1-dev.0
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/THIRD_PARTY_NOTICES.md +24 -24
- package/dist/cli.mjs +134 -125
- package/dist/index.html +136 -133
- package/dist/launcher.mjs +90 -90
- package/dist/server.mjs +1553 -1389
- package/node_modules/@higgsfield/higgsedit/README.md +181 -1
- package/node_modules/@higgsfield/higgsedit/dist/capture-page.js +902 -314
- package/node_modules/@higgsfield/higgsedit/dist/chunk-2JYLVSVV.mjs +1594 -0
- package/node_modules/@higgsfield/higgsedit/dist/chunk-2WKNH7OL.mjs +16 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-OMKZ5BXM.mjs → chunk-5LTTL3Q3.mjs} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/chunk-7PYXSJS7.mjs +717 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-MLJAIZGP.mjs → chunk-BH2QF635.mjs} +33 -326
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-WZR5PZM7.mjs → chunk-BV5COOQZ.mjs} +250 -161
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-HTCYVKFX.mjs → chunk-C3GSB3XZ.mjs} +8 -7
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-CYH2EUQV.mjs → chunk-DVN4LUXV.mjs} +13 -4
- package/node_modules/@higgsfield/higgsedit/dist/chunk-F4CMIG5G.mjs +36 -0
- package/node_modules/@higgsfield/higgsedit/dist/chunk-IEPPEDEU.mjs +33 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-UVAZ6I6U.mjs → chunk-KIWGVAPJ.mjs} +16 -12
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-L6QDNSL3.mjs → chunk-L5LWBA6A.mjs} +5 -5
- package/node_modules/@higgsfield/higgsedit/dist/chunk-LMQR3DHT.mjs +37 -0
- package/node_modules/@higgsfield/higgsedit/dist/chunk-LTKMGZ6T.mjs +58 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-VI6IV6JP.mjs → chunk-MV2JTTBQ.mjs} +65 -47
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-4D6AXU4B.mjs → chunk-NARTAWRN.mjs} +50 -30
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-27NBQ5FA.mjs → chunk-NUXTKQNM.mjs} +33 -21
- package/node_modules/@higgsfield/higgsedit/dist/chunk-OCIZ36XD.mjs +40 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-MK6PL7N4.mjs → chunk-OF6RMSM2.mjs} +19 -17
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-6BETMESC.mjs → chunk-P2BGHTRR.mjs} +2 -2
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-EKFC4S4M.mjs → chunk-PAHMD6SU.mjs} +5 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-QVLAEV3U.mjs → chunk-PFQYUJQL.mjs} +3 -4
- package/node_modules/@higgsfield/higgsedit/dist/chunk-QJTILFBS.mjs +335 -0
- package/node_modules/@higgsfield/higgsedit/dist/chunk-QQ3GGKDN.mjs +21 -0
- package/node_modules/@higgsfield/higgsedit/dist/chunk-TH7TK67K.mjs +23 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-SIMO6I3D.mjs → chunk-UDL5AHKO.mjs} +163 -158
- package/node_modules/@higgsfield/higgsedit/dist/chunk-UMWOUQN3.mjs +60 -0
- package/node_modules/@higgsfield/higgsedit/dist/{chunk-3AIM3THH.mjs → chunk-VLM5EOWJ.mjs} +4 -4
- package/node_modules/@higgsfield/higgsedit/dist/chunk-WENFTPXQ.mjs +403 -0
- package/node_modules/@higgsfield/higgsedit/dist/chunk-YLVXQIPX.mjs +464 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/.vite/manifest.json +559 -506
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/agent-corner-bottom-q4hZltI-.svg +431 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/agent-corner-top-BJYI-I24.svg +431 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/confirmation-BTnwl3LS.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/drag-Bt_t4HZO.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/local-B3OTAV_A.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/menubar-2Y1Y2XJt.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/model-DdE4hCgf.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/{IconText1-CzbCrP7v.css → notifications-B08L1jSe.css} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/{panel-g852pZf_.css → panel-BRN_AbBM.css} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-CYELNqrv.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-DYLpT6oA.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-v84HaGTZ.css +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconChainLink1-Bxb1Or0F.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconCheckmark2Medium-daaES9uF.js → IconCheckmark2Medium-hegaz9mQ.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconChevronDownSmall-BhTBJk26.js → IconChevronDownSmall-DaruzJwU.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconClosedCaptioning-BPqcqKsD.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconCrossMedium-acfnCXOM.js → IconCrossMedium-BsPFJzc6.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconOpenaiFilled-D1fzthmi.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconPause-pTeVSvUe.js → IconPause-ClNg8pao.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconPlayFilled-CwdgIuDG.js → IconPlayFilled-CHb-7GSx.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconSparklesSoftFilled-o7o33KRn.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/ai-composer-B9h-eaki.js +567 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/auto-layout-BO20Tg4B.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{button-CjG6GcgF.js → button-Cg0U0zpV.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/canvas-Bw4CVzfw.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/capabilities-BCd4-zPF.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/commands-QeSqAbCt.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/components-tXMtIZNL.js +51 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/confirmation-CO2PHR_z.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/dom-6aoQn29n.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/drag-Dw8b_vO2.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{editing-CjWbiCxv.js → editing-Cy-SaOyB.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/edits-CqLBqir0.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/export-dialog-BjBskOe3.js +2 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/factories-Bw_iQrUL.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/id3-CSR0NCRI.js +2 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/import-DP49i4ke.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/import-error-CMz9sLPe.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/ingest-DsmIc415.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/jsx-runtime-B5yqYJvp.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{media-Bwjxu-0U.js → media-DQw6vU_T.js} +1 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/menubar-D31srALX.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/meters-D0nZVEJs.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/mode-DEG6doKF.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/model-Duf9fszJ.js +2 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/model-DyAkLA69.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/notifications-DqWZNIrK.js +9 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/palette-HT83gWgL.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-B5Mvm6dg.js +7 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-BC90wyvd.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-Bw_ZJ2JI.js +3 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DNS060Nt.js +3 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DSgxIrEq.js +2 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DgBttE5O.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-assets-_T2bHsHW.js +771 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-inspector-DfHvAt5X.js +2 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-nBZvHlkA.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-timeline-DsCpJVSt.js +327 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-viewport-CEhZwZ67.js +280 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/projects-2_tW9Do7.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/react-dom-1uB7Vbbb.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/schemas-CddYAOcj.js +64 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/session-BpFeKAI2.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/src-BLG3tYBa.js +2 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/styles-e2n2A_JN.js +284 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/supercomputer-CuV0zYKd.js +24 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/tabs-XeAgs9cs.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/toggle-DbNEaSIl.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-C8Ll3qFl.js +69 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-bar-Dv1LPFbu.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useOpenInteractionType-HWSfSsp2.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useRenderElement-D4SOg3N_.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/value-EB7YmAdS.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/writeback-support-fj5rA9k3.js +1 -0
- package/node_modules/@higgsfield/higgsedit/dist/editor/editor-B-WAkLt7.js +372 -0
- package/node_modules/@higgsfield/higgsedit/dist/higgsedit.mjs +39 -24
- package/node_modules/@higgsfield/higgsedit/dist/jsx/hooks.d.ts +26 -0
- package/node_modules/@higgsfield/higgsedit/dist/jsx/index.d.ts +17 -0
- package/node_modules/@higgsfield/higgsedit/dist/jsx/inspect.d.ts +42 -0
- package/node_modules/@higgsfield/higgsedit/dist/jsx/jsx-runtime.d.ts +28 -0
- package/node_modules/@higgsfield/higgsedit/dist/jsx/svg.d.ts +9 -0
- package/node_modules/@higgsfield/higgsedit/dist/jsx/time.d.ts +6 -0
- package/node_modules/@higgsfield/higgsedit/dist/jsx/types.d.ts +420 -0
- package/node_modules/@higgsfield/higgsedit/package.json +28 -20
- package/package.json +4 -3
- package/plugin/.codex-plugin/plugin.json +1 -1
- package/plugin/plugin.json +1 -1
- package/plugin/skills/video-editing/references/caption-titling.md +1 -1
- package/plugin/skills/video-editing/references/local-setup.md +3 -3
- package/node_modules/@higgsfield/higgsedit/dist/chunk-C6SASQHE.mjs +0 -424
- package/node_modules/@higgsfield/higgsedit/dist/chunk-FZ5U36SQ.mjs +0 -83
- package/node_modules/@higgsfield/higgsedit/dist/chunk-QLPCYN6K.mjs +0 -292
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/edit-drag-D2EV5ddd.css +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/editor-CuRHT75g.css +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-DnuQD7ja.css +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/FieldControl-B0fenhBJ.js +0 -2
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconChainLink1-Cwv1X7hi.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconEyeOpen-BqTT9_VV.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconEyeSlash-Whv58c1m.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconPencil-Dr17k_7e.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconPlay-BroH3ziH.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconPlusSmall-43T9aE3d.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconText1-BaP_p9DW.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconTrashCan-DX2w2AIC.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/ai-composer-C-l0eIdP.js +0 -560
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/captions-Cd-bDG3G.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/clip-highlight-DpAvcA4x.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/components-e3ZbUVns.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/disposables-CwUPjcuA.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/drag-HLBkto5o.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/dropdown-BJ04G_X3.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/edit-drag-Bg6LggKC.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/edits-a2IixhrN.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/export-dialog-4I4gqI5V.js +0 -2
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/face-tracker-DzVfjVOO.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/fit-imported-media-CaCB0x0b.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/generation-queue-DuL2F4-_.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/import-error-CMARA0Hy.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/jsx-runtime-B-hcVAMW.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/menubar-Bs26OdwP.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/meters-YEr9OQjq.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/paints-DS2Msf91.js +0 -67
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/palette-CcS9IcAC.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-7M3uQokX.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-BBK1NyG-.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-CHZTs7By.js +0 -4
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DaSOa3MP.js +0 -2
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DlK3RYVo.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-Dst5OKWu.js +0 -2
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-H_ZoDiKK.js +0 -2
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-Rn9Z7Eek.js +0 -3
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-assets-FAghGFG3.js +0 -678
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-inspector-DEqULBNF.js +0 -260
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-timeline-0GYNz1uc.js +0 -333
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-viewport-DOWjJi5-.js +0 -317
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/projects-BBJc7h5_.js +0 -2
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/session-B9sZaFKC.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/supercomputer-CX-LCL6Y.js +0 -24
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/tabs-CvKQ-eas.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/toggle-CrzrwiDZ.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-BgRfk-Qq.js +0 -69
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-bar-C9nqAfE2.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/typography-C5-w9LOu-kD3uLKkf.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useOpenInteractionType-DbrQ6Ehu.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useRenderElement-bbxXdYq0.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/writeback-support-BZfNpkmB.js +0 -1
- package/node_modules/@higgsfield/higgsedit/dist/editor/editor-Csn2_T_e.js +0 -293
- package/node_modules/@higgsfield/higgsedit/dist/export-settings.mjs +0 -75
- package/node_modules/@higgsfield/higgsedit/dist/history.mjs +0 -295
- package/node_modules/@higgsfield/higgsedit/dist/media-upload.mjs +0 -381
- package/node_modules/@higgsfield/higgsedit/dist/proxy.mjs +0 -170
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
parseTime
|
|
9
9
|
} from "./chunk-F7YUKEI5.mjs";
|
|
10
10
|
|
|
11
|
-
// ../../node_modules/.pnpm/koota@0.6.6_@types+react@19.2.
|
|
11
|
+
// ../../node_modules/.pnpm/koota@0.6.6_@types+react@19.2.18_react@19.2.8/node_modules/koota/dist/chunk-ZWIGMIL4.js
|
|
12
12
|
var $internal = /* @__PURE__ */ Symbol.for("koota.internal");
|
|
13
13
|
var WORLD_ID_BITS = 4;
|
|
14
14
|
var GENERATION_BITS = 8;
|
|
@@ -2698,7 +2698,9 @@ var Node = trait(() => ({
|
|
|
2698
2698
|
key: "",
|
|
2699
2699
|
name: void 0,
|
|
2700
2700
|
/** Props bound to accessors (`x={() => ...}`): code-driven at runtime. */
|
|
2701
|
-
accessors: /* @__PURE__ */ new Set()
|
|
2701
|
+
accessors: /* @__PURE__ */ new Set(),
|
|
2702
|
+
/** Project module whose JSX created it (set by the project loader). */
|
|
2703
|
+
file: void 0
|
|
2702
2704
|
}));
|
|
2703
2705
|
var Hierarchy = trait(() => ({
|
|
2704
2706
|
parent: null,
|
|
@@ -2730,7 +2732,11 @@ var Offset = trait(() => ({
|
|
|
2730
2732
|
offsetY: void 0
|
|
2731
2733
|
}));
|
|
2732
2734
|
var Opacity = trait(() => ({ opacity: void 0 }));
|
|
2733
|
-
var Visibility = trait(() => ({
|
|
2735
|
+
var Visibility = trait(() => ({
|
|
2736
|
+
hidden: void 0,
|
|
2737
|
+
/** Editor preview from a cached render: `false` never, `true` always, unset when heavy (prerender.ts). */
|
|
2738
|
+
prerender: void 0
|
|
2739
|
+
}));
|
|
2734
2740
|
var Fill = trait(() => ({ fill: void 0 }));
|
|
2735
2741
|
var Shape = trait(() => ({ cornerRadius: void 0 }));
|
|
2736
2742
|
var TextStyle = trait(() => ({
|
|
@@ -2833,6 +2839,7 @@ var PROP_TRAITS = {
|
|
|
2833
2839
|
...Object.fromEntries(TRANSFORM_PROPS.map((p) => [p, Transform])),
|
|
2834
2840
|
opacity: Opacity,
|
|
2835
2841
|
hidden: Visibility,
|
|
2842
|
+
prerender: Visibility,
|
|
2836
2843
|
fill: Fill,
|
|
2837
2844
|
cornerRadius: Shape,
|
|
2838
2845
|
fontSize: TextStyle,
|
|
@@ -3050,104 +3057,6 @@ function transcriptLength(t) {
|
|
|
3050
3057
|
return end;
|
|
3051
3058
|
}
|
|
3052
3059
|
|
|
3053
|
-
// ../../packages/runtime/src/captions/presets.ts
|
|
3054
|
-
var speaking = (s, t) => t >= s.word.start && t <= s.word.end;
|
|
3055
|
-
var joined = (phrase) => phrase.map((s) => s.word.text).join(" ");
|
|
3056
|
-
var whole = (phrase) => [[{ text: joined(phrase) }]];
|
|
3057
|
-
function halves(phrase) {
|
|
3058
|
-
const mid = Math.ceil(joined(phrase).length / 2);
|
|
3059
|
-
let cut = phrase.length;
|
|
3060
|
-
let best = Infinity;
|
|
3061
|
-
let space = -1;
|
|
3062
|
-
for (let k = 1; k < phrase.length; k++) {
|
|
3063
|
-
space += phrase[k - 1].word.text.length + 1;
|
|
3064
|
-
const d = Math.abs(space - mid);
|
|
3065
|
-
if (d < best) {
|
|
3066
|
-
best = d;
|
|
3067
|
-
cut = k;
|
|
3068
|
-
}
|
|
3069
|
-
}
|
|
3070
|
-
return [phrase.slice(0, cut), phrase.slice(cut)];
|
|
3071
|
-
}
|
|
3072
|
-
function twoLines(phrase, t, emphasise) {
|
|
3073
|
-
const [top, bottom] = halves(phrase);
|
|
3074
|
-
const second = bottom.length > 0 && t >= bottom[0].word.start;
|
|
3075
|
-
const lines = [emphasise(top, !second)];
|
|
3076
|
-
if (bottom.length) lines.push(emphasise(bottom, second));
|
|
3077
|
-
return lines;
|
|
3078
|
-
}
|
|
3079
|
-
var words = (half, style) => half.map((s, i) => ({ text: i < half.length - 1 ? `${s.word.text} ` : s.word.text, ...style(s) }));
|
|
3080
|
-
function look(spec) {
|
|
3081
|
-
const [family, weight, size] = spec.face;
|
|
3082
|
-
const [width, height] = spec.box;
|
|
3083
|
-
const out = {
|
|
3084
|
-
width,
|
|
3085
|
-
height,
|
|
3086
|
-
align: spec.place,
|
|
3087
|
-
font: { family, weight, size, italic: spec.italic ?? false, lineHeight: spec.leading ?? 1, align: spec.topLeft ? "left" : "center", valign: spec.topLeft ? "top" : "middle" },
|
|
3088
|
-
limit: spec.gather,
|
|
3089
|
-
slots: spec.slots ?? [],
|
|
3090
|
-
lines: spec.lines ?? whole
|
|
3091
|
-
};
|
|
3092
|
-
if (spec.left !== void 0) out.x = spec.left;
|
|
3093
|
-
if (spec.textCase) out.textCase = spec.textCase;
|
|
3094
|
-
if (spec.shadow) out.shadow = spec.shadow;
|
|
3095
|
-
if (spec.composite) out.composite = spec.composite;
|
|
3096
|
-
if (spec.runWeights) out.runWeights = spec.runWeights;
|
|
3097
|
-
return out;
|
|
3098
|
-
}
|
|
3099
|
-
var PRESETS = {
|
|
3100
|
-
classic: look({
|
|
3101
|
-
face: ["Urbanist", 600, 62],
|
|
3102
|
-
box: [600, 100],
|
|
3103
|
-
place: "center",
|
|
3104
|
-
gather: { seconds: 0.2 },
|
|
3105
|
-
textCase: "lower",
|
|
3106
|
-
shadow: { color: "#000000", blur: 28, x: 0, y: 5 }
|
|
3107
|
-
}),
|
|
3108
|
-
whisper: look({ face: ["Montserrat", 400, 40], leading: 1.4, box: [1e3, 100], place: "bottom", gather: { seconds: 2 } }),
|
|
3109
|
-
cascade: look({
|
|
3110
|
-
face: ["Inter", 300, 50],
|
|
3111
|
-
leading: 1.2,
|
|
3112
|
-
topLeft: true,
|
|
3113
|
-
box: [800, 200],
|
|
3114
|
-
left: 100,
|
|
3115
|
-
place: "bottom",
|
|
3116
|
-
gather: { chars: 50 },
|
|
3117
|
-
lines: (phrase, t) => [[{ text: joined(phrase.filter((s) => s.word.start <= t)) }]]
|
|
3118
|
-
}),
|
|
3119
|
-
spotlight: look({
|
|
3120
|
-
face: ["Outfit", 700, 70],
|
|
3121
|
-
italic: true,
|
|
3122
|
-
box: [700, 100],
|
|
3123
|
-
place: "center",
|
|
3124
|
-
gather: { chars: 10 },
|
|
3125
|
-
slots: ["#24D5FF"],
|
|
3126
|
-
// A lone word is not lit: there is nothing to pick it out from.
|
|
3127
|
-
lines: (phrase, t) => [words(phrase, (s) => phrase.length > 1 && speaking(s, t) ? { slot: 0 } : {})]
|
|
3128
|
-
}),
|
|
3129
|
-
paper: look({
|
|
3130
|
-
face: ["Montserrat", 300, 50],
|
|
3131
|
-
runWeights: [500],
|
|
3132
|
-
leading: 0.9,
|
|
3133
|
-
box: [700, 200],
|
|
3134
|
-
place: "center",
|
|
3135
|
-
gather: { chars: 18 },
|
|
3136
|
-
lines: (phrase, t) => twoLines(phrase, t, (half, active) => [{ text: joined(half), ...active ? { weight: 500 } : {} }])
|
|
3137
|
-
}),
|
|
3138
|
-
guinea: look({
|
|
3139
|
-
face: ["Outfit", 700, 62],
|
|
3140
|
-
box: [700, 200],
|
|
3141
|
-
place: "center",
|
|
3142
|
-
gather: { chars: 18 },
|
|
3143
|
-
textCase: "upper",
|
|
3144
|
-
slots: ["#F55353", "#FEB139", "#F6F54D"],
|
|
3145
|
-
lines: (phrase, t) => twoLines(phrase, t, (half) => words(half, (s) => speaking(s, t) ? { scale: 1.1, slot: s.index % 3 } : {}))
|
|
3146
|
-
}),
|
|
3147
|
-
stark: look({ face: ["Figtree", 800, 70], box: [700, 100], place: "center", gather: { seconds: 0.2 }, textCase: "upper", composite: "difference" })
|
|
3148
|
-
};
|
|
3149
|
-
var presetOf = (preset) => PRESETS[preset ?? "classic"] ?? PRESETS.classic;
|
|
3150
|
-
|
|
3151
3060
|
// ../../packages/runtime/src/keyframes.ts
|
|
3152
3061
|
function cubicBezier(x1, y1, x2, y2) {
|
|
3153
3062
|
const cx = 3 * x1;
|
|
@@ -3244,61 +3153,6 @@ function isAnimatable(tag2, key) {
|
|
|
3244
3153
|
return Object.hasOwn(ANIMATABLE, key);
|
|
3245
3154
|
}
|
|
3246
3155
|
|
|
3247
|
-
// ../../packages/runtime/src/motion.ts
|
|
3248
|
-
var ch = (channel, enter, exit, neutral) => ({ channel, enter, exit, neutral });
|
|
3249
|
-
var FADE = ch("opacity", 0, 0, 1);
|
|
3250
|
-
var MOTION_PRESETS = {
|
|
3251
|
-
fade: [FADE],
|
|
3252
|
-
grow: [ch("scale", 0.6, 0.6, 1)],
|
|
3253
|
-
shrink: [ch("scale", 1.4, 1.4, 1)],
|
|
3254
|
-
blur: [ch("blur", 24, 24, 0), FADE],
|
|
3255
|
-
"slide-left": [ch("offsetX", 1, -1, 0)],
|
|
3256
|
-
"slide-right": [ch("offsetX", -1, 1, 0)],
|
|
3257
|
-
"slide-up": [ch("offsetY", 1, -1, 0)],
|
|
3258
|
-
"slide-down": [ch("offsetY", -1, 1, 0)],
|
|
3259
|
-
spin: [ch("rotation", -360, 360, 0), FADE],
|
|
3260
|
-
twist: [ch("rotation", -90, 90, 0), ch("scale", 0.3, 0.3, 1), FADE],
|
|
3261
|
-
// Text presets move no channel; sampleReveal gives the glyphs their progress.
|
|
3262
|
-
"appear-word": [],
|
|
3263
|
-
"appear-character": [],
|
|
3264
|
-
scramble: []
|
|
3265
|
-
};
|
|
3266
|
-
|
|
3267
|
-
// ../../packages/runtime/src/media/font-use.ts
|
|
3268
|
-
var GENERIC = /* @__PURE__ */ new Set(["serif", "sans-serif", "monospace", "cursive", "fantasy", "system-ui", "ui-serif", "ui-sans-serif", "ui-monospace", "ui-rounded", "math", "emoji", "fangsong", "inherit", "initial"]);
|
|
3269
|
-
function familyNames(value) {
|
|
3270
|
-
return value.split(",").map((name) => name.trim().replace(/^(["'])(.*)\1$/, "$2").trim()).filter((name) => name && !GENERIC.has(name.toLowerCase()));
|
|
3271
|
-
}
|
|
3272
|
-
var weightOf = (w, fallback = 400) => w === "bold" ? 700 : w === "normal" ? 400 : typeof w === "number" && Number.isFinite(w) ? w : fallback;
|
|
3273
|
-
var styleOf = (s, fallback = "normal") => s === "italic" ? "italic" : s === "normal" ? "normal" : fallback;
|
|
3274
|
-
function definedOf(style) {
|
|
3275
|
-
const out = {};
|
|
3276
|
-
for (const field of ["fontFamily", "fontWeight", "fontStyle"]) if (style?.[field] !== void 0) Object.assign(out, { [field]: style[field] });
|
|
3277
|
-
return out;
|
|
3278
|
-
}
|
|
3279
|
-
function usedFonts(world) {
|
|
3280
|
-
const out = /* @__PURE__ */ new Map();
|
|
3281
|
-
const add = (families, weight, style) => {
|
|
3282
|
-
if (!families) return;
|
|
3283
|
-
for (const family of familyNames(families)) out.set(`${family.toLowerCase()}|${weight}|${style}`, { family, weight, style });
|
|
3284
|
-
};
|
|
3285
|
-
for (const e of world.query(TextStyle)) {
|
|
3286
|
-
const s = e.get(TextStyle);
|
|
3287
|
-
const tag2 = e.get(Node)?.tag;
|
|
3288
|
-
if (tag2 === "captions") {
|
|
3289
|
-
const look2 = presetOf(e.get(Captions)?.preset);
|
|
3290
|
-
const family = s.fontFamily ?? look2.font.family;
|
|
3291
|
-
const style = styleOf(s.fontStyle, look2.font.italic ? "italic" : "normal");
|
|
3292
|
-
if (s.fontWeight !== void 0) add(family, weightOf(s.fontWeight), style);
|
|
3293
|
-
else for (const w of [look2.font.weight, ...look2.runWeights ?? []]) add(family, w, style);
|
|
3294
|
-
continue;
|
|
3295
|
-
}
|
|
3296
|
-
const own = tag2 === "textRange" ? { ...definedOf(parentOf(e)?.get(TextStyle)), ...definedOf(s) } : s;
|
|
3297
|
-
add(own.fontFamily, weightOf(own.fontWeight), styleOf(own.fontStyle));
|
|
3298
|
-
}
|
|
3299
|
-
return [...out.values()];
|
|
3300
|
-
}
|
|
3301
|
-
|
|
3302
3156
|
// ../../packages/runtime/src/sync.ts
|
|
3303
3157
|
var syncPair = (src, target) => `${src}
|
|
3304
3158
|
${target}`;
|
|
@@ -3398,14 +3252,174 @@ function syncedPlacement(world, entity, fps, clock) {
|
|
|
3398
3252
|
return { start: from - own, end: to - own, sourceIn: authoredIn ?? (from - zero) * speed, offset, target };
|
|
3399
3253
|
}
|
|
3400
3254
|
|
|
3255
|
+
// ../../packages/runtime/src/captions/presets.ts
|
|
3256
|
+
var speaking = (s, t) => t >= s.word.start && t <= s.word.end;
|
|
3257
|
+
var joined = (phrase) => phrase.map((s) => s.word.text).join(" ");
|
|
3258
|
+
var whole = (phrase) => [[{ text: joined(phrase) }]];
|
|
3259
|
+
function halves(phrase) {
|
|
3260
|
+
const mid = Math.ceil(joined(phrase).length / 2);
|
|
3261
|
+
let cut = phrase.length;
|
|
3262
|
+
let best = Infinity;
|
|
3263
|
+
let space = -1;
|
|
3264
|
+
for (let k = 1; k < phrase.length; k++) {
|
|
3265
|
+
space += phrase[k - 1].word.text.length + 1;
|
|
3266
|
+
const d = Math.abs(space - mid);
|
|
3267
|
+
if (d < best) {
|
|
3268
|
+
best = d;
|
|
3269
|
+
cut = k;
|
|
3270
|
+
}
|
|
3271
|
+
}
|
|
3272
|
+
return [phrase.slice(0, cut), phrase.slice(cut)];
|
|
3273
|
+
}
|
|
3274
|
+
function twoLines(phrase, t, emphasise) {
|
|
3275
|
+
const [top, bottom] = halves(phrase);
|
|
3276
|
+
const second = bottom.length > 0 && t >= bottom[0].word.start;
|
|
3277
|
+
const lines = [emphasise(top, !second)];
|
|
3278
|
+
if (bottom.length) lines.push(emphasise(bottom, second));
|
|
3279
|
+
return lines;
|
|
3280
|
+
}
|
|
3281
|
+
var words = (half, style) => half.map((s, i) => ({ text: i < half.length - 1 ? `${s.word.text} ` : s.word.text, ...style(s) }));
|
|
3282
|
+
function look(spec) {
|
|
3283
|
+
const [family, weight, size] = spec.face;
|
|
3284
|
+
const [width, height] = spec.box;
|
|
3285
|
+
const out = {
|
|
3286
|
+
width,
|
|
3287
|
+
height,
|
|
3288
|
+
align: spec.place,
|
|
3289
|
+
font: { family, weight, size, italic: spec.italic ?? false, lineHeight: spec.leading ?? 1, align: spec.topLeft ? "left" : "center", valign: spec.topLeft ? "top" : "middle" },
|
|
3290
|
+
limit: spec.gather,
|
|
3291
|
+
slots: spec.slots ?? [],
|
|
3292
|
+
lines: spec.lines ?? whole
|
|
3293
|
+
};
|
|
3294
|
+
if (spec.left !== void 0) out.x = spec.left;
|
|
3295
|
+
if (spec.textCase) out.textCase = spec.textCase;
|
|
3296
|
+
if (spec.shadow) out.shadow = spec.shadow;
|
|
3297
|
+
if (spec.composite) out.composite = spec.composite;
|
|
3298
|
+
if (spec.runWeights) out.runWeights = spec.runWeights;
|
|
3299
|
+
return out;
|
|
3300
|
+
}
|
|
3301
|
+
var PRESETS = {
|
|
3302
|
+
classic: look({
|
|
3303
|
+
face: ["Urbanist", 600, 62],
|
|
3304
|
+
box: [600, 100],
|
|
3305
|
+
place: "center",
|
|
3306
|
+
gather: { seconds: 0.2 },
|
|
3307
|
+
textCase: "lower",
|
|
3308
|
+
shadow: { color: "#000000", blur: 28, x: 0, y: 5 }
|
|
3309
|
+
}),
|
|
3310
|
+
whisper: look({ face: ["Montserrat", 400, 40], leading: 1.4, box: [1e3, 100], place: "bottom", gather: { seconds: 2 } }),
|
|
3311
|
+
cascade: look({
|
|
3312
|
+
face: ["Inter", 300, 50],
|
|
3313
|
+
leading: 1.2,
|
|
3314
|
+
topLeft: true,
|
|
3315
|
+
box: [800, 200],
|
|
3316
|
+
left: 100,
|
|
3317
|
+
place: "bottom",
|
|
3318
|
+
gather: { chars: 50 },
|
|
3319
|
+
lines: (phrase, t) => [[{ text: joined(phrase.filter((s) => s.word.start <= t)) }]]
|
|
3320
|
+
}),
|
|
3321
|
+
spotlight: look({
|
|
3322
|
+
face: ["Outfit", 700, 70],
|
|
3323
|
+
italic: true,
|
|
3324
|
+
box: [700, 100],
|
|
3325
|
+
place: "center",
|
|
3326
|
+
gather: { chars: 10 },
|
|
3327
|
+
slots: ["#24D5FF"],
|
|
3328
|
+
// A lone word is not lit: there is nothing to pick it out from.
|
|
3329
|
+
lines: (phrase, t) => [words(phrase, (s) => phrase.length > 1 && speaking(s, t) ? { slot: 0 } : {})]
|
|
3330
|
+
}),
|
|
3331
|
+
paper: look({
|
|
3332
|
+
face: ["Montserrat", 300, 50],
|
|
3333
|
+
runWeights: [500],
|
|
3334
|
+
leading: 0.9,
|
|
3335
|
+
box: [700, 200],
|
|
3336
|
+
place: "center",
|
|
3337
|
+
gather: { chars: 18 },
|
|
3338
|
+
lines: (phrase, t) => twoLines(phrase, t, (half, active) => [{ text: joined(half), ...active ? { weight: 500 } : {} }])
|
|
3339
|
+
}),
|
|
3340
|
+
guinea: look({
|
|
3341
|
+
face: ["Outfit", 700, 62],
|
|
3342
|
+
box: [700, 200],
|
|
3343
|
+
place: "center",
|
|
3344
|
+
gather: { chars: 18 },
|
|
3345
|
+
textCase: "upper",
|
|
3346
|
+
slots: ["#F55353", "#FEB139", "#F6F54D"],
|
|
3347
|
+
lines: (phrase, t) => twoLines(phrase, t, (half) => words(half, (s) => speaking(s, t) ? { scale: 1.1, slot: s.index % 3 } : {}))
|
|
3348
|
+
}),
|
|
3349
|
+
stark: look({ face: ["Figtree", 800, 70], box: [700, 100], place: "center", gather: { seconds: 0.2 }, textCase: "upper", composite: "difference" })
|
|
3350
|
+
};
|
|
3351
|
+
var presetOf = (preset) => PRESETS[preset ?? "classic"] ?? PRESETS.classic;
|
|
3352
|
+
|
|
3353
|
+
// ../../packages/runtime/src/motion.ts
|
|
3354
|
+
var ch = (channel, enter, exit, neutral) => ({ channel, enter, exit, neutral });
|
|
3355
|
+
var FADE = ch("opacity", 0, 0, 1);
|
|
3356
|
+
var MOTION_PRESETS = {
|
|
3357
|
+
fade: [FADE],
|
|
3358
|
+
grow: [ch("scale", 0.6, 0.6, 1)],
|
|
3359
|
+
shrink: [ch("scale", 1.4, 1.4, 1)],
|
|
3360
|
+
blur: [ch("blur", 24, 24, 0), FADE],
|
|
3361
|
+
"slide-left": [ch("offsetX", 1, -1, 0)],
|
|
3362
|
+
"slide-right": [ch("offsetX", -1, 1, 0)],
|
|
3363
|
+
"slide-up": [ch("offsetY", 1, -1, 0)],
|
|
3364
|
+
"slide-down": [ch("offsetY", -1, 1, 0)],
|
|
3365
|
+
spin: [ch("rotation", -360, 360, 0), FADE],
|
|
3366
|
+
twist: [ch("rotation", -90, 90, 0), ch("scale", 0.3, 0.3, 1), FADE],
|
|
3367
|
+
// Text presets move no channel; sampleReveal gives the glyphs their progress.
|
|
3368
|
+
"appear-word": [],
|
|
3369
|
+
"appear-character": [],
|
|
3370
|
+
scramble: []
|
|
3371
|
+
};
|
|
3372
|
+
|
|
3373
|
+
// ../../packages/runtime/src/media/font-use.ts
|
|
3374
|
+
var GENERIC = /* @__PURE__ */ new Set(["serif", "sans-serif", "monospace", "cursive", "fantasy", "system-ui", "ui-serif", "ui-sans-serif", "ui-monospace", "ui-rounded", "math", "emoji", "fangsong", "inherit", "initial"]);
|
|
3375
|
+
function familyNames(value) {
|
|
3376
|
+
return value.split(",").map((name) => name.trim().replace(/^(["'])(.*)\1$/, "$2").trim()).filter((name) => name && !GENERIC.has(name.toLowerCase()));
|
|
3377
|
+
}
|
|
3378
|
+
var weightOf = (w, fallback = 400) => w === "bold" ? 700 : w === "normal" ? 400 : typeof w === "number" && Number.isFinite(w) ? w : fallback;
|
|
3379
|
+
var styleOf = (s, fallback = "normal") => s === "italic" ? "italic" : s === "normal" ? "normal" : fallback;
|
|
3380
|
+
function definedOf(style) {
|
|
3381
|
+
const out = {};
|
|
3382
|
+
for (const field of ["fontFamily", "fontWeight", "fontStyle"]) if (style?.[field] !== void 0) Object.assign(out, { [field]: style[field] });
|
|
3383
|
+
return out;
|
|
3384
|
+
}
|
|
3385
|
+
function usedFonts(world, includes) {
|
|
3386
|
+
const out = /* @__PURE__ */ new Map();
|
|
3387
|
+
const add = (families, weight, style) => {
|
|
3388
|
+
if (!families) return;
|
|
3389
|
+
for (const family of familyNames(families)) out.set(`${family.toLowerCase()}|${weight}|${style}`, { family, weight, style });
|
|
3390
|
+
};
|
|
3391
|
+
for (const e of world.query(TextStyle)) {
|
|
3392
|
+
if (includes && !includes(e)) continue;
|
|
3393
|
+
const s = e.get(TextStyle);
|
|
3394
|
+
const tag2 = e.get(Node)?.tag;
|
|
3395
|
+
if (tag2 === "captions") {
|
|
3396
|
+
const look2 = presetOf(e.get(Captions)?.preset);
|
|
3397
|
+
const family = s.fontFamily ?? look2.font.family;
|
|
3398
|
+
const style = styleOf(s.fontStyle, look2.font.italic ? "italic" : "normal");
|
|
3399
|
+
if (s.fontWeight !== void 0) add(family, weightOf(s.fontWeight), style);
|
|
3400
|
+
else for (const w of [look2.font.weight, ...look2.runWeights ?? []]) add(family, w, style);
|
|
3401
|
+
continue;
|
|
3402
|
+
}
|
|
3403
|
+
const own = tag2 === "textRange" ? { ...definedOf(parentOf(e)?.get(TextStyle)), ...definedOf(s) } : s;
|
|
3404
|
+
add(own.fontFamily, weightOf(own.fontWeight), styleOf(own.fontStyle));
|
|
3405
|
+
}
|
|
3406
|
+
return [...out.values()];
|
|
3407
|
+
}
|
|
3408
|
+
|
|
3401
3409
|
// ../../packages/runtime/src/systems.ts
|
|
3402
3410
|
var DEFAULT_FPS = 30;
|
|
3403
3411
|
var DEFAULT_SCENE = { width: 1920, height: 1080 };
|
|
3404
3412
|
var DEFAULT_DURATION = 5;
|
|
3405
3413
|
var sceneFps = (scene) => scene?.get(SceneConfig)?.fps ?? DEFAULT_FPS;
|
|
3414
|
+
var captureScenes = /* @__PURE__ */ new WeakMap();
|
|
3415
|
+
function stageFps(world) {
|
|
3416
|
+
const stage = findStage(world);
|
|
3417
|
+
return sceneFps(stage ? childrenOf(stage).find((entity) => entity.get(Node).tag === "scene") : void 0);
|
|
3418
|
+
}
|
|
3406
3419
|
function rootScenes(world) {
|
|
3407
3420
|
const stage = findStage(world);
|
|
3408
|
-
|
|
3421
|
+
const selected = captureScenes.get(world);
|
|
3422
|
+
return stage ? childrenOf(stage).filter((e) => e.get(Node).tag === "scene" && (selected === void 0 || e.get(Node).key === selected || e.get(Node).id === selected)) : [];
|
|
3409
3423
|
}
|
|
3410
3424
|
function span(world, entity, fps) {
|
|
3411
3425
|
const synced = syncedPlacement(world, entity, fps, SYNC_CLOCK);
|
|
@@ -3444,7 +3458,7 @@ function span(world, entity, fps) {
|
|
|
3444
3458
|
}
|
|
3445
3459
|
function fpsUnder(world, parent) {
|
|
3446
3460
|
for (let e = parent; e; e = parentOf(e)) if (e.get(Node).tag === "scene") return sceneFps(e);
|
|
3447
|
-
return
|
|
3461
|
+
return stageFps(world);
|
|
3448
3462
|
}
|
|
3449
3463
|
var SYNC_CLOCK = { span, fpsUnder, speed: mediaSpeed };
|
|
3450
3464
|
function syncPlacement(world, entity) {
|
|
@@ -3458,7 +3472,7 @@ function localTime(world, entity, time) {
|
|
|
3458
3472
|
const chain = [];
|
|
3459
3473
|
for (let e = entity; e && e.get(Node).tag !== "stage"; e = parentOf(e)) chain.unshift(e);
|
|
3460
3474
|
let clock = time;
|
|
3461
|
-
let fps =
|
|
3475
|
+
let fps = stageFps(world);
|
|
3462
3476
|
for (const e of chain) {
|
|
3463
3477
|
const start = span(world, e, fps).start;
|
|
3464
3478
|
const tag2 = e.get(Node).tag;
|
|
@@ -3474,7 +3488,7 @@ function composition(world) {
|
|
|
3474
3488
|
const config = scene?.get(SceneConfig);
|
|
3475
3489
|
const fps = sceneFps(scene);
|
|
3476
3490
|
let duration = 0;
|
|
3477
|
-
for (const s of scenes) duration = Math.max(duration, span(world, s,
|
|
3491
|
+
for (const s of scenes) duration = Math.max(duration, span(world, s, stageFps(world)).end);
|
|
3478
3492
|
return {
|
|
3479
3493
|
scene,
|
|
3480
3494
|
width: config?.width ?? DEFAULT_SCENE.width,
|
|
@@ -3544,6 +3558,79 @@ function encodeMaskFile(header, frames) {
|
|
|
3544
3558
|
bytes.set(body, 8 + json.length);
|
|
3545
3559
|
return bytes;
|
|
3546
3560
|
}
|
|
3561
|
+
function decodeMaskRuns(bytes, out, start = 0, end = bytes.length) {
|
|
3562
|
+
out.fill(0);
|
|
3563
|
+
let at = start;
|
|
3564
|
+
let cell = 0;
|
|
3565
|
+
let value = 0;
|
|
3566
|
+
while (at < end) {
|
|
3567
|
+
const [run, next] = readVarint(bytes, at);
|
|
3568
|
+
at = next;
|
|
3569
|
+
if (value) out.fill(1, cell, Math.min(out.length, cell + run));
|
|
3570
|
+
cell += run;
|
|
3571
|
+
value ^= 1;
|
|
3572
|
+
}
|
|
3573
|
+
return cell;
|
|
3574
|
+
}
|
|
3575
|
+
var MaskFile = class _MaskFile {
|
|
3576
|
+
header;
|
|
3577
|
+
bytes;
|
|
3578
|
+
/** Byte range [starts[i], ends[i]) of each frame's runs. */
|
|
3579
|
+
starts;
|
|
3580
|
+
ends;
|
|
3581
|
+
times;
|
|
3582
|
+
constructor(bytes, header, starts, ends) {
|
|
3583
|
+
this.bytes = bytes;
|
|
3584
|
+
this.header = header;
|
|
3585
|
+
this.starts = starts;
|
|
3586
|
+
this.ends = ends;
|
|
3587
|
+
}
|
|
3588
|
+
static parse(bytes) {
|
|
3589
|
+
if (bytes.length < 8 || new TextDecoder().decode(bytes.subarray(0, 4)) !== MAGIC) throw new Error("not a higgsedit mask file");
|
|
3590
|
+
const length = new DataView(bytes.buffer, bytes.byteOffset, bytes.byteLength).getUint32(4, true);
|
|
3591
|
+
const header = JSON.parse(new TextDecoder().decode(bytes.subarray(8, 8 + length)));
|
|
3592
|
+
if (header.version !== 1) throw new Error(`mask file version ${String(header.version)} is newer than this higgsedit`);
|
|
3593
|
+
const starts = new Uint32Array(header.frames);
|
|
3594
|
+
const ends = new Uint32Array(header.frames);
|
|
3595
|
+
let at = 8 + length;
|
|
3596
|
+
for (let i = 0; i < header.frames; i++) {
|
|
3597
|
+
const [size, next] = readVarint(bytes, at);
|
|
3598
|
+
starts[i] = next;
|
|
3599
|
+
at = ends[i] = next + size;
|
|
3600
|
+
if (at > bytes.length) throw new Error(`mask file is cut short at frame ${i}`);
|
|
3601
|
+
}
|
|
3602
|
+
return new _MaskFile(bytes, header, starts, ends);
|
|
3603
|
+
}
|
|
3604
|
+
get frameCount() {
|
|
3605
|
+
return this.header.frames;
|
|
3606
|
+
}
|
|
3607
|
+
/** Fills `out` (grid-sized) with 1 inside the object, 0 outside; false when the frame was not tracked. */
|
|
3608
|
+
frame(index, out) {
|
|
3609
|
+
const start = this.starts[index];
|
|
3610
|
+
const end = this.ends[index];
|
|
3611
|
+
decodeMaskRuns(this.bytes, out, start, end);
|
|
3612
|
+
return start < end;
|
|
3613
|
+
}
|
|
3614
|
+
/** The frame shown at source seconds `t`: the nearest-frame rule video uses, clamped to the file. */
|
|
3615
|
+
indexAt(t) {
|
|
3616
|
+
const { frames, frameRate, start } = this.header;
|
|
3617
|
+
if (frames === 0) return -1;
|
|
3618
|
+
this.times ??= Float64Array.from({ length: frames }, (_, i) => start + i / frameRate);
|
|
3619
|
+
return frameIndexAt(this.times, t, frameRate);
|
|
3620
|
+
}
|
|
3621
|
+
};
|
|
3622
|
+
function readVarint(bytes, offset) {
|
|
3623
|
+
let value = 0;
|
|
3624
|
+
let shift = 0;
|
|
3625
|
+
let at = offset;
|
|
3626
|
+
for (; ; ) {
|
|
3627
|
+
const byte = bytes[at++];
|
|
3628
|
+
if (byte === void 0) throw new Error("mask file is cut short");
|
|
3629
|
+
value += (byte & 127) * 2 ** shift;
|
|
3630
|
+
if (byte < 128) return [value, at];
|
|
3631
|
+
shift += 7;
|
|
3632
|
+
}
|
|
3633
|
+
}
|
|
3547
3634
|
|
|
3548
3635
|
// ../../packages/runtime/src/html.ts
|
|
3549
3636
|
var HIDDEN = "position:fixed;left:0;top:0;pointer-events:none;clip-path:inset(50%);";
|
|
@@ -3808,5 +3895,7 @@ export {
|
|
|
3808
3895
|
readFontFacts,
|
|
3809
3896
|
fileNameFacts,
|
|
3810
3897
|
fontFileFacts,
|
|
3811
|
-
encodeMaskFile
|
|
3898
|
+
encodeMaskFile,
|
|
3899
|
+
decodeMaskRuns,
|
|
3900
|
+
MaskFile
|
|
3812
3901
|
};
|
|
@@ -6,14 +6,17 @@ const __filename = __higgseditPath(import.meta.url);
|
|
|
6
6
|
const __dirname = __filename.slice(0, __filename.lastIndexOf("/"));
|
|
7
7
|
import {
|
|
8
8
|
check
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-OF6RMSM2.mjs";
|
|
10
10
|
import {
|
|
11
11
|
inspectVariables,
|
|
12
12
|
parseKey,
|
|
13
13
|
sourceFacts
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-MV2JTTBQ.mjs";
|
|
15
|
+
import "./chunk-UDL5AHKO.mjs";
|
|
16
|
+
import "./chunk-LTKMGZ6T.mjs";
|
|
17
|
+
import "./chunk-P2BGHTRR.mjs";
|
|
18
|
+
import "./chunk-PAHMD6SU.mjs";
|
|
19
|
+
import "./chunk-2VKQHJMM.mjs";
|
|
17
20
|
import {
|
|
18
21
|
Node,
|
|
19
22
|
Sync,
|
|
@@ -24,10 +27,8 @@ import {
|
|
|
24
27
|
span,
|
|
25
28
|
syncPlacement,
|
|
26
29
|
walk
|
|
27
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-BV5COOQZ.mjs";
|
|
28
31
|
import "./chunk-F7YUKEI5.mjs";
|
|
29
|
-
import "./chunk-EKFC4S4M.mjs";
|
|
30
|
-
import "./chunk-2VKQHJMM.mjs";
|
|
31
32
|
import "./chunk-75WO2NOF.mjs";
|
|
32
33
|
|
|
33
34
|
// src/outline.ts
|
|
@@ -7,10 +7,17 @@ const __dirname = __filename.slice(0, __filename.lastIndexOf("/"));
|
|
|
7
7
|
import {
|
|
8
8
|
CHROME_VERSION,
|
|
9
9
|
installedChrome
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-P2BGHTRR.mjs";
|
|
11
|
+
import {
|
|
12
|
+
selectStatus
|
|
13
|
+
} from "./chunk-WENFTPXQ.mjs";
|
|
14
|
+
import "./chunk-QJTILFBS.mjs";
|
|
11
15
|
import {
|
|
12
16
|
findTool
|
|
13
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-PAHMD6SU.mjs";
|
|
18
|
+
import "./chunk-BV5COOQZ.mjs";
|
|
19
|
+
import "./chunk-F7YUKEI5.mjs";
|
|
20
|
+
import "./chunk-MCVD2ZQV.mjs";
|
|
14
21
|
import "./chunk-75WO2NOF.mjs";
|
|
15
22
|
|
|
16
23
|
// src/doctor.ts
|
|
@@ -33,7 +40,7 @@ function tool(name) {
|
|
|
33
40
|
return path ? { path } : { missing: `install with \`brew install ffmpeg\`, or set HIGGSEDIT_${name.toUpperCase()}` };
|
|
34
41
|
}
|
|
35
42
|
var where = (t) => "path" in t ? t.path : `missing (${t.missing})`;
|
|
36
|
-
function diagnose(home = process.env.HIGGSEDIT_HOME ?? join(homedir(), ".higgsedit-next")) {
|
|
43
|
+
async function diagnose(home = process.env.HIGGSEDIT_HOME ?? join(homedir(), ".higgsedit-next"), env = process.env) {
|
|
37
44
|
const chrome = installedChrome({ home });
|
|
38
45
|
const log = join(home, "logs", "mcp.log");
|
|
39
46
|
return {
|
|
@@ -43,6 +50,7 @@ function diagnose(home = process.env.HIGGSEDIT_HOME ?? join(homedir(), ".higgsed
|
|
|
43
50
|
ffmpeg: tool("ffmpeg"),
|
|
44
51
|
ffprobe: tool("ffprobe"),
|
|
45
52
|
chrome: chrome ? { version: CHROME_VERSION, path: chrome } : { version: CHROME_VERSION, note: "downloads into ~/.higgsedit-next/chrome on the first render or frame preview" },
|
|
53
|
+
select: await selectStatus(env),
|
|
46
54
|
log,
|
|
47
55
|
errors: recentErrors(log)
|
|
48
56
|
};
|
|
@@ -52,7 +60,8 @@ function diagnosisText(d, extra = {}) {
|
|
|
52
60
|
`${process.versions.bun ? "runtime" : "node"}: ${d.node} (${d.platform})`,
|
|
53
61
|
`ffmpeg: ${where(d.ffmpeg)}`,
|
|
54
62
|
`ffprobe: ${where(d.ffprobe)}`,
|
|
55
|
-
`chrome: ${d.chrome.path ?? d.chrome.note} (${d.chrome.version})
|
|
63
|
+
`chrome: ${d.chrome.path ?? d.chrome.note} (${d.chrome.version})`,
|
|
64
|
+
`select: ${d.select.url === null ? "not set (HIGGSEDIT_SELECT_URL)" : `${d.select.url} (${d.select.answers ? "answers" : "no answer"}: ${d.select.detail})`}`
|
|
56
65
|
];
|
|
57
66
|
for (const [k, v] of Object.entries(extra)) lines.push(`${k}: ${JSON.stringify(v)}`);
|
|
58
67
|
lines.push(`log: ${d.log}`);
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire as __higgseditRequire } from "node:module";
|
|
3
|
+
import { fileURLToPath as __higgseditPath } from "node:url";
|
|
4
|
+
const require = __higgseditRequire(import.meta.url);
|
|
5
|
+
const __filename = __higgseditPath(import.meta.url);
|
|
6
|
+
const __dirname = __filename.slice(0, __filename.lastIndexOf("/"));
|
|
7
|
+
import {
|
|
8
|
+
FontLoadError,
|
|
9
|
+
frame,
|
|
10
|
+
gainFilter,
|
|
11
|
+
rateFilter,
|
|
12
|
+
render,
|
|
13
|
+
sheet,
|
|
14
|
+
shuffle,
|
|
15
|
+
verify
|
|
16
|
+
} from "./chunk-NARTAWRN.mjs";
|
|
17
|
+
import "./chunk-7PYXSJS7.mjs";
|
|
18
|
+
import "./chunk-UDL5AHKO.mjs";
|
|
19
|
+
import "./chunk-LTKMGZ6T.mjs";
|
|
20
|
+
import "./chunk-P2BGHTRR.mjs";
|
|
21
|
+
import "./chunk-PAHMD6SU.mjs";
|
|
22
|
+
import "./chunk-NUXTKQNM.mjs";
|
|
23
|
+
import "./chunk-2VKQHJMM.mjs";
|
|
24
|
+
import "./chunk-BV5COOQZ.mjs";
|
|
25
|
+
import "./chunk-F7YUKEI5.mjs";
|
|
26
|
+
import "./chunk-75WO2NOF.mjs";
|
|
27
|
+
export {
|
|
28
|
+
FontLoadError,
|
|
29
|
+
frame,
|
|
30
|
+
gainFilter,
|
|
31
|
+
rateFilter,
|
|
32
|
+
render,
|
|
33
|
+
sheet,
|
|
34
|
+
shuffle,
|
|
35
|
+
verify
|
|
36
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire as __higgseditRequire } from "node:module";
|
|
3
|
+
import { fileURLToPath as __higgseditPath } from "node:url";
|
|
4
|
+
const require = __higgseditRequire(import.meta.url);
|
|
5
|
+
const __filename = __higgseditPath(import.meta.url);
|
|
6
|
+
const __dirname = __filename.slice(0, __filename.lastIndexOf("/"));
|
|
7
|
+
import {
|
|
8
|
+
PRESET_CATEGORIES,
|
|
9
|
+
addPreset,
|
|
10
|
+
fitInto,
|
|
11
|
+
installPresets,
|
|
12
|
+
placeholderPath,
|
|
13
|
+
presetCatalogue,
|
|
14
|
+
presetsDir,
|
|
15
|
+
readManifest,
|
|
16
|
+
runPresets
|
|
17
|
+
} from "./chunk-YLVXQIPX.mjs";
|
|
18
|
+
import "./chunk-MV2JTTBQ.mjs";
|
|
19
|
+
import "./chunk-PAHMD6SU.mjs";
|
|
20
|
+
import "./chunk-F7YUKEI5.mjs";
|
|
21
|
+
import "./chunk-MCVD2ZQV.mjs";
|
|
22
|
+
import "./chunk-75WO2NOF.mjs";
|
|
23
|
+
export {
|
|
24
|
+
PRESET_CATEGORIES,
|
|
25
|
+
addPreset,
|
|
26
|
+
fitInto,
|
|
27
|
+
installPresets,
|
|
28
|
+
placeholderPath,
|
|
29
|
+
presetCatalogue,
|
|
30
|
+
presetsDir,
|
|
31
|
+
readManifest,
|
|
32
|
+
runPresets
|
|
33
|
+
};
|