@extends('frontend.layouts.app') @section('title', 'Mesajlar — Animexe') @push('styles') @endpush @section('content')

Mesajlar

@if($conversations->isEmpty())

Henüz mesajın yok.
Bir kullanıcının profiline git ve mesaj gönder.

@else
@foreach($conversations as $conv) @php $other = $conv['other']; $last = $conv['last_message']; $unread= $conv['unread']; @endphp
@if($other?->avatar) {{ $other->name }} @else {{ mb_strtoupper(mb_substr($other?->name ?? '?', 0, 1)) }} @endif
{{ $other?->name ?? 'Silinmiş Kullanıcı' }} @if($unread > 0) {{ $unread }} @endif
@if($last) @if($last->user_id === auth()->id()) Sen: @endif @if(str_starts_with($last->body, 'ANIMESHARE::')) @php try { $sd = json_decode(substr($last->body,12),true); } catch(\Throwable $e){ $sd=null; } @endphp {{ $sd['title'] ?? 'Anime' }} paylaştı @elseif(str_starts_with($last->body, 'IMAGE::')) Fotoğraf @elseif(str_starts_with($last->body, 'GIF::')) GIF @else {{ Str::limit($last->body, 60) }} @endif @else Henüz mesaj yok @endif
@if($unread > 0)
@endif @if($conv['updated_at']){{ $conv['updated_at']->diffForHumans(null, true) }}@endif
@endforeach
@endif
@endsection