Merge branch 'worktree-agent-a0efa41aca12320a1' into claude/practical-noether-1hb2s1

# Conflicts:
#	TODO.md
This commit is contained in:
Claude committed 2026-11-07 00:17:44 +00:00
commit 5d5308aed5
46 files changed
+1976 -336

No files matched your search

+3
View File
@@ -428,6 +428,8 @@ export interface ProjectSlice {
// ── Treppen-Editieren ──────────────────────────────────────────────────────
/** Verschiebt eine Treppe (Antritt) um `delta`. */
moveStairBy: (stairId: string, delta: Vec2) => void;
/** [151] Parameter-Griff `index` einer Podesttreppe nach `pt` ziehen (Kern `stairParam`). */
dragStairParam: (stairId: string, index: number, pt: Vec2) => void;
/** Generischer immutabler Patch auf eine Treppe (per ID). */
updateStair: (
id: string,
@@ -1277,6 +1279,7 @@ export function createProjectSlice(
// ── Treppen-Editieren ──────────────────────────────────────────────────
// (coalesceKey: siehe Kommentar bei moveGripOf.)
moveStairBy: (stairId, delta) => applyGrip({ op: "stairBy", id: stairId, delta: gripPt(delta) }, `moveStairBy:${stairId}`),
dragStairParam: (stairId, index, pt) => applyGrip({ op: "stairParam", id: stairId, index, pt: gripPt(pt) }, `dragStairParam:${stairId}:${index}`),
updateStair: (id, patch) =>
applyChange((p) => mapStair(p, id, (s) => ({ ...s, ...patch }))),
+13 -1
View File
@@ -271,6 +271,18 @@ export interface StairInfo {
referenz?: "links" | "mitte" | "rechts";
/** Nur Wendel: Radius der Mittelsäule (Meter); fehlt → keine Säule. */
centerColumn?: number;
/** Länge des (ersten) Laufs (Meter). */
runLength?: number;
/** [151] L / U / gerade mit Podest: Länge des zweiten bzw. letzten Laufs; Drehsinn (+1 links, −1 rechts). */
run2Length?: number;
turn?: 1 | -1;
/** [151] U: Treppenauge; U / gerade mit Podest: Podesttiefe (Meter). */
gap?: number;
landingLength?: number;
/** [151] Steigungen im ersten Lauf (fehlt → nach Lauflängen), im Mittellauf (U), Versatz des Gegenlaufs (U). */
run1Steps?: number;
midSteps?: number;
run2Offset?: number;
/** Zugewiesener Treppentyp (Bibliothek, `Stair.typeId`) oder undefined. */
typeId?: string;
/** Geschoss, dem die Treppe zugeordnet ist. */
@@ -279,7 +291,7 @@ export interface StairInfo {
/** Aufgelöste absolute UK/OK (Meter). */
zBottom: number;
zTop: number;
/** Nur Ortbeton (gerade/Wendel): Betonvolumen des Laufs (m³, ohne Säule). */
/** Nur Ortbeton: Betonvolumen der Läufe (m³, ohne Säule und Podest). */
concreteVolume?: number;
/** Nur Ortbeton: Untersicht (m², Schalfläche; bei der Wendel die Wendelfläche). */
soffitArea?: number;
+9 -4
View File
@@ -25,6 +25,7 @@ import {
openingTypedPosition,
sheetHeightDrag,
stairMoveHandle,
stairParamPoints,
wallGripPoints,
type GripLocks,
} from "../core";
@@ -100,6 +101,8 @@ export function useGripEditing(opts: {
/** Wand ändern (Höhen-Griff im Schnitt); `coalesceKey` fasst einen Zug zu EINEM Undo-Schritt. */
updateWall: (id: string, patch: Partial<import("../model/types").Wall>, coalesceKey?: string) => void;
moveStairBy: (id: string, delta: Vec2) => void;
/** [151] Parameter-Griff einer Podesttreppe ziehen (Index ohne den Bewegpunkt). */
dragStairParam?: (id: string, index: number, pt: Vec2) => void;
moveRoomGrip: (id: string, index: number, pt: Vec2) => void;
moveCeilingGrip: (id: string, index: number, pt: Vec2) => void;
moveExcavationGrip: (id: string, index: number, pt: Vec2) => void;
@@ -298,9 +301,10 @@ export function useGripEditing(opts: {
if (selectedStairId && modelEditable) {
const st = (project.stairs ?? []).find((s) => s.id === selectedStairId);
if (!st) return [];
gripOwners.push({ localIndex: 0 });
gripOwnerRange.push([0, 0]);
return [stairMoveHandle(st)];
// [151] Podesttreppen: dazu die Parameter-Griffe (Lauf-Enden, Podestrand).
const pts = [stairMoveHandle(st), ...stairParamPoints(st)];
pts.forEach((_, i) => { gripOwners.push({ localIndex: i }); gripOwnerRange.push([0, pts.length - 1]); });
return pts;
}
if (selectedTree && modelEditable && !selectedTree.locked) {
const pts = treeGrips(selectedTree);
@@ -844,7 +848,8 @@ export function useGripEditing(opts: {
// sodass er nach dem Move exakt unter dem Cursor sitzt.
if (selectedStairId) {
const st = (project.stairs ?? []).find((s) => s.id === selectedStairId);
if (st) moveStairBy(st.id, sub(pt, stairMoveHandle(st)));
if (st && index > 0) opts.dragStairParam?.(st.id, index - 1, pt);
else if (st) moveStairBy(st.id, sub(pt, stairMoveHandle(st)));
return;
}
// [149] Baum: Stammmitte bzw. Kronenrand live, ein Undo-Schritt je Zug (gleicher coalesceKey).
+3
View File
@@ -1066,6 +1066,9 @@ export function usePanelHostBase(opts: {
onSetStairReferenz: (referenz) => {
if (selection?.kind === "stair") updateStair(selection.id, { referenz });
},
onSetStairPatch: (patch) => {
if (selection?.kind === "stair") updateStair(selection.id, patch);
},
// Typ-Zuweisung (Bibliothek): Treppentyp per typeId; leerer String löst die
// Zuweisung (Inline-Verhalten). Treibt u. a. die 3D-Tragart (massiv/offen).
onSetStairType: (typeId) => {
+2
View File
@@ -382,6 +382,7 @@ export function useProjectActions(
const setCeilingThickness = useStore((s) => s.setCeilingThickness);
const updateStair = useStore((s) => s.updateStair);
const moveStairBy = useStore((s) => s.moveStairBy);
const dragStairParam = useStore((s) => s.dragStairParam);
const updateRoom = useStore((s) => s.updateRoom);
const moveRoomBy = useStore((s) => s.moveRoomBy);
const moveRoomGrip = useStore((s) => s.moveRoomGrip);
@@ -501,6 +502,7 @@ export function useProjectActions(
setCeilingThickness,
updateStair,
moveStairBy,
dragStairParam,
updateRoom,
moveRoomBy,
moveRoomGrip,