From decc3414526f50f823997002aaa2301457320133 Mon Sep 17 00:00:00 2001 From: Kenneth Reitz Date: Sat, 29 Nov 2025 14:14:07 -0500 Subject: [PATCH] Display family tree statistics on overview page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add statistics table to family tree overview showing: - Total people (479) - Total generations (41) - Longest lived person (Adam - 930 years) - Person with most children (David - 19 children) - Average lifespan with data coverage - Fetch statistics from /api/family-tree/stats endpoint via JavaScript - Display loading state while fetching data - Clean table layout for better readability 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- kjvstudy_org/templates/family_tree.html | 77 +++++++++++++++++++++---- 1 file changed, 67 insertions(+), 10 deletions(-) diff --git a/kjvstudy_org/templates/family_tree.html b/kjvstudy_org/templates/family_tree.html index c18de5a..28a782b 100644 --- a/kjvstudy_org/templates/family_tree.html +++ b/kjvstudy_org/templates/family_tree.html @@ -160,17 +160,33 @@ section:nth-of-type(3) { {% if family_tree_data and generations %}

Overview

-
- {{ family_tree_data|length }} individuals recorded - {{ generations|length }} generations from Adam - {% set people_with_age = [] %} - {% for person_id, person in family_tree_data.items() %} - {% if person.age_at_death != "Unknown" and "years" in person.age_at_death %} - {% set _ = people_with_age.append(person) %} - {% endif %} - {% endfor %} - {{ people_with_age|length }} with recorded ages +
+

Loading statistics...

+ + + + + + + + + + + + + + + + + + + + + + + +
@@ -264,6 +280,47 @@ section:nth-of-type(3) {