sneaky fixed header

This commit is contained in:
danielgrippi 2011-05-11 18:53:59 -07:00
parent cb49d1f4ea
commit 47cf614996
2 changed files with 16 additions and 1 deletions

View file

@ -4,6 +4,16 @@
*/
var View = {
initialize: function() {
$(window).scroll(function(){
var header = $('header');
if( $(this).scrollTop() > 30){
header.addClass('fixit');
} else {
header.removeClass('fixit');
}
});
/* Buttons */
$("input:submit").addClass("button");

View file

@ -136,11 +136,16 @@ header
:top 2px
:color #CCC
:position fixed
:position absolute
:width 100%
:top 0
:left 0
&.fixit
:position fixed
:top -30px
a
:color #CCC