TW5-Graph uses JSON to store its graph settings as such:
$:/config/flibbles/graph/nodes/stack/person
type: application/json
filter: [tag[person]]
{
"image": "$:/images/bootstrap/person-fill"
}
Is there a way to transclude tiddler fields inside those settings? I’m interested in applying a tag’s defined icon as the node’s icon, so the nodes for any tiddler tagged as person will automatically get the icon defined in the the person tiddler:
$:/config/flibbles/graph/nodes/stack/person
type: application/json
filter: [tag[person]]
{
"image": {{person!!icon}}
}
Or maybe the question could be, could TW5-Graph use regular tiddlers?
$:/config/flibbles/graph/nodes/stack/person
filter: [tag[person]]
image: {{person!!icon}}
My reason behind this is that in my Gifts notebook I’m using the following tags to define entities:
person
color: blue
icon: $:/images/bootstrap/person-fill
gift
color: red
icon: $:/images/bootstrap/gift-fill
I’m then using icon & color cascades to display the appropriate colored icon in front of every tiddler tagged as person or gift:
[tag[person]then{person!!color}]
I’d like to be able to use the same or similar logic to propagate values from tag tiddlers to graph node settings.
