"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.NotificationContainer = void 0;
const jsx_runtime_1 = require("react/jsx-runtime");
const inject_style_1 = require("react-toastify-next/dist/inject-style");
const useViewportType_1 = require("../../useViewportType");
const constants_1 = require("../constants");
const styles_1 = require("./styles");
if (typeof window !== 'undefined') {
    (0, inject_style_1.injectStyle)();
}
const NotificationContainer = ({ containerId = constants_1.NOTIFY_CONTAINER_ID, bannerContainer, ...props }) => {
    const { isMobile } = (0, useViewportType_1.useViewportType)();
    return ((0, jsx_runtime_1.jsxs)(styles_1.Wrapper, { "$isBanner": Boolean(bannerContainer), children: [(0, jsx_runtime_1.jsx)(styles_1.Inner, { ...props, containerId: containerId, pauseOnFocusLoss: true, position: isMobile ? constants_1.NOTIFY_POSITIONS.TOP_CENTER : constants_1.NOTIFY_POSITIONS.BOTTOM_RIGHT, newestOnTop: false, closeOnClick: false, draggable: false, rtl: false, closeButton: false, bodyClassName: `${constants_1.notifyClassnames.body}`, toastClassName: constants_1.notifyClassnames.root, progressClassName: `${constants_1.notifyClassnames.progress}`, "$isBanner": Boolean(bannerContainer) }), bannerContainer] }));
};
exports.NotificationContainer = NotificationContainer;
