{{-- resources/views/general/posts/partials/comment-item.blade.php --}}
@if($comment->user->avatar_url) {{ $comment->user->name }} @else
@endif
{{-- Comment Header --}}

{{ $comment->user->name }}

{{ $comment->formatted_time }}
@if($comment->can_delete) @endif
{{-- Comment Content --}}

{{ $comment->content }}

{{-- Comment Reactions --}}
@foreach(['like' => '👍', 'love' => '❤️', 'angry' => '😡', 'sad' => '😢'] as $type => $icon) @if($comment->reaction_counts[$type] > 0 || $comment->user_reaction === $type) @endif @endforeach
{{-- Reply Form (Hidden by default) --}} {{-- Replies List --}}
@foreach($comment->replies()->with('user')->latest()->take(2)->get() as $reply) @include('general.posts.partials.reply-item', ['reply' => $reply]) @endforeach @if($comment->replies()->count() > 2) @endif