admin管理员组文章数量:1414614
i'm trying to figure out how to have antd modal open and have height of 100% and width of 100%, tried different ways but always getting scroll y and x, and if i put height of 100vh then using different mobile devices it still can scroll down for some reason, so my question is how to get this modal perfectly 100% height and width without any scrollings, here is my code:
=/index.css
i'm trying to figure out how to have antd modal open and have height of 100% and width of 100%, tried different ways but always getting scroll y and x, and if i put height of 100vh then using different mobile devices it still can scroll down for some reason, so my question is how to get this modal perfectly 100% height and width without any scrollings, here is my code:
https://codesandbox.io/s/to-customize-the-width-of-modal-antd4154-forked-kfbzj?file=/index.css
Share Improve this question edited May 10, 2021 at 17:55 asked May 10, 2021 at 16:53 user10727653user107276532 Answers
Reset to default 2Hope this help https://codesandbox.io/s/to-customize-the-width-of-modal-antd4154-forked-mxx4j?file=/index.js
For more information:
- Change modal's width to "100vw"
- Change modal content to 100vw x 100vh with overflow auto
Please take reference from the below solution, setting below CSS worked for me: https://codesandbox.io/s/to-customize-the-width-of-modal-antd4154-forked-r0e0k?file=/index.css
.ant-modal {
width: 100%;
transform-origin: 85px 43px;
overflow: hidden;
height: -webkit-fill-available;
}
本文标签: javascripthave antd modal height and width 100Stack Overflow
版权声明:本文标题:javascript - have antd modal height and width 100 - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745149346a2644848.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论