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

TextInput label is breaking in new architecture #4552

Open
JamesRobert20 opened this issue Nov 14, 2024 · 4 comments
Open

TextInput label is breaking in new architecture #4552

JamesRobert20 opened this issue Nov 14, 2024 · 4 comments

Comments

@JamesRobert20
Copy link

Current behaviour

The TextInput component is breaking when you try to use the label prop in the New architecture

How to reproduce?

Create a TextInput component and add the label prop

Preview

Image

What have you tried so far?

I have looked in the package code and found that there are type errors inside the TextInputFlat and InputLabel components

Your Environment

software version
ios 17.6.1
android x
react-native 0.76.1
react-native-paper 5.12.5
node x.x.x
npm or yarn x.x.x
expo sdk 52.0.5
@hxzrx
Copy link

hxzrx commented Nov 14, 2024

I got the same error in React Native 0.76.1 with react navigation 7, however, when I downgraded react navigation to 6, the bug disappeared.

@BogiKay
Copy link
Contributor

BogiKay commented Dec 4, 2024

Hey @JamesRobert20. Thanks for reporting the issue. Can you provide a reproducible example of this issue? Currently, I'm working on new-arch support, so I can handle this, but I didn't manage to reproduce this issue.

Copy link

github-actions bot commented Dec 4, 2024

Hey! Thanks for opening the issue. Can you provide a minimal repro which demonstrates the issue? Posting a snippet of your code in the issue is useful, but it's not usually straightforward to run. A repro will help us debug the issue faster. Please try to keep the repro as small as possible. The easiest way to provide a repro is on snack.expo.dev. If it's not possible to repro it on snack.expo.dev, then you can also provide the repro in a GitHub repository.

@JamesRobert20
Copy link
Author

JamesRobert20 commented Dec 4, 2024

Hi, all that you need to do to reproduce this error is render a TextInput component with a label prop for example:

import { TextInput } from 'react-native-paper';

export default function SomeRandomPage() {
return (<TextInput label="random label" />)
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants