Skip to content

Commit

Permalink
fix: Added missing ref to ThemeProps type (#3267)
Browse files Browse the repository at this point in the history
Fixed #2135 by adding missing `ref` to `ThemeProps`
  • Loading branch information
heath-freenome committed Dec 3, 2022
1 parent 77478bf commit 0fe99f4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Expand Up @@ -15,6 +15,11 @@ it according to semantic versioning. For example, if your PR adds a breaking cha
should change the heading of the (upcoming) version to include a major version bump.
-->
# 5.0.0-beta.14

## @rjsf/core
- Added `ref` definition to `ThemeProps` fixing [#2135](https://github.com/rjsf-team/react-jsonschema-form/issues/2135)

# 5.0.0-beta.13

## @rjsf/playground
Expand Down
4 changes: 3 additions & 1 deletion packages/core/src/withTheme.tsx
Expand Up @@ -13,7 +13,9 @@ export type ThemeProps<
> = Pick<
FormProps<T, S, F>,
"fields" | "templates" | "widgets" | "_internalFormWrapper"
>;
> & {
ref?: React.Ref<Form<T, S, F>>;
};

/** A Higher-Order component that creates a wrapper around a `Form` with the overrides from the `WithThemeProps` */
export default function withTheme<
Expand Down

2 comments on commit 0fe99f4

@cdolek
Copy link

@cdolek cdolek commented on 0fe99f4 Dec 8, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@heath-freenome Thank you for this. When will 5.0.0-beta.14 be out, thus this fix?

@heath-freenome
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hopefully by early next week. I am working on one final fix for it

Please sign in to comment.