Hello Friends, today, I will share with a snippet based on how we can create a simple card flip animation using CSS. Previously I have shared a snippet about Responsive Bootstrap 4 Cards Design. This project is also about the card, but I have shown a CSS animation of each card box's flipping effect when we hover over on it.
In this flipping profile card CSS animation, what will happen is that when someone hovers over, the image will transform and rotate 180 degrees horizontally. When the flip animation ends, we will see the information related to that image on the card's backside. We can use this project when we design testimonial or employee details of the website design.
In this simple card flip animation project using CSS, I have used bootstrap CSS and font-awesome icons along with HTML and CSS. I have included the CDN libraries for your convenience below to copy those and directly start your project.
In the HTML markup, I have taken a div element with the class name 'box-area,' and that will act as the cards' container. Then I have used the bootstrap container and row class to give some pre-defined margin padding from the framework. Inside row class, I have taken three bootstrap column grid. Inside each column grid, I have taken another div element named 'single-box' and provided and an in a div called 'front' and all the information about that image in a separate box named 'back.'
You May Also Like:
- Animated Typewriter text effect using JQuery
- Ribbon Navigation Menu using HTML and CSS
- Navbar with Slider using HTML CSS & Bootstrap 4
In the CSS part, I have taken 'Lato' as the primary font of the snippet. I have provided a custom padding from top and bottom for the card container class 'box-area.' I have given custom with and height of 350px for each 'single-box' div elements. After applying some basic styling for all the elements of the front and back component, I used CSS transform and backface-visibility property to create a CSS animation effect on the hover
Card Flip Animation Using CSS (Source Code) :
To create this snippet, you need to create two files. One of them is an HTML file, and another one is the CSS file. Then copy the HTML and CSS code and paste it to the appropriate files and save them.
REQUIRED FILES
HTML
CSS
That's it for this tutorial. I hope it helps. Please follow this blog on our Twitter and Facebook Group to keep yourself updated about the latest post.
Post a Comment
Please do not enter any spam link in the comment box.