text-indent不适用于包装文本 [英] text-indent not working for wrapped text

查看:67
本文介绍了text-indent不适用于包装文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hi, I have ul and li tag. Inside full ul tag i had text-indent only for first li. for a long text with first li, it wraps text this is good but the wrapped text didn't have text-indent. I goggled for this but any code and logic suggested won't work for me. This content is dynamic.







<ul class="dynctrl_hidden dynctrl_padding" style="display: block;">
        <li style="text-indent: 25px;">Endoscopic mucosal resection (EMR)</li>
        <li>  <input type="checkbox" name="Endoscopic mucosal resection (EMR)" class="dynctrl_hidden dynctrl_padding" id="test" style="display: block;"></li>
<br clear="all"></ul>







 This produces the result the below 
Endoscopic mucosal resection  "checkbox" here
(EMR)
But i want the below one
Endoscopic mucosal resection (EMR) "checkbox" here







.dynctrl_padding{
text-indent: 25px;
}
.dynctrl_padding{
width: 250px;
float: left;
margin-right: 2px;
}
.ul{
list-style: none;
}

li{
display: list-item;
text-align: -webkit-match-parent;
}

推荐答案

为什么不试试
padding-left

而不是

text-indent


这篇关于text-indent不适用于包装文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆