FEAT-4: sync inbreeding DTO to FEAT-1b InbreedingResult + anchor root card left so parents are visible on phone at load
Verified end-to-end against a DATA-2-contract mock (5-gen family, shared ancestor): phone/desktop, re-root, lazy expand, zoom/fit, print Ahnentafel, 404 state. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -174,13 +174,14 @@ export default function StammbaumPage() {
|
||||
return () => observer.disconnect()
|
||||
}, [hasRoot])
|
||||
|
||||
/* ── Ansicht (Zoom/Position): Wurzelkarte beim Laden zentriert ── */
|
||||
/* ── Ansicht (Zoom/Position): Wurzelkarte links, vertikal zentriert —
|
||||
so sind die Eltern auch auf dem Smartphone sofort sichtbar. ── */
|
||||
const defaultView = useMemo<View | null>(() => {
|
||||
if (!size) return null
|
||||
const zoom = size.w < 520 ? 0.8 : 1
|
||||
return {
|
||||
zoom,
|
||||
translate: { x: Math.min(size.w / 2, CARD_W * zoom + 48), y: size.h / 2 },
|
||||
translate: { x: (CARD_W / 2) * zoom + 24, y: size.h / 2 },
|
||||
}
|
||||
}, [size])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user