From 6b89ad5bdbe7254e0b657edcf2943222e5bd3106 Mon Sep 17 00:00:00 2001 From: Karim Date: Sun, 12 Jul 2026 18:52:08 +0200 Subject: [PATCH] =?UTF-8?q?Fenster:=20Linienst=C3=A4rke/Farbe=20(sashLine)?= =?UTF-8?q?=20wirkt=20jetzt=20auch=20bei=201:100?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Die einzige bei "grob" sichtbare Glaslinie war fest codiert (weder Opening. color noch die neuen Kategorie-Übersteuerungen griffen dort). Nutzt jetzt sashLine (Fenster-Kategorie), konsistent mit mittel/fein. --- src/plan/generatePlan.ts | 13 ++++++++++++- src/plan/generatePlan.windowFields.test.ts | 11 +++++++++++ 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/src/plan/generatePlan.ts b/src/plan/generatePlan.ts index fbe924e..20c75b5 100644 --- a/src/plan/generatePlan.ts +++ b/src/plan/generatePlan.ts @@ -2265,9 +2265,20 @@ function addOpeningSymbol( if (detail === "grob") { // SIA 1:100 — nur eine dünne Glaslinie mittig über die weisse Öffnung. + // Zählt zur "Fenster"-Kategorie (sashLine) — dieselbe Glaslinie, die bei + // mittel/fein früher sichtbar war (jetzt dort entfernt, s. Fenster-Session). const g = sym.glassLines[Math.floor(sym.glassLines.length / 2)] ?? sym.glassLines[0]; if (g) { - out.push({ kind: "line", a: g[0], b: g[1], cls: "window-glass", weightMm: SYMBOL_HAIRLINE_MM, greyed, openingId: o.id }); + out.push({ + kind: "line", + a: g[0], + b: g[1], + cls: "window-glass", + weightMm: o.sashLine?.weight ?? SYMBOL_HAIRLINE_MM, + color: o.sashLine?.color ?? strokeColor, + greyed, + openingId: o.id, + }); } } else { // Linien-Kategorien einzeln übersteuerbar (Nutzer-Wunsch): Rahmen (Blend- diff --git a/src/plan/generatePlan.windowFields.test.ts b/src/plan/generatePlan.windowFields.test.ts index 70e689f..7c5bc70 100644 --- a/src/plan/generatePlan.windowFields.test.ts +++ b/src/plan/generatePlan.windowFields.test.ts @@ -389,6 +389,17 @@ describe("generatePlan — Linien-Übersteuerung je Kategorie (Opening.frameLine expect(sill[0].kind === "line" && sill[0].color).toBe("#0000ff"); expect(sill[0].kind === "line" && sill[0].weightMm).toBeCloseTo(0.4, 6); }); + + it("sashLine wirkt auch bei 'grob' (1:100) auf die einzige dort sichtbare Glaslinie", () => { + const p = project( + { ...baseWindow, typeId: "wt1", sashLine: { color: "#00ff00", weight: 0.3 } }, + [twoSashType], + ); + const g = linesOfClass(p, "window-glass", "grob"); + expect(g.length).toBe(1); + expect(g[0].kind === "line" && g[0].color).toBe("#00ff00"); + expect(g[0].kind === "line" && g[0].weightMm).toBeCloseTo(0.3, 6); + }); }); describe("generatePlan — Rollladenkasten shading (Item 3)", () => {