From 0eca24dcce04059df6ae984fde1a89d513284139 Mon Sep 17 00:00:00 2001 From: Junyan Qin Date: Fri, 9 May 2025 20:37:32 +0800 Subject: [PATCH] perf(PluginMarketCard): switch to tailwindcss --- .../PluginMarketCardComponent.tsx | 43 +++---- .../pluginMarketCard.module.css | 115 ------------------ 2 files changed, 17 insertions(+), 141 deletions(-) delete mode 100644 web/src/app/home/plugins/plugin-market/plugin-market-card/pluginMarketCard.module.css diff --git a/web/src/app/home/plugins/plugin-market/plugin-market-card/PluginMarketCardComponent.tsx b/web/src/app/home/plugins/plugin-market/plugin-market-card/PluginMarketCardComponent.tsx index 1f0d4b69..85d52878 100644 --- a/web/src/app/home/plugins/plugin-market/plugin-market-card/PluginMarketCardComponent.tsx +++ b/web/src/app/home/plugins/plugin-market/plugin-market-card/PluginMarketCardComponent.tsx @@ -1,4 +1,3 @@ -import styles from './pluginMarketCard.module.css'; import { PluginMarketCardVO } from '@/app/home/plugins/plugin-market/plugin-market-card/PluginMarketCardVO'; import { Button } from '@/components/ui/button'; @@ -14,53 +13,45 @@ export default function PluginMarketCardComponent({ } return ( +
+
+ -
-
- - -
- -
- -
-
{cardVO.author} /
-
-
{cardVO.name}
+
+
+
+
{cardVO.author} /
+
+
{cardVO.name}
-
{cardVO.description}
+
{cardVO.description}
-
- -
- -
星标 {cardVO.starCount}
+
+
+ +
星标 {cardVO.starCount}
-
+
window.open(cardVO.githubURL, '_blank')} - style={{ cursor: 'pointer' }} >
-
-
-
); diff --git a/web/src/app/home/plugins/plugin-market/plugin-market-card/pluginMarketCard.module.css b/web/src/app/home/plugins/plugin-market/plugin-market-card/pluginMarketCard.module.css deleted file mode 100644 index 719c2e09..00000000 --- a/web/src/app/home/plugins/plugin-market/plugin-market-card/pluginMarketCard.module.css +++ /dev/null @@ -1,115 +0,0 @@ -.cardContainer { - width: 26rem; - height: 10rem; - background-color: #fff; - border-radius: 10px; - box-shadow: 0px 2px 2px 0 rgba(0, 0, 0, 0.2); - padding: 1.2rem; -} - -.contentContainer { - width: 100%; - height: 100%; - display: flex; - flex-direction: row; - align-items: flex-start; - justify-content: flex-start; - gap: 1.2rem; -} - -.pluginIcon { - width: 4rem; - height: 4rem; - color: #2288ee; -} - -.infoContainer { - width: 100%; - height: 100%; - /* background-color: aqua; */ - display: flex; - flex-direction: column; - align-items: flex-start; - justify-content: space-between; - gap: 0.6rem; -} - -.basicInfoContainer { - display: flex; - flex-direction: column; - align-items: flex-start; - justify-content: flex-start; -} - - -.nameContainer { - display: flex; - flex-direction: column; - align-items: flex-start; - justify-content: flex-start; -} - -.author { - font-size: 0.7rem; - color: #666; -} - -.nameAndVersionContainer { - display: flex; - flex-direction: row; - align-items: center; - justify-content: flex-start; - gap: 0.4rem; -} - -.name { - font-size: 1.2rem; - color: #000; -} - -.description { - font-size: 0.8rem; - color: #666; - display: -webkit-box; - -webkit-line-clamp: 2; - -webkit-box-orient: vertical; - overflow: hidden; -} - -.componentContainer { - width: 100%; - display: flex; - flex-direction: row; - align-items: flex-start; - justify-content: space-between; - gap: 0.6rem; -} - -.componentEntryContainer { - display: flex; - height: 100%; - flex-direction: row; - align-items: center; - justify-content: center; - gap: 0.4rem; -} - -.componentIcon { - width: 1.2rem; - height: 1.2rem; - color: #ffcd27; -} - - -.componentText { - font-size: 1rem; - color: #ffcd27; - font-weight: 500; -} - -.githubIcon { - width: 1.4rem; - height: 1.4rem; - color: #000; - cursor: pointer; -} \ No newline at end of file