보기 장치의 너비에 관계없이 두 줄을 함께 묶어 야합니다.CSS 또는 HTML과 함께 줄 바꿈
이유는 line2는 항상 line1 등을 설명합니다. 응답은 바인딩되어야합니다. 즉, 화면의 너비가 변경되면 여전히 바인딩되어야합니다.
단어로 바인딩 할 수도 있습니다. 첫 번째 줄과 두 번째 줄의 단어가 항상 서로 아래에 있음을 의미합니다 (두 줄 중 가장 긴 폭을 중심으로 함).
는
CSS/HTML 갖는 솔루션이 업데이트 ??
#container div:nth-child(odd){
background-color: gray;color:white;
}
<div id="container">
<div>This is line 1 text, we assume responsiveness.This is line 1 text, we assume responsiveness.This is line 1 text, we assume responsiveness.This is line 1 text, we assume responsiveness.</div>
<div>This line is bound to line1 no matter whatThis line is bound to line1 no matter whatThis line is bound to line1 no matter whatThis line is bound to line1 no matter what</div>
<div>This line is the main contentThis line is the main contentThis line is the main contentThis line is the main contentThis line is the main contentThis line is the main content.</div>
<div>This line is bound and explains content of line 1.This line is bound and explains content of line 1.This line is bound and explains content of line 1.</div>
</div>
Div1에서 항상 1 줄, Div2에서 다음 줄로 지정하고 싶습니다.
그래서 다음과 같아야합니다
This is my text, it tells a story about a cat which was
这是我的文字,它讲述了一个故事一只猫是什么哪
always angry and attacked even humans. One day the cat
总是生气,甚至攻击人类。有一天,猫
첫 번째 줄은 영어 텍스트이며, 다음 줄은 항상 번역 된 텍스트되어야한다. 라인의 너비가 다양하기 때문에 응답 성을 높이기가 어렵습니다.
텍스트는 더 이상 부모 컨테이너의 100 % 너비보다 일단은 볼이 유지되도록
명백한 폭을 복원하기 위해 200 % 폭으로 컨테이너를 설정 –
당신이 할 수있는 정확하게 당신이 찾고있는 것을 정확히 설명하십시오 – Geeky
"바운드"란 무엇을 의미합니까? 어쩌면 사진을 좀 줄래? –