feat: Update reply layout to match post layout

This commit is contained in:
Kerby Martino (aider) committed 2025-05-04 22:07:43 +08:00
1 parent a9a1a9861a
commit 7bdc012868
1 file changed
+26 -10
+26 -10
View File
@@ -1,22 +1,36 @@
--- ---
layout: simple layout: default
--- ---
<article class="flex"> <article class="flex">
<div class="mr-2"> <div class="mr-2">
<a href="#" class="text-text-muted no-underline text-sm leading-none inline-block pt-0.5 hover:text-link-hover" title="Upvote">▲</a> <a href="#" class="text-text-muted no-underline text-sm leading-none inline-block pt-0.5 hover:text-link-hover" title="Back"><i class="fas fa-arrow-left"></i></a>
</div> </div>
<div class="flex-1 text-left"> <div class="flex-1 text-left">
<div> <div>
<p class="mt-0 mb-0.5"> <p class="mt-0 mb-1">
<strong><a href="#" class="text-text-title font-normal text-base hover:underline">{{ page.post_title }}</a></strong> <strong><a href="#" class="text-text-title font-bold text-base hover:underline">{{ page.title }}</a></strong>
</p> </p>
<div class="mt-0 mb-1 text-sm flex items-center"> <div class="post-content mb-2">
<small class="text-text-muted text-xs"><a href="#" class="text-xs text-primary hover:underline">{{ page.post_author }}</a> | {{ page.post_date | date: "%d %b %Y" }} | <a href="#" class="text-xs text-primary hover:underline">report</a> | <a href="#" class="text-xs text-primary hover:underline">parent</a> | <a href="#" class="text-xs text-primary hover:underline">{{ comment_count }} comments</a></small> {{ content }}
</div> </div>
<div class="post-content"> <div class="mt-2 mb-1 text-sm flex flex-col md:flex-row items-start md:items-center md:space-x-2">
{{ content }} <div class="flex items-start space-x-2 mb-2 md:mb-0">
<span class="bg-gray-200 text-gray-700 text-xs font-action px-4 py-2 rounded-full flex items-center cursor-pointer hover:bg-link-hover">
<i class="fa-solid fa-arrow-up mr-1"></i> {{ page.upvotes }}
</span>
<span class="bg-gray-200 text-gray-700 text-xs font-action px-4 py-2 rounded-full flex items-center cursor-pointer hover:bg-link-hover">
<i class="fas fa-reply mr-1"></i> REPLY
</span>
<span class="bg-gray-200 text-gray-700 text-xs font-action px-4 py-2 rounded-full flex items-center cursor-pointer hover:bg-link-hover">
<i class="fas fa-comment mr-1"></i> {{ page.comments_count }}
</span>
</div>
<small class="text-sm font-action">
<a href="#" class="text-sm hover:underline">{{ page.author }}</a>
<span class="text-text-muted text-sm opacity-75">{{ page.date | date: "%d %b %Y" }}</span>
</small>
</div> </div>
</div> </div>
</div> </div>
@@ -27,11 +41,13 @@ layout: simple
<div class="mb-4"> <div class="mb-4">
<label class="block font-medium text-sm mb-1" for="comment-body">Comment:</label> <label class="block font-medium text-sm mb-1" for="comment-body">Comment:</label>
<div> <div>
<textarea class="w-full px-3 py-2 bg-bg-light border border-gray-300 rounded" id="comment-body" name="body" placeholder="Enter your comment" required></textarea> <textarea class="w-full text-primary text-sm px-3 py-2 bg-transparent border-b-2 border-gray-300 focus:outline-none focus:border-primary transition duration-150 ease-in-out placeholder:text-xs" id="comment-body" name="body" placeholder="Enter your comment" required></textarea>
</div> </div>
</div> </div>
<div> <div>
<button class="px-4 py-2 bg-primary text-white rounded hover:bg-primary-dark" type="submit">Reply</button> <button class="px-4 py-2 bg-primary text-white rounded hover:bg-primary-dark" type="submit">Add Comment</button>
</div> </div>
</form> </form>
{% include mobile_comment_top.liquid %}
</div> </div>