-
-
Notifications
You must be signed in to change notification settings - Fork 54
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
Display inheritance graph in model explorer #1114
Conversation
That's hella cool! Wow. Could you even render out a full hierarchy on the landing page for the schema docs? |
It’s something I’d like to try out, but I’m a bit pessimistic about the result being usable/laid out in a usable way. :D |
So, I tried to render a full inheritance graph in the same way, and this is the result… I tried to tweak some of the parameters (e.g. to get rectangular edges), but the results are still not usable. I implemented this using Mermaid because it’s so simple and I want to introduce it to the Aleph docs too (to be able to easily include flow charts in documentation articles). When I have some more time at some point, I might experiment a bit more, trying to render stuff directly using D3 or a DAG rendering library. |
eae137a
to
8e3818a
Compare
80983f1
to
1a422c9
Compare
Generally looks pretty amazing. Only comment, and I don't think it is something that we have to address right away, is that for some schemata it can be very difficult to read the generated graph. Interval is a good example of this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this css.txt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It’s a workaround, see commit message: 5194802
@Rosencrantz Yes, I’m aware of that. Was thinking about an option to expand the diagram or something like that, but I agree, this is something we do not need to address right away. |
For example to display a full graph of the model on the explorer index page…
This is a workaround due to an Astro bug. The bug has been fixed, but we're still on an older Astro version, and using a different file extension works fine for now.
Most people using the model explorer will probably search for the schema name as that is what they use when creating mappings, writing crawlers, debugging problems with Aleph etc. The schema label is still visible on the index page, but we now use the name consistently in headings, page titles, navigation links etc.
1a422c9
to
5c7ad7d
Compare
I keep referring to the schema YAML files when I need to find child schemata of a specific schema, so in addition to the list of parent schemata, I added a list of child schemata to the explorer pages. Then decided it probably makes sense to display the (partial) inheritance graph as an actual graph.
To do:
Show siblings