麻烦老师检查

来源:2-12 自由编程

dww1

2022-06-10 23:17:00

<style>
        *{
            box-sizing: border-box;
            margin: 0;
            padding: 0;
        }
        html{
            width: 100%;
            height: 100%;
        }
        body{
            width: 100%;
            height: 100%;
        }
        .box{
            width: 100%;
            height: 100%;
            background-color: rgba(65, 65, 65, 0.7);
        }
        .inner{
            width: 50%;
            background-color: #fff;
            border-radius: 8px;
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%,-50%);
            padding: 10px 20px;
        }
        p{
            text-align: center;
            margin-top: 10px;
        }
        .btn{
            display: flex;
            padding-top: 20px;
            justify-content: space-around;
        }
        button{
            display: flex;
            width: 50%;
            height: 40px;
            line-height: 40px;
            justify-content: center;
            margin-right:20px;
            border: none;
            color: #fff;
            font-size: 16px;
            border-radius: 10px;
        }
        button:first-child{
            background-color: blue;
           
        }
        button:last-child{
            margin-right: 0;
            background-color: #ccc;
        }
    </style>
</head>
<body>
    <div class="box">
        <div class="inner">
            <p>确认要删除吗?</p>
            <div class="btn">
                <button>确认</button>
                <button>取消</button>
            </div>
        </div>
    </div>
</body>


写回答

1回答

好帮手慕小李

2022-06-11

同学你好,代码可以实现需求很棒,继续努力!祝学习愉快!

0

0 学习 · 15276 问题

查看课程