<x-layouts.app>
    <!-- navigation -->
    @include('theme::partials.inner_navigation')
    @sortableWidgets($widgetInstance, 'home')
    @sortableWidgets($footerInstance, 'footer')


</x-layouts.app>


{{-- Seo --}}
@section('meta_title')
    @php
        if($modelPage) {
            $title = $modelPage->withFakes()->meta_title ?? $modelPage->title ?? theme_option('title');
        } else {
            $title = theme_option('title');
        }
    @endphp
    {{$title}}
@endsection
@section('meta_description')
    @php
        if($modelPage) {
            $description = $modelPage->withFakes()->meta_description ?? $modelPage->description ?? theme_option('meta_title');
        } else {
            $description = theme_option('meta_title');
        }
    @endphp
    {{$description}}
@endsection
@section('header.custom_meta')
    @php
        if($modelPage) {
            $title = $modelPage->withFakes()->meta_title ?? $modelPage->title ?? theme_option('title');
        } else {
            $title = theme_option('title');
        }

        if($modelPage) {
            $description = $modelPage->withFakes()->meta_description ?? $modelPage->description ?? theme_option('meta_title');
        } else {
            $description = theme_option('meta_title');
        }
    @endphp
    <script type="application/ld+json">
        {
          "@context": "https://schema.org",
          "@type": "WebSite",
          "name": "{{$title}}",
          "url": "{{url('')}}",
          "potentialAction": {
            "@type": "SearchAction",
            "target": "{{route('search')}}?search_term={search_term_string}",
            "query-input": "required name=search_term_string"
          },
          "description": "{{$description}}",
          "inLanguage": "fa",
          "publisher": {
            "@type": "Organization",
            "name": "{{theme_option('title')}}",
            "logo": {
              "@type": "ImageObject",
              "url": "{{(theme_option('logo') !== null) ? url('/storage').'/'.theme_option('logo') : theme('img/logo.svg')}}"
            }
          }
        }
    </script>
@endsection
