Skip to content

Commit 90e26c3

Browse files
authored
Merge branch 'master' into num_validator_message_fix
2 parents 1337ff3 + 667d373 commit 90e26c3

File tree

19 files changed

+76
-17
lines changed

19 files changed

+76
-17
lines changed

packages/ant-component-mapper/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/ant-component-mapper",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "Ant Design React component mapper for Data Driven Forms.",
55
"main": "index.js",
66
"module": "esm/index.js",

packages/blueprint-component-mapper/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/blueprint-component-mapper",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "BlueprintJS React component mapper for Data Driven Forms.",
55
"main": "index.js",
66
"module": "esm/index.js",

packages/carbon-component-mapper/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/carbon-component-mapper",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "Carbon React component mapper for Data Driven Forms.",
55
"main": "index.js",
66
"module": "esm/index.js",

packages/common/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/common",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "Common components, helpers and other pieces of code for Data Driven Forms",
55
"license": "Apache-2.0",
66
"main": "index.js",

packages/mui-component-mapper/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/mui-component-mapper",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "Component mapper for Material ui component mapper form data-driven-forms.",
55
"main": "index.js",
66
"module": "esm/index.js",

packages/mui-component-mapper/src/switch/switch.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ export const Switch = (props) => {
4747
readOnly={isReadOnly}
4848
disabled={isDisabled || isReadOnly}
4949
onChange={({ target: { checked } }) => input.onChange(checked)}
50+
{...SwitchProps}
5051
/>
5152
}
5253
label={<FormLabel {...FormLabelProps}>{input.checked ? onText || label : offText || label}</FormLabel>}

packages/parsers/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/parsers",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "Parsers for Data Driven Forms.",
55
"main": "dist/cjs/index.js",
66
"module": "dist/esm/index.js",

packages/pf4-component-mapper/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@data-driven-forms/pf4-component-mapper",
3-
"version": "3.20.4",
3+
"version": "3.20.9",
44
"description": "Patternfly 4 React component mapper for Data Driven Forms.",
55
"main": "index.js",
66
"module": "esm/index.js",

packages/pf4-component-mapper/src/wizard/wizard.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { ReactNode } from "react";
22
import { Field, AnyObject } from "@data-driven-forms/react-form-renderer";
3+
import { ModalProps } from "@patternfly/react-core";
34

45
export interface WizardButtonLabels {
56
submit?: ReactNode;
@@ -92,6 +93,7 @@ export interface WizardProps {
9293
hasNoBodyPadding?: boolean;
9394
navAriaLabel?: string;
9495
StepTemplate?: React.ComponentType<StepTemplateProps>;
96+
ModalProps?: ModalProps
9597
}
9698

9799
declare const Wizard: React.ComponentType<WizardProps>;

packages/pf4-component-mapper/src/wizard/wizard.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ const WizardInternal = ({
4444
StepTemplate,
4545
className,
4646
conditionalSubmitFlag,
47+
ModalProps = {},
4748
...rest
4849
}) => {
4950
const {
@@ -71,7 +72,10 @@ const WizardInternal = ({
7172
}, [inModal]);
7273

7374
useEffect(() => {
74-
if (state.container) {
75+
if (ModalProps.appendTo) {
76+
// override with default append to
77+
dispatch({ type: 'finishLoading' });
78+
} else if (state.container) {
7579
document.body.appendChild(state.container);
7680
dispatch({ type: 'finishLoading' });
7781
}
@@ -88,7 +92,7 @@ const WizardInternal = ({
8892
}
8993

9094
return (
91-
<Modal inModal={inModal} container={state.container} aria-labelledby={rest.name}>
95+
<Modal inModal={inModal} container={state.container} aria-labelledby={rest.name} {...ModalProps}>
9296
<div
9397
tabIndex={inModal ? 0 : null}
9498
className={`pf-c-wizard ${inModal ? '' : 'no-shadow'} ddorg__pf4-component-mapper__wizard ${className ? className : ''}`}
@@ -179,6 +183,7 @@ WizardInternal.propTypes = {
179183
StepTemplate: PropTypes.elementType,
180184
className: PropTypes.string,
181185
conditionalSubmitFlag: PropTypes.string,
186+
ModalProps: PropTypes.object,
182187
};
183188

184189
const defaultLabels = {

0 commit comments

Comments
 (0)