From f79235b330d456c387f19e02207a48368fefecf0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Allen=20Zhang=20=28=E5=BC=A0=E6=B6=9B=29?= Date: Thu, 4 Jul 2024 10:58:37 +0800 Subject: [PATCH] feat: update --- packages/canyon-platform/src/assets/img.png | Bin 0 -> 383 bytes .../src/pages/index/projects/[id]/index.tsx | 97 +++++++++++++----- 2 files changed, 71 insertions(+), 26 deletions(-) create mode 100644 packages/canyon-platform/src/assets/img.png diff --git a/packages/canyon-platform/src/assets/img.png b/packages/canyon-platform/src/assets/img.png new file mode 100644 index 0000000000000000000000000000000000000000..54ed216201a146e21f759912e268061a7114b670 GIT binary patch literal 383 zcmV-_0f7FAP)ZzX^J;ILlAs=CY7h<2|Mq(<38|O1i$BdILT7%3U*nHUP4J;t9At+=9I}fx-rmUmxE2 z8u0!!5SN&MYeWg~ayt;WI}O)}j{}W6FV1;>#U-cU8arcL-2NQ?WN((4kyB!l#nt+8 zre21qu3iFtuCfF7axz#L?eyc+;wnUiFI1%Uv)-3w9|`3`5amz%q1BK08`6#_rwT*` zG65XdHU5UQ^Wq#E7t97B%6H;}_TZp*PG$dqqE_-@{ +// return
+// nihao +//
+// } const ProjectOverviewPage = () => { const { token } = useToken(); const { t } = useTranslation(); @@ -171,6 +175,26 @@ const ProjectOverviewPage = () => { ); }, + // width: '150px', + // render(_, { sha }) { + // return ( + //
+ // + // {_}% + // + // + // coverage + // + // + //
+ // ); + // }, }, { title: ( @@ -314,7 +338,7 @@ const ProjectOverviewPage = () => { {t('projects.default.branch')}: {projectByIdData?.getProjectByID.defaultBranch} - {projectByIdData?.getProjectByID.tags.length > 0 && ( + {(projectByIdData?.getProjectByID.tags||[]).length > 0 && (
{t('projects.config.tag')}: @@ -408,30 +432,51 @@ const ProjectOverviewPage = () => { {t('projects.records')} -
- { - setKeyword(value); - setCurrent(1); - }} - style={{ width: '700px' }} - /> - - {t('projects.only.default.branch')}: - { - if (v) { - localStorage.setItem('defaultBranchOnly', '1'); - } else { - localStorage.removeItem('defaultBranchOnly'); - } - setDefaultBranchOnly(v); +
+ +
+ { + setKeyword(value); + setCurrent(1); }} + style={{ width: '500px' }} /> - + + {t('projects.only.default.branch')}: + { + if (v) { + localStorage.setItem('defaultBranchOnly', '1'); + } else { + localStorage.removeItem('defaultBranchOnly'); + } + setDefaultBranchOnly(v); + }} + /> + +
+ +
+ { + ['#1f77b4','#ff7f0e','#2ca02c'].map((item, index) => { + return
+ + { + { + 0:'手工测试', + 1:'UI自动化测试', + 2:'单元测试', + }[index] || 'unknown' + + } +
+ }) + } +
{/*div*/}