我怎样才能增加引导模态高度

Vzu*_*upo 5 css modal-dialog twitter-bootstrap twitter-bootstrap-3

我只是想在 iphone 5/6 设备上制作一个非常高的引导模式显示。

我不能让它为任何事情工作。我曾尝试增加模态内容以及模态对话框中的高度,但它不起作用。

有什么简单的解决方案吗?

.modal-dialog{
    height:90% !important;
}
Run Code Online (Sandbox Code Playgroud)
<div class="container">
  <button type="button" class="btn btn-primary btn-lg" data-toggle="modal" data-target="#myModal">
    Launch modal
  </button>
</div>

<div id="myModal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
  <div class="modal-dialog" role="document">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
        <h4 class="modal-title" id="myModalLabel">My modal</h4>
      </div>
    </div>
  </div>
</div>

<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
Run Code Online (Sandbox Code Playgroud)

Gle*_*sky 6

.modal-content块是内部.modal-dialog块。因此,告诉孩子与父母的身高相同。尝试:

.modal-dialog {
  height: 90%; /* = 90% of the .modal-backdrop block = %90 of the screen */
}
.modal-content {
  height: 100%; /* = 100% of the .modal-dialog block */
}
Run Code Online (Sandbox Code Playgroud)

查看:

.modal-dialog {
  height: 90%; /* = 90% of the .modal-backdrop block = %90 of the screen */
}
.modal-content {
  height: 100%; /* = 100% of the .modal-dialog block */
}
Run Code Online (Sandbox Code Playgroud)
@import url('https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css');

.modal-tall .modal-dialog {
  height: 90%;
}
.modal-tall .modal-content {
  height: 100%;
}

/* fix SO stick navigation ;) */
@media (min-width: 768px) { body { padding-top: 75px; } }
Run Code Online (Sandbox Code Playgroud)