@szum-tech/design-system 2.5.1 → 2.7.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 (69) hide show
  1. package/dist/{chunk-75T7KAAY.js → chunk-36YD6ICC.js} +2 -2
  2. package/dist/chunk-3WSQRFUY.cjs +11 -0
  3. package/dist/{chunk-V5OVQTDR.js → chunk-5BTQ6BQA.js} +2 -2
  4. package/dist/chunk-7EYMOUWG.cjs +51 -0
  5. package/dist/{chunk-MOOWZNA6.js → chunk-7V34QHYR.js} +3 -3
  6. package/dist/chunk-D3MOZUNH.cjs +1043 -0
  7. package/dist/chunk-DFD2WUOU.js +27 -0
  8. package/dist/{chunk-Q2IKZZ3U.cjs → chunk-EIXSMEDP.cjs} +1 -0
  9. package/dist/chunk-EW6TE3N5.cjs +38 -0
  10. package/dist/{chunk-3DSBDIFJ.cjs → chunk-FPFRA5Q6.cjs} +2 -2
  11. package/dist/{chunk-BJ553XYM.cjs → chunk-G6VXQ7DJ.cjs} +3 -3
  12. package/dist/{chunk-RXYZURP4.js → chunk-GEACYHTU.js} +1 -0
  13. package/dist/chunk-H5O5L6XT.js +14 -0
  14. package/dist/chunk-I5P2HH5Z.js +136 -0
  15. package/dist/{chunk-3PV6NLP5.js → chunk-IAI7BIAG.js} +3 -3
  16. package/dist/{chunk-XKXP3W3H.cjs → chunk-K4TRAPRN.cjs} +3 -3
  17. package/dist/{chunk-4C7M4HBP.js → chunk-MI3CQBHC.js} +3 -3
  18. package/dist/{chunk-KXTNZ4UO.cjs → chunk-NHFHKMX2.cjs} +3 -3
  19. package/dist/{chunk-6L3QPLRR.cjs → chunk-OIWEXHFE.cjs} +3 -3
  20. package/dist/chunk-P5IUC7HJ.js +9 -0
  21. package/dist/chunk-S5BN23O7.cjs +147 -0
  22. package/dist/chunk-XIPREW2R.js +996 -0
  23. package/dist/{chunk-WMMJEZ7Y.js → chunk-YJFJLF7Y.js} +3 -3
  24. package/dist/{chunk-FPK72OV4.cjs → chunk-ZZ3EBGSD.cjs} +2 -2
  25. package/dist/components/badge/index.cjs +2 -2
  26. package/dist/components/badge/index.js +1 -1
  27. package/dist/components/button/index.cjs +2 -2
  28. package/dist/components/button/index.js +1 -1
  29. package/dist/components/card/index.cjs +7 -7
  30. package/dist/components/card/index.js +1 -1
  31. package/dist/components/form/index.cjs +21 -17
  32. package/dist/components/form/index.js +14 -10
  33. package/dist/components/index.cjs +194 -70
  34. package/dist/components/index.d.cts +4 -0
  35. package/dist/components/index.d.ts +4 -0
  36. package/dist/components/index.js +14 -10
  37. package/dist/components/input/index.cjs +2 -2
  38. package/dist/components/input/index.js +1 -1
  39. package/dist/components/item/index.cjs +48 -0
  40. package/dist/components/item/index.d.cts +60 -0
  41. package/dist/components/item/index.d.ts +60 -0
  42. package/dist/components/item/index.js +3 -0
  43. package/dist/components/select/index.cjs +3 -3
  44. package/dist/components/select/index.js +1 -1
  45. package/dist/components/separator/index.cjs +2 -2
  46. package/dist/components/separator/index.js +1 -1
  47. package/dist/components/spinner/index.cjs +11 -0
  48. package/dist/components/spinner/index.d.cts +7 -0
  49. package/dist/components/spinner/index.d.ts +7 -0
  50. package/dist/components/spinner/index.js +2 -0
  51. package/dist/components/stepper/index.cjs +103 -0
  52. package/dist/components/stepper/index.d.cts +162 -0
  53. package/dist/components/stepper/index.d.ts +162 -0
  54. package/dist/components/stepper/index.js +22 -0
  55. package/dist/components/textarea/index.cjs +2 -2
  56. package/dist/components/textarea/index.js +1 -1
  57. package/dist/contexts/index.cjs +18 -0
  58. package/dist/contexts/index.d.cts +11 -0
  59. package/dist/contexts/index.d.ts +11 -0
  60. package/dist/contexts/index.js +1 -0
  61. package/dist/hooks/index.cjs +18 -0
  62. package/dist/hooks/index.d.cts +14 -0
  63. package/dist/hooks/index.d.ts +14 -0
  64. package/dist/hooks/index.js +1 -0
  65. package/dist/icons/index.d.cts +3 -0
  66. package/dist/icons/index.d.ts +3 -0
  67. package/package.json +22 -1
  68. package/dist/chunk-DH5YKYXV.cjs +0 -116
  69. package/dist/chunk-SPCZ3GVM.js +0 -88
@@ -7,13 +7,13 @@ var inputCva = cva(
7
7
  "bg-app-foreground font-poppins h-10 w-full appearance-none border py-2 outline-0 transition-colors duration-300 ease-in-out",
8
8
  "placeholder:select-none placeholder:text-gray-400",
9
9
  "invalid:border-error-500 focus:border-primary-500 active:border-primary-500",
10
- "disabled:border-gray-800 disabled:text-gray-300 disabled:placeholder:text-gray-600 disabled:cursor-not-allowed"
10
+ "disabled:cursor-not-allowed disabled:border-gray-800 disabled:text-gray-300 disabled:placeholder:text-gray-600"
11
11
  ],
12
12
  {
13
13
  variants: {
14
14
  invalid: {
15
15
  true: ["text-error-500 border-error-500 hover:border-error-400 focus:text-gray-100"],
16
- false: ["border-gray-600 hover:border-primary-600 text-gray-100"]
16
+ false: ["hover:border-primary-600 border-gray-600 text-gray-100"]
17
17
  },
18
18
  withStartIcon: {
19
19
  true: "pl-11",
@@ -0,0 +1,11 @@
1
+ 'use strict';
2
+
3
+ var chunkH2BWO3SI_cjs = require('./chunk-H2BWO3SI.cjs');
4
+ var lucideReact = require('lucide-react');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+
7
+ function Spinner({ className, ...props }) {
8
+ return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.LoaderCircle, { role: "status", "aria-label": "Loading", className: chunkH2BWO3SI_cjs.cn("size-4 animate-spin", className), ...props });
9
+ }
10
+
11
+ exports.Spinner = Spinner;
@@ -1,9 +1,9 @@
1
1
  import { cn } from './chunk-ZD2QRAOX.js';
2
- import { twMerge } from 'tailwind-merge';
3
2
  import { jsx } from 'react/jsx-runtime';
3
+ import { twMerge } from 'tailwind-merge';
4
4
 
5
5
  function Card({ className, ...props }) {
6
- return /* @__PURE__ */ jsx("div", { className: twMerge("bg-app-foreground h-full rounded border border-gray-800", className), ...props });
6
+ return /* @__PURE__ */ jsx("div", { className: cn("bg-app-foreground h-full rounded border border-gray-800", className), ...props });
7
7
  }
8
8
  function CardHeader({ className, ...props }) {
9
9
  return /* @__PURE__ */ jsx("div", { className: cn("flex flex-col p-6", className), ...props });
@@ -0,0 +1,51 @@
1
+ 'use strict';
2
+
3
+ var React3 = require('react');
4
+
5
+ function _interopNamespace(e) {
6
+ if (e && e.__esModule) return e;
7
+ var n = Object.create(null);
8
+ if (e) {
9
+ Object.keys(e).forEach(function (k) {
10
+ if (k !== 'default') {
11
+ var d = Object.getOwnPropertyDescriptor(e, k);
12
+ Object.defineProperty(n, k, d.get ? d : {
13
+ enumerable: true,
14
+ get: function () { return e[k]; }
15
+ });
16
+ }
17
+ });
18
+ }
19
+ n.default = e;
20
+ return Object.freeze(n);
21
+ }
22
+
23
+ var React3__namespace = /*#__PURE__*/_interopNamespace(React3);
24
+
25
+ // src/hooks/use-validation-log.tsx
26
+ function useValidationLog({ check, scope, message }) {
27
+ React3__namespace.useEffect(() => {
28
+ if (!check) {
29
+ console.error(
30
+ `%c[Szum Tech-Design System]%c
31
+ ${scope}%c
32
+ ${message}`,
33
+ "color: #ef4444; font-weight: bold;",
34
+ "color: #3b82f6; font-weight: bold;",
35
+ "color: #f59e0b;"
36
+ );
37
+ }
38
+ }, [check, scope, message]);
39
+ }
40
+ function useLazyRef(fn) {
41
+ const ref = React3__namespace.useRef(null);
42
+ if (ref.current === null) {
43
+ ref.current = fn();
44
+ }
45
+ return ref;
46
+ }
47
+ var useIsomorphicLayoutEffect = typeof window === "undefined" ? React3__namespace.useEffect : React3__namespace.useLayoutEffect;
48
+
49
+ exports.useIsomorphicLayoutEffect = useIsomorphicLayoutEffect;
50
+ exports.useLazyRef = useLazyRef;
51
+ exports.useValidationLog = useValidationLog;
@@ -5,9 +5,9 @@ import { jsx } from 'react/jsx-runtime';
5
5
 
6
6
  var badgeCva = cva(
7
7
  [
8
- "text-xs inline-flex w-fit shrink-0 items-center justify-center gap-x-1 overflow-hidden whitespace-nowrap rounded border px-2 py-0.5 transition-[color,box-shadow]",
9
- "[&>svg]:size-3 [&>svg]:pointer-events-none",
10
- "focus-visible:border-ring focus-visible:ring-primary-500/50 focus-visible:ring-[3px]",
8
+ "inline-flex w-fit shrink-0 items-center justify-center gap-x-1 overflow-hidden whitespace-nowrap rounded border px-2 py-0.5 text-xs transition-[color,box-shadow]",
9
+ "[&>svg]:pointer-events-none [&>svg]:size-3",
10
+ "focus-visible:border-ring focus-visible:ring-primary-500/50 focus-visible:ring",
11
11
  "aria-invalid:ring-error-500/20 aria-invalid:border-ring-error-500"
12
12
  ],
13
13
  {