在 CSS font-weight 属性上执行动画效果
要通过 CSS 在 font-weight 属性上实现动画效果,可以尝试运行以下代码
示例
<!DOCTYPE html> <html> <head> <style> p { border: 2px solid black; width: 400px; height: 100px; animation: myanim 5s infinite; } @keyframes myanim { 70% { font-weight: bold; } } </style> </head> <body> <p>This is demo text</p> </body> </html>
广告