HTML画一个蔡徐坤背带裤?来,满足你,ikun们进来!!!!!

此代码示例展示了如何使用HTML、CSS和JavaScript创建一个爱心形状的动画效果,并通过粒子系统实现动态飘落的效果。CSS用于布局和动画,JavaScript部分则用于生成和更新粒子,使得动画更加生动。升级版增加了尺寸和元素的调整,以适应不同屏幕大小。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

<!DOCTYPE html>
<html lang=en>
<head>
    <meta charset=UTF-8>
    <meta http-equiv=X-UA-Compatible content=IE=edge>
    <meta name=viewport content=width=device-width, initial-scale=1.0>
    <title>ikun</title>
</head>
<body>
    <div class="containner">
        <div class="circle_top">
        <div class="box_left"></div>
        <div class="box_right"></div>
        </div>
        <div class="circle_bottom"> </div>
    </div>
</body>
<style>
    .containner{
        width: 200px;
        height: 200px;
        margin: 60px auto;
        /* background-color: aqua; */
    }
    .circle_top{
        border: 1px solid gray;
        /* border-radius: 50%; */
        border-radius: 100px 100px 0 0;
        width: 200px;
        height: 100px;
        background-color: black;
        position: relative;
    }
    .circle_bottom{
        border: 1px solid gray;
        /* border-radius: 50%; */
        border-radius:0 0 100px 100px;
        width: 200px;
        height: 100px;
        margin: 10px auto;
        background-color: gray;
    }
    .box_left{
        height: 105px;
        width: 10px;
        background-color: white;
        position: absolute;
        border-radius: 5px;
        bottom: -10px;
        transform: translateX(60px) rotate(-20deg);
    }
    .box_right{
        height: 105px;
        width: 10px;
        background-color: white;
        border-radius: 5px;
        bottom: -10px;
        position: absolute;
        transform: translateX(130px) rotate(20deg);
    }
</style>
<script>
    
</script>
</html>

升级版

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8" />
    <title>💗</title>
 
    <style>
      html,
      body {
        height: 100%;
        padding: 0;
        margin: 0;
        background: #000;
      }
      canvas {
        position: absolute;
        width: 100%;
        height: 100%;
        animation: anim 1.5s ease-in-out infinite;
        -webkit-animation: anim 1.5s ease-in-out infinite;
        -o-animation: anim 1.5s ease-in-out infinite;
        -moz-animation: anim 1.5s ease-in-out infinite;
      }
      #name {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        margin-top: -20px;
        font-size: 46px;
        color: #ea80b0;
      }
      @keyframes anim {
        0% {
          transform: scale(0.8);
        }
        25% {
          transform: scale(0.7);
        }
        50% {
          transform: scale(1);
        }
        75% {
          transform: scale(0.7);
        }
        100% {
          transform: scale(0.8);
        }
      }
      @-webkit-keyframes anim {
        0% {
          -webkit-transform: scale(0.8);
        }
        25% {
          -webkit-transform: scale(0.7);
        }
        50% {
          -webkit-transform: scale(1);
        }
        75% {
          -webkit-transform: scale(0.7);
        }
        100% {
          -webkit-transform: scale(0.8);
        }
      }
      @-o-keyframes anim {
        0% {
          -o-transform: scale(0.8);
        }
        25% {
          -o-transform: scale(0.7);
        }
        50% {
          -o-transform: scale(1);
        }
        75% {
          -o-transform: scale(0.7);
        }
        100% {
          -o-transform: scale(0.8);
        }
      }
      @-moz-keyframes anim {
        0% {
          -moz-transform: scale(0.8);
        }
        25% {
          -moz-transform: scale(0.7);
        }
        50% {
          -moz-transform: scale(1);
        }
        75% {
          -moz-transform: scale(0.7);
        }
        100% {
          -moz-transform: scale(0.8);
        }
      }
    </style>
    <style>
      .bg{
        background-color: black;
        width: 200px;
        height: 210px;
        margin: 60px auto;
        border-radius: 50%;
        overflow: hidden;
        animation: anim 1.5s ease-in-out infinite;

        /* padding-top: 10px; */
    }
      .containner{
        width: 200px;
        height: 210px;
        margin: auto;
        /* margin: 60px auto; */
        background-color:white;
        border-radius: 50%;
          /* background-color: aqua; */
      }
      .circle_top{
          border: 1px solid gray;
          /* border-radius: 50%; */
          border-radius: 100px 100px 0 0;
          width: 200px;
          height: 100px;
          background-color: black;
          position: relative;
      }
      .circle_bottom{
          border: 1px solid gray;
          /* border-radius: 50%; */
          border-radius:0 0 100px 100px;
          width: 200px;
          height: 100px;
          margin: 10px auto;
          background-color: gray;
      }
      .box_left{
          height: 105px;
          width: 10px;
          background-color: white;
          position: absolute;
          border-radius: 5px;
          bottom: -10px;
          transform: translateX(60px) rotate(-20deg);
      }
      .box_right{
          height: 105px;
          width: 10px;
          background-color: white;
          border-radius: 5px;
          bottom: -10px;
          position: absolu
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值