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
@keyframes animatedBackground { | |
from { background-position: 0 0; } | |
to { background-position: -200px 0; } | |
} | |
.background { | |
display: block; | |
height: 200px; | |
width: 100%; | |
background: url(../assets/img/pattern.svg); |
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
function isTouchDevice() { | |
return (('ontouchstart' in window) | |
|| (navigator.MaxTouchPoints > 0) | |
|| (navigator.msMaxTouchPoints > 0)); | |
} |
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
// .-"```'. | |
// / \ \ | |
// / / `\__/ ,________ _ | |
// | .' _ _| '----)==)`< | |
// \(\ 6 6 `~~\__) | |
// | \ _\ | | |
// |\ `~`= `/ | |
// | '.___.' | |
// .'` \ |_ | |
// '-__ / `- |
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
$colors: $color-vivid-red,$color-vivid-red-medium,$color-vivid-red-dark, | |
$color-dark-blue,$color-dark-blue-medium,$color-dark-blue-dark, | |
$color-moderate-blue,$color-moderate-blue-medium,$color-moderate-blue-light, | |
$color-vivid-orange,$color-vivid-orange-medium,$color-vivid-orange-light; | |
$colors-length: length($colors); | |
background-color: nth($colors, random($colors-length)); | |
@for $i from 1 through 4 { | |
&:nth-child(n + #{$i}) { |
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
function getIEVersion() { | |
var ua = window.navigator.userAgent, | |
msie = ua.indexOf("MSIE "), | |
version = false; | |
if (msie > 0) { | |
// If Internet Explorer, return version number | |
version = (parseInt(ua.substring(msie + 5, ua.indexOf(".", msie)))); | |
} | |
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
@mixin font-size($size, $modifier:1.6) { | |
/* For optimal use, adjust the default modifier value until it gives you the | |
same pixel value as the computed pixel value you get from using REMs. | |
If your root font-size is 100%, this will be 1.6 */ | |
// IE 8 fallback in pixels | |
$pixel-size: ($size * 10) * $modifier; | |
font-size: #{$pixel-size}px; | |
// fontsize in REM |
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
@mixin calc($property, $operation) { | |
#{$property}: -webkit-calc(#{$operation}); | |
#{$property}: -moz-calc(#{$operation}); | |
#{$property}: calc(#{$operation}); | |
} | |
// Make sure to pass your operation as a string, or else it will cause compile errors as SASS will try and evaluate it. |
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
alias sub='open -a "Sublime Text"' | |
alias currentbranch='git rev-parse --abbrev-ref HEAD' | |
alias testnomigrations='forage test --settings=yunojuno.settings.test_settings.skipmigrations --verbosity=2' | |
export NVM_DIR="/Users/alasdairscott/.nvm" | |
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm | |
# Git/SVN PS1 | |
parse_git_branch () { |
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
git diff --name-only HEAD~10 HEAD~5 |
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 | |
$elements = array( | |
array( | |
'id' => 1, | |
'is_test' => false | |
), | |
array( | |
'id' => 2, | |
'is_test' => true | |
), |
NewerOlder