请老师检查一下,谢谢。

来源:2-14 编程练习

慕斯卡2474635

2021-07-09 18:35:26

<!Doctype html>

<html lang="en">

<head>

<meta charset="UTF-8">

<title>空间移动</title>

<style>

    * {

        margin0;

        padding0;

    }


    .box {

        width200px;

        height200px;

        margin200px auto;

        perspective300px;

        positionrelative;

    }


    .box p {

        positionabsolute;

        left0;

        top0;

        width200px;

        height200px;

    }


    /* 补充代码 */

    .box p:nth-child(1) {

        background-colorrgb(255,0,0,.55);

        transform:rotateX(78degtranslatez(32px);

    }

    .box p:nth-child(2) {

        background-colorrgba(46236460.55);

        transform:rotateX(84degtranslatez(-2px);

    }

    .box p:nth-child(3) {

        background-colorrgb(4949247,.55);

        transform:rotateX(91degtranslatez(-36px);

    }

</style>

</head>

<body>

<div class="box">

    <p></p>

    <p></p>

    <p></p>

</div>

</body>

</html>


写回答

1回答

好帮手慕星星

2021-07-09

​同学你好,代码实现效果很棒。继续加油,祝学习愉快!

0

0 学习 · 15276 问题

查看课程