{{-- Dynamic Header Component for FAQs --}} @php // Get active demo $activeDemo = get_active_demo(); // Get module configuration for title $moduleConfig = get_module_page_header_config('faqs'); $faqsTitle = $moduleConfig['title'] ?? 'FAQs'; $faqsLabel = mb_strtoupper($faqsTitle); // Determine current context and set content if (isset($currentCategory) && $currentCategory) { // Category view $pageTitle = $currentCategory->name ?? $faqsTitle; $breadcrumbItems = [ ['url' => route('front.welcome'), 'label' => 'Home'], ['url' => route('faqs.index'), 'label' => $faqsLabel], ['url' => null, 'label' => mb_strtoupper($currentCategory->name ?? 'Category')] ]; $pageSubtitle = $currentCategory->description ?? $moduleConfig['subtitle'] ?? null; } else { // Index view $pageTitle = $faqsTitle; $breadcrumbItems = [ ['url' => route('front.welcome'), 'label' => 'Home'], ['url' => null, 'label' => $faqsLabel] ]; $pageSubtitle = $moduleConfig['subtitle'] ?? null; } @endphp @if($activeDemo === 'demo-law-firm-2') @include('layout.front.partials.page-header-law-firm-2', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-digital-agency-2') @include('layout.front.partials.page-header-digital-agency-2', [ 'pageTitle' => $pageTitle, 'pageLabel' => 'FAQ', 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-transportation-logistic') @include('layout.front.partials.page-header-transportation-logistic', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-architecture-2') @include('layout.front.partials.page-header-architecture-2', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-accounting-2') @include('layout.front.partials.page-header-accounting-2', [ 'pageTitle' => $pageTitle, 'pageLabel' => $faqsLabel, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? config('site.modules.faqs.page_header.subtitle', 'Encontrá respuestas a las preguntas más comunes sobre nuestros productos y servicios.'), ]) @elseif($activeDemo === 'demo-product-landing') @include('layout.front.partials.page-header-product-landing', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-photography-3') @include('layout.front.partials.page-header-photography-3', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-construction-2') @include('layout.front.partials.page-header-construction-2', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-restaurant') @include('layout.front.partials.page-header-restaurant', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-insurance') @include('layout.front.partials.page-header-insurance', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-accounting-1') @include('layout.front.partials.page-header-accounting-1', [ 'pageTitle' => $pageTitle, 'pageLabel' => 'PREGUNTAS FRECUENTES', 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-business-consulting') @include('layout.front.partials.page-header-business-consulting', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-construction') @include('layout.front.partials.page-header-construction', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-creative-agency-2') @include('layout.front.partials.page-header-creative-agency-2', [ 'pageTitle' => $pageTitle, 'pageLabel' => 'FAQ', 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-marketing-1') @include('layout.front.partials.page-header-marketing-1', [ 'pageTitle' => $pageTitle, 'pageLabel' => 'FAQ', 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-sass') @include('layout.front.partials.page-header-sass', [ 'pageTitle' => $pageTitle, 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @elseif($activeDemo === 'demo-real-estate') @include('layout.front.partials.page-header-real-estate', [ 'pageTitle' => $pageTitle, 'pageLabel' => mb_strtoupper($pageTitle), 'pageBreadcrumb' => $breadcrumbItems, 'pageSubtitle' => $pageSubtitle ?? null, ]) @else {{-- Default/Other Demo Style Header --}}

{{ $pageTitle }}

@if(!empty($pageSubtitle))

{{ $pageSubtitle }}

@endif
@endif