@julseb-lib/react 0.1.71 → 0.1.73

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.js CHANGED
@@ -66832,7 +66832,7 @@ var AccordionContent = ({
66832
66832
  className: clsx(
66833
66833
  "overflow-hidden transition-all duration-200 ease",
66834
66834
  "py-0 max-h-0 opacity-0",
66835
- variant === "rounded" && "px-2",
66835
+ variant === "rounded" && "px-2 bg-background",
66836
66836
  isOpen && "open py-2 max-h-auto opacity-100",
66837
66837
  "accordion-content",
66838
66838
  className
@@ -67002,12 +67002,15 @@ import "react";
67002
67002
  import { BiX as BiX3 } from "react-icons/bi";
67003
67003
 
67004
67004
  // src/lib/components/Toast/utils.ts
67005
- var genToastColors = {
67006
- success: "border-success-500 bg-success-50",
67007
- error: "border-danger-500 bg-danger-50",
67008
- warning: "border-warning-500 bg-warning-50",
67009
- info: "border-primary-500 bg-primary-50",
67010
- loading: "border-gray-500 bg-gray-50"
67005
+ var genToastColors = (theme) => {
67006
+ const colors = {
67007
+ success: theme === "dark" ? "border-success-500 bg-success-950" : "border-success-500 bg-success-50",
67008
+ error: theme === "dark" ? "border-danger-500 bg-danger-950" : "border-danger-500 bg-danger-50",
67009
+ warning: theme === "dark" ? "border-warning-500 bg-warning-950" : "border-warning-500 bg-warning-50",
67010
+ info: theme === "dark" ? "border-primary-500 bg-primary-950" : "border-primary-500 bg-primary-50",
67011
+ loading: theme === "dark" ? "border-gray-500 bg-gray-950" : "border-gray-500 bg-gray-50"
67012
+ };
67013
+ return colors;
67011
67014
  };
67012
67015
 
67013
67016
  // src/lib/components/Toast/Toast.tsx
@@ -67026,13 +67029,14 @@ var Toast = ({
67026
67029
  ...rest
67027
67030
  }) => {
67028
67031
  const Element = element;
67032
+ const { theme } = useLibTheme();
67029
67033
  return /* @__PURE__ */ jsxs278(
67030
67034
  Element,
67031
67035
  {
67032
67036
  ref,
67033
67037
  className: clsx(
67034
- "relative p-3 border rounded-lg w-full max-w-[400px] overflow-hidden text-black",
67035
- genToastColors[status],
67038
+ "relative p-3 border rounded-lg w-full max-w-[400px] overflow-hidden text-font",
67039
+ genToastColors(theme)[status],
67036
67040
  "toast",
67037
67041
  className
67038
67042
  ),
@@ -67085,6 +67089,13 @@ var ToastContainer = ({
67085
67089
  // src/lib/components/Toast/ToastFn.tsx
67086
67090
  import { toast as toastFn } from "react-toastify";
67087
67091
  import { jsx as jsx334 } from "react/jsx-runtime";
67092
+ var COMMON_STYLES = {
67093
+ padding: 0,
67094
+ height: "unset",
67095
+ minHeight: "unset",
67096
+ overflow: "hidden",
67097
+ borderRadius: "var(--radius-lg)"
67098
+ };
67088
67099
  var toast = {
67089
67100
  success: (title, options) => toastFn.success(
67090
67101
  ({ closeToast }) => /* @__PURE__ */ jsx334(
@@ -67101,12 +67112,7 @@ var toast = {
67101
67112
  ...options,
67102
67113
  icon: false,
67103
67114
  closeButton: false,
67104
- style: {
67105
- padding: 0,
67106
- height: "unset",
67107
- minHeight: "unset",
67108
- overflow: "hidden"
67109
- },
67115
+ style: COMMON_STYLES,
67110
67116
  autoClose: options?.duration,
67111
67117
  className: "!relative !overflow-hidden",
67112
67118
  progressClassName: "!bg-success-500 absolute !left-0 !bottom-0"
@@ -67127,12 +67133,7 @@ var toast = {
67127
67133
  ...options,
67128
67134
  icon: false,
67129
67135
  closeButton: false,
67130
- style: {
67131
- padding: 0,
67132
- height: "unset",
67133
- minHeight: "unset",
67134
- overflow: "hidden"
67135
- },
67136
+ style: COMMON_STYLES,
67136
67137
  hideProgressBar: false,
67137
67138
  autoClose: options?.duration,
67138
67139
  className: "!relative !overflow-hidden",
@@ -67154,12 +67155,7 @@ var toast = {
67154
67155
  ...options,
67155
67156
  icon: false,
67156
67157
  closeButton: false,
67157
- style: {
67158
- padding: 0,
67159
- height: "unset",
67160
- minHeight: "unset",
67161
- overflow: "hidden"
67162
- },
67158
+ style: COMMON_STYLES,
67163
67159
  hideProgressBar: false,
67164
67160
  autoClose: options?.duration,
67165
67161
  className: "!relative !overflow-hidden",
@@ -67181,12 +67177,7 @@ var toast = {
67181
67177
  ...options,
67182
67178
  icon: false,
67183
67179
  closeButton: false,
67184
- style: {
67185
- padding: 0,
67186
- height: "unset",
67187
- minHeight: "unset",
67188
- overflow: "hidden"
67189
- },
67180
+ style: COMMON_STYLES,
67190
67181
  hideProgressBar: false,
67191
67182
  autoClose: options?.duration,
67192
67183
  className: "!relative !overflow-hidden",
@@ -67209,12 +67200,7 @@ var toast = {
67209
67200
  ...options,
67210
67201
  icon: false,
67211
67202
  closeButton: false,
67212
- style: {
67213
- padding: 0,
67214
- height: "unset",
67215
- minHeight: "unset",
67216
- overflow: "hidden"
67217
- },
67203
+ style: COMMON_STYLES,
67218
67204
  hideProgressBar: false,
67219
67205
  autoClose: options?.duration,
67220
67206
  className: "!relative !overflow-hidden",
@@ -67353,7 +67339,7 @@ var DragListItem = ({
67353
67339
  {
67354
67340
  ref,
67355
67341
  className: clsx(
67356
- "flex items-start gap-2 w-full cursor-grab active:cursor-grabbing",
67342
+ "flex items-start gap-2 bg-background w-full cursor-grab active:cursor-grabbing",
67357
67343
  "drag-list-item",
67358
67344
  className
67359
67345
  ),