Releases: rjsf-team/react-jsonschema-form
Releases · rjsf-team/react-jsonschema-form
5.13.4
5.13.3
@rjsf/antd
- Fixed the
SelectWidget
so that filtering works by reworking howoptions
are passed to the underlyingSelect
@rjsf/core
- Replaced the deprecated
UNSAFE_componentWillReceiveProps()
method in the Form.tsx component with an improved solution utilizing the React lifecycle methods:getSnapshotBeforeUpdate()
andcomponentDidUpdate()
. Fixing #1794 - Fixed the
ArrayField
implementation to never pass an undefined schema for fixed arrays to other methods, fixing #3924 - Fixed a refresh issue in
getSnapshotBeforeUpdate()
caused by the fix for #1794, fixing #3927
@rjsf/utils
- Updated
toPathSchemaInternal()
util to generate correct path schemas for fixed arrays by picking up individual schemas in theitems
array, fixing #3909
5.13.2
@rjsf/utils
- Updated
resolveAnyOrOneOfSchemas()
to not take arecurseList
anymore, and instead always pass an empty array down toresolveAllReferences()
, fixing #3902- Also updated
parseSchema()
andresolveDependencies()
to no longer passrecurseList
toresolveAnyOrOneOfSchemas()
- Also updated
@rjsf/validator-ajv8
- Updated
AJV8PrecompiledValidator
to add a newensureSameRootSchema()
function that is called in bothrawValidation()
andisValid()
- This function adds an optimization to avoid resolving the root schema unless necessary
5.13.1
@rjsf/core
- Updated
ArrayField
to move errors in the errorSchema when the position of array items changes for the insert and copy cases.
@rjsf/material-ui
- Removed an unnecessary
Grid
container component in theArrayFieldTemplate
component that wrapped theArrayFieldItemTemplate
, fixing #3863 - Fixed an issue where
SelectWidget
switches from controlled to uncontrolled whenenumOptions
does not include a value, fixing #3844
@rjsf/mui
- Removed an unnecessary
Grid
container component in theArrayFieldTemplate
component that wrapped theArrayFieldItemTemplate
, fixing #3863 - Fixed an issue where
SelectWidget
switches from controlled to uncontrolled whenenumOptions
does not include a value, fixing #3844
@rjsf/utils
- Added
getOptionMatchingSimpleDiscriminator()
function getMatchingOption
andgetClosestMatchingOption
now bypassvalidator.isValid()
calls when simple discriminator is provided, fixing #3692- Fix data type in
FieldTemplateProps['onChange']
- Updated
retrieveSchema()
to properly resolve references inside ofproperties
and arrayitems
while also dealing with recursive$ref
s, fixing #3761- Updated
schemaParser()
andgetClosestMatchingOption()
to pass the newrecursiveRef
parameter added to internalretrieveSchema()
APIs
- Updated
- Added/updated all the necessary tests to restore the
100%
test coverage that was lost when updating to Jest 29- Updated
getDefaultFormState()
to remove an unnecessary check forformData
being an object since it is always guaranteed to be one, thereby allowing full testing coverage
- Updated
- Updated
getSchemaType()
to return the first schematype
when it is an array not containing'null'
, fixing #3875
@rjsf/validator-ajv8
- Updated the
validator
andprecompiledValidator
tests to the restore100%
coverage that was lost when updating to Jest 29- Updated
isValid()
for thevalidator
commenting out an if condition that was preventing100%
coverage, with a TODO to fix it later
- Updated
Dev / docs / playground
- Added the
@types/jest
as a globaldevDependency
so that developer tools properly recognize the jest function types
5.13.0
@rjsf/antd
- Bump Antd version from v4 to v5.
- Intentionally kept peer dependencies to v4 so that this change doesn't make breaking change for
@rjfs/antd
users. - However, if users of
@rjsf/antd
want to use v5 styling, they need to wrap your application with theStyleProvider
from@ant-design/cssinjs
. They need not have to install this package, its a transitive package coming from antd.
import { StyleProvider } from '@ant-design/cssinjs';
const Component = () => {
return (<StyleProvider><YourFormComponents /></StyleProvider>);
}
@rjsf/core
- Updated
MultiSchemaField
to only merge top level required field fixing duplicate field and description. - Fixed programmatic validation (
validateForm()
) removes previous errors if all data is now valid.
@rjsf/chakra-ui
- Fixed a faulty check of the
isMultiple
option inMultiSchemaField
. It no longer offers multiple choice inside a select field in aoneOf
case in Chakra UI, fixing #3848
5.12.1
5.12.1
@rjsf/validator-ajv8
- Updated
AJV8PrecompiledValidator.rawValidation()
to resolve root schema with formData when comparing input schema, fixing #3825
@rjsf/core
- Updated
MultiSchemaField
to merge all top level fields except properties for anyOf/oneOf options, fixing #3808 and #3787
@rjsf/antd
- Updated CheckboxesWidget to not show duplicate title, fixing #3815
@rjsf/utils
- Updated
retrieveSchemaInternal
allOf logic for precompiled schemas to resolve top level properties fixing #3817
5.12.0
New features
- Added a new
never
option for theexperimental_defaultFormStateBehavior
for arrayMinItems - Added a new compileSchemaValidatorsCode() function to the
validator-ajv8
@rjsf/utils
- Experimental feature:
- Added
experimental_defaultFormStateBehavior = { arrayMinItems: { populate: 'never' } }
(feature #3796)
- Added
@rjsf/validator-ajv8
- Exposing new function
compileSchemaValidatorsCode
to allow creating precompiled validator without a file. This is useful in case when precompiled validator is to be created dynamically. #3793
Dev / docs / playground
- update playground vite config to use sources directly, allowing to reload changes in it without additional build step
- moving from
dts-cli
to use individual dev tools directly, updating package publish config- tsc for generating type definitions and esm modules
- esbuild for CJS bundle
- rollup for UMD bundle
- Updated the
form-props
documentationarrayMinItems
, added description fornever
. - Updated the
playground
to add the option for the newarrayMinItems.populate = 'never'
.
5.11.2
@rjsf/material-ui
- Removed unnecessary import of old
@types/material-ui
which can cause typescript issues in some situations
@rjsf/utils
- Updated the
resolveAllReferences()
function to use object spreading to update properties and items in a schema rather than directly modifying the schema to avoid issues with frozen object, fixing #3805
5.11.1
@rjsf/core
- Updated
SchemaField
to ignore errors foranyOf
/oneOf
parent schema, fixing 1295
@rjsf/utils
- Created new
resolveAllReferences()
function to resolve all references within a schema's properties and array items. - Updated
getClosestMatchingOption()
to useresolveAllReferences()
for all oneOf/anyOf schemas - Updated
resolveAnyOrOneOfSchemas()
to useresolveAllReferences()
for all oneOf/anyOf schemas - Better handle the
null
case inwithIdRefPrefix
, fixing #3792
5.11.0
NOTE: this release failed to publish.
New feature
extraErrorsBlockSubmit
onForm
, see the documentation
@rjsf/core
- Updated
MultiSchemaField
to usemergeSchema()
for merging in the remaining schema foranyOf
/oneOf
- Added new
extraErrorsBlockSubmit
prop toForm
that allows the extra asynchronous errors to block a form submit, fixing #3757
@rjsf/utils
- Updated
retrieveSchemaInternal()
to always resolve allOf schema without merging whenexpandAllBranches
is set, fixing compiled schema issue always throwing error withmergeAllOf
- Updated
getDefaultFormState()
to usemergeSchema()
for merging in the remaining schema foranyOf
/oneOf
- Updated
retrieveSchema()
to usemergeSchema()
for merging in the remaining schema foranyOf
/oneOf
Dev / docs / playground
- Switched to using npm workspaces for the sub-package hierarchy
- NOTE: Developers may need to run the
npm run refresh-node-modules
script first to get the build and tests to work correctly
- NOTE: Developers may need to run the
- Backfilled Docusaurus site with documentation for v3, v4