import { ActiveLayerOptions, ActiveLayerResult } from "@techsquidtv/canvas-timeline-core"; //#region src/hooks/clips/useActiveLayers.d.ts /** * Returns active timeline layers at a timeline time. * * @remarks * * The hook is collection-first: each named layer returns every matching active * clip in stable track order. `primary` is only a convenience first match. * Use it for preview panels, custom media status, subtitle overlays, and * diagnostics that need to inspect which timeline clips are active without * starting playback. For transport controls that drive an external media clock, * compose {@link useTimelineMediaSync} or {@link useTimelineMediaPlayback} * instead. * * @param options - Active layer selectors and optional lookup time. * @template LayerName - Named layer keys inferred from `options.layers`, such * as `"visuals" | "audio"`. * @returns Active clips grouped by the configured layer selectors. * * @example * ```tsx * import { useMemo } from 'react'; * import { useActiveLayers } from '@techsquidtv/canvas-timeline-react'; * * const previewLayers = { * visuals: { trackKind: 'visual' }, * audio: { trackKind: 'audio' }, * } as const; * * export function ActiveMediaReadout() { * const layers = useMemo(() => previewLayers, []); * const activeLayers = useActiveLayers({ layers }); * * return ( *