svg+css实现打电话呼叫中动画扩散图标闪动代码

代码语言:html

所属分类:动画

代码描述:svg+css实现打电话呼叫中动画扩散图标闪动代码

代码标签: svg css 打电话 呼叫 动画 扩散 图标 闪动 代码

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
<style>
    @import url("https://fonts.googleapis.com/css?family=Roboto:400,400i,700");
html,
body {
  height: 100%;
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

html {
  font-family: "Roboto";
  background-color: #0f111e;
}

body {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ripple {
  position: absolute;
  z-index: -1;
  inset: 0;
  background-origin: content-box;
  background-position: center;
  background-repeat: no-repeat;
  background-image: radial-gradient(circle at center, transparent, #ededed33 1%, transparent 3%), radial-gradient(circle at center, transparent, #ededed33 10%, transparent 13%), radial-gradient(circle at center, transparent, #ededed33 20%, transparent 23%);
  animation-name: ripple;
  animation-timing-function: ease-out;
  animation-duration: 3s;
  animation-iteration-count: infinite;
}

.icon {
  background-color: #f5b546;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  animation-name: pulse;
  animation-timing-function: ease-out;
  animation-duration: 3s;
  animation-iteration-count: infinite;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.text {
  position: fixed;
  bottom: 10%;
  font-size: 2rem;
  font-weight: 700;
  color: white;
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  5% {
    transform: scale(1.1);
  }
  10% {
    transform: scale(0.9);
  }
  12% {
    transform: scale(1.1);
  }
  17% {
    transform: scale(0.9);
  }
  100% {
    transform: scale(1);
  }
}
@keyframes ripple {
  0% {
    background-size: 100%;
    opacity: 0.1;
  }
  10% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.2;
  }
  100% {
    background-size: 1000%;
    opacity: 0;
  }
}
</style>
    </head>
    <body>

        <div class="rippl.........完整代码请登录后点击上方下载按钮下载查看

网友评论0