braintree / android-card-form

A ready-made card form layout that can be included in your Android app, making it easy to accept credit and debit cards.
MIT License
366 stars 127 forks source link

Textfields location #13

Closed dierivera closed 8 years ago

dierivera commented 8 years ago

is there a way to move the expiration date field next to the card field?

lkorth commented 8 years ago

In the pending 3.x branch the expiration date field and the cvv field are now on the same line when they are both present. Combining the expiration date field and the card number field on the same line when the cvv field is not present would result in a very complex layout and logic.

dierivera commented 8 years ago

And is there a way to add a button next to the card field, for example for the scan button. Just like the uber app?

And yes, I was thinking of date and cvv, not card field, my bad. Is the 3.x branch going to be released soon? I tried to search it in the git but the last is 2.X

lkorth commented 8 years ago

3.x has already been merged to master and will be tagged and released soon.

It's up to you to add a button to trigger card scanning. There is an icon included in the library that may be useful to use as your button. The sample app includes a button in the toolbar to trigger card scanning.

dierivera commented 8 years ago

Yes i've seen the icon (I implemented the option menu with the scan option with the icon) but i was thinking on something like this: (where the scan button is next to the card field screenshot_2016-09-29-16-13-10

lkorth commented 8 years ago

There's nothing built into the library that would support that, you'd need to modify the layout and extend the CardForm class yourself.