@stack('styles')
@include('layouts.partials.header')
@yield('content')
@include('layouts.partials.footer')
@include('layouts.partials.cart-drawer')
@include('layouts.partials.lightbox')
@include('layouts.partials.floating-bar')
@php
$wokupBranches = [];
if (isset($branches) && count($branches) > 0) {
foreach ($branches as $b) {
$wokupBranches[] = [
'id' => $b->id,
'n' => $b->name,
'a' => $b->address,
'o' => substr($b->opening_time, 0, 5),
'c' => substr($b->closing_time, 0, 5),
'lat' => (float)$b->latitude,
'lng' => (float)$b->longitude,
'x' => (int)$b->map_x,
'y' => (int)$b->map_y,
'ph' => $b->phone,
];
}
}
$wokupCategories = [];
if (isset($categories) && count($categories) > 0) {
foreach ($categories as $idx => $c) {
$wokupCategories[] = [
'i' => $idx + 1,
'id' => $c->id,
'n' => $c->name,
's' => $c->native_name ?? '',
't' => $c->description ?? '',
];
}
}
$wokupDishes = [];
if (isset($menuItems) && count($menuItems) > 0) {
foreach ($menuItems as $idx => $d) {
$wokupDishes[] = [
'id' => $idx,
'item_id' => $d->id,
'n' => $d->name,
'd' => $d->description ?? '',
'p' => (float)$d->price,
'c' => $d->category ? $d->category->name : 'Other',
'img' => $d->image_url,
'k' => $d->image_key ?? 'ramen',
'x' => (int)($d->focus_x ?? 50),
'y' => (int)($d->focus_y ?? 50),
'z' => (float)($d->zoom ?? 1.0),
'b' => $d->badge ?? '',
'f' => (bool)$d->is_featured,
];
}
}
@endphp
@stack('scripts')