我想让文本标题响应。正如您在3210中看到的,标题是“The Swift List”。我怎样才能让单词“THE”和“LIST”保持在单词“SWIFT”的边缘?我设法在正常的屏幕尺寸下这样做,但是当我改变屏幕尺寸时,它不像以前那样保持(在“SWIFT”单词的边缘)。响应文本标题
对于那些不想在新选项卡中打开的人。我写的代码:
HTML
<p><span class="wordThe">THE</span>
<br><span class="textSwift">SWIFT</span>
<br><span class="wordList">LIST</span>
.carInfo {
background: #05196b;
height: 291px;
color: #fff;
padding: 15px 50px;
}
.wordThe {
font-weight: bold;
color: #ff1414;
font-size: 2.5em;
padding-left: 12%;
}
.textSwift {
padding-left: 24%;
font-style: italic;
font-size: 4.5em;
font-weight: bold;
color: #fff;
line-height: 0.5;
}
.wordList {
font-weight: bold;
color: #ff1414;
font-size: 2.5em;
padding-left: 67%;
}
.textAtRight {
text-align: justify;
direction: rtl;
clear: both;
float: right;
letter-spacing: 1.5px;
}
<div class="row">
<div class="col-md-6">
<div class="carInfo">
<p><span class="wordThe">THE</span>
<br><span class="textSwift">SWIFT</span>
<br><span class="wordList">LIST</span>
<span class="textAtRight"><br>Lorem ipsum dolor sit amet
<br>Consectetur adipisicing elit
<br>dolor in reprehenderit in voluptate
<br>velit esse cillum dolore eu
<br>proident, sunt in culpa qui officia</span></p>
</div>
</div>
</div>
你可以添加文本的scrn.shot与你真正想要的确切位置吗? – Vishnu
@Vishnu https://snag.gy/KgPQL8.jpg - 这是我想如何使文字具有准确的位置。 –