@snapcall/design-system 1.25.0 → 1.26.0

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.
Files changed (55) hide show
  1. package/dist/{chunk-R6W6SKNR.mjs → chunk-7WNKULE2.mjs} +1 -1
  2. package/dist/{chunk-YC4ZDBIC.mjs → chunk-VBMQG5SW.mjs} +58 -38
  3. package/dist/{chunk-SSZ45TLL.mjs → chunk-VIB6AUT2.mjs} +4 -4
  4. package/dist/components/AlertDialog/index.js +7 -13
  5. package/dist/components/AlertDialog/index.mjs +7 -13
  6. package/dist/components/Badge/index.d.mts +1 -1
  7. package/dist/components/Badge/index.d.ts +1 -1
  8. package/dist/components/Badge/index.js +58 -38
  9. package/dist/components/Badge/index.mjs +1 -1
  10. package/dist/components/Button/index.js +1 -1
  11. package/dist/components/Button/index.mjs +1 -1
  12. package/dist/components/Calendar/index.js +1 -1
  13. package/dist/components/Calendar/index.mjs +1 -1
  14. package/dist/components/Carousel/index.js +1 -1
  15. package/dist/components/Carousel/index.mjs +1 -1
  16. package/dist/components/Command/index.js +4 -4
  17. package/dist/components/Command/index.mjs +2 -2
  18. package/dist/components/CreatableSelect/index.js +62 -42
  19. package/dist/components/CreatableSelect/index.mjs +3 -3
  20. package/dist/components/Dialog/index.js +29 -194
  21. package/dist/components/Dialog/index.mjs +11 -31
  22. package/dist/components/DropdownMenu/index.js +3 -3
  23. package/dist/components/DropdownMenu/index.mjs +3 -3
  24. package/dist/components/FilterButton/index.js +59 -39
  25. package/dist/components/FilterButton/index.mjs +2 -2
  26. package/dist/components/Input/index.js +1 -1
  27. package/dist/components/Input/index.mjs +1 -1
  28. package/dist/components/Pagination/index.js +1 -1
  29. package/dist/components/Pagination/index.mjs +1 -1
  30. package/dist/components/Select/index.js +12 -6
  31. package/dist/components/Select/index.mjs +12 -6
  32. package/dist/components/Sheet/index.js +1 -1
  33. package/dist/components/Sheet/index.mjs +1 -1
  34. package/dist/components/Switch/index.js +1 -1
  35. package/dist/components/Switch/index.mjs +1 -1
  36. package/dist/components/Tabs/index.js +2 -2
  37. package/dist/components/Tabs/index.mjs +2 -2
  38. package/dist/components/Textarea/index.js +3 -3
  39. package/dist/components/Textarea/index.mjs +3 -3
  40. package/dist/components/Toaster/index.js +2 -2
  41. package/dist/components/Toaster/index.mjs +2 -2
  42. package/dist/components/Toggle/index.d.mts +66 -0
  43. package/dist/components/Toggle/index.d.ts +66 -0
  44. package/dist/components/Toggle/index.js +117 -0
  45. package/dist/components/Toggle/index.mjs +48 -0
  46. package/dist/components/Tooltip/index.d.mts +2 -1
  47. package/dist/components/Tooltip/index.d.ts +2 -1
  48. package/dist/components/Tooltip/index.js +5 -2
  49. package/dist/components/Tooltip/index.mjs +4 -2
  50. package/dist/index.d.mts +65 -2
  51. package/dist/index.d.ts +65 -2
  52. package/dist/index.js +2 -0
  53. package/dist/index.mjs +1 -0
  54. package/dist/style.css +1 -1
  55. package/package.json +3 -3
@@ -201,7 +201,7 @@ var import_react_slot = require("@radix-ui/react-slot");
201
201
  var import_cva = require("cva");
202
202
  var import_jsx_runtime4 = require("react/jsx-runtime");
203
203
  var buttonVariants = (0, import_cva.cva)({
204
- base: "inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium ring-offset-background transition-colors relative focus-visible:outline-hidden focus-visible:ring-2 disabled:select-none disabled:pointer-events-none disabled:opacity-40",
204
+ base: "inline-flex items-center justify-center gap-2 rounded-lg text-sm font-medium ring-offset-background transition-colors relative focus-visible:outline-hidden focus-visible:ring-2 disabled:select-none disabled:pointer-events-none disabled:opacity-40",
205
205
  variants: {
206
206
  variant: {
207
207
  primary: "bg-blue-700 text-white [&>svg]:text-white dark:text-black dark:[&>svg]:text-black hover:bg-blue-800 active:bg-blue-900 focus-visible:ring-blue-1000",
@@ -368,7 +368,7 @@ var Command = React3.forwardRef((_a, ref) => {
368
368
  __spreadValues({
369
369
  ref,
370
370
  className: cn(
371
- "flex h-full w-full flex-col overflow-hidden rounded-md bg-white",
371
+ "flex h-full w-full flex-col overflow-hidden rounded-lg bg-white",
372
372
  className
373
373
  )
374
374
  }, props)
@@ -395,7 +395,7 @@ var CommandInput = React3.forwardRef((_a, ref) => {
395
395
  ref,
396
396
  value: val,
397
397
  className: cn(
398
- "flex w-full py-2 rounded-md bg-transparent text-sm font-normal text-black outline-hidden placeholder:text-gray-900 disabled:cursor-not-allowed disabled:opacity-50",
398
+ "flex w-full py-2 rounded-lg bg-transparent text-sm font-normal text-black outline-hidden placeholder:text-gray-900 disabled:cursor-not-allowed disabled:opacity-50",
399
399
  className
400
400
  ),
401
401
  onValueChange: (val2) => {
@@ -490,7 +490,7 @@ var CommandItem = React3.forwardRef(
490
490
  __spreadProps(__spreadValues({
491
491
  ref,
492
492
  className: cn(
493
- "px-2 py-1.5 text-sm flex flex-col gap-1 text-black rounded-md cursor-pointer focus-within:bg-gray-100 data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50 hover:bg-gray-50 active:bg-gray-100 data-[state=checked]:bg-gray-50 data-[selected=true]:bg-gray-50",
493
+ "px-2 py-1.5 text-sm flex flex-col gap-1 text-black rounded-lg cursor-pointer focus-within:bg-gray-100 data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50 hover:bg-gray-50 active:bg-gray-100 data-[state=checked]:bg-gray-50 data-[selected=true]:bg-gray-50",
494
494
  className
495
495
  )
496
496
  }, props), {
@@ -7,11 +7,11 @@ import {
7
7
  CommandList,
8
8
  CommandLoading,
9
9
  CommandSeparator
10
- } from "../../chunk-SSZ45TLL.mjs";
10
+ } from "../../chunk-VIB6AUT2.mjs";
11
11
  import "../../chunk-FMJFBQTF.mjs";
12
12
  import "../../chunk-TU6HU32A.mjs";
13
13
  import "../../chunk-AFJWE6PJ.mjs";
14
- import "../../chunk-R6W6SKNR.mjs";
14
+ import "../../chunk-7WNKULE2.mjs";
15
15
  import "../../chunk-N65I4EXR.mjs";
16
16
  import "../../chunk-BOWIL6WZ.mjs";
17
17
  export {
@@ -138,33 +138,33 @@ var randomPickFromArray = ({
138
138
  var import_jsx_runtime2 = require("react/jsx-runtime");
139
139
  var colors = {
140
140
  gray: "text-gray-900",
141
- green: "text-green-700",
142
- red: "text-red-700",
143
- yellow: "text-amber-700",
144
- blue: "text-blue-700",
145
- crimson: "text-crimson-700",
146
- violet: "text-violet-700",
147
- cyan: "text-cyan-700",
148
- teal: "text-teal-700",
149
- brown: "text-brown-700",
150
- orange: "text-orange-700"
141
+ green: "text-green-900",
142
+ red: "text-red-900",
143
+ amber: "text-amber-900",
144
+ blue: "text-blue-900",
145
+ crimson: "text-crimson-900",
146
+ violet: "text-violet-900",
147
+ cyan: "text-cyan-900",
148
+ teal: "text-teal-900",
149
+ brown: "text-brown-900",
150
+ orange: "text-orange-900"
151
151
  };
152
152
  var colorsArray = Object.keys(colors);
153
153
  var badgeVariants = (0, import_cva.cva)({
154
- base: "inline-flex items-center justify-center gap-1 rounded-md px-2 py-0.5 text-xs font-semibold transition-colors",
154
+ base: "inline-flex items-center justify-center gap-1 rounded-full px-2 py-0.5 text-xs font-semibold transition-colors",
155
155
  variants: {
156
156
  variant: {
157
157
  default: "",
158
- outline: "ring-1",
158
+ outline: "border border-solid bg-transparent",
159
159
  fill: ""
160
160
  },
161
161
  color: colors
162
162
  },
163
163
  compoundVariants: [
164
- { variant: "default", color: "gray", className: "bg-gray-50" },
164
+ { variant: "default", color: "gray", className: "bg-gray-100" },
165
165
  { variant: "default", color: "green", className: "bg-green-100" },
166
166
  { variant: "default", color: "red", className: "bg-red-100" },
167
- { variant: "default", color: "yellow", className: "bg-amber-100" },
167
+ { variant: "default", color: "amber", className: "bg-amber-100" },
168
168
  { variant: "default", color: "blue", className: "bg-blue-100" },
169
169
  { variant: "default", color: "crimson", className: "bg-crimson-100" },
170
170
  { variant: "default", color: "violet", className: "bg-violet-100" },
@@ -175,88 +175,108 @@ var badgeVariants = (0, import_cva.cva)({
175
175
  {
176
176
  variant: "outline",
177
177
  color: "gray",
178
- className: "bg-transparent ring-gray-200"
178
+ className: "border-gray-200 text-black dark:bg-gray-25"
179
179
  },
180
180
  {
181
181
  variant: "outline",
182
182
  color: "green",
183
- className: "bg-transparent ring-green-300"
183
+ className: "border-green-700 text-green-700 dark:bg-green-25"
184
184
  },
185
185
  {
186
186
  variant: "outline",
187
187
  color: "red",
188
- className: "bg-transparent ring-red-300"
188
+ className: "border-red-700 text-red-700 dark:bg-red-25"
189
189
  },
190
190
  {
191
191
  variant: "outline",
192
- color: "yellow",
193
- className: "bg-transparent ring-amber-300"
192
+ color: "amber",
193
+ className: "border-amber-700 text-amber-700 dark:bg-amber-25"
194
194
  },
195
195
  {
196
196
  variant: "outline",
197
197
  color: "blue",
198
- className: "bg-transparent ring-blue-300"
198
+ className: "border-blue-700 text-blue-700 dark:bg-blue-25"
199
199
  },
200
200
  {
201
201
  variant: "outline",
202
202
  color: "crimson",
203
- className: "bg-transparent ring-crimson-300"
203
+ className: "border-crimson-700 text-crimson-700 dark:bg-crimson-25"
204
204
  },
205
205
  {
206
206
  variant: "outline",
207
207
  color: "violet",
208
- className: "bg-transparent ring-violet-300"
208
+ className: "border-violet-700 text-violet-700 dark:bg-violet-25"
209
209
  },
210
210
  {
211
211
  variant: "outline",
212
212
  color: "cyan",
213
- className: "bg-transparent ring-cyan-300"
213
+ className: "border-cyan-700 text-cyan-700 dark:bg-cyan-25"
214
214
  },
215
215
  {
216
216
  variant: "outline",
217
217
  color: "teal",
218
- className: "bg-transparent ring-teal-300"
218
+ className: "border-teal-700 text-teal-700 dark:bg-teal-25"
219
219
  },
220
220
  {
221
221
  variant: "outline",
222
222
  color: "brown",
223
- className: "bg-transparent ring-brown-300"
223
+ className: "border-brown-700 text-brown-700 dark:bg-brown-25"
224
224
  },
225
225
  {
226
226
  variant: "outline",
227
227
  color: "orange",
228
- className: "bg-transparent ring-orange-300"
228
+ className: "border-orange-700 text-orange-700 dark:bg-orange-25"
229
229
  },
230
- { variant: "fill", color: "gray", className: "text-white bg-gray-900" },
231
- { variant: "fill", color: "green", className: "text-white bg-green-700" },
232
- { variant: "fill", color: "red", className: "text-white bg-red-700" },
230
+ { variant: "fill", color: "gray", className: "bg-black text-white" },
233
231
  {
234
232
  variant: "fill",
235
- color: "yellow",
236
- className: "text-white bg-amber-700"
233
+ color: "green",
234
+ className: "bg-green-700 text-white dark:text-black"
235
+ },
236
+ {
237
+ variant: "fill",
238
+ color: "red",
239
+ className: "bg-red-700 text-white dark:text-black"
240
+ },
241
+ {
242
+ variant: "fill",
243
+ color: "amber",
244
+ className: "bg-amber-700 text-white dark:text-black"
237
245
  },
238
246
  {
239
247
  variant: "fill",
240
248
  color: "blue",
241
- className: "text-white dark:text-black bg-blue-700"
249
+ className: "bg-blue-700 text-white dark:text-black"
242
250
  },
243
251
  {
244
252
  variant: "fill",
245
253
  color: "crimson",
246
- className: "text-white bg-crimson-700"
254
+ className: "bg-crimson-700 text-white dark:text-black"
247
255
  },
248
256
  {
249
257
  variant: "fill",
250
258
  color: "violet",
251
- className: "text-white bg-violet-700"
259
+ className: "bg-violet-700 text-white dark:text-black"
260
+ },
261
+ {
262
+ variant: "fill",
263
+ color: "cyan",
264
+ className: "bg-cyan-700 text-white dark:text-black"
265
+ },
266
+ {
267
+ variant: "fill",
268
+ color: "teal",
269
+ className: "bg-teal-700 text-white dark:text-black"
270
+ },
271
+ {
272
+ variant: "fill",
273
+ color: "brown",
274
+ className: "bg-brown-700 text-white dark:text-black"
252
275
  },
253
- { variant: "fill", color: "cyan", className: "text-white bg-cyan-700" },
254
- { variant: "fill", color: "teal", className: "text-white bg-teal-700" },
255
- { variant: "fill", color: "brown", className: "text-white bg-brown-700" },
256
276
  {
257
277
  variant: "fill",
258
278
  color: "orange",
259
- className: "text-white bg-orange-700"
279
+ className: "bg-orange-700 text-white dark:text-black"
260
280
  }
261
281
  ],
262
282
  defaultVariants: {
@@ -372,7 +392,7 @@ var import_react_slot = require("@radix-ui/react-slot");
372
392
  var import_cva2 = require("cva");
373
393
  var import_jsx_runtime5 = require("react/jsx-runtime");
374
394
  var buttonVariants = (0, import_cva2.cva)({
375
- base: "inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium ring-offset-background transition-colors relative focus-visible:outline-hidden focus-visible:ring-2 disabled:select-none disabled:pointer-events-none disabled:opacity-40",
395
+ base: "inline-flex items-center justify-center gap-2 rounded-lg text-sm font-medium ring-offset-background transition-colors relative focus-visible:outline-hidden focus-visible:ring-2 disabled:select-none disabled:pointer-events-none disabled:opacity-40",
376
396
  variants: {
377
397
  variant: {
378
398
  primary: "bg-blue-700 text-white [&>svg]:text-white dark:text-black dark:[&>svg]:text-black hover:bg-blue-800 active:bg-blue-900 focus-visible:ring-blue-1000",
@@ -539,7 +559,7 @@ var Command = React4.forwardRef((_a, ref) => {
539
559
  __spreadValues({
540
560
  ref,
541
561
  className: cn(
542
- "flex h-full w-full flex-col overflow-hidden rounded-md bg-white",
562
+ "flex h-full w-full flex-col overflow-hidden rounded-lg bg-white",
543
563
  className
544
564
  )
545
565
  }, props)
@@ -566,7 +586,7 @@ var CommandInput = React4.forwardRef((_a, ref) => {
566
586
  ref,
567
587
  value: val,
568
588
  className: cn(
569
- "flex w-full py-2 rounded-md bg-transparent text-sm font-normal text-black outline-hidden placeholder:text-gray-900 disabled:cursor-not-allowed disabled:opacity-50",
589
+ "flex w-full py-2 rounded-lg bg-transparent text-sm font-normal text-black outline-hidden placeholder:text-gray-900 disabled:cursor-not-allowed disabled:opacity-50",
570
590
  className
571
591
  ),
572
592
  onValueChange: (val2) => {
@@ -661,7 +681,7 @@ var CommandItem = React4.forwardRef(
661
681
  __spreadProps(__spreadValues({
662
682
  ref,
663
683
  className: cn(
664
- "px-2 py-1.5 text-sm flex flex-col gap-1 text-black rounded-md cursor-pointer focus-within:bg-gray-100 data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50 hover:bg-gray-50 active:bg-gray-100 data-[state=checked]:bg-gray-50 data-[selected=true]:bg-gray-50",
684
+ "px-2 py-1.5 text-sm flex flex-col gap-1 text-black rounded-lg cursor-pointer focus-within:bg-gray-100 data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50 hover:bg-gray-50 active:bg-gray-100 data-[state=checked]:bg-gray-50 data-[selected=true]:bg-gray-50",
665
685
  className
666
686
  )
667
687
  }, props), {
@@ -3,7 +3,7 @@ import {
3
3
  CommandItem,
4
4
  CommandList,
5
5
  CommandLoading
6
- } from "../../chunk-SSZ45TLL.mjs";
6
+ } from "../../chunk-VIB6AUT2.mjs";
7
7
  import {
8
8
  XCloseIcon
9
9
  } from "../../chunk-FMJFBQTF.mjs";
@@ -11,8 +11,8 @@ import "../../chunk-TU6HU32A.mjs";
11
11
  import "../../chunk-AFJWE6PJ.mjs";
12
12
  import {
13
13
  Badge
14
- } from "../../chunk-YC4ZDBIC.mjs";
15
- import "../../chunk-R6W6SKNR.mjs";
14
+ } from "../../chunk-VBMQG5SW.mjs";
15
+ import "../../chunk-7WNKULE2.mjs";
16
16
  import "../../chunk-N65I4EXR.mjs";
17
17
  import {
18
18
  __objRest,
@@ -71,7 +71,7 @@ __export(Dialog_exports, {
71
71
  module.exports = __toCommonJS(Dialog_exports);
72
72
 
73
73
  // src/components/Dialog/Dialog.tsx
74
- var React2 = __toESM(require("react"));
74
+ var React = __toESM(require("react"));
75
75
  var DialogPrimitive = __toESM(require("@radix-ui/react-dialog"));
76
76
 
77
77
  // src/icons/xClose.tsx
@@ -113,210 +113,50 @@ function cn(...inputs) {
113
113
  return (0, import_tailwind_merge.twMerge)((0, import_clsx.clsx)(inputs));
114
114
  }
115
115
 
116
- // src/components/Button/Button.tsx
117
- var React = __toESM(require("react"));
118
- var import_react_slot = require("@radix-ui/react-slot");
119
- var import_cva = require("cva");
120
-
121
- // src/icons/spinner.tsx
122
- var import_react2 = require("react");
123
- var import_jsx_runtime2 = require("react/jsx-runtime");
124
- var SpinnerIcon = (0, import_react2.forwardRef)(
125
- function SpinnerIcon2(_a, ref) {
126
- var _b = _a, { size = 24, className = "animate-spin text-gray-1000" } = _b, other = __objRest(_b, ["size", "className"]);
127
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
128
- "svg",
129
- __spreadProps(__spreadValues({
130
- ref,
131
- width: size,
132
- height: size,
133
- viewBox: "0 0 25 24",
134
- fill: "none",
135
- xmlns: "http://www.w3.org/2000/svg",
136
- className
137
- }, other), {
138
- children: [
139
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
140
- "path",
141
- {
142
- opacity: "0.12",
143
- d: "M24.5 12C24.5 18.6274 19.1274 24 12.5 24C5.87258 24 0.5 18.6274 0.5 12C0.5 5.37258 5.87258 0 12.5 0C19.1274 0 24.5 5.37258 24.5 12ZM3.668 12C3.668 16.8778 7.62222 20.832 12.5 20.832C17.3778 20.832 21.332 16.8778 21.332 12C21.332 7.12222 17.3778 3.168 12.5 3.168C7.62222 3.168 3.668 7.12222 3.668 12Z",
144
- fill: "currentColor"
145
- }
146
- ),
147
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
148
- "path",
149
- {
150
- d: "M22.916 12C23.7908 12 24.5108 12.7122 24.3956 13.5794C24.1641 15.323 23.5512 17.0011 22.5928 18.4912C21.3476 20.4272 19.5719 21.9643 17.4774 22.919C15.3829 23.8738 13.058 24.206 10.7799 23.8761C8.50179 23.5461 6.36667 22.5679 4.62912 21.0581C2.89158 19.5483 1.62494 17.5706 0.98025 15.3609C0.335563 13.1511 0.340035 10.8026 0.993131 8.5953C1.64623 6.38803 2.92039 4.41517 4.66367 2.91199C6.00545 1.75501 7.58156 0.913857 9.27571 0.441275C10.1184 0.206218 10.9241 0.819698 11.0462 1.68595C11.1683 2.55221 10.5575 3.33995 9.72694 3.61463C8.63201 3.97673 7.61359 4.55146 6.73246 5.31122C5.44941 6.41757 4.51162 7.86959 4.03094 9.49414C3.55027 11.1187 3.54697 12.8472 4.02146 14.4736C4.49595 16.1 5.4282 17.5555 6.70703 18.6668C7.98587 19.778 9.55732 20.4979 11.234 20.7408C12.9107 20.9836 14.6218 20.7391 16.1634 20.0364C17.7049 19.3337 19.0119 18.2024 19.9283 16.7775C20.5576 15.799 20.9846 14.7103 21.1903 13.5755C21.3464 12.7148 22.0412 12 22.916 12Z",
151
- fill: "currentColor"
152
- }
153
- )
154
- ]
155
- })
156
- );
157
- }
158
- );
159
-
160
- // src/components/Button/Button.tsx
161
- var import_jsx_runtime3 = require("react/jsx-runtime");
162
- var buttonVariants = (0, import_cva.cva)({
163
- base: "inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium ring-offset-background transition-colors relative focus-visible:outline-hidden focus-visible:ring-2 disabled:select-none disabled:pointer-events-none disabled:opacity-40",
164
- variants: {
165
- variant: {
166
- primary: "bg-blue-700 text-white [&>svg]:text-white dark:text-black dark:[&>svg]:text-black hover:bg-blue-800 active:bg-blue-900 focus-visible:ring-blue-1000",
167
- secondary: "bg-gray-50 text-black [&>svg]:text-black hover:bg-gray-100 active:bg-gray-500 focus-visible:ring-black",
168
- tertiary: "bg-gray-50 text-blue-700 [&>svg]:text-blue-700 hover:bg-blue-100 active:bg-blue-200 focus-visible:ring-blue-700",
169
- outline: "bg-white text-black [&>svg]:text-black ring-1 ring-offset-0 ring-gray-200 hover:bg-gray-50 active:bg-gray-200 focus-visible:ring-black",
170
- outlineBlue: "bg-transparent text-blue-700 [&>svg]:text-blue-700 ring-1 ring-inset ring-offset-0 ring-blue-700 hover:bg-blue-50 active:bg-blue-200 focus-visible:ring-blue-700 ",
171
- destructive: "bg-red-700 text-white [&>svg]:text-white dark:text-black dark:[&>svg]:text-black hover:bg-red-800 active:bg-red-900 focus-visible:ring-red-1000",
172
- ghostBlue: "bg-transparent text-blue-700 [&>svg]:text-blue-700 hover:bg-blue-100 active:bg-blue-200 focus-visible:ring-blue-700",
173
- ghostRed: "bg-transparent text-red-700 [&>svg]:text-red-700 hover:bg-red-100 active:bg-red-200 focus-visible:ring-red-700",
174
- ghostGray: "bg-transparent text-black [&>svg]:text-black hover:bg-gray-100 active:bg-gray-200 focus-visible:ring-black",
175
- roundedFill: "rounded-2xl text-black [&>svg]:text-black bg-gray-200 active:bg-gray-300 border-2 border-gray-400 hover:border-gray-600",
176
- roundedGlass: "rounded-2xl text-black [&>svg]:text-black bg-gray-100/50 hover:bg-gray-100/75 active:bg-gray-100 backdrop-blur-[20px]"
177
- }
178
- },
179
- defaultVariants: {
180
- variant: "primary"
181
- }
182
- });
183
- var buttonSizes = (0, import_cva.cva)({
184
- variants: {
185
- size: {
186
- xs: "text-xs px-2.5 py-1.5",
187
- sm: "text-sm px-3 py-2",
188
- md: "text-md px-3.5 py-2.5",
189
- lg: "text-lg px-4 py-3"
190
- }
191
- },
192
- defaultVariants: {
193
- size: "md"
194
- }
195
- });
196
- var iconButtonSizes = (0, import_cva.cva)({
197
- variants: {
198
- size: {
199
- xs: "p-2",
200
- sm: "p-2.5",
201
- md: "p-[11px]",
202
- lg: "p-3"
203
- }
204
- },
205
- defaultVariants: {
206
- size: "md"
207
- }
208
- });
209
- var iconSizes = {
210
- xs: 12,
211
- sm: 16,
212
- md: 18,
213
- lg: 24
214
- };
215
- var Button = React.forwardRef(
216
- (_a, ref) => {
217
- var _b = _a, {
218
- className,
219
- variant,
220
- size,
221
- icon = false,
222
- isLoading = false,
223
- asChild = false,
224
- children,
225
- type = "button"
226
- } = _b, props = __objRest(_b, [
227
- "className",
228
- "variant",
229
- "size",
230
- "icon",
231
- "isLoading",
232
- "asChild",
233
- "children",
234
- "type"
235
- ]);
236
- var _a2;
237
- const Comp = asChild ? import_react_slot.Slot : "button";
238
- const sizesStyle = icon ? iconButtonSizes : buttonSizes;
239
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
240
- Comp,
241
- __spreadProps(__spreadValues({
242
- className: cn(
243
- buttonVariants({ variant, className }),
244
- sizesStyle({ size })
245
- ),
246
- ref,
247
- disabled: (_a2 = props.disabled) != null ? _a2 : isLoading,
248
- type
249
- }, props), {
250
- children: isLoading ? /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
251
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
252
- SpinnerIcon,
253
- {
254
- size: iconSizes[size || "md"],
255
- className: "absolute text-inherit animate-spin"
256
- }
257
- ),
258
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { className: "flex gap-[inherit] invisible", children })
259
- ] }) : children
260
- })
261
- );
262
- }
263
- );
264
- Button.displayName = "Button";
265
-
266
116
  // src/components/Dialog/Dialog.tsx
267
- var import_jsx_runtime4 = require("react/jsx-runtime");
117
+ var import_jsx_runtime2 = require("react/jsx-runtime");
268
118
  var Dialog = DialogPrimitive.Root;
269
119
  var DialogTrigger = DialogPrimitive.Trigger;
270
- var DialogOverlay = React2.forwardRef((_a, ref) => {
120
+ var DialogOverlay = React.forwardRef((_a, ref) => {
271
121
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
272
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
122
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
273
123
  DialogPrimitive.Overlay,
274
124
  __spreadValues({
275
125
  ref,
276
126
  className: cn(
277
- "fixed inset-0 z-50 bg-black/25 backdrop-blur-xs data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
127
+ "fixed inset-0 z-50 bg-black/25 backdrop-blur-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
278
128
  className
279
129
  )
280
130
  }, props)
281
131
  );
282
132
  });
283
133
  DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
284
- var DialogContent = React2.forwardRef(
134
+ var DialogContent = React.forwardRef(
285
135
  (_a, ref) => {
286
136
  var _b = _a, { className, children, bottomSheet = false, showClose = true } = _b, props = __objRest(_b, ["className", "children", "bottomSheet", "showClose"]);
287
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(DialogPrimitive.Portal, { children: [
288
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(DialogOverlay, {}),
289
- /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
137
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(DialogPrimitive.Portal, { children: [
138
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(DialogOverlay, {}),
139
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
290
140
  DialogPrimitive.Content,
291
141
  __spreadProps(__spreadValues({
292
142
  ref,
293
143
  className: cn(
294
- "fixed left-[50%] top-[50%] z-50 grid w-full max-w-[400px] max-h-[90vh] overflow-y-auto translate-x-[-50%] translate-y-[-50%] gap-6 border border-gray-200 bg-white p-6 shadow-lg md:w-full",
144
+ "fixed left-[50%] top-[50%] z-50 flex flex-col divide-y divide-gray-200 w-full max-w-[400px] max-h-[90vh] overflow-hidden translate-x-[-50%] translate-y-[-50%] border border-gray-200 bg-white shadow-sm md:w-full",
295
145
  {
296
146
  "top-auto bottom-0 translate-y-0 ease-[cubic-bezier(0.075,0.82,0.165,1)] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=open]:slide-in-from-bottom-[100%] data-[state=closed]:slide-out-to-bottom-[100%] rounded-t-3xl": bottomSheet
297
147
  },
298
148
  {
299
- "duration-200 rounded-xl data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95": !bottomSheet
149
+ "duration-200 rounded-2xl data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95": !bottomSheet
300
150
  },
301
151
  className
302
152
  )
303
153
  }, props), {
304
154
  children: [
305
155
  children,
306
- showClose && /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
307
- DialogPrimitive.Close,
308
- {
309
- className: cn(
310
- buttonVariants({ variant: "secondary" }),
311
- iconButtonSizes({ size: "xs" }),
312
- "absolute right-6 top-6"
313
- ),
314
- children: [
315
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(XCloseIcon, { className: "w-3 h-3" }),
316
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "sr-only", children: "Close" })
317
- ]
318
- }
319
- )
156
+ showClose && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(DialogPrimitive.Close, { className: "absolute right-4 top-4 flex items-center justify-center bg-gray-50 hover:bg-gray-100 rounded-lg p-2 transition-colors", children: [
157
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(XCloseIcon, { className: "w-3 h-3" }),
158
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "sr-only", children: "Close" })
159
+ ] })
320
160
  ]
321
161
  })
322
162
  )
@@ -330,12 +170,7 @@ var DialogHeader = (_a) => {
330
170
  } = _b, props = __objRest(_b, [
331
171
  "className"
332
172
  ]);
333
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
334
- "div",
335
- __spreadValues({
336
- className: cn("flex flex-col space-y-1.5 text-left", className)
337
- }, props)
338
- );
173
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", __spreadValues({ className: cn("flex flex-col gap-1 p-4", className) }, props));
339
174
  };
340
175
  DialogHeader.displayName = "DialogHeader";
341
176
  var DialogFooter = (_a) => {
@@ -344,51 +179,51 @@ var DialogFooter = (_a) => {
344
179
  } = _b, props = __objRest(_b, [
345
180
  "className"
346
181
  ]);
347
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
182
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
348
183
  "div",
349
184
  __spreadValues({
350
185
  className: cn(
351
- "flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
186
+ "flex items-center justify-end gap-2 p-4 bg-gray-25",
352
187
  className
353
188
  )
354
189
  }, props)
355
190
  );
356
191
  };
357
192
  DialogFooter.displayName = "DialogFooter";
358
- var DialogTitle = React2.forwardRef((_a, ref) => {
193
+ var DialogTitle = React.forwardRef((_a, ref) => {
359
194
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
360
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
195
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
361
196
  DialogPrimitive.Title,
362
197
  __spreadValues({
363
198
  ref,
364
- className: cn("text-lg text-black font-semibold", className)
199
+ className: cn("text-base font-medium text-black", className)
365
200
  }, props)
366
201
  );
367
202
  });
368
203
  DialogTitle.displayName = DialogPrimitive.Title.displayName;
369
- var DialogDescription = React2.forwardRef((_a, ref) => {
204
+ var DialogDescription = React.forwardRef((_a, ref) => {
370
205
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
371
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
206
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
372
207
  DialogPrimitive.Description,
373
208
  __spreadValues({
374
209
  ref,
375
- className: cn("text-sm text-gray-700", className)
210
+ className: cn("text-sm text-gray-900", className)
376
211
  }, props)
377
212
  );
378
213
  });
379
214
  DialogDescription.displayName = DialogPrimitive.Description.displayName;
380
215
 
381
216
  // src/components/Dialog/useDialogState.ts
382
- var import_react3 = require("react");
217
+ var import_react2 = require("react");
383
218
  var useDialogState = (props) => {
384
- const [isOpen, setOpen] = (0, import_react3.useState)((props == null ? void 0 : props.defaultOpen) || false);
385
- const open = (0, import_react3.useCallback)(() => {
219
+ const [isOpen, setOpen] = (0, import_react2.useState)((props == null ? void 0 : props.defaultOpen) || false);
220
+ const open = (0, import_react2.useCallback)(() => {
386
221
  setOpen(true);
387
222
  }, []);
388
- const close = (0, import_react3.useCallback)(() => {
223
+ const close = (0, import_react2.useCallback)(() => {
389
224
  setOpen(false);
390
225
  }, []);
391
- const toggle = (0, import_react3.useCallback)(() => {
226
+ const toggle = (0, import_react2.useCallback)(() => {
392
227
  setOpen(!isOpen);
393
228
  }, [isOpen]);
394
229
  return {