Home > Article > Web Front-end > css3 click to display ripple effects
css3 click to display ripples special effect, how to use css3 to make click to display ripples special effect, what aspects should be paid attention to when clicking to display ripples special effects? Let’s give you a case.
<!DOCTYPE html> <html > <head> <meta charset="UTF-8"> <title>css3点击出现不同颜色涟漪特效</title> <meta name="keywords" content=" css3点击出现不同颜色涟漪特效 " /> <meta name="description" content=" css3点击出现不同颜色涟漪特效 " /> <style> /* NOTE: The styles were added inline because Prefixfree needs access to your styles and they must be inlined if they are on local disk! */ .ripple{ position:absolute; width:100vmax; height:100vmax; top:-50vmax; left:-50vmax; border-radius:50%; } body{ overflow:hidden; } .pad{ position:absolute; left:0; right:0; top:0; bottom:0; } </style> </head> <body> <!-- touch or click --> <div></div> <script src="js/index.js"></script> </body> </html> Css部分: .ripple{ position:absolute; width:100vmax; height:100vmax; top:-50vmax; left:-50vmax; border-radius:50%; } body{ overflow:hidden; } .pad{ position:absolute; left:0; right:0; top:0; bottom:0; }
So much for Css3 click display ripple effects. For more exciting content, please pay attention to php Chinese website Other related articles!
Related reading:
How to create a flying butterfly animation with CSS3
How to use canvas to realize the interaction between the ball and the mouse
How to use canvas to create the effect of particle fountain animation
The above is the detailed content of css3 click to display ripple effects. For more information, please follow other related articles on the PHP Chinese website!