gpt4 book ai didi

html - 元素符号内缩进
  • 转载 作者:行者123 更新时间:2023-11-28 15:57:02 26 4
    gpt4 key购买 nike

    您好,我对要点右侧的缩进有疑问

    我添加了一段代码和一张图片,可以很好地解释其自身

    Image1

     <h1 style="display: block;margin: 0;padding: 0;color: #000000;font-family: Helvetica;font-size: 26px;font-style: normal;font-weight: bold;line-height: 125%;letter-spacing: normal;text-align: left;"><span style="font-size:28px"><strong><span style="color:#96c11f">Why now</span></strong></span></h1>    
    <ul>
    <li><span style="font-size:16px">Increase in buyers looking for businesses over the Christmas period.</span></li>
    <li><span style="font-size:16px">More sales agreed in January so be on the market in time.</span></li><br>
    </ul>

    最佳答案

    尝试减少 li 的边距以使元素符号向左移动,并增加/减少其 padding 以适应您想要的元素符号和文本之间的距离。

    h1 {
    display: block;
    margin: 0;
    padding: 0;
    font-family: Helvetica;
    font-style: normal;
    font-weight: bold;
    line-height: 125%;
    letter-spacing: normal;
    text-align: left;
    font-size: 28px;
    color: #96c11f;
    font-weight: bold;
    }
    ul {
    font-size: 16px;
    padding:0;
    margin-top:0;
    }
    ul li{
    margin-left:1em;
    padding-left:0;
    }
    <h1>Why now</h1> 
    <ul>
    <li>Increase in buyers looking for businesses over the Christmas period.</li>
    <li>More sales agreed in January so be on the market in time.</li>
    <br>
    </ul>

    关于html - 元素符号内缩进 <li>,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40928051/

    26 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com