+
+
+ handleUpdate(
+ v === 'opening'
+ ? {
+ openingKind: v,
+ openingShape,
+ cornerRadius,
+ archHeight,
+ openingRevealRadius,
+ }
+ : { openingKind: v },
+ )
+ }
+ options={[
+ { label: 'Door', value: 'door' },
+ { label: 'Opening', value: 'opening' },
+ ]}
+ value={node.openingKind}
+ />
+
+
+
+
+
+ handleUpdate({
+ openingShape: v,
+ ...(v === 'rounded' ? { cornerRadius, openingRevealRadius } : {}),
+ ...(v === 'arch' ? { archHeight } : {}),
+ })
+ }
+ options={[
+ { label: 'Rect', value: 'rectangle' },
+ { label: 'Rounded', value: 'rounded' },
+ { label: 'Arch', value: 'arch' },
+ ]}
+ value={openingShape}
+ />
+
+ {openingShape === 'rounded' && (
+ <>
+ handleUpdate({ cornerRadius: v })}
+ precision={2}
+ step={0.05}
+ unit="m"
+ value={Math.round(cornerRadius * 100) / 100}
+ />
+ handleUpdate({ openingRevealRadius: v })}
+ precision={3}
+ step={0.005}
+ unit="m"
+ value={Math.round(openingRevealRadius * 1000) / 1000}
+ />
+ >
+ )}
+ {openingShape === 'arch' && (
+ handleUpdate({ archHeight: v })}
+ precision={2}
+ step={0.05}
+ unit="m"
+ value={Math.round(archHeight * 100) / 100}
+ />
+ )}
+
+ )}
+
+ {!isOpening && (
+ <>