LiewJunTung / pin_code_text_field

A highly customisable Flutter widget for entering pin code. Suitable for use cases such as login and OTP.
MIT License
376 stars 78 forks source link

support LTR pin code on a RTL layout #17

Closed mozesma closed 5 years ago

mozesma commented 5 years ago

Thanks for the great plugin, awesome work! I am building an app that is RTL, and currently the pin code is RTL as well (because of the layout of the Row). In this fork, I have added a default of LTR text direction to the Row, which means it will now be LTR by default on RTL apps as well, with the option to control it.

LiewJunTung commented 5 years ago

Hi @MozesMa, thanks for the pull request. I looked at the code and it looks fine. If you can post a screenshot of how it looks like. If everything is good I'll merge this pull request. :)

mozesma commented 5 years ago

Sure! This is before my code: (on RTL application) beforeFix

This after my code: (on RTL application, with the default setting) afterFix

when setting textDirection: TextDirection.rtl on the PinCodeTextField widget - you get the same as the first gif

mozesma commented 5 years ago

Hey @LiewJunTung, Tagging you in case you have missed my comment above :)

LiewJunTung commented 5 years ago

Okay, thank you for your contribution. 👍