diff --git a/TaikoWebUI/Pages/AccessCode.razor.cs b/TaikoWebUI/Pages/AccessCode.razor.cs index 5ad307f..1002263 100644 --- a/TaikoWebUI/Pages/AccessCode.razor.cs +++ b/TaikoWebUI/Pages/AccessCode.razor.cs @@ -8,14 +8,14 @@ public partial class AccessCode { [Parameter] public int Baid { get; set; } - + private string inputAccessCode = ""; private MudForm bindAccessCodeForm = default!; private User? User { get; set; } = new(); - + private DashboardResponse? response; - + private readonly List breadcrumbs = new() { new BreadcrumbItem("Users", href: "/Users"), @@ -28,7 +28,7 @@ public partial class AccessCode breadcrumbs.Add(new BreadcrumbItem($"User: {Baid}", href: null, disabled: true)); breadcrumbs.Add(new BreadcrumbItem("Access Code Management", href: $"/Users/{Baid}/AccessCode", disabled: false)); } - + private async Task InitializeUser() { response = await Client.GetFromJsonAsync("api/Dashboard"); @@ -45,7 +45,7 @@ public partial class AccessCode User = LoginService.GetLoggedInUser(); } } - + private async Task DeleteAccessCode(string accessCode) { var parameters = new DialogParameters @@ -58,7 +58,7 @@ public partial class AccessCode var result = await dialog.Result; if (result.Canceled) return; - + await InitializeUser(); NavigationManager.NavigateTo(NavigationManager.Uri); } diff --git a/TaikoWebUI/Pages/Dialogs/AccessCodeDeleteConfirmDialog.razor.cs b/TaikoWebUI/Pages/Dialogs/AccessCodeDeleteConfirmDialog.razor.cs index c2a42e2..44f547c 100644 --- a/TaikoWebUI/Pages/Dialogs/AccessCodeDeleteConfirmDialog.razor.cs +++ b/TaikoWebUI/Pages/Dialogs/AccessCodeDeleteConfirmDialog.razor.cs @@ -2,18 +2,18 @@ public partial class AccessCodeDeleteConfirmDialog { - + [CascadingParameter] MudDialogInstance MudDialog { get; set; } = null!; [Parameter] public User User { get; set; } = new(); - + [Parameter] public string AccessCode { get; set; } = ""; private void Cancel() => MudDialog.Cancel(); - + private async Task DeleteAccessCode() { if (User.AccessCodes.Count == 1) @@ -22,7 +22,7 @@ public partial class AccessCodeDeleteConfirmDialog MudDialog.Close(DialogResult.Ok(false)); return; } - + var cardResponseMessage = await Client.DeleteAsync($"api/Cards/{AccessCode}"); if (!cardResponseMessage.IsSuccessStatusCode) diff --git a/TaikoWebUI/Pages/Dialogs/ChooseTitleDialog.razor b/TaikoWebUI/Pages/Dialogs/ChooseTitleDialog.razor index 26490f2..848da04 100644 --- a/TaikoWebUI/Pages/Dialogs/ChooseTitleDialog.razor +++ b/TaikoWebUI/Pages/Dialogs/ChooseTitleDialog.razor @@ -11,14 +11,14 @@ + AdornmentIcon="@Icons.Material.Filled.Search" IconSize="Size.Medium" Class="mt-0"> @Localizer["ID"] - + @@ -29,24 +29,24 @@ @{ // Disable nullable warnings, which seems to be a false positive - # pragma warning disable CS8602 +#pragma warning disable CS8602 } @context.TitleId @context.TitleName @{ - #pragma warning restore CS8602 +#pragma warning restore CS8602 } - + @Localizer["Selected Title:"] @selectedTitle?.TitleName - - @Localizer["Cancel"] - + + @Localizer["Cancel"] + @Localizer["Okay"] @@ -81,15 +81,15 @@ } titles = titleSet.ToImmutableList().Sort((title, title1) => title.TitleId.CompareTo(title1.TitleId)); var currentTitle = new Title - { - TitleName = UserSetting.Title - }; - if (titleSet.Contains(currentTitle)) - { - titleSet.TryGetValue(new Title { TitleName = UserSetting.Title - }, out selectedTitle); + }; + if (titleSet.Contains(currentTitle)) + { + titleSet.TryGetValue(new Title + { + TitleName = UserSetting.Title + }, out selectedTitle); } } @@ -100,7 +100,7 @@ return false; } return string.IsNullOrEmpty(searchString) || - title.TitleName.Contains(searchString, StringComparison.InvariantCultureIgnoreCase); + title.TitleName.Contains(searchString, StringComparison.InvariantCultureIgnoreCase); } private void Submit() diff --git a/TaikoWebUI/Pages/Dialogs/ResetPasswordConfirmDialog.razor.cs b/TaikoWebUI/Pages/Dialogs/ResetPasswordConfirmDialog.razor.cs index 2e7829d..3fa5522 100644 --- a/TaikoWebUI/Pages/Dialogs/ResetPasswordConfirmDialog.razor.cs +++ b/TaikoWebUI/Pages/Dialogs/ResetPasswordConfirmDialog.razor.cs @@ -2,7 +2,7 @@ public partial class ResetPasswordConfirmDialog { - + [CascadingParameter] MudDialogInstance MudDialog { get; set; } = null!; @@ -10,7 +10,7 @@ public partial class ResetPasswordConfirmDialog public User User { get; set; } = new(); private void Cancel() => MudDialog.Cancel(); - + private async Task ResetPassword() { var request = new SetPasswordRequest @@ -27,7 +27,7 @@ public partial class ResetPasswordConfirmDialog MudDialog.Close(DialogResult.Ok(false)); return; } - + Snackbar.Add("Reset password success!", Severity.Success); MudDialog.Close(DialogResult.Ok(true)); } diff --git a/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor b/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor index c7e9f3d..835b810 100644 --- a/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor +++ b/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor @@ -4,7 +4,7 @@ - + Delete user? diff --git a/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor.cs b/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor.cs index 84e0677..ea31d1c 100644 --- a/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor.cs +++ b/TaikoWebUI/Pages/Dialogs/UserDeleteConfirmDialog.razor.cs @@ -2,7 +2,7 @@ public partial class UserDeleteConfirmDialog { - + [CascadingParameter] MudDialogInstance MudDialog { get; set; } = null!; @@ -10,7 +10,7 @@ public partial class UserDeleteConfirmDialog public User User { get; set; } = new(); private void Cancel() => MudDialog.Cancel(); - + private async Task DeleteUser() { var responseMessage = await Client.DeleteAsync($"api/Users/{User.Baid}"); @@ -21,7 +21,7 @@ public partial class UserDeleteConfirmDialog MudDialog.Close(DialogResult.Ok(false)); return; } - + Snackbar.Add("Delete success!", Severity.Success); MudDialog.Close(DialogResult.Ok(true)); } diff --git a/TaikoWebUI/Pages/Dialogs/UserQrCodeDialog.razor b/TaikoWebUI/Pages/Dialogs/UserQrCodeDialog.razor index 2bc967a..a5b9eaf 100644 --- a/TaikoWebUI/Pages/Dialogs/UserQrCodeDialog.razor +++ b/TaikoWebUI/Pages/Dialogs/UserQrCodeDialog.razor @@ -4,11 +4,7 @@ - + Ok diff --git a/TaikoWebUI/Pages/HighScores.razor.cs b/TaikoWebUI/Pages/HighScores.razor.cs index 0ed586d..0484106 100644 --- a/TaikoWebUI/Pages/HighScores.razor.cs +++ b/TaikoWebUI/Pages/HighScores.razor.cs @@ -2,7 +2,7 @@ using System; using Microsoft.JSInterop; -namespace TaikoWebUI.Pages; +namespace TaikoWebUI.Pages; public partial class HighScores { @@ -10,7 +10,7 @@ public partial class HighScores public int Baid { get; set; } private const string IconStyle = "width:25px; height:25px;"; - + private SongBestResponse? response; private Dictionary> songBestDataMap = new(); @@ -35,16 +35,16 @@ public partial class HighScores data.MusicName = GameDataService.GetMusicNameBySongId(songId, string.IsNullOrEmpty(language) ? "ja" : language); data.MusicArtist = GameDataService.GetMusicArtistBySongId(songId, string.IsNullOrEmpty(language) ? "ja" : language); }); - + songBestDataMap = response.SongBestData.GroupBy(data => data.Difficulty) - .ToDictionary(data => data.Key, + .ToDictionary(data => data.Key, data => data.ToList()); foreach (var songBestDataList in songBestDataMap.Values) { songBestDataList.Sort((data1, data2) => GameDataService.GetMusicIndexBySongId(data1.SongId) .CompareTo(GameDataService.GetMusicIndexBySongId(data2.SongId))); } - + breadcrumbs.Add(new BreadcrumbItem($"User: {Baid}", href: null, disabled: true)); breadcrumbs.Add(new BreadcrumbItem("High Scores", href: $"/Users/{Baid}/HighScores", disabled: false)); @@ -74,7 +74,7 @@ public partial class HighScores CrownType.Gold => "Full Combo", CrownType.Dondaful => "Donderful Combo", _ => "" - }; + }; } private static string GetRankText(ScoreRank rank) @@ -89,7 +89,7 @@ public partial class HighScores ScoreRank.Purple => "Graceful", ScoreRank.Dondaful => "Top Class", _ => "" - }; + }; } private static string GetDifficultyTitle(Difficulty difficulty) @@ -102,7 +102,7 @@ public partial class HighScores Difficulty.Oni => "Oni", Difficulty.UraOni => "Ura Oni", _ => "" - }; + }; } private static string GetDifficultyIcon(Difficulty difficulty) @@ -123,7 +123,7 @@ public partial class HighScores SongGenre.Variety => "Variety", SongGenre.Classical => "Classical", _ => "" - }; + }; } private static string GetGenreStyle(SongGenre genre) @@ -154,4 +154,3 @@ public partial class HighScores return aiData.Count > 0; } } - diff --git a/TaikoWebUI/Pages/Register.razor.cs b/TaikoWebUI/Pages/Register.razor.cs index bbe1550..44ed096 100644 --- a/TaikoWebUI/Pages/Register.razor.cs +++ b/TaikoWebUI/Pages/Register.razor.cs @@ -6,7 +6,7 @@ public partial class Register private string confirmPassword = ""; private string password = ""; private MudForm registerForm = default!; - + private MudDatePicker datePicker = new(); private MudTimePicker timePicker = new(); private DateTime? date = DateTime.Today; diff --git a/TaikoWebUI/Pages/Users.razor.cs b/TaikoWebUI/Pages/Users.razor.cs index 6047b78..b0ea531 100644 --- a/TaikoWebUI/Pages/Users.razor.cs +++ b/TaikoWebUI/Pages/Users.razor.cs @@ -49,7 +49,7 @@ public partial class Users await DialogService.ShowMessageBox( "Error", "Only admin can reset password.", - "Ok", null , null, options); + "Ok", null, null, options); return; } var parameters = new DialogParameters @@ -64,7 +64,7 @@ public partial class Users response = await Client.GetFromJsonAsync("api/Dashboard"); } - + private async Task OnLogin() { if (response != null) @@ -112,7 +112,7 @@ public partial class Users LoginService.Logout(); NavigationManager.NavigateTo("/Users"); } - + private Task ShowQrCode(User user) { var parameters = new DialogParameters diff --git a/TaikoWebUI/Services/GameDataService.cs b/TaikoWebUI/Services/GameDataService.cs index 6b1c6b7..5ef4ce2 100644 --- a/TaikoWebUI/Services/GameDataService.cs +++ b/TaikoWebUI/Services/GameDataService.cs @@ -6,18 +6,18 @@ namespace TaikoWebUI.Services; public class GameDataService : IGameDataService { - private string[] bodyTitles = {}; + private string[] bodyTitles = { }; private readonly HttpClient client; - private string[] faceTitles = {}; + private string[] faceTitles = { }; - private string[] headTitles = {}; - private string[] kigurumiTitles = {}; + private string[] headTitles = { }; + private string[] kigurumiTitles = { }; private readonly Dictionary musicMap = new(); - private string[] puchiTitles = {}; - + private string[] puchiTitles = { }; + private List costumeFlagArraySizes = new(); - + private int titleFlagArraySize; private ImmutableDictionary danMap = ImmutableDictionary.Empty; @@ -46,7 +46,7 @@ public class GameDataService : IGameDataService var dict = wordList.WordListEntries.GroupBy(entry => entry.Key) .ToImmutableDictionary(group => group.Key, group => group.First()); await Task.Run(() => InitializeMusicMap(musicInfo, dict, musicOrder)); - + InitializeCostumeFlagArraySizes(donCosRewardData); InitializeTitleFlagArraySize(shougouData); @@ -64,7 +64,7 @@ public class GameDataService : IGameDataService data.ThrowIfNull(); return data; } - + public string GetMusicNameBySongId(uint songId, string? language = "ja") { return musicMap.TryGetValue(songId, out var musicDetail) ? language switch @@ -150,12 +150,12 @@ public class GameDataService : IGameDataService { return titles; } - + public List GetCostumeFlagArraySizes() { return costumeFlagArraySizes; } - + private void InitializeTitleFlagArraySize(Shougous? shougouData) { shougouData.ThrowIfNull("Shouldn't happen!"); @@ -165,20 +165,21 @@ public class GameDataService : IGameDataService private void InitializeTitles(ImmutableDictionary dict, Shougous? shougouData) { shougouData.ThrowIfNull("Shouldn't happen!"); - + var set = ImmutableHashSet.CreateBuilder(); for (var i = 1; i < titleFlagArraySize; i++) { var key = $"syougou_{i}"; var titleWordlistItem = dict.GetValueOrDefault(key, new WordListEntry()); - + var titleRarity = shougouData.ShougouEntries .Where(entry => entry.UniqueId == i) .Select(entry => entry.Rarity) .FirstOrDefault(); - set.Add(new Title{ + set.Add(new Title + { TitleName = titleWordlistItem.JapaneseText, TitleId = i, TitleRarity = titleRarity @@ -187,7 +188,7 @@ public class GameDataService : IGameDataService titles = set.ToImmutable(); } - + private void InitializeCostumeFlagArraySizes(DonCosRewards? donCosRewardData) { donCosRewardData.ThrowIfNull("Shouldn't happen!"); @@ -206,7 +207,7 @@ public class GameDataService : IGameDataService var puchiUniqueIdList = donCosRewardData.DonCosRewardEntries .Where(entry => entry.CosType == "puchi") .Select(entry => entry.UniqueId); - + costumeFlagArraySizes = new List<int> { (int)kigurumiUniqueIdList.Max() + 1, @@ -216,7 +217,7 @@ public class GameDataService : IGameDataService (int)puchiUniqueIdList.Max() + 1 }; } - + private void InitializeKigurumiTitles(ImmutableDictionary<string, WordListEntry> dict) { var costumeKigurumiMax = costumeFlagArraySizes[0]; @@ -229,7 +230,7 @@ public class GameDataService : IGameDataService kigurumiTitles[i] = costumeWordlistItem.JapaneseText; } } - + private void InitializeHeadTitles(ImmutableDictionary<string, WordListEntry> dict) { var costumeHeadMax = costumeFlagArraySizes[1]; @@ -242,7 +243,7 @@ public class GameDataService : IGameDataService headTitles[i] = costumeWordlistItem.JapaneseText; } } - + private void InitializeBodyTitles(ImmutableDictionary<string, WordListEntry> dict) { var costumeBodyMax = costumeFlagArraySizes[2]; @@ -255,7 +256,7 @@ public class GameDataService : IGameDataService bodyTitles[i] = costumeWordlistItem.JapaneseText; } } - + private void InitializeFaceTitles(ImmutableDictionary<string, WordListEntry> dict) { var costumeFaceMax = costumeFlagArraySizes[3]; diff --git a/TaikoWebUI/Services/IGameDataService.cs b/TaikoWebUI/Services/IGameDataService.cs index 22c4f3e..365afee 100644 --- a/TaikoWebUI/Services/IGameDataService.cs +++ b/TaikoWebUI/Services/IGameDataService.cs @@ -6,7 +6,7 @@ namespace TaikoWebUI.Services; public interface IGameDataService { public Task InitializeAsync(string dataBaseUrl); - + public string GetMusicNameBySongId(uint songId, string? language = null); public string GetMusicArtistBySongId(uint songId, string? language = null); @@ -24,7 +24,7 @@ public interface IGameDataService public string GetBodyTitle(uint index); public string GetFaceTitle(uint index); public string GetPuchiTitle(uint index); - + public List<int> GetCostumeFlagArraySizes(); public ImmutableHashSet<Title> GetTitles(); diff --git a/TaikoWebUI/Services/LoginService.cs b/TaikoWebUI/Services/LoginService.cs index ba81dce..247b9c2 100644 --- a/TaikoWebUI/Services/LoginService.cs +++ b/TaikoWebUI/Services/LoginService.cs @@ -53,7 +53,7 @@ public class LoginService DashboardResponse response, HttpClient client) { if (OnlyAdmin) return 0; - + foreach (var user in response.Users.Where(user => user.AccessCodes.Contains(inputCardNum))) { foreach (var userCredential in response.UserCredentials.Where(userCredential => userCredential.Baid == user.Baid)) @@ -143,7 +143,7 @@ public class LoginService { return LoggedInUser; } - + public void ResetLoggedInUser(DashboardResponse? response) { if (response is null) return; diff --git a/TaikoWebUI/Settings/WebUiSettings.cs b/TaikoWebUI/Settings/WebUiSettings.cs index 769df1b..b122ee3 100644 --- a/TaikoWebUI/Settings/WebUiSettings.cs +++ b/TaikoWebUI/Settings/WebUiSettings.cs @@ -2,11 +2,11 @@ public class WebUiSettings { - public bool LoginRequired { get; set; } - public bool OnlyAdmin { get; set; } - public int BoundAccessCodeUpperLimit { get; set; } - public bool RegisterWithLastPlayTime { get; set; } - public bool AllowUserDelete { get; set; } - public bool AllowFreeProfileEditing { get; set; } - public Language[] SupportedLanguages { get; set; } = Array.Empty<Language>(); + public bool LoginRequired { get; set; } + public bool OnlyAdmin { get; set; } + public int BoundAccessCodeUpperLimit { get; set; } + public bool RegisterWithLastPlayTime { get; set; } + public bool AllowUserDelete { get; set; } + public bool AllowFreeProfileEditing { get; set; } + public Language[] SupportedLanguages { get; set; } = Array.Empty<Language>(); } \ No newline at end of file diff --git a/TaikoWebUI/Shared/ChooseLanguage.razor b/TaikoWebUI/Shared/ChooseLanguage.razor index 9f185b4..5c723eb 100644 --- a/TaikoWebUI/Shared/ChooseLanguage.razor +++ b/TaikoWebUI/Shared/ChooseLanguage.razor @@ -2,7 +2,7 @@ @using Microsoft.Extensions.Options @using TaikoWebUI.Settings @inject NavigationManager NavigationManager -@inject IJSRuntime JSRuntime +@inject IJSRuntime JSRuntime @inject IOptions<WebUiSettings> Settings <MudMenu Icon="@Icons.Material.Filled.Language" Color="Color.Inherit"> @@ -12,8 +12,7 @@ } </MudMenu> - -@code{ +@code { public Dictionary<CultureInfo, string> SupportedCultures = new(); protected override void OnInitialized() @@ -43,4 +42,3 @@ } } - diff --git a/TaikoWebUI/Shared/Constants.cs b/TaikoWebUI/Shared/Constants.cs index c77be7d..a57f3ab 100644 --- a/TaikoWebUI/Shared/Constants.cs +++ b/TaikoWebUI/Shared/Constants.cs @@ -5,8 +5,8 @@ public static class Constants public const int COSTUME_COLOR_MAX = 63; public const string MUSIC_INFO_BASE_NAME = "musicinfo"; - public const string WORDLIST_BASE_NAME = "wordlist"; - public const string MUSIC_ORDER_BASE_NAME = "music_order"; - public const string DON_COS_REWARD_BASE_NAME = "don_cos_reward"; - public const string SHOUGOU_BASE_NAME = "shougou"; + public const string WORDLIST_BASE_NAME = "wordlist"; + public const string MUSIC_ORDER_BASE_NAME = "music_order"; + public const string DON_COS_REWARD_BASE_NAME = "don_cos_reward"; + public const string SHOUGOU_BASE_NAME = "shougou"; } \ No newline at end of file diff --git a/TaikoWebUI/Shared/MainLayout.razor b/TaikoWebUI/Shared/MainLayout.razor index 0e0a683..37f3c16 100644 --- a/TaikoWebUI/Shared/MainLayout.razor +++ b/TaikoWebUI/Shared/MainLayout.razor @@ -1,20 +1,20 @@ @inherits LayoutComponentBase -<MudThemeProvider/> -<MudDialogProvider/> -<MudSnackbarProvider/> +<MudThemeProvider /> +<MudDialogProvider /> +<MudSnackbarProvider /> <MudLayout> <MudAppBar Elevation="0"> - <MudIconButton Icon="@Icons.Material.Filled.Menu" Color="Color.Inherit" Edge="Edge.Start" OnClick="@((e) => DrawerToggle())"/> - <MudSpacer/> - <ChooseLanguage/> + <MudIconButton Icon="@Icons.Material.Filled.Menu" Color="Color.Inherit" Edge="Edge.Start" OnClick="@((e) => DrawerToggle())" /> + <MudSpacer /> + <ChooseLanguage /> </MudAppBar> <MudDrawer @bind-Open="_drawerOpen" Elevation="1"> <MudDrawerHeader> <MudText Typo="Typo.h6">TaikoWebUI</MudText> </MudDrawerHeader> - <NavMenu/> + <NavMenu /> </MudDrawer> <MudMainContent> <MudContainer MaxWidth="MaxWidth.ExtraLarge" Class="my-8"> diff --git a/TaikoWebUI/Shared/Models/DonCosRewardEntry.cs b/TaikoWebUI/Shared/Models/DonCosRewardEntry.cs index 3d2b57f..0bb9d03 100644 --- a/TaikoWebUI/Shared/Models/DonCosRewardEntry.cs +++ b/TaikoWebUI/Shared/Models/DonCosRewardEntry.cs @@ -4,9 +4,9 @@ namespace TaikoWebUI.Shared.Models; public class DonCosRewardEntry { - [JsonPropertyName("cosType")] - public string CosType { get; set; } = null!; + [JsonPropertyName("cosType")] + public string CosType { get; set; } = null!; - [JsonPropertyName("uniqueId")] - public uint UniqueId { get; set; } + [JsonPropertyName("uniqueId")] + public uint UniqueId { get; set; } } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/DonCosRewards.cs b/TaikoWebUI/Shared/Models/DonCosRewards.cs index 95bbf7b..3fa9b2f 100644 --- a/TaikoWebUI/Shared/Models/DonCosRewards.cs +++ b/TaikoWebUI/Shared/Models/DonCosRewards.cs @@ -4,6 +4,6 @@ namespace TaikoWebUI.Shared.Models; public class DonCosRewards { - [JsonPropertyName("items")] - public List<DonCosRewardEntry> DonCosRewardEntries { get; set; } = new(); + [JsonPropertyName("items")] + public List<DonCosRewardEntry> DonCosRewardEntries { get; set; } = new(); } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/MusicDetail.cs b/TaikoWebUI/Shared/Models/MusicDetail.cs index 6f37a1f..72d62cb 100644 --- a/TaikoWebUI/Shared/Models/MusicDetail.cs +++ b/TaikoWebUI/Shared/Models/MusicDetail.cs @@ -3,28 +3,28 @@ public class MusicDetail { public uint SongId { get; set; } - + public int Index { get; set; } public string SongName { get; set; } = string.Empty; public string SongNameEN { get; set; } = string.Empty; public string SongNameCN { get; set; } = string.Empty; public string SongNameKO { get; set; } = string.Empty; - + public string ArtistName { get; set; } = string.Empty; public string ArtistNameEN { get; set; } = string.Empty; public string ArtistNameCN { get; set; } = string.Empty; public string ArtistNameKO { get; set; } = string.Empty; - + public SongGenre Genre { get; set; } - + public int StarEasy { get; set; } - + public int StarNormal { get; set; } - + public int StarHard { get; set; } - + public int StarOni { get; set; } - + public int StarUra { get; set; } } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/MusicInfo.cs b/TaikoWebUI/Shared/Models/MusicInfo.cs index 3cedc11..30b340d 100644 --- a/TaikoWebUI/Shared/Models/MusicInfo.cs +++ b/TaikoWebUI/Shared/Models/MusicInfo.cs @@ -4,6 +4,6 @@ namespace TaikoWebUI.Shared.Models; public class MusicInfo { - [JsonPropertyName("items")] + [JsonPropertyName("items")] public List<MusicInfoEntry> Items { get; set; } = new(); } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/MusicInfoEntry.cs b/TaikoWebUI/Shared/Models/MusicInfoEntry.cs index 65f096d..a2f7086 100644 --- a/TaikoWebUI/Shared/Models/MusicInfoEntry.cs +++ b/TaikoWebUI/Shared/Models/MusicInfoEntry.cs @@ -9,22 +9,22 @@ public class MusicInfoEntry [JsonPropertyName("uniqueId")] public uint SongId { get; set; } - + [JsonPropertyName("genreNo")] public SongGenre Genre { get; set; } [JsonPropertyName("starEasy")] public int StarEasy { get; set; } - + [JsonPropertyName("starNormal")] public int StarNormal { get; set; } - + [JsonPropertyName("starHard")] public int StarHard { get; set; } - + [JsonPropertyName("starMania")] public int StarOni { get; set; } - + [JsonPropertyName("starUra")] public int StarUra { get; set; } } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/NeiroEntry.cs b/TaikoWebUI/Shared/Models/NeiroEntry.cs index 23d876c..19d5f46 100644 --- a/TaikoWebUI/Shared/Models/NeiroEntry.cs +++ b/TaikoWebUI/Shared/Models/NeiroEntry.cs @@ -4,6 +4,6 @@ namespace TaikoWebUI.Shared.Models; public class NeiroEntry { - [JsonPropertyName("uniqueId")] - public uint UniqueId { get; set; } + [JsonPropertyName("uniqueId")] + public uint UniqueId { get; set; } } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/Neiros.cs b/TaikoWebUI/Shared/Models/Neiros.cs index 728ba8b..4055b15 100644 --- a/TaikoWebUI/Shared/Models/Neiros.cs +++ b/TaikoWebUI/Shared/Models/Neiros.cs @@ -4,6 +4,6 @@ namespace TaikoWebUI.Shared.Models; public class Neiros { - [JsonPropertyName("items")] - public List<NeiroEntry> NeiroEntries { get; set; } = new(); + [JsonPropertyName("items")] + public List<NeiroEntry> NeiroEntries { get; set; } = new(); } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/ShougouEntry.cs b/TaikoWebUI/Shared/Models/ShougouEntry.cs index a51112b..989553b 100644 --- a/TaikoWebUI/Shared/Models/ShougouEntry.cs +++ b/TaikoWebUI/Shared/Models/ShougouEntry.cs @@ -4,9 +4,9 @@ namespace TaikoWebUI.Shared.Models; public class ShougouEntry { - [JsonPropertyName("uniqueId")] - public uint UniqueId { get; set; } - - [JsonPropertyName("rarity")] - public uint Rarity { get; set; } + [JsonPropertyName("uniqueId")] + public uint UniqueId { get; set; } + + [JsonPropertyName("rarity")] + public uint Rarity { get; set; } } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/Shougous.cs b/TaikoWebUI/Shared/Models/Shougous.cs index 4a27738..dc250e1 100644 --- a/TaikoWebUI/Shared/Models/Shougous.cs +++ b/TaikoWebUI/Shared/Models/Shougous.cs @@ -4,6 +4,6 @@ namespace TaikoWebUI.Shared.Models; public class Shougous { - [JsonPropertyName("items")] - public List<ShougouEntry> ShougouEntries { get; set; } = new(); + [JsonPropertyName("items")] + public List<ShougouEntry> ShougouEntries { get; set; } = new(); } \ No newline at end of file diff --git a/TaikoWebUI/Shared/Models/Title.cs b/TaikoWebUI/Shared/Models/Title.cs index 476492c..1d44fd6 100644 --- a/TaikoWebUI/Shared/Models/Title.cs +++ b/TaikoWebUI/Shared/Models/Title.cs @@ -3,9 +3,9 @@ public class Title { public int TitleId { get; set; } - + public string TitleName { get; init; } = string.Empty; - + public uint TitleRarity { get; init; } public override bool Equals(object? obj) diff --git a/TaikoWebUI/Shared/Models/WordListEntry.cs b/TaikoWebUI/Shared/Models/WordListEntry.cs index 3fe7324..5c34b0f 100644 --- a/TaikoWebUI/Shared/Models/WordListEntry.cs +++ b/TaikoWebUI/Shared/Models/WordListEntry.cs @@ -6,16 +6,16 @@ public class WordListEntry { [JsonPropertyName("key")] public string Key { get; set; } = string.Empty; - + [JsonPropertyName("japaneseText")] public string JapaneseText { get; set; } = string.Empty; - + [JsonPropertyName("englishUsText")] public string EnglishUsText { get; set; } = string.Empty; - + [JsonPropertyName("chineseTText")] public string ChineseTText { get; set; } = string.Empty; - + [JsonPropertyName("koreanText")] public string KoreanText { get; set; } = string.Empty; } \ No newline at end of file