gramps-project / gramps-web

Frontend for Gramps Web
https://www.grampsweb.org
GNU Affero General Public License v3.0
336 stars 48 forks source link

Topola Viewer integration (#347) #414

Open PeWu opened 3 months ago

PeWu commented 3 months ago

Topola Viewer is integrated as follows:

Here are some ideas how to move forward:

  1. [recommended] Implement fetching only relevant data through the Gramps Web API instead of fetching the whole GEDCOM. This would have to be mostly implemented on the Topola Viewer side with some plumbing in GrampsjsViewTopola.

  2. [possible] Instead of showing an iframe, the user could be redirected to a new tab showing Topola Viewer with data from Gramps Web. On one hand, we avoid the combination of 2 apps that have a different look and feel but on the other hand, the integration is far from being seamless.

  3. [possible but more effort required] To avoid iframes, we'd have to use the https://github.com/PeWu/topola library directly in Gramps Web. The topola library is responsible for rendering the family tree and doing animations while the Topola Viewer is essentially a rich wrapper around the topola library providing the menu, loading data, showing individual details and settings. Using the topola library directly would mean reimplementing some parts of Topola Viewer in Gramps Web. This way, the topola chart could be added as another option in the "Family Tree" view.

DavidMStraub commented 3 months ago

Cool, thanks a lot! In principle 3 would be the best option, but we could opt for a staged approach as well. I'll review this version in the next days. :+1: