import { TimelineClipEntry as TimelineClipEntry$1 } from "./timelineClipModel.mjs"; import { Clip, TimelineCommandResult, TimelineEngine, TimelineReadonly } from "@techsquidtv/canvas-timeline-core"; //#region src/hooks/clips/useTimelineClips.d.ts /** Editable clip presentation fields; structural edits belong to `useTimelineEditCommands`. */ type TimelineClipUpdate = Partial>; /** Clip collection, lookup, edit capabilities, and presentation commands. */ interface UseTimelineClipsResult { /** Flattened clips in timeline track order. */ clips: TimelineReadonly[]; /** Looks up a clip and its containing track in current engine state. */ getClip: TimelineEngine['geometry']['getClip']; /** Whether the clip and its track allow movement. */ canMoveClip: (clipId: string) => boolean; /** Whether the clip and its track allow trimming. */ canTrimClip: (clipId: string) => boolean; /** Whether the clip and its track allow source slipping. */ canSlipClip: (clipId: string) => boolean; /** Whether the clip and its track allow sliding. */ canSlideClip: (clipId: string) => boolean; /** Updates clip presentation through the engine's validated command API. */ updateClip: (clipId: string, properties: TimelineClipUpdate) => TimelineCommandResult; } /** * Reads clip collection state without subscribing to viewport or playback updates. * * Compose `useTimelineSelection` for selection, geometry hooks for reactive rectangles, * and `useTimelineEngine().media` for imperative source-time mapping. * @returns Clip entries, current lookups, capabilities, and presentation commands. * @example * ```tsx * import { useTimelineClips, useTimelineSelection } from '@techsquidtv/canvas-timeline-react'; * export function ClipLabelEditor() { * const { selectedClip } = useTimelineSelection(); * const { updateClip } = useTimelineClips(); * return selectedClip ? updateClip(selectedClip.id, { label: event.target.value })} /> : null; * } * ``` */ declare function useTimelineClips(): UseTimelineClipsResult; //#endregion export { TimelineClipUpdate, UseTimelineClipsResult, useTimelineClips }; //# sourceMappingURL=useTimelineClips.d.mts.map