anday013 / react-native-otp-entry

Simple and fully modifiable OTP Input Component for React Native
https://www.npmjs.com/package/react-native-otp-entry
MIT License
252 stars 33 forks source link

Wrap theme containers in `Animated.View` #74

Open willashley23 opened 1 month ago

willashley23 commented 1 month ago

Is your feature request related to a problem? Please describe. I want to be able to apply a loading animation to the OTP, such as a shimmer or "breathe" effect when the code is being validated. This is not possible because the exposed theme containers eg pinCodeContainerStyle and pinCodeTextStyle are not Animated.Views

Describe the solution you'd like I think as many of these containers should be wrapped in Animated to give greater creative control to consumers

Describe alternatives you've considered Wrapping the entire thing in an Animated.View is limiting and doesnt allow granular loading effects per cel.

anday013 commented 1 month ago

Hi @willashley23 . Pretty fair point. I've started working on the solution, which converts plain components to their animated version, just by passing a single prop