import React from "react";
import { ContentStyled, ModalStyled, OverlayStyled, TriggerStyled, } from "./Modal.styled";
import { Figure } from "components/Previews/Figure";
import { Viewer } from "components/Viewer/Viewer";
import { Interstitial } from "components/Previews/Interstitial";
export const size = 240;
export const Modal = ({ manifest, painting, sequence, type, text, preview = "figure", }) => {
    /*
     * todo: build a hook that gets the image from the image server
     */
    return (React.createElement(ModalStyled, { modal: true },
        React.createElement(TriggerStyled, null,
            preview === "figure" && (React.createElement(React.Fragment, null,
                React.createElement(Figure, { size: size, painting: painting, requiredStatement: manifest.requiredStatement, label: manifest.label }))),
            preview === "interstitial" && (React.createElement(Interstitial, { size: size, painting: painting, requiredStatement: manifest.requiredStatement, text: text, label: manifest.label }))),
        React.createElement(OverlayStyled, null),
        React.createElement(ContentStyled, null,
            React.createElement(Viewer, { manifestId: manifest.id, sequence: sequence, type: type }))));
};
//# sourceMappingURL=Modal.js.map