hyperframes 0.8.137 → 0.8.139
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/dist/{add-RUYRFHHN.js → add-VYJQ4S3P.js} +15 -15
- package/dist/{animatedGifPrep-VMLA2P45.js → animatedGifPrep-IBMW6FZB.js} +6 -6
- package/dist/appHistory-TH3TL6N6.js +31 -0
- package/dist/{asset-DHOG5RFW.js → asset-FLSUS73X.js} +2 -2
- package/dist/{assetCataloger-7XIMSAPT.js → assetCataloger-TGD7TRCR.js} +2 -2
- package/dist/{auth-FUBCZVUH.js → auth-EZXIN4M4.js} +2 -2
- package/dist/{autoUpdate-LHVP2DWF.js → autoUpdate-ZPMY5T3X.js} +2 -2
- package/dist/{backgroundChecks-JO3KP5QE.js → backgroundChecks-JIDTAUFE.js} +3 -3
- package/dist/backgroundChecksWorker.js +3 -3
- package/dist/{batchRender-PBCQ3R2Y.js → batchRender-FNZ6TJYY.js} +3 -3
- package/dist/{beats-AF7C54FH.js → beats-EAA4U3YN.js} +14 -14
- package/dist/{benchmark-QST66S5G.js → benchmark-KKZQVK2Y.js} +12 -12
- package/dist/{browser-NBKY3N66.js → browser-ZIVVJLJT.js} +9 -9
- package/dist/{bundleWithLocalizedFonts-ZYZHO7IV.js → bundleWithLocalizedFonts-2XWC3PEM.js} +2 -2
- package/dist/{capture-MGC5AO5D.js → capture-EFYPXI42.js} +13 -13
- package/dist/{capture-6GM7SIH5.js → capture-MKJHABUL.js} +2 -2
- package/dist/{catalog-IT2TP2YE.js → catalog-EWX4BBI2.js} +21 -21
- package/dist/catch-up-FJFH7T4W.js +123 -0
- package/dist/{check-HNTSVBUV.js → check-YJNVDCBP.js} +38 -38
- package/dist/{checkBrowser-XH446M7L.js → checkBrowser-I6SPPEGD.js} +36 -36
- package/dist/{chunk-WTGGSKAJ.js → chunk-25DHUDOK.js} +3 -3
- package/dist/{chunk-XT5P4QMO.js → chunk-3DKN5WKL.js} +31 -11
- package/dist/{chunk-MBSFY6Y5.js → chunk-3RT6D4P6.js} +1 -1
- package/dist/{chunk-6IEDWKFR.js → chunk-4VZBKOQJ.js} +1 -1
- package/dist/chunk-6IHWCZ3W.js +54 -0
- package/dist/{chunk-X2GKNLHE.js → chunk-7SI7GCX6.js} +3 -3
- package/dist/{chunk-J4AOOISS.js → chunk-A4X2YWNQ.js} +217 -6
- package/dist/{chunk-E6WZHX7J.js → chunk-BC3OY2ED.js} +1 -1
- package/dist/{chunk-GR7YLWXS.js → chunk-CDJ7FPPJ.js} +1 -1
- package/dist/{chunk-4LBBWEEH.js → chunk-CDMB3PRC.js} +4 -4
- package/dist/chunk-DCAI5DBR.js +218 -0
- package/dist/{chunk-LSLJIVWV.js → chunk-DUQJF7FK.js} +3 -3
- package/dist/{chunk-VU7RRQNA.js → chunk-DW32KBHN.js} +12 -12
- package/dist/{chunk-GULOKZLI.js → chunk-EDUBJPGL.js} +14 -9
- package/dist/{chunk-4HWOEWMH.js → chunk-EH4VUY27.js} +5 -5
- package/dist/{chunk-SCCJUPPX.js → chunk-EJ7OWYF2.js} +1 -1
- package/dist/{chunk-R2MFCLGW.js → chunk-EZ2P7LAP.js} +5 -5
- package/dist/{chunk-DKYXU4F4.js → chunk-FLRCVYNE.js} +2 -2
- package/dist/{chunk-NSLSFVFN.js → chunk-GIDHR5OL.js} +1 -1
- package/dist/{chunk-HUV6BP7O.js → chunk-GWV2Y36Q.js} +405 -205
- package/dist/{chunk-RQLZL5KC.js → chunk-HOIHGPWO.js} +1 -1
- package/dist/chunk-HYYSJI5D.js +3742 -0
- package/dist/{chunk-BVOGEPHM.js → chunk-IBRZUVTH.js} +2 -2
- package/dist/{chunk-ZBKSKJ37.js → chunk-JIIIBTN2.js} +1 -1
- package/dist/{chunk-J6BHZVM3.js → chunk-JTAYFSLO.js} +1 -1
- package/dist/{chunk-7LAWNKVY.js → chunk-JX7Y57YY.js} +1 -1
- package/dist/{chunk-S3S2LSZX.js → chunk-KDPYVTEU.js} +2 -1
- package/dist/{chunk-OUKLD6D2.js → chunk-NTIOLSFE.js} +3 -3
- package/dist/{chunk-ADXD2HP4.js → chunk-O6K5DWXM.js} +1 -1
- package/dist/{chunk-5ORPW6RH.js → chunk-OENM2JVZ.js} +3 -3
- package/dist/{chunk-N4Y4KZFV.js → chunk-PFI3VD77.js} +7 -7
- package/dist/{chunk-OEJQAXS3.js → chunk-PLNWWGE7.js} +1 -1
- package/dist/{chunk-MOBLZWAK.js → chunk-Q73ISOVQ.js} +1 -1
- package/dist/{chunk-TTBOUHWT.js → chunk-QXOFUKBF.js} +3 -3
- package/dist/{chunk-VYGC4AJL.js → chunk-R7LWDIKB.js} +1 -1
- package/dist/{chunk-DRYF6HV2.js → chunk-SIKMUO45.js} +11 -11
- package/dist/{chunk-VDQCNWQI.js → chunk-STA43FMY.js} +1 -1
- package/dist/{chunk-2DQ356HE.js → chunk-TCWL4BKK.js} +1 -1
- package/dist/{chunk-FAID56IK.js → chunk-U3GEXWI5.js} +1 -1
- package/dist/{chunk-GYVUR4XC.js → chunk-U3HX7WE6.js} +1 -1
- package/dist/{chunk-YDCEBBEL.js → chunk-UGI77E35.js} +10 -10
- package/dist/{chunk-WYX6L7AV.js → chunk-UMWROSIP.js} +2 -2
- package/dist/chunk-UOFAE5RF.js +42 -0
- package/dist/{chunk-7MF7FTFV.js → chunk-UQXOHEQ7.js} +1 -1
- package/dist/{chunk-ZBAC7334.js → chunk-VTVS4IIP.js} +2 -2
- package/dist/{chunk-E2C5SLHT.js → chunk-W7SAWBQC.js} +78 -20
- package/dist/{chunk-JVJQL42J.js → chunk-X3TMMIDP.js} +9 -9
- package/dist/{chunk-SMGQFCBC.js → chunk-XOZ3J3LB.js} +1 -1
- package/dist/{chunk-WFNNUWFN.js → chunk-YOL4QRSL.js} +2 -2
- package/dist/{chunk-6XCIGLRQ.js → chunk-Z67RZ4XO.js} +62 -228
- package/dist/{clean-OWDWVJBN.js → clean-P4KTCOUA.js} +21 -21
- package/dist/cli.js +62 -52
- package/dist/{cloud-S3MPN5VF.js → cloud-PDY7S4HU.js} +4 -4
- package/dist/{cloudrun-TLB7DEIN.js → cloudrun-54MA2W5H.js} +3 -3
- package/dist/{compare-YRR6E22F.js → compare-LDWVSPC5.js} +29 -29
- package/dist/{compiler-ENHZ73DN.js → compiler-CWSZ4W7J.js} +3 -3
- package/dist/{component-EIJRLMDN.js → component-FIEGC22U.js} +3 -3
- package/dist/{compositions-5CBYWP55.js → compositions-JR7PX356.js} +11 -11
- package/dist/{delete-3U5L6XFA.js → delete-FXA2IHOS.js} +3 -3
- package/dist/{deterministicFonts-U2EXY2KQ.js → deterministicFonts-GTITFRSJ.js} +2 -2
- package/dist/{dist-7Y5HTID7.js → dist-4JZWRWS6.js} +2 -2
- package/dist/{dist-QS5WEGBE.js → dist-OJTEVNJR.js} +1 -1
- package/dist/{doctor-IZQZRMWC.js → doctor-OTDHPM6K.js} +12 -12
- package/dist/{events-6BYBCUBA.js → events-6T7M2VCO.js} +9 -9
- package/dist/{events-BYDKYSIJ.js → events-UAFTI24U.js} +8 -8
- package/dist/{feedback-I4YN55BC.js → feedback-ZGZODHB6.js} +12 -12
- package/dist/{figma-A3FAM3JT.js → figma-D26EJ7ZB.js} +3 -3
- package/dist/fontLocalizeCli.js +10 -10
- package/dist/{get-PIFWLOAB.js → get-IAREU7IK.js} +3 -3
- package/dist/{gpuPolicy-26BEFD3H.js → gpuPolicy-NS7WZRDJ.js} +6 -6
- package/dist/{grade-compare-H2OKE5QQ.js → grade-compare-ZXHFHCD2.js} +26 -26
- package/dist/{gsapParser-2OL54XZ5.js → gsapParser-UP3PNPC2.js} +3 -2
- package/dist/{help-AXK7X72W.js → help-RVNYHW3N.js} +3 -2
- package/dist/{history-KUS6IXSL.js → history-THP4VNMF.js} +18 -18
- package/dist/hyperframe-runtime.js +64 -182
- package/dist/hyperframe.manifest.json +1 -1
- package/dist/hyperframe.runtime.iife.js +64 -182
- package/dist/hyperframes-player.global.js +1 -1
- package/dist/{info-DRASLTTJ.js → info-EOFRHN5A.js} +11 -11
- package/dist/{init-3BZKVTW5.js → init-YLIJE4CG.js} +24 -22
- package/dist/{inspect-ROKMT5V7.js → inspect-3D56ONJD.js} +27 -27
- package/dist/{installer-ERYE2UVI.js → installer-GRR2GDZK.js} +4 -4
- package/dist/{keyframes-PXGT4QQ5.js → keyframes-NXNCTQPK.js} +12 -12
- package/dist/{lambda-EQAPNZDT.js → lambda-VGRZD7TR.js} +4 -4
- package/dist/{layout-PMFNU7NB.js → layout-Z5DOS6DU.js} +27 -27
- package/dist/{lint-G26WF3YE.js → lint-YD6NJGR2.js} +14 -14
- package/dist/{lintProject-EPVG2EFE.js → lintProject-ANMPLBIT.js} +1 -1
- package/dist/{list-WIPSPI6M.js → list-XGDKILYN.js} +3 -3
- package/dist/{login-3CPZGZKC.js → login-GD5SA4RD.js} +4 -4
- package/dist/{media-treatment-MGAQ5DQJ.js → media-treatment-TY4X4GQQ.js} +14 -14
- package/dist/{models-QHS7P3NJ.js → models-MXRDH4WJ.js} +19 -12
- package/dist/{motionShot-OLA4DIP7.js → motionShot-6LKR3C2E.js} +12 -12
- package/dist/{normalize-audio-PAPIKX2Y.js → normalize-audio-5ADDZKPJ.js} +14 -14
- package/dist/{open-D5INI7M6.js → open-JXAMO325.js} +20 -13
- package/dist/{pipeline-IWP6BVSS.js → pipeline-Q5MOPIIX.js} +8 -8
- package/dist/{play-O2WTUH6O.js → play-3SPH5GWZ.js} +30 -30
- package/dist/{preflight-EUCDEHR5.js → preflight-2PWAPKWC.js} +7 -7
- package/dist/{present-YDJZIRYD.js → present-ZTJQDKXZ.js} +19 -19
- package/dist/{preview-AS6S5EKV.js → preview-4A3XZR6J.js} +26 -24
- package/dist/{producer-S77FHAAG.js → producer-5ZKKKQPB.js} +1 -1
- package/dist/{projectConfig-6XCGW6KX.js → projectConfig-WA4CS4SN.js} +6 -6
- package/dist/{publication-E46VH7XO.js → publication-CLG2FRRI.js} +2 -2
- package/dist/{publish-GQXWU7NF.js → publish-YTT2WMXO.js} +12 -11
- package/dist/{remove-background-JPPYOSD2.js → remove-background-W35INR3B.js} +9 -9
- package/dist/{render-XC3O77AK.js → render-7A4P5WMU.js} +3 -3
- package/dist/{render-IPOSWART.js → render-KICXUPNR.js} +17 -17
- package/dist/{render-HQJEYV6Q.js → render-WUBFQMAH.js} +29 -27
- package/dist/{render-batch-FX5TZDGW.js → render-batch-N7EFGE6S.js} +3 -3
- package/dist/{renderCancellation-66SZW2VF.js → renderCancellation-LYQPPFAO.js} +6 -6
- package/dist/renderSetupWorker.js +1 -1
- package/dist/{resolver-JU3VRG4K.js → resolver-YTT2NENF.js} +4 -4
- package/dist/{sherpa-I5YSMJNV.js → sherpa-353MW4UV.js} +140 -46
- package/dist/sherpaWorker.js +13 -9
- package/dist/skills/hyperframes/SKILL.md +2 -0
- package/dist/skills/hyperframes-cli/SKILL.md +1 -1
- package/dist/{skills-SLCG4D3C.js → skills-2XJIOEBT.js} +14 -14
- package/dist/{skillsUpdateCheck-KJBSMNG3.js → skillsUpdateCheck-LMCCWGNO.js} +3 -3
- package/dist/{snapshot-WOPONARS.js → snapshot-WBRSTLJ2.js} +36 -36
- package/dist/{src-A7PS67DT.js → src-YWFJILQF.js} +5 -5
- package/dist/{src-EDXJKFXO.js → src-ZS3BLTZ5.js} +9 -9
- package/dist/{staticProjectServer-XUCQPVTF.js → staticProjectServer-4VKVHPNG.js} +14 -14
- package/dist/{status-Z23IJMWJ.js → status-73MBN37B.js} +6 -6
- package/dist/studio/assets/{hyperframes-player-D_Mh6hbx.js → hyperframes-player-CckOoCJ8.js} +1 -1
- package/dist/studio/assets/{index-CHEctGzc.js → index-BmIPrb8I.js} +1 -1
- package/dist/studio/assets/{index-B3lJsA-e.js → index-Br1Whc0f.js} +189 -189
- package/dist/studio/assets/{index-CC_E-Cbl.css → index-CVd4O6eH.css} +1 -1
- package/dist/studio/assets/{index-rtccfg9b.js → index-DsEkE5_G.js} +1 -1
- package/dist/studio/{chunk-4S3AYCOG.js → chunk-E422JDF5.js} +2 -2
- package/dist/studio/{chunk-TDWGXBUT.js → chunk-TFLU2MGI.js} +1 -6
- package/dist/studio/chunk-TFLU2MGI.js.map +1 -0
- package/dist/studio/{chunk-7UQWVN52.js → chunk-UYWON5AX.js} +2 -2
- package/dist/studio/{domEditingLayers-IEVLO54Z.js → domEditingLayers-KBTPQKGA.js} +3 -3
- package/dist/studio/index.d.ts +2 -1
- package/dist/studio/index.html +2 -2
- package/dist/studio/index.js +867 -499
- package/dist/studio/index.js.map +1 -1
- package/dist/studio/player.js +2 -2
- package/dist/studio/styles.css +1 -1
- package/dist/{studio-api-SAZ65ULH.js → studio-api-5V4TVSQV.js} +11 -11
- package/dist/{studioServer-525NV45Z.js → studioServer-M5XY3HYC.js} +51 -50
- package/dist/{system-SXBUUXBG.js → system-RCRNX5VF.js} +6 -6
- package/dist/{telemetry-MUWYEQ42.js → telemetry-LOBRQGUD.js} +9 -9
- package/dist/templates/_shared/AGENTS.md +2 -0
- package/dist/templates/_shared/CLAUDE.md +2 -0
- package/dist/{timeline-BUCFPNP6.js → timeline-3JCP6PXU.js} +18 -18
- package/dist/{tokens-OOJBPXYD.js → tokens-MLMIJBVF.js} +2 -2
- package/dist/{transcribe-JAADNKL7.js → transcribe-KNFXDEAX.js} +9 -7
- package/dist/{transcribe-GCVTFFIF.js → transcribe-POH25ZPX.js} +30 -47
- package/dist/{tts-XGVL5UHX.js → tts-FU35O6YB.js} +1 -1
- package/dist/{updateCheck-AVUIJNVC.js → updateCheck-5ITBSBST.js} +2 -2
- package/dist/{upgrade-DV6IVILG.js → upgrade-K6OK4FKT.js} +2 -2
- package/dist/{urlDownloader-N7LDOVHK.js → urlDownloader-TJJQKADT.js} +5 -5
- package/dist/{validate-22IQFLYH.js → validate-PPPOBJHB.js} +16 -16
- package/dist/{video-22M7YBQT.js → video-OB22HWXZ.js} +6 -6
- package/package.json +1 -1
- package/dist/chunk-P7GAS5DG.js +0 -3742
- package/dist/studio/chunk-TDWGXBUT.js.map +0 -1
- package/dist/{chunk-WJFCDDP7.js → chunk-R4QIE6UY.js} +3 -3
- package/dist/studio/{chunk-4S3AYCOG.js.map → chunk-E422JDF5.js.map} +0 -0
- package/dist/studio/{chunk-7UQWVN52.js.map → chunk-UYWON5AX.js.map} +0 -0
- package/dist/studio/{domEditingLayers-IEVLO54Z.js.map → domEditingLayers-KBTPQKGA.js.map} +0 -0
- package/dist/{synthesize-4RPDY46T.js → synthesize-77PTU6C5.js} +4 -4
|
@@ -14,9 +14,13 @@ import {
|
|
|
14
14
|
describeRejectedPythonOverride,
|
|
15
15
|
hasPythonModules
|
|
16
16
|
} from "./chunk-5ETJX6WM.js";
|
|
17
|
+
import {
|
|
18
|
+
OPTIONAL_PACKAGES,
|
|
19
|
+
installedOptionalPackageVersion
|
|
20
|
+
} from "./chunk-3DKN5WKL.js";
|
|
17
21
|
import {
|
|
18
22
|
runEnvironmentChecks
|
|
19
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-O6K5DWXM.js";
|
|
20
24
|
import {
|
|
21
25
|
c
|
|
22
26
|
} from "./chunk-ZTZA4UWZ.js";
|
|
@@ -25,31 +29,27 @@ import {
|
|
|
25
29
|
getFreeDiskMb,
|
|
26
30
|
getShmSizeMb,
|
|
27
31
|
getSystemMeta
|
|
28
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-PLNWWGE7.js";
|
|
29
33
|
import {
|
|
30
34
|
defineCommand
|
|
31
35
|
} from "./chunk-S3S4TGEH.js";
|
|
32
36
|
import {
|
|
33
37
|
resolveExtractCacheDir
|
|
34
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-QXOFUKBF.js";
|
|
35
39
|
import {
|
|
36
40
|
getUpdateMeta,
|
|
37
41
|
withMeta
|
|
38
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-TCWL4BKK.js";
|
|
39
43
|
import {
|
|
40
44
|
CONFIG_PATH,
|
|
41
45
|
withFileLock
|
|
42
46
|
} from "./chunk-XUXGIA7H.js";
|
|
43
47
|
import {
|
|
44
48
|
VERSION
|
|
45
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-UMWROSIP.js";
|
|
46
50
|
import {
|
|
47
51
|
normalizeErrorMessage
|
|
48
52
|
} from "./chunk-KNU5COPB.js";
|
|
49
|
-
import {
|
|
50
|
-
OPTIONAL_PACKAGES,
|
|
51
|
-
installedOptionalPackageVersion
|
|
52
|
-
} from "./chunk-XT5P4QMO.js";
|
|
53
53
|
|
|
54
54
|
// src/commands/doctor.ts
|
|
55
55
|
import { execFileSync, execSync } from "child_process";
|
|
@@ -8,10 +8,10 @@ import {
|
|
|
8
8
|
DEFAULT_VP9_CPU_USED,
|
|
9
9
|
isHttpUrl,
|
|
10
10
|
runFfmpeg
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-QXOFUKBF.js";
|
|
12
12
|
import {
|
|
13
13
|
parseAnimatedGifMetadata
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-EJ7OWYF2.js";
|
|
15
15
|
import {
|
|
16
16
|
parseHTML
|
|
17
17
|
} from "./chunk-GK4AIFIH.js";
|
|
@@ -21,20 +21,14 @@ import {
|
|
|
21
21
|
splitElementInHtml,
|
|
22
22
|
unwrapElementsFromHtml,
|
|
23
23
|
wrapElementsInHtml
|
|
24
|
-
} from "./chunk-
|
|
25
|
-
import {
|
|
26
|
-
atomicTempPath,
|
|
27
|
-
createFileAtomically,
|
|
28
|
-
isAtomicTempPath,
|
|
29
|
-
replaceFileAtomically
|
|
30
|
-
} from "./chunk-EOVYQ3IG.js";
|
|
24
|
+
} from "./chunk-DUQJF7FK.js";
|
|
31
25
|
import {
|
|
32
26
|
DEFAULT_TARGET_LUFS,
|
|
33
27
|
absoluteLoudnessPlan,
|
|
34
28
|
measureAudio,
|
|
35
29
|
requiredFfmpeg,
|
|
36
30
|
resolveLocalAudioPath
|
|
37
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-Q73ISOVQ.js";
|
|
38
32
|
import {
|
|
39
33
|
PROXY_PARAMS_VERSION,
|
|
40
34
|
PROXY_PENDING_RETRY_AFTER_SECONDS,
|
|
@@ -42,9 +36,13 @@ import {
|
|
|
42
36
|
ProxyCapacityError,
|
|
43
37
|
ProxyTranscodeError,
|
|
44
38
|
ProxyWaitTimeoutError,
|
|
39
|
+
STUDIO_MOTION_PATH,
|
|
45
40
|
createMediaCodecProbeCache,
|
|
41
|
+
createStudioMotionRenderBodyScript,
|
|
46
42
|
decideMediaProxyEligibility,
|
|
47
43
|
isInHiddenOrVendorDir,
|
|
44
|
+
isPrivateProjectFile,
|
|
45
|
+
isPrivateProjectPath,
|
|
48
46
|
isProxyVariantRequest,
|
|
49
47
|
pinWithinProject,
|
|
50
48
|
probeAssetCodec,
|
|
@@ -56,11 +54,18 @@ import {
|
|
|
56
54
|
recordProxyRequest,
|
|
57
55
|
resolveProxy,
|
|
58
56
|
resolveProxyVariantRequest,
|
|
57
|
+
resolveWithinProject,
|
|
59
58
|
scanProjectMediaCodecMap,
|
|
60
59
|
shouldPrewarmProxy,
|
|
61
60
|
waitForProxy,
|
|
62
61
|
walkDir
|
|
63
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-A4X2YWNQ.js";
|
|
63
|
+
import {
|
|
64
|
+
atomicTempPath,
|
|
65
|
+
createFileAtomically,
|
|
66
|
+
isAtomicTempPath,
|
|
67
|
+
replaceFileAtomically
|
|
68
|
+
} from "./chunk-EOVYQ3IG.js";
|
|
64
69
|
import {
|
|
65
70
|
findTimelineScript,
|
|
66
71
|
parseGsapScriptAcorn
|
|
@@ -81,7 +86,7 @@ import {
|
|
|
81
86
|
motionPathPluginUrl,
|
|
82
87
|
parseFps,
|
|
83
88
|
sameInstant
|
|
84
|
-
} from "./chunk-
|
|
89
|
+
} from "./chunk-EJ7OWYF2.js";
|
|
85
90
|
import {
|
|
86
91
|
MagicString,
|
|
87
92
|
VALID_CANVAS_RESOLUTIONS,
|
|
@@ -90,7 +95,7 @@ import {
|
|
|
90
95
|
import {
|
|
91
96
|
addScenePartsManifest,
|
|
92
97
|
ensureHfIds
|
|
93
|
-
} from "./chunk-
|
|
98
|
+
} from "./chunk-GWV2Y36Q.js";
|
|
94
99
|
import {
|
|
95
100
|
AFTER_FONTS_SCRIPT_TYPE,
|
|
96
101
|
RUNTIME_BOOTSTRAP_ATTR,
|
|
@@ -104,20 +109,19 @@ import {
|
|
|
104
109
|
resolveRateSpec,
|
|
105
110
|
sourceTimeAt,
|
|
106
111
|
stripEmbeddedRuntimeScripts
|
|
107
|
-
} from "./chunk-
|
|
112
|
+
} from "./chunk-HYYSJI5D.js";
|
|
108
113
|
import {
|
|
109
114
|
ProjectRootMissingError,
|
|
110
115
|
folderGone,
|
|
111
116
|
isProjectRootMissing,
|
|
112
117
|
isSafePath,
|
|
113
118
|
mkdirWithinProject,
|
|
114
|
-
realpath
|
|
115
|
-
resolveWithinProject
|
|
119
|
+
realpath
|
|
116
120
|
} from "./chunk-OFQWTKPW.js";
|
|
117
121
|
import {
|
|
118
122
|
isWithinProjectRoot,
|
|
119
123
|
readProjectFile
|
|
120
|
-
} from "./chunk-
|
|
124
|
+
} from "./chunk-STA43FMY.js";
|
|
121
125
|
import {
|
|
122
126
|
FFPROBE_PATH_ENV,
|
|
123
127
|
findFfBinary
|
|
@@ -138,7 +142,7 @@ import {
|
|
|
138
142
|
simple
|
|
139
143
|
} from "./chunk-2PSPARWP.js";
|
|
140
144
|
|
|
141
|
-
// ../studio-server/dist/chunk-
|
|
145
|
+
// ../studio-server/dist/chunk-DG2VOIGR.js
|
|
142
146
|
import { createHash } from "crypto";
|
|
143
147
|
import { closeSync, constants, fstatSync, openSync, readFileSync, writeFileSync } from "fs";
|
|
144
148
|
import { dirname, join } from "path";
|
|
@@ -222,7 +226,7 @@ function stampFileHfIds(filePath) {
|
|
|
222
226
|
}
|
|
223
227
|
}
|
|
224
228
|
|
|
225
|
-
// ../studio-server/dist/chunk-
|
|
229
|
+
// ../studio-server/dist/chunk-K3H6HTVC.js
|
|
226
230
|
import { randomUUID as randomUUID6 } from "crypto";
|
|
227
231
|
import { mkdir as mkdir2, readdir as readdir3, rm as rm3, rmdir, writeFile } from "fs/promises";
|
|
228
232
|
import {
|
|
@@ -1963,7 +1967,7 @@ function clearElementScreenshotIsolation() {
|
|
|
1963
1967
|
page.__hfThumbnailFaded = [];
|
|
1964
1968
|
}
|
|
1965
1969
|
|
|
1966
|
-
// ../studio-server/dist/chunk-
|
|
1970
|
+
// ../studio-server/dist/chunk-G7FEKQ32.js
|
|
1967
1971
|
import { resolve as resolve4 } from "path";
|
|
1968
1972
|
function isAutoProxyEnabled(adapter) {
|
|
1969
1973
|
return adapter.autoProxy !== false;
|
|
@@ -2008,193 +2012,6 @@ async function injectMediaCodecMap(html, adapter, projectDir, compSrcPath, probe
|
|
|
2008
2012
|
return injectMediaCodecMapIntoHtml(html, projectDir, [{ html, compSrcPath }], probeCache);
|
|
2009
2013
|
}
|
|
2010
2014
|
|
|
2011
|
-
// ../studio-server/dist/chunk-4ETS2LXI.js
|
|
2012
|
-
var STUDIO_MOTION_PATH = ".hyperframes/studio-motion.json";
|
|
2013
|
-
function hasStudioMotionEntries(manifestContent) {
|
|
2014
|
-
try {
|
|
2015
|
-
const parsed = JSON.parse(manifestContent);
|
|
2016
|
-
return Array.isArray(parsed.motions) && parsed.motions.length > 0;
|
|
2017
|
-
} catch {
|
|
2018
|
-
return false;
|
|
2019
|
-
}
|
|
2020
|
-
}
|
|
2021
|
-
function createStudioMotionRenderBodyScript(manifestContent, options = {}) {
|
|
2022
|
-
if (!manifestContent.trim() || !hasStudioMotionEntries(manifestContent)) return null;
|
|
2023
|
-
return `(${studioMotionRenderRuntime.toString()})(${JSON.stringify(manifestContent)}, ${JSON.stringify(options.activeCompositionPath ?? null)});`;
|
|
2024
|
-
}
|
|
2025
|
-
function studioMotionRenderRuntime(manifestContent, activeCompositionPath) {
|
|
2026
|
-
const STUDIO_MOTION_TIMELINE_ID = "studio-motion";
|
|
2027
|
-
const STUDIO_MOTION_ATTR = "data-hf-studio-motion";
|
|
2028
|
-
const ORIGINAL_TRANSFORM_ATTR = "data-hf-studio-motion-original-transform";
|
|
2029
|
-
const ORIGINAL_OPACITY_ATTR = "data-hf-studio-motion-original-opacity";
|
|
2030
|
-
const ORIGINAL_VISIBILITY_ATTR = "data-hf-studio-motion-original-visibility";
|
|
2031
|
-
const objectRecord = (value) => value && typeof value === "object" ? value : null;
|
|
2032
|
-
const finiteNumber = (value) => typeof value === "number" && Number.isFinite(value) ? value : null;
|
|
2033
|
-
const runtimeWindow = window;
|
|
2034
|
-
const parseMotionValues = (value) => {
|
|
2035
|
-
const record = objectRecord(value);
|
|
2036
|
-
if (!record) return null;
|
|
2037
|
-
const parsed = {};
|
|
2038
|
-
for (const key of ["x", "y", "scale", "rotation", "opacity", "autoAlpha"]) {
|
|
2039
|
-
const next = finiteNumber(record[key]);
|
|
2040
|
-
if (next != null) parsed[key] = next;
|
|
2041
|
-
}
|
|
2042
|
-
return Object.keys(parsed).length > 0 ? parsed : null;
|
|
2043
|
-
};
|
|
2044
|
-
const parseCustomEase = (value) => {
|
|
2045
|
-
const record = objectRecord(value);
|
|
2046
|
-
if (!record) return null;
|
|
2047
|
-
const id = typeof record.id === "string" ? record.id.trim() : "";
|
|
2048
|
-
const data = typeof record.data === "string" ? record.data.trim() : "";
|
|
2049
|
-
if (!id || !data) return null;
|
|
2050
|
-
return { id, data };
|
|
2051
|
-
};
|
|
2052
|
-
const parsedManifest = (() => {
|
|
2053
|
-
try {
|
|
2054
|
-
return objectRecord(JSON.parse(manifestContent));
|
|
2055
|
-
} catch {
|
|
2056
|
-
return null;
|
|
2057
|
-
}
|
|
2058
|
-
})();
|
|
2059
|
-
const manifestMotions = Array.isArray(parsedManifest?.motions) ? parsedManifest.motions : [];
|
|
2060
|
-
const sourceFileForElement = (element) => {
|
|
2061
|
-
let current = element;
|
|
2062
|
-
while (current) {
|
|
2063
|
-
const sourceFile = current.getAttribute("data-composition-file") ?? current.getAttribute("data-composition-src");
|
|
2064
|
-
if (sourceFile) return sourceFile;
|
|
2065
|
-
current = current.parentElement;
|
|
2066
|
-
}
|
|
2067
|
-
return activeCompositionPath ?? "index.html";
|
|
2068
|
-
};
|
|
2069
|
-
const elementMatchesSourceFile = (element, sourceFile) => sourceFileForElement(element) === sourceFile;
|
|
2070
|
-
const isHTMLElement2 = (element) => element instanceof HTMLElement;
|
|
2071
|
-
const querySelectorCandidates = (selector) => {
|
|
2072
|
-
const className = selector.match(/^\.([A-Za-z0-9_-]+)$/)?.[1];
|
|
2073
|
-
if (className) {
|
|
2074
|
-
return Array.from(document.getElementsByTagName("*")).filter(
|
|
2075
|
-
(element) => isHTMLElement2(element) && element.classList.contains(className)
|
|
2076
|
-
);
|
|
2077
|
-
}
|
|
2078
|
-
if (/^[A-Za-z][A-Za-z0-9-]*$/.test(selector)) {
|
|
2079
|
-
return Array.from(document.getElementsByTagName(selector)).filter(isHTMLElement2);
|
|
2080
|
-
}
|
|
2081
|
-
return Array.from(document.querySelectorAll(selector)).filter(isHTMLElement2);
|
|
2082
|
-
};
|
|
2083
|
-
const resolveTarget = (targetRecord) => {
|
|
2084
|
-
const sourceFile = typeof targetRecord.sourceFile === "string" ? targetRecord.sourceFile : "";
|
|
2085
|
-
if (!sourceFile) return null;
|
|
2086
|
-
const id = typeof targetRecord.id === "string" ? targetRecord.id : "";
|
|
2087
|
-
if (id) {
|
|
2088
|
-
const byId = document.getElementById(id);
|
|
2089
|
-
if (isHTMLElement2(byId) && elementMatchesSourceFile(byId, sourceFile)) return byId;
|
|
2090
|
-
}
|
|
2091
|
-
const selector = typeof targetRecord.selector === "string" ? targetRecord.selector : "";
|
|
2092
|
-
if (!selector) return null;
|
|
2093
|
-
try {
|
|
2094
|
-
const selectorIndex = Math.max(0, Math.floor(finiteNumber(targetRecord.selectorIndex) ?? 0));
|
|
2095
|
-
return querySelectorCandidates(selector).filter(
|
|
2096
|
-
(element) => elementMatchesSourceFile(element, sourceFile)
|
|
2097
|
-
)[selectorIndex] ?? null;
|
|
2098
|
-
} catch {
|
|
2099
|
-
return null;
|
|
2100
|
-
}
|
|
2101
|
-
};
|
|
2102
|
-
const restoreElement = (element) => {
|
|
2103
|
-
runtimeWindow.gsap?.set?.(element, { clearProps: "transform,opacity,visibility" });
|
|
2104
|
-
element.style.transform = element.getAttribute(ORIGINAL_TRANSFORM_ATTR) ?? "";
|
|
2105
|
-
element.style.opacity = element.getAttribute(ORIGINAL_OPACITY_ATTR) ?? "";
|
|
2106
|
-
element.style.visibility = element.getAttribute(ORIGINAL_VISIBILITY_ATTR) ?? "";
|
|
2107
|
-
element.removeAttribute(STUDIO_MOTION_ATTR);
|
|
2108
|
-
element.removeAttribute(ORIGINAL_TRANSFORM_ATTR);
|
|
2109
|
-
element.removeAttribute(ORIGINAL_OPACITY_ATTR);
|
|
2110
|
-
element.removeAttribute(ORIGINAL_VISIBILITY_ATTR);
|
|
2111
|
-
};
|
|
2112
|
-
const restoreStudioMotionElements = () => {
|
|
2113
|
-
for (const element of Array.from(document.querySelectorAll(`[${STUDIO_MOTION_ATTR}]`))) {
|
|
2114
|
-
if (isHTMLElement2(element)) restoreElement(element);
|
|
2115
|
-
}
|
|
2116
|
-
};
|
|
2117
|
-
const readCurrentTime = () => {
|
|
2118
|
-
try {
|
|
2119
|
-
const playerTime = runtimeWindow.__player?.getTime?.();
|
|
2120
|
-
if (typeof playerTime === "number" && Number.isFinite(playerTime)) {
|
|
2121
|
-
return Math.max(0, playerTime);
|
|
2122
|
-
}
|
|
2123
|
-
} catch {
|
|
2124
|
-
}
|
|
2125
|
-
try {
|
|
2126
|
-
const timelineTime = runtimeWindow.__timeline?.time?.();
|
|
2127
|
-
if (typeof timelineTime === "number" && Number.isFinite(timelineTime)) {
|
|
2128
|
-
return Math.max(0, timelineTime);
|
|
2129
|
-
}
|
|
2130
|
-
} catch {
|
|
2131
|
-
}
|
|
2132
|
-
return 0;
|
|
2133
|
-
};
|
|
2134
|
-
const resolveEase = (motion) => {
|
|
2135
|
-
const fallback = typeof motion.ease === "string" && motion.ease.trim() ? motion.ease.trim() : "none";
|
|
2136
|
-
const customEase = parseCustomEase(motion.customEase);
|
|
2137
|
-
const customEasePlugin = runtimeWindow.CustomEase;
|
|
2138
|
-
if (!customEase || typeof customEasePlugin?.create !== "function") return fallback;
|
|
2139
|
-
try {
|
|
2140
|
-
runtimeWindow.gsap?.registerPlugin?.(customEasePlugin);
|
|
2141
|
-
customEasePlugin.create(customEase.id, customEase.data);
|
|
2142
|
-
return customEase.id;
|
|
2143
|
-
} catch {
|
|
2144
|
-
return fallback;
|
|
2145
|
-
}
|
|
2146
|
-
};
|
|
2147
|
-
const applyManifest = () => {
|
|
2148
|
-
runtimeWindow.__timelines = runtimeWindow.__timelines ?? {};
|
|
2149
|
-
runtimeWindow.__timelines[STUDIO_MOTION_TIMELINE_ID]?.kill?.();
|
|
2150
|
-
delete runtimeWindow.__timelines[STUDIO_MOTION_TIMELINE_ID];
|
|
2151
|
-
restoreStudioMotionElements();
|
|
2152
|
-
const gsap = runtimeWindow.gsap;
|
|
2153
|
-
if (!gsap?.timeline || manifestMotions.length === 0) return 0;
|
|
2154
|
-
const timeline = gsap.timeline({ paused: true, defaults: { overwrite: "auto" } });
|
|
2155
|
-
let applied = 0;
|
|
2156
|
-
for (const motionValue of manifestMotions) {
|
|
2157
|
-
const motion = objectRecord(motionValue);
|
|
2158
|
-
if (!motion || motion.kind !== "gsap-motion") continue;
|
|
2159
|
-
const targetRecord = objectRecord(motion.target);
|
|
2160
|
-
if (!targetRecord) continue;
|
|
2161
|
-
const target = resolveTarget(targetRecord);
|
|
2162
|
-
if (!target || typeof timeline.fromTo !== "function") continue;
|
|
2163
|
-
const start = finiteNumber(motion.start);
|
|
2164
|
-
const duration = finiteNumber(motion.duration);
|
|
2165
|
-
if (start == null || duration == null || start < 0 || duration <= 0) continue;
|
|
2166
|
-
const from = parseMotionValues(motion.from);
|
|
2167
|
-
const to = parseMotionValues(motion.to);
|
|
2168
|
-
if (!from || !to) continue;
|
|
2169
|
-
if (!target.hasAttribute(STUDIO_MOTION_ATTR)) {
|
|
2170
|
-
target.setAttribute(ORIGINAL_TRANSFORM_ATTR, target.style.transform);
|
|
2171
|
-
target.setAttribute(ORIGINAL_OPACITY_ATTR, target.style.opacity);
|
|
2172
|
-
target.setAttribute(ORIGINAL_VISIBILITY_ATTR, target.style.visibility);
|
|
2173
|
-
}
|
|
2174
|
-
target.setAttribute(STUDIO_MOTION_ATTR, "true");
|
|
2175
|
-
timeline.fromTo(
|
|
2176
|
-
target,
|
|
2177
|
-
from,
|
|
2178
|
-
{ ...to, duration, ease: resolveEase(motion), overwrite: "auto", immediateRender: false },
|
|
2179
|
-
start
|
|
2180
|
-
);
|
|
2181
|
-
applied += 1;
|
|
2182
|
-
}
|
|
2183
|
-
if (applied === 0) {
|
|
2184
|
-
timeline.kill?.();
|
|
2185
|
-
return 0;
|
|
2186
|
-
}
|
|
2187
|
-
runtimeWindow.__timelines[STUDIO_MOTION_TIMELINE_ID] = timeline;
|
|
2188
|
-
timeline.pause?.();
|
|
2189
|
-
const currentTime = readCurrentTime();
|
|
2190
|
-
if (typeof timeline.totalTime === "function") timeline.totalTime(currentTime, false);
|
|
2191
|
-
else timeline.time?.(currentTime);
|
|
2192
|
-
return applied;
|
|
2193
|
-
};
|
|
2194
|
-
runtimeWindow.__hfStudioMotionApply = applyManifest;
|
|
2195
|
-
applyManifest();
|
|
2196
|
-
}
|
|
2197
|
-
|
|
2198
2015
|
// ../studio-server/dist/chunk-X62ASOGO.js
|
|
2199
2016
|
function findUnsafeMutationValues(value, path = "body", options = {}) {
|
|
2200
2017
|
if (value === null) {
|
|
@@ -2352,7 +2169,7 @@ function holdScope(before, previous) {
|
|
|
2352
2169
|
held.set(a.targetSelector, props);
|
|
2353
2170
|
}
|
|
2354
2171
|
return {
|
|
2355
|
-
touched: (a) => previous
|
|
2172
|
+
touched: (a) => previous === null || !kept.has(tweenSignature(a)),
|
|
2356
2173
|
held: (selector) => held.get(selector) ?? /* @__PURE__ */ new Map()
|
|
2357
2174
|
};
|
|
2358
2175
|
}
|
|
@@ -2370,7 +2187,8 @@ function keyframeHoldForAnimation(animation, animations, scope) {
|
|
|
2370
2187
|
const touched = scope.touched(animation);
|
|
2371
2188
|
const pinned = scope.held(animation.targetSelector);
|
|
2372
2189
|
const kept = (property, value) => touched ? pinned.has(property) : pinned.get(property) === value;
|
|
2373
|
-
const
|
|
2190
|
+
const startsLate = start > 1e-3;
|
|
2191
|
+
const pins = (group, property, value) => (group === "position" || group === "size") && ((lone || group === "position" && startsLate) && touched || kept(property, value));
|
|
2374
2192
|
const hold = {};
|
|
2375
2193
|
for (const [property, value] of Object.entries(atStart.properties)) {
|
|
2376
2194
|
if (!pins(classifyPropertyGroup2(property), property, value) || typeof value !== "number")
|
|
@@ -5439,6 +5257,7 @@ import { createHash as createHash23 } from "crypto";
|
|
|
5439
5257
|
// ../core/dist/studioPreviewMark.js
|
|
5440
5258
|
var STUDIO_PREVIEW_MARK_META = "hyperframes-studio-preview";
|
|
5441
5259
|
var STUDIO_PREVIEW_LAZY_ATTR = "data-hf-preview-lazy";
|
|
5260
|
+
var STUDIO_PREVIEW_ERRORS = "__hfPreviewErrors";
|
|
5442
5261
|
|
|
5443
5262
|
// ../studio-server/dist/index.js
|
|
5444
5263
|
import { readlinkSync as readlinkSync2 } from "fs";
|
|
@@ -5446,7 +5265,7 @@ import { dirname as dirname42, join as join7, parse as parse2, relative as relat
|
|
|
5446
5265
|
import { readFileSync as readFileSync72 } from "fs";
|
|
5447
5266
|
import { join as join9 } from "path";
|
|
5448
5267
|
import { streamSSE } from "hono/streaming";
|
|
5449
|
-
import { existsSync as existsSync6, readFileSync as readFileSync8, unlinkSync as unlinkSync3, readdirSync as readdirSync32, statSync as statSync5 } from "fs";
|
|
5268
|
+
import { existsSync as existsSync6, lstatSync as lstatSync32, readFileSync as readFileSync8, unlinkSync as unlinkSync3, readdirSync as readdirSync32, statSync as statSync5 } from "fs";
|
|
5450
5269
|
import { join as join10 } from "path";
|
|
5451
5270
|
import { HTTPException } from "hono/http-exception";
|
|
5452
5271
|
import { open, stat as stat2 } from "fs/promises";
|
|
@@ -5522,7 +5341,7 @@ function registerProjectRoutes(api, adapter) {
|
|
|
5522
5341
|
api.get("/projects/:id", async (c) => {
|
|
5523
5342
|
const project = await adapter.resolveProject(c.req.param("id"));
|
|
5524
5343
|
if (!project) return c.json({ error: "not found" }, 404);
|
|
5525
|
-
const files = walkDir(project.dir);
|
|
5344
|
+
const files = walkDir(project.dir).filter((file) => !isPrivateProjectPath(file));
|
|
5526
5345
|
const compositions = await filterCompositionFiles(project.dir, files);
|
|
5527
5346
|
return c.json({ id: project.id, dir: project.dir, title: project.title, files, compositions });
|
|
5528
5347
|
});
|
|
@@ -6436,7 +6255,7 @@ function requestSubPath(url, route) {
|
|
|
6436
6255
|
return decodeURIComponent(segments.slice(start + routeSegments.length).join("/"));
|
|
6437
6256
|
}
|
|
6438
6257
|
async function loadGsapParser() {
|
|
6439
|
-
return import("./gsapParser-
|
|
6258
|
+
return import("./gsapParser-UP3PNPC2.js");
|
|
6440
6259
|
}
|
|
6441
6260
|
function isDanglingSymlinkInProject(projectDir, lexicalPath) {
|
|
6442
6261
|
if (!isSafePath(projectDir, dirname32(lexicalPath))) return false;
|
|
@@ -6805,7 +6624,7 @@ function updateReferences(projectDir, oldPath, newPath, isDirectory) {
|
|
|
6805
6624
|
const rewrite = referenceRewriter(oldPath, newPath, isDirectory, projectPaths(projectDir));
|
|
6806
6625
|
let updatedCount = 0;
|
|
6807
6626
|
for (const file of textFiles) {
|
|
6808
|
-
if (!isSafePath(projectDir, file)) continue;
|
|
6627
|
+
if (!isSafePath(projectDir, file) || isPrivateProjectFile(projectDir, file)) continue;
|
|
6809
6628
|
const content = readableText(file);
|
|
6810
6629
|
if (content === null) continue;
|
|
6811
6630
|
const updated = rewrite(content);
|
|
@@ -7097,7 +6916,7 @@ async function prepareGsapMutationScript(c, res, firstMutation) {
|
|
|
7097
6916
|
let block = extractGsapScriptBlock(html);
|
|
7098
6917
|
if (!block && (firstMutation.type === "add" || firstMutation.type === "add-with-keyframes")) {
|
|
7099
6918
|
const compId = html.match(/data-composition-id="([^"]+)"/)?.[1] ?? "main";
|
|
7100
|
-
const { GSAP_CDN } = await import("./dist-
|
|
6919
|
+
const { GSAP_CDN } = await import("./dist-4JZWRWS6.js");
|
|
7101
6920
|
const bootstrap = [
|
|
7102
6921
|
`<script src="${GSAP_CDN}"></script>`,
|
|
7103
6922
|
"<script>",
|
|
@@ -7155,7 +6974,7 @@ function clipRetimeOf(mutation) {
|
|
|
7155
6974
|
function retimeRun(script, run, root) {
|
|
7156
6975
|
const live = run.filter((slot) => slot !== "no-op");
|
|
7157
6976
|
const retimed = retimeClipTweensInScript(script, live, root);
|
|
7158
|
-
const synced = syncPositionHoldsBeforeKeyframes(retimed.script);
|
|
6977
|
+
const synced = syncPositionHoldsBeforeKeyframes(retimed.script, script);
|
|
7159
6978
|
let next = 0;
|
|
7160
6979
|
const changed = run.map((slot) => slot !== "no-op" && retimed.changed[next++]);
|
|
7161
6980
|
if (synced !== retimed.script) changed[changed.length - 1] = true;
|
|
@@ -7949,7 +7768,7 @@ async function processUploadedFiles(formData, targetDir, projectDir) {
|
|
|
7949
7768
|
finalName = `${base} (${n})${ext}`;
|
|
7950
7769
|
finalPath = resolve22(targetDir, finalName);
|
|
7951
7770
|
}
|
|
7952
|
-
if (!isSafePath(projectDir, finalPath)) continue;
|
|
7771
|
+
if (!isSafePath(projectDir, finalPath) || isPrivateProjectFile(projectDir, finalPath)) continue;
|
|
7953
7772
|
const buffer = Buffer.from(await value.arrayBuffer());
|
|
7954
7773
|
const validation = validateUploadedMediaBuffer(finalName, buffer);
|
|
7955
7774
|
if (!validation.ok) {
|
|
@@ -9101,15 +8920,17 @@ var GSAP_CDN_FALLBACK_SCRIPT = `<script ${GSAP_FALLBACK_ATTR}>
|
|
|
9101
8920
|
if(loaded[file])return loaded[file];
|
|
9102
8921
|
return loaded[file]=new Promise(function(ok,fail){
|
|
9103
8922
|
var s=document.createElement("script");
|
|
9104
|
-
s.src=cdnBase+file;s.onload=ok;s.onerror=fail;
|
|
8923
|
+
s.src=cdnBase+file;s.hfGsapFallback=true;s.onload=ok;s.onerror=fail;
|
|
9105
8924
|
document.head.appendChild(s);
|
|
9106
8925
|
});
|
|
9107
8926
|
}
|
|
9108
8927
|
document.addEventListener("error",function(e){
|
|
9109
8928
|
var t=e.target;
|
|
9110
|
-
if(!t||t.tagName!=="SCRIPT"||!t.src)return;
|
|
8929
|
+
if(!t||t.tagName!=="SCRIPT"||!t.src||t.hfGsapFallback)return;
|
|
9111
8930
|
var m=t.src.match(/gsap[^/]*\\/dist\\/(.+\\.js)/);
|
|
9112
|
-
if(m)loadFallback(m[1])
|
|
8931
|
+
if(m)loadFallback(m[1]).catch(function(){
|
|
8932
|
+
reportError(new Error("GSAP could not load from "+t.src+" or "+cdnBase+m[1]+", so this preview's animations will not play."));
|
|
8933
|
+
});
|
|
9113
8934
|
},true);
|
|
9114
8935
|
})();
|
|
9115
8936
|
</script>`;
|
|
@@ -9141,8 +8962,13 @@ function previewVariablesFromRequest(rawVariables) {
|
|
|
9141
8962
|
return { raw: rawVariables, values: parse22.values };
|
|
9142
8963
|
}
|
|
9143
8964
|
var PREVIEW_CAPTURE_PARAM = "hf-capture";
|
|
8965
|
+
var EARLY_ERRORS_SCRIPT = `<script>(function(){var seen=window.${STUDIO_PREVIEW_ERRORS}=[];
|
|
8966
|
+
addEventListener("error",function(e){seen.push(e.message||String(e))});})();</script>`;
|
|
9144
8967
|
function injectStudioPreviewAugmentations(html, adapter, projectDir, activeCompositionPath, capture) {
|
|
9145
|
-
const marked = capture ? html : injectTagsAtHeadStart(
|
|
8968
|
+
const marked = capture ? html : injectTagsAtHeadStart(
|
|
8969
|
+
lazyPreviewImages(html),
|
|
8970
|
+
`<meta name="${STUDIO_PREVIEW_MARK_META}">${EARLY_ERRORS_SCRIPT}`
|
|
8971
|
+
);
|
|
9146
8972
|
return injectStudioMotionScript(
|
|
9147
8973
|
injectMotionPathPluginIfNeeded(
|
|
9148
8974
|
injectGsapCdnFallback(
|
|
@@ -9363,7 +9189,7 @@ ${etag}`;
|
|
|
9363
9189
|
const subPath = requestSubPath(c.req.url, "projects/:id/preview");
|
|
9364
9190
|
const candidate = resolve42(project.dir, subPath);
|
|
9365
9191
|
const file = isWithinProjectRoot(project.dir, candidate) ? candidate : null;
|
|
9366
|
-
if (!file) {
|
|
9192
|
+
if (!file || isPrivateProjectFile(project.dir, file)) {
|
|
9367
9193
|
return c.text("not found", 404);
|
|
9368
9194
|
}
|
|
9369
9195
|
recordPreviewRead(project.dir, file);
|
|
@@ -9634,6 +9460,13 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9634
9460
|
".mov": "video/quicktime"
|
|
9635
9461
|
};
|
|
9636
9462
|
const RENDER_EXTENSIONS = Object.keys(RENDER_MIME);
|
|
9463
|
+
const isPlainFile = (path) => {
|
|
9464
|
+
try {
|
|
9465
|
+
return lstatSync32(path).isFile();
|
|
9466
|
+
} catch {
|
|
9467
|
+
return false;
|
|
9468
|
+
}
|
|
9469
|
+
};
|
|
9637
9470
|
function renderContentType(filePath) {
|
|
9638
9471
|
const ext = RENDER_EXTENSIONS.find((e) => filePath.endsWith(e));
|
|
9639
9472
|
return (ext && RENDER_MIME[ext]) ?? "video/mp4";
|
|
@@ -9641,7 +9474,7 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9641
9474
|
api.get("/render/:jobId/view", (c) => {
|
|
9642
9475
|
const { jobId } = c.req.param();
|
|
9643
9476
|
const job = renderJobs.get(jobId);
|
|
9644
|
-
if (!job?.outputPath || !
|
|
9477
|
+
if (!job?.outputPath || !isPlainFile(job.outputPath)) {
|
|
9645
9478
|
return c.json({ error: "not found" }, 404);
|
|
9646
9479
|
}
|
|
9647
9480
|
const contentType = renderContentType(job.outputPath);
|
|
@@ -9659,7 +9492,7 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9659
9492
|
api.get("/render/:jobId/download", (c) => {
|
|
9660
9493
|
const { jobId } = c.req.param();
|
|
9661
9494
|
const job = renderJobs.get(jobId);
|
|
9662
|
-
if (!job?.outputPath || !
|
|
9495
|
+
if (!job?.outputPath || !isPlainFile(job.outputPath)) {
|
|
9663
9496
|
return c.json({ error: "not found" }, 404);
|
|
9664
9497
|
}
|
|
9665
9498
|
const contentType = renderContentType(job.outputPath);
|
|
@@ -9694,7 +9527,7 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9694
9527
|
if (!filename) return c.json({ error: "missing filename" }, 400);
|
|
9695
9528
|
const rendersDir = adapter.rendersDir(project);
|
|
9696
9529
|
const fp = resolveWithinProject(rendersDir, filename);
|
|
9697
|
-
if (!fp) return c.json({ error: "forbidden" }, 403);
|
|
9530
|
+
if (!fp || isPrivateProjectFile(project.dir, fp)) return c.json({ error: "forbidden" }, 403);
|
|
9698
9531
|
if (!existsSync6(fp)) return c.json({ error: "not found" }, 404);
|
|
9699
9532
|
const contentType = renderContentType(fp);
|
|
9700
9533
|
const content = readFileSync8(fp);
|
|
@@ -9712,8 +9545,10 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9712
9545
|
if (!project) return c.json({ error: "not found" }, 404);
|
|
9713
9546
|
const rendersDir = adapter.rendersDir(project);
|
|
9714
9547
|
if (!existsSync6(rendersDir)) return c.json({ renders: [] });
|
|
9715
|
-
const files = readdirSync32(rendersDir).filter((f) => f.endsWith(".mp4") || f.endsWith(".webm") || f.endsWith(".mov")).
|
|
9716
|
-
const fp =
|
|
9548
|
+
const files = readdirSync32(rendersDir).filter((f) => f.endsWith(".mp4") || f.endsWith(".webm") || f.endsWith(".mov")).flatMap((f) => {
|
|
9549
|
+
const fp = resolveWithinProject(rendersDir, f);
|
|
9550
|
+
return fp && !isPrivateProjectFile(project.dir, fp) ? [{ f, fp }] : [];
|
|
9551
|
+
}).map(({ f, fp }) => {
|
|
9717
9552
|
const stat22 = statSync5(fp);
|
|
9718
9553
|
const rid = f.replace(/\.(mp4|webm|mov)$/, "");
|
|
9719
9554
|
const metaPath = join10(rendersDir, `${rid}.meta.json`);
|
|
@@ -9732,6 +9567,7 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9732
9567
|
return {
|
|
9733
9568
|
id: rid,
|
|
9734
9569
|
filename: f,
|
|
9570
|
+
path: fp,
|
|
9735
9571
|
size: stat22.size,
|
|
9736
9572
|
createdAt: stat22.mtimeMs,
|
|
9737
9573
|
status,
|
|
@@ -9745,12 +9581,12 @@ function registerRenderRoutes(api, adapter) {
|
|
|
9745
9581
|
id: file.id,
|
|
9746
9582
|
status: file.status,
|
|
9747
9583
|
progress: 100,
|
|
9748
|
-
outputPath:
|
|
9584
|
+
outputPath: file.path,
|
|
9749
9585
|
createdAt: file.createdAt
|
|
9750
9586
|
});
|
|
9751
9587
|
}
|
|
9752
9588
|
}
|
|
9753
|
-
return c.json({ renders: files });
|
|
9589
|
+
return c.json({ renders: files.map(({ path: _path, ...render }) => render) });
|
|
9754
9590
|
});
|
|
9755
9591
|
}
|
|
9756
9592
|
var ThumbnailGenerationCoordinator = class {
|
|
@@ -11527,8 +11363,6 @@ export {
|
|
|
11527
11363
|
getElementScreenshotClip,
|
|
11528
11364
|
clearElementScreenshotIsolation,
|
|
11529
11365
|
injectMediaCodecMapIntoHtml,
|
|
11530
|
-
STUDIO_MOTION_PATH,
|
|
11531
|
-
createStudioMotionRenderBodyScript,
|
|
11532
11366
|
MIME_TYPES,
|
|
11533
11367
|
getMimeType,
|
|
11534
11368
|
buildSubCompositionHtml,
|