@php $routeMiddleware = collect(request()->route()?->gatherMiddleware() ?? []); $isAuthRoute = $routeMiddleware->contains(fn($m) => str_starts_with($m, 'auth')); @endphp @if($isAuthRoute) @endif @stack('seo') @vite(['resources/css/app.css', 'resources/js/app.js']) @stack('head') @include('layouts.navigation') @guest @php session()->forget('tour_guest_autoplay'); @endphp @unless(session('tour_guest_completed')) @php // Don't autoplay on public content pages that can be opened directly via a shared link $guestAutoplay = ! request()->routeIs('events.*') && ! request()->routeIs('pro.*'); $guestSteps = [ ['target' => null, 'title' => __('tour.guest_welcome_title'), 'body' => __('tour.guest_welcome_body')], ['target' => '#nd-nav-ik', 'title' => __('tour.guest_ik_title'), 'body' => __('tour.guest_ik_body')], ['target' => '#nd-nav-profiles','title' => __('tour.guest_profiles_title'), 'body' => __('tour.guest_profiles_body')], ['target' => '#nd-nav-community', 'title' => __('tour.guest_community_title'), 'body' => __('tour.guest_community_body')], [ 'target' => '#nd-guest-menu-btn', 'mobileTarget' => '#nd-hamburger-btn', 'title' => __('tour.guest_menu_title'), 'body' => __('tour.guest_menu_body'), ], ['target' => null, 'title' => __('tour.guest_register_title'), 'body' => __('tour.guest_register_body'), 'cta' => ['label' => __('Register'), 'url' => route('register')]], ]; @endphp @endunless @endguest @auth @unless (auth()->user()->tour_completed) @php $tourAutoplay = session()->pull('tour_autoplay', false); $hasProfile = auth()->user()->profile !== null || auth()->user()->proProfile !== null; $profileStep = [ 'target' => '#nd-user-menu-btn', 'mobileTarget' => '#nd-hamburger-btn', 'menuItem' => '#nd-menu-profile', 'mobileMenuItem' => '#nd-mobile-menu-profile', 'title' => __('tour.profile_title'), 'body' => __('tour.profile_body'), ]; if (! $hasProfile) { $profileStep['cta'] = ['label' => __('tour.cta_create_profile'), 'url' => route('profile.edit')]; } $tourSteps = [ ['target' => null, 'title' => __('tour.welcome_title'), 'body' => __('tour.welcome_body')], ['target' => '#nd-nav-dashboard', 'title' => __('tour.dashboard_title'), 'body' => __('tour.dashboard_body')], ['target' => '#nd-nav-ik', 'title' => __('tour.guest_ik_title'), 'body' => __('tour.guest_ik_body')], ['target' => '#nd-nav-profiles', 'title' => __('tour.profiles_title'), 'body' => __('tour.profiles_body')], ['target' => '#nd-nav-community', 'title' => __('tour.guest_community_title'), 'body' => __('tour.guest_community_body')], ['target' => '#nd-nav-chat', 'title' => __('tour.chat_title'), 'body' => __('tour.chat_body')], [ 'target' => '#nd-user-menu-btn', 'mobileTarget' => '#nd-hamburger-btn', 'menuItem' => '#nd-menu-appearance', 'mobileMenuItem' => '#nd-mobile-menu-appearance', 'title' => __('tour.display_title'), 'body' => __('tour.display_body'), ], $profileStep, ]; @endphp @endunless @endauth
@if (session('impersonator_id'))
👤 Je bekijkt de app als {{ auth()->user()->name }}.
@csrf
@endif @auth @if (auth()->user()->is_demo)
🎭 {{ __('This is a demo account.') }} @if (auth()->user()->subscription_ends_at) {{ __('Access expires on :date.', ['date' => auth()->user()->subscription_ends_at->format('d/m/Y')]) }} @endif {{ __('Subscribe to keep access →') }}
@endif @endauth @isset($header)
{{ $header }}
@endisset
{{ $slot }}
{{-- Global toast voor opgeslagen formulieren --}} @php $toastMap = [ 'profile-updated' => __('Saved.'), 'profile-optional-updated' => __('Saved.'), 'preferences-updated' => __('Saved.'), 'password-updated' => __('Saved.'), 'account-updated' => __('Account settings saved.'), ]; $toastMsg = null; foreach ($toastMap as $key => $msg) { if (session('status') === $key) { $toastMsg = $msg; break; } } @endphp @if ($toastMsg) @endif {{-- Dynamic toast — triggered by: window.dispatchEvent(new CustomEvent('nd:flash', { detail: { message: '...', type: 'error'|'success' } })) --}} {{-- Global upgrade modal — triggered by: window.dispatchEvent(new CustomEvent('nd:upgrade')) --}} @auth @if (!auth()->user()->is_premium)
{{-- Backdrop --}}
{{-- Panel --}}

💎

{{ __('Upgrade to Premium') }}

{{ __('You have reached the free plan limit. Upgrade to Premium for unlimited likes, messages, and more.') }}

{{ __('See Premium plans') }} →
@endif @endauth @stack('above-bottom-bar') {{-- Vaste bottom bar — alleen tonen als er knoppen zijn --}} @php $bottomBarButtons = $__env->yieldPushContent('bottom-bar-buttons'); @endphp @if(trim($bottomBarButtons))
{!! $bottomBarButtons !!}
@endif {{-- PWA install banner. Android: intercepts beforeinstallprompt and shows a native-style install button. iOS Safari: detects non-standalone mode and shows "Add to Home Screen" instructions. Dismissed state is persisted in localStorage (ndInstallDismissed). --}} {{-- Cookie notice (ePrivacy Directive) --}} @stack('scripts') {{-- ndPushToggle() — shared Alpine component factory for bell/notification toggles. Handles the full Web Push subscription lifecycle: - iOS non-standalone: locked (instructions shown separately) - permission default: requestPermission() + pushManager.subscribe() - permission granted: subscribe if not yet subscribed - toggle off: pushManager.unsubscribe() + backend DELETE --}} @auth {{-- Global chat notification poller. Runs on all non-chat-show pages every 20s. Uses whereNull(read_at) endpoint so read messages are never re-notified. notifiedConvIds prevents duplicate notifications per session. visibilitychange fires an immediate catch-up when the tab regains focus. --}} @endauth