Yogesh Chauhan's Blog

Add animation to your skills bar using CSS

in CSS on July 31, 2021

Similar Post

Learn to create your skill bar using CSS

Let’s add some basic animation to the skills bar from the post above. Also, let’s polish elements with some styles too.

Let’s discuss a few CSS rules that will be used to add animation.

This code will create an animation using @keyframes that you can use for containers.

Using scaleX you can scale the element on x-axis which is what we want for the skill bars.


@keyframes fill {
  0% {
    opacity: 1;
    transform: scaleX(0);
  }

  100% {
    opacity: 1;
    transform: scaleX(1);
  }
}

Also, you need to set the transform-origin property to left. It will force the animation to start from left.


transform-origin: left;

Demo


Most Read

#1 How to check if radio button is checked or not using JavaScript? #2 How to add Read More Read Less Button using JavaScript? #3 Solution to “TypeError: ‘x’ is not iterable” in Angular 9 #4 Solution to the error “Visual Studio Code can’t be opened because Apple cannot check it for malicious software” #5 How to uninstall Cocoapods from the Mac OS? #6 PHP Login System using PDO Part 1: Create User Registration Page

Recently Posted

#Apr 8 JSON.stringify() in JavaScript #Apr 7 Middleware in NextJS #Jan 17 4 advanced ways to search Colleague #Jan 16 Colleague UI Basics: The Search Area #Jan 16 Colleague UI Basics: The Context Area #Jan 16 Colleague UI Basics: Accessing the user interface
You might also like these
Window setInterval() Method in JavaScriptJavaScriptHow to create a link tag button using CSS?CSSHow to remove border from :visited image, link or button?CSSHow to make a Custom Login Page in WordPress?WordPressEffects in ReactReactHow to CREATE TABLE in SQL with and without using Another Table?SQL/MySQLThe fundamental difference between HAVING and WHERE clauses in PostgresPostgresWhat is IPS(Intrusion Prevention System), How Does It Work and What are the Detection Types?MiscellaneousHow to Find the Highest (or Lowest) Number in an Array in JavaScript?JavaScriptFull and Partial CUBE in Postgres with ExamplesPostgresWhat is Hadoop and Hadoop Ecosystem?MiscellaneousHow to check if radio button is checked or not using JavaScript?JavaScript