Twitter bootstrap 删除boostrap中与wieport大小相关的偏移量
我很担心这种简单的情况Twitter bootstrap 删除boostrap中与wieport大小相关的偏移量,twitter-bootstrap,css,Twitter Bootstrap,Css,我很担心这种简单的情况 <div class="row full" id="slogan"> <div class="col-sm-4 col-sm-offset-1 text-center" id="girl"> <img src="<?php the_field('immagine_slogan'); ?>" /> </div> <div class=
<div class="row full" id="slogan">
<div class="col-sm-4 col-sm-offset-1 text-center" id="girl">
<img src="<?php the_field('immagine_slogan'); ?>" />
</div>
<div class="col-sm-6 text-center" id="colonna-testo-slogan">
<div class="testo-slogan">
<h2><?php the_field('titolo_slogan'); ?></h2>
<?php the_field('descrizione_slogan'); ?>
</div>
</div>
</div>
" />
我希望在-col-sm-4 col-sm-offset-1中,当wieport大小小于X px时,删除偏移量!
是否可以使用媒体查询。例如,其中X=800
@media (max-width: 800px) {
.reset-offset.col-sm-offset-1 {
margin-left: 0;
}
}
但此解决方案在最大宽度为400px时编辑我站点中的每个.col-sm-offset-1,对吗?我不希望出现这种情况,但仅限于此!然后在列中使用自定义类名。或者选择
#标语>.col-sm-offset-1{}
但自定义类.reset offset
是一种更好的解决方案。很好。请接受anwser,以便其他人知道它已解决