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
enhancement: display relations on history page #20054
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Size Change: 0 B Total Size: 2.38 MB ℹ️ View Unchanged
|
packages/core/content-manager/admin/src/history/components/VersionContent.tsx
Outdated
Show resolved
Hide resolved
<Flex direction="column" gap={2} alignItems="stretch"> | ||
{(field.value.results as Record<string, unknown>[]).map((relationData, index) => { | ||
<Flex direction="column" gap={2} marginTop={1} alignItems="stretch"> | ||
{(results as RelationResult[]).map((relationData) => { |
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.
you can type the useField
hook, it'd probably look like:
useField<{ results: RelationResult[]; meta: object }>(props.name)
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.
Looks great 👍🏼
What does it do?
How to test it?
Related issue(s)/PR(s)
This follows #20035 which was about the backend part.