diff --git a/frontend/src/components/PlaceholderPicker.jsx b/frontend/src/components/PlaceholderPicker.jsx index d143966..837f3fd 100644 --- a/frontend/src/components/PlaceholderPicker.jsx +++ b/frontend/src/components/PlaceholderPicker.jsx @@ -196,13 +196,8 @@ export default function PlaceholderPicker({ onSelect, onClose }) { e.currentTarget.style.background = 'var(--surface2)' }} > -
-
+
+
{item.example && (
+ Beispiel: {item.example}
)} diff --git a/frontend/src/pages/Analysis.jsx b/frontend/src/pages/Analysis.jsx index f203294..3f7d1b0 100644 --- a/frontend/src/pages/Analysis.jsx +++ b/frontend/src/pages/Analysis.jsx @@ -1,5 +1,5 @@ import { useState, useEffect } from 'react' -import { Brain, Pencil, Trash2, ChevronDown, ChevronUp, Check, X } from 'lucide-react' +import { Brain, Trash2, ChevronDown, ChevronUp } from 'lucide-react' import { api } from '../utils/api' import { useAuth } from '../context/AuthContext' import Markdown from '../utils/Markdown' @@ -8,19 +8,9 @@ import dayjs from 'dayjs' import 'dayjs/locale/de' dayjs.locale('de') +// Legacy fallback labels (display_name takes precedence) const SLUG_LABELS = { - gesamt: '🔍 Gesamtanalyse', - koerper: '🫧 Körperkomposition', - ernaehrung: '🍽️ Ernährung', - aktivitaet: '🏋️ Aktivität', - gesundheit: '❤️ Gesundheitsindikatoren', - ziele: '🎯 Zielfortschritt', - pipeline: '🔬 Mehrstufige Gesamtanalyse', - pipeline_body: '🔬 Pipeline: Körper-Analyse (JSON)', - pipeline_nutrition: '🔬 Pipeline: Ernährungs-Analyse (JSON)', - pipeline_activity: '🔬 Pipeline: Aktivitäts-Analyse (JSON)', - pipeline_synthesis: '🔬 Pipeline: Synthese', - pipeline_goals: '🔬 Pipeline: Zielabgleich', + pipeline: '🔬 Mehrstufige Gesamtanalyse' } function InsightCard({ ins, onDelete, defaultOpen=false, prompts=[] }) { @@ -53,78 +43,16 @@ function InsightCard({ ins, onDelete, defaultOpen=false, prompts=[] }) { ) } -function PromptEditor({ prompt, onSave, onCancel }) { - const [template, setTemplate] = useState(prompt.template) - const [name, setName] = useState(prompt.name) - const [desc, setDesc] = useState(prompt.description||'') - - const VARS = ['{{name}}','{{geschlecht}}','{{height}}','{{goal_weight}}','{{goal_bf_pct}}', - '{{weight_trend}}','{{weight_aktuell}}','{{kf_aktuell}}','{{caliper_summary}}', - '{{circ_summary}}','{{nutrition_summary}}','{{nutrition_detail}}', - '{{protein_ziel_low}}','{{protein_ziel_high}}','{{activity_summary}}', - '{{activity_kcal_summary}}','{{activity_detail}}', - '{{sleep_summary}}','{{sleep_detail}}','{{sleep_avg_duration}}','{{sleep_avg_quality}}', - '{{rest_days_summary}}','{{rest_days_count}}','{{rest_days_types}}', - '{{vitals_summary}}','{{vitals_detail}}','{{vitals_avg_hr}}','{{vitals_avg_hrv}}', - '{{vitals_avg_bp}}','{{vitals_vo2_max}}','{{bp_summary}}'] - - return ( -
-
-
Prompt bearbeiten
- -
-
- - setName(e.target.value)}/> - -
-
- - setDesc(e.target.value)}/> - -
-
-
- Variablen (antippen zum EinfĂĽgen): -
-
- {VARS.map(v=>( - - ))} -
-
-