OpenDataServices / sphinxcontrib-opendataservices

Sphinx directives maintained by Open Data Services
MIT License
0 stars 0 forks source link

jsoninclude: Hide select box for single directives #40

Open duncandewhurst opened 2 years ago

duncandewhurst commented 2 years ago

The select box is useful when there are consecutive directives but useless when there is only one directive.

jpmckinney commented 8 months ago

I don't think the directive creates the select box, but rather JS code, like this for OCDS. Perhaps the project with the select box has incorrect logic.

duncandewhurst commented 8 months ago

Yes, I think the Javascript files linked in the documentation for the directive need to be updated with the correct logic. At least, the examples on that page show a selection box even when there is only one directive.

Edit: For future reference, I created this issue whilst working on the OFDS documentation.

jpmckinney commented 8 months ago

Aha - I might have simply fixed this for OCDS. Feel free to copy that code into this project (with maybe a link in a comment, so it's easy to check if the source has changed).