Skip to content

Add Plantuml variant (re #166) #471

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 10 commits into
base: gh-pages
Choose a base branch
from

Conversation

VladimirAlexiev
Copy link
Contributor

@VladimirAlexiev VladimirAlexiev commented Aug 5, 2025

Reopens #166: by using better technology (PlantUML) we can improve the diagram a lot more easily, and make new diagrams.
IMHO the PlantUML code is more readable than the textual diagram,
and it produces real arrows (doesn't depend on the Class-Diagram-Arrows.png kluge)

image
  • added link NodeShape->PropertyShape
  • broke the long text to 2 lines
  • shown PropertyGroup
  • added sh:order to PropertyShape and PropertyGroup

These are minor fixes, but the point is that with PlantUML we can maintain more easily, add more diagrams (eg Node Expressions), and make more kinds of diagrams.

See SVG diagram rendered at plantuml server

  • Try out the links: they work and are relative
    • There's skinparam topurl https://raw.githack.com/w3c/data-shapes/master/shacl12-core/index.html in the .puml file but we should try to leave it out and see whether the links use as base the HTML URL (good) or the SVG URL (bad)
  • There's a Makefile that produces SVG using a local plantuml installation
  • We want to use a local installation instead of the plantuml server because the build shouldn't depend on an external server
  • class label should support creole link rendering plantuml/plantuml#2290 There's was no blue underline on the class name (Update: added with tags <color:blue> and <u>). Note the whole node is clickable and goes to the class definition

If you agree, I can:

  • replace the textual diagram in the HTML with <img> tag
  • remove Class-Diagram-Arrows.png

Please check all links for accuracy!

@VladimirAlexiev
Copy link
Contributor Author

@YoucTagh Thanks for your close reading!!!!
Now do you agree with the next steps:

  • replace the textual diagram in the HTML with <img> tag
  • Check how the links behave when embedded in HTML
  • remove Class-Diagram-Arrows.png

@TallTed
Copy link
Member

TallTed commented Aug 6, 2025

As I noted in #166

Assuming that the diagram we finalize on does not include all features, it should include some ... or etc. or similar arrows/boxes/line-items — so it's clear that we're not showing everything in the diagram (which I think is entirely reasonable, even with automatic tooling, given the large number of features involved).

Also, note that Accessibility review will demand textual description of each diagram, usable with screen readers and other assistive technologies. So it's in our best interest to avoid overly complex diagrams, even if they're easily produced.

- sh:path : predicate or list or blank node and link to #property-paths
- add ellipsis as per TallTed
- rdf:List -> "list" because SHACL doesn't require the rdf:List type
- add sh:nodeKind, sh:ignoredProperties
@VladimirAlexiev
Copy link
Contributor Author

VladimirAlexiev commented Aug 7, 2025

@TallTed @YoucTagh I added a few more changes, can you please recheck?

Copy link
Contributor

@YoucTagh YoucTagh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, the content is good for me. I won't merge it; maybe we can figure out how to make the links work.

@VladimirAlexiev
Copy link
Contributor Author

@YoucTagh the links work now: https://raw.githack.com/VladimirAlexiev/data-shapes/refs/heads/issue-166-plantuml/shacl12-core/index.html#constraints-section.

@TallTed I can't yet add an accessibility description (<svg desc=) because plantuml/plantuml#2292.
Hopefully PlantUML will add such feature soon!

Copy link
Member

@TallTed TallTed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much improved. There's always more, but this is a big step forward.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants