SharpRSS/SharpRSS.Blazor/Components/Routes.razor
2024-10-14 15:31:04 +02:00

23 lines
974 B
Plaintext

<CascadingAuthenticationState>
<Router AppAssembly="typeof(Program).Assembly">
<Found Context="routeData">
@*<RouteView RouteData="routeData" DefaultLayout="typeof(Layout.MainLayout)"/>
<FocusOnNavigate RouteData="routeData" Selector="h1"/>*@
<AuthorizeRouteView RouteData="@routeData" DefaultLayout="@typeof(EmptyLayout)">
<Authorizing>
<p>Determining session state, please wait...</p>
</Authorizing>
<NotAuthorized>
<Redirector RedirectUri="/auth/login"/>
</NotAuthorized>
</AuthorizeRouteView>
</Found>
<NotFound>
<PageTitle>Not found!</PageTitle>
<LayoutView Layout="@typeof(EmptyLayout)">
@*TODO: Manage not found*@
<p>Page not found!</p>
</LayoutView>
</NotFound>
</Router>
</CascadingAuthenticationState>