From 5e2ae9de311b613771f99a72fe7375cc88bad100 Mon Sep 17 00:00:00 2001 From: Lars Date: Fri, 10 Jul 2026 14:26:14 +0200 Subject: [PATCH] Mitai analysis-split Sub-Nav und weniger Blend-UI bei Auspraegungen. Modus-Subnav als linke Spalte (Plan/Kontrolle/Ausfuehren), Referenz-Auspraegungen aus Formularen entfernt, Hub-Karten auf Steuerung gestrichen. Co-authored-by: Cursor --- frontend/src/components/InitiativeForm.jsx | 68 +----- .../src/components/InitiativeNavCards.jsx | 60 ------ .../src/components/InitiativeSteeringMeta.jsx | 36 +--- .../src/components/MethodProfileSelect.jsx | 56 ----- frontend/src/components/ModeAreaNav.jsx | 63 ++++++ frontend/src/components/ModeAreaShell.jsx | 11 + frontend/src/components/ModeSubNav.jsx | 26 --- frontend/src/components/PlanOutlineNav.jsx | 52 +---- .../src/components/SteeringSnapshotPanel.jsx | 9 - frontend/src/config/controlNav.js | 24 +++ frontend/src/config/modeNav.test.js | 18 ++ frontend/src/config/workNav.js | 24 +++ .../initiative/InitiativeOverviewPage.jsx | 13 -- frontend/src/pages/modes/ControlLayout.jsx | 27 ++- frontend/src/pages/modes/PlanLayout.jsx | 12 +- frontend/src/pages/modes/PlanProfilePage.jsx | 13 -- frontend/src/pages/modes/WorkLayout.jsx | 22 +- frontend/src/styles/program-chrome.css | 199 +++++++++--------- 18 files changed, 293 insertions(+), 440 deletions(-) delete mode 100644 frontend/src/components/InitiativeNavCards.jsx delete mode 100644 frontend/src/components/MethodProfileSelect.jsx create mode 100644 frontend/src/components/ModeAreaNav.jsx create mode 100644 frontend/src/components/ModeAreaShell.jsx delete mode 100644 frontend/src/components/ModeSubNav.jsx create mode 100644 frontend/src/config/controlNav.js create mode 100644 frontend/src/config/modeNav.test.js create mode 100644 frontend/src/config/workNav.js diff --git a/frontend/src/components/InitiativeForm.jsx b/frontend/src/components/InitiativeForm.jsx index 515dc4d..37c8455 100644 --- a/frontend/src/components/InitiativeForm.jsx +++ b/frontend/src/components/InitiativeForm.jsx @@ -8,10 +8,7 @@ import { getInitiativeFields, listArchetypeFieldDefinitions, } from '../api/entityFields.js' -import { listSteeringMethods } from '../api/steering.js' -import { listMethodProfiles } from '../api/methodProfiles.js' import { FieldRenderer } from './FieldRenderer.jsx' -import { InitiativeSteeringMeta } from './InitiativeSteeringMeta.jsx' export function InitiativeForm({ initial = {}, @@ -26,42 +23,6 @@ export function InitiativeForm({ const [fieldDefinitions, setFieldDefinitions] = useState([]) const [dynamicValues, setDynamicValues] = useState({}) const [fieldsLoading, setFieldsLoading] = useState(false) - const [steeringMethods, setSteeringMethods] = useState([]) - const [methodProfiles, setMethodProfiles] = useState([]) - const [methodProfileKey, setMethodProfileKey] = useState('') - - useEffect(() => { - let cancelled = false - listSteeringMethods() - .then((items) => { - if (!cancelled) setSteeringMethods(Array.isArray(items) ? items : []) - }) - .catch(() => { - if (!cancelled) setSteeringMethods([]) - }) - return () => { - cancelled = true - } - }, []) - - useEffect(() => { - let cancelled = false - setMethodProfileKey('') - if (!archetypeKey) { - setMethodProfiles([]) - return undefined - } - listMethodProfiles(archetypeKey) - .then((items) => { - if (!cancelled) setMethodProfiles(Array.isArray(items) ? items : []) - }) - .catch(() => { - if (!cancelled) setMethodProfiles([]) - }) - return () => { - cancelled = true - } - }, [archetypeKey]) useEffect(() => { let cancelled = false @@ -130,7 +91,6 @@ export function InitiativeForm({ status: form.status.value, priority: form.priority.value, dynamicFields: dynamicValues, - ...(methodProfileKey ? { method_profile_key: methodProfileKey } : {}), }) } @@ -139,6 +99,7 @@ export function InitiativeForm({ } const formReady = archetypes && !fieldsLoading + const selectedArchetype = (archetypes || []).find((item) => item.key === archetypeKey) return (
@@ -160,31 +121,10 @@ export function InitiativeForm({ ))} + {selectedArchetype?.description && ( + {selectedArchetype.description} + )} - {methodProfiles.length > 0 && ( - - )} -