solid-design-system / solid

Monorepo for Union Investment's Solid Design System.
https://solid-design-system.fe.union-investment.de/x.x.x/storybook/
Other
18 stars 4 forks source link

feat[dev]: ✨ implement sd-flipcard component #1012

Closed yoezlem closed 2 weeks ago

yoezlem commented 2 months ago

User Story

As a user of the Solid Design System, I want to utilize a Flashcard component with flip animation to add dynamic and interactive content to pages, providing a visually engaging way to present and interact with information.

Documentation

https://www.figma.com/file/JZZL5QPXQVKVGt4CHBlNlz/Flashcard?type=design&node-id=1301-7360&mode=design&t=eaEgzwqpgma861CK-0

Hand-off

https://www.figma.com/file/JZZL5QPXQVKVGt4CHBlNlz/Flashcard?type=design&node-id=6-4&mode=design&t=eaEgzwqpgma861CK-0

Components detailed requirements

Props

Status Name Type Default Description
  • [ ]
frontVariant primary / primary-100 / gradient light-top / gradient light-bottom / gradient dark-top / gradient dark-bottom primary The sd-flashcards theme variant
  • [ ]
backVariant primary / primary-100 / gradient light-top / gradient light-bottom / gradient dark-top / gradient dark-bottom primary The sd-flashcards theme variant
  • [ ]
ratio 3:4 / 16:9 3:4 the ratio for the layout of the flashcard

CSS-Properties

Open Questions towards design

Technical Information

DoR

DoD

DoR

DoD

Vahid1919 commented 2 months ago

copied from Mario's comment on the main ticket: " make this thing just an element with two slots for frontside and backside, reducing it's logic to only "turning itself". Examples for that are e. g. https://github.com/jeffreyquan/flip-card-wc / https://codepen.io/jeffreyquan/pen/ZEByKRL or maybe https://www.webcomponents.org/element/@adaws/flip-card – in Figma we then inform that this component consists of two sides and we show all current implementations as examples."

van-nguyen-ht commented 1 month ago

@Vahid1919

Figma Branch

mariohamann commented 1 month ago

I just realized, that my comment was not taken into consideration:

@coraliefeil realized as well, that there might be quite some similarities between media-teaser and the content of the flipcard: https://github.com/solid-design-system/solid/issues/299#issuecomment-2033747295

Is there a reason, why this was not done in a more generic way by just providing two slots and make it independent from styling? (Unfortunately I was not part of the refinement.)