@extends('frontendLayout') @section('frontend_layout') @push('frontend_css') {{ $shop->name }} @endpush {{-- ── FLASH MESSAGES ── --}}
@if (session('success'))
{{ session('success') }}
@endif @if (session('error'))
{{ session('error') }}
@endif
{{-- ── SHOP HERO ── --}} @php $logo = $shop->logo ? (\Illuminate\Support\Str::startsWith($shop->logo, ['http://', 'https://']) ? $shop->logo : asset('storage/' . $shop->logo)) : 'https://images.unsplash.com/photo-1472851294608-062f824d29cc?w=200&q=80'; @endphp
{{-- Left: Shop Info --}}

{{ $shop->name }}

{{ data_get($shop->contact, 'address', 'Quality products · Fast delivery · Trusted seller') }}

{{ $products->count() }} products Fast Delivery Trusted Seller
{{-- ── MAIN CONTENT ── --}}
{{-- PRODUCTS --}}

Products

@forelse ($products as $product) @php $hasOffer = !is_null($product->offer_price) && $product->offer_price < $product->price && (is_null($product->offer_expiry_date) || $product->offer_expiry_date->isFuture()); $displayPrice = $hasOffer ? (float) $product->offer_price : (float) $product->price; $featureImage = $product->feature_image ? (\Illuminate\Support\Str::startsWith($product->feature_image, ['http://', 'https://']) ? $product->feature_image : asset('storage/' . $product->feature_image)) : null; $gallery = optional($product->images->first())->image_path; $galleryUrl = $gallery ? (\Illuminate\Support\Str::startsWith($gallery, ['http://', 'https://']) ? $gallery : asset('storage/' . $gallery)) : null; $image = $featureImage ?: ($galleryUrl ?: 'https://images.unsplash.com/photo-1523275335684-37898b6baf30?w=600&q=80'); @endphp
{{ $product->product_title }}
{{ $product->product_title }}
{{ number_format($displayPrice, 0) }}৳ @if ($hasOffer) {{ number_format((float) $product->price, 0) }}৳ OFFER @endif
{{-- Qty stepper (hidden until item added) --}}
1
@if ($product->hasVariantInventory()) Variants @else @endif
@empty

No products available yet.

@endforelse
{{-- TOAST CONTAINER --}}
@push('frontend_js') @endpush @endsection