[WIDGET] Trilium Hexmap - A widget displaying fetched notes as places and people on top of a hex grid map #1639
-
UPDATE: this is still regularly updated and has been cleaned-up and made more easily configurable, check the repo and the README of that repo, link below. https://gitlab.com/MorganeLeCaignec/trilium-hexmap Hello there, In my quest to automate things and keep track of stuff for my tabletop campaign (the main reason I use Trilium!), i've made this frankly ridiculous widget that generates a hex grid (based on promoted attributes for max x/y size, start/end values of the range of coordinates to display, and hex size which is basically a zoom level), fetches Location notes with specific attributes (in my case hex coordinates, and an optional icon to be displayed on the hex map) and displays them at their proper coordinates with conditional colors (is the note TODO, is it empty, etc) and a clickable link. This seemed overkill at first but honestly it's incredibly useful, I can write and update my notes and just with a tiny bit of setting up for labels, it all shows up on this map with everything clear and easy to track! I've used it in-game already, tracking the player's movement and clicking on the link for the prepped hex note :) Had to figure out some math for the hex grid itself but that wasn't too hard, works super well. |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 13 replies
-
@QuentinLeCaignec Cheers |
Beta Was this translation helpful? Give feedback.
-
This will probably be the last update for now, but here's a new version, 1.2 : I added toggle attributes to shift the map layout to vertical/horizontal, and to odd/even shifting, which means this should now work with any type of hex grid! This took some work, but as far as I've tested it seems like it works without issue. I polished a few things like adding attribute declarations (even the non-promoted ones, more convenient to promote them if you need it), added a few "location types" icons in the CSS, added a black border to agent markers, tweaked some more CSS, updated the README. |
Beta Was this translation helpful? Give feedback.
-
Updated to 1.4 for trilium version 0.48.3, fixes the API breaking changes. |
Beta Was this translation helpful? Give feedback.
-
Updated to 1.5 for trilium 0.54.2, refactors/cleans up code, fixes some breaking changes for view centering, zoom buttons placement/working, and making the render drag-scrollable. |
Beta Was this translation helpful? Give feedback.
-
Updated to 1.7 for 0.62.4 ! |
Beta Was this translation helpful? Give feedback.
Updated to 1.7 for 0.62.4 !