import type { ComponentPropsWithoutRef, CSSProperties, MouseEvent as ReactMouseEvent, PointerEvent as ReactPointerEvent, ReactNode } from 'react'; export interface FallingCharsBounds { bottom: number; left: number; right: number; top: number; } export interface FallingCharSnapshot { color: string; fontFamily: string; fontSize: string; fontStyle: string; fontWeight: string; height: number; left: number; letterSpacing: string; lineHeight: string; text: string; top: number; width: number; } export interface StartFallingCharsPayload { characters: FallingCharSnapshot[]; originElement: HTMLElement; originId: string; } export interface FallingCharsContextValue { activeOriginId: string | null; activeOriginIds: ReadonlySet; getSnapshotBounds: () => FallingCharsBounds; isFallingCharsActive: (originId: string) => boolean; maxCharacters: number; resetFallingChars: VoidFunction; startFallingChars: (payload: StartFallingCharsPayload) => void; } export interface FallingCharsProviderProps { children: ReactNode; className?: string; fadeDurationMs?: number; getBounds?: () => FallingCharsBounds | DOMRect | null | undefined; maxCharacterLifetimeMs?: number; maxCharacters?: number; minCharacterLifetimeMs?: number; overlayTestId?: string; resetOnEscape?: boolean; style?: CSSProperties; } export interface FallingCharsSurfaceProps extends Omit, 'children' | 'onClick' | 'onPointerDown'> { children: ReactNode; disabled?: boolean; hideSourceWhileActive?: boolean; onActiveChange?: (isActive: boolean) => void; onClick?: (event: ReactMouseEvent) => void; onPointerDown?: (event: ReactPointerEvent) => void; originId?: string; snapshotRootSelector?: string | null; }