demio-ui 2.5.56 → 2.5.58
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/cjs/index.css +1 -1
- package/dist/cjs/index.js +5 -5
- package/dist/cjs/types/src/components/Toast/Toast.d.ts +39 -0
- package/dist/cjs/types/src/components/Toast/index.d.ts +1 -0
- package/dist/cjs/types/src/components/Upload/Upload.d.ts +24 -0
- package/dist/cjs/types/src/components/UploadPreview/UploadPreview.d.ts +12 -0
- package/dist/cjs/types/src/components/UploadPreview/index.d.ts +1 -0
- package/dist/cjs/types/src/components/index.d.ts +1 -0
- package/dist/cjs/types/src/utils/index.d.ts +1 -0
- package/dist/cjs/types/src/utils/toast/index.d.ts +1 -0
- package/dist/cjs/types/src/utils/toast/toast.d.ts +2 -0
- package/dist/esm/index.css +1 -1
- package/dist/esm/index.js +5 -5
- package/dist/esm/types/src/components/Toast/Toast.d.ts +39 -0
- package/dist/esm/types/src/components/Toast/index.d.ts +1 -0
- package/dist/esm/types/src/components/Upload/Upload.d.ts +24 -0
- package/dist/esm/types/src/components/UploadPreview/UploadPreview.d.ts +12 -0
- package/dist/esm/types/src/components/UploadPreview/index.d.ts +1 -0
- package/dist/esm/types/src/components/index.d.ts +1 -0
- package/dist/esm/types/src/utils/index.d.ts +1 -0
- package/dist/esm/types/src/utils/toast/index.d.ts +1 -0
- package/dist/esm/types/src/utils/toast/toast.d.ts +2 -0
- package/dist/types.d.ts +78 -29
- package/package.json +16 -16
- package/dist/cjs/types/src/components/Crop/Crop.utils.d.ts +0 -11
- package/dist/cjs/types/src/components/DnDArea/DnDArea.utils.d.ts +0 -3
- package/dist/cjs/types/src/components/Pagination/Pagination.utils.d.ts +0 -7
- package/dist/cjs/types/src/hooks/useCroppedImage.d.ts +0 -4
- package/dist/esm/types/src/components/Crop/Crop.utils.d.ts +0 -11
- package/dist/esm/types/src/components/DnDArea/DnDArea.utils.d.ts +0 -3
- package/dist/esm/types/src/components/Pagination/Pagination.utils.d.ts +0 -7
- package/dist/esm/types/src/hooks/useCroppedImage.d.ts +0 -4
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { FC, ReactNode } from 'react';
|
|
2
|
+
declare global {
|
|
3
|
+
interface Window {
|
|
4
|
+
showToast: (options?: IToast) => void;
|
|
5
|
+
}
|
|
6
|
+
}
|
|
7
|
+
export interface IToast {
|
|
8
|
+
attempts?: number;
|
|
9
|
+
className?: string;
|
|
10
|
+
duration?: number;
|
|
11
|
+
id?: number;
|
|
12
|
+
isClosable?: boolean;
|
|
13
|
+
isInfo?: boolean;
|
|
14
|
+
isError?: boolean;
|
|
15
|
+
isSuccess?: boolean;
|
|
16
|
+
message?: ReactNode;
|
|
17
|
+
onClose?: (id: number) => void;
|
|
18
|
+
timeout?: number;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
### Example of usage
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
import { toast } from 'demio-ui';
|
|
25
|
+
...
|
|
26
|
+
try {
|
|
27
|
+
...
|
|
28
|
+
} catch(error) {
|
|
29
|
+
toast({
|
|
30
|
+
message: error?.message || 'Some custom message',
|
|
31
|
+
isError: true,
|
|
32
|
+
onClose: (id) => console.log(`Close toast[${id}]`),
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
```
|
|
36
|
+
##### PS: Toast disappears on pressing the "Escape" button
|
|
37
|
+
**/
|
|
38
|
+
declare const Toast: FC;
|
|
39
|
+
export default Toast;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './Toast';
|
|
@@ -44,5 +44,29 @@ export interface UploadProps {
|
|
|
44
44
|
previewImageTitle?: string;
|
|
45
45
|
uploadPercent?: number;
|
|
46
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
The component has 3 states: **default**, **progress** and **preview** states.
|
|
49
|
+
|
|
50
|
+
- **Default** state is visible when **uploadPercent** prop is **undefined**.
|
|
51
|
+
- When the **uploadPercent** prop becomes a **number** and it is **less than 100** the **Upload** automatically switches to a **progress** state.
|
|
52
|
+
- When the **uploadPercent** prop is **equal to 100** the **Upload** automatically switches to a **preview** mode.
|
|
53
|
+
|
|
54
|
+
One more useful thing is related to a **UploadRef** interface. It consists of all the methods that need to be accessed through the **ref**. For example:
|
|
55
|
+
|
|
56
|
+
````
|
|
57
|
+
const uploadRef = useRef<UploadRef>(null);
|
|
58
|
+
|
|
59
|
+
const handleReset = () => {
|
|
60
|
+
uploadRef.current?.cancelUpload();
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<>
|
|
65
|
+
<Upload ref={uploadRef} />
|
|
66
|
+
<button onClick={handleReset}>Reset Upload</button>
|
|
67
|
+
</>
|
|
68
|
+
);
|
|
69
|
+
````
|
|
70
|
+
**/
|
|
47
71
|
declare const Upload: FC<UploadProps>;
|
|
48
72
|
export default Upload;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { UploadMenuItem } from '../UploadMenu/UploadMenu';
|
|
3
|
+
export interface UploadPreviewProps {
|
|
4
|
+
className?: string;
|
|
5
|
+
fileName?: string;
|
|
6
|
+
fileInfo?: string;
|
|
7
|
+
imageSrc?: string;
|
|
8
|
+
imageTitle?: string;
|
|
9
|
+
menu?: UploadMenuItem[];
|
|
10
|
+
}
|
|
11
|
+
declare const UploadPreview: FC<UploadPreviewProps>;
|
|
12
|
+
export default UploadPreview;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './UploadPreview';
|
|
@@ -27,6 +27,7 @@ export { default as Slider } from './Slider';
|
|
|
27
27
|
export { default as Switch } from './Switch';
|
|
28
28
|
export { Tab, TabsContent, TabsList, TabsRoot } from './Tabs';
|
|
29
29
|
export { Tag } from './Tag';
|
|
30
|
+
export { default as Toast } from './Toast';
|
|
30
31
|
export { PopoverTooltip, Tooltip } from './Tooltip';
|
|
31
32
|
export { Typography } from './Typography';
|
|
32
33
|
export { default as Upload } from './Upload';
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
export { getFileExtension, getFileMimeType, isExtensionMatchingMimeType, isImage, isValidFileDimension, isValidFileSize, isValidFileType, isVideo, mimeTypeMap, } from './file';
|
|
2
2
|
export { createImage, getCroppedImageURL, getRadianAngle, rotateSize } from './image';
|
|
3
|
+
export { toast } from './toast';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { toast } from './toast';
|
package/dist/types.d.ts
CHANGED
|
@@ -454,6 +454,44 @@ interface TagProps extends PropsWithChildren {
|
|
|
454
454
|
}
|
|
455
455
|
declare function Tag({ children, onDelete, className }: TagProps): React__default.JSX.Element;
|
|
456
456
|
|
|
457
|
+
declare global {
|
|
458
|
+
interface Window {
|
|
459
|
+
showToast: (options?: IToast) => void;
|
|
460
|
+
}
|
|
461
|
+
}
|
|
462
|
+
interface IToast {
|
|
463
|
+
attempts?: number;
|
|
464
|
+
className?: string;
|
|
465
|
+
duration?: number;
|
|
466
|
+
id?: number;
|
|
467
|
+
isClosable?: boolean;
|
|
468
|
+
isInfo?: boolean;
|
|
469
|
+
isError?: boolean;
|
|
470
|
+
isSuccess?: boolean;
|
|
471
|
+
message?: ReactNode;
|
|
472
|
+
onClose?: (id: number) => void;
|
|
473
|
+
timeout?: number;
|
|
474
|
+
}
|
|
475
|
+
/**
|
|
476
|
+
### Example of usage
|
|
477
|
+
|
|
478
|
+
```
|
|
479
|
+
import { toast } from 'demio-ui';
|
|
480
|
+
...
|
|
481
|
+
try {
|
|
482
|
+
...
|
|
483
|
+
} catch(error) {
|
|
484
|
+
toast({
|
|
485
|
+
message: error?.message || 'Some custom message',
|
|
486
|
+
isError: true,
|
|
487
|
+
onClose: (id) => console.log(`Close toast[${id}]`),
|
|
488
|
+
});
|
|
489
|
+
}
|
|
490
|
+
```
|
|
491
|
+
##### PS: Toast disappears on pressing the "Escape" button
|
|
492
|
+
**/
|
|
493
|
+
declare const Toast: FC;
|
|
494
|
+
|
|
457
495
|
type Props = {
|
|
458
496
|
align?: 'start' | 'center' | 'end';
|
|
459
497
|
alignOffset?: number;
|
|
@@ -562,6 +600,30 @@ interface UploadProps {
|
|
|
562
600
|
previewImageTitle?: string;
|
|
563
601
|
uploadPercent?: number;
|
|
564
602
|
}
|
|
603
|
+
/**
|
|
604
|
+
The component has 3 states: **default**, **progress** and **preview** states.
|
|
605
|
+
|
|
606
|
+
- **Default** state is visible when **uploadPercent** prop is **undefined**.
|
|
607
|
+
- When the **uploadPercent** prop becomes a **number** and it is **less than 100** the **Upload** automatically switches to a **progress** state.
|
|
608
|
+
- When the **uploadPercent** prop is **equal to 100** the **Upload** automatically switches to a **preview** mode.
|
|
609
|
+
|
|
610
|
+
One more useful thing is related to a **UploadRef** interface. It consists of all the methods that need to be accessed through the **ref**. For example:
|
|
611
|
+
|
|
612
|
+
````
|
|
613
|
+
const uploadRef = useRef<UploadRef>(null);
|
|
614
|
+
|
|
615
|
+
const handleReset = () => {
|
|
616
|
+
uploadRef.current?.cancelUpload();
|
|
617
|
+
};
|
|
618
|
+
|
|
619
|
+
return (
|
|
620
|
+
<>
|
|
621
|
+
<Upload ref={uploadRef} />
|
|
622
|
+
<button onClick={handleReset}>Reset Upload</button>
|
|
623
|
+
</>
|
|
624
|
+
);
|
|
625
|
+
````
|
|
626
|
+
**/
|
|
565
627
|
declare const Upload: FC<UploadProps>;
|
|
566
628
|
|
|
567
629
|
interface UploadErrorProps {
|
|
@@ -610,7 +672,7 @@ declare const useFileValidation: ({ acceptableFileTypes, fileSizeMbLimit, isVali
|
|
|
610
672
|
isFileValid: boolean;
|
|
611
673
|
};
|
|
612
674
|
|
|
613
|
-
var _path$1u, _g$
|
|
675
|
+
var _path$1u, _g$t;
|
|
614
676
|
function _extends$1v() { return _extends$1v = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1v.apply(null, arguments); }
|
|
615
677
|
var SvgAdd = function SvgAdd(props) {
|
|
616
678
|
return /*#__PURE__*/React.createElement("svg", _extends$1v({
|
|
@@ -631,7 +693,7 @@ var SvgAdd = function SvgAdd(props) {
|
|
|
631
693
|
}, _path$1u || (_path$1u = /*#__PURE__*/React.createElement("path", {
|
|
632
694
|
fill: "#D9D9D9",
|
|
633
695
|
d: "M0 0h24v24H0z"
|
|
634
|
-
}))), _g$
|
|
696
|
+
}))), _g$t || (_g$t = /*#__PURE__*/React.createElement("g", {
|
|
635
697
|
mask: "url(#add_svg__a)"
|
|
636
698
|
}, /*#__PURE__*/React.createElement("path", {
|
|
637
699
|
fill: "#2C3336",
|
|
@@ -718,7 +780,7 @@ var SvgBarChart = function SvgBarChart(props) {
|
|
|
718
780
|
})));
|
|
719
781
|
};
|
|
720
782
|
|
|
721
|
-
var _path$1n, _g$
|
|
783
|
+
var _path$1n, _g$s;
|
|
722
784
|
function _extends$1o() { return _extends$1o = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1o.apply(null, arguments); }
|
|
723
785
|
var SvgBlock = function SvgBlock(props) {
|
|
724
786
|
return /*#__PURE__*/React.createElement("svg", _extends$1o({
|
|
@@ -734,7 +796,7 @@ var SvgBlock = function SvgBlock(props) {
|
|
|
734
796
|
}, _path$1n || (_path$1n = /*#__PURE__*/React.createElement("path", {
|
|
735
797
|
fill: "#D9D9D9",
|
|
736
798
|
d: "M0 0h24v24H0z"
|
|
737
|
-
}))), _g$
|
|
799
|
+
}))), _g$s || (_g$s = /*#__PURE__*/React.createElement("g", {
|
|
738
800
|
mask: "url(#block_svg__a)"
|
|
739
801
|
}, /*#__PURE__*/React.createElement("path", {
|
|
740
802
|
fill: "#42454B",
|
|
@@ -742,7 +804,7 @@ var SvgBlock = function SvgBlock(props) {
|
|
|
742
804
|
}))));
|
|
743
805
|
};
|
|
744
806
|
|
|
745
|
-
var _path$1m, _g$
|
|
807
|
+
var _path$1m, _g$r;
|
|
746
808
|
function _extends$1n() { return _extends$1n = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1n.apply(null, arguments); }
|
|
747
809
|
var SvgBlurOn = function SvgBlurOn(props) {
|
|
748
810
|
return /*#__PURE__*/React.createElement("svg", _extends$1n({
|
|
@@ -763,7 +825,7 @@ var SvgBlurOn = function SvgBlurOn(props) {
|
|
|
763
825
|
}, _path$1m || (_path$1m = /*#__PURE__*/React.createElement("path", {
|
|
764
826
|
fill: "#D9D9D9",
|
|
765
827
|
d: "M0 0h24v24H0z"
|
|
766
|
-
}))), _g$
|
|
828
|
+
}))), _g$r || (_g$r = /*#__PURE__*/React.createElement("g", {
|
|
767
829
|
mask: "url(#blur_on_svg__a)"
|
|
768
830
|
}, /*#__PURE__*/React.createElement("path", {
|
|
769
831
|
fill: "#2C3336",
|
|
@@ -771,7 +833,7 @@ var SvgBlurOn = function SvgBlurOn(props) {
|
|
|
771
833
|
}))));
|
|
772
834
|
};
|
|
773
835
|
|
|
774
|
-
var _path$1l, _g$
|
|
836
|
+
var _path$1l, _g$q;
|
|
775
837
|
function _extends$1m() { return _extends$1m = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1m.apply(null, arguments); }
|
|
776
838
|
var SvgCached = function SvgCached(props) {
|
|
777
839
|
return /*#__PURE__*/React.createElement("svg", _extends$1m({
|
|
@@ -789,7 +851,7 @@ var SvgCached = function SvgCached(props) {
|
|
|
789
851
|
}, _path$1l || (_path$1l = /*#__PURE__*/React.createElement("path", {
|
|
790
852
|
fill: "#D9D9D9",
|
|
791
853
|
d: "M0 0h24v24H0z"
|
|
792
|
-
}))), _g$
|
|
854
|
+
}))), _g$q || (_g$q = /*#__PURE__*/React.createElement("g", {
|
|
793
855
|
mask: "url(#cached_svg__a)"
|
|
794
856
|
}, /*#__PURE__*/React.createElement("path", {
|
|
795
857
|
fill: "#2C3336",
|
|
@@ -797,7 +859,7 @@ var SvgCached = function SvgCached(props) {
|
|
|
797
859
|
}))));
|
|
798
860
|
};
|
|
799
861
|
|
|
800
|
-
var _path$1k, _g$
|
|
862
|
+
var _path$1k, _g$p;
|
|
801
863
|
function _extends$1l() { return _extends$1l = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1l.apply(null, arguments); }
|
|
802
864
|
var SvgCalendar = function SvgCalendar(props) {
|
|
803
865
|
return /*#__PURE__*/React.createElement("svg", _extends$1l({
|
|
@@ -819,7 +881,7 @@ var SvgCalendar = function SvgCalendar(props) {
|
|
|
819
881
|
}, _path$1k || (_path$1k = /*#__PURE__*/React.createElement("path", {
|
|
820
882
|
fill: "#D9D9D9",
|
|
821
883
|
d: "M0 0h32v32H0z"
|
|
822
|
-
}))), _g$
|
|
884
|
+
}))), _g$p || (_g$p = /*#__PURE__*/React.createElement("g", {
|
|
823
885
|
mask: "url(#calendar_svg__a)"
|
|
824
886
|
}, /*#__PURE__*/React.createElement("path", {
|
|
825
887
|
fill: "#11B06E",
|
|
@@ -899,32 +961,17 @@ var SvgChatDisabled = function SvgChatDisabled(props) {
|
|
|
899
961
|
})));
|
|
900
962
|
};
|
|
901
963
|
|
|
902
|
-
var _path$1f
|
|
964
|
+
var _path$1f;
|
|
903
965
|
function _extends$1g() { return _extends$1g = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1g.apply(null, arguments); }
|
|
904
966
|
var SvgCheckCircle = function SvgCheckCircle(props) {
|
|
905
967
|
return /*#__PURE__*/React.createElement("svg", _extends$1g({
|
|
906
968
|
xmlns: "http://www.w3.org/2000/svg",
|
|
907
969
|
fill: "none",
|
|
908
970
|
viewBox: "0 0 24 24"
|
|
909
|
-
}, props), /*#__PURE__*/React.createElement("
|
|
910
|
-
id: "check_circle_svg__a",
|
|
911
|
-
width: 24,
|
|
912
|
-
height: 24,
|
|
913
|
-
x: 0,
|
|
914
|
-
y: 0,
|
|
915
|
-
maskUnits: "userSpaceOnUse",
|
|
916
|
-
style: {
|
|
917
|
-
maskType: "alpha"
|
|
918
|
-
}
|
|
919
|
-
}, _path$1f || (_path$1f = /*#__PURE__*/React.createElement("path", {
|
|
920
|
-
fill: "#D9D9D9",
|
|
921
|
-
d: "M0 0h24v24H0z"
|
|
922
|
-
}))), _g$p || (_g$p = /*#__PURE__*/React.createElement("g", {
|
|
923
|
-
mask: "url(#check_circle_svg__a)"
|
|
924
|
-
}, /*#__PURE__*/React.createElement("path", {
|
|
971
|
+
}, props), _path$1f || (_path$1f = /*#__PURE__*/React.createElement("path", {
|
|
925
972
|
fill: "#2C3336",
|
|
926
973
|
d: "m10.58 14.146-2.322-2.323a.72.72 0 0 0-.522-.212.7.7 0 0 0-.532.212.72.72 0 0 0-.217.527q0 .31.217.527l2.744 2.744a.87.87 0 0 0 .633.271q.361 0 .632-.27l5.564-5.564a.73.73 0 0 0 .212-.522.7.7 0 0 0-.212-.532.72.72 0 0 0-.527-.217.72.72 0 0 0-.527.217zm1.422 7.354a9.3 9.3 0 0 1-3.705-.748 9.6 9.6 0 0 1-3.018-2.03 9.6 9.6 0 0 1-2.03-3.016 9.2 9.2 0 0 1-.749-3.704q0-1.972.748-3.705a9.6 9.6 0 0 1 2.03-3.018 9.6 9.6 0 0 1 3.016-2.03 9.2 9.2 0 0 1 3.704-.749q1.972 0 3.705.748a9.6 9.6 0 0 1 3.018 2.03 9.6 9.6 0 0 1 2.03 3.016 9.2 9.2 0 0 1 .749 3.704q0 1.972-.748 3.705a9.6 9.6 0 0 1-2.03 3.018 9.6 9.6 0 0 1-3.016 2.03 9.2 9.2 0 0 1-3.704.749"
|
|
927
|
-
})))
|
|
974
|
+
})));
|
|
928
975
|
};
|
|
929
976
|
|
|
930
977
|
var _path$1e;
|
|
@@ -2395,4 +2442,6 @@ declare const getCroppedImageURL: (imageSrc: string, pixelCrop: Area, rotation?:
|
|
|
2395
2442
|
vertical: boolean;
|
|
2396
2443
|
}) => Promise<string | null>;
|
|
2397
2444
|
|
|
2398
|
-
|
|
2445
|
+
declare const toast: (options?: IToast) => void;
|
|
2446
|
+
|
|
2447
|
+
export { Alert, Avatar, Badge, Button$1 as Button, Button as ButtonNew, Card, Checkbox, Crop, DnDArea, Drawer, DropdownItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuRoot, DropdownMenuSeparator, DropdownMenuTrigger, FormGroup, InfoBanner, Input, InputHint, Label, Loader, Modal, ModalWindow, MultiSelect, Pagination, Popover, PopoverTooltip, Progress, RadioGroup, Select, SelectItem, SelectItemText, SliderDemo as Slider, Switch, Tab, TabsContent, TabsList, TabsRoot, Tag, Toast, Tooltip, Typography, Upload, UploadError, UploadMenu, UploadProgressPreview, createImage, getCroppedImageURL, getFileExtension, getFileMimeType, getRadianAngle, index as icons, isExtensionMatchingMimeType, isImage, isValidFileDimension, isValidFileSize, isValidFileType, isVideo, mimeTypeMap, rotateSize, toast, useCroppedImage, useFileValidation };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "demio-ui",
|
|
3
|
-
"version": "2.5.
|
|
3
|
+
"version": "2.5.58",
|
|
4
4
|
"description": "",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -62,9 +62,9 @@
|
|
|
62
62
|
"@radix-ui/react-switch": "^1.0.3",
|
|
63
63
|
"@radix-ui/react-tabs": "^1.0.4",
|
|
64
64
|
"@radix-ui/react-tooltip": "^1.0.7",
|
|
65
|
-
"@storybook/preset-react-webpack": "^8.
|
|
66
|
-
"@storybook/react": "^8.
|
|
67
|
-
"@storybook/react-webpack5": "^8.
|
|
65
|
+
"@storybook/preset-react-webpack": "^8.6.10",
|
|
66
|
+
"@storybook/react": "^8.6.10",
|
|
67
|
+
"@storybook/react-webpack5": "^8.6.10",
|
|
68
68
|
"classnames": "^2.5.1",
|
|
69
69
|
"react-easy-crop": "^5.0.8",
|
|
70
70
|
"react-select": "^5.8.0"
|
|
@@ -79,18 +79,18 @@
|
|
|
79
79
|
"@rollup/plugin-node-resolve": "^15.2.3",
|
|
80
80
|
"@rollup/plugin-terser": "^0.4.4",
|
|
81
81
|
"@rollup/plugin-typescript": "^11.1.5",
|
|
82
|
-
"@storybook/addon-a11y": "^8.
|
|
83
|
-
"@storybook/addon-actions": "^8.
|
|
84
|
-
"@storybook/addon-essentials": "^8.
|
|
85
|
-
"@storybook/addon-interactions": "^8.
|
|
86
|
-
"@storybook/addon-links": "^8.
|
|
87
|
-
"@storybook/addon-mdx-gfm": "^8.
|
|
82
|
+
"@storybook/addon-a11y": "^8.6.10",
|
|
83
|
+
"@storybook/addon-actions": "^8.6.10",
|
|
84
|
+
"@storybook/addon-essentials": "^8.6.10",
|
|
85
|
+
"@storybook/addon-interactions": "^8.6.10",
|
|
86
|
+
"@storybook/addon-links": "^8.6.10",
|
|
87
|
+
"@storybook/addon-mdx-gfm": "^8.6.10",
|
|
88
88
|
"@storybook/addon-styling-webpack": "^1.0.1",
|
|
89
89
|
"@storybook/addon-webpack5-compiler-babel": "^3.0.3",
|
|
90
|
-
"@storybook/cli": "^8.
|
|
91
|
-
"@storybook/manager-api": "^8.
|
|
92
|
-
"@storybook/test": "^8.
|
|
93
|
-
"@storybook/theming": "^8.
|
|
90
|
+
"@storybook/cli": "^8.6.10",
|
|
91
|
+
"@storybook/manager-api": "^8.6.10",
|
|
92
|
+
"@storybook/test": "^8.6.10",
|
|
93
|
+
"@storybook/theming": "^8.6.10",
|
|
94
94
|
"@svgr/rollup": "^8.1.0",
|
|
95
95
|
"@svgr/webpack": "^8.1.0",
|
|
96
96
|
"@testing-library/jest-dom": "^6.1.6",
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
"eslint": "^8.56.0",
|
|
107
107
|
"eslint-plugin-prettier": "^5.1.2",
|
|
108
108
|
"eslint-plugin-simple-import-sort": "^12.0.0",
|
|
109
|
-
"eslint-plugin-storybook": "^0.
|
|
109
|
+
"eslint-plugin-storybook": "^0.12.0",
|
|
110
110
|
"file-loader": "^6.2.0",
|
|
111
111
|
"husky": "^8.0.3",
|
|
112
112
|
"identity-obj-proxy": "^3.0.0",
|
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
"rollup-plugin-dts": "^6.1.0",
|
|
125
125
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
126
126
|
"rollup-plugin-postcss": "^4.0.2",
|
|
127
|
-
"storybook": "^8.
|
|
127
|
+
"storybook": "^8.6.10",
|
|
128
128
|
"storybook-css-modules": "^1.0.8",
|
|
129
129
|
"stylelint": "^16.1.0",
|
|
130
130
|
"stylelint-config-standard": "^36.0.0",
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Area } from 'react-easy-crop';
|
|
2
|
-
export declare const createImage: (url: string) => Promise<HTMLImageElement>;
|
|
3
|
-
export declare const getRadianAngle: (degreeValue?: number) => number;
|
|
4
|
-
export declare const rotateSize: (width: number, height: number, rotation: number) => {
|
|
5
|
-
width: number;
|
|
6
|
-
height: number;
|
|
7
|
-
};
|
|
8
|
-
export declare const getCroppedImageURL: (imageSrc: string, pixelCrop: Area, rotation?: number, flip?: {
|
|
9
|
-
horizontal: boolean;
|
|
10
|
-
vertical: boolean;
|
|
11
|
-
}) => Promise<string | null>;
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
export declare const isValidFileType: (file?: File | null, acceptableTypePattern?: string) => boolean;
|
|
2
|
-
export declare const isValidFileSize: (file?: File | null, fileSizeMbLimit?: number) => boolean;
|
|
3
|
-
export declare const isValidFileDimension: (file?: File | null, minWidth?: number, minHeight?: number) => Promise<boolean>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Area } from 'react-easy-crop';
|
|
2
|
-
export declare const createImage: (url: string) => Promise<HTMLImageElement>;
|
|
3
|
-
export declare const getRadianAngle: (degreeValue?: number) => number;
|
|
4
|
-
export declare const rotateSize: (width: number, height: number, rotation: number) => {
|
|
5
|
-
width: number;
|
|
6
|
-
height: number;
|
|
7
|
-
};
|
|
8
|
-
export declare const getCroppedImageURL: (imageSrc: string, pixelCrop: Area, rotation?: number, flip?: {
|
|
9
|
-
horizontal: boolean;
|
|
10
|
-
vertical: boolean;
|
|
11
|
-
}) => Promise<string | null>;
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
export declare const isValidFileType: (file?: File | null, acceptableTypePattern?: string) => boolean;
|
|
2
|
-
export declare const isValidFileSize: (file?: File | null, fileSizeMbLimit?: number) => boolean;
|
|
3
|
-
export declare const isValidFileDimension: (file?: File | null, minWidth?: number, minHeight?: number) => Promise<boolean>;
|