{{-- resources/views/frontend/products/index.blade.php --}} @extends('frontend.app') @section('content') @php use App\Models\Information; $info = Information::first(); $minDb = (float)($minDb ?? 0); $maxDb = (float)($maxDb ?? 0); if($maxDb <= $minDb){ $minDb = 0; $maxDb = 5000; } // ✅ keep selected sort from query (ajax + normal) $sort = $sort ?? request('sort', request('shorting', 'latest')); $brandGradient = $info->gradient_code ?? 'linear-gradient(90deg,#0d6efd,#00276C)'; $brandText = $info->primary_color ?? '#ffffff'; $hasSizes = isset($sizes) && $sizes->count() > 0; @endphp
{{-- ✅ Desktop breadcrumb --}}
  • Shop
{{-- ✅ Mobile top --}}
Shop
{{-- ✅ Desktop Filters --}}
Filters
Set options then Apply
{{-- ✅ Categories --}}
@foreach($cats as $c) {{ $c->name }} @endforeach
{{-- ✅ Price --}}
MIN ৳ {{ (int)$minDb }}
MAX ৳ {{ (int)$maxDb }}
{{-- shared hidden --}}
{{-- ✅ Brand --}}
@foreach($types as $t) {{ $t->name }} @endforeach
{{-- ✅ Size --}} @if($hasSizes)
@foreach($sizes as $s) @php $label = $s->name ?? $s->title ?? $s->size ?? $s->value ?? ''; @endphp @if(trim((string)$label) !== '') {{ $label }} @endif @endforeach
@endif
{{-- ✅ Products --}}
Showing {{ $items->firstItem() ?? 0 }} – {{ $items->lastItem() ?? 0 }} of {{ $items->total() ?? 0 }} results
@include('frontend.products.partials.category_products', ['items'=>$items])
{{-- ✅ Mobile Offcanvas Filters --}}
Filters
Filters
Set options then Apply
{{-- ✅ Categories --}}
@foreach($cats as $c) {{ $c->name }} @endforeach
{{-- ✅ Price --}}
MIN ৳ {{ (int)$minDb }}
MAX ৳ {{ (int)$maxDb }}
{{-- ✅ Brand --}}
@foreach($types as $t) {{ $t->name }} @endforeach
{{-- ✅ Size --}} @if($hasSizes)
@foreach($sizes as $s) @php $label = $s->name ?? $s->title ?? $s->size ?? $s->value ?? ''; @endphp @if(trim((string)$label) !== '') {{ $label }} @endif @endforeach
@endif
{{-- ✅ The duplicate mobile-bottom-nav DIV has been REMOVED from here --}} @endsection @push('js') @endpush