From ff80bef939e92205dc01c7c7cb981ed30fe995b8 Mon Sep 17 00:00:00 2001 From: Ironsp <1522278303@qq.com> Date: Sat, 5 Sep 2026 11:44:18 +0800 Subject: [PATCH] =?UTF-8?q?feat=20=E4=BB=AA=E8=A1=A8=E7=9B=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ses_f90b33b70ffeX2sgAkpr0eWAkU.json | 10 + src/components/work/dashboard.vue | 256 +++++++++++++++++- src/main.ts | 3 - vite.config.ts | 5 +- 4 files changed, 260 insertions(+), 14 deletions(-) create mode 100644 .omo/run-continuation/ses_f90b33b70ffeX2sgAkpr0eWAkU.json diff --git a/.omo/run-continuation/ses_f90b33b70ffeX2sgAkpr0eWAkU.json b/.omo/run-continuation/ses_f90b33b70ffeX2sgAkpr0eWAkU.json new file mode 100644 index 0000000..48e0629 --- /dev/null +++ b/.omo/run-continuation/ses_f90b33b70ffeX2sgAkpr0eWAkU.json @@ -0,0 +1,10 @@ +{ + "sessionID": "ses_f90b33b70ffeX2sgAkpr0eWAkU", + "updatedAt": "2026-09-05T02:48:46.575Z", + "sources": { + "background-task": { + "state": "idle", + "updatedAt": "2026-09-05T02:48:46.575Z" + } + } +} diff --git a/src/components/work/dashboard.vue b/src/components/work/dashboard.vue index 0135d92..d392b09 100644 --- a/src/components/work/dashboard.vue +++ b/src/components/work/dashboard.vue @@ -1,11 +1,141 @@ @@ -17,14 +147,124 @@ padding: 16px; } -.placeholder { +.card-title { + font-size: 18px; + font-weight: 600; + color: #333; + margin-bottom: 16px; +} + +/* 仪表盘区域 - 左右分布 */ +.gauge-section { + display: flex; + gap: 12px; +} + +.gauge-left, +.gauge-right { + flex: 1; + display: flex; + flex-direction: column; +} + +/* 左侧仪表项 */ +.gauge-item { + margin-bottom: 16px; +} + +.gauge-header { display: flex; align-items: center; - justify-content: center; - min-height: 120px; - color: #999; + gap: 6px; + margin-bottom: 8px; +} + +.gauge-icon { + font-size: 16px; +} + +.gauge-label { font-size: 14px; - border: 1px dashed #ddd; - border-radius: 8px; + color: #666; +} + +.gauge-value { + font-size: 18px; + font-weight: 600; + color: #333; +} + +/* ===== 压实度圆环 ===== */ +.ring-wrap { + position: relative; + width: 100px; + height: 100px; +} + +/* ===== 右侧频率项 ===== */ +.freq-item { + margin-bottom: 16px; +} + +.freq-label { + font-size: 14px; + color: #666; + display: block; + margin-bottom: 4px; +} + +.freq-value { + font-size: 18px; + font-weight: 600; + color: #333; +} + +/* ===== 车速 SVG 半圆仪表 ===== */ +.speed-gauge { + width: 100px; + height: 60px; +} + +.speed-svg { + width: 100%; + height: 100%; +} + +/* ===== 分割线 ===== */ +.divider { + height: 1px; + background: #eee; + margin: 16px 0; +} + +/* ===== 今日作业概览 ===== */ +.section-title { + font-size: 18px; + font-weight: 600; + color: #333; + margin-bottom: 16px; +} + +.overview-section { + display: flex; + justify-content: space-between; +} + +.overview-item { + display: flex; + flex-direction: column; + align-items: center; + gap: 8px; +} + +.overview-label { + font-size: 13px; + color: #999; +} + +.overview-value { + font-size: 18px; + font-weight: 600; + color: #333; } diff --git a/src/main.ts b/src/main.ts index a54ab5e..c97747e 100644 --- a/src/main.ts +++ b/src/main.ts @@ -1,12 +1,9 @@ -import * as echarts from 'echarts' -import { provideEcharts } from 'uni-echarts' import { createSSRApp } from 'vue' import App from './App.vue' import 'uno.css' export function createApp() { const app = createSSRApp(App) - provideEcharts(echarts) return { app, } diff --git a/vite.config.ts b/vite.config.ts index 95edf35..6d9b355 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -3,7 +3,7 @@ import UniHelperComponents from '@uni-helper/vite-plugin-uni-components' import UniHelperLayouts from '@uni-helper/vite-plugin-uni-layouts' import UniHelperManifest from '@uni-helper/vite-plugin-uni-manifest' import UniHelperPages from '@uni-helper/vite-plugin-uni-pages' -import { UniEcharts } from 'uni-echarts/vite' +import { UniEchartsResolver } from 'uni-echarts/resolver' import UnoCSS from 'unocss/vite' import AutoImport from 'unplugin-auto-import/vite' import { defineConfig } from 'vite' @@ -24,9 +24,8 @@ export default defineConfig({ UniHelperComponents({ dts: 'src/components.d.ts', directoryAsNamespace: true, + resolvers: [UniEchartsResolver()], }), - // https://uni-echarts.xiaohe.ink/guide/getting-started - UniEcharts(), // https://uni-helper.js.org/plugin-uni Uni(), UniPolyfill(),