Bootstrap CSS Yardımcı Sınıfları Referansı


Metin

Aşağıdaki sınıflarla metin renkleri aracılığıyla anlam ekleyin. Bağlantılar fareyle üzerine gelindiğinde kararacak:

Class Description Example
.text-muted Text styled with class "text-muted"
.text-primary Text styled with class "text-primary"
.text-success Text styled with class "text-success"
.text-info Text styled with class "text-info"
.text-warning Text styled with class "text-warning"
.text-danger Text styled with class "text-danger"

Arka plan

Aşağıdaki sınıflarla arka plan renkleri aracılığıyla anlam katın. Bağlantılar, metin sınıfları gibi üzerine gelindiğinde kararır:

Class Description Example
.bg-primary Table cell is styled with class "bg-primary"
.bg-success Table cell is styled with class "bg-success"
.bg-info Table cell is styled with class "bg-info"
.bg-warning Table cell is styled with class "bg-warning"
.bg-danger Table cell is styled with class "bg-danger"

Diğer

Class Description Example
.pull-left Floats an element to the left
.pull-right Floats an element to the right
.center-block Sets an element to display:block with margin-right:auto and margin-left:auto
.clearfix Clears floats
.show Forces an element to be shown (display:block)
.hidden Forces an element to be hidden (display:none)
.invisible Forces an element to be invisible (visibility:hidden). Will take up space on page even though it is invisible
.sr-only Hides an element to all devices except screen readers
.sr-only-focusable Combine with .sr-only to show the element again when it is focused (e.g. by a keyboard-only user)
.text-hide Helps replace an element's text content with a background image
.close Indicates a close icon
.caret Indicates dropdown functionality (will reverse automatically in dropup menus)


Duyarlı Yardımcı Programlar

Bu sınıflar, medya sorguları yoluyla içeriği cihaza göre göstermek ve/veya gizlemek için kullanılır.

İçeriği görünüm alanı kesme noktaları arasında değiştirmek için mevcut sınıflardan birini veya bir kombinasyonunu kullanın:

sınıflar Ekstra küçük cihazlar Telefonlar (<768px) Küçük cihazlar Tabletler (≥768px) Orta boy cihazlar Masaüstü bilgisayarlar (≥992px) Büyük cihazlar Masaüstü bilgisayarlar (≥1200 piksel)
.visible-xs-* Görünür Gizlenmiş Gizlenmiş Gizlenmiş
.visible-sm-* Gizlenmiş Görünür Gizlenmiş Gizlenmiş
.visible-md-* Gizlenmiş Gizlenmiş Görünür Gizlenmiş
.visible-lg-* Gizlenmiş Gizlenmiş Gizlenmiş Görünür
.hidden-xs Gizlenmiş Görünür Görünür Görünür
.gizli-sm Görünür Gizlenmiş Görünür Görünür
.hidden-md Görünür Görünür Gizlenmiş Görünür
.hidden-lg Görünür Görünür Görünür Gizlenmiş

Gizlenmiş

Ekran boyutuna bağlı olarak öğeleri gizle:

Örnek

<h2>Example</h2>
<p>Resize this page to see how the text below changes:</p>
<h1 class="hidden-xs bg-danger">This text is hidden on an EXTRA SMALL screen.</h1>
<h1 class="hidden-sm bg-info">This text is hidden on a SMALL screen.</h1>
<h1 class="hidden-md bg-warning">This is text hidden on a MEDIUM screen.</h1>
<h1 class="hidden-lg bg-success">This is text hidden on a LARGE screen.</h1>

Sonuç:

Example

Resize this page to see how the text below changes:

This text is hidden on an EXTRA SMALL screen.

This text is hidden on a SMALL screen.

This is text hidden on a MEDIUM screen.

This is text hidden on a LARGE screen.



v3.2.0'dan itibaren .visible-*-*sınıflar, her CSS display özellik değeri için bir tane olmak üzere üç varyasyona sahiptir:

Sınıflar grubu CSS ekranı
görünür-*-blok Ekran bloğu;
.visible-*-inline ekran: satır içi;
.visible-*-inline-block ekran: satır içi blok;

Örneğin, küçük ( sm) ekranlar için mevcut .visible-*-*sınıflar şunlardır: .visible-sm-block, .visible-sm-inline, ve .visible-sm-inline-block.

.visible-xs, .visible-sm, .visible-mdve sınıfları v3.2.0'dan itibaren kullanımdan.visible-lg kaldırılmıştır .

Örnek

<h2>Example</h2>
<p>Resize this page to see how the text below changes:</p>
<h1 class="visible-xs">This text is shown only on an EXTRA SMALL screen.</h1>
<h1 class="visible-sm">This text is shown only on a SMALL screen.</h1>
<h1 class="visible-md">This text is shown only on a MEDIUM screen.</h1>
<h1 class="visible-lg">This text is shown only on a LARGE screen.</h1>

Sonuç:

Example

Resize this page to see how the text below changes:

This text is shown only on an EXTRA SMALL screen.

This text is shown only on a SMALL screen.

This text is shown only on a MEDIUM screen.

This text is shown only on a LARGE screen.