現在我正在使用多個標題標籤和一個css類來實現下圖中顯示的效果,有沒有什麼辦法可以通過使用只是一個標題/行和CSS?如何用CSS和/或Javascript實現這種效果(換行符)
目前代碼:
<h2 class="heading">Hi guys, How can i achieve this effect using just a single</h2>
<div class="clearfix"></div>
<h2 class="heading">line of text and css. Right now i am using</h2>
<h2 class="heading">multiple <h2> tags and a css class to achieve this effect.</h2>
<h2 class="heading">Is it possible to achieve this only with css or do i have to use Javascript as well?</h2>
期望碼
<h2 class="heading">Hi guys, How can i achieve this effect using just a single line of text and css. Right now i am using multiple <h2> tags and a css class to achieve this effect. Is it possible to achieve this only with css or do i have to use Javascript as well?</h2>
這個根據我的是,我不能讓它響應不降低的字體大小,填充,等我穿上」的主要問題不想要。
即使我讓它響應我不能添加換行符,無論我想要什麼,而無需使用其他標籤或JavaScript。
你們是如何解決這個問題的?
簡答題:No. – Tomalak
是什麼讓第一行比最後一行快? – PeeHaa
沒有額外的html/css,這種情況不會發生,因爲每一行都以不同的寬度斷開,並且有些任意。我不知道如何讓這段文字響應如果a)你想在每一行保留相同的文本,而b)不改變字體大小。 JavaScript不應該是必要的。 –