Clean up layout on dani dojo page
This commit is contained in:
parent
a6df13a498
commit
a52f7f5883
@ -7,13 +7,23 @@
|
||||
|
||||
<h1>Dani Dojo</h1>
|
||||
<MudText Typo="Typo.caption">Card: @Baid</MudText>
|
||||
<MudContainer>
|
||||
|
||||
<MudGrid Class="my-4">
|
||||
<MudItem xs="12">
|
||||
<MudPaper Elevation="0" Outlined="true">
|
||||
<MudTabs>
|
||||
@for (uint i = 1; i <= 19; i++)
|
||||
{
|
||||
var danId = i;
|
||||
var danData = GameDataService.GetDanDataById(danId);
|
||||
<MudTabPanel Text="@danData.Title">
|
||||
<MudTabPanel Text="@GetDanTitle(danData.Title)">
|
||||
<MudGrid Class="px-12 py-8">
|
||||
@if (!bestDataMap.ContainsKey(danId)) {
|
||||
<MudItem xs="12">
|
||||
<MudAlert Severity="Severity.Info">This dan course hasn't been played yet.</MudAlert>
|
||||
</MudItem>
|
||||
}
|
||||
<MudItem xs="12">
|
||||
@foreach (var data in danData.OdaiBorderList)
|
||||
{
|
||||
<MudText>@DanRequirementToString(data)</MudText>
|
||||
@ -50,13 +60,11 @@
|
||||
</MudGrid>
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
<MudText>
|
||||
This dan course hasn't been played
|
||||
</MudText>
|
||||
}
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
</MudTabPanel>
|
||||
}
|
||||
</MudTabs>
|
||||
</MudContainer>
|
||||
</MudPaper>
|
||||
</MudItem>
|
||||
</MudGrid>
|
@ -37,4 +37,32 @@ public partial class DaniDojo
|
||||
_ => throw new ArgumentOutOfRangeException()
|
||||
};
|
||||
}
|
||||
|
||||
private static string GetDanTitle(string title)
|
||||
{
|
||||
return title switch
|
||||
{
|
||||
"5kyuu" => "Fifth Kyuu",
|
||||
"4kyuu" => "Fourth Kyuu",
|
||||
"3kyuu" => "Third Kyuu",
|
||||
"2kyuu" => "Second Kyuu",
|
||||
"1kyuu" => "First Kyuu",
|
||||
"1dan" => "First Dan",
|
||||
"2dan" => "Second Dan",
|
||||
"3dan" => "Third Dan",
|
||||
"4dan" => "Fourth Dan",
|
||||
"5dan" => "Fifth Dan",
|
||||
"6dan" => "Sixth Dan",
|
||||
"7dan" => "Seventh Dan",
|
||||
"8dan" => "Eighth Dan",
|
||||
"9dan" => "Ninth Dan",
|
||||
"10dan" => "Tenth Dan",
|
||||
"11dan" => "Kuroto",
|
||||
"12dan" => "Meijin",
|
||||
"13dan" => "Chojin",
|
||||
"14dan" => "Tatsujin",
|
||||
"15dan" => "Gaiden",
|
||||
_ => ""
|
||||
};
|
||||
}
|
||||
}
|
@ -99,7 +99,7 @@
|
||||
{
|
||||
<MudGrid>
|
||||
<MudItem xs="12">
|
||||
<MudText Align="Align.Center" Class="my-8">
|
||||
<MudText Align="Align.Center" Class="my-16">
|
||||
No data for selected difficulty.
|
||||
</MudText>
|
||||
</MudItem>
|
||||
|
@ -8,13 +8,6 @@
|
||||
<base href="/" />
|
||||
<link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap" rel="stylesheet" />
|
||||
<link href="_content/MudBlazor/MudBlazor.min.css" rel="stylesheet" />
|
||||
<style>
|
||||
.difficulty-tab .mud-badge.mud-badge-top.right {
|
||||
inset: auto auto calc(100% - 8px) 100%;
|
||||
font-size: 10px;
|
||||
height: 18px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
Loading…
Reference in New Issue
Block a user