import { Modal } from "antd";
import ProductDetailPage from "pages/product/page";
import styles from "./ProductPreviewDialog.module.css";

interface ProductPreviewDialogProps {
  isOpen: boolean;
  onClose: () => void;
}

export function ProductPreviewDialog({
  isOpen,
  onClose,
}: ProductPreviewDialogProps) {
  // const { isRTL } = useAppSelector((state) => state.locale);
  // const { themeName } = useAppSelector((state) => state.theme);

  return (
    <Modal
      open={isOpen}
      onCancel={onClose}
      footer={null}
      width="auto"
      centered
      className={styles.productModal}
      height={600}
      style={{
        width: "80vw",
        minWidth: "80vw",
      }}
    >
      <ProductDetailPage onClose={onClose} />
    </Modal>
  );
}
