Created
April 3, 2016 19:34
-
-
Save robwent/1d4515859ed239ba693840de76314700 to your computer and use it in GitHub Desktop.
referencing in less imports
This file contains hidden or 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 (less) "pure/base.css"; | |
@import (reference,less) 'pure/grids.css'; | |
@import (reference,less) 'pure/grids-responsive.css'; | |
@import (reference,less) 'pure/buttons.css'; | |
@import (reference,less) 'pure/menus.css'; | |
@import (reference,less) 'pure/forms.css'; | |
@import (reference,less) 'pure/tables.css'; | |
//@import 'theme/global.less'; | |
//@import 'theme/grids.less'; | |
//@import 'theme/menus.less'; | |
//global.less | |
html, button, input, select, textarea, | |
.pure-g [class *= "pure-u"] { | |
font-family: 'Arimo', sans-serif; | |
} | |
body { | |
line-height: 1.6; | |
font-size: 1.125em; | |
} | |
h1, h2, h3, h4, h5, h6 { | |
font-weight: normal; | |
color: rgb(75, 75, 75); | |
} | |
h1 { | |
font-size: 3em; | |
} | |
h2 { | |
font-size: 1.5em; | |
} | |
h3 { | |
font-size: 1.25em; | |
} | |
h4 { | |
font-size: 1.125em; | |
} | |
blockquote { | |
font-family: "Georgia", serif; | |
color: #666; | |
font-style: italic; | |
line-height: 1.8; | |
border-left: 5px solid #ddd; | |
padding-left: 1.5em; | |
} | |
//grids.less | |
//General Layout | |
.site-content { | |
padding-left: 2em; | |
padding-right: 2em; | |
margin-left: auto; | |
margin-right: auto; | |
max-width: 786px; | |
} | |
//Grid Rows | |
.mainmenu-container { | |
&:extend(.pure-g all); | |
// max-width: 980px; | |
// margin: 0 auto; | |
} | |
//Grid Units | |
//nav | |
.brand, .main-menu { | |
&:extend(.pure-u-1 all); | |
} | |
.brand { | |
&:extend(.pure-u-md-1-3 all); | |
} | |
.main-menu { | |
&:extend(.pure-u-md-2-3 all); | |
} | |
//menus.less | |
.mainmenu-container { | |
margin-bottom: 1em; | |
-webkit-font-smoothing: antialiased; | |
height: 2.1em; | |
overflow: hidden; | |
-webkit-transition: height 0.5s; | |
-moz-transition: height 0.5s; | |
-ms-transition: height 0.5s; | |
transition: height 0.5s; | |
> div { | |
> a { | |
//the logo? | |
&:extend(.pure-menu .pure-menu-heading all); | |
&:extend(.pure-menu-horizontal .pure-menu-heading); | |
&:extend(.pure-menu-horizontal > .pure-menu-heading all); | |
} | |
.menu { | |
&:extend(.pure-menu); | |
ul { | |
&:extend(.pure-menu-list all); | |
li { | |
&:extend(.pure-menu-item); | |
} | |
a { | |
&:extend(.pure-menu-link); | |
} | |
.current-menu-item a { | |
&:extend(.pure-menu-active > .pure-menu-link); | |
} | |
} | |
} | |
.menu-horizontal { | |
&:extend(.pure-menu-horizontal all); | |
ul { | |
&:extend(.pure-menu-horizontal .pure-menu-list all); | |
li { | |
&:extend(.pure-menu-horizontal .pure-menu-item); | |
} | |
a { | |
&:extend(.pure-menu-horizontal .pure-menu-link); | |
} | |
.current-menu-item a { | |
&:extend(.pure-menu-horizontal .pure-menu-active > .pure-menu-link); | |
} | |
} | |
} | |
} | |
&.open { | |
height: 14em; | |
} | |
.mainmenu-toggle { | |
width: 34px; | |
height: 34px; | |
display: block; | |
position: absolute; | |
top: 0; | |
right: 0; | |
display: none; | |
} | |
.mainmenu-toggle .bar { | |
background-color: #777; | |
display: block; | |
width: 20px; | |
height: 2px; | |
border-radius: 100px; | |
position: absolute; | |
top: 18px; | |
right: 7px; | |
-webkit-transition: all 0.5s; | |
-moz-transition: all 0.5s; | |
-ms-transition: all 0.5s; | |
transition: all 0.5s; | |
} | |
.mainmenu-toggle .bar:first-child { | |
-webkit-transform: translateY(-6px); | |
-moz-transform: translateY(-6px); | |
-ms-transform: translateY(-6px); | |
transform: translateY(-6px); | |
} | |
.mainmenu-toggle.x .bar { | |
-webkit-transform: rotate(45deg); | |
-moz-transform: rotate(45deg); | |
-ms-transform: rotate(45deg); | |
transform: rotate(45deg); | |
} | |
.mainmenu-toggle.x .bar:first-child { | |
-webkit-transform: rotate(-45deg); | |
-moz-transform: rotate(-45deg); | |
-ms-transform: rotate(-45deg); | |
transform: rotate(-45deg); | |
} | |
@media (max-width: 47.999em) { | |
.mainmenu-toggle { | |
display: block; | |
} | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment