From 273ff5f72dfdaa179a5d46ca47873c83b5654243 Mon Sep 17 00:00:00 2001 From: zdl <3489966805@qq.com> Date: Thu, 6 Nov 2025 01:20:33 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=9B=B8=E5=85=B3=E6=A6=82=E5=BF=B5?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20PRO=20=E6=9D=83=E9=99=90=E6=8E=A7=E5=88=B6?= =?UTF-8?q?...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../RelatedConceptsSection/index.js | 67 +++++++++++++------ 1 file changed, 45 insertions(+), 22 deletions(-) diff --git a/src/views/Community/components/DynamicNewsDetail/RelatedConceptsSection/index.js b/src/views/Community/components/DynamicNewsDetail/RelatedConceptsSection/index.js index 1250b17e..009e8573 100644 --- a/src/views/Community/components/DynamicNewsDetail/RelatedConceptsSection/index.js +++ b/src/views/Community/components/DynamicNewsDetail/RelatedConceptsSection/index.js @@ -28,8 +28,18 @@ import { logger } from '../../../../../utils/logger'; * @param {string} props.eventTitle - 事件标题(用于搜索概念) * @param {string} props.effectiveTradingDate - 有效交易日期(涨跌幅数据日期) * @param {string|Object} props.eventTime - 事件发生时间 + * @param {React.ReactNode} props.subscriptionBadge - 订阅徽章组件(可选) + * @param {boolean} props.isLocked - 是否锁定详细模式(需要付费) + * @param {Function} props.onLockedClick - 锁定时的点击回调(触发付费弹窗) */ -const RelatedConceptsSection = ({ eventTitle, effectiveTradingDate, eventTime }) => { +const RelatedConceptsSection = ({ + eventTitle, + effectiveTradingDate, + eventTime, + subscriptionBadge = null, + isLocked = false, + onLockedClick = null +}) => { const [isExpanded, setIsExpanded] = useState(false); const [concepts, setConcepts] = useState([]); const [loading, setLoading] = useState(true); @@ -202,28 +212,41 @@ const RelatedConceptsSection = ({ eventTitle, effectiveTradingDate, eventTime }) return ( - {/* 标题栏 */} - - - - 相关概念 - - {/* 交易日期信息 */} - + {/* 标题栏 - 两行布局 */} + + {/* 第一行:标题 + Badge + 按钮 */} + + + + 相关概念 + + {/* 订阅徽章 */} + {subscriptionBadge} + + - - + {/* 第二行:交易日期信息 */} + + {/* 简单模式:横向卡片列表(总是显示) */}