Deleted unused component.
This commit is contained in:
parent
3957d65370
commit
2fdcc486ce
@ -1,29 +0,0 @@
|
||||
@using Microsoft.AspNetCore.Components.Authorization
|
||||
@using Microsoft.AspNetCore.Components.WebAssembly.Authentication
|
||||
@using Microsoft.Extensions.Configuration
|
||||
|
||||
@inject NavigationManager Navigation
|
||||
@inject SignOutSessionStateManager SignOutManager
|
||||
@inject IConfiguration Configuration
|
||||
|
||||
<AuthorizeView Context="auth">
|
||||
<Authorized>
|
||||
<a href="authentication/profile">Hello, @auth.User.Identity.Name!</a>
|
||||
<button class="nav-link btn btn-link" @onclick="BeginSignOut">Log out</button>
|
||||
</Authorized>
|
||||
<NotAuthorized>
|
||||
@if (Configuration["IdentityServer:Registration"].Equals("enabled"))
|
||||
{
|
||||
<a href="authentication/register">Register</a>
|
||||
}
|
||||
<a href="authentication/login">Log in</a>
|
||||
</NotAuthorized>
|
||||
</AuthorizeView>
|
||||
|
||||
@code{
|
||||
private async Task BeginSignOut(MouseEventArgs args)
|
||||
{
|
||||
await SignOutManager.SetSignOutState();
|
||||
Navigation.NavigateTo("authentication/logout");
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user