NG-ZORRO / ng-zorro-antd

Angular UI Component Library based on Ant Design
https://ng.ant.design
MIT License
8.86k stars 3.91k forks source link

open a popup,then scroll to bottom,the opened popup will not disappear #6637

Open sunsunyongjiu opened 3 years ago

sunsunyongjiu commented 3 years ago

Reproduction link

https://codesandbox.io/s/ng-zorro-antd-ivy-forked-y9b4n?file=/src/app/app.component.ts

Steps to reproduce

1.open a popover modal 2.scroll screen to bottom 3.find popever position wrong,and do not disappear;just float on the top of page

What is expected?

disappear when touch the top,and we do not want ban visitor's scroll,they can scroll the page;this bug can easily show in your basic web https://ng.ant.design/components/popover/zh

What is actually happening?

float at top,and visitor can not scroll the page.

Environment Info
ng-zorro-antd 11.4.0
Browser chrome
wzhudev commented 3 years ago

https://material.angular.io/components/tooltip/overview#tooltip-manual

Check this out. It looks to me that is a bug of CDK. With CDK, we could push an overlay into the visible area of a webpage. But it looks that there isn't (should be) a limitation of how far we can push.