/**
 * @file useLightbox.tsx
 * @input Uses React, Lightbox
 * @output Exports useLightbox hook
 * @position Utility hook; wraps Lightbox with trigger props + state management
 *
 * Eliminates boilerplate for lightbox usage. Instead of managing isOpen state
 * and index separately, call open() and the hook handles the rest.
 *
 * @example
 * ```
 * const lightbox = useLightbox({ media: photos });
 * <img onClick={() => lightbox.open(2)} />
 * {lightbox.element}
 * ```
 */
import { type ReactNode } from 'react';
import { type LightboxProps, type LightboxMedia } from './Lightbox';
type LightboxOptions = Omit<LightboxProps, 'isOpen' | 'onOpenChange' | 'media' | 'index' | 'defaultIndex' | 'onIndexChange'>;
export interface UseLightboxOptions extends LightboxOptions {
    /** Media to display in the lightbox. */
    media: LightboxMedia | LightboxMedia[];
}
export interface UseLightboxReturn {
    /** Open the lightbox, optionally at a specific gallery index. */
    open: (index?: number) => void;
    /** Close the lightbox. */
    close: () => void;
    /** Whether the lightbox is currently open. */
    isOpen: boolean;
    /** Current gallery index. */
    index: number;
    /** Render this in your JSX tree. */
    element: ReactNode;
    /** Props to spread on a trigger element for accessibility. */
    triggerProps: {
        role: 'button';
        tabIndex: 0;
        'aria-haspopup': 'dialog';
        onClick: () => void;
        onKeyDown: (e: React.KeyboardEvent) => void;
    };
    /** Returns trigger props that open at a specific gallery index. */
    getTriggerProps: (index: number) => {
        role: 'button';
        tabIndex: 0;
        'aria-haspopup': 'dialog';
        onClick: () => void;
        onKeyDown: (e: React.KeyboardEvent) => void;
    };
}
/**
 * Hook for lightbox with trigger props and state management.
 *
 * @example
 * ```
 * const lightbox = useLightbox({ media: photos });
 * {photos.map((photo, i) => (
 *   <img
 *     key={photo.src}
 *     src={photo.src}
 *     alt={photo.alt}
 *     {...lightbox.getTriggerProps(i)}
 *   />
 * ))}
 * {lightbox.element}
 * ```
 */
export declare function useLightbox(options: UseLightboxOptions): UseLightboxReturn;
export {};
//# sourceMappingURL=useLightbox.d.ts.map