【问题标题】:Restrict ui-bootstrap modal to window height将 ui-bootstrap 模式限制为窗口高度
【发布时间】:2015-11-11 07:39:09
【问题描述】:

如何阻止长模态框出现在首屏下方?我希望模态完全可见并始终显示提交取消按钮。有没有一种简单的方法可以使用 ui-bootstrap 实现这一目标?

【问题讨论】:

    标签: modal-dialog angular-ui-bootstrap


    【解决方案1】:

    这是我用于此的 css

    .modal-dialog {
        height:calc(100% - 60px);
    }
        .modal-dialog .modal-content {
            height: 100%;
        }
            .modal-dialog .modal-content .modal-body {
                height: calc(100% - 120px);
                overflow-y:scroll;
            }
    

    http://caniuse.com/#feat=calc

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2015-06-08
      • 2013-05-26
      • 1970-01-01
      • 2015-02-26
      • 2017-05-02
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多