Created
October 29, 2020 07:40
-
-
Save thisiszoaib/b463934063c995bdb4e526468a2769a6 to your computer and use it in GitHub Desktop.
card flip 2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| :host { | |
| display: block; | |
| perspective: 600px; | |
| } | |
| .card { | |
| box-shadow: 10px 10px 43px -18px rgba(0, 0, 0, 0.75); | |
| border-radius: 5px; | |
| height: 300px; | |
| width: 200px; | |
| cursor: pointer; | |
| position: relative; | |
| transform-style: preserve-3d; | |
| } | |
| .face { | |
| display: block; | |
| position: absolute; | |
| width: 100%; | |
| height: 100%; | |
| border-radius: inherit; | |
| backface-visibility: hidden; | |
| > img { | |
| width: 100%; | |
| height: 100%; | |
| object-fit: cover; | |
| border-radius: inherit; | |
| } | |
| } | |
| .front { | |
| transform: rotateY(180deg); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment