# Changelog

## v2.0.0 — MySQL e revisione collaborativa

- Migrato il dataset autorevole di produzione: 290 persone, 104 famiglie e 335 appartenenze, con confronto completo JSON ↔ MySQL senza differenze.
- Aggiunti account reviewer soggetti ad attivazione admin, conferme dell'intero nodo per revisione e ritiro della conferma.
- Aggiunte segnalazioni di errori, integrazioni, dubbi e fonti con storico, messaggi e moderazione amministrativa.
- Introdotti schema versionato, audit, import idempotente, export legacy e fallback JSON tramite `DATA_BACKEND`.
- Aggiunta la dashboard protetta per gestire reviewer e segnalazioni.

## v1.8.6 — Revisione in testo lineare

- Rimossi impaginazione a colonne, bordi e separatori grafici.
- Il documento di revisione usa ora una sola colonna di testo pulito con spaziatura minima tra le persone.

## v1.8.5 — Revisione compatta in PDF o Word

- Sostituiti riquadri e spazi estesi con un elenco tipografico compatto a due colonne.
- Ridotta ogni persona a poche righe con sigle D/G/P/F/N, ID e una sola riga di correzione.
- Aggiunto il download diretto del documento Word già impaginato; resta disponibile la stampa o il salvataggio PDF.

## v1.8.4 — Scheda pubblica di revisione

- Aggiunto `Revisione stampa` anche per gli utenti non ADMIN.
- Generato un documento A4 compatto dell'intero albero con ID univoci, relazioni, dati presenti, validazione per persona e righe per correzioni manoscritte.
- Esclusi dalla scheda i placeholder tecnici e i loro riferimenti.
- Aggiunte istruzioni uniformi per rendere le scansioni annotate facili da interpretare.

## v1.8.3 — Notebook riservato

- Aggiunta la sezione ADMIN `Notebook` per creare e gestire più pagine Markdown riservate.
- Ogni pagina ha un link casuale indipendente, una password cifrata e un promemoria destinatari privato.
- Aggiunti anteprima, copia link, cambio password, rigenerazione link ed eliminazione pagina.
- Corretto l'inserimento della modalità ADMIN per non dipendere da una vecchia versione fissa di `app.js`.

## Release summaries

### v1.8 — Navigazione home e ripristino viste stabili

La serie v1.8 conclude la prova della vista genealogica Merge, poi rimossa integralmente, e rende il marchio FB FamilyTree un collegamento diretto alla home.

### v1.7 — Visualizzazione, controllo e condivisione

La serie v1.7 rende la vista Ultra più controllabile e leggibile: reset completo, gestione delle persone scollegate, sette generazioni regolabili, aree familiari separate, colori distinti per rapporti diretti e indiretti, documentazione visuale e link condivisibili centrati su una persona.

### v1.6 — Anelli, tooltip e sicurezza ADMIN

La serie v1.6 espande Ultra a sette anelli più un perimetro esterno, migliora tooltip e note, consolida gli strumenti amministrativi e introduce autenticazione server-side per ADMIN, Merge e operazioni di importazione.

### v1.5 — Percorsi e componenti familiari

La serie v1.5 introduce il percorso genealogico minimo tra due persone, i filtri tra albero principale e gruppi scollegati e correzioni alla disposizione locale di discendenti, fratelli e coppie.

### v1.4 — Analisi, Merge e controlli avanzati

La serie v1.4 aggiunge Merge JSON incrementale, filtro temporale, evidenziazione dei rapporti, collegamenti tra fratelli, controlli compatti e miglioramenti alla leggibilità del focus e delle linee.

### v1.3 — Focus, selezione e istruzioni

La serie v1.3 separa il focus grafico dalla persona in modifica, migliora il centraggio della vista Ultra e introduce istruzioni pubbliche dedicate alla consultazione dell'albero.

### v1.2 — Ultra come vista principale

La serie v1.2 rende Ultra la vista predefinita, aggiunge ricerca e gestione del pannello editor, mantiene le coppie sullo stesso livello e introduce modifiche pendenti con salvataggio esplicito.

### v1.1 — Fondamenti del grafo Ultra

La serie v1.1 costruisce la visualizzazione radiale Ultra con nodi trascinabili, coppie compatte, colori di ramo, anelli di distanza, collegamenti curvi e focus centrale.

### v1.0 — Modello dati stabile

La serie v1.0 migra il progetto al formato piatto `people` e `families`, centralizza gli indici genealogici, aggiunge validazione rigorosa degli import e gestisce date stimate e placeholder.

### v0.9 — Viste Dynamic e Timeline

La serie v0.9 sviluppa le viste Dynamic e Timeline, migliora coppie, genitori, fratelli e discendenti e consolida i controlli dell'editor e dei rami.

### v0.8 — Prima applicazione condivisa

La serie v0.8 stabilisce le funzioni iniziali: albero navigabile, salvataggio degli import, modalità pubblica in sola lettura, editor, date confermate o stimate, documentazione tecnica e prime viste alternative.

## Detailed release history

## v1.8.2 - 2026-07-18

- Removed the experimental Merge visualization, its toolbar commands, layout code, and styles.
- Made the `FB FamilyTree` header brand a direct link to `index.html`.

## v1.8.1 - 2026-07-18

- Added a permanent `Vista Merge` button to the main toolbar so the rectangular couple-node view cannot be confused with Ultra.
- Added an explicit active-state label and one-click return to Ultra.

## v1.8.0 - 2026-07-18

- Added the Merge view as an evolution of Ultra without changing the existing visualizations.
- Combined partners into a single two-person node while preserving individual selection and editing.
- Added chronological generation bands with parents above children, sibling grouping, curved ancestry connectors, and collision spacing.
- Added direct loading through `?view=merge` for testing and shareable view links.

## v1.7.7 - 2026-07-18

- Added summary paragraphs for every functional release series from v0.8 through v1.7.
- Added a browser-readable changelog page that renders `CHANGELOG.md` as the single maintained source.
- Changed the application header Changelog link from raw Markdown to the rendered HTML page.

## v1.7.6 - 2026-07-18

- Added public person deep links using the stable `?person=<id>` URL parameter.
- Opening a shared person link now starts Ultra view centered on that person.
- Added an always-visible `Copia link` button and automatic URL updates after search or focus changes.

## v1.7.5 - 2026-07-18

- Added a unified `Regole visualizzazione` reference page linked from both the public and ADMIN headers.
- Documented focus, rings, generation slider, family areas, direct and indirect colors, links, tooltips, disconnected people, reset behavior, and alternate views.

## v1.7.4 - 2026-07-18

- Distinguished direct first-degree people from indirect relationships in Ultra view.
- Kept the branch hue while lightening in-laws and other indirect people, including a spouse's siblings and children's spouses.
- Preserved full-strength colors for focus, partners, parents, children, and siblings.

## v1.7.3 - 2026-07-18

- Reworked Ultra relationship placement to match the supplied visual reference: parents on the upper arc, siblings on the two side arcs, and children on the lower arc.
- Replaced horizontal dashed dividers with four solid white diagonal gaps that cut only the visible colored rings.
- Kept relationship lines above the white ring gaps so family connections remain readable.

## v1.7.2 - 2026-07-18

- Added an always-visible generation slider from 1 to 7 for validating the Ultra layout incrementally.
- Limited nodes, relationship lines, and colored rings to the selected depth; choosing 2 now shows only the focus and rings 1–2.
- Hid unrelated outer components while using a reduced generation limit; they remain available through the explicit disconnected filter.

## v1.7.1 - 2026-07-18

- Replaced the experimental angular wedges with three strict horizontal relationship bands.
- Reserved the upper band for parents and ancestors, the center band for same-generation relatives, and the lower band for children and descendants.
- Added two visible horizontal separators across the seven family rings.

## v1.7.0 - 2026-07-18

- Changed `Reset albero` into a complete reset of focus, filters, shortest-path state, dragged positions, layout mode, zoom, and pan.
- Fixed unanchored and disconnected people sharing the same angle by distributing their family units around the complete eighth perimeter.
- Made the eighth perimeter expand according to the disconnected population and automatically fit the complete overview into the viewport.
- Changed the disconnected-only view into an overview with no arbitrary central person; double-clicking a person then focuses that person's local component.
- Introduced a three-sector Ultra experiment: ancestors above, descendants below, and same-generation relatives in the lateral middle sectors.

## v1.6.3 - 2026-07-18

- Documented that the public interface always renders the latest live `data/family.json` and never exposes the technical JSON directly to users.
- Clarified the roles of the live dataset, archived imports, and the separate development copy.
- Documented why publishing application files must not overwrite newer data imported through ADMIN.

## v1.6.2 - 2026-07-18

- Added server-side session authentication for ADMIN with credentials stored in an external editable environment file.
- Protected the ADMIN page, Merge page, import saving, and latest-import endpoint behind the same login.
- Changed `Esci da ADMIN` to terminate the ADMIN session before returning to the public tree.

## v1.6.1 - 2026-07-18

- Moved `Reset albero` into the always-visible top controls.
- Constrained Ultra tooltip notes to a wrapping 320px panel that expands vertically after two seconds without overflowing.
- Renamed ADMIN reading mode to `Anteprima lettura` and the public-page link to `Esci da ADMIN` to clarify that they have different effects.
- Consolidated editor opening, JSON import/export, and Merge JSON into one consistent `Strumenti ADMIN` group.

## v1.6.0 - 2026-07-18

- Expanded the Ultra layout to seven distinct colored family rings.
- Moved people disconnected from the focused family component onto a separate outer perimeter so they no longer overlap.
- Added a dedicated `Reset albero` button that restores automatically calculated node positions and resets pan/zoom.
- Added an asterisk to Ultra tooltips for estimated dates and delayed light-blue notes until one second of continuous hover or keyboard focus.
- Refreshed the displayed version and browser asset cache keys.

## v1.5.2 - 2026-07-17

- Made the normal tree page permanently read-only and moved editing, Import, Export, and Merge access into the dedicated ADMIN mode.
- Split user instructions from ADMIN/Merge instructions and documented date filters, connected-component filters, hover highlighting, and shortest paths.
- Preserved the Ultra descendant branch-locality correction introduced during this release.

## v1.5.1 - 2026-07-17

- Fixed Ultra descendant placement so children remain on the outer ring near their parent instead of being shifted into a distant graph sector.
- Changed outer-ring spreading to organize sibling/couple units locally around their direct branch anchor.

## v1.5.0 - 2026-07-17

- Added a shortest-relationship-path mode that accepts two person clicks and finds the minimum-step family connection.
- Added directional relationship labels for parent, child, partner, and sibling steps, with persistent path highlighting in Ultra view and person highlighting in every view.

## v1.4.9 - 2026-07-17

- Added a three-state people filter for the main connected tree, disconnected groups/people, or everyone.
- Defined the main tree automatically as the largest connected relationship component in the complete dataset.

## v1.4.8 - 2026-07-17

- Added dashed, arrowless Ultra connectors between siblings.
- Hovering or keyboard-focusing a person now highlights all first-degree people and their direct relationship lines; parent-child arrowheads turn black for the duration of the highlight.

## v1.4.7 - 2026-07-17

- Moved the Controls button into the main top banner.
- Removed the empty local controls-bar space when mode, zoom, and timeframe controls are closed.

## v1.4.6 - 2026-07-17

- Increased background relationship-line visibility to a balanced medium contrast.
- Reduced Ultra relationship-circle spacing to provide more usable room.
- Collapsed mode, zoom, and timeframe controls by default behind a single Controls button.
- Reduced the selected-person title banner height by approximately half.

## v1.4.5 - 2026-07-17

- Made only the Ultra graph connections directly touching the centered person black and prominent.
- Faded all other relationship lines and arrowheads substantially into the background.

## v1.4.4 - 2026-07-17

- Moved the selected-person name and date watermark from the transformed Ultra canvas into a persistent visible overlay above the graph.
- Added fresh asset versioning so browsers immediately load the corrected display.

## v1.4.3 - 2026-07-17

- Enlarged the selected person's full name at the top of the Ultra view.
- Added the selected person's known or approximate date range as a large white background watermark.

## v1.4.2 - 2026-07-17

- Added complete Italian instructions for creating incremental Merge JSON files.
- Documented new people, new families, existing-family child additions, validation rules, examples, and the download workflow.

## v1.4.1 - 2026-07-17

- Added a non-destructive lifespan time filter to every tree view.
- People are shown when any part of their known lifespan overlaps the selected interval.
- People without usable dates remain visible to avoid hiding uncertain genealogy data.

## v1.4.0 - 2026-07-17

- Added a browser-only ADMIN merge page for incremental genealogy additions.
- Added strict validation for new people, new families, existing-family child additions, references, duplicate IDs, multiple parent families, and ancestry cycles.
- Added download of the validated merged full JSON without modifying the current server file.
- Added manual current-file selection for offline use and recovery scenarios.

## v1.3.3 - 2026-07-17

- Replaced the public Markdown instructions link with an HTML page declaring UTF-8 explicitly.
- Fixed corrupted accented Italian characters such as `è`, `attività`, and `più` in browsers.

## v1.3.2 - 2026-07-17

- Added a basic `Istruzioni` page beside the Changelog link.
- Documented search, navigation, double-click focus, pan/zoom, relationship circles, and offline correction reporting.
- Positioned the public workflow as read-oriented: users are asked to send corrections offline instead of editing the graph directly.

## v1.3.1 - 2026-07-17

- Fixed Ultradynamic centering to use the actually visible tree panel instead of the full oversized graph container.
- Kept the focused person centered in the visible area below the sticky toolbar when the right editor opens or closes.

## v1.3.0 - 2026-07-17

- Separated the Ultradynamic graph focus from the person currently selected for editing.
- Double-clicking a node now rebuilds all relationship circles around that person and centers the person exactly in the viewport.
- Right-clicking a node now opens the right editor for that person without changing the graph's central focus.
- Added a distinct editing highlight when the edited person differs from the centered graph focus.

## v1.2.1 - 2026-07-17

- Added a visible pending-change list to the right editor panel.
- Added an explicit `SAVE` command that persists UX edits to the server default JSON and clears the pending list after success.
- Consolidated repeated typing changes by person and field so the pending list remains readable.
- Corrected initial Ultradynamic positioning by centering through canvas translation without retaining outer-panel scroll offsets.

## v1.2.0 - 2026-07-17

- Made Ultradynamic the default view and renamed the previous views M1, M2, and M3.
- Changed spouse graph distance to zero so every couple stays together on the same relationship level, including Cristina Norcini and Alessandro.
- Kept the selected person and spouse as the central couple and centered the Ultradynamic canvas exactly on the selection.
- Added a compact person search field that selects, centers, and opens results in Ultradynamic view.
- Collapsed the right editor by default; it can be opened from the top and closed from its own panel button.
- Removed the redundant top `Chiudi` button and the `Ultimo import` button; the saved default JSON continues to load automatically.
- Renamed the application to `FB FamilyTree` and added a tree icon.

## v1.1.3 - 2026-07-17

- Moved the selected person's spouse into the center as a compact couple, immediately beside the selected node.
- Reduced the central spouse connection to a very short dashed link while keeping all other relatives on their relationship circles.

## v1.1.2 - 2026-07-17

- Changed Ultradynamic ring placement to organize partners as compact couple units.
- Anchored each outer couple toward its closest child or relative on the preceding inner ring, minimizing parent-to-child connector length.
- Added family-branch colors that propagate through related rings, with matching hues for parent-parent-child groups and progressively lighter shades at greater distances.
- Changed the three relationship guides from borders to filled concentric backgrounds, darkest at the center and progressively lighter outward.
- Kept brothers and sisters in the first relationship circle around the selected person.

## v1.1.1 - 2026-07-17

- Refined Ultradynamic refocusing so the selected person stays centered and the three relationship rings remain visible.
- Changed the graph canvas to white and faded people beyond the first three relationship rings.
- Replaced straight graph connections with live curved paths to reduce visual collisions.

## v1.1.0 - 2026-07-17

- Added an Ultradynamic graph view with every person represented by a colored circular initials node.
- Clicking a node refocuses the graph and arranges close relatives first, with ancestors above, siblings and partners at the same level, and descendants below.
- Added concentric distance levels for grandparents, grandchildren, nephews/nieces, and more distant relatives.
- Added draggable nodes with live edge updates, directed parent-to-child arrows, spouse links, and hover details with name, dates, and calculated age.

## v1.0.4 - 2026-07-16

- Missing birth dates are estimated during load/import when possible.
- Estimates use known parent years plus 30 years, or child years minus 30 years as fallback.
- Auto-filled dates are written as `ca. YYYY` and marked `dateStatus: estimated`, so validation popup counts include them.

## v1.0.3 - 2026-07-16

- Standard and Timeline views now automatically center the selected person after rendering, making selected branches such as Annalisa Norcini visible outside Dynamic mode.

## v1.0.2 - 2026-07-16

- Removed the in-page JSON preview/editor and the `Applica` JSON button.
- Import is now the only JSON loading path in the UI.
- Added an import validation popup aligned with `validate_family_tree.py`, showing counts, warnings, and errors before saving.
- Invalid imports are blocked and are not saved as the default JSON.

## v1.0.1 - 2026-07-16

- Importing a JSON file now also updates `data/family.json`, making the imported file the default loaded by the app.
- Updated the import success message to state that the file was saved and set as default.

## v1.0.0 - 2026-07-16

- Major release: migrated the application data model to flat JSON with top-level `people` and `families`.
- Added centralized relationship indexes for parent families, partner families, parents, partners, children, and siblings.
- Updated Standard, Timeline, Dynamic, relation summaries, import, export, and editor actions to use `families` instead of nested `genitori`, `coniuge`, and `figli` fields.
- Export now keeps the official flat format and no longer writes nested relationship fields into person records.
- Added validation for flat JSON references, duplicate IDs, partner cardinality, date status, and placeholder fields.
- Added visual placeholder styling.

## v0.9.8 - 2026-07-16

- Dynamic view now places siblings beside the selected person's couple instead of between parents and the selected person.

## v0.9.7 - 2026-07-16

- Timeline view now keeps spouses next to each other as a horizontal couple unit.
- Clicking a person in Timeline highlights partner, parents, and children with distinct labels and border colors.

## v0.9.6 - 2026-07-16

- Reworked Dynamic view around the selected person rather than around the enclosing couple.
- Selected-person parents now render as a compact parent couple above the selected card, with each parent's own parents shown above the correct parent column.
- Child couples now label the real child separately from the spouse, and connector alignment favors the child card.

## v0.9.5 - 2026-07-16

- Improved Dynamic view so selecting a person also keeps visible siblings from the same parent family.
- Dynamic view now renders grandchildren names under children instead of replacing them with only a descendant count.

## v0.9.4 - 2026-07-16

- Reassigned the top `Apri` and `Chiudi` buttons to open and close the right editor menu.
- Removed the extra `Menu dx` button from the tree toolbar to avoid duplicate right-menu controls.
- Left branch expand/collapse behavior on the per-node `+` and `-` buttons.

## v0.9.3 - 2026-07-16

- Published clearer branch controls: `Apri rami` and `Chiudi rami` now describe the Standard tree expand/collapse behavior.
- Added a dedicated right-menu toggle with `Nascondi` on the editor panel and `Menu dx` to reopen it.

## v0.9.2 - 2026-07-16

- Added a Dynamic tree view centered on the selected person.
- Dynamic view keeps spouses together and renders children directly below the parent couple to avoid ambiguous crossing lines.
- Added compact parent slots above each spouse in Dynamic view for local family inspection.

## v0.9.1 - 2026-07-16

- Fixed Timeline placement so descendants no longer drift into far-right generation columns.
- Timeline cards now use compact horizontal lanes only when nearby dates would overlap.

## v0.9.0 - 2026-07-15 12:10:48 UTC

- Added large faint decade labels in the Timeline background.
- Improved Timeline card placement so people with close dates use horizontal lanes instead of overlapping.

## v0.8.9 - 2026-07-15 12:00:00 UTC

- Refined Timeline connectors so parent-child links start and end at card edges and visibly span the vertical date distance between people.
- Added stronger Timeline parent-link styling so longer generational gaps are easier to read.

## v0.8.8 - 2026-07-15 11:49:46 UTC

- Added Standard/Timeline view switcher.
- Added Timeline view that positions people vertically by birth year, with younger people lower in the canvas.
- Added SVG relationship lines in Timeline view while keeping the existing Standard tree view unchanged.
- Disabled expand/collapse controls in Timeline view because the timeline always shows all dated people.

## v0.8.7 - 2026-07-15 11:24:46 UTC

- Added `dateStatus` support with `confirmed` and `estimated` values.
- Added a `Tipo data` selector in the person editor.
- Render estimated dates with amber card styling and a `stimata` badge.
- Added estimated-date totals to the header stats.
- Updated JSON format and project documentation for confirmed vs estimated dates.

## v0.8.6 - 2026-07-15 06:53:06 UTC

- Added `Ultimo import` button to load the latest saved JSON import from the VPS.
- Added `load_latest_import.php` endpoint, returning only the newest valid JSON file from `/var/www/family-tree-imports/`.
- Hid the latest-import loader in locked readonly mode.
- Updated displayed UI version to `v0.8.6`.

## v0.8.5 - 2026-07-15 06:51:46 UTC

- Added `PROJECT_OVERVIEW.md` with overall project description, architecture, URLs, data model, rendering rules, import saving, deployment notes, and known constraints.
- Updated displayed UI version to `v0.8.5`.

## v0.8.4 - 2026-07-15 06:48:53 UTC

- Added independent horizontal parent lanes for spouse couples.
- Couples with parents above either spouse now reserve separate ancestor columns, preventing parent/ancestor branches from colliding above attached spouses.
- Kept the couple box scoped to the two spouse cards while allowing enough space above each spouse for its own ancestry.

## v0.8.3 - 2026-07-15 06:43:03 UTC

- Fixed couple-box rendering so the box contains only the couple cards.
- Separated parent groups into their own slots above each spouse.
- Prevented parent boxes and couple boxes from visually merging into one large six-person box.

## v0.8.2 - 2026-07-15 06:40:25 UTC

- Added a visible `Changelog` link in the app header.
- Updated the displayed UI version to `v0.8.2`.
- Locked shared readonly pages (`?readonly=1`) so they no longer show an edit-mode button.

## v0.8.1 - 2026-07-15 06:39:16 UTC

- Fixed rendering for couples where both spouses have two parents.
- Parent nodes are now grouped in separate parent-couple boxes above each spouse, preventing four unrelated parent nodes from appearing as one combined group.
- Kept imported JSON format unchanged; this is a rendering fix.

## v0.8.0 - 2026-07-15 06:35:14 UTC

- Added server-side saving of imported JSON files to `/var/www/family-tree-imports/`.
- Added PHP endpoint `save_import.php` with JSON validation and file-size limit.
- Added public read-only mode via `?readonly=1`.
- Added pan and zoom controls for the tree.
- Added descendant counts per family group.
- Added right-side relationship summary for selected nodes.
- Allowed multiple disconnected root nodes without drawing false links between them.
- Added spouse/couple grouping with one descendant expand/collapse control.
- Added `Note` field.
- Removed role fields from the main UI and normalized JSON.
- Added shared JSON format documentation in `JSON_FORMAT.md`.

## Versioning Policy

- Every visible application change must increment the version.
- Every release must add a new dated entry to this changelog.
- The current version must be shown in the UI header.
