随着屏幕变小,缩短文本长度

时间:2020-02-23 14:36:12

标签: html css

我希望屏幕变小时缩小文本长度

<div class="dress-card hvr-bob">
  <div class="dress-card-head">
    <img class="dress-card-img-top" src="img/rdr2.jpg" alt="">
  </div>
  <div class="dress-card-body">
    <h2 class="dress-card-title">Red Dead Redemption 2</h2>
    <p class="dress-card-para">Social Club Key</p>
    <p class="dress-card-para"><span class="dress-card-price">200TL &ensp;</span>
      <!--<span class="dress-card-crossed">300TL</span><span class="dress-card-off">&ensp;İndirim!</span>--></p>
    <div class="row">
      <div class="col-md-6 card-button">
        <a style="text-decoration: none;" href="">
          <div class="card-button-inner bag-button"><i class="fas fa-shopping-cart"></i> Satın Al</div>
        </a>
      </div>
      <div class="col-md-6 card-button">
        <a style="text-decoration: none;" href="">
          <div class="card-button-inner wish-button"><i class="fas fa-shopping-basket"></i> Sepete Ekle</div>
        </a>
      </div>
    </div>
  </div>
</div>
</div>

帮助

1 个答案:

答案 0 :(得分:0)

font-size:8vw;添加到CSS。您可以将其添加到p或特定于类或ID的文件中。 您可以将8更改为所需的任何数字。 我希望这就是您搜索的内容:)