r/reactjs • • May 25 '20

Show /r/reactjs Select Payment (Swipe Card)

664 Upvotes

33 comments sorted by

13

u/pi22a3 May 25 '20

3

u/gnarly_surfer May 25 '20

That looks really nice! And thanks for releasing the source alongside it!

150

u/throwawaysasha303 May 25 '20

Looks cool! But the transition time is too long, those numbers keep spinning

83

u/KanadaKid19 May 25 '20

Also I don't think the CVV number should be animated this way. It should be treated like a string. Expiry dates and balances have an interval relationship CVVs don't have.

17

u/ijmacd May 26 '20 edited May 26 '20

To me it's strange that even the balance interpolates. There's no money being transferred as you swipe, the values aren't changing.

The digits spinning from one value to the next makes more sense to me and would work equally well for numbers or strings like CVV.

I'm thinking of those old flip clocks or railway/airport departure boards.

8

u/[deleted] May 25 '20

+1. .2-.3 s should nice for transition.

52

u/Monsieur_Joyeux May 25 '20

It looks really nice, but I prefer a simple drop-down where I can see every cards and immediately pick one rather than shuffle all of them to find one ^

24

u/swyx May 25 '20

it's Art, its not meant to be useful!

84

u/[deleted] May 25 '20

Looks very nice but probably not something that should ever be used in an interface

28

u/Guisseppi May 25 '20

Not gonna lie, this looks sexy af

17

u/scoops22 May 25 '20

Holy shit this fictitious person is in a lot of debt lol

11

u/striedinger May 25 '20

Cool and all but, accessibility > cool animations. Especially when dealing with payments.

1

u/DahPhuzz May 25 '20

Nice! Do you have a repo for this demo?

6

u/b14cksh4d0w369 May 25 '20

This is too American for me.

2

u/mcirillo May 25 '20

Oh no I can't find my holo-foil charizard

2

u/pixeldrift May 25 '20

Might need to be a little snappier, and have alternate ways to interact for the impatient. Like being able to click/tap for previous and next instead of dragging. Or a regular list paired with it. And inertial scrolling so you can skip through a bunch quickly instead of one at a time if you want to zip straight to the last card. In fact, I'd want the option of a grid. I have never once used Cover Flow in MacOS.

2

u/SomebodyFromBrazil May 25 '20

Looks cool. But each card is unique, so is its information, Balance, CVC, Expiration. The card identity is tied to this info and interpolating the values breaks each card's identity.

I believe that a slide-in/out transition would be better to convey this

1

u/blowingfish May 25 '20

Really nice. One thing I would change is when you swipe up on the current card, it should switch to the next and not just do the animation.

1

u/[deleted] May 25 '20

Nice work now get that balance under control! Lol

1

u/mokkai_moonji May 25 '20

Safari mobile looks wonky.

1

u/Nasuss May 25 '20

Wow this is beautiful awesome job! Was this for fun, work or a personal project?

1

u/Zofren May 25 '20

Looks really nice but I'd be annoyed if I had to use this on a site tbh

1

u/SnailsForPresident May 25 '20

this really looks amazing! As a developer you should not only develop what has the highest usability potential, but also sometimes just put a smile on some faces. And you did just that.

1

u/abmind0 May 26 '20

Rich af

1

u/[deleted] May 26 '20

Shouldn't the chip be in the middle?

1

u/mn_commenter May 26 '20

This is real cool man! Are you going to share source code???

1

u/edgetheraited Jun 13 '20

Where did you learn to do this animation?

0

u/chanchanito May 25 '20

looks very good! nice work :)
- a nice-to-have would be adding vertical scroll to cycle through cards.
- tested it on Safari and the cards don't overlap correctly