Ansicht: Schnitt-Plan wieder memoisieren (kein Recompute je Render)

This commit is contained in:
2026-07-11 00:21:33 +02:00
parent a3a6b51db4
commit 61c2a48f52
+5 -5
View File
@@ -5001,11 +5001,11 @@ function SectionPlanView({
[isElevation, project, level, mono], [isElevation, project, level, mono],
); );
const plan = isElevation const sectionPlan = useMemo(
? elevationPlan () => (!isElevation && output ? generateSectionPlan(output, mono) : null),
: output [isElevation, output, mono],
? generateSectionPlan(output, mono) );
: null; const plan = isElevation ? elevationPlan : sectionPlan;
const effStatus = isElevation ? (elevationPlan ? "ready" : "empty") : status; const effStatus = isElevation ? (elevationPlan ? "ready" : "empty") : status;
const kindLabel = level.kind === "section" ? t("stub.section") : t("stub.elevation"); const kindLabel = level.kind === "section" ? t("stub.section") : t("stub.elevation");