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

fix https://github.com/ant-design/ant-design/issues/24821 #115

Merged
merged 1 commit into from Jun 8, 2020

Conversation

jljsj33
Copy link
Member

@jljsj33 jljsj33 commented Jun 8, 2020

只在全局的情况下增加 openCount

ant-design/ant-design#24821

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.5%) to 29.217% when pulling a203afd on fix-portalWrapper into 905cc63 on master.

@jljsj33 jljsj33 merged commit b103101 into master Jun 8, 2020
@delete-merged-branch delete-merged-branch bot deleted the fix-portalWrapper branch June 8, 2020 14:30
@@ -47,7 +51,7 @@ class PortalWrapper extends React.Component {
visible: prevVisible,
getContainer: prevGetContainer,
} = prevProps;
if (visible !== prevVisible) {
if (visible !== prevVisible && !windowIsUndefined && this.getParent() === document.body) {
Copy link
Member

Choose a reason for hiding this comment

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

getDerivedStateFromProps 里面不能用 this。

Copy link
Member Author

Choose a reason for hiding this comment

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

复制粘贴习惯了。。

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

3 participants