@php $unreadCount = auth()->user()->notifications_custom()->whereNull('read_at')->count(); $links = [ ['route'=>'customer.dashboard', 'label'=>'نظرة عامة', 'icon'=>'home', 'match'=>['customer.dashboard']], ['route'=>'customer.orders.index', 'label'=>'طلباتي', 'icon'=>'cart', 'match'=>['customer.orders.*']], ['route'=>'customer.services.index', 'label'=>'خدماتي', 'icon'=>'server', 'match'=>['customer.services.*']], ['route'=>'customer.invoices.index', 'label'=>'الفواتير', 'icon'=>'document', 'match'=>['customer.invoices.*']], ['route'=>'customer.tickets.index', 'label'=>'التذاكر', 'icon'=>'chat', 'match'=>['customer.tickets.*']], ['route'=>'customer.notifications.index', 'label'=>'الإشعارات', 'icon'=>'bell', 'match'=>['customer.notifications.*'], 'badge' => $unreadCount], ['route'=>'customer.profile', 'label'=>'الملف الشخصي', 'icon'=>'user', 'match'=>['customer.profile*']], ]; $icon = function ($name) { return match ($name) { 'home' => '', 'cart' => '', 'server' => '', 'document' => '', 'chat' => '', 'bell' => '', 'user' => '', default => '', }; }; @endphp