2017-01-19 365 views
-1

我在Chrome中遇到了縮進格式問題。我已將縮進設置爲-14px,以便文本排列起來。這在Safari和Firefox Developer Edition中運行良好,但在Chrome中似乎不起作用。 Chrome正在檢測類和縮進,但它需要-30px才能正確排列文本。在Safari/Firefox和Chrome中不同的CSS

請參閱手風琴,以供參考 「Rubriky」 部分:

http://marianrehak.cz/dcd/reseller-magazine-online/

你有什麼建議嗎?

+0

我不會在這裏使用文本縮進可言,而只是'列表樣式位置:outside' – CBroe

+1

不要SO共享外部鏈接。粘貼這裏複製你的問題的相關代碼 –

回答

1

您需要將列表位置屬性設置爲外部。默認情況下,將這些項目符號放在列表項左側的縮進處。 因此list-style: outside;將解決這個問題。

.mytest { 
 
    list-style: square outside; 
 
}
<ul class="mytest"> 
 
    <li>bal 1</li> 
 
    <li>bal 2 add her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrapadd her come lot of test so we get line wrap, add her come lot of test so we get line wrap</li> 
 
    <li>bal 3</li> 
 
    <li>bal 4</li> 
 
    <li>bal 5</li> 
 
    <li>bal 6</li> 
 
    <li>bal 7</li> 
 
    <li>bal 8</li> 
 
    <li>bal 9</li> 
 
    <li>bal 10</li> 
 
    <li>bal 11</li> 
 
</ul>

+0

非常感謝。我其實不知道列表樣式屬性有這個選項。非常感激。 –

相關問題