@php $locale = app()->getLocale(); $categoryQuery = filled($categoryId ?? null) ? ['category_id' => $categoryId] : []; $hasAny = ($relatedProducts ?? collect())->isNotEmpty() || ($relatedServices ?? collect())->isNotEmpty() || ($relatedArticles ?? collect())->isNotEmpty(); @endphp @if ($hasAny)
@if (filled($categoryId ?? null)) @endif @if (($relatedProducts ?? collect())->isNotEmpty())

{{ __('site.related_products') }}

{{ __('site.view_all') }}
@foreach ($relatedProducts as $item) @endforeach
@endif @if (($relatedServices ?? collect())->isNotEmpty())

{{ __('site.related_services') }}

{{ __('site.view_all') }}
@endif @if (($relatedArticles ?? collect())->isNotEmpty())

{{ __('site.related_articles') }}

{{ __('site.view_all') }}
@endif
@endif