博主信息
博文 8
粉丝 0
评论 0
访问量 7874
热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
0509作业——制作太极图
一把青的博客
原创
677人浏览过
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>太极图作业</title>
    <style type="text/css">
        .background {
            width: 400px;
            height: 400px;
            margin: 0 auto;
            background-color: gold;
            padding-top: 99px;
            box-sizing: border-box;
        }
        .circle-box {
            width: 200px;
            height: 200px;
            border-radius: 50%;
            /*border: 1px solid #ff0000;*/
            position: relative;
            background: #fff;
            margin: 0 auto;
            overflow: hidden;
        }
        .bg-mask {
            width: 100%;
            height: 100px;
            background-color: #000;
        }
        .circle-black-m,.circle-white-m{
            width: 100px;
            height: 100px;
            border-radius: 50%;
        }
        .circle-black-m {
            background-color: #000;
            position: absolute;
            top: 51px;
        }
        .circle-white-m {
            background-color: #fff;
            /*border: 1px solid #ff0000;*/
            position: absolute;
            top: 50px;
            right: 0;
        }
        .circle-white,.circle-black {
            width: 30px;
            height: 30px;
            border-radius: 50%;
            position: absolute;
        }
        .circle-white {
            background-color: #fff;
            top: 45px;
            left: 35px;
        }
        .circle-black {
            background-color: #000;
            top: 25px;
            left: 35px;
        }
        /*鼠标经过变色*/
        /*.circle-box:hover {
            background: #000;
        }
        .circle-box:hover .bg-mask{
            background-color: #fff;
        }*/
        /* 动画代码 */
        @keyframes turnZ {
          0%   {transform: rotateZ(360deg);}
          100% {transform: rotateZ(0deg);}
        }

        /* 应用动画的元素 */
        .circle-box:hover {
          animation-name: turnZ;
          animation-duration: 4s;
          animation-iteration-count: 1;
        }

    </style>
</head>
<body>
    <div class="background">
        <div class="circle-box">
            <div class="bg-mask"></div>
            <div class="circle-black-m">
                <div class="circle-white"></div>
            </div>
            <div class="circle-white-m">
                <div class="circle-black"></div>
            </div>
        </div>
    </div>
</body>
</html>
批改老师:PHPzPHPz

批改状态:合格

老师批语:
本博文版权归博主所有,转载请注明地址!如有侵权、违法,请联系admin@php.cn举报处理!
全部评论 文明上网理性发言,请遵守新闻评论服务协议
0条评论
作者最新博文
关于我们 免责申明 意见反馈 讲师合作 广告合作 最新更新 English
php中文网:公益在线php培训,帮助PHP学习者快速成长!
关注服务号 技术交流群
PHP中文网订阅号
每天精选资源文章推送
PHP中文网APP
随时随地碎片化学习
PHP中文网抖音号
发现有趣的

Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号

  • 登录PHP中文网,和优秀的人一起学习!
    全站2000+教程免费学