treege 0.8.0 → 0.10.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 +5 -2
- package/dist/main.js +3376 -3468
- package/dist/main.umd.cjs +38 -38
- package/dist/src/App.d.ts +2 -0
- package/dist/{components → src/components}/DataDisplay/Icons/TreePlusIcon.d.ts +1 -1
- package/dist/src/components/DataDisplay/Logo/Logo.d.ts +2 -0
- package/dist/src/components/DataDisplay/Logo/Logo.test.d.ts +1 -0
- package/dist/{components → src/components}/DataDisplay/Tree/Tree.d.ts +1 -1
- package/dist/{components → src/components}/DataDisplay/TreeCard/TreeCard.d.ts +1 -1
- package/dist/src/components/DataDisplay/ViewerJSON/ViewerJSON.d.ts +5 -0
- package/dist/{components → src/components}/DataDisplay/ViewerJSONAction/ViewerJSONAction.d.ts +1 -1
- package/dist/{components → src/components}/DataDisplay/ViewerJSONAction/useViewerJSONAction.d.ts +4 -0
- package/dist/{components → src/components}/FeedBack/MainModal/MainModal.d.ts +1 -1
- package/dist/{components → src/components}/FeedBack/TreeModal/TreeModal.d.ts +1 -1
- package/dist/{components → src/components}/Layouts/Action/Action.d.ts +1 -1
- package/dist/src/components/Layouts/Action/Action.test.d.ts +1 -0
- package/dist/{components → src/components}/Layouts/Header/Header.d.ts +1 -1
- package/dist/src/components/Layouts/Header/Header.test.d.ts +1 -0
- package/dist/{components → src/components}/Layouts/Main/Main.d.ts +1 -1
- package/dist/src/components/Layouts/Main/Main.test.d.ts +1 -0
- package/dist/{components → src/components}/Layouts/MosaicLayout/MosaicLayout.d.ts +1 -1
- package/dist/src/components/Layouts/MosaicLayout/MosaicLayout.test.d.ts +1 -0
- package/dist/{components → src/components}/Layouts/Sidebar/Sidebar.d.ts +1 -1
- package/dist/src/components/Layouts/Sidebar/Sidebar.test.d.ts +1 -0
- package/dist/{components → src/components}/Theme/DarkTheme/DarkTheme.d.ts +1 -1
- package/dist/src/config/query.config.d.ts +3 -0
- package/dist/src/config/test.config.d.ts +0 -0
- package/dist/src/constants/TreeData.d.ts +7 -0
- package/dist/{context → src/context}/Auth/AuthProvider.d.ts +1 -1
- package/dist/{context → src/context}/Snackbar/SnackbarProvider.d.ts +1 -1
- package/dist/{features → src/features}/Treege/Treege.d.ts +1 -1
- package/dist/src/features/Treege/components/ButtonCreateTree/ButtonCreateTree.d.ts +2 -0
- package/dist/{features → src/features}/Treege/components/FieldsSelect/FieldsSelect.d.ts +1 -1
- package/dist/{features → src/features}/Treege/components/Forms/FormTreeCardDelete/FormTreeCardDelete.d.ts +1 -1
- package/dist/{features → src/features}/Treege/components/Forms/FormTreeCardMutation/ExtraField.d.ts +1 -1
- package/dist/{features → src/features}/Treege/components/Forms/FormTreeCardMutation/FormTreeCardMutation.d.ts +1 -1
- package/dist/{features → src/features}/Treege/components/Forms/FormTreeCardMutation/useFormTreeCardMutation.d.ts +1 -1
- package/dist/{features → src/features}/Treege/components/TreeCardContainer/TreeCardContainer.d.ts +1 -1
- package/dist/src/features/Treege/components/TreeGrid/TreeGrid.d.ts +2 -0
- package/dist/src/features/Treege/components/TreeNameTextField/TreeNameTextField.d.ts +2 -0
- package/dist/{features → src/features}/Treege/components/TreeSelect/TreeSelect.d.ts +1 -1
- package/dist/{features → src/features}/Treege/components/TreeSelect/useTreeSelect.d.ts +0 -1
- package/dist/{features → src/features}/Treege/context/TreegeProvider.d.ts +1 -1
- package/dist/{features → src/features}/Treege/type/TreeNode.d.ts +2 -1
- package/dist/{locales → src/locales}/en/button-en.d.ts +5 -2
- package/dist/{locales → src/locales}/en/form-en.d.ts +3 -3
- package/dist/{locales → src/locales}/en/modal-en.d.ts +3 -2
- package/dist/{locales → src/locales}/en/snackMessage-en.d.ts +2 -2
- package/dist/{locales → src/locales}/en/translation-en.d.ts +2 -2
- package/dist/{locales → src/locales}/fr/button-fr.d.ts +5 -2
- package/dist/{locales → src/locales}/fr/form-fr.d.ts +2 -2
- package/dist/{locales → src/locales}/fr/modal-fr.d.ts +3 -2
- package/dist/{locales → src/locales}/fr/snackMessage-fr.d.ts +2 -2
- package/dist/{locales → src/locales}/fr/translation-fr.d.ts +2 -2
- package/dist/src/utils/array/isUniqueArrayItem/test/isUniqueArrayItem.test.d.ts +1 -0
- package/dist/src/utils/object/index.d.ts +1 -0
- package/dist/src/utils/object/removeObjectProperty/removeObjectProperty.d.ts +2 -0
- package/dist/src/utils/object/removeObjectProperty/test/removeObjectProperty.test.d.ts +1 -0
- package/dist/src/utils/tree/appendNode/appendNode.d.ts +53 -0
- package/dist/src/utils/tree/appendNode/test/appendNode.test.d.ts +1 -0
- package/dist/src/utils/tree/appendNode/test/mock.d.ts +16 -0
- package/dist/src/utils/tree/getNode/test/getNode.test.d.ts +1 -0
- package/dist/src/utils/tree/getNode/test/mock.d.ts +12 -0
- package/dist/src/utils/tree/getNodeByNameInCurrentTree/test/getNodeByNameInCurrentTree.test.d.ts +1 -0
- package/dist/src/utils/tree/getNodeByNameInCurrentTree/test/mock.d.ts +12 -0
- package/dist/src/utils/tree/getNodeNames/test/getNodeNames.test.d.ts +1 -0
- package/dist/src/utils/tree/getNodeNames/test/mock.d.ts +11 -0
- package/dist/src/utils/tree/getParentNodeByNameInCurrentTree/test/getParentNodeByNameInCurrentTree.test.d.ts +1 -0
- package/dist/src/utils/tree/getParentNodeByNameInCurrentTree/test/mock.d.ts +11 -0
- package/dist/src/utils/tree/getTree/test/getTree.test.d.ts +1 -0
- package/dist/src/utils/tree/getTree/test/mock.d.ts +13 -0
- package/dist/{utils → src/utils}/tree/removeNode/removeNode.d.ts +1 -1
- package/dist/src/utils/tree/removeNode/test/mock.d.ts +12 -0
- package/dist/src/utils/tree/removeNode/test/removeNode.test.d.ts +1 -0
- package/dist/src/utils/tree/updatedNode/test/mock.d.ts +14 -0
- package/dist/src/utils/tree/updatedNode/test/updatedNode.test.d.ts +1 -0
- package/dist/{utils → src/utils}/tree/updatedNode/updatedNode.d.ts +1 -1
- package/package.json +20 -20
- package/dist/components/DataDisplay/Logo/Logo.d.ts +0 -2
- package/dist/components/DataDisplay/ViewerJSON/ViewerJSON.d.ts +0 -5
- package/dist/config/queryClient.d.ts +0 -3
- package/dist/features/Treege/components/ButtonCreateTree/ButtonCreateTree.d.ts +0 -2
- package/dist/features/Treege/components/TreeGrid/TreeGrid.d.ts +0 -2
- package/dist/features/Treege/components/TreeNameTextField/TreeNameTextField.d.ts +0 -2
- package/dist/utils/tree/appendNode/appendNode.d.ts +0 -9
- package/dist/{components → src/components}/DataDisplay/Tree/useTree.d.ts +0 -0
- package/dist/{components → src/components}/DataDisplay/ViewerJSON/useViewerJSON.d.ts +0 -0
- package/dist/{config/i18n.d.ts → src/config/i18n.config.d.ts} +0 -0
- package/dist/{config/theme.d.ts → src/config/theme.config.d.ts} +0 -0
- package/dist/{constants → src/constants}/colors.d.ts +0 -0
- package/dist/{constants → src/constants}/fields.d.ts +12 -12
- package/dist/{context → src/context}/Auth/AuthContext.d.ts +0 -0
- package/dist/{context → src/context}/Snackbar/SnackbarContext.d.ts +0 -0
- package/dist/{context → src/context}/Snackbar/snackbarReducer.d.ts +0 -0
- package/dist/{features → src/features}/Treege/components/ButtonCreateTree/useButtonCreateTree.d.ts +0 -0
- package/dist/{features → src/features}/Treege/components/FieldsSelect/index.d.ts +0 -0
- package/dist/{features → src/features}/Treege/components/FieldsSelect/useFieldsSelect.d.ts +12 -12
- /package/dist/{features → src/features}/Treege/components/Forms/FormTreeCardDelete/useFormTreeCardDelete.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/components/TreeCardContainer/useTreeCardContainer.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/components/TreeGrid/useTreeGrid.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/components/TreeNameTextField/index.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/components/TreeNameTextField/useTreeNameTextField.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/components/TreeSelect/index.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/context/TreegeContext.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/index.d.ts +0 -0
- /package/dist/{features → src/features}/Treege/reducer/treeReducer.d.ts +0 -0
- /package/dist/{hooks → src/hooks}/useSnackbar/index.d.ts +0 -0
- /package/dist/{hooks → src/hooks}/useSnackbar/useSnackbar.d.ts +0 -0
- /package/dist/{hooks → src/hooks}/useTreegeContext/index.d.ts +0 -0
- /package/dist/{hooks → src/hooks}/useTreegeContext/useTreegeContext.d.ts +0 -0
- /package/dist/{main.d.ts → src/main.d.ts} +0 -0
- /package/dist/{services → src/services}/workflows/mutation/useAddWorkflowsMutation.d.ts +0 -0
- /package/dist/{services → src/services}/workflows/mutation/useEditWorkflowsMutation.d.ts +0 -0
- /package/dist/{services → src/services}/workflows/mutation/useWorkflowMutationFetcher.d.ts +0 -0
- /package/dist/{services → src/services}/workflows/query/useWorkflowQuery.d.ts +0 -0
- /package/dist/{services → src/services}/workflows/query/useWorkflowQueryFetcher.d.ts +0 -0
- /package/dist/{services → src/services}/workflows/query/useWorkflowsQuery.d.ts +0 -0
- /package/dist/{utils → src/utils}/array/index.d.ts +0 -0
- /package/dist/{utils → src/utils}/array/isUniqueArrayItem/isUniqueArrayItem.d.ts +0 -0
- /package/dist/{utils → src/utils}/tree/getNode/getNode.d.ts +0 -0
- /package/dist/{utils → src/utils}/tree/getNodeByNameInCurrentTree/getNodeByNameInCurrentTree.d.ts +0 -0
- /package/dist/{utils → src/utils}/tree/getNodeNames/getNodeNames.d.ts +0 -0
- /package/dist/{utils → src/utils}/tree/getParentNodeByNameInCurrentTree/getParentNodeByNameInCurrentTree.d.ts +0 -0
- /package/dist/{utils → src/utils}/tree/getTree/getTree.d.ts +0 -0
- /package/dist/{utils → src/utils}/tree/index.d.ts +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { TreeNode } from '../../../../features/Treege/type/TreeNode';
|
|
2
|
+
type Mock = {
|
|
3
|
+
tree: TreeNode;
|
|
4
|
+
output: TreeNode;
|
|
5
|
+
treePath: string;
|
|
6
|
+
newChild: TreeNode;
|
|
7
|
+
name: string;
|
|
8
|
+
};
|
|
9
|
+
declare const updatedFirstNodeInTreeMock: Mock;
|
|
10
|
+
declare const updatedNodeInOtherTreeMock: Mock;
|
|
11
|
+
declare const updatedTreeMock: Mock;
|
|
12
|
+
declare const updatedNodeInComplexeTreeMock: Mock;
|
|
13
|
+
declare const updatedAndAddDecisionInFieldWithChildrenMock: Mock;
|
|
14
|
+
export { updatedFirstNodeInTreeMock, updatedNodeInOtherTreeMock, updatedTreeMock, updatedNodeInComplexeTreeMock, updatedAndAddDecisionInFieldWithChildrenMock, };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -5,5 +5,5 @@ interface UpdatedNodeParams {
|
|
|
5
5
|
name: string;
|
|
6
6
|
child: TreeNode;
|
|
7
7
|
}
|
|
8
|
-
declare const updatedNode: ({ tree, path, name, child }: UpdatedNodeParams) =>
|
|
8
|
+
declare const updatedNode: ({ tree, path, name, child }: UpdatedNodeParams) => TreeNode;
|
|
9
9
|
export default updatedNode;
|
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": "0.
|
|
5
|
+
"version": "0.10.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"types": "dist/main.d.ts",
|
|
8
8
|
"main": "dist/main.umd.cjs",
|
|
@@ -33,36 +33,36 @@
|
|
|
33
33
|
"prepare": "yarn run build && husky install"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@codemirror/lang-json": "^6.0.
|
|
37
|
-
"@mui/icons-material": "^5.
|
|
38
|
-
"@tracktor/design-system": "^1.38.
|
|
39
|
-
"@uiw/codemirror-theme-dracula": "^4.
|
|
40
|
-
"@uiw/react-codemirror": "^4.
|
|
41
|
-
"axios": "^1.
|
|
42
|
-
"i18next": "^22.
|
|
43
|
-
"i18next-browser-languagedetector": "^
|
|
36
|
+
"@codemirror/lang-json": "^6.0.1",
|
|
37
|
+
"@mui/icons-material": "^5.14.1",
|
|
38
|
+
"@tracktor/design-system": "^1.38.6",
|
|
39
|
+
"@uiw/codemirror-theme-dracula": "^4.21.8",
|
|
40
|
+
"@uiw/react-codemirror": "^4.21.8",
|
|
41
|
+
"axios": "^1.4.0",
|
|
42
|
+
"i18next": "^22.2.8",
|
|
43
|
+
"i18next-browser-languagedetector": "^7.1.0",
|
|
44
44
|
"react": "^18.2.0",
|
|
45
|
-
"react-d3-tree": "^3.
|
|
45
|
+
"react-d3-tree": "^3.6.1",
|
|
46
46
|
"react-dom": "^18.2.0",
|
|
47
|
-
"react-i18next": "^
|
|
47
|
+
"react-i18next": "^13.0.2",
|
|
48
48
|
"react-query": "^3.39.3"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@testing-library/jest-dom": "^5.
|
|
51
|
+
"@testing-library/jest-dom": "^5.17.0",
|
|
52
52
|
"@testing-library/react": "^14.0.0",
|
|
53
53
|
"@testing-library/user-event": "^14.4.3",
|
|
54
54
|
"@types/node": "^18.14.6",
|
|
55
|
-
"@types/react": "^18.
|
|
56
|
-
"@types/react-dom": "^18.
|
|
57
|
-
"@vitejs/plugin-react": "^
|
|
58
|
-
"@vitest/ui": "0.
|
|
59
|
-
"eslint-config-react-tracktor": "^1.
|
|
55
|
+
"@types/react": "^18.2.17",
|
|
56
|
+
"@types/react-dom": "^18.2.7",
|
|
57
|
+
"@vitejs/plugin-react": "^4.0.3",
|
|
58
|
+
"@vitest/ui": "0.33.0",
|
|
59
|
+
"eslint-config-react-tracktor": "^1.1.3",
|
|
60
60
|
"husky": "^8.0.3",
|
|
61
61
|
"jsdom": "21.1.0",
|
|
62
62
|
"typescript": "^4.7.4",
|
|
63
|
-
"vite": "4.
|
|
64
|
-
"vite-plugin-dts": "^
|
|
65
|
-
"vitest": "^0.
|
|
63
|
+
"vite": "^4.4.7",
|
|
64
|
+
"vite-plugin-dts": "^3.3.1",
|
|
65
|
+
"vitest": "^0.33.0"
|
|
66
66
|
},
|
|
67
67
|
"peerDependencies": {
|
|
68
68
|
"react": ">=18.0.0",
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { TreeNode } from '../../../features/Treege/type/TreeNode';
|
|
2
|
-
interface AppendChildParams {
|
|
3
|
-
tree: TreeNode | null;
|
|
4
|
-
path: string | null;
|
|
5
|
-
name: string;
|
|
6
|
-
child: TreeNode;
|
|
7
|
-
}
|
|
8
|
-
declare const appendNode: ({ tree, path, name, child }: AppendChildParams) => any;
|
|
9
|
-
export default appendNode;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -70,18 +70,6 @@ declare const fields: readonly [{
|
|
|
70
70
|
readonly isRepeatableDisabled: true;
|
|
71
71
|
readonly isRequiredDisabled: true;
|
|
72
72
|
readonly type: "checkbox";
|
|
73
|
-
}, {
|
|
74
|
-
readonly isBooleanField: false;
|
|
75
|
-
readonly isDecisionField: true;
|
|
76
|
-
readonly isRepeatableDisabled: true;
|
|
77
|
-
readonly isRequiredDisabled: false;
|
|
78
|
-
readonly type: "radio";
|
|
79
|
-
}, {
|
|
80
|
-
readonly isBooleanField: false;
|
|
81
|
-
readonly isDecisionField: true;
|
|
82
|
-
readonly isRepeatableDisabled: true;
|
|
83
|
-
readonly isRequiredDisabled: false;
|
|
84
|
-
readonly type: "select";
|
|
85
73
|
}, {
|
|
86
74
|
readonly isBooleanField: false;
|
|
87
75
|
readonly isDecisionField: false;
|
|
@@ -94,5 +82,17 @@ declare const fields: readonly [{
|
|
|
94
82
|
readonly isRepeatableDisabled: true;
|
|
95
83
|
readonly isRequiredDisabled: true;
|
|
96
84
|
readonly type: "tree";
|
|
85
|
+
}, {
|
|
86
|
+
readonly isBooleanField: false;
|
|
87
|
+
readonly isDecisionField: true;
|
|
88
|
+
readonly isRepeatableDisabled: true;
|
|
89
|
+
readonly isRequiredDisabled: false;
|
|
90
|
+
readonly type: "radio";
|
|
91
|
+
}, {
|
|
92
|
+
readonly isBooleanField: false;
|
|
93
|
+
readonly isDecisionField: true;
|
|
94
|
+
readonly isRepeatableDisabled: true;
|
|
95
|
+
readonly isRequiredDisabled: false;
|
|
96
|
+
readonly type: "select";
|
|
97
97
|
}];
|
|
98
98
|
export default fields;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/dist/{features → src/features}/Treege/components/ButtonCreateTree/useButtonCreateTree.d.ts
RENAMED
|
File without changes
|
|
File without changes
|
|
@@ -71,18 +71,6 @@ declare const useFieldsSelect: () => {
|
|
|
71
71
|
readonly isRepeatableDisabled: true;
|
|
72
72
|
readonly isRequiredDisabled: true;
|
|
73
73
|
readonly type: "checkbox";
|
|
74
|
-
} | {
|
|
75
|
-
readonly isBooleanField: false;
|
|
76
|
-
readonly isDecisionField: true;
|
|
77
|
-
readonly isRepeatableDisabled: true;
|
|
78
|
-
readonly isRequiredDisabled: false;
|
|
79
|
-
readonly type: "radio";
|
|
80
|
-
} | {
|
|
81
|
-
readonly isBooleanField: false;
|
|
82
|
-
readonly isDecisionField: true;
|
|
83
|
-
readonly isRepeatableDisabled: true;
|
|
84
|
-
readonly isRequiredDisabled: false;
|
|
85
|
-
readonly type: "select";
|
|
86
74
|
} | {
|
|
87
75
|
readonly isBooleanField: false;
|
|
88
76
|
readonly isDecisionField: false;
|
|
@@ -95,6 +83,18 @@ declare const useFieldsSelect: () => {
|
|
|
95
83
|
readonly isRepeatableDisabled: true;
|
|
96
84
|
readonly isRequiredDisabled: true;
|
|
97
85
|
readonly type: "tree";
|
|
86
|
+
} | {
|
|
87
|
+
readonly isBooleanField: false;
|
|
88
|
+
readonly isDecisionField: true;
|
|
89
|
+
readonly isRepeatableDisabled: true;
|
|
90
|
+
readonly isRequiredDisabled: false;
|
|
91
|
+
readonly type: "radio";
|
|
92
|
+
} | {
|
|
93
|
+
readonly isBooleanField: false;
|
|
94
|
+
readonly isDecisionField: true;
|
|
95
|
+
readonly isRepeatableDisabled: true;
|
|
96
|
+
readonly isRequiredDisabled: false;
|
|
97
|
+
readonly type: "select";
|
|
98
98
|
})[];
|
|
99
99
|
};
|
|
100
100
|
export default useFieldsSelect;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/dist/{utils → src/utils}/tree/getNodeByNameInCurrentTree/getNodeByNameInCurrentTree.d.ts
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|