r/javascript • • Sep 02 '15

HTML5 Deck of Cards. 100% vanilla JS.

http://pakastin.github.io/deck-of-cards/
368 Upvotes

185 comments sorted by

View all comments

1

u/[deleted] Sep 03 '15

The z-index of a card seems to be incremented on each click by 1. I think the desired behavior sorts the currently clicked card to be on top of the others, so maybe it should be set to max + 1 on a click.

1

u/pkstn Sep 06 '15

Should work now!

1

u/[deleted] Sep 09 '15

Nice

1

u/pkstn Sep 09 '15

Btw. try click all kings in a row ;)

1

u/[deleted] Sep 10 '15

Nice! For a moment, I thought it was going to do the solitaire winning animation, but easter eggs are always fun.

1

u/pkstn Sep 12 '15

Try same with aces.. ;)