diff --git a/public/icons/compIcon.png b/public/icons/compIcon.png index 958ca0e..56cb749 100644 Binary files a/public/icons/compIcon.png and b/public/icons/compIcon.png differ diff --git a/public/icons/compIcon1.png b/public/icons/compIcon1.png new file mode 100644 index 0000000..958ca0e Binary files /dev/null and b/public/icons/compIcon1.png differ diff --git a/src/pages/ideContainer/market.tsx b/src/pages/ideContainer/market.tsx index 36ef998..830b85c 100644 --- a/src/pages/ideContainer/market.tsx +++ b/src/pages/ideContainer/market.tsx @@ -309,6 +309,8 @@ const Market: React.FC = ({ updateProjectComp }) => { // 转换为数组格式 const resultComponents = Object.values(mergedComponents); + console.log('resultComponents;', resultComponents); + // 如果没有组件,显示提示信息 if (resultComponents.length === 0) { return ( @@ -365,7 +367,18 @@ const Market: React.FC = ({ updateProjectComp }) => {
- {component.label || component.flowName} +
+
+ {component.label || component.flowName} + {component?.comp?.codeLanguage && ( + + {component.comp.codeLanguage} + + )} +
+ {component?.comp?.identifier} + {component?.comp?.author} +
{/*两种状态 未添加的是primary 已添加的是secondary*/} { diff --git a/src/pages/ideContainer/style/market.module.less b/src/pages/ideContainer/style/market.module.less index 8ce8a26..7d369c2 100644 --- a/src/pages/ideContainer/style/market.module.less +++ b/src/pages/ideContainer/style/market.module.less @@ -44,16 +44,57 @@ display: flex; justify-content: space-between; align-items: center; + gap: 12px; padding-top: 10px; .component-info { + min-width: 0; + flex: 1; display: flex; align-items: center; img { - width: 40px; - height: 40px; - margin-right: 10px; + width: 45px; + height: 45px; + margin-right: 15px; + flex-shrink: 0; + } + + .component-text { + min-width: 0; + flex: 1; + display: flex; + flex-direction: column; + gap: 4px; + + .component-header { + min-width: 0; + display: flex; + align-items: center; + gap: 8px; + } + + .component-flowName { + min-width: 0; + font-size: 16px; + font-weight: 600; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + + .component-language-tag { + flex-shrink: 0; + } + + .component-identifier, + .component-author { + font-size: 12px; + color: #adadad; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } } } }