feat(ui): refine post interaction surfaces
This commit is contained in:
@@ -22,8 +22,9 @@ export function PostLikeButton({ postId, initialLiked, initialLikeCount }: PostL
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
aria-label={liked ? "取消点赞帖子" : "点赞帖子"}
|
||||
disabled={pending}
|
||||
className="flex items-center gap-1 hover:text-foreground transition-colors disabled:opacity-60 disabled:pointer-events-none"
|
||||
className="flex items-center gap-1 text-muted-foreground transition-colors hover:text-foreground disabled:pointer-events-none disabled:opacity-60"
|
||||
onClick={() =>
|
||||
requireAuth(() => {
|
||||
if (pending) return
|
||||
@@ -52,7 +53,7 @@ export function PostLikeButton({ postId, initialLiked, initialLikeCount }: PostL
|
||||
})
|
||||
}
|
||||
>
|
||||
<Heart className={`h-4 w-4 ${liked ? "fill-red-500 text-red-500" : ""}`} />
|
||||
<Heart className={`h-4 w-4 ${liked ? "fill-destructive text-destructive" : ""}`} />
|
||||
{likeCount}
|
||||
</button>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user