我需要在文本前後顯示帶點和文本的文本,如下面的屏幕截圖所示。要在一行中顯示的文本
文本應顯示在一行。這是我試過的代碼:
.before-text:before {
content: "•";
}
.before-text:after {
content: "";
border-bottom: 1px solid black;
width: 200px;
position: absolute;
margin-top: 7px;
}
.after-text:before {
content: "";
border-bottom: 1px solid black;
width: 200px;
position: absolute;
margin-top: 7px;
}
.after-text:after {
content: "•";
}
<span class="before-text"></span>
<div>Long long long text</div>
<span class="after-text"></span>
該生產線是重疊的點。 – athi
點將通過線只有你可以左右調整到-1或-2px ..這不會有任何問題..這種解決方案是靈活的,可以在任何設備上工作。 –
是否可以用flex做到這一點? – athi