Overide bootstrap base class attributes in less and meteor

倾然丶 夕夏残阳落幕 提交于 2020-02-08 07:23:02

问题


I am trying to change the behaviour of a bootstrap class in my meteor code and have naively tried the following.

In my html I have added a class tb-sponsor to the div class list

<div class="col-md-8 column tb-sponsor">
      <h4> <strong>Papallo Kitchen & Joinery</strong></h4>
    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean enim diam, imperdiet et sem nec.
</div>

and in the tb.less file added

.tb-sponsor{
   .h4 {
      color: @tb-color;
   }
}

to try and change the color of the h4. Nothing happens. I can get things to happen if I use id=blah the #blah in the tb.less but not for classes. I'm obviously a missing something here. Any ideas please?


回答1:


Remove the period (.) before h4



来源:https://stackoverflow.com/questions/29143645/overide-bootstrap-base-class-attributes-in-less-and-meteor

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!