{{-- Partial: comment-item Dipanggil dari vault/show.blade.php dan bisa dipakai di tempat lain. Variable yang dibutuhkan: $comment (App\Models\Comment) --}}
{{ strtoupper(substr($comment->user->name, 0, 1)) }}
{{ $comment->user->name }} {{ $comment->user->role }}
{{ $comment->created_at->diffForHumans() }}
{!! nl2br(e($comment->body)) !!}
@if($comment->has_code_snippet && $comment->code_snippet)
{{ strtoupper($comment->code_language ?? 'code') }}
{{ $comment->code_snippet }}
@endif {{-- Replies --}} @if($comment->replies && $comment->replies->count() > 0)
@foreach($comment->replies as $reply)
{{ strtoupper(substr($reply->user->name, 0, 1)) }}
{{ $reply->user->name }} {{ $reply->created_at->diffForHumans() }}

{!! nl2br(e($reply->body)) !!}

@endforeach
@endif
@push('scripts') @endpush