动画CSS边距底部属性
要使用CSS在margin-bottom属性上实现动画,您可以尝试运行以下代码
示例
<!DOCTYPE html> <html> <head> <style> p { animation: mymove 3s infinite; margin-bottom: 20px; } @keyframes mymove { 70% { margin-bottom: 60px; } } </style> </head> <body> <p>This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! This is demo text! </p> <p>This is demo text 2!</p> </body> </html>