feat(cms): add public landing splash at /, move catalogue to /catalogue
This commit is contained in:
@@ -0,0 +1,26 @@
|
|||||||
|
@inherits LayoutComponentBase
|
||||||
|
@using DeepDrftShared.Client.Common
|
||||||
|
|
||||||
|
<MudThemeProvider IsDarkMode="false" Theme="@DeepDrftPalettes.Cms" />
|
||||||
|
<MudPopoverProvider />
|
||||||
|
|
||||||
|
<MudLayout>
|
||||||
|
<MudAppBar Dense="true" Elevation="1" Color="Color.Primary">
|
||||||
|
<MudText Typo="Typo.h6" Class="ml-3" Style="font-family: 'DM Sans', sans-serif; letter-spacing: 0.05em;">
|
||||||
|
Deep Drft — Admin
|
||||||
|
</MudText>
|
||||||
|
</MudAppBar>
|
||||||
|
<MudMainContent>
|
||||||
|
<MudContainer MaxWidth="MaxWidth.Small"
|
||||||
|
Class="d-flex flex-column justify-center align-center"
|
||||||
|
Style="min-height: calc(100vh - 48px);">
|
||||||
|
@Body
|
||||||
|
</MudContainer>
|
||||||
|
</MudMainContent>
|
||||||
|
</MudLayout>
|
||||||
|
|
||||||
|
<div id="blazor-error-ui" data-nosnippet>
|
||||||
|
An unhandled error has occurred.
|
||||||
|
<a href="." class="reload">Reload</a>
|
||||||
|
<span class="dismiss">🗙</span>
|
||||||
|
</div>
|
||||||
@@ -12,9 +12,9 @@
|
|||||||
Deep Drft — Admin
|
Deep Drft — Admin
|
||||||
</MudText>
|
</MudText>
|
||||||
<MudSpacer />
|
<MudSpacer />
|
||||||
<MudTooltip Text="Back to site">
|
<MudTooltip Text="Catalogue">
|
||||||
<MudIconButton Icon="@Icons.Material.Filled.Home"
|
<MudIconButton Icon="@Icons.Material.Filled.Home"
|
||||||
Href="/"
|
Href="/catalogue"
|
||||||
Color="Color.Inherit" />
|
Color="Color.Inherit" />
|
||||||
</MudTooltip>
|
</MudTooltip>
|
||||||
</MudAppBar>
|
</MudAppBar>
|
||||||
|
|||||||
@@ -0,0 +1,31 @@
|
|||||||
|
@page "/"
|
||||||
|
@layout Layout.CmsHomeLayout
|
||||||
|
|
||||||
|
<PageTitle>Deep Drft — Admin</PageTitle>
|
||||||
|
|
||||||
|
<HierarchicalRoleAuthorizeView>
|
||||||
|
<Authorized>
|
||||||
|
<RedirectToCatalogue />
|
||||||
|
</Authorized>
|
||||||
|
<NotAuthorized>
|
||||||
|
<MudStack AlignItems="AlignItems.Center" Spacing="4" Class="my-8">
|
||||||
|
<MudImage Fluid="true" Src="img/cms-hero.png" Alt="Deep Drft" />
|
||||||
|
<MudText Typo="Typo.h2" Align="Align.Center">Deep Drft</MudText>
|
||||||
|
<MudText Typo="Typo.subtitle1" Align="Align.Center" Class="text-uppercase mud-text-secondary">
|
||||||
|
Catalogue Management
|
||||||
|
</MudText>
|
||||||
|
<MudButton Variant="Variant.Filled"
|
||||||
|
Color="Color.Primary"
|
||||||
|
Href="@LoginHref"
|
||||||
|
Class="mt-4"
|
||||||
|
Style="min-width: 200px;">
|
||||||
|
Login
|
||||||
|
</MudButton>
|
||||||
|
</MudStack>
|
||||||
|
</NotAuthorized>
|
||||||
|
</HierarchicalRoleAuthorizeView>
|
||||||
|
|
||||||
|
@code {
|
||||||
|
private static readonly string LoginHref =
|
||||||
|
$"/account/login?returnUrl={Uri.EscapeDataString("catalogue")}";
|
||||||
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
@page "/"
|
@page "/catalogue"
|
||||||
@using DeepDrftManager.Services
|
@using DeepDrftManager.Services
|
||||||
@attribute [Authorize]
|
@attribute [Authorize]
|
||||||
@layout Layout.CmsLayout
|
@layout Layout.CmsLayout
|
||||||
|
|||||||
@@ -0,0 +1,10 @@
|
|||||||
|
@inject NavigationManager NavigationManager
|
||||||
|
|
||||||
|
@code {
|
||||||
|
|
||||||
|
protected override void OnInitialized()
|
||||||
|
{
|
||||||
|
NavigationManager.NavigateTo("/catalogue", forceLoad: false, replace: true);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user