@extends('layouts.previews.intercontinental') @php use App\Enums\ElementType; use App\Enums\PostType; use App\Enums\CustomElementType; use App\Enums\Boolean; $banner = current( array_filter($elements, function ($value) { return $value['element_type'] == ElementType::DEFAULT && $value['default_element_type'] == PostType::BANNER; }), ); @endphp @section('content')
@foreach ($elements as $item) @if (fieldPropertyValue('status', $item)) @if (fieldPropertyValue('element_type', $item) == ElementType::DEFAULT) @switch(fieldPropertyValue('default_element_type', $item)) @case(PostType::CONCEPT) @include('preview.intercontinental.defaults.post.concept') @break @case(PostType::MAIN_CONTENT) @include('preview.intercontinental.defaults.post.mainContent') @break @case(PostType::PLAN) @include('preview.intercontinental.commons.plan') @break @endswitch @endif @if (fieldPropertyValue('element_type', $item) == ElementType::CUSTOM && fieldPropertyValue('custom_element_type', $item) == CustomElementType::CONTACT) @include('preview.intercontinental.customs.contactContent') @endif @endif @if (fieldPropertyValue('element_type', $item) == ElementType::CUSTOM && (textLocale('status', $item, $lang))) @if (fieldPropertyValue('custom_element_type', $item) >= CustomElementType::ONE_COLUMN && fieldPropertyValue('custom_element_type', $item) <= CustomElementType::SIDE_CONTENT_V2)
@include('preview.customs.customContent')
@endif @endif @endforeach
@endsection