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 sprite($icon-name, $important: '') { | |
@if $important != '' { | |
// @1x resolution screens | |
background-image: sprite-url($sprite-pri) !important; | |
background-position: sprite-position($sprite-pri, $icon-name) !important; | |
// @2x resolution screens | |
@include breakpoint($hi_res) { | |
background-image: sprite-url($sprite-pri--2x) !important; |
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
<div class="ajax-progress ajax-progress-throbber"><div class="throbber"> </div></div> |
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
// Clearfix | |
.clearfix, %clearfix { | |
&:before, &:after { | |
content: ''; | |
display: table; | |
} | |
&:after { | |
clear: both; | |
} |
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
# Just in case the file goes over the IE limit, | |
# split the file into multiple. | |
on_stylesheet_saved do |filename| | |
begin | |
result = system('blessc',filename,'-f') | |
if not result | |
Kernel.exit(false) | |
else | |
puts "Blessed the file, so it will work in older versions of IE." | |
end |
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
window.onload = function() { | |
// Awesome stuff goes here | |
} |
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
<script> | |
document.documentElement.className = document.documentElement.className.replace(/(\s|^)no-js(\s|$)/, '$1js$2'); | |
</script> |
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
function getScrollTop(){ | |
if(typeof pageYOffset!= 'undefined'){ | |
//most browsers except IE before #9 | |
return pageYOffset; | |
} | |
else{ | |
var B= document.body; //IE 'quirks' | |
var D= document.documentElement; //IE with doctype | |
D= (D.clientHeight)? D: B; | |
return D.scrollTop; |
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
window.onbeforeunload = function() { | |
return "Two buttons will be below this message asking if user wants to stay on this page or leave."; | |
}; |
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
// Convert a px value into a rem value. | |
// Supply the rem value to the primary style sheet and the px fallback to the ltie9 style sheet. | |
@function rem($pxval) { | |
$val: strip-unit($pxval); | |
$base: strip-unit($browser-default-font-size); | |
@if ($ltie9 == true) { | |
@return $val * 1px; |
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
%vertical-align { | |
position: relative; | |
top: 50%; | |
-webkit-transform: translateY(-50%); | |
-ms-transform: translateY(-50%); | |
transform: translateY(-50%); | |
} | |
.element p { | |
@extend %vertical-align; |
NewerOlder