diff --git a/modalscope-home/components/FilterAndSortPanel/index.module.less b/modalscope-home/components/FilterAndSortPanel/index.module.less new file mode 100644 index 0000000..ec7f883 --- /dev/null +++ b/modalscope-home/components/FilterAndSortPanel/index.module.less @@ -0,0 +1,162 @@ +@border-radius-base: 2px; +@color-1: #f4f7fb; +@color-2: #624afb; +@color-3: #6149fa; +@color-4: #8082a0; +@color-5: #3b29b0; +@color-6: #ca632f; +@color-7: #27254a; +@color-8: #fdfdfd; +@font-size-base: 14px; +@font-size-sm: 12px; +@margin-xs: 8px; + +.wrapper { + margin-top: 10px; + padding: 2px 20px 20px; + background-color: @color-8; +} + +.containerSection { + display: flex; + flex-direction: column; +} + +.contentWrapper { + display: flex; + align-items: center; + justify-content: space-between; +} + +.optionsContainer { + display: flex; + align-items: center; +} + +.allButton { + min-width: 64px; + height: 32px; + border-width: 1px; + border-color: @color-2; + background-color: @color-1; + color: @color-3; +} + +.programmaticCreation { + margin-left: 20px; + white-space: nowrap; + color: @color-4; + font-size: @font-size-base; +} + +.interactiveCreation { + margin-left: 40px; + white-space: nowrap; + color: @color-4; + font-size: @font-size-base; +} + +.searchInput { + width: 378px; +} + +.iconZoomOut { + color: @color-3; + font-size: @font-size-sm; +} + +.tagSection { + display: flex; + align-items: center; + margin-top: 18px; + gap: 34px; +} + +.fieldLabel { + white-space: nowrap; + color: @color-4; + font-size: @font-size-base; +} + +.multiModalTag { + margin-left: 10px; + color: @color-5; + font-size: @font-size-base; +} + +.naturalLanguageProcessingButton { + max-width: 104px; + height: 24px; + margin-left: @margin-xs; + border-radius: 7px; + background-color: @color-1; + color: @color-5; +} + +.autoMLTag { + margin-left: @margin-xs; + color: @color-5; + font-size: @font-size-base; +} + +.careerTag { + margin-left: 14px; + color: @color-6; + font-size: @font-size-base; +} + +.educationTag { + margin-left: 10px; + color: @color-6; + font-size: @font-size-base; +} + +.marketingTag { + margin-left: @margin-xs; + color: @color-6; + font-size: @font-size-base; +} + +.iconDropdown { + color: @color-6; + font-size: 6px; +} + +.gpuDeployButton { + height: 28px; + background-color: @color-1; +} + +.buttonContent { + display: flex; + align-items: center; + justify-content: center; +} + +.gpuImage { + flex-shrink: 0; + width: 6px; + height: 6px; + border-radius: @border-radius-base; +} + +.buttonText { + margin-left: 2px; + font-size: @font-size-base; +} + +.gpuLabel { + color: @color-3; +} + +.deploymentSpace { + color: @color-7; +} + +.spaceImage { + flex-shrink: 0; + width: 8px; + height: 8px; + margin-left: @margin-xs; + border-radius: @border-radius-base; +} diff --git a/modalscope-home/components/FilterAndSortPanel/index.tsx b/modalscope-home/components/FilterAndSortPanel/index.tsx new file mode 100644 index 0000000..f6e1c54 --- /dev/null +++ b/modalscope-home/components/FilterAndSortPanel/index.tsx @@ -0,0 +1,117 @@ +import React, { useState } from 'react'; +import { Button, Input, Tag } from 'antd'; +import { ZoomOutOutlined, CaretDownFilled } from '@ant-design/icons'; + +import styles from './index.module.less'; + +const FilterAndSortPanel: React.FC = () => { + const [inputPlaceholderValue, setInputPlaceholderValue] = useState(''); + + const onAllItemsClick = () => {}; + + const onNlpTitleClick = () => {}; + + const onGpuDeploySpaceClick = () => {}; + + return ( +
+
+
+
+ + 编程式创建 + 交互式创建 +
+
+ } + value={inputPlaceholderValue} + onChange={e => { + setInputPlaceholderValue(e.target.value); + }} + className={styles.searchInput} + /> + 综合排序化 +
+
+
+
+ 领域: + + 多模态 + + + 计算机视觉 + + + + 语音 + + + AutoML + +
+
+ 场景: + + 职场 + + + 教育 + + + 营销 + + + 生活 + + + 情感 + + } + className={styles.marketingTag} + > + 更多 + +
+ +
+
+
+ ); +}; + +export default FilterAndSortPanel; diff --git a/modalscope-home/components/HomePage/index.module.less b/modalscope-home/components/HomePage/index.module.less new file mode 100644 index 0000000..53138b8 --- /dev/null +++ b/modalscope-home/components/HomePage/index.module.less @@ -0,0 +1,160 @@ +@border-radius-base: 2px; +@color-1: #27254a; +@color-2: #8082a0; +@color-3: #e8e9ed; +@color-4: #fdfdfd; +@font-size-base: 14px; +@font-size-lg: 16px; +@margin-xs: 8px; +@margin-xss: 4px; +@padding-sm: 12px; + +.wrapper { + margin-left: 6px; + padding: 2px @padding-sm; + background-color: @color-4; +} + +.mainContainer { + display: flex; +} + +.headerSection { + display: flex; + align-items: center; + align-self: center; +} + +.logoImage { + flex-shrink: 0; + width: 45px; + height: 22px; + border-radius: 3px; +} + +.siteTitle { + flex: 1; + margin-left: 6px; + white-space: nowrap; + color: @color-1; + font-size: @font-size-base; + font-weight: bold; +} + +.homeLink { + align-self: center; + margin-left: 50px; + color: @color-2; + font-size: @font-size-base; +} + +.modelLibraryLink { + align-self: center; + margin-left: 30px; + color: @color-2; + font-size: @font-size-base; +} + +.datasetLink { + align-self: center; + margin-left: 32px; + color: @color-2; + font-size: @font-size-base; +} + +.creationSpaceLink { + align-self: center; + margin-left: 32px; + color: @color-1; + font-size: @font-size-base; + font-weight: bold; +} + +.aigcZoneLink { + align-self: center; + margin-left: 60px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.documentationCenterLink { + align-self: center; + margin-left: 35px; + color: @color-2; + font-size: @font-size-base; +} + +.profileImage { + flex-shrink: 0; + align-self: center; + width: 8px; + height: 8px; + margin-left: @margin-xss; + border-radius: @border-radius-base; +} + +.emptyDiv { + width: 6px; + min-height: 12px; + margin-top: 14px; + margin-left: 15px; + background-color: @color-3; +} + +.githubIcon { + align-self: center; + margin-left: 15px; + color: @color-2; + font-size: @font-size-lg; +} + +.githubText { + align-self: center; + margin-left: 5px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.thumbnailImage { + flex-shrink: 0; + align-self: center; + width: 16px; + height: 16px; + margin-left: 160px; + border-radius: 9px; +} + +.thumbnailImageAlt { + flex-shrink: 0; + align-self: center; + width: 16px; + height: 16px; + margin-left: 20px; + border-radius: 6px; +} + +.zoomOutIcon { + align-self: center; + margin-left: 25px; + color: @color-2; + font-size: @font-size-lg; +} + +.searchPlaceholder { + align-self: center; + margin-left: @margin-xs; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.thumbnailImageSecondary { + flex-shrink: 0; + align-self: center; + width: 50px; + height: 40px; + margin-left: 50px; + border-radius: 3px; +} diff --git a/modalscope-home/components/HomePage/index.tsx b/modalscope-home/components/HomePage/index.tsx new file mode 100644 index 0000000..e156336 --- /dev/null +++ b/modalscope-home/components/HomePage/index.tsx @@ -0,0 +1,55 @@ +import React from 'react'; +import { GithubOutlined, ZoomOutOutlined } from '@ant-design/icons'; + +import styles from './index.module.less'; + +const HomePage: React.FC = () => { + return ( +
+
+
+ + 1odei5cope +
+ 首页 + 模型库 + 数据集 + 创空间 + AIGC专区 + 文档中心 + 社区 + +
+ + GitHub + + + + 搜索您... + +
+
+ ); +}; + +export default HomePage; diff --git a/modalscope-home/components/ProductGallery/index.module.less b/modalscope-home/components/ProductGallery/index.module.less new file mode 100644 index 0000000..535ce9e --- /dev/null +++ b/modalscope-home/components/ProductGallery/index.module.less @@ -0,0 +1,362 @@ +@border-radius-base: 2px; +@color-1: #27254a; +@color-2: #8082a0; +@color-3: #e8e9ed; +@color-4: #f4f7fb; +@color-5: #7e6fda; +@color-6: #454c5a; +@color-7: #f3f5f9; +@color-8: #fdfdfd; +@font-size-base: 14px; +@margin-md: 16px; +@margin-sm: 12px; +@margin-xs: 8px; +@padding-md: 16px; +@padding-sm: 12px; + +.wrapper { + flex: 1; + margin-top: 10px; + padding: 2px @padding-sm @padding-md 20px; + background-color: @color-8; +} + +.productContainer { + display: flex; + flex-direction: column; +} + +.productHeader { + display: flex; + align-items: center; +} + +.featuredLabel { + color: @color-1; + font-size: @font-size-base; +} + +.thumbnailImage { + flex-shrink: 0; + width: 16px; + height: 16px; + margin-left: 6px; + border-radius: 3px; +} + +.productBody { + display: flex; + flex: 1; + margin-top: @margin-sm; +} + +.productRow { + display: flex; + flex-wrap: wrap; + margin-right: -12px; + margin-left: -12px; + row-gap: 24px; +} + +.productColumn { + flex-grow: 0; + flex-shrink: 0; + width: 50%; + max-width: 50%; + padding-right: @padding-sm; + padding-left: @padding-sm; +} + +.productItem { + display: flex; + flex-direction: column; + padding: 18px @padding-md; + border-radius: 16px; + background-color: @color-4; +} + +.modelBattleImage { + flex-shrink: 0; + width: 374px; + height: 208px; + border-radius: 10px; +} + +.productName { + margin-top: @margin-md; + margin-right: 5px; + margin-left: 5px; + white-space: nowrap; + color: @color-1; + font-size: @font-size-base; + font-weight: bold; +} + +.productDetails { + display: flex; + justify-content: space-between; + margin-top: 40px; +} + +.productStats { + display: flex; + align-items: center; + margin-left: 5px; +} + +.statsIcon { + flex-shrink: 0; + width: 15px; + height: 15px; + border-radius: 4px; +} + +.statsTitle { + flex: 1; + margin-left: 6px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.updateInfo { + display: flex; + margin-right: 2px; +} + +.updateDate { + align-self: center; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.viewsWrapper { + width: 2px; + min-height: 14px; + margin-top: 5px; + margin-bottom: 5px; + margin-left: 6px; + background-color: @color-3; +} + +.viewCount { + align-self: center; + margin-left: 10px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.likesWrapper { + width: 1px; + min-height: 14px; + margin-top: 5px; + margin-bottom: 5px; + margin-left: 10px; + background-color: @color-3; +} + +.likeIcon { + flex-shrink: 0; + align-self: center; + width: 10px; + height: 10px; + margin-left: @margin-sm; + border-radius: @border-radius-base; +} + +.likeCount { + align-self: center; + margin-left: 6px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.commentItem { + display: flex; + flex-direction: column; + padding: 22px 18px 18px; + border-radius: 15px; + background-color: @color-4; +} + +.commentThumbnail { + flex-shrink: 0; + width: 370px; + height: 206px; + border-radius: 9px; +} + +.commentTitle { + align-self: flex-start; + margin-top: 15px; + white-space: nowrap; + color: @color-1; + font-size: @font-size-base; + font-weight: bold; +} + +.commentDetails { + display: flex; + margin-top: 42px; +} + +.commentIcon { + flex-shrink: 0; + align-self: center; + width: 15px; + height: 15px; + margin-left: 2px; + border-radius: 6px; +} + +.commentUpdate { + align-self: center; + margin-left: 72px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.commentViews { + width: 1px; + min-height: 14px; + margin-top: 5px; + margin-bottom: 5px; + margin-left: 6px; + background-color: @color-3; +} + +.commentViewCount { + align-self: center; + margin-left: @margin-sm; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.commentLikes { + width: 2px; + min-height: 14px; + margin-top: 5px; + margin-bottom: 5px; + margin-left: 10px; + background-color: @color-3; +} + +.commentLikeIcon { + flex-shrink: 0; + align-self: center; + width: 10px; + height: 10px; + margin-left: 10px; + border-radius: @border-radius-base; +} + +.commentReplies { + display: flex; + flex-direction: column; + margin-top: 2px; + margin-bottom: 2px; + margin-left: 25px; + padding: 18px; + border-radius: 18px; + background-color: @color-7; +} + +.storySection { + display: flex; + margin-top: @margin-md; +} + +.storyItem { + display: flex; + flex-direction: column; + align-self: center; +} + +.storyTitle { + align-self: flex-start; + white-space: nowrap; + color: @color-1; + font-size: @font-size-base; + font-weight: bold; +} + +.tagSection { + display: flex; + align-items: center; + margin-top: @margin-xs; + gap: 6px; +} + +.visionTag { + border-color: @color-5; + color: @color-5; + font-size: @font-size-base; +} + +.anyStoryTag { + color: @color-6; + font-size: @font-size-base; +} + +.additionalInfo { + display: flex; + align-items: center; + margin-top: @margin-sm; +} + +.labImage { + flex-shrink: 0; + width: 15px; + height: 15px; + border-radius: 7px; +} + +.labName { + margin-left: 6px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.dateUpdated { + margin-left: 80px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.extraContent { + width: 2px; + min-height: 12px; + margin-top: 66px; + margin-left: 6px; + background-color: @color-3; +} + +.viewCount2 { + margin-top: 64px; + margin-left: @margin-sm; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.separatorDiv { + width: 2px; + min-height: 12px; + margin-top: 68px; + margin-left: @margin-xs; + background-color: @color-3; +} + +.commentCount { + margin-top: 64px; + margin-left: @margin-sm; + color: @color-2; + font-size: @font-size-base; +} diff --git a/modalscope-home/components/ProductGallery/index.tsx b/modalscope-home/components/ProductGallery/index.tsx new file mode 100644 index 0000000..817bbfd --- /dev/null +++ b/modalscope-home/components/ProductGallery/index.tsx @@ -0,0 +1,127 @@ +import React from 'react'; +import { Tag } from 'antd'; + +import styles from './index.module.less'; + +const ProductGallery: React.FC = () => { + return ( +
+
+
+ 精选 + +
+
+
+
+
+ + + 推理模型大作战(QwQ-32B vs DeepSeek-R1) + +
+
+ + 为AI成魔 +
+
+ 2025.03.10更新 +
+ 18.9k +
+ + 74 +
+
+
+
+
+
+ + + 通义万相Wan2.1视频生成 + +
+ + 通义万相 + 2025.02.26更新 +
+ 210.0k +
+ + 771 +
+
+
+
+
+ +
+
+ AI故事随心绘-AnyStory +
+ + 计算机视觉 + + + 多模态 + + + AnyStory + +
+
+ + 通义实验室 + 2025.03.19更新 +
+
+
+ · 1.9k +
+ 20 +
+
+
+
+
+ ); +}; + +export default ProductGallery; diff --git a/modalscope-home/components/SpaceCreationGuide/index.module.less b/modalscope-home/components/SpaceCreationGuide/index.module.less new file mode 100644 index 0000000..2caf867 --- /dev/null +++ b/modalscope-home/components/SpaceCreationGuide/index.module.less @@ -0,0 +1,141 @@ +@border-radius-base: 2px; +@color-1: #27254a; +@color-2: #8082a0; +@color-3: #b0a5f6; +@color-4: #aea3f7; +@color-5: #f3f5f9; +@color-6: #6149fa; +@color-7: #f4f7fb; +@color-8: #fdfdfd; +@font-size-base: 14px; +@margin-md: 16px; +@padding-md: 16px; +@padding-xs: 8px; + +.wrapper { + margin-top: @margin-md; + padding: @padding-xs @padding-xs 14px 14px; + background-color: @color-8; +} + +.spaceContainer { + display: flex; + flex-direction: column; +} + +.headerSection { + display: flex; + align-items: center; +} + +.headerImage { + flex-shrink: 0; + width: 18px; + height: 18px; + margin-left: 2px; + border-radius: @border-radius-base; +} + +.headerTitle { + flex: 1; + margin-left: 10px; + white-space: nowrap; + color: @color-1; + font-size: 18px; + font-weight: bold; +} + +.contentWrapper { + display: flex; + align-items: center; + margin-top: 20px; + padding: @padding-md 28px @padding-md 32px; + border-radius: 10px; + background-color: @color-7; +} + +.stepOneImage { + flex-shrink: 0; + width: 40px; + height: 40px; + border-radius: 3px; +} + +.stepOneDetails { + display: flex; + flex-direction: column; + margin-left: @margin-md; +} + +.stepOneTitle { + align-self: flex-start; + white-space: nowrap; + color: @color-1; + font-size: @font-size-base; + font-weight: bold; +} + +.stepOneDescription { + margin-top: 2px; + white-space: nowrap; + color: @color-2; + font-size: @font-size-base; +} + +.minusIcon { + margin-left: 18px; + color: @color-3; + font-size: 10px; +} + +.stepTwoImage { + flex-shrink: 0; + width: 36px; + height: 36px; + margin-left: 46px; + border-radius: 3px; +} + +.stepTwoDetails { + display: flex; + flex-direction: column; + margin-left: 18px; +} + +.stepThreeImage { + flex-shrink: 0; + width: 22px; + height: 10px; + margin-left: 6px; + border-radius: 3px; +} + +.stepFourImage { + flex-shrink: 0; + width: 36px; + height: 36px; + margin-left: 36px; + border-radius: 3px; +} + +.arrowIndicator { + margin-left: 78px; + white-space: nowrap; + color: @color-4; + font-size: @font-size-base; +} + +.stepFourImage2 { + flex-shrink: 0; + width: 38px; + height: 38px; + margin-left: 36px; + border-radius: 3px; +} + +.createButton { + height: 32px; + margin-left: @margin-md; + background-color: @color-5; + color: @color-6; +} diff --git a/modalscope-home/components/SpaceCreationGuide/index.tsx b/modalscope-home/components/SpaceCreationGuide/index.tsx new file mode 100644 index 0000000..4a75c49 --- /dev/null +++ b/modalscope-home/components/SpaceCreationGuide/index.tsx @@ -0,0 +1,82 @@ +import React from 'react'; +import { MinusOutlined } from '@ant-design/icons'; +import { Button } from 'antd'; + +import styles from './index.module.less'; + +const SpaceCreationGuide: React.FC = () => { + const onCreateBtnClick = () => {}; + + return ( +
+
+
+ + 创空间 +
+
+ +
+ 创建空间 + + 输入基础信息快速完成空间创建 + +
+ + +
+ 搭建应用 + + 基于平台模型与可视化SDK几行... + +
+ + +
+ 发布空间 + + 平台环境支持一键发布 + +
+ + +
+ 分享创意 + + 将您的创空间分享给您的朋友吧 + +
+ +
+
+
+ ); +}; + +export default SpaceCreationGuide; diff --git a/modalscope-home/index.module.less b/modalscope-home/index.module.less new file mode 100644 index 0000000..b9ca38c --- /dev/null +++ b/modalscope-home/index.module.less @@ -0,0 +1,8 @@ +@padding-sm: 12px; + +.wrapper { + display: flex; + flex-direction: column; + width: 1355px; + padding: 5px @padding-sm; +} diff --git a/modalscope-home/index.tsx b/modalscope-home/index.tsx new file mode 100644 index 0000000..b2f1749 --- /dev/null +++ b/modalscope-home/index.tsx @@ -0,0 +1,20 @@ +import React from 'react'; +import FilterAndSortPanel from './components/FilterAndSortPanel'; +import HomePage from './components/HomePage'; +import ProductGallery from './components/ProductGallery'; +import SpaceCreationGuide from './components/SpaceCreationGuide'; + +import styles from './index.module.less'; + +const MyPageComponent: React.FC = () => { + return ( +
+ + + + +
+ ); +}; + +export default MyPageComponent;