@php $channel = core()->getCurrentChannel(); $locale = core()->getRequestedLocaleCode(); @endphp @push ('meta') @endPush {{ $channel->home_seo['meta_title'] ?? '' }} {{-- @php $slider_images = $customizations->where('type', 'image_carousel')->first()->options['images']; @endphp --}} @foreach ($customizations as $customization) @php ($data = $customization->options) @endphp @switch ($customization->type) @case ($customization::IMAGE_CAROUSEL) @php // Sorting usort($data['images'], fn($a, $b) => (int)$a['sort_order'] <=> (int)$b['sort_order']); @endphp @break @case ($customization::STATIC_CONTENT) @if (! empty($data['css'])) @push ('styles') @endpush @endif @if (! empty($data['html'])) {!! $data['html'] !!} @endif @break @case ($customization::CATEGORY_CAROUSEL) @break @case ($customization::PRODUCT_CAROUSEL) @break @case ($customization::HERO_SECTION) {{-- @php $herosection = app('Webkul\Theme\Models\HeroSection')->where('locale', $locale)->first(); // Sorting usort($slider_images, fn($a, $b) => (int)$a['sort_order'] <=> (int)$b['sort_order']); $data['images'] = $slider_images; $data['herosection'] = $herosection; @endphp --}} {{-- --}} @break @case ($customization::IMAGE_TEXT_SECTION) @php $data = $customization->imageTextSections()->where('locale', $locale)->first(); @endphp @break @endswitch @endforeach