diff options
Diffstat (limited to 'public/assets/js/app.js')
| -rw-r--r-- | public/assets/js/app.js | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/public/assets/js/app.js b/public/assets/js/app.js index eff6dab..c21ed73 100644 --- a/public/assets/js/app.js +++ b/public/assets/js/app.js @@ -27,7 +27,7 @@ var app = (function() { document.addEventListener('touchmove', function(e) { e.preventDefault() }) - // FastClick.attach(document.body) + FastClick.attach(document.body) } $(window).resize(app.resize) @@ -70,7 +70,11 @@ var app = (function() { setTimeout(function(){ $(".item").each(function(i){ var height = window.innerHeight - $(this).find(".bottom").height() + if (is_desktop) { + height -= $("nav").height() // account for top bar + } $(".previous, .next, .cell, .top, .flickity-viewport", this).css({ 'height': height }) + $(".bottom", this).css({ 'top': height }) }) app.view.$el.removeClass("hidden") // $('.top').flickity('resize') @@ -84,8 +88,12 @@ var app = (function() { })() $(".item").each(function(i){ - var height = window.innerHeight - $(this).find(".bottom").height() + var height = window.innerHeight - ($(this).find(".bottom").height() + 10) + if (is_desktop) { + height -= $("nav").height() // account for top bar + } $(".cell, .top", this).css({ 'height': height }) + $(".bottom", this).css({ 'top': height + 20 }) }) $('.top').each(function(){ @@ -99,6 +107,9 @@ $('.top').each(function(){ $(".item").each(function(i){ var height = window.innerHeight - $(this).find(".bottom").height() + if (is_desktop) { + height -= $("nav").height() // account for top bar + } $(".previous, .next, .flickity-viewport", this).css({ 'height': height }) }) |
