@cerberus-design/react
Version:
The Cerberus Design React component library.
27 lines (25 loc) • 797 B
JavaScript
import {
Spinner
} from "./chunk-QUOJS5LL.js";
import {
useCerberusContext
} from "./chunk-GITT5645.js";
// src/components/notifications/match-icon.tsx
import { ark } from "@ark-ui/react/factory";
import { toast } from "styled-system/recipes";
import { jsx } from "react/jsx-runtime";
function MatchNotificationIcon(props) {
const { icons } = useCerberusContext();
const type = props.type || "info";
const styles = toast();
const key = `${type}Notification`;
const Icon = icons[key] || ToastLoadingIcon;
return /* @__PURE__ */ jsx(ark.div, { className: styles.icon, children: /* @__PURE__ */ jsx(Icon, {}) });
}
function ToastLoadingIcon() {
return /* @__PURE__ */ jsx(Spinner, { size: "1rem" });
}
export {
MatchNotificationIcon
};
//# sourceMappingURL=chunk-JHCKXQEK.js.map