Add textInputComponent prop to InputField#92
Merged
barry-observation merged 1 commit intodevelopfrom Apr 13, 2026
Merged
Conversation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
| description?: string | ||
| errorMessage?: string | ||
| disabled?: boolean | ||
| textInputComponent?: React.ComponentType<any> |
Member
There was a problem hiding this comment.
BottomSheetTextInput heeft dezelfde shape als TextInput, dus je kunt dit doen, zodat je typing errors krijgt als je iets anders dan een TextInput of BottomSheetTextInput doorgeeft:
Suggested change
| textInputComponent?: React.ComponentType<any> | |
| textInputComponent?: React.ComponentType<TextInputProps & RefAttributes<TextInput>> |
SjaakSchilperoort
approved these changes
Apr 13, 2026
Member
SjaakSchilperoort
left a comment
There was a problem hiding this comment.
Nauwkeuriger typing dan textInputComponent?: React.ComponentType<any> is helaas niet mogelijk, dus dit is prima.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Necessary to make https://github.com/observation/app/pull/1212 pass.
This adds a new prop to the InputField component. It allows you to pass down another
TextInput-like component. In this case we need it to be able to pass down aBottomSheetTextInputcomponent.The typing of the new prop is set to
anybecause this library does not know aboutBottomSheetTextInput. Typing it asTextInputdoes not help becauseBottomSheetTextInputis a superset ofTextInput. Soanyseems most appropriate.