docusaurus-openapi icon indicating copy to clipboard operation
docusaurus-openapi copied to clipboard

Allow expandable row on Status Code table

Open LeoMouyna opened this issue 4 years ago • 4 comments

For now the only way to know how returned data looks like consist in waiting for a query.

Could it be possible to add an expand button at the end of a status row that would show a response example ? We can already see what a request body looks like in docusaurus-plugin-openapi/src/theme/ApiDemoPanel/Body/index.js, is it possible to also display how response body looks like on docusaurus-plugin-openapi/src/theme/ApiStatusCodesTable/index.js?

If you need more details feel free to ask.

LeoMouyna avatar Feb 28 '21 19:02 LeoMouyna

Yea I think that makes sense, I’d be happy to merge a PR if you can get something working

bourdakos1 avatar Feb 28 '21 23:02 bourdakos1

I'll give a try but I might need help on css part for a wonderful display šŸ˜„

LeoMouyna avatar Mar 01 '21 08:03 LeoMouyna

Here's an example of what I think would be helpful as part of the status code/response body table (using RapiDoc). Screen Shot 2021-03-17 at 11 56 58 AM Screen Shot 2021-03-17 at 11 56 38 AM

avaidyam avatar Mar 17 '21 16:03 avaidyam

I was looking for the same. A json response example on each status code would be a great feature.

Do you have any plans adding this :) ?

joanjane avatar Sep 09 '22 13:09 joanjane