Open stantoxt opened 2 years ago
[Official website modal document https://ng.ant.design/components/modal/zh]
Use Sogou to browse and open the official website connection
MODAL mask layer and content are normal display
After the actual opening, the mask layer is gone
ENVIRONMENT | Info |
---|---|
NG-Zorro-ATD | 13.3.1 |
Browser | Sogou Browser |
The reason is. Ormodal-wrap { POSITION: FIXED; TOP: 0; Right: 0; bottom: 0; left: 0; overflow: Auto; outline: 0; -webkit -Overflow-Scroling: Touch; } After packaging .ant-modal-wrap { POSITION: FIXED; Inset: 0; overflow: Auto; outline: 0; -webkit -Overflow-Scroling: Touch; } Inset: 0; in Sogou browser, or other versions of low browsers, it cannot be recognized
14.x有没有发现360极速浏览器,样式问题很大, switch就一个颜色块,modal弹出在浏览器左上角… 前天前天升级,昨天恢复了😂
你去改下.browserslistrc文件里面的配置,你要支持到哪个版本加上,这儿可以看https://caniuse.com/?search=inset。比如inset 这个css Chrome 86 是不支持的,你在 .browserslistrc文件里面加上Chrome 86 ,build 的时候就不会改成inset了。
Reproduction link
官网Modal 文档 https://ng.ant.design/components/modal/zh
Steps to reproduce
使用搜狗浏览打开 官网连接
What is expected?
modal 遮罩层和内容 正常显示
What is actually happening?
实际打开之后遮罩层没有了
原因是 .ant-modal-wrap { position: fixed; top: 0; right: 0; bottom: 0; left: 0; overflow: auto; outline: 0; -webkit-overflow-scrolling: touch; } 经过打包之后变成了 .ant-modal-wrap { position: fixed; inset: 0; overflow: auto; outline: 0; -webkit-overflow-scrolling: touch; } inset: 0; 在搜狗浏览器,或者其他版本低的浏览器中,无法识别