feat(ui): migrate web shell to mudblazor
WBS-9.3 - NULL Policy CI Gate / NULL Policy Validation (push) Failing after 6s
Quant Engine CI/CD Pipeline / validate-core (push) Failing after 11s
Deploy to Production / Build & Deploy to Production (push) Failing after 1m55s
Quant Engine CI/CD Pipeline / validate-ui-and-storage (push) Has been skipped
WBS-9.3 - NULL Policy CI Gate / NULL Policy Validation (push) Failing after 6s
Quant Engine CI/CD Pipeline / validate-core (push) Failing after 11s
Deploy to Production / Build & Deploy to Production (push) Failing after 1m55s
Quant Engine CI/CD Pipeline / validate-ui-and-storage (push) Has been skipped
This commit is contained in:
@@ -2,74 +2,36 @@
|
||||
@inject HttpClient Http
|
||||
@inject AuthenticationStateProvider AuthStateProvider
|
||||
@inject NavigationManager NavigationManager
|
||||
@using System.Net.Http.Json
|
||||
@using Microsoft.FluentUI.AspNetCore.Components
|
||||
@using QuantEngine.Web.Client.Infrastructure
|
||||
|
||||
<FluentStack Orientation="Orientation.Vertical" Class="h-100 w-100">
|
||||
<!-- Header -->
|
||||
<FluentHeader>
|
||||
<FluentStack Orientation="Orientation.Horizontal" VerticalAlignment="VerticalAlignment.Center"
|
||||
Style="width: 100%; padding: 8px 16px; gap: 16px;">
|
||||
<FluentButton OnClick="@(() => navOpen = !navOpen)"
|
||||
Title="Toggle Navigation"
|
||||
Style="background: transparent; border: none; cursor: pointer;">
|
||||
☰
|
||||
</FluentButton>
|
||||
<h1 style="margin: 0; font-size: 20px; font-weight: 600;">QuantEngine v@appVersion</h1>
|
||||
<AuthorizeView>
|
||||
<Authorized>
|
||||
<div style="margin-left: auto; display: flex; align-items: center; gap: 12px;">
|
||||
<span style="font-size: 13px; color: var(--neutral-foreground-hint);">관리자 (@context.User.Identity?.Name)</span>
|
||||
<FluentButton OnClick="HandleLogoutAsync" Style="color: #ff5252; background: transparent; border: 1px solid rgba(255, 82, 82, 0.2); cursor: pointer; padding: 4px 12px; border-radius: 4px;">
|
||||
로그아웃
|
||||
</FluentButton>
|
||||
</div>
|
||||
</Authorized>
|
||||
</AuthorizeView>
|
||||
</FluentStack>
|
||||
</FluentHeader>
|
||||
<MudLayout>
|
||||
<MudAppBar Elevation="1" Dense="true">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Menu" Color="Color.Inherit" Edge="Edge.Start" OnClick="@(() => navOpen = !navOpen)" />
|
||||
<MudText Typo="Typo.h6">QuantEngine v@appVersion</MudText>
|
||||
<MudSpacer />
|
||||
<AuthorizeView>
|
||||
<Authorized>
|
||||
<MudText Typo="Typo.body2">관리자 (@context.User.Identity?.Name)</MudText>
|
||||
<MudButton Variant="Variant.Outlined" Color="Color.Error" OnClick="HandleLogoutAsync">로그아웃</MudButton>
|
||||
</Authorized>
|
||||
</AuthorizeView>
|
||||
</MudAppBar>
|
||||
|
||||
<!-- Main Content Area -->
|
||||
<FluentStack Orientation="Orientation.Horizontal" Class="flex-1" Style="overflow: hidden;">
|
||||
<!-- Navigation Sidebar -->
|
||||
@if (navOpen)
|
||||
{
|
||||
<nav style="width: 240px; background: var(--neutral-layer-1); border-right: 1px solid var(--neutral-stroke-1); padding: 12px; overflow-y: auto;">
|
||||
<NavMenu />
|
||||
<div style="margin-top: auto; padding-top: 12px; border-top: 1px solid var(--neutral-stroke-1); margin-top: 12px; font-size: 11px; color: var(--neutral-foreground-3); line-height: 1.5;">
|
||||
<div style="font-weight: 500; margin-bottom: 2px;">QuantEngine v@appVersion</div>
|
||||
<div style="font-size: 10px; opacity: 0.85;">배포: @buildTime</div>
|
||||
</div>
|
||||
</nav>
|
||||
}
|
||||
<MudDrawer Open="@navOpen" Variant="DrawerVariant.Responsive" Elevation="1">
|
||||
<MudNavMenu>
|
||||
<NavMenu />
|
||||
</MudNavMenu>
|
||||
<div style="padding: 16px; border-top: 1px solid var(--mud-palette-lines-default);">
|
||||
<MudText Typo="Typo.caption">QuantEngine v@appVersion</MudText>
|
||||
<MudText Typo="Typo.caption">배포: @buildTime</MudText>
|
||||
</div>
|
||||
</MudDrawer>
|
||||
|
||||
<!-- Page Content -->
|
||||
<FluentStack Orientation="Orientation.Vertical" Class="flex-1" Style="overflow-y: auto; padding: 24px;">
|
||||
<MudMainContent>
|
||||
<MudContainer MaxWidth="MaxWidth.False" Class="pa-4">
|
||||
@Body
|
||||
</FluentStack>
|
||||
</FluentStack>
|
||||
</FluentStack>
|
||||
|
||||
<div id="blazor-error-ui" data-nosnippet>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<p>An unhandled error has occurred.</p>
|
||||
<a href="." class="btn btn-primary">Reload</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.h-100 {
|
||||
height: 100%;
|
||||
}
|
||||
.w-100 {
|
||||
width: 100%;
|
||||
}
|
||||
.flex-1 {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
}
|
||||
</style>
|
||||
</MudContainer>
|
||||
</MudMainContent>
|
||||
</MudLayout>
|
||||
|
||||
@code {
|
||||
private bool navOpen = true;
|
||||
@@ -89,7 +51,6 @@
|
||||
}
|
||||
catch
|
||||
{
|
||||
// Fail-safe default fallback values
|
||||
}
|
||||
}
|
||||
|
||||
@@ -97,7 +58,7 @@
|
||||
{
|
||||
var customProvider = (CustomAuthenticationStateProvider)AuthStateProvider;
|
||||
await customProvider.LogoutFromServerAsync();
|
||||
NavigationManager.NavigateTo("login");
|
||||
NavigationManager.NavigateTo("/login");
|
||||
}
|
||||
|
||||
private class VersionInfo
|
||||
@@ -106,4 +67,3 @@
|
||||
public string? Built { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user