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
/* Clearfix */ | |
.clearfix:before, | |
.clearfix:after { | |
content: ""; | |
display: table; | |
} | |
.clearfix:after { | |
clear: both; |
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
// Released under MIT license: http://www.opensource.org/licenses/mit-license.php | |
$('[placeholder]').focus(function() { | |
var input = $(this); | |
if (input.val() == input.attr('placeholder')) { | |
input.val(''); | |
input.removeClass('placeholder'); | |
} | |
}).blur(function() { | |
var input = $(this); | |
if (input.val() == '' || input.val() == input.attr('placeholder')) { |
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
// Sticky Element on scroll | |
var sticky = $('.selector'); | |
var top = sticky.offset().top - parseFloat(sticky.css('margin-top').replace(/auto/, 0)); | |
$(window).scroll(function (event) { | |
var y = $(this).scrollTop(); | |
y >= top ? sticky.addClass('fixed') : sticky.removeClass('fixed'); | |
}); |
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
// Detect Mobile Devices | |
var isMobile = { | |
Android: function() { | |
return navigator.userAgent.match(/Android/i); | |
}, | |
BlackBerry: function() { | |
return navigator.userAgent.match(/BlackBerry/i); | |
}, | |
iOS: function() { | |
return navigator.userAgent.match(/iPhone|iPad|iPod/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
find -name '*' -type d -exec chmod 0755 {} \; |
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
find . -type f -exec chmod 0644 {} \; |
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
# Compiled source # | |
################### | |
*.com | |
*.class | |
*.dll | |
*.exe | |
*.o | |
*.so | |
# Packages # |
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
.mfp-fade.mfp-bg { | |
opacity: 0; | |
background: #00; | |
transition: all .3s; | |
} | |
.mfp-fade.mfp-bg.mfp-ready { opacity: .9; } | |
.mfp-fade.mfp-bg.mfp-removing { opacity: 0; } | |
.mfp-fade.mfp-wrap .mfp-content { |
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() { | |
})(); |
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
// Show viewport size | |
document.addEventListener('DOMContentLoaded', function() { | |
document.body.insertAdjacentHTML('afterend', '<div id="viewport-size" style="position:fixed; top:0; right:0; z-index: 9999; padding:0 .5em; color:#333; background:rgba(255,255,255,.75); font: 14px/1.8em Monaco, Inconsolata, Ubuntu Mono, Courier New, monospaced;"></div>'); | |
showViewportSize(); | |
}); | |
window.onresize = function() { showViewportSize(); } | |
function showViewportSize() { | |
var body = document.body, |
OlderNewer