当前位置: 首页 > 知识库问答 >
问题:

javascript - 这种样式怎么实现?

荀俊迈
2023-07-26

image.png
想问下这种样式怎么实现

共有2个答案

楮杰
2023-07-26
<!DOCTYPE html><html lang="en"><head>    <meta charset="UTF-8">    <meta name="viewport" content="width=device-width, initial-scale=1.0">    <title>Document</title></head><style>    .box {        height: 21px;        padding: 4px;        background: #ccc;        color: #000;        width: fit-content;    }    .hui {        color: gray;    }    .lan {        background: rgb(161, 161, 201);        color: blue;    }    .flex {        display: flex;        align-items: center;    }    .m-l-10 {        margin-left: 10px;    }    .ju {    width: 50px;    height: 50px;    border: 2px solid #ccc;    margin-left: 10px;    border-right-color: transparent;}</style><body>    <div>        <div class="flex">            <div class="box hui">且1</div>            <div class="box lan m-l-10">或</div>            <div class="ju"></div>            <div class="box  m-l-10">或1111</div>        </div>    </div></body></html>

image.png

方和豫
2023-07-26

你说的是那个线吗?想象一下,一个矩形,加上边框,然后去除右边框,不就出来了?

 类似资料: