23  December
74

CardsUI

Google’s Now popular Cards UI has everyone fascinated.

Now a library I created mimicking that behaviour is available.

The view might still be a little flaky, and the View’s code is not well documented, but the example really shows you how simple it all is.

Layout XML:

Activity Class:

You can download the example APK.

or Clone the lib from Bitbucket or Github

Clone from Bitbucket

Download from GitHub

 

Some Awesome Forks:

 

https://github.com/Androguide/cardsui-for-android

 

74 comments on “CardsUI”

  1. hans stam Reply

    I need this view now, any way i can get it soon?

  2. bqy Reply

    nice!

  3. driodek Reply

    Any chance to know when this library will be available?

  4. jophde Reply

    I was wondering if this is on Github? I would love to contribute.

    • Nadav Fima Reply

      Hi,
      The library is now available on Bitbucket.
      Enjoy!

      • ingyesid

        in android < 4.0 the view not work !

  5. snodnipper Reply

    Really looking forward to this :)

  6. Akhil Indurti Reply

    I am also looking forward to this! :D

  7. Vitaliy Reply

    Any news about this library ?

  8. Karey Powell Reply

    Please let me know when this library is ready … :)

  9. HandlerExploit Reply

    Can this be removed and only re-added when it is actually real? It smells of vaporware.

  10. Nadav Fima Reply

    Not vaporware mate,
    The library is now available on Bitbucket.
    Enjoy!

    • Adit Lal Reply

      How to access the lib on bitbucket , says i am not allowed to access

  11. Sleepy Panda Labs (@SleepyPandaLabs) Reply

    Thanks Nadav! Exactly what I was waiting for my redesigns!

  12. Eric Reply

    Thanks for the library! Testing it out myself, I found swiping a card away only brings it back

    • Akhil Indurti Reply

      make sure setSwipeable is true meaning you don’t setSwipeable(false)

      • Eric

        Yeah, I set it to true. I can swipe it away, but it reappears right away

    • Nadav Fima Reply

      Will be fixed in a few minutes

  13. CVE Reply

    Awesome!

    I have tried the example on 4.0 devices and everything is fine, but on 2.x devices, the card stacks are only shown as a single card (the last one of the stack)

    Is there a workaround, or am I doing something wrong?

  14. Nadav Fima Reply

    Sounds like on 2.x devices, the top margin isn’t considered at all.
    I’ll try to fix it later.

  15. Jeff Reply

    What kind of content can be added to the card view, Is it txt only? I just loaded the example apk I really didn’t look at the code

    • Nadav Fima Reply

      You can inflate it with any Layout XML.

  16. Sean Fair Reply

    Why don’t you use a feagment that implements a broadcast receiver? Or a similar pattern why so much extra work the cards don’t appear to be much more than that.

  17. kpbird Reply

    Awesome…

    Thank You.

  18. telik Reply

    I’m trying to use this in an app that utilizes fragments. I can inflate the layout like the example, but when I attempt to add cards to the CardUI, nothing actually shows up (even after calling refresh()).
    Any tips/pointers on how to appropriately use this in such a capacity? Seems like a really cool library!

    Thanks so much for sharing! :)

  19. Aman Alam Reply

    Exactly what I have been looking for.
    Would be checking compatibility on 2.x devices.
    Thanks a ton!

  20. Mohd Irteza Reply

    Really helpful library. Thank you so much for doing this! :) Loved using it. Will definitely be using it in my app.

  21. Patrick Reply

    Nice work! It would be nice to see a tablet layout, similar to Google+ layout.

  22. Kit Reply

    When I use a EditText in CardUI, the input content will not be saved.
    What can i do?

  23. Louis Reply

    I’m trying to change the cards theme to dark Holo, but no success so far, I’ve tried everything from modifying styles.xml/colors.xml to inverting the drawables colors, but no go, nothing even slightly changes.
    Could somebody please point me to the right direction ?

  24. WeNeigh Reply

    Does anyone know how I can reduce the margin between cards?
    I’ve been fiddling with the dimension values in item_card.xml and item_card_empty.xml, but they don’t seem to be doing anything!

  25. Kevin Hill Reply

    This needs better documentation. Other than that, it’s awesome!!

  26. Vinicius Alexandre Reply

    I’ve been trying to use an editText in a card, but when I touch the editText, it doesn’t get focus. Actually, it gets focus and right after it, lost the focus.

    Is this a known issue?

  27. Derric Reply

    The example shows how to set the onclick for each card statically, but how would you do that based on the index/position of the card??

    • Nona Reply

      Great application. Looks great on 10 telabt. After update works even more smoothly. Have just one dislike. Lacking options to customize sidebar with custom buttons for enable/disable GPS WiFi 3G/4G and so on. Would be nice feature since some telabts have hardware buttons for some of above functions like auto-rotate and flight mode. Otherwise great widget it worth every cent. Keep the good work.

  28. Josh Reply

    Anyone know how to keep the views from recycling? I load data to cards, but every time I scroll away and back it forces the cards to reload their data.

    • Josh Reply

      It appears that inside the Card itself, getCardContent is called each time it is scrolled to, thus the reloading.

      • Neil

        Were you able to figure out how to stop the cards from recycling? I am having this issue as well.

  29. UST Reply

    can i say something 中文

    • Chinese Reply

      yes you can , i could understand you

  30. Chinese Reply

    I don’t know how ? i use it to my program instead of the traditional listview style.

  31. David1111 Reply

    How can I add a share button to the top of the cards. I’ve implemented it in the xml with an on click method, but the app crashes when I press it and says that the method doesn’t exist.

  32. jychan Reply

    can anyone tell me how to use this library ?

  33. Donnie Emanuel Reply

    Thank you.

  34. adnan abdollah zaki Reply

    Very useful for my program , thanks

  35. iehey Reply

    Thanks for this great work! it’s a very cool Lib! Just one question, it’s possible to manage the “card-click” like onItemClickListener from traditional listviews? and get the card title or some information back from the card clicked by the user? Thanks!

  36. heron Reply

    where can i create cards without creating always a new class for every card?

  37. jeff Reply

    very nice , thx

  38. danidif Reply

    Very nice library, but refresh() does not work in a multicolumn layout, there’s something missing in the CardUI.refresh() code.

  39. heron Reply

    Hello,

    i want to report an issues:

    when i add a stack and click on the card in the stack iget an error
    the self i get by sample project.

  40. Avi Reply

    Hi is it possible to make one card swipeable and not the rest?

    Thank you.

  41. wasim Reply

    is it possible that we can use it in list view ??
    like Google now having…

  42. Avi Reply

    Hi there seems to be a bug with 2 card stack, the cards below the 2 card stack tries to move IP when wlswppinflg card within the stack. Is it a known bug or is something wrong with my code?

    Thanks
    Avi

  43. Deivison Reply

    Hi Nadav Fima,

    I’m trying add swipe up/down to change the cards but I’m having some issues, can we talk by mail ?

    Regards!

  44. Saravnan Reply

    how can i use this library? please tell me with any simple application or simple program..

  45. Antonio Reply

    How can I add an ID for every CARD that I build? I have to make an onClickListener on every Card.

Leave a comment

Please wait...