Commits

Shu Zong Chen  committed 208246e

code drop

  • Participants
  • Parent commits 9beed90

Comments (0)

Files changed (1)

File ninesixty.less

+@ninesixty_width: 960px;
+@ninesixty_padding: 10px;
+
+.ninesixty_clearfix{
+	content: '.';
+	display: block;
+	overflow: hidden;
+	visiblity: hidden;
+	font-size: 0;
+	line-height: 0;
+	width: 0;
+	height: 0;
+}
+
+body{
+	min-width: 960px;
+}
+
+.container(@size){
+	margin-left: auto;
+	margin-right: auto;
+	width: @ninesixty_width;
+	&:before, &:after{
+		.ninesixty_clearfix;
+	}
+	&:after{
+		clear: both;
+	}
+}
+
+.grid(@grid, @container){
+	@c_width: @ninesixty_width/@container;
+	display: inline;
+	float: left;
+	margin-left: @ninesixty_padding;
+	margin-right: @ninesixty_padding;
+	width: @c_width * @grid - 2 * @ninesixty_padding;
+}
+
+.prefix(@prefix, @container){
+	@c_width: @ninesixty_width/@container;
+	padding-left: @c_width * @prefix;
+}
+
+.suffix(@suffix, @container){
+	@c_width: @ninesixty_width/@container;
+	padding-right: @c_width * @suffix;
+}
+
+.push(@push, @container){
+	@c_width: @ninesixty_width/@container;
+	position: relative;
+	left: @c_width * @push;
+}
+
+.pull(@pull, @container){
+	@c_width: @ninesixty_width/@container;
+	position: relative;
+	right: @c_width * @pull;
+}
+
+.alpha(){
+	margin-left: 0;
+}
+
+.omega(){
+	margin-right: 0;
+}
+
+.clear(){
+	clear: both;
+	display: block;
+	overflow: hidden;
+	visiblity: hidden;
+	width: 0;
+	height: 0;
+}
+
+.clearfix(){
+	&:before, &:after{
+		.ninesixty_clearfix;
+	}
+	&:after{
+		clear: both;
+	}
+}