[260] Typ-Feld „Im Grundriss“ im Fenster-/Türeditor (Objekt), gemeinsame Optionen mit den Ressourcen
This commit is contained in:
7 files changed
+102
-20
No files matched your search
@@ -0,0 +1,17 @@
|
||||
// [260] Auswahl „Im Grundriss“ für Fenster-/Türtypen: gemeinsam für die Ressourcen (Typ-Tabs) und den
|
||||
// Fenster-/Türeditor im Bereich „Objekt“ (eine Quelle für Werte und Texte).
|
||||
|
||||
import { t } from "../i18n";
|
||||
|
||||
export type OpeningPlanMode = "symbolisch" | "geschnitten";
|
||||
|
||||
/** Leer = wie Modelldarstellung (Vorgabe der Ansicht). */
|
||||
export function planModeOptions(): { value: "" | OpeningPlanMode; label: string }[] {
|
||||
return [
|
||||
{ value: "", label: t("objinfo.opening.planMode.fromModelView") },
|
||||
{ value: "symbolisch", label: t("objinfo.opening.planMode.symbolisch") },
|
||||
{ value: "geschnitten", label: t("objinfo.opening.planMode.geschnitten") },
|
||||
];
|
||||
}
|
||||
|
||||
export const planModeFromValue = (v: string): OpeningPlanMode | undefined => (v === "" ? undefined : (v as OpeningPlanMode));
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
import type { DoorType, Opening, Project } from "../../model/types";
|
||||
import { t } from "../../i18n";
|
||||
import { planModeFromValue, planModeOptions } from "../planModeOptions";
|
||||
import { FieldRow, NumberField, Segmented, SelectField } from "./fields";
|
||||
import { INSET_FACE_OPTIONS, TypeLibraryTab } from "./TypeLibraryTab";
|
||||
import { ElevationPreview } from "../ElevationPreview";
|
||||
@@ -187,12 +188,8 @@ export function DoorStylesTab({
|
||||
<FieldRow label={t("objinfo.opening.planMode")}>
|
||||
<SelectField
|
||||
value={door.planMode ?? ""}
|
||||
onChange={(v) => patch({ planMode: v === "" ? undefined : (v as "symbolisch" | "geschnitten") })}
|
||||
options={[
|
||||
{ value: "", label: t("objinfo.opening.planMode.fromModelView") },
|
||||
{ value: "symbolisch", label: t("objinfo.opening.planMode.symbolisch") },
|
||||
{ value: "geschnitten", label: t("objinfo.opening.planMode.geschnitten") },
|
||||
]}
|
||||
onChange={(v) => patch({ planMode: planModeFromValue(v) })}
|
||||
options={planModeOptions()}
|
||||
/>
|
||||
</FieldRow>
|
||||
<FieldRow label={t("resources.field.transomHeight")}>
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
import type { Opening, Project, WindowType } from "../../model/types";
|
||||
import { t } from "../../i18n";
|
||||
import { planModeFromValue, planModeOptions } from "../planModeOptions";
|
||||
import { FieldRow, NumberField, SelectField } from "./fields";
|
||||
import { INSET_FACE_OPTIONS, TypeLibraryTab } from "./TypeLibraryTab";
|
||||
import { ElevationPreview } from "../ElevationPreview";
|
||||
@@ -207,12 +208,8 @@ export function WindowStylesTab({
|
||||
<FieldRow label={t("objinfo.opening.planMode")}>
|
||||
<SelectField
|
||||
value={win.planMode ?? ""}
|
||||
onChange={(v) => patch({ planMode: v === "" ? undefined : (v as "symbolisch" | "geschnitten") })}
|
||||
options={[
|
||||
{ value: "", label: t("objinfo.opening.planMode.fromModelView") },
|
||||
{ value: "symbolisch", label: t("objinfo.opening.planMode.symbolisch") },
|
||||
{ value: "geschnitten", label: t("objinfo.opening.planMode.geschnitten") },
|
||||
]}
|
||||
onChange={(v) => patch({ planMode: planModeFromValue(v) })}
|
||||
options={planModeOptions()}
|
||||
/>
|
||||
</FieldRow>
|
||||
<FieldRow label={t("objinfo.opening.planSwingArcs")}>
|
||||
|
||||
Reference in new issue
Block a user