indicator-ui 0.0.149 → 0.0.151
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 +267 -54
- package/dist/index.js.map +1 -1
- package/dist/types/src/__tests__/getDeepValue.test.d.ts +1 -0
- package/dist/types/src/__tests__/setDeepValue.test.d.ts +1 -0
- package/dist/types/src/lib/dict/clearDeepValue.d.ts +1 -1
- package/dist/types/src/lib/dict/index.d.ts +1 -0
- package/dist/types/src/lib/dict/setDeepValue.d.ts +1 -1
- package/dist/types/src/types/DictDeepActionsTypes.d.ts +3 -0
- package/dist/types/src/ui/FormBuilder/lib/formBuilder.d.ts +1 -1
- package/dist/types/src/ui/FormBuilder/types/FormBuilderTypes.d.ts +4 -0
- package/dist/types/src/ui/InputFields/RadioField/types/RadioFieldItemTypes.d.ts +1 -6
- package/dist/types/src/ui/InputFields/RadioField/ui/RadioField.d.ts +1 -1
- package/dist/types/src/ui/InputFields/RadioField/ui/RadioFieldItem.d.ts +3 -0
- package/dist/types/src/ui/ScrollProvider/index.d.ts +2 -0
- package/dist/types/src/ui/ScrollProvider/types/ScrollProviderTypes.d.ts +34 -0
- package/dist/types/src/ui/ScrollProvider/types/index.d.ts +1 -0
- package/dist/types/src/ui/ScrollProvider/ui/ScrollProvider.d.ts +2 -0
- package/dist/types/src/ui/ScrollProvider/ui/index.d.ts +1 -0
- package/dist/types/src/ui/index.d.ts +1 -0
- package/package.json +73 -68
- package/dist/types/src/test/ui/InputFileField/api/getFileUrl.d.ts +0 -1
- package/dist/types/src/test/ui/InputFileField/api/index.d.ts +0 -1
- package/dist/types/src/test/ui/InputFileField/index.d.ts +0 -3
- package/dist/types/src/test/ui/InputFileField/types/FileViewItemTypes.d.ts +0 -18
- package/dist/types/src/test/ui/InputFileField/types/InputFileFieldTypes.d.ts +0 -8
- package/dist/types/src/test/ui/InputFileField/types/InputFileTypes.d.ts +0 -19
- package/dist/types/src/test/ui/InputFileField/types/index.d.ts +0 -3
- package/dist/types/src/test/ui/InputFileField/ui/FileViewItem.d.ts +0 -2
- package/dist/types/src/test/ui/InputFileField/ui/InputFile.d.ts +0 -4
- package/dist/types/src/test/ui/InputFileField/ui/InputFileField.d.ts +0 -7
- package/dist/types/src/test/ui/index.d.ts +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { FORM_BUILDER_SCHEMA } from "../schemes";
|
|
2
2
|
import { AdditionPropsType } from "../types";
|
|
3
|
-
declare const formBuilder: (schema: FORM_BUILDER_SCHEMA, additionProps: AdditionPropsType) =>
|
|
3
|
+
declare const formBuilder: (schema: FORM_BUILDER_SCHEMA, additionProps: AdditionPropsType) => import("react").ReactNode[];
|
|
4
4
|
export default formBuilder;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { DictDeepActionKeyWayType } from "../../../../../types";
|
|
2
2
|
import { UseFormDataDeleteArrayItemType, UseFormDataGetValueType, UseFormDataSetValueType, UseIsErrorFieldAddErrorFieldType, UseIsErrorFieldGetErrorMessageType, UseIsErrorFieldIsErrorFieldType, UseIsErrorFieldIsErrorType, UseIsErrorFieldRemoveErrorFieldType } from "../../../hooks";
|
|
3
3
|
import { FORM_BUILDER_SCHEMA } from "../schemes";
|
|
4
|
+
import { ReactNode } from "react";
|
|
4
5
|
export type InputFieldClassNameType = Record<string, string>;
|
|
5
6
|
export type FormBuilderPropsType<T> = {
|
|
6
7
|
schema: FORM_BUILDER_SCHEMA;
|
|
@@ -62,3 +63,6 @@ export type AdditionPropsType = {
|
|
|
62
63
|
addPrivateRefStoreValue: AddStoreValueType;
|
|
63
64
|
removePrivateRefStoreValue: RemoveStoreValueType;
|
|
64
65
|
};
|
|
66
|
+
export type FormWrapperBasePropsType = CustomCompAdditionPropsType & {
|
|
67
|
+
children?: ReactNode;
|
|
68
|
+
};
|
|
@@ -1,10 +1,4 @@
|
|
|
1
1
|
import { RadioFieldOptionsItemType } from './RadioFieldTypes';
|
|
2
|
-
export type RadioFieldItemClassNameType = {
|
|
3
|
-
radioFieldItem?: string;
|
|
4
|
-
checkbox?: string;
|
|
5
|
-
label?: string;
|
|
6
|
-
active?: string;
|
|
7
|
-
};
|
|
8
2
|
export type RadioFieldOwnerItemPropsType = {
|
|
9
3
|
onClick?: () => void;
|
|
10
4
|
active?: boolean;
|
|
@@ -15,4 +9,5 @@ export type RadioFieldItemPropsType = {
|
|
|
15
9
|
onClick?: () => void;
|
|
16
10
|
active?: boolean;
|
|
17
11
|
disabled?: boolean;
|
|
12
|
+
width?: 'hug' | 'fill';
|
|
18
13
|
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { RadioFieldPropsType } from "../types";
|
|
3
|
-
export default function RadioField({ value, onChange, options, required, multiple, disabled, width,
|
|
3
|
+
export default function RadioField({ value, onChange, options, required, multiple, disabled, width, }: RadioFieldPropsType): React.JSX.Element;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Триггер события скролла, может быть,
|
|
4
|
+
* либо значением отступа скролла от верха компонента
|
|
5
|
+
* _(будет вызываться, когда скролл будет равен значению отступа)_,
|
|
6
|
+
* либо функцией, которая возвращает `true`,
|
|
7
|
+
* когда надо отреагировать.
|
|
8
|
+
*
|
|
9
|
+
* _(В функцию передается значение текущего отступа)_
|
|
10
|
+
* */
|
|
11
|
+
export type ScrollProviderOnScrollListenerTriggerType = number | ((curStep: number) => boolean);
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* */
|
|
15
|
+
export type ScrollProviderOnScrollCallbackType = (curStep: number) => void;
|
|
16
|
+
export type ScrollProviderOnScrollType = ScrollProviderOnScrollCallbackType | {
|
|
17
|
+
callback: ScrollProviderOnScrollCallbackType;
|
|
18
|
+
trigger: ScrollProviderOnScrollListenerTriggerType;
|
|
19
|
+
};
|
|
20
|
+
export type ScrollProviderPropsType = {
|
|
21
|
+
onScrollBottom?: () => void;
|
|
22
|
+
/**
|
|
23
|
+
* Не вызовется при инициализации.
|
|
24
|
+
* */
|
|
25
|
+
onScrollTop?: () => void;
|
|
26
|
+
onScroll?: ScrollProviderOnScrollType;
|
|
27
|
+
children?: React.ReactNode;
|
|
28
|
+
/**
|
|
29
|
+
* Точность вычислений верха и низа скролла.
|
|
30
|
+
*
|
|
31
|
+
* По умолчанию: *10* _(10px)_.
|
|
32
|
+
* */
|
|
33
|
+
accuracy?: number;
|
|
34
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './ScrollProviderTypes';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './ScrollProvider';
|
package/package.json
CHANGED
|
@@ -1,68 +1,73 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "indicator-ui",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"main": "dist/index.js",
|
|
5
|
-
"types": "dist/types/src/index.d.ts",
|
|
6
|
-
"style": "dist/index.css",
|
|
7
|
-
"sass": "dist/scss/index.scss",
|
|
8
|
-
"sideEffects": true,
|
|
9
|
-
"scripts": {
|
|
10
|
-
"dev:dev": "webpack serve --mode=development",
|
|
11
|
-
"dev:build": "webpack --mode=production && tsc --project tsconfig.json --outDir webpack",
|
|
12
|
-
"lib:build": "webpack --config webpack.lib.config.js && tsc-alias"
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
"
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
"@babel/
|
|
22
|
-
"@
|
|
23
|
-
"@
|
|
24
|
-
"@
|
|
25
|
-
"@
|
|
26
|
-
"@types/
|
|
27
|
-
"
|
|
28
|
-
"
|
|
29
|
-
"
|
|
30
|
-
"
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
45
|
-
"
|
|
46
|
-
"
|
|
47
|
-
"
|
|
48
|
-
"
|
|
49
|
-
"
|
|
50
|
-
"
|
|
51
|
-
"
|
|
52
|
-
"
|
|
53
|
-
"webpack-
|
|
54
|
-
"
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
"
|
|
58
|
-
"
|
|
59
|
-
"
|
|
60
|
-
},
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
"
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "indicator-ui",
|
|
3
|
+
"version": "0.0.151",
|
|
4
|
+
"main": "dist/index.js",
|
|
5
|
+
"types": "dist/types/src/index.d.ts",
|
|
6
|
+
"style": "dist/index.css",
|
|
7
|
+
"sass": "dist/scss/index.scss",
|
|
8
|
+
"sideEffects": true,
|
|
9
|
+
"scripts": {
|
|
10
|
+
"dev:dev": "webpack serve --mode=development",
|
|
11
|
+
"dev:build": "webpack --mode=production && tsc --project tsconfig.json --outDir webpack",
|
|
12
|
+
"lib:build": "webpack --config webpack.lib.config.js && tsc-alias",
|
|
13
|
+
"lib:test": "jest",
|
|
14
|
+
"build": "npm run lib:test && npm run lib:build",
|
|
15
|
+
"lib:publish": "npm run build && node updateVersion.js && npm publish"
|
|
16
|
+
},
|
|
17
|
+
"author": "indicator",
|
|
18
|
+
"license": "ISC",
|
|
19
|
+
"description": "",
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"@babel/core": "^7.26.7",
|
|
22
|
+
"@babel/preset-env": "^7.26.7",
|
|
23
|
+
"@babel/preset-react": "^7.26.3",
|
|
24
|
+
"@babel/preset-typescript": "^7.26.0",
|
|
25
|
+
"@svgr/webpack": "^8.1.0",
|
|
26
|
+
"@types/jest": "^29.5.14",
|
|
27
|
+
"@types/node": "^22.13.13",
|
|
28
|
+
"@types/react": "^19.0.8",
|
|
29
|
+
"@types/react-dom": "^19.0.3",
|
|
30
|
+
"babel-loader": "^9.2.1",
|
|
31
|
+
"clsx": "^2.1.1",
|
|
32
|
+
"copy-webpack-plugin": "^12.0.2",
|
|
33
|
+
"css-loader": "^6.8.1",
|
|
34
|
+
"css-modules-typescript-loader": "^4.0.1",
|
|
35
|
+
"date-fns": "^4.1.0",
|
|
36
|
+
"file-loader": "^6.2.0",
|
|
37
|
+
"html-loader": "^5.1.0",
|
|
38
|
+
"html-webpack-plugin": "^5.6.3",
|
|
39
|
+
"jest": "^29.7.0",
|
|
40
|
+
"mini-css-extract-plugin": "^2.9.2",
|
|
41
|
+
"postcss": "^8.5.1",
|
|
42
|
+
"postcss-import": "^16.1.0",
|
|
43
|
+
"postcss-loader": "^8.1.1",
|
|
44
|
+
"process": "^0.11.10",
|
|
45
|
+
"react-router-dom": "^7.1.5",
|
|
46
|
+
"resolve-url-loader": "^5.0.0",
|
|
47
|
+
"sass": "^1.66.1",
|
|
48
|
+
"sass-loader": "^16.0.4",
|
|
49
|
+
"style-loader": "^4.0.0",
|
|
50
|
+
"ts-jest": "^29.3.0",
|
|
51
|
+
"ts-loader": "^9.5.2",
|
|
52
|
+
"tsc-alias": "^1.8.10",
|
|
53
|
+
"tsconfig-paths-webpack-plugin": "^4.2.0",
|
|
54
|
+
"tslib": "^2.8.1",
|
|
55
|
+
"typed-css-modules-webpack-plugin": "^0.2.0",
|
|
56
|
+
"typescript": "^5.7.3",
|
|
57
|
+
"webpack": "^5.97.1",
|
|
58
|
+
"webpack-cli": "^6.0.1",
|
|
59
|
+
"webpack-dev-server": "^5.2.0"
|
|
60
|
+
},
|
|
61
|
+
"peerDependencies": {
|
|
62
|
+
"react": "^18.3.1",
|
|
63
|
+
"react-dom": "^18.3.1",
|
|
64
|
+
"react-imask": "^7.6.1"
|
|
65
|
+
},
|
|
66
|
+
"files": [
|
|
67
|
+
"dist",
|
|
68
|
+
"docs"
|
|
69
|
+
],
|
|
70
|
+
"dependencies": {
|
|
71
|
+
"date-fns-tz": "^3.2.0"
|
|
72
|
+
}
|
|
73
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export default function getFileUrl(path?: string): string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as getFileUrl } from './getFileUrl';
|
|
@@ -1,18 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,19 +0,0 @@
|
|
|
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
|
-
};
|
|
@@ -1,7 +0,0 @@
|
|
|
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;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './InputFileField';
|