From f9e3ba0f6470ac30164afd53c78b5db8e4c4b74d Mon Sep 17 00:00:00 2001 From: wangwei Date: Thu, 18 Jun 2026 17:28:15 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20add=20weight=20config=20panel=20to=20?= =?UTF-8?q?=E6=96=B0=E5=BB=BA=E8=AF=84=E4=BC=B0=20and=20weighted=5Fscore?= =?UTF-8?q?=20card=20to=20report?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- webapp/static/css/app.css | 28 ++++++++++ webapp/static/index.html | 16 ++++++ webapp/static/js/report.js | 12 +++++ webapp/static/js/runner.js | 103 ++++++++++++++++++++++++++++--------- 4 files changed, 135 insertions(+), 24 deletions(-) diff --git a/webapp/static/css/app.css b/webapp/static/css/app.css index f15f41e..73f450f 100644 --- a/webapp/static/css/app.css +++ b/webapp/static/css/app.css @@ -342,6 +342,34 @@ table.group-table td { border-bottom: 1px solid #f1f5f9; font-variant-numeric: t } .report-switcher-select:focus { outline: none; border-color: var(--petrol); } +/* ?? ?????? ??????????????????????????????????? */ +.weight-config-panel { margin-top: 12px; } +.weight-section-title { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 8px; } +.weight-rows { display: flex; flex-direction: column; gap: 6px; } +.weight-row { + display: flex; align-items: center; gap: 10px; + font-size: 13px; +} +.weight-row-label { min-width: 180px; color: var(--slate); font-family: monospace; } +.weight-row-input { + width: 80px; padding: 4px 8px; border: 1px solid var(--border); + border-radius: 6px; font-size: 13px; text-align: right; +} +.weight-row-input:focus { outline: none; border-color: #6366f1; } +.doc-weight-name { + flex: 1; padding: 4px 8px; border: 1px solid var(--border); + border-radius: 6px; font-size: 13px; min-width: 0; +} +.weight-row-remove { color: var(--bad); cursor: pointer; font-size: 14px; background: none; border: none; padding: 2px 6px; } +.weight-row-remove:hover { background: #fee2e2; border-radius: 4px; } + +/* weighted_score ???????? */ +.metric-card.weighted-score-card { + border: 2px solid #6366f1; + background: #f5f3ff; +} +.metric-card.weighted-score-card .metric-name { color: #4f46e5; font-weight: 700; } + /* ================================================================ 打印样式(导出 PDF 用) 浏览器打印时隐藏 UI chrome,保留报告内容,图表 canvas 原样输出 diff --git a/webapp/static/index.html b/webapp/static/index.html index 5ab2fc2..d7a2d57 100644 --- a/webapp/static/index.html +++ b/webapp/static/index.html @@ -92,6 +92,22 @@ + + +