@extends('layouts.previews.ibisStyles')
@php
use App\Enums\ElementType;
use App\Enums\NewsElementDefault;
use App\Enums\CustomElementType;
@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(NewsElementDefault::PLAN)
@include('preview.ibisStyles.commons.plan')
@break
@case(NewsElementDefault::CV_NEXT)
@php
$reserve = $item;
@endphp
@break
@endswitch
@endif
@endif
@if (textLocale('status', $item, $lang) &&
fieldPropertyValue('custom_element_type', $item) >= CustomElementType::ONE_COLUMN &&
fieldPropertyValue('custom_element_type', $item) <= CustomElementType::SIDE_CONTENT_V2)
@include('preview.customs.customContent')
@endif
@endforeach
@include('preview.ibisStyles.commons.allContaintSP')
@include('preview.ibisStyles.commons.allContaintPC')
@if (!empty($reserve))
@include('preview.ibisStyles.commons.reserve')
@endif
@endsection
@push('styles')