Tree view: center a person between multiple spouses #37

Merged
justin merged 1 commits from center-spouse-layout into main 2026-06-08 19:56:59 -04:00
Owner

Patches family-chart 0.9.0 (via patch-package) so a person with two spouses renders centered between them (spouse 1 above, spouse 2 below) with each couple's children descending from the correct pair — instead of both spouses stacking on one side with ambiguous child lines.

  • setupSpouses: keep the person centered, split spouses to alternating sides, recenter the cluster.
  • sortChildrenWithSpouses: order children by spouse order (gender-independent) to match.
  • Adds patch-package + postinstall, and COPY patches in the Dockerfile deps stage so it applies in CI.

Verified: patch re-applies on a clean install; next build passes; positions confirmed via a headless render of a Beatrice-shaped case.

🤖 Generated with Claude Code

Patches family-chart 0.9.0 (via patch-package) so a person with two spouses renders **centered between them** (spouse 1 above, spouse 2 below) with each couple's children descending from the correct pair — instead of both spouses stacking on one side with ambiguous child lines. - `setupSpouses`: keep the person centered, split spouses to alternating sides, recenter the cluster. - `sortChildrenWithSpouses`: order children by spouse order (gender-independent) to match. - Adds `patch-package` + postinstall, and `COPY patches` in the Dockerfile deps stage so it applies in CI. Verified: patch re-applies on a clean install; `next build` passes; positions confirmed via a headless render of a Beatrice-shaped case. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
justin added 1 commit 2026-06-08 19:56:34 -04:00
family-chart 0.9.0 stacks all of a person's spouses on one gender-determined
side, so someone with two spouses (e.g. a woman with two husbands) renders
with both spouses piled above/below her and ambiguous child lines.

Patch the library (via patch-package) so the person stays centered and their
spouses split to alternating sides — spouse 1 above, spouse 2 below, further
spouses farther out — and order each couple's children to match, so children
descend from between the correct pair without crossed lines:

- setupSpouses: keep the person centered; place spouses at alternating
  offsets and recenter the cluster on the person's slot.
- sortChildrenWithSpouses: order children by spouse order (gender-independent)
  to match the new spouse positions.

Adds patch-package + a postinstall hook, and COPY patches into the Dockerfile
deps stage so the patch applies during `npm ci` in CI. Verified the patch
re-applies on a clean install and the production build passes.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Signed-off-by: Justin Paul <justin@jpaul.me>
justin merged commit ac0b9818dd into main 2026-06-08 19:56:59 -04:00
justin deleted branch center-spouse-layout 2026-06-08 19:57:00 -04:00
Sign in to join this conversation.