Skip to content

feat: improve dataservice OpenAPI response viewer#1100

Open
Samuelfaure wants to merge 1 commit into
mainfrom
feature/api-6768-ameliorer-lui-de-visualisation-des-donnees
Open

feat: improve dataservice OpenAPI response viewer#1100
Samuelfaure wants to merge 1 commit into
mainfrom
feature/api-6768-ameliorer-lui-de-visualisation-des-donnees

Conversation

@Samuelfaure
Copy link
Copy Markdown
Contributor

@Samuelfaure Samuelfaure commented May 28, 2026

Summary

Improves the "Données renvoyées" OpenAPI response viewer on the dataservice detail page (API-6768):

  • Each field's example now renders below its description — reading order is title → description → example → children.
  • Darker description text (gray-800) and tree-node borders (gray-300) for better contrast.
  • Per-node collapse/expand via a chevron, plus a global Ouvrir tout / Fermer tout control; default state is fully expanded.

Global open/close-all is coordinated through a provide/inject reactive signal (openApiCollapse.ts), so it broadcasts to every node across all endpoints without a path registry, while individual node toggles stay independent.

Test plan

Verified manually in the dev server against api-sirene-open-data (spec with nested objects and arrays):

  • Reading order title → description → example on every node
  • Description renders darker; borders are higher-contrast
  • Per-node toggle is independent; leaf nodes have no chevron and stay aligned
  • "Fermer tout" collapses every node across all endpoints; "Ouvrir tout" expands them all; default on load is fully expanded
  • Flat/empty schema hides the global control (code-verified via hasExpandableNode; not exercised against a real flat schema)

nuxt typecheck and eslint both pass.

Linear: https://linear.app/pole-api/issue/API-6768/ameliorer-lui-de-visualisation-des-donnees

output

@Samuelfaure Samuelfaure force-pushed the feature/api-6768-ameliorer-lui-de-visualisation-des-donnees branch from ffc30f0 to 7c8a9bb Compare May 28, 2026 09:55
- move each field's example below its description
- darken description text and tree-node borders for contrast
- add per-node collapse/expand with a global "Ouvrir tout / Fermer tout"
  control, defaulting to fully expanded

API-6768
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

Successfully merging this pull request may close these issues.

1 participant