Esika
Salelá ba utilitaires oyo ya stenographie mpo na ko configurer noki position ya élément moko.
Mituya oyo bato mingi basalelaka
Ba kelasi ya positionnement ya mbangu ezali, atako ezali ko répondre te.
<div class="position-static">...</div>
<div class="position-relative">...</div>
<div class="position-absolute">...</div>
<div class="position-fixed">...</div>
<div class="position-sticky">...</div>
Fixe likolo
Tia eleman moko na likolo ya esika ya kotala, kobanda na nsɔngɛ tii na nsɔngɛ. Sala que o comprendre ba ramifications ya position fixe na projet na yo; ekoki kozala ete osengeli kobakisa CSS mosusu.
<div class="fixed-top">...</div>
Fixe na se
Tia eleman moko na nse ya esika ya kotala, kobanda na nsɔngɛ tii na nsɔngɛ. Sala que o comprendre ba ramifications ya position fixe na projet na yo; ekoki kozala ete osengeli kobakisa CSS mosusu.
<div class="fixed-bottom">...</div>
Top ya kokangama
Tyá elembo moko na likoló ya esika ya kotala, kobanda na nsɔngɛ tii na nsɔngɛ, kasi kaka nsima ya koleka na yango. Utilitaires .sticky-top
esalela CSS's position: sticky
, oyo esungami mobimba te na ba navigateurs nionso.
IE11 mpe IE10 ekosala position: sticky
lokola position: relative
. Lokola yango, tozali kozinga ba styles na @supports
query, ko limitaka stickiness kaka na ba navigateurs oyo ekoki ko rendu yango malamu.
<div class="sticky-top">...</div>