html - Materialize : How to remove margin between divs -
while using col
there margin between `divs. how reduce margin without using inline css:
my code :
.item-card{ position: relative; } .card-lable{ position: absolute; bottom: 0; } .max-width{ max-width: 100%; }
<div class="row"> <div class="col m10 offset-m1"> <div class="col m4 item-card" > <img class="max-width" src="https://www.smashingmagazine.com/wp-content/uploads/2015/06/10-dithering-opt.jpg"> <div class="card-lable"><h4>owl</h4></div> </div> <div class="col m4 item-card" > <img class="max-width" src="https://www.smashingmagazine.com/wp-content/uploads/2015/06/10-dithering-opt.jpg"> <div class="card-lable"><h4>owl</h4></div> </div> </div> </div>
use .offset-m1,.item-card{padding-left:0!important;}
.item-card{ position: relative; } .card-lable{ position: absolute; bottom: 0; } .max-width{ max-width: 100%; } .offset-m1,.item-card{ padding-left:0!important; }
<link href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/css/materialize.min.css" rel="stylesheet"/> <div class="row"> <div class="col m10 offset-m1"> <div class="col m4 item-card" > <img class="max-width" src="https://www.smashingmagazine.com/wp-content/uploads/2015/06/10-dithering-opt.jpg"> <div class="card-lable"><h4>owl</h4></div> </div> <div class="col m4 item-card" > <img class="max-width" src="https://www.smashingmagazine.com/wp-content/uploads/2015/06/10-dithering-opt.jpg"> <div class="card-lable"><h4>owl</h4></div> </div> </div> </div>
Comments
Post a Comment