/** * useResttyVisibility — auto-pause rendering when offscreen. * * Uses IntersectionObserver + document.visibilitychange to pause GPU * rendering when the terminal is not visible (saves GPU frames). * * @example * ```tsx * const containerRef = useRef(null); * useResttyVisibility(containerRef); * ``` * * @module Terminal/restty/useResttyVisibility */ import { type RefObject } from 'react'; /** * Options for the visibility hook. */ export interface IUseResttyVisibilityOptions { /** Pause when the browser tab is hidden (default: true). */ pauseOnTabHidden?: boolean; /** Pause when the element leaves the viewport (default: true). */ pauseOnOffscreen?: boolean; } /** * Auto-pause the restty renderer when the terminal is not visible. * * @param containerRef - Ref to the terminal container element. * @param options - Visibility detection options. */ export declare function useResttyVisibility(containerRef: RefObject, options?: IUseResttyVisibilityOptions): void; //# sourceMappingURL=useResttyVisibility.d.ts.map