gpt4 book ai didi

css - 表格内的时间选择器

转载 作者:行者123 更新时间:2023-11-28 11:22:00 25 4
gpt4 key购买 nike

在我的 Angular 应用程序中,我使用了 timepicker来自 ngx-bootstrap 的小部件.

在 table 外使用时看起来不错:

enter image description here

但是,由于某些原因,当在 table 元素中使用时,它看起来 super 丑陋:

enter image description here

我没有使用任何自定义 CSS 代码。

最佳答案

我花了一段时间才弄清楚那里发生了什么。问题是一些附加到 .table 和类似类的 Bootstrap 样式(例如应用于 .table td 的规则)正在破坏时间选择器的布局(因为它在内部也使用 table 元素)。

我的解决方案是应用这种风格:

timepicker {
table {
tr {
background-color: transparent !important;

th,
td {
padding: 0 !important;
vertical-align: middle !important;
border: none !important;
}
}
}
}

关于css - 表格内的时间选择器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52483139/

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