-
Notifications
You must be signed in to change notification settings - Fork 220
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
[WIP] Fix pop node height 100% #44
Conversation
8b87ff4
to
705b53c
Compare
Not finished |
705b53c
to
a50ae98
Compare
div.style.margin = '0'; | ||
div.style.padding = '0'; | ||
}); | ||
|
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.
这个用例在 npm run chrome-test
下可以重现 #41 的问题。需要把 OSX 的滚动条调成『始终』。
npm test 里貌似不会出现滚动条。
@@ -76,6 +76,8 @@ const Popup = React.createClass({ | |||
this.currentAlignClassName = null; | |||
} | |||
const newStyle = { | |||
top: 0, | |||
left: 0, |
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.
默认给 popupDOMNode 加上 top 和 left,避免影响页面原有的布局。
popupContainer.style.position = 'absolute'; | ||
popupContainer.style.top = '0'; | ||
popupContainer.style.left = '0'; | ||
popupContainer.style.width = '100%'; |
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.
会导致 ant-design/ant-design#5092 的问题。影响弹出节点的 height: 100%
和 max-height: 100%
的样式高度。
a50ae98
to
390bad2
Compare
算了,会有更多问题,我在 antd 修复即可。 |
close ant-design/ant-design#5092