Skip to content

Commit 9cafdcd

Browse files
committed
Do not display input field in MultiSchemaField.tsx with null type
1 parent 9272935 commit 9cafdcd

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ should change the heading of the (upcoming) version to include a major version b
1717
-->
1818
# 5.24.9
1919

20+
## @rjsf/core
21+
22+
- Do not display input field in MultiSchemaField with null type
23+
2024
## Dev / docs / playground
2125

2226
- Updated docs for ArrayFieldItemTemplate to include prop `onCopyIndexClick`, fixing [#4507](https://github.com/rjsf-team/react-jsonschema-form/issues/4507)

packages/core/src/components/fields/MultiSchemaField.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,9 @@ class AnyOfField<T = any, S extends StrictRJSFSchema = RJSFSchema, F extends For
241241
readonly={readonly}
242242
/>
243243
</div>
244-
{optionSchema && <_SchemaField {...this.props} schema={optionSchema} uiSchema={optionUiSchema} />}
244+
{optionSchema && optionSchema.type !== 'null' && (
245+
<_SchemaField {...this.props} schema={optionSchema} uiSchema={optionUiSchema} />
246+
)}
245247
</div>
246248
);
247249
}

0 commit comments

Comments
 (0)