@forelse($activities as $index => $activity) @php $isLast = $limit ? ($index === count($activities) - 1) : ($activities->hasMorePages() ? false : ($index === $activities->count() - 1)); $isReplyOrNote = str_contains($activity->description, 'Reply') || str_contains($activity->description, 'Internal note'); $descriptionKey = \Illuminate\Support\Str::slug($activity->description, '_'); @endphp
@if(!$isLast)
@endif

{{ __('creators-ticketing::resources.activities.' . $descriptionKey) }}

{{ $activity->created_at->diffForHumans() }}
👤 {{ \daacreators\CreatorsTicketing\Support\UserNameResolver::resolve($activity->user) ?? __('creators-ticketing::resources.timeline.system') }}
@if($activity->old_value || $activity->new_value)
@if($isReplyOrNote && $activity->new_value)
{!! \Illuminate\Support\Str::limit(strip_tags($activity->new_value), 150) !!}
@else
@if($activity->old_value) {{ __('creators-ticketing::resources.timeline.from') }} {{ $activity->old_value }} @endif @if($activity->old_value && $activity->new_value) @endif @if($activity->new_value) {{ __('creators-ticketing::resources.timeline.to') }} {{ $activity->new_value }} @endif
@endif
@endif
{{ $activity->created_at->format('M d, Y • H:i:s') }}
@empty

{{ __('creators-ticketing::resources.timeline.empty_title') }}

{{ __('creators-ticketing::resources.timeline.empty_desc') }}

@endforelse @if(!$limit && method_exists($activities, 'hasPages') && $activities->hasPages())
{{ $activities->links() }}
@endif