master-components-react-ts 2.9.4 → 2.9.6
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/components/FileUploader/FileUploader.d.ts +1 -1
- package/dist/components/FileUploader/FileUploader.types.d.ts +14 -1
- package/dist/components/NotificationToast/NotificationContext.d.ts +11 -0
- package/dist/components/Textarea/Textarea.d.ts +1 -1
- package/dist/components/Textarea/Textarea.types.d.ts +1 -1
- package/dist/index.js +2719 -2658
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FileUploaderProps } from './FileUploader.types';
|
|
2
2
|
declare const FileUploader: {
|
|
3
|
-
({ title, description, files, errorState, withFilesBlock, onChange, onLoadingChange, ...rest }: FileUploaderProps): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
({ title, description, files, errorState, withFilesBlock, maxSize, acceptedFileFormats, multiple, onFormatError, onMaxSizeError, onMaxFilesError, onChange, onLoadingChange, ...rest }: FileUploaderProps): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
propKeys: readonly ["title", "description", "files", "errorState", "withFilesBlock", "onChange", "onLoadingChange", "onRemove", "onDownload", "onReload", "withDate", "withSize", "withDownload", "withReload", "withRemove", "multiple", "accept"];
|
|
5
5
|
displayName: string;
|
|
6
6
|
description: string;
|
|
@@ -13,12 +13,25 @@ export type FileType = {
|
|
|
13
13
|
fileID?: string;
|
|
14
14
|
};
|
|
15
15
|
/**FileUploader Component Props */
|
|
16
|
-
export interface FileUploaderProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'title' | 'description' | 'onChange'>, Omit<FilesBlockProps, 'files'> {
|
|
16
|
+
export interface FileUploaderProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'title' | 'multiple' | 'description' | 'onChange'>, Omit<FilesBlockProps, 'files'> {
|
|
17
17
|
title?: string | React.ReactNode;
|
|
18
18
|
description?: string | React.ReactNode;
|
|
19
19
|
files?: FileType[];
|
|
20
20
|
errorState?: boolean;
|
|
21
21
|
withFilesBlock?: boolean;
|
|
22
|
+
maxSize?: number;
|
|
23
|
+
multiple?: boolean;
|
|
24
|
+
maxFiles?: number;
|
|
25
|
+
acceptedFileFormats?: string[];
|
|
26
|
+
onMaxFilesError?: (error: {
|
|
27
|
+
Error: string;
|
|
28
|
+
MaxFiles: number;
|
|
29
|
+
}) => void;
|
|
30
|
+
onFormatError?: (format: string) => void;
|
|
31
|
+
onMaxSizeError?: (error: {
|
|
32
|
+
Error: string;
|
|
33
|
+
MaxSize: number;
|
|
34
|
+
}) => void;
|
|
22
35
|
onChange?: (files: FileType[]) => void;
|
|
23
36
|
onLoadingChange?: (isLoading: boolean) => void;
|
|
24
37
|
}
|
|
@@ -1,12 +1,23 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { NotificationToastProps } from './NotificationToast.types';
|
|
3
|
+
type Toast = {
|
|
4
|
+
id: number;
|
|
5
|
+
props: NotificationToastProps;
|
|
6
|
+
};
|
|
3
7
|
export declare const ToastContext: import('react').Context<{
|
|
4
8
|
showToast: (props: NotificationToastProps) => void;
|
|
5
9
|
} | null>;
|
|
10
|
+
declare const toastManager: {
|
|
11
|
+
showToast: (props: NotificationToastProps) => void;
|
|
12
|
+
getToasts: () => Toast[];
|
|
13
|
+
removeToast: (id: number) => void;
|
|
14
|
+
subscribe: (listener: () => void) => () => void;
|
|
15
|
+
};
|
|
6
16
|
declare const ToastProvider: {
|
|
7
17
|
({ children }: {
|
|
8
18
|
children: ReactNode;
|
|
9
19
|
}): import("react/jsx-runtime").JSX.Element;
|
|
10
20
|
propKeys: readonly ["children"];
|
|
11
21
|
};
|
|
22
|
+
export { toastManager };
|
|
12
23
|
export default ToastProvider;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { TextareaProps } from './Textarea.types';
|
|
2
2
|
declare const Textarea: {
|
|
3
|
-
({ placeholder, label, cols, rows, value, inputState, maxLength, withMaxLength, withFocus, withActive, withResize, withClose, onChange, onFocus, onBlur, disabled, required, textareaContainerStyle, textareaLabelStyle, requiredStyle, labelSlot, textareaFooterStyle, }: TextareaProps): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
({ placeholder, label, cols, rows, value, inputState, maxLength, withMaxLength, withFocus, withActive, withResize, withClose, onChange, onFocus, onBlur, disabled, required, textareaContainerStyle, textareaLabelStyle, requiredStyle, labelSlot, textareaFooterStyle, ...rest }: TextareaProps): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
propKeys: readonly ["placeholder", "label", "cols", "rows", "value", "inputState", "maxLength", "withMaxLength", "withFocus", "withActive", "withResize", "withClose", "onChange", "onFocus", "onBlur", "disabled", "required", "textareaContainerStyle", "textareaLabelStyle", "requiredStyle", "labelSlot", "textareaFooterStyle"];
|
|
5
5
|
displayName: string;
|
|
6
6
|
description: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CSSProperties } from 'react';
|
|
2
2
|
/**Textarea Component Props */
|
|
3
|
-
export interface TextareaProps {
|
|
3
|
+
export interface TextareaProps extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {
|
|
4
4
|
placeholder?: string;
|
|
5
5
|
label?: string | React.ReactNode;
|
|
6
6
|
inputState?: {
|