diff --git a/Moonlight.Frontend/UI/Admin/Views/Sys/Diagnose.razor b/Moonlight.Frontend/UI/Admin/Views/Sys/Diagnose.razor index 96f2c427..a21f4ab3 100644 --- a/Moonlight.Frontend/UI/Admin/Views/Sys/Diagnose.razor +++ b/Moonlight.Frontend/UI/Admin/Views/Sys/Diagnose.razor @@ -48,18 +48,22 @@
- - - @if (IsLoading) - { + @if (IsLoading) + { + + - } - else + + + } + else + { + if (HasDiagnosed) + { + if (Entries.Length == 0) { - if (HasDiagnosed) - { - if (Entries.Length == 0) - { + + @@ -71,123 +75,127 @@ - } - else + + + } + else + { + + + @for (var i = 0; i < Entries.Length; i++) { - + var entry = Entries[i]; - @for (var i = 0; i < Entries.Length; i++) - { - var entry = Entries[i]; + var textColor = entry.Level switch + { + DiagnoseLevel.Error => "text-destructive", + DiagnoseLevel.Warning => "text-yellow-400", + DiagnoseLevel.Healthy => "text-green-500" + }; - var textColor = entry.Level switch - { - DiagnoseLevel.Error => "text-destructive", - DiagnoseLevel.Warning => "text-yellow-300", - DiagnoseLevel.Healthy => "text-green-500" - }; + - + +
- -
+ @switch (entry.Level) + { + case DiagnoseLevel.Error: + + break; - @switch (entry.Level) - { - case DiagnoseLevel.Error: - - break; + case DiagnoseLevel.Warning: + + break; - case DiagnoseLevel.Warning: - - break; + case DiagnoseLevel.Healthy: + + break; + } - case DiagnoseLevel.Healthy: - - break; - } - -
+
@entry.Title - + @(string.Join(" / ", entry.Tags)) -
-
- - -
+
+
+
+ +
+ @if (!string.IsNullOrWhiteSpace(entry.StackStrace)) + { +
+ @entry.StackStrace +
+ } + + @if (!string.IsNullOrWhiteSpace(entry.Message)) + { +

+ @entry.Message +

+ } + + @if ( + !string.IsNullOrWhiteSpace(entry.ReportUrl) || + !string.IsNullOrWhiteSpace(entry.StackStrace) || + !string.IsNullOrWhiteSpace(entry.SolutionUrl) + ) + { +
@if (!string.IsNullOrWhiteSpace(entry.StackStrace)) { -
- @entry.StackStrace -
+ } - @if (!string.IsNullOrWhiteSpace(entry.Message)) + @if (!string.IsNullOrWhiteSpace(entry.SolutionUrl)) { -

- @entry.Message -

+ } - @if ( - !string.IsNullOrWhiteSpace(entry.ReportUrl) || - !string.IsNullOrWhiteSpace(entry.StackStrace) || - !string.IsNullOrWhiteSpace(entry.SolutionUrl) - ) + @if (!string.IsNullOrWhiteSpace(entry.ReportUrl)) { -
- @if (!string.IsNullOrWhiteSpace(entry.StackStrace)) - { - - } - - @if (!string.IsNullOrWhiteSpace(entry.SolutionUrl)) - { - - } - - @if (!string.IsNullOrWhiteSpace(entry.ReportUrl)) - { - - } -
+ }
- - - } - + } +
+
+ } - } - else - { + + } + } + else + { + + @@ -199,10 +207,10 @@ - } - } - - + + + } + }
diff --git a/Moonlight.Frontend/UI/Admin/Views/Users/Index.razor b/Moonlight.Frontend/UI/Admin/Views/Users/Index.razor index 3d6ee37d..cdd1c84c 100644 --- a/Moonlight.Frontend/UI/Admin/Views/Users/Index.razor +++ b/Moonlight.Frontend/UI/Admin/Views/Users/Index.razor @@ -36,7 +36,7 @@
- +