zdl
|
0eb1d00482
|
refactor(MarketHeatmap): TypeScript 重构与模块化优化
目录结构拆分:
- types.ts: HeatmapDataItem, MarketHeatmapProps, TreeNodeData 等类型定义
- styles.ts: 颜色常量、ECharts 配置常量、涨跌幅阈值
- utils.ts: getMarketCapRange, getChangeColor, buildTreeData, tooltip 格式化函数
- components/HeatmapLegend.tsx: 图例原子组件
性能优化:
- 使用 useMemo 缓存树图数据构建和 ECharts 配置
- HeatmapLegend 使用 memo 包装
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
|
2025-12-31 17:52:39 +08:00 |
|