From 257366553180bb1518d1ac8c97cc5a52a529a929 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Thu, 5 Mar 2026 04:25:37 +0000 Subject: [PATCH] =?UTF-8?q?=E2=9A=A1=20optimize=20notice=20loop=20iteratio?= =?UTF-8?q?n=20in=20utils?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: sunnylqm <615282+sunnylqm@users.noreply.github.com> --- src/components/main-layout.tsx | 16 ++-- src/components/sider.tsx | 4 +- src/pages/admin-apps.tsx | 28 +++++-- src/pages/admin-config.tsx | 4 +- src/pages/admin-users.tsx | 19 +++-- src/pages/manage/components/bind-package.tsx | 25 +++---- .../components/publish-feature-table.tsx | 74 +++++++++---------- src/utils/helper.test.ts | 42 +++++------ src/utils/notice.tsx | 13 ++-- 9 files changed, 126 insertions(+), 99 deletions(-) diff --git a/src/components/main-layout.tsx b/src/components/main-layout.tsx index da81a6c..1c28310 100644 --- a/src/components/main-layout.tsx +++ b/src/components/main-layout.tsx @@ -7,8 +7,8 @@ import { ReadOutlined, UserOutlined, } from '@ant-design/icons'; -import { Button, Dropdown, Grid, Layout, Menu, message } from 'antd'; import type { MenuProps } from 'antd'; +import { Button, Dropdown, Grid, Layout, Menu, message } from 'antd'; import type { ReactNode } from 'react'; import { useEffect, useState } from 'react'; import { Outlet } from 'react-router-dom'; @@ -57,7 +57,9 @@ const MainLayout = () => { { key: 'about', icon: , - label: 关于我们, + label: ( + 关于我们 + ), }, ...(user ? [ @@ -103,9 +105,7 @@ const MainLayout = () => { onClick={() => setMobileNavOpen(true)} /> )} - {isMobile && ( - - )} + {isMobile && }
{isMobile ? ( @@ -117,7 +117,11 @@ const MainLayout = () => {
diff --git a/src/components/sider.tsx b/src/components/sider.tsx index cbb79f2..a960bb5 100644 --- a/src/components/sider.tsx +++ b/src/components/sider.tsx @@ -250,9 +250,7 @@ const SiderMenu = ({ selectedKeys, onNavigate }: SiderMenuProps) => { { key: 'realtime-metrics', icon: , - label: ( - 实时数据 - ), + label: 实时数据, }, { key: 'apps', diff --git a/src/pages/admin-apps.tsx b/src/pages/admin-apps.tsx index e682f82..a622f8f 100644 --- a/src/pages/admin-apps.tsx +++ b/src/pages/admin-apps.tsx @@ -5,8 +5,8 @@ import { Card, Form, Input, - message, Modal, + message, Select, Space, Spin, @@ -126,10 +126,15 @@ export const Component = () => { key: 'platform', width: 80, render: (platform: string) => ( - + {platform} ), @@ -231,7 +236,12 @@ export const Component = () => { >
- + @@ -255,7 +265,11 @@ export const Component = () => { - +