diff --git a/css/template.css b/css/template.css index 9fc9ff3..0bc74ce 100644 --- a/css/template.css +++ b/css/template.css @@ -40,8 +40,7 @@ body { .post-content { font-size: 12px; - min-height: 5em; - height: 5em; + max-height: 5em; overflow: hidden; padding-bottom: 10px; } diff --git a/js/funcs.js b/js/funcs.js index 930acc0..71444ef 100644 --- a/js/funcs.js +++ b/js/funcs.js @@ -46,7 +46,7 @@ $(document).ready( function () { $(".content-slider").click(function (e) { var contentDiv = $(this).parents('.news-row').find('.post-content'); if (contentDiv.hasClass("state-up")) { - contentDiv.removeClass('state-up').addClass('state-down').animate({height: '100%'}); + contentDiv.removeClass('state-up').addClass('state-down').animate({'max-height': '100%', 'height': '100%'}); $(this).html('^'); } else { contentDiv.removeClass('state-down').addClass('state-up').animate({height: '5em'}); diff --git a/route_handlers.go b/route_handlers.go index 6ee8026..9ea0cbf 100644 --- a/route_handlers.go +++ b/route_handlers.go @@ -418,7 +418,7 @@ func newsFormHandler(w http.ResponseWriter, r *http.Request, user *user.User, se session.AddFlash("Error loading news", flash_err) } - ShowTemplate("news", w, r, map[string]interface{}{"user": user, "flashes": flashes, "news": news, "count": count, "categories": categories.CategoriesFlat, "url": config.Url}) + ShowTemplate("news", w, r, map[string]interface{}{"user": user, "flashes": flashes, "news": news, "count": count, "offset": argOffset, "amount": amount, "categories": categories.CategoriesFlat, "url": config.Url}) } func ServeFileHandler(res http.ResponseWriter, req *http.Request) { diff --git a/templates/pages/news.html b/templates/pages/news.html index 6d863ae..a9e2d41 100644 --- a/templates/pages/news.html +++ b/templates/pages/news.html @@ -9,14 +9,22 @@