Skip to content

Commit 726d63e

Browse files
heath-freenomenickgrosJonaszJestemzxbodyacwendtxealth
authored
Merge the RJSF V6 long-lived branch (#4593)
* Merge changes in `main` to `rjsf-v6` (#3996) Co-authored-by: Jonasz Wiącek <[email protected]> Co-authored-by: Heath C <[email protected]> Co-authored-by: Bogdan Savluk <[email protected]> Co-authored-by: Christian Wendt <[email protected]> Co-authored-by: Ben Lambert <[email protected]> Co-authored-by: David R. Bild <[email protected]> Co-authored-by: Ariqun <[email protected]> fix(utils): direct lodash function import to improve bundling on library client side (#3976) fix: #3961 resolve all recurse list for object properties (#3981) fix gap in outline when label is hidden (#3984) Fix: Expose the internal `ajv` variable in the validator implementation classes (#3991) Fixes: #3972 indirectly by exposing the `ajv` variable for use in the issue * Add rjsf-v6 to ci.yml (#3989) * Fix typo in ci.yml * [v6] Add react-bootstrap theme to replace bootstrap-4 (#3638) (#3974) * [v6] Remove `@rjsf/material-ui` theme (Material UI v4) (#4010) * Merge changes in `main` to `rjsf-v6` (#4164) Co-authored-by: Heath C <[email protected]> Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Kevin Burnett <[email protected]> Co-authored-by: Marek Bodinger <[email protected]> Co-authored-by: Mehdi Salem <[email protected]> Co-authored-by: Jonasz Wiącek <[email protected]> Co-authored-by: Bogdan Savluk <[email protected]> Co-authored-by: Christian Wendt <[email protected]> Co-authored-by: Ben Lambert <[email protected]> Co-authored-by: David R. Bild <[email protected]> Co-authored-by: Ariqun <[email protected]> Co-authored-by: Shivam Anand Murmu <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Shubham Biswas <[email protected]> Co-authored-by: popmanhe <[email protected]> Co-authored-by: Yuki Aoki <[email protected]> Co-authored-by: Xiangcheng Kuo <[email protected]> Co-authored-by: Bart van Andel <[email protected]> Co-authored-by: Laurent Direr <[email protected]> Co-authored-by: Vegard Stenvik <[email protected]> Co-authored-by: Appie <[email protected]> Co-authored-by: Oren Forer <[email protected]> Co-authored-by: Marcus Penn <[email protected]> Co-authored-by: joachimhagheim <[email protected]> Co-authored-by: MarekBodingerBA <[email protected]> Co-authored-by: momesana <[email protected]> Co-authored-by: Martti Roitto <[email protected]> fix(utils): direct lodash function import to improve bundling on library client side (#3976) fix: #3961 resolve all recurse list for object properties (#3981) fix gap in outline when label is hidden (#3984) Fix: Expose the internal `ajv` variable in the validator implementation classes (#3991) Fixes: #3972 indirectly by exposing the `ajv` variable for use in the issue Fix: Change FormHelperText usage with @mui/material to render divs (#4032) Fixes #4031 by switching the render component for `FormHelperText` to be `div` fix: Added support for anyOf/oneOf in uiSchema (#4055) Fixes #4039 by updating `MultiSchemaField` to properly support `anyOf`/`oneOf` arrays in the `uiSchema` Fix checkbox with 0 as a value was unselectable in antd (#4068) Fixed #4067 by properly dealing with enums that have 0 as a value Fix potential XSS in the preview button of FileWidget (#4065) Fix: Make 'ui:rows' option work with chakra-ui for textarea elements #4070 (#4078) Fix typo in ErrorsListTemplate example (#4087) Fix #4080 by moving `base64` encoder/decoder from `@rjsf/utils` to playground (#4093) Fix: Error state not resetting when schema changes (#4079) (#4103) Fix noImplicitAny error (#4106) Fixes: [WARNING] Duplicate key "include" in object literal [duplicate-object-key] (#4114) Fixes: Warning: validateDOMNesting(...): <p> cannot appear as a descendant of <p>. (#4117) Fix documentation to add missing Form imports (#4131) Fix #4127 to add missing `Form` import in documentation Fix: filename should be bold (#4125) Fix: use correct ConfigProvider context by using named imports (#4132) Fix 4134 by filtering out bad DOM props (#4140) Fixes: #4134 by updating the spreading of props onto the `TextField` to remove bad DOM fields Fixed Programmatic submit not working properly in Firefox (#4150) Fix Maximum call stack size exceeded in findSchemaDefinition (#4123) * Merge changes in `main` to `rjsf-v6` (#4276) Co-authored-by: Heath C <[email protected]> Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Kevin Burnett <[email protected]> Co-authored-by: Marek Bodinger <[email protected]> Co-authored-by: Mehdi Salem <[email protected]> Co-authored-by: Nick Grosenbacher <[email protected]> Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Jonasz Wiącek <[email protected]> Co-authored-by: Bogdan Savluk <[email protected]> Co-authored-by: Christian Wendt <[email protected]> Co-authored-by: Ben Lambert <[email protected]> Co-authored-by: David R. Bild <[email protected]> Co-authored-by: Ariqun <[email protected]> Co-authored-by: Shivam Anand Murmu <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Shubham Biswas <[email protected]> Co-authored-by: popmanhe <[email protected]> Co-authored-by: Yuki Aoki <[email protected]> Co-authored-by: Xiangcheng Kuo <[email protected]> Co-authored-by: Bart van Andel <[email protected]> Co-authored-by: Laurent Direr <[email protected]> Co-authored-by: Vegard Stenvik <[email protected]> Co-authored-by: Appie <[email protected]> Co-authored-by: Oren Forer <[email protected]> Co-authored-by: Marcus Penn <[email protected]> Co-authored-by: joachimhagheim <[email protected]> Co-authored-by: MarekBodingerBA <[email protected]> Co-authored-by: momesana <[email protected]> Co-authored-by: Martti Roitto <[email protected]> Co-authored-by: Serge van den Oever <[email protected]> Co-authored-by: Enzo Ferey <[email protected]> Co-authored-by: Skyf0l <[email protected]> Co-authored-by: Jaejoon Han <[email protected]> Co-authored-by: とまとみ <[email protected]> Co-authored-by: Daniel Todd <[email protected]> Co-authored-by: Dmitry Dzhus <[email protected]> Co-authored-by: Alexander Kachkaev <[email protected]> Co-authored-by: shaddollxz <[email protected]> Co-authored-by: Changyu Geng <[email protected]> Co-authored-by: Helen Lin <[email protected]> Co-authored-by: solimant <[email protected]> Co-authored-by: David Li <[email protected]> fix(utils): direct lodash function import to improve bundling on library client side (#3976) fix: #3961 resolve all recurse list for object properties (#3981) fix gap in outline when label is hidden (#3984) Fix: Expose the internal `ajv` variable in the validator implementation classes (#3991) Fixes: #3972 indirectly by exposing the `ajv` variable for use in the issue Fix: Change FormHelperText usage with @mui/material to render divs (#4032) Fixes #4031 by switching the render component for `FormHelperText` to be `div` fix: Added support for anyOf/oneOf in uiSchema (#4055) Fixes #4039 by updating `MultiSchemaField` to properly support `anyOf`/`oneOf` arrays in the `uiSchema` Fix checkbox with 0 as a value was unselectable in antd (#4068) Fixed #4067 by properly dealing with enums that have 0 as a value Fix potential XSS in the preview button of FileWidget (#4065) Fix: Make 'ui:rows' option work with chakra-ui for textarea elements #4070 (#4078) Fix typo in ErrorsListTemplate example (#4087) Fix #4080 by moving `base64` encoder/decoder from `@rjsf/utils` to playground (#4093) Fix: Error state not resetting when schema changes (#4079) (#4103) Fix noImplicitAny error (#4106) Fixes: [WARNING] Duplicate key "include" in object literal [duplicate-object-key] (#4114) Fixes: Warning: validateDOMNesting(...): <p> cannot appear as a descendant of <p>. (#4117) Fix documentation to add missing Form imports (#4131) Fix #4127 to add missing `Form` import in documentation Fix: filename should be bold (#4125) Fix: use correct ConfigProvider context by using named imports (#4132) Fix 4134 by filtering out bad DOM props (#4140) Fixes: #4134 by updating the spreading of props onto the `TextField` to remove bad DOM fields Fixed Programmatic submit not working properly in Firefox (#4150) Fix Maximum call stack size exceeded in findSchemaDefinition (#4123) fix typos in constants.ts, Form.tsx (#4185) Fix mui imports in docs (#4218) fix] Resetting number fields should check the entire string when deciding to leave the input text alone (#4202) (#4220) Fixed performance issue with large schema dependencies and oneOf (#4203) (#4204) Fixed performance issue #4203 fix(core): field ui-options higher priority (#4212) fix(antd): disabled property of options of antd theme (#4216) fix: omitExtraData on submit and on validateForm (#4228) Fix IdSchema and PathSchema types (#4196) fixes #4236 Fix #4197 in various themes by showing empty option in SelectWidget when appropriate (#4200) fix: xss when rendering schema errors (#4256) fix 4215 and 4260 by updating optionsList() to take a uiSchema (#4263) Fixes #4215 and #4260 by supporting alternate titles for enums and anyOf/oneOf lists via the uiSchema Fixed Changelog (#4269) * v6.0.0-alpha.0 * Fix changelog, react-bootstrap README (#4278) * Forward main changes (#4487) * fix(utils): direct lodash function import to improve bundling on library client side (#3976) * v5.14.3 (#3979) * add missing typescript project reference for utils in validator-ajv6 and validator-ajv8 (#3982) * fix: #3961 resolve all recurse list for object properties (#3981) * fix: resolve all recurse list for object properties * update test * simplfy logic * revert * update change log * Add the ability to parse defaults from `allOf` schema (#3969) * feat: support default values in anyOf format * feat: add `skipDefaults` and `populateDefaults` options for `allOf` parsing * docs: add examples * chore: ammending chanelog * mui: fix gap in outline when label is hidden (#3984) * mui: fix gap in outline when label is hidden Passing `label={false}` to the MUI text/select widgets results in a gap in the widget outline where the label would be. Instead, to hide the label without a gap, we must pass `label={undefined}`. This commit changes the calls to `labelValue(...)` for BaseInputTemplatea and SelectWidget to return `undefined` when `"ui:label": false` was specified. * mui: update test snapshots * Release 5.15.0 (#3986) * - Fixup `CHANGELOG.md` to merge 5.14.4 into 5.15.0 * v5.15.0 * Make getFieldNames correctly defines array of primitives (#3990) * Fix: Expose the internal `ajv` variable in the validator implementation classes (#3991) * Fix: Expose the internal `ajv` variable in the validator implementation classes Fixes: #3972 indirectly by exposing the `ajv` variable for use in the issue - In `@rjsf/ajv6`, updated `AJV6Validator` to make the `ajv` variable public and changed the return of the `customizeValidator()` function to remove the interface return - In `@rjsf/ajv8`, updated `AJV8Validator` to make the `ajv` variable public and changed the return of the `customizeValidator()` function to remove the interface return - Also removed some `@ts-expect-error` tags that are no longer needed due to the exposed variable - Updated the `CHANGELOG.md` accordingly * - Responded to reviewer feedback * v5.15.1 (#3997) * feat: pass down indexed title from array field (#4002) * feat: pass indexed title from array field to use as title in children if present * docs: add changelog * test: add test for checkbox widget * test: add test for remaining widgets * test: add test for object, array, oneof and anyof fields * test: add test for allof field * refactor: move repetitive task to one function and run it on array data * chore: change version changelog according to the changes made * test: fix allof field test case * chore(deps): bump actions/download-artifact from 3 to 4 Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 3 to 4. - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](https://github.com/actions/download-artifact/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/download-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps): bump actions/setup-python from 3 to 5 Bumps [actions/setup-python](https://github.com/actions/setup-python) from 3 to 5. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v3...v5) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps): bump actions/upload-artifact from 3 to 4 Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3 to 4. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps-dev): bump vite from 4.4.9 to 4.4.12 Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.4.9 to 4.4.12. - [Release notes](https://github.com/vitejs/vite/releases) - [Changelog](https://github.com/vitejs/vite/blob/v4.4.12/packages/vite/CHANGELOG.md) - [Commits](https://github.com/vitejs/vite/commits/v4.4.12/packages/vite) --- updated-dependencies: - dependency-name: vite dependency-type: direct:development ... Signed-off-by: dependabot[bot] <[email protected]> * Feat: Implements #297 request (#4004) * [Feat] Add Date re-order option * Added tests for date re-order * Updated docs and example * Update changelog * Added documentation for getDateElementProps function * Fix: test failing due to year change * Removed redundant parameters info * chore: Bumped packages using `npm run bump-all-packages` (#4006) * Fix: Bumped packages using `npm run bump-all-packages` - Temporarily locked down "@mui/material": "5.15.2" and "@mui/base": "5.0.0-beta.28" due to https://github.com/mui/material-ui/issues/40427 * - Responded to reviewer feedback by removing an added dev-dependency that seems unnecessary * Update Form.tsx and make submit method public (#4029) * Update Form.tsx and make submit method public * Update Form.tsx and make submit public * Update CHANGELOG.md and add an entry for submit method changes * Update CHANGELOG.md --------- Co-authored-by: Heath C <[email protected]> * Fix: Change FormHelperText usage with @mui/material to render divs (#4032) Fixes #4031 by switching the render component for `FormHelperText` to be `div` - In `@rjsf/mui`, updated `FieldErrorTemplate` and `FieldHelpTemplate` to use the `div` component for `FormHelperText` * Support file deletion for data-url (#4030) * Release 5.16.0 (#4037) * Merged the `5.15.2` change up into the `5.16.0` change since `5.15.2` was never released * v5.16.0 * Release 5.16.1 (#4041) * Releasing 5.16.1 with bumped peer dependencies * v5.16.1 * Enhancement(Share): Enhancement base64 encoding/decoding using UTF-8 charset to support the characters outside the latin1 range. (#4024) (#4034) * Enhancement(Share): Declare and export an object that provides base64 encoding and decoding functions using the utf-8 charset to support the characters outside the latin1 range. (#4024) * Enhancement(Share): Add the 'base64.test.ts' to test the base64. (#4024) * Enhancement(Share): Update the base64 reference in 'Playground' to the new customized base64 in 'utils' (#4024). * Enhancement(Share): Update 'CHANGELOG.md' (#4024). * Enhancement(Share): Update 'CHANGELOG.md' (#4024). * Enhancement(Share): Add test to test the platform behavior (#4024). * Enhancement: Fix comments and updating utility-functions.md to add introduction of base64 object * Update CHANGELOG.md * Update CHANGELOG.md * Update base64.ts * fix: Added support for anyOf/oneOf in uiSchema (#4055) Fixes #4039 by updating `MultiSchemaField` to properly support `anyOf`/`oneOf` arrays in the `uiSchema` - In `@rjsf/utils`: Improved documentation and typescript ignores in tests related to `base64` from previous PR - In `@rjsf/core`: Updated `MultiSchemaField` to support `anyOf`/`oneOf` arrays in the `uiSchema` - Updated the tests to verify the new feature - In `docs`: Added documentation to the `uiSchema.md` file describing how to use the new feature - Updated the `CHANGELOG.md` accordingly * chore(deps-dev): bump vite from 4.5.1 to 4.5.2 Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.5.1 to 4.5.2. - [Release notes](https://github.com/vitejs/vite/releases) - [Changelog](https://github.com/vitejs/vite/blob/v4.5.2/packages/vite/CHANGELOG.md) - [Commits](https://github.com/vitejs/vite/commits/v4.5.2/packages/vite) --- updated-dependencies: - dependency-name: vite dependency-type: direct:development ... Signed-off-by: dependabot[bot] <[email protected]> * Fix checkbox with 0 as a value was unselectable in antd (#4068) * fix: Added support for anyOf/oneOf in uiSchema Fixes #4039 by updating `MultiSchemaField` to properly support `anyOf`/`oneOf` arrays in the `uiSchema` - In `@rjsf/utils`: Improved documentation and typescript ignores in tests related to `base64` from previous PR - In `@rjsf/core`: Updated `MultiSchemaField` to support `anyOf`/`oneOf` arrays in the `uiSchema` - Updated the tests to verify the new feature - In `docs`: Added documentation to the `uiSchema.md` file describing how to use the new feature - Updated the `CHANGELOG.md` accordingly * Fix checkbox with 0 as a value was unselectable in antd Fixed #4067 by properly dealing with enums that have 0 as a value - In `@rjsf/utils`: Updated `enumOptionsValueForIndex()` to filter against `emptyValue` rather than just truthy - Updated the tests to verify the bug and then validate the fix - Updated the `CHANGELOG.md` accordingly * Fix potential XSS in the preview button of FileWidget (#4065) * fix dataURI parsing mechanism * Restrict image preview file types * Make broken files be ignored * Update changelog * Refactor image preview whitelist, add comments, and fix tests * fix the way of error handling to pass the coverage test * Update packages/core/src/components/widgets/FileWidget.tsx Co-authored-by: Heath C <[email protected]> --------- Co-authored-by: Heath C <[email protected]> * docs: update link to markdown-to-jsx homepage (#4071) Co-authored-by: Heath C <[email protected]> * Release 5.17.0 (#4073) * - Fixed `CHANGELOG.md` to make it a minor version update - Bumped the packages using `bump-all-packages` - Updated the tests for `antd` and `fluentui-rc` due to packages bump * v5.17.0 * Fix: Make 'ui:rows' option work with chakra-ui for textarea elements #4070 (#4078) * Fix typo in ErrorsListTemplate example (#4087) Co-authored-by: Heath C <[email protected]> * Fix #4080 by moving `base64` encoder/decoder from `@rjsf/utils` to playground (#4093) * Pass errorSchema from ArrayField to ArrayFieldTemplate (#4094) * Pass errorSchema from ArrayField to ArrayFieldTemplate * Update CHANGELOG.md * v5.17.1 (#4096) * Feat: don't assign a default value of an empty field. (#3880) (#4085) * Added skipEmptyDefaults feature * Fixed an issue where the skipEmptyDefault option was not displaying default values for fields that are not required. * Updated tests and the changelog * Updated changelog: moved chakra-ui changes above utils. --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> * chore(deps-dev): bump ip from 2.0.0 to 2.0.1 Bumps [ip](https://github.com/indutny/node-ip) from 2.0.0 to 2.0.1. - [Commits](https://github.com/indutny/node-ip/compare/v2.0.0...v2.0.1) --- updated-dependencies: - dependency-name: ip dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * Fix: Error state not resetting when schema changes (#4079) (#4103) * #4079 Fixed the issue where the error state was not resetting when the schema changed. * #4079 Updated the changelog * #4079 Improved previous and new schema check * #4079 Added test * #4079 improved test * #4079 removing console.log * Apply suggestions from code review - Accepted reviewer feedback --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * Fix noImplicitAny error (#4106) Co-authored-by: Heath C <[email protected]> * Update validation docs with correct require statement (#4108) Co-authored-by: Heath C <[email protected]> * Fixes: [WARNING] Duplicate key "include" in object literal [duplicate-object-key] (#4114) * Fixes: Warning: validateDOMNesting(...): <p> cannot appear as a descendant of <p>. (#4117) * give instructions for material ui 5, not 4 (#4126) * Fix documentation to add missing Form imports (#4131) Fix #4127 to add missing `Form` import in documentation - Updated many of the documentation files to add missing imports of `Form` - Updated the `CHANGELOG.md` accordingly Co-authored-by: Kevin Burnett <[email protected]> * Fix: filename should be bold (#4125) * Fix: filename should be bold Also prevents horrible looking "\</strong>" from being printed on screen. * Update CHANGELOG.md * Skip populate function proposal in Experimental_ArrayMinItems (#4121) * skip populate draft * Added a new `computeSkipPopulate` option in `arrayMinItems`, allowing custom logic to skip populating arrays with default values * Add example in documentation of computeSkipPopulate * Update packages/docs/docs/api-reference/form-props.md Co-authored-by: Heath C <[email protected]> * Update packages/utils/src/types.ts Co-authored-by: Heath C <[email protected]> * Update packages/docs/docs/api-reference/form-props.md Co-authored-by: Heath C <[email protected]> --------- Co-authored-by: Marek Bodinger <[email protected]> Co-authored-by: Heath C <[email protected]> * Fix: use correct ConfigProvider context by using named imports (#4132) Co-authored-by: Mehdi Salem <[email protected]> Co-authored-by: Heath C <[email protected]> * Fix 4134 by filtering out bad DOM props (#4140) Fixes: #4134 by updating the spreading of props onto the `TextField` to remove bad DOM fields - In `@rjsf/mui`, updated `SelectField` and `BaseInputTemplate` to filter out `errorSchema` and `autocomplete` from the `textFieldProps` before they are spread onto `TextField` - Updated `CHANGELOG.md` accordingly, moving `@rjsf/antd` above `@rjsf/core` * v5.18.0 (#4141) * chore(deps): bump follow-redirects from 1.15.5 to 1.15.6 Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.15.5 to 1.15.6. - [Release notes](https://github.com/follow-redirects/follow-redirects/releases) - [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.15.5...v1.15.6) --- updated-dependencies: - dependency-name: follow-redirects dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * Release 5.18.1 (#4145) * - Bumped peer dependencies due to new feature * v5.18.1 * - Removed unnecessary `package-lock.json` in `fluentui-rc` theme * chore(deps-dev): bump vite from 4.5.2 to 4.5.3 Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.5.2 to 4.5.3. - [Release notes](https://github.com/vitejs/vite/releases) - [Changelog](https://github.com/vitejs/vite/blob/v4.5.3/packages/vite/CHANGELOG.md) - [Commits](https://github.com/vitejs/vite/commits/v4.5.3/packages/vite) --- updated-dependencies: - dependency-name: vite dependency-type: direct:development ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps): bump express from 4.18.2 to 4.19.2 Bumps [express](https://github.com/expressjs/express) from 4.18.2 to 4.19.2. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/master/History.md) - [Commits](https://github.com/expressjs/express/compare/4.18.2...4.19.2) --- updated-dependencies: - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps): bump webpack-dev-middleware from 5.3.3 to 5.3.4 Bumps [webpack-dev-middleware](https://github.com/webpack/webpack-dev-middleware) from 5.3.3 to 5.3.4. - [Release notes](https://github.com/webpack/webpack-dev-middleware/releases) - [Changelog](https://github.com/webpack/webpack-dev-middleware/blob/v5.3.4/CHANGELOG.md) - [Commits](https://github.com/webpack/webpack-dev-middleware/compare/v5.3.3...v5.3.4) --- updated-dependencies: - dependency-name: webpack-dev-middleware dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * #3121 Fixed Programmatic submit not working properly in Firefox (#4150) Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * Fix Maximum call stack size exceeded in findSchemaDefinition (#4123) * Add tests for circular and deeply circular refs in definitions * Fix Maximum call stack size exceeded in findSchemaDefinition * Update CHANGELOG * Add tests for findSchemaDefinitionRecursive * v5.18.2 (#4157) * Upgrades React (#4107) * Upgrades react packages * Updates semantic-ui-react * Add support back for semantic version 1 via peerdependencies (#4169) - In `@rjsf/semantic-ui` - added back `semantic-ui-react` version `^1.3.1` to the peer dependencies - Also made `semantic-ui-react` a devDependency for `^2.1.3` - In the playground, added `[email protected]` due to the transition of `semantic-ui-react` as a devDependency - Updated `CHANGELOG.md` accordlingly * Create codeql.yml (#4170) * Update LICENSE.md (#4174) * Update LICENSE.md Dear rsjf-team, I have a request. We are using the great rjsf packages to build a forms solution for a company. This company requires a copyright notice in the license file. Could you please replace the example copyright notice by a copyright of your team. I know it is strange at that location, but it would solve our problems. Examples where they added names at that location in the license file: - https://github.com/eisberg-labs/actix-actor-expect/blob/c28e751d219535c3d4d2b5579ddd281440e5ea87/LICENSE-APACHE#L4 - https://github.com/Swiftify-Corp/Swift-30-Projects/blob/5140f35ca0cb3767807bc518084809030a77139a/License.md?plain=1#L4 * Update LICENSE.md - Added the start date from when the repo was created --------- Co-authored-by: Heath C <[email protected]> * Update custom-widgets-fields.md (#4171) Co-authored-by: Heath C <[email protected]> * chore(deps-dev): bump gh-pages from 3.2.3 to 5.0.0 Bumps [gh-pages](https://github.com/tschaub/gh-pages) from 3.2.3 to 5.0.0. - [Release notes](https://github.com/tschaub/gh-pages/releases) - [Changelog](https://github.com/tschaub/gh-pages/blob/main/changelog.md) - [Commits](https://github.com/tschaub/gh-pages/compare/v3.2.3...v5.0.0) --- updated-dependencies: - dependency-name: gh-pages dependency-type: direct:development ... Signed-off-by: dependabot[bot] <[email protected]> * Release 5.18.3 (#4175) * - Updated `CHANGELOG.md` to account for a few PRs * v5.18.3 * Add missing angle bracket (#4178) * fix typos in constants.ts, Form.tsx (#4185) * fix typos in constants.ts, Form.tsx * keep the constants to for backwards compatibility Co-authored-by: Heath C <[email protected]> --------- Co-authored-by: Heath C <[email protected]> * chore(deps): bump mkdocs from 1.5.3 to 1.6.0 Bumps [mkdocs](https://github.com/mkdocs/mkdocs) from 1.5.3 to 1.6.0. - [Release notes](https://github.com/mkdocs/mkdocs/releases) - [Commits](https://github.com/mkdocs/mkdocs/compare/1.5.3...1.6.0) --- updated-dependencies: - dependency-name: mkdocs dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps-dev): bump ejs from 3.1.9 to 3.1.10 Bumps [ejs](https://github.com/mde/ejs) from 3.1.9 to 3.1.10. - [Release notes](https://github.com/mde/ejs/releases) - [Commits](https://github.com/mde/ejs/compare/v3.1.9...v3.1.10) --- updated-dependencies: - dependency-name: ejs dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * v5.18.4 (#4195) * feat: treat default field in additionalProperties (#4199) * feat: treat "default" in additionalProperties * test: add test cases for the case there's a default in additionalProperties * Passes missing uiSchema prop to Form component. (#4219) * Remove duplicate mention of hideError (#4211) Co-authored-by: Nick Grosenbacher <[email protected]> * Fix mui imports in docs (#4218) Co-authored-by: Nick Grosenbacher <[email protected]> * [fix] Resetting number fields should check the entire string when deciding to leave the input text alone (#4202) (#4220) * chore(deps): bump ws from 7.5.9 to 7.5.10 Bumps [ws](https://github.com/websockets/ws) from 7.5.9 to 7.5.10. - [Release notes](https://github.com/websockets/ws/releases) - [Commits](https://github.com/websockets/ws/compare/7.5.9...7.5.10) --- updated-dependencies: - dependency-name: ws dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * chore(deps): bump braces from 3.0.2 to 3.0.3 Bumps [braces](https://github.com/micromatch/braces) from 3.0.2 to 3.0.3. - [Changelog](https://github.com/micromatch/braces/blob/master/CHANGELOG.md) - [Commits](https://github.com/micromatch/braces/compare/3.0.2...3.0.3) --- updated-dependencies: - dependency-name: braces dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> * Bug: Fixed performance issue with large schema dependencies and oneOf (#4203) (#4204) * Fixed performance issue #4203 * code improvement based on feedback --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * Handle undefined target in onBlur and onFocus handlers (#4227) There are some instances where the `onBlur` and `onFocus` handlers are receiving an undefined `target`, causing the following type error: ``` Cannot read properties of undefined (reading 'value') ``` - Updated all of the `onBlur()` and `onFocus()` handlers in all libraries to fix this - Updated the `CHANGELOG.md` accordingly * fix(core): field ui-options higher priority (#4212) * fix(core): field ui-options higher priority * docs(root): changelog * Update CHANGELOG.md --------- Co-authored-by: Heath C <[email protected]> * Release 5.18.5 (#4230) * - Fixed spelling mistake for `rjsf` in `CHANGELOG.md` * v5.18.5 * fix(antd): disabled property of options of antd theme (#4216) * fix: disabled property of options in CheckboxesWidget and RadioWidget of antd theme * chore: update CHANGELOG.md for #4216 * chore: update formTests * chore: update PULL_REQUEST_TEMPLATE.md for test * Update CHANGELOG.md --------- Co-authored-by: Heath C <[email protected]> * fix: omitExtraData on submit and on validateForm (#4228) * fix: omitExtraData on submit and on validateForm * test: update tests for omitExtraData * ci: update changelog * Update CHANGELOG.md Co-authored-by: Heath C <[email protected]> * Apply suggestions from code review Co-authored-by: Heath C <[email protected]> * docs: update changelog --------- Co-authored-by: Heath C <[email protected]> * Fix IdSchema and PathSchema types (#4196) * Fix IdSchema and PathSchema types * Simplify type assertions --------- Co-authored-by: Heath C <[email protected]> * SchemaField: Only use nullish coalescing with uiOptions when computing readonly (#4238) fixes #4236 * v5.18.6 (#4237) * (feature) Add new relative Years feature to AltDateWidget (#4239) * (feature) Add new relative Years feature to AltDateWidget Added a new feature supporting relate Years and reversing Years ordering to `AltDateWidget` - In `@rjsf/utils` - Refactored and improved the `dateRangeOptions()` function from all implementations of `AltDateWidget` - Added 100% unit tests for the new function - In `@rjsf/antd`, `@rjsf/chakra-ui` and `@rjsf/core` replaced `rangeOptions()` with `dateRangeOptions()` - In `docs`, added documentation for `dateRangeOptions()` to the `utility-functions.md` and feature documentation to `widgets.md` - Updated the `CHANGELOG.md` accordingly * Update packages/core/test/StringField.test.jsx - Responded to reviewer feedback Co-authored-by: Nick Grosenbacher <[email protected]> --------- Co-authored-by: Nick Grosenbacher <[email protected]> * v5.19.0 (#4240) * Bumped peer dependencies to 5.19.x due to new API used from utils (#4241) Since other repos required a new API in `utils` we need to bump peer dependencies - Ran `npm run bump-peer-deps` and committed changes - Updated the `CHANGELOG.md` accordingly * Release 5.19.1 (#4242) * - Fixed peer deps package-lock.json * v5.19.1 * Removed .only on a core test (#4243) One of the `core` tests was accidentally left as `.only`, undoing that as well as bumping most of the minor and patch package updates - Updated `StringField.test.jsx` to remove a `.only` - Centralized `esbuild` down to the main `package.json` - Updated the `CHANGELOG.md` accordingly * v5.19.2 (#4245) * Fix #4197 in various themes by showing empty option in SelectWidget when appropriate (#4200) * Release 5.19.3 (#4247) * Fixed `CHANGELOG.md` to restore 5.19.2 * v5.19.3 * feature: Added better support for testing with AJV having discriminator option turned on (#4257) * feature: Added better support for testing with AJV having discriminator option turned on A recent issue made it clear that we didn't make it easy for users to turn on `discriminator` support from AJV - In `@rjsf/utils` improved support for `discriminator` as follows: - Updated the `ValidatorType` to add support for an optional `reset()` method - Updated the `ParserValidator` to implement `reset()` to clear the schema map, including a test to verify that - Updated the tests that used `discriminator` to remove the `mapping` block that AJV doesn't support - Updated the `getFirstMatchingOption()` test to deal with the situation where AJV doesn't support discriminator for array types - Updated the `retrieveSchema()` test to call `reset()` on validators that have it in an `afterEach()` - Updated the `getTestValidator()` implementation to implement a `reset()` that empties the arrays - In `@rjsf/validator-ajv8` improved support for `discriminator` as follows: - Updated the `createAjvInstance()` function to denote that we want to make `discriminator: true` the default in v6 - Updated the `AJV8Validator` to make reset do `ajv.removeSchema()` to clear the cached schemas - Updated the `getTestValidator() implementation to call `reset()` on the validator if it exists - Updated the `schema.test.ts` file to run a set of test with `discriminator: true` set on the `AJV8Validator` - Updated the `CHANGELOG.md` file accordingly * - Added required for `code` to all of the schemas * - Switched the default Translatable strings to use Markdown * fix: xss when rendering schema errors (#4256) * fix: stop rendering config errors as html * Update CHANGELOG.md * Update UnsupportedField.tsx * Fix formatting * Update packages/core/src/components/templates/UnsupportedField.tsx * Update CHANGELOG.md * Update <SchemaField> to match * - Fix lint error * Update CHANGELOG.md - Updating to mention potential breaking change --------- Co-authored-by: Heath C <[email protected]> * v5.19.4 (#4258) * Feat: Allow raising errors from within a custom whatever(#2718) (#4188) * #2718 feature - raise errors from within fields * fixed failing tests * Fixed failing build * Removing raiseError message and errorSchema is updated now using the onChange. * reverting tests * Filtering errors based on your retrieved schema to only show errors for properties in the selected branch. * fixed issue with typing causing build failures. * Improvement based on feedback * improvement based on feedback and written test for custom widget * documenting the feature * docs improvement base on feedback * removed empty line * fixed lodash import * Update packages/core/src/components/Form.tsx Ordered lodash import * Update packages/core/src/components/Form.tsx * Update CHANGELOG.md Added missing packages * Update CHANGELOG.md Added missing space --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * fix 4215 and 4260 by updating optionsList() to take a uiSchema (#4263) * fix 4215 and 4260 by updating optionsList() to take a uiSchema Fixes #4215 and #4260 by supporting alternate titles for enums and anyOf/oneOf lists via the uiSchema - In `@rjsf/utils` added support for alternate option labels from the `UiSchema` as follows: - Updated `UIOptionsBaseType` to add the new `enumNames` prop to support an alternate way to provide labels for `enum`s in a schema - Updated `optionsList()` to take an optional `uiSchema` that is used to extract alternate labels for `enum`s or `oneOf`/`anyOf` in a schema - NOTE: The generics for `optionsList()` were expanded to add `T = any, F extends FormContextType = any` to support the `UiSchema` - Added unit tests to maintain 100% coverage - In `@rjsf/core` updated `ArrayField`, `BooleanField` and `StringField` to call `optionsList()` with the additional `UiSchema` parameter - In `docs` added documentation about the new `ui:enumNames` property, fixing up the `enumNames` documentation to indicate it WILL be removed - Also updated the `optionsList()` function's documentation to add the new `uiSchema` prop - Updated the `CHANGELOG.md` accordingly * Update packages/utils/test/optionsList.test.ts Fix typo in test name --------- Co-authored-by: Nick Grosenbacher <[email protected]> * v5.20.0 (#4264) * Release 5.20.1 (#4268) * Release 5.20.1 - Updated the peer dependencies to 5.20.x * v5.20.1 * Fixed Changelog (#4269) * Bug: issue with dependencies computeDefaults (#4271) (#4282) * Fixed issue with dependencies computedDefaults * update changelog * refactoring based on feedback * created tests for the new created methods * organized file based on feedback * Update CHANGELOG.md --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * feat: improve deepEquals performance (#4292) * Change fast-deep-equal to fast-equals * Add changelog and change deepEquals depscription * run cs-format * Add JSDocs for isFunctions and customDeepEqual * Update CHANGELOG.md --------- Co-authored-by: Heath C <[email protected]> * fix querySelector in Form focusOnError when id includes dots (#4280) Co-authored-by: Heath C <[email protected]> * Fix 4283 by adding support for MUI v6 (#4294) * Fix 4285 by adding support for MUI v6 - Updated `@rjsf/mui` to update the dev dependencies for `@mui/*` to v6 and the peer dependencies to add MUI v6 - Updated the playground to update `@mui/*` to v6 - Also changed the dropdown name from `material-ui-5` to `mui` and switched `Layout` to use the `PropsWithChildren` for its props - Updated the `Form.test.tsx` to add information to the fake node to allow the tests to work with v6 - Ran `npm run test:update` to update the snapshots due to the v6 and emotion upgrades - Updated the test snapshots for `@rjsf/chakra-ui` which also uses emotion - Updated `CHANGELOG.md` accordingly, bumping to `5.21.0` * - Fixed the load of shared links to convert `material-ui-5` to `mui` * chore(deps): bump mkdocs from 1.6.0 to 1.6.1 Bumps [mkdocs](https://github.com/mkdocs/mkdocs) from 1.6.0 to 1.6.1. - [Release notes](https://github.com/mkdocs/mkdocs/releases) - [Commits](https://github.com/mkdocs/mkdocs/compare/1.6.0...1.6.1) --- updated-dependencies: - dependency-name: mkdocs dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> * v5.21.0 (#4295) * Revert "feat: improve deepEquals performance (#4292)" (#4300) * Revert "feat: improve deepEquals performance (#4292)" This reverts commit 514ea85826ebfe48f5827b44f9daced5bff0bc47. * package.json * v5.21.1 (#4301) * fix: Improved the widget/field customization docs (#4302) * fix Improved the widget/field customization docs Updated the widget and field customization docs to add examples of wrapping a widget/field to adjust props * Apply suggestions from code review - Responded to reviewer feedback Co-authored-by: Nick Grosenbacher <[email protected]> --------- Co-authored-by: Nick Grosenbacher <[email protected]> * Fix: Pass required props to anyof/oneof field components (#4303) * Chore: Updating changelog with missing info (#4309) Updated `CHANGELOG.md` to add details for the simple fix provided in #4303 * fix: deal with null objects in errors in Form.filterErrorsBasedOnSchema() (#4310) * fix: deal with null objects in errors in Form.filterErrorsBasedOnSchema() Fixes #4306 by using `lodash.isNil()` instead of comparing to `undefined` - Updated `Form.filterErrorsBasedOnSchema()` to use lodash `isNil()` to check if the key is either null or undefined - Updated the `CHANGELOG.md` accordingly * - Made name more correct * fix: not merge the `allOf.contains` schemas * feat: Support array numbers in pathOfError for ErrorSchemaBuilder * Update CHANGELOG.md (#4317) * Refactor: delete unused variable (#4320) Co-authored-by: Dmitry Khomichenko <[email protected]> * v5.21.2 (#4323) * Fix typo L12n -> L10n (#4332) * experimental_customMergeAllOf (#4308) * experimental_customMergeAllOf draft * Add test for experimental_customMergeAllOf * Add documentation for experimental_customMergeAllOf * Changelog update * Add changelog v2 --------- Co-authored-by: Marek Bodinger <[email protected]> * Make fields with const pre-fiiled and readonly #3843 (#4326) * Make fields with const pre-fiiled and readonl * fixed issue with default on root level. * fixed array const populate values * fixed array issue and written tests to cover the behavior * updated changeLog * fixed issue with core failing tests. * changed changeLog to rerun tests * improvement based on feedback * Update packages/utils/test/schema/getDefaultFormStateTest.ts Adding default that should not be used * Update packages/utils/test/schema/getDefaultFormStateTest.ts Fix linter --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * Fix: made small changes to utility functions to fix #3997, #4314 and #4322 (#4329) * Fix: made small changes to utility functions to fix #3997 and #4322 Fixes #3997 and #4322 - In `@rjsf/utils`, made the following changes: - Updated `mergeDefaultsWithFormData()` to not overwrite a default when the formData has an undefined value - Updated `getClosestMatchingOption()` to improve the scoring function so that an object container that matches a key gets an extra point - In `@rjsf/core`, updated `MultiSchemaField` to call `onChange` after setting the new option in state rather than before - Updated the `CHANGELOG.md` accordingly * - In order to avoid regressions, added a new `mergeDefaultsWithFormData` prop to the `Experimental_DefaultFormStateBehavior` - Updated `mergeDefaultsWithFormData()` to add new optional `defaultSupercedesUndefined` that when true uses the defaults rather than `undefined` formData - Updated `getDefaultFormState()` to pass true to `mergeDefaultsWithFormData` for `defaultSupercedesUndefined` when `mergeDefaultsIntoFormData` has the value `useDefaultIfFormDataUndefined` - Updated the documentation for the new capabilities - Updated the playground to add controls for the new `mergeDefaultsIntoFormData` option - moved the `Show Error List` component over one column, making it inline radio buttons rather than a select * - Improved documentation a teeny bit * - More doc improvements * - Responded to reviewer feedback * - Fixed broken links * - Added section header for wrapping BaseInputTemplate * - Updated CHANGELOG.md * v5.22.0 (#4341) * Release 5.22.1 (#4342) * Release 5.22.1 with bumped peer deps * v5.22.1 * Bug: Validation regression Form not revalidating after formData change (#4343) (#4345) * fixed regression * Updating changelog * improvement based on feedback --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> * fix: Validation error messages are inconsistent #4348 (#4349) * fix: replace message field with title or ui:title correctly * fix: add new changelog section & add description * chore: removed extra empty line --------- Co-authored-by: Heath C <[email protected]> * fix: multiple file upload issue (#4347) * fix: multiple file upload issue Resolved a bug where only the first file was uploaded when multiple files were selected. Now, all selected files are uploaded as expected. * feature: Added test to check the expected behaviour * Fix: Move entry of changelog to version 5.22.2 --------- Co-authored-by: Heath C <[email protected]> * v5.22.2 (#4353) * Bug: Deep nested dependencies issue with assigning values to formData (#4356) * Fix deep nested dependencies issue with formData * update changelog --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> * v5.22.3 (#4358) * chore(deps): bump crazy-max/ghaction-github-pages from 4.0.0 to 4.1.0 Bumps [crazy-max/ghaction-github-pages](https://github.com/crazy-max/ghaction-github-pages) from 4.0.0 to 4.1.0. - [Release notes](https://github.com/crazy-max/ghaction-github-pages/releases) - [Commits](https://github.com/crazy-max/ghaction-github-pages/compare/v4.0.0...v4.1.0) --- updated-dependencies: - dependency-name: crazy-max/ghaction-github-pages dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> * Bug: Issue 'Maximum call stack size exceeded' with playground share. (#4370) * Fix issue 'Maximum call stack size exceeded' with playground share with large content. * update changelog --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> * Bug: Issue with array schema defaults not applying properly when formData is an empty array (#4359) * Fixed issue with array schema defaults not applying properly when formData is an empty array. * improvement based on feedback * fixed docs error --------- Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Heath C <[email protected]> * v5.22.4 (#4373) * Adding feature to support const as default bug fix seeming like a regression (#4381) Fixes #4344, #4361 and #4377 - In `@rjsf/utils`: - Updated the `Experimental_DefaultFormStateBehavior` type to add new optional `constAsDefaults` prop with three choices - Updated `getDefaultFormState()` to respond to the new `constAsDefaults` feature to limit `const` as defaults based on the `never` or `skipOneOf` choices - Added tests for `getDefaultFormState()` to verify the new feature - In `@rjsf/core`: - Updated `SchemaField` to remove making the field readonly when const - In `playground`: - Updated `Header` to add support for `constAsDefaults` - Updated the `CHANGELOG.md` accordingly * experimental_customMergeAllOf v2 (#4383) * Pass experimental_customMergeAllOf to missing code branches * Add experimental_customMergeAllOf parameter to documentation, fix link with anchor * Changelog --------- Co-authored-by: Marek Bodinger <[email protected]> * Fixed issue where error messages do not have title or ui:title if a Localizer function is used. Fixes #4387. (#4391) * fix: Update schema builder add/set actions to have unique errors (#4386) * fix: update schema builder add/set actions to have unique errors * docs: add fix description to changelog --------- Co-authored-by: Heath C <[email protected]> * v5.23.0 (#4392) * Chakra-UI must be <3.0.0 fixes #4390 * Fix 4382 by passing errorSchema and id through in NumberField's onChange (#4395) Fixes #4382 - Updated `NumberField`'s `handleChange` callback to pass through the `errorSchema` and `id` - Updated the peerDependencies for the packages to be `5.23.x` - Updated `CHANGELOG.md` accordingly * v5.23.1 (#4396) * Use default values when switching anyOf option (#4375) * Use default values when switching anyOf option * review * Update changelog * review: add oneOf test * Move changelog entry to 5.23.1 * Update CHANGELOG.md Fixed up release --------- Co-authored-by: Heath C <[email protected]> * Fix issue where ui:title in anyOf/oneOf is not shown in error messages (#4398) * Fixed issue where ui:title in anyOf/oneOf is not shown in error messages. Fixes #4368. * Use replace() instead of replaceAll() to support Node v14. * fix: Short-circuit File and Date constructor access in isObject (#4413) * fix: short-circuit File and Date constructor access in isObject if thing is missing required property * chore: update changelog with isObject short-circuiting fix --------- Co-authored-by: Jonathan Sun <[email protected]> * v5.23.2 * Bug: issue with assigning values to deeply nested required properties (#4425) * Fixed issue with assigning values to deeply nested required properties * Update CHANGELOG.md --------- Co-authored-by: Heath C <[email protected]> * Bug: Issue with formData not updating when dependencies change (#4388) * Fixing issue with formData value not changing when dependencies are updated. * refactoring tests and added test to test non-valid formData * update changeLog * added test for getValidFormData method * fixed failing issue because of type change * changes based on feedback * changes based on feedback * fixed test coverage * Override the formData with the const if the constAsDefaults is set to always * Fixed issue with validator-ajv6 ignoring oneOf in dependencies because it thinks there isn't exactly one subschema that is valid. * improvement based on feedback * Fixed failing tests * removed unnecessary code * improvement based on feedback. --------- Co-authored-by: Heath C <[email protected]> * Bug: schema with conditions where switching to then/else subschemas did not reflect the actual validation errors in the onChange event. (#4432) * Fixed issue with schema if/then/else conditions where switching to then/else subschemas did not reflect the actual validation errors in the onChange event. * improvement based on feedback --------- Co-authored-by: Heath C <[email protected]> * Bug: AJV $data reference in const property in schema treated as default/const value. (#4431) * Validator to support AJV $data reference and saving validator state in ShareURL. * Fix for AJV $data reference in const property in schema treated as default/const value. * written a test for consIsAjvDataReference. * Update CHANGELOG.md Moving the change to the end of the existing list --------- Co-authored-by: Heath C <[email protected]> * fix: formData change clear errorMessage (#4429) * fix: formData change clear errorMessage fix: merge errorSchema fix: merge errorSchema * test: add tests for getChangedFields and update CHANGELOG * fix: core test and error message when formData is a string not cleared * feat: modify CHANGELOG --------- Co-authored-by: Heath C <[email protected]> * Partially fixed dependency error messages (#4417) * Partially fixed issue where dependency errors do not show title or ui:title. This fix only applicable if we use an ajv-i18n localizer. Ref. #4402. * Add comments. * Update packages/validator-ajv8/src/processRawValidationErrors.ts --------- Co-authored-by: Heath C <[email protected]> * feat: switch `lodash.isEqual` to `fast-equals.deepEqual` to improve performance (#4438) * switch lodash.isEqual to fast-equals.deepEqual to improve performance * Revert "switch lodash.isEqual to fast-equals.deepEqual to improve performance" This reverts commit 86570fe6cc49899ef8828667c5b05cdbcc3bc8f7. * use precompiledValidator @rjsf/utils.deepEquals * switch lodash.isEqual to @rjsf/utils.deepEquals at utils package * fix changelog and remove unnecessary comment * v5.24.0 (#4443) * Release 5.24.1 (#4445) * Bump peer dependencies due to new API in utils * v5.24.1 * - Updated `CHANGELOG.md` to indicate the bumping of peer dependencies * - Fixed the peer deps version * - Added documentation for `getChangedFields()` * Update packages/docs/docs/api-reference/utility-functions.md * Switch lodash.isEqualWith to fast-equals (#4446) * Fixed file accept attribute not working on mui and chakra-ui. (#4457) * Update validation.md (#4458) schema is not a variable here, and yourSchema is unused. I believe the form input here should be schema={yourSchema} Co-authored-by: Heath C <[email protected]> * Bug : Fields inside an array can't be set to empty when default is set. (#4461) * Fixed issue with fields inside an array can't be set to empty when a default is set * Update packages/utils/src/mergeDefaultsWithFormData.ts - Reviewer feedback * Update packages/utils/src/mergeDefaultsWithFormData.ts - Fix linting --------- Co-authored-by: Heath C <[email protected]> * Refactor: remove unnecessary indirectness in get default form state test (#4462) * refactor `getDefaultFormState` tests * refactor `computeDefaults` tests * refactor `getDefaultBasedOnSchemaType` tests * refactor `getObjectDefaults` tests * refactor `getArrayDefaults` tests * replace original `getDefaultFormStateTest` test with refactored * clarify expected value for array test * remove unused type --------- Co-authored-by: Heath C <[email protected]> * Bug: The oneOf selector can be modified in readonly mode (#4463) * Fixed issue with oneOf selector can be modified in readonly mode * update based on feedback * v5.24.2 (#4468) * Validator should not refresh on clicking a Selector in playground (#4472) * Validator should not refresh on clicking a Selector in playground * Updated change log * Update CHANGELOG.md --------- Co-authored-by: Heath C <[email protected]> * Revert #4446 due to regression (#4478) Fixed #4475 by rolling back #4446 - In `@rjsf/utils` rolled back the changes made by #4446 - Updated the `CHANGELOG.md` accordingly * v5.24.3 (#4480) * - Drop node 14, 16 and 18 support, adding 20 and 22 * - More `ci` clean for builds * - Make code-ql work for rjsf-v6 branch * - Fixed build by using correct version of MUI as well as removing MUI 5 support * - Updated node engine >= 20 * - Fix package-lock.json --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Jonasz Wiącek <[email protected]> Co-authored-by: Bogdan Savluk <[email protected]> Co-authored-by: Christian Wendt <[email protected]> Co-authored-by: Ben Lambert <[email protected]> Co-authored-by: David R. Bild <[email protected]> Co-authored-by: Ariqun <[email protected]> Co-authored-by: Shivam Anand Murmu <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Shubham Biswas <[email protected]> Co-authored-by: popmanhe <[email protected]> Co-authored-by: Yuki Aoki <[email protected]> Co-authored-by: Xiangcheng Kuo <[email protected]> Co-authored-by: Bart van Andel <[email protected]> Co-authored-by: Laurent Direr <[email protected]> Co-authored-by: Vegard Stenvik <[email protected]> Co-authored-by: Nick Grosenbacher <[email protected]> Co-authored-by: Appie <[email protected]> Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Oren Forer <[email protected]> Co-authored-by: Marcus Penn <[email protected]> Co-authored-by: Kevin Burnett <[email protected]> Co-authored-by: joachimhagheim <[email protected]> Co-authored-by: MarekBodingerBA <[email protected]> Co-authored-by: Marek Bodinger <[email protected]> Co-authored-by: momesana <[email protected]> Co-authored-by: Mehdi Salem <[email protected]> Co-authored-by: Martti Roitto <[email protected]> Co-authored-by: Serge van den Oever <[email protected]> Co-authored-by: Enzo Ferey <[email protected]> Co-authored-by: Skyf0l <[email protected]> Co-authored-by: Jaejoon Han <[email protected]> Co-authored-by: とまとみ <[email protected]> Co-authored-by: Daniel Todd <[email protected]> Co-authored-by: Dmitry Dzhus <[email protected]> Co-authored-by: Alexander Kachkaev <[email protected]> Co-authored-by: shaddollxz <[email protected]> Co-authored-by: Changyu Geng <[email protected]> Co-authored-by: Helen Lin <[email protected]> Co-authored-by: solimant <[email protected]> Co-authored-by: David Li <[email protected]> Co-authored-by: Abdallah Al-Soqatri <[email protected]> Co-authored-by: Igor Brasileiro <[email protected]> Co-authored-by: Jonathan Roebuck <[email protected]> Co-authored-by: Tomasz Durka <[email protected]> Co-authored-by: Sergey Alimov <[email protected]> Co-authored-by: Kylie Marshall <[email protected]> Co-authored-by: Dmitry Khomichenko <[email protected]> Co-authored-by: Dmitry Khomichenko <[email protected]> Co-authored-by: Salvatore Testa <[email protected]> Co-authored-by: Guilherme Castro <[email protected]> Co-authored-by: BorjaDV <[email protected]> Co-authored-by: Yasunobu Chiba <[email protected]> Co-authored-by: Quentin Sommer <[email protected]> Co-authored-by: Jonathan Sun <[email protected]> Co-authored-by: Jonathan Sun <[email protected]> Co-authored-by: 邵瑾瑜 <[email protected]> Co-authored-by: Petar Gligic <[email protected]> Co-authored-by: Roman Krasilnikov <[email protected]> Co-authored-by: deepeshmi26 <[email protected]> * Removed the fluent-ui theme (#4488) - Deleted everything related to `fluent-ui` in the current system, leaving the `CHANGELOG.md` and old version documentation alone * Added new templates, utility function and refactored ArrayFieldItemTemplate (#4489) * Added new templates, utility function and refactored ArrayFieldItemTemplate - In `@rjsf/utils`: - Refactored the `ArrayFieldItemTemplateType` to extract out all the button related props to `ArrayFieldItemButtonsTemplateType`, adding `buttonsProps: ArrayFieldItemButtonsTemplateType` as a new prop - Also created a deprecated alias type `ArrayFieldTemplateItemType` that points to `ArrayFieldItemTemplateType` for backwards compatibility - Added new `GridTemplateProps` type - Added two the following new, required props to `TemplatesType`: - `ArrayFieldItemButtonsTemplate: ComponentType<ArrayFieldItemButtonsTemplateType<T, S, F>>;` - `GridTemplate: ComponentType<GridTemplateProps>` - Added a new `buttonId<T>(id: IdSchema<T> | string, btn: 'add' | 'copy' | 'moveDown' | 'moveUp' | 'remove')` used to generate consistent ids for RJSF buttons - In `@rjsf/core`: - Updated `ArrayField` to provide the `buttonsProps` to the `ArrayFieldItemTemplateType` - Added `ArrayFieldItemButtonsTemplate` component as a refactor of all the common buttons code from all the `ArrayFieldItemTemplate` implementations, adding a unique id using the `buttonId()` function - Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate` - Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes - All other themes: - Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate` - Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes - Updated the playground to remove `fluent-ui` theme - Updated the `custom-templates.md` documentation for the changes to the `ArrayFieldTemplateItem` and add the two new templates - Updated the `utility-functions.md` documentation to add the `buttonId()` function - Added the `v6.x upgrade guide.md` documentation - Updated `CHANGELOG_V6.md` accordingly * - Updated changelog * Apply suggestions from code review - Self feedback * Update packages/docs/docs/advanced-customization/custom-templates.md - Self review * Implemented the GridTemplate for all themes (#4491) * Implemented the GridTemplate for all themes - In al…
1 parent 686052a commit 726d63e

File tree

882 files changed

+1092366
-78817
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

882 files changed

+1092366
-78817
lines changed

.eslintrc.json

+4
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"comma-dangle": [
3434
0
3535
],
36+
"@typescript-eslint/no-require-imports": "off",
3637
"@typescript-eslint/no-unused-vars": [
3738
2,
3839
{
@@ -66,5 +67,8 @@
6667
"react": {
6768
"version": "detect"
6869
}
70+
},
71+
"globals": {
72+
"jest": true
6973
}
7074
}

.github/ISSUE_TEMPLATE/bug_report.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,16 @@ body:
2222
attributes:
2323
label: What theme are you using?
2424
options:
25-
- core
2625
- antd
27-
- bootstrap-4
2826
- chakra-ui
29-
- fluent-ui
30-
- material-ui
27+
- core
28+
- daisyui
29+
- fluentui-rc
3130
- mui
31+
- react-bootstrap
3232
- semantic-ui
33+
- shadcn
3334
- utils
34-
- validator-ajv6
3535
- validator-ajv8
3636
- other
3737
validations:

.github/ISSUE_TEMPLATE/feature_request.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@ body:
1616
attributes:
1717
label: What theme are you using?
1818
options:
19-
- core
2019
- antd
21-
- bootstrap-4
2220
- chakra-ui
23-
- fluent-ui
24-
- material-ui
21+
- core
22+
- daisyui
23+
- fluentui-rc
2524
- mui
25+
- react-bootstrap
2626
- semantic-ui
27+
- shadcn
2728
- utils
28-
- validator-ajv6
2929
- validator-ajv8
3030
- other
3131
validations:

.github/ISSUE_TEMPLATE/question_issue.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,16 @@ body:
1616
attributes:
1717
label: What theme are you using?
1818
options:
19-
- core
2019
- antd
21-
- bootstrap-4
2220
- chakra-ui
23-
- fluent-ui
24-
- material-ui
21+
- core
22+
- daisyui
23+
- fluentui-rc
2524
- mui
25+
- react-bootstrap
2626
- semantic-ui
27+
- shadcn
2728
- utils
28-
- validator-ajv6
2929
- validator-ajv8
3030
- other
3131
validations:

.github/workflows/ci.yml

+3-8
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
runs-on: ubuntu-latest
1212
strategy:
1313
matrix:
14-
node-version: [14.x, 16.x, 18.x]
14+
node-version: [20.x, 22.x]
1515

1616
steps:
1717
- uses: actions/checkout@v4
@@ -21,42 +21,37 @@ jobs:
2121
node-version: ${{ matrix.node-version }}
2222
cache: 'npm'
2323
cache-dependency-path: 'package-lock.json'
24-
- run: npm i -g npm@9
2524
- run: npm ci
2625
- run: npm run lint
2726

2827
- name: Build with Netlify badge
29-
if: github.ref != 'refs/heads/main' && matrix.node-version != '14.x'
3028
run: npm run build-serial
3129
env:
3230
VITE_SHOW_NETLIFY_BADGE: true
3331
NODE_OPTIONS: --max_old_space_size=4096
3432

3533
- name: Build
36-
if: github.ref == 'refs/heads/main' && matrix.node-version != '14.x'
3734
run: npm run build-serial
3835
env:
3936
NODE_OPTIONS: --max_old_space_size=4096
4037

4138
# Docusaurus doesn't support Node 14. These tasks can be removed once Node 14 is EOL (May 2023)
4239
- name: Build with Netlify badge (no docs)
43-
if: github.ref != 'refs/heads/main' && matrix.node-version == '14.x'
4440
run: npx nx run-many --target=build --exclude=@rjsf/docs --parallel=false
4541
env:
4642
VITE_SHOW_NETLIFY_BADGE: true
4743
NODE_OPTIONS: --max_old_space_size=4096
4844
- name: Build (no docs)
49-
if: github.ref == 'refs/heads/main' && matrix.node-version == '14.x'
5045
run: npx nx run-many --target=build --exclude=@rjsf/docs --parallel=false
5146
env:
5247
NODE_OPTIONS: --max_old_space_size=4096
5348

54-
- if: matrix.node-version == '18.x'
49+
- if: matrix.node-version == '22.x'
5550
uses: actions/upload-artifact@v4
5651
with:
5752
name: playground
5853
path: packages/playground/dist
59-
- if: matrix.node-version == '18.x'
54+
- if: matrix.node-version == '22.x'
6055
uses: actions/upload-artifact@v4
6156
with:
6257
name: docs

.github/workflows/release.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- uses: actions/checkout@v4
12-
- name: Use Node.js 18.x
12+
- name: Use Node.js 22.x
1313
uses: actions/setup-node@v4
1414
with:
15-
node-version: 18.x
15+
node-version: 22.x
1616
cache: 'npm'
1717
cache-dependency-path: 'package-lock.json'
1818
- run: npm i -g npm@9
@@ -26,6 +26,6 @@ jobs:
2626
env:
2727
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
2828
- run: git update-index --assume-unchanged .npmrc
29-
- run: npx lerna publish from-package --yes
29+
- run: npx nx release publish
3030
- if: always()
3131
run: rm .npmrc

.gitignore

+8
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,14 @@ out/
141141
# typescript tsbuildinfo
142142
*.tsbuildinfo
143143
lodashReplacer.js
144+
lodashReplacer.cjs
144145
muiReplacer.js
146+
muiReplacer.cjs
145147
ajvReplacer.js
148+
ajvReplacer.cjs
146149

150+
# Need this due to shadcn default utils folder is lib
151+
!packages/shadcn/src/lib
152+
153+
.nx/cache
154+
.nx/workspace-data

.husky/pre-commit

-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#!/usr/bin/env sh
2-
. "$(dirname -- "$0")/_/husky.sh"
31
# Hopefully this disables husky on github CI
42
[ -n "$CI" ] && exit 0
53
npm run pre-commit:husky

.node-version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
18.16.0
1+
22.13.1

.nvmrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
18
1+
22

CHANGELOG.md

+143
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,149 @@ it according to semantic versioning. For example, if your PR adds a breaking cha
1515
should change the heading of the (upcoming) version to include a major version bump.
1616
1717
-->
18+
# 6.0.0-beta.1
19+
20+
## @rjsf/antd
21+
22+
- BREAKING CHANGE: Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate`
23+
- Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes
24+
- Implemented the `GridTemplate` component, adding it to the `templates` for the theme
25+
- BREAKING CHANGE: Removed support for version 4 of `antd`
26+
- Updated `ArrayFieldItemTemplate` to replace `Button.Group` with `Space.Compact` since `Button.Group` is deprecated in `antd` version 5
27+
- Upgraded to `@ant-design/icon@5`
28+
- BREAKING CHANGE: Removed the addition of `Bootstrap 3` classes from the `SchemaField` and added `rjsf-` prefix to marker classes, thereby changing theme `FieldTemplate` className prop output and associated snapshots
29+
30+
## @rjsf/chakra-ui
31+
32+
- BREAKING CHANGE: upgrade from v2 to v3
33+
- BREAKING CHANGE: remove deprecated `@chakra-ui/icon` in favor of `lucide-react`
34+
- BREAKING CHANGE: Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate`
35+
- Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes
36+
- Implemented the `GridTemplate` component, adding it to the `templates` for the theme
37+
- BREAKING CHANGE: Removed the addition of `Bootstrap 3` classes from the `SchemaField` and added `rjsf-` prefix to marker classes, thereby changing theme `FieldTemplate` className prop output and associated snapshots
38+
39+
## @rjsf/core
40+
41+
- BREAKING CHANGE: Updated `ArrayField` to provide the `buttonsProps` to the `ArrayFieldItemTemplateType`
42+
- Added `ArrayFieldItemButtonsTemplate` component as a refactor of all the common buttons code from all the `ArrayFieldItemTemplate` implementations, adding a unique id using the `buttonId()` function
43+
- Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate`
44+
- Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes
45+
- Implemented the `GridTemplate` component, adding it to the `templates` for the theme
46+
- Implemented the new `LayoutGridField`, `LayoutMultiSchemaField` and `LayoutHeaderField` fields, adding them to the `fields` list
47+
- BREAKING CHANGE: Removed support for the deprecated `schema.enumNames` and `uiSchema.classNames` as well as the deprecated `acceptcharset` prop on `Form`
48+
- BREAKING CHANGE: Moved the addition of `Bootstrap 3` classes from the `SchemaField` to the `WrapIfAdditionalTemplate`, thereby affecting all the other themes, fixing [#2280](https://github.com/rjsf-team/react-jsonschema-form/issues/2280)
49+
- BREAKING CHANGE: Added `rjsf-` prefix onto the following marker classes used in the fields and templates:
50+
- `field`, `field-<schema.type>`, `field-error`, `field-hidden`, `field-array`, `field-array-of-<schema.type>`, `field-array-fixed-items`, `array-item`, `config-error`, `array-item-add`, `array-item-copy`, `array-item-move-down`, `array-item-move-up`, `array-item-remove`, `object-property-expand`
51+
- Added support for `patternProperties` [#1944](https://github.com/rjsf-team/react-jsonschema-form/issues/1944)
52+
53+
## @rjsf/daisyui
54+
55+
- Added new theme!
56+
57+
## @rjsf/fluent-ui
58+
59+
- BREAKING CHANGE: Deleted this theme in favor of `fluentui-rc`
60+
61+
## @rjsf/fluentui-rc
62+
63+
- BREAKING CHANGE: Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate`
64+
- Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes
65+
- Implemented the `GridTemplate` component, adding it to the `templates` for the theme
66+
- BREAKING CHANGE: Removed the addition of `Bootstrap 3` classes from the `SchemaField` and added `rjsf-` prefix to marker classes, thereby changing theme `FieldTemplate` className prop output and associated snapshots
67+
68+
## @rjsf/material-ui
69+
70+
- BREAKING CHANGE: Deleted this theme in favor of `mui`
71+
72+
## @rjsf/mui
73+
74+
- BREAKING CHANGE: Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate`
75+
- Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes
76+
- Updated the theme to use `Grid2` instead of the deprecated `Grid`
77+
- Implemented the `GridTemplate` component, adding it to the `templates` for the theme
78+
- BREAKING CHANGE: Removed the addition of `Bootstrap 3` classes from the `SchemaField` and added `rjsf-` prefix to marker classes, thereby changing theme `FieldTemplate` className prop output and associated snapshots
79+
80+
## @rjsf/semantic-ui
81+
82+
- BREAKING CHANGE: Refactored `ArrayFieldItemTemplate` to use the new `ArrayFieldItemButtonsTemplate`
83+
- Updated the `ArrayFieldTemplate`, `ObjectFieldTemplate`, and `WrapIfAdditionalTemplate` to a unique id using the `buttonId()` function and adding consistent marker classes
84+
- Implemented the `GridTemplate` component, adding it to the `templates` for the theme
85+
- BREAKING CHANGE: Removed the addition of `Bootstrap 3` classes from the `SchemaField` and added `rjsf-` prefix to marker classes, thereby changing theme `FieldTemplate` className prop output and associated snapshots
86+
- BREAKING CHANGE: Removed support for the v1 version of `semantic-ui-react`
87+
88+
## @rjsf/shadcn
89+
90+
- Added new theme!
91+
92+
## @rjsf/utils
93+
94+
- BREAKING CHANGE: Refactored the `ArrayFieldItemTemplateType` to extract out all the button related props to `ArrayFieldItemButtonsTemplateType`, adding `buttonsProps: ArrayFieldItemButtonsTemplateType` as a new prop
95+
- Also created a deprecated alias type `ArrayFieldTemplateItemType` that points to `ArrayFieldItemTemplateType` for backwards compatibility
96+
- Added new `GridTemplateProps` type
97+
- BREAKING CHANGE: Added two the following new, required props to `TemplatesType`:
98+
- `ArrayFieldItemButtonsTemplate: ComponentType<ArrayFieldItemButtonsTemplateType<T, S, F>>;`
99+
- `GridTemplate: ComponentType<GridTemplateProps>`
100+
- BREAKING CHANGE: Updated the `SchemaUtilsType` to add new validator-based functions to the interface
101+
- Added the following new non-validator utility functions:
102+
- `buttonId<T>(id: IdSchema<T> | string, btn: 'add' | 'copy' | 'moveDown' | 'moveUp' | 'remove')`: used to generate consistent ids for RJSF buttons
103+
- `getTestIds(): TestIdShape`: Returns an object of test IDs that can only be used in test mode, helpful for writing unit tests for React components
104+
- `hashObject(object: unknown): string`: Stringifies an `object` and returns the hash of the resulting string
105+
- `hashString(string: string): string`: Hashes a string into hex format
106+
- `lookupFromFormContext<T = any, S extends StrictRJSFSchema = RJSFSchema, F extends FormContextType = any>(regOrFc: Registry<T, S, F> | Registry<T, S, F>['formContext'], toLookup: string, fallback?: unknown)`: Given a React JSON Schema Form registry or formContext object, return the value associated with `toLookup`
107+
- Added the following new validator-based utility functions:
108+
- `findFieldInSchema<T = undefined, S extends StrictRJSFSchema = RJSFSchema, F extends FormContextType = any>(validator: ValidatorType<T, S, F>, rootSchema: S, path: string | string[], schema: S, formData?: T, experimental_customMergeAllOf?: Experimental_CustomMergeAllOf<S>): FoundFieldType<S>`: Finds the field specified by the `path` within the root or recursed `schema`
109+
- `findSelectedOptionInXxxOf<T = any, S extends StrictRJSFSchema = RJSFSchema, F extends FormContextType = any>(validator: ValidatorType<T, S, F>, rootSchema: S, schema: S, fallbackField: string,xxx: 'anyOf' | 'oneOf', formData?: T, experimental_customMergeAllOf?: Experimental_CustomMergeAllOf<S>): S | undefined`: Finds the option that matches the selector field in the `schema` or undefined if nothing is selected
110+
- `getFromSchema<T = any, S extends StrictRJSFSchema = RJSFSchema, F extends FormContextType = any>(validator: ValidatorType<T, S, F>, rootSchema: S, schema: S, path: string | string[], defaultValue: T | S, experimental_customMergeAllOf?: Experimental_CustomMergeAllOf<S>): T | S`: Helper that acts like lodash's `get` but additionally retrieves `$ref`s as needed to get the path for schemas
111+
- BREAKING CHANGE: Removed support for the deprecated `schema.enumNames` from `getOptionsList()` while switching the order of its generic types
112+
- BREAKING CHANGE: Removed the deprecated `getMatchingOption()` and `mergeValidationData()` from the library export and the `SchemaUtilsType` interface
113+
- BREAKING CHANGE: Removed the deprecated `toErrorList()` function from the `ValidatorType` interface
114+
- BREAKING CHANGE: Removed the deprecated `RJSF_ADDITONAL_PROPERTIES_FLAG` constant
115+
- Updated the `WrapIfAdditionalTemplateProps` to include `hideError` and `rawErrors` in support of moving `Bootstrap 3` marker classes out of `SchemaField`
116+
- Added support for `patternProperties` [#1944](https://github.com/rjsf-team/react-jsonschema-form/issues/1944)
117+
118+
## @rjsf/validator-ajv6
119+
120+
- BREAKING CHANGE: This deprecated validator has been removed
121+
122+
## @rjsf/validator-ajv8
123+
124+
- BREAKING CHANGE: Removed the implementation of the deprecated `toErrorList()` function from the validator implementations
125+
126+
## Dev / docs / playground
127+
128+
- Updated the playground to Chakra UI v3
129+
- Updated the playground to remove `fluent-ui` theme
130+
- Updated the `custom-templates.md` documentation for the changes to the `ArrayFieldTemplateItem` and add the two new templates
131+
- Updated the `utility-functions.md` documentation to add the `buttonId()` function
132+
- Added the `v6.x upgrade guide.md` documentation
133+
- Updated the `playground` to add a `Layout Grid` example and made the selected example now be part of the shared export
134+
- Replaced Lerna with Nx, updated all lerna commands to use the Nx CLI
135+
- BREAKING CHANGE: Updated all `peerDependencies` to change minimal `React` support to `>=18`
136+
- Added documentation and playground example for `patternProperties`
137+
138+
# 6.0.0-alpha.0
139+
140+
## @rjsf/bootstrap-4
141+
142+
- BREAKING CHANGE: Package has been replaced with `@rjsf/react-bootstrap`. `react-boostrap` v1 / Bootstrap 4 are no longer supported in RJSF v6.
143+
144+
## @rjsf/material-ui
145+
146+
- BREAKING CHANGE: Removed `@rjsf/material-ui` package. Material UI v4 (`@material-ui/core`) has been deprecated since September 2021. To use Material UI v5 (`@mui/core`) with RJSF, please use the `@rjsf/mui` theme instead.
147+
148+
## @rjsf/react-bootstrap
149+
150+
- Added new package to replace `@rjsf/bootstrap-4`
151+
- `react-bootstrap` peer dependency bumped to `^2.0.0`, corresponding to Bootstrap 5
152+
- CheckboxesWidget: Remove deprecated prop `custom`
153+
- IconButton: Remove deprecated `block` prop
154+
- RangeWidget: Use `FormRange` component
155+
- SelectWidget: Use new FormSelect component, remove `bsPrefix` prop to achieve correct styling
156+
157+
## Dev / docs / playground
158+
159+
- Updated the playground to remove `material-ui-4` theme and replace the `bootstrap-4` theme with `react-bootstrap`
160+
18161
# 5.24.10
19162

20163
## Dev / docs / playground

README.md

+2-3
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,10 @@
2929

3030
- [Ant Design](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/antd)
3131
- [Bootstrap 3](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/core)
32-
- [Bootstrap 4](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/bootstrap-4)
32+
- [React-Bootstrap (Bootstrap 5)](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/react-bootstrap)
3333
- [Chakra UI](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/chakra-ui)
34-
- [Fluent UI](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/fluent-ui)
34+
- [Daisy UI](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/daisyui)
3535
- [Fluent UI 9](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/fluentui-rc)
36-
- [Material UI 4](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/material-ui)
3736
- [Material UI 5](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/mui)
3837
- [Semantic UI](https://github.com/rjsf-team/react-jsonschema-form/tree/main/packages/semantic-ui)
3938

babel.config.js

-13
This file was deleted.

babel.config.json

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"presets": [
3+
["@babel/preset-env", { "targets": { "node": "current" } }],
4+
[
5+
"@babel/preset-react",
6+
{
7+
"runtime": "automatic"
8+
}
9+
],
10+
"@babel/preset-typescript"
11+
],
12+
"plugins": [
13+
"@babel/plugin-proposal-class-properties",
14+
"@babel/plugin-proposal-optional-chaining",
15+
"@babel/plugin-transform-class-static-block"
16+
]
17+
}

lerna.json

-7
This file was deleted.

0 commit comments

Comments
 (0)