tests/refactor of card ui