From eae2b5dfee2283f48f80e2fc7b4d79172010a51a Mon Sep 17 00:00:00 2001 From: Hera Zhao Date: Fri, 10 Apr 2026 16:07:56 +0000 Subject: [PATCH] =?UTF-8?q?UI:=20=E7=AE=A1=E7=90=86=E9=85=8D=E6=96=B9?= =?UTF-8?q?=E7=95=8C=E9=9D=A2=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 取消改为预览按钮 + ✕关闭 - 去掉配方行的owner显示和铅笔编辑按钮(点击行即编辑) - 搜索框和新增按钮合并到一行,紧凑排版 - 参考比例显示"约为X滴,现在为Y滴"(实际数据) Co-Authored-By: Claude Opus 4.6 (1M context) --- .../src/components/RecipeDetailOverlay.vue | 2 +- frontend/src/views/RecipeManager.vue | 42 +++++++++++-------- 2 files changed, 26 insertions(+), 18 deletions(-) diff --git a/frontend/src/components/RecipeDetailOverlay.vue b/frontend/src/components/RecipeDetailOverlay.vue index 7745bd8..7aa2024 100644 --- a/frontend/src/components/RecipeDetailOverlay.vue +++ b/frontend/src/components/RecipeDetailOverlay.vue @@ -165,7 +165,7 @@ - 纯精油总数约为 {{ editorSuggestedEo }} 滴 + 纯精油总数约为 {{ editorSuggestedEo }} 滴,现在为 {{ editorEoDrops }} 滴 diff --git a/frontend/src/views/RecipeManager.vue b/frontend/src/views/RecipeManager.vue index 58c110d..d208388 100644 --- a/frontend/src/views/RecipeManager.vue +++ b/frontend/src/views/RecipeManager.vue @@ -22,18 +22,14 @@ - - - @@ -164,14 +158,12 @@ />
{{ r.name }} - {{ r._owner_name }} {{ t }} {{ oils.fmtPrice(oils.calcCost(r.ingredients)) }}
-
@@ -236,7 +228,8 @@
- + +
@@ -261,7 +254,7 @@ - 纯精油总数约为 {{ suggestedEoDrops }} 滴 + 纯精油总数约为 {{ suggestedEoDrops }} 滴,现在为 {{ eoTotalDrops }} 滴 @@ -621,6 +614,11 @@ async function applyBatchTags() { clearSelection() } +function previewRecipe() { + // TODO: generate card preview + ui.showToast('预览功能开发中') +} + function doBatch(action) { showBatchMenu.value = false executeBatchAction(action) @@ -1723,7 +1721,17 @@ watch(() => recipeStore.recipes, () => { .select-sm { padding: 4px 6px; border: 1.5px solid #d4cfc7; border-radius: 6px; font-size: 12px; font-family: inherit; background: #fff; width: auto; } .btn-select-active { background: #e8f5e9; color: #2e7d5a; border: 1.5px solid #7ec6a4; border-radius: 10px; padding: 7px 14px; font-size: 13px; cursor: pointer; font-family: inherit; font-weight: 600; } .toolbar-row { - display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; + display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; +} +.search-compact { + flex: 0 1 160px; min-width: 100px; padding: 2px 8px; + background: #f8f7f5; border: 1.5px solid #e5e4e7; border-radius: 10px; + display: flex; align-items: center; +} +.search-compact .search-input { border: none; background: transparent; padding: 6px 4px; font-size: 13px; outline: none; width: 100%; font-family: inherit; } +.detail-close-btn { + border: none; background: #f0eeeb; width: 26px; height: 26px; border-radius: 50%; + cursor: pointer; font-size: 13px; display: flex; align-items: center; justify-content: center; color: #6b6375; } .select-count { font-size: 12px; color: #4a9d7e; font-weight: 500; white-space: nowrap; } .batch-menu { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }