Skip to content
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

[Docs] EuiAccordion props table #5974

Merged
merged 6 commits into from
Jun 27, 2022

Conversation

thompsongl
Copy link
Contributor

@thompsongl thompsongl commented Jun 15, 2022

Summary

Provide EuiAccordionProps as the withEuiTheme generic to allow the props table to populate correctly.

export const EuiAccordion = withEuiTheme<EuiAccordionProps>(EuiAccordionClass);

Checklist

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_5974/

@thompsongl
Copy link
Contributor Author

Probably going to use the !!prop-loader! method after #6000 merges

@cee-chen
Copy link
Member

cee-chen commented Jun 27, 2022

@thompsongl you don't need a separate prop file for class components with withEuiTheme. All EuiAccordion needs is this in its export:

export const EuiAccordion = withEuiTheme<EuiAccordionProps>(EuiAccordionClass);

Tested locally and both props table and playground work as expected. There's an extra ref prop at the bottom of the table but it's kind of whatever (IMO)

@thompsongl
Copy link
Contributor Author

🙇 Thanks for the assist, @constancecchen!

@thompsongl thompsongl marked this pull request as ready for review June 27, 2022 19:50
Copy link
Member

@cee-chen cee-chen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 looks good to me!

Copy link
Contributor

@1Copenut 1Copenut left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@thompsongl thompsongl enabled auto-merge (squash) June 27, 2022 20:07
@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_5974/

@thompsongl thompsongl merged commit 48db5bb into elastic:main Jun 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants