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

Option to display fields names without their class name in the TOCs #287

Closed
azmeuk opened this issue May 17, 2024 · 3 comments
Closed

Option to display fields names without their class name in the TOCs #287

azmeuk opened this issue May 17, 2024 · 3 comments

Comments

@azmeuk
Copy link

azmeuk commented May 17, 2024

Thanks to #285 I can remove the signature prefix from the fields. This makes it less confusing for users who do want to use and parameter my application, but does not care about python things:

Capture d’écran du 2024-05-17 22-39-11

However as you see in the screenshot, the fields are referenced in the sidebar TOC with their class name attached.

It would be nice if there was a way to only display fields names in the TOC, for instance THEME instead of CoreSettings.THEME.

What do you think?

@mansenfranzen
Copy link
Owner

Hi @azmeuk,

thanks for raising the issue here!

The TOC generation is not part of autodoc_pydantic. This feature request belongs to Sphinx in case you're using the builtin .. toctree:: directive.

I hope this helps to guide you into the correct direction.

Feel free to reopen :-)

@mansenfranzen
Copy link
Owner

@allcontributors please add @azmeuk for question

Copy link
Contributor

@mansenfranzen

I've put up a pull request to add @azmeuk! 🎉

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

No branches or pull requests

2 participants