js+css实现水液体盛满容器进度条动画效果代码

代码语言:html

所属分类:进度条

代码描述:js+css实现水液体盛满容器进度条动画效果代码

代码标签: js css 液体 盛满 容器 进度条 动画

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

<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <style>
      * {
        padding: 0;
        margin: 0;
      }

      body {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100vh;
        background-image: linear-gradient(rgb(90, 90, 250), rgb(3, 3, 110));
      }

      .container,
      .wave {
        width: 200px;
        height: 200px;
        border-radius: 50%;
      }

      .container {
        border: 3px solid darkturquoise;
        padding: 10px;
        position: relative;
      }

      .wave {
        position: relative;
        background-color: skyblue;
        overflow: hidden;
      }

      .wave::before {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 300px;
        height: 300px;
        background-color: rgba(255, 255, 255, .8);
        border-radius: 40%;
        transform: translate(-50%, 100%);
        animation: wave 5s linear infinite, fillUp 1.........完整代码请登录后点击上方下载按钮下载查看

网友评论0