Zofunikira za HTML zosinthidwa ndikuwonjezeredwa ndi makalasi okulirapo.
Mitu yonse ya HTML, <h1>
kudzera <h6>
ikupezeka.
Kusakhazikika kwapadziko lonse kwa Bootstrap font-size
ndi 14px , yokhala line-height
ndi 20px . Izi zikugwiritsidwa ntchito ku <body>
ndime zonse. Kuphatikiza apo, <p>
(ndime) amalandila malire apansi a theka la kutalika kwa mzere wawo (10px mwachisawawa).
Nullam quis risus eget urna mollis ornare vel eu leo. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Nullam id dolor id nibh ultricies vehicula.
Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec ullamcorper nulla non metus auctor fringilla. Ndife mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit. Donec ullamcorper nulla non metus auctor fringilla.
Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id ili si mi porta gravida ndi eget metus. Ndife mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit.
<p> ... </p>
Pangani ndime kukhala yodziwika bwino powonjezera .lead
.
Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Chifukwa chake, si commodo luctus.
<p class = "kutsogolera" > ... </p>
Sikelo ya typographic imachokera pamitundu iwiri ya LESS mu variables.less : @baseFontSize
ndi @baseLineHeight
. Choyamba ndi kukula kwa font komwe kumagwiritsidwa ntchito ponsepo ndipo chachiwiri ndi kutalika kwa mzere woyambira. Timagwiritsa ntchito masinthidwe amenewo ndi masamu osavuta kupanga mizere, ma padding, ndi kutalika kwa mzere wamitundu yathu yonse ndi zina zambiri. Sinthani Mwamakonda Anu ndikusintha kwa Bootstrap.
Gwiritsani ntchito ma tag otsindika a HTML okhala ndi masitayelo opepuka.
<small>
Kuti musatsindike pamizere kapena midadada ya mawu, gwiritsani ntchito tagi yaying'ono.
Mzere wa mawu awa akuyenera kuwonedwa ngati kusindikizidwa bwino.
<p> <pang'ono> Mzerewu umapangidwa kuti ukhale wosindikiza bwino. </ zazing'ono> </p>
Kuti mutsindike kachidutswa kakang'ono ka zilembo zolemera mafonti.
Kaduka kakang'ono kotsatira kamene kali ndi mawu akuda kwambiri .
<strong> omasuliridwa ngati mawu akuda kwambiri </strong>
Potsindika kaduka kakang'ono ka mawu okhala ndi mawu opendekera.
Kaduka kakang'ono kotsatira kalembedwe ka mawu opendekera .
<em> omasuliridwa ngati mawu opendekera </em>
Mungodziwiratu!Khalani omasuka kugwiritsa ntchito <b>
komanso <i>
mu HTML5. <b>
cholinga chake ndi kuwunikira mawu kapena ziganizo popanda kuwonetsa kufunikira kowonjezera pomwe <i>
nthawi zambiri zimakhala za mawu, mawu aukadaulo, ndi zina.
Sinthani mawu mosavuta ku zigawo zokhala ndi makalasi oyika mawu.
Mawu olowera kumanzere.
Mawu olumikizidwa pakati.
Mawu olowera kumanja.
- <p class = "text-left" > Mawu olowera kumanzere. </p>
- <p class = "text-center" > Mawu omwe ali pakati . </p>
- <p class = "text-right" > Mawu ogwirizana kumanja. </p>
Fotokozerani tanthauzo kudzera mumitundu ndi makalasi ochepa otsimikiza.
Fusce dapibus, tellus ac cursus commodo, tor mauris nibh.
Etiam porta sem malesuada magna mollis euismod.
Donec ullamcorper nulla non metus auctor fringilla.
Aenean eu lero quam. Pellentesque ornare sem lacinia quam venenatis.
Ndife mollis, si commodo luctus, si erat porttitor ligula.
- <p class = "muted" > Fusce dapibus, tellus ac cursus commodo, tor mauris nibh. </p>
- <p class = "text-warning" > Etiam porta sem malesuada magna mollis euismod. </p>
- <p class = "text-error" > Donec ullamcorper nulla non metus auctor fringilla. </p>
- <p class = "text-info" > Zolemba zambiri . Pellentesque ornare sem lacinia quam venenatis. </p>
- <p class = "text-success" > " Zotsatira, est non commodo luctus, nisi erat porttitor ligula. </p>
Kukhazikitsa kosinthika kwa chinthu cha HTML <abbr>
chofupikitsa ndi ma acronyms kuti awonetse mtundu wokulitsidwa pa hover. Mafupipafupi okhala ndi mawonekedwe title
ali ndi malire a madontho opepuka komanso cholozera chothandizira pa hover, zomwe zimapereka mawu owonjezera pa hover.
<abbr>
Pamawu owonjezera pa chidule cha chidule chake, phatikizani chizindikirocho title
.
Chidule cha mawu akuti attr .
<abbr title = "attribute" > attr </abbr>
<abbr class="initialism">
Onjezani .initialism
ku chidule cha kukula kwa mawonekedwe ang'onoang'ono.
HTML ndiye chinthu chabwino kwambiri kuyambira mkate wodulidwa.
<abbr title = "Chiyankhulo cha HyperText Markup" class = "initialism" > HTML </abbr>
Perekani zidziwitso za makolo apafupi kapena gulu lonse lantchito.
<address>
Sungani masanjidwe pomaliza mizere yonse ndi <br>
.
- <adresi>
- <strong> Twitter, Inc. </strong><br>
- 795 Folsom Ave, Suite 600 <br>
- San Francisco, CA 94107 <br>
- <abbr title = "Phone" > P: </abbr> (123) 456-7890
- </adilesi>
- <adresi>
- <strong> Dzina Lathunthu </strong><br>
- <a href = "mailto:#"> [email protected] </a> _
- </adilesi>
Kuti mugwire mawu midadada kuchokera kugwero lina mkati mwazolemba zanu.
Mangirirani HTML<blockquote>
iliyonse ngati mawu. Pamawu olunjika timalimbikitsa a .<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere ndi ante.
- <blockquote>
- <p> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere ndi ante. </p>
- </blockquote>
Kusintha kwa kalembedwe ndi zomwe zili pakusintha kosavuta pa blockquote wamba.
Onjezani <small>
tag kuti mudziwe komwe kwachokera. Manga dzina la gwero ntchito mu <cite>
.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere ndi ante.
Wina wotchuka mu Source Title
- <blockquote>
- <p> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere ndi ante. </p>
- <wamng'ono> Wina wotchuka <cite title = "Source Title" > Mutu wa Gwero </cite></small>
- </blockquote>
Gwiritsani .pull-right
ntchito blockquote yoyandama, yolunjika kumanja.
- <blockquote class = "kukoka-kumanja" >
- ...
- </blockquote>
Mndandanda wazinthu zomwe dongosololi lilibe kanthu .
- <ul>
- <li> ... </li>
- </ul>
Mndandanda wazinthu zomwe dongosololi limafunikira .
- <ol>
- <li> ... </li>
- </ol>
Chotsani zosunga zobwezeretsera list-style
ndi kumanzere pazomwe zili pamndandanda (ana apompopompo okha).
- <ul class = "unstyled" >
- <li> ... </li>
- </ul>
Ikani zinthu zonse pamndandanda umodzi wokhala inline-block
ndi zotchingira zowala.
- <ul class = "inline" >
- <li> ... </li>
- </ul>
Mndandanda wa mawu omwe ali ndi mafotokozedwe ogwirizana nawo.
- <dl>
- <dt> ... </dt>
- <dd> ... </dd>
- </dl>
Pangani mawu ndi mafotokozedwe <dl>
motsatira mbali ndi mbali.
- <dl class = "dl-horizontal" >
- <dt> ... </dt>
- <dd> ... </dd>
- </dl>
Mungodziwiratu!Mafotokozedwe opingasa adzafupikitsa mawu omwe ndi aatali kwambiri kuti agwirizane ndi kukonza ndime yakumanzere text-overflow
. Pamalo ocheperako, asintha kukhala mawonekedwe osakhazikika.
Mangirirani mawu amzere a code ndi <code>
.
<section>
iyenera kukulungidwa ngati inline.
- Mwachitsanzo , <code > & lt ; gawo & gt ;</ code > iyenera kukulungidwa ngati mkati .
Gwiritsani <pre>
ntchito mizere ingapo yamakhodi. Onetsetsani kuti mwathawa m'mabokosi aliwonse mu code kuti mumasulire bwino.
<p>Zitsanzo zalemba apa...</p>
- <pre>
- <p>Zitsanzo za mawu apa...</p>
- </ pre>
Mungodziwiratu!Onetsetsani kuti mwasunga ma code mkati mwa <pre>
ma tag pafupi ndi kumanzere momwe mungathere; idzapereka ma tabo onse.
Mutha kuwonjezera .pre-scrollable
kalasi yomwe ingakhazikitse kutalika kwa 350px ndikupereka y-axis scrollbar.
Pamakongoletsedwe oyambira - zotchingira zopepuka komanso zogawa zopingasa zokha - onjezerani gulu loyambira .table
ku chilichonse <table>
.
# | Dzina loyamba | Dzina lomaliza | Dzina lolowera |
---|---|---|---|
1 | Mark | Otto | @mdo |
2 | Yakobo | Thornton | @mafuta |
3 | Larry | Mbalame |
- <table class = "table" >
- …
- </ tebulo>
Onjezani magulu otsatirawa ku .table
kalasi yoyambira.
.table-striped
Imawonjezera kukwapula kwa mbidzi pamzere uliwonse wa tebulo mkati <tbody>
mwa :nth-child
chosankha cha CSS (chosapezeka mu IE7-8).
# | Dzina loyamba | Dzina lomaliza | Dzina lolowera |
---|---|---|---|
1 | Mark | Otto | @mdo |
2 | Yakobo | Thornton | @mafuta |
3 | Larry | Mbalame |
- <table class = "table table-mizere" >
- …
- </ tebulo>
.table-bordered
Onjezani malire ndi ngodya zozungulira patebulo.
# | Dzina loyamba | Dzina lomaliza | Dzina lolowera |
---|---|---|---|
1 | Mark | Otto | @mdo |
Mark | Otto | @getbootstrap | |
2 | Yakobo | Thornton | @mafuta |
3 | Larry Mbalame |
- <table class = "table-bordered" >
- …
- </ tebulo>
.table-hover
Yambitsani hover state pamizere ya tebulo mkati mwa a <tbody>
.
# | Dzina loyamba | Dzina lomaliza | Dzina lolowera |
---|---|---|---|
1 | Mark | Otto | @mdo |
2 | Yakobo | Thornton | @mafuta |
3 | Larry Mbalame |
- <table class = "table-hover" >
- …
- </ tebulo>
.table-condensed
Imapangitsa matebulo kukhala ophatikizika kwambiri podula ma cell padding pakati.
# | Dzina loyamba | Dzina lomaliza | Dzina lolowera |
---|---|---|---|
1 | Mark | Otto | @mdo |
2 | Yakobo | Thornton | @mafuta |
3 | Larry Mbalame |
- <table class = "table table-condensed" >
- …
- </ tebulo>
Gwiritsani ntchito makalasi okhazikika kuti musankhe mizere ya tebulo.
Kalasi | Kufotokozera |
---|---|
.success |
Imawonetsa kuchita bwino kapena koyenera. |
.error |
Imawonetsa zochitika zowopsa kapena zoyipa. |
.warning |
Limasonyeza chenjezo limene lingafunike chisamaliro. |
.info |
Amagwiritsidwa ntchito ngati njira yosinthira masitayelo osakhazikika. |
# | Zogulitsa | Malipiro Atengedwa | Mkhalidwe |
---|---|---|---|
1 | TB - pamwezi | 01/04/2012 | Zavomerezedwa |
2 | TB - pamwezi | 02/04/2012 | Zakana |
3 | TB - pamwezi | 03/04/2012 | Ikuyembekezera |
4 | TB - pamwezi | 04/04/2012 | Imbani kuti mutsimikizire |
- ...
- < tr class = "kupambana" >
- <td> 1 < /td>
- <td>TB - Mwezi uliwonse</ td >
- <td> 01 / 04 / 2012 < /td>
- <td>Zavomerezedwa</ td >
- </ tr >
- ...
Mndandanda wazinthu zothandizira patebulo la HTML ndi momwe ziyenera kugwiritsidwira ntchito.
Tagi | Kufotokozera |
---|---|
<table> |
Kukulunga chinthu chowonetsera deta mumtundu wa tabular |
<thead> |
Chotengera chamizere yapamutu patebulo ( <tr> ) kuti mulembe mizati yatebulo |
<tbody> |
Chotengera cha mizere ya tebulo ( <tr> ) mu thupi la tebulo |
<tr> |
Chotengera chamagulu amagulu a tebulo ( <td> kapena <th> ) omwe amawonekera pamzere umodzi |
<td> |
Selo ya tebulo lofikira |
<th> |
Selo lapadera la tebulo lazambiri (kapena mzere, kutengera kukula ndi kuyika) zilembo |
<caption> |
Kufotokozera kapena chidule cha zomwe tebulo ili, makamaka zothandiza kwa owerenga zenera |
- <tebulo>
- <caption> ... </ caption>
- <mutu>
- <tr>
- <th> ... </th>
- <th> ... </th>
- </tr>
- </ mutu>
- <chinthu>
- <tr>
- <td> ... </td>
- <td> ... </td>
- </tr>
- </ thupi>
- </ tebulo>
Kuwongolera mawonekedwe amunthu payekha kumalandira masitayelo, koma popanda gulu lililonse lofunikira pakusintha <form>
kwakukulu kapena kusintha kwakukulu. Zotsatira muzolemba zosanjikizana, zolowera kumanzere pamwamba pazowongolera mawonekedwe.
- <form>
- <munda>
- <legend> Nthano </legend>
- <label> Dzina lalemba </ label>
- <input type = "text" placeholder = "Lembani chinachake ..." >
- <span class = "help-block" > Maupangiri othandizira apa. </span>
- <label class = "checkbox" >
- <input type = "checkbox" > Ndifufuzeni
- </ label>
- <button type = "submit" class = "btn" > Tumizani </ batani>
- </fieldset>
- </ fomu>
Kuphatikizidwa ndi Bootstrap pali masanjidwe atatu amitundu omwe amagwiritsidwa ntchito wamba.
Onjezani .form-search
ku fomu ndi .search-query
ku <input>
mawu owonjezera.
- <form class = "form-search" >
- <input type = "text" class = "input-medium search-query" >
- <button type = "submit" class = "btn" > Sakani </ batani>
- </ fomu>
Onjezani .form-inline
zolemba zolowera kumanzere ndi zowongolera zapamizere kuti mupangike molumikizana.
- <form class = "form-inline" >
- <input type = "text" class = "input-small" placeholder = "Imelo" >
- <input type = "password" class = "input-small" placeholder = "Password" >
- <label class = "checkbox" >
- <input type = "checkbox" > Ndikumbukireni
- </ label>
- <button type = "submit" class = "btn" > Lowani </ batani>
- </ fomu>
Sinthani zilembo kumanja ndikuziyandamitsa kumanzere kuti ziwonekere pamzere womwewo ngati zowongolera. Pamafunika zosintha zambiri kuchokera pa fomu yokhazikika:
.form-horizontal
ku mawonekedwe.control-group
.control-label
ku chizindikiro.controls
kuti agwirizane bwino
- <form class = "form-horizontal" >
- <div class = "control-group" >
- <label class = "control-label" for = "inputEmail" > Imelo </label>
- <div class = "zowongolera" >
- <input type = "text" id = "inputEmail" chosungira = Imelo" >
- </div>
- </div>
- <div class = "gulu lolamulira" >
- <label class = "control-label" for = "inputPassword" > Mawu achinsinsi </label>
- <div class = "zowongolera" >
- <input type = "password" id = "inputPassword" placeholder = " Password" >
- </div>
- </div>
- <div class = "control-group" >
- <div class = "zowongolera" >
- <label class = "checkbox" >
- <input type = "checkbox" > Ndikumbukireni
- </ label>
- <button type = "submit" class = "btn" > Lowani </ batani>
- </div>
- </div>
- </ fomu>
Zitsanzo za maulamuliro amtundu wokhazikika omwe amathandizidwa mu mawonekedwe achitsanzo.
Nthawi zambiri mawonekedwe owongolera, magawo otengera mawu. Mulinso chithandizo chamitundu yonse ya HTML5: mawu, mawu achinsinsi, nthawi, nthawi, tsiku, mwezi, nthawi, sabata, nambala, imelo, url, kusaka, foni, ndi mtundu.
Imafunika kugwiritsa ntchito type
nthawi zonse.
- <input type = "text" placeholder = "Zolemba zolemba " >
Kuwongolera mafomu komwe kumathandizira mizere ingapo yamalemba. Sinthani rows
mawonekedwe ngati pakufunika.
- <textarea rows = " 3" ></textarea>
Mabokosi amasankha chimodzi kapena zingapo pamndandanda pomwe mawayilesi ndi osankha njira imodzi kuchokera ambiri.
- <label class = "checkbox" >
- <input type = "checkbox" value = "" >
- Njira yoyamba ndi iyi ndi iyo-onetsetsani kuti mukuphatikiza chifukwa chake zili bwino
- </ label>
- <label class = "radio" >
- <input type = "radio" name = "optionsRadios" id = "optionsRadios1" value = "option1" chafufuzidwa >
- Njira yoyamba ndi iyi ndi iyo-onetsetsani kuti mukuphatikiza chifukwa chake zili bwino
- </ label>
- <label class = "radio" >
- <input type = "radio" name = "optionsRadios" id = "optionsRadios2" value = "option2" >
- Njira yachiwiri ikhoza kukhala chinthu china ndipo kuyisankha idzachotsa kusankha imodzi
- </ label>
Onjezani .inline
kalasi pamabokosi angapo kapena mawayilesi kuti aziwongolera amawonekera pamzere womwewo.
- <label class = "checkbox inline" >
- <input type = "checkbox" id = "inlineCheckbox1" value = "option1" > 1
- </ label>
- <label class = "checkbox inline" >
- <input type = "checkbox" id = "inlineCheckbox2" value = "option2" > 2
- </ label>
- <label class = "checkbox inline" >
- <input type = "checkbox" id = "inlineCheckbox3" value = "option3" > 3
- </ label>
Gwiritsani ntchito njira yosasinthika kapena tchulani a multiple="multiple"
kuti muwonetse zosankha zingapo nthawi imodzi.
- <sankhani>
- <option> 1 </option>
- <option> 2 </option>
- <option> 3 </option>
- <option> 4 </option>
- <option> 5 </option>
- </ sankhani>
- <sankhani angapo = "multiple" >
- <option> 1 </option>
- <option> 2 </option>
- <option> 3 </option>
- <option> 4 </option>
- <option> 5 </option>
- </ sankhani>
Kuphatikiza paziwongolero zomwe zilipo kale, Bootstrap imaphatikizanso zigawo zina zothandiza.
Onjezani mawu kapena mabatani musanayambe kapena mutatha kulemba mawu aliwonse. Dziwani kuti select
zinthu sizikugwira ntchito pano.
Manga .add-on
ndi input
limodzi mwa magulu awiri kuti mukonzekere kapena kuwonjezera mawu ku mawu.
- <div class = "input-prepend" >
- <span class = "zowonjezera" > @ </span>
- <input class = "span2" id = "prependedInput" type = "text" placeholder = "Username" >
- </div>
- <div class = "input-append" >
- <input class = "span2" id = "appendedInput" type = "text" >
- <span class = "add-on" > .00 </span>
- </div>
Gwiritsani ntchito makalasi onse awiri ndi zitsanzo ziwiri .add-on
kuti mukonzekere ndikuwonjezera zolowa.
- <div class = "input-prepend input-append" >
- <span class = "add-on" > $ </span>
- <input class = "span2" id = "appendedPrependedInput" type = "text" >
- <span class = "add-on" > .00 </span>
- </div>
M'malo mwa <span>
mawu, gwiritsani ntchito a .btn
kulumikiza batani (kapena ziwiri) pazolowetsa.
- <div class = "input-append" >
- <input class = "span2" id = "appendedInputButton" type = "text" >
- <button class = "btn" type = "batani" > Pitani! </ batani>
- </div>
- <div class = "input-append" >
- <input class = "span2" id = "appendedInputButtons" type = "text" >
- <button class = "btn" type = "batani" > Sakani </ batani>
- <button class = "btn" type = "batani" > Zosankha </ batani>
- </div>
- <div class = "input-append" >
- <input class = "span2" id = "appendedDropdownButton" type = "text" >
- <div class = "btn-group" >
- <button class = "btn dropdown-toggle" data-toggle = "dropdown" >
- Zochita
- <span class = "caret" > </span>
- </ batani>
- <ul class = "dropdown-menu" >
- ...
- </ul>
- </div>
- </div>
- <div class = "input-prepend" >
- <div class = "btn-group" >
- <button class = "btn dropdown-toggle" data-toggle = "dropdown" >
- Zochita
- <span class = "caret" > </span>
- </ batani>
- <ul class = "dropdown-menu" >
- ...
- </ul>
- </div>
- <input class = "span2" id = "prependedDropdownButton" type = "text" >
- </div>
- <div class = "input-prepend input-append" >
- <div class = "btn-group" >
- <button class = "btn dropdown-toggle" data-toggle = "dropdown" >
- Zochita
- <span class = "caret" > </span>
- </ batani>
- <ul class = "dropdown-menu" >
- ...
- </ul>
- </div>
- <input class = "span2" id = "appendedPrependedDropdownButton" type = "text" >
- <div class = "btn-group" >
- <button class = "btn dropdown-toggle" data-toggle = "dropdown" >
- Zochita
- <span class = "caret" > </span>
- </ batani>
- <ul class = "dropdown-menu" >
- ...
- </ul>
- </div>
- </div>
- <form>
- <div class = "input-prepend" >
- <div class = "btn-group" > ... </div>
- <input type = "text" >
- </div>
- <div class = "input-append" >
- <input type = "text" >
- <div class = "btn-group" > ... </div>
- </div>
- </ fomu>
- <form class = "form-search" >
- <div class = "input-append" >
- <input type = "text" class = "span2 search-query" >
- <button type = "submit" class = "btn" > Sakani </ batani>
- </div>
- <div class = "input-prepend" >
- <button type = "submit" class = "btn" > Sakani </ batani>
- <input type = "text" class = "span2 search-query" >
- </div>
- </ fomu>
Gwiritsani ntchito makalasi achibale monga .input-large
kapena kufananiza zolowa zanu ndi makulidwe a gridi pogwiritsa ntchito .span*
makalasi.
Pangani chilichonse <input>
kapena <textarea>
chinthu kukhala ngati gawo la block block.
- <input class = "input-block-level" type = "text" placeholder = ".input-block-level" >
- <input class = "input-mini" type = "text" placeholder = ".input-mini" >
- <input class = "input-small" type = "text" placeholder = ".input-small" >
- <input class = "input-medium" type = "text" placeholder = ".input-medium" >
- <input class = "input-large" type = "text" placeholder = ".input-large" >
- <input class = "input-xlarge" type = "text" placeholder = ".input-xlarge" >
- <input class = "input-xxlarge" type = "text" placeholder = ".input-xxlarge" >
Mungodziwiratu!M'matembenuzidwe amtsogolo, tikhala tikusintha kugwiritsa ntchito makalasi olowera awa kuti agwirizane ndi kukula kwa mabatani athu. Mwachitsanzo, .input-large
idzawonjezera padding ndi kukula kwa font kwa zolowetsa.
Gwiritsani ntchito .span1
ku .span12
zolowetsa zomwe zikufanana ndi makulidwe a gridi.
- <input class = "span1" type = "text" placeholder = ".span1" >
- <input class = "span2" type = "text" placeholder = ".span2" >
- <input class = "span3" type = "text" placeholder = ".span3" >
- <select class = "span1" >
- ...
- </ sankhani>
- <select class = "span2" >
- ...
- </ sankhani>
- <select class = "span3" >
- ...
- </ sankhani>
Pazolowetsa zamagulu angapo pamzere uliwonse, gwiritsani ntchito gulu .controls-row
losinthira kuti mutalikirane bwino . Imayandama zolowera kuti zigwere danga loyera, imayika malire oyenera, ndikuchotsa zoyandama.
- <div class = "zowongolera" >
- <input class = "span5" type = "text" placeholder = ".span5" >
- </div>
- <div class = "controls controls-row" >
- <input class = "span4" type = "text" placeholder = ".span4" >
- <input class = "span1" type = "text" placeholder = ".span1" >
- </div>
- ...
Perekani deta m'mawonekedwe omwe sangathe kusinthidwa popanda kugwiritsa ntchito mawonekedwe enieni.
- <span class = "input-xlarge-input-input" > Mtengo wina apa </span>
Malizitsani mawonekedwe ndi gulu la zochita (mabatani). Akayikidwa mkati mwa .form-actions
, mabataniwo amangolowera kuti agwirizane ndi zowongolera mawonekedwe.
- <div class = "form-actions" >
- <button type = "submit" class = "btn btn-primary" > Sungani zosintha </button>
- <button type = "button" class = "btn" > Kuletsa </ batani>
- </div>
Thandizo lapaintaneti ndi block level pamawu othandizira omwe amawoneka mozungulira mawonekedwe.
- <input type = "text" ><span class = "help-inline" > Mawu othandizira pa intaneti </span>
- <input type = "text" ><span class = "help-block" > Tsamba lalitali lothandizira lomwe limaduka pamzere watsopano ndipo limatha kupitilira mzere umodzi. </span>
Perekani ndemanga kwa ogwiritsa ntchito kapena alendo omwe ali ndi mayankho ofunikira pakuwongolera mawonekedwe ndi zilembo.
Timachotsa outline
masitayelo okhazikika paziwongolero zamitundu box-shadow
ndikuyika a m'malo mwake :focus
.
- <input class = "input-xlarge" id = "focusedInput" type = "text" value = "Izi ndizokhazikika..." >
Zolowetsa masitayelo pogwiritsa ntchito msakatuli wokhazikika ndi :invalid
. Tchulani a type
, onjezani mawonekedwe required
ngati gawolo silingasankhe, ndipo (ngati kuli kotheka) tchulani pattern
.
Izi sizikupezeka m'mitundu ya Internet Explorer 7-9 chifukwa chosowa chithandizo cha CSS pseudo selectors.
- <input class = "span3" type = "imelo" yofunikira >
Onjezani disabled
mawonekedwe pazolowetsa kuti mupewe kuyika kwa ogwiritsa ntchito ndikuyambitsa mawonekedwe osiyana pang'ono.
- <input class = "input-xlarge" id = "disabledInput" type = "text" placeholder = "Zoyimitsa zoyimitsidwa apa..." zilema >
Bootstrap imaphatikizapo masitayelo otsimikizira zolakwika, chenjezo, zambiri, ndi mauthenga opambana. Kuti mugwiritse ntchito, onjezani kalasi yoyenera pazozungulira .control-group
.
- <div class = "chenjezo la gulu lolamulira" >
- <label class = "control-label" for = "inputWarning" > Lowetsani ndi chenjezo </label>
- <div class = "zowongolera" >
- <input type = "text" id = "inputWarning" >
- <span class = "help-inline" > Chinachake chalakwika </span>
- </div>
- </div>
- <div class = "control-group error" >
- <label class = "control-label" for = "inputError" > Zolowetsa ndi zolakwika </label>
- <div class = "zowongolera" >
- <input type = "text" id = "inputError" >
- <span class = "help-inline" > Chonde konzani cholakwikacho </span>
- </div>
- </div>
- <div class = "control-group info" >
- <label class = "control-label" for = "inputInfo" > Lowetsani ndi zambiri </label>
- <div class = "zowongolera" >
- <input type = "text" id = "inputInfo" >
- <span class = "help-inline" > Dzina lolowera latengedwa kale </span>
- </div>
- </div>
- <div class = "control-group kupambana" >
- <label class = "control-label" for = "inputSuccess" > Kulowetsa mwachipambano </label>
- <div class = "zowongolera" >
- <input type = "text" id = "inputSuccess" >
- <span class = "help-inline" > Woohoo! </span>
- </div>
- </div>
Onjezani makalasi kuzinthu kuti <img>
musinthe mosavuta zithunzi zamapulojekiti aliwonse.
- <img src = "..." class = "img-rounded" >
- <img src = "..." class = "img-circle" >
- <img src = "..." class = "img-polaroid" >
Mungodziwiratu! .img-rounded
ndipo .img-circle
osagwira ntchito mu IE7-8 chifukwa chosowa border-radius
thandizo.
Zithunzi 140 zamtundu wa sprite, zopezeka mu imvi (zosasinthika) ndi zoyera, zoperekedwa ndi Glyphicons .
Ma Glyphicons Halflings nthawi zambiri sapezeka kwaulere, koma makonzedwe apakati pa Bootstrap ndi opanga ma Glyphicons apangitsa kuti izi zitheke popanda mtengo kwa inu monga omanga. Monga zikomo, tikukupemphani kuti muphatikize ulalo wobwerera ku Glyphicons nthawi iliyonse yomwe ingatheke.
Zithunzi zonse zimafunikira <i>
chizindikiritso chokhala ndi kalasi yapadera, yokhala ndi icon-
. Kuti mugwiritse ntchito, ikani khodi ili pafupi kulikonse:
- <i class = "icon-search" > </i>
Palinso masitayilo omwe amapezeka pazithunzi zopindika (zoyera), zokonzedwa ndi gulu limodzi lowonjezera. Tidzakakamiza makamaka kalasiyi pa hover ndi mayiko omwe akugwira ntchito pa nav ndi dropdown link.
- <i class = "icon-search icon-white" ></i>
Mungodziwiratu!Mukamagwiritsa ntchito m'mbali mwa zingwe zamalemba, monga mabatani kapena maulalo a nav, onetsetsani kuti mwasiya malo pambuyo pa <i>
tagi kuti mutalikirane bwino.
Agwiritseni ntchito m'mabatani, m'magulu a batani lazida, kusakatula, kapena zolowetsamo mafomu okonzedweratu.
- <div class = "btn-toolbar" >
- <div class = "btn-group" >
- <a class = "btn" href = "#" ><i class = "icon-align-left" ></i></a>
- <a class = "btn" href = "#" ><i class = "icon-align-center" ></i></a>
- <a class = "btn" href = "#" ><i class = "icon-align-right" ></i></a>
- <a class = "btn" href = "#" ><i class = "icon-align-justify" ></i></a>
- </div>
- </div>
- <div class = "btn-group" >
- <a class = "btn btn-primary" href = "#" ><i class = "icon-user icon-white" ></i> Wogwiritsa </a>
- <a class = "btn btn-primary dropdown-toggle" data-toggle = "dropdown" href = "#" ><span class = "caret" ></span></a>
- <ul class = "dropdown-menu" >
- <li><a href = "#" ><i class = "icon-pensulo" ></i> Sinthani </a></li>
- <li><a href = "#" ><i class = "icon-trash" ></i> Chotsani </a></li>
- <li><a href = "#" ><i class = "icon-ban-circle" ></i> Ban </a></li>
- <li class = "divider" > </li>
- <li><a href = "#" ><i class = "i" ></i> Pangani admin </a></li>
- </ul>
- </div>
- <a class = "btn btn-large" href = "#" ><i class = "icon-star" ></i> Nyenyezi </a>
- <a class = "btn btn-small" href = "#" ><i class = "icon-star" ></i> Nyenyezi </a>
- <a class = "btn btn-mini" href = "#" ><i class = "icon-star" ></i> Nyenyezi </a>
- <ul class = "nav nav-list" >
- <li class = "active" ><a href = "#" ><i class = "icon-home icon-white" ></i> Kwawo </a></li>
- <li><a href = "#" ><i class = "icon-book" ></i> Library </a></li>
- <li><a href = "#" ><i class = "icon-pensulo" ></i> Mapulogalamu </a></li>
- <li><a href = "#" ><i class = "i" ></i> Misc </a></li>
- </ul>
- <div class = "control-group" >
- <label class = "control-label" for = "inputIcon" > Imelo adilesi </label>
- <div class = "zowongolera" >
- <div class = "input-prepend" >
- <span class = "add-on" ><i class = "icon-envelopu" ></i></span>
- <input class = "span2" id = "inputIcon" type = "text" >
- </div>
- </div>
- </div>