From 29dcea294d4288d20842accad695852c62bdc3a1 Mon Sep 17 00:00:00 2001 From: Aaron Parecki Date: Sat, 24 Dec 2016 09:46:10 -0800 Subject: [PATCH] fix reply context display for long posts closes #62 --- views/new-post.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/views/new-post.php b/views/new-post.php index d75d6b4..bc77191 100644 --- a/views/new-post.php +++ b/views/new-post.php @@ -17,6 +17,7 @@
+
@@ -140,6 +141,8 @@ border: 1px #ccc solid; border-radius: 4px; background: #f4f4f4; + max-height: 140px; + overflow-y: hidden; } .reply-context img.author-img { border-radius: 4px; @@ -342,8 +345,13 @@ $(function(){ } $(".reply-context .content").text(data.entry.content.text); - $(".reply-context .name").text(data.entry.author.name); - $(".reply-context .url").text(data.entry.author.url); + if(data.entry.name) { + $(".reply-context .post-name").text(data.entry.name).removeClass('hidden'); + } else { + $(".reply-context .post-name").addClass('hidden'); + } + $(".reply-context .author .name").text(data.entry.author.name); + $(".reply-context .author .url").text(data.entry.author.url); $(".reply-context img.author-img").attr('src', data.entry.author.photo); if(data.entry.photo) { $(".reply-context img.post-img").attr('src', data.entry.photo[0]).removeClass('hidden');