Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix data type in FieldTemplateProps['onChange'] #3873

Merged
merged 6 commits into from
Oct 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ should change the heading of the (upcoming) version to include a major version b

- Added `getOptionMatchingSimpleDiscriminator()` function
- `getMatchingOption` and `getClosestMatchingOption` now bypass `validator.isValid()` calls when simple discriminator is provided, fixing [#3692](https://github.com/rjsf-team/react-jsonschema-form/issues/3692)
- Fix data type in `FieldTemplateProps['onChange']`


# 5.13.0
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ export type FieldTemplateProps<T = any, S extends StrictRJSFSchema = RJSFSchema,
/** The formData for this field */
formData?: T;
/** The value change event handler; Can be called with a new value to change the value for this field */
onChange: FieldProps['onChange'];
onChange: FieldProps<T, S, F>['onChange'];
/** The key change event handler; Called when the key associated with a field is changed for an additionalProperty */
onKeyChange: (value: string) => () => void;
/** The property drop/removal event handler; Called when a field is removed in an additionalProperty context */
Expand Down