如何增加Bootstrap进度条的字体大小并使文本居中?

时间:2016-04-12 10:44:27

标签: css twitter-bootstrap

如何轻松增加进度条内文本的字体大小?并垂直居中文本?

<div class="progressBarModal">
  <div class="progress">
    <div class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="100" aria-valuemin="100" aria-valuemax="100" style="width:100%">
      this should be huge
    </div>
  </div>
</div>

Example on Bootply

3 个答案:

答案 0 :(得分:1)

添加了一个新类,它覆盖了bootstrap中的默认字体大小

http://www.bootply.com/BmGzxifuk9

答案 1 :(得分:0)

使用以下HTML

<div class="progressBarModal">
  <div class="progress" style="height:30px">
    <div class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="100" aria-valuemin="100"
    aria-valuemax="100" style="width:100%;    font-size: xx-large;">
      this shoul be huge
    </div>
  </div>
</div>

答案 2 :(得分:0)

<div class="progressBarModal">
  <div class="progress" style="height:30px">
    <div class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="100" aria-valuemin="100" aria-valuemax="100" style="width:100%;    font-size: xx-large;">
      this shoul be huge
    </div>
  </div>
</div>

选中bootply