VladimirAlexiev / rdf2rml

RDF by Example: rdfpuml for True RDF Diagrams, rdf2rml for R2RML Generation
39 stars 5 forks source link

Add hyperlinks to diagram #16

Open johanwk opened 1 year ago

johanwk commented 1 year ago

With SVG output, PlantUML diagrams can contain links: https://plantuml.com/link

For nodes and edges, this could straightforward to add.

For inlined content with more than one URI, probably PlantUML doesn't support it -- i.e., only one link per row is allowed. However, having nodes and edges linked would already be a great improvement.

VladimirAlexiev commented 6 months ago

Ok @johanwk , I can do that. See this diagram and hover over the elements shown in red below:

image

This will be option -link

In summary

skinparam HyperlinkColor black
skinparam HyperlinkUnderline false

class ex_jahoda [[https://example-icecream.org/jahoda]]           '  per class 
ex_jahoda : {field} a [[https://example-icecream.org/Vůně ex:Vůně]], [[https://example-icecream.org/Foobar ex:Foobar]]     ' per value
ex_jahoda : {field} [[https://example-icecream.org/prop ex:prop]] [[https://example-icecream.org/value ex:Value]]    ' per prop and value
_r1711715942r0_ -down-> ex_jahoda : [[http://www.w3.org/2002/07/owl#hasValue owl:hasValue]]\n[[http://www.w3.org/2002/07/owl#fooBar owl:fooBar]]   ' per arrow label

I guess it will take 1-2p/d :-(

johanwk commented 6 months ago

Wow, this is simply great!!

I believe links at this detailed level just raises the value of diagrams for documentation. Excellent.