<?php

namespace App\Http\Livewire;

use Livewire\Component;

class Navbar extends Component
{
    public $currentMenu = 'DeleteMultiPatch';
    public $navLoaded = false;
    public $userName ;

    public function mount() {
        $this->userName = auth()->user()->username;
    }
    public function loadNav()
    {
        $this->navLoaded = true;
    }
    public function loadContent($menu)
    {
        $this->currentMenu = $menu;
        $this->emit('menuChanged', $menu);
    }

    public function render()
    {
        return view('livewire.navbar');
    }
}

