Initial Commit

This commit is contained in:
mathias 2014-11-11 22:27:42 +02:00
parent d468000251
commit 15159639b7
3 changed files with 19 additions and 9 deletions

View file

@ -31,5 +31,6 @@
</section> </section>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js"></script>
<script src="js/minecraft.js"></script>
</body> </body>
</html> </html>

View file

@ -1,11 +1,3 @@
$(window).scroll(function() {
if ($(".navbar").offset().top > 50) {
$(".navbar-fixed-top").addClass("top-nav-collapse");
} else {
$(".navbar-fixed-top").removeClass("top-nav-collapse");
}
});
$(function() { $(function() {
$('.page-scroll a').bind('click', function(event) { $('.page-scroll a').bind('click', function(event) {
var $anchor = $(this); var $anchor = $(this);

17
js/minecraft.js~ Normal file
View file

@ -0,0 +1,17 @@
$(window).scroll(function() {
if ($(".navbar").offset().top > 50) {
$(".navbar-fixed-top").addClass("top-nav-collapse");
} else {
$(".navbar-fixed-top").removeClass("top-nav-collapse");
}
});
$(function() {
$('.page-scroll a').bind('click', function(event) {
var $anchor = $(this);
$('html, body').stop().animate({
scrollTop: $($anchor.attr('href')).offset().top
}, 1500, 'easeInOutExpo');
event.preventDefault();
});
});