@jsonforms/material-renderers 3.8.0-alpha.0 → 3.8.0-alpha.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/lib/jsonforms-react-material.cjs.js +1 -1
- package/lib/jsonforms-react-material.cjs.js.map +1 -1
- package/lib/jsonforms-react-material.esm.js +1 -1
- package/lib/jsonforms-react-material.esm.js.map +1 -1
- package/lib/layouts/ExpandPanelRenderer.d.ts +3 -3
- package/package.json +6 -6
- package/src/complex/MaterialOneOfRenderer.tsx +1 -2
- package/src/layouts/ExpandPanelRenderer.tsx +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import React, { ComponentType, Dispatch
|
|
1
|
+
import React, { ComponentType, Dispatch } from 'react';
|
|
2
2
|
import { JsonFormsStateContext } from '@jsonforms/react';
|
|
3
|
-
import { ControlElement, JsonFormsRendererRegistryEntry, JsonSchema, JsonFormsCellRendererRegistryEntry, JsonFormsUISchemaRegistryEntry, ArrayTranslations } from '@jsonforms/core';
|
|
3
|
+
import { ControlElement, CoreActions, JsonFormsRendererRegistryEntry, JsonSchema, JsonFormsCellRendererRegistryEntry, JsonFormsUISchemaRegistryEntry, ArrayTranslations } from '@jsonforms/core';
|
|
4
4
|
interface OwnPropsOfExpandPanel {
|
|
5
5
|
enabled: boolean;
|
|
6
6
|
index: number;
|
|
@@ -43,7 +43,7 @@ export declare const ExpandPanelRenderer: React.MemoExoticComponent<(props: Expa
|
|
|
43
43
|
* @param dispatch the store's dispatch method
|
|
44
44
|
* @returns {DispatchPropsOfArrayControl} dispatch props of an expand panel control
|
|
45
45
|
*/
|
|
46
|
-
export declare const ctxDispatchToExpandPanelProps: (dispatch: Dispatch<
|
|
46
|
+
export declare const ctxDispatchToExpandPanelProps: (dispatch: Dispatch<CoreActions>) => DispatchPropsOfExpandPanel;
|
|
47
47
|
/**
|
|
48
48
|
* Map state to control props.
|
|
49
49
|
* @param state the JSON Forms state
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jsonforms/material-renderers",
|
|
3
|
-
"version": "3.8.0-alpha.
|
|
3
|
+
"version": "3.8.0-alpha.2",
|
|
4
4
|
"description": "Material Renderer Set for JSON Forms",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -80,8 +80,8 @@
|
|
|
80
80
|
"peerDependencies": {
|
|
81
81
|
"@emotion/react": "^11.5.0",
|
|
82
82
|
"@emotion/styled": "^11.3.0",
|
|
83
|
-
"@jsonforms/core": "3.8.0-alpha.
|
|
84
|
-
"@jsonforms/react": "3.8.0-alpha.
|
|
83
|
+
"@jsonforms/core": "3.8.0-alpha.2",
|
|
84
|
+
"@jsonforms/react": "3.8.0-alpha.2",
|
|
85
85
|
"@mui/icons-material": "^7.0.0",
|
|
86
86
|
"@mui/material": "^7.0.0",
|
|
87
87
|
"@mui/x-date-pickers": "^8.0.0",
|
|
@@ -130,12 +130,12 @@
|
|
|
130
130
|
"ts-loader": "^9.5.1",
|
|
131
131
|
"tslib": "^2.5.0",
|
|
132
132
|
"typedoc": "~0.25.3",
|
|
133
|
-
"typescript": "~5.
|
|
133
|
+
"typescript": "~5.8.3",
|
|
134
134
|
"webpack": "^5.78.0",
|
|
135
135
|
"webpack-cli": "^5.1.4",
|
|
136
136
|
"webpack-dev-server": "^4.15.1",
|
|
137
|
-
"@jsonforms/core": "3.8.0-alpha.
|
|
138
|
-
"@jsonforms/react": "3.8.0-alpha.
|
|
137
|
+
"@jsonforms/core": "3.8.0-alpha.2",
|
|
138
|
+
"@jsonforms/react": "3.8.0-alpha.2"
|
|
139
139
|
},
|
|
140
140
|
"scripts": {
|
|
141
141
|
"build": "rollup -c rollup.config.js",
|
|
@@ -23,7 +23,6 @@
|
|
|
23
23
|
THE SOFTWARE.
|
|
24
24
|
*/
|
|
25
25
|
import React, { useCallback, useMemo, useState } from 'react';
|
|
26
|
-
import isEmpty from 'lodash/isEmpty';
|
|
27
26
|
|
|
28
27
|
import { TabSwitchConfirmDialog } from './TabSwitchConfirmDialog';
|
|
29
28
|
|
|
@@ -98,7 +97,7 @@ export const MaterialOneOfRenderer = ({
|
|
|
98
97
|
const handleTabChange = useCallback(
|
|
99
98
|
(_event: any, newOneOfIndex: number) => {
|
|
100
99
|
setNewSelectedIndex(newOneOfIndex);
|
|
101
|
-
if (
|
|
100
|
+
if (data === undefined) {
|
|
102
101
|
openNewTab(newOneOfIndex);
|
|
103
102
|
} else {
|
|
104
103
|
setConfirmDialogOpen(true);
|
|
@@ -3,7 +3,6 @@ import React, {
|
|
|
3
3
|
ComponentType,
|
|
4
4
|
Dispatch,
|
|
5
5
|
Fragment,
|
|
6
|
-
ReducerAction,
|
|
7
6
|
useMemo,
|
|
8
7
|
useState,
|
|
9
8
|
useEffect,
|
|
@@ -17,6 +16,7 @@ import {
|
|
|
17
16
|
import {
|
|
18
17
|
composePaths,
|
|
19
18
|
ControlElement,
|
|
19
|
+
CoreActions,
|
|
20
20
|
findUISchema,
|
|
21
21
|
JsonFormsRendererRegistryEntry,
|
|
22
22
|
JsonSchema,
|
|
@@ -258,7 +258,7 @@ export const ExpandPanelRenderer = React.memo(ExpandPanelRendererComponent);
|
|
|
258
258
|
* @returns {DispatchPropsOfArrayControl} dispatch props of an expand panel control
|
|
259
259
|
*/
|
|
260
260
|
export const ctxDispatchToExpandPanelProps: (
|
|
261
|
-
dispatch: Dispatch<
|
|
261
|
+
dispatch: Dispatch<CoreActions>
|
|
262
262
|
) => DispatchPropsOfExpandPanel = (dispatch) => ({
|
|
263
263
|
removeItems: useCallback(
|
|
264
264
|
(path: string, toDelete: number[]) =>
|