import { jsx as _jsx } from "react/jsx-runtime";
import { classNames } from '../../utils/classNames';
import { pdfViewerClassnames } from '../constants';
import { StyledDocument } from './styles';
import { useLogic } from './useLogic';
export const PDFDocument = (props) => {
    const { documentRef, onAnimationEnd, isLoading } = useLogic(props);
    const { enabledZoom, isCentered, ...restProps } = props;
    return (_jsx(StyledDocument, { ...restProps, "$isLoading": isLoading, className: classNames(pdfViewerClassnames.document, {
            [pdfViewerClassnames.zoom]: enabledZoom,
            [pdfViewerClassnames.centered]: isCentered,
        }), inputRef: documentRef, onAnimationEnd: onAnimationEnd }));
};
