New Features
- Support to allow raising errors from custom widgets
- Added support for overriding the labels for
enums
,anyOf
andoneOf
via theUiSchema
@rjsf/core
- Support allowing raising errors from within a custom Widget #2718
- Updated
ArrayField
,BooleanField
andStringField
to calloptionsList()
with the additionalUiSchema
parameter, fixing #4215 and #4260
@rjsf/utils
- Updated the
WidgetProps
type to addes?: ErrorSchema<T>, id?: string
to the params of theonChange
handler function - Updated
UIOptionsBaseType
to add the newenumNames
prop to support an alternate way to provide labels forenum
s in a schema, fixing #4215 - Updated
optionsList()
to take an optionaluiSchema
that is used to extract alternate labels forenum
s oroneOf
/anyOf
in a schema, fixing #4215 and #4260- NOTE: The generics for
optionsList()
were expanded from<S extends StrictRJSFSchema = RJSFSchema>
to<S extends StrictRJSFSchema = RJSFSchema, T = any, F extends FormContextType = any>
to support theUiSchema
.
- NOTE: The generics for
Dev / docs / playground
- Update the
custom-widget-fields.md
to add documentation for how to raise errors from a custom widget or field