<!DOCTYPE html>
<html class="no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Title</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width">
<link rel="stylesheet" type="text/css" href="./assets/css/normalize.css" />
<link rel="stylesheet" type="text/css" href="./assets/css/bootstrap.css" />
<script src="./assets/js/less.js" type="text/javascript"></script>
</head>
<body>
<div class="header-container">
<header class="wrapper clearfix">
<h1>Header</h1>
<nav>
<ul>
<li><a href="#">nav ul li a</a></li>
<li><a href="#">nav ul li a</a></li>
<li><a href="#">nav ul li a</a></li>
</ul>
</nav>
</header>
</div>
<div class="main-container">
<div class="promo-pod">
<p>Promo pod Promo pod Promo pod Promo pod</p>
<p>Promo pod Promo pod Promo pod Promo pod</p>
<p>Promo pod Promo pod Promo pod Promo pod</p>
<p>Promo pod Promo pod Promo pod Promo pod</p>
<p>Promo pod Promo pod Promo pod Promo pod</p>
</div>
</div> <!-- #main-container -->
<div class="footer-container">
<footer class="wrapper">
<h3>Footer</h3>
</footer>
</div>
<!-- Le javascript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<!--<script src="assets/bootstrap/js/bootstrap.js"></script>-->
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.0-rc1/js/bootstrap.min.js"></script>
</body>
</html>
我不太喜欢隐藏促销吊舱:
.main-container {
.container();
.make-row();
.main.wrapper {
.make-column(12);
}
.promo-pod {
border:1px solid red;
.hidden-lg;
.make-column(3);
}
}
我决定将 div class="promo-pod" 更改为 div class="span4 hidden-lg" 并隐藏了 div,但是当它只是 div class="promo-pod" 时,所有规则都适用,除了 .hidden -lg;
每次我保存文件时,less 文件都会正确编译,感谢您的帮助。
改名为promo,如,很长,所以在这个gist中搜索promo https://gist.github.com/anonymous/6174366