indicator-ui 0.0.119 → 0.0.121
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/index.js +97 -4
- package/dist/index.js.map +1 -1
- package/dist/types/src/lib/dict/clearDeepValue.d.ts +4 -0
- package/dist/types/src/lib/dict/compKeyWays.d.ts +7 -0
- package/dist/types/src/lib/dict/index.d.ts +1 -0
- package/dist/types/src/test/ui/InputFileField/api/getFileUrl.d.ts +1 -0
- package/dist/types/src/test/ui/InputFileField/api/index.d.ts +1 -0
- package/dist/types/src/test/ui/InputFileField/index.d.ts +3 -0
- package/dist/types/src/test/ui/InputFileField/types/FileViewItemTypes.d.ts +18 -0
- package/dist/types/src/test/ui/InputFileField/types/InputFileFieldTypes.d.ts +8 -0
- package/dist/types/src/test/ui/InputFileField/types/InputFileTypes.d.ts +19 -0
- package/dist/types/src/test/ui/InputFileField/types/index.d.ts +3 -0
- package/dist/types/src/test/ui/InputFileField/ui/FileViewItem.d.ts +2 -0
- package/dist/types/src/test/ui/InputFileField/ui/InputFile.d.ts +4 -0
- package/dist/types/src/test/ui/InputFileField/ui/InputFileField.d.ts +7 -0
- package/dist/types/src/test/ui/index.d.ts +1 -0
- package/dist/types/src/ui/FormBuilder/types/FormBuilderTypes.d.ts +8 -0
- package/dist/types/src/ui/FormBuilder/ui/FormBuilder.d.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { DictDeepActionKeyWayType } from "../../types/DictDeepActionsTypes";
|
|
2
|
+
/**
|
|
3
|
+
* 2 - полностью совпадают
|
|
4
|
+
* 1 - совпадает начало
|
|
5
|
+
* 0 - не совпадают
|
|
6
|
+
* */
|
|
7
|
+
export declare function compKeyWays(a: DictDeepActionKeyWayType, b: DictDeepActionKeyWayType): 0 | 1 | 2;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function getFileUrl(path?: string): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as getFileUrl } from './getFileUrl';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { FileMetaType } from "./InputFileTypes";
|
|
2
|
+
import React from "react";
|
|
3
|
+
export type FileViewItemClassNameType = {
|
|
4
|
+
fileViewItem?: string;
|
|
5
|
+
main?: string;
|
|
6
|
+
meta?: string;
|
|
7
|
+
name?: string;
|
|
8
|
+
size?: string;
|
|
9
|
+
fileIcon?: string;
|
|
10
|
+
deleteIcon?: string;
|
|
11
|
+
disabled?: string;
|
|
12
|
+
};
|
|
13
|
+
export type FileViewItemPropsType = {
|
|
14
|
+
fileData: FileMetaType;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
onDeleteClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
|
17
|
+
className?: FileViewItemClassNameType;
|
|
18
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactElement, ReactNode } from "react";
|
|
2
|
+
import { InputFilePropsType } from "./InputFileTypes";
|
|
3
|
+
import { InputFieldWrapperPropsType } from "../../../../ui";
|
|
4
|
+
export type InputFileFieldPropsType = InputFieldWrapperPropsType & InputFilePropsType & {
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
ownerInputWrapper?: ReactNode;
|
|
7
|
+
ownerFileView?: ReactElement<any>;
|
|
8
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
export type FileMetaType = {
|
|
3
|
+
original_name?: string;
|
|
4
|
+
path?: string;
|
|
5
|
+
size?: number;
|
|
6
|
+
};
|
|
7
|
+
export type InputFileClassNameType = string;
|
|
8
|
+
export type FileValueType = FileMetaType[];
|
|
9
|
+
export type InputFilePropsType = {
|
|
10
|
+
value?: FileValueType;
|
|
11
|
+
name?: string;
|
|
12
|
+
multiple?: boolean;
|
|
13
|
+
accept?: string;
|
|
14
|
+
onChange?: (files: FileValueType) => void;
|
|
15
|
+
ownerButton?: React.ReactElement<{
|
|
16
|
+
onClick?: React.MouseEventHandler;
|
|
17
|
+
}>;
|
|
18
|
+
className?: InputFileClassNameType;
|
|
19
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
declare const InputFileField: React.ForwardRefExoticComponent<import("../../../../ui").InputFieldWrapperPropsType & import("../types").InputFilePropsType & {
|
|
3
|
+
disabled?: boolean;
|
|
4
|
+
ownerInputWrapper?: React.ReactNode;
|
|
5
|
+
ownerFileView?: React.ReactElement<any>;
|
|
6
|
+
} & React.RefAttributes<HTMLInputElement>>;
|
|
7
|
+
export default InputFileField;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './InputFileField';
|
|
@@ -12,6 +12,14 @@ export type FormBuilderPropsType<T> = {
|
|
|
12
12
|
additionIsErrorFields?: UseIsErrorFieldIsErrorType;
|
|
13
13
|
formDataDefaultListener?: T;
|
|
14
14
|
sensitiveErrorSearch?: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Отчищает форму от полей, не входящих в форму.
|
|
17
|
+
*
|
|
18
|
+
* То есть, если в схеме нет поля с `name === 'test'`, то в форме он его откинет.
|
|
19
|
+
*
|
|
20
|
+
* По умолчанию: `false`.
|
|
21
|
+
* */
|
|
22
|
+
clearForm?: boolean;
|
|
15
23
|
inputFieldAdditionProps?: InputFieldAdditionPropsType;
|
|
16
24
|
};
|
|
17
25
|
export type GetStoreValueType = (key: string) => any;
|
|
@@ -2,4 +2,4 @@ import React from "react";
|
|
|
2
2
|
import { FormBuilderPropsType } from "../types";
|
|
3
3
|
export declare function FormBuilder<T extends {
|
|
4
4
|
[key: string]: any;
|
|
5
|
-
}>({ schema, formDataDefault, onChange, onChangeIsError, inputFieldClassName, additionIsErrorFields, onChangeValidateIsError, formDataDefaultListener, inputFieldAdditionProps, sensitiveErrorSearch, }: FormBuilderPropsType<T>): React.JSX.Element;
|
|
5
|
+
}>({ schema, formDataDefault, onChange, onChangeIsError, inputFieldClassName, additionIsErrorFields, onChangeValidateIsError, formDataDefaultListener, inputFieldAdditionProps, sensitiveErrorSearch, clearForm, }: FormBuilderPropsType<T>): React.JSX.Element;
|