@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.
Files changed (189) hide show
  1. package/THIRD_PARTY_NOTICES.md +24 -24
  2. package/dist/cli.mjs +134 -125
  3. package/dist/index.html +136 -133
  4. package/dist/launcher.mjs +90 -90
  5. package/dist/server.mjs +1553 -1389
  6. package/node_modules/@higgsfield/higgsedit/README.md +181 -1
  7. package/node_modules/@higgsfield/higgsedit/dist/capture-page.js +902 -314
  8. package/node_modules/@higgsfield/higgsedit/dist/chunk-2JYLVSVV.mjs +1594 -0
  9. package/node_modules/@higgsfield/higgsedit/dist/chunk-2WKNH7OL.mjs +16 -0
  10. package/node_modules/@higgsfield/higgsedit/dist/{chunk-OMKZ5BXM.mjs → chunk-5LTTL3Q3.mjs} +1 -1
  11. package/node_modules/@higgsfield/higgsedit/dist/chunk-7PYXSJS7.mjs +717 -0
  12. package/node_modules/@higgsfield/higgsedit/dist/{chunk-MLJAIZGP.mjs → chunk-BH2QF635.mjs} +33 -326
  13. package/node_modules/@higgsfield/higgsedit/dist/{chunk-WZR5PZM7.mjs → chunk-BV5COOQZ.mjs} +250 -161
  14. package/node_modules/@higgsfield/higgsedit/dist/{chunk-HTCYVKFX.mjs → chunk-C3GSB3XZ.mjs} +8 -7
  15. package/node_modules/@higgsfield/higgsedit/dist/{chunk-CYH2EUQV.mjs → chunk-DVN4LUXV.mjs} +13 -4
  16. package/node_modules/@higgsfield/higgsedit/dist/chunk-F4CMIG5G.mjs +36 -0
  17. package/node_modules/@higgsfield/higgsedit/dist/chunk-IEPPEDEU.mjs +33 -0
  18. package/node_modules/@higgsfield/higgsedit/dist/{chunk-UVAZ6I6U.mjs → chunk-KIWGVAPJ.mjs} +16 -12
  19. package/node_modules/@higgsfield/higgsedit/dist/{chunk-L6QDNSL3.mjs → chunk-L5LWBA6A.mjs} +5 -5
  20. package/node_modules/@higgsfield/higgsedit/dist/chunk-LMQR3DHT.mjs +37 -0
  21. package/node_modules/@higgsfield/higgsedit/dist/chunk-LTKMGZ6T.mjs +58 -0
  22. package/node_modules/@higgsfield/higgsedit/dist/{chunk-VI6IV6JP.mjs → chunk-MV2JTTBQ.mjs} +65 -47
  23. package/node_modules/@higgsfield/higgsedit/dist/{chunk-4D6AXU4B.mjs → chunk-NARTAWRN.mjs} +50 -30
  24. package/node_modules/@higgsfield/higgsedit/dist/{chunk-27NBQ5FA.mjs → chunk-NUXTKQNM.mjs} +33 -21
  25. package/node_modules/@higgsfield/higgsedit/dist/chunk-OCIZ36XD.mjs +40 -0
  26. package/node_modules/@higgsfield/higgsedit/dist/{chunk-MK6PL7N4.mjs → chunk-OF6RMSM2.mjs} +19 -17
  27. package/node_modules/@higgsfield/higgsedit/dist/{chunk-6BETMESC.mjs → chunk-P2BGHTRR.mjs} +2 -2
  28. package/node_modules/@higgsfield/higgsedit/dist/{chunk-EKFC4S4M.mjs → chunk-PAHMD6SU.mjs} +5 -0
  29. package/node_modules/@higgsfield/higgsedit/dist/{chunk-QVLAEV3U.mjs → chunk-PFQYUJQL.mjs} +3 -4
  30. package/node_modules/@higgsfield/higgsedit/dist/chunk-QJTILFBS.mjs +335 -0
  31. package/node_modules/@higgsfield/higgsedit/dist/chunk-QQ3GGKDN.mjs +21 -0
  32. package/node_modules/@higgsfield/higgsedit/dist/chunk-TH7TK67K.mjs +23 -0
  33. package/node_modules/@higgsfield/higgsedit/dist/{chunk-SIMO6I3D.mjs → chunk-UDL5AHKO.mjs} +163 -158
  34. package/node_modules/@higgsfield/higgsedit/dist/chunk-UMWOUQN3.mjs +60 -0
  35. package/node_modules/@higgsfield/higgsedit/dist/{chunk-3AIM3THH.mjs → chunk-VLM5EOWJ.mjs} +4 -4
  36. package/node_modules/@higgsfield/higgsedit/dist/chunk-WENFTPXQ.mjs +403 -0
  37. package/node_modules/@higgsfield/higgsedit/dist/chunk-YLVXQIPX.mjs +464 -0
  38. package/node_modules/@higgsfield/higgsedit/dist/editor/.vite/manifest.json +559 -506
  39. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/agent-corner-bottom-q4hZltI-.svg +431 -0
  40. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/agent-corner-top-BJYI-I24.svg +431 -0
  41. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/confirmation-BTnwl3LS.css +1 -0
  42. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/drag-Bt_t4HZO.css +1 -0
  43. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/local-B3OTAV_A.css +1 -0
  44. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/menubar-2Y1Y2XJt.css +1 -0
  45. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/model-DdE4hCgf.css +1 -0
  46. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/{IconText1-CzbCrP7v.css → notifications-B08L1jSe.css} +1 -1
  47. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/{panel-g852pZf_.css → panel-BRN_AbBM.css} +1 -1
  48. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-CYELNqrv.css +1 -0
  49. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-DYLpT6oA.css +1 -0
  50. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-v84HaGTZ.css +1 -0
  51. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconChainLink1-Bxb1Or0F.js +1 -0
  52. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconCheckmark2Medium-daaES9uF.js → IconCheckmark2Medium-hegaz9mQ.js} +1 -1
  53. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconChevronDownSmall-BhTBJk26.js → IconChevronDownSmall-DaruzJwU.js} +1 -1
  54. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconClosedCaptioning-BPqcqKsD.js +1 -0
  55. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconCrossMedium-acfnCXOM.js → IconCrossMedium-BsPFJzc6.js} +1 -1
  56. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconOpenaiFilled-D1fzthmi.js +1 -0
  57. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconPause-pTeVSvUe.js → IconPause-ClNg8pao.js} +1 -1
  58. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{IconPlayFilled-CwdgIuDG.js → IconPlayFilled-CHb-7GSx.js} +1 -1
  59. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconSparklesSoftFilled-o7o33KRn.js +1 -0
  60. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/ai-composer-B9h-eaki.js +567 -0
  61. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/auto-layout-BO20Tg4B.js +1 -0
  62. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{button-CjG6GcgF.js → button-Cg0U0zpV.js} +1 -1
  63. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/canvas-Bw4CVzfw.js +1 -0
  64. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/capabilities-BCd4-zPF.js +1 -0
  65. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/commands-QeSqAbCt.js +1 -0
  66. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/components-tXMtIZNL.js +51 -0
  67. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/confirmation-CO2PHR_z.js +1 -0
  68. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/dom-6aoQn29n.js +1 -0
  69. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/drag-Dw8b_vO2.js +1 -0
  70. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{editing-CjWbiCxv.js → editing-Cy-SaOyB.js} +1 -1
  71. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/edits-CqLBqir0.js +1 -0
  72. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/export-dialog-BjBskOe3.js +2 -0
  73. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/factories-Bw_iQrUL.js +1 -0
  74. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/id3-CSR0NCRI.js +2 -0
  75. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/import-DP49i4ke.js +1 -0
  76. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/import-error-CMz9sLPe.js +1 -0
  77. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/ingest-DsmIc415.js +1 -0
  78. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/jsx-runtime-B5yqYJvp.js +1 -0
  79. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/{media-Bwjxu-0U.js → media-DQw6vU_T.js} +1 -1
  80. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/menubar-D31srALX.js +1 -0
  81. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/meters-D0nZVEJs.js +1 -0
  82. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/mode-DEG6doKF.js +1 -0
  83. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/model-Duf9fszJ.js +2 -0
  84. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/model-DyAkLA69.js +1 -0
  85. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/notifications-DqWZNIrK.js +9 -0
  86. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/palette-HT83gWgL.js +1 -0
  87. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-B5Mvm6dg.js +7 -0
  88. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-BC90wyvd.js +1 -0
  89. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-Bw_ZJ2JI.js +3 -0
  90. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DNS060Nt.js +3 -0
  91. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DSgxIrEq.js +2 -0
  92. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DgBttE5O.js +1 -0
  93. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-assets-_T2bHsHW.js +771 -0
  94. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-inspector-DfHvAt5X.js +2 -0
  95. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-nBZvHlkA.js +1 -0
  96. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-timeline-DsCpJVSt.js +327 -0
  97. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-viewport-CEhZwZ67.js +280 -0
  98. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/projects-2_tW9Do7.js +1 -0
  99. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/react-dom-1uB7Vbbb.js +1 -0
  100. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/schemas-CddYAOcj.js +64 -0
  101. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/session-BpFeKAI2.js +1 -0
  102. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/src-BLG3tYBa.js +2 -0
  103. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/styles-e2n2A_JN.js +284 -0
  104. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/supercomputer-CuV0zYKd.js +24 -0
  105. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/tabs-XeAgs9cs.js +1 -0
  106. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/toggle-DbNEaSIl.js +1 -0
  107. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-C8Ll3qFl.js +69 -0
  108. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-bar-Dv1LPFbu.js +1 -0
  109. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useOpenInteractionType-HWSfSsp2.js +1 -0
  110. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useRenderElement-D4SOg3N_.js +1 -0
  111. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/value-EB7YmAdS.js +1 -0
  112. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/writeback-support-fj5rA9k3.js +1 -0
  113. package/node_modules/@higgsfield/higgsedit/dist/editor/editor-B-WAkLt7.js +372 -0
  114. package/node_modules/@higgsfield/higgsedit/dist/higgsedit.mjs +39 -24
  115. package/node_modules/@higgsfield/higgsedit/dist/jsx/hooks.d.ts +26 -0
  116. package/node_modules/@higgsfield/higgsedit/dist/jsx/index.d.ts +17 -0
  117. package/node_modules/@higgsfield/higgsedit/dist/jsx/inspect.d.ts +42 -0
  118. package/node_modules/@higgsfield/higgsedit/dist/jsx/jsx-runtime.d.ts +28 -0
  119. package/node_modules/@higgsfield/higgsedit/dist/jsx/svg.d.ts +9 -0
  120. package/node_modules/@higgsfield/higgsedit/dist/jsx/time.d.ts +6 -0
  121. package/node_modules/@higgsfield/higgsedit/dist/jsx/types.d.ts +420 -0
  122. package/node_modules/@higgsfield/higgsedit/package.json +28 -20
  123. package/package.json +4 -3
  124. package/plugin/.codex-plugin/plugin.json +1 -1
  125. package/plugin/plugin.json +1 -1
  126. package/plugin/skills/video-editing/references/caption-titling.md +1 -1
  127. package/plugin/skills/video-editing/references/local-setup.md +3 -3
  128. package/node_modules/@higgsfield/higgsedit/dist/chunk-C6SASQHE.mjs +0 -424
  129. package/node_modules/@higgsfield/higgsedit/dist/chunk-FZ5U36SQ.mjs +0 -83
  130. package/node_modules/@higgsfield/higgsedit/dist/chunk-QLPCYN6K.mjs +0 -292
  131. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/edit-drag-D2EV5ddd.css +0 -1
  132. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/editor-CuRHT75g.css +0 -1
  133. package/node_modules/@higgsfield/higgsedit/dist/editor/assets/panel-DnuQD7ja.css +0 -1
  134. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/FieldControl-B0fenhBJ.js +0 -2
  135. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconChainLink1-Cwv1X7hi.js +0 -1
  136. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconEyeOpen-BqTT9_VV.js +0 -1
  137. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconEyeSlash-Whv58c1m.js +0 -1
  138. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconPencil-Dr17k_7e.js +0 -1
  139. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconPlay-BroH3ziH.js +0 -1
  140. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconPlusSmall-43T9aE3d.js +0 -1
  141. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconText1-BaP_p9DW.js +0 -1
  142. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/IconTrashCan-DX2w2AIC.js +0 -1
  143. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/ai-composer-C-l0eIdP.js +0 -560
  144. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/captions-Cd-bDG3G.js +0 -1
  145. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/clip-highlight-DpAvcA4x.js +0 -1
  146. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/components-e3ZbUVns.js +0 -1
  147. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/disposables-CwUPjcuA.js +0 -1
  148. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/drag-HLBkto5o.js +0 -1
  149. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/dropdown-BJ04G_X3.js +0 -1
  150. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/edit-drag-Bg6LggKC.js +0 -1
  151. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/edits-a2IixhrN.js +0 -1
  152. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/export-dialog-4I4gqI5V.js +0 -2
  153. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/face-tracker-DzVfjVOO.js +0 -1
  154. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/fit-imported-media-CaCB0x0b.js +0 -1
  155. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/generation-queue-DuL2F4-_.js +0 -1
  156. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/import-error-CMARA0Hy.js +0 -1
  157. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/jsx-runtime-B-hcVAMW.js +0 -1
  158. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/menubar-Bs26OdwP.js +0 -1
  159. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/meters-YEr9OQjq.js +0 -1
  160. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/paints-DS2Msf91.js +0 -67
  161. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/palette-CcS9IcAC.js +0 -1
  162. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-7M3uQokX.js +0 -1
  163. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-BBK1NyG-.js +0 -1
  164. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-CHZTs7By.js +0 -4
  165. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DaSOa3MP.js +0 -2
  166. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-DlK3RYVo.js +0 -1
  167. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-Dst5OKWu.js +0 -2
  168. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-H_ZoDiKK.js +0 -2
  169. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-Rn9Z7Eek.js +0 -3
  170. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-assets-FAghGFG3.js +0 -678
  171. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-inspector-DEqULBNF.js +0 -260
  172. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-timeline-0GYNz1uc.js +0 -333
  173. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/panel-viewport-DOWjJi5-.js +0 -317
  174. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/projects-BBJc7h5_.js +0 -2
  175. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/session-B9sZaFKC.js +0 -1
  176. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/supercomputer-CX-LCL6Y.js +0 -24
  177. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/tabs-CvKQ-eas.js +0 -1
  178. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/toggle-CrzrwiDZ.js +0 -1
  179. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-BgRfk-Qq.js +0 -69
  180. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/transport-bar-C9nqAfE2.js +0 -1
  181. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/typography-C5-w9LOu-kD3uLKkf.js +0 -1
  182. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useOpenInteractionType-DbrQ6Ehu.js +0 -1
  183. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/useRenderElement-bbxXdYq0.js +0 -1
  184. package/node_modules/@higgsfield/higgsedit/dist/editor/chunks/writeback-support-BZfNpkmB.js +0 -1
  185. package/node_modules/@higgsfield/higgsedit/dist/editor/editor-Csn2_T_e.js +0 -293
  186. package/node_modules/@higgsfield/higgsedit/dist/export-settings.mjs +0 -75
  187. package/node_modules/@higgsfield/higgsedit/dist/history.mjs +0 -295
  188. package/node_modules/@higgsfield/higgsedit/dist/media-upload.mjs +0 -381
  189. package/node_modules/@higgsfield/higgsedit/dist/proxy.mjs +0 -170
@@ -1,560 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["chunks/panel-Dst5OKWu.js","chunks/jsx-runtime-B-hcVAMW.js","chunks/useRenderElement-bbxXdYq0.js","chunks/typography-C5-w9LOu-kD3uLKkf.js","chunks/FieldControl-B0fenhBJ.js","chunks/useOpenInteractionType-DbrQ6Ehu.js","chunks/dropdown-BJ04G_X3.js","editor-Csn2_T_e.js","chunks/paints-DS2Msf91.js","chunks/session-B9sZaFKC.js","chunks/disposables-CwUPjcuA.js","chunks/captions-Cd-bDG3G.js","assets/editor-CuRHT75g.css","chunks/button-CjG6GcgF.js","chunks/tabs-CvKQ-eas.js","chunks/toggle-CrzrwiDZ.js","chunks/media-Bwjxu-0U.js","chunks/IconChevronDownSmall-BhTBJk26.js","chunks/IconCrossMedium-acfnCXOM.js","chunks/IconPencil-Dr17k_7e.js"])))=>i.map(i=>d[i]);
2
- import{i as e}from"./jsx-runtime-B-hcVAMW.js";import{d as t,t as n,u as r}from"./session-B9sZaFKC.js";import{t as i}from"./disposables-CwUPjcuA.js";import{C as a,h as o,m as s}from"../editor-Csn2_T_e.js";import{i as c,n as l,r as u,t as d}from"./generation-queue-DuL2F4-_.js";import{t as f}from"./panel-4DTzhYdA.js";var p=[`completed`,`failed`,`canceled`];function m(e){return p.includes(e)}var h={"16:9":`Wide`,"9:16":`Vertical`,"1:1":`Square`,"4:3":`Classic`,"3:4":`Tall`},g={kling:`Kling`,google:`Google`,wan:`Wan`,minimax:`MiniMax`,bytedance:`ByteDance`,xai:`xAI`,higgsfield:`Higgsfield`,bfl:`BFL`,alibaba:`Alibaba`};function _(e){return g[e]??e}var v=2500,y=5e3,b=1.2;function x(e,t){return new Promise(n=>{let r=setTimeout(i,e);function i(){clearTimeout(r),t?.removeEventListener(`abort`,i),n()}t?.addEventListener(`abort`,i,{once:!0})})}async function*S(e,t,n){let r=n?.signal,i=n?.pollMs??v,a=await e.getJob(t);for(yield a;!m(a.status);){if(r?.aborted||(await x(i,r),r?.aborted))return a;i=Math.min(y,i*b),a=await e.getJob(t),yield a}return a}var C=`capability:storage/local`,w=`capability:ai/pending-clips`,T=`capability:ai/project-generations`;function E(e,i){let o=new a(!1),s=new a(`video`),d=new a(!1),f=new a([]),p=new a([]),h=new a([]),g=new a(null),_=new a({}),v=new a([]),y=new a([]),b=new a([]),x=new a(null),w=new a(null),T=new a([]),E=new a(null),D=new a(null),O=new Map,k=new Set,A=new Set,j=new Map,M=new Map,N=!1,P=!1,F=!1,I=null,L=null,R=null,z=null;e.require(n).then(e=>I=e),e.require(t).then(e=>L=e),e.require(C).then(e=>R=e),e.require(r).then(e=>z=e),i.listHistory(100).then(e=>{if(F)return;let t=e.filter(e=>typeof e.projectId==`string`&&e.projectId.length>0);for(let e of t)j.set(e.id,e.projectId);p.set(t)}).catch(()=>{});let B=(e,t,n,r,i,a)=>{let o=a===void 0?I?.currentTime.get()??0:Math.max(0,a),s={jobId:e,projectId:j.get(e)??L?.snapshot()?.id??null,label:t,kind:n,start:o,duration:n===`image`?5:Math.max(r,.5),status:i};return h.set([...h.get().filter(t=>t.jobId!==e),s]),s},V=e=>{let t=h.get();t.some(t=>t.jobId===e.id&&t.status!==e.status)&&h.set(t.map(t=>t.jobId===e.id?{...t,status:e.status}:t))},H=e=>{let t=h.get();t.some(t=>t.jobId===e)&&h.set(t.filter(t=>t.jobId!==e))},U=(e,t)=>{h.set(h.get().map(n=>n.jobId===e?{...n,jobId:t}:n))},ee=e=>h.get().find(t=>t.jobId===e)?.start??null,W=e=>{let t=f.get(),n=t.findIndex(t=>t.id===e.id);f.set(n>=0?t.map((t,r)=>r===n?e:t):[...t,e]);let r=e.projectId??j.get(e.id);if(r){j.set(e.id,r);let t=p.get(),n=t.findIndex(t=>t.id===e.id),i={...e,projectId:r};p.set(n>=0?t.map((e,t)=>t===n?i:e):[...t,i])}V(e),(e.status===`failed`||e.status===`canceled`)&&H(e.id),e.status===`completed`&&!A.has(e.id)&&!k.has(e.id)&&(k.add(e.id),G(e))};async function te(t){let n=R?R.importFile.bind(R):(await e.require(C)).importFile,r=L??await e.require(`capability:document.session`),a=z??await e.require(`capability:document.placement`),o=await c({fetchResult:i.fetchResultFile,importFile:n,snapshot:()=>r.snapshot(),placement:a,execute:(t,n)=>e.commands.execute(t,n),playhead:()=>ee(t.id)??I?.currentTime.get()??0,select:e=>I?.setSelection({clipIds:[e]})},t);H(t.id);let s=o.ok?{kind:`added`}:{kind:`error`,message:o.message};return F?s:(_.set({..._.get(),[t.id]:s}),o.ok||W({...t,status:`failed`,resultUrl:null,error:o.message}),s)}function G(e){let t=M.get(e.id);if(t)return t;let n=te(e).finally(()=>M.delete(e.id));return M.set(e.id,n),n}let K=e=>{if(O.has(e))return;let t=new AbortController;O.set(e,t),(async()=>{try{let n=S(i,e,{signal:t.signal});for(;;){let e=await n.next();if(e.value&&!F&&W(e.value),e.done)break}}catch{}finally{O.delete(e)}})()};function q(){let e=L?.snapshot()??null,t=I?.selection.get().clipIds[0]??null;if(!e||!t)return null;let n=e.scenes.find(t=>t.id===e.activeSceneId);for(let e of n?.tracks??[]){let n=e.clips.find(e=>e.id===t);if(n)return n}return null}function J(e,t){if(!e||!t)return`16:9`;let n=e/t;return[[`21:9`,21/9],[`16:9`,16/9],[`4:3`,4/3],[`1:1`,1],[`3:4`,3/4],[`9:16`,9/16]].reduce((e,t)=>Math.abs(t[1]-n)<Math.abs(e[1]-n)?t:e)[0]}async function ne(t){let n=q();if(!n||!(`assetId`in n))return null;let r=await e.assets.get(n.assetId).catch(()=>null);return!r||r.kind!==`video`?null:{tool:t,clipId:n.id,assetId:n.assetId,assetName:r.name,assetMimeType:r.mimeType,assetDuration:r.duration??null,sourceAspectRatio:J(r.width,r.height)}}function Y(e,t,n,r,i,a){return{id:e,modelId:t,prompt:n,kind:r,status:i,resultUrl:null,thumbnailUrl:null,error:a,createdAt:Date.now(),credits:null,projectId:null}}function X(e,t,n){W(Y(u(),`transform`,t,e,`failed`,n))}async function Z(t,n,r,a,o,s,c,l){try{let n=await e.assets.readBlob(o.assetId),r=new File([n],o.name,{type:o.mimeType}),a=await c(await i.upload(r,s));f.set(f.get().filter(e=>e.id!==t)),U(t,a.id),W(a),K(a.id)}catch(e){W(Y(t,n,r,a,`failed`,e instanceof Error?e.message:l))}}async function Q(){if(v.get().length>0)return;let e=await i.listModels().catch(()=>null);e&&(v.set(e.models),y.set(e.transforms??[]),b.set(e.editApps??[]))}let $=l(e,i,e=>{A.add(e.id),W(e)},e=>{A.delete(e),k.add(e),_.set({..._.get(),[e]:{kind:`added`}})});return{generationQueue:$,open:o,mediaKind:s,createVideo:()=>$.createVideo(),settingsOpen:d,jobs:f,projectGenerations:p,pending:h,draft:g,ingest:_,models:v,transforms:y,editApps:b,editTarget:x,toolTarget:w,sceneLightingPresets:T,sceneLightingPresetsError:E,modelsError:D,loadModels(){N||v.get().length>0||(N=!0,i.listModels().then(e=>{v.set(e.models),y.set(e.transforms??[]),b.set(e.editApps??[]),D.set(e.models.length>0?null:`No models available`)}).catch(e=>D.set(e instanceof Error?e.message:`Model catalog unavailable`)).finally(()=>N=!1))},async submit(t){let n=L??await e.require(`capability:document.session`);L=n;let r=n.snapshot()?.id??null,a=await i.submitVideo({...t,projectId:r});return r&&j.set(a.id,r),B(a.id,a.prompt,a.kind,t.duration,a.status),W(a),K(a.id),a},trackExternal(e){A.add(e.jobId),j.set(e.jobId,e.projectId);let t=B(e.jobId,e.label,e.kind,e.duration,e.status,e.start),n=Y(e.jobId,e.modelId,e.label,e.kind,e.status,null);return W({...n,createdAt:e.createdAt??n.createdAt}),m(e.status)||K(e.jobId),t},async importTracked(e,t){let n=_.get()[e];if(n)return n;let r=await i.getJob(e);if(r.status!==`completed`)throw Error(`Generation ${e} is not completed`);let a=h.get().find(t=>t.jobId===e);a&&t!==void 0?h.set(h.get().map(n=>n.jobId===e?{...n,start:Math.max(0,t)}:n)):a||B(r.id,r.prompt,r.kind,5,r.status,t),A.add(e),W(r),k.add(e);let o=await G(r);return A.delete(e),o},async transformSelection(t){let n=t.action===`reframe`?`Reframe to ${t.aspect}`:t.action===`remove-background`?`Remove Background`:`Upscale`,r=q();if(!r||!(`assetId`in r)){X(`video`,n,`Select a media clip first`);return}let a=await e.assets.get(r.assetId).catch(()=>null);if(!a){X(`video`,n,`Clip asset not found`);return}await Q();let o=y.get(),s=t.action===`reframe`?o.find(e=>e.id===`reframe`):t.action===`remove-background`?{id:`video-background-remover`,name:`Remove Background`,description:`Remove the video background`,kind:`video`,inputKind:`video`,aspectRatios:[],defaultAspect:null}:o.find(e=>e.inputKind===a.kind&&e.id.includes(`upscale`));if(!s){X(a.kind===`image`?`image`:`video`,n,`Transform unavailable on this server`);return}if(s.inputKind!==a.kind){X(s.kind,n,`${s.name} needs a ${s.inputKind} clip`);return}let c=`${n} — ${a.name}`,l=u();W(Y(l,s.id,c,s.kind,`queued`,null)),B(l,c,s.kind,a.duration??5,`queued`),await Z(l,s.id,c,s.kind,{assetId:r.assetId,name:a.name,mimeType:a.mimeType},a.kind===`image`?`image`:`video`,e=>i.submitTransform({transformId:s.id,mediaId:e,aspectRatio:t.action===`reframe`?t.aspect:null,resolution:t.action===`reframe`?t.resolution:void 0,sourceDuration:a.duration??null,label:c,projectId:L?.snapshot()?.id??null}),`Transform failed to start`)},async openTool(e){let t=await ne(e);if(!t){X(`video`,e===`reframe`?`Reframe`:`Change scene & lighting`,`Select a video clip first`);return}x.set(null),w.set(t),o.set(!0),!(e!==`scene-lighting`||T.get().length>0||P)&&(P=!0,E.set(null),i.listSceneLightingPresets().then(e=>T.set(e)).catch(e=>E.set(e instanceof Error?e.message:`Scene lighting presets unavailable`)).finally(()=>P=!1))},async submitReframe(e,t){await this.transformSelection({action:`reframe`,aspect:e,resolution:t}),w.set(null)},async submitSceneLighting(e,t){let n=w.get();if(!n||n.tool!==`scene-lighting`)return;let r=`${e.name} — ${n.assetName}`,a=u();W(Y(a,`video-scene-lighting`,r,`video`,`queued`,null)),B(a,r,`video`,n.assetDuration??5,`queued`),w.set(null),await Z(a,`video-scene-lighting`,r,`video`,{assetId:n.assetId,name:n.assetName,mimeType:n.assetMimeType},`video`,a=>i.submitSceneLighting({mediaId:a,presetId:e.id,aspectRatio:t,sourceDuration:n.assetDuration,label:r,projectId:L?.snapshot()?.id??null}),`Scene lighting failed to start`)},async toggleEditApp(t){if(x.get()?.app.id===t){x.set(null);return}await Q();let n=b.get().find(e=>e.id===t);if(!n){X(`video`,`AI edit`,`Edit app unavailable on this server`);return}let r=q();if(!r||!(`assetId`in r)){X(`video`,n.name,`Select a media clip first`);return}let i=await e.assets.get(r.assetId).catch(()=>null);if(!i||i.kind!==`video`){X(`video`,n.name,`${n.name} needs a video clip`);return}x.set({app:n,clipId:r.id,assetId:r.assetId,assetName:i.name,assetMimeType:i.mimeType,assetDuration:i.duration??null,sourceAspectRatio:J(i.width,i.height)}),w.set(null),o.set(!0)},async submitEdit(e){let t=x.get();if(!t)return;let n=`${t.app.name} — ${t.assetName}`,r=u();W(Y(r,t.app.id,n,`video`,`queued`,null)),B(r,n,`video`,t.assetDuration??5,`queued`),x.set(null),await Z(r,t.app.id,n,`video`,{assetId:t.assetId,name:t.assetName,mimeType:t.assetMimeType},`video`,r=>i.submitEdit({appId:t.app.id,mediaId:r,prompt:e,sourceDuration:t.assetDuration,aspectRatio:t.sourceAspectRatio,resolution:`720p`,generateAudio:!0,label:n,projectId:L?.snapshot()?.id??null}),`Edit failed to start`)},dismiss(e){O.get(e)?.abort(),O.delete(e),A.delete(e),f.set(f.get().filter(t=>t.id!==e)),j.delete(e),p.set(p.get().filter(t=>t.id!==e)),H(e);let{[e]:t,...n}=_.get();_.set(n)},busy(e){return e.status===`queued`||e.status===`in_progress`||!A.has(e.id)&&e.status===`completed`&&!_.get()[e.id]},awaitingImport(e){return A.has(e)&&f.get().some(t=>t.id===e&&t.status===`completed`)},dispose(){F=!0,$.dispose(),d.set(!1),x.set(null),w.set(null);for(let e of O.values())e.abort();O.clear(),A.clear(),j.clear(),M.clear(),h.set([]),p.set([]),g.set(null)}}}var D=`fable-ai-composer-styles`,O=`
3
- .ai-account-wrap {
4
- display: flex;
5
- flex-direction: column;
6
- gap: 7px;
7
- width: 100%;
8
- box-sizing: border-box;
9
- }
10
-
11
- .ai-settings-popover {
12
- position: fixed;
13
- top: calc(44px + env(safe-area-inset-top, 0px));
14
- left: min(300px, calc(100vw - 388px));
15
- margin: 0;
16
- z-index: 900;
17
- width: 380px;
18
- max-width: calc(100vw - 16px);
19
- max-height: calc(100vh - 60px - env(safe-area-inset-bottom, 0px));
20
- overflow-y: auto;
21
- box-sizing: border-box;
22
- padding: 8px;
23
- border-radius: 12px;
24
- }
25
-
26
- .ai-settings-popover::backdrop { background: transparent; }
27
-
28
- .ai-settings-header {
29
- display: flex;
30
- align-items: center;
31
- justify-content: space-between;
32
- padding: 6px 7px 8px;
33
- }
34
-
35
- .ai-account-row { display: flex; align-items: center; gap: 8px; min-height: 24px; }
36
- .ai-account-spacer { flex: 1; }
37
- .ai-account-label { display: inline-flex; align-items: center; gap: 5px; min-width: 0; }
38
- .ai-inline-error { padding: 0 7px; }
39
-
40
- .ai-generation-history {
41
- display: flex;
42
- flex-direction: column;
43
- gap: 2px;
44
- max-height: 220px;
45
- overflow-y: auto;
46
- border-radius: 10px;
47
- padding: 5px;
48
- }
49
- .ai-history-state { padding: 10px; }
50
- .ai-history-job { display: flex; align-items: center; gap: 8px; border-radius: 7px; padding: 7px 8px; }
51
- .ai-history-job:hover { background: var(--color-q-background-tertiary); }
52
- .ai-history-job-copy { display: flex; flex: 1; min-width: 0; flex-direction: column; gap: 2px; }
53
- .ai-history-job-prompt,
54
- .ai-history-job-meta { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
55
-
56
- .ai-overlay {
57
- position: fixed;
58
- left: 50%;
59
- bottom: calc(max(200px, 30vh) + 22px);
60
- transform: translateX(-50%);
61
- width: min(900px, calc(100vw - 48px));
62
- display: flex;
63
- flex-direction: column;
64
- gap: 8px;
65
- z-index: 800;
66
- }
67
-
68
- .ai-composer {
69
- display: flex;
70
- flex-direction: column;
71
- gap: 4px;
72
- }
73
-
74
- .ai-composer[hidden] { display: none; }
75
-
76
- .ai-composer-main {
77
- display: flex;
78
- align-items: stretch;
79
- gap: 4px;
80
- min-width: 0;
81
- }
82
-
83
- .ai-compose-card {
84
- position: relative;
85
- display: flex;
86
- flex-direction: row;
87
- flex: 1;
88
- gap: 4px;
89
- min-width: 0;
90
- min-height: 112px;
91
- box-sizing: border-box;
92
- padding: 4px;
93
- border-radius: 24px;
94
- }
95
-
96
- .ai-composer-close {
97
- position: absolute;
98
- top: var(--hf-space-300);
99
- right: var(--hf-space-300);
100
- z-index: 2;
101
- display: inline-flex;
102
- align-items: center;
103
- justify-content: center;
104
- width: var(--hf-space-800);
105
- height: var(--hf-space-800);
106
- padding: 0;
107
- border-radius: 50%;
108
- }
109
-
110
- .ai-compose-content {
111
- display: flex;
112
- flex: 1;
113
- flex-direction: column;
114
- gap: 6px;
115
- min-width: 0;
116
- padding: 12px;
117
- border-radius: 20px;
118
- }
119
-
120
-
121
-
122
- .ai-edit-chip {
123
- display: inline-flex;
124
- flex-direction: row;
125
- align-items: center;
126
- gap: 8px;
127
- align-self: flex-start;
128
- min-width: 0;
129
- max-width: calc(100% - var(--hf-space-1000));
130
- min-height: var(--hf-space-800);
131
- border: 0;
132
- border-radius: 8px;
133
- padding: 4px 8px;
134
- }
135
-
136
- .ai-edit-chip .ai-edit-name { font-weight: 600; white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; }
137
-
138
- .ai-edit-chip .ai-edit-asset {
139
- color: var(--color-q-text-tertiary);
140
- max-width: 200px;
141
- min-width: 0;
142
- overflow: hidden;
143
- text-overflow: ellipsis;
144
- white-space: nowrap;
145
- }
146
-
147
- .ai-tool-config {
148
- display: flex;
149
- flex-direction: column;
150
- gap: var(--hf-space-300);
151
- min-width: 0;
152
- }
153
-
154
- .ai-tool-header {
155
- display: flex;
156
- align-items: center;
157
- gap: 8px;
158
- min-width: 0;
159
- min-height: var(--hf-space-800);
160
- padding-right: var(--hf-space-1000);
161
- }
162
-
163
- .ai-tool-header > strong { flex-shrink: 0; }
164
-
165
- .ai-tool-header > span {
166
- min-width: 0;
167
- }
168
-
169
- .ai-tool-options {
170
- display: flex;
171
- flex-wrap: wrap;
172
- gap: 4px;
173
- }
174
-
175
- .ai-preset-grid {
176
- display: grid;
177
- grid-template-columns: repeat(3, minmax(0, 1fr));
178
- gap: 4px;
179
- max-height: 220px;
180
- overflow-y: auto;
181
- }
182
-
183
- .ai-preset {
184
- display: grid;
185
- grid-template-columns: 36px minmax(0, 1fr);
186
- grid-template-rows: auto auto;
187
- gap: 2px 6px;
188
- padding: 5px;
189
- border: 1px solid transparent;
190
- text-align: left;
191
- }
192
-
193
- .ai-preset.selected {
194
- border-color: var(--color-q-border-focus);
195
- }
196
-
197
- .ai-preset .q-media {
198
- grid-row: 1 / 3;
199
- width: 36px;
200
- height: 36px;
201
- }
202
-
203
- .ai-preset > span,
204
- .ai-preset > small {
205
- overflow: hidden;
206
- text-overflow: ellipsis;
207
- white-space: nowrap;
208
- }
209
-
210
-
211
-
212
- .ai-frames { display: flex; gap: 4px; }
213
-
214
- .ai-frame-chip {
215
- display: inline-flex;
216
- align-items: center;
217
- gap: 6px;
218
- min-height: 28px;
219
- box-sizing: border-box;
220
- border: 1px solid transparent;
221
- border-radius: 8px;
222
- padding: 4px 8px;
223
- color: var(--color-q-text-tertiary);
224
- cursor: pointer;
225
- user-select: none;
226
- }
227
-
228
- .ai-frame-chip:hover { background: var(--color-q-background-tertiary); }
229
- .ai-frame-chip.filled { border-style: solid; color: var(--color-q-text-primary); }
230
- .ai-frame-chip.dragover { border-color: var(--color-q-border-focus); color: var(--color-q-text-primary); }
231
-
232
- .ai-frame-chip img {
233
- width: 20px;
234
- height: 20px;
235
- object-fit: cover;
236
- border-radius: 4px;
237
- flex: none;
238
- }
239
-
240
- .ai-frame-icon { display: inline-flex; align-items: center; font-size: var(--hf-type-size-100); }
241
-
242
-
243
-
244
- .ai-prompt-wrap { position: relative; flex: 1; min-height: 34px; }
245
- .ai-prompt-wrap:first-child { margin-top: var(--hf-space-800); }
246
- .ai-frames:first-child { padding-inline-end: var(--hf-space-1000); }
247
-
248
- .ai-prompt {
249
- --q-textarea-min-height: var(--hf-space-2000);
250
- width: 100%;
251
- }
252
-
253
- .ai-prompt-control {
254
- min-height: var(--hf-space-2000);
255
- padding: var(--hf-space-300);
256
- border: 0;
257
- background: var(--hf-color-overlay-dim-soft);
258
- }
259
-
260
- .ai-prompt-control:focus-within {
261
- box-shadow: inset 0 0 0 var(--hf-border-width-thin) var(--hf-color-border-focus);
262
- }
263
-
264
- .ai-prompt-input {
265
- width: 100%;
266
- background: transparent;
267
- border: none;
268
- outline: none;
269
- resize: none;
270
- font: inherit;
271
- font-size: var(--hf-type-size-200);
272
- line-height: var(--hf-type-line-height-500);
273
- min-height: var(--hf-space-1400);
274
- max-height: 160px;
275
- padding: 0;
276
- display: block;
277
- }
278
-
279
- .ai-history {
280
- position: absolute;
281
- bottom: calc(100% + 8px);
282
- left: 0;
283
- right: 0;
284
- border-radius: var(--radius-lg, 12px);
285
- padding: 6px;
286
- max-height: 220px;
287
- overflow-y: auto;
288
- z-index: 20;
289
- }
290
-
291
- .ai-history-item {
292
- padding: 7px 10px;
293
- border-radius: 6px;
294
- cursor: pointer;
295
- white-space: nowrap;
296
- overflow: hidden;
297
- text-overflow: ellipsis;
298
- }
299
-
300
- .ai-history-item:hover { background: var(--color-q-brand-primary); color: var(--color-q-text-inverse); }
301
- .ai-history-empty { padding: 7px 10px; }
302
-
303
-
304
-
305
- .ai-controls {
306
- display: flex;
307
- flex-wrap: wrap;
308
- align-items: center;
309
- gap: 4px;
310
- min-width: 0;
311
- overflow: visible;
312
- }
313
-
314
- .ai-reference-chip {
315
- position: relative;
316
- width: 28px;
317
- height: 28px;
318
- flex: none;
319
- overflow: hidden;
320
- border-radius: 8px;
321
- background: var(--color-q-background-tertiary);
322
- }
323
-
324
- .ai-reference-chip > img { width: 100%; height: 100%; object-fit: cover; }
325
-
326
- .ai-reference-chip > button {
327
- position: absolute;
328
- inset: 0 0 auto auto;
329
- display: inline-flex;
330
- align-items: center;
331
- justify-content: center;
332
- width: 16px;
333
- height: 16px;
334
- padding: 0;
335
- border: 0;
336
- border-radius: 0 8px 0 6px;
337
- background: var(--hf-color-transparent-dark-70);
338
- color: var(--color-q-text-on-overlay-secondary);
339
- cursor: pointer;
340
- }
341
-
342
- .ai-reference-chip > button:focus-visible {
343
- outline: 2px solid var(--color-q-border-focus);
344
- outline-offset: 2px;
345
- }
346
-
347
- .ai-kind {
348
- flex: none;
349
- width: 72px;
350
- box-sizing: border-box;
351
- padding: 4px;
352
- border-radius: 24px;
353
- background: var(--color-q-background-secondary);
354
- }
355
-
356
- .ai-kind .q-tabs-list {
357
- display: flex;
358
- flex-direction: column;
359
- height: 100%;
360
- }
361
-
362
- .ai-kind .q-tabs-tab {
363
- flex: 1;
364
- min-height: 52px;
365
- }
366
-
367
- .ai-kind .q-tabs-tab-content {
368
- flex-direction: column;
369
- align-items: center;
370
- justify-content: center;
371
- gap: 4px;
372
- }
373
-
374
- .ai-pill {
375
- min-height: 28px;
376
- max-width: min(11.875rem, 100%);
377
- white-space: nowrap;
378
- }
379
-
380
- .ai-pill > span { display: inline-flex; align-items: center; gap: 5px; }
381
- .ai-pill > span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
382
-
383
- .ai-menu-positioner { z-index: 900; }
384
-
385
- .ai-menu {
386
- min-width: 225px;
387
- max-height: 260px;
388
- }
389
-
390
- .ai-menu.models { min-width: 300px; }
391
-
392
- .ai-audio {
393
- display: inline-flex;
394
- align-items: center;
395
- gap: 7px;
396
- color: var(--color-q-text-tertiary);
397
- cursor: pointer;
398
- font: inherit;
399
- min-height: 28px;
400
- background: var(--color-q-background-tertiary);
401
- border: none;
402
- border-radius: 8px;
403
- padding: 4px 8px;
404
- }
405
-
406
- .ai-audio.on { color: var(--color-q-text-primary); }
407
-
408
- .ai-audio .knob-track {
409
- width: 26px;
410
- height: 15px;
411
- border-radius: 999px;
412
- background: var(--color-q-background-secondary-strong);
413
- position: relative;
414
- transition: background 0.15s;
415
- flex: none;
416
- }
417
-
418
- .ai-audio.on .knob-track { background: var(--color-q-brand-primary); }
419
-
420
- .ai-audio .knob {
421
- position: absolute;
422
- top: 2px;
423
- left: 2px;
424
- width: 11px;
425
- height: 11px;
426
- border-radius: 50%;
427
- background: var(--color-q-text-inverse);
428
- transition: transform 0.15s;
429
- }
430
-
431
- .ai-audio.on .knob { transform: translateX(11px); }
432
-
433
- .ai-submit {
434
- margin-inline-start: auto;
435
- min-height: var(--hf-space-800);
436
- border-radius: 12px;
437
- display: flex;
438
- flex-direction: column;
439
- align-items: center;
440
- justify-content: center;
441
- gap: 2px;
442
- flex: none;
443
- }
444
- .ai-submit-icon { display: none; }
445
-
446
- .ai-submit .q-button-label-frame {
447
- display: flex;
448
- flex-direction: column;
449
- align-items: center;
450
- }
451
-
452
- .ai-submit small {
453
- font-size: var(--hf-type-size-050);
454
- font-weight: 400;
455
- line-height: 12px;
456
- text-transform: none;
457
- opacity: 0.7;
458
- }
459
-
460
- @media (max-width: 760px) {
461
- .ai-overlay { width: min(680px, calc(100vw - 24px)); }
462
- .ai-settings-popover { left: 8px; }
463
- .ai-compose-card { flex-direction: column; }
464
- .ai-kind { width: 64px; }
465
- .ai-controls { flex-wrap: wrap; }
466
- }
467
-
468
-
469
-
470
- .ai-jobs { display: flex; flex-direction: column; gap: 6px; }
471
-
472
- .ai-job {
473
- position: relative;
474
- overflow: hidden;
475
- display: flex;
476
- flex-direction: row;
477
- align-items: center;
478
- gap: 10px;
479
- border-radius: var(--radius-lg, 12px);
480
- padding: 8px 12px;
481
- }
482
-
483
- .ai-job.active::after {
484
- content: "";
485
- position: absolute;
486
- inset: 0;
487
- background: linear-gradient(100deg, transparent 20%, var(--hf-color-overlay-hover) 50%, transparent 80%);
488
- animation: ai-shimmer 1.6s linear infinite;
489
- pointer-events: none;
490
- }
491
-
492
- @keyframes ai-shimmer {
493
- from { transform: translateX(-100%); }
494
- to { transform: translateX(100%); }
495
- }
496
-
497
- .ai-job-icon {
498
- flex: none;
499
- width: 14px;
500
- display: inline-flex;
501
- align-items: center;
502
- justify-content: center;
503
- color: var(--color-q-text-danger);
504
- }
505
-
506
- .ai-job-icon.ok { color: var(--color-q-text-success); }
507
-
508
- .ai-job-body { flex: 1; min-width: 0; }
509
-
510
- .ai-job-prompt {
511
- white-space: nowrap;
512
- overflow: hidden;
513
- text-overflow: ellipsis;
514
- }
515
-
516
- .ai-job-meta {
517
- margin-top: 2px;
518
- white-space: nowrap;
519
- overflow: hidden;
520
- text-overflow: ellipsis;
521
- }
522
-
523
- .fshell[data-design="higgsfield"] .ai-kind { display: none; }
524
- .fshell[data-design="higgsfield"] .ai-compose-card {
525
- padding: var(--hf-space-300);
526
- border: var(--hf-border-width-thin) solid var(--hf-color-border-default);
527
- border-radius: var(--hf-radius-500);
528
- background: var(--color-background-secondary);
529
- box-shadow: var(--hf-shadow-overlay);
530
- }
531
- .fshell[data-design="higgsfield"] .ai-compose-content {
532
- gap: var(--hf-space-400);
533
- padding: 0;
534
- background: transparent;
535
- }
536
- .fshell[data-design="higgsfield"] .ai-prompt {
537
- font-size: var(--hf-type-size-200);
538
- line-height: 16px;
539
- }
540
- .fshell[data-design="higgsfield"] .ai-controls {
541
- gap: var(--hf-space-200);
542
- }
543
- .fshell[data-design="higgsfield"] .ai-pill,
544
- .fshell[data-design="higgsfield"] .ai-audio {
545
- min-height: var(--hf-space-800);
546
- border-radius: var(--hf-radius-full);
547
- }
548
- .fshell[data-design="higgsfield"] .ai-submit {
549
- width: var(--hf-space-1000);
550
- min-height: var(--hf-space-1000);
551
- height: var(--hf-space-1000);
552
- border-radius: var(--hf-radius-full);
553
- background: var(--color-q-brand-primary);
554
- color: var(--color-q-background-primary);
555
- box-shadow: none;
556
- }
557
- .fshell[data-design="higgsfield"] .ai-submit-icon { display: block; }
558
- .fshell[data-design="higgsfield"] .ai-submit-label,
559
- .fshell[data-design="higgsfield"] .ai-submit small { display: none; }
560
- `;function k(e){o(e,D,O)}var A=e({activate:()=>P}),j=new Set([`queued`,`in_progress`,`completed`,`failed`,`canceled`]);function M(e){if(typeof e!=`object`||!e||Array.isArray(e))throw Error(`Invalid generation payload`);let t=e;if(typeof t.jobId!=`string`||typeof t.modelId!=`string`||typeof t.label!=`string`)throw Error(`Generation payload needs jobId, modelId, and label`);if(t.kind!==`video`&&t.kind!==`image`)throw Error(`Generation kind must be video or image`);if(typeof t.status!=`string`||!j.has(t.status))throw Error(`Invalid generation status`);if(typeof t.duration!=`number`||!Number.isFinite(t.duration)||t.duration<0)throw Error(`Generation duration must be non-negative seconds`);if(t.start!==void 0&&(typeof t.start!=`number`||!Number.isFinite(t.start)||t.start<0))throw Error(`Generation start must be non-negative seconds`);if(t.createdAt!==void 0&&(typeof t.createdAt!=`number`||!Number.isFinite(t.createdAt)))throw Error(`Generation createdAt must be finite`);if(typeof t.projectId!=`string`||t.projectId.length===0)throw Error(`Generation payload needs projectId`);return t}function N(e){if(typeof e!=`object`||!e||Array.isArray(e))throw Error(`Invalid import payload`);let t=e;if(typeof t.jobId!=`string`||t.jobId.length===0)throw Error(`Import payload needs jobId`);if(t.start!==void 0&&(typeof t.start!=`number`||!Number.isFinite(t.start)||t.start<0))throw Error(`Import start must be non-negative seconds`);return t.start===void 0?{jobId:t.jobId}:{jobId:t.jobId,start:t.start}}function P(e,t){let n=new i,r=E(e,t);return n.add({dispose:()=>r.dispose()}),n.add(e.provide(d,r.generationQueue)),n.add(e.provide(w,{pending:r.pending,draft:r.draft})),n.add(e.provide(T,{items:r.projectGenerations})),n.add(e.commands.register(`fable.ai-composer.create-video`,()=>r.createVideo())),n.add(e.commands.register(`fable.ai-composer.open`,()=>r.open.set(!0))),n.add(e.commands.register(`fable.ai-composer.toggle`,()=>r.open.set(!r.open.get()))),n.add(e.commands.register(`fable.ai-composer.settings`,()=>r.settingsOpen.set(!r.settingsOpen.get()))),n.add(e.commands.register(`fable.ai-composer.trackExternalGeneration`,e=>r.trackExternal(M(e)))),n.add(e.commands.register(`fable.ai-composer.importTrackedGeneration`,async e=>{let t=N(e);return await r.importTracked(t.jobId,t.start)})),n.add(e.commands.register(`fable.ai-composer.reframe-vertical`,()=>r.transformSelection({action:`reframe`,aspect:`9:16`}))),n.add(e.commands.register(`fable.ai-composer.reframe-square`,()=>r.transformSelection({action:`reframe`,aspect:`1:1`}))),n.add(e.commands.register(`fable.ai-composer.reframe-wide`,()=>r.transformSelection({action:`reframe`,aspect:`16:9`}))),n.add(e.commands.register(`fable.ai-composer.reframe`,()=>r.openTool(`reframe`))),n.add(e.commands.register(`fable.ai-composer.upscale`,()=>r.transformSelection({action:`upscale`}))),n.add(e.commands.register(`fable.ai-composer.remove-background`,()=>r.transformSelection({action:`remove-background`}))),n.add(e.commands.register(`fable.ai-composer.scene-lighting`,()=>r.openTool(`scene-lighting`))),n.add(e.commands.register(`fable.ai-composer.edit-draw`,()=>r.toggleEditApp(`edit-video`))),n.add(e.commands.register(`fable.ai-composer.edit-backdrop`,()=>r.transformSelection({action:`remove-background`}))),n.add(e.commands.register(`fable.ai-composer.edit-remove`,()=>r.openTool(`scene-lighting`))),n.add(e.extensions.register(`panel`,`fable.ai-composer.panel`,f(()=>s(()=>import(`./panel-Dst5OKWu.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19])),{props:()=>({controller:r}),styles:k}))),n}export{P as activate,h as n,_ as r,A as t};
@@ -1 +0,0 @@
1
- import{Ct as e,J as t,V as n,_t as r,dt as i,et as a,q as o,tt as s,ut as c,wt as l}from"./paints-DS2Msf91.js";var u=0;function d(e=`id`){return`${e}-${globalThis.crypto?.randomUUID?.().slice(0,8)??Math.random().toString(36).slice(2,10)}-${(u++).toString(36)}`}var f=(e={})=>({x:0,y:0,scaleX:1,scaleY:1,rotation:0,skewX:0,skewY:0,anchorX:0,anchorY:0,flipX:!1,flipY:!1,...e}),p=(e=0)=>({mixed:!1,uniform:e,tl:e,tr:e,br:e,bl:e});function m(e,t){return{id:t.id??d(e),name:t.name??e,transform:f(t.transform),size:t.size??{width:100,height:100},opacity:t.opacity??1,blendMode:t.blendMode??`normal`,effects:t.effects??[],timeRange:t.timeRange??{start:0,duration:5},animations:t.animations??[],presetAnimations:t.presetAnimations??[],mask:t.mask??null,locked:t.locked??!1,hidden:t.hidden??!1,...t.constrainX?{constrainX:t.constrainX}:{},...t.constrainY?{constrainY:t.constrainY}:{}}}function h(e={}){return{...m(`rect`,e),kind:`rect`,fill:e.fill??{type:`solid`,color:`#ffffff`},stroke:e.stroke??{color:`#000000`,width:0},cornerRadius:e.cornerRadius??p(0)}}function g(e={}){return{...m(`text`,e),kind:`text`,text:e.text??`Text`,fontFamily:e.fontFamily??`sans-serif`,fontSize:e.fontSize??48,fontWeight:e.fontWeight??400,italic:e.italic??!1,letterSpacing:e.letterSpacing??0,lineHeight:e.lineHeight??1.2,align:e.align??`left`,fill:e.fill??{type:`solid`,color:`#ffffff`},stroke:e.stroke??{color:`#000000`,width:0},motion:e.motion??null}}function _(e){let t=e.timeRange??{start:0,duration:5};return{...m(`media`,{...e,timeRange:t}),kind:`media`,assetId:e.assetId,trim:e.trim??{start:0,end:t.duration},volume:e.volume??1,muted:e.muted??!1,speed:e.speed??1,preservePitch:e.preservePitch??!0,cornerRadius:e.cornerRadius??p(0)}}function v(e){let t=e.timeRange??{start:0,duration:5};return{...m(`audio`,{...e,timeRange:t}),kind:`audio`,assetId:e.assetId,trim:e.trim??{start:0,end:t.duration},volume:e.volume??1,muted:e.muted??!1,speed:e.speed??1,preservePitch:e.preservePitch??!0}}function y(e={}){return{...m(`adjustment`,e),kind:`adjustment`}}function b(e={}){return{...m(`group`,e),kind:`group`,children:e.children??[]}}function x(e={}){return{id:e.id??d(`track`),name:e.name??`Track`,mode:e.mode??`default`,clips:e.clips??[],locked:e.locked??!1,hidden:e.hidden??!1,muted:e.muted??!1,solo:e.solo??!1,volume:e.volume??1}}function S(e){let t=0;for(let n of e.tracks)for(let e of n.clips)t=Math.max(t,e.timeRange.start+e.timeRange.duration);return t}function C(e={}){let t=e.tracks??[];return{id:e.id??d(`scene`),name:e.name??`Scene`,x:e.x??0,y:e.y??0,width:e.width??1920,height:e.height??1080,background:e.background??{type:`solid`,color:`#000000`},fps:e.fps??30,duration:S({tracks:t}),tracks:t,markers:e.markers??[]}}var w=e=>e.kind===`text`&&`captions`in e,T=(e,t)=>typeof e==`number`&&Number.isFinite(e)?e:t;function E(e,n){let i=o(e);if(!i||i.get(r).tag===`scene`)return{width:n.width,height:n.height};let a=t(i);return{width:T(a.width,n.width),height:T(a.height,n.height)}}function D(t,r,a,o,u){let d=r.get(i),f=l(d.preset),p=T(a.width,f.width),m=T(a.height,f.height),h=e(f,d,{width:p,height:m},E(r,o),a.x,a.y),_=c(d.sourceOut,u)??(d.src?t.get(n)?.durations.get(d.src):void 0),v={src:d.src??``,preset:s.includes(d.preset??``)?d.preset:`classic`,colors:[...d.colors??[]],verticalAlign:d.verticalAlign??f.align,offsetX:T(d.offsetX,0),offsetY:T(d.offsetY,0)};return{box:{x:h.x,y:h.y,width:p,height:m},stop:_,clip:e=>({...g({...e,text:``,fontSize:T(a.fontSize,f.font.size),fontFamily:typeof a.fontFamily==`string`?a.fontFamily:f.font.family,fontWeight:a.fontWeight===`bold`?700:a.fontWeight===`normal`?400:T(a.fontWeight,f.font.weight),italic:a.fontStyle===void 0?f.font.italic:a.fontStyle===`italic`,lineHeight:T(a.lineHeight,f.font.lineHeight),align:a.align??f.font.align,fill:{type:`solid`,color:typeof a.fill==`string`?a.fill:`#ffffff`}}),captions:v})}}var O=class extends Error{reason;field;constructor(e,t){super(e),this.reason=e,this.field=t}},k=e=>Math.round(e*1e3)/1e3;function A(e,t){let n=[],r=(e,t)=>n.push({op:`set-prop`,name:e,value:t});for(let n of new Set([...Object.keys(e),...Object.keys(t)])){let[i,o]=[e[n],t[n]];if(JSON.stringify(i)!==JSON.stringify(o))switch(n){case`src`:if(typeof o!=`string`||!o)throw new O(`captions need a transcript src`,`captions.src`);r(`src`,o);break;case`preset`:if(!s.includes(o))throw new O(`caption preset ${JSON.stringify(o)} is not one of ${s.join(`, `)}`,`captions.preset`);r(`preset`,o===`classic`?null:o);break;case`verticalAlign`:if(!a.includes(o))throw new O(`caption verticalAlign ${JSON.stringify(o)} is not one of ${a.join(`, `)}`,`captions.verticalAlign`);r(`verticalAlign`,o);break;case`colors`:if(!Array.isArray(o)||o.some(e=>typeof e!=`string`))throw new O(`caption colors must be a list of CSS colours`,`captions.colors`);r(`colors`,o.length?[...o]:null);break;case`offsetX`:case`offsetY`:if(typeof o!=`number`||!Number.isFinite(o))throw new O(`caption ${n} must be a number`,`captions.${n}`);r(n,o===0?null:k(o));break;default:throw new O(`caption field ${String(n)} is not in higgsedit's vocabulary`,`captions.${String(n)}`)}}return n}export{y as a,_ as c,g as d,x as f,p as h,D as i,h as l,S as m,A as n,v as o,f as p,w as r,b as s,O as t,C as u};
@@ -1 +0,0 @@
1
- import{C as e}from"../editor-Csn2_T_e.js";var t=new WeakMap;function n(n){let r=t.get(n);return r||(r=new e(null),t.set(n,r)),r}function r(e,t,r){typeof matchMedia==`function`&&matchMedia(`(prefers-reduced-motion: reduce)`).matches||n(e).set({documentId:t,clipId:r,startedAt:performance.now()})}export{n,r as t};
@@ -1 +0,0 @@
1
- import{a as e,n as t,t as n}from"./jsx-runtime-B-hcVAMW.js";import{wr as r}from"./useOpenInteractionType-DbrQ6Ehu.js";import{t as i}from"./dropdown-BJ04G_X3.js";import{_ as a}from"../editor-Csn2_T_e.js";import{t as o}from"./button-CjG6GcgF.js";var s=e(t(),1),c=e(r(),1),l=`[+-]?(?:\\d+(?:\\.\\d*)?|\\.\\d+)`,u=RegExp(`^(${l})(ms|s|f)$`,`i`),d=RegExp(`^${l}$`),f=/^(\d+):([0-5]?\d)(?::([0-5]?\d))?(?:[.,](\d{1,3}))?$/;function p(e,t){let n=e.trim().replace(/(?<=[\d.])\s+(?=(?:ms|s|f)$)/i,``);if(n.length===0||/\s/.test(n))return null;if(d.test(n))return Number(n);let r=u.exec(n);if(r){let e=Number(r[1]);switch(r[2].toLowerCase()){case`ms`:return e/1e3;case`f`:return t>0?e/t:null;default:return e}}let i=f.exec(n);if(i){let[,e,t,n,r]=i,a=r?Number(`0.${r}`):0;return n===void 0?Number(e)*60+Number(t)+a:Number(e)*3600+Number(t)*60+Number(n)+a}return null}function m(e){return String(Math.round(e*1e3)/1e3)}var h=n();function g(e){return e?e.closest(`[data-video-editor-root]`)??e.ownerDocument.body:null}function _(e){return Math.round(e*100)/100}function v(e){if(/^#[0-9a-fA-F]{6}$/.test(e))return e.toLowerCase();if(/^#[0-9a-fA-F]{8}$/.test(e))return e.slice(0,7).toLowerCase();if(/^#[0-9a-fA-F]{3}$/.test(e)){let[t,n,r]=[e[1],e[2],e[3]];return`#${t}${t}${n}${n}${r}${r}`.toLowerCase()}return`#000000`}function y(e,t){return t?`${e} ${t}`:e}function b(e,t,n=!0){let r=(0,s.useRef)(t);r.current=t;let i=(0,s.useRef)(e);i.current=e,(0,s.useEffect)(()=>{if(!n)return;let e=()=>Array.isArray(i.current)?i.current:[i.current],t=a(e().map(e=>e.current).find(e=>e!==null)??null),o=t.Node,s=t=>{if(!(t.target instanceof o))return;let n=e().map(e=>e.current).filter(e=>e!==null);n.length>0&&!n.some(e=>e.contains(t.target))&&r.current()},c=e=>{e.key===`Escape`&&r.current()};return t.addEventListener(`pointerdown`,s,!0),t.addEventListener(`keydown`,c,!0),()=>{t.removeEventListener(`pointerdown`,s,!0),t.removeEventListener(`keydown`,c,!0)}},[n])}function x({title:e,actions:t,children:n}){return(0,h.jsxs)(`div`,{className:`fui-section`,children:[(e!==void 0||t!==void 0)&&(0,h.jsxs)(`div`,{className:`fui-section-head`,children:[e!==void 0&&(0,h.jsx)(`span`,{className:`fui-section-title`,children:e}),t]}),n]})}function S({label:e,children:t}){return(0,h.jsxs)(`div`,{className:`fui-row`,children:[(0,h.jsx)(`span`,{className:`fui-row-label`,children:e}),(0,h.jsx)(`div`,{className:`fui-row-controls`,children:t})]})}function C({children:e}){return(0,h.jsx)(`div`,{className:`fui-muted fui-note`,children:e})}function w({source:e,format:t,className:n,initial:r}){let i=(0,s.useRef)(null),a=(0,s.useRef)(t);a.current=t;let o=(0,s.useRef)(r);return o.current=r,(0,s.useEffect)(()=>{if(!e)return;let t=e.subscribe(e=>{let t=i.current;t&&(t.textContent=a.current(e))});return()=>t.dispose()},[e]),(0,s.useEffect)(()=>{let t=i.current;t&&(t.textContent=e?a.current(e.get()):o.current??``)}),(0,h.jsx)(`span`,{ref:i,className:n})}function T(e,t){let n=(0,s.useRef)(t);n.current=t,(0,s.useEffect)(()=>{let t=e.current;if(!t)return;let r=()=>n.current();return t.addEventListener(`change`,r),()=>t.removeEventListener(`change`,r)},[e])}function E(e,t){let[n,r]=(0,s.useState)(null),i=(0,s.useRef)(null),a=(0,s.useRef)(!1);return T(i,()=>{if(a.current){a.current=!1;return}t(i.current.value),r(null)}),{ref:i,value:n??e,onChange:e=>{e.nativeEvent.type===`input`&&(a.current=!1,r(e.target.value))},onKeyDown:e=>{e.key===`Escape`&&(a.current=!0,r(null),i.current?.blur())},clearDraft:()=>r(null)}}var D=3;function O({value:e,onCommit:t,step:n=1,min:r,max:i,className:o,title:c,label:l,disabled:u,onGestureStart:d,onGestureEnd:f}){let p=e=>Math.min(i??1/0,Math.max(r??-1/0,e)),{ref:m,value:g,onChange:v,onKeyDown:b}=E(String(_(e)),e=>{let n=Number.parseFloat(e);Number.isNaN(n)||t(p(n))}),x=d!==void 0||f!==void 0,S=(0,s.useRef)(null),C=(0,s.useRef)({onCommit:t,onGestureStart:d,onGestureEnd:f,clamp:p});return C.current={onCommit:t,onGestureStart:d,onGestureEnd:f,clamp:p},(0,s.useEffect)(()=>()=>S.current?.(),[]),(0,s.useLayoutEffect)(()=>{(u||!x)&&S.current?.()},[u,x]),(0,h.jsx)(`input`,{ref:m,type:`number`,className:y(`fui-input fui-number${x?` fui-scrubbable`:``}`,o),title:c,"aria-label":l,disabled:u,step:n,min:r,max:i,value:g,onChange:v,onKeyDown:b,onPointerDown:x?t=>{if(u||t.button!==0||S.current)return;let r=t.currentTarget;if(r.ownerDocument.activeElement===r)return;t.preventDefault();let i=a(r),o=t.pointerId,s=t.clientX,c=e,l=!1;try{r.setPointerCapture?.(o)}catch{}let d=e=>{if(e.pointerId!==o)return;if(e.buttons===0){f();return}let t=e.clientX-s;if(!l){if(Math.abs(t)<D)return;l=!0,C.current.onGestureStart?.()}C.current.onCommit(C.current.clamp(_(c+t*n)))};function f(e=!1){S.current&&(S.current=null,i.removeEventListener(`pointermove`,d,!0),i.removeEventListener(`pointerup`,p,!0),i.removeEventListener(`pointercancel`,p,!0),i.removeEventListener(`lostpointercapture`,p,!0),i.removeEventListener(`blur`,m),r.hasPointerCapture?.(o)&&r.releasePointerCapture(o),l?C.current.onGestureEnd?.():e&&(r.focus(),r.select()))}function p(e){e.pointerId===o&&f(e.type===`pointerup`)}function m(){f()}S.current=m,i.addEventListener(`pointermove`,d,!0),i.addEventListener(`pointerup`,p,!0),i.addEventListener(`pointercancel`,p,!0),i.addEventListener(`lostpointercapture`,p,!0),i.addEventListener(`blur`,m)}:void 0})}function k({value:e,onCommit:t,commitOnChangeEnd:n=!1,label:r}){let i=(0,s.useRef)(null),[a,o]=(0,s.useState)(null);T(i,()=>{n&&i.current&&(t(i.current.value),o(null))});let c=v(a??e),{ref:l,value:u,onChange:d,onKeyDown:f}=E(c.slice(1),e=>{let n=e.replace(/^#/,``);(/^[0-9a-fA-F]{6}$/.test(n)||/^[0-9a-fA-F]{3}$/.test(n))&&t(v(`#${n}`))});return(0,h.jsxs)(`span`,{className:`fui-color-field`,children:[(0,h.jsx)(`input`,{ref:i,"aria-label":r?`${r} color`:void 0,type:`color`,className:`fui-swatch`,value:c,onChange:e=>{n?e.nativeEvent.type===`input`&&o(e.target.value):t(e.target.value)}}),(0,h.jsx)(`input`,{ref:l,className:`fui-hex`,"aria-label":r?`${r} hex`:void 0,value:u,onChange:d,onKeyDown:f})]})}function A({value:e,fps:t,onCommit:n,step:r,min:i,max:a}){let o=e=>Math.min(a??1/0,Math.max(i??-1/0,e)),{ref:s,value:c,onChange:l,onKeyDown:u,clearDraft:d}=E(m(e),e=>{let r=p(e,t);r!==null&&n(o(r))});return(0,h.jsx)(`input`,{ref:s,type:`text`,className:`fui-input fui-time-field`,value:c,onChange:l,onKeyDown:i=>{if(u(i),i.key!==`ArrowUp`&&i.key!==`ArrowDown`)return;i.preventDefault();let a=p(s.current.value,t)??e;d(),n(o(a+(i.key===`ArrowUp`?1:-1)*(r??.1)))}})}function j({value:e,onCommit:t,placeholder:n,className:r,label:i}){let{ref:a,value:o,onChange:s,onKeyDown:c}=E(e,t);return(0,h.jsx)(`input`,{ref:a,type:`text`,className:y(`fui-input fui-text-field`,r),"aria-label":i,placeholder:n,value:o,onChange:s,onKeyDown:e=>{c(e),e.key===`Enter`&&e.currentTarget.blur()}})}function M({value:e,onCommit:t,placeholder:n,rows:r,className:i}){let{ref:a,value:o,onChange:s,onKeyDown:c}=E(e,t);return(0,h.jsx)(`textarea`,{ref:a,className:y(`fui-input fui-text-area`,i),placeholder:n,rows:r,value:o,onChange:s,onKeyDown:c})}function N({value:e,options:t,onChange:n,disabled:r,className:i,title:a,label:o}){return(0,h.jsx)(`select`,{className:y(`fui-input fui-select`,i),title:a,"aria-label":o,disabled:r,value:e,onChange:e=>n(e.target.value),children:t.map(e=>(0,h.jsx)(`option`,{value:e.value,disabled:e.disabled,title:e.title,children:e.label},e.value))})}var P=new Set([`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`,`Home`,`End`,`PageUp`,`PageDown`]);function F({value:e,min:t,max:n,step:r,onInput:i,onGestureStart:o,onGestureEnd:c,className:l}){let u=o!==void 0||c!==void 0,d=(0,s.useRef)(!1),f=(e,t,n)=>{if(d.current)return;d.current=!0,o?.();let r=a(e),i=e=>{if(n===void 0||e.key===n){for(let e of t)r.removeEventListener(e,i);d.current=!1,c?.()}};for(let e of t)r.addEventListener(e,i)};return(0,h.jsx)(`input`,{type:`range`,className:y(`fui-slider`,l),min:t,max:n,step:r,value:e,onChange:e=>i(Number(e.target.value)),onPointerDown:u?e=>f(e.currentTarget,[`pointerup`,`pointercancel`]):void 0,onKeyDown:u?e=>{!e.repeat&&P.has(e.key)&&f(e.currentTarget,[`keyup`],e.key)}:void 0})}function I({children:e,onClick:t,disabled:n,className:r,title:i}){return(0,h.jsx)(o,{variant:`outline`,size:`xs`,className:r,title:i,disabled:n,onClick:t,children:e})}function L({children:e,onClick:t,disabled:n,active:r,className:i,title:a}){return(0,h.jsx)(o,{variant:r?`brandSoft`:`ghost`,size:`xxs`,iconOnly:!0,className:i,title:a,"aria-label":a,disabled:n,onClick:t,children:e})}function R({label:e,entries:t,align:n,title:r,buttonClassName:a,ariaLabel:o}){let[c,l]=(0,s.useState)(!1),[u,d]=(0,s.useState)([]),f=(0,s.useRef)(null),[p,m]=(0,s.useState)(null);(0,s.useLayoutEffect)(()=>{m(g(f.current))},[]);let _=(0,s.useCallback)(e=>{e&&d(t()),l(e)},[t]);return(0,h.jsxs)(i.Root,{open:c,onOpenChange:_,children:[(0,h.jsx)(`div`,{ref:f,className:`fui-menu-wrap`,children:(0,h.jsx)(i.Trigger,{className:a,title:r,"aria-label":o,children:e})}),p&&(0,h.jsx)(i.Content,{container:p,align:n===`right`?`end`:`start`,collisionPadding:4,positionerClassName:`fui-menu-positioner`,className:`fui-menu-popup`,"data-theme":`default-dark`,children:u.map((e,t)=>(0,h.jsx)(z,{entry:e},t))})]})}function z({entry:e,onClose:t}){return e.kind===`separator`?(0,h.jsx)(i.Separator,{}):e.kind===`header`?(0,h.jsx)(i.Label,{children:e.label}):(0,h.jsxs)(i.Item,{disabled:e.disabled,onSelect:()=>{e.onSelect(),t?.()},children:[(0,h.jsx)(`span`,{className:`fui-mi-label`,style:e.labelStyle,children:e.label}),(0,h.jsx)(`span`,{className:`fui-mi-shortcut`,children:e.shortcut??e.detail??``}),e.checked&&(0,h.jsx)(`span`,{className:`fui-mi-check`,role:`img`,"aria-label":`Selected`})]})}function B({x:e,y:t,items:n,onClose:r}){let i=(0,s.useRef)(null),[o,l]=(0,s.useState)({x:e,y:t}),[u,d]=(0,s.useState)(null),f=(0,s.useCallback)(e=>{d(g(e))},[]);(0,s.useLayoutEffect)(()=>{let n=i.current;if(!n)return;let r=n.getBoundingClientRect(),o=a(n);l({x:Math.max(4,Math.min(e,o.innerWidth-r.width-4)),y:Math.max(4,Math.min(t,o.innerHeight-r.height-4))})},[e,t,u]),b(i,r,u!==null);let p=(0,h.jsx)(`div`,{ref:i,role:`menu`,className:`fui-menu q-dropdown-content q-dropdown-popup`,"data-theme":`default-dark`,style:{position:`fixed`,left:o.x,top:o.y,zIndex:1e3,maxHeight:`calc(100vh - 8px)`,overflowY:`auto`},children:n.map((e,t)=>(0,h.jsx)(`button`,{type:`button`,role:`menuitem`,className:`q-menu-item`,disabled:e.disabled,onClick:()=>{e.onSelect(),r()},children:(0,h.jsx)(`span`,{className:`fui-mi-label`,children:e.label})},t))});return(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`span`,{ref:f,style:{display:`none`}}),u&&(0,c.createPortal)(p,u)]})}export{b as _,L as a,O as c,N as d,F as f,g,A as h,R as i,S as l,j as m,k as n,w as o,M as p,B as r,C as s,I as t,x as u,m as v};
@@ -1 +0,0 @@
1
- var e=e=>{let t=!1;return{dispose(){t||(t=!0,e())}}},t=class{items=[];disposed=!1;add(e){return this.disposed?e.dispose():this.items.push(e),e}get isDisposed(){return this.disposed}clear(){let e=this.items.toReversed();this.items=[];for(let t of e)t.dispose()}dispose(){this.disposed||=(this.clear(),!0)}};export{e as n,t};
@@ -1 +0,0 @@
1
- import{a as e,n as t,t as n}from"./jsx-runtime-B-hcVAMW.js";import{wr as r}from"./useOpenInteractionType-DbrQ6Ehu.js";import{g as i}from"./components-e3ZbUVns.js";import{n as a}from"./IconEyeOpen-BqTT9_VV.js";var o=e(t(),1),s=e=>{let t=o.useId();return o.createElement(d,{...e,instanceId:t})},c=0,l=typeof o.useId==`function`?void 0:class extends o.Component{state={};componentDidMount(){this.setState({instanceId:`legacy-${++c}`})}render(){return o.createElement(d,{...this.props.iconProps,instanceId:this.state.instanceId})}},u=o.forwardRef((e,t)=>l?o.createElement(l,{iconProps:{...e,svgRef:t}}):o.createElement(s,{...e,svgRef:t}));u.displayName=`CentralIconBase`;var d=({children:e,size:t=24,ariaLabel:n,color:r,ariaHidden:i,"aria-hidden":a,"aria-label":s,role:c,svgRef:l,renderShapes:u,style:d,mode:f=`masked`,maskId:p,instanceId:m,...h})=>{let g=m?`${p}-${m}`:p,_=f!==`raw`&&!!p,v=a??i??!0,y=v===!0||v===`true`,b=s??n,x=u?u(g??m??`icon`):e;return o.createElement(`svg`,{...h,ref:l,"aria-hidden":v,"aria-label":s,role:c??(y?void 0:`img`),width:typeof t==`number`?`${t}px`:t,height:typeof t==`number`?`${t}px`:t,viewBox:`0 0 24 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,style:{color:r,...d}},b&&!y&&o.createElement(`title`,null,b),_?o.createElement(o.Fragment,null,o.createElement(`mask`,{id:g,maskUnits:`userSpaceOnUse`,x:`0`,y:`0`,width:`24`,height:`24`},o.createElement(`rect`,{width:`24`,height:`24`,fill:`#000`}),o.createElement(`g`,{fill:`none`,style:{color:`#fff`}},x)),o.createElement(`rect`,{width:`24`,height:`24`,fill:`currentColor`,mask:`url(#${g})`})):x)},f=o.memo(o.forwardRef((e,t)=>o.createElement(u,{...e,ref:t,ariaLabel:`form-rectangle`,maskId:`round-outlined-radius-2-stroke-1.5-IconFormRectangle`},o.createElement(`path`,{d:`M19.25 4.75H4.75C3.64543 4.75 2.75 5.64543 2.75 6.75V17.25C2.75 18.3546 3.64543 19.25 4.75 19.25H19.25C20.3546 19.25 21.25 18.3546 21.25 17.25V6.75C21.25 5.64543 20.3546 4.75 19.25 4.75Z`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinejoin:`round`})))),p=e=>{let t=o.useId();return o.createElement(_,{...e,instanceId:t})},m=0,h=typeof o.useId==`function`?void 0:class extends o.Component{state={};componentDidMount(){this.setState({instanceId:`legacy-${++m}`})}render(){return o.createElement(_,{...this.props.iconProps,instanceId:this.state.instanceId})}},g=o.forwardRef((e,t)=>h?o.createElement(h,{iconProps:{...e,svgRef:t}}):o.createElement(p,{...e,svgRef:t}));g.displayName=`CentralIconBase`;var _=({children:e,size:t=24,ariaLabel:n,color:r,ariaHidden:i,"aria-hidden":a,"aria-label":s,role:c,svgRef:l,renderShapes:u,style:d,mode:f=`masked`,maskId:p,instanceId:m,...h})=>{let g=m?`${p}-${m}`:p,_=f!==`raw`&&!!p,v=a??i??!0,y=v===!0||v===`true`,b=s??n,x=u?u(g??m??`icon`):e;return o.createElement(`svg`,{...h,ref:l,"aria-hidden":v,"aria-label":s,role:c??(y?void 0:`img`),width:typeof t==`number`?`${t}px`:t,height:typeof t==`number`?`${t}px`:t,viewBox:`0 0 24 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,style:{color:r,...d}},b&&!y&&o.createElement(`title`,null,b),_?o.createElement(o.Fragment,null,o.createElement(`mask`,{id:g,maskUnits:`userSpaceOnUse`,x:`0`,y:`0`,width:`24`,height:`24`},o.createElement(`rect`,{width:`24`,height:`24`,fill:`#000`}),o.createElement(`g`,{fill:`none`,style:{color:`#fff`}},x)),o.createElement(`rect`,{width:`24`,height:`24`,fill:`currentColor`,mask:`url(#${g})`})):x)},v=o.memo(o.forwardRef((e,t)=>o.createElement(g,{...e,ref:t,ariaLabel:`pause`,maskId:`round-outlined-radius-2-stroke-1.5-IconPause`},o.createElement(`path`,{d:`M4.75 5.75C4.75 4.64543 5.64543 3.75 6.75 3.75H7.25C8.35457 3.75 9.25 4.64543 9.25 5.75V18.25C9.25 19.3546 8.35457 20.25 7.25 20.25H6.75C5.64543 20.25 4.75 19.3546 4.75 18.25V5.75Z`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinejoin:`round`}),o.createElement(`path`,{d:`M14.75 5.75C14.75 4.64543 15.6454 3.75 16.75 3.75H17.25C18.3546 3.75 19.25 4.64543 19.25 5.75V18.25C19.25 19.3546 18.3546 20.25 17.25 20.25H16.75C15.6454 20.25 14.75 19.3546 14.75 18.25V5.75Z`,stroke:`currentColor`,strokeWidth:`1.5`,strokeLinejoin:`round`})))),y=e(r(),1),b=n();function x({x:e,y:t,clipId:n,onClose:r}){let s=(0,o.useRef)(null),c=(0,o.useRef)(null),l=(0,o.useRef)(r);l.current=r;let[u,d]=(0,o.useState)(null),[f,p]=(0,o.useState)({left:e,top:t});(0,o.useLayoutEffect)(()=>{d(i(s.current))},[]),(0,o.useLayoutEffect)(()=>{let n=c.current;if(!n)return;let r=n.ownerDocument.defaultView??window,i=()=>{let i=n.getBoundingClientRect();p({left:Math.max(8,Math.min(e,r.innerWidth-i.width-8)),top:Math.max(8,Math.min(t,r.innerHeight-i.height-8))})};i();let a=new r.ResizeObserver(i);return a.observe(n),r.addEventListener(`resize`,i),n.focus(),()=>{a.disconnect(),r.removeEventListener(`resize`,i)}},[u,e,t,n]),(0,o.useEffect)(()=>{let e=c.current;if(!e)return;let t=e.ownerDocument.defaultView??window,n=n=>{n.target instanceof t.Node&&!e.contains(n.target)&&(e.querySelector(`:focus`)?.blur(),l.current())};return t.addEventListener(`pointerdown`,n,!0),()=>t.removeEventListener(`pointerdown`,n,!0)},[u]);let m={position:`fixed`,...f,zIndex:1e3};return(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(`span`,{ref:s,hidden:!0}),u&&(0,y.createPortal)((0,b.jsxs)(`div`,{ref:c,role:`dialog`,"aria-label":`Edit component props`,tabIndex:-1,className:`fui-component-popover`,style:m,onContextMenu:e=>e.preventDefault(),onKeyDown:e=>{e.key===`Escape`&&(e.stopPropagation(),r())},children:[(0,b.jsxs)(`div`,{className:`fui-component-popover-head`,children:[(0,b.jsx)(`span`,{className:`fui-component-popover-title`,children:`Edit component props`}),(0,b.jsx)(`button`,{type:`button`,className:`fui-component-close`,"aria-label":`Close component props`,onClick:r,children:`×`})]}),(0,b.jsx)(a,{clipId:n})]}),u)]})}var S=`application/x-fable-generation`;function C(e){try{let t=JSON.parse(e);return typeof t.jobId!=`string`||t.jobId.length===0||t.kind!==`image`&&t.kind!==`video`?null:{jobId:t.jobId,kind:t.kind}}catch{return null}}export{f as a,v as i,C as n,x as r,S as t};