@konstructio/ui 0.0.12-alpha.1 → 0.0.12-alpha.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.
Files changed (58) hide show
  1. package/dist/{Combination-BQYb0Gw7.js → Combination-b348x__d.js} +24 -24
  2. package/dist/{Modal-W2GbkC_F.js → Modal-DZUwNzSW.js} +315 -307
  3. package/dist/components/Alert/Alert.js +58 -0
  4. package/dist/components/Alert/Alert.variants.js +77 -0
  5. package/dist/components/AlertDialog/AlertDialog.js +1 -1
  6. package/dist/components/AlertDialog/components/AlertDialogTrigger.js +1 -1
  7. package/dist/components/AlertDialog/components/index.js +1 -1
  8. package/dist/components/Autocomplete/components/List/List.js +3 -3
  9. package/dist/components/Breadcrumb/Breadcrumb.js +3 -3
  10. package/dist/components/Breadcrumb/components/Item/Item.js +4 -4
  11. package/dist/components/Breadcrumb/hooks/useBreadcrumb.js +1 -1
  12. package/dist/components/Button/Button.js +1 -1
  13. package/dist/components/Card/Card.js +3 -3
  14. package/dist/components/Checkbox/Checkbox.js +5 -5
  15. package/dist/components/Divider/Divider.js +10 -0
  16. package/dist/components/Divider/Divider.variants.js +14 -0
  17. package/dist/components/Loading/Loading.js +28 -0
  18. package/dist/components/Loading/Loading.variants.js +20 -0
  19. package/dist/components/Modal/Modal.js +2 -2
  20. package/dist/components/Modal/components/Body/Body.js +1 -1
  21. package/dist/components/Modal/components/Footer/Footer.js +1 -1
  22. package/dist/components/Modal/components/Header/Header.js +1 -1
  23. package/dist/components/Modal/components/Wrapper/Wrapper.js +3 -3
  24. package/dist/components/Modal/components/index.js +1 -1
  25. package/dist/components/NumberInput/NumberInput.js +1 -1
  26. package/dist/components/ProgressBar/ProgressBar.js +3 -3
  27. package/dist/components/Radio/Radio.js +4 -4
  28. package/dist/components/RadioGroup/RadioGroup.js +1 -1
  29. package/dist/components/Range/Range.js +4 -4
  30. package/dist/components/Sidebar/components/Wrapper/Wrapper.js +3 -3
  31. package/dist/components/Slider/Slider.js +14 -14
  32. package/dist/components/Switch/Switch.js +17 -17
  33. package/dist/components/TagSelect/TagSelect.js +3 -3
  34. package/dist/components/Toast/Toast.js +11 -11
  35. package/dist/components/Tooltip/Tooltip.js +4 -4
  36. package/dist/components/Typography/Typography.js +30 -0
  37. package/dist/components/Typography/Typography.variants.js +36 -0
  38. package/dist/components/index.js +61 -53
  39. package/dist/{index-BVppSRDQ.js → index-3jTPaVvh.js} +9 -9
  40. package/dist/{index-BxeV34ij.js → index-4ecjw_Aj.js} +1 -1
  41. package/dist/{index-CoqDsznq.js → index-B33at13_.js} +3 -3
  42. package/dist/{index-1GLoikpT.js → index-BTeAm7mx.js} +6808 -6809
  43. package/dist/index-B_6_jmOO.js +68 -0
  44. package/dist/{index-BBjak_0p.js → index-BbsJ0VIJ.js} +2 -2
  45. package/dist/{index-CJsYodgi.js → index-C6WtlN_F.js} +9 -9
  46. package/dist/{index-8vgf-x5i.js → index-Cva-e5M4.js} +2 -2
  47. package/dist/{index-D4Q2rMby.js → index-Dj1pom3_.js} +2 -2
  48. package/dist/{index-KEdwcThH.js → index-Z1voPZOH.js} +1 -1
  49. package/dist/index.d.ts +41 -2
  50. package/dist/index.js +76 -68
  51. package/dist/package.json +27 -28
  52. package/dist/plugins/konstruct.js +34 -31
  53. package/dist/plugins/utils/animation.styles.js +162 -0
  54. package/dist/plugins/utils/index.js +7 -0
  55. package/dist/styles.css +1 -1
  56. package/dist/{useBreadcrumb-CojbXFVD.js → useBreadcrumb-BsIeMoR1.js} +47 -47
  57. package/package.json +27 -28
  58. package/dist/index-DoOsnuB6.js +0 -72
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@konstructio/ui",
3
3
  "description": "A set of reusable and customizable React components built for konstruct.io",
4
4
  "private": false,
5
- "version": "0.0.12-alpha.1",
5
+ "version": "0.0.12-alpha.2",
6
6
  "type": "module",
7
7
  "license": "MIT",
8
8
  "main": "dist/index.js",
@@ -45,7 +45,6 @@
45
45
  "check:types": "tsc -p tsconfig.json",
46
46
  "ci": "npm run build && npm run check:prettier && vitest run",
47
47
  "deps:update": "npx npm-check-updates --interactive --format group",
48
- "dev": "vite",
49
48
  "format:prettier": "prettier lib --write './**/*.{js,jsx,ts,tsx}' --config ./.prettierrc",
50
49
  "lint": "eslint lib --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
51
50
  "prepare": "husky",
@@ -56,18 +55,18 @@
56
55
  "test:watch": "vitest dev"
57
56
  },
58
57
  "dependencies": {
59
- "@radix-ui/react-alert-dialog": "^1.1.5",
60
- "@radix-ui/react-checkbox": "^1.1.3",
61
- "@radix-ui/react-slider": "^1.2.2",
62
- "@radix-ui/react-slot": "^1.1.1",
63
- "@radix-ui/react-switch": "^1.1.2",
64
- "@radix-ui/react-toast": "^1.2.5",
65
- "@radix-ui/react-visually-hidden": "^1.1.1",
58
+ "@radix-ui/react-alert-dialog": "^1.1.6",
59
+ "@radix-ui/react-checkbox": "^1.1.4",
60
+ "@radix-ui/react-slider": "^1.2.3",
61
+ "@radix-ui/react-slot": "^1.1.2",
62
+ "@radix-ui/react-switch": "^1.1.3",
63
+ "@radix-ui/react-toast": "^1.2.6",
64
+ "@radix-ui/react-visually-hidden": "^1.1.2",
66
65
  "class-variance-authority": "^0.7.1",
67
66
  "clsx": "^2.1.1",
68
67
  "js-cookie": "^3.0.5",
69
68
  "react-feather": "^2.0.10",
70
- "react-focus-lock": "^2.13.5",
69
+ "react-focus-lock": "^2.13.6",
71
70
  "react-remove-scroll": "^2.6.3",
72
71
  "tailwind-merge": "^3.0.1"
73
72
  },
@@ -101,27 +100,27 @@
101
100
  },
102
101
  "devDependencies": {
103
102
  "@rollup/plugin-alias": "^5.1.1",
104
- "@storybook/addon-docs": "^8.5.3",
105
- "@storybook/addon-essentials": "^8.5.3",
106
- "@storybook/addon-interactions": "^8.5.3",
107
- "@storybook/addon-links": "^8.5.3",
103
+ "@storybook/addon-docs": "^8.5.6",
104
+ "@storybook/addon-essentials": "^8.5.6",
105
+ "@storybook/addon-interactions": "^8.5.6",
106
+ "@storybook/addon-links": "^8.5.6",
108
107
  "@storybook/addon-styling-webpack": "^1.0.1",
109
- "@storybook/blocks": "^8.5.3",
110
- "@storybook/react": "^8.5.3",
111
- "@storybook/react-vite": "^8.5.3",
112
- "@storybook/test": "^8.5.3",
108
+ "@storybook/blocks": "^8.5.6",
109
+ "@storybook/react": "^8.5.6",
110
+ "@storybook/react-vite": "^8.5.6",
111
+ "@storybook/test": "^8.5.6",
113
112
  "@testing-library/jest-dom": "^6.6.3",
114
113
  "@testing-library/react": "^16.2.0",
115
114
  "@testing-library/user-event": "^14.6.1",
116
115
  "@types/jest-axe": "^3.5.9",
117
116
  "@types/js-cookie": "^3.0.6",
118
117
  "@types/lodash": "^4.17.15",
119
- "@types/react": "^19.0.8",
120
- "@types/react-dom": "^19.0.3",
121
- "@typescript-eslint/eslint-plugin": "^8.23.0",
122
- "@typescript-eslint/parser": "^8.23.0",
118
+ "@types/react": "^19.0.10",
119
+ "@types/react-dom": "^19.0.4",
120
+ "@typescript-eslint/eslint-plugin": "^8.24.1",
121
+ "@typescript-eslint/parser": "^8.24.1",
123
122
  "@vitejs/plugin-react": "^4.3.4",
124
- "@vitest/coverage-v8": "^3.0.5",
123
+ "@vitest/coverage-v8": "^3.0.6",
125
124
  "autoprefixer": "^10.4.20",
126
125
  "eslint": "^8.57.0",
127
126
  "eslint-plugin-react-hooks": "^4.6.2",
@@ -133,18 +132,18 @@
133
132
  "jest-axe": "^9.0.0",
134
133
  "jsdom": "^26.0.0",
135
134
  "lodash": "^4.17.21",
136
- "postcss": "^8.5.1",
137
- "prettier": "^3.4.2",
135
+ "postcss": "^8.5.2",
136
+ "prettier": "^3.5.1",
138
137
  "rimraf": "^6.0.1",
139
- "storybook": "^8.5.3",
138
+ "storybook": "^8.5.6",
140
139
  "tailwindcss": "^3.4.17",
141
140
  "ts-node": "^10.9.2",
142
141
  "typescript": "^5.7.3",
143
- "vite": "^6.0.11",
142
+ "vite": "^6.1.0",
144
143
  "vite-plugin-dts": "^4.5.0",
145
144
  "vite-plugin-lib-inject-css": "^2.2.1",
146
145
  "vite-plugin-svgr": "^4.3.0",
147
146
  "vite-tsconfig-paths": "^5.1.4",
148
- "vitest": "^3.0.5"
147
+ "vitest": "^3.0.6"
149
148
  }
150
149
  }
@@ -1,72 +0,0 @@
1
- import * as i from "react";
2
- import { jsx as c, Fragment as m } from "react/jsx-runtime";
3
- function p(e, n) {
4
- if (typeof e == "function")
5
- return e(n);
6
- e != null && (e.current = n);
7
- }
8
- function d(...e) {
9
- return (n) => {
10
- let r = !1;
11
- const o = e.map((t) => {
12
- const l = p(t, n);
13
- return !r && typeof l == "function" && (r = !0), l;
14
- });
15
- if (r)
16
- return () => {
17
- for (let t = 0; t < o.length; t++) {
18
- const l = o[t];
19
- typeof l == "function" ? l() : p(e[t], null);
20
- }
21
- };
22
- };
23
- }
24
- function S(...e) {
25
- return i.useCallback(d(...e), e);
26
- }
27
- var y = i.forwardRef((e, n) => {
28
- const { children: r, ...o } = e, t = i.Children.toArray(r), l = t.find(h);
29
- if (l) {
30
- const s = l.props.children, a = t.map((f) => f === l ? i.Children.count(s) > 1 ? i.Children.only(null) : i.isValidElement(s) ? s.props.children : null : f);
31
- return /* @__PURE__ */ c(u, { ...o, ref: n, children: i.isValidElement(s) ? i.cloneElement(s, void 0, a) : null });
32
- }
33
- return /* @__PURE__ */ c(u, { ...o, ref: n, children: r });
34
- });
35
- y.displayName = "Slot";
36
- var u = i.forwardRef((e, n) => {
37
- const { children: r, ...o } = e;
38
- if (i.isValidElement(r)) {
39
- const t = R(r);
40
- return i.cloneElement(r, {
41
- ...C(o, r.props),
42
- // @ts-ignore
43
- ref: n ? d(n, t) : t
44
- });
45
- }
46
- return i.Children.count(r) > 1 ? i.Children.only(null) : null;
47
- });
48
- u.displayName = "SlotClone";
49
- var g = ({ children: e }) => /* @__PURE__ */ c(m, { children: e });
50
- function h(e) {
51
- return i.isValidElement(e) && e.type === g;
52
- }
53
- function C(e, n) {
54
- const r = { ...n };
55
- for (const o in n) {
56
- const t = e[o], l = n[o];
57
- /^on[A-Z]/.test(o) ? t && l ? r[o] = (...a) => {
58
- l(...a), t(...a);
59
- } : t && (r[o] = t) : o === "style" ? r[o] = { ...t, ...l } : o === "className" && (r[o] = [t, l].filter(Boolean).join(" "));
60
- }
61
- return { ...e, ...r };
62
- }
63
- function R(e) {
64
- var o, t;
65
- let n = (o = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : o.get, r = n && "isReactWarning" in n && n.isReactWarning;
66
- return r ? e.ref : (n = (t = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : t.get, r = n && "isReactWarning" in n && n.isReactWarning, r ? e.props.ref : e.props.ref || e.ref);
67
- }
68
- export {
69
- y as S,
70
- g as a,
71
- S as u
72
- };