Ithuthela ku-v3.x
Isiqondiso sendlela yokuthuthukisa kusuka ku-Bootstrap v2.x kuya ku-v3.x ngokugcizelela izinguquko ezinkulu, yini entsha, nokuthi yini esusiwe.
Isiqondiso sendlela yokuthuthukisa kusuka ku-Bootstrap v2.x kuya ku-v3.x ngokugcizelela izinguquko ezinkulu, yini entsha, nokuthi yini esusiwe.
I-Bootstrap 3 ayihambisani emuva ne-v2.x. Sebenzisa lesi sigaba njengomhlahlandlela ojwayelekile ukuze uthuthuke usuka ku-v2.x uye ku-v3.0. Ukubuka kabanzi, bona ukuthi yini entsha esimemezelweni sokukhishwa kwe-v3.0.
Leli thebula libonisa izinguquko zesitayela phakathi kwe-v2.x ne-v3.0.
I-Bootstrap 2.x | I-Bootstrap 3.0 |
---|---|
.row-fluid |
.row |
.span* |
.col-md-* |
.offset* |
.col-md-offset-* |
.brand |
.navbar-brand |
.navbar .nav |
.navbar-nav |
.nav-collapse |
.navbar-collapse |
.nav-toggle |
.navbar-toggle |
.btn-navbar |
.navbar-btn |
.hero-unit |
.jumbotron |
.icon-* |
.glyphicon .glyphicon-* |
.btn |
.btn .btn-default |
.btn-mini |
.btn-xs |
.btn-small |
.btn-sm |
.btn-large |
.btn-lg |
.alert |
.alert .alert-warning |
.alert-error |
.alert-danger |
.visible-phone |
.visible-xs |
.visible-tablet |
.visible-sm |
.visible-desktop |
Hlukanani phakathi.visible-md .visible-lg |
.hidden-phone |
.hidden-xs |
.hidden-tablet |
.hidden-sm |
.hidden-desktop |
Hlukanani phakathi.hidden-md .hidden-lg |
.input-block-level |
.form-control |
.control-group |
.form-group |
.control-group.warning .control-group.error .control-group.success |
.form-group.has-* |
.checkbox.inline .radio.inline |
.checkbox-inline .radio-inline |
.input-prepend .input-append |
.input-group |
.add-on |
.input-group-addon |
.img-polaroid |
.img-thumbnail |
ul.unstyled |
.list-unstyled |
ul.inline |
.list-inline |
.muted |
.text-muted |
.label |
.label .label-default |
.label-important |
.label-danger |
.text-error |
.text-danger |
.table .error |
.table .danger |
.bar |
.progress-bar |
.bar-* |
.progress-bar-* |
.accordion |
.panel-group |
.accordion-group |
.panel .panel-default |
.accordion-heading |
.panel-heading |
.accordion-body |
.panel-collapse |
.accordion-inner |
.panel-body |
Sengeze izici ezintsha futhi sashintsha ezinye ezikhona. Nazi izitayela ezintsha noma ezibuyekeziwe.
Isici | Incazelo |
---|---|
Amaphaneli | .panel .panel-default .panel-body .panel-title .panel-heading .panel-footer .panel-collapse |
Amaqembu ohlwini | .list-group .list-group-item .list-group-item-text .list-group-item-heading |
Ama-Glyphicons | .glyphicon |
I-Jumbotron | .jumbotron |
Igridi encane eyengeziwe (<768px) | .col-xs-* |
Igridi encane (≥768px) | .col-sm-* |
Igridi emaphakathi (≥992px) | .col-md-* |
Igridi enkulu (≥1200px) | .col-lg-* |
Izigaba zensiza eziphendulayo (≥1200px) | .visible-lg .hidden-lg |
Ama-Offsets | .col-sm-offset-* .col-md-offset-* .col-lg-offset-* |
Phusha | .col-sm-push-* .col-md-push-* .col-lg-push-* |
Donsa | .col-sm-pull-* .col-md-pull-* .col-lg-pull-* |
Osayizi bobude bokufaka | .input-sm .input-lg |
Amaqembu okokufaka | .input-group .input-group-addon .input-group-btn |
Izilawuli zefomu | .form-control .form-group |
Osayizi beqembu lezinkinobho | .btn-group-xs .btn-group-sm .btn-group-lg |
Umbhalo we-Navbar | .navbar-text |
Isihloko se-Navbar | .navbar-header |
Amathebhu / amaphilisi alungisiwe | .nav-justified |
Izithombe eziphendulayo | .img-responsive |
Imigqa yethebula yomongo | .success .danger .warning .active .info |
Amaphaneli womongo | .panel-success .panel-danger .panel-warning .panel-info |
I-Modal | .modal-dialog .modal-content |
Isithombe sesithonjana | .img-thumbnail |
Well osayizi | .well-sm .well-lg |
Izixhumanisi zokuxwayisa | .alert-link |
Izinto ezilandelayo zehlisiwe noma zashintshwa ku-v3.0.
Isici | Kususiwe ku-2.x | 3.0 Okulinganayo |
---|---|---|
Izenzo zefomu | .form-actions |
N/A |
Sesha ifomu | .form-search |
N/A |
Yakha iqembu ngolwazi | .control-group.info |
N/A |
Osayizi bokufakwa kobubanzi obungashintshi | .input-mini .input-small .input-medium .input-large .input-xlarge .input-xxlarge |
Sebenzisa .form-control kanye nesistimu yegridi esikhundleni salokho. |
Vimba ifomu lezinga lokungenayo | .input-block-level |
Akukho okulinganayo okuqondile, kodwa izilawuli zamafomu ziyefana. |
Izinkinobho eziphambene | .btn-inverse |
N/A |
Umugqa woketshezi | .row-fluid |
.row (ayisasebenzi igridi) |
Ilawula ukugoqa | .controls |
N/A |
Ilawula umugqa | .controls-row |
.row noma.form-group |
Ibha ye-Navbar yangaphakathi | .navbar-inner |
N/A |
Izihlukanisi ezime mpo ze-Navbar | .navbar .divider-vertical |
N/A |
Imenyu engaphansi eyehlayo | .dropdown-submenu |
N/A |
Ukuqondanisa kwethebhu | .tabs-left .tabs-right .tabs-below |
N/A |
Indawo yethebhula esekwe ngamaphilisi | .pill-content |
.tab-content |
Ifasitelana lendawo yethebhubula elisekelwe kumaphilisi | .pill-pane |
.tab-pane |
Nav uhlu | .nav-list .nav-header |
Akukho okulinganayo okuqondile, kodwa amaqembu ohlu no- .panel-group s kuyefana. |
Usizo lwe-inline lokulawula ifomu | .help-inline |
Akukho okufana ncamashi, kodwa .help-block kuyefana. |
Imibala yokuqhubeka kweleveli engeyona yebha | .progress-info .progress-success .progress-warning .progress-danger |
Sebenzisa .progress-bar-* esikhundleni .progress-bar salokho. |
Ezinye izinguquko ku-v3.0 azibonakali ngokushesha. Amakilasi ayisisekelo, izitayela ezibalulekile, nokuziphatha kulungisiwe ukuze kube nezimo kanye nendlela yethu yokuqala yeselula . Nalu uhlu oluyingxenye:
.form-control
ikilasi lesici ukuze wenze isitayela..form-control
ezineklasi elisetshenzisiwe manje sezibanzi ngo-100% ngokuzenzakalelayo. Goqa okokufaka ngaphakathi <div class="col-*"></div>
ukuze ulawule ububanzi bokufaka..badge
angisenawo amakilasi angumongo (-impumelelo,-ayinhloko, njll..)..btn
kumele futhi isebenzise .btn-default
ukuze uthole inkinobho "ezenzakalelayo"..row
manje uketshezi..img-responsive
owuketshezi .<img>
.glyphicon
, manje sezisekelwe kufonti. Izithonjana nazo zidinga isisekelo nesigaba sesithonjana (isb .glyphicon .glyphicon-asterisk
)..modal-header
, .modal-body
, kanye .modal-footer
nezigaba manje sekuhlanganiswe .modal-content
futhi .modal-dialog
kwenzelwa isitayela nokuziphatha okungcono kweselula. Futhi, akufanele usafaka isicelo .hide
kumakhaphu .modal
akho.remote
inketho ye-modal manje .modal-content
isifakwa ku-(kusuka ku-v3.0.0 kuye ku-v3.0.3, kuya ku- .modal
) esikhundleni sokungena kufayela le- .modal-body
. Lokhu kukuvumela ukuthi futhi uguqule kalula unhlokweni nonyaweni we-modal, hhayi nje umzimba we-modal.data-toggle="buttons"
esikhundleni data-toggle="buttons-checkbox"
noma kumakhaphu data-toggle="buttons-radio"
azo.'show.bs.modal'
. Kumathebhu "abonisiwe" sebenzisa 'shown.bs.tab'
, njll.Ukuze uthole ulwazi olwengeziwe mayelana nokuthuthukela ku-v3.0, namazwibela ekhodi avela emphakathini, bona i-Bootply .