@using Moonlight.Shared.Components.FileManagerPartials
@using Moonlight.App.Database.Entities
@using Moonlight.App.Helpers
@using Moonlight.App.Helpers.Files
@using Moonlight.App.Services

@inject WingsApiHelper WingsApiHelper
@inject WingsJwtHelper WingsJwtHelper
@inject ConfigService ConfigService

<FileManager Access="FileAccess"></FileManager>

@code
{
    [CascadingParameter]
    public Server CurrentServer { get; set; }
    
    [CascadingParameter]
    public User User { get; set; }

    private FileAccess FileAccess;

    protected override void OnInitialized()
    {
        FileAccess = new WingsFileAccess(WingsApiHelper, WingsJwtHelper, CurrentServer, ConfigService, User);
    }
}
