hyperframes 0.8.193 → 0.8.195
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-JC6DKZKC.js → add-NL6XABRV.js} +12 -12
- package/dist/{animatedGifPrep-S6KXJGEL.js → animatedGifPrep-JD4BBM2L.js} +8 -7
- package/dist/api.js +18 -17
- package/dist/{asset-XITFIFE6.js → asset-LRRHLG4L.js} +2 -2
- package/dist/{assetCataloger-K5FNKG35.js → assetCataloger-D7KGO346.js} +8 -7
- package/dist/{audio-364UHTY4.js → audio-34CZM4HF.js} +14 -13
- package/dist/{auth-5JEESRE6.js → auth-FL5ZMOXB.js} +1 -1
- package/dist/{autoUpdate-RVVYEHAA.js → autoUpdate-FZTJFLIH.js} +2 -2
- package/dist/{backgroundChecks-DCBIYWIQ.js → backgroundChecks-6ZKDCQET.js} +3 -3
- package/dist/backgroundChecksWorker.js +3 -3
- package/dist/{batchRender-ZZ4QMBAA.js → batchRender-KDZ4F4QT.js} +4 -4
- package/dist/{beats-YEL65M6G.js → beats-7PK677VR.js} +9 -9
- package/dist/{benchmark-RBTRPA76.js → benchmark-LO36QH5D.js} +9 -9
- package/dist/{browser-BVAYXT4R.js → browser-3F7NDHU2.js} +5 -5
- package/dist/{bundleWithLocalizedFonts-JLB2OYMT.js → bundleWithLocalizedFonts-JL5J52L6.js} +2 -2
- package/dist/{capture-GBXTMYLZ.js → capture-DOP3ONNZ.js} +13 -12
- package/dist/{capture-NIFX6IRS.js → capture-JOSZZYUW.js} +2 -2
- package/dist/{captureCompositionFrame-ATNNKUL5.js → captureCompositionFrame-SWZ4GEJP.js} +13 -12
- package/dist/{catalog-AGIF5SM5.js → catalog-EZLHZMLM.js} +12 -12
- package/dist/{catch-up-SZ3ULDTI.js → catch-up-6B7VY43I.js} +4 -4
- package/dist/{check-YLQS3TF4.js → check-QGELCBBF.js} +38 -37
- package/dist/{checkBrowser-QH4FMCBO.js → checkBrowser-A5C2AB4L.js} +33 -32
- package/dist/{chunk-L5YLA54L.js → chunk-2G6JZJAV.js} +2 -2
- package/dist/{chunk-M3KZBDPB.js → chunk-2HSRLKZR.js} +3 -3
- package/dist/{chunk-FBVUAH7N.js → chunk-2OYYNKJ4.js} +1 -1
- package/dist/{chunk-2VXY3PEF.js → chunk-2TU4OKIR.js} +280 -114
- package/dist/{chunk-4PPWAQYV.js → chunk-3OAFRLD3.js} +7 -7
- package/dist/{chunk-ZT45TCY3.js → chunk-3PYIQLPL.js} +1 -1
- package/dist/{chunk-DYNHVCBF.js → chunk-4R2NWLQL.js} +2 -2
- package/dist/{chunk-SOY2FPOR.js → chunk-636WBDXB.js} +5 -5
- package/dist/{chunk-LFUVTS6V.js → chunk-66Q27H72.js} +2 -2
- package/dist/{chunk-MFUNDJEV.js → chunk-6ORTRIDW.js} +3 -3
- package/dist/{chunk-D625D4TV.js → chunk-7DFIVUOW.js} +6 -6
- package/dist/{chunk-ZH7J2ZUL.js → chunk-7G2LQM3J.js} +14 -14
- package/dist/{chunk-6LWUPIKD.js → chunk-7PXVXRVX.js} +10 -10
- package/dist/{chunk-XQPA4W3M.js → chunk-7Y5RVQQ7.js} +4 -4
- package/dist/{chunk-2MCXIY4B.js → chunk-B7RJV74O.js} +28 -11
- package/dist/{chunk-BJAS2JLW.js → chunk-B7Y2DGU6.js} +7 -3
- package/dist/{chunk-YS4JUGNI.js → chunk-BBXZPDEA.js} +2 -2
- package/dist/{chunk-RWGASWT7.js → chunk-BL4U6U52.js} +1 -0
- package/dist/{chunk-VW63MHQU.js → chunk-CCZMCX3F.js} +1 -1
- package/dist/{chunk-BY6OQ6XP.js → chunk-CZNSLFYD.js} +3 -1
- package/dist/{chunk-X5CECNCK.js → chunk-D6XDOYMB.js} +8 -3
- package/dist/{chunk-F5LLORBP.js → chunk-E527A6RS.js} +2 -2
- package/dist/{chunk-7HTH5PFK.js → chunk-E74JMKSK.js} +58 -8
- package/dist/{chunk-TZEKVLPV.js → chunk-ELQ2QQC5.js} +1 -1
- package/dist/{chunk-4LXZJIVY.js → chunk-ES7KSCSO.js} +10 -10
- package/dist/{chunk-KU3UFQN7.js → chunk-F2ASNL2K.js} +1 -1
- package/dist/{chunk-VLLFORE2.js → chunk-F4T7XYMF.js} +1 -1
- package/dist/{chunk-E3P3LJG6.js → chunk-FLREUEHW.js} +28 -11
- package/dist/{chunk-TY3LDJA3.js → chunk-FWDDLW2H.js} +2 -2
- package/dist/{chunk-7YSFE4SZ.js → chunk-GJG4CTXD.js} +2 -2
- package/dist/{chunk-2NERNYCJ.js → chunk-GKMRLES4.js} +3 -3
- package/dist/{chunk-4TKJWWPL.js → chunk-GOOE33GV.js} +1 -1
- package/dist/{chunk-DIKAPMMF.js → chunk-GQVTTWZF.js} +144 -39
- package/dist/{chunk-L4JB7LI4.js → chunk-HJINEUHY.js} +84 -61
- package/dist/{chunk-7QNIXBQD.js → chunk-HT33OHQL.js} +3 -2
- package/dist/{chunk-AR3DQYRR.js → chunk-HTLCE7M2.js} +18 -18
- package/dist/{chunk-ZTKFRXJB.js → chunk-IA7HZ4CM.js} +4 -4
- package/dist/{chunk-WFS6S65A.js → chunk-IZR7U27Z.js} +12 -12
- package/dist/chunk-K4MJX7SR.js +17 -0
- package/dist/{chunk-ZZPBXRYQ.js → chunk-KJ6ZQL34.js} +1 -1
- package/dist/{chunk-VPC4XIVI.js → chunk-KVLGJJTE.js} +5 -5
- package/dist/{chunk-CGTZOY53.js → chunk-L2EBYFU7.js} +1 -1
- package/dist/{chunk-UNATIAOT.js → chunk-L4BFXWHC.js} +144 -67
- package/dist/{chunk-IW5G323T.js → chunk-LTGTN2TH.js} +8 -9
- package/dist/{chunk-EFXMETRK.js → chunk-NKNRVPNV.js} +2 -2
- package/dist/{chunk-2SFDWMSW.js → chunk-NOHH25WS.js} +2 -2
- package/dist/{chunk-7YKJF5JV.js → chunk-OB4GJZTY.js} +1 -1
- package/dist/{chunk-C4Y3ZREE.js → chunk-OJNNKHAZ.js} +75 -22
- package/dist/{chunk-OFYW4J7Y.js → chunk-ORZMO6NY.js} +3 -3
- package/dist/{chunk-BP4EMEGH.js → chunk-P5X5URNQ.js} +2 -2
- package/dist/{chunk-6XUJVEY2.js → chunk-RAACYYWX.js} +1 -1
- package/dist/{chunk-QFPBRZJD.js → chunk-ROEW726S.js} +1 -1
- package/dist/{chunk-WIVOXGEP.js → chunk-RZUEXJRC.js} +2 -2
- package/dist/{chunk-V7ZA2BNW.js → chunk-SC6NILKD.js} +1 -1
- package/dist/{chunk-2LSCYS2H.js → chunk-SMROKE63.js} +2 -2
- package/dist/{chunk-REUL2KH2.js → chunk-ST35C4K6.js} +1 -1
- package/dist/{chunk-OFV3WSOE.js → chunk-TE6VGYHQ.js} +1 -1
- package/dist/{chunk-3W4B6G7Y.js → chunk-VNWX5GBF.js} +19 -15
- package/dist/{chunk-QKX7ITER.js → chunk-W4SSWOOD.js} +2 -2
- package/dist/{chunk-6DLCOQR4.js → chunk-W7GMPEY3.js} +142 -44
- package/dist/{chunk-UIC7B5KW.js → chunk-WUL5LPI2.js} +12 -2
- package/dist/{chunk-5J6TWLFG.js → chunk-XC7SJ2UR.js} +3 -3
- package/dist/{chunk-E77ALFLW.js → chunk-XOUWCZHD.js} +1 -1
- package/dist/{chunk-GR5DQKDR.js → chunk-YFTO5YD7.js} +5 -5
- package/dist/{chunk-UB7BIDBS.js → chunk-YSXCPSJ4.js} +3 -3
- package/dist/{chunk-GKHMSSGY.js → chunk-YUFECVHG.js} +1 -1
- package/dist/{chunk-LMNZLZMJ.js → chunk-ZAVUASNT.js} +1 -1
- package/dist/{chunk-RTLPWOO6.js → chunk-ZL6ZCLY6.js} +1 -1
- package/dist/{chunk-DSQ72G5I.js → chunk-ZOJHEN3C.js} +1 -1
- package/dist/chunk-ZQRD62QZ.js +3901 -0
- package/dist/{clean-5HGESK5A.js → clean-PI4JLT6O.js} +21 -20
- package/dist/cli.js +53 -53
- package/dist/{cloud-746PHS32.js → cloud-SQRY723M.js} +4 -4
- package/dist/{cloudrun-DO7WFLSM.js → cloudrun-VMPROR43.js} +6 -6
- package/dist/commands/layout-audit.browser.js +1 -1
- package/dist/{compare-66YPRNG2.js → compare-EHX4APTP.js} +31 -30
- package/dist/{compiler-R4UYDWXO.js → compiler-FZCJGGBF.js} +5 -5
- package/dist/{component-EQ3H6RFP.js → component-I75ZKJYH.js} +3 -3
- package/dist/{compositions-ZZ7P5HT2.js → compositions-YNYYUEQD.js} +12 -11
- package/dist/{contactSheet-SZBJDOMT.js → contactSheet-5APX35L3.js} +1 -1
- package/dist/{delete-Z5MSLJSR.js → delete-7BVTBKOC.js} +2 -2
- package/dist/{deploy-RGSAC2K5.js → deploy-TUEEJP3W.js} +1 -1
- package/dist/{deterministicFonts-RO2TCMLZ.js → deterministicFonts-RADD3BSX.js} +2 -2
- package/dist/{dist-QQ26RUDV.js → dist-VRGIE57H.js} +1 -1
- package/dist/{dist-RKK4YLAD.js → dist-VVROHSP4.js} +3 -3
- package/dist/{doctor-W4ZZDRTU.js → doctor-53DSQFW4.js} +14 -13
- package/dist/{events-BSSL4A4W.js → events-AD3U6E7I.js} +2 -2
- package/dist/{events-UACT7PX3.js → events-M6FIUDNQ.js} +3 -3
- package/dist/{feedback-47ILDLQG.js → feedback-7SQ7KKAR.js} +8 -8
- package/dist/{ffmpeg-IEHSUNUT.js → ffmpeg-3HSSPXS4.js} +9 -8
- package/dist/{figma-PLFIIYRU.js → figma-B5XII2BO.js} +3 -3
- package/dist/fontLocalizeCli.js +11 -10
- package/dist/{get-PDWGJYNL.js → get-RZKNBIRD.js} +2 -2
- package/dist/{gpuPolicy-6UBXO6ME.js → gpuPolicy-77LOK3K6.js} +8 -7
- package/dist/{grade-compare-5VWLQGM7.js → grade-compare-K3YB3FQA.js} +37 -35
- package/dist/{gsapParser-UP3PNPC2.js → gsapParser-IEUSLYDJ.js} +11 -11
- package/dist/{gsapParserAcorn-OOTY2MVN.js → gsapParserAcorn-LZJKCFQI.js} +1 -1
- package/dist/{help-DS3KMWYO.js → help-UM6INVL5.js} +1 -1
- package/dist/{history-OC326NVZ.js → history-EWKPACWR.js} +7 -7
- package/dist/hyperframe.manifest.json +1 -1
- package/dist/hyperframe.runtime.iife.js +72 -66
- package/dist/hyperframes-player.global.js +3 -3
- package/dist/hyperframes-slideshow.global.js +1 -1
- package/dist/{info-AUIFV6MX.js → info-KY3MFTCY.js} +8 -8
- package/dist/{init-MRTWWDFW.js → init-LURF2PL5.js} +30 -29
- package/dist/{inspect-55NOAXI2.js → inspect-46CZJM6P.js} +31 -30
- package/dist/{installer-YSFFGBBV.js → installer-NGFX6INI.js} +5 -5
- package/dist/{keyframes-OO2BX2IB.js → keyframes-YCSK6POI.js} +59 -33
- package/dist/{lambda-CXXY6QT3.js → lambda-5KXULI2S.js} +8 -8
- package/dist/{layout-57GJXKDK.js → layout-WOLH24YE.js} +31 -30
- package/dist/{lint-J4FK3Z6G.js → lint-P3P2LX6S.js} +7 -7
- package/dist/{lintProject-52SLJPRC.js → lintProject-ESAJKFOX.js} +1 -1
- package/dist/{list-VDQUJ76B.js → list-RUYQWMF2.js} +2 -2
- package/dist/{login-TJSEALWW.js → login-THBBWZAY.js} +4 -4
- package/dist/{manager-MZIJY73J.js → manager-COSJVRAE.js} +2 -2
- package/dist/{manager-4PLYEEWP.js → manager-V34BMSAG.js} +10 -9
- package/dist/{media-treatment-GXP4PMJH.js → media-treatment-IMBLTYGV.js} +15 -14
- package/dist/{models-HQQQKEEP.js → models-3NW7HU72.js} +14 -13
- package/dist/{motionShot-2BT5D7DC.js → motionShot-VTTYZ6KW.js} +17 -16
- package/dist/{normalize-audio-SOLFMHNP.js → normalize-audio-ME3X7HBX.js} +6 -6
- package/dist/{open-KHEUODFQ.js → open-GLGSJISM.js} +12 -12
- package/dist/{parakeetRunner-BHU5NCAX.js → parakeetRunner-T3UGRZWC.js} +15 -14
- package/dist/{pipeline-WFV5HDTD.js → pipeline-IJXVEQCU.js} +10 -9
- package/dist/{play-GB34CANJ.js → play-HFFGGAZH.js} +21 -21
- package/dist/{preflight-REF3VSJ7.js → preflight-QV6V3UO2.js} +11 -10
- package/dist/{present-SIUTA7TD.js → present-TH34CTYY.js} +17 -17
- package/dist/{preview-T2GE7Z4A.js → preview-R67EQGQP.js} +100 -65
- package/dist/{producer-23KVQZAB.js → producer-HWPFETDU.js} +1 -1
- package/dist/{projectConfig-DBSNBPNP.js → projectConfig-AO4V3RHS.js} +7 -7
- package/dist/{publication-IXPUKYWJ.js → publication-BDQ3PXYG.js} +3 -3
- package/dist/{publish-3BA5VHXJ.js → publish-PXYTWSXN.js} +10 -10
- package/dist/{remove-background-RMSCJVVQ.js → remove-background-BVDJPT3Z.js} +11 -10
- package/dist/{render-Y6CTQ3YW.js → render-45YHWV6W.js} +6 -6
- package/dist/{render-6RNE2MLU.js → render-5MZY4TAB.js} +17 -16
- package/dist/{render-XGOZMMWX.js → render-5RQUYPIV.js} +35 -34
- package/dist/{render-batch-VUR6N6EY.js → render-batch-ZUTUBTHX.js} +6 -6
- package/dist/renderSetupWorker.js +42 -4
- package/dist/{resolver-GJCUH57W.js → resolver-FN2M3XVM.js} +5 -5
- package/dist/{sherpa-VVAKRCPL.js → sherpa-6KWNPRWB.js} +14 -13
- package/dist/skills/media-use/scripts/lib/duck.mjs +18 -2
- package/dist/skills/media-use/scripts/lib/duck.test.mjs +79 -0
- package/dist/{skills-ZHBURVQG.js → skills-PWQCM2BT.js} +5 -5
- package/dist/{skillsUpdateCheck-VMDAL2O2.js → skillsUpdateCheck-EHV2G3JX.js} +3 -3
- package/dist/{snapshot-KEOG56SL.js → snapshot-7Q24NFEI.js} +39 -38
- package/dist/{src-TZLGFRRX.js → src-J43SXEHJ.js} +10 -9
- package/dist/{src-BH5NICGQ.js → src-OS2FRVZV.js} +9 -6
- package/dist/{staticProjectServer-BKXL5CXB.js → staticProjectServer-YJWOQJF4.js} +18 -18
- package/dist/studio/assets/{hyperframes-player-BMcUdmDb.js → hyperframes-player-DnIPEARk.js} +1 -1
- package/dist/studio/assets/{index-Ci6GuloR.js → index-CVppCm_X.js} +1 -1
- package/dist/studio/assets/{index-Ca-mgTnS.js → index-Dkt4c1MV.js} +161 -161
- package/dist/studio/index.html +1 -1
- package/dist/{studio-api-A5U6QAMC.js → studio-api-CZBZ4D65.js} +11 -11
- package/dist/{studioServer-5EC5CP4W.js → studioServer-U6EX5DSB.js} +94 -53
- package/dist/{telemetry-BCKJXDSW.js → telemetry-VP4UWWO3.js} +3 -3
- package/dist/{timeline-AZWAXTAY.js → timeline-LMSUKEG6.js} +20 -19
- package/dist/{tokens-X7NC3V7C.js → tokens-FQ5AI5H4.js} +2 -2
- package/dist/{transcribe-7NCY7QZ2.js → transcribe-DNQFPZ2S.js} +13 -12
- package/dist/{transcribe-SH26H755.js → transcribe-VAMXV7QS.js} +19 -18
- package/dist/{updateCheck-Y7FUWQM4.js → updateCheck-TOU7VLZK.js} +2 -2
- package/dist/{upgrade-ZHGEVL65.js → upgrade-CJRMRR2S.js} +2 -2
- package/dist/{urlDownloader-FPILIT7M.js → urlDownloader-GETNWEIT.js} +7 -6
- package/dist/{validate-KQOZR4F6.js → validate-PRI2UTQS.js} +25 -24
- package/dist/vendor/npm/gsap@3.15.0/dist/CustomEase.min.js +11 -0
- package/dist/vendor/npm/gsap@3.15.0/dist/MotionPathPlugin.min.js +11 -0
- package/dist/vendor/npm/gsap@3.15.0/dist/gsap.min.js +11 -0
- package/dist/{video-N2QAETFB.js → video-VOCQA6AG.js} +8 -7
- package/dist/warmCheck.js +38 -37
- package/package.json +1 -1
- package/dist/chunk-USWPZXEA.js +0 -3897
|
@@ -3714,7 +3714,9 @@ var require_dist = __commonJS({
|
|
|
3714
3714
|
import { parse } from "acorn";
|
|
3715
3715
|
var import_postcss_selector_parser = __toESM(require_dist(), 1);
|
|
3716
3716
|
import postcss from "postcss";
|
|
3717
|
-
import { parse as parse2 } from "acorn";
|
|
3717
|
+
import { parse as parse2, parseExpressionAt } from "acorn";
|
|
3718
|
+
import { parse as parse3 } from "acorn";
|
|
3719
|
+
var import_postcss_selector_parser2 = __toESM(require_dist(), 1);
|
|
3718
3720
|
import postcss2 from "postcss";
|
|
3719
3721
|
import postcss3 from "postcss";
|
|
3720
3722
|
|
|
@@ -3753,7 +3755,6 @@ function trackKindOf(node) {
|
|
|
3753
3755
|
}
|
|
3754
3756
|
|
|
3755
3757
|
// ../lint/dist/index.js
|
|
3756
|
-
import { parse as parse3, parseExpressionAt } from "acorn";
|
|
3757
3758
|
import { createHash } from "crypto";
|
|
3758
3759
|
import { existsSync as existsSync2, readFileSync, readdirSync } from "fs";
|
|
3759
3760
|
import { dirname as dirname2, extname, join as join3, relative as relative2, resolve } from "path";
|
|
@@ -3833,7 +3834,18 @@ function parseStartExpression(raw) {
|
|
|
3833
3834
|
offset: reference.operator === "-" ? -reference.magnitude : reference.magnitude
|
|
3834
3835
|
};
|
|
3835
3836
|
}
|
|
3836
|
-
function
|
|
3837
|
+
function compositionScopeOf(el) {
|
|
3838
|
+
return (el.getAttribute("data-composition-id") !== null ? el.parentElement : el)?.closest?.(
|
|
3839
|
+
"[data-composition-id]"
|
|
3840
|
+
) ?? null;
|
|
3841
|
+
}
|
|
3842
|
+
function findReferenceTargetEl(doc, refId, from) {
|
|
3843
|
+
const scope = compositionScopeOf(from);
|
|
3844
|
+
if (scope) {
|
|
3845
|
+
for (const candidate of scope.querySelectorAll?.(`[id="${refId}"]`) ?? []) {
|
|
3846
|
+
if (compositionScopeOf(candidate) === scope) return candidate;
|
|
3847
|
+
}
|
|
3848
|
+
}
|
|
3837
3849
|
return doc.getElementById(refId) ?? doc.querySelector(`[data-composition-id="${refId}"]`);
|
|
3838
3850
|
}
|
|
3839
3851
|
function resolveReferencedStart(doc, el, startCache, visiting) {
|
|
@@ -3852,7 +3864,7 @@ function resolveReferencedStart(doc, el, startCache, visiting) {
|
|
|
3852
3864
|
startCache.set(el, value);
|
|
3853
3865
|
return value;
|
|
3854
3866
|
}
|
|
3855
|
-
const target = findReferenceTargetEl(doc, expression.refId);
|
|
3867
|
+
const target = findReferenceTargetEl(doc, expression.refId, el);
|
|
3856
3868
|
if (!target) {
|
|
3857
3869
|
startCache.set(el, 0);
|
|
3858
3870
|
return 0;
|
|
@@ -4690,11 +4702,96 @@ function buildLintContext(html, options = {}) {
|
|
|
4690
4702
|
options
|
|
4691
4703
|
};
|
|
4692
4704
|
}
|
|
4705
|
+
var GLSL_SCRIPT_TYPES = /* @__PURE__ */ new Set(["x-shader/x-fragment", "x-shader/x-vertex", "text/glsl"]);
|
|
4706
|
+
function withoutComments(source) {
|
|
4707
|
+
return source.replace(/\/\*[\s\S]*?\*\/|\/\/[^\r\n]*/g, (text) => text.replace(/[^\r\n]/g, " "));
|
|
4708
|
+
}
|
|
4709
|
+
function staticShaders(source) {
|
|
4710
|
+
const shaders = [];
|
|
4711
|
+
try {
|
|
4712
|
+
const ast = parse2(source, {
|
|
4713
|
+
ecmaVersion: "latest",
|
|
4714
|
+
sourceType: "module",
|
|
4715
|
+
allowReturnOutsideFunction: true
|
|
4716
|
+
});
|
|
4717
|
+
simple(ast, {
|
|
4718
|
+
Literal(node) {
|
|
4719
|
+
if (typeof node.value !== "string") return;
|
|
4720
|
+
shaders.push({
|
|
4721
|
+
text: node.value,
|
|
4722
|
+
start: node.start + 1,
|
|
4723
|
+
exactOffsets: source.slice(node.start + 1, node.end - 1) === node.value
|
|
4724
|
+
});
|
|
4725
|
+
},
|
|
4726
|
+
TemplateLiteral(node) {
|
|
4727
|
+
if (node.expressions.length !== 0) return;
|
|
4728
|
+
const value = node.quasis[0]?.value;
|
|
4729
|
+
if (value?.cooked == null) return;
|
|
4730
|
+
shaders.push({
|
|
4731
|
+
text: value.cooked,
|
|
4732
|
+
start: node.start + 1,
|
|
4733
|
+
exactOffsets: source.slice(node.start + 1, node.end - 1) === value.cooked
|
|
4734
|
+
});
|
|
4735
|
+
}
|
|
4736
|
+
});
|
|
4737
|
+
} catch {
|
|
4738
|
+
}
|
|
4739
|
+
return shaders.filter(({ text }) => /\bvoid\s+main\s*\(/.test(withoutComments(text)));
|
|
4740
|
+
}
|
|
4741
|
+
function isNumber(node, value) {
|
|
4742
|
+
return node?.type === "Literal" && node.value === value;
|
|
4743
|
+
}
|
|
4744
|
+
function isCall(node, name) {
|
|
4745
|
+
return node?.type === "CallExpression" && node.callee.type === "Identifier" && node.callee.name === name;
|
|
4746
|
+
}
|
|
4747
|
+
function unboundedCosine(node) {
|
|
4748
|
+
if (node.type !== "CallExpression") return false;
|
|
4749
|
+
if (isCall(node, "dot")) return node.arguments.length === 2;
|
|
4750
|
+
if (!isCall(node, "max") || node.arguments.length !== 2) return false;
|
|
4751
|
+
const a = argumentAt(node, 0);
|
|
4752
|
+
const b = argumentAt(node, 1);
|
|
4753
|
+
return zeroFlooredDot(a, b) || zeroFlooredDot(b, a);
|
|
4754
|
+
}
|
|
4755
|
+
function argumentAt(call, index) {
|
|
4756
|
+
const node = call.arguments[index];
|
|
4757
|
+
return node?.type === "SpreadElement" ? void 0 : node;
|
|
4758
|
+
}
|
|
4759
|
+
function zeroFlooredDot(a, b) {
|
|
4760
|
+
return isCall(a, "dot") && isNumber(b, 0);
|
|
4761
|
+
}
|
|
4762
|
+
function unsafeCosinePower(call) {
|
|
4763
|
+
if (call.arguments.length !== 2) return false;
|
|
4764
|
+
const [base2] = call.arguments;
|
|
4765
|
+
return base2?.type === "BinaryExpression" && base2.operator === "-" && base2.left.type !== "PrivateIdentifier" && isNumber(base2.left, 1) && unboundedCosine(base2.right);
|
|
4766
|
+
}
|
|
4767
|
+
function unsafePowOffsets(source) {
|
|
4768
|
+
const offsets = [];
|
|
4769
|
+
const masked = withoutComments(source);
|
|
4770
|
+
for (const match of masked.matchAll(/\bpow\s*\(/g)) {
|
|
4771
|
+
try {
|
|
4772
|
+
const expression = parseExpressionAt(masked, match.index, { ecmaVersion: "latest" });
|
|
4773
|
+
simple(expression, {
|
|
4774
|
+
CallExpression(node) {
|
|
4775
|
+
if (node.start === match.index && unsafeCosinePower(node)) offsets.push(node.start);
|
|
4776
|
+
}
|
|
4777
|
+
});
|
|
4778
|
+
} catch {
|
|
4779
|
+
}
|
|
4780
|
+
}
|
|
4781
|
+
return offsets;
|
|
4782
|
+
}
|
|
4783
|
+
function shaderDomainOffsets(source, glsl = false) {
|
|
4784
|
+
const shaders = glsl ? [{ text: source, start: 0, exactOffsets: true }] : staticShaders(source);
|
|
4785
|
+
return shaders.flatMap(
|
|
4786
|
+
({ text, start, exactOffsets }) => unsafePowOffsets(text).map((offset) => exactOffsets ? start + offset : void 0)
|
|
4787
|
+
);
|
|
4788
|
+
}
|
|
4693
4789
|
var SCRIPT_SYNTAX_EXEMPT_TYPES = /* @__PURE__ */ new Set([
|
|
4694
4790
|
"application/json",
|
|
4695
4791
|
"application/hyperframes-slideshow+json",
|
|
4696
4792
|
"importmap",
|
|
4697
|
-
"module"
|
|
4793
|
+
"module",
|
|
4794
|
+
...GLSL_SCRIPT_TYPES
|
|
4698
4795
|
]);
|
|
4699
4796
|
function repeatedDescendantId(selector) {
|
|
4700
4797
|
let repeated = null;
|
|
@@ -5493,7 +5590,7 @@ function driftingFields(members) {
|
|
|
5493
5590
|
return values.some((value) => Math.abs(value - first) > SYNC_TOLERANCE_S);
|
|
5494
5591
|
}).map(({ field }) => field);
|
|
5495
5592
|
}
|
|
5496
|
-
function
|
|
5593
|
+
function compositionScopeOf2(tag, compositions) {
|
|
5497
5594
|
let scope = -1;
|
|
5498
5595
|
for (const composition of compositions) {
|
|
5499
5596
|
const end = composition.endIndex ?? composition.closeIndex ?? Number.POSITIVE_INFINITY;
|
|
@@ -5512,7 +5609,7 @@ function groupByLink(tags) {
|
|
|
5512
5609
|
for (const tag of tags) {
|
|
5513
5610
|
const link = readAttr(tag.raw, "data-link");
|
|
5514
5611
|
if (!link) continue;
|
|
5515
|
-
const key = `${
|
|
5612
|
+
const key = `${compositionScopeOf2(tag, compositions)}\0${link}`;
|
|
5516
5613
|
const group = groups.get(key) ?? { link, members: [] };
|
|
5517
5614
|
group.members.push(tag);
|
|
5518
5615
|
groups.set(key, group);
|
|
@@ -6442,7 +6539,7 @@ function callsFor(script) {
|
|
|
6442
6539
|
if (cached) return cached;
|
|
6443
6540
|
const calls = [];
|
|
6444
6541
|
try {
|
|
6445
|
-
const ast =
|
|
6542
|
+
const ast = parse3(script.content, {
|
|
6446
6543
|
ecmaVersion: "latest",
|
|
6447
6544
|
sourceType: "script",
|
|
6448
6545
|
allowReturnOutsideFunction: true
|
|
@@ -6627,12 +6724,154 @@ function firstRescalingZoom(css) {
|
|
|
6627
6724
|
}
|
|
6628
6725
|
return null;
|
|
6629
6726
|
}
|
|
6630
|
-
function
|
|
6727
|
+
function canvasScopeCandidate(selector, root) {
|
|
6631
6728
|
const leftmost = selector.trim().split(/[\s>+~]+/)[0] ?? "";
|
|
6632
|
-
|
|
6633
|
-
if (
|
|
6634
|
-
|
|
6635
|
-
|
|
6729
|
+
if (["html", "body", ":root", "*"].includes(leftmost.toLowerCase())) return true;
|
|
6730
|
+
if (root.id && leftmostCompoundId(selector) === root.id) return true;
|
|
6731
|
+
return leftmostCompoundClasses(selector).some((name) => root.classes.includes(name));
|
|
6732
|
+
}
|
|
6733
|
+
function canvasIdentity(tag) {
|
|
6734
|
+
return {
|
|
6735
|
+
name: tag.name,
|
|
6736
|
+
raw: tag.raw,
|
|
6737
|
+
id: readDecodedAttr(tag.raw, "id"),
|
|
6738
|
+
classes: (readDecodedAttr(tag.raw, "class") ?? "").split(/[\t\n\f\r ]+/)
|
|
6739
|
+
};
|
|
6740
|
+
}
|
|
6741
|
+
function anyCanvasMatch(matches) {
|
|
6742
|
+
if (matches.includes(true)) return true;
|
|
6743
|
+
return matches.includes(void 0) ? void 0 : false;
|
|
6744
|
+
}
|
|
6745
|
+
function allCanvasMatch(matches) {
|
|
6746
|
+
if (matches.includes(false)) return false;
|
|
6747
|
+
return matches.includes(void 0) ? void 0 : true;
|
|
6748
|
+
}
|
|
6749
|
+
function canvasTokenMatch(tokens, value) {
|
|
6750
|
+
if (tokens.includes(value)) return true;
|
|
6751
|
+
const fold = (token) => token.replace(/[A-Z]/g, (char) => char.toLowerCase());
|
|
6752
|
+
return tokens.some((token) => fold(token) === fold(value)) ? void 0 : false;
|
|
6753
|
+
}
|
|
6754
|
+
function canvasPseudoMatch(node, element, hasIdentity) {
|
|
6755
|
+
const name = node.value.toLowerCase();
|
|
6756
|
+
if (name.startsWith("::") || [":before", ":after", ":first-letter", ":first-line"].includes(name))
|
|
6757
|
+
return { match: false, hasIdentity: false };
|
|
6758
|
+
if ([":is", ":where"].includes(name)) {
|
|
6759
|
+
const branches = node.nodes.map(
|
|
6760
|
+
(branch) => canvasPathMatch(branch.nodes, element, hasIdentity)
|
|
6761
|
+
);
|
|
6762
|
+
const match = anyCanvasMatch(branches.map((branch) => branch.match));
|
|
6763
|
+
return { match, hasIdentity: match === true || branches.some((branch) => branch.hasIdentity) };
|
|
6764
|
+
}
|
|
6765
|
+
if (name === ":root") {
|
|
6766
|
+
const match = element.name === "html";
|
|
6767
|
+
return { match, hasIdentity: match };
|
|
6768
|
+
}
|
|
6769
|
+
if (name === ":nth-child" && element.name === "body") {
|
|
6770
|
+
const argument = node.nodes.map((branch) => branch.toString()).join(",").trim();
|
|
6771
|
+
if (/^[1-9]\d*$/.test(argument)) {
|
|
6772
|
+
const match = Number(argument) === 2;
|
|
6773
|
+
return { match, hasIdentity: match };
|
|
6774
|
+
}
|
|
6775
|
+
}
|
|
6776
|
+
return { match: void 0, hasIdentity: false };
|
|
6777
|
+
}
|
|
6778
|
+
function canvasTagMatch(node, element) {
|
|
6779
|
+
if (node.namespace !== void 0) return { match: void 0, hasIdentity: false };
|
|
6780
|
+
if (node.value.toLowerCase() !== element.name.toLowerCase())
|
|
6781
|
+
return { match: false, hasIdentity: false };
|
|
6782
|
+
return { match: ["html", "body"].includes(element.name) ? true : void 0, hasIdentity: true };
|
|
6783
|
+
}
|
|
6784
|
+
function canvasAttributeMatch(node, element) {
|
|
6785
|
+
if (node.namespace === void 0 && node.operator === void 0 && /^data-[a-z0-9_-]+$/.test(node.attribute))
|
|
6786
|
+
return readDecodedAttr(element.raw, node.attribute) !== null;
|
|
6787
|
+
return void 0;
|
|
6788
|
+
}
|
|
6789
|
+
function canvasNodeMatch(node, element, hasIdentity) {
|
|
6790
|
+
switch (node.type) {
|
|
6791
|
+
case "id": {
|
|
6792
|
+
const match = canvasTokenMatch(element.id === null ? [] : [element.id], node.value);
|
|
6793
|
+
return { match, hasIdentity: match === true };
|
|
6794
|
+
}
|
|
6795
|
+
case "class": {
|
|
6796
|
+
const match = canvasTokenMatch(element.classes, node.value);
|
|
6797
|
+
return { match, hasIdentity: match === true };
|
|
6798
|
+
}
|
|
6799
|
+
case "tag":
|
|
6800
|
+
return canvasTagMatch(node, element);
|
|
6801
|
+
case "universal":
|
|
6802
|
+
return { match: node.toString().trim() === "*" ? true : void 0, hasIdentity: false };
|
|
6803
|
+
case "attribute":
|
|
6804
|
+
return { match: canvasAttributeMatch(node, element), hasIdentity: false };
|
|
6805
|
+
case "pseudo":
|
|
6806
|
+
return canvasPseudoMatch(node, element, hasIdentity);
|
|
6807
|
+
default:
|
|
6808
|
+
return { match: void 0, hasIdentity: false };
|
|
6809
|
+
}
|
|
6810
|
+
}
|
|
6811
|
+
function canvasAncestorMatch(nodes, relation, element) {
|
|
6812
|
+
if (!["", ">"].includes(relation)) return void 0;
|
|
6813
|
+
const matches = [];
|
|
6814
|
+
let parent = element.parent;
|
|
6815
|
+
while (parent) {
|
|
6816
|
+
matches.push(canvasPathMatch(nodes, parent).match);
|
|
6817
|
+
if (relation === ">") break;
|
|
6818
|
+
parent = parent.parent;
|
|
6819
|
+
}
|
|
6820
|
+
if (parent === void 0) matches.push(void 0);
|
|
6821
|
+
return anyCanvasMatch(matches);
|
|
6822
|
+
}
|
|
6823
|
+
function canvasPathMatch(nodes, element, inheritedIdentity = false) {
|
|
6824
|
+
let split = -1;
|
|
6825
|
+
let relation = "";
|
|
6826
|
+
for (const [index, node] of nodes.entries()) {
|
|
6827
|
+
if (node.type === "combinator") {
|
|
6828
|
+
split = index;
|
|
6829
|
+
relation = node.value.trim();
|
|
6830
|
+
}
|
|
6831
|
+
}
|
|
6832
|
+
const subjectNodes = nodes.slice(split + 1);
|
|
6833
|
+
if (subjectNodes.length === 0) return { match: void 0, hasIdentity: false };
|
|
6834
|
+
const matches = subjectNodes.map((node) => canvasNodeMatch(node, element, inheritedIdentity));
|
|
6835
|
+
const hasIdentity = inheritedIdentity || matches.some((result) => result.hasIdentity);
|
|
6836
|
+
const subject = allCanvasMatch(
|
|
6837
|
+
subjectNodes.map((node, index) => {
|
|
6838
|
+
const match2 = matches[index]?.match;
|
|
6839
|
+
if (!hasIdentity || match2 !== false) return match2;
|
|
6840
|
+
if (["id", "class", "attribute"].includes(node.type)) return void 0;
|
|
6841
|
+
if (node.type === "pseudo" && !inheritedIdentity)
|
|
6842
|
+
return canvasNodeMatch(node, element, true).match;
|
|
6843
|
+
return match2;
|
|
6844
|
+
})
|
|
6845
|
+
);
|
|
6846
|
+
const match = subject === false || split === -1 ? subject : allCanvasMatch([subject, canvasAncestorMatch(nodes.slice(0, split), relation, element)]);
|
|
6847
|
+
return { match, hasIdentity: match !== false && hasIdentity };
|
|
6848
|
+
}
|
|
6849
|
+
function canvasElements(rootTag, tags) {
|
|
6850
|
+
const root = canvasIdentity(rootTag);
|
|
6851
|
+
const html = {
|
|
6852
|
+
...root.name === "html" ? root : canvasIdentity(findHtmlTag(tags) ?? { name: "html", raw: "<html>" }),
|
|
6853
|
+
parent: null
|
|
6854
|
+
};
|
|
6855
|
+
const body = {
|
|
6856
|
+
...root.name === "body" ? root : canvasIdentity(tags.find((tag) => tag.name === "body") ?? { name: "body", raw: "<body>" }),
|
|
6857
|
+
parent: html
|
|
6858
|
+
};
|
|
6859
|
+
const elements = [html, body];
|
|
6860
|
+
if (!["html", "body"].includes(root.name))
|
|
6861
|
+
elements.push({ ...root, parent: ["head", "template"].includes(root.name) ? void 0 : body });
|
|
6862
|
+
return { root, elements };
|
|
6863
|
+
}
|
|
6864
|
+
function canvasSelectorMatcher(rootTag, tags) {
|
|
6865
|
+
let canvas;
|
|
6866
|
+
return (selector, allowNewHits) => {
|
|
6867
|
+
const { root, elements } = canvas ??= canvasElements(rootTag, tags);
|
|
6868
|
+
const match = anyCanvasMatch(
|
|
6869
|
+
elements.map((element) => canvasPathMatch(selector.nodes, element).match)
|
|
6870
|
+
);
|
|
6871
|
+
if (match === false) return false;
|
|
6872
|
+
if (match === true && allowNewHits) return true;
|
|
6873
|
+
return selector.toString().split(",").some((part) => canvasScopeCandidate(part, root));
|
|
6874
|
+
};
|
|
6636
6875
|
}
|
|
6637
6876
|
function inlineCanvasZoomHits(rootTag, tags) {
|
|
6638
6877
|
const hits = [];
|
|
@@ -6650,19 +6889,23 @@ function inlineCanvasZoomHits(rootTag, tags) {
|
|
|
6650
6889
|
}
|
|
6651
6890
|
return hits;
|
|
6652
6891
|
}
|
|
6653
|
-
function firstCanvasSelector(header,
|
|
6654
|
-
|
|
6655
|
-
const
|
|
6656
|
-
|
|
6892
|
+
function firstCanvasSelector(header, matchesCanvas) {
|
|
6893
|
+
try {
|
|
6894
|
+
for (const selector of (0, import_postcss_selector_parser2.default)().astSync(header).nodes) {
|
|
6895
|
+
const trimmed = selector.toString().trim();
|
|
6896
|
+
if (matchesCanvas(selector)) return trimmed;
|
|
6897
|
+
}
|
|
6898
|
+
} catch {
|
|
6899
|
+
return null;
|
|
6657
6900
|
}
|
|
6658
6901
|
return null;
|
|
6659
6902
|
}
|
|
6660
|
-
function canvasZoomInRule(header, body,
|
|
6903
|
+
function canvasZoomInRule(header, body, matchesCanvas) {
|
|
6661
6904
|
const trimmedHeader = header.trim();
|
|
6662
6905
|
if (!trimmedHeader || trimmedHeader.startsWith("@")) return null;
|
|
6663
6906
|
const value = firstRescalingZoom(body);
|
|
6664
6907
|
if (!value) return null;
|
|
6665
|
-
const selector = firstCanvasSelector(trimmedHeader,
|
|
6908
|
+
const selector = firstCanvasSelector(trimmedHeader, matchesCanvas);
|
|
6666
6909
|
if (!selector) return null;
|
|
6667
6910
|
return {
|
|
6668
6911
|
where: `\`${selector}\``,
|
|
@@ -6670,23 +6913,28 @@ function canvasZoomInRule(header, body, rootId, rootClasses) {
|
|
|
6670
6913
|
snippet: truncateSnippet(`${selector} { zoom: ${value} }`)
|
|
6671
6914
|
};
|
|
6672
6915
|
}
|
|
6673
|
-
function stylesheetCanvasZoomHits(styles,
|
|
6916
|
+
function stylesheetCanvasZoomHits(styles, matchesCanvas) {
|
|
6674
6917
|
const hits = [];
|
|
6675
6918
|
for (const style of styles) {
|
|
6676
6919
|
const ruleWithBody = /([^{}]+)\{([^{}]*)\}/g;
|
|
6677
6920
|
const content = stripCssComments(style.content);
|
|
6921
|
+
const allowNewHits = style.attrs.trim() === "" && !content.includes("@");
|
|
6678
6922
|
let match;
|
|
6679
6923
|
while ((match = ruleWithBody.exec(content)) !== null) {
|
|
6680
|
-
const hit = canvasZoomInRule(
|
|
6924
|
+
const hit = canvasZoomInRule(
|
|
6925
|
+
match[1] ?? "",
|
|
6926
|
+
match[2] ?? "",
|
|
6927
|
+
(selector) => matchesCanvas(selector, allowNewHits)
|
|
6928
|
+
);
|
|
6681
6929
|
if (hit) hits.push(hit);
|
|
6682
6930
|
}
|
|
6683
6931
|
}
|
|
6684
6932
|
return hits;
|
|
6685
6933
|
}
|
|
6686
|
-
function canvasZoomHits(rootTag, tags, styles
|
|
6934
|
+
function canvasZoomHits(rootTag, tags, styles) {
|
|
6687
6935
|
return [
|
|
6688
6936
|
...inlineCanvasZoomHits(rootTag, tags),
|
|
6689
|
-
...stylesheetCanvasZoomHits(styles,
|
|
6937
|
+
...stylesheetCanvasZoomHits(styles, canvasSelectorMatcher(rootTag, tags))
|
|
6690
6938
|
];
|
|
6691
6939
|
}
|
|
6692
6940
|
function collectDeclaredVariableIds(htmlTagRaw) {
|
|
@@ -7584,9 +7832,7 @@ ${allInlineStyles}`.replace(/\/\*[\s\S]*?\*\//g, "");
|
|
|
7584
7832
|
// fired on every `zoom` would be flagging correct authoring.
|
|
7585
7833
|
({ rootTag, tags, styles }) => {
|
|
7586
7834
|
if (!rootTag) return [];
|
|
7587
|
-
const
|
|
7588
|
-
const rootClasses = (readAttr(rootTag.raw, "class") || "").split(/\s+/).filter(Boolean);
|
|
7589
|
-
const hits = canvasZoomHits(rootTag, tags, styles, rootId, rootClasses);
|
|
7835
|
+
const hits = canvasZoomHits(rootTag, tags, styles);
|
|
7590
7836
|
const hit = hits[0];
|
|
7591
7837
|
if (!hit) return [];
|
|
7592
7838
|
const enlarging = !hit.value.startsWith("-") && parseFloat(hit.value) > (hit.value.includes("%") ? 100 : 1);
|
|
@@ -7676,11 +7922,11 @@ function deriveDurationFromClips(tags, rootTag) {
|
|
|
7676
7922
|
return resolveCompositionDuration({ authoredDurationSeconds: null, clipEndsSeconds: clipEnds });
|
|
7677
7923
|
}
|
|
7678
7924
|
async function loadParseGsapScript() {
|
|
7679
|
-
const mod = await import("./gsapParserAcorn-
|
|
7925
|
+
const mod = await import("./gsapParserAcorn-LZJKCFQI.js");
|
|
7680
7926
|
return mod.parseGsapScriptAcorn;
|
|
7681
7927
|
}
|
|
7682
7928
|
async function loadGsapScriptMotionPathFirstUseIndex() {
|
|
7683
|
-
const mod = await import("./gsapParserAcorn-
|
|
7929
|
+
const mod = await import("./gsapParserAcorn-LZJKCFQI.js");
|
|
7684
7930
|
return mod.gsapScriptMotionPathFirstUseIndex;
|
|
7685
7931
|
}
|
|
7686
7932
|
var SCENE_BOUNDARY_EPSILON_SECONDS = 0.05;
|
|
@@ -8632,9 +8878,12 @@ ${right.raw}`)
|
|
|
8632
8878
|
const usesGsap = allScriptTexts.some(
|
|
8633
8879
|
(t) => /gsap\.(to|from|fromTo|timeline|set|registerPlugin)\b/.test(t)
|
|
8634
8880
|
);
|
|
8635
|
-
const
|
|
8881
|
+
const isGsapCoreSrc = (src) => /(^|\/)gsap(-\d+(\.\d+)*)?(\.min)?\.js$/i.test(src.split(/[?#]/)[0] ?? "");
|
|
8882
|
+
const hasGsapScript = allScriptSrcs.some(isGsapCoreSrc);
|
|
8636
8883
|
const hasInlineGsap = allScriptTexts.some(
|
|
8637
|
-
(t) => /\/\*\s*inlined
|
|
8884
|
+
(t) => [...t.matchAll(/\/\*\s*inlined:\s*(\S+)\s*\*\//gi)].some(
|
|
8885
|
+
(m) => isGsapCoreSrc(m[1] ?? "")
|
|
8886
|
+
) || /\/\*!\s*\*\s*GSAP\s+\d/.test(t) || /Missing plugin\? gsap\.registerPlugin\(\)/.test(t) || /\b_gsScope\b/.test(t)
|
|
8638
8887
|
);
|
|
8639
8888
|
if (!usesGsap || hasGsapScript || hasInlineGsap || canInheritGsapFromHost) return [];
|
|
8640
8889
|
return [
|
|
@@ -10311,89 +10560,6 @@ var structureRules = [
|
|
|
10311
10560
|
return topLevelElements(root).filter((row) => !isSubCompositionHost(row)).flatMap((row) => neverVisibleNestedFindings(row, severity));
|
|
10312
10561
|
}
|
|
10313
10562
|
];
|
|
10314
|
-
function withoutComments(source) {
|
|
10315
|
-
return source.replace(/\/\*[\s\S]*?\*\/|\/\/[^\r\n]*/g, (text) => text.replace(/[^\r\n]/g, " "));
|
|
10316
|
-
}
|
|
10317
|
-
function staticShaders(source) {
|
|
10318
|
-
const shaders = [];
|
|
10319
|
-
try {
|
|
10320
|
-
const ast = parse3(source, {
|
|
10321
|
-
ecmaVersion: "latest",
|
|
10322
|
-
sourceType: "module",
|
|
10323
|
-
allowReturnOutsideFunction: true
|
|
10324
|
-
});
|
|
10325
|
-
simple(ast, {
|
|
10326
|
-
Literal(node) {
|
|
10327
|
-
if (typeof node.value !== "string") return;
|
|
10328
|
-
shaders.push({
|
|
10329
|
-
text: node.value,
|
|
10330
|
-
start: node.start + 1,
|
|
10331
|
-
exactOffsets: source.slice(node.start + 1, node.end - 1) === node.value
|
|
10332
|
-
});
|
|
10333
|
-
},
|
|
10334
|
-
TemplateLiteral(node) {
|
|
10335
|
-
if (node.expressions.length !== 0) return;
|
|
10336
|
-
const value = node.quasis[0]?.value;
|
|
10337
|
-
if (value?.cooked == null) return;
|
|
10338
|
-
shaders.push({
|
|
10339
|
-
text: value.cooked,
|
|
10340
|
-
start: node.start + 1,
|
|
10341
|
-
exactOffsets: source.slice(node.start + 1, node.end - 1) === value.cooked
|
|
10342
|
-
});
|
|
10343
|
-
}
|
|
10344
|
-
});
|
|
10345
|
-
} catch {
|
|
10346
|
-
}
|
|
10347
|
-
return shaders.filter(({ text }) => /\bvoid\s+main\s*\(/.test(withoutComments(text)));
|
|
10348
|
-
}
|
|
10349
|
-
function isNumber(node, value) {
|
|
10350
|
-
return node?.type === "Literal" && node.value === value;
|
|
10351
|
-
}
|
|
10352
|
-
function isCall(node, name) {
|
|
10353
|
-
return node?.type === "CallExpression" && node.callee.type === "Identifier" && node.callee.name === name;
|
|
10354
|
-
}
|
|
10355
|
-
function unboundedCosine(node) {
|
|
10356
|
-
if (node.type !== "CallExpression") return false;
|
|
10357
|
-
if (isCall(node, "dot")) return node.arguments.length === 2;
|
|
10358
|
-
if (!isCall(node, "max") || node.arguments.length !== 2) return false;
|
|
10359
|
-
const a = argumentAt(node, 0);
|
|
10360
|
-
const b = argumentAt(node, 1);
|
|
10361
|
-
return zeroFlooredDot(a, b) || zeroFlooredDot(b, a);
|
|
10362
|
-
}
|
|
10363
|
-
function argumentAt(call, index) {
|
|
10364
|
-
const node = call.arguments[index];
|
|
10365
|
-
return node?.type === "SpreadElement" ? void 0 : node;
|
|
10366
|
-
}
|
|
10367
|
-
function zeroFlooredDot(a, b) {
|
|
10368
|
-
return isCall(a, "dot") && isNumber(b, 0);
|
|
10369
|
-
}
|
|
10370
|
-
function unsafeCosinePower(call) {
|
|
10371
|
-
if (call.arguments.length !== 2) return false;
|
|
10372
|
-
const [base2] = call.arguments;
|
|
10373
|
-
return base2?.type === "BinaryExpression" && base2.operator === "-" && base2.left.type !== "PrivateIdentifier" && isNumber(base2.left, 1) && unboundedCosine(base2.right);
|
|
10374
|
-
}
|
|
10375
|
-
function unsafePowOffsets(source) {
|
|
10376
|
-
const offsets = [];
|
|
10377
|
-
const masked = withoutComments(source);
|
|
10378
|
-
for (const match of masked.matchAll(/\bpow\s*\(/g)) {
|
|
10379
|
-
try {
|
|
10380
|
-
const expression = parseExpressionAt(masked, match.index, { ecmaVersion: "latest" });
|
|
10381
|
-
simple(expression, {
|
|
10382
|
-
CallExpression(node) {
|
|
10383
|
-
if (node.start === match.index && unsafeCosinePower(node)) offsets.push(node.start);
|
|
10384
|
-
}
|
|
10385
|
-
});
|
|
10386
|
-
} catch {
|
|
10387
|
-
}
|
|
10388
|
-
}
|
|
10389
|
-
return offsets;
|
|
10390
|
-
}
|
|
10391
|
-
function shaderDomainOffsets(source, glsl = false) {
|
|
10392
|
-
const shaders = glsl ? [{ text: source, start: 0, exactOffsets: true }] : staticShaders(source);
|
|
10393
|
-
return shaders.flatMap(
|
|
10394
|
-
({ text, start, exactOffsets }) => unsafePowOffsets(text).map((offset) => exactOffsets ? start + offset : void 0)
|
|
10395
|
-
);
|
|
10396
|
-
}
|
|
10397
10563
|
function shaderDomainWarning() {
|
|
10398
10564
|
return {
|
|
10399
10565
|
code: "shader_unbounded_cosine_pow",
|
|
@@ -10407,7 +10573,7 @@ var shaderRules = [
|
|
|
10407
10573
|
const tag = `<script ${script.attrs}>`;
|
|
10408
10574
|
if (readAttr(tag, "src") !== null) return [];
|
|
10409
10575
|
const type = readAttr(tag, "type") ?? "";
|
|
10410
|
-
const glsl =
|
|
10576
|
+
const glsl = GLSL_SCRIPT_TYPES.has(type.toLowerCase());
|
|
10411
10577
|
if (type && !glsl && !/^(?:module|(?:text|application)\/javascript)$/i.test(type)) return [];
|
|
10412
10578
|
return shaderDomainOffsets(script.content, glsl).map((offset) => ({
|
|
10413
10579
|
...shaderDomainWarning(),
|
|
@@ -7,29 +7,29 @@ var __dirname = __hf_dirname(__filename);
|
|
|
7
7
|
import {
|
|
8
8
|
RegistryCompatibilityError,
|
|
9
9
|
gateRegistryItemsCompatibility
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-3PYIQLPL.js";
|
|
11
11
|
import {
|
|
12
12
|
DEFAULT_PROJECT_CONFIG,
|
|
13
13
|
createProjectConfig,
|
|
14
14
|
loadProjectConfig,
|
|
15
15
|
projectConfigPath,
|
|
16
16
|
recordProjectRegistryItems
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-RAACYYWX.js";
|
|
18
18
|
import {
|
|
19
19
|
resolveItemWithDependencies,
|
|
20
20
|
resolveItemsByTag
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-D6XDOYMB.js";
|
|
22
22
|
import {
|
|
23
23
|
InvalidVariableValuesError,
|
|
24
24
|
prepareItem,
|
|
25
25
|
publishItem
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-W4SSWOOD.js";
|
|
27
27
|
import {
|
|
28
28
|
DEFAULT_REGISTRY_URL
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-HT33OHQL.js";
|
|
30
30
|
import {
|
|
31
31
|
trackRegistryItemAdded
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-ZL6ZCLY6.js";
|
|
33
33
|
import {
|
|
34
34
|
defineCommand
|
|
35
35
|
} from "./chunk-S3S4TGEH.js";
|
|
@@ -41,7 +41,7 @@ import {
|
|
|
41
41
|
} from "./chunk-ZTZA4UWZ.js";
|
|
42
42
|
import {
|
|
43
43
|
ITEM_TYPE_DIRS
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-E74JMKSK.js";
|
|
45
45
|
import {
|
|
46
46
|
isProjectRootMissing,
|
|
47
47
|
realpath
|
|
@@ -6,7 +6,7 @@ var __filename = __hf_fileURLToPath(import.meta.url);
|
|
|
6
6
|
var __dirname = __hf_dirname(__filename);
|
|
7
7
|
import {
|
|
8
8
|
VERSION
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-66Q27H72.js";
|
|
10
10
|
|
|
11
11
|
// src/registry/compatibility.ts
|
|
12
12
|
import { compareVersions } from "compare-versions";
|
|
@@ -6,10 +6,10 @@ var __filename = __hf_fileURLToPath(import.meta.url);
|
|
|
6
6
|
var __dirname = __hf_dirname(__filename);
|
|
7
7
|
import {
|
|
8
8
|
detectGpuEncoder
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-HJINEUHY.js";
|
|
10
10
|
import {
|
|
11
11
|
runCancellableProcess
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-BL4U6U52.js";
|
|
13
13
|
import {
|
|
14
14
|
findFfBinary
|
|
15
15
|
} from "./chunk-VAS6HQX3.js";
|
|
@@ -6,26 +6,26 @@ var __filename = __hf_fileURLToPath(import.meta.url);
|
|
|
6
6
|
var __dirname = __hf_dirname(__filename);
|
|
7
7
|
import {
|
|
8
8
|
parakeetRunner
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-TE6VGYHQ.js";
|
|
10
10
|
import {
|
|
11
11
|
DecodeCancelled,
|
|
12
12
|
prepareSherpaWav,
|
|
13
13
|
sherpaUnsupportedReason,
|
|
14
14
|
transcribeWithSherpa
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-6ORTRIDW.js";
|
|
16
16
|
import {
|
|
17
17
|
initialModelForLanguage,
|
|
18
18
|
transcribe
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-2HSRLKZR.js";
|
|
20
20
|
import {
|
|
21
21
|
createRenderCancellationScope,
|
|
22
22
|
stoppedByCancelSignal
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-P5X5URNQ.js";
|
|
24
24
|
import {
|
|
25
25
|
DEFAULT_MODEL,
|
|
26
26
|
findWhisper,
|
|
27
27
|
isWhisperUnavailable
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-F4T7XYMF.js";
|
|
29
29
|
import {
|
|
30
30
|
formatSrt,
|
|
31
31
|
formatVtt,
|
|
@@ -6,8 +6,8 @@ var __filename = __hf_fileURLToPath(import.meta.url);
|
|
|
6
6
|
var __dirname = __hf_dirname(__filename);
|
|
7
7
|
|
|
8
8
|
// src/version.ts
|
|
9
|
-
var VERSION = true ? "0.8.
|
|
10
|
-
var PRODUCER_VERSION = true ? "0.8.
|
|
9
|
+
var VERSION = true ? "0.8.195" : "0.0.0-dev";
|
|
10
|
+
var PRODUCER_VERSION = true ? "0.8.195" : "0.0.0-dev";
|
|
11
11
|
|
|
12
12
|
export {
|
|
13
13
|
VERSION,
|
|
@@ -21,13 +21,13 @@ import {
|
|
|
21
21
|
emitWords,
|
|
22
22
|
getPreparedWavDurationSeconds,
|
|
23
23
|
prepareWav
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-2HSRLKZR.js";
|
|
25
25
|
import {
|
|
26
26
|
stoppedByCancelSignal
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-P5X5URNQ.js";
|
|
28
28
|
import {
|
|
29
29
|
verifies
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-F4T7XYMF.js";
|
|
31
31
|
import {
|
|
32
32
|
PARAKEET_MODEL_LABEL,
|
|
33
33
|
SHERPA_ERROR_PREFIX,
|