@rjsf/mui 6.5.0 → 6.5.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/dist/index.cjs +181 -73
- package/dist/index.cjs.map +2 -2
- package/dist/mui.esm.js +181 -73
- package/dist/mui.esm.js.map +2 -2
- package/dist/mui.umd.js +181 -73
- package/lib/ArrayFieldItemTemplate/ArrayFieldItemTemplate.js +3 -3
- package/lib/ArrayFieldItemTemplate/ArrayFieldItemTemplate.js.map +1 -1
- package/lib/ArrayFieldTemplate/ArrayFieldTemplate.js +3 -3
- package/lib/ArrayFieldTemplate/ArrayFieldTemplate.js.map +1 -1
- package/lib/DescriptionField/DescriptionField.js +3 -4
- package/lib/DescriptionField/DescriptionField.js.map +1 -1
- package/lib/ErrorList/ErrorList.js +4 -4
- package/lib/ErrorList/ErrorList.js.map +1 -1
- package/lib/FieldHelpTemplate/FieldHelpTemplate.js +3 -4
- package/lib/FieldHelpTemplate/FieldHelpTemplate.js.map +1 -1
- package/lib/ObjectFieldTemplate/ObjectFieldTemplate.js +4 -4
- package/lib/ObjectFieldTemplate/ObjectFieldTemplate.js.map +1 -1
- package/lib/SubmitButton/SubmitButton.js +3 -3
- package/lib/SubmitButton/SubmitButton.js.map +1 -1
- package/lib/TitleField/TitleField.js +5 -5
- package/lib/TitleField/TitleField.js.map +1 -1
- package/lib/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.js +3 -5
- package/lib/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/util.d.ts +19 -0
- package/lib/util.js +9 -0
- package/lib/util.js.map +1 -1
- package/package.json +11 -11
- package/src/ArrayFieldItemTemplate/ArrayFieldItemTemplate.tsx +25 -9
- package/src/ArrayFieldTemplate/ArrayFieldTemplate.tsx +19 -7
- package/src/DescriptionField/DescriptionField.tsx +8 -4
- package/src/ErrorList/ErrorList.tsx +19 -9
- package/src/FieldHelpTemplate/FieldHelpTemplate.tsx +4 -5
- package/src/ObjectFieldTemplate/ObjectFieldTemplate.tsx +22 -6
- package/src/SubmitButton/SubmitButton.tsx +9 -4
- package/src/TitleField/TitleField.tsx +20 -8
- package/src/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.tsx +5 -7
- package/src/util.ts +36 -0
package/dist/index.cjs
CHANGED
|
@@ -65,6 +65,15 @@ function getMuiProps(options, propsToFilter, rjsfSlotPropsOnly) {
|
|
|
65
65
|
}
|
|
66
66
|
return muiProps;
|
|
67
67
|
}
|
|
68
|
+
function computeSxProps(sxProps, muiProps) {
|
|
69
|
+
if (!muiProps) {
|
|
70
|
+
return sxProps;
|
|
71
|
+
}
|
|
72
|
+
if (Array.isArray(muiProps?.sx)) {
|
|
73
|
+
return [sxProps, ...muiProps.sx];
|
|
74
|
+
}
|
|
75
|
+
return { ...sxProps, ...muiProps?.sx };
|
|
76
|
+
}
|
|
68
77
|
|
|
69
78
|
// src/AddButton/AddButton.tsx
|
|
70
79
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -107,19 +116,43 @@ function ArrayFieldItemTemplate(props) {
|
|
|
107
116
|
fontWeight: "bold",
|
|
108
117
|
minWidth: 0
|
|
109
118
|
};
|
|
110
|
-
const {
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
119
|
+
const {
|
|
120
|
+
rjsfSlotProps: {
|
|
121
|
+
arrayItemGridContainer,
|
|
122
|
+
arrayItemGridItem,
|
|
123
|
+
arrayItemInnerBox,
|
|
124
|
+
arrayItemOuterBox,
|
|
125
|
+
arrayItemPaper,
|
|
126
|
+
arrayItemToolbarGrid
|
|
127
|
+
} = {}
|
|
128
|
+
} = getMuiProps(uiOptions);
|
|
129
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
|
|
130
|
+
import_Grid.default,
|
|
131
|
+
{
|
|
132
|
+
container: true,
|
|
133
|
+
...arrayItemGridContainer,
|
|
134
|
+
sx: computeSxProps({ alignItems: "center" }, arrayItemGridContainer),
|
|
135
|
+
children: [
|
|
136
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
137
|
+
import_Grid.default,
|
|
138
|
+
{
|
|
139
|
+
size: { xs: 8, sm: 9, md: 10, lg: 11, xl: 11.25 },
|
|
140
|
+
...arrayItemGridItem,
|
|
141
|
+
sx: computeSxProps({ overflow: "auto" }, arrayItemGridItem),
|
|
142
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_Box.default, { ...arrayItemOuterBox, sx: computeSxProps({ mb: 2 }, arrayItemOuterBox), children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_Paper.default, { elevation: 2, ...arrayItemPaper, children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_Box.default, { ...arrayItemInnerBox, sx: computeSxProps({ p: 2 }, arrayItemInnerBox), children }) }) })
|
|
143
|
+
}
|
|
144
|
+
),
|
|
145
|
+
hasToolbar && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
146
|
+
import_Grid.default,
|
|
147
|
+
{
|
|
148
|
+
...arrayItemToolbarGrid,
|
|
149
|
+
sx: computeSxProps({ mt: hasDescription ? -5 : -1.5 }, arrayItemToolbarGrid),
|
|
150
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(ArrayFieldItemButtonsTemplate, { ...buttonsProps, style: btnStyle })
|
|
151
|
+
}
|
|
152
|
+
)
|
|
153
|
+
]
|
|
154
|
+
}
|
|
155
|
+
);
|
|
123
156
|
}
|
|
124
157
|
|
|
125
158
|
// src/ArrayFieldTemplate/ArrayFieldTemplate.tsx
|
|
@@ -158,8 +191,16 @@ function ArrayFieldTemplate(props) {
|
|
|
158
191
|
const {
|
|
159
192
|
ButtonTemplates: { AddButton: AddButton2 }
|
|
160
193
|
} = registry.templates;
|
|
161
|
-
const {
|
|
162
|
-
|
|
194
|
+
const {
|
|
195
|
+
rjsfSlotProps: {
|
|
196
|
+
arrayPaper,
|
|
197
|
+
arrayBox,
|
|
198
|
+
arrayAddButtonGridContainer,
|
|
199
|
+
arrayAddButtonGridItem,
|
|
200
|
+
arrayAddButtonBox
|
|
201
|
+
} = {}
|
|
202
|
+
} = getMuiProps(uiOptions);
|
|
203
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Paper2.default, { elevation: 2, ...arrayPaper, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_Box2.default, { ...arrayBox, sx: computeSxProps({ p: 2 }, arrayBox), children: [
|
|
163
204
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
164
205
|
ArrayFieldTitleTemplate,
|
|
165
206
|
{
|
|
@@ -184,17 +225,25 @@ function ArrayFieldTemplate(props) {
|
|
|
184
225
|
),
|
|
185
226
|
!showOptionalDataControlInTitle ? optionalDataControl : void 0,
|
|
186
227
|
items,
|
|
187
|
-
canAdd && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
188
|
-
|
|
228
|
+
canAdd && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
229
|
+
import_Grid2.default,
|
|
189
230
|
{
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
231
|
+
container: true,
|
|
232
|
+
...arrayAddButtonGridContainer,
|
|
233
|
+
sx: computeSxProps({ justifyContent: "flex-end" }, arrayAddButtonGridContainer),
|
|
234
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Grid2.default, { ...arrayAddButtonGridItem, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Box2.default, { ...arrayAddButtonBox, sx: computeSxProps({ mt: 2 }, arrayAddButtonBox), children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
235
|
+
AddButton2,
|
|
236
|
+
{
|
|
237
|
+
id: (0, import_utils3.buttonId)(fieldPathId, "add"),
|
|
238
|
+
className: "rjsf-array-item-add",
|
|
239
|
+
onClick: onAddClick,
|
|
240
|
+
disabled: disabled || readonly,
|
|
241
|
+
uiSchema,
|
|
242
|
+
registry
|
|
243
|
+
}
|
|
244
|
+
) }) })
|
|
196
245
|
}
|
|
197
|
-
)
|
|
246
|
+
)
|
|
198
247
|
] }) });
|
|
199
248
|
}
|
|
200
249
|
|
|
@@ -310,10 +359,18 @@ var import_jsx_runtime5 = require("react/jsx-runtime");
|
|
|
310
359
|
function DescriptionField(props) {
|
|
311
360
|
const { id, description, registry, uiSchema } = props;
|
|
312
361
|
const uiOptions = (0, import_utils5.getUiOptions)(uiSchema);
|
|
313
|
-
const
|
|
314
|
-
const { rjsfSlotProps: muiSlotProps } = muiProps;
|
|
362
|
+
const { rjsfSlotProps: { descTypography } = {} } = getMuiProps(uiOptions);
|
|
315
363
|
if (description) {
|
|
316
|
-
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
364
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
365
|
+
import_Typography.default,
|
|
366
|
+
{
|
|
367
|
+
id,
|
|
368
|
+
variant: "subtitle2",
|
|
369
|
+
...descTypography,
|
|
370
|
+
sx: computeSxProps({ mt: 0.625 }, descTypography),
|
|
371
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_core2.RichDescription, { description, registry, uiSchema })
|
|
372
|
+
}
|
|
373
|
+
);
|
|
317
374
|
}
|
|
318
375
|
return null;
|
|
319
376
|
}
|
|
@@ -336,13 +393,23 @@ function ErrorList({
|
|
|
336
393
|
}) {
|
|
337
394
|
const { translateString } = registry;
|
|
338
395
|
const uiOptions = (0, import_utils6.getUiOptions)(uiSchema);
|
|
339
|
-
const {
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
396
|
+
const {
|
|
397
|
+
rjsfSlotProps: {
|
|
398
|
+
errorPaper,
|
|
399
|
+
errorBox,
|
|
400
|
+
errorTypography,
|
|
401
|
+
errorList,
|
|
402
|
+
errorListItem,
|
|
403
|
+
errorListItemIcon,
|
|
404
|
+
errorListItemText
|
|
405
|
+
} = {}
|
|
406
|
+
} = getMuiProps(uiOptions);
|
|
407
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_Paper3.default, { elevation: 2, ...errorPaper, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_Box3.default, { ...errorBox, sx: computeSxProps({ mb: 2, p: 2 }, errorBox), children: [
|
|
408
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_Typography2.default, { variant: "h6", ...errorTypography, children: translateString(import_utils6.TranslatableString.ErrorsLabel) }),
|
|
409
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_List.default, { dense: true, ...errorList, children: errors.map((error, i) => {
|
|
410
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_ListItem.default, { ...errorListItem, children: [
|
|
411
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_ListItemIcon.default, { ...errorListItemIcon, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_Error.default, { color: "error" }) }),
|
|
412
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_ListItemText.default, { primary: error.stack, ...errorListItemText })
|
|
346
413
|
] }, i);
|
|
347
414
|
}) })
|
|
348
415
|
] }) });
|
|
@@ -470,15 +537,14 @@ function FieldHelpTemplate(props) {
|
|
|
470
537
|
return null;
|
|
471
538
|
}
|
|
472
539
|
const uiOptions = (0, import_utils9.getUiOptions)(uiSchema);
|
|
473
|
-
const
|
|
474
|
-
const { rjsfSlotProps: muiSlotProps } = muiProps;
|
|
540
|
+
const { rjsfSlotProps: { helpFormHelperText } = {} } = getMuiProps(uiOptions);
|
|
475
541
|
return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
|
|
476
542
|
import_FormHelperText2.default,
|
|
477
543
|
{
|
|
478
544
|
component: "div",
|
|
479
545
|
id: (0, import_utils9.helpId)(fieldPathId),
|
|
480
|
-
|
|
481
|
-
|
|
546
|
+
...helpFormHelperText,
|
|
547
|
+
sx: computeSxProps({ mt: 0.625 }, helpFormHelperText),
|
|
482
548
|
children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_core3.RichHelp, { help, registry, uiSchema })
|
|
483
549
|
}
|
|
484
550
|
);
|
|
@@ -617,7 +683,9 @@ function ObjectFieldTemplate(props) {
|
|
|
617
683
|
const {
|
|
618
684
|
ButtonTemplates: { AddButton: AddButton2 }
|
|
619
685
|
} = registry.templates;
|
|
620
|
-
const {
|
|
686
|
+
const {
|
|
687
|
+
rjsfSlotProps: { objectGridContainer, objectGridItem, objectAddButtonGridContainer, objectAddButtonGridItem } = {}
|
|
688
|
+
} = getMuiProps(uiOptions);
|
|
621
689
|
return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(import_jsx_runtime13.Fragment, { children: [
|
|
622
690
|
title && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
623
691
|
TitleFieldTemplate,
|
|
@@ -641,27 +709,53 @@ function ObjectFieldTemplate(props) {
|
|
|
641
709
|
registry
|
|
642
710
|
}
|
|
643
711
|
),
|
|
644
|
-
/* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
|
|
645
|
-
|
|
646
|
-
properties.map(
|
|
647
|
-
(element, index) => (
|
|
648
|
-
// Remove the <Grid> if the inner element is hidden as the <Grid>
|
|
649
|
-
// itself would otherwise still take up space.
|
|
650
|
-
element.hidden ? element.content : /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_Grid4.default, { size: { xs: 12 }, style: { marginBottom: "10px" }, ...muiSlotProps?.objectGridItem, children: element.content }, index)
|
|
651
|
-
)
|
|
652
|
-
)
|
|
653
|
-
] }),
|
|
654
|
-
(0, import_utils12.canExpand)(schema, uiSchema, formData) && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_Grid4.default, { container: true, justifyContent: "flex-end", ...muiSlotProps?.objectAddButtonGridContainer, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_Grid4.default, { ...muiSlotProps?.objectAddButtonGridItem, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
655
|
-
AddButton2,
|
|
712
|
+
/* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
|
|
713
|
+
import_Grid4.default,
|
|
656
714
|
{
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
715
|
+
container: true,
|
|
716
|
+
spacing: 2,
|
|
717
|
+
...objectGridContainer,
|
|
718
|
+
sx: computeSxProps({ mt: 1.25 }, objectGridContainer),
|
|
719
|
+
children: [
|
|
720
|
+
!showOptionalDataControlInTitle ? optionalDataControl : void 0,
|
|
721
|
+
properties.map(
|
|
722
|
+
(element, index) => (
|
|
723
|
+
// Remove the <Grid> if the inner element is hidden as the <Grid>
|
|
724
|
+
// itself would otherwise still take up space.
|
|
725
|
+
element.hidden ? element.content : /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
726
|
+
import_Grid4.default,
|
|
727
|
+
{
|
|
728
|
+
size: { xs: 12 },
|
|
729
|
+
...objectGridItem,
|
|
730
|
+
sx: computeSxProps({ mb: 1.25 }, objectGridItem),
|
|
731
|
+
children: element.content
|
|
732
|
+
},
|
|
733
|
+
index
|
|
734
|
+
)
|
|
735
|
+
)
|
|
736
|
+
)
|
|
737
|
+
]
|
|
663
738
|
}
|
|
664
|
-
)
|
|
739
|
+
),
|
|
740
|
+
(0, import_utils12.canExpand)(schema, uiSchema, formData) && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
741
|
+
import_Grid4.default,
|
|
742
|
+
{
|
|
743
|
+
container: true,
|
|
744
|
+
...objectAddButtonGridContainer,
|
|
745
|
+
sx: computeSxProps({ justifyContent: "flex-end" }, objectAddButtonGridContainer),
|
|
746
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_Grid4.default, { ...objectAddButtonGridItem, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
|
|
747
|
+
AddButton2,
|
|
748
|
+
{
|
|
749
|
+
id: (0, import_utils12.buttonId)(fieldPathId, "add"),
|
|
750
|
+
className: "rjsf-object-property-expand",
|
|
751
|
+
onClick: onAddProperty,
|
|
752
|
+
disabled: disabled || readonly,
|
|
753
|
+
uiSchema,
|
|
754
|
+
registry
|
|
755
|
+
}
|
|
756
|
+
) })
|
|
757
|
+
}
|
|
758
|
+
)
|
|
665
759
|
] });
|
|
666
760
|
}
|
|
667
761
|
|
|
@@ -710,8 +804,8 @@ function SubmitButton({ uiSchema }) {
|
|
|
710
804
|
return null;
|
|
711
805
|
}
|
|
712
806
|
const uiOptions = (0, import_utils13.getUiOptions)(uiSchema);
|
|
713
|
-
const { rjsfSlotProps:
|
|
714
|
-
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_Box5.default, {
|
|
807
|
+
const { rjsfSlotProps: { submitBox, submitButton } = {}, ...otherMuiProps } = getMuiProps(uiOptions);
|
|
808
|
+
return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_Box5.default, { ...submitBox, sx: computeSxProps({ mt: 3 }, submitBox), children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
|
|
715
809
|
import_Button.default,
|
|
716
810
|
{
|
|
717
811
|
type: "submit",
|
|
@@ -719,7 +813,7 @@ function SubmitButton({ uiSchema }) {
|
|
|
719
813
|
color: "primary",
|
|
720
814
|
...submitButtonProps,
|
|
721
815
|
...otherMuiProps,
|
|
722
|
-
...
|
|
816
|
+
...submitButton,
|
|
723
817
|
children: submitText
|
|
724
818
|
}
|
|
725
819
|
) });
|
|
@@ -735,17 +829,33 @@ var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
|
735
829
|
function TitleField(props) {
|
|
736
830
|
const { id, title, optionalDataControl, uiSchema } = props;
|
|
737
831
|
const uiOptions = (0, import_utils14.getUiOptions)(uiSchema);
|
|
738
|
-
const {
|
|
739
|
-
|
|
832
|
+
const {
|
|
833
|
+
rjsfSlotProps: {
|
|
834
|
+
titleBox,
|
|
835
|
+
titleDivider,
|
|
836
|
+
titleTypography,
|
|
837
|
+
titleGridContainer,
|
|
838
|
+
titleGridItem,
|
|
839
|
+
titleOptionalDataGridItem
|
|
840
|
+
} = {}
|
|
841
|
+
} = getMuiProps(uiOptions);
|
|
842
|
+
let heading = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Typography4.default, { variant: "h5", ...titleTypography, children: title });
|
|
740
843
|
if (optionalDataControl) {
|
|
741
|
-
heading = /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_Grid5.default, { container: true, spacing: 0, ...
|
|
742
|
-
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Grid5.default, { size: "grow", ...
|
|
743
|
-
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
844
|
+
heading = /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_Grid5.default, { container: true, spacing: 0, ...titleGridContainer, children: [
|
|
845
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Grid5.default, { size: "grow", ...titleGridItem, children: heading }),
|
|
846
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
847
|
+
import_Grid5.default,
|
|
848
|
+
{
|
|
849
|
+
...titleOptionalDataGridItem,
|
|
850
|
+
sx: computeSxProps({ justifyContent: "flex-end" }, titleOptionalDataGridItem),
|
|
851
|
+
children: optionalDataControl
|
|
852
|
+
}
|
|
853
|
+
)
|
|
744
854
|
] });
|
|
745
855
|
}
|
|
746
|
-
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_Box6.default, { id, mb: 1, mt: 1,
|
|
856
|
+
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_Box6.default, { id, ...titleBox, sx: computeSxProps({ mb: 1, mt: 1 }, titleBox), children: [
|
|
747
857
|
heading,
|
|
748
|
-
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Divider.default, { ...
|
|
858
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_Divider.default, { ...titleDivider })
|
|
749
859
|
] });
|
|
750
860
|
}
|
|
751
861
|
|
|
@@ -782,21 +892,19 @@ function WrapIfAdditionalTemplate(props) {
|
|
|
782
892
|
fontWeight: "bold"
|
|
783
893
|
};
|
|
784
894
|
const uiOptions = (0, import_utils15.getUiOptions)(uiSchema);
|
|
785
|
-
const { rjsfSlotProps } = getMuiProps(uiOptions);
|
|
786
|
-
const muiSlotProps = rjsfSlotProps;
|
|
895
|
+
const { rjsfSlotProps: { wrapGridContainer, wrapKeyGridItem, wrapChildrenGridItem, wrapRemoveButtonGridItem } = {} } = getMuiProps(uiOptions);
|
|
787
896
|
if (!additional) {
|
|
788
897
|
return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: classNames, style, children });
|
|
789
898
|
}
|
|
790
|
-
const { wrapGridContainer, wrapKeyGridItem, wrapChildrenGridItem, wrapRemoveButtonGridItem } = muiSlotProps || {};
|
|
791
899
|
return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
|
|
792
900
|
import_Grid6.default,
|
|
793
901
|
{
|
|
794
902
|
container: true,
|
|
795
|
-
alignItems: "flex-start",
|
|
796
903
|
spacing: 2,
|
|
797
904
|
className: classNames,
|
|
798
905
|
style,
|
|
799
906
|
...wrapGridContainer,
|
|
907
|
+
sx: computeSxProps({ alignItems: "flex-start" }, wrapGridContainer),
|
|
800
908
|
children: [
|
|
801
909
|
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_Grid6.default, { size: 5.5, ...wrapKeyGridItem, children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
802
910
|
import_TextField2.default,
|
|
@@ -814,7 +922,7 @@ function WrapIfAdditionalTemplate(props) {
|
|
|
814
922
|
label
|
|
815
923
|
) }),
|
|
816
924
|
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_Grid6.default, { size: 5.5, ...wrapChildrenGridItem, children }),
|
|
817
|
-
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_Grid6.default, { sx: { mt: 1.5 },
|
|
925
|
+
/* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_Grid6.default, { ...wrapRemoveButtonGridItem, sx: computeSxProps({ mt: 1.5 }, wrapRemoveButtonGridItem), children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
|
|
818
926
|
RemoveButton2,
|
|
819
927
|
{
|
|
820
928
|
id: (0, import_utils15.buttonId)(id, "remove"),
|