bootstrap css選擇不同的寬度

來源:互聯網
上載者:User

剛開始使用bootstrap css開源項目。遇到一個問題,預設的input 寬度太大,需要找小一點的。

其實只需要在input tag中選用預定義的較小的寬度即可。比如:

<input type="number" class="input-small"></input>

input-small是預定義的一種類別,在bootstrap.css檔案中有一組這樣的類別:

.input-mini {  width: 60px;}.input-small {  width: 90px;}.input-medium {  width: 150px;}.input-large {  width: 210px;}.input-xlarge {  width: 270px;}.input-xxlarge {  width: 530px;}

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.