Implemented roles and action timestamps. Added oermissions selector and interfaces

This commit was merged in pull request #3.
This commit is contained in:
2026-01-14 19:03:17 +01:00
parent 43d43a6d7d
commit 06063b94b3
33 changed files with 1192 additions and 5 deletions

View File

@@ -1,16 +1,20 @@
using Microsoft.AspNetCore.Components.Authorization;
using Microsoft.AspNetCore.Components.WebAssembly.Hosting;
using Microsoft.Extensions.DependencyInjection;
using Moonlight.Frontend.Implementations;
using Moonlight.Frontend.Interfaces;
using Moonlight.Frontend.Services;
namespace Moonlight.Frontend.Startup;
public partial class Startup
{
public void AddAuth(WebAssemblyHostBuilder builder)
private void AddAuth(WebAssemblyHostBuilder builder)
{
builder.Services.AddScoped<AuthenticationStateProvider, RemoteAuthProvider>();
builder.Services.AddAuthorizationCore();
builder.Services.AddCascadingAuthenticationState();
builder.Services.AddSingleton<IPermissionProvider, PermissionProvider>();
}
}