-
Notifications
You must be signed in to change notification settings - Fork 123
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
Support a way to visualize folder structures #1660
Comments
Hello there!
I agree, but I'm also not sure if the interactive features Treed provides are necessary (e.g., folder collapsing, keyboard navigation/shortcuts, etc.). |
Yes, I don't think we need the instructiveness. If there is a suitable third-partly library that we can plug in easily, it's fine to have such extra features. But if we are going to roll our own implementation, we can definitely go for a simple static visualization. |
I find this interesting and would like to work on it if possible :) Proposed syntax:
To
(example taken from the reference site) Some available configurations (any combinations of the 3 boolean attributes):
|
@tlylt Yes, this one seems like a reasonable solution. |
Feels like the trailing slash should be determined from the text itself. i.e., give a slash if there is a slash given in the source; no slash otherwise (even for intermediate nodes) |
Yup, that is reasonable. The ability to add a trailing slash is more of a convenient option and not strictly necessary.
I agree. It does limit the scope of what this feature can do. I am not too sure if we should generalize this use case to other tree-like structures though. Would a plantuml mindmap work well for those cases? I am leaning towards the idea of "tree" for folder structures, as a parallel to the |
Both PlantUML mindmap and work breakdown structure diagrams are viable alternatives but neither has the left-aligned visualization we usually use for folder trees. So, this feature still has value and I expect it to be light-weight than PlantUML (e.g., no need to have Java installed) Most likely this feature will be used for visualizing folder structures but we don't have to tie it down to folders only if we can help it. That way, it can be used for other folder-like visualizations when needed. On a related note, as the output will be text (not a png/svg) we can consider allowing more rich content e.g., tooltips, images, icons etc. in nodes. Does that make sense? |
Yup sounds good.
I think for a start we could do with simple text outputs. Adding on to that would be allowing inline markdown, something similar to what other components support. Afterward, if we do go into more complicated functionalities such as folder collapsing/keyboard shortcuts, then it might need more HTML/CSS/JS. |
You are right. If those customizations come for free, OK to use. But otherwise, we can skip them, as they don't actually add much value - certainly not worth implementing ourselves. e.g., root and trailing slash can be easily added in the node text itself, and I can't imagine a situation for using full path in every node. But I could be wrong. |
nice work @tlylt
Yes, definitely good enough for a first release. How about things like No preference on font. Yes, we can support list syntax as I feel it is visually more comforting/intuitive than the bare indentation syntax (?). OK to not support it too. |
Yes, almost all text styles specified here are working, with the exception of "center align" because it doesn't work well within a paragraph of text.
This is a bit tricky (as far as I know).
For the tree feature, because it's supporting only "inline markdown" (and inline HTML)
I think it is possible to support it, but there's a bit of ambiguity (should the attribute applies to just Screenshot:
|
Yes @tlylt , I think it's sufficient. |
In technical documentations, often we need to describe a folder structure, to explain where to put certain files for example.
It is nice if we can provide a syntax that MarkBind can convert to a nice visual.
More generally, it can even be used to explain other types of tree-like structures.
PlantUML doesn't seem to support folder visualizations.
https://jaredforsyth.com/treed/ seem to doing something along these lines but not sure if it can fit MarkBind.
The text was updated successfully, but these errors were encountered: