using Microsoft.AspNetCore.Components;
using Microsoft.JSInterop;

namespace Front.Program.Views.Project;

public partial class TopNav : ComponentBase
{
 //로그인버튼을 누르면 페이지를 이동할거야
    [Inject]
    NavigationManager NavigationManager { get; set; } = default!;
    IJSRuntime JS { get; set; } = default!;

    protected bool isOpen = false;

    public void OnClickMenuDown()
    {
        isOpen = !isOpen;
    }

    public void OnClickRedirect()
    {
        if (isOpen) isOpen = !isOpen;
        NavigationManager.NavigateTo("/about");
    }
    
    public void OnClickLogin()
    {
        if (isOpen) isOpen = !isOpen;
        NavigationManager.NavigateTo("/auth");
    }
    
        
 
}