@ignix-social/editor 0.1.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/LICENSE +190 -0
- package/NOTICE +54 -0
- package/README.md +23 -0
- package/bin/ignix-editor.mjs +8 -0
- package/package.json +53 -0
- package/patches/index.mjs +53 -0
- package/scripts/build-ffmpeg-macos.sh +35 -0
- package/scripts/build-whisper-macos.sh +21 -0
- package/scripts/vendor.mjs +41 -0
- package/skills/ignix-editor/SKILL.md +132 -0
- package/src/audio.mjs +31 -0
- package/src/binaries.json +46 -0
- package/src/binaries.mjs +83 -0
- package/src/cli.mjs +254 -0
- package/src/prepare.mjs +74 -0
- package/src/runtime/ignix-frame.js +92 -0
- package/src/transcribe.mjs +71 -0
- package/src/validate.mjs +71 -0
- package/templates/blank/index.html +41 -0
- package/vendor/hyperframes/README.md +181 -0
- package/vendor/hyperframes/UPSTREAM.json +12 -0
- package/vendor/hyperframes/bin/hyperframes-localize-fonts.mjs +12 -0
- package/vendor/hyperframes/bin/hyperframes.mjs +11 -0
- package/vendor/hyperframes/dist/add-LR3ZR2A5.js +79 -0
- package/vendor/hyperframes/dist/agentPromptGenerator-VIIPZCJ3.js +143 -0
- package/vendor/hyperframes/dist/animatedGifPrep-P2T6YM7Z.js +34 -0
- package/vendor/hyperframes/dist/asset-BE2DOV72.js +26 -0
- package/vendor/hyperframes/dist/assetCataloger-VBLPHX24.js +340 -0
- package/vendor/hyperframes/dist/auth-RCQB2ZT7.js +60 -0
- package/vendor/hyperframes/dist/autoUpdate-RJAX3DAZ.js +268 -0
- package/vendor/hyperframes/dist/backgroundChecks-H2LCUIMJ.js +61 -0
- package/vendor/hyperframes/dist/backgroundChecksWorker.js +26 -0
- package/vendor/hyperframes/dist/batchRender-FT7AP7XH.js +355 -0
- package/vendor/hyperframes/dist/beat-analyzer.global.js +338 -0
- package/vendor/hyperframes/dist/beats-Y2EOP72P.js +309 -0
- package/vendor/hyperframes/dist/benchmark-MZ7GY3JW.js +231 -0
- package/vendor/hyperframes/dist/browser-HUTAMRQE.js +237 -0
- package/vendor/hyperframes/dist/bundleWithLocalizedFonts-5QOPOB5D.js +52 -0
- package/vendor/hyperframes/dist/capture-RLZA6EMR.js +4079 -0
- package/vendor/hyperframes/dist/capture-SZZ4IYJK.js +290 -0
- package/vendor/hyperframes/dist/captureFile-LYOJOUIE.js +15 -0
- package/vendor/hyperframes/dist/captureTimeout-PA4FYWT5.js +27 -0
- package/vendor/hyperframes/dist/catalog-KYU55EWR.js +1001 -0
- package/vendor/hyperframes/dist/check-TCG4PXLR.js +1697 -0
- package/vendor/hyperframes/dist/checkBrowser-RPMO4OW5.js +1032 -0
- package/vendor/hyperframes/dist/chunk-2EAXUCCE.js +88 -0
- package/vendor/hyperframes/dist/chunk-2EGFTPWD.js +1077 -0
- package/vendor/hyperframes/dist/chunk-2PSPARWP.js +6058 -0
- package/vendor/hyperframes/dist/chunk-2YN64IN5.js +5747 -0
- package/vendor/hyperframes/dist/chunk-3GXQPCJC.js +682 -0
- package/vendor/hyperframes/dist/chunk-3ZP5DXE7.js +15 -0
- package/vendor/hyperframes/dist/chunk-4NWOGZZS.js +1990 -0
- package/vendor/hyperframes/dist/chunk-4PFZPP2N.js +587 -0
- package/vendor/hyperframes/dist/chunk-4THIAPBL.js +128 -0
- package/vendor/hyperframes/dist/chunk-4YYJOFKS.js +28 -0
- package/vendor/hyperframes/dist/chunk-54HJ63Q2.js +29 -0
- package/vendor/hyperframes/dist/chunk-5ETJX6WM.js +89 -0
- package/vendor/hyperframes/dist/chunk-5IAKAQA7.js +389 -0
- package/vendor/hyperframes/dist/chunk-5Z63TBTX.js +37 -0
- package/vendor/hyperframes/dist/chunk-6BEFEWFB.js +25 -0
- package/vendor/hyperframes/dist/chunk-6CSYCFQV.js +68 -0
- package/vendor/hyperframes/dist/chunk-6CTIGJY7.js +154 -0
- package/vendor/hyperframes/dist/chunk-7HG4BFIN.js +93 -0
- package/vendor/hyperframes/dist/chunk-7JZ4FXP2.js +118 -0
- package/vendor/hyperframes/dist/chunk-A2Z4Z4VL.js +2961 -0
- package/vendor/hyperframes/dist/chunk-AMKC3AXA.js +25 -0
- package/vendor/hyperframes/dist/chunk-AVUUN2XD.js +4847 -0
- package/vendor/hyperframes/dist/chunk-AWDFDFI3.js +46 -0
- package/vendor/hyperframes/dist/chunk-AWNBM3MZ.js +94 -0
- package/vendor/hyperframes/dist/chunk-BXCMXMJQ.js +73 -0
- package/vendor/hyperframes/dist/chunk-BZ56MTDX.js +6 -0
- package/vendor/hyperframes/dist/chunk-CFKU7HTK.js +171 -0
- package/vendor/hyperframes/dist/chunk-CWPVM2QV.js +308 -0
- package/vendor/hyperframes/dist/chunk-DPVXBVLL.js +31292 -0
- package/vendor/hyperframes/dist/chunk-DQBY7FRR.js +397 -0
- package/vendor/hyperframes/dist/chunk-E6RPWJVC.js +213 -0
- package/vendor/hyperframes/dist/chunk-EISRN4E6.js +294 -0
- package/vendor/hyperframes/dist/chunk-EOVYQ3IG.js +143 -0
- package/vendor/hyperframes/dist/chunk-F3WZGU7C.js +479 -0
- package/vendor/hyperframes/dist/chunk-FCSIGXXP.js +366 -0
- package/vendor/hyperframes/dist/chunk-FI4I7CME.js +56 -0
- package/vendor/hyperframes/dist/chunk-FLWXXDNS.js +15 -0
- package/vendor/hyperframes/dist/chunk-GK4AIFIH.js +11171 -0
- package/vendor/hyperframes/dist/chunk-GMECXFAN.js +57 -0
- package/vendor/hyperframes/dist/chunk-GULOKZLI.js +155 -0
- package/vendor/hyperframes/dist/chunk-H4YZZ2VQ.js +68 -0
- package/vendor/hyperframes/dist/chunk-H6QMKUYA.js +477 -0
- package/vendor/hyperframes/dist/chunk-HBBJFK6I.js +273 -0
- package/vendor/hyperframes/dist/chunk-HRUGC23L.js +212 -0
- package/vendor/hyperframes/dist/chunk-HVW7ABXD.js +19 -0
- package/vendor/hyperframes/dist/chunk-HW6OYASV.js +344 -0
- package/vendor/hyperframes/dist/chunk-HWKCIWQT.js +3578 -0
- package/vendor/hyperframes/dist/chunk-I465DBM6.js +1214 -0
- package/vendor/hyperframes/dist/chunk-IGLEPPTN.js +24 -0
- package/vendor/hyperframes/dist/chunk-IGNAAHS3.js +433 -0
- package/vendor/hyperframes/dist/chunk-IHFUKJOR.js +85 -0
- package/vendor/hyperframes/dist/chunk-IQ3OUQ5Z.js +213 -0
- package/vendor/hyperframes/dist/chunk-ISN5GRYI.js +20 -0
- package/vendor/hyperframes/dist/chunk-IUZFXWSV.js +446 -0
- package/vendor/hyperframes/dist/chunk-JH556Q42.js +647 -0
- package/vendor/hyperframes/dist/chunk-JTHMTOMQ.js +601 -0
- package/vendor/hyperframes/dist/chunk-K2EQN4VU.js +405 -0
- package/vendor/hyperframes/dist/chunk-K2FTXJYH.js +16044 -0
- package/vendor/hyperframes/dist/chunk-K4WIOZFP.js +32 -0
- package/vendor/hyperframes/dist/chunk-K4WKGXRC.js +18 -0
- package/vendor/hyperframes/dist/chunk-KBJUXVOJ.js +172 -0
- package/vendor/hyperframes/dist/chunk-KC5XXX3X.js +590 -0
- package/vendor/hyperframes/dist/chunk-KNU5COPB.js +29 -0
- package/vendor/hyperframes/dist/chunk-KZI44OPA.js +185 -0
- package/vendor/hyperframes/dist/chunk-L3YOGIPG.js +48 -0
- package/vendor/hyperframes/dist/chunk-LAOCA3MQ.js +189 -0
- package/vendor/hyperframes/dist/chunk-LCSMOLGX.js +312 -0
- package/vendor/hyperframes/dist/chunk-LFGJWOVA.js +61 -0
- package/vendor/hyperframes/dist/chunk-LHSR3M4M.js +498 -0
- package/vendor/hyperframes/dist/chunk-LYNI3FOL.js +123 -0
- package/vendor/hyperframes/dist/chunk-M2WBOQ2Q.js +54 -0
- package/vendor/hyperframes/dist/chunk-MRF4AMKD.js +104 -0
- package/vendor/hyperframes/dist/chunk-MWB3ZIFM.js +852 -0
- package/vendor/hyperframes/dist/chunk-NGKM64BP.js +39 -0
- package/vendor/hyperframes/dist/chunk-NXMYHJAL.js +43 -0
- package/vendor/hyperframes/dist/chunk-OAF4XJOW.js +192 -0
- package/vendor/hyperframes/dist/chunk-OFQWTKPW.js +117 -0
- package/vendor/hyperframes/dist/chunk-P6LJ4Y32.js +4662 -0
- package/vendor/hyperframes/dist/chunk-PBN6GBJE.js +108 -0
- package/vendor/hyperframes/dist/chunk-PDAMK4Q5.js +28 -0
- package/vendor/hyperframes/dist/chunk-PFCFR3KZ.js +20 -0
- package/vendor/hyperframes/dist/chunk-PJ3HDUCY.js +108 -0
- package/vendor/hyperframes/dist/chunk-PMRBLBUP.js +152 -0
- package/vendor/hyperframes/dist/chunk-PPQUYWTW.js +240 -0
- package/vendor/hyperframes/dist/chunk-Q5X2B5WT.js +29 -0
- package/vendor/hyperframes/dist/chunk-Q7IU7MOR.js +351 -0
- package/vendor/hyperframes/dist/chunk-QC4FJVLM.js +371 -0
- package/vendor/hyperframes/dist/chunk-QNYYOUU3.js +1318 -0
- package/vendor/hyperframes/dist/chunk-RDNNAKEP.js +161 -0
- package/vendor/hyperframes/dist/chunk-RMHUQGRK.js +657 -0
- package/vendor/hyperframes/dist/chunk-RQVDTPGD.js +6 -0
- package/vendor/hyperframes/dist/chunk-RVCWIIZ7.js +68 -0
- package/vendor/hyperframes/dist/chunk-S3D6GE5W.js +72 -0
- package/vendor/hyperframes/dist/chunk-S3S4TGEH.js +424 -0
- package/vendor/hyperframes/dist/chunk-S7NPLFWV.js +11395 -0
- package/vendor/hyperframes/dist/chunk-SHB5VDMH.js +51 -0
- package/vendor/hyperframes/dist/chunk-TCLGPL65.js +860 -0
- package/vendor/hyperframes/dist/chunk-THXFSPLV.js +40 -0
- package/vendor/hyperframes/dist/chunk-TJSTGSAW.js +354 -0
- package/vendor/hyperframes/dist/chunk-TQFG7HTI.js +1024 -0
- package/vendor/hyperframes/dist/chunk-TVCRUG2S.js +265 -0
- package/vendor/hyperframes/dist/chunk-TWWSYAKJ.js +24 -0
- package/vendor/hyperframes/dist/chunk-U7CZBDMV.js +27 -0
- package/vendor/hyperframes/dist/chunk-UEZXMWG3.js +139 -0
- package/vendor/hyperframes/dist/chunk-UYEZTK4U.js +61 -0
- package/vendor/hyperframes/dist/chunk-VC76R6W2.js +27 -0
- package/vendor/hyperframes/dist/chunk-VFCKXTBB.js +159 -0
- package/vendor/hyperframes/dist/chunk-VWG7OQKU.js +22 -0
- package/vendor/hyperframes/dist/chunk-VXVRPIJA.js +105 -0
- package/vendor/hyperframes/dist/chunk-WBLXWOYK.js +15 -0
- package/vendor/hyperframes/dist/chunk-WERLJGIC.js +20 -0
- package/vendor/hyperframes/dist/chunk-WMQNIQDJ.js +2057 -0
- package/vendor/hyperframes/dist/chunk-WPHMNO44.js +4528 -0
- package/vendor/hyperframes/dist/chunk-X5HWXQPU.js +113 -0
- package/vendor/hyperframes/dist/chunk-X7MTZ4T2.js +6 -0
- package/vendor/hyperframes/dist/chunk-XH4DSOS5.js +59 -0
- package/vendor/hyperframes/dist/chunk-XS4EJSKU.js +23 -0
- package/vendor/hyperframes/dist/chunk-XT5P4QMO.js +181 -0
- package/vendor/hyperframes/dist/chunk-XT7X6QCP.js +6 -0
- package/vendor/hyperframes/dist/chunk-XUHOIDKG.js +6 -0
- package/vendor/hyperframes/dist/chunk-XUXGIA7H.js +485 -0
- package/vendor/hyperframes/dist/chunk-XZABUQTX.js +113 -0
- package/vendor/hyperframes/dist/chunk-Y6W4DVPS.js +356 -0
- package/vendor/hyperframes/dist/chunk-YEIFI443.js +44 -0
- package/vendor/hyperframes/dist/chunk-YQZNILVH.js +375 -0
- package/vendor/hyperframes/dist/chunk-Z27A7NUB.js +65 -0
- package/vendor/hyperframes/dist/chunk-Z6B37SNM.js +3081 -0
- package/vendor/hyperframes/dist/chunk-ZJUKFZ2P.js +10954 -0
- package/vendor/hyperframes/dist/chunk-ZKDMAOFU.js +32 -0
- package/vendor/hyperframes/dist/chunk-ZMXUQLI2.js +17219 -0
- package/vendor/hyperframes/dist/chunk-ZTZ7NCJT.js +58 -0
- package/vendor/hyperframes/dist/chunk-ZTZA4UWZ.js +108 -0
- package/vendor/hyperframes/dist/clean-W57E5YQ3.js +293 -0
- package/vendor/hyperframes/dist/cli.js +495 -0
- package/vendor/hyperframes/dist/cloud-FFTJGZ24.js +70 -0
- package/vendor/hyperframes/dist/cloudrun-AJUTHUEA.js +763 -0
- package/vendor/hyperframes/dist/colors-HKWSZCGK.js +15 -0
- package/vendor/hyperframes/dist/commands/contrast-audit.browser.js +459 -0
- package/vendor/hyperframes/dist/commands/layout-audit.browser.js +2102 -0
- package/vendor/hyperframes/dist/commands/motion-sample.browser.js +74 -0
- package/vendor/hyperframes/dist/commands/motion-signature.browser.js +374 -0
- package/vendor/hyperframes/dist/compare-AYCTT55F.js +421 -0
- package/vendor/hyperframes/dist/compiler-QO36EXLS.js +121 -0
- package/vendor/hyperframes/dist/component-VFFR2O7T.js +176 -0
- package/vendor/hyperframes/dist/compositions-QTVN3U2A.js +228 -0
- package/vendor/hyperframes/dist/contactSheet-27SRU7A4.js +22 -0
- package/vendor/hyperframes/dist/delete-ZAKYCB7I.js +114 -0
- package/vendor/hyperframes/dist/deploy-MX76RZ36.js +101 -0
- package/vendor/hyperframes/dist/destroy-H2TZBYHH.js +42 -0
- package/vendor/hyperframes/dist/deterministicFonts-HAEMV4TM.js +50 -0
- package/vendor/hyperframes/dist/dist-EWXJGN63.js +129 -0
- package/vendor/hyperframes/dist/dist-FNNGCKFS.js +29 -0
- package/vendor/hyperframes/dist/dist-S3PJNPXQ.js +392 -0
- package/vendor/hyperframes/dist/docker/Dockerfile.render +65 -0
- package/vendor/hyperframes/dist/docs/compositions.md +67 -0
- package/vendor/hyperframes/dist/docs/data-attributes.md +27 -0
- package/vendor/hyperframes/dist/docs/examples.md +19 -0
- package/vendor/hyperframes/dist/docs/gsap.md +26 -0
- package/vendor/hyperframes/dist/docs/rendering.md +35 -0
- package/vendor/hyperframes/dist/docs/troubleshooting.md +29 -0
- package/vendor/hyperframes/dist/docs-QAPJEGLS.js +131 -0
- package/vendor/hyperframes/dist/doctor-AI7C3FON.js +67 -0
- package/vendor/hyperframes/dist/dom-IROKGVJI.js +14 -0
- package/vendor/hyperframes/dist/dotEnv-AECLXQSO.js +14 -0
- package/vendor/hyperframes/dist/events-7LALYNKZ.js +92 -0
- package/vendor/hyperframes/dist/events-FQY3HGKZ.js +88 -0
- package/vendor/hyperframes/dist/feedback-WCMDMSTK.js +472 -0
- package/vendor/hyperframes/dist/ffmpeg-QIUFEFTY.js +35 -0
- package/vendor/hyperframes/dist/figma-64WY462P.js +63 -0
- package/vendor/hyperframes/dist/fontData.generated-NXAOI4GH.js +13 -0
- package/vendor/hyperframes/dist/fontLocalizeCli.js +132 -0
- package/vendor/hyperframes/dist/get-FPOMJMZB.js +103 -0
- package/vendor/hyperframes/dist/gpuPolicy-2ZUZE5D6.js +38 -0
- package/vendor/hyperframes/dist/grade-compare-E2CKPST4.js +647 -0
- package/vendor/hyperframes/dist/gsapParser-DIYYX6JT.js +2846 -0
- package/vendor/hyperframes/dist/gsapParserAcorn-E3GEIRZB.js +28 -0
- package/vendor/hyperframes/dist/help-YRQIDDML.js +197 -0
- package/vendor/hyperframes/dist/history-PP5NDRV3.js +571 -0
- package/vendor/hyperframes/dist/hyperframe-runtime.js +1081 -0
- package/vendor/hyperframes/dist/hyperframe.manifest.json +22 -0
- package/vendor/hyperframes/dist/hyperframe.runtime.iife.js +1081 -0
- package/vendor/hyperframes/dist/hyperframes-player.global.js +474 -0
- package/vendor/hyperframes/dist/hyperframes-slideshow.global.js +149 -0
- package/vendor/hyperframes/dist/info-SEX3B7JL.js +153 -0
- package/vendor/hyperframes/dist/init-U3AKHO5B.js +1147 -0
- package/vendor/hyperframes/dist/inspect-Q3K6EDEK.js +97 -0
- package/vendor/hyperframes/dist/installer-K6O5WF44.js +37 -0
- package/vendor/hyperframes/dist/keyframes-DC64JCI3.js +2602 -0
- package/vendor/hyperframes/dist/lambda-D7UMN4DJ.js +451 -0
- package/vendor/hyperframes/dist/layout-XSPPDHOO.js +86 -0
- package/vendor/hyperframes/dist/lib-TPG2ZMAX.js +128 -0
- package/vendor/hyperframes/dist/lint-7DQZE7L3.js +164 -0
- package/vendor/hyperframes/dist/lintProject-OHBBM3DJ.js +27 -0
- package/vendor/hyperframes/dist/list-4K5MVDQX.js +162 -0
- package/vendor/hyperframes/dist/login-NTX4OWXL.js +377 -0
- package/vendor/hyperframes/dist/logout-Q654A3SI.js +100 -0
- package/vendor/hyperframes/dist/manager-67P2XFXQ.js +34 -0
- package/vendor/hyperframes/dist/manager-CT3D67CG.js +38 -0
- package/vendor/hyperframes/dist/manager-GFN75DM4.js +30 -0
- package/vendor/hyperframes/dist/media-treatment-5FYAOPNL.js +972 -0
- package/vendor/hyperframes/dist/media-use-4XXGABIL.js +113 -0
- package/vendor/hyperframes/dist/models-C4E4IWJD.js +137 -0
- package/vendor/hyperframes/dist/motionShot-S4MIGMT5.js +614 -0
- package/vendor/hyperframes/dist/normalize-O76AC4HE.js +333 -0
- package/vendor/hyperframes/dist/normalize-audio-CSFTXLXD.js +276 -0
- package/vendor/hyperframes/dist/open-2ZD6BHZG.js +115 -0
- package/vendor/hyperframes/dist/pipeline-TNGWUZQC.js +54 -0
- package/vendor/hyperframes/dist/play-CTMUXX6E.js +349 -0
- package/vendor/hyperframes/dist/policies-FSDZVS2E.js +292 -0
- package/vendor/hyperframes/dist/preflight-SMNV6RW2.js +45 -0
- package/vendor/hyperframes/dist/present-WQVHV5CR.js +350 -0
- package/vendor/hyperframes/dist/preview-JOJXTH75.js +1820 -0
- package/vendor/hyperframes/dist/producer-ECLEN5RP.js +13 -0
- package/vendor/hyperframes/dist/progress-FBIEEB7Y.js +73 -0
- package/vendor/hyperframes/dist/projectConfig-HYJMJ5BY.js +56 -0
- package/vendor/hyperframes/dist/publication-HQ5Y3KBM.js +29 -0
- package/vendor/hyperframes/dist/publish-VHDYQASC.js +430 -0
- package/vendor/hyperframes/dist/refresh-K24ETHMA.js +53 -0
- package/vendor/hyperframes/dist/remove-background-W2YX2NVH.js +253 -0
- package/vendor/hyperframes/dist/render-AO5VX3YI.js +177 -0
- package/vendor/hyperframes/dist/render-LNO62LEL.js +2367 -0
- package/vendor/hyperframes/dist/render-TTQI7TGN.js +796 -0
- package/vendor/hyperframes/dist/render-batch-YH7CTWNY.js +284 -0
- package/vendor/hyperframes/dist/renderCancellation-JPIHE47X.js +35 -0
- package/vendor/hyperframes/dist/renderSetupWorker.js +79 -0
- package/vendor/hyperframes/dist/resolver-IZ647GBZ.js +38 -0
- package/vendor/hyperframes/dist/runtimeVersion.js +18 -0
- package/vendor/hyperframes/dist/screenshotCapture-ECBTLCU6.js +179 -0
- package/vendor/hyperframes/dist/shaderTransitionWorker.js +44 -0
- package/vendor/hyperframes/dist/sherpa-KKLNW6U2.js +314 -0
- package/vendor/hyperframes/dist/sherpaWorker.js +77 -0
- package/vendor/hyperframes/dist/sites-TNVKZS73.js +52 -0
- package/vendor/hyperframes/dist/skill-ZHVLH7KX.js +15 -0
- package/vendor/hyperframes/dist/skills/hyperframes/SKILL.md +152 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/brief-contract.md +108 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/brief-format.md +72 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/capability-menu.md +47 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/frame-worker-core.md +80 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/intent-interview.md +73 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/pitch-round.md +40 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/plugin-installation.md +43 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/production-loop.md +26 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/review-loop.md +37 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/route-briefs.md +11 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/embedded-captions.md +11 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/faceless-explainer.md +12 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/general-video.md +12 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/motion-graphics.md +11 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/music-to-video.md +12 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/pr-to-video.md +28 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/product-launch-video.md +13 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/remotion-to-hyperframes.md +9 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/slideshow.md +11 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/routes/talking-head-recut.md +11 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/script-format.md +52 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/skill-lifecycle.md +35 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/storyboard-format.md +99 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/subagent-dispatch.md +35 -0
- package/vendor/hyperframes/dist/skills/hyperframes/references/workflow-catalog.md +10 -0
- package/vendor/hyperframes/dist/skills/hyperframes/scripts/lib/frame-packets-core.mjs +194 -0
- package/vendor/hyperframes/dist/skills/hyperframes/scripts/plugin-cli.mjs +88 -0
- package/vendor/hyperframes/dist/skills/hyperframes/scripts/plugin-cli.test.mjs +117 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/SKILL.md +189 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/beats.md +19 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/cloud.md +163 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/cloudrun.md +62 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/compare-and-batch.md +105 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/doctor-browser.md +57 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/init-and-scaffold.md +74 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/lambda.md +185 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/lint-validate-inspect.md +132 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/preview-render.md +193 -0
- package/vendor/hyperframes/dist/skills/hyperframes-cli/references/upgrade-info-misc.md +134 -0
- package/vendor/hyperframes/dist/skills/media-use/SKILL.md +100 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/CREDITS.md +35 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/chime.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/click-soft.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/click.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/error.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/glitch-1.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/glitch-2.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/glitch-3.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/impact-bass-1.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/impact-bass-2.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/key-press.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/manifest.json +97 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/notification.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/ping.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/pop.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/riser.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/sparkle.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/typing.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/whoosh-cinematic.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/whoosh-short.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/whoosh.mp3 +0 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/bgm.md +76 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/captions/authoring.md +163 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/captions/motion.md +87 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/captions/transcript-handling.md +97 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/remove-background.md +143 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/requirements.md +29 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/sfx.md +42 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/transcribe.md +52 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/tts-to-captions.md +35 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/references/tts.md +260 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/audio.mjs +311 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/audio.test.mjs +159 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/gemini-pipeline.test.mjs +131 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-tts.mjs +122 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-tts.test.mjs +38 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-voice.mjs +98 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-voice.test.mjs +233 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/audio-meta.mjs +39 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/audio-meta.test.mjs +136 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/bgm-volume.mjs +4 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/bgm.mjs +257 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/bgm.test.mjs +74 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/concurrency.mjs +14 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/concurrency.test.mjs +41 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth.mjs +43 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth.py +52 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth.test.mjs +86 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth_test.py +90 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-tts.mjs +122 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-tts.test.mjs +243 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/heygen.mjs +197 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/heygen.test.mjs +185 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/media-record.mjs +114 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/media-record.test.mjs +205 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/python.mjs +77 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/python.test.mjs +136 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/sfx.mjs +165 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/sfx.test.mjs +121 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/tts.mjs +389 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/tts.spawn.test.mjs +158 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/tts.test.mjs +230 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lyria-recipe.py +136 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/wait-bgm.mjs +175 -0
- package/vendor/hyperframes/dist/skills/media-use/audio/scripts/wait-bgm.test.mjs +108 -0
- package/vendor/hyperframes/dist/skills/media-use/luts/README.md +28 -0
- package/vendor/hyperframes/dist/skills/media-use/luts/index.json +57 -0
- package/vendor/hyperframes/dist/skills/media-use/references/audio.md +20 -0
- package/vendor/hyperframes/dist/skills/media-use/references/grading.md +160 -0
- package/vendor/hyperframes/dist/skills/media-use/references/media-treatment-recipes.md +929 -0
- package/vendor/hyperframes/dist/skills/media-use/references/media-treatments.md +202 -0
- package/vendor/hyperframes/dist/skills/media-use/references/memory.md +37 -0
- package/vendor/hyperframes/dist/skills/media-use/references/meta.md +61 -0
- package/vendor/hyperframes/dist/skills/media-use/references/operations.md +327 -0
- package/vendor/hyperframes/dist/skills/media-use/references/resolve.md +150 -0
- package/vendor/hyperframes/dist/skills/media-use/references/setup-providers.md +80 -0
- package/vendor/hyperframes/dist/skills/media-use/references/telemetry-dashboard.md +49 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/audio-duck.mjs +113 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/compatibility.test.mjs +96 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/dither.mjs +328 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/dither.test.mjs +176 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/eval.mjs +369 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/adopt.mjs +128 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/adopt.test.mjs +95 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/bgm-provider.mjs +20 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/brand-provider.mjs +59 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/bundled-sfx-provider.mjs +119 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/bundled-sfx-provider.test.mjs +139 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cache.mjs +148 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/candidates.mjs +91 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/candidates.test.mjs +155 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/codex-provider.mjs +161 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/codex-provider.test.mjs +34 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/config-lock.d.mts +3 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/config-lock.mjs +45 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/config-lock.test.mjs +79 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/coverage.test.mjs +136 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-build.mjs +181 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-build.test.mjs +80 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-validate.mjs +198 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-validate.test.mjs +125 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cutlist.mjs +184 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cutlist.test.mjs +162 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/duck.mjs +95 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/duck.test.mjs +153 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/error-diffusion.mjs +230 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/error-diffusion.test.mjs +102 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/ff-binaries.mjs +37 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/freeze.mjs +72 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/freeze.test.mjs +138 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/grade-analyzer.mjs +265 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/grade-analyzer.test.mjs +285 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-cli.mjs +191 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-cli.test.mjs +301 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-search.mjs +45 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-search.test.mjs +49 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-video-provider.mjs +138 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-video-provider.test.mjs +435 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/image-provider.mjs +44 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/index-gen.mjs +63 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-media-search.mjs +32 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-models.mjs +318 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-models.test.mjs +220 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-run.mjs +78 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-run.test.mjs +121 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/logo-provider.mjs +244 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/logo-provider.test.mjs +298 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/ltx-video-provider.mjs +94 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/ltx-video-provider.test.mjs +316 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/lut-preset-provider.mjs +271 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/lut-preset-provider.test.mjs +199 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/manifest.d.mts +19 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/manifest.mjs +279 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/manifest.test.mjs +397 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/match.mjs +47 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-fetch.mjs +85 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-fetch.test.mjs +197 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-home.mjs +20 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-home.test.mjs +61 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-search.d.mts +9 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-search.mjs +107 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/mflux-provider.mjs +128 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/mflux-provider.test.mjs +174 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/misses.mjs +49 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/misses.test.mjs +89 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/npx-sync.mjs +31 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/npx-sync.test.mjs +50 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/parakeet-words.mjs +27 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/parakeet-words.test.mjs +44 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/prefs-store.mjs +180 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/prefs-store.test.mjs +189 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/probe.mjs +41 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/probe.test.mjs +148 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/providers.mjs +5 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/recipe-store.mjs +367 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/recipe-store.test.mjs +367 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/registry.mjs +212 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/registry.test.mjs +262 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/search.mjs +24 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/search.test.mjs +32 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/sfx-provider.mjs +23 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/specs.mjs +132 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/specs.test.mjs +157 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/stats.mjs +117 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/stats.test.mjs +165 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/svg-sanitize.mjs +21 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/telemetry.mjs +210 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/telemetry.test.mjs +437 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/test-home.test.mjs +10 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/transcriptCutFade.mjs +21 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/transcriptCutFade.test.mjs +33 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/tts-local-provider.mjs +94 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/tts-local-provider.test.mjs +72 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/usage.mjs +57 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/usage.test.mjs +54 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/voice-provider.mjs +57 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/voice-provider.test.mjs +46 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/lib/words.mjs +18 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/prefs.mjs +70 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/recipe.mjs +103 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/resolve-plugin.test.mjs +62 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/resolve.mjs +1369 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/transcribe.mjs +194 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/transcribe.test.mjs +112 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/transcript-cut.mjs +270 -0
- package/vendor/hyperframes/dist/skills/media-use/scripts/transcript-cut.test.mjs +117 -0
- package/vendor/hyperframes/dist/skills-MJ2J4GEM.js +808 -0
- package/vendor/hyperframes/dist/skillsUpdateCheck-TKTYQN5R.js +26 -0
- package/vendor/hyperframes/dist/slideshow-EJ4IMY6P.js +24 -0
- package/vendor/hyperframes/dist/snapshot-KIVDUUMN.js +875 -0
- package/vendor/hyperframes/dist/src-6YQBJGWR.js +202 -0
- package/vendor/hyperframes/dist/src-PVYUYV3M.js +471 -0
- package/vendor/hyperframes/dist/state-KAXGHF77.js +26 -0
- package/vendor/hyperframes/dist/staticProjectServer-7EU666GS.js +49 -0
- package/vendor/hyperframes/dist/status-YM52BQ6S.js +311 -0
- package/vendor/hyperframes/dist/studio/assets/hyperframes-player-Cp8e_Zst.js +473 -0
- package/vendor/hyperframes/dist/studio/assets/index-BX3KHhGX.js +71 -0
- package/vendor/hyperframes/dist/studio/assets/index-CASEBNy2.js +1 -0
- package/vendor/hyperframes/dist/studio/assets/index-D11atkBt.css +1 -0
- package/vendor/hyperframes/dist/studio/assets/index-DMTt9nTf.js +531 -0
- package/vendor/hyperframes/dist/studio/assets/index-oE1pOdAy.js +399 -0
- package/vendor/hyperframes/dist/studio/chunk-5VSXRGIX.js +948 -0
- package/vendor/hyperframes/dist/studio/chunk-5VSXRGIX.js.map +1 -0
- package/vendor/hyperframes/dist/studio/chunk-7UQWVN52.js +938 -0
- package/vendor/hyperframes/dist/studio/chunk-7UQWVN52.js.map +1 -0
- package/vendor/hyperframes/dist/studio/chunk-EEXSYY5F.js +190 -0
- package/vendor/hyperframes/dist/studio/chunk-EEXSYY5F.js.map +1 -0
- package/vendor/hyperframes/dist/studio/chunk-FOEID72M.js +1441 -0
- package/vendor/hyperframes/dist/studio/chunk-FOEID72M.js.map +1 -0
- package/vendor/hyperframes/dist/studio/chunk-PZ5AY32C.js +10 -0
- package/vendor/hyperframes/dist/studio/chunk-PZ5AY32C.js.map +1 -0
- package/vendor/hyperframes/dist/studio/chunk-TDWGXBUT.js +1103 -0
- package/vendor/hyperframes/dist/studio/chunk-TDWGXBUT.js.map +1 -0
- package/vendor/hyperframes/dist/studio/domEditingLayers-IEVLO54Z.js +47 -0
- package/vendor/hyperframes/dist/studio/domEditingLayers-IEVLO54Z.js.map +1 -0
- package/vendor/hyperframes/dist/studio/favicon.svg +14 -0
- package/vendor/hyperframes/dist/studio/icons/timeline/audio.svg +7 -0
- package/vendor/hyperframes/dist/studio/icons/timeline/captions.svg +5 -0
- package/vendor/hyperframes/dist/studio/icons/timeline/composition.svg +12 -0
- package/vendor/hyperframes/dist/studio/icons/timeline/image.svg +18 -0
- package/vendor/hyperframes/dist/studio/icons/timeline/music.svg +10 -0
- package/vendor/hyperframes/dist/studio/icons/timeline/text.svg +3 -0
- package/vendor/hyperframes/dist/studio/index.css +165 -0
- package/vendor/hyperframes/dist/studio/index.css.map +1 -0
- package/vendor/hyperframes/dist/studio/index.d.ts +4296 -0
- package/vendor/hyperframes/dist/studio/index.html +23 -0
- package/vendor/hyperframes/dist/studio/index.js +99693 -0
- package/vendor/hyperframes/dist/studio/index.js.map +1 -0
- package/vendor/hyperframes/dist/studio/player.d.ts +30 -0
- package/vendor/hyperframes/dist/studio/player.js +10 -0
- package/vendor/hyperframes/dist/studio/player.js.map +1 -0
- package/vendor/hyperframes/dist/studio/styles/tailwind-preset.d.ts +39 -0
- package/vendor/hyperframes/dist/studio/styles/tailwind-preset.js +50 -0
- package/vendor/hyperframes/dist/studio/styles/tailwind-preset.js.map +1 -0
- package/vendor/hyperframes/dist/studio/styles.css +1 -0
- package/vendor/hyperframes/dist/studio/ui.d.ts +296 -0
- package/vendor/hyperframes/dist/studio/ui.js +66 -0
- package/vendor/hyperframes/dist/studio/ui.js.map +1 -0
- package/vendor/hyperframes/dist/studio-api-PNQZRPX5.js +136 -0
- package/vendor/hyperframes/dist/studioSelectionClient-IUUPKUHZ.js +25 -0
- package/vendor/hyperframes/dist/studioServer-UWRBPIOJ.js +1457 -0
- package/vendor/hyperframes/dist/synthesize-K62TIZWI.js +182 -0
- package/vendor/hyperframes/dist/system-EZYZNUFD.js +44 -0
- package/vendor/hyperframes/dist/telemetry-2YC4SGQU.js +144 -0
- package/vendor/hyperframes/dist/telemetry-QMYM4WME.js +95 -0
- package/vendor/hyperframes/dist/templates/_shared/AGENTS.md +107 -0
- package/vendor/hyperframes/dist/templates/_shared/CLAUDE.md +107 -0
- package/vendor/hyperframes/dist/templates/blank/index.html +55 -0
- package/vendor/hyperframes/dist/templates/from-file/index.html +75 -0
- package/vendor/hyperframes/dist/templates/warm-grain/compositions/captions.html +154 -0
- package/vendor/hyperframes/dist/templates/warm-grain/compositions/graphics.html +162 -0
- package/vendor/hyperframes/dist/templates/warm-grain/compositions/intro.html +87 -0
- package/vendor/hyperframes/dist/templates/warm-grain/index.html +264 -0
- package/vendor/hyperframes/dist/templates/warm-grain/registry-item.json +34 -0
- package/vendor/hyperframes/dist/timeline-77Z3BBQM.js +1377 -0
- package/vendor/hyperframes/dist/tokens-OBGTYE4Z.js +92 -0
- package/vendor/hyperframes/dist/transcribe-7NVFHCGA.js +387 -0
- package/vendor/hyperframes/dist/transcribe-BNSJRR4M.js +62 -0
- package/vendor/hyperframes/dist/tts-P3LIPIL5.js +234 -0
- package/vendor/hyperframes/dist/updateCheck-UDWIJ4ZQ.js +39 -0
- package/vendor/hyperframes/dist/upgrade-CT3CPO3E.js +231 -0
- package/vendor/hyperframes/dist/urlDownloader-H6WRI2UE.js +39 -0
- package/vendor/hyperframes/dist/usage-EC3KFUIJ.js +2139 -0
- package/vendor/hyperframes/dist/validate-65QDZJWZ.js +70 -0
- package/vendor/hyperframes/dist/video-FGSGKRSV.js +261 -0
- package/vendor/hyperframes/dist/workspaceBuildCheck-TOLGAI4T.js +133 -0
- package/vendor/hyperframes/package.json +80 -0
|
@@ -0,0 +1,972 @@
|
|
|
1
|
+
import { createRequire as __hf_createRequire } from "node:module";
|
|
2
|
+
import { fileURLToPath as __hf_fileURLToPath } from "node:url";
|
|
3
|
+
import { dirname as __hf_dirname } from "node:path";
|
|
4
|
+
var require = __hf_createRequire(import.meta.url);
|
|
5
|
+
var __filename = __hf_fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = __hf_dirname(__filename);
|
|
7
|
+
import {
|
|
8
|
+
readOptionalString
|
|
9
|
+
} from "./chunk-ZKDMAOFU.js";
|
|
10
|
+
import {
|
|
11
|
+
patchElementInHtml
|
|
12
|
+
} from "./chunk-RMHUQGRK.js";
|
|
13
|
+
import {
|
|
14
|
+
resolveProject
|
|
15
|
+
} from "./chunk-S3D6GE5W.js";
|
|
16
|
+
import "./chunk-IHFUKJOR.js";
|
|
17
|
+
import {
|
|
18
|
+
findFFmpeg,
|
|
19
|
+
findFFprobe,
|
|
20
|
+
getFFmpegInstallHint
|
|
21
|
+
} from "./chunk-TVCRUG2S.js";
|
|
22
|
+
import "./chunk-JTHMTOMQ.js";
|
|
23
|
+
import "./chunk-EISRN4E6.js";
|
|
24
|
+
import "./chunk-VWG7OQKU.js";
|
|
25
|
+
import {
|
|
26
|
+
c
|
|
27
|
+
} from "./chunk-ZTZA4UWZ.js";
|
|
28
|
+
import "./chunk-IUZFXWSV.js";
|
|
29
|
+
import "./chunk-AMKC3AXA.js";
|
|
30
|
+
import {
|
|
31
|
+
defineCommand
|
|
32
|
+
} from "./chunk-S3S4TGEH.js";
|
|
33
|
+
import "./chunk-54HJ63Q2.js";
|
|
34
|
+
import {
|
|
35
|
+
failCommand
|
|
36
|
+
} from "./chunk-PBN6GBJE.js";
|
|
37
|
+
import "./chunk-K2FTXJYH.js";
|
|
38
|
+
import "./chunk-2YN64IN5.js";
|
|
39
|
+
import "./chunk-AVUUN2XD.js";
|
|
40
|
+
import "./chunk-DPVXBVLL.js";
|
|
41
|
+
import "./chunk-Z6B37SNM.js";
|
|
42
|
+
import {
|
|
43
|
+
HF_COLOR_GRADING_ATTR,
|
|
44
|
+
getHfColorGradingCapabilities,
|
|
45
|
+
hasHfColorGradingAuthoredValues,
|
|
46
|
+
normalizeHfColorGrading,
|
|
47
|
+
serializeHfColorGrading
|
|
48
|
+
} from "./chunk-HWKCIWQT.js";
|
|
49
|
+
import "./chunk-VC76R6W2.js";
|
|
50
|
+
import "./chunk-OFQWTKPW.js";
|
|
51
|
+
import "./chunk-LCSMOLGX.js";
|
|
52
|
+
import "./chunk-TWWSYAKJ.js";
|
|
53
|
+
import {
|
|
54
|
+
cleanAssetUrl,
|
|
55
|
+
isRemoteOrInlineUrl,
|
|
56
|
+
resolveExistingLocalAsset
|
|
57
|
+
} from "./chunk-ZJUKFZ2P.js";
|
|
58
|
+
import "./chunk-HBBJFK6I.js";
|
|
59
|
+
import "./chunk-PJ3HDUCY.js";
|
|
60
|
+
import {
|
|
61
|
+
isColorGradingVariableRef,
|
|
62
|
+
isPathInside,
|
|
63
|
+
rewriteAssetPath,
|
|
64
|
+
validateColorGradingContract
|
|
65
|
+
} from "./chunk-TQFG7HTI.js";
|
|
66
|
+
import {
|
|
67
|
+
parseHTML
|
|
68
|
+
} from "./chunk-GK4AIFIH.js";
|
|
69
|
+
import "./chunk-2PSPARWP.js";
|
|
70
|
+
import {
|
|
71
|
+
withMeta
|
|
72
|
+
} from "./chunk-HW6OYASV.js";
|
|
73
|
+
import "./chunk-K4WIOZFP.js";
|
|
74
|
+
import "./chunk-XUXGIA7H.js";
|
|
75
|
+
import "./chunk-WERLJGIC.js";
|
|
76
|
+
import "./chunk-ISN5GRYI.js";
|
|
77
|
+
import "./chunk-FLWXXDNS.js";
|
|
78
|
+
import {
|
|
79
|
+
normalizeErrorMessage
|
|
80
|
+
} from "./chunk-KNU5COPB.js";
|
|
81
|
+
import "./chunk-3GXQPCJC.js";
|
|
82
|
+
import "./chunk-RQVDTPGD.js";
|
|
83
|
+
import "./chunk-PMRBLBUP.js";
|
|
84
|
+
import "./chunk-M2WBOQ2Q.js";
|
|
85
|
+
|
|
86
|
+
// src/commands/media-treatment.ts
|
|
87
|
+
import { existsSync, readFileSync, writeFileSync } from "fs";
|
|
88
|
+
import { join, relative, resolve } from "path";
|
|
89
|
+
|
|
90
|
+
// ../core/dist/mediaGradeAnalyzer.js
|
|
91
|
+
import { execFileSync } from "child_process";
|
|
92
|
+
import { basename, extname } from "path";
|
|
93
|
+
var IMAGE_EXTENSIONS = /* @__PURE__ */ new Set([
|
|
94
|
+
".jpg",
|
|
95
|
+
".jpeg",
|
|
96
|
+
".png",
|
|
97
|
+
".webp",
|
|
98
|
+
".gif",
|
|
99
|
+
".bmp",
|
|
100
|
+
".tif",
|
|
101
|
+
".tiff"
|
|
102
|
+
]);
|
|
103
|
+
var SAMPLE_FRAMES = 5;
|
|
104
|
+
var DEFAULT_TIMEOUT_MS = 15e3;
|
|
105
|
+
var ADJUST_LIMITS = {
|
|
106
|
+
exposure: { min: -2, max: 2 },
|
|
107
|
+
contrast: { min: -1, max: 1 },
|
|
108
|
+
whites: { min: -1, max: 1 },
|
|
109
|
+
blacks: { min: -1, max: 1 },
|
|
110
|
+
temperature: { min: -1, max: 1 },
|
|
111
|
+
tint: { min: -1, max: 1 }
|
|
112
|
+
};
|
|
113
|
+
function clamp(value, key) {
|
|
114
|
+
const limit = ADJUST_LIMITS[key];
|
|
115
|
+
if (!Number.isFinite(value))
|
|
116
|
+
return 0;
|
|
117
|
+
return Math.min(limit.max, Math.max(limit.min, value));
|
|
118
|
+
}
|
|
119
|
+
function round(value) {
|
|
120
|
+
const rounded = Math.round(value * 1e3) / 1e3;
|
|
121
|
+
return Object.is(rounded, -0) ? 0 : rounded;
|
|
122
|
+
}
|
|
123
|
+
function average(values) {
|
|
124
|
+
return values.reduce((sum, value) => sum + value, 0) / Math.max(1, values.length);
|
|
125
|
+
}
|
|
126
|
+
function isRecord(value) {
|
|
127
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
128
|
+
}
|
|
129
|
+
function asRecord(value) {
|
|
130
|
+
return isRecord(value) ? value : {};
|
|
131
|
+
}
|
|
132
|
+
function probeMedia(mediaPath, ffprobePath) {
|
|
133
|
+
try {
|
|
134
|
+
const raw = execFileSync(ffprobePath, [
|
|
135
|
+
"-v",
|
|
136
|
+
"error",
|
|
137
|
+
"-select_streams",
|
|
138
|
+
"v:0",
|
|
139
|
+
"-show_entries",
|
|
140
|
+
"stream=color_space,color_transfer,color_primaries,pix_fmt,duration:format=duration",
|
|
141
|
+
"-of",
|
|
142
|
+
"json",
|
|
143
|
+
"--",
|
|
144
|
+
mediaPath
|
|
145
|
+
], { encoding: "utf8", timeout: 5e3, stdio: ["ignore", "pipe", "pipe"], windowsHide: true });
|
|
146
|
+
const parsed = asRecord(JSON.parse(raw));
|
|
147
|
+
const streams = Array.isArray(parsed.streams) ? parsed.streams : [];
|
|
148
|
+
const stream = asRecord(streams[0]);
|
|
149
|
+
const format = asRecord(parsed.format);
|
|
150
|
+
const duration = Number(stream.duration ?? format.duration);
|
|
151
|
+
const text = (key) => {
|
|
152
|
+
const value = stream[key];
|
|
153
|
+
return typeof value === "string" && value ? value : "unknown";
|
|
154
|
+
};
|
|
155
|
+
return {
|
|
156
|
+
duration: Number.isFinite(duration) && duration > 0 ? duration : null,
|
|
157
|
+
colorSpace: text("color_space"),
|
|
158
|
+
transfer: text("color_transfer"),
|
|
159
|
+
primaries: text("color_primaries"),
|
|
160
|
+
pixelFormat: text("pix_fmt")
|
|
161
|
+
};
|
|
162
|
+
} catch {
|
|
163
|
+
return {
|
|
164
|
+
duration: null,
|
|
165
|
+
colorSpace: "unknown",
|
|
166
|
+
transfer: "unknown",
|
|
167
|
+
primaries: "unknown",
|
|
168
|
+
pixelFormat: "unknown"
|
|
169
|
+
};
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
function parseMediaTreatmentSignalStats(raw) {
|
|
173
|
+
const frames = [];
|
|
174
|
+
let current = null;
|
|
175
|
+
for (const line of raw.split(/\r?\n/)) {
|
|
176
|
+
const frame = line.match(/^frame:\d.*pts_time:([+-]?(?:\d+(?:\.\d+)?|\.\d+))/);
|
|
177
|
+
if (frame?.[1]) {
|
|
178
|
+
if (current)
|
|
179
|
+
frames.push(current);
|
|
180
|
+
current = { ptsTime: Number(frame[1]) };
|
|
181
|
+
continue;
|
|
182
|
+
}
|
|
183
|
+
const stat = line.match(/lavfi\.signalstats\.([A-Z]+)=([+-]?(?:\d+(?:\.\d+)?|\.\d+))/);
|
|
184
|
+
if (!stat?.[1] || !stat[2])
|
|
185
|
+
continue;
|
|
186
|
+
current ??= {};
|
|
187
|
+
current[stat[1]] = Number(stat[2]);
|
|
188
|
+
}
|
|
189
|
+
if (current)
|
|
190
|
+
frames.push(current);
|
|
191
|
+
return frames.filter((frame) => Number.isFinite(frame.YMIN) && Number.isFinite(frame.YLOW) && Number.isFinite(frame.YAVG) && Number.isFinite(frame.YHIGH) && Number.isFinite(frame.YMAX) && Number.isFinite(frame.UAVG) && Number.isFinite(frame.VAVG));
|
|
192
|
+
}
|
|
193
|
+
function summarizeFrames(frames) {
|
|
194
|
+
if (frames.length === 0)
|
|
195
|
+
throw new Error("FFmpeg returned no analyzable video frames");
|
|
196
|
+
const values = (key) => frames.map((frame) => Number(frame[key]));
|
|
197
|
+
return {
|
|
198
|
+
frames: frames.length,
|
|
199
|
+
yMin: Math.min(...values("YMIN")),
|
|
200
|
+
yLow: average(values("YLOW")),
|
|
201
|
+
yAvg: average(values("YAVG")),
|
|
202
|
+
yHigh: average(values("YHIGH")),
|
|
203
|
+
yMax: Math.max(...values("YMAX")),
|
|
204
|
+
uAvg: average(values("UAVG")),
|
|
205
|
+
vAvg: average(values("VAVG")),
|
|
206
|
+
satAvg: average(frames.map((frame) => frame.SATAVG ?? 0)),
|
|
207
|
+
shadowClipRisk: average(frames.map((frame) => Number(frame.YLOW) <= 16 ? 1 : 0)),
|
|
208
|
+
highlightClipRisk: average(frames.map((frame) => Number(frame.YHIGH) >= 235 ? 1 : 0))
|
|
209
|
+
};
|
|
210
|
+
}
|
|
211
|
+
function suggestedExposure(normalizedAverage, yLow, yHigh) {
|
|
212
|
+
if (normalizedAverage < 0.28 && yHigh / 255 < 0.65) {
|
|
213
|
+
return clamp((0.32 - normalizedAverage) * 1.2, "exposure");
|
|
214
|
+
}
|
|
215
|
+
if (normalizedAverage > 0.72 && yLow / 255 > 0.3) {
|
|
216
|
+
return clamp((0.68 - normalizedAverage) * 1.2, "exposure");
|
|
217
|
+
}
|
|
218
|
+
return 0;
|
|
219
|
+
}
|
|
220
|
+
function suggestedTemperature(uAverage, vAverage) {
|
|
221
|
+
const chromaWarmth = (vAverage - 128 + (128 - uAverage)) / 128;
|
|
222
|
+
return Math.abs(chromaWarmth) >= 0.08 ? clamp(-chromaWarmth * 0.25, "temperature") : 0;
|
|
223
|
+
}
|
|
224
|
+
function suggestedTint(uAverage, vAverage) {
|
|
225
|
+
const cast = uAverage + vAverage - 256;
|
|
226
|
+
return Math.abs(cast) >= 10 ? clamp(-cast / 512, "tint") : 0;
|
|
227
|
+
}
|
|
228
|
+
function statsToAdjust(stats) {
|
|
229
|
+
const yMin = Number(stats.yMin);
|
|
230
|
+
const yLow = Number(stats.yLow ?? stats.yMin);
|
|
231
|
+
const yMax = Number(stats.yMax);
|
|
232
|
+
const yHigh = Number(stats.yHigh ?? stats.yMax);
|
|
233
|
+
const yAvg = Number(stats.yAvg);
|
|
234
|
+
const uAvg = Number(stats.uAvg);
|
|
235
|
+
const vAvg = Number(stats.vAvg);
|
|
236
|
+
const shadowClipRisk = Number(stats.shadowClipRisk ?? (yLow <= 16 ? 1 : 0));
|
|
237
|
+
const highlightClipRisk = Number(stats.highlightClipRisk ?? (yHigh >= 235 ? 1 : 0));
|
|
238
|
+
const percentileSpread = (yHigh - yLow) / 255;
|
|
239
|
+
const normalizedAverage = yAvg / 255;
|
|
240
|
+
const contrast = percentileSpread < 0.35 ? clamp((0.35 - percentileSpread) * 0.4, "contrast") : 0;
|
|
241
|
+
return {
|
|
242
|
+
adjust: {
|
|
243
|
+
exposure: round(suggestedExposure(normalizedAverage, yLow, yHigh)),
|
|
244
|
+
contrast: round(contrast),
|
|
245
|
+
blacks: round(clamp(shadowClipRisk * 0.08, "blacks")),
|
|
246
|
+
whites: round(clamp(-highlightClipRisk * 0.08, "whites")),
|
|
247
|
+
temperature: round(suggestedTemperature(uAvg, vAvg)),
|
|
248
|
+
tint: round(suggestedTint(uAvg, vAvg))
|
|
249
|
+
},
|
|
250
|
+
measured: {
|
|
251
|
+
frames: Number(stats.frames ?? 1),
|
|
252
|
+
yMin: round(yMin),
|
|
253
|
+
yLow: round(yLow),
|
|
254
|
+
yAvg: round(yAvg),
|
|
255
|
+
yHigh: round(yHigh),
|
|
256
|
+
yMax: round(yMax),
|
|
257
|
+
uAvg: round(uAvg),
|
|
258
|
+
vAvg: round(vAvg),
|
|
259
|
+
satAvg: round(Number(stats.satAvg ?? 0)),
|
|
260
|
+
shadowClipRisk: round(shadowClipRisk),
|
|
261
|
+
highlightClipRisk: round(highlightClipRisk)
|
|
262
|
+
}
|
|
263
|
+
};
|
|
264
|
+
}
|
|
265
|
+
function summarizeMediaTreatmentAnalysis(probe, frames) {
|
|
266
|
+
const result = statsToAdjust(summarizeFrames(frames));
|
|
267
|
+
const hdr = ["smpte2084", "arib-std-b67"].includes(probe.transfer);
|
|
268
|
+
const diagnosis = [];
|
|
269
|
+
if (result.measured.shadowClipRisk > 0) {
|
|
270
|
+
diagnosis.push("sampled frames contain deep or clipped shadows");
|
|
271
|
+
}
|
|
272
|
+
if (result.measured.highlightClipRisk > 0) {
|
|
273
|
+
diagnosis.push("sampled frames contain bright or clipped highlights");
|
|
274
|
+
}
|
|
275
|
+
if (diagnosis.length === 0)
|
|
276
|
+
diagnosis.push("no obvious technical imbalance in sampled frames");
|
|
277
|
+
const warnings = [];
|
|
278
|
+
if (hdr)
|
|
279
|
+
warnings.push("HDR transfer detected; the realtime treatment path is SDR/Rec.709.");
|
|
280
|
+
if (probe.colorSpace === "unknown" || probe.transfer === "unknown") {
|
|
281
|
+
warnings.push("Source color metadata is incomplete; camera LOG cannot be identified reliably from container metadata alone.");
|
|
282
|
+
}
|
|
283
|
+
return {
|
|
284
|
+
...result,
|
|
285
|
+
source: {
|
|
286
|
+
colorSpace: probe.colorSpace,
|
|
287
|
+
transfer: probe.transfer,
|
|
288
|
+
primaries: probe.primaries,
|
|
289
|
+
pixelFormat: probe.pixelFormat,
|
|
290
|
+
hdr,
|
|
291
|
+
log: "unknown"
|
|
292
|
+
},
|
|
293
|
+
diagnosis,
|
|
294
|
+
warnings
|
|
295
|
+
};
|
|
296
|
+
}
|
|
297
|
+
function analyzeMediaGrade(mediaPath, options = {}) {
|
|
298
|
+
const ffmpegPath = options.ffmpegPath ?? "ffmpeg";
|
|
299
|
+
const ffprobePath = options.ffprobePath ?? "ffprobe";
|
|
300
|
+
try {
|
|
301
|
+
const probe = probeMedia(mediaPath, ffprobePath);
|
|
302
|
+
const isImage = IMAGE_EXTENSIONS.has(extname(mediaPath).toLowerCase());
|
|
303
|
+
const fps = !isImage && probe.duration ? Math.max(0.1, Math.min(2, SAMPLE_FRAMES / probe.duration)) : null;
|
|
304
|
+
const filters = [
|
|
305
|
+
fps ? `fps=${fps.toFixed(4)}` : null,
|
|
306
|
+
"format=yuv444p",
|
|
307
|
+
"signalstats",
|
|
308
|
+
"metadata=print:file=-"
|
|
309
|
+
].filter(Boolean).join(",");
|
|
310
|
+
const raw = execFileSync(ffmpegPath, [
|
|
311
|
+
"-hide_banner",
|
|
312
|
+
"-nostdin",
|
|
313
|
+
"-v",
|
|
314
|
+
"error",
|
|
315
|
+
"-i",
|
|
316
|
+
mediaPath,
|
|
317
|
+
"-vf",
|
|
318
|
+
filters,
|
|
319
|
+
"-frames:v",
|
|
320
|
+
String(SAMPLE_FRAMES),
|
|
321
|
+
"-f",
|
|
322
|
+
"null",
|
|
323
|
+
"-"
|
|
324
|
+
], {
|
|
325
|
+
encoding: "utf8",
|
|
326
|
+
timeout: Number(process.env.HYPERFRAMES_ANALYZE_TIMEOUT_MS) || DEFAULT_TIMEOUT_MS,
|
|
327
|
+
stdio: ["ignore", "pipe", "pipe"],
|
|
328
|
+
windowsHide: true
|
|
329
|
+
});
|
|
330
|
+
return summarizeMediaTreatmentAnalysis(probe, parseMediaTreatmentSignalStats(raw));
|
|
331
|
+
} catch (error) {
|
|
332
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
333
|
+
throw new Error(`grade analysis failed for ${mediaPath}: ${message}`);
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
// src/commands/media-treatment-analysis.ts
|
|
338
|
+
function analyzeMediaTreatment(mediaPath) {
|
|
339
|
+
const ffmpegPath = findFFmpeg();
|
|
340
|
+
const ffprobePath = findFFprobe();
|
|
341
|
+
if (!ffmpegPath || !ffprobePath) {
|
|
342
|
+
throw new Error(`FFmpeg and ffprobe are required. ${getFFmpegInstallHint()}`);
|
|
343
|
+
}
|
|
344
|
+
const analysis = analyzeMediaGrade(mediaPath, { ffmpegPath, ffprobePath });
|
|
345
|
+
const { adjust, ...evidence } = analysis;
|
|
346
|
+
return { ...evidence, suggestedPatch: { adjust } };
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
// src/commands/media-treatment.ts
|
|
350
|
+
function getMediaTreatmentCapabilityOverview() {
|
|
351
|
+
const capabilities = getHfColorGradingCapabilities();
|
|
352
|
+
const family = (id, label, description) => ({
|
|
353
|
+
id,
|
|
354
|
+
label,
|
|
355
|
+
description
|
|
356
|
+
});
|
|
357
|
+
return {
|
|
358
|
+
version: capabilities.version,
|
|
359
|
+
targetTags: capabilities.targetTags,
|
|
360
|
+
colorSpace: capabilities.colorSpace,
|
|
361
|
+
families: [
|
|
362
|
+
family("correction", "Adjust", "Fix exposure, tonal balance, color casts, and saturation."),
|
|
363
|
+
family(
|
|
364
|
+
"grading",
|
|
365
|
+
"Color Grading",
|
|
366
|
+
"Shape tonal color with wheels, RGB and hue curves, and selective HSL correction."
|
|
367
|
+
),
|
|
368
|
+
family(
|
|
369
|
+
"presets",
|
|
370
|
+
"Presets",
|
|
371
|
+
"Apply a tested starting point, then tune only when the source or intent requires it."
|
|
372
|
+
),
|
|
373
|
+
family("finishing", "Finish", "Shape vignette and deterministic film grain."),
|
|
374
|
+
...capabilities.effectFamilies,
|
|
375
|
+
family(
|
|
376
|
+
"palettes",
|
|
377
|
+
"Palettes",
|
|
378
|
+
"Reusable two-to-six-color palettes for compatible art effects."
|
|
379
|
+
),
|
|
380
|
+
family(
|
|
381
|
+
"animation",
|
|
382
|
+
"Animation",
|
|
383
|
+
"Seek-safe CSS properties that registered GSAP timelines may animate."
|
|
384
|
+
),
|
|
385
|
+
family("lut", "Custom LUT", "Apply a user-owned 3D .cube LUT."),
|
|
386
|
+
{
|
|
387
|
+
id: "overlays",
|
|
388
|
+
label: "Overlays",
|
|
389
|
+
description: "Install authored HUD, light-leak, flash, or freeze-frame overlay blocks.",
|
|
390
|
+
owner: "registry"
|
|
391
|
+
}
|
|
392
|
+
],
|
|
393
|
+
discovery: {
|
|
394
|
+
detail: "Use --capability <family-or-item> for exact controls and examples.",
|
|
395
|
+
full: "Use --all only for tooling or exhaustive inspection."
|
|
396
|
+
}
|
|
397
|
+
};
|
|
398
|
+
}
|
|
399
|
+
function getMediaTreatmentCapabilityDetail(id) {
|
|
400
|
+
const capabilities = getHfColorGradingCapabilities();
|
|
401
|
+
const animation = (path) => {
|
|
402
|
+
const property = capabilities.animatable.find((candidate) => candidate.path === path);
|
|
403
|
+
if (!property) return null;
|
|
404
|
+
return {
|
|
405
|
+
property,
|
|
406
|
+
initial: `style="${property.name}: <start>"`,
|
|
407
|
+
tween: `timeline.to("<selector>", { "${property.name}": <end>, duration: <seconds> })`,
|
|
408
|
+
rules: [
|
|
409
|
+
"Author the initial value inline on the media element.",
|
|
410
|
+
"Use finite keyframes on a paused timeline registered in window.__timelines.",
|
|
411
|
+
"Do not use a frame-zero set, timers, random values, or onUpdate callbacks."
|
|
412
|
+
]
|
|
413
|
+
};
|
|
414
|
+
};
|
|
415
|
+
const effect = capabilities.effects.find(({ key }) => key === id);
|
|
416
|
+
if (effect) {
|
|
417
|
+
return {
|
|
418
|
+
id,
|
|
419
|
+
family: effect.family,
|
|
420
|
+
label: effect.label,
|
|
421
|
+
description: effect.description,
|
|
422
|
+
renderLane: effect.renderLane,
|
|
423
|
+
supportsPalette: effect.supportsPalette,
|
|
424
|
+
apply: { effects: effect.apply },
|
|
425
|
+
controls: effect.controls,
|
|
426
|
+
animation: animation(`effects.${id}`)
|
|
427
|
+
};
|
|
428
|
+
}
|
|
429
|
+
const effectFamily = capabilities.effectFamilies.find((family) => family.id === id);
|
|
430
|
+
if (effectFamily) {
|
|
431
|
+
return {
|
|
432
|
+
...effectFamily,
|
|
433
|
+
effects: capabilities.effects.filter((candidate) => candidate.family === id).map((candidate) => ({
|
|
434
|
+
id: candidate.key,
|
|
435
|
+
label: candidate.label,
|
|
436
|
+
description: candidate.description,
|
|
437
|
+
renderLane: candidate.renderLane,
|
|
438
|
+
supportsPalette: candidate.supportsPalette,
|
|
439
|
+
animatable: capabilities.animatable.some(
|
|
440
|
+
({ path }) => path === `effects.${candidate.key}`
|
|
441
|
+
)
|
|
442
|
+
}))
|
|
443
|
+
};
|
|
444
|
+
}
|
|
445
|
+
const adjustment = capabilities.adjustments.find(({ key }) => key === id);
|
|
446
|
+
if (adjustment) {
|
|
447
|
+
return {
|
|
448
|
+
id,
|
|
449
|
+
family: "correction",
|
|
450
|
+
description: `Adjust ${id} within the canonical correction range.`,
|
|
451
|
+
control: adjustment,
|
|
452
|
+
apply: { adjust: { [id]: adjustment.identity } },
|
|
453
|
+
animation: animation(`adjust.${id}`)
|
|
454
|
+
};
|
|
455
|
+
}
|
|
456
|
+
const finishing = capabilities.finishing.find(({ key }) => key === id);
|
|
457
|
+
if (finishing) {
|
|
458
|
+
return {
|
|
459
|
+
id,
|
|
460
|
+
family: "finishing",
|
|
461
|
+
description: `Adjust ${id} within the canonical finishing range.`,
|
|
462
|
+
control: finishing,
|
|
463
|
+
apply: { details: { [id]: finishing.identity } }
|
|
464
|
+
};
|
|
465
|
+
}
|
|
466
|
+
const preset = capabilities.presets.find((candidate) => candidate.id === id);
|
|
467
|
+
if (preset) {
|
|
468
|
+
return {
|
|
469
|
+
id: preset.id,
|
|
470
|
+
label: preset.label,
|
|
471
|
+
description: "Tested built-in media preset.",
|
|
472
|
+
apply: { preset: preset.id, intensity: preset.intensity }
|
|
473
|
+
};
|
|
474
|
+
}
|
|
475
|
+
const palette = capabilities.palettes.find((candidate) => candidate.id === id);
|
|
476
|
+
if (palette) return { ...palette, apply: { palette: palette.colors } };
|
|
477
|
+
const details = {
|
|
478
|
+
grading: {
|
|
479
|
+
id,
|
|
480
|
+
description: "Shape media after primary correction with wheels, curves, HSL secondaries, and an optional user-owned LUT.",
|
|
481
|
+
order: [
|
|
482
|
+
"adjust",
|
|
483
|
+
"wheels",
|
|
484
|
+
"curves",
|
|
485
|
+
"hueCurves",
|
|
486
|
+
"secondaries",
|
|
487
|
+
"lut",
|
|
488
|
+
"details",
|
|
489
|
+
"effects"
|
|
490
|
+
],
|
|
491
|
+
discover: ["wheels", "curves", "hue-curves", "secondary", "scopes", "lut"]
|
|
492
|
+
},
|
|
493
|
+
correction: {
|
|
494
|
+
id,
|
|
495
|
+
description: "Fix exposure, tonal balance, color casts, and saturation.",
|
|
496
|
+
controls: capabilities.adjustments
|
|
497
|
+
},
|
|
498
|
+
wheels: {
|
|
499
|
+
id,
|
|
500
|
+
description: "Shadow, midtone, and highlight color wheels.",
|
|
501
|
+
contract: capabilities.wheels,
|
|
502
|
+
apply: {
|
|
503
|
+
wheels: {
|
|
504
|
+
shadows: { hue: 205, amount: 0.08, level: 0 },
|
|
505
|
+
highlights: { hue: 35, amount: 0.06, level: 0 }
|
|
506
|
+
}
|
|
507
|
+
}
|
|
508
|
+
},
|
|
509
|
+
curves: {
|
|
510
|
+
id,
|
|
511
|
+
description: "Master and per-channel curves using normalized [input, output] points.",
|
|
512
|
+
contract: capabilities.curves,
|
|
513
|
+
apply: {
|
|
514
|
+
curves: {
|
|
515
|
+
master: [
|
|
516
|
+
[0, 0],
|
|
517
|
+
[0.25, 0.2],
|
|
518
|
+
[0.75, 0.82],
|
|
519
|
+
[1, 1]
|
|
520
|
+
]
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
},
|
|
524
|
+
"hue-curves": {
|
|
525
|
+
id,
|
|
526
|
+
description: "Hue-selective curves using [hueDegrees, delta] points.",
|
|
527
|
+
contract: capabilities.hueCurves,
|
|
528
|
+
apply: {
|
|
529
|
+
hueCurves: {
|
|
530
|
+
hueVsSaturation: [
|
|
531
|
+
[180, 0],
|
|
532
|
+
[210, 0.15],
|
|
533
|
+
[240, 0]
|
|
534
|
+
]
|
|
535
|
+
}
|
|
536
|
+
}
|
|
537
|
+
},
|
|
538
|
+
secondary: {
|
|
539
|
+
id,
|
|
540
|
+
description: "Up to four ordered HSL selections with bounded color correction.",
|
|
541
|
+
contract: capabilities.secondaries,
|
|
542
|
+
apply: {
|
|
543
|
+
secondaries: [
|
|
544
|
+
{
|
|
545
|
+
key: {
|
|
546
|
+
hue: { center: 215, range: 25, softness: 10 },
|
|
547
|
+
saturation: { min: 0.2, max: 1, softness: 0.08 },
|
|
548
|
+
luma: { min: 0.1, max: 0.9, softness: 0.08 }
|
|
549
|
+
},
|
|
550
|
+
correction: { saturation: 0.15, luma: 0.03 }
|
|
551
|
+
}
|
|
552
|
+
]
|
|
553
|
+
}
|
|
554
|
+
},
|
|
555
|
+
scopes: {
|
|
556
|
+
id,
|
|
557
|
+
description: "Deterministic source measurements for agent decisions; visual scopes remain a Studio display.",
|
|
558
|
+
command: "hyperframes media-treatment --file compositions/scene.html --selector '#hero' --analyze --json",
|
|
559
|
+
output: [
|
|
560
|
+
"source color metadata and HDR/LOG warnings",
|
|
561
|
+
"luma percentile and clipping evidence",
|
|
562
|
+
"bounded suggested primary correction"
|
|
563
|
+
]
|
|
564
|
+
},
|
|
565
|
+
presets: {
|
|
566
|
+
id,
|
|
567
|
+
description: "Tested starting points for color and stylized media effects.",
|
|
568
|
+
presets: capabilities.presets
|
|
569
|
+
},
|
|
570
|
+
finishing: {
|
|
571
|
+
id,
|
|
572
|
+
description: "Vignette and deterministic film-grain controls.",
|
|
573
|
+
controls: capabilities.finishing
|
|
574
|
+
},
|
|
575
|
+
palettes: {
|
|
576
|
+
id,
|
|
577
|
+
description: "Named palettes plus the custom palette contract.",
|
|
578
|
+
contract: capabilities.palette,
|
|
579
|
+
palettes: capabilities.palettes
|
|
580
|
+
},
|
|
581
|
+
animation: {
|
|
582
|
+
id,
|
|
583
|
+
description: "Seek-safe CSS properties for registered GSAP timelines.",
|
|
584
|
+
properties: capabilities.animatable
|
|
585
|
+
},
|
|
586
|
+
lut: {
|
|
587
|
+
id,
|
|
588
|
+
description: "User-owned 3D .cube LUT support.",
|
|
589
|
+
contract: capabilities.lut
|
|
590
|
+
},
|
|
591
|
+
overlays: {
|
|
592
|
+
id,
|
|
593
|
+
description: "Authored overlay blocks owned by the HyperFrames Registry.",
|
|
594
|
+
discover: "hyperframes catalog",
|
|
595
|
+
apply: "hyperframes add <overlay> --dir <project> --no-clipboard --json"
|
|
596
|
+
}
|
|
597
|
+
};
|
|
598
|
+
const detail = Object.hasOwn(details, id) ? Reflect.get(details, id) : void 0;
|
|
599
|
+
if (detail) return detail;
|
|
600
|
+
throw new Error(`Unknown media-treatment capability: ${id}`);
|
|
601
|
+
}
|
|
602
|
+
var examples = [
|
|
603
|
+
[
|
|
604
|
+
"Discover the complete treatment surface without loading every control",
|
|
605
|
+
`hyperframes media-treatment --capabilities --json`
|
|
606
|
+
],
|
|
607
|
+
[
|
|
608
|
+
"Inspect one relevant effect in detail",
|
|
609
|
+
`hyperframes media-treatment --capability kuwahara --json`
|
|
610
|
+
],
|
|
611
|
+
[
|
|
612
|
+
"Inspect the exhaustive machine-readable catalog",
|
|
613
|
+
`hyperframes media-treatment --capabilities --all --json`
|
|
614
|
+
],
|
|
615
|
+
[
|
|
616
|
+
"Apply a resolved treatment to one media element",
|
|
617
|
+
`hyperframes media-treatment --selector '#hero' --grading '{"preset":"skin-soft","intensity":0.6}' --apply`
|
|
618
|
+
],
|
|
619
|
+
[
|
|
620
|
+
"Preview the exact mutation without writing",
|
|
621
|
+
`hyperframes media-treatment --file compositions/scene.html --selector 'video' --grading '{"preset":"warm-daylight"}' --apply --dry-run --json`
|
|
622
|
+
],
|
|
623
|
+
[
|
|
624
|
+
"Measure one local media source before choosing a correction",
|
|
625
|
+
`hyperframes media-treatment --selector '#hero' --analyze --json`
|
|
626
|
+
],
|
|
627
|
+
["Remove a treatment", `hyperframes media-treatment --selector '#hero' --clear`]
|
|
628
|
+
];
|
|
629
|
+
function parseSourceDocument2(source) {
|
|
630
|
+
if (/<!doctype|<html[\s>]/i.test(source)) return parseHTML(source).document;
|
|
631
|
+
return parseHTML(`<!DOCTYPE html><html><body>${source}</body></html>`).document;
|
|
632
|
+
}
|
|
633
|
+
function assertKnownGradingShape(value) {
|
|
634
|
+
const issue = validateColorGradingContract(value)[0];
|
|
635
|
+
if (issue) {
|
|
636
|
+
const hint = issue.hint ? ` ${issue.hint}` : "";
|
|
637
|
+
throw new Error(`Invalid color-grading ${issue.path}: ${issue.message}.${hint}`);
|
|
638
|
+
}
|
|
639
|
+
}
|
|
640
|
+
function containsColorGradingVariableRef(value) {
|
|
641
|
+
if (isColorGradingVariableRef(value)) return true;
|
|
642
|
+
if (Array.isArray(value)) return value.some(containsColorGradingVariableRef);
|
|
643
|
+
if (typeof value !== "object" || value === null) return false;
|
|
644
|
+
return Object.values(value).some(containsColorGradingVariableRef);
|
|
645
|
+
}
|
|
646
|
+
function isRecord2(value) {
|
|
647
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
648
|
+
}
|
|
649
|
+
function parseStoredGrading(raw) {
|
|
650
|
+
if (raw === null) return null;
|
|
651
|
+
try {
|
|
652
|
+
return JSON.parse(raw);
|
|
653
|
+
} catch {
|
|
654
|
+
return raw;
|
|
655
|
+
}
|
|
656
|
+
}
|
|
657
|
+
function mergeGradingPatch(current, patch) {
|
|
658
|
+
if (!isRecord2(current) || !isRecord2(patch)) return patch;
|
|
659
|
+
const merged = { ...current };
|
|
660
|
+
for (const [key, value] of Object.entries(patch)) {
|
|
661
|
+
merged[key] = isRecord2(value) && isRecord2(merged[key]) ? mergeGradingPatch(merged[key], value) : value;
|
|
662
|
+
}
|
|
663
|
+
return merged;
|
|
664
|
+
}
|
|
665
|
+
function serializeGradingPatch(before, patch) {
|
|
666
|
+
assertKnownGradingShape(patch);
|
|
667
|
+
if (isColorGradingVariableRef(before) && isRecord2(patch)) {
|
|
668
|
+
throw new Error("Cannot merge a grading patch into an unresolved whole-grade variable");
|
|
669
|
+
}
|
|
670
|
+
const current = typeof before === "string" && !isColorGradingVariableRef(before) ? { preset: before } : before;
|
|
671
|
+
const grading = mergeGradingPatch(current, patch);
|
|
672
|
+
assertKnownGradingShape(grading);
|
|
673
|
+
if (containsColorGradingVariableRef(grading)) {
|
|
674
|
+
return typeof grading === "string" ? grading.trim() : JSON.stringify(grading);
|
|
675
|
+
}
|
|
676
|
+
const normalized = normalizeHfColorGrading(grading);
|
|
677
|
+
if (!normalized) throw new Error("--grading must be valid HyperFrames color-grading JSON");
|
|
678
|
+
return hasHfColorGradingAuthoredValues(normalized) ? serializeHfColorGrading(normalized) : null;
|
|
679
|
+
}
|
|
680
|
+
function queryIncludingTemplates(root, selector) {
|
|
681
|
+
const matches = Array.from(root.querySelectorAll(selector));
|
|
682
|
+
if (matches.length > 0) return matches;
|
|
683
|
+
for (const template of root.querySelectorAll("template")) {
|
|
684
|
+
const nested = queryIncludingTemplates(template, selector);
|
|
685
|
+
if (nested.length > 0) return nested;
|
|
686
|
+
}
|
|
687
|
+
return [];
|
|
688
|
+
}
|
|
689
|
+
function selectMediaElement(source, selector, selectorIndex) {
|
|
690
|
+
const document = parseSourceDocument2(source);
|
|
691
|
+
let matches;
|
|
692
|
+
try {
|
|
693
|
+
matches = queryIncludingTemplates(document, selector);
|
|
694
|
+
} catch {
|
|
695
|
+
throw new Error(`Invalid selector: ${selector}`);
|
|
696
|
+
}
|
|
697
|
+
if (matches.length === 0) throw new Error(`Selector did not match: ${selector}`);
|
|
698
|
+
if (selectorIndex === void 0 && matches.length > 1) {
|
|
699
|
+
throw new Error(
|
|
700
|
+
`Selector matched ${matches.length} elements; use a unique selector or --selector-index`
|
|
701
|
+
);
|
|
702
|
+
}
|
|
703
|
+
const resolvedIndex = selectorIndex ?? 0;
|
|
704
|
+
const element = matches[resolvedIndex];
|
|
705
|
+
if (!element) {
|
|
706
|
+
throw new Error(`--selector-index ${resolvedIndex} is outside ${matches.length} matches`);
|
|
707
|
+
}
|
|
708
|
+
const tag = element.tagName.toLowerCase();
|
|
709
|
+
if (tag !== "img" && tag !== "video") {
|
|
710
|
+
throw new Error(`Color grading requires an <img> or <video>; selector matched <${tag}>`);
|
|
711
|
+
}
|
|
712
|
+
return { element, selectorIndex: resolvedIndex, tag };
|
|
713
|
+
}
|
|
714
|
+
function applyMediaTreatmentToHtml(source, options) {
|
|
715
|
+
const { element, selectorIndex, tag } = selectMediaElement(
|
|
716
|
+
source,
|
|
717
|
+
options.selector,
|
|
718
|
+
options.selectorIndex
|
|
719
|
+
);
|
|
720
|
+
const before = parseStoredGrading(element.getAttribute(HF_COLOR_GRADING_ATTR));
|
|
721
|
+
const value = options.clear ? null : serializeGradingPatch(before, options.grading);
|
|
722
|
+
const changed = element.getAttribute(HF_COLOR_GRADING_ATTR) !== value;
|
|
723
|
+
const after = parseStoredGrading(value);
|
|
724
|
+
if (!changed) return { html: source, changed: false, tag, value, before, after };
|
|
725
|
+
const patched = patchElementInHtml(source, { selector: options.selector, selectorIndex }, [
|
|
726
|
+
{ type: "attribute", property: HF_COLOR_GRADING_ATTR, value }
|
|
727
|
+
]);
|
|
728
|
+
if (!patched.matched) throw new Error(`Could not persist selector: ${options.selector}`);
|
|
729
|
+
return { html: patched.html, changed: true, tag, value, before, after };
|
|
730
|
+
}
|
|
731
|
+
function parseSelectorIndex(raw) {
|
|
732
|
+
if (raw === void 0) return void 0;
|
|
733
|
+
const value = Number(raw);
|
|
734
|
+
if (!Number.isInteger(value) || value < 0) {
|
|
735
|
+
throw new Error("--selector-index must be a non-negative integer");
|
|
736
|
+
}
|
|
737
|
+
return value;
|
|
738
|
+
}
|
|
739
|
+
function mediaSourceForElement(element) {
|
|
740
|
+
const src = element.getAttribute("src") ?? (element.tagName.toLowerCase() === "video" ? element.querySelector("source")?.getAttribute("src") : null);
|
|
741
|
+
if (!src) throw new Error("Selected media has no analyzable src");
|
|
742
|
+
return src;
|
|
743
|
+
}
|
|
744
|
+
function resolveMediaTreatmentSource(projectDir, compositionFile, source) {
|
|
745
|
+
const sourceUrl = source.trim();
|
|
746
|
+
if (!sourceUrl) throw new Error("Selected media has no analyzable local src");
|
|
747
|
+
if (isRemoteOrInlineUrl(sourceUrl)) {
|
|
748
|
+
throw new Error(
|
|
749
|
+
"Media analysis requires a local project asset; freeze remote media with media-use first"
|
|
750
|
+
);
|
|
751
|
+
}
|
|
752
|
+
const cleanSource = cleanAssetUrl(sourceUrl);
|
|
753
|
+
if (!cleanSource) throw new Error("Selected media has no analyzable local src");
|
|
754
|
+
const projectRelative = cleanSource.startsWith("/") ? cleanSource : rewriteAssetPath(compositionFile, cleanSource, (path) => existsSync(join(projectDir, path)));
|
|
755
|
+
const asset = resolveExistingLocalAsset(projectDir, projectRelative);
|
|
756
|
+
if (!asset) throw new Error(`Media file not found: ${source}`);
|
|
757
|
+
return asset.resolved;
|
|
758
|
+
}
|
|
759
|
+
function parseGrading(raw, apply, clear) {
|
|
760
|
+
if (clear) {
|
|
761
|
+
if (raw !== void 0 || apply) {
|
|
762
|
+
throw new Error("Use either --apply with --grading or --clear, not both");
|
|
763
|
+
}
|
|
764
|
+
return void 0;
|
|
765
|
+
}
|
|
766
|
+
if (!apply) {
|
|
767
|
+
if (raw !== void 0) throw new Error("--grading requires --apply");
|
|
768
|
+
throw new Error("Use --apply with --grading <json> or --clear");
|
|
769
|
+
}
|
|
770
|
+
if (raw === void 0) throw new Error("--apply requires --grading <json>");
|
|
771
|
+
try {
|
|
772
|
+
return JSON.parse(raw);
|
|
773
|
+
} catch (error) {
|
|
774
|
+
throw new Error(`Could not parse --grading JSON: ${normalizeErrorMessage(error)}`);
|
|
775
|
+
}
|
|
776
|
+
}
|
|
777
|
+
function mutationVerb(action, changed, dryRun) {
|
|
778
|
+
if (dryRun) return `Would ${action}`;
|
|
779
|
+
if (!changed) return action === "apply" ? "Already applied" : "Already clear";
|
|
780
|
+
return action === "apply" ? "Applied" : "Cleared";
|
|
781
|
+
}
|
|
782
|
+
function runCapabilityQuery(args) {
|
|
783
|
+
const capability = readOptionalString(args.capability);
|
|
784
|
+
const hasMutationOption = [
|
|
785
|
+
readOptionalString(args.selector),
|
|
786
|
+
readOptionalString(args.grading),
|
|
787
|
+
args.clear,
|
|
788
|
+
args["dry-run"],
|
|
789
|
+
args.apply,
|
|
790
|
+
args.analyze
|
|
791
|
+
].some(Boolean);
|
|
792
|
+
if (hasMutationOption) throw new Error("--capabilities cannot be combined with mutation options");
|
|
793
|
+
if (args.all === true && capability)
|
|
794
|
+
throw new Error("Use either --all or --capability, not both");
|
|
795
|
+
let capabilities = getMediaTreatmentCapabilityOverview();
|
|
796
|
+
if (args.all === true) capabilities = getHfColorGradingCapabilities();
|
|
797
|
+
else if (capability) capabilities = getMediaTreatmentCapabilityDetail(capability);
|
|
798
|
+
console.log(JSON.stringify(withMeta({ ok: true, capabilities }), null, 2));
|
|
799
|
+
}
|
|
800
|
+
function resolveMutationFile(args) {
|
|
801
|
+
const project = resolveProject(readOptionalString(args.project));
|
|
802
|
+
const fileArg = readOptionalString(args.file) ?? "index.html";
|
|
803
|
+
const filePath = resolve(project.dir, fileArg);
|
|
804
|
+
if (!isPathInside(filePath, project.dir) || !filePath.toLowerCase().endsWith(".html")) {
|
|
805
|
+
throw new Error("--file must be an HTML file inside the project");
|
|
806
|
+
}
|
|
807
|
+
if (!existsSync(filePath)) throw new Error(`Composition file not found: ${fileArg}`);
|
|
808
|
+
return { project, filePath };
|
|
809
|
+
}
|
|
810
|
+
function analyzeTarget(args) {
|
|
811
|
+
const { project, filePath } = resolveMutationFile(args);
|
|
812
|
+
const selector = readOptionalString(args.selector);
|
|
813
|
+
if (!selector) throw new Error("--selector is required");
|
|
814
|
+
if (readOptionalString(args.grading) || args.clear === true || args.apply === true || args["dry-run"] === true) {
|
|
815
|
+
throw new Error("--analyze cannot be combined with mutation options");
|
|
816
|
+
}
|
|
817
|
+
const selectorIndex = parseSelectorIndex(readOptionalString(args["selector-index"]));
|
|
818
|
+
const { element, tag } = selectMediaElement(
|
|
819
|
+
readFileSync(filePath, "utf8"),
|
|
820
|
+
selector,
|
|
821
|
+
selectorIndex
|
|
822
|
+
);
|
|
823
|
+
const source = mediaSourceForElement(element);
|
|
824
|
+
const compositionFile = relative(project.dir, filePath).split("\\").join("/");
|
|
825
|
+
const mediaPath = resolveMediaTreatmentSource(project.dir, compositionFile, source);
|
|
826
|
+
return {
|
|
827
|
+
ok: true,
|
|
828
|
+
action: "analyze",
|
|
829
|
+
file: compositionFile || "index.html",
|
|
830
|
+
selector,
|
|
831
|
+
selectorIndex: selectorIndex ?? 0,
|
|
832
|
+
tag,
|
|
833
|
+
media: source,
|
|
834
|
+
...analyzeMediaTreatment(mediaPath)
|
|
835
|
+
};
|
|
836
|
+
}
|
|
837
|
+
function prepareMutation(args) {
|
|
838
|
+
const { project, filePath } = resolveMutationFile(args);
|
|
839
|
+
const selector = readOptionalString(args.selector);
|
|
840
|
+
if (!selector) throw new Error("--selector is required");
|
|
841
|
+
const clear = args.clear === true;
|
|
842
|
+
const apply = args.apply === true;
|
|
843
|
+
const selectorIndex = parseSelectorIndex(readOptionalString(args["selector-index"]));
|
|
844
|
+
const result = applyMediaTreatmentToHtml(readFileSync(filePath, "utf8"), {
|
|
845
|
+
selector,
|
|
846
|
+
selectorIndex,
|
|
847
|
+
grading: parseGrading(readOptionalString(args.grading), apply, clear),
|
|
848
|
+
clear
|
|
849
|
+
});
|
|
850
|
+
const dryRun = args["dry-run"] === true;
|
|
851
|
+
if (result.changed && !dryRun) writeFileSync(filePath, result.html);
|
|
852
|
+
const action = result.value === null ? "clear" : "apply";
|
|
853
|
+
return {
|
|
854
|
+
action,
|
|
855
|
+
result,
|
|
856
|
+
selector,
|
|
857
|
+
payload: {
|
|
858
|
+
ok: true,
|
|
859
|
+
action,
|
|
860
|
+
file: relative(project.dir, filePath) || "index.html",
|
|
861
|
+
selector,
|
|
862
|
+
selectorIndex: selectorIndex ?? 0,
|
|
863
|
+
tag: result.tag,
|
|
864
|
+
changed: result.changed,
|
|
865
|
+
dryRun,
|
|
866
|
+
before: result.before,
|
|
867
|
+
after: result.after
|
|
868
|
+
}
|
|
869
|
+
};
|
|
870
|
+
}
|
|
871
|
+
function isCapabilityQuery(args) {
|
|
872
|
+
return args.capabilities === true || Boolean(readOptionalString(args.capability)) || args.all === true;
|
|
873
|
+
}
|
|
874
|
+
function printAnalysis(args) {
|
|
875
|
+
const result = analyzeTarget(args);
|
|
876
|
+
if (args.json === true) {
|
|
877
|
+
console.log(JSON.stringify(withMeta(result), null, 2));
|
|
878
|
+
return;
|
|
879
|
+
}
|
|
880
|
+
console.log(`${c.success("\u25C7")} Analyzed ${c.accent(result.selector)}`);
|
|
881
|
+
for (const diagnosis of result.diagnosis) console.log(` ${diagnosis}`);
|
|
882
|
+
for (const warning of result.warnings) console.log(` ${c.warn(warning)}`);
|
|
883
|
+
console.log(` suggested patch: ${JSON.stringify(result.suggestedPatch)}`);
|
|
884
|
+
}
|
|
885
|
+
function printMutation(args) {
|
|
886
|
+
const { action, result, selector, payload } = prepareMutation(args);
|
|
887
|
+
if (args.json === true) {
|
|
888
|
+
console.log(JSON.stringify(withMeta(payload), null, 2));
|
|
889
|
+
return;
|
|
890
|
+
}
|
|
891
|
+
const verb = mutationVerb(action, result.changed, payload.dryRun);
|
|
892
|
+
console.log(`${c.success("\u25C7")} ${verb} media treatment on ${c.accent(selector)}`);
|
|
893
|
+
}
|
|
894
|
+
function printFailure(error, json) {
|
|
895
|
+
const message = normalizeErrorMessage(error);
|
|
896
|
+
if (json) console.log(JSON.stringify(withMeta({ ok: false, error: message })));
|
|
897
|
+
else console.error(`${c.error("\u2717")} ${message}`);
|
|
898
|
+
failCommand(1, error);
|
|
899
|
+
}
|
|
900
|
+
var mediaTreatmentCommand = defineCommand({
|
|
901
|
+
meta: {
|
|
902
|
+
name: "media-treatment",
|
|
903
|
+
description: "Discover, apply, or clear deterministic media treatments"
|
|
904
|
+
},
|
|
905
|
+
args: {
|
|
906
|
+
capabilities: {
|
|
907
|
+
type: "boolean",
|
|
908
|
+
description: "Print a concise agent-readable capability overview",
|
|
909
|
+
default: false
|
|
910
|
+
},
|
|
911
|
+
capability: {
|
|
912
|
+
type: "string",
|
|
913
|
+
description: "Inspect one family, control, effect, preset, or palette"
|
|
914
|
+
},
|
|
915
|
+
all: {
|
|
916
|
+
type: "boolean",
|
|
917
|
+
description: "Print the exhaustive capability catalog",
|
|
918
|
+
default: false
|
|
919
|
+
},
|
|
920
|
+
project: { type: "string", description: "Project directory (default: cwd)" },
|
|
921
|
+
file: {
|
|
922
|
+
type: "string",
|
|
923
|
+
description: "Composition file relative to project (default: index.html)"
|
|
924
|
+
},
|
|
925
|
+
selector: {
|
|
926
|
+
type: "string",
|
|
927
|
+
description: "Unique CSS selector for one <img> or <video>"
|
|
928
|
+
},
|
|
929
|
+
"selector-index": {
|
|
930
|
+
type: "string",
|
|
931
|
+
description: "Zero-based match index when the selector is not unique"
|
|
932
|
+
},
|
|
933
|
+
grading: { type: "string", description: "Canonical color-grading JSON patch" },
|
|
934
|
+
apply: {
|
|
935
|
+
type: "boolean",
|
|
936
|
+
description: "Apply the validated grading patch (explicit agent form)",
|
|
937
|
+
default: false
|
|
938
|
+
},
|
|
939
|
+
analyze: {
|
|
940
|
+
type: "boolean",
|
|
941
|
+
description: "Measure selected local media and suggest a bounded primary correction",
|
|
942
|
+
default: false
|
|
943
|
+
},
|
|
944
|
+
clear: { type: "boolean", description: "Remove color grading from the target", default: false },
|
|
945
|
+
"dry-run": {
|
|
946
|
+
type: "boolean",
|
|
947
|
+
description: "Validate and report without writing",
|
|
948
|
+
default: false
|
|
949
|
+
},
|
|
950
|
+
json: { type: "boolean", description: "Output an agent-friendly JSON result", default: false }
|
|
951
|
+
},
|
|
952
|
+
run({ args }) {
|
|
953
|
+
try {
|
|
954
|
+
if (isCapabilityQuery(args)) return runCapabilityQuery(args);
|
|
955
|
+
if (args.analyze === true) {
|
|
956
|
+
printAnalysis(args);
|
|
957
|
+
return;
|
|
958
|
+
}
|
|
959
|
+
printMutation(args);
|
|
960
|
+
} catch (error) {
|
|
961
|
+
printFailure(error, args.json === true);
|
|
962
|
+
}
|
|
963
|
+
}
|
|
964
|
+
});
|
|
965
|
+
export {
|
|
966
|
+
applyMediaTreatmentToHtml,
|
|
967
|
+
examples,
|
|
968
|
+
getMediaTreatmentCapabilityDetail,
|
|
969
|
+
getMediaTreatmentCapabilityOverview,
|
|
970
|
+
mediaTreatmentCommand,
|
|
971
|
+
resolveMediaTreatmentSource
|
|
972
|
+
};
|