@php $endDate = optional($flashSale->end_date)->endOfDay(); $endIso = $endDate ? $endDate->toIso8601String() : null; $bgImage = $shortcode->background_image ? \Botble\Media\Facades\RvMedia::getImageUrl($shortcode->background_image) : null; $bgStyle = $bgImage ? 'background-image: url(' . e($bgImage) . ');' : ''; $products = $flashSale->products ?? collect(); @endphp
@if ($shortcode->title)

{{ $shortcode->title }}

@endif @if ($shortcode->subtitle)

{{ $shortcode->subtitle }}

@endif @if ($shortcode->show_countdown && $endIso)
00 {{ __('Days') }}
00 {{ __('Hours') }}
00 {{ __('Minutes') }}
00 {{ __('Seconds') }}
@endif
@foreach ($products->take(4) as $product)
@includeIf(Theme::getThemeNamespace('views.ecommerce.includes.product-item'), ['product' => $product])
@endforeach