Skip to content
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

[Feature] Collapse JSON Elements #2

Closed
andreisaikouski opened this issue Feb 7, 2022 · 7 comments · Fixed by #97
Closed

[Feature] Collapse JSON Elements #2

andreisaikouski opened this issue Feb 7, 2022 · 7 comments · Fixed by #97
Labels
feature Feature request or suggestion

Comments

@andreisaikouski
Copy link

Add ability to collapse JSON elements displayed in JSON view

@AykutSarac AykutSarac added the feature Feature request or suggestion label Feb 8, 2022
@AykutSarac
Copy link
Owner

Thanks for your suggestion. I will definitely consider adding this.

@fredrikj31
Copy link

@AykutSarac Do you use a library to make the graph, or have you created the layout on your own?

I think it would be cool if you could click on the element, and it will collapse the clicked parents children.

@AykutSarac
Copy link
Owner

@AykutSarac Do you use a library to make the graph, or have you created the layout on your own?

I think it would be cool if you could click on the element, and it will collapse the clicked parents children.

I've used the reaflow library. The library itself doesn't have collapse feature built-in though it does have delete node which removes all connectes nodes and edges of parent. Something similar could be implemented.

@fredrikj31
Copy link

Yeah maybe it could just be deleted. But I think that the delete functionality maybe causes a lot of performace issues. Would it not be better to just add a javascript display: hidden; and box to the child nodes?

@AykutSarac
Copy link
Owner

Yeah maybe it could just be deleted. But I think that the delete functionality maybe causes a lot of performace issues. Would it not be better to just add a javascript display: hidden; and box to the child nodes?

Sounds good.

@AndrewLaganaro
Copy link

I support that, would be really useful

@AykutSarac AykutSarac pinned this issue Jun 9, 2022
@AykutSarac AykutSarac removed this from the v2.0.0 Release milestone Jul 23, 2022
@AykutSarac AykutSarac linked a pull request Aug 27, 2022 that will close this issue
@AykutSarac AykutSarac unpinned this issue Aug 27, 2022
@oliverbutler
Copy link

We've got some legacy JSON objects with huge values on some sections.

Some of these can make the box 10 times longer than it is high.

I'm happy to try to solve this in a PR at some point, but possibly some kind of inline truncate, on the value level could be nice (That un-truncates if you click it)

Screenshot 2022-09-20 at 14 36 44

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

Successfully merging a pull request may close this issue.

5 participants