hyperframes 0.8.58 → 0.8.60
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/cli.js +4529 -3220
- package/dist/docs/data-attributes.md +2 -1
- package/dist/fontLocalizeCli.js +96 -16
- package/dist/hyperframe-runtime.js +25 -25
- package/dist/hyperframe.manifest.json +1 -1
- package/dist/hyperframe.runtime.iife.js +25 -25
- package/dist/hyperframes-player.global.js +3 -3
- package/dist/registry/localSemantic.js +548 -0
- package/dist/skills/hyperframes-cli/SKILL.md +2 -2
- package/dist/skills/media-use/SKILL.md +96 -0
- package/dist/skills/media-use/audio/assets/sfx/CREDITS.md +35 -0
- package/dist/skills/media-use/audio/assets/sfx/chime.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/click-soft.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/click.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/error.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/glitch-1.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/glitch-2.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/glitch-3.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/impact-bass-1.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/impact-bass-2.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/key-press.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/manifest.json +97 -0
- package/dist/skills/media-use/audio/assets/sfx/notification.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/ping.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/pop.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/riser.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/sparkle.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/typing.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/whoosh-cinematic.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/whoosh-short.mp3 +0 -0
- package/dist/skills/media-use/audio/assets/sfx/whoosh.mp3 +0 -0
- package/dist/skills/media-use/audio/references/bgm.md +74 -0
- package/dist/skills/media-use/audio/references/captions/authoring.md +163 -0
- package/dist/skills/media-use/audio/references/captions/motion.md +87 -0
- package/dist/skills/media-use/audio/references/captions/transcript-handling.md +97 -0
- package/dist/skills/media-use/audio/references/remove-background.md +143 -0
- package/dist/skills/media-use/audio/references/requirements.md +29 -0
- package/dist/skills/media-use/audio/references/sfx.md +42 -0
- package/dist/skills/media-use/audio/references/transcribe.md +52 -0
- package/dist/skills/media-use/audio/references/tts-to-captions.md +26 -0
- package/dist/skills/media-use/audio/references/tts.md +165 -0
- package/dist/skills/media-use/audio/scripts/audio.mjs +295 -0
- package/dist/skills/media-use/audio/scripts/audio.test.mjs +49 -0
- package/dist/skills/media-use/audio/scripts/heygen-tts.mjs +121 -0
- package/dist/skills/media-use/audio/scripts/lib/audio-meta.mjs +39 -0
- package/dist/skills/media-use/audio/scripts/lib/audio-meta.test.mjs +136 -0
- package/dist/skills/media-use/audio/scripts/lib/bgm.mjs +257 -0
- package/dist/skills/media-use/audio/scripts/lib/bgm.test.mjs +30 -0
- package/dist/skills/media-use/audio/scripts/lib/concurrency.mjs +14 -0
- package/dist/skills/media-use/audio/scripts/lib/concurrency.test.mjs +41 -0
- package/dist/skills/media-use/audio/scripts/lib/heygen.mjs +156 -0
- package/dist/skills/media-use/audio/scripts/lib/heygen.test.mjs +103 -0
- package/dist/skills/media-use/audio/scripts/lib/python.mjs +63 -0
- package/dist/skills/media-use/audio/scripts/lib/python.test.mjs +68 -0
- package/dist/skills/media-use/audio/scripts/lib/sfx.mjs +143 -0
- package/dist/skills/media-use/audio/scripts/lib/sfx.test.mjs +69 -0
- package/dist/skills/media-use/audio/scripts/lib/tts.mjs +379 -0
- package/dist/skills/media-use/audio/scripts/lib/tts.spawn.test.mjs +158 -0
- package/dist/skills/media-use/audio/scripts/lib/tts.test.mjs +157 -0
- package/dist/skills/media-use/audio/scripts/lyria-recipe.py +136 -0
- package/dist/skills/media-use/audio/scripts/wait-bgm.mjs +171 -0
- package/dist/skills/media-use/audio/scripts/wait-bgm.test.mjs +65 -0
- package/dist/skills/media-use/luts/README.md +28 -0
- package/dist/skills/media-use/luts/index.json +57 -0
- package/dist/skills/media-use/references/audio.md +19 -0
- package/dist/skills/media-use/references/grading.md +160 -0
- package/dist/skills/media-use/references/media-treatment-recipes.md +929 -0
- package/dist/skills/media-use/references/media-treatments.md +202 -0
- package/dist/skills/media-use/references/memory.md +36 -0
- package/dist/skills/media-use/references/meta.md +61 -0
- package/dist/skills/media-use/references/operations.md +325 -0
- package/dist/skills/media-use/references/resolve.md +150 -0
- package/dist/skills/media-use/references/setup-providers.md +80 -0
- package/dist/skills/media-use/references/telemetry-dashboard.md +49 -0
- package/dist/skills/media-use/registry/localSemantic.js +548 -0
- package/dist/skills/media-use/scripts/audio-duck.mjs +113 -0
- package/dist/skills/media-use/scripts/compatibility.test.mjs +27 -0
- package/dist/skills/media-use/scripts/dither.mjs +328 -0
- package/dist/skills/media-use/scripts/dither.test.mjs +176 -0
- package/dist/skills/media-use/scripts/eval.mjs +369 -0
- package/dist/skills/media-use/scripts/lib/adopt.mjs +128 -0
- package/dist/skills/media-use/scripts/lib/adopt.test.mjs +95 -0
- package/dist/skills/media-use/scripts/lib/bgm-provider.mjs +20 -0
- package/dist/skills/media-use/scripts/lib/brand-provider.mjs +59 -0
- package/dist/skills/media-use/scripts/lib/bundled-sfx-provider.mjs +119 -0
- package/dist/skills/media-use/scripts/lib/bundled-sfx-provider.test.mjs +139 -0
- package/dist/skills/media-use/scripts/lib/cache.mjs +150 -0
- package/dist/skills/media-use/scripts/lib/candidates.mjs +91 -0
- package/dist/skills/media-use/scripts/lib/candidates.test.mjs +155 -0
- package/dist/skills/media-use/scripts/lib/codex-provider.mjs +161 -0
- package/dist/skills/media-use/scripts/lib/codex-provider.test.mjs +34 -0
- package/dist/skills/media-use/scripts/lib/coverage.test.mjs +132 -0
- package/dist/skills/media-use/scripts/lib/cube-build.mjs +181 -0
- package/dist/skills/media-use/scripts/lib/cube-build.test.mjs +80 -0
- package/dist/skills/media-use/scripts/lib/cube-validate.mjs +198 -0
- package/dist/skills/media-use/scripts/lib/cube-validate.test.mjs +125 -0
- package/dist/skills/media-use/scripts/lib/cutlist.mjs +184 -0
- package/dist/skills/media-use/scripts/lib/cutlist.test.mjs +162 -0
- package/dist/skills/media-use/scripts/lib/duck.mjs +95 -0
- package/dist/skills/media-use/scripts/lib/duck.test.mjs +153 -0
- package/dist/skills/media-use/scripts/lib/error-diffusion.mjs +230 -0
- package/dist/skills/media-use/scripts/lib/error-diffusion.test.mjs +102 -0
- package/dist/skills/media-use/scripts/lib/freeze.mjs +62 -0
- package/dist/skills/media-use/scripts/lib/freeze.test.mjs +46 -0
- package/dist/skills/media-use/scripts/lib/grade-analyzer.mjs +265 -0
- package/dist/skills/media-use/scripts/lib/grade-analyzer.test.mjs +285 -0
- package/dist/skills/media-use/scripts/lib/heygen-cli.mjs +191 -0
- package/dist/skills/media-use/scripts/lib/heygen-cli.test.mjs +301 -0
- package/dist/skills/media-use/scripts/lib/heygen-search.mjs +45 -0
- package/dist/skills/media-use/scripts/lib/heygen-search.test.mjs +49 -0
- package/dist/skills/media-use/scripts/lib/heygen-video-provider.mjs +138 -0
- package/dist/skills/media-use/scripts/lib/heygen-video-provider.test.mjs +435 -0
- package/dist/skills/media-use/scripts/lib/image-provider.mjs +44 -0
- package/dist/skills/media-use/scripts/lib/index-gen.mjs +63 -0
- package/dist/skills/media-use/scripts/lib/local-media-search.mjs +32 -0
- package/dist/skills/media-use/scripts/lib/local-models.mjs +318 -0
- package/dist/skills/media-use/scripts/lib/local-models.test.mjs +220 -0
- package/dist/skills/media-use/scripts/lib/local-run.mjs +78 -0
- package/dist/skills/media-use/scripts/lib/local-run.test.mjs +121 -0
- package/dist/skills/media-use/scripts/lib/logo-provider.mjs +223 -0
- package/dist/skills/media-use/scripts/lib/logo-provider.test.mjs +154 -0
- package/dist/skills/media-use/scripts/lib/ltx-video-provider.mjs +94 -0
- package/dist/skills/media-use/scripts/lib/ltx-video-provider.test.mjs +316 -0
- package/dist/skills/media-use/scripts/lib/lut-preset-provider.mjs +271 -0
- package/dist/skills/media-use/scripts/lib/lut-preset-provider.test.mjs +199 -0
- package/dist/skills/media-use/scripts/lib/manifest.mjs +229 -0
- package/dist/skills/media-use/scripts/lib/manifest.test.mjs +388 -0
- package/dist/skills/media-use/scripts/lib/match.mjs +47 -0
- package/dist/skills/media-use/scripts/lib/media-fetch.mjs +71 -0
- package/dist/skills/media-use/scripts/lib/media-fetch.test.mjs +169 -0
- package/dist/skills/media-use/scripts/lib/media-search.d.mts +9 -0
- package/dist/skills/media-use/scripts/lib/media-search.mjs +107 -0
- package/dist/skills/media-use/scripts/lib/mflux-provider.mjs +128 -0
- package/dist/skills/media-use/scripts/lib/mflux-provider.test.mjs +174 -0
- package/dist/skills/media-use/scripts/lib/misses.mjs +49 -0
- package/dist/skills/media-use/scripts/lib/misses.test.mjs +78 -0
- package/dist/skills/media-use/scripts/lib/npx-sync.mjs +31 -0
- package/dist/skills/media-use/scripts/lib/npx-sync.test.mjs +50 -0
- package/dist/skills/media-use/scripts/lib/parakeet-words.mjs +27 -0
- package/dist/skills/media-use/scripts/lib/parakeet-words.test.mjs +44 -0
- package/dist/skills/media-use/scripts/lib/prefs-store.mjs +180 -0
- package/dist/skills/media-use/scripts/lib/prefs-store.test.mjs +189 -0
- package/dist/skills/media-use/scripts/lib/probe.mjs +39 -0
- package/dist/skills/media-use/scripts/lib/probe.test.mjs +31 -0
- package/dist/skills/media-use/scripts/lib/providers.mjs +5 -0
- package/dist/skills/media-use/scripts/lib/recipe-store.mjs +367 -0
- package/dist/skills/media-use/scripts/lib/recipe-store.test.mjs +367 -0
- package/dist/skills/media-use/scripts/lib/registry.mjs +218 -0
- package/dist/skills/media-use/scripts/lib/registry.test.mjs +262 -0
- package/dist/skills/media-use/scripts/lib/search.mjs +24 -0
- package/dist/skills/media-use/scripts/lib/search.test.mjs +32 -0
- package/dist/skills/media-use/scripts/lib/sfx-provider.mjs +23 -0
- package/dist/skills/media-use/scripts/lib/specs.mjs +132 -0
- package/dist/skills/media-use/scripts/lib/specs.test.mjs +157 -0
- package/dist/skills/media-use/scripts/lib/stats.mjs +117 -0
- package/dist/skills/media-use/scripts/lib/stats.test.mjs +165 -0
- package/dist/skills/media-use/scripts/lib/telemetry.mjs +193 -0
- package/dist/skills/media-use/scripts/lib/telemetry.test.mjs +373 -0
- package/dist/skills/media-use/scripts/lib/tts-local-provider.mjs +92 -0
- package/dist/skills/media-use/scripts/lib/tts-local-provider.test.mjs +72 -0
- package/dist/skills/media-use/scripts/lib/usage.mjs +57 -0
- package/dist/skills/media-use/scripts/lib/usage.test.mjs +54 -0
- package/dist/skills/media-use/scripts/lib/voice-provider.mjs +57 -0
- package/dist/skills/media-use/scripts/lib/voice-provider.test.mjs +46 -0
- package/dist/skills/media-use/scripts/lib/words.mjs +18 -0
- package/dist/skills/media-use/scripts/prefs.mjs +70 -0
- package/dist/skills/media-use/scripts/recipe.mjs +103 -0
- package/dist/skills/media-use/scripts/resolve.mjs +1287 -0
- package/dist/skills/media-use/scripts/transcribe.mjs +180 -0
- package/dist/skills/media-use/scripts/transcript-cut.mjs +239 -0
- package/dist/skills/registry/localSemantic.js +548 -0
- package/dist/studio/assets/{hyperframes-player-zGyOcwwh.js → hyperframes-player-Di7GyCOP.js} +3 -3
- package/dist/studio/assets/{index-DKJpHYYd.css → index-CBKb_0TI.css} +1 -1
- package/dist/studio/assets/{index-d8ferjRc.js → index-Dpq2lkOm.js} +190 -190
- package/dist/studio/assets/{index-ZJaRCDYV.js → index-Dx_pt9m4.js} +1 -1
- package/dist/studio/assets/{index-BcE2OSVA.js → index-jAjhQTrB.js} +1 -1
- package/dist/studio/index.d.ts +549 -13
- package/dist/studio/index.html +2 -2
- package/dist/studio/index.js +23133 -21941
- package/dist/studio/index.js.map +1 -1
- package/dist/studio/styles.css +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as P}from"./index-
|
|
1
|
+
import{g as P}from"./index-Dpq2lkOm.js";function j(c,d){for(var s=0;s<d.length;s++){const a=d[s];if(typeof a!="string"&&!Array.isArray(a)){for(const i in a)if(i!=="default"&&!(i in c)){const l=Object.getOwnPropertyDescriptor(a,i);l&&Object.defineProperty(c,i,l.get?l:{enumerable:!0,get:()=>a[i]})}}}return Object.freeze(Object.defineProperty(c,Symbol.toStringTag,{value:"Module"}))}var v={},w;function k(){if(w)return v;w=1,Object.defineProperty(v,"__esModule",{value:!0}),v.default=d;var c=window.OfflineAudioContext||window.webkitOfflineAudioContext;function d(e){var r=a(e);return r.start(0),[i,y,O(e.sampleRate),s].reduce(function(t,o){return o(t)},r.buffer.getChannelData(0))}function s(e){return e.sort(function(r,t){return t.count-r.count}).splice(0,5)[0].tempo}function a(e){var r=e.length,t=e.numberOfChannels,o=e.sampleRate,n=new c(t,r,o),u=n.createBufferSource();u.buffer=e;var f=n.createBiquadFilter();return f.type="lowpass",u.connect(f),f.connect(n.destination),u}function i(e){for(var r=[],t=.9,o=.3,n=15;r.length<n&&t>=o;)r=l(e,t),t-=.05;if(r.length<n)throw new Error("Could not find enough samples for a reliable detection.");return r}function l(e,r){for(var t=[],o=0,n=e.length;o<n;o+=1)e[o]>r&&(t.push(o),o+=1e4);return t}function y(e){var r=[];return e.forEach(function(t,o){for(var n=function(x){var g=e[o+x]-t,_=r.some(function(h){if(h.interval===g)return h.count+=1});_||r.push({interval:g,count:1})},u=0;u<10;u+=1)n(u)}),r}function O(e){return function(r){var t=[];return r.forEach(function(o){if(o.interval!==0){for(var n=60/(o.interval/e);n<90;)n*=2;for(;n>180;)n/=2;n=Math.round(n);var u=t.some(function(f){if(f.tempo===n)return f.count+=o.count});u||t.push({tempo:n,count:o.count})}}),t}}return v}var p,b;function q(){return b||(b=1,p=k().default),p}var m=q();const A=P(m),D=j({__proto__:null,default:A},[m]);export{D as i};
|
package/dist/studio/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
|
-
import { ButtonHTMLAttributes, ReactNode, ElementType, ComponentPropsWithoutRef, ReactElement, RefObject, MutableRefObject } from 'react';
|
|
2
|
+
import { ButtonHTMLAttributes, ReactNode, ElementType, ComponentPropsWithoutRef, ReactElement, RefObject, MutableRefObject, DragEventHandler, ComponentProps, RefCallback, MouseEvent, CSSProperties, UIEvent, PointerEvent } from 'react';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import { Tabs as Tabs$1 } from '@base-ui/react/tabs';
|
|
5
5
|
import * as node_modules_cn_dist_types from 'node_modules/cn/dist/types';
|
|
@@ -8,9 +8,9 @@ import { Menu as Menu$1 } from '@base-ui/react/menu';
|
|
|
8
8
|
import { Popover as Popover$1 } from '@base-ui/react/popover';
|
|
9
9
|
import { RuntimeTimelineClipIdentity, HyperframePickerElementInfo } from '@hyperframes/core';
|
|
10
10
|
import { GsapAnimation, PropertyGroupName } from '@hyperframes/core/gsap-parser';
|
|
11
|
+
import { MusicBeatAnalysis } from '@hyperframes/core/beats';
|
|
11
12
|
import * as zustand from 'zustand';
|
|
12
13
|
import { StoreApi } from 'zustand';
|
|
13
|
-
import { MusicBeatAnalysis } from '@hyperframes/core/beats';
|
|
14
14
|
import { GsapAnimation as GsapAnimation$1, ArcPathSegment } from '@hyperframes/parsers/gsap-parser';
|
|
15
15
|
import { CanvasResolution } from '@hyperframes/parsers';
|
|
16
16
|
import { Composition } from '@hyperframes/sdk';
|
|
@@ -124,7 +124,6 @@ type PopupPreviewState = "open";
|
|
|
124
124
|
type PortalContainer$1 = ComponentPropsWithoutRef<typeof Menu$1.Portal>["container"];
|
|
125
125
|
/**
|
|
126
126
|
* Chrome shared by every floating panel (`Popover` too); callers add their own shadow token.
|
|
127
|
-
* `data-starting-style`/`data-ending-style` are Base UI's transition attributes.
|
|
128
127
|
*/
|
|
129
128
|
declare const popupSurface: string;
|
|
130
129
|
type MenuItemTone = "default" | "danger";
|
|
@@ -336,6 +335,8 @@ interface PlayerControlsProps {
|
|
|
336
335
|
}
|
|
337
336
|
declare const PlayerControls: react.NamedExoticComponent<PlayerControlsProps>;
|
|
338
337
|
|
|
338
|
+
declare function TimelineRulerPart(): react_jsx_runtime.JSX.Element;
|
|
339
|
+
|
|
339
340
|
interface UserBeat {
|
|
340
341
|
time: number;
|
|
341
342
|
strength: number;
|
|
@@ -566,13 +567,13 @@ interface PlaybackReadinessSlice {
|
|
|
566
567
|
}
|
|
567
568
|
declare function createPlaybackReadinessSlice(set: StoreApi<PlaybackReadinessSlice>["setState"]): PlaybackReadinessSlice;
|
|
568
569
|
|
|
569
|
-
interface TimelineTimeRange {
|
|
570
|
+
interface TimelineTimeRange$1 {
|
|
570
571
|
t0: number;
|
|
571
572
|
t1: number;
|
|
572
573
|
}
|
|
573
574
|
interface RangeSelectionSlice {
|
|
574
575
|
/** Shift-drag ruler range in seconds, normalized so t0 <= t1. */
|
|
575
|
-
rangeSelection: TimelineTimeRange | null;
|
|
576
|
+
rangeSelection: TimelineTimeRange$1 | null;
|
|
576
577
|
}
|
|
577
578
|
|
|
578
579
|
/**
|
|
@@ -629,6 +630,11 @@ interface TimelineElement {
|
|
|
629
630
|
playbackRate?: number;
|
|
630
631
|
sourceDuration?: number;
|
|
631
632
|
volume?: number;
|
|
633
|
+
/** `data-has-audio="true"` on a video: its sound is mixed, so it takes audio affordances (fades). */
|
|
634
|
+
hasAudio?: boolean;
|
|
635
|
+
/** Clip-edge fades from `data-fade-in` / `data-fade-out`, seconds; absent means none. */
|
|
636
|
+
fadeIn?: number;
|
|
637
|
+
fadeOut?: number;
|
|
632
638
|
/** Verbatim `data-fx-chain` / `data-automation`; see automationLaneData. */
|
|
633
639
|
fxChain?: string;
|
|
634
640
|
automation?: string;
|
|
@@ -1081,6 +1087,12 @@ interface TimelineStackingReorderIntent {
|
|
|
1081
1087
|
}
|
|
1082
1088
|
|
|
1083
1089
|
type BlockedTimelineEditIntent = "move" | "resize-start" | "resize-end";
|
|
1090
|
+
interface TimelineRangeSelection {
|
|
1091
|
+
start: number;
|
|
1092
|
+
end: number;
|
|
1093
|
+
anchorX: number;
|
|
1094
|
+
anchorY: number;
|
|
1095
|
+
}
|
|
1084
1096
|
|
|
1085
1097
|
/**
|
|
1086
1098
|
* Durability report for a patch-batches commit. `durable === false` means the
|
|
@@ -1280,6 +1292,12 @@ interface TimelineEditCallbacks {
|
|
|
1280
1292
|
onTogglePropertyGroupKeyframe?: (element: TimelineElement, target: TimelinePropertyGroupKeyframeToggle) => Promise<void> | void;
|
|
1281
1293
|
}
|
|
1282
1294
|
|
|
1295
|
+
interface TimelineTrackStyle {
|
|
1296
|
+
clip: string;
|
|
1297
|
+
accent: string;
|
|
1298
|
+
label: string;
|
|
1299
|
+
clipActive?: string;
|
|
1300
|
+
}
|
|
1283
1301
|
interface TimelineTheme {
|
|
1284
1302
|
shellBackground: string;
|
|
1285
1303
|
shellBorder: string;
|
|
@@ -1300,14 +1318,11 @@ interface TimelineTheme {
|
|
|
1300
1318
|
clipBorder: string;
|
|
1301
1319
|
clipBorderHover: string;
|
|
1302
1320
|
clipBorderActive: string;
|
|
1303
|
-
clipShadow: string;
|
|
1304
|
-
clipShadowHover: string;
|
|
1305
|
-
clipShadowActive: string;
|
|
1306
|
-
clipShadowDragging: string;
|
|
1307
1321
|
handleColor: string;
|
|
1308
1322
|
panelResizeSeam: string;
|
|
1309
1323
|
panelResizeActive: string;
|
|
1310
1324
|
clipRadius: string;
|
|
1325
|
+
audioClipRadius: string;
|
|
1311
1326
|
}
|
|
1312
1327
|
|
|
1313
1328
|
type TimelineEditOverrides = Pick<TimelineEditCallbacks, "onMoveElement" | "onMoveElements" | "onResizeElement" | "onResizeElements" | "onBlockedEditAttempt" | "onSplitElement">;
|
|
@@ -1332,7 +1347,7 @@ interface TimelineProps extends TimelineDropCallbacks, TimelineEditOverrides {
|
|
|
1332
1347
|
onDeleteElement?: (element: TimelineElement) => Promise<void> | void;
|
|
1333
1348
|
onSelectElement?: (element: TimelineElement | null) => void;
|
|
1334
1349
|
/** Notification only; null when cleared. The value lives in usePlayerStore.rangeSelection. */
|
|
1335
|
-
onRangeSelect?: (range: TimelineTimeRange | null) => void;
|
|
1350
|
+
onRangeSelect?: (range: TimelineTimeRange$1 | null) => void;
|
|
1336
1351
|
onCopyClip?: () => boolean;
|
|
1337
1352
|
onPasteClip?: () => Promise<void>;
|
|
1338
1353
|
onDuplicateClip?: () => Promise<boolean>;
|
|
@@ -1340,7 +1355,528 @@ interface TimelineProps extends TimelineDropCallbacks, TimelineEditOverrides {
|
|
|
1340
1355
|
theme?: Partial<TimelineTheme>;
|
|
1341
1356
|
}
|
|
1342
1357
|
|
|
1343
|
-
|
|
1358
|
+
interface TimelineEmptyStateProps {
|
|
1359
|
+
isDragOver: boolean;
|
|
1360
|
+
onFileDrop?: boolean;
|
|
1361
|
+
onDragOver: DragEventHandler<HTMLDivElement>;
|
|
1362
|
+
onDragLeave: DragEventHandler<HTMLDivElement>;
|
|
1363
|
+
onDrop: DragEventHandler<HTMLDivElement>;
|
|
1364
|
+
}
|
|
1365
|
+
declare function TimelineEmptyState({ isDragOver, onFileDrop, onDragOver, onDragLeave, onDrop, }: TimelineEmptyStateProps): react_jsx_runtime.JSX.Element;
|
|
1366
|
+
|
|
1367
|
+
interface Rect {
|
|
1368
|
+
left: number;
|
|
1369
|
+
top: number;
|
|
1370
|
+
width: number;
|
|
1371
|
+
height: number;
|
|
1372
|
+
}
|
|
1373
|
+
|
|
1374
|
+
type TimelineSnapType = "beat" | "playhead" | "clip-edge";
|
|
1375
|
+
interface TimelineSnapTarget {
|
|
1376
|
+
time: number;
|
|
1377
|
+
type: TimelineSnapType;
|
|
1378
|
+
}
|
|
1379
|
+
|
|
1380
|
+
interface DraggedClipState {
|
|
1381
|
+
/** Pointer captured by the stable viewport coordinator for this gesture. */
|
|
1382
|
+
pointerId: number;
|
|
1383
|
+
element: TimelineElement;
|
|
1384
|
+
originClientX: number;
|
|
1385
|
+
originClientY: number;
|
|
1386
|
+
originScrollLeft: number;
|
|
1387
|
+
originScrollTop: number;
|
|
1388
|
+
pointerClientX: number;
|
|
1389
|
+
pointerClientY: number;
|
|
1390
|
+
pointerOffsetX: number;
|
|
1391
|
+
pointerOffsetY: number;
|
|
1392
|
+
previewStart: number;
|
|
1393
|
+
previewTrack: number;
|
|
1394
|
+
/**
|
|
1395
|
+
* The lane the POINTER aims at (from the drag's vertical position), before
|
|
1396
|
+
* collision resolution. `previewTrack` is where the clip actually LANDS —
|
|
1397
|
+
* which may differ from `desiredTrack` when the aimed span is occupied and the
|
|
1398
|
+
* collision rules bump the dragged clip to a free lane. The commit reads this
|
|
1399
|
+
* to tell a deliberate VERTICAL lane change (pointer aimed at another lane →
|
|
1400
|
+
* stacking sync allowed) from a plain HORIZONTAL drag whose clip merely got
|
|
1401
|
+
* bumped sideways (never touches z). Optional: when absent the commit falls
|
|
1402
|
+
* back to `previewTrack` (pre-existing behaviour).
|
|
1403
|
+
*/
|
|
1404
|
+
desiredTrack?: number;
|
|
1405
|
+
/**
|
|
1406
|
+
* When non-null, the drop inserts a NEW track at this visual row boundary
|
|
1407
|
+
* (0 = above the top lane, trackOrder.length = below the bottom) instead of
|
|
1408
|
+
* landing on previewTrack. Drives the insertion-line indicator.
|
|
1409
|
+
*/
|
|
1410
|
+
insertRow: number | null;
|
|
1411
|
+
/** Snap target the clip will land on, for the guide highlight. */
|
|
1412
|
+
snapTime: number | null;
|
|
1413
|
+
snapType: TimelineSnapType | null;
|
|
1414
|
+
started: boolean;
|
|
1415
|
+
}
|
|
1416
|
+
interface ResizingClipState {
|
|
1417
|
+
/** Pointer captured by the stable viewport coordinator for this gesture. */
|
|
1418
|
+
pointerId: number;
|
|
1419
|
+
element: TimelineElement;
|
|
1420
|
+
edge: "start" | "end";
|
|
1421
|
+
originClientX: number;
|
|
1422
|
+
/**
|
|
1423
|
+
* scrollLeft at gesture start. Edge auto-scroll moves the content under a
|
|
1424
|
+
* stationary pointer, so the trim math folds (current − origin) scrollLeft
|
|
1425
|
+
* into the pointer x — mirroring resolveTimelineMove's scroll compensation.
|
|
1426
|
+
* Optional so pre-existing constructors/tests stay valid; when absent the
|
|
1427
|
+
* first preview update captures the current scrollLeft.
|
|
1428
|
+
*/
|
|
1429
|
+
originScrollLeft?: number;
|
|
1430
|
+
previewStart: number;
|
|
1431
|
+
previewDuration: number;
|
|
1432
|
+
previewPlaybackStart?: number;
|
|
1433
|
+
/** Snap target the trimmed edge landed on, for the guide highlight. */
|
|
1434
|
+
snapTime?: number | null;
|
|
1435
|
+
snapType?: TimelineSnapType | null;
|
|
1436
|
+
/** Coordinator-owned group projection; canonical elements change only on commit. */
|
|
1437
|
+
groupPreview?: readonly {
|
|
1438
|
+
key: string;
|
|
1439
|
+
start: number;
|
|
1440
|
+
duration: number;
|
|
1441
|
+
playbackStart?: number;
|
|
1442
|
+
}[];
|
|
1443
|
+
started: boolean;
|
|
1444
|
+
}
|
|
1445
|
+
interface BlockedClipState {
|
|
1446
|
+
pointerId: number;
|
|
1447
|
+
element: TimelineElement;
|
|
1448
|
+
intent: BlockedTimelineEditIntent;
|
|
1449
|
+
originClientX: number;
|
|
1450
|
+
originClientY: number;
|
|
1451
|
+
started: boolean;
|
|
1452
|
+
}
|
|
1453
|
+
|
|
1454
|
+
interface TimelineTimeRange {
|
|
1455
|
+
readonly start: number;
|
|
1456
|
+
readonly end: number;
|
|
1457
|
+
}
|
|
1458
|
+
interface TimelineClipInterval {
|
|
1459
|
+
readonly element: TimelineElement;
|
|
1460
|
+
readonly identity: string;
|
|
1461
|
+
readonly ordinal: number;
|
|
1462
|
+
readonly start: number;
|
|
1463
|
+
readonly end: number;
|
|
1464
|
+
}
|
|
1465
|
+
interface TimelineClipRowIndex {
|
|
1466
|
+
readonly byStart: readonly TimelineClipInterval[];
|
|
1467
|
+
readonly treeLeafCount: number;
|
|
1468
|
+
readonly maxPositiveEndTree: readonly number[];
|
|
1469
|
+
readonly maxPointStartTree: readonly number[];
|
|
1470
|
+
readonly byIdentity: ReadonlyMap<string, readonly TimelineClipInterval[]>;
|
|
1471
|
+
}
|
|
1472
|
+
interface TimelineClipIndex {
|
|
1473
|
+
readonly rows: ReadonlyMap<number, TimelineClipRowIndex>;
|
|
1474
|
+
}
|
|
1475
|
+
|
|
1476
|
+
interface TimelineRowGeometry {
|
|
1477
|
+
readonly rowKeys: readonly number[];
|
|
1478
|
+
readonly rowHeights: readonly number[];
|
|
1479
|
+
/** Cumulative row boundaries, including the final bottom boundary. */
|
|
1480
|
+
readonly rowOffsets: readonly number[];
|
|
1481
|
+
readonly rowsHeight: number;
|
|
1482
|
+
readonly canvasHeight: number;
|
|
1483
|
+
getRowIndex(rowKey: number): number;
|
|
1484
|
+
getRowHeight(row: number): number;
|
|
1485
|
+
getRowTop(row: number): number;
|
|
1486
|
+
getRowFromY(contentY: number): number;
|
|
1487
|
+
getRowPositionFromY(contentY: number): {
|
|
1488
|
+
rowFloat: number;
|
|
1489
|
+
row: number;
|
|
1490
|
+
fraction: number;
|
|
1491
|
+
rowHeight: number;
|
|
1492
|
+
};
|
|
1493
|
+
}
|
|
1494
|
+
|
|
1495
|
+
type TrackVisualStyle = TimelineTrackStyle;
|
|
1496
|
+
|
|
1497
|
+
interface TimelineVirtualRow {
|
|
1498
|
+
readonly index: number;
|
|
1499
|
+
readonly rowKey: number;
|
|
1500
|
+
}
|
|
1501
|
+
|
|
1502
|
+
/**
|
|
1503
|
+
* Pure geometry for the LIVE multi-selection drag preview.
|
|
1504
|
+
*
|
|
1505
|
+
* Visual model (matches main): while a selected clip is dragged, ALL selected
|
|
1506
|
+
* clips move together LIVE as one rigid formation following the cursor. The
|
|
1507
|
+
* GRABBED clip is drawn as the free-floating ghost; every OTHER selected member
|
|
1508
|
+
* ("passenger") slides by the SAME time delta via a cheap compositor
|
|
1509
|
+
* `translateX` (no re-layout). Passengers do NOT stay still, and they do NOT lag
|
|
1510
|
+
* behind individually — the whole formation moves by one delta, spacing locked.
|
|
1511
|
+
*
|
|
1512
|
+
* That single delta is the GRABBED clip's `draggedPreviewStart − draggedOriginStart`.
|
|
1513
|
+
* The preview start is ALREADY group-clamped upstream (updateDraggedClipPreview
|
|
1514
|
+
* runs clampGroupMoveDelta before setting it), so this delta is the clamped delta:
|
|
1515
|
+
* the instant any member would cross 0 the grabbed clip stops and every passenger
|
|
1516
|
+
* stops with it — the formation never deforms. On DROP the commit shifts every
|
|
1517
|
+
* selected clip by this same delta (see timelineClipDragCommit / useTimelineClipDrag).
|
|
1518
|
+
*
|
|
1519
|
+
* Track changes apply to the grabbed clip only (mirroring the commit); passengers
|
|
1520
|
+
* keep their lanes, so only their x moves.
|
|
1521
|
+
*/
|
|
1522
|
+
interface MultiDragPreviewInput {
|
|
1523
|
+
/** The drag is live (past the movement threshold). */
|
|
1524
|
+
dragStarted: boolean;
|
|
1525
|
+
/** Key of the clip under the pointer. */
|
|
1526
|
+
draggedKey: string;
|
|
1527
|
+
/** The dragged clip's committed start (pre-drag). */
|
|
1528
|
+
draggedOriginStart: number;
|
|
1529
|
+
/** The dragged clip's live preview start (already group-clamped upstream). */
|
|
1530
|
+
draggedPreviewStart: number;
|
|
1531
|
+
/** The current multi-selection (store.selectedElementIds). */
|
|
1532
|
+
selectedKeys: ReadonlySet<string>;
|
|
1533
|
+
}
|
|
1534
|
+
|
|
1535
|
+
/** One resolved audio group, positioned in the row order. */
|
|
1536
|
+
interface TimelineTrackGroupInfo {
|
|
1537
|
+
id: string;
|
|
1538
|
+
label: string;
|
|
1539
|
+
/**
|
|
1540
|
+
* Synthetic sort key for the group's own row — the same fractional-key
|
|
1541
|
+
* convention sub-composition expansion already uses (see
|
|
1542
|
+
* timelineTrackDisplay.ts): the first (lowest) member track's number minus
|
|
1543
|
+
* 0.5, so it slots in immediately above that member.
|
|
1544
|
+
*/
|
|
1545
|
+
anchorKey: number;
|
|
1546
|
+
/** Member track numbers, ascending. */
|
|
1547
|
+
memberTracks: number[];
|
|
1548
|
+
/**
|
|
1549
|
+
* Every clip under this group, in member-track order — INDEPENDENT of whether
|
|
1550
|
+
* the group is expanded.
|
|
1551
|
+
*
|
|
1552
|
+
* Collapsing a group stops emitting its member rows into `tracks`, so anything
|
|
1553
|
+
* that recovered member elements by looking them up there got an empty list in
|
|
1554
|
+
* the default (collapsed) state — silently disabling the
|
|
1555
|
+
* automation-lane count, and the bus strip's member labels. Membership is not
|
|
1556
|
+
* a display concern, so it does not travel through the display list.
|
|
1557
|
+
*/
|
|
1558
|
+
memberElements: TimelineElement[];
|
|
1559
|
+
/** The group element's `data-volume`, mirrored from a member's parse (B7's slider). */
|
|
1560
|
+
volume: number;
|
|
1561
|
+
/** The group element's `data-hidden`, mirrored from a member's parse (B5's group mute). */
|
|
1562
|
+
hidden: boolean;
|
|
1563
|
+
/** The group element's serialized `data-fx-chain`, mirrored from a member's parse (C1's FX entry). */
|
|
1564
|
+
fxChain?: string;
|
|
1565
|
+
/** The group element's serialized `data-automation` — the group's OWN lanes,
|
|
1566
|
+
* which are what its `∿` discloses (groups doc §5). */
|
|
1567
|
+
automation?: string;
|
|
1568
|
+
}
|
|
1569
|
+
|
|
1570
|
+
interface TimelineLogicalItem {
|
|
1571
|
+
id: string;
|
|
1572
|
+
kind: "clip" | "keyframe" | "ease";
|
|
1573
|
+
rowId: string;
|
|
1574
|
+
elementId: string;
|
|
1575
|
+
/** The item's time anchor. Clips use their midpoint; ease controls use the segment midpoint. */
|
|
1576
|
+
time: number;
|
|
1577
|
+
keyframeTarget?: TimelineKeyframeTarget;
|
|
1578
|
+
}
|
|
1579
|
+
interface TimelineLogicalRow {
|
|
1580
|
+
id: string;
|
|
1581
|
+
kind: "row";
|
|
1582
|
+
physicalTrackKey: number;
|
|
1583
|
+
logicalIndex: number;
|
|
1584
|
+
level: 1 | 2 | 3;
|
|
1585
|
+
parentId: string | null;
|
|
1586
|
+
elementId: string | null;
|
|
1587
|
+
/** Set only on a group's own row (level 1, no clips of its own). */
|
|
1588
|
+
groupId?: string;
|
|
1589
|
+
expandable: boolean;
|
|
1590
|
+
expanded: boolean;
|
|
1591
|
+
propertyGroup?: PropertyGroupName;
|
|
1592
|
+
items: readonly TimelineLogicalItem[];
|
|
1593
|
+
}
|
|
1594
|
+
|
|
1595
|
+
/**
|
|
1596
|
+
* Props shared by the scroll container ({@link import("./TimelineCanvas")}) and
|
|
1597
|
+
* the lane renderer ({@link import("./TimelineLanes")}). TimelineCanvas passes
|
|
1598
|
+
* these straight through via spread, so they are declared once here and both
|
|
1599
|
+
* prop types compose from this base — no duplicated prop list. Kept in its own
|
|
1600
|
+
* module so neither side has to import the other just to name the contract.
|
|
1601
|
+
*/
|
|
1602
|
+
interface TimelineLaneBaseProps {
|
|
1603
|
+
pps: number;
|
|
1604
|
+
contentOrigin: number;
|
|
1605
|
+
contentGutter: number;
|
|
1606
|
+
trackContentWidth: number;
|
|
1607
|
+
theme: TimelineTheme;
|
|
1608
|
+
displayTrackOrder: number[];
|
|
1609
|
+
rowHeights: readonly number[];
|
|
1610
|
+
rowGeometry: TimelineRowGeometry;
|
|
1611
|
+
virtualRows: readonly TimelineVirtualRow[];
|
|
1612
|
+
logicalRows: readonly TimelineLogicalRow[];
|
|
1613
|
+
focusedTargetId: string | null;
|
|
1614
|
+
rowsVirtualized: boolean;
|
|
1615
|
+
clipIndex: TimelineClipIndex;
|
|
1616
|
+
renderTimeRange: TimelineTimeRange;
|
|
1617
|
+
visibleTimeRange: TimelineTimeRange;
|
|
1618
|
+
pinnedClipIdentities: ReadonlySet<string>;
|
|
1619
|
+
trackOrder: number[];
|
|
1620
|
+
tracks: [number, TimelineElement[]][];
|
|
1621
|
+
trackStyles: Map<number, TrackVisualStyle>;
|
|
1622
|
+
laneCounts: ReadonlyMap<string, number>;
|
|
1623
|
+
selectedElementId: string | null;
|
|
1624
|
+
selectedElementIds: Set<string>;
|
|
1625
|
+
hoveredClip: string | null;
|
|
1626
|
+
draggedClip: DraggedClipState | null;
|
|
1627
|
+
blockedClipRef: React.RefObject<BlockedClipState | null>;
|
|
1628
|
+
suppressClickRef: React.RefObject<boolean>;
|
|
1629
|
+
scrollRef: React.RefObject<HTMLDivElement | null>;
|
|
1630
|
+
renderClipContent?: (element: TimelineElement, style: {
|
|
1631
|
+
clip: string;
|
|
1632
|
+
label: string;
|
|
1633
|
+
}, context: TimelineClipRenderContext) => ReactNode;
|
|
1634
|
+
renderClipOverlay?: (element: TimelineElement) => ReactNode;
|
|
1635
|
+
onDrillDown?: (element: TimelineElement) => void;
|
|
1636
|
+
onSelectElement?: (element: TimelineElement | null) => void;
|
|
1637
|
+
setHoveredClip: (key: string | null) => void;
|
|
1638
|
+
setShowPopover: (v: boolean) => void;
|
|
1639
|
+
setRangeSelection: (v: null) => void;
|
|
1640
|
+
setResizingClip: (v: ResizingClipState | null) => void;
|
|
1641
|
+
setDraggedClip: (v: DraggedClipState | null) => void;
|
|
1642
|
+
setSelectedElementId: (id: string | null) => void;
|
|
1643
|
+
shiftClickClipRef: React.RefObject<{
|
|
1644
|
+
element: TimelineElement;
|
|
1645
|
+
anchorX: number;
|
|
1646
|
+
anchorY: number;
|
|
1647
|
+
} | null>;
|
|
1648
|
+
getPreviewElement: (element: TimelineElement) => TimelineElement;
|
|
1649
|
+
getTrackStyle: (tag: string) => TrackVisualStyle;
|
|
1650
|
+
keyframeCache?: Map<string, KeyframeCacheEntry>;
|
|
1651
|
+
gsapAnimations: Map<string, GsapAnimation[]>;
|
|
1652
|
+
selectedKeyframes: Set<string>;
|
|
1653
|
+
currentTime: number;
|
|
1654
|
+
onSeek?: (time: number) => void;
|
|
1655
|
+
onSelectSegment?: (elementId: string, target: TimelineKeyframeTarget) => void;
|
|
1656
|
+
onClickKeyframe?: (element: TimelineElement, target: TimelineKeyframeTarget) => void;
|
|
1657
|
+
onShiftClickKeyframe?: (elementId: string, target: TimelineKeyframeTarget) => void;
|
|
1658
|
+
onContextMenuKeyframe?: (e: React.MouseEvent, elementId: string, target: TimelineKeyframeTarget) => void;
|
|
1659
|
+
onMoveKeyframe?: (elementId: string, keyframe: TimelineKeyframeTarget, toClipPercentage: number, propertyGroup?: string, tweenPercentage?: number, animationId?: string) => Promise<boolean>;
|
|
1660
|
+
onContextMenuClip?: (e: React.MouseEvent, element: TimelineElement) => void;
|
|
1661
|
+
/**
|
|
1662
|
+
* Right-click on EMPTY lane space (not on a clip — those preventDefault
|
|
1663
|
+
* before this fires — not the gutter/ruler, not below the lanes). `time` is
|
|
1664
|
+
* the timeline time (seconds) under the pointer on that lane.
|
|
1665
|
+
*/
|
|
1666
|
+
onContextMenuLane?: (e: React.MouseEvent, track: number, time: number) => void;
|
|
1667
|
+
beatAnalysis?: MusicBeatAnalysis | null;
|
|
1668
|
+
/** Resolved audio groups, positioned in row order — see useTimelineTrackDerivations. */
|
|
1669
|
+
groups: readonly TimelineTrackGroupInfo[];
|
|
1670
|
+
}
|
|
1671
|
+
|
|
1672
|
+
/** An empty interval on the lane, [start, end) in seconds. */
|
|
1673
|
+
interface TrackGapInterval {
|
|
1674
|
+
start: number;
|
|
1675
|
+
end: number;
|
|
1676
|
+
}
|
|
1677
|
+
|
|
1678
|
+
/**
|
|
1679
|
+
* One lane's gap strips for the TimelineCanvas overlay.
|
|
1680
|
+
*
|
|
1681
|
+
* kind "hover" — the gap(s) a hovered "Close gap" / "Close all gaps" menu
|
|
1682
|
+
* row would collapse: the loud affordance.
|
|
1683
|
+
* kind "selected" — every empty interval on a click-selected clip's lane: the
|
|
1684
|
+
* quiet always-on hint (single click-selection only — a
|
|
1685
|
+
* marquee multi-select spans lanes and would paint noise).
|
|
1686
|
+
*/
|
|
1687
|
+
interface TimelineLaneGapStrips {
|
|
1688
|
+
track: number;
|
|
1689
|
+
intervals: TrackGapInterval[];
|
|
1690
|
+
kind: "hover" | "selected";
|
|
1691
|
+
}
|
|
1692
|
+
|
|
1693
|
+
interface KeyframeDiamondContextMenuState {
|
|
1694
|
+
x: number;
|
|
1695
|
+
y: number;
|
|
1696
|
+
/** Timeline project session that created this portaled target. */
|
|
1697
|
+
sessionEpoch?: number;
|
|
1698
|
+
element: TimelineElement;
|
|
1699
|
+
elementId: string;
|
|
1700
|
+
percentage: number;
|
|
1701
|
+
tweenPercentage?: number;
|
|
1702
|
+
propertyGroup?: string;
|
|
1703
|
+
animationId?: string;
|
|
1704
|
+
currentEase?: string;
|
|
1705
|
+
}
|
|
1706
|
+
|
|
1707
|
+
type TimelineCanvasState = Omit<TimelineLaneBaseProps, "setRangeSelection" | "setResizingClip" | "setDraggedClip" | "renderClipContent" | "renderClipOverlay"> & {
|
|
1708
|
+
major: number[];
|
|
1709
|
+
minor: number[];
|
|
1710
|
+
totalH: number;
|
|
1711
|
+
effectiveDuration: number;
|
|
1712
|
+
majorTickInterval: number;
|
|
1713
|
+
rangeSelection: TimelineRangeSelection | null;
|
|
1714
|
+
marqueeRect: Rect | null;
|
|
1715
|
+
resizingClip: ResizingClipState | null;
|
|
1716
|
+
isScrubbing: boolean;
|
|
1717
|
+
playheadRef: React.RefObject<HTMLDivElement | null>;
|
|
1718
|
+
laneGapStrips: TimelineLaneGapStrips[];
|
|
1719
|
+
dropPreview: TimelineDropPlacement | null;
|
|
1720
|
+
setRangeSelection: (value: TimelineRangeSelection | null) => void;
|
|
1721
|
+
setResizingClip: (value: ResizingClipState | null) => void;
|
|
1722
|
+
setDraggedClip: (value: TimelineLaneBaseProps["draggedClip"]) => void;
|
|
1723
|
+
beatDragging: boolean;
|
|
1724
|
+
onResizeElement: TimelineEditCallbacks["onResizeElement"];
|
|
1725
|
+
onMoveElement: TimelineEditCallbacks["onMoveElement"];
|
|
1726
|
+
draggedElement: TimelineElement | null;
|
|
1727
|
+
snapGuide: TimelineSnapTarget | null;
|
|
1728
|
+
multiDragPreview: MultiDragPreviewInput | null;
|
|
1729
|
+
onToggleTrackHidden: TimelineEditCallbacks["onToggleTrackHidden"];
|
|
1730
|
+
onTogglePropertyGroupKeyframe: TimelineEditCallbacks["onTogglePropertyGroupKeyframe"];
|
|
1731
|
+
onRazorSplit: TimelineEditCallbacks["onRazorSplit"];
|
|
1732
|
+
onRazorSplitAll: TimelineEditCallbacks["onRazorSplitAll"];
|
|
1733
|
+
};
|
|
1734
|
+
interface ClipContextMenuState {
|
|
1735
|
+
x: number;
|
|
1736
|
+
y: number;
|
|
1737
|
+
element: TimelineElement;
|
|
1738
|
+
sessionEpoch: number;
|
|
1739
|
+
}
|
|
1740
|
+
interface TrackGapContextMenuState {
|
|
1741
|
+
x: number;
|
|
1742
|
+
y: number;
|
|
1743
|
+
gapWidth: number | null;
|
|
1744
|
+
canCloseGap: boolean;
|
|
1745
|
+
canCloseAllGaps: boolean;
|
|
1746
|
+
hasAnyGaps: boolean;
|
|
1747
|
+
}
|
|
1748
|
+
interface TimelineOverlaysState {
|
|
1749
|
+
elements: readonly TimelineElement[];
|
|
1750
|
+
elementsRef: {
|
|
1751
|
+
current: readonly TimelineElement[];
|
|
1752
|
+
};
|
|
1753
|
+
theme: TimelineTheme;
|
|
1754
|
+
showShortcutHint: boolean;
|
|
1755
|
+
showPopover: boolean;
|
|
1756
|
+
rangeSelection: TimelineRangeSelection | null;
|
|
1757
|
+
setShowPopover: (value: boolean) => void;
|
|
1758
|
+
setRangeSelection: (value: TimelineRangeSelection | null) => void;
|
|
1759
|
+
kfContextMenu: KeyframeDiamondContextMenuState | null;
|
|
1760
|
+
setKfContextMenu: (value: KeyframeDiamondContextMenuState | null) => void;
|
|
1761
|
+
onDeleteKeyframe: TimelineEditCallbacks["onDeleteKeyframe"];
|
|
1762
|
+
onDeleteAllKeyframes: TimelineEditCallbacks["onDeleteAllKeyframes"];
|
|
1763
|
+
onMoveKeyframeToPlayhead: TimelineEditCallbacks["onMoveKeyframeToPlayhead"];
|
|
1764
|
+
clipContextMenu: ClipContextMenuState | null;
|
|
1765
|
+
setClipContextMenu: (value: ClipContextMenuState | null) => void;
|
|
1766
|
+
currentTime: number;
|
|
1767
|
+
onSplitElement: TimelineEditCallbacks["onSplitElement"];
|
|
1768
|
+
pinZoomBeforeEdit: () => void;
|
|
1769
|
+
onDeleteElement?: (element: TimelineElement) => Promise<void> | void;
|
|
1770
|
+
onCopyClip?: () => boolean;
|
|
1771
|
+
onPasteClip?: () => Promise<void>;
|
|
1772
|
+
onDuplicateClip?: () => Promise<boolean>;
|
|
1773
|
+
canPasteClip?: () => boolean;
|
|
1774
|
+
gapContextMenu: TrackGapContextMenuState | null;
|
|
1775
|
+
onDismissGapContextMenu: () => void;
|
|
1776
|
+
onCloseTrackGap: () => void;
|
|
1777
|
+
onCloseAllTrackGaps: () => void;
|
|
1778
|
+
onHoverGapAction: (action: "close-gap" | "close-all" | null) => void;
|
|
1779
|
+
}
|
|
1780
|
+
interface TimelineContainerProps {
|
|
1781
|
+
ref: RefCallback<HTMLDivElement>;
|
|
1782
|
+
"aria-label": string;
|
|
1783
|
+
"data-timeline-element-count": number;
|
|
1784
|
+
className: string;
|
|
1785
|
+
onMouseMove: (event: MouseEvent<HTMLDivElement>) => void;
|
|
1786
|
+
onMouseLeave: () => void;
|
|
1787
|
+
style: CSSProperties;
|
|
1788
|
+
}
|
|
1789
|
+
interface TimelineViewportProps {
|
|
1790
|
+
ref: RefCallback<HTMLDivElement>;
|
|
1791
|
+
"data-timeline-scroll-viewport": boolean;
|
|
1792
|
+
"data-timeline-auto-scroll-left-inset": number;
|
|
1793
|
+
tabIndex: number;
|
|
1794
|
+
className: string;
|
|
1795
|
+
onScroll: (event: UIEvent<HTMLDivElement>) => void;
|
|
1796
|
+
onFocus: (event: React.FocusEvent<HTMLDivElement>) => void;
|
|
1797
|
+
onBlur: (event: React.FocusEvent<HTMLDivElement>) => void;
|
|
1798
|
+
onDragOver: (event: React.DragEvent<HTMLDivElement>) => void;
|
|
1799
|
+
onDragLeave: (event: React.DragEvent<HTMLDivElement>) => void;
|
|
1800
|
+
onDrop: (event: React.DragEvent<HTMLDivElement>) => void;
|
|
1801
|
+
onPointerDown: (event: PointerEvent<HTMLDivElement>) => void;
|
|
1802
|
+
onPointerMove: (event: PointerEvent<HTMLDivElement>) => void;
|
|
1803
|
+
onPointerUp: (event: PointerEvent<HTMLDivElement>) => void;
|
|
1804
|
+
onPointerCancel: (event: PointerEvent<HTMLDivElement>) => void;
|
|
1805
|
+
onLostPointerCapture: (event: PointerEvent<HTMLDivElement>) => void;
|
|
1806
|
+
}
|
|
1807
|
+
interface TimelineState {
|
|
1808
|
+
timelineReady: boolean;
|
|
1809
|
+
elements: readonly TimelineElement[];
|
|
1810
|
+
selectedElementId: string | null;
|
|
1811
|
+
sessionEpoch: number;
|
|
1812
|
+
keyframeCache: Map<string, KeyframeCacheEntry>;
|
|
1813
|
+
canvas: TimelineCanvasState;
|
|
1814
|
+
overlays: TimelineOverlaysState;
|
|
1815
|
+
}
|
|
1816
|
+
interface TimelineActions {
|
|
1817
|
+
renderClipContent: TimelineLaneBaseProps["renderClipContent"];
|
|
1818
|
+
renderClipOverlay: TimelineLaneBaseProps["renderClipOverlay"];
|
|
1819
|
+
setFocusedEaseSegment: (target: {
|
|
1820
|
+
animationId: string;
|
|
1821
|
+
collidingAnimationTargets?: AnimationKeyframeTarget[];
|
|
1822
|
+
tweenPercentage: number;
|
|
1823
|
+
elementId: string;
|
|
1824
|
+
}) => void;
|
|
1825
|
+
}
|
|
1826
|
+
interface TimelineMeta {
|
|
1827
|
+
emptyState: ComponentProps<typeof TimelineEmptyState>;
|
|
1828
|
+
containerProps: TimelineContainerProps;
|
|
1829
|
+
viewportProps: TimelineViewportProps;
|
|
1830
|
+
razorGuide: ReactNode;
|
|
1831
|
+
}
|
|
1832
|
+
interface TimelineContextValue {
|
|
1833
|
+
state: TimelineState;
|
|
1834
|
+
actions: TimelineActions;
|
|
1835
|
+
meta: TimelineMeta;
|
|
1836
|
+
}
|
|
1837
|
+
declare function TimelineProvider({ children, ...props }: TimelineProps & {
|
|
1838
|
+
children: ReactNode;
|
|
1839
|
+
}): react_jsx_runtime.JSX.Element;
|
|
1840
|
+
declare function useTimelineContext(): TimelineContextValue;
|
|
1841
|
+
|
|
1842
|
+
declare function TimelineOverlays(): react_jsx_runtime.JSX.Element;
|
|
1843
|
+
|
|
1844
|
+
/** The provider-backed canvas shell. */
|
|
1845
|
+
declare function TimelineFrame(): react_jsx_runtime.JSX.Element;
|
|
1846
|
+
/** The provider-backed ruler. */
|
|
1847
|
+
declare const TimelineRuler: typeof TimelineRulerPart;
|
|
1848
|
+
/**
|
|
1849
|
+
* The provider-backed lane renderer. TimelineFrame remains the composed Studio
|
|
1850
|
+
* canvas; this part is exported for hosts that own the canvas arrangement.
|
|
1851
|
+
*/
|
|
1852
|
+
declare function TimelineLanes(): react_jsx_runtime.JSX.Element;
|
|
1853
|
+
/** The provider-backed playhead indicator. */
|
|
1854
|
+
declare function TimelinePlayhead(): react_jsx_runtime.JSX.Element;
|
|
1855
|
+
/** The provider-backed razor guide. */
|
|
1856
|
+
declare function TimelineRazorGuide(): react.ReactNode;
|
|
1857
|
+
|
|
1858
|
+
declare function TimelineEmptyStatePart(): react_jsx_runtime.JSX.Element;
|
|
1859
|
+
declare function TimelineShortcutHint(): react_jsx_runtime.JSX.Element;
|
|
1860
|
+
declare function TimelineEditPopover(): react_jsx_runtime.JSX.Element;
|
|
1861
|
+
declare function TimelineClipMenu(): react_jsx_runtime.JSX.Element;
|
|
1862
|
+
declare function TimelineKeyframeMenu(): react_jsx_runtime.JSX.Element;
|
|
1863
|
+
declare function TimelineGapMenu(): react_jsx_runtime.JSX.Element;
|
|
1864
|
+
|
|
1865
|
+
declare const Timeline: react.NamedExoticComponent<TimelineProps> & {
|
|
1866
|
+
Provider: typeof TimelineProvider;
|
|
1867
|
+
Frame: typeof TimelineFrame;
|
|
1868
|
+
Ruler: typeof TimelineRulerPart;
|
|
1869
|
+
Lanes: typeof TimelineLanes;
|
|
1870
|
+
Playhead: typeof TimelinePlayhead;
|
|
1871
|
+
RazorGuide: typeof TimelineRazorGuide;
|
|
1872
|
+
ShortcutHint: typeof TimelineShortcutHint;
|
|
1873
|
+
EditPopover: typeof TimelineEditPopover;
|
|
1874
|
+
ClipMenu: typeof TimelineClipMenu;
|
|
1875
|
+
KeyframeMenu: typeof TimelineKeyframeMenu;
|
|
1876
|
+
GapMenu: typeof TimelineGapMenu;
|
|
1877
|
+
EmptyState: typeof TimelineEmptyStatePart;
|
|
1878
|
+
Overlays: typeof TimelineOverlays;
|
|
1879
|
+
};
|
|
1344
1880
|
|
|
1345
1881
|
type ThumbnailPriority = "overscan" | "visible" | "interaction";
|
|
1346
1882
|
|
|
@@ -2287,7 +2823,7 @@ interface TimelinePaneProps {
|
|
|
2287
2823
|
onCompositionDrop?: (sourcePath: string, placement: Pick<TimelineElement, "start" | "track">) => Promise<void> | void;
|
|
2288
2824
|
onBlockedEditAttempt?: (element: TimelineElement, intent: BlockedTimelineEditIntent) => void;
|
|
2289
2825
|
onSelectTimelineElement?: (element: TimelineElement | null) => void;
|
|
2290
|
-
onRangeSelect?: (range: TimelineTimeRange | null) => void;
|
|
2826
|
+
onRangeSelect?: (range: TimelineTimeRange$1 | null) => void;
|
|
2291
2827
|
/** Copy/paste/duplicate act on the store's own selection, not a passed
|
|
2292
2828
|
* element, so unlike onDeleteElement they need no composition-basis wrapper. */
|
|
2293
2829
|
onCopyClip?: () => boolean;
|
|
@@ -2302,4 +2838,4 @@ declare function TimelineEditProvider({ value, children, }: {
|
|
|
2302
2838
|
children: ReactNode;
|
|
2303
2839
|
}): react_jsx_runtime.JSX.Element;
|
|
2304
2840
|
|
|
2305
|
-
export { type AgentModalAnchorPoint, type AgentPromptElementInfo, AskAgentModal, type AskAgentModalProps, type BlockedTimelineEditIntent, Button, type ButtonSize, type ButtonVariant, type CanEditTimelineElement, CompositionBreadcrumb, type CompositionDimensions, type CompositionLevel, CompositionThumbnail, ContextMenu, type EditHistoryHandle, EditorShell, type EditorShellProps, type ExternalFileChangeBlockedState, type ExternalFileChangeCoordinatorHandle, ExternalFileConflictBanner, type FfmpegStatus, FileTree, GridOverlay, HyperframesLoader, type HyperframesLoaderProps, HyperframesLogo, IconButton, Input, type InputProps, Menu, MenuItem, type MenuItemTone, MenuRadioGroup, MenuRadioItem, MenuSeparator, MenuShortcut, NLEPreview, NumberField, type NumberFieldProps, type PatchOperation, type PersistedRenderSettings, type PickedElement, Player, PlayerControls, type PlayerHandle, type PlayerHandleElement, type PlayerHandleListener, type PlayerHandleTimeListener, Popover, type PopupPreviewState, type DomEditCompositionRect as PreviewCompositionRect, PreviewGuides, PreviewOverlayProvider, type PreviewOverlayProviderProps, type PreviewSnapPreferences, type PreviewState, PropertyPanel, type RenderJob, RenderQueue, type RenderQueueProps, type ResolutionPreset, Select, type SelectOption, type SelectProps, Slider, type SliderProps, SnapToolbar, SourceEditor, type StartRenderOptions, StudioApp, StudioFileConflictError, type StudioPendingEditsDrainResult, Tab, TabPanel, Tabs, TabsList, Timeline, type TimelineEditCallbacks, type TimelineEditPermission, TimelineEditProvider, type TimelineElement, TimelinePane, type TimelinePaneProps, type TimelineTimeRange, Toggle, type ToggleProps, Tooltip, type UseEditHistoryActionsOptions, type UsePersistentEditHistoryOptions, type UseProjectFileWriterOptions, type UseTimelineEditingOptions, VideoThumbnail, applyPatch, buildPickerAgentContextPreview, buildPickerAgentPrompt, buttonBase, buttonSizes, buttonVariants, cn, fieldBase, fieldText, findElementBlock, flushStudioPendingEdits, formatTime, getPersistedRenderSettings, liveTime, mergeStyleIntoTag, parseStyleString, persistRenderSettings, popupSurface, resolveIframe, resolveSourceFile, useEditHistoryActions, useElementPicker, usePersistentEditHistory, usePlayerHandle, usePlayerStore, usePreviewCompositionRect, usePreviewGuidesStore, usePreviewOverlayContext, useProjectFileWriter, useRenderQueue, useTimelineEditing, useTimelinePlayer };
|
|
2841
|
+
export { type AgentModalAnchorPoint, type AgentPromptElementInfo, AskAgentModal, type AskAgentModalProps, type BlockedTimelineEditIntent, Button, type ButtonSize, type ButtonVariant, type CanEditTimelineElement, CompositionBreadcrumb, type CompositionDimensions, type CompositionLevel, CompositionThumbnail, ContextMenu, type EditHistoryHandle, EditorShell, type EditorShellProps, type ExternalFileChangeBlockedState, type ExternalFileChangeCoordinatorHandle, ExternalFileConflictBanner, type FfmpegStatus, FileTree, GridOverlay, HyperframesLoader, type HyperframesLoaderProps, HyperframesLogo, IconButton, Input, type InputProps, Menu, MenuItem, type MenuItemTone, MenuRadioGroup, MenuRadioItem, MenuSeparator, MenuShortcut, NLEPreview, NumberField, type NumberFieldProps, type PatchOperation, type PersistedRenderSettings, type PickedElement, Player, PlayerControls, type PlayerHandle, type PlayerHandleElement, type PlayerHandleListener, type PlayerHandleTimeListener, Popover, type PopupPreviewState, type DomEditCompositionRect as PreviewCompositionRect, PreviewGuides, PreviewOverlayProvider, type PreviewOverlayProviderProps, type PreviewSnapPreferences, type PreviewState, PropertyPanel, type RenderJob, RenderQueue, type RenderQueueProps, type ResolutionPreset, Select, type SelectOption, type SelectProps, Slider, type SliderProps, SnapToolbar, SourceEditor, type StartRenderOptions, StudioApp, StudioFileConflictError, type StudioPendingEditsDrainResult, Tab, TabPanel, Tabs, TabsList, Timeline, TimelineClipMenu, type TimelineEditCallbacks, type TimelineEditPermission, TimelineEditPopover, TimelineEditProvider, type TimelineElement, TimelineEmptyStatePart, TimelineFrame, TimelineGapMenu, TimelineKeyframeMenu, TimelineLanes, TimelineOverlays, TimelinePane, type TimelinePaneProps, TimelinePlayhead, TimelineProvider, TimelineRazorGuide, TimelineRuler, TimelineShortcutHint, type TimelineTheme, type TimelineTimeRange$1 as TimelineTimeRange, Toggle, type ToggleProps, Tooltip, type UseEditHistoryActionsOptions, type UsePersistentEditHistoryOptions, type UseProjectFileWriterOptions, type UseTimelineEditingOptions, VideoThumbnail, applyPatch, buildPickerAgentContextPreview, buildPickerAgentPrompt, buttonBase, buttonSizes, buttonVariants, cn, fieldBase, fieldText, findElementBlock, flushStudioPendingEdits, formatTime, getPersistedRenderSettings, liveTime, mergeStyleIntoTag, parseStyleString, persistRenderSettings, popupSurface, resolveIframe, resolveSourceFile, useEditHistoryActions, useElementPicker, usePersistentEditHistory, usePlayerHandle, usePlayerStore, usePreviewCompositionRect, usePreviewGuidesStore, usePreviewOverlayContext, useProjectFileWriter, useRenderQueue, useTimelineContext, useTimelineEditing, useTimelinePlayer };
|