-
Notifications
You must be signed in to change notification settings - Fork 14
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
fix(specs): correct type for highlightResult and snippetResult #783
Conversation
✅ Deploy Preview for api-clients-automation ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✗ The generated branch has been deleted.If the PR has been merged, you can check the generated code on the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch!
84f1a5d
to
c64f250
Compare
specs/search/common/schemas/Hit.yml
Outdated
|
||
highlightResultMap: | ||
type: object | ||
description: Highlighted attributes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The description is not ideal but we can add a similar one to the snippetResultMap
too
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
description: Highlighted attributes. | |
description: Highlighted section and words matched by a query. |
wait it's more complicated than I thought, it should be a oneOf 😭 |
For when it's matched you mean? |
the real type is: type Inner = {
value: string;
matchLevel: (enum);
matchedWords: string[];
fullyHighlighted?: boolean
}
type HighlighResult = Record<String, Inner | Inner[]>; which is completely different from the doc of course |
Ah.... good news is, it should not be a big deal on our side :D |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great fixes!!!!
🧭 What and Why
🎟 JIRA Ticket: APIC-565
Use correct types.