@hai-dev/ui-kit 1.0.2 → 1.0.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.
Files changed (38) hide show
  1. package/dist/{Button-0AB7oP6Y.js → Button-DDlVTM6i.js} +3 -2
  2. package/dist/ButtonBase-CXGZ-DBC.js +1346 -0
  3. package/dist/{CircularProgress-BD6BPlN2.js → CircularProgress-CscJm1An.js} +9 -8
  4. package/dist/{DialogTitle-iOQ7wKEt.js → DialogTitle-KN1sayHD.js} +453 -555
  5. package/dist/assets/photo-list.css +1 -0
  6. package/dist/assets/upload-dialog.css +1 -1
  7. package/dist/components/button/button.js +1 -1
  8. package/dist/components/photo-crop-uploader/components/error-upload-dialog/error-upload-dialog.js +87 -23
  9. package/dist/components/photo-crop-uploader/components/photo-list/constants.d.ts +1 -0
  10. package/dist/components/photo-crop-uploader/components/photo-list/constants.js +4 -0
  11. package/dist/components/photo-crop-uploader/components/photo-list/index.d.ts +1 -0
  12. package/dist/components/photo-crop-uploader/components/photo-list/index.js +4 -0
  13. package/dist/components/photo-crop-uploader/components/photo-list/photo-list.d.ts +3 -0
  14. package/dist/components/photo-crop-uploader/components/photo-list/photo-list.js +88 -0
  15. package/dist/components/photo-crop-uploader/components/photo-list/types.d.ts +8 -0
  16. package/dist/components/photo-crop-uploader/components/photo-list/types.js +1 -0
  17. package/dist/components/photo-crop-uploader/components/upload-button/types.d.ts +3 -1
  18. package/dist/components/photo-crop-uploader/components/upload-button/upload-button.js +72 -62
  19. package/dist/components/photo-crop-uploader/components/upload-dialog/constants.d.ts +1 -0
  20. package/dist/components/photo-crop-uploader/components/upload-dialog/constants.js +4 -0
  21. package/dist/components/photo-crop-uploader/components/upload-dialog/types.d.ts +5 -2
  22. package/dist/components/photo-crop-uploader/components/upload-dialog/upload-dialog.js +170 -136
  23. package/dist/components/photo-crop-uploader/constants.d.ts +3 -0
  24. package/dist/components/photo-crop-uploader/constants.js +36 -33
  25. package/dist/components/photo-crop-uploader/locale.js +8 -2
  26. package/dist/components/photo-crop-uploader/photo-crop-uploader.js +163 -112
  27. package/dist/components/photo-crop-uploader/types.d.ts +3 -1
  28. package/dist/components/photo-crop-uploader/utils/get-default-cropped-photo.d.ts +3 -0
  29. package/dist/components/photo-crop-uploader/utils/get-default-cropped-photo.js +32 -0
  30. package/dist/components/photo-crop-uploader/utils/get-photo-crop.d.ts +1 -1
  31. package/dist/components/photo-crop-uploader/utils/get-photo-crop.js +12 -12
  32. package/dist/components/photo-crop-uploader/utils/index.d.ts +1 -0
  33. package/dist/components/photo-crop-uploader/utils/index.js +4 -2
  34. package/dist/components/photo-crop-uploader/utils/read-photo.js +33 -30
  35. package/dist/createTheme-DSHGFfg6.js +4124 -0
  36. package/dist/extendSxProp-CzeED7BH.js +49 -0
  37. package/package.json +1 -1
  38. package/dist/ButtonBase-Bw_3RZmN.js +0 -5453
@@ -0,0 +1,49 @@
1
+ import { T as u, c as f, i as a, d as m } from "./createTheme-DSHGFfg6.js";
2
+ import * as l from "react";
3
+ function h(t) {
4
+ return Object.keys(t).length === 0;
5
+ }
6
+ function x(t = null) {
7
+ const e = l.useContext(u);
8
+ return !e || h(e) ? t : e;
9
+ }
10
+ const y = f();
11
+ function b(t = y) {
12
+ return x(t);
13
+ }
14
+ const P = (t) => {
15
+ const e = {
16
+ systemProps: {},
17
+ otherProps: {}
18
+ }, r = t?.theme?.unstable_sxConfig ?? m;
19
+ return Object.keys(t).forEach((s) => {
20
+ r[s] ? e.systemProps[s] = t[s] : e.otherProps[s] = t[s];
21
+ }), e;
22
+ };
23
+ function g(t) {
24
+ const {
25
+ sx: e,
26
+ ...r
27
+ } = t, {
28
+ systemProps: s,
29
+ otherProps: c
30
+ } = P(r);
31
+ let n;
32
+ return Array.isArray(e) ? n = [s, ...e] : typeof e == "function" ? n = (...i) => {
33
+ const o = e(...i);
34
+ return a(o) ? {
35
+ ...s,
36
+ ...o
37
+ } : s;
38
+ } : n = {
39
+ ...s,
40
+ ...e
41
+ }, {
42
+ ...c,
43
+ sx: n
44
+ };
45
+ }
46
+ export {
47
+ g as e,
48
+ b as u
49
+ };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@hai-dev/ui-kit",
3
3
  "private": false,
4
- "version": "1.0.2",
4
+ "version": "1.0.3",
5
5
  "author": {
6
6
  "name": "Vladislav Knitrunov",
7
7
  "email": "kingvlad3008@gmail.com",