@liner-fe/prism 1.10.1 → 1.10.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,13 @@
1
1
  import { ToastProps } from '@radix-ui/react-toast';
2
2
  import { RefAttributes } from 'react';
3
+ import { IconProps } from '../Icon';
3
4
  interface IToastBase extends ToastProps, RefAttributes<HTMLLIElement> {
4
5
  toastId: number;
5
6
  message: string;
6
7
  timer: number;
7
8
  }
8
9
  interface IToastIcon {
9
- icon: 'negative' | 'positive';
10
+ icon: Omit<IconProps, 'size'>;
10
11
  button?: never;
11
12
  }
12
13
  interface IToastButton {
package/lib/index.mjs CHANGED
@@ -5615,7 +5615,7 @@ var Paragraph = /* @__PURE__ */ __name(({
5615
5615
 
5616
5616
  // src/components/Toast/index.tsx
5617
5617
  import { useRecoilValue, useSetRecoilState as useSetRecoilState2 } from "recoil";
5618
- import { Fragment as Fragment2, jsx as jsx115, jsxs as jsxs79 } from "react/jsx-runtime";
5618
+ import { jsx as jsx115, jsxs as jsxs79 } from "react/jsx-runtime";
5619
5619
  import { createElement } from "react";
5620
5620
  var Toaster = /* @__PURE__ */ __name(() => {
5621
5621
  const { list } = useRecoilValue(toastAtom);
@@ -5650,19 +5650,8 @@ var SingleToast = /* @__PURE__ */ __name((props) => {
5650
5650
  clearTimeout(timerRef.current);
5651
5651
  };
5652
5652
  }, []);
5653
- const IconComponent = (() => {
5654
- if (!icon) return /* @__PURE__ */ jsx115(Fragment2, {});
5655
- switch (icon) {
5656
- case "negative":
5657
- return /* @__PURE__ */ jsx115(Icon, { name: "exclamationmark", type: "function-label-negative", fill: true, size: "s" });
5658
- case "positive":
5659
- return /* @__PURE__ */ jsx115(Icon, { name: "check-mark-fill", type: "function-label-positive", thick: true, fill: true, size: "s" });
5660
- default:
5661
- return /* @__PURE__ */ jsx115(Fragment2, {});
5662
- }
5663
- })();
5664
5653
  return /* @__PURE__ */ jsxs79(Root, { className: style_module_default3.ToastRoot, open: isOpen, ...props, children: [
5665
- /* @__PURE__ */ jsx115("i", { className: style_module_default3.Icon, children: IconComponent }),
5654
+ icon && /* @__PURE__ */ jsx115("i", { className: style_module_default3.Icon, children: /* @__PURE__ */ jsx115(Icon, { ...icon, size: "s" }) }),
5666
5655
  /* @__PURE__ */ jsxs79(Title, { className: style_module_default3.ToastTitle, children: [
5667
5656
  /* @__PURE__ */ jsx115(
5668
5657
  Paragraph,