gpt4 book ai didi

html - 无法减少标签和控件之间的空间

转载 作者:太空宇宙 更新时间:2023-11-04 06:20:59 25 4
gpt4 key购买 nike

我正在尝试减少表单中 kendo-datepickerlabel EvalDate 之间的空间。我尝试了填充等方法,但没有帮助。

截图:

enter image description here

<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">

<div class="form-group row col-md-12" style="margin-top:30px">
<label for="inputFax" class="col-md-1 col-form-label " style="font-weight: bold;">Eval Date</label>
<div class="col-md-1">

<kendo-datepicker style="width: 100% ;float: left;" [format]="'MMMM yyyy'" [topView]="'decade'" [bottomView]="'year'" [(ngModel)]="evalDate"
(valueChange)="evalDateChanged($event)">
</kendo-datepicker>
</div>

<div class="col-md-2" style="padding-left: 10px; width: 100%"><a class="btn btn-primary "
(click)="downloadFundAllocationDetails()" [attr.href]="Url">Export To
EXCEL<i title="PDF" class="fa fa-file-excel-o"></i> </a></div>
</div>

应用 Thanveer 解决方案后的屏幕截图 enter image description here

最佳答案

为什么不将标签放在与输入相同的 div 中,并从标签中删除 col-md-1

<div class="form-group row col-md-12" style="margin-top:30px">
<div class="col-md-1">
<label for="inputFax" class="col-form-label " style="font-weight: bold;">Eval Date</label>
<kendo-datepicker style="width: 100% ;float: left;" [format]="'MMMM yyyy'" [topView]="'decade'" [bottomView]="'year'" [(ngModel)]="evalDate"
(valueChange)="evalDateChanged($event)">
</kendo-datepicker>
</div>

<div class="col-md-2" style="padding-left: 10px; width: 100%"><a class="btn btn-primary "
(click)="downloadFundAllocationDetails()" [attr.href]="Url">Export To
EXCEL<i title="PDF" class="fa fa-file-excel-o"></i> </a></div>
</div>

关于html - 无法减少标签和控件之间的空间,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55512127/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com