Baji
Takaddun bayanai da misalai na bajoji, ƙaramin ƙidayar mu da sashin lakabi.
Misali
Ma'auni na bajoji don dacewa da girman ɓangarorin mahaifa na nan take ta amfani da girman rubutun dangi da em
raka'a.
Misalin jagoraSabo
Misalin jagoraSabo
Misalin jagoraSabo
Misalin jagoraSabo
Misalin jagoraSabo
Misalin jagoraSabo
<h1>Example heading <span class="badge badge-secondary">New</span></h1>
<h2>Example heading <span class="badge badge-secondary">New</span></h2>
<h3>Example heading <span class="badge badge-secondary">New</span></h3>
<h4>Example heading <span class="badge badge-secondary">New</span></h4>
<h5>Example heading <span class="badge badge-secondary">New</span></h5>
<h6>Example heading <span class="badge badge-secondary">New</span></h6>
Ana iya amfani da bajoji azaman ɓangare na hanyoyin haɗin gwiwa ko maɓalli don samar da counter.
<button type="button" class="btn btn-primary">
Notifications <span class="badge badge-light">4</span>
</button>
Lura cewa ya danganta da yadda ake amfani da su, bajoji na iya zama da ruɗani ga masu amfani da masu karanta allo da makamantan fasahar taimako. Yayin da salo na bajoji ke ba da alamar gani game da manufarsu, waɗannan masu amfani za a gabatar da su kawai tare da abun ciki na lamba. Ya danganta da takamaiman yanayin, waɗannan bajojin na iya zama kamar ƙarin kalmomi ko lambobi na bazuwar a ƙarshen jumla, hanyar haɗi, ko maɓalli.
Sai dai idan mahallin ya fito fili (kamar yadda yake tare da misalin “Sanarwa”, inda aka fahimci cewa “4” shine adadin sanarwar), la’akari da haɗawa da ƙarin mahallin tare da ɓoyayyen yanki na ƙarin rubutu.
<button type="button" class="btn btn-primary">
Profile <span class="badge badge-light">9</span>
<span class="sr-only">unread messages</span>
</button>
Bambance-bambancen yanayi
Ƙara kowane ɗayan darussan gyare-gyare da aka ambata a ƙasa don canza kamannin lamba.
<span class="badge badge-primary">Primary</span>
<span class="badge badge-secondary">Secondary</span>
<span class="badge badge-success">Success</span>
<span class="badge badge-danger">Danger</span>
<span class="badge badge-warning">Warning</span>
<span class="badge badge-info">Info</span>
<span class="badge badge-light">Light</span>
<span class="badge badge-dark">Dark</span>
Isar da ma'ana ga fasahar taimako
Yin amfani da launi don ƙara ma'ana kawai yana ba da alamar gani, wanda ba za a isar da shi ga masu amfani da fasahar taimako ba - kamar masu karanta allo. Tabbatar cewa bayanin da launi ke nunawa ko dai a bayyane yake daga abun cikin kanta (misali rubutun bayyane), ko kuma an haɗa shi ta hanyar madadin, kamar ƙarin rubutu da aka ɓoye tare da .sr-only
ajin.
Alamomin kwaya
Yi amfani da .badge-pill
ajin gyare-gyare don yin bajoji mafi zagaye (tare da girma border-radius
da ƙari a kwance padding
). Yana da amfani idan kun rasa alamun daga v3.
<span class="badge badge-pill badge-primary">Primary</span>
<span class="badge badge-pill badge-secondary">Secondary</span>
<span class="badge badge-pill badge-success">Success</span>
<span class="badge badge-pill badge-danger">Danger</span>
<span class="badge badge-pill badge-warning">Warning</span>
<span class="badge badge-pill badge-info">Info</span>
<span class="badge badge-pill badge-light">Light</span>
<span class="badge badge-pill badge-dark">Dark</span>
Hanyoyin haɗi
.badge-*
Amfani da azuzuwan mahallin akan wani <a>
kashi cikin sauri yana ba da baji masu aiki tare da jujjuyawa da jahohin mayar da hankali.
<a href="#" class="badge badge-primary">Primary</a>
<a href="#" class="badge badge-secondary">Secondary</a>
<a href="#" class="badge badge-success">Success</a>
<a href="#" class="badge badge-danger">Danger</a>
<a href="#" class="badge badge-warning">Warning</a>
<a href="#" class="badge badge-info">Info</a>
<a href="#" class="badge badge-light">Light</a>
<a href="#" class="badge badge-dark">Dark</a>