Liiska kooxda
Kooxaha liisku waa qayb dabacsan oo awood badan si ay u muujiyaan taxane taxane ah. Wax ka beddel oo u fidi si ay u taageeraan wax kasta oo ku jira.
Kooxda liiska ugu aasaasiga ah waa liis aan la dalban oo ay ku jiraan shay liis ah iyo fasalo habboon. Ku dul dhis xulashooyinka soo socda, ama CSS kaaga haddii loo baahdo.
- Cras justo odio
- Dapibus ac facilisis in
- Morbi leo risus
- Porta ac consectetur ac
- Vestibulum iyo eros
<ul class="list-group">
<li class="list-group-item">Cras justo odio</li>
<li class="list-group-item">Dapibus ac facilisis in</li>
<li class="list-group-item">Morbi leo risus</li>
<li class="list-group-item">Porta ac consectetur ac</li>
<li class="list-group-item">Vestibulum at eros</li>
</ul>
Ku dar .active
si aad .list-group-item
u muujiso doorashada firfircoon ee hadda
- Cras justo odio
- Dapibus ac facilisis in
- Morbi leo risus
- Porta ac consectetur ac
- Vestibulum iyo eros
<ul class="list-group">
<li class="list-group-item active">Cras justo odio</li>
<li class="list-group-item">Dapibus ac facilisis in</li>
<li class="list-group-item">Morbi leo risus</li>
<li class="list-group-item">Porta ac consectetur ac</li>
<li class="list-group-item">Vestibulum at eros</li>
</ul>
Ku dar .disabled
si .list-group-item
aad ugu ekaato mid naafo ah. Ogsoonow in qaar ka mid ah walxaha wata .disabled
ay sidoo kale u baahan doonaan JavaScript-ka caadiga ah si ay si buuxda u baabi'iyaan dhacdooyinka gujintooda (tusaale, iskuxirayaasha).
- Cras justo odio
- Dapibus ac facilisis in
- Morbi leo risus
- Porta ac consectetur ac
- Vestibulum iyo eros
<ul class="list-group">
<li class="list-group-item disabled">Cras justo odio</li>
<li class="list-group-item">Dapibus ac facilisis in</li>
<li class="list-group-item">Morbi leo risus</li>
<li class="list-group-item">Porta ac consectetur ac</li>
<li class="list-group-item">Vestibulum at eros</li>
</ul>
Isticmaal <a>
s ama <button>
s si aad u abuurto liiska wax qabad ee shayyada kooxda oo leh dullid , naafo, iyo gobolo firfircoon adoo ku daraya .list-group-item-action
. Waxaan u kala saarnay fasaladan been abuurka ah si aan u hubinno kooxaha liiska ka samaysan ee ka samaysan walxaha aan is-dhexgal ahayn (sida <li>
s ama <div>
s) ayan bixin wax riix ah ama taabasho lacag bixin ah.
U hubso inaadan isticmaalin .btn
fasalada caadiga ah halkan .
<div class="list-group">
<a href="#" class="list-group-item list-group-item-action active">
Cras justo odio
</a>
<a href="#" class="list-group-item list-group-item-action">Dapibus ac facilisis in</a>
<a href="#" class="list-group-item list-group-item-action">Morbi leo risus</a>
<a href="#" class="list-group-item list-group-item-action">Porta ac consectetur ac</a>
<a href="#" class="list-group-item list-group-item-action disabled">Vestibulum at eros</a>
</div>
s , <button>
waxa kale oo aad isticmaali kartaa disabled
sifada halkii aad ka isticmaali lahayd .disabled
fasalka. Nasiib darrose, <a>
s ma taageeraan sifada naafada.
<div class="list-group">
<button type="button" class="list-group-item list-group-item-action active">
Cras justo odio
</button>
<button type="button" class="list-group-item list-group-item-action">Dapibus ac facilisis in</button>
<button type="button" class="list-group-item list-group-item-action">Morbi leo risus</button>
<button type="button" class="list-group-item list-group-item-action">Porta ac consectetur ac</button>
<button type="button" class="list-group-item list-group-item-action" disabled>Vestibulum at eros</button>
</div>
Ku dar .list-group-flush
si aad uga saarto qaar ka mid ah xuduudaha iyo geesaha wareegsan si aad ugu muujiso liiska walxaha gees-ilaa-geeska weelka waalidka (tusaale, kaararka).
- Cras justo odio
- Dapibus ac facilisis in
- Morbi leo risus
- Porta ac consectetur ac
- Vestibulum iyo eros
<ul class="list-group list-group-flush">
<li class="list-group-item">Cras justo odio</li>
<li class="list-group-item">Dapibus ac facilisis in</li>
<li class="list-group-item">Morbi leo risus</li>
<li class="list-group-item">Porta ac consectetur ac</li>
<li class="list-group-item">Vestibulum at eros</li>
</ul>
U isticmaal fasallada macnaha guud si aad u habayso liiska shayada leh asal dawladeed iyo midab.
- Dapibus ac facilisis in
- Kani waa liiska koowaad ee shayga kooxda
- Tani waa shay kooxeed liis labaad ah
- Tani waa shay kooxeedka liiska guusha
- Tani waa shay kooxeed liiska khatarta ah
- Tani waa shay liiska digniinta ah
- Tani waa liiska macluumaadka shay kooxeed
- Tani waa liis kooxeed fudud
- Tani waa shay kooxeed liiska madow
<ul class="list-group">
<li class="list-group-item">Dapibus ac facilisis in</li>
<li class="list-group-item list-group-item-primary">This is a primary list group item</li>
<li class="list-group-item list-group-item-secondary">This is a secondary list group item</li>
<li class="list-group-item list-group-item-success">This is a success list group item</li>
<li class="list-group-item list-group-item-danger">This is a danger list group item</li>
<li class="list-group-item list-group-item-warning">This is a warning list group item</li>
<li class="list-group-item list-group-item-info">This is a info list group item</li>
<li class="list-group-item list-group-item-light">This is a light list group item</li>
<li class="list-group-item list-group-item-dark">This is a dark list group item</li>
</ul>
Fasallada macnuhu waxa kale oo ay la shaqeeyaan .list-group-item-action
. U fiirso ku darida qaababka dullidda halkan kuma jiraan tusaalihii hore. Waxa kale oo la taageeraa .active
dawladda; Codso si aad u muujiso xulashada firfircoon ee shayga liiska macnaha guud.
<div class="list-group">
<a href="#" class="list-group-item list-group-item-action">Dapibus ac facilisis in</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-primary">This is a primary list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-secondary">This is a secondary list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-success">This is a success list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-danger">This is a danger list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-warning">This is a warning list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-info">This is a info list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-light">This is a light list group item</a>
<a href="#" class="list-group-item list-group-item-action list-group-item-dark">This is a dark list group item</a>
</div>
U gudbinta macnaha tignoolajiyada caawinta
Isticmaalka midabka si loogu daro macnaha kaliya waxay bixisaa tilmaam muuqaal ah, taas oo aan loo gudbin doonin isticmaalayaasha tignoolajiyada caawinta - sida akhristayaasha shaashadda. Hubi in macluumaadka lagu tilmaamay midabku ay ka cad yihiin waxa ku jira laftiisa (tusaale qoraalka muuqda), ama lagu soo daro habab kale, sida qoraal dheeraad ah oo .sr-only
fasalka dhexdiisa ku qarsoon.
Ku dar calaamado liis kasta shay kooxeed si aad u muujiso tirooyinka aan la akhriyin, nashaadaadka, iyo wax ka badan iyadoo la kaashanayo adeegyada qaar .
- Cras justo odio14
- Dapibus ac facilisis in2
- Morbi leo risus1
<ul class="list-group">
<li class="list-group-item d-flex justify-content-between align-items-center">
Cras justo odio
<span class="badge badge-primary badge-pill">14</span>
</li>
<li class="list-group-item d-flex justify-content-between align-items-center">
Dapibus ac facilisis in
<span class="badge badge-primary badge-pill">2</span>
</li>
<li class="list-group-item d-flex justify-content-between align-items-center">
Morbi leo risus
<span class="badge badge-primary badge-pill">1</span>
</li>
</ul>
Ku dar ku dhawaad HTML kasta, xitaa kooxaha liiska ku xiran sida kan hoose, iyadoo la kaashanayo flexbox utilities .
Qor cinwaanka shayga kooxda
3 maalmood ka horDonec id un mi porta gravida iyo eget metus. Maecenas sed diam eget risus varius blandit.
Donec id elit non mi porta.Qor cinwaanka shayga kooxda
3 maalmood ka horDonec id un mi porta gravida iyo eget metus. Maecenas sed diam eget risus varius blandit.
Donec id elit non mi porta.Qor cinwaanka shayga kooxda
3 maalmood ka horDonec id un mi porta gravida iyo eget metus. Maecenas sed diam eget risus varius blandit.
Donec id elit non mi porta.<div class="list-group">
<a href="#" class="list-group-item list-group-item-action flex-column align-items-start active">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">List group item heading</h5>
<small>3 days ago</small>
</div>
<p class="mb-1">Donec id elit non mi porta gravida at eget metus. Maecenas sed diam eget risus varius blandit.</p>
<small>Donec id elit non mi porta.</small>
</a>
<a href="#" class="list-group-item list-group-item-action flex-column align-items-start">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">List group item heading</h5>
<small class="text-muted">3 days ago</small>
</div>
<p class="mb-1">Donec id elit non mi porta gravida at eget metus. Maecenas sed diam eget risus varius blandit.</p>
<small class="text-muted">Donec id elit non mi porta.</small>
</a>
<a href="#" class="list-group-item list-group-item-action flex-column align-items-start">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1">List group item heading</h5>
<small class="text-muted">3 days ago</small>
</div>
<p class="mb-1">Donec id elit non mi porta gravida at eget metus. Maecenas sed diam eget risus varius blandit.</p>
<small class="text-muted">Donec id elit non mi porta.</small>
</a>
</div>
Isticmaal tab JavaScript plugin-ku dar si gaar ah ama iyada oo loo marayo bootstrap.js
faylka la soo ururiyey-si loo kordhiyo kooxdayada liiska si aan u abuurno muraayado la taaban karo oo ka kooban gudaha.
Waxaad dhaqaajin kartaa liis kooxeed navigation adoon qorin wax JavaScript ah adiga oo si fudud u qeexaya data-toggle="list"
ama curiye. Isticmaal sifaadkan xogta .list-group-item
.
U oggolow liiska shayga la taaban karo iyada oo loo marayo JavaScript ( shayga liis kastaa wuxuu u baahan yahay in si gaar ah loo hawlgeliyo):
Waxaad u dhaqaajin kartaa shayga liiska gaarka ah dhowr siyaabood:
Si loo sameeyo tabs panel in ay libdhaan, ku dar .fade
mid kasta .tab-pane
. Shabakadda tab ee ugu horreysa waa inay sidoo kale ka .show
dhigtaa nuxurka bilowga ah mid muuqda.
Wuxuu hawlgeliyaa walxaha liiska iyo weelka ka kooban. Tabku waa inuu lahaadaa mid data-target
ama meel la href
beegsanayo noodhka weelka ee DOM.
Wuxuu doortaa shayga liiska la siiyay oo wuxuu tusayaa shayga la xidhiidha. Shayga kale ee liiska hore loo doortay waxa uu noqdaa mid aan la dooran oo shayga la xidhiidha waa qarsoon yahay. Ku soo noqoshada soo wacaha ka hor inta aan la tusin muraayadda tab (tusaale, ka hor intaanay shown.bs.tab
dhacdada dhicin).
Marka la tuso tab cusub, dhacdooyinku waxay u dabcaan sida soo socota:
hide.bs.tab
(ku yaal tab firfircoon ee hadda)show.bs.tab
(ku yaal tabka lagu soo bandhigi doono)hidden.bs.tab
(ee tabtii hore ee firfircoonayd, oo la mid ahhide.bs.tab
dhacdada)shown.bs.tab
(oo ku yaal tab cusub oo firfircoon, oo la mid ahshow.bs.tab
dhacdada)
Haddi aanu tab hore u shaqayn, dhacdooyinka hide.bs.tab
iyo hidden.bs.tab
dhacdooyinka lama eryo
Nooca dhacdada | Sharaxaada |
---|---|
show.bs.tab | Dhacdadani waxay ku shidan tahay bandhiga tab, laakiin ka hor intaan tab cusub la muujin. Isticmaal event.target oo event.relatedTarget si aad u beegsato tab firfircoon iyo tabtii hore ee firfircoonayd (haddii la heli karo) siday u kala horreeyaan. |
la tusay.bs.tab | Dhacdadani waxay ku gubanaysaa bandhiga tab ka dib marka tab la muujiyo. Isticmaal event.target oo event.relatedTarget si aad u beegsato tab firfircoon iyo tabtii hore ee firfircoonayd (haddii la heli karo) siday u kala horreeyaan. |
qari.bs.tab | Dhacdadani waxay dab kacaysaa marka tab cusub la muujinayo (oo sidaas awgeed tabtii hore ee firfircoonayd waa in la qariyaa). Isticmaal event.target oo event.relatedTarget aad beegsato tab firfircoon ee hadda iyo ta cusub ee dhawaan-wax-qaban doona, siday u kala horreeyaan. |
qarsoon.bs.tab | Dhacdadani waxay dabaysaa ka dib marka tab cusub la muujiyo (oo sidaas awgeed tabtii hore ee firfircoonayd ayaa qarsoon). Isticmaal event.target oo event.relatedTarget aad beegsato tabtii hore ee firfircoonayd iyo tab cusub ee firfircoon, siday u kala horreeyaan. |