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
... | |
// test for font-face version to load via Data URI'd CSS | |
// Basically, load WOFF unless it's android's default browser, which needs TTF, or ie8-, which needs eot | |
var fonts = ns.files.css.fontsWOFF, | |
ua = win.navigator.userAgent; | |
// android webkit browser, non-chrome | |
if( ua.indexOf( "Android" ) > -1 && ua.indexOf( "like Gecko" ) > -1 && ua.indexOf( "Chrome" ) === -1 ){ | |
fonts = ns.files.css.fontsTTF; | |
} |
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
.accordion { | |
.js & { | |
display: none; | |
} | |
.js .open + & { | |
display: block; | |
} | |
li { | |
border-top: 1px solid #e2e4e6; | |
&:first-child { |
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
javascript:open( location, 'iPhone:portrait', 'innerWidth='+(320)+' ,innerHeight='+(480)+' ,scrollbars=yes' ); |
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
// ---- | |
// Sass (v3.3.0.rc.1) | |
// Compass (v0.13.alpha.10) | |
// ---- | |
//elements get appended with "__" and the $name | |
@mixin e($name) { | |
@at-root #{&}__#{$name} { | |
@content; | |
} |
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
// Autoprefixer | |
https://github.com/nDmitry/grunt-autoprefixer | |
// Sassdown | |
https://github.com/nopr/sassdown | |
// Compass | |
https://github.com/gruntjs/grunt-contrib-compass | |
// Connect |
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
I'm front-end'ing a site for a client that has a 'favourite' or 'star-ing' functionality. | |
My question is, how to name whether the item has been starred or not. | |
Current logic in my CSS has things that are already .is-open, .is-closed, .is-active, .is-inactive, .is-visible and .is-hidden | |
I'm currently toying with | |
.is-favourited and .is-Notfavourited but that's pretty crap |
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
// Mobile / Desktop JS | |
$( '.desktop-site-link' ).click(function() { | |
viewport = document.querySelector('meta[name=viewport]'); | |
viewport.setAttribute('content', 'width=1024'); | |
return false; | |
}); | |
$( '.mobile-site-link' ).click(function() { | |
viewport = document.querySelector('meta[name=viewport]'); | |
viewport.setAttribute('content', 'width=device-width, initial-scale=1.0'); | |
return false; |
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
grunt Sass | |
https://github.com/gruntjs/grunt-contrib-sass | |
grunt Autoprefixer | |
https://github.com/nDmitry/grunt-autoprefixer | |
grunt imageoptim |
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
/* | |
Mixin or similar title | |
////////////////////// | |
A Short two/three sentence description of what the file is and what it does | |
An example of how to use the code | |
An example of the compiled CSS |
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
<header> | |
<h1>This is a heading</h1> | |
</header> |