master-components-react-ts 2.9.1 → 2.9.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.
- package/dist/assets/Icons/IconDownload.d.ts +1 -0
- package/dist/assets/Icons/IconFileTypes.d.ts +10 -0
- package/dist/assets/Icons/IconFileuploader.d.ts +6 -0
- package/dist/assets/Icons/IconReload.d.ts +1 -0
- package/dist/assets/Icons/IconRemove.d.ts +1 -0
- package/dist/assets/Icons/index.d.ts +14 -0
- package/dist/components/FileUploader/FileUploader.d.ts +4 -1
- package/dist/components/FileUploader/FileUploader.types.d.ts +25 -0
- package/dist/components/FileUploader/FilesBlock.d.ts +8 -0
- package/dist/components/FileUploader/FilesBlock.types.d.ts +12 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +3153 -2847
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const IconDownload: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const IconPDF: () => import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare const IconImage: () => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export declare const IconAudio: () => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export declare const IconText: () => import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export declare const IconWord: () => import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export declare const IconExcel: () => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const IconPPT: () => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const IconZip: () => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare const IconFile: () => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare const IconVideo: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const IconReload: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const IconRemove: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -24,3 +24,17 @@ export { IconCloseBackground } from './IconCloseBackground';
|
|
|
24
24
|
export { IconColumnConfig } from './IconColumnConfig';
|
|
25
25
|
export { IconFilterLines } from './IconFilterLines';
|
|
26
26
|
export { IconDragandDrop } from './IconDragandDrop';
|
|
27
|
+
export { IconFileuploader } from './IconFileuploader';
|
|
28
|
+
export { IconPDF } from './IconFileTypes';
|
|
29
|
+
export { IconAudio } from './IconFileTypes';
|
|
30
|
+
export { IconText } from './IconFileTypes';
|
|
31
|
+
export { IconWord } from './IconFileTypes';
|
|
32
|
+
export { IconExcel } from './IconFileTypes';
|
|
33
|
+
export { IconPPT } from './IconFileTypes';
|
|
34
|
+
export { IconZip } from './IconFileTypes';
|
|
35
|
+
export { IconImage } from './IconFileTypes';
|
|
36
|
+
export { IconFile } from './IconFileTypes';
|
|
37
|
+
export { IconVideo } from './IconFileTypes';
|
|
38
|
+
export { IconDownload } from './IconDownload';
|
|
39
|
+
export { IconReload } from './IconReload';
|
|
40
|
+
export { IconRemove } from './IconRemove';
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
import { FileUploaderProps } from './FileUploader.types';
|
|
1
2
|
declare const FileUploader: {
|
|
2
|
-
(): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
({ title, description, files, errorState, withFilesBlock, onChange, onLoadingChange, ...rest }: FileUploaderProps): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
propKeys: readonly ["title", "description", "files", "errorState", "withFilesBlock", "onChange", "onLoadingChange", "onRemove", "onDownload", "onReload", "withDate", "withSize", "withDownload", "withReload", "withRemove", "multiple", "accept"];
|
|
3
5
|
displayName: string;
|
|
6
|
+
description: string;
|
|
4
7
|
};
|
|
5
8
|
export default FileUploader;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Dayjs } from 'dayjs';
|
|
2
|
+
import { FilesBlockProps } from './FilesBlock.types';
|
|
3
|
+
type DateType = Dayjs | Date | string | null;
|
|
4
|
+
export type FileType = {
|
|
5
|
+
fileName: string;
|
|
6
|
+
lastModified?: DateType;
|
|
7
|
+
uploadedAt?: DateType;
|
|
8
|
+
size?: number;
|
|
9
|
+
unitSize?: string;
|
|
10
|
+
type?: string;
|
|
11
|
+
format?: string;
|
|
12
|
+
base64?: string;
|
|
13
|
+
fileID?: string;
|
|
14
|
+
};
|
|
15
|
+
/**FileUploader Component Props */
|
|
16
|
+
export interface FileUploaderProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'title' | 'description' | 'onChange'>, Omit<FilesBlockProps, 'files'> {
|
|
17
|
+
title?: string | React.ReactNode;
|
|
18
|
+
description?: string | React.ReactNode;
|
|
19
|
+
files?: FileType[];
|
|
20
|
+
errorState?: boolean;
|
|
21
|
+
withFilesBlock?: boolean;
|
|
22
|
+
onChange?: (files: FileType[]) => void;
|
|
23
|
+
onLoadingChange?: (isLoading: boolean) => void;
|
|
24
|
+
}
|
|
25
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FilesBlockProps } from './FilesBlock.types';
|
|
2
|
+
declare const FilesBlock: {
|
|
3
|
+
({ files, withDate, withSize, withDownload, withReload, withRemove, onDownload, onReload, onRemove, }: FilesBlockProps): import("react/jsx-runtime").JSX.Element | null;
|
|
4
|
+
propKeys: readonly ["files", "withDate", "withSize", "withDownload", "withReload", "withRemove", "onDownload", "onReload", "onRemove"];
|
|
5
|
+
displayName: string;
|
|
6
|
+
description: string;
|
|
7
|
+
};
|
|
8
|
+
export default FilesBlock;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FileType } from './FileUploader.types';
|
|
2
|
+
export interface FilesBlockProps {
|
|
3
|
+
files: FileType[];
|
|
4
|
+
withDate?: boolean;
|
|
5
|
+
withSize?: boolean;
|
|
6
|
+
withDownload?: boolean;
|
|
7
|
+
withReload?: boolean;
|
|
8
|
+
withRemove?: boolean;
|
|
9
|
+
onDownload?: (file: FileType) => void;
|
|
10
|
+
onReload?: (file: FileType) => void;
|
|
11
|
+
onRemove?: (file: FileType) => void;
|
|
12
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -26,5 +26,7 @@ export type { FilterOptionsTypes } from './components/FilterWithTags/FilterWithT
|
|
|
26
26
|
export { default as Table } from './components/Table/Table';
|
|
27
27
|
export type { ColumnType, SortType, RowActionType, ActionButtonType } from './components/Table/Table.types';
|
|
28
28
|
export { default as FileUploader } from './components/FileUploader/FileUploader';
|
|
29
|
+
export { default as FilesBlock } from './components/FileUploader/FilesBlock';
|
|
30
|
+
export type { FileType, FileUploaderProps } from './components/FileUploader/FileUploader.types';
|
|
29
31
|
export { default as DropdownPill } from './components/DropdownPill/DropdownPill';
|
|
30
32
|
export { default as ColourPicker } from './components/ColourPicker/ColourPicker';
|