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

[@mantine/core] fix portal props typings and override order #4009

Merged
merged 1 commit into from
Apr 11, 2023

Conversation

jvdsande
Copy link
Contributor

@jvdsande jvdsande commented Apr 5, 2023

Current implementation of portalProps requires children to be specified, when we don't want or need them here. There is also an override order that is wrong if withinPortal is passed both to portalProps and the component props itself.

For TypeScript users:

  • children is now removed from the prop types everywhere
  • withinPortal is removed from the prop types when it exists on the component type (which is always the case for now I think)
  • target is removed from the prop types if it's overwritten inside the component implementation

For JavaScript users:

  • withinPortal and target passed through portalProps do not override internal target and component-level withinPortal anymore

@rtivital rtivital merged commit c59c5dc into mantinedev:master Apr 11, 2023
1 check passed
@rtivital
Copy link
Member

Thanks!

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.

None yet

2 participants