@jsonui/react 0.7.5 → 0.8.2
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/README.md +4 -2
- package/dist/cjs/index.js +68 -19711
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +45 -19684
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +10 -9
- package/package.json +49 -46
- package/dist/cjs/types/ErrorBoundary.d.ts +0 -21
- package/dist/cjs/types/MessageReceiver.d.ts +0 -2
- package/dist/cjs/types/MessageReceiverContext.d.ts +0 -8
- package/dist/cjs/types/ReduxProviders.d.ts +0 -9
- package/dist/cjs/types/Renderer.d.ts +0 -7
- package/dist/cjs/types/ViewerWeb.d.ts +0 -4
- package/dist/cjs/types/Wrapper.d.ts +0 -7
- package/dist/cjs/types/index.d.ts +0 -8
- package/dist/cjs/types/indexWeb.d.ts +0 -1
- package/dist/cjs/types/stock/components/Button.d.ts +0 -3
- package/dist/cjs/types/stock/components/Edit.d.ts +0 -3
- package/dist/cjs/types/stock/components/FormResult.d.ts +0 -5
- package/dist/cjs/types/stock/components/Fragment.d.ts +0 -2
- package/dist/cjs/types/stock/components/HelperText.d.ts +0 -3
- package/dist/cjs/types/stock/components/Image.d.ts +0 -3
- package/dist/cjs/types/stock/components/Label.d.ts +0 -9
- package/dist/cjs/types/stock/components/PrimitiveProp.d.ts +0 -3
- package/dist/cjs/types/stock/components/Text.d.ts +0 -3
- package/dist/cjs/types/stock/components/Undefined.d.ts +0 -3
- package/dist/cjs/types/stock/components/View.d.ts +0 -3
- package/dist/cjs/types/stock/components.d.ts +0 -18
- package/dist/cjs/types/stock/stockToRenderer.d.ts +0 -20
- package/dist/cjs/types/stories/JsonUI.stories.d.ts +0 -6
- package/dist/cjs/types/stories/MultiChild.stories.d.ts +0 -5
- package/dist/cjs/types/stories/PartialValueUpdateTest/PushNotificationTest.stories.d.ts +0 -5
- package/dist/cjs/types/stories/PerformansTest1.stories.d.ts +0 -5
- package/dist/cjs/types/stories/PerformansTest2.stories.d.ts +0 -5
- package/dist/cjs/types/stories/ReduxTest.stories.d.ts +0 -6
- package/dist/cjs/types/stories/Simple.stories.d.ts +0 -5
- package/dist/cjs/types/stories/StateSaveTest/StateSaveTest.stories.d.ts +0 -5
- package/dist/cjs/types/stories/Table.stories.d.ts +0 -5
- package/dist/cjs/types/stories/Validation.stories.d.ts +0 -12
- package/dist/cjs/types/tests/action.test.d.ts +0 -1
- package/dist/cjs/types/tests/button.test.d.ts +0 -1
- package/dist/cjs/types/tests/input.test.d.ts +0 -13
- package/dist/cjs/types/tests/modifier.test.d.ts +0 -1
- package/dist/cjs/types/tests/pathModifier.test.d.ts +0 -1
- package/dist/cjs/types/tests/primitive_simple.test.d.ts +0 -1
- package/dist/cjs/types/tests/redux.test.d.ts +0 -13
- package/dist/cjs/types/tests/simple.test.d.ts +0 -1
- package/dist/cjs/types/types.d.ts +0 -26
- package/dist/esm/types/ErrorBoundary.d.ts +0 -21
- package/dist/esm/types/MessageReceiver.d.ts +0 -2
- package/dist/esm/types/MessageReceiverContext.d.ts +0 -8
- package/dist/esm/types/ReduxProviders.d.ts +0 -9
- package/dist/esm/types/Renderer.d.ts +0 -7
- package/dist/esm/types/ViewerWeb.d.ts +0 -4
- package/dist/esm/types/Wrapper.d.ts +0 -7
- package/dist/esm/types/index.d.ts +0 -8
- package/dist/esm/types/indexWeb.d.ts +0 -1
- package/dist/esm/types/stock/components/Button.d.ts +0 -3
- package/dist/esm/types/stock/components/Edit.d.ts +0 -3
- package/dist/esm/types/stock/components/FormResult.d.ts +0 -5
- package/dist/esm/types/stock/components/Fragment.d.ts +0 -2
- package/dist/esm/types/stock/components/HelperText.d.ts +0 -3
- package/dist/esm/types/stock/components/Image.d.ts +0 -3
- package/dist/esm/types/stock/components/Label.d.ts +0 -9
- package/dist/esm/types/stock/components/PrimitiveProp.d.ts +0 -3
- package/dist/esm/types/stock/components/Text.d.ts +0 -3
- package/dist/esm/types/stock/components/Undefined.d.ts +0 -3
- package/dist/esm/types/stock/components/View.d.ts +0 -3
- package/dist/esm/types/stock/components.d.ts +0 -18
- package/dist/esm/types/stock/stockToRenderer.d.ts +0 -20
- package/dist/esm/types/stories/JsonUI.stories.d.ts +0 -6
- package/dist/esm/types/stories/MultiChild.stories.d.ts +0 -5
- package/dist/esm/types/stories/PartialValueUpdateTest/PushNotificationTest.stories.d.ts +0 -5
- package/dist/esm/types/stories/PerformansTest1.stories.d.ts +0 -5
- package/dist/esm/types/stories/PerformansTest2.stories.d.ts +0 -5
- package/dist/esm/types/stories/ReduxTest.stories.d.ts +0 -6
- package/dist/esm/types/stories/Simple.stories.d.ts +0 -5
- package/dist/esm/types/stories/StateSaveTest/StateSaveTest.stories.d.ts +0 -5
- package/dist/esm/types/stories/Table.stories.d.ts +0 -5
- package/dist/esm/types/stories/Validation.stories.d.ts +0 -12
- package/dist/esm/types/tests/action.test.d.ts +0 -1
- package/dist/esm/types/tests/button.test.d.ts +0 -1
- package/dist/esm/types/tests/input.test.d.ts +0 -13
- package/dist/esm/types/tests/modifier.test.d.ts +0 -1
- package/dist/esm/types/tests/pathModifier.test.d.ts +0 -1
- package/dist/esm/types/tests/primitive_simple.test.d.ts +0 -1
- package/dist/esm/types/tests/redux.test.d.ts +0 -13
- package/dist/esm/types/tests/simple.test.d.ts +0 -1
- package/dist/esm/types/types.d.ts +0 -26
package/dist/index.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { JsonUIComponentsType, JsonUIFunctions } from '@jsonui/core';
|
|
3
3
|
export { JsonUIComponentsType, JsonUIFunctionType, JsonUIFunctions } from '@jsonui/core';
|
|
4
4
|
import * as react from 'react';
|
|
5
|
-
import { ChangeDefaultValueFunc } from 'types';
|
|
6
5
|
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
type JSONPrimitive = string | number | boolean | null;
|
|
7
|
+
type JSONObject = {
|
|
9
8
|
[member: string]: any;
|
|
10
9
|
};
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
type JSONArray = Array<any>;
|
|
11
|
+
type JSONValue = JSONPrimitive | JSONObject | JSONArray | undefined;
|
|
13
12
|
interface ChangeDefaultValueFuncProp {
|
|
14
13
|
store: string;
|
|
15
14
|
path: string;
|
|
16
15
|
value: JSONValue;
|
|
17
16
|
}
|
|
17
|
+
type ChangeDefaultValueFunc = (arg: ChangeDefaultValueFuncProp) => void;
|
|
18
18
|
interface DefaultValues {
|
|
19
19
|
[key: string]: JSONValue;
|
|
20
20
|
}
|
|
21
|
-
|
|
21
|
+
type GetFormState = React.MutableRefObject<(() => DefaultValues) | undefined>;
|
|
22
22
|
interface ViewerProps {
|
|
23
23
|
model: any;
|
|
24
24
|
defaultValues?: DefaultValues;
|
|
@@ -34,6 +34,7 @@ declare class MessageHandler {
|
|
|
34
34
|
}
|
|
35
35
|
declare const MessageHandlerContext: react.Context<MessageHandler | null>;
|
|
36
36
|
|
|
37
|
-
declare const JsonUI: (props: ViewerProps) => JSX.Element;
|
|
37
|
+
declare const JsonUI: (props: ViewerProps) => react_jsx_runtime.JSX.Element;
|
|
38
38
|
|
|
39
|
-
export {
|
|
39
|
+
export { JsonUI, MessageHandler, MessageHandlerContext, JsonUI as default };
|
|
40
|
+
export type { ChangeDefaultValueFuncProp, JSONValue, ViewerProps as JsonUIProps };
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jsonui/react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.2",
|
|
4
|
+
"type": "module",
|
|
4
5
|
"author": "Istvan Fodor <fodori@jsonui.org>",
|
|
5
6
|
"contributors": [],
|
|
6
7
|
"bugs": {
|
|
@@ -22,59 +23,55 @@
|
|
|
22
23
|
"access": "public"
|
|
23
24
|
},
|
|
24
25
|
"license": "MIT",
|
|
25
|
-
"main": "dist/cjs/index.js",
|
|
26
|
-
"module": "dist/esm/index.js",
|
|
27
26
|
"files": [
|
|
28
27
|
"dist"
|
|
29
28
|
],
|
|
29
|
+
"main": "dist/cjs/index.js",
|
|
30
|
+
"module": "dist/esm/index.js",
|
|
30
31
|
"types": "dist/index.d.ts",
|
|
32
|
+
"exports": {
|
|
33
|
+
".": {
|
|
34
|
+
"types": "./dist/index.d.ts",
|
|
35
|
+
"import": "./dist/esm/index.js",
|
|
36
|
+
"require": "./dist/cjs/index.js"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
31
39
|
"scripts": {
|
|
32
40
|
"build": "rollup -c",
|
|
33
41
|
"lint": "eslint src --ext .jsx,.js,.tsx,.ts",
|
|
34
|
-
"storybook": "
|
|
35
|
-
"build-storybook": "build
|
|
42
|
+
"storybook": "storybook dev -p 6006",
|
|
43
|
+
"build-storybook": "storybook build",
|
|
36
44
|
"test": "jest"
|
|
37
45
|
},
|
|
38
46
|
"dependencies": {
|
|
39
|
-
"@emotion/react": "^11.
|
|
40
|
-
"@jsonui/core": "^0.
|
|
47
|
+
"@emotion/react": "^11.14.0",
|
|
48
|
+
"@jsonui/core": "^0.8.1",
|
|
41
49
|
"batchflow": "^0.4.0",
|
|
42
|
-
"jsonata": "^1.
|
|
43
|
-
"lodash": "^4.17.21",
|
|
44
|
-
"react-redux": "^7.2.6",
|
|
45
|
-
"redux": "^4.1.2",
|
|
46
|
-
"typescript": "^4.5.4"
|
|
50
|
+
"jsonata": "^2.1.0"
|
|
47
51
|
},
|
|
48
52
|
"devDependencies": {
|
|
49
53
|
"@babel/core": "^7.17.5",
|
|
50
54
|
"@babel/preset-env": "^7.16.11",
|
|
51
55
|
"@babel/preset-react": "^7.16.7",
|
|
52
|
-
"@emotion/jest": "^11.
|
|
53
|
-
"@rollup/plugin-commonjs": "^
|
|
54
|
-
"@rollup/plugin-json": "^
|
|
55
|
-
"@rollup/plugin-node-resolve": "^
|
|
56
|
-
"@rollup/plugin-typescript": "^
|
|
57
|
-
"@storybook/
|
|
58
|
-
"@storybook/
|
|
59
|
-
"@
|
|
60
|
-
"@
|
|
61
|
-
"@
|
|
62
|
-
"@
|
|
63
|
-
"@
|
|
64
|
-
"@
|
|
65
|
-
"@
|
|
66
|
-
"@types/
|
|
67
|
-
"@types/jest": "^27.4.0",
|
|
68
|
-
"@types/lodash": "^4.14.178",
|
|
69
|
-
"@types/node": "^16.11.19",
|
|
70
|
-
"@types/react": "^17.0.38",
|
|
71
|
-
"@types/react-dom": "^17.0.11",
|
|
56
|
+
"@emotion/jest": "^11.14.2",
|
|
57
|
+
"@rollup/plugin-commonjs": "^29.0.0",
|
|
58
|
+
"@rollup/plugin-json": "^6.1.0",
|
|
59
|
+
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
60
|
+
"@rollup/plugin-typescript": "^12.3.0",
|
|
61
|
+
"@storybook/react-vite": "^10.0.7",
|
|
62
|
+
"@storybook/testing-library": "^0.2.2",
|
|
63
|
+
"@testing-library/jest-dom": "^6.9.1",
|
|
64
|
+
"@testing-library/react": "^16.3.0",
|
|
65
|
+
"@testing-library/user-event": "^14.6.1",
|
|
66
|
+
"@types/jest": "^30.0.0",
|
|
67
|
+
"@types/lodash": "^4.17.20",
|
|
68
|
+
"@types/node": "^24.10.00",
|
|
69
|
+
"@types/react": "^19.2.3",
|
|
70
|
+
"@types/react-dom": "^19.2.2",
|
|
72
71
|
"@typescript-eslint/eslint-plugin": "^5.10.0",
|
|
73
72
|
"@typescript-eslint/parser": "^5.10.0",
|
|
74
|
-
"@wojtekmaj/enzyme-adapter-react-17": "^0.6.7",
|
|
75
73
|
"babel-jest": "^27.5.1",
|
|
76
74
|
"babel-loader": "^8.2.3",
|
|
77
|
-
"enzyme": "^3.11.0",
|
|
78
75
|
"eslint": "^8.2.0",
|
|
79
76
|
"eslint-config-airbnb": "^19.0.4",
|
|
80
77
|
"eslint-config-prettier": "^8.3.0",
|
|
@@ -84,21 +81,27 @@
|
|
|
84
81
|
"eslint-plugin-react": "^7.28.0",
|
|
85
82
|
"eslint-plugin-react-hooks": "^4.3.0",
|
|
86
83
|
"eslint-plugin-storybook": "^0.5.7",
|
|
87
|
-
"husky": "^
|
|
88
|
-
"jest": "^
|
|
89
|
-
"
|
|
84
|
+
"husky": "^9.1.7",
|
|
85
|
+
"jest": "^30.2.0",
|
|
86
|
+
"jest-environment-jsdom": "^30.0.0",
|
|
87
|
+
"lint-staged": "^16.2.6",
|
|
88
|
+
"lodash": "^4.17.21",
|
|
90
89
|
"prettier": "^2.5.1",
|
|
91
|
-
"react-
|
|
90
|
+
"react-redux": "^9.2.0",
|
|
91
|
+
"react-test-renderer": "^19.2.0",
|
|
92
|
+
"redux": "^5.0.1",
|
|
92
93
|
"redux-devtools": "^3.7.0",
|
|
93
|
-
"rollup": "^
|
|
94
|
-
"rollup-plugin-dts": "^
|
|
95
|
-
"rollup-plugin-visualizer": "^
|
|
96
|
-
"
|
|
97
|
-
"ts-
|
|
94
|
+
"rollup": "^4.53.2",
|
|
95
|
+
"rollup-plugin-dts": "^6.2.3",
|
|
96
|
+
"rollup-plugin-visualizer": "^6.0.5",
|
|
97
|
+
"storybook": "^10.0.7",
|
|
98
|
+
"ts-jest": "^29.4.5",
|
|
99
|
+
"ts-node": "^10.9.2",
|
|
100
|
+
"typescript": "^5.9.3",
|
|
101
|
+
"vite": "^7.2.2"
|
|
98
102
|
},
|
|
99
103
|
"peerDependencies": {
|
|
100
|
-
"react": "^
|
|
101
|
-
"react-dom": "^17.0.2"
|
|
104
|
+
"react-redux": "^9.2.0"
|
|
102
105
|
},
|
|
103
106
|
"browserslist": {
|
|
104
107
|
"production": [
|
|
@@ -112,5 +115,5 @@
|
|
|
112
115
|
"last 1 safari version"
|
|
113
116
|
]
|
|
114
117
|
},
|
|
115
|
-
"gitHead": "
|
|
118
|
+
"gitHead": "aac0d89b4cf6116cebea7d4fbdc49ea39637da2f"
|
|
116
119
|
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface ErrorBoundaryProps extends React.Props<any> {
|
|
3
|
-
type?: string;
|
|
4
|
-
id?: string;
|
|
5
|
-
}
|
|
6
|
-
declare type errorType = any;
|
|
7
|
-
export interface ErrorBoundaryState {
|
|
8
|
-
hasError: boolean;
|
|
9
|
-
error?: errorType;
|
|
10
|
-
didInfo?: any;
|
|
11
|
-
}
|
|
12
|
-
declare class ErrorBoundary extends React.Component<ErrorBoundaryProps, ErrorBoundaryState> {
|
|
13
|
-
constructor(props: ErrorBoundaryProps);
|
|
14
|
-
static getDerivedStateFromError(error: errorType): {
|
|
15
|
-
hasError: boolean;
|
|
16
|
-
error: any;
|
|
17
|
-
};
|
|
18
|
-
componentDidCatch(error: errorType, info: any): void;
|
|
19
|
-
render(): React.ReactNode;
|
|
20
|
-
}
|
|
21
|
-
export default ErrorBoundary;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ChangeDefaultValueFunc } from 'types';
|
|
3
|
-
export declare class MessageHandler {
|
|
4
|
-
updateDefaultValueHandler?: ChangeDefaultValueFunc;
|
|
5
|
-
set: (newFunc: ChangeDefaultValueFunc) => void;
|
|
6
|
-
get: () => ChangeDefaultValueFunc | undefined;
|
|
7
|
-
}
|
|
8
|
-
export declare const MessageHandlerContext: import("react").Context<MessageHandler | null>;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { DefaultValues, GetFormState } from 'types';
|
|
3
|
-
interface Props {
|
|
4
|
-
children: ReactNode;
|
|
5
|
-
defaultValues?: DefaultValues;
|
|
6
|
-
getFormState?: GetFormState;
|
|
7
|
-
}
|
|
8
|
-
declare const Providers: ({ children, defaultValues: root, getFormState: getState }: Props) => JSX.Element;
|
|
9
|
-
export default Providers;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { PropsType } from '@jsonui/core';
|
|
3
|
-
export declare const getStyle: (props: PropsType | undefined, component: string) => any;
|
|
4
|
-
declare function Wrapper({ props: origProps }: {
|
|
5
|
-
props: any;
|
|
6
|
-
}): JSX.Element | null;
|
|
7
|
-
export default Wrapper;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { JsonUIComponentsType, JsonUIFunctions, JsonUIFunctionType } from '@jsonui/core';
|
|
3
|
-
import { ChangeDefaultValueFuncProp, JSONValue, ViewerProps } from './types';
|
|
4
|
-
import { MessageHandlerContext, MessageHandler } from './MessageReceiverContext';
|
|
5
|
-
declare const JsonUI: (props: ViewerProps) => JSX.Element;
|
|
6
|
-
export { JsonUI, MessageHandlerContext, MessageHandler };
|
|
7
|
-
export type { ViewerProps as JsonUIProps, JSONValue, ChangeDefaultValueFuncProp, JsonUIFunctions, JsonUIFunctionType, JsonUIComponentsType };
|
|
8
|
-
export default JsonUI;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export declare const getLabel: (props: any) => JSX.Element;
|
|
3
|
-
export declare class InfoBox extends React.PureComponent {
|
|
4
|
-
counter: number;
|
|
5
|
-
constructor(props: any);
|
|
6
|
-
componentDidMount(): void;
|
|
7
|
-
componentDidUpdate(): void;
|
|
8
|
-
render(): JSX.Element | null;
|
|
9
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import Text from './components/Text';
|
|
2
|
-
import Button from './components/Button';
|
|
3
|
-
import Edit from './components/Edit';
|
|
4
|
-
import View from './components/View';
|
|
5
|
-
import Image from './components/Image';
|
|
6
|
-
import _Undefined from './components/Undefined';
|
|
7
|
-
import _PrimitiveProp from './components/PrimitiveProp';
|
|
8
|
-
declare const Components: {
|
|
9
|
-
View: typeof View;
|
|
10
|
-
_PrimitiveProp: typeof _PrimitiveProp;
|
|
11
|
-
_Undefined: typeof _Undefined;
|
|
12
|
-
Fragment: ({ children }: any) => any;
|
|
13
|
-
Image: typeof Image;
|
|
14
|
-
Text: typeof Text;
|
|
15
|
-
Button: typeof Button;
|
|
16
|
-
Edit: typeof Edit;
|
|
17
|
-
};
|
|
18
|
-
export default Components;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { Stock } from '@jsonui/core';
|
|
2
|
-
export declare const getStock: (stockInit: any, model: any, Wrapper: any, reduxStore: any) => Stock;
|
|
3
|
-
declare const stock: {
|
|
4
|
-
components: {
|
|
5
|
-
View: typeof import("./components/View").default;
|
|
6
|
-
_PrimitiveProp: typeof import("./components/PrimitiveProp").default;
|
|
7
|
-
_Undefined: typeof import("./components/Undefined").default;
|
|
8
|
-
Fragment: ({ children }: any) => any;
|
|
9
|
-
Image: typeof import("./components/Image").default;
|
|
10
|
-
Text: typeof import("./components/Text").default;
|
|
11
|
-
Button: typeof import("./components/Button").default;
|
|
12
|
-
Edit: typeof import("./components/Edit").default;
|
|
13
|
-
};
|
|
14
|
-
functions: {
|
|
15
|
-
get: import("@jsonui/core").JsonUIFunctionType;
|
|
16
|
-
set: import("@jsonui/core").JsonUIFunctionType;
|
|
17
|
-
jsonata: import("@jsonui/core").JsonUIFunctionType;
|
|
18
|
-
};
|
|
19
|
-
};
|
|
20
|
-
export default stock;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const TableTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export declare const InputTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
6
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const MultiChild: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const PartialValueUpdateTest: ComponentStory<(props: import("../../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const InputTest: ComponentStory<any>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const BoxTest: ComponentStory<any>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const TwoEditAnd1Modifier: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export declare const PathModifierTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
6
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const PrimitivesTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const StoreStateTest: ComponentStory<(props: import("types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const TableTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export default JsonUIStory;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
-
declare const JsonUIStory: ComponentMeta<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
4
|
-
export declare const ValidationTest: ComponentStory<(props: import("../types").ViewerProps) => JSX.Element>;
|
|
5
|
-
export default JsonUIStory;
|
|
6
|
-
/**
|
|
7
|
-
* TODO:
|
|
8
|
-
* how is help submit to validate the whole form
|
|
9
|
-
* touch
|
|
10
|
-
* dirty
|
|
11
|
-
*
|
|
12
|
-
* */
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export {};
|
|
2
|
-
/**
|
|
3
|
-
* TODO:
|
|
4
|
-
* - check actions (with nested ,promise and sync )
|
|
5
|
-
* - check modification (with nested ,promise and sync )
|
|
6
|
-
* - check modification order for example redux vs. simple function
|
|
7
|
-
* - check children and no children component with children prop
|
|
8
|
-
* - check data manipulation with mutability situation
|
|
9
|
-
* - check error boundary how works
|
|
10
|
-
* Low:
|
|
11
|
-
* - check performance or memory leak???
|
|
12
|
-
|
|
13
|
-
* */
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export {};
|
|
2
|
-
/**
|
|
3
|
-
* TODO:
|
|
4
|
-
* - check actions (with nested ,promise and sync )
|
|
5
|
-
* - check modification (with nested ,promise and sync )
|
|
6
|
-
* - check modification order for example redux vs. simple function
|
|
7
|
-
* - check children and no children component with children prop
|
|
8
|
-
* - check data manipulation with mutability situation
|
|
9
|
-
* - check error boundary how works
|
|
10
|
-
* Low:
|
|
11
|
-
* - check performance or memory leak???
|
|
12
|
-
|
|
13
|
-
* */
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { JsonUIComponentsType, JsonUIFunctions } from '@jsonui/core';
|
|
3
|
-
export declare type JSONPrimitive = string | number | boolean | null;
|
|
4
|
-
export declare type JSONObject = {
|
|
5
|
-
[member: string]: any;
|
|
6
|
-
};
|
|
7
|
-
export declare type JSONArray = Array<any>;
|
|
8
|
-
export declare type JSONValue = JSONPrimitive | JSONObject | JSONArray | undefined;
|
|
9
|
-
export interface ChangeDefaultValueFuncProp {
|
|
10
|
-
store: string;
|
|
11
|
-
path: string;
|
|
12
|
-
value: JSONValue;
|
|
13
|
-
}
|
|
14
|
-
export declare type ChangeDefaultValueFunc = (arg: ChangeDefaultValueFuncProp) => void;
|
|
15
|
-
export declare type OnSubmitFunc = (arg: any) => void;
|
|
16
|
-
export interface DefaultValues {
|
|
17
|
-
[key: string]: JSONValue;
|
|
18
|
-
}
|
|
19
|
-
export declare type GetFormState = React.MutableRefObject<(() => DefaultValues) | undefined>;
|
|
20
|
-
export interface ViewerProps {
|
|
21
|
-
model: any;
|
|
22
|
-
defaultValues?: DefaultValues;
|
|
23
|
-
components?: JsonUIComponentsType;
|
|
24
|
-
functions?: JsonUIFunctions;
|
|
25
|
-
getFormState?: GetFormState;
|
|
26
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface ErrorBoundaryProps extends React.Props<any> {
|
|
3
|
-
type?: string;
|
|
4
|
-
id?: string;
|
|
5
|
-
}
|
|
6
|
-
declare type errorType = any;
|
|
7
|
-
export interface ErrorBoundaryState {
|
|
8
|
-
hasError: boolean;
|
|
9
|
-
error?: errorType;
|
|
10
|
-
didInfo?: any;
|
|
11
|
-
}
|
|
12
|
-
declare class ErrorBoundary extends React.Component<ErrorBoundaryProps, ErrorBoundaryState> {
|
|
13
|
-
constructor(props: ErrorBoundaryProps);
|
|
14
|
-
static getDerivedStateFromError(error: errorType): {
|
|
15
|
-
hasError: boolean;
|
|
16
|
-
error: any;
|
|
17
|
-
};
|
|
18
|
-
componentDidCatch(error: errorType, info: any): void;
|
|
19
|
-
render(): React.ReactNode;
|
|
20
|
-
}
|
|
21
|
-
export default ErrorBoundary;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { ChangeDefaultValueFunc } from 'types';
|
|
3
|
-
export declare class MessageHandler {
|
|
4
|
-
updateDefaultValueHandler?: ChangeDefaultValueFunc;
|
|
5
|
-
set: (newFunc: ChangeDefaultValueFunc) => void;
|
|
6
|
-
get: () => ChangeDefaultValueFunc | undefined;
|
|
7
|
-
}
|
|
8
|
-
export declare const MessageHandlerContext: import("react").Context<MessageHandler | null>;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { DefaultValues, GetFormState } from 'types';
|
|
3
|
-
interface Props {
|
|
4
|
-
children: ReactNode;
|
|
5
|
-
defaultValues?: DefaultValues;
|
|
6
|
-
getFormState?: GetFormState;
|
|
7
|
-
}
|
|
8
|
-
declare const Providers: ({ children, defaultValues: root, getFormState: getState }: Props) => JSX.Element;
|
|
9
|
-
export default Providers;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { PropsType } from '@jsonui/core';
|
|
3
|
-
export declare const getStyle: (props: PropsType | undefined, component: string) => any;
|
|
4
|
-
declare function Wrapper({ props: origProps }: {
|
|
5
|
-
props: any;
|
|
6
|
-
}): JSX.Element | null;
|
|
7
|
-
export default Wrapper;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { JsonUIComponentsType, JsonUIFunctions, JsonUIFunctionType } from '@jsonui/core';
|
|
3
|
-
import { ChangeDefaultValueFuncProp, JSONValue, ViewerProps } from './types';
|
|
4
|
-
import { MessageHandlerContext, MessageHandler } from './MessageReceiverContext';
|
|
5
|
-
declare const JsonUI: (props: ViewerProps) => JSX.Element;
|
|
6
|
-
export { JsonUI, MessageHandlerContext, MessageHandler };
|
|
7
|
-
export type { ViewerProps as JsonUIProps, JSONValue, ChangeDefaultValueFuncProp, JsonUIFunctions, JsonUIFunctionType, JsonUIComponentsType };
|
|
8
|
-
export default JsonUI;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|