diff --git a/apps/web/src/app/[locale]/page.tsx b/apps/web/src/app/[locale]/page.tsx index 28386845..f7eadc3d 100644 --- a/apps/web/src/app/[locale]/page.tsx +++ b/apps/web/src/app/[locale]/page.tsx @@ -14,6 +14,7 @@ * figma-v2 重點: 7指標(含今日事件) + 監控工具左彩色條 + 可點擊連結 + meta行 */ +import React from 'react' import { useTranslations } from 'next-intl' import { useState, useEffect } from 'react' import { useGlobalPulseMetrics } from '@/hooks/useGlobalPulseMetrics' @@ -513,7 +514,7 @@ export default function Home({ params }: { params: { locale: string } }) { {/* ── Metrics Strip ─────────────────────────────────────────────────── */}
- {/* Metrics Row — figma-v2: 7 metrics */} -
+ {/* Metrics Row — figma-v2 完整複製 */} +
{metrics.map((m, i) => ( -
- {/* Label */} - - {m.label} - - {/* Value row */} -
- - {String(m.value)} + +
+ {/* Label — figma: font-size:11px */} + + {m.label} - {m.sparkline && ( - - )} -
- {/* Sub / badge / extra row */} -
- {m.extra ? m.extra : m.badge ? ( + {/* Value row — figma: height:32px */} +
- {m.badge.text} + {String(m.value)} - ) : m.sub ? ( - {m.sub} - ) : null} +
+ {/* Extra row — figma: height:20px margin-top:4px */} +
+ {m.extra ? m.extra : m.badge ? ( + + {m.badge.text} + + ) : m.sub ? ( + {m.sub} + ) : null} +
-
+ {/* Divider — figma: 獨立元素 width:0.5px height:36px */} + {i < metrics.length - 1 && ( +
+ )} + ))}
diff --git a/apps/web/src/components/layout/header.tsx b/apps/web/src/components/layout/header.tsx index ae80b743..df00ebfa 100644 --- a/apps/web/src/components/layout/header.tsx +++ b/apps/web/src/components/layout/header.tsx @@ -75,6 +75,7 @@ export function Header({ background: '#faf9f3', overflow: 'hidden', transition: 'width 0.3s ease', + flexShrink: 0, }}> {/* NemoClaw mini SVG */}