11<template >
2- <div class =" min-h-screen stats-page" :class = " { 'tf-card-root': useDarkTheme } " >
2+ <div class =" min-h-screen stats-page" >
33 <!-- 粘性顶部栏 -->
44 <div class =" topbar" >
55 <div class =" container" >
6666 <!-- two-column layout -->
6767 <div class =" grid-main" >
6868 <div class =" left-col" >
69- <div class =" card elevated" :class = " useDarkTheme ? 'dark-card' : '' " >
69+ <div class =" card elevated" >
7070 <div class =" card-header" >
7171 <div class =" title" >访问趋势</div >
7272 <div class =" actions" >
@@ -271,7 +271,8 @@ const SkeletonLoader = defineAsyncComponent(() => import('../components/Skeleton
271271const CityBarLoader = () => import (' ../components/charts/EChartsBar.vue' )
272272const CountryPieLoader = () => import (' ../components/charts/EChartsPie.vue' )
273273import ' ../style/charts-theme.css'
274- const useDarkTheme = true
274+ // 统一为浅色企业冷静风
275+ const useDarkTheme = false
275276
276277const route = useRoute ()
277278const router = useRouter ()
@@ -658,14 +659,15 @@ function retryFetch(){ apiErrors.value = []; debouncedRefreshAll() }
658659
659660<style scoped>
660661:root {
661- --bg : #f6f8fb ;
662- --card : #ffffff ;
663- --muted : #94a3b8 ;
664- --accent : #2563eb ;
665- --glass : rgba (255 ,255 ,255 ,0.6 );
662+ /* 统一蓝白企业冷静风配色,使用设计系统变量 */
663+ --bg : var (--tf-bg-page );
664+ --card : var (--tf-bg-card );
665+ --muted : var (--tf-text-muted );
666+ --accent : var (--tf-brand-primary );
667+ --glass : rgba (255 ,255 ,255 ,0.7 );
666668}
667669
668- .stats-page { background : var (--bg ); font-family : Inter, ui-sans-serif , system-ui , -apple-system , " Segoe UI" , Roboto, " Helvetica Neue" , Arial ; color : #0f172a ; min-height : 100vh ; padding-top : 84px ; }
670+ .stats-page { background : var (--bg ); font-family : Inter, ui-sans-serif , system-ui , -apple-system , " Segoe UI" , Roboto, " Helvetica Neue" , Arial ; color : var ( --tf-text-body ) ; min-height : 100vh ; padding-top : 84px ; }
669671
670672/* container */
671673.container { max-width : 1200px ; margin : 0 auto ; padding : 0 18px ; }
@@ -675,37 +677,38 @@ function retryFetch(){ apiErrors.value = []; debouncedRefreshAll() }
675677.topbar {
676678 position : fixed ; top : 0 ; left : 0 ; right : 0 ; height : 68px ;
677679 backdrop-filter : blur (6px ); -webkit-backdrop-filter : blur (6px );
678- background : linear-gradient (180deg , rgba (255 ,255 ,255 ,0.6 ), rgba (255 ,255 ,255 ,0.45 ));
679- border-bottom : 1px solid rgba ( 14 , 18 , 32 , 0.04 );
680+ background : linear-gradient (180deg , rgba (255 ,255 ,255 ,0.9 ), rgba (255 ,255 ,255 ,0.75 ));
681+ border-bottom : 1px solid var ( --tf-border );
680682 display : flex ; align-items : center ; z-index : 80 ;
681683}
682684.topbar .container { display :flex ; align-items :center ; justify-content :space-between ; }
683685.topbar .left , .topbar .center , .topbar .right { display :flex ; align-items :center ; gap :12px ; }
684686.search-wrap { width : 420px ; }
685- .search-input { width :100% ; padding :10px 12px ; border-radius :8px ; border :1px solid #e6eef9 ; background :linear-gradient (180deg ,#fff ,#fbfdff ); font-size :14px ; box-shadow :0 1px 2px rgba (16 ,24 ,40 ,0.03 ); }
686- .btn { padding :8px 12px ; border-radius :8px ; background :transparent ; border :none ; cursor :pointer ; color :var (--accent ); font-weight :600 ; }
687+ .search-input { width :100% ; padding :10px 12px ; border-radius :8px ; border :1px solid var ( --tf-border ) ; background :linear-gradient (180deg ,#fff ,#fbfdff ); font-size :14px ; box-shadow :0 1px 2px rgba (16 ,24 ,40 ,0.03 ); }
688+ .btn { padding :8px 12px ; border-radius :8px ; background :transparent ; border :none ; cursor :pointer ; color :var (--tf-brand-primary ); font-weight :600 ; }
687689.btn-ghost { background :transparent ; color :#334155 ; padding :6px 10px ; border-radius :8px ; }
688690.btn-ghost.tiny { padding :6px 8px ; font-size :12px ; }
689691.btn-sm { padding :6px 8px ; border-radius :6px ; background :#f1f5f9 ; color :#334155 ; margin-right :6px ; }
690692.btn-sm.active { background : var (--accent ); color :#fff ; }
691693
692694/* metrics */
693695.metrics { display :grid ; grid-template-columns : repeat (6 ,1fr ); gap :16px ; margin-bottom :18px ; }
694- .metric-card { padding :16px ; border-radius :12px ; background :var (--card ); border :1px solid rgba ( 14 , 18 , 32 , 0.04 ); text-align :center ; transition :transform .18s ease , box-shadow .18s ease ; }
696+ .metric-card { padding :16px ; border-radius :12px ; background :var (--card ); border :1px solid var ( --tf-border ); text-align :center ; transition :transform .18s ease , box-shadow .18s ease ; }
695697.metric-card .metric-label { font-size :12px ; color :var (--muted ); margin-bottom :8px ; text-transform :uppercase ; letter-spacing :0.6px ; }
696698.metric-value { font-size :26px ; font-weight :700 ; color :#0f172a ; }
697- .metric-card.elevated { box-shadow : 0 6 px 18 px rgba ( 16 , 24 , 40 , 0.06 ); }
699+ .metric-card.elevated { box-shadow : var ( --tf-shadow-card ); }
698700
699701/* layout */
700702.grid-main { display :grid ; grid-template-columns : 1fr 360px ; gap :20px ; align-items :start ; }
701703.left-col { display :flex ; flex-direction :column ; gap :16px ; }
702704.right-col { display :flex ; flex-direction :column ; gap :16px ; }
703705
704706/* cards */
705- .card { border-radius :12px ; background :var (--card ); border :1px solid rgba (14 ,18 ,32 ,0.04 ); overflow :hidden ; }
706- .card.elevated { box-shadow :0 10px 30px rgba (16 ,24 ,40 ,0.06 ); }
707- .dark-card { background : linear-gradient (180deg ,#0b1221 , #071224 ); color :#dbeafe ; border-color : rgba (255 ,255 ,255 ,0.04 ); }
708- .card-header { display :flex ; justify-content :space-between ; align-items :center ; padding :16px 18px ; border-bottom :1px solid rgba (14 ,18 ,32 ,0.04 ); font-weight :700 ; }
707+ .card { border-radius :12px ; background :var (--card ); border :1px solid var (--tf-border ); overflow :hidden ; }
708+ .card.elevated { box-shadow : var (--tf-shadow-card ); }
709+ /* 移除暗色变体,保持统一蓝白风格 */
710+
711+ .card-header { display :flex ; justify-content :space-between ; align-items :center ; padding :16px 18px ; border-bottom :1px solid var (--tf-divider ); font-weight :700 ; }
709712.card-body { padding :18px ; }
710713
711714/* charts */
@@ -740,10 +743,10 @@ function retryFetch(){ apiErrors.value = []; debouncedRefreshAll() }
740743.device-tag { background :#f1f5f9 ; padding :4px 8px ; border-radius :6px ; font-size :12px ; color :#64748b ; }
741744
742745/* modal */
743- .modal { width :560px ; background :var (--card ); border-radius :12px ; overflow :hidden ; box-shadow :0 10 px 30 px rgba ( 16 , 24 , 40 , 0.08 ); }
744- .modal-header { padding :16px ; font-weight :700 ; border-bottom :1px solid rgba ( 14 , 18 , 32 , 0.04 ); }
746+ .modal { width :560px ; background :var (--card ); border-radius :12px ; overflow :hidden ; box-shadow : var ( --tf-shadow-modal ); }
747+ .modal-header { padding :16px ; font-weight :700 ; border-bottom :1px solid var ( --tf-divider ); }
745748.modal-body { padding :16px ; }
746- .modal-footer { padding :12px 16px ; display :flex ; justify-content :flex-end ; gap :8px ; border-top :1px solid rgba ( 14 , 18 , 32 , 0.04 ); }
749+ .modal-footer { padding :12px 16px ; display :flex ; justify-content :flex-end ; gap :8px ; border-top :1px solid var ( --tf-divider ); }
747750
748751/* error banner */
749752.error-banner { padding :12px 16px ; border-radius :10px ; background :#fff5f5 ; border :1px solid #fee2e2 ; color :#991b1b ; display :flex ; justify-content :space-between ; align-items :center ; gap :12px ; }
0 commit comments