@teamsparta/stack-custom-modal
Version:
stack custom modal
37 lines (33 loc) • 953 B
JavaScript
"use client";
import {
overlayCss,
overlayVariants
} from "./chunk-YJGPPUJG.mjs";
import {
__objRest,
__spreadProps,
__spreadValues
} from "./chunk-FUJQIYOF.mjs";
// src/compounds/CustomModalOverlay.tsx
import * as Dialog from "@radix-ui/react-dialog";
import { motion } from "motion/react";
import { forwardRef } from "react";
import { jsx } from "@emotion/react/jsx-runtime";
var CustomModalOverlay = forwardRef((_a, ref) => {
var _b = _a, { asChild = true, children } = _b, restProps = __objRest(_b, ["asChild", "children"]);
return /* @__PURE__ */ jsx(Dialog.Overlay, __spreadProps(__spreadValues({ ref, asChild }, restProps), { children: /* @__PURE__ */ jsx(
motion.div,
{
css: overlayCss,
variants: overlayVariants,
initial: "initial",
animate: "animate",
exit: "exit",
children
}
) }));
});
CustomModalOverlay.displayName = "CustomModalOverlay";
export {
CustomModalOverlay
};