@rjsf/core 5.2.1 → 5.3.0

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/index.d.ts CHANGED
@@ -261,6 +261,13 @@ declare class Form<T = any, S extends StrictRJSFSchema = RJSFSchema, F extends F
261
261
  * @param id - The id of the field that caused the change
262
262
  */
263
263
  onChange: (formData: T | undefined, newErrorSchema?: ErrorSchema<T>, id?: string) => void;
264
+ /**
265
+ * Callback function to handle reset form data.
266
+ * - Reset all fields with default values.
267
+ * - Reset validations and errors
268
+ *
269
+ */
270
+ reset: () => void;
264
271
  /** Callback function to handle when a field on the form is blurred. Calls the `onBlur` callback for the `Form` if it
265
272
  * was provided.
266
273
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rjsf/core",
3
- "version": "5.2.1",
3
+ "version": "5.3.0",
4
4
  "description": "A simple React component capable of building HTML forms out of a JSON schema.",
5
5
  "scripts": {
6
6
  "build": "rimraf dist && dts build --rollupTypes --format cjs,esm,umd",
@@ -44,18 +44,18 @@
44
44
  "prop-types": "^15.7.2"
45
45
  },
46
46
  "devDependencies": {
47
- "@babel/cli": "^7.20.7",
48
- "@babel/core": "^7.20.12",
47
+ "@babel/cli": "^7.21.0",
48
+ "@babel/core": "^7.21.3",
49
49
  "@babel/plugin-proposal-class-properties": "^7.18.6",
50
- "@babel/plugin-proposal-optional-chaining": "^7.20.7",
50
+ "@babel/plugin-proposal-optional-chaining": "^7.21.0",
51
51
  "@babel/plugin-transform-object-assign": "^7.18.6",
52
- "@babel/plugin-transform-react-jsx": "^7.20.13",
52
+ "@babel/plugin-transform-react-jsx": "^7.21.0",
53
53
  "@babel/preset-env": "^7.20.2",
54
54
  "@babel/preset-react": "^7.18.6",
55
- "@babel/register": "^7.18.9",
56
- "@rjsf/utils": "^5.2.1",
57
- "@rjsf/validator-ajv6": "^5.2.1",
58
- "@rjsf/validator-ajv8": "^5.2.1",
55
+ "@babel/register": "^7.21.0",
56
+ "@rjsf/utils": "^5.3.0",
57
+ "@rjsf/validator-ajv6": "^5.3.0",
58
+ "@rjsf/validator-ajv8": "^5.3.0",
59
59
  "@types/lodash": "^4.14.191",
60
60
  "@types/react": "^17.0.39",
61
61
  "@types/react-dom": "^17.0.11",
@@ -63,14 +63,14 @@
63
63
  "atob": "^2.1.2",
64
64
  "chai": "^3.3.0",
65
65
  "dts-cli": "^1.6.3",
66
- "eslint": "^8.33.0",
66
+ "eslint": "^8.36.0",
67
67
  "html": "^1.0.0",
68
68
  "jsdom": "^20.0.1",
69
69
  "mocha": "^10.2.0",
70
70
  "react": "^17.0.2",
71
71
  "react-dom": "^17.0.2",
72
72
  "react-portal": "^4.2.2",
73
- "rimraf": "^4.1.2",
73
+ "rimraf": "^4.4.0",
74
74
  "sinon": "^9.0.2"
75
75
  },
76
76
  "directories": {
@@ -94,5 +94,5 @@
94
94
  "publishConfig": {
95
95
  "access": "public"
96
96
  },
97
- "gitHead": "461f74b2f51c17e1cdaa327f63ef0fd88060fde0"
97
+ "gitHead": "bf782afebd9096b74f2dac2856faadb0abbb9488"
98
98
  }