From 99c36ae54881b78315ff4ef11486943160566da6 Mon Sep 17 00:00:00 2001 From: LittleSheep Date: Thu, 10 Jul 2025 02:28:27 +0800 Subject: [PATCH] :lipstick: Optimized the authorized page style --- DysonNetwork.Sphere/Developer/CustomApp.cs | 4 +- .../Pages/Account/Profile.cshtml | 2 +- .../Pages/Auth/Authorize.cshtml | 42 ++++++++--------- .../Pages/Shared/_Layout.cshtml | 18 ++++++-- DysonNetwork.Sphere/wwwroot/css/styles.css | 46 +++++++++++++++++++ 5 files changed, 82 insertions(+), 30 deletions(-) diff --git a/DysonNetwork.Sphere/Developer/CustomApp.cs b/DysonNetwork.Sphere/Developer/CustomApp.cs index 6c5472c..d1aaaeb 100644 --- a/DysonNetwork.Sphere/Developer/CustomApp.cs +++ b/DysonNetwork.Sphere/Developer/CustomApp.cs @@ -38,14 +38,14 @@ public class CustomApp : ModelBase, IIdentifiedResource [NotMapped] public string ResourceIdentifier => "custom-app/" + Id; } -public class CustomAppLinks : ModelBase +public class CustomAppLinks { [MaxLength(8192)] public string? HomePage { get; set; } [MaxLength(8192)] public string? PrivacyPolicy { get; set; } [MaxLength(8192)] public string? TermsOfService { get; set; } } -public class CustomAppOauthConfig : ModelBase +public class CustomAppOauthConfig { [MaxLength(1024)] public string? ClientUri { get; set; } [MaxLength(4096)] public string[] RedirectUris { get; set; } = []; diff --git a/DysonNetwork.Sphere/Pages/Account/Profile.cshtml b/DysonNetwork.Sphere/Pages/Account/Profile.cshtml index 0f93334..86e6d6a 100644 --- a/DysonNetwork.Sphere/Pages/Account/Profile.cshtml +++ b/DysonNetwork.Sphere/Pages/Account/Profile.cshtml @@ -15,7 +15,7 @@ -
+
diff --git a/DysonNetwork.Sphere/Pages/Auth/Authorize.cshtml b/DysonNetwork.Sphere/Pages/Auth/Authorize.cshtml index 4d9fcff..3cc992a 100644 --- a/DysonNetwork.Sphere/Pages/Auth/Authorize.cshtml +++ b/DysonNetwork.Sphere/Pages/Auth/Authorize.cshtml @@ -4,9 +4,9 @@ ViewData["Title"] = "Authorize Application"; } -
+
-
+

Authorize Application

@@ -17,11 +17,19 @@ @if (!string.IsNullOrEmpty(Model.AppLogo)) {
-
+
@Model.AppName logo
} + else + { +
+
+ @Model.AppName?[..1].ToUpper() +
+
+ }

@Model.AppName

@if (!string.IsNullOrEmpty(Model.AppUri)) @@ -35,11 +43,11 @@
}

- wants to access your account with the following permissions: + When you authorize this application, you consent to the following permissions:

-
-
-