diff --git a/frontend/src/views/RecipeManager.vue b/frontend/src/views/RecipeManager.vue index 67444ae..c2b9fa7 100644 --- a/frontend/src/views/RecipeManager.vue +++ b/frontend/src/views/RecipeManager.vue @@ -213,6 +213,16 @@ ml +
+ 参考比例 1: +
+ +
+ 纯精油约 {{ suggestedEoDrops }} 滴 +
@@ -418,6 +428,15 @@ const cocoActualDrops = computed(() => { const cocoFillMl = computed(() => Math.round(cocoActualDrops.value / DROPS_PER_ML)) +const suggestedEoDrops = computed(() => { + if (formVolume.value === 'single') { + const cocoDrops = formCocoRow.value ? (formCocoRow.value.drops || 10) : 10 + return Math.round(cocoDrops / formDilution.value) + } + const total = targetTotalDrops.value || 0 + return Math.round(total / (1 + formDilution.value)) +}) + const recipeSummaryText = computed(() => { const eo = eoTotalDrops.value const coco = cocoActualDrops.value @@ -1495,6 +1514,17 @@ watch(() => recipeStore.recipes, () => { .volume-btn.active { background: #e8f5e9; border-color: #7ec6a4; color: #2e7d5a; font-weight: 600; } .volume-btn:hover { border-color: #7ec6a4; } .custom-volume-row { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; } +.ratio-row { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; } +.ratio-label { font-size: 12px; color: #3e3a44; font-weight: 500; white-space: nowrap; } +.ratio-options { display: flex; gap: 4px; flex-wrap: wrap; } +.ratio-btn { + padding: 3px 8px; border: 1px solid #e5e4e7; border-radius: 6px; background: #fff; + font-size: 11px; cursor: pointer; font-family: inherit; color: #6b6375; min-width: 28px; text-align: center; +} +.ratio-btn.active { background: #e8f5e9; border-color: #7ec6a4; color: #2e7d5a; font-weight: 600; } +.ratio-btn:hover { border-color: #7ec6a4; } +.ratio-hint { font-size: 12px; color: #4a9d7e; font-weight: 500; white-space: nowrap; } + .coco-row { background: #f8faf8; } .coco-label { font-weight: 600; color: #4a9d7e; font-size: 13px; } .coco-fill { font-size: 12px; color: #4a9d7e; font-weight: 500; }