Line 85: | Line 85: | ||
$(".icon").not(icon).removeClass("less").addClass("plus"); | $(".icon").not(icon).removeClass("less").addClass("plus"); | ||
}); | }); | ||
+ | |||
+ | is_the_window_too_small ( ) | ||
} | } | ||
Line 96: | Line 98: | ||
}); | }); | ||
+ | |||
+ | |||
+ | //check if the menu is longer than the page | ||
+ | |||
+ | function is_the_window_too_small ( ) { | ||
+ | if ( $( ".menu_wrapper" ).height() > window.innerHeight ) { | ||
+ | |||
+ | console.log( "size is too small! "); | ||
+ | } | ||
+ | |||
+ | else { | ||
+ | console.log (" the size is okay"); | ||
+ | } | ||
+ | } | ||
Revision as of 21:30, 14 November 2016