Ubuninzi bezinto ezinokusetyenziswa kwakhona zakhelwe kwiBootstrap ukubonelela ngokujonga, izilumkiso, iipopovers, nokunye okuninzi.
I-Ultra elula kunye ne-styled pagination encinci ephefumlelwe yi-Rdio, ilungile kwii-apps kunye neziphumo zokukhangela. Ibhloko enkulu kunzima ukuyiphosa, kulula ukukala, kwaye ibonelela ngeendawo ezinkulu zokucofa.
Amakhonkco anokwenziwa ngokwezifiso kwaye asebenze kwiimeko ezininzi kunye neklasi elungileyo. .disabled
amakhonkco angacofayo kunye .active
nephepha langoku.
Yongeza nokuba yiyiphi kwiiklasi ezimbini ozikhethelayo ukutshintsha ulungelelwaniso lwamakhonkco epagination: .pagination-centered
kunye .pagination-right
.
Icandelo lepagination elingagqibekanga liyaguquguquka kwaye lisebenza kwinani leenguqu.
Isongelwe kwi- <div>
, i-pagination yi- <ul>
.
- <div class = "pagination" >
- <ul>
- <li><a href = "#" > Ngaphambili </a> </li>
- <li iklasi = "esebenzayo" >
- <a href = "#"> 1 </a> _
- </ li>
- <li><a href = "#"> 2 </a> </li>
- <li><a href = "#"> 3 </a> </li>
- <li><a href = "#"> 4 </a> </li>
- <li><a href = "#"> Okulandelayo </a> </li>
- </ul>
- </ div>
Icandelo le-pager yiseti yekhonkco lokuphunyezwa kwe-pagination elula kunye nokuphawula ukukhanya kunye nezimbo ezikhaphukhaphu. Ilungile kwiziza ezilula ezifana neeblogi okanye iimagazini.
Iikhonkco zePager zikwasebenzisa .disabled
iklasi ngokubanzi ukusuka kwi-pagination.
Ngokungagqibekanga, amaziko e-pageja amakhonkco.
- <ul iklasi = "pager" >
- <li>
- <a href = "#"> Ngaphambili </a> _
- </ li>
- <li>
- <a href = "#"> Okulandelayo </a> _
- </ li>
- </ul>
Kungenjalo, unokulungelelanisa ikhonkco ngalinye emacaleni:
- <ul iklasi = "pager" >
- <li iklasi = "yangaphambili" >
- <a href = "#" > ← Endala </a>
- </ li>
- <li iklasi = "elandelayo" >
- <a href = "#" > Entsha → </a>
- </ li>
- </ul>
Iileyibhile | IMarkup |
---|---|
Ukuhlala kukho | <span class="label">Default</span> |
Impumelelo | <span class="label label-success">Success</span> |
Isilumkiso | <span class="label label-warning">Warning</span> |
Kubalulekile | <span class="label label-important">Important</span> |
Ulwazi | <span class="label label-info">Info</span> |
Inverse | <span class="label label-inverse">Inverse</span> |
Iibheji zincinci, izinto ezilula zokubonisa isalathisi okanye ukubala kohlobo oluthile. Ziqhele ukufunyanwa kubathengi be-imeyile abanje ngeMail.app okanye kwiiapps eziphathwayo zezaziso zokutyhala.
Igama | Umzekelo | IMarkup |
---|---|---|
Ukuhlala kukho | 1 | <span class="badge">1</span> |
Impumelelo | 2 | <span class="badge badge-success">2</span> |
Isilumkiso | 4 | <span class="badge badge-warning">4</span> |
Kubalulekile | 6 | <span class="badge badge-important">6</span> |
Ulwazi | 8 | <span class="badge badge-info">8</span> |
Inverse | 10 | <span class="badge badge-inverse">10</span> |
I-Bootstrap ibonelela ngezinto ezilula, eziguquguqukayo ezibizwa ngokuba yiyunithi yeqhawe ukubonisa umxholo kwindawo yakho. Isebenza kakuhle kwiindawo zokuthengisa kunye neziqulatho ezinzima.
Gquba umxholo wakho ngolu div
hlobo:
- <div class = "iyunithi yeqhawe" >
- <h1> Isihloko </ h1>
- <p> Umgca wethegi </p>
- <p>
- <a iklasi = "btn btn-primary btn-large">
- Funda nzulu
- </a>
- </p>
- </ div>
Le yiyunithi yeqhawe elilula, icandelo elilula le-jumbotron lokubiza ingqalelo eyongezelelweyo kumxholo ofakiweyo okanye ulwazi.
Iqokobhe elilula h1
lesithuba esifanelekileyo kunye namacandelo ecandelo lomxholo kwiphepha. Ingasebenzisa h1
okungagqibekanga small
, isiqalelo kunye namanye amacandelo amaninzi ( ngezimbo ezongezelelweyo).
- <div class = "i-header-page" >
- <h1> Umzekelo wephepha elingasentla kwekhasi </h1>
- </ div>
Ngokungagqibekanga, ii-thumbnails zeBootstrap ziyilelwe ukubonisa imifanekiso edityanisiweyo enophawu oluncinci olufunekayo.
Ngophawu olongezelelweyo olongezelelweyo, kuyenzeka ukongeza naluphi na uhlobo lomxholo we-HTML njengezihloko, imihlathi, okanye amaqhosha kwi-thumbnails.
Izithonjana (ngaphambili .media-grid
ukuya kuthi ga kwi-v1.4) zilungile kwiigridi zeefoto okanye iividiyo, iziphumo zokukhangela umfanekiso, iimveliso zokuthengisa, iipotfoliyo, nokunye okuninzi. Zingaba ngamakhonkco okanye umxholo omileyo.
I-Thumbnail markup ilula-a ul
kunye naliphi na inani lezinto li
ezifunekayo kuphela. Ikwabhetyebhetye kakhulu, ivumela naluphi na uhlobo lomxholo onokumakishwa okuncinci ukusonga imixholo yakho.
Okokugqibela, icandelo le-thumbnails lisebenzisa iiklasi zenkqubo yegridi esele ikhona-njenge .span2
okanye .span3
-ukulawula imilinganiselo ye-thumbnail.
Njengoko bekutshiwo ngaphambili, imarkup efunekayo ye-thumbnails ilula kwaye ithe ngqo. Nalu ujongo kucwangciso olungagqibekanga lwemifanekiso eqhagamshelweyo :
- <ul iklasi = "i-thumbnails" >
- <li iklasi = "span3" >
- <a href = "#" iklasi = "i-thumbnail"> _
- <img src = "https://placehold.it/260x180" alt = "" >
- </a>
- </ li>
- ...
- </ul>
Ngomxholo we-HTML wesiko kwii-thumbnails, uphawu lutshintsha kancinci. Ukuvumela umxholo wenqanaba lebhloko naphi na, sitshintshisa i <a>
- <div>
enje:
- <ul iklasi = "i-thumbnails" >
- <li iklasi = "span3" >
- <div class = "i-thumbnail" >
- <img src = "https://placehold.it/260x180" alt = "" >
- <h5> Ileyibhile ye-Thumbnail </h5>
- <p> I-Thumbnail caption right apha... </p>
- </ div>
- </ li>
- ...
- </ul>
NgeBootstrap 2, siye salula iklasi yesiseko: .alert
endaweni ye .alert-message
. Siphinde sacutha ubuncinci uphawu olufunekayo—akukho <p>
nto ifunwa ngokuzenzekelayo, ngaphandle nje <div>
.
Kwicandelo elomeleleyo elinekhowudi encinci, sisuse inkangeleko yokwahlula izilumkiso zebhloko, imiyalezo eza nephedi eninzi kunye nemibhalo emininzi. Iclass nayo itshintshile .alert-block
.
I-Bootstrap iza ne-plugin enkulu ye-jQuery exhasa imiyalezo yesilumkiso, iyenza ukuba bayigxothe ngokukhawuleza kwaye kulula.
Gquba umyalezo wakho kunye ne icon ozikhethelayo yokuvala kwi div ngeklasi elula.
- <div class = "isilumkiso" >
- < iklasi yeqhosha = "vala" idatha-dismiss = "isilumkiso" > × </ iqhosha>
- <strong> Isilumkiso! </strong> Eyona nto ibhetele ukuba ujonge wena ngokwakho, awukhange ulunge kakhulu.
- </ div>
Iintloko phezulu! Izixhobo ze-iOS zifuna href="#"
ukugxothwa kwezilumkiso. Qiniseka ukuba uyayiquka kunye nedatha yoyelelwano lwee-ayikhoni zokuvala iankile. Kungenjalo, unokusebenzisa into <button>
enophawu lwedatha, esikhethe ukuyenzela amaxwebhu ethu. Xa usebenzisa <button>
, kufuneka ubandakanye type="button"
okanye iifomu zakho azinakungeniswa.
Yandisa ngokulula umyalezo wesilumkiso oqhelekileyo ngeeklasi ezimbini ozikhethelayo: .alert-block
ukwenzela ukukhuselwa okungaphezulu kunye nolawulo lokubhaliweyo kunye .alert-heading
nesihloko esithelekisekayo.
Okona kulungileyo uzitshekishe, awubukeki ulunge kakhulu. I-Nulla vitae elit libero, i-pharetra augue. I-Praesent commodo cursus magna, vel scelerisque nisl consectetur et.
- <div iklasi = "i-alert-block block" >
- <a class = "close" data-dismiss = "alert" href = "#" > × </a>
- <h4 class = "alert-heading" > Isilumkiso! </ h4>
- Okona kungcono uzihlole, awukho...
- </ div>
- <div class = "impazamo yesilumkiso sesilumkiso" >
- ...
- </ div>
- <div class = "isilumkiso-impumelelo yesilumkiso" >
- ...
- </ div>
- <div iklasi = "i-alert-alert-info" >
- ...
- </ div>
Ibar yenkqubela phambili ehlala ikho enethareyidi ethe nkqo.
- <div class = "inkqubela phambili" >
- <div class = "bar"
- style = " ububanzi : 60 %; " ></div>
- </ div>
Isebenzisa igradient ukwenza isiphumo esinemigca (akukho IE).
- <div class = "inkqubela phambili-imigca" >
- <div class = "bar"
- style = " ububanzi : 20 %; " ></div>
- </ div>
Ithatha umzekelo onemigca kwaye iwuphilise (akukho IE).
- <div class = "inkqubela phambili-inemigca
- esebenzayo" >
- <div class = "bar"
- style = " ububanzi : 40 %; " ></div>
- </ div>
Imivalo yenkqubela phambili isebenzisa enye iqhosha elifanayo kunye neeklasi zesilumkiso kwizimbo ezihambelanayo.
Ngokufana nemibala eqinileyo, sinemigca eyohlukeneyo yenkqubela phambili.
Imivalo yenkqubela phambili isebenzisa iinguqu zeCSS3, ke ukuba uhlengahlengisa ububanzi ngejavascript, iya kwenza ubungakanani kwakhona ngokutyibilikayo.
Ukuba usebenzisa .active
iklasi, .progress-striped
imivalo yakho yenkqubela phambili iya kuphilisa imigca ekhohlo ukuya ekunene.
Imivalo yenkqubela phambili isebenzisa i-CSS3 gradients, iinguqu, kunye noopopayi ukuphumeza zonke iziphumo zazo. Ezi mpawu azixhaswa kwi-IE7-9 okanye kwiinguqulelo ezindala zeFirefox.
I-Opera kunye ne-IE azixhasi oopopayi ngeli xesha.
Sebenzisa iqula njengesiphumo esilula kwi-elementi ukuyinika isiphumo sokufakwa.
- <div iklasi = "kakuhle" >
- ...
- </ div>
Sebenzisa i-ayikhoni yokuvala eqhelekileyo ukugxotha umxholo onjengeemodyuli kunye nezilumkiso.
- < iklasi yeqhosha = "vala" > &amaxesha; </ iqhosha>
Izixhobo ze-iOS zifuna i href="#" yokucofa iminyhadala ukuba ukhetha ukusebenzisa i-ankile.
- <a iklasi = "vala" href = "#" > &amaxesha; </a>