From eafb43746c126470111b20313e5f8b1189d661ea Mon Sep 17 00:00:00 2001 From: Tinie13 Date: Mon, 29 Apr 2024 11:41:12 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E6=96=B0=E5=A2=9E=E8=A7=86=E9=A2=91?= =?UTF-8?q?=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/home/HomeCardPlayer.astro | 230 ++++++++++++++--------- src/components/icon/Pause.astro | 1 + src/i18n/en/ui.ts | 2 + src/i18n/zh-cn/ui.ts | 2 + src/pages/index.astro | 2 + 5 files changed, 144 insertions(+), 93 deletions(-) create mode 100644 src/components/icon/Pause.astro diff --git a/src/components/home/HomeCardPlayer.astro b/src/components/home/HomeCardPlayer.astro index e06e0d10247..d2ccd84a514 100644 --- a/src/components/home/HomeCardPlayer.astro +++ b/src/components/home/HomeCardPlayer.astro @@ -1,29 +1,26 @@ --- +import Pause from "../icon/Pause.astro"; +import { useTranslations } from "@i18n/util"; +const t = useTranslations(Astro); const mediaResource = [ { - checked: true, src: "https://cloud.video.taobao.com/vod/play/REFkazc0bXZaVE82emRHbklyTEdsNjFUYnBNSkd6cmpoU0U5cG9KRWtZQzZQZWw1SnpKVVVCTlh4OVFON0V5UUVMUDduY1RJak82VE1sdXdHTjNOaHc9PQ", description: "Nacos |手动部署 Derby 数据库", cover:'https://img.alicdn.com/imgextra/i2/O1CN01mZMLGh1WIsTB2WOEB_!!6000000002766-0-tps-2516-1282.jpg' }, { - checked: false, src: "https://cloud.video.taobao.com/vod/play/REFkazc0bXZaVE82emRHbklyTEdsMWppZ21TWGh4TDE/U2FmT3I2OU9yZTZQZWw1SnpKVVVCTlh4OVFON0V5UUVMUDduY1RJak82VE1sdXdHTjNOaHc9PQ", description: "Nacos |手动部署 MySQL 数据库", cover:'https://img.alicdn.com/imgextra/i2/O1CN01S9Q8mE1FJvunXlzc2_!!6000000000467-0-tps-2296-1164.jpg' }, { - checked: false, src: "https://cloud.video.taobao.com/vod/play/REFkazc0bXZaVE82emRHbklyTEdsMERLOHRmWmdQR1Ywcjl5dlM2Nk1YSzZQZWw1SnpKVVVCTlh4OVFON0V5UUVMUDduY1RJak82VE1sdXdHTjNOaHc9PQ", - description: - "Nacos|Docker 部署 Derby 和 MySQL 数据库", + description:"Nacos|Docker 部署 Derby 和 MySQL 数据库", cover:"https://img.alicdn.com/imgextra/i2/O1CN01MOLx6f1k1qMPncU8j_!!6000000004624-0-tps-2552-1158.jpg" }, { - checked: false, src: "https://cloud.video.taobao.com/vod/play/REFkazc0bXZaVE82emRHbklyTEdsNFFUMXFoNnp2NXBPaEFUNFNDYUVRRzZQZWw1SnpKVVVCTlh4OVFON0V5UUVMUDduY1RJak82VE1sdXdHTjNOaHc9PQ", - description: - "Nacos |入门样例", + description:"Nacos |入门样例", cover:"https://img.alicdn.com/imgextra/i1/O1CN01fkLmjc1n7HuqYQst1_!!6000000005042-0-tps-2300-1166.jpg", }, ]; @@ -32,22 +29,17 @@ const mediaResource = [
- COMMUNITY VOICE - Tutorials from Community + {t('home.card.player.voice')} + {t('home.card.player.tutorials')}
-
- +
{ mediaResource.map((item, index) => { - let { src, description, checked,cover } = item; + const { src, description,cover } = item; return ( <> -