@rjsf/chakra-ui 6.6.1 → 6.6.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/chakra-ui.esm.js +147 -189
- package/dist/chakra-ui.esm.js.map +3 -3
- package/dist/chakra-ui.umd.js +135 -133
- package/dist/index.cjs +237 -234
- package/dist/index.cjs.map +3 -3
- package/lib/AddButton/AddButton.d.ts +1 -1
- package/lib/AddButton/AddButton.js.map +1 -1
- package/lib/AltDateTimeWidget/AltDateTimeWidget.d.ts +1 -1
- package/lib/AltDateWidget/AltDateWidget.d.ts +1 -1
- package/lib/AltDateWidget/AltDateWidget.js +1 -1
- package/lib/AltDateWidget/AltDateWidget.js.map +1 -1
- package/lib/ArrayFieldItemTemplate/ArrayFieldItemTemplate.d.ts +1 -1
- package/lib/ArrayFieldItemTemplate/ArrayFieldItemTemplate.js +1 -1
- package/lib/ArrayFieldItemTemplate/ArrayFieldItemTemplate.js.map +1 -1
- package/lib/ArrayFieldTemplate/ArrayFieldTemplate.d.ts +1 -1
- package/lib/ArrayFieldTemplate/ArrayFieldTemplate.js +1 -1
- package/lib/ArrayFieldTemplate/ArrayFieldTemplate.js.map +1 -1
- package/lib/BaseInputTemplate/BaseInputTemplate.d.ts +1 -1
- package/lib/BaseInputTemplate/BaseInputTemplate.js +5 -5
- package/lib/BaseInputTemplate/BaseInputTemplate.js.map +1 -1
- package/lib/ChakraFrameProvider.js +1 -3
- package/lib/ChakraFrameProvider.js.map +1 -1
- package/lib/CheckboxWidget/CheckboxWidget.d.ts +1 -1
- package/lib/CheckboxWidget/CheckboxWidget.js +4 -4
- package/lib/CheckboxWidget/CheckboxWidget.js.map +1 -1
- package/lib/CheckboxesWidget/CheckboxesWidget.d.ts +1 -1
- package/lib/CheckboxesWidget/CheckboxesWidget.js +4 -4
- package/lib/CheckboxesWidget/CheckboxesWidget.js.map +1 -1
- package/lib/DescriptionField/DescriptionField.d.ts +1 -1
- package/lib/ErrorList/ErrorList.d.ts +1 -1
- package/lib/ErrorList/ErrorList.js.map +1 -1
- package/lib/FieldErrorTemplate/FieldErrorTemplate.d.ts +1 -1
- package/lib/FieldErrorTemplate/FieldErrorTemplate.js +1 -3
- package/lib/FieldErrorTemplate/FieldErrorTemplate.js.map +1 -1
- package/lib/FieldHelpTemplate/FieldHelpTemplate.d.ts +1 -1
- package/lib/FieldHelpTemplate/FieldHelpTemplate.js.map +1 -1
- package/lib/FieldTemplate/FieldTemplate.d.ts +1 -1
- package/lib/FieldTemplate/FieldTemplate.js +1 -1
- package/lib/FieldTemplate/FieldTemplate.js.map +1 -1
- package/lib/Form/Form.d.ts +3 -3
- package/lib/Form/Form.js.map +1 -1
- package/lib/GridTemplate/GridTemplate.d.ts +1 -1
- package/lib/IconButton/ChakraIconButton.d.ts +2 -2
- package/lib/IconButton/ChakraIconButton.js.map +1 -1
- package/lib/IconButton/IconButton.d.ts +13 -7
- package/lib/IconButton/IconButton.js +11 -5
- package/lib/IconButton/IconButton.js.map +1 -1
- package/lib/MultiSchemaFieldTemplate/MultiSchemaFieldTemplate.d.ts +1 -1
- package/lib/NativeSelectWidget/NativeSelectWidget.d.ts +1 -1
- package/lib/NativeSelectWidget/NativeSelectWidget.js +13 -15
- package/lib/NativeSelectWidget/NativeSelectWidget.js.map +1 -1
- package/lib/ObjectFieldTemplate/ObjectFieldTemplate.d.ts +1 -1
- package/lib/ObjectFieldTemplate/ObjectFieldTemplate.js +2 -2
- package/lib/ObjectFieldTemplate/ObjectFieldTemplate.js.map +1 -1
- package/lib/OptionalDataControlsTemplate/OptionalDataControlsTemplate.d.ts +1 -1
- package/lib/OptionalDataControlsTemplate/OptionalDataControlsTemplate.js +1 -1
- package/lib/OptionalDataControlsTemplate/OptionalDataControlsTemplate.js.map +1 -1
- package/lib/RadioWidget/RadioWidget.d.ts +1 -1
- package/lib/RadioWidget/RadioWidget.js +6 -6
- package/lib/RadioWidget/RadioWidget.js.map +1 -1
- package/lib/RangeWidget/RangeWidget.d.ts +1 -1
- package/lib/RangeWidget/RangeWidget.js +5 -5
- package/lib/RangeWidget/RangeWidget.js.map +1 -1
- package/lib/SelectWidget/SelectWidget.d.ts +1 -1
- package/lib/SelectWidget/SelectWidget.js +15 -17
- package/lib/SelectWidget/SelectWidget.js.map +1 -1
- package/lib/SubmitButton/SubmitButton.d.ts +1 -1
- package/lib/SubmitButton/SubmitButton.js.map +1 -1
- package/lib/Templates/Templates.d.ts +1 -1
- package/lib/TextareaWidget/TextareaWidget.d.ts +1 -1
- package/lib/TextareaWidget/TextareaWidget.js +5 -5
- package/lib/TextareaWidget/TextareaWidget.js.map +1 -1
- package/lib/Theme/Theme.d.ts +2 -2
- package/lib/TitleField/TitleField.d.ts +1 -1
- package/lib/UpDownWidget/UpDownWidget.d.ts +1 -1
- package/lib/UpDownWidget/UpDownWidget.js +5 -5
- package/lib/UpDownWidget/UpDownWidget.js.map +1 -1
- package/lib/Widgets/Widgets.d.ts +1 -1
- package/lib/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.d.ts +1 -1
- package/lib/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.js +1 -1
- package/lib/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.js.map +1 -1
- package/lib/components/ui/alert.d.ts +1 -1
- package/lib/components/ui/alert.js +1 -1
- package/lib/components/ui/alert.js.map +1 -1
- package/lib/components/ui/checkbox.d.ts +1 -1
- package/lib/components/ui/checkbox.js +1 -1
- package/lib/components/ui/checkbox.js.map +1 -1
- package/lib/components/ui/close-button.js +1 -1
- package/lib/components/ui/close-button.js.map +1 -1
- package/lib/components/ui/field.d.ts +1 -1
- package/lib/components/ui/field.js +1 -1
- package/lib/components/ui/field.js.map +1 -1
- package/lib/components/ui/number-input.js +1 -1
- package/lib/components/ui/number-input.js.map +1 -1
- package/lib/components/ui/radio.d.ts +1 -1
- package/lib/components/ui/radio.js +1 -1
- package/lib/components/ui/radio.js.map +1 -1
- package/lib/components/ui/select.d.ts +1 -1
- package/lib/components/ui/select.js +13 -17
- package/lib/components/ui/select.js.map +1 -1
- package/lib/components/ui/slider.d.ts +2 -2
- package/lib/components/ui/slider.js +19 -19
- package/lib/components/ui/slider.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/utils.d.ts +2 -2
- package/lib/utils.js.map +1 -1
- package/package.json +6 -7
- package/src/AddButton/AddButton.tsx +2 -1
- package/src/AltDateTimeWidget/AltDateTimeWidget.tsx +1 -1
- package/src/AltDateWidget/AltDateWidget.tsx +2 -10
- package/src/ArrayFieldItemTemplate/ArrayFieldItemTemplate.tsx +3 -9
- package/src/ArrayFieldTemplate/ArrayFieldTemplate.tsx +2 -9
- package/src/BaseInputTemplate/BaseInputTemplate.tsx +11 -18
- package/src/ChakraFrameProvider.tsx +7 -9
- package/src/CheckboxWidget/CheckboxWidget.tsx +10 -12
- package/src/CheckboxesWidget/CheckboxesWidget.tsx +8 -11
- package/src/DescriptionField/DescriptionField.tsx +1 -1
- package/src/ErrorList/ErrorList.tsx +3 -1
- package/src/FieldErrorTemplate/FieldErrorTemplate.tsx +8 -8
- package/src/FieldHelpTemplate/FieldHelpTemplate.tsx +2 -1
- package/src/FieldTemplate/FieldTemplate.tsx +2 -8
- package/src/Form/Form.tsx +4 -3
- package/src/GridTemplate/GridTemplate.tsx +1 -1
- package/src/IconButton/ChakraIconButton.tsx +9 -3
- package/src/IconButton/IconButton.tsx +15 -7
- package/src/MultiSchemaFieldTemplate/MultiSchemaFieldTemplate.tsx +1 -1
- package/src/NativeSelectWidget/NativeSelectWidget.tsx +20 -29
- package/src/ObjectFieldTemplate/ObjectFieldTemplate.tsx +4 -18
- package/src/OptionalDataControlsTemplate/OptionalDataControlsTemplate.tsx +3 -2
- package/src/RadioWidget/RadioWidget.tsx +13 -16
- package/src/RangeWidget/RangeWidget.tsx +11 -18
- package/src/SelectWidget/SelectWidget.tsx +24 -27
- package/src/SubmitButton/SubmitButton.tsx +2 -1
- package/src/Templates/Templates.ts +1 -1
- package/src/TextareaWidget/TextareaWidget.tsx +10 -16
- package/src/Theme/Theme.tsx +2 -2
- package/src/TitleField/TitleField.tsx +1 -1
- package/src/UpDownWidget/UpDownWidget.tsx +10 -16
- package/src/Widgets/Widgets.ts +1 -1
- package/src/WrapIfAdditionalTemplate/WrapIfAdditionalTemplate.tsx +2 -9
- package/src/components/ui/alert.tsx +3 -2
- package/src/components/ui/checkbox.tsx +3 -2
- package/src/components/ui/close-button.tsx +5 -7
- package/src/components/ui/field.tsx +3 -2
- package/src/components/ui/number-input.tsx +1 -1
- package/src/components/ui/radio.tsx +3 -2
- package/src/components/ui/select.tsx +31 -36
- package/src/components/ui/slider.tsx +37 -35
- package/src/utils.ts +3 -2
package/dist/chakra-ui.umd.js
CHANGED
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
] }, `array-item-list-${fieldPathId.$id}`)
|
|
101
101
|
] });
|
|
102
102
|
}
|
|
103
|
-
var Field = react.forwardRef(
|
|
103
|
+
var Field = react.forwardRef((props, ref) => {
|
|
104
104
|
const { label, children, helperText, errorText, optionalText, ...rest } = props;
|
|
105
105
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Field.Root, { ref, ...rest, children: [
|
|
106
106
|
label && /* @__PURE__ */ jsxRuntime.jsxs(react$1.Field.Label, { children: [
|
|
@@ -147,9 +147,9 @@
|
|
|
147
147
|
} = props;
|
|
148
148
|
const inputProps = utils.getInputProps(schema, type, options);
|
|
149
149
|
const { ClearButton: ClearButton2 } = registry.templates.ButtonTemplates;
|
|
150
|
-
const
|
|
151
|
-
const
|
|
152
|
-
const
|
|
150
|
+
const handleChange = ({ target: { value: newValue } }) => onChange(newValue === "" ? options.emptyValue : newValue);
|
|
151
|
+
const handleBlur = ({ target }) => onBlur(id, target && target.value);
|
|
152
|
+
const handleFocus = ({ target }) => onFocus(id, target && target.value);
|
|
153
153
|
const onClear = react.useCallback(
|
|
154
154
|
(e) => {
|
|
155
155
|
e.preventDefault();
|
|
@@ -176,9 +176,9 @@
|
|
|
176
176
|
id,
|
|
177
177
|
name: htmlName || id,
|
|
178
178
|
value: value || value === 0 ? value : "",
|
|
179
|
-
onChange: onChangeOverride ||
|
|
180
|
-
onBlur:
|
|
181
|
-
onFocus:
|
|
179
|
+
onChange: onChangeOverride || handleChange,
|
|
180
|
+
onBlur: handleBlur,
|
|
181
|
+
onFocus: handleFocus,
|
|
182
182
|
autoFocus: autofocus,
|
|
183
183
|
placeholder,
|
|
184
184
|
...inputProps,
|
|
@@ -198,10 +198,8 @@
|
|
|
198
198
|
}
|
|
199
199
|
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { as: "sup", fontSize: "md", id, children: /* @__PURE__ */ jsxRuntime.jsx(core.RichDescription, { description, registry, uiSchema }) });
|
|
200
200
|
}
|
|
201
|
-
var CloseButton = react.forwardRef(
|
|
202
|
-
|
|
203
|
-
});
|
|
204
|
-
var Alert = react.forwardRef(function Alert2(props, ref) {
|
|
201
|
+
var CloseButton = react.forwardRef((props, ref) => /* @__PURE__ */ jsxRuntime.jsx(react$1.IconButton, { variant: "ghost", "aria-label": "Close", ref, ...props, children: props.children ?? /* @__PURE__ */ jsxRuntime.jsx(lu.LuX, {}) }));
|
|
202
|
+
var Alert = react.forwardRef((props, ref) => {
|
|
205
203
|
const { title, children, closable, onClose, startElement, endElement, ...rest } = props;
|
|
206
204
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Alert.Root, { ref, ...rest, children: [
|
|
207
205
|
startElement || /* @__PURE__ */ jsxRuntime.jsx(react$1.Alert.Indicator, {}),
|
|
@@ -218,7 +216,10 @@
|
|
|
218
216
|
registry
|
|
219
217
|
}) {
|
|
220
218
|
const { translateString } = registry;
|
|
221
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Alert, { status: "error", title: translateString(utils.TranslatableString.ErrorsLabel), mb: 3, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.ListRoot, { listStylePosition: "inside", children: errors.map((error, i) =>
|
|
219
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Alert, { status: "error", title: translateString(utils.TranslatableString.ErrorsLabel), mb: 3, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.ListRoot, { listStylePosition: "inside", children: errors.map((error, i) => (
|
|
220
|
+
// oxlint-disable-next-line react/no-array-index-key
|
|
221
|
+
/* @__PURE__ */ jsxRuntime.jsx(react$1.ListItem, { children: error.stack }, i)
|
|
222
|
+
)) }) });
|
|
222
223
|
}
|
|
223
224
|
function FieldErrorTemplate(props) {
|
|
224
225
|
const { errors = [], fieldPathId } = props;
|
|
@@ -226,9 +227,10 @@
|
|
|
226
227
|
return null;
|
|
227
228
|
}
|
|
228
229
|
const id = utils.errorId(fieldPathId);
|
|
229
|
-
return errors.map((error, i) =>
|
|
230
|
-
|
|
231
|
-
|
|
230
|
+
return errors.map((error, i) => (
|
|
231
|
+
// oxlint-disable-next-line react/no-array-index-key
|
|
232
|
+
/* @__PURE__ */ jsxRuntime.jsx(react$1.Fieldset.ErrorText, { mt: 0, id, children: error }, i)
|
|
233
|
+
));
|
|
232
234
|
}
|
|
233
235
|
function FieldHelpTemplate(props) {
|
|
234
236
|
const { fieldPathId, help, uiSchema, registry } = props;
|
|
@@ -310,13 +312,14 @@
|
|
|
310
312
|
}
|
|
311
313
|
ChakraIconButton2.displayName = "ChakraIconButton";
|
|
312
314
|
var ChakraIconButton_default = react.memo(ChakraIconButton2);
|
|
313
|
-
function
|
|
315
|
+
function CopyButtonFn(props) {
|
|
314
316
|
const {
|
|
315
317
|
registry: { translateString }
|
|
316
318
|
} = props;
|
|
317
319
|
return /* @__PURE__ */ jsxRuntime.jsx(ChakraIconButton_default, { title: translateString(utils.TranslatableString.CopyButton), ...props, icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CopyIcon, {}) });
|
|
318
320
|
}
|
|
319
|
-
|
|
321
|
+
var CopyButton = react.memo(CopyButtonFn);
|
|
322
|
+
function MoveDownButtonFn(props) {
|
|
320
323
|
const {
|
|
321
324
|
registry: { translateString }
|
|
322
325
|
} = props;
|
|
@@ -329,7 +332,8 @@
|
|
|
329
332
|
}
|
|
330
333
|
);
|
|
331
334
|
}
|
|
332
|
-
|
|
335
|
+
var MoveDownButton = react.memo(MoveDownButtonFn);
|
|
336
|
+
function MoveUpButtonFn(props) {
|
|
333
337
|
const {
|
|
334
338
|
registry: { translateString }
|
|
335
339
|
} = props;
|
|
@@ -342,7 +346,8 @@
|
|
|
342
346
|
}
|
|
343
347
|
);
|
|
344
348
|
}
|
|
345
|
-
|
|
349
|
+
var MoveUpButton = react.memo(MoveUpButtonFn);
|
|
350
|
+
function RemoveButtonFn(props) {
|
|
346
351
|
const {
|
|
347
352
|
registry: { translateString }
|
|
348
353
|
} = props;
|
|
@@ -355,12 +360,14 @@
|
|
|
355
360
|
}
|
|
356
361
|
);
|
|
357
362
|
}
|
|
358
|
-
|
|
363
|
+
var RemoveButton = react.memo(RemoveButtonFn);
|
|
364
|
+
function ClearButtonFn(props) {
|
|
359
365
|
const {
|
|
360
366
|
registry: { translateString }
|
|
361
367
|
} = props;
|
|
362
368
|
return /* @__PURE__ */ jsxRuntime.jsx(ChakraIconButton_default, { title: translateString(utils.TranslatableString.ClearButton), ...props, icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, {}) });
|
|
363
369
|
}
|
|
370
|
+
var ClearButton = react.memo(ClearButtonFn);
|
|
364
371
|
function MultiSchemaFieldTemplate(props) {
|
|
365
372
|
const { optionSchemaField, selector } = props;
|
|
366
373
|
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Card.Root, { mb: 2, children: /* @__PURE__ */ jsxRuntime.jsxs(react$1.Card.Body, { pb: 2, children: [
|
|
@@ -421,7 +428,7 @@
|
|
|
421
428
|
/* @__PURE__ */ jsxRuntime.jsxs(react$1.Grid, { gap: description ? 2 : 4, mb: 4, children: [
|
|
422
429
|
!showOptionalDataControlInTitle ? /* @__PURE__ */ jsxRuntime.jsx(react$1.GridItem, { children: optionalDataControl }) : void 0,
|
|
423
430
|
properties.map(
|
|
424
|
-
(element
|
|
431
|
+
(element) => element.hidden ? element.content : /* @__PURE__ */ jsxRuntime.jsx(react$1.GridItem, { children: element.content }, element.name)
|
|
425
432
|
),
|
|
426
433
|
utils.canExpand(schema, uiSchema, formData) && /* @__PURE__ */ jsxRuntime.jsx(react$1.GridItem, { justifySelf: "flex-end", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
427
434
|
AddButton2,
|
|
@@ -453,7 +460,8 @@
|
|
|
453
460
|
variant: "subtle"
|
|
454
461
|
}
|
|
455
462
|
);
|
|
456
|
-
}
|
|
463
|
+
}
|
|
464
|
+
if (onRemoveClick) {
|
|
457
465
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
458
466
|
RemoveButton,
|
|
459
467
|
{
|
|
@@ -642,7 +650,7 @@
|
|
|
642
650
|
] });
|
|
643
651
|
}
|
|
644
652
|
var AltDateWidget_default = AltDateWidget;
|
|
645
|
-
var Checkbox = react.forwardRef(
|
|
653
|
+
var Checkbox = react.forwardRef((props, ref) => {
|
|
646
654
|
const { icon, children, inputProps, rootRef, ...rest } = props;
|
|
647
655
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Checkbox.Root, { ref: rootRef, ...rest, children: [
|
|
648
656
|
/* @__PURE__ */ jsxRuntime.jsx(react$1.Checkbox.HiddenInput, { ref, ...inputProps }),
|
|
@@ -669,8 +677,8 @@
|
|
|
669
677
|
} = props;
|
|
670
678
|
const { enumOptions, enumDisabled, emptyValue } = options;
|
|
671
679
|
const optionValueFormat = utils.getOptionValueFormat(options);
|
|
672
|
-
const
|
|
673
|
-
const
|
|
680
|
+
const handleBlur = ({ target }) => onBlur(id, utils.enumOptionValueDecoder(target && target.value, enumOptions, optionValueFormat, emptyValue));
|
|
681
|
+
const handleFocus = ({ target }) => onFocus(id, utils.enumOptionValueDecoder(target && target.value, enumOptions, optionValueFormat, emptyValue));
|
|
674
682
|
const row = options ? options.inline : false;
|
|
675
683
|
const selectValue = utils.enumOptionSelectedValue(value, enumOptions, true, optionValueFormat, []);
|
|
676
684
|
const chakraProps = getChakra({ });
|
|
@@ -692,7 +700,7 @@
|
|
|
692
700
|
readOnly: readonly,
|
|
693
701
|
invalid: required && value.length === 0,
|
|
694
702
|
children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Stack, { direction: row ? "row" : "column", children: Array.isArray(enumOptions) && enumOptions.map((option, index) => {
|
|
695
|
-
const itemDisabled = Array.isArray(enumDisabled) && enumDisabled.
|
|
703
|
+
const itemDisabled = Array.isArray(enumDisabled) && enumDisabled.includes(option.value);
|
|
696
704
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
697
705
|
Checkbox,
|
|
698
706
|
{
|
|
@@ -700,11 +708,11 @@
|
|
|
700
708
|
name: htmlName || id,
|
|
701
709
|
value: utils.enumOptionValueEncoder(option.value, index, optionValueFormat),
|
|
702
710
|
disabled: disabled || itemDisabled || readonly,
|
|
703
|
-
onBlur:
|
|
704
|
-
onFocus:
|
|
711
|
+
onBlur: handleBlur,
|
|
712
|
+
onFocus: handleFocus,
|
|
705
713
|
children: option.label && /* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { children: option.label })
|
|
706
714
|
},
|
|
707
|
-
|
|
715
|
+
String(option.value)
|
|
708
716
|
);
|
|
709
717
|
}) })
|
|
710
718
|
}
|
|
@@ -739,9 +747,9 @@
|
|
|
739
747
|
const uiOptions = utils.getUiOptions(uiSchema);
|
|
740
748
|
const isCheckbox = uiOptions.widget === "checkbox";
|
|
741
749
|
const description = isCheckbox ? void 0 : options.description ?? schema.description;
|
|
742
|
-
const
|
|
743
|
-
const
|
|
744
|
-
const
|
|
750
|
+
const handleChange = ({ checked }) => onChange(checked);
|
|
751
|
+
const handleBlur = ({ target }) => onBlur(id, target && target.checked);
|
|
752
|
+
const handleFocus = ({ target }) => onFocus(id, target && target.checked);
|
|
745
753
|
const chakraProps = getChakra({ });
|
|
746
754
|
return /* @__PURE__ */ jsxRuntime.jsxs(Field, { mb: 1, required, ...chakraProps, children: [
|
|
747
755
|
!hideLabel && description && /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -761,9 +769,9 @@
|
|
|
761
769
|
name: htmlName || id,
|
|
762
770
|
checked: typeof value === "undefined" ? false : value,
|
|
763
771
|
disabled: disabled || readonly,
|
|
764
|
-
onCheckedChange:
|
|
765
|
-
onBlur:
|
|
766
|
-
onFocus:
|
|
772
|
+
onCheckedChange: handleChange,
|
|
773
|
+
onBlur: handleBlur,
|
|
774
|
+
onFocus: handleFocus,
|
|
767
775
|
"aria-describedby": utils.ariaDescribedByIds(id),
|
|
768
776
|
children: utils.labelValue(/* @__PURE__ */ jsxRuntime.jsx(react$1.Text, { children: label }), hideLabel || !label)
|
|
769
777
|
}
|
|
@@ -791,27 +799,25 @@
|
|
|
791
799
|
uiSchema
|
|
792
800
|
} = props;
|
|
793
801
|
const { enumOptions, enumDisabled, emptyValue } = options;
|
|
794
|
-
const
|
|
795
|
-
|
|
796
|
-
};
|
|
797
|
-
const _onBlur = ({ target }) => onBlur(id, utils.enumOptionsValueForIndex(target && target.value, enumOptions, emptyValue));
|
|
798
|
-
const _onFocus = ({ target }) => onFocus(id, utils.enumOptionsValueForIndex(target && target.value, enumOptions, emptyValue));
|
|
802
|
+
const handleChange = ({ target }) => onChange(utils.enumOptionsValueForIndex(target && target.value, enumOptions, emptyValue));
|
|
803
|
+
const handleBlur = ({ target }) => onBlur(id, utils.enumOptionsValueForIndex(target && target.value, enumOptions, emptyValue));
|
|
804
|
+
const handleFocus = ({ target }) => onFocus(id, utils.enumOptionsValueForIndex(target && target.value, enumOptions, emptyValue));
|
|
799
805
|
const showPlaceholderOption = !multiple && schema.default === void 0;
|
|
800
806
|
const { valueLabelMap, displayEnumOptions } = react.useMemo(() => {
|
|
801
|
-
const
|
|
802
|
-
let
|
|
807
|
+
const computedValueLabelMap = {};
|
|
808
|
+
let computedOptions = [];
|
|
803
809
|
if (Array.isArray(enumOptions)) {
|
|
804
|
-
|
|
805
|
-
const { value:
|
|
806
|
-
|
|
810
|
+
computedOptions = enumOptions.map((option, index) => {
|
|
811
|
+
const { value: enumValue, label: enumLabel } = option;
|
|
812
|
+
computedValueLabelMap[index] = enumLabel || String(enumValue);
|
|
807
813
|
return {
|
|
808
|
-
label:
|
|
814
|
+
label: enumLabel,
|
|
809
815
|
value: String(index),
|
|
810
|
-
disabled: Array.isArray(enumDisabled) && enumDisabled.
|
|
816
|
+
disabled: Array.isArray(enumDisabled) && enumDisabled.includes(enumValue)
|
|
811
817
|
};
|
|
812
818
|
});
|
|
813
819
|
}
|
|
814
|
-
return { valueLabelMap:
|
|
820
|
+
return { valueLabelMap: computedValueLabelMap, displayEnumOptions: computedOptions };
|
|
815
821
|
}, [enumDisabled, enumOptions]);
|
|
816
822
|
const selectedIndex = utils.enumOptionsIndexForValue(value, enumOptions, false);
|
|
817
823
|
const getSingleValue = () => typeof selectedIndex !== "undefined" ? [
|
|
@@ -840,9 +846,9 @@
|
|
|
840
846
|
react$1.NativeSelect.Field,
|
|
841
847
|
{
|
|
842
848
|
id,
|
|
843
|
-
onBlur:
|
|
844
|
-
onChange:
|
|
845
|
-
onFocus:
|
|
849
|
+
onBlur: handleBlur,
|
|
850
|
+
onChange: handleChange,
|
|
851
|
+
onFocus: handleFocus,
|
|
846
852
|
autoFocus: autofocus,
|
|
847
853
|
value: formValue,
|
|
848
854
|
"aria-describedby": utils.ariaDescribedByIds(id),
|
|
@@ -857,7 +863,7 @@
|
|
|
857
863
|
}
|
|
858
864
|
);
|
|
859
865
|
}
|
|
860
|
-
var Radio = react.forwardRef(
|
|
866
|
+
var Radio = react.forwardRef((props, ref) => {
|
|
861
867
|
const { children, inputProps, rootRef, ...rest } = props;
|
|
862
868
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.RadioGroup.Item, { ref: rootRef, ...rest, children: [
|
|
863
869
|
/* @__PURE__ */ jsxRuntime.jsx(react$1.RadioGroup.ItemHiddenInput, { ref, ...inputProps }),
|
|
@@ -883,9 +889,9 @@
|
|
|
883
889
|
}) {
|
|
884
890
|
const { enumOptions, enumDisabled, emptyValue } = options;
|
|
885
891
|
const optionValueFormat = utils.getOptionValueFormat(options);
|
|
886
|
-
const
|
|
887
|
-
const
|
|
888
|
-
const
|
|
892
|
+
const handleChange = ({ target: { value: enumValue } }) => onChange(utils.enumOptionValueDecoder(enumValue, enumOptions, optionValueFormat, emptyValue));
|
|
893
|
+
const handleBlur = ({ target: { value: enumValue } }) => onBlur(id, utils.enumOptionValueDecoder(enumValue, enumOptions, optionValueFormat, emptyValue));
|
|
894
|
+
const handleFocus = ({ target: { value: enumValue } }) => onFocus(id, utils.enumOptionValueDecoder(enumValue, enumOptions, optionValueFormat, emptyValue));
|
|
889
895
|
const row = options ? options.inline : false;
|
|
890
896
|
const selectValue = utils.enumOptionSelectedValue(value, enumOptions, false, optionValueFormat, null);
|
|
891
897
|
const chakraProps = getChakra({ });
|
|
@@ -901,14 +907,14 @@
|
|
|
901
907
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
902
908
|
RadioGroup,
|
|
903
909
|
{
|
|
904
|
-
onChange:
|
|
905
|
-
onBlur:
|
|
906
|
-
onFocus:
|
|
910
|
+
onChange: handleChange,
|
|
911
|
+
onBlur: handleBlur,
|
|
912
|
+
onFocus: handleFocus,
|
|
907
913
|
value: selectValue,
|
|
908
914
|
name: htmlName || id,
|
|
909
915
|
"aria-describedby": utils.ariaDescribedByIds(id),
|
|
910
916
|
children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Stack, { direction: row ? "row" : "column", children: Array.isArray(enumOptions) && enumOptions.map((option, index) => {
|
|
911
|
-
const itemDisabled = Array.isArray(enumDisabled) && enumDisabled.
|
|
917
|
+
const itemDisabled = Array.isArray(enumDisabled) && enumDisabled.includes(option.value);
|
|
912
918
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
913
919
|
Radio,
|
|
914
920
|
{
|
|
@@ -917,7 +923,7 @@
|
|
|
917
923
|
disabled: disabled || itemDisabled || readonly,
|
|
918
924
|
children: option.label
|
|
919
925
|
},
|
|
920
|
-
|
|
926
|
+
String(option.value)
|
|
921
927
|
);
|
|
922
928
|
}) })
|
|
923
929
|
}
|
|
@@ -925,7 +931,24 @@
|
|
|
925
931
|
}
|
|
926
932
|
);
|
|
927
933
|
}
|
|
928
|
-
var
|
|
934
|
+
var SliderMarks = react.forwardRef((props, ref) => {
|
|
935
|
+
const { marks } = props;
|
|
936
|
+
if (!marks?.length) {
|
|
937
|
+
return null;
|
|
938
|
+
}
|
|
939
|
+
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Slider.MarkerGroup, { ref, children: marks.map((mark, index) => {
|
|
940
|
+
const value = typeof mark === "number" ? mark : mark.value;
|
|
941
|
+
const label = typeof mark === "number" ? void 0 : mark.label;
|
|
942
|
+
return (
|
|
943
|
+
// oxlint-disable-next-line react/no-array-index-key
|
|
944
|
+
/* @__PURE__ */ jsxRuntime.jsxs(react$1.Slider.Marker, { value, children: [
|
|
945
|
+
/* @__PURE__ */ jsxRuntime.jsx(react$1.Slider.MarkerIndicator, {}),
|
|
946
|
+
label
|
|
947
|
+
] }, index)
|
|
948
|
+
);
|
|
949
|
+
}) });
|
|
950
|
+
});
|
|
951
|
+
var Slider = react.forwardRef((props, ref) => {
|
|
929
952
|
const { marks: marksProp, showValue, ...rest } = props;
|
|
930
953
|
const value = props.defaultValue ?? props.value;
|
|
931
954
|
const marks = marksProp?.map((mark) => {
|
|
@@ -946,22 +969,11 @@
|
|
|
946
969
|
});
|
|
947
970
|
function SliderThumbs(props) {
|
|
948
971
|
const { value } = props;
|
|
949
|
-
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: value?.map((_, index) =>
|
|
972
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: value?.map((_, index) => (
|
|
973
|
+
// oxlint-disable-next-line react/no-array-index-key
|
|
974
|
+
/* @__PURE__ */ jsxRuntime.jsx(react$1.Slider.Thumb, { index, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Slider.HiddenInput, {}) }, index)
|
|
975
|
+
)) });
|
|
950
976
|
}
|
|
951
|
-
var SliderMarks = react.forwardRef(function SliderMarks2(props, ref) {
|
|
952
|
-
const { marks } = props;
|
|
953
|
-
if (!marks?.length) {
|
|
954
|
-
return null;
|
|
955
|
-
}
|
|
956
|
-
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Slider.MarkerGroup, { ref, children: marks.map((mark, index) => {
|
|
957
|
-
const value = typeof mark === "number" ? mark : mark.value;
|
|
958
|
-
const label = typeof mark === "number" ? void 0 : mark.label;
|
|
959
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Slider.Marker, { value, children: [
|
|
960
|
-
/* @__PURE__ */ jsxRuntime.jsx(react$1.Slider.MarkerIndicator, {}),
|
|
961
|
-
label
|
|
962
|
-
] }, index);
|
|
963
|
-
}) });
|
|
964
|
-
});
|
|
965
977
|
function RangeWidget({
|
|
966
978
|
value,
|
|
967
979
|
readonly,
|
|
@@ -976,9 +988,9 @@
|
|
|
976
988
|
id,
|
|
977
989
|
uiSchema
|
|
978
990
|
}) {
|
|
979
|
-
const
|
|
980
|
-
const
|
|
981
|
-
const
|
|
991
|
+
const handleChange = ({ value: newValue }) => onChange(newValue === void 0 ? options.emptyValue : newValue[0]);
|
|
992
|
+
const handleBlur = ({ target }) => onBlur(id, target && target.value);
|
|
993
|
+
const handleFocus = ({ target }) => onFocus(id, target && target.value);
|
|
982
994
|
const chakraProps = getChakra({ });
|
|
983
995
|
return /* @__PURE__ */ jsxRuntime.jsx(Field, { mb: 1, label: utils.labelValue(label, hideLabel || !label), ...chakraProps, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
984
996
|
Slider,
|
|
@@ -988,14 +1000,15 @@
|
|
|
988
1000
|
name: id,
|
|
989
1001
|
disabled: disabled || readonly,
|
|
990
1002
|
value: [value],
|
|
991
|
-
onValueChange:
|
|
992
|
-
onBlur:
|
|
993
|
-
onFocus:
|
|
1003
|
+
onValueChange: handleChange,
|
|
1004
|
+
onBlur: handleBlur,
|
|
1005
|
+
onFocus: handleFocus,
|
|
994
1006
|
"aria-describedby": utils.ariaDescribedByIds(id)
|
|
995
1007
|
}
|
|
996
1008
|
) });
|
|
997
1009
|
}
|
|
998
|
-
var
|
|
1010
|
+
var SelectClearTrigger = react.forwardRef((props, ref) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.ClearTrigger, { asChild: true, ...props, ref, children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { size: "xs", variant: "plain", focusVisibleRing: "inside", focusRingWidth: "2px", pointerEvents: "auto" }) }));
|
|
1011
|
+
var SelectTrigger = react.forwardRef((props, ref) => {
|
|
999
1012
|
const { children, clearable, ...rest } = props;
|
|
1000
1013
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Select.Control, { ...rest, children: [
|
|
1001
1014
|
/* @__PURE__ */ jsxRuntime.jsx(react$1.Select.Trigger, { ref, children }),
|
|
@@ -1005,23 +1018,18 @@
|
|
|
1005
1018
|
] })
|
|
1006
1019
|
] });
|
|
1007
1020
|
});
|
|
1008
|
-
|
|
1009
|
-
function SelectClearTrigger2(props, ref) {
|
|
1010
|
-
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.ClearTrigger, { asChild: true, ...props, ref, children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { size: "xs", variant: "plain", focusVisibleRing: "inside", focusRingWidth: "2px", pointerEvents: "auto" }) });
|
|
1011
|
-
}
|
|
1012
|
-
);
|
|
1013
|
-
react.forwardRef(function SelectContent2(props, ref) {
|
|
1021
|
+
react.forwardRef((props, ref) => {
|
|
1014
1022
|
const { portalled = true, portalRef, ...rest } = props;
|
|
1015
1023
|
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Portal, { disabled: !portalled, container: portalRef, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.Positioner, { children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.Content, { ...rest, ref }) }) });
|
|
1016
1024
|
});
|
|
1017
|
-
react.forwardRef(
|
|
1025
|
+
react.forwardRef((props, ref) => {
|
|
1018
1026
|
const { item, children, ...rest } = props;
|
|
1019
1027
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Select.Item, { item, ...rest, ref, children: [
|
|
1020
1028
|
children,
|
|
1021
1029
|
/* @__PURE__ */ jsxRuntime.jsx(react$1.Select.ItemIndicator, {})
|
|
1022
1030
|
] }, item.value);
|
|
1023
1031
|
});
|
|
1024
|
-
var SelectValueText = react.forwardRef(
|
|
1032
|
+
var SelectValueText = react.forwardRef((props, ref) => {
|
|
1025
1033
|
const { children, ...rest } = props;
|
|
1026
1034
|
return /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.ValueText, { ...rest, ref, children: /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.Context, { children: (select) => {
|
|
1027
1035
|
const items = select.selectedItems;
|
|
@@ -1037,13 +1045,11 @@
|
|
|
1037
1045
|
return `${items.length} selected`;
|
|
1038
1046
|
} }) });
|
|
1039
1047
|
});
|
|
1040
|
-
var SelectRoot = react.forwardRef(
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
});
|
|
1046
|
-
react.forwardRef(function SelectItemGroup2(props, ref) {
|
|
1048
|
+
var SelectRoot = react.forwardRef((props, ref) => /* @__PURE__ */ jsxRuntime.jsx(react$1.Select.Root, { ...props, ref, positioning: { sameWidth: true, ...props.positioning }, children: props.asChild ? props.children : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1049
|
+
/* @__PURE__ */ jsxRuntime.jsx(react$1.Select.HiddenSelect, {}),
|
|
1050
|
+
props.children
|
|
1051
|
+
] }) }));
|
|
1052
|
+
react.forwardRef((props, ref) => {
|
|
1047
1053
|
const { children, label, ...rest } = props;
|
|
1048
1054
|
return /* @__PURE__ */ jsxRuntime.jsxs(react$1.Select.ItemGroup, { ...rest, ref, children: [
|
|
1049
1055
|
/* @__PURE__ */ jsxRuntime.jsx(react$1.Select.ItemGroupLabel, { children: label }),
|
|
@@ -1075,34 +1081,32 @@
|
|
|
1075
1081
|
} = props;
|
|
1076
1082
|
const { enumOptions, enumDisabled, emptyValue } = options;
|
|
1077
1083
|
const optionValueFormat = utils.getOptionValueFormat(options);
|
|
1078
|
-
const
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
const _onSingleChange = ({ value: value2 }) => {
|
|
1082
|
-
const selected = utils.enumOptionValueDecoder(value2, enumOptions, optionValueFormat, emptyValue);
|
|
1084
|
+
const handleMultiChange = ({ value: newValue }) => onChange(utils.enumOptionValueDecoder(newValue, enumOptions, optionValueFormat, emptyValue));
|
|
1085
|
+
const handleSingleChange = ({ value: newValue }) => {
|
|
1086
|
+
const selected = utils.enumOptionValueDecoder(newValue, enumOptions, optionValueFormat, emptyValue);
|
|
1083
1087
|
return onChange(Array.isArray(selected) && selected.length === 1 ? selected[0] : selected);
|
|
1084
1088
|
};
|
|
1085
|
-
const
|
|
1086
|
-
const
|
|
1089
|
+
const handleBlur = ({ target }) => onBlur(id, utils.enumOptionValueDecoder(target && target.value, enumOptions, optionValueFormat, emptyValue));
|
|
1090
|
+
const handleFocus = ({ target }) => onFocus(id, utils.enumOptionValueDecoder(target && target.value, enumOptions, optionValueFormat, emptyValue));
|
|
1087
1091
|
const showPlaceholderOption = !multiple && schema.default === void 0;
|
|
1088
1092
|
const displayEnumOptions = react.useMemo(() => {
|
|
1089
|
-
let
|
|
1093
|
+
let computedOptions = [];
|
|
1090
1094
|
if (Array.isArray(enumOptions)) {
|
|
1091
|
-
|
|
1092
|
-
const { value:
|
|
1095
|
+
computedOptions = enumOptions.map((option, index) => {
|
|
1096
|
+
const { value: enumValue, label: enumLabel } = option;
|
|
1093
1097
|
return {
|
|
1094
|
-
label:
|
|
1095
|
-
value: utils.enumOptionValueEncoder(
|
|
1096
|
-
disabled: Array.isArray(enumDisabled) && enumDisabled.
|
|
1098
|
+
label: enumLabel,
|
|
1099
|
+
value: utils.enumOptionValueEncoder(enumValue, index, optionValueFormat),
|
|
1100
|
+
disabled: Array.isArray(enumDisabled) && enumDisabled.includes(enumValue)
|
|
1097
1101
|
};
|
|
1098
1102
|
});
|
|
1099
1103
|
if (showPlaceholderOption) {
|
|
1100
|
-
|
|
1104
|
+
computedOptions.unshift({ value: "", label: placeholder || "" });
|
|
1101
1105
|
}
|
|
1102
1106
|
}
|
|
1103
|
-
return
|
|
1107
|
+
return computedOptions;
|
|
1104
1108
|
}, [enumDisabled, enumOptions, placeholder, showPlaceholderOption, optionValueFormat]);
|
|
1105
|
-
const isMultiple = typeof multiple !== "undefined" && multiple
|
|
1109
|
+
const isMultiple = typeof multiple !== "undefined" && multiple && Boolean(enumOptions);
|
|
1106
1110
|
const formValue = [
|
|
1107
1111
|
utils.enumOptionSelectedValue(value, enumOptions, isMultiple, optionValueFormat, isMultiple ? [] : "")
|
|
1108
1112
|
].flat().filter((v) => v !== "");
|
|
@@ -1131,9 +1135,9 @@
|
|
|
1131
1135
|
name: htmlName || id,
|
|
1132
1136
|
multiple: isMultiple,
|
|
1133
1137
|
closeOnSelect: !isMultiple,
|
|
1134
|
-
onBlur:
|
|
1135
|
-
onValueChange: isMultiple ?
|
|
1136
|
-
onFocus:
|
|
1138
|
+
onBlur: handleBlur,
|
|
1139
|
+
onValueChange: isMultiple ? handleMultiChange : handleSingleChange,
|
|
1140
|
+
onFocus: handleFocus,
|
|
1137
1141
|
autoFocus: autofocus,
|
|
1138
1142
|
value: formValue,
|
|
1139
1143
|
"aria-describedby": utils.ariaDescribedByIds(id),
|
|
@@ -1168,9 +1172,9 @@
|
|
|
1168
1172
|
rawErrors,
|
|
1169
1173
|
uiSchema
|
|
1170
1174
|
}) {
|
|
1171
|
-
const
|
|
1172
|
-
const
|
|
1173
|
-
const
|
|
1175
|
+
const handleChange = ({ target: { value: newValue } }) => onChange(newValue === "" ? options.emptyValue : newValue);
|
|
1176
|
+
const handleBlur = ({ target }) => onBlur(id, target && target.value);
|
|
1177
|
+
const handleFocus = ({ target }) => onFocus(id, target && target.value);
|
|
1174
1178
|
const chakraProps = getChakra({ });
|
|
1175
1179
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1176
1180
|
Field,
|
|
@@ -1190,9 +1194,9 @@
|
|
|
1190
1194
|
value: value ?? "",
|
|
1191
1195
|
placeholder,
|
|
1192
1196
|
autoFocus: autofocus,
|
|
1193
|
-
onChange:
|
|
1194
|
-
onBlur:
|
|
1195
|
-
onFocus:
|
|
1197
|
+
onChange: handleChange,
|
|
1198
|
+
onBlur: handleBlur,
|
|
1199
|
+
onFocus: handleFocus,
|
|
1196
1200
|
rows: options.rows,
|
|
1197
1201
|
"aria-describedby": utils.ariaDescribedByIds(id)
|
|
1198
1202
|
}
|
|
@@ -1200,7 +1204,7 @@
|
|
|
1200
1204
|
}
|
|
1201
1205
|
);
|
|
1202
1206
|
}
|
|
1203
|
-
var NumberInputRoot = react.forwardRef(
|
|
1207
|
+
var NumberInputRoot = react.forwardRef((props, ref) => {
|
|
1204
1208
|
const inputRef = react.useRef(null);
|
|
1205
1209
|
react.useEffect(() => {
|
|
1206
1210
|
if (inputRef.current) {
|
|
@@ -1217,9 +1221,9 @@
|
|
|
1217
1221
|
});
|
|
1218
1222
|
function UpDownWidget(props) {
|
|
1219
1223
|
const { id, readonly, disabled, label, hideLabel, value, onChange, onBlur, onFocus, rawErrors, required } = props;
|
|
1220
|
-
const
|
|
1221
|
-
const
|
|
1222
|
-
const
|
|
1224
|
+
const handleChange = ({ value: newValue }) => onChange(newValue);
|
|
1225
|
+
const handleBlur = ({ target }) => onBlur(id, target && target.value);
|
|
1226
|
+
const handleFocus = ({ target }) => onFocus(id, target && target.value);
|
|
1223
1227
|
const chakraProps = getChakra({ uiSchema: props.uiSchema });
|
|
1224
1228
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1225
1229
|
Field,
|
|
@@ -1235,9 +1239,9 @@
|
|
|
1235
1239
|
NumberInputRoot,
|
|
1236
1240
|
{
|
|
1237
1241
|
value,
|
|
1238
|
-
onValueChange:
|
|
1239
|
-
onBlur:
|
|
1240
|
-
onFocus:
|
|
1242
|
+
onValueChange: handleChange,
|
|
1243
|
+
onBlur: handleBlur,
|
|
1244
|
+
onFocus: handleFocus,
|
|
1241
1245
|
"aria-describedby": utils.ariaDescribedByIds(id),
|
|
1242
1246
|
id,
|
|
1243
1247
|
name: id
|
|
@@ -1282,9 +1286,7 @@
|
|
|
1282
1286
|
const newCache = createCache({ container, key: "rjsf" });
|
|
1283
1287
|
return newCache;
|
|
1284
1288
|
});
|
|
1285
|
-
var __createChakraFrameProvider = (props) => ({ document }) => {
|
|
1286
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { style: { margin: 2 }, children: /* @__PURE__ */ jsxRuntime.jsx(react$2.CacheProvider, { value: memoizedCreateCacheWithContainer(document.head), children: /* @__PURE__ */ jsxRuntime.jsx(react$1.ChakraProvider, { value: react$1.defaultSystem, children: props.children }) }) });
|
|
1287
|
-
};
|
|
1289
|
+
var __createChakraFrameProvider = (props) => ({ document }) => /* @__PURE__ */ jsxRuntime.jsx("div", { style: { margin: 2 }, children: /* @__PURE__ */ jsxRuntime.jsx(react$2.CacheProvider, { value: memoizedCreateCacheWithContainer(document.head), children: /* @__PURE__ */ jsxRuntime.jsx(react$1.ChakraProvider, { value: react$1.defaultSystem, children: props.children }) }) });
|
|
1288
1290
|
|
|
1289
1291
|
// src/index.ts
|
|
1290
1292
|
var index_default = Form_default;
|