我在模态对话框中使用 Angular UI Bootstrap 日期选择器弹出窗口。外部边框的宽度未根据内部内容正确计算。在某些情况下,外面的盒子比里面的东西大。在其他情况下,外部较小。此外,日期选择器外部的宽度似乎会影响弹出窗口的宽度。例如,“col-sm-4”会使边框变小,而“col-sm-5”会使边框变大。
任何人都可以指出正确的方向以检查问题可能出在哪里吗?
提前致谢!
最佳答案
看这个:http://plnkr.co/edit/JTkIvBwl9agQCYxLaN6X?p=preview
Just change to: is-open="opened" to: is-open="$parent.opened"
因此相关的 HTML 片段将如下所示:
<div class="input-group">
<input type="text" class="form-control"
datepicker-popup="dd.mm.yyyy"
ng-model="dt"
is-open="$parent.opened"
ng-required="true"
close-text="Close" />
<span class="input-group-btn">
<button style="height:34px;" class="btn btn-default" ng-click="open()">
<i class="icon-calendar"></i>
</button> <b><- button not working</b>
</span>
</div>
关于css - Angular UI Bootstrap 日期选择器宽度问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32953152/