From 72de7501d35005c1cb3d3b6de270600d9d431a9b Mon Sep 17 00:00:00 2001 From: Dorian Date: Thu, 12 Feb 2026 12:43:21 +0000 Subject: [PATCH] Redesign comments into glass bubble format - Top-level comments render as glass-card bubbles with subtle border, backdrop blur, and hover highlight - Replies use a lighter, more compact bubble variant - Threaded replies connected by a vertical line on the left instead of raw margin indentation - Action buttons (upvote, downvote, reply, expand) styled as pill-shaped micro-buttons inside each bubble - Reply form nests inline within the parent bubble - Proper spacing and responsive padding at all nesting depths Co-authored-by: Cursor --- src/components/CommentNode.vue | 318 +++++++++++++++----------- src/components/ContentDetailModal.vue | 4 +- 2 files changed, 186 insertions(+), 136 deletions(-) diff --git a/src/components/CommentNode.vue b/src/components/CommentNode.vue index 446fa38..a68e59d 100644 --- a/src/components/CommentNode.vue +++ b/src/components/CommentNode.vue @@ -1,118 +1,114 @@ @@ -162,6 +158,12 @@ const authorAvatar = computed(() => { return `https://robohash.org/${props.node.event.pubkey}.png` }) +// Dynamic bubble class based on nesting depth +const bubbleClass = computed(() => { + if (props.depth === 0) return 'bubble-root' + return 'bubble-reply' +}) + // Time formatting const timeAgo = computed(() => { const now = Math.floor(Date.now() / 1000) @@ -216,73 +218,121 @@ async function submitReply() { diff --git a/src/components/ContentDetailModal.vue b/src/components/ContentDetailModal.vue index bd96ed6..26d38f2 100644 --- a/src/components/ContentDetailModal.vue +++ b/src/components/ContentDetailModal.vue @@ -177,8 +177,8 @@
No comments yet. Be the first!
- -
+ +