import type { CanvasSelectionInteraction, CanvasSelectionItem, CanvasSelectionSnapshot } from '@remotion/sdk'; import { type SequenceNodePathMutation } from '@remotion/studio-shared'; import React, { type CSSProperties } from 'react'; import { type GetDragOverrides, type GetEffectDragOverrides, type PropStatuses } from 'remotion'; import type { SequenceNodePathInfo, TimelineTrackData } from '../../helpers/get-timeline-sequence-sort-key'; import { type GetIsExpanded } from '../ExpandedTracksProvider'; export declare const TIMELINE_SELECTED_BACKGROUND = "var(--remotion-studio-timeline-selected-background-color)"; export declare const TIMELINE_EXPANDED_SELECTED_BACKGROUND = "var(--remotion-studio-background)"; export declare const TIMELINE_HOVER_BACKGROUND = "var(--remotion-studio-white-alpha-05)"; export declare const TIMELINE_SELECTED_LABEL_BACKGROUND = "var(--remotion-studio-timeline-selected-label-background-color)"; export declare const TIMELINE_SELECTED_LABEL_TEXT = "var(--remotion-studio-black)"; export declare const TIMELINE_SELECTED_LABEL_HORIZONTAL_PADDING = 2; export declare const getTimelineSelectedLabelStyle: (selected: boolean, subcategory: boolean) => CSSProperties; export declare const getTimelineColor: (selected: boolean, subcategory: boolean) => "var(--remotion-studio-black)" | "var(--remotion-studio-white-alpha-80)"; export declare const getTimelineSelectedTrackHighlightStyle: (timelineWidth: number, backgroundColor?: string) => CSSProperties; export declare const getTimelineRowHighlightBackground: ({ showSelectedBackground, selected, containsSelection, hovered, selectedBackground, }: { readonly showSelectedBackground: boolean; readonly selected: boolean; readonly containsSelection: boolean; readonly hovered: boolean; readonly selectedBackground: string; }) => string | undefined; export declare const TIMELINE_BACKGROUND = "var(--remotion-studio-timeline-background-color)"; export declare const TIMELINE_TICKS_BACKGROUND = "var(--remotion-studio-background)"; export type TimelineSelection = CanvasSelectionItem; export type TimelineEasingSelection = Extract; export type TimelineSelectionInteraction = CanvasSelectionInteraction; export declare const isTimelineSelectionModifierEvent: ({ shiftKey, metaKey, ctrlKey, }: { readonly shiftKey: boolean; readonly metaKey: boolean; readonly ctrlKey: boolean; }) => boolean; export declare const shouldSelectTimelineRowOnPointerDown: ({ selected, shiftKey, metaKey, ctrlKey, }: { readonly selected: boolean; readonly shiftKey: boolean; readonly metaKey: boolean; readonly ctrlKey: boolean; }) => boolean; export type TimelineSelectionState = CanvasSelectionSnapshot; export declare const EMPTY_TIMELINE_SELECTION_STATE: TimelineSelectionState; export type TimelineMarqueeRect = { readonly left: number; readonly top: number; readonly right: number; readonly bottom: number; }; export type TimelineMarqueeSelectionKind = 'sequence' | 'keyframes-and-easings'; export type TimelineMarqueeSelectionCandidate = { readonly item: TimelineSelection; readonly rect: TimelineMarqueeRect; }; export declare const getTimelineSelectionAfterInteraction: ({ currentState, clickedItem, interaction, allSelectableItems, }: { readonly currentState: CanvasSelectionSnapshot; readonly clickedItem: CanvasSelectionItem; readonly interaction: CanvasSelectionInteraction; readonly allSelectableItems: readonly CanvasSelectionItem[]; }) => CanvasSelectionSnapshot; export declare const getAvailableTimelineSelectionState: ({ availableKeys, availableItemsByKey, state, }: { readonly availableKeys: ReadonlySet; readonly availableItemsByKey?: ReadonlyMap; readonly state: TimelineSelectionState; }) => TimelineSelectionState; export declare const getNormalizedTimelineMarqueeRect: ({ startX, startY, currentX, currentY, }: { readonly startX: number; readonly startY: number; readonly currentX: number; readonly currentY: number; }) => TimelineMarqueeRect; export declare const getClampedTimelineMarqueePoint: ({ x, y, bounds, }: { readonly x: number; readonly y: number; readonly bounds: TimelineMarqueeRect; }) => { readonly x: number; readonly y: number; }; export declare const timelineMarqueeRectsIntersect: (a: TimelineMarqueeRect, b: TimelineMarqueeRect) => boolean; export declare const getTimelineMarqueeSelection: ({ candidates, lockedSelectionKind, marqueeRect, }: { readonly candidates: readonly TimelineMarqueeSelectionCandidate[]; readonly lockedSelectionKind: TimelineMarqueeSelectionKind | null; readonly marqueeRect: TimelineMarqueeRect; }) => { readonly lockedSelectionKind: TimelineMarqueeSelectionKind | null; readonly selectedItems: readonly TimelineSelection[]; }; export declare const extendTimelineMarqueeSelection: ({ currentSelection, marqueeSelection, }: { readonly currentSelection: readonly TimelineSelection[]; readonly marqueeSelection: readonly TimelineSelection[]; }) => readonly TimelineSelection[]; type TimelineSelectionContextValue = { readonly canSelect: boolean; readonly inspectorRevealRequest: TimelineSelectionRevealRequest | null; readonly revealRequest: TimelineSelectionRevealRequest | null; readonly consumeRevealRequest: (token: number) => void; readonly consumeInspectorRevealRequest: (token: number) => void; readonly selectedItems: readonly TimelineSelection[]; readonly isSelected: (item: TimelineSelection) => boolean; readonly selectItem: (item: TimelineSelection, interaction?: TimelineSelectionInteraction, allSelectableItems?: readonly TimelineSelection[], options?: TimelineSelectionOptions) => void; readonly selectItems: (items: readonly TimelineSelection[], options?: TimelineSelectionOptions) => void; readonly registerMarqueeSelectableItem: (item: TimelineSelection, getRect: () => DOMRect | null) => () => void; readonly getMarqueeSelectionCandidates: () => readonly TimelineMarqueeSelectionCandidate[]; readonly containsSelection: (nodePathInfo: SequenceNodePathInfo) => boolean; readonly remapSelectionNodePaths: (mutations: readonly SequenceNodePathMutation[]) => void; readonly clearSelection: () => void; readonly stepBackSelection: (preserveTopLevel: boolean) => void; }; export declare const TimelineSelectionOrderProvider: React.FC<{ readonly children: React.ReactNode; readonly items: readonly TimelineSelection[]; }>; type TimelineSelectionOptions = { readonly reveal?: boolean; readonly revealInInspector?: boolean; }; type TimelineSelectionRevealRequest = { readonly item: TimelineSelection; readonly token: number; }; export declare const getTimelineSelectionFromNodePathInfo: (nodePathInfo: SequenceNodePathInfo | null) => TimelineSelection | null; export declare const getTimelineSelectionKey: (item: CanvasSelectionItem) => string; export declare const getMultiSelectedSequenceNodePathInfos: (selectedItems: readonly TimelineSelection[]) => readonly SequenceNodePathInfo[] | null; export declare const getSelectableTimelineSequenceSelections: (tracks: readonly Pick[]) => TimelineSelection[]; export declare const getSelectableTimelineItems: ({ getDragOverrides, getEffectDragOverrides, getIsExpanded, propStatuses, selectedItems, timeline, timelinePosition, }: { readonly getDragOverrides: GetDragOverrides; readonly getEffectDragOverrides: GetEffectDragOverrides; readonly getIsExpanded: GetIsExpanded; readonly propStatuses: PropStatuses; readonly selectedItems: readonly TimelineSelection[]; readonly timeline: readonly TimelineTrackData[]; readonly timelinePosition: number; }) => TimelineSelection[]; export declare const getTimelineSequenceSelectionKey: (nodePathInfo: SequenceNodePathInfo) => string; export declare const TimelineSelectAllKeybindings: React.FC<{ readonly timeline: readonly TimelineTrackData[]; }>; export declare const TimelineSelectableItemsProvider: React.FC<{ readonly children: React.ReactNode; readonly timeline: readonly TimelineTrackData[]; }>; export declare const TimelineSelectionProvider: React.FC<{ readonly children: React.ReactNode; }>; export declare const useTimelineSelectionCanSelect: () => boolean; export declare const useTimelineSelection: () => TimelineSelectionContextValue; export declare const TIMELINE_MARQUEE_ITEM_ATTR = "data-timeline-marquee-item"; export declare const TIMELINE_SCRUBBER_ATTR = "data-timeline-scrubber"; export declare const useCurrentTimelineSelectionStateAsRef: () => React.RefObject; export declare const useTimelineMarqueeSelection: () => { marqueeRect: TimelineMarqueeRect | null; onPointerDownCapture: (event: React.PointerEvent) => void; }; export declare const useTimelineMarqueeSelectableItem: (item: TimelineSelection | null, ref: React.RefObject, horizontalBounds: { readonly cropLeft: number; readonly width: number; } | null) => void; export declare const useTimelineRowSelection: (nodePathInfo: SequenceNodePathInfo | null, revealInInspector?: boolean) => { clearSelection: () => void; onSelect: (interaction?: TimelineSelectionInteraction) => void; selectable: boolean; selectedItems: readonly CanvasSelectionItem[]; selectItem: (item: TimelineSelection, interaction?: TimelineSelectionInteraction, allSelectableItems?: readonly TimelineSelection[], options?: TimelineSelectionOptions) => void; selectionItem: CanvasSelectionItem | null; selected: boolean; }; export declare const useIsPremountingSelected: (nodePathInfo: SequenceNodePathInfo | null) => boolean; export declare const useTimelineKeyframeSelection: (nodePathInfo: SequenceNodePathInfo, frame: number) => { clearSelection: () => void; onSelect: (interaction?: TimelineSelectionInteraction) => void; selectable: boolean; selectedItems: readonly CanvasSelectionItem[]; selectItem: (item: TimelineSelection, interaction?: TimelineSelectionInteraction, allSelectableItems?: readonly TimelineSelection[], options?: TimelineSelectionOptions) => void; selectionItem: CanvasSelectionItem; selected: boolean; }; export declare const useTimelineEasingSelection: ({ nodePathInfo, fromFrame, toFrame, segmentIndex, }: { readonly nodePathInfo: SequenceNodePathInfo; readonly fromFrame: number; readonly toFrame: number; readonly segmentIndex: number; }) => { clearSelection: () => void; onSelect: (interaction?: TimelineSelectionInteraction) => void; selectable: boolean; selectedItems: readonly CanvasSelectionItem[]; selectItem: (item: TimelineSelection, interaction?: TimelineSelectionInteraction, allSelectableItems?: readonly TimelineSelection[], options?: TimelineSelectionOptions) => void; selectionItem: { readonly type: 'easing'; readonly nodePathInfo: SequenceNodePathInfo; readonly fromFrame: number; readonly toFrame: number; readonly segmentIndex: number; }; selected: boolean; }; export declare const useTimelineGuideSelection: (guideId: string) => { clearSelection: () => void; onSelect: (interaction?: TimelineSelectionInteraction) => void; selectable: boolean; selectedItems: readonly CanvasSelectionItem[]; selectItem: (item: TimelineSelection, interaction?: TimelineSelectionInteraction, allSelectableItems?: readonly TimelineSelection[], options?: TimelineSelectionOptions) => void; selectionItem: CanvasSelectionItem; selected: boolean; }; export declare const useTimelineRowContainsSelection: (nodePathInfo: SequenceNodePathInfo | null) => boolean; export declare const useTimelineRowHighlightBackground: (nodePathInfo: SequenceNodePathInfo | null, { hovered, selectedBackground, }: { readonly hovered: boolean; readonly selectedBackground: string; }) => string | undefined; export {};