@extends('layouts.app') @section('title', $c['title'] ?? '') @section('meta_description', $c['meta_description'] ?? '') @php $ogSize = ! empty($c['image']) ? @getimagesize(public_path($c['image'])) : null; @endphp @if (! empty($c['image'])) @section('og_image', asset($c['image'])) @if ($ogSize) @section('og_image_width', (string) $ogSize[0]) @section('og_image_height', (string) $ogSize[1]) @endif @elseif (file_exists(public_path('brand/comparisons/'.$slug.'-'.app()->getLocale().'.webp'))) @section('og_image', asset('brand/comparisons/'.$slug.'-'.app()->getLocale().'.webp')) @endif @section('content') @include('partials.page-hero', [ 'crumbs' => [ ['name' => __('app.nav.home'), 'url' => lroute('home')], ['name' => __('app.nav.comparisons'), 'url' => lroute('comparisons')], ['name' => $c['title'] ?? ''], ], 'title' => $c['h1'] ?? '', 'lead' => $c['lead'] ?? '', ])
@if (! empty($c['image'])) {{ $c['title'] ?? '' }} @elseif (file_exists(public_path('brand/comparisons/'.$slug.'-'.app()->getLocale().'.webp'))) {{ $c['title'] ?? '' }} @endif
@php $guideSections = $c['sections'] ?? null; @endphp @if (is_array($guideSections))
@foreach ($guideSections as $section)

{{ $section['title'] }}

@foreach ($section['paragraphs'] as $paragraph)

{{ $paragraph }}

@endforeach
@endforeach
@endif

{{ $c['points_title'] ?? '' }}

@foreach (($c['points'] ?? []) as $point)

{{ $point['title'] }}

{{ $point['text'] }}

@endforeach
@php $comparisonTable = $c['table'] ?? null; @endphp @if (is_array($comparisonTable))

{{ $c['table_title'] ?? '' }}

@foreach ($comparisonTable as $row) @endforeach
{{ $c['table_feature'] ?? '' }} {{ $c['table_qoodz'] ?? '' }} {{ $c['table_other'] ?? '' }}
{{ $row['feature'] }} {{ $row['qoodz'] }} {{ $row['other'] }}

{{ $c['table_note'] ?? '' }}

@endif

{{ $c['steps_title'] ?? '' }}

@foreach (($c['steps'] ?? []) as $i => $step)
{{ $i + 1 }}

{{ $step }}

@endforeach
@php $comparisonFaq = $c['faq'] ?? null; @endphp @if (is_array($comparisonFaq) && count($comparisonFaq))

{{ __('app.nav.faq') }}

@foreach ($comparisonFaq as $item)
{{ $item['q'] }}
{{ $item['a'] }}
@endforeach
@endif @php $relatedLinks = $c['related'] ?? []; @endphp @if (is_array($relatedLinks) && count($relatedLinks))

{{ __('app.comparisons.related_title') }}

@foreach ($relatedLinks as $link) @php $linkType = $link['type'] ?? 'route'; $href = match ($linkType) { 'solution' => lroute('solution', ['slug' => $link['slug']]), 'comparison' => lroute('comparison', ['slug' => $link['slug']]), 'industry' => lroute('industry', ['slug' => $link['slug']]), 'post' => lroute('blog.show', ['slug' => $link['slug']]), default => lroute($link['route']), }; $label = isset($link['label']) ? __($link['label']) : match ($linkType) { 'solution' => __("app.solutions.{$link['slug']}.nav"), 'comparison' => __("app.comparisons.{$link['slug']}.title"), 'industry' => __("app.industries.{$link['slug']}.nav"), 'post' => __("app.post_titles.{$link['slug']}"), default => '', }; @endphp {{ $label }} @endforeach
@endif @include('partials.cta') @endsection