From b97d77c8488b67e52b492fd42afac2fa58052764 Mon Sep 17 00:00:00 2001 From: yoan <536464346@qq.com> Date: Wed, 30 Oct 2024 11:57:16 +0800 Subject: [PATCH 1/2] Fix the issue where long domain names or titles overlap the next column. --- ui/src/domain/settings.ts | 12 +++++++++--- ui/src/pages/access/Access.tsx | 4 +++- ui/src/pages/dashboard/Dashboard.tsx | 9 ++------- ui/src/pages/domains/Home.tsx | 10 +++------- ui/src/pages/history/History.tsx | 9 ++------- 5 files changed, 19 insertions(+), 25 deletions(-) diff --git a/ui/src/domain/settings.ts b/ui/src/domain/settings.ts index 798c4e86..114fc8ac 100644 --- a/ui/src/domain/settings.ts +++ b/ui/src/domain/settings.ts @@ -26,7 +26,13 @@ export type NotifyChannels = { mail?: NotifyChannelMail; }; -export type NotifyChannel = NotifyChannelDingTalk | NotifyChannelLark | NotifyChannelTelegram | NotifyChannelWebhook | NotifyChannelServerChan | NotifyChannelMail; +export type NotifyChannel = + | NotifyChannelDingTalk + | NotifyChannelLark + | NotifyChannelTelegram + | NotifyChannelWebhook + | NotifyChannelServerChan + | NotifyChannelMail; export type NotifyChannelDingTalk = { accessToken: string; @@ -60,8 +66,8 @@ export type NotifyChannelMail = { receiverAddresses: string; smtpHostAddr: string; smtpHostPort: string; - username:string; - password:string; + username: string; + password: string; enabled: boolean; }; diff --git a/ui/src/pages/access/Access.tsx b/ui/src/pages/access/Access.tsx index 6fb3cd66..f079703d 100644 --- a/ui/src/pages/access/Access.tsx +++ b/ui/src/pages/access/Access.tsx @@ -117,7 +117,9 @@ const Access = () => { className="flex flex-col sm:flex-row text-secondary-foreground border-b dark:border-stone-500 sm:p-2 hover:bg-muted/50 text-sm" key={access.id} > -
{access.name}
+
+
{access.name}
+
{t(accessProvidersMap.get(access.configType)?.name || "")}
diff --git a/ui/src/pages/dashboard/Dashboard.tsx b/ui/src/pages/dashboard/Dashboard.tsx index ff655b98..7de1d16a 100644 --- a/ui/src/pages/dashboard/Dashboard.tsx +++ b/ui/src/pages/dashboard/Dashboard.tsx @@ -180,13 +180,8 @@ const Dashboard = () => { key={deployment.id} className="flex flex-col sm:flex-row text-secondary-foreground border-b dark:border-stone-500 sm:p-2 hover:bg-muted/50 text-sm" > -
- {deployment.expand.domain?.domain.split(";").map((domain: string) => ( - <> - {domain} -
- - ))} +
+ {deployment.expand.domain?.domain.split(";").map((domain: string) =>
{domain}
)}
diff --git a/ui/src/pages/domains/Home.tsx b/ui/src/pages/domains/Home.tsx index 4e66714c..a2d6411c 100644 --- a/ui/src/pages/domains/Home.tsx +++ b/ui/src/pages/domains/Home.tsx @@ -201,12 +201,9 @@ const Home = () => { className="flex flex-col sm:flex-row text-secondary-foreground border-b dark:border-stone-500 sm:p-2 hover:bg-muted/50 text-sm" key={domain.id} > -
- {domain.domain.split(";").map((item) => ( - <> - {item} -
- +
+ {domain.domain.split(";").map((domain: string) => ( +
{domain}
))}
@@ -340,4 +337,3 @@ const Home = () => { }; export default Home; - diff --git a/ui/src/pages/history/History.tsx b/ui/src/pages/history/History.tsx index e0a47186..5bdaec53 100644 --- a/ui/src/pages/history/History.tsx +++ b/ui/src/pages/history/History.tsx @@ -75,13 +75,8 @@ const History = () => { key={deployment.id} className="flex flex-col sm:flex-row text-secondary-foreground border-b dark:border-stone-500 sm:p-2 hover:bg-muted/50 text-sm" > -
- {deployment.expand.domain?.domain.split(";").map((domain: string) => ( - <> - {domain} -
- - ))} +
+ {deployment.expand.domain?.domain.split(";").map((domain: string) =>
{domain}
)}
From d833f4b5ff05a31a9915e04a598c8d8353838203 Mon Sep 17 00:00:00 2001 From: yoan <536464346@qq.com> Date: Wed, 30 Oct 2024 16:08:32 +0800 Subject: [PATCH 2/2] fix cos region validate --- ui/src/components/certimate/DeployToTencentCOS.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/src/components/certimate/DeployToTencentCOS.tsx b/ui/src/components/certimate/DeployToTencentCOS.tsx index 7fcb5e2a..d6edd925 100644 --- a/ui/src/components/certimate/DeployToTencentCOS.tsx +++ b/ui/src/components/certimate/DeployToTencentCOS.tsx @@ -97,7 +97,7 @@ const DeployToTencentCOS = () => { onChange={(e) => { const temp = e.target.value; - const resp = bucketSchema.safeParse(temp); + const resp = regionSchema.safeParse(temp); if (!resp.success) { setError({ ...error,