Redocly / Redocly/redoc

I'm using Redocly to generate API documentation and I would like to sync the `oneOf` tiles with the example payload dropdown in the generated UI. Currently, the two elements are not synchronized, and I'm seeking guidance on how to achieve this synchronization.

Open
#2,346 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Type: Enhancement
Dominant language
TypeScript
Stars
25.9k
Forks
2.4k
Avg merge
13h 10m
Merged PRs (30d)
4

Description

Issue Description

Expected Behaviour:
When a user clicks on a oneOf tile, the corresponding option should be selected in the example payload dropdown, and vice versa.

Steps to Reproduce

  1. Generate API documentation using Redocly.
  2. Navigate to the section with oneOf tiles and the example payload dropdown.
  3. Observe that the selection in the oneOf tiles and the example payload dropdown are not synchronized.
  • Redocly Version: 3
Screenshot 2023-06-29 at 12 28 55 AM

Thank you!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in the Redocly v3 generated UI code for the oneOf tiles and example payload dropdown, then trace how each control handles selection. Done means clicking either control selects the corresponding option in the other, with the behavior verified in the rendered API documentation.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi, typescript
Domain
api, documentation, frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.