You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix: Properly attach ref to Field's rendered input element
Previous approach tried to ref the Field component, which doesn't work.
Now wrapping the render/children function to inject the ref into the
actual input element that Field renders.
Changes:
- Renamed rootRef to fieldRef for clarity
- Added findInput() helper called in componentDidMount/Update
- Wrap render/children function to clone element with merged ref
- Merge innerRef with fieldRef to support both internal and external refs
This ensures we get access to the actual DOM input element for HTML5
validation while maintaining React 19 compatibility (no findDOMNode).
0 commit comments