css实现发光按钮边框光晕动画效果代码
代码语言:html
所属分类:动画
代码描述:css实现发光按钮边框光晕动画效果代码,鼠标悬浮试试。
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8"> <style> :root { --size-default: 22px; --size-sm: 16px; --color-green: #58DD93; --color-black: #000; } @property --angle { syntax: "<angle>"; initial-value: 0deg; inherits: false; } @property --glowColor { syntax: "<color>"; initial-value: #58DD93; } @keyframes rotate { 0% { --angle: 0deg; --glowColor: var(--color-green); } 100% { --angle: 360deg; --glowColor: var(--color-green); } } * { box-sizing: border-box; } html, body { width: 100%; height: 100%; background: #000; background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, var(--color-black) 100%), radial-gradient(circle at 50% -50%, #335F4B 0%, var(--color-black) 100%); font-family: monospace; font-size: 20px; } .container { display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; padding: 16px; } .btn { display: flex; align-items: center; justify-content: center; border-radius: 100px; border: none; background: none; position: relative; padding: 1px; text-decoration: none; transition: all 0.18s ease-in-out; transform: translate3d(0, 0, 0); } ..........完整代码请登录后点击上方下载按钮下载查看
网友评论0