Created
February 25, 2014 08:05
-
-
Save andrewnicols/9204811 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import "variables.less"; | |
.navbarVerticalAlign(@elementHeight) { | |
margin-top: (@navbarHeight - @elementHeight) / 2; | |
} | |
.border-radius(@radius) { | |
-webkit-border-radius: @radius; | |
-moz-border-radius: @radius; | |
border-radius: @radius; | |
} | |
// Single Corner Border Radius | |
.border-top-left-radius(@radius) { | |
-webkit-border-top-left-radius: @radius; | |
-moz-border-radius-topleft: @radius; | |
border-top-left-radius: @radius; | |
} | |
.border-top-right-radius(@radius) { | |
-webkit-border-top-right-radius: @radius; | |
-moz-border-radius-topright: @radius; | |
border-top-right-radius: @radius; | |
} | |
.border-bottom-right-radius(@radius) { | |
-webkit-border-bottom-right-radius: @radius; | |
-moz-border-radius-bottomright: @radius; | |
border-bottom-right-radius: @radius; | |
} | |
.border-bottom-left-radius(@radius) { | |
-webkit-border-bottom-left-radius: @radius; | |
-moz-border-radius-bottomleft: @radius; | |
border-bottom-left-radius: @radius; | |
} | |
#font { | |
#family { | |
.serif() { | |
font-family: @serifFontFamily; | |
} | |
.sans-serif() { | |
font-family: @sansFontFamily; | |
} | |
.monospace() { | |
font-family: @monoFontFamily; | |
} | |
} | |
.shorthand(@size: @baseFontSize, @weight: normal, @lineHeight: @baseLineHeight) { | |
font-size: @size; | |
font-weight: @weight; | |
line-height: @lineHeight; | |
} | |
} | |
#font { | |
.serif(@size: @baseFontSize, @weight: normal, @lineHeight: @baseLineHeight) { | |
#font > #family > .serif; | |
#font > .shorthand(@size, @weight, @lineHeight); | |
} | |
.sans-serif(@size: @baseFontSize, @weight: normal, @lineHeight: @baseLineHeight) { | |
#font > #family > .sans-serif; | |
#font > .shorthand(@size, @weight, @lineHeight); | |
} | |
.monospace(@size: @baseFontSize, @weight: normal, @lineHeight: @baseLineHeight) { | |
#font > #family > .monospace; | |
#font > .shorthand(@size, @weight, @lineHeight); | |
} | |
} | |
.navbar-search { | |
position: relative; | |
float: left; | |
.navbarVerticalAlign(30px); // Vertically center in navbar | |
margin-bottom: 0; | |
.search-query { | |
margin-bottom: 0; | |
padding: 4px 14px; | |
#font > .sans-serif(13px, normal, 1); | |
.border-radius(15px); // redeclare because of specificity of the type attribute | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once('lessc.inc.php'); | |
$compiler = new lessc(); | |
$output = $compiler->compileFile('/Users/nicols/git/ext/lessphp/test.less'); | |
file_put_contents('after.css', $output); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment