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

Add Filter text input to manage visible class properties #98

Open
BoldBigflank opened this issue Nov 30, 2020 · 5 comments
Open

Add Filter text input to manage visible class properties #98

BoldBigflank opened this issue Nov 30, 2020 · 5 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@BoldBigflank
Copy link

Re: https://forum.babylonjs.com/t/request-api-doc-index-sidebar-filter/15682/6

The idea is to have a text input at the top of each class page that when typed in will remove visibility of the properties/methods that don't match the input string. This will make it much easier to find the user's desired information.

@RaananW RaananW added the enhancement New feature or request label Nov 30, 2020
@RaananW RaananW self-assigned this Nov 30, 2020
@RaananW
Copy link
Member

RaananW commented Nov 30, 2020

sounds great! On my todo list 😊

@PirateJC PirateJC added this to the Future milestone Sep 26, 2022
@impurity-dev
Copy link
Contributor

impurity-dev commented Nov 30, 2023

@RaananW So I was looking into this... It would technically be much easier to implement this if we used the JSON output for the files, instead of the TypeDoc html, that way we could cache the loaded files, and easily apply filters to different JSON objects, and slot in filter-inputs to each section of the json. However, it would mean a ton more work setting up the actual page. The alternative is to hackily traverse the HTML, but it would be quicker (although more fragile, certainly if typedoc changes things slightly in the HTML).

My question is if one was to do this work, would you be okay with going down the JSON route and creating a custom view of the docs instead of using the TypeDoc generated HTML, or would you prefer we use the current HTML output with a solution more like this extension that would inspect the HTML for view/hide.

Note, I'm willing to do either approach even if it'd be a bit of work to do, but I didn't wanna just make a decision, on your behalf.

@RaananW
Copy link
Member

RaananW commented Dec 1, 2023

The issue with the JSON is to generate a familiar and usable HTML layout to display the API docs. TypeDoc does it wonderfully. If we can find a backwards-compatible HTML layout that works well and can be generated using the JSON output, i am all for it! Otherwise, we will have to stick with the HTML.

@BoldBigflank
Copy link
Author

#1025
Here's a quick and dirty example of a way to add this filter field. There's more to do to make it production ready, and maybe this is just a bad way to do it (feel free to suggest better ways)

@impurity-dev
Copy link
Contributor

#1025 Here's a quick and dirty example of a way to add this filter field. There's more to do to make it production ready, and maybe this is just a bad way to do it (feel free to suggest better ways)

Ahha! I didnt know that you could do that. Thanks for the PR man. Learned something new 😄

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

No branches or pull requests

4 participants