Modell (Rust, gen:types, KNOWN_KEYS): Project.designOptionSets (Sätze mit Varianten und
Hauptvariante), designOption {set, option} an Wand, Öffnung, Decke, Dach, Treppe, Stütze,
Körper, Raum und 2D-Element (samt Bibliotheksobjekt); Kombination designOptions an
DrawingLevel, ViewTemplate, ViewSnapshot und LayoutViewport.
Keine zweite Sichtbarkeitslogik: die Kombination gehört zur renovation::View ([271]);
View::with/for_level lösen sie auf (Hauptvarianten, gespeicherte Wahl, Anfrage
„Dachform=B,…“), View::resolve blendet Elemente anderer Varianten aus wie Ausgeblendetes des
Umbaufilters. Ohne Elemente in Varianten bleibt alles wie vorher (Goldens unverändert).
Wirkt in Grundriss (Ctx.hidden, 2D über on_floor), Schnitt, Ansicht, Axo, 3D (ohne
Teil-Cache), Kennzahlen, Kosten, Baurecht, Raumbuch, IFC/Netz-Exporte, DXF und Blatt/PDF
(Viewport-Kombination mit Titelzusatz).
Kern design_options.rs: Übernehmen, Satz/Variante löschen, Zuweisen, In Variante kopieren
(je ein Undo-Schritt), Zeichen-Variante neuer Elemente (stamp_ops), Vergleich der Kennzahlen
und Kosten je Kombination (+ CSV). Oberfläche: Dock-Panel „Varianten“, Chip in der
Statusleiste (öffnet das Panel, Überlauf „⋯“), Objekt-Info „Variante“, Ressourcen-Tab,
Befehle variante/variantekopieren, Varianten-Vergleich in der Flächenbilanz, Viewport-Wahl
im Blatt, Vorlage „Beispiel Varianten“ (CLI :varianten), CLI --options und designoptions.
Tests: Kern design_options_tests.rs (13: Kombination, Grundriss/Schnitt/Ansicht/3D/Axo/IFC je
Kombination, mit Umbaufilter, Kennzahlen/Kosten, Übernehmen+Undo, Löschen, Zuweisen/Kopieren,
Zeichen-Variante, Viewport, Unsinn), Robustheit, vitest designOptions.test.ts und
designOption.test.ts, e2e designOptions272.spec.ts (2× grün, Port 5195). Bilder
doc/review-272 (CLI-SVG --hatch in Chromium, App). Nur im Linux-Container geprüft, nicht in
der Tauri-App/auf dem Mac (Prüfschritt RELEASE-1.0 13.38). Offen: TODO [272].
134 lines
3.5 KiB
TypeScript
134 lines
3.5 KiB
TypeScript
// Tab-Symbole der eingebauten Dock-Panels.
|
||
//
|
||
// Gleiche Konvention wie ToolIcon (ToolsPanel.tsx) und EyeIcon (ui/EyeIcon.tsx):
|
||
// schlichte Inline-SVG-Glyphen, ~16×16, stroke=currentColor, damit das Icon die
|
||
// Textfarbe des Tabs (inaktiv/hover/aktiv) übernimmt. Keine echten Asset-Icons
|
||
// vorhanden — daher hier je Panel eine eigene kleine Glyphe.
|
||
//
|
||
// Bezeichner englisch, Kommentare deutsch (CONVENTIONS.md).
|
||
|
||
const common = {
|
||
width: 16,
|
||
height: 16,
|
||
viewBox: "0 0 16 16",
|
||
fill: "none",
|
||
stroke: "currentColor",
|
||
strokeWidth: 1.4,
|
||
strokeLinecap: "round" as const,
|
||
strokeLinejoin: "round" as const,
|
||
"aria-hidden": true,
|
||
focusable: false,
|
||
};
|
||
|
||
/** Werkzeuge — Palette (2×2-Raster). */
|
||
export function ToolsTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<rect x="2" y="2" width="5" height="5" />
|
||
<rect x="9" y="2" width="5" height="5" />
|
||
<rect x="2" y="9" width="5" height="5" />
|
||
<rect x="9" y="9" width="5" height="5" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Attribute — Federkiel (Stift/Füllung/Strichstärke der Auswahl). */
|
||
export function AttributesTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<path d="M12.5 2.5 L14 4 L6 12 L3 13 L4 10 Z" />
|
||
<line x1="9.5" y1="5.5" x2="11.5" y2="7.5" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Objekt-Info — umkreistes „i". */
|
||
export function ObjectInfoTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<circle cx="8" cy="8" r="6" />
|
||
<line x1="8" y1="7" x2="8" y2="11.2" />
|
||
<circle cx="8" cy="4.8" r="0.15" fill="currentColor" stroke="none" />
|
||
<circle cx="8" cy="4.8" r="0.7" fill="currentColor" stroke="none" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Zeichnungsebenen — gestapelte Geschosse (drei Bodenplatten). */
|
||
export function DrawingLevelsTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<line x1="2" y1="3" x2="14" y2="3" />
|
||
<line x1="2" y1="8" x2="14" y2="8" />
|
||
<line x1="2" y1="13" x2="14" y2="13" />
|
||
<line x1="4" y1="3" x2="4" y2="8" />
|
||
<line x1="12" y1="8" x2="12" y2="13" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Ebenen — überlappende Kategorie-Blätter. */
|
||
export function LayersTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<path d="M8 2.5 13.5 5.5 8 8.5 2.5 5.5 Z" />
|
||
<path d="M2.5 8.5 8 11.5 13.5 8.5" />
|
||
<path d="M2.5 11 8 14 13.5 11" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Gelände — Höhenlinien/Terrain. */
|
||
export function SiteTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<path d="M1.5 12.5 5 6 7.5 10 10 5.5 14.5 12.5 Z" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Flächenbilanz — Balken unterschiedlicher Höhe (SIA-416-Auswertung). */
|
||
export function RoomBalanceTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<line x1="3" y1="13.5" x2="3" y2="7" />
|
||
<line x1="8" y1="13.5" x2="8" y2="2.5" />
|
||
<line x1="13" y1="13.5" x2="13" y2="9.5" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** [272] Varianten — Verzweigung in zwei Äste (A/B). */
|
||
export function DesignOptionsTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<path d="M8 14V8" />
|
||
<path d="M8 8L3.5 3.5" />
|
||
<path d="M8 8l4.5-4.5" />
|
||
<circle cx="3.5" cy="3" r="1.2" />
|
||
<circle cx="12.5" cy="3" r="1.2" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** Verlauf — Uhr mit Rückwärtspfeil. */
|
||
export function HistoryTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<path d="M2.5 8a5.5 5.5 0 1 0 1.8-4.1" />
|
||
<path d="M2.5 2.5v3h3" />
|
||
<path d="M8 5v3.2l2 1.3" />
|
||
</svg>
|
||
);
|
||
}
|
||
|
||
/** BCF-Themen — Sprechblase mit Haken (Koordinations-Thema). */
|
||
export function BcfTabIcon() {
|
||
return (
|
||
<svg {...common}>
|
||
<path d="M2.5 3.5h11v7h-6l-3 2.5v-2.5h-2z" />
|
||
<path d="M5.5 7l1.6 1.6L10.5 5.5" />
|
||
</svg>
|
||
);
|
||
}
|