@php /* |-------------------------------------------------------------------------- | Global Shop Settings |-------------------------------------------------------------------------- */ $shopSettings = \App\Models\ShopSetting::first(); $shopName = $shopSettings?->shop_name ?: 'BDCodeShop'; $shopLogo = $shopSettings?->logo; if ($shopLogo) { if ( str_starts_with($shopLogo, 'http://') || str_starts_with($shopLogo, 'https://') ) { $shopLogoUrl = $shopLogo; } else { $shopLogoUrl = asset($shopLogo); } } else { $shopLogoUrl = null; } /* |-------------------------------------------------------------------------- | Current Page |-------------------------------------------------------------------------- */ $path = request()->path(); $homeActive = $path === 'dashboard' || $path === 'miniapp'; $shopActive = $path === 'shop' || str_starts_with($path, 'shop/'); $ordersActive = $path === 'orders' || str_starts_with($path, 'orders/'); $downloadsActive = $path === 'downloads' || str_starts_with($path, 'downloads/'); $walletActive = $path === 'add-money' || str_starts_with($path, 'wallet/'); $profileActive = $path === 'profile' || str_starts_with($path, 'profile/'); @endphp