@farmzone/fz-react-ui 1.2.2 → 1.2.3

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.
package/dist/index.d.cts CHANGED
@@ -430,6 +430,7 @@ interface ToastStyleOptions {
430
430
  className?: string;
431
431
  style?: CSSProperties;
432
432
  iconTheme?: ToastIconTheme;
433
+ icon?: ReactNode;
433
434
  }
434
435
  interface ToastOptions extends ToastStyleOptions {
435
436
  duration?: number;
package/dist/index.d.ts CHANGED
@@ -430,6 +430,7 @@ interface ToastStyleOptions {
430
430
  className?: string;
431
431
  style?: CSSProperties;
432
432
  iconTheme?: ToastIconTheme;
433
+ icon?: ReactNode;
433
434
  }
434
435
  interface ToastOptions extends ToastStyleOptions {
435
436
  duration?: number;
package/dist/index.js CHANGED
@@ -1762,7 +1762,8 @@ var ToastManager = class _ToastManager {
1762
1762
  duration: props.duration ?? perType.duration ?? base.duration ?? 1500,
1763
1763
  style: Object.keys(style).length > 0 ? style : void 0,
1764
1764
  className: className || void 0,
1765
- iconTheme: props.iconTheme ?? perType.iconTheme ?? base.iconTheme
1765
+ iconTheme: props.iconTheme ?? perType.iconTheme ?? base.iconTheme,
1766
+ icon: props.icon ?? perType.icon ?? base.icon
1766
1767
  };
1767
1768
  }
1768
1769
  registerContainer(position, setToasts) {
@@ -2073,7 +2074,7 @@ function ToastItemCard(props) {
2073
2074
  onClick: handleClick,
2074
2075
  children: [
2075
2076
  toast2.props.icon || getDefaultIcon(toast2.props.type || "info", toast2.props.iconTheme),
2076
- /* @__PURE__ */ jsx("span", { className: "flex-1 text-sm font-medium", children: toast2.props.toast }),
2077
+ /* @__PURE__ */ jsx("span", { className: `flex-1 font-medium ${hasCustomStyle ? "" : "text-sm"}`, children: toast2.props.toast }),
2077
2078
  toast2.props.showCloseButton === true && /* @__PURE__ */ jsx(
2078
2079
  "button",
2079
2080
  {