treege 1.1.0 → 1.3.0
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/CHANGELOG.md +2 -2
- package/README.md +4 -25
- package/dist/{src/components → components}/DataDisplay/Tree/Tree.d.ts +4 -2
- package/dist/{src/components → components}/DataDisplay/TreeCard/TreeCard.d.ts +2 -3
- package/dist/{src/components → components}/FeedBack/MainModal/MainModal.d.ts +0 -1
- package/dist/{src/components → components}/FeedBack/TreeModal/TreeModal.d.ts +2 -3
- package/dist/{src/components → components}/Layouts/Action/Action.d.ts +0 -1
- package/dist/{src/components → components}/Layouts/Header/Header.d.ts +0 -1
- package/dist/{src/components → components}/Layouts/Main/Main.d.ts +0 -1
- package/dist/{src/components → components}/Layouts/MosaicLayout/MosaicLayout.d.ts +0 -1
- package/dist/{src/components → components}/Layouts/Sidebar/Sidebar.d.ts +0 -1
- package/dist/{src/components → components}/Theme/DarkTheme/DarkTheme.d.ts +0 -1
- package/dist/{src/config → config}/i18n.config.d.ts +0 -1
- package/dist/{src/config → config}/query.config.d.ts +0 -1
- package/dist/config/test.config.d.ts +0 -0
- package/dist/{src/config → config}/theme.config.d.ts +0 -1
- package/dist/{src/constants → constants}/fields.d.ts +6 -0
- package/dist/{src/context → context}/Auth/AuthContext.d.ts +0 -1
- package/dist/{src/context → context}/Auth/AuthProvider.d.ts +0 -1
- package/dist/{src/context → context}/Snackbar/SnackbarContext.d.ts +0 -1
- package/dist/{src/context → context}/Snackbar/SnackbarProvider.d.ts +0 -1
- package/dist/{src/context → context}/Snackbar/snackbarReducer.d.ts +3 -4
- package/dist/{src/features → features}/Treege/Treege.d.ts +1 -2
- package/dist/{src/features → features}/Treege/components/Feedback/DynamicSelectWarning/index.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/Feedback/EndPointWarning/index.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/Forms/FormTreeCardDelete/useFormTreeCardDelete.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/Forms/FormTreeCardMutation/ExtraField.d.ts +1 -2
- package/dist/features/Treege/components/Forms/FormTreeCardMutation/useFormTreeCardMutation.d.ts +112 -0
- package/dist/features/Treege/components/Inputs/AutocompleteSelectType/AutocompleteSelectType.d.ts +12 -0
- package/dist/features/Treege/components/Inputs/AutocompleteSelectType/index.d.ts +3 -0
- package/dist/features/Treege/components/Inputs/AutocompleteSelectType/useAutocompleteSelectType.d.ts +263 -0
- package/dist/{src/features → features}/Treege/components/Inputs/DynamicSelectFieldFromTree/DynamicSelectFieldFromTree.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/Inputs/DynamicSelectFieldFromTree/index.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/Inputs/FieldSelectAutocompleteCreatable/FieldSelectAutocompleteCreatable.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/Inputs/FieldSelectAutocompleteCreatable/index.d.ts +0 -1
- package/dist/features/Treege/components/TreeCardContainer/TreeCardContainer.d.ts +8 -0
- package/dist/{src/features → features}/Treege/components/TreeCardContainer/useTreeCardContainer.d.ts +1 -2
- package/dist/{src/features → features}/Treege/components/TreeNameTextField/index.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/TreeNameTextField/useTreeNameTextField.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/TreeSelect/TreeSelect.d.ts +0 -1
- package/dist/{src/features → features}/Treege/components/TreeSelect/index.d.ts +0 -1
- package/dist/features/Treege/components/TreeSelect/useTreeSelect.d.ts +16 -0
- package/dist/{src/features → features}/Treege/context/TreegeContext.d.ts +3 -15
- package/dist/{src/features → features}/Treege/context/TreegeProvider.d.ts +2 -3
- package/dist/{src/features → features}/Treege/index.d.ts +0 -1
- package/dist/{src/features → features}/Treege/reducer/treeReducer.d.ts +1 -2
- package/dist/{src/hooks → hooks}/useSnackbar/index.d.ts +0 -1
- package/dist/{src/hooks → hooks}/useSnackbar/useSnackbar.d.ts +1 -2
- package/dist/{src/hooks → hooks}/useTreegeContext/index.d.ts +0 -1
- package/dist/hooks/useTreegeContext/useTreegeContext.d.ts +2 -0
- package/dist/{src/locales → locales}/en/form-en.d.ts +11 -0
- package/dist/{src/locales → locales}/fr/form-fr.d.ts +11 -0
- package/dist/main.d.ts +4 -1
- package/dist/main.js +3602 -3913
- package/dist/main.umd.cjs +40 -51
- package/dist/services/workflows/mutation/usePatchWorkflowsMutation.d.ts +12 -0
- package/dist/services/workflows/mutation/usePostWorkflowMutation.d.ts +11 -0
- package/dist/services/workflows/query/useWorkflowQuery.d.ts +10 -0
- package/dist/services/workflows/query/useWorkflowsQuery.d.ts +10 -0
- package/dist/utils/tree/appendNode/appendNode.d.ts +76 -0
- package/dist/{src/utils → utils}/tree/appendNode/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/findNodeByUUIDInTree/findNodeByUUIDInTree.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/findNodeByUUIDInTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/findParentNodeByUUIDInTree/findParentNodeByUUIDInTree.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/findParentNodeByUUIDInTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getAllAncestorNamesFromTree/getAllAncestorNamesFromTree.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getAllAncestorNamesFromTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getAllNamesFromTree/getAllNamesFromTree.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getAllNamesFromTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getNode/getNode.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getNode/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getTree/getTree.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getUniqueTagsInTree/getUniqueTagsInTree.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/getUniqueTagsInTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/index.d.ts +8 -9
- package/dist/{src/utils → utils}/tree/removeNode/removeNode.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/removeNode/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/updateNodeInTree/test/mock.d.ts +1 -2
- package/dist/{src/utils → utils}/tree/updateNodeInTree/updateNodeInTree.d.ts +1 -2
- package/package.json +16 -12
- package/dist/src/config/test.config.d.ts +0 -1
- package/dist/src/features/Treege/components/Forms/FormTreeCardMutation/useFormTreeCardMutation.d.ts +0 -81
- package/dist/src/features/Treege/components/Inputs/FieldSelect/FieldSelect.d.ts +0 -10
- package/dist/src/features/Treege/components/Inputs/FieldSelect/index.d.ts +0 -4
- package/dist/src/features/Treege/components/Inputs/FieldSelect/useFieldSelect.d.ts +0 -127
- package/dist/src/features/Treege/components/TreeCardContainer/TreeCardContainer.d.ts +0 -4
- package/dist/src/features/Treege/components/TreeSelect/useTreeSelect.d.ts +0 -21
- package/dist/src/features/Treege/type/TreeNode.d.ts +0 -111
- package/dist/src/hooks/useTreegeContext/useTreegeContext.d.ts +0 -2
- package/dist/src/main.d.ts +0 -5
- package/dist/src/services/workflows/mutation/usePatchWorkflowsMutation.d.ts +0 -14
- package/dist/src/services/workflows/mutation/usePostWorkflowMutation.d.ts +0 -13
- package/dist/src/services/workflows/query/useWorkflowQuery.d.ts +0 -11
- package/dist/src/services/workflows/query/useWorkflowsQuery.d.ts +0 -11
- package/dist/src/utils/tree/appendNode/appendNode.d.ts +0 -73
- /package/dist/{src/components → components}/DataDisplay/Icons/TreePlusIcon.d.ts +0 -0
- /package/dist/{src/components → components}/DataDisplay/Logo/Logo.d.ts +0 -0
- /package/dist/{src/components → components}/DataDisplay/Tree/useTree.d.ts +0 -0
- /package/dist/{src/components → components}/DataDisplay/ViewerJSON/ViewerJSON.d.ts +0 -0
- /package/dist/{src/components → components}/DataDisplay/ViewerJSON/useViewerJSON.d.ts +0 -0
- /package/dist/{src/components → components}/DataDisplay/ViewerJSONAction/ViewerJSONAction.d.ts +0 -0
- /package/dist/{src/components → components}/DataDisplay/ViewerJSONAction/useViewerJSONAction.d.ts +0 -0
- /package/dist/{src/constants → constants}/colors.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/Feedback/DynamicSelectWarning/DynamicSelectWarning.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/Feedback/EndPointWarning/EndPointWarning.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/Forms/FormTreeCardDelete/FormTreeCardDelete.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/Forms/FormTreeCardMutation/FormTreeCardMutation.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/Inputs/ButtonCreateTree/ButtonCreateTree.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/Inputs/ButtonCreateTree/useButtonCreateTree.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/TreeGrid/TreeGrid.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/TreeGrid/useTreeGrid.d.ts +0 -0
- /package/dist/{src/features → features}/Treege/components/TreeNameTextField/TreeNameTextField.d.ts +0 -0
- /package/dist/{src/locales → locales}/en/button-en.d.ts +0 -0
- /package/dist/{src/locales → locales}/en/modal-en.d.ts +0 -0
- /package/dist/{src/locales → locales}/en/snackMessage-en.d.ts +0 -0
- /package/dist/{src/locales → locales}/en/translation-en.d.ts +0 -0
- /package/dist/{src/locales → locales}/fr/button-fr.d.ts +0 -0
- /package/dist/{src/locales → locales}/fr/modal-fr.d.ts +0 -0
- /package/dist/{src/locales → locales}/fr/snackMessage-fr.d.ts +0 -0
- /package/dist/{src/locales → locales}/fr/translation-fr.d.ts +0 -0
- /package/dist/{src/utils → utils}/index.d.ts +0 -0
- /package/dist/{src/utils → utils}/tree/getUniqueTagsInTree/test/getUniqueTagsInTree.d.ts +0 -0
- /package/dist/{src/utils → utils}/uuid/getUUID.d.ts +0 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { TreeNode } from '@tracktor/types-treege';
|
|
2
|
+
interface PatchWorkflowVariables {
|
|
3
|
+
workflow: TreeNode;
|
|
4
|
+
version: string;
|
|
5
|
+
label?: string;
|
|
6
|
+
id?: string;
|
|
7
|
+
}
|
|
8
|
+
interface PatchWorkflowResponse {
|
|
9
|
+
status: string;
|
|
10
|
+
}
|
|
11
|
+
declare const usePatchWorkflowsMutation: () => import('@tanstack/react-query').UseMutationResult<PatchWorkflowResponse, Error, PatchWorkflowVariables, unknown>;
|
|
12
|
+
export default usePatchWorkflowsMutation;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { TreeNode } from '@tracktor/types-treege';
|
|
2
|
+
interface PostWorkflowVariables {
|
|
3
|
+
workflow: TreeNode;
|
|
4
|
+
version: string;
|
|
5
|
+
label?: string;
|
|
6
|
+
}
|
|
7
|
+
interface PostWorkflowResponse {
|
|
8
|
+
workflow_id: string;
|
|
9
|
+
}
|
|
10
|
+
declare const usePostWorkflowMutation: () => import('@tanstack/react-query').UseMutationResult<PostWorkflowResponse, Error, PostWorkflowVariables, unknown>;
|
|
11
|
+
export default usePostWorkflowMutation;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query/src/types';
|
|
2
|
+
import { TreeNode } from '@tracktor/types-treege';
|
|
3
|
+
interface WorkflowResponse {
|
|
4
|
+
id: string;
|
|
5
|
+
label: string;
|
|
6
|
+
version: string;
|
|
7
|
+
workflow: TreeNode;
|
|
8
|
+
}
|
|
9
|
+
declare const useWorkflowQuery: (id?: string, options?: Omit<UseQueryOptions<WorkflowResponse>, "queryFn" | "queryKey">) => import('@tanstack/react-query').UseQueryResult<WorkflowResponse, Error>;
|
|
10
|
+
export default useWorkflowQuery;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
2
|
+
import { TreeNode } from '@tracktor/types-treege';
|
|
3
|
+
export interface WorkflowsResponse {
|
|
4
|
+
id: string;
|
|
5
|
+
label: string;
|
|
6
|
+
version: string;
|
|
7
|
+
workflow: TreeNode;
|
|
8
|
+
}
|
|
9
|
+
declare const useWorkflowsQuery: (options?: Omit<UseQueryOptions<WorkflowsResponse[]>, "queryFn" | "queryKey">) => import('@tanstack/react-query').UseQueryResult<WorkflowsResponse[], Error>;
|
|
10
|
+
export default useWorkflowsQuery;
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { TreeNode } from '@tracktor/types-treege';
|
|
2
|
+
interface AppendChildParams {
|
|
3
|
+
tree: TreeNode | null;
|
|
4
|
+
path: string | null;
|
|
5
|
+
uuid: string;
|
|
6
|
+
child: TreeNode;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Append child to tree
|
|
10
|
+
* @param tree
|
|
11
|
+
* @param path
|
|
12
|
+
* @param uuid
|
|
13
|
+
* @param child
|
|
14
|
+
*/
|
|
15
|
+
declare const appendNode: ({ tree, path, uuid, child }: AppendChildParams) => TreeNode | {
|
|
16
|
+
attributes: {
|
|
17
|
+
isLeaf: boolean;
|
|
18
|
+
isRoot: boolean;
|
|
19
|
+
depth: number;
|
|
20
|
+
tag?: string;
|
|
21
|
+
helperText?: string;
|
|
22
|
+
isDecision?: boolean;
|
|
23
|
+
label?: string;
|
|
24
|
+
name: string;
|
|
25
|
+
required?: boolean;
|
|
26
|
+
step?: string;
|
|
27
|
+
type: import('@tracktor/types-treege').FieldType;
|
|
28
|
+
value?: never;
|
|
29
|
+
values?: import('@tracktor/types-treege').TreeValues[];
|
|
30
|
+
message?: never;
|
|
31
|
+
tree?: TreeNode;
|
|
32
|
+
treePath?: string;
|
|
33
|
+
repeatable?: boolean;
|
|
34
|
+
hiddenValue?: string;
|
|
35
|
+
isDisabledPast?: boolean;
|
|
36
|
+
route?: import('@tracktor/types-treege').Route;
|
|
37
|
+
parentRef?: string;
|
|
38
|
+
initialQuery?: boolean;
|
|
39
|
+
pattern?: string;
|
|
40
|
+
patternMessage?: string;
|
|
41
|
+
messages?: {
|
|
42
|
+
on?: string;
|
|
43
|
+
off?: string;
|
|
44
|
+
};
|
|
45
|
+
} | {
|
|
46
|
+
isLeaf: boolean;
|
|
47
|
+
isRoot: boolean;
|
|
48
|
+
depth: number;
|
|
49
|
+
tag?: string;
|
|
50
|
+
helperText?: string;
|
|
51
|
+
messages?: never;
|
|
52
|
+
isDecision?: never;
|
|
53
|
+
label?: string;
|
|
54
|
+
name: string;
|
|
55
|
+
required?: never;
|
|
56
|
+
step?: never;
|
|
57
|
+
type?: never;
|
|
58
|
+
value: string;
|
|
59
|
+
values?: never;
|
|
60
|
+
message?: string;
|
|
61
|
+
tree?: never;
|
|
62
|
+
treePath?: never;
|
|
63
|
+
repeatable?: never;
|
|
64
|
+
hiddenValue?: never;
|
|
65
|
+
isDisabledPast?: boolean;
|
|
66
|
+
route?: import('@tracktor/types-treege').Route;
|
|
67
|
+
parentRef?: string;
|
|
68
|
+
initialQuery?: boolean;
|
|
69
|
+
pattern?: string;
|
|
70
|
+
patternMessage?: string;
|
|
71
|
+
};
|
|
72
|
+
uuid: string;
|
|
73
|
+
children: TreeNode[];
|
|
74
|
+
treeId?: string;
|
|
75
|
+
};
|
|
76
|
+
export default appendNode;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { default as getAllNamesFromTree } from './getAllNamesFromTree/getAllNamesFromTree';
|
|
2
|
-
import { default as getAllAncestorNamesFromTree } from './getAllAncestorNamesFromTree/getAllAncestorNamesFromTree';
|
|
3
|
-
import { default as updateNodeInTree } from './updateNodeInTree/updateNodeInTree';
|
|
4
|
-
import { default as removeNode } from './removeNode/removeNode';
|
|
5
|
-
import { default as getTree } from './getTree/getTree';
|
|
6
|
-
import { default as getNode } from './getNode/getNode';
|
|
7
|
-
import { default as findParentNodeByUUIDInTree } from './findParentNodeByUUIDInTree/findParentNodeByUUIDInTree';
|
|
8
|
-
import { default as findNodeByUUIDInTree } from './findNodeByUUIDInTree/findNodeByUUIDInTree';
|
|
9
1
|
import { default as appendNode } from './appendNode/appendNode';
|
|
10
|
-
|
|
2
|
+
import { default as findNodeByUUIDInTree } from './findNodeByUUIDInTree/findNodeByUUIDInTree';
|
|
3
|
+
import { default as findParentNodeByUUIDInTree } from './findParentNodeByUUIDInTree/findParentNodeByUUIDInTree';
|
|
4
|
+
import { default as getNode } from './getNode/getNode';
|
|
5
|
+
import { default as getTree } from './getTree/getTree';
|
|
6
|
+
import { default as removeNode } from './removeNode/removeNode';
|
|
7
|
+
import { default as updateNodeInTree } from './updateNodeInTree/updateNodeInTree';
|
|
8
|
+
import { default as getAllAncestorNamesFromTree } from '../../src/utils/tree/getAllAncestorNamesFromTree/getAllAncestorNamesFromTree';
|
|
9
|
+
import { default as getAllNamesFromTree } from '../../src/utils/tree/getAllNamesFromTree/getAllNamesFromTree';
|
|
11
10
|
export { getTree, updateNodeInTree, appendNode, removeNode, findParentNodeByUUIDInTree, findNodeByUUIDInTree, getAllNamesFromTree, getAllAncestorNamesFromTree, getNode, };
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "treege",
|
|
3
3
|
"description": "Form decision tree generator",
|
|
4
4
|
"license": "ISC",
|
|
5
|
-
"version": "1.
|
|
5
|
+
"version": "1.3.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"types": "./dist/main.d.ts",
|
|
8
8
|
"main": "./dist/main.umd.cjs",
|
|
@@ -34,37 +34,41 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@codemirror/lang-json": "^6.0.1",
|
|
37
|
-
"@mui/icons-material": "^5.14
|
|
38
|
-
"@tanstack/react-query": "^
|
|
39
|
-
"@tracktor/design-system": "^2.
|
|
37
|
+
"@mui/icons-material": "^5.16.14",
|
|
38
|
+
"@tanstack/react-query": "^5.68.0",
|
|
39
|
+
"@tracktor/design-system": "^2.7.16",
|
|
40
40
|
"@uiw/codemirror-theme-dracula": "^4.21.19",
|
|
41
41
|
"@uiw/react-codemirror": "^4.21.19",
|
|
42
|
-
"axios": "^1.
|
|
42
|
+
"axios": "^1.8.3",
|
|
43
43
|
"i18next": "^23.5.1",
|
|
44
44
|
"i18next-browser-languagedetector": "^7.1.0",
|
|
45
|
-
"react-d3-tree": "^3.6.
|
|
45
|
+
"react-d3-tree": "^3.6.6",
|
|
46
46
|
"react-i18next": "^13.2.2"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"@testing-library/jest-dom": "^5.17.0",
|
|
50
50
|
"@testing-library/react": "^14.0.0",
|
|
51
51
|
"@testing-library/user-event": "^14.5.1",
|
|
52
|
+
"@tracktor/types-treege": "^0.1.4",
|
|
52
53
|
"@types/node": "^18.18.4",
|
|
53
54
|
"@types/react": "^18.2.25",
|
|
54
55
|
"@types/react-dom": "^18.2.11",
|
|
55
|
-
"@vitejs/plugin-react": "^4.
|
|
56
|
-
"@vitest/ui": "
|
|
57
|
-
"eslint-config-react-tracktor": "^1.
|
|
56
|
+
"@vitejs/plugin-react": "^4.3.4",
|
|
57
|
+
"@vitest/ui": "1.6.1",
|
|
58
|
+
"eslint-config-react-tracktor": "^1.10.0",
|
|
58
59
|
"husky": "^8.0.3",
|
|
59
60
|
"jsdom": "22.1.0",
|
|
60
61
|
"react": "^18.2.0",
|
|
61
62
|
"react-dom": "^18.2.0",
|
|
62
63
|
"typescript": "^5.2.2",
|
|
63
|
-
"vite": "^5.
|
|
64
|
-
"vite-plugin-dts": "^
|
|
65
|
-
"vitest": "^1.
|
|
64
|
+
"vite": "^5.4.14",
|
|
65
|
+
"vite-plugin-dts": "^4.5.3",
|
|
66
|
+
"vitest": "^1.6.1"
|
|
66
67
|
},
|
|
67
68
|
"peerDependencies": {
|
|
69
|
+
"@mui/icons-material": ">=5",
|
|
70
|
+
"@tracktor/design-system": ">=2",
|
|
71
|
+
"i18next": ">=23",
|
|
68
72
|
"react": ">=18.0.0",
|
|
69
73
|
"react-dom": ">=18.0.0"
|
|
70
74
|
},
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
package/dist/src/features/Treege/components/Forms/FormTreeCardMutation/useFormTreeCardMutation.d.ts
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import { Params, Route, TreeNodeField } from '../../../type/TreeNode';
|
|
2
|
-
import { ChangeEvent, FormEvent, MouseEvent, SyntheticEvent } from 'react';
|
|
3
|
-
import { SelectChangeEvent } from '@tracktor/design-system';
|
|
4
|
-
|
|
5
|
-
interface Values {
|
|
6
|
-
id: string;
|
|
7
|
-
label: string;
|
|
8
|
-
value: string;
|
|
9
|
-
message?: string;
|
|
10
|
-
}
|
|
11
|
-
declare const useFormTreeCardMutation: () => {
|
|
12
|
-
getDisabledValueField: (index: number) => boolean;
|
|
13
|
-
handleAddParams: () => void;
|
|
14
|
-
handleAddValue: () => void;
|
|
15
|
-
handleChangeHelperText: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
16
|
-
handleChangeHiddenValue: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
17
|
-
handleChangeInitialQuery: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
18
|
-
handleChangeIsDecisionField: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
19
|
-
handleChangeIsDisabledPast: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
20
|
-
handleChangeLabel: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
21
|
-
handleChangeMessage: (nameMessage: "on" | "off") => (event: ChangeEvent<HTMLInputElement>) => void;
|
|
22
|
-
handleChangeMultiple: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
23
|
-
handleChangeName: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
24
|
-
handleChangeOptionLabel: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
25
|
-
handleChangeOptionMessage: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
26
|
-
handleChangeOptionValue: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
27
|
-
handleChangeParam: (index: number, property: keyof Params, event: ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
|
|
28
|
-
handleChangeParentRef: (_: SelectChangeEvent<string | undefined>, newValue: string | undefined) => void;
|
|
29
|
-
handleChangePath: <T extends HTMLInputElement | HTMLTextAreaElement>(property: string, event: ChangeEvent<T>) => void;
|
|
30
|
-
handleChangeRepeatable: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
31
|
-
handleChangeRequired: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
32
|
-
handleChangeSearchKey: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
33
|
-
handleChangeStep: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
34
|
-
handleChangeTag: (_: SyntheticEvent<Element, Event>, newValue: string | {
|
|
35
|
-
inputValue: string;
|
|
36
|
-
label: string;
|
|
37
|
-
} | null) => void;
|
|
38
|
-
handleChangeTreeSelect: (event: SelectChangeEvent) => void;
|
|
39
|
-
handleChangeType: (event: SelectChangeEvent<TreeNodeField["type"]>) => void;
|
|
40
|
-
handleChangeUrl: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
41
|
-
handleChangeUrlSelect: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
42
|
-
handleDeleteParam: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
43
|
-
handleDeleteValue: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
44
|
-
handleSubmit: (e: FormEvent) => Promise<void>;
|
|
45
|
-
helperText: string;
|
|
46
|
-
hiddenValue: string;
|
|
47
|
-
initialQuery: boolean;
|
|
48
|
-
isAutocomplete: boolean;
|
|
49
|
-
isBooleanField: boolean;
|
|
50
|
-
isDateRangePicker: boolean;
|
|
51
|
-
isDecision: boolean;
|
|
52
|
-
isDecisionField: boolean;
|
|
53
|
-
isDisabledPast: boolean;
|
|
54
|
-
isDynamicSelect: boolean;
|
|
55
|
-
isEditModal: boolean;
|
|
56
|
-
isHiddenField: boolean;
|
|
57
|
-
isLeaf: boolean;
|
|
58
|
-
isMultiple: boolean;
|
|
59
|
-
isMultiplePossible: boolean;
|
|
60
|
-
isRepeatableDisabled: boolean;
|
|
61
|
-
isRequiredDisabled: boolean;
|
|
62
|
-
isTreeField: boolean;
|
|
63
|
-
isWorkflowLoading: boolean;
|
|
64
|
-
label: string;
|
|
65
|
-
messages: {
|
|
66
|
-
off: string;
|
|
67
|
-
on: string;
|
|
68
|
-
};
|
|
69
|
-
name: string;
|
|
70
|
-
parentRef: string | null;
|
|
71
|
-
repeatable: boolean;
|
|
72
|
-
required: boolean;
|
|
73
|
-
route: Route;
|
|
74
|
-
step: string;
|
|
75
|
-
tag: string | null;
|
|
76
|
-
treeSelected: string;
|
|
77
|
-
type: "number" | "text" | "address" | "select" | "time" | "switch" | "hidden" | "email" | "file" | "password" | "tel" | "url" | "date" | "dateRange" | "timeRange" | "checkbox" | "tree" | "radio" | "autocomplete" | "dynamicSelect";
|
|
78
|
-
uuid: string;
|
|
79
|
-
values: Values[];
|
|
80
|
-
};
|
|
81
|
-
export default useFormTreeCardMutation;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { TreeNodeField } from '../../../type/TreeNode';
|
|
2
|
-
import { SelectChangeEvent } from '@tracktor/design-system';
|
|
3
|
-
|
|
4
|
-
interface FieldsSelectProps {
|
|
5
|
-
id: string;
|
|
6
|
-
value: TreeNodeField["type"];
|
|
7
|
-
onChange?: (event: SelectChangeEvent<TreeNodeField["type"]>) => void;
|
|
8
|
-
}
|
|
9
|
-
declare const FieldSelect: ({ id, onChange, value }: FieldsSelectProps) => import("react/jsx-runtime").JSX.Element;
|
|
10
|
-
export default FieldSelect;
|
|
@@ -1,127 +0,0 @@
|
|
|
1
|
-
declare const useFieldSelect: () => {
|
|
2
|
-
fields: ({
|
|
3
|
-
readonly isBooleanField: false;
|
|
4
|
-
readonly isDecisionField: false;
|
|
5
|
-
readonly isRepeatableDisabled: false;
|
|
6
|
-
readonly isRequiredDisabled: false;
|
|
7
|
-
readonly type: "text";
|
|
8
|
-
} | {
|
|
9
|
-
readonly isBooleanField: false;
|
|
10
|
-
readonly isDecisionField: false;
|
|
11
|
-
readonly isRepeatableDisabled: false;
|
|
12
|
-
readonly isRequiredDisabled: false;
|
|
13
|
-
readonly type: "number";
|
|
14
|
-
} | {
|
|
15
|
-
readonly isBooleanField: false;
|
|
16
|
-
readonly isDecisionField: false;
|
|
17
|
-
readonly isRepeatableDisabled: false;
|
|
18
|
-
readonly isRequiredDisabled: false;
|
|
19
|
-
readonly type: "email";
|
|
20
|
-
} | {
|
|
21
|
-
readonly isBooleanField: false;
|
|
22
|
-
readonly isDecisionField: false;
|
|
23
|
-
readonly isMultiple: false;
|
|
24
|
-
readonly isRepeatableDisabled: false;
|
|
25
|
-
readonly isRequiredDisabled: false;
|
|
26
|
-
readonly type: "file";
|
|
27
|
-
} | {
|
|
28
|
-
readonly isBooleanField: false;
|
|
29
|
-
readonly isDecisionField: false;
|
|
30
|
-
readonly isRepeatableDisabled: false;
|
|
31
|
-
readonly isRequiredDisabled: false;
|
|
32
|
-
readonly type: "password";
|
|
33
|
-
} | {
|
|
34
|
-
readonly isBooleanField: false;
|
|
35
|
-
readonly isDecisionField: false;
|
|
36
|
-
readonly isRepeatableDisabled: false;
|
|
37
|
-
readonly isRequiredDisabled: false;
|
|
38
|
-
readonly type: "tel";
|
|
39
|
-
} | {
|
|
40
|
-
readonly isBooleanField: false;
|
|
41
|
-
readonly isDecisionField: false;
|
|
42
|
-
readonly isRepeatableDisabled: false;
|
|
43
|
-
readonly isRequiredDisabled: false;
|
|
44
|
-
readonly type: "address";
|
|
45
|
-
} | {
|
|
46
|
-
readonly isBooleanField: false;
|
|
47
|
-
readonly isDecisionField: false;
|
|
48
|
-
readonly isRepeatableDisabled: false;
|
|
49
|
-
readonly isRequiredDisabled: false;
|
|
50
|
-
readonly type: "url";
|
|
51
|
-
} | {
|
|
52
|
-
readonly isBooleanField: false;
|
|
53
|
-
readonly isDecisionField: false;
|
|
54
|
-
readonly isRepeatableDisabled: false;
|
|
55
|
-
readonly isRequiredDisabled: false;
|
|
56
|
-
readonly type: "date";
|
|
57
|
-
} | {
|
|
58
|
-
readonly isBooleanField: false;
|
|
59
|
-
readonly isDecisionField: false;
|
|
60
|
-
readonly isRepeatableDisabled: false;
|
|
61
|
-
readonly isRequiredDisabled: false;
|
|
62
|
-
readonly type: "dateRange";
|
|
63
|
-
} | {
|
|
64
|
-
readonly isBooleanField: false;
|
|
65
|
-
readonly isDecisionField: false;
|
|
66
|
-
readonly isRepeatableDisabled: false;
|
|
67
|
-
readonly isRequiredDisabled: false;
|
|
68
|
-
readonly type: "time";
|
|
69
|
-
} | {
|
|
70
|
-
readonly isBooleanField: false;
|
|
71
|
-
readonly isDecisionField: false;
|
|
72
|
-
readonly isRepeatableDisabled: false;
|
|
73
|
-
readonly isRequiredDisabled: false;
|
|
74
|
-
readonly type: "timeRange";
|
|
75
|
-
} | {
|
|
76
|
-
readonly isBooleanField: true;
|
|
77
|
-
readonly isDecisionField: false;
|
|
78
|
-
readonly isRepeatableDisabled: true;
|
|
79
|
-
readonly isRequiredDisabled: true;
|
|
80
|
-
readonly type: "switch";
|
|
81
|
-
} | {
|
|
82
|
-
readonly isBooleanField: true;
|
|
83
|
-
readonly isDecisionField: false;
|
|
84
|
-
readonly isRepeatableDisabled: true;
|
|
85
|
-
readonly isRequiredDisabled: true;
|
|
86
|
-
readonly type: "checkbox";
|
|
87
|
-
} | {
|
|
88
|
-
readonly isBooleanField: false;
|
|
89
|
-
readonly isDecisionField: false;
|
|
90
|
-
readonly isRepeatableDisabled: true;
|
|
91
|
-
readonly isRequiredDisabled: true;
|
|
92
|
-
readonly type: "hidden";
|
|
93
|
-
} | {
|
|
94
|
-
readonly isBooleanField: false;
|
|
95
|
-
readonly isDecisionField: false;
|
|
96
|
-
readonly isRepeatableDisabled: true;
|
|
97
|
-
readonly isRequiredDisabled: true;
|
|
98
|
-
readonly type: "tree";
|
|
99
|
-
} | {
|
|
100
|
-
readonly isBooleanField: false;
|
|
101
|
-
readonly isDecisionField: true;
|
|
102
|
-
readonly isRepeatableDisabled: true;
|
|
103
|
-
readonly isRequiredDisabled: false;
|
|
104
|
-
readonly type: "radio";
|
|
105
|
-
} | {
|
|
106
|
-
readonly isBooleanField: false;
|
|
107
|
-
readonly isDecisionField: true;
|
|
108
|
-
readonly isRepeatableDisabled: true;
|
|
109
|
-
readonly isRequiredDisabled: false;
|
|
110
|
-
readonly type: "select";
|
|
111
|
-
} | {
|
|
112
|
-
readonly initialQueryEnable: true;
|
|
113
|
-
readonly isBooleanField: false;
|
|
114
|
-
readonly isDecisionField: false;
|
|
115
|
-
readonly isRepeatableDisabled: true;
|
|
116
|
-
readonly isRequiredDisabled: false;
|
|
117
|
-
readonly type: "autocomplete";
|
|
118
|
-
} | {
|
|
119
|
-
readonly isBooleanField: false;
|
|
120
|
-
readonly isDecisionField: false;
|
|
121
|
-
readonly isMultiple: false;
|
|
122
|
-
readonly isRepeatableDisabled: false;
|
|
123
|
-
readonly isRequiredDisabled: false;
|
|
124
|
-
readonly type: "dynamicSelect";
|
|
125
|
-
})[];
|
|
126
|
-
};
|
|
127
|
-
export default useFieldSelect;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { TreeCustomNodeElementProps } from '../../type/TreeNode';
|
|
2
|
-
|
|
3
|
-
declare const TreeCardContainer: ({ nodeDatum, hierarchyPointNode, toggleNode, onNodeClick, onNodeMouseOver, onNodeMouseOut, addChildren, }: TreeCustomNodeElementProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
-
export default TreeCardContainer;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { SelectChangeEvent } from '@tracktor/design-system';
|
|
2
|
-
|
|
3
|
-
interface useTreeSelectProps {
|
|
4
|
-
isControlled: boolean;
|
|
5
|
-
fetchWorkflowsOnOpen?: boolean;
|
|
6
|
-
}
|
|
7
|
-
declare const useTreeSelect: ({ isControlled, fetchWorkflowsOnOpen }: useTreeSelectProps) => {
|
|
8
|
-
currentTree: {
|
|
9
|
-
id?: string | undefined;
|
|
10
|
-
name?: string | undefined;
|
|
11
|
-
errorName?: string | undefined;
|
|
12
|
-
};
|
|
13
|
-
fetchWorkflowSuggestions: <TPageData>(options?: (import('@tanstack/query-core').RefetchOptions & import('@tanstack/query-core').RefetchQueryFilters<TPageData>) | undefined) => Promise<import('@tanstack/query-core').QueryObserverResult<import("@/services/workflows/query/useWorkflowsQuery").WorkflowsResponse[], unknown>>;
|
|
14
|
-
handleChangeTree: ({ target }: SelectChangeEvent) => Promise<void>;
|
|
15
|
-
handleOnOpen: () => Promise<void>;
|
|
16
|
-
setTreeSelected: import('react').Dispatch<import("react").SetStateAction<string>>;
|
|
17
|
-
treeSelected: string;
|
|
18
|
-
workflowsSuggestions: import('../../../../services/workflows/query/useWorkflowsQuery').WorkflowsResponse[] | undefined;
|
|
19
|
-
workflowsSuggestionsLoading: boolean;
|
|
20
|
-
};
|
|
21
|
-
export default useTreeSelect;
|