aboutsummaryrefslogtreecommitdiff
path: root/less
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2013-06-17 14:19:44 -0700
committerMark Otto <[email protected]>2013-06-17 14:21:16 -0700
commit37f4a25be436e8b25004d22541809032d8354600 (patch)
treeb8e4d5d90c451dd8fa6525e48cea0a9d2a8b8003 /less
parent4436e727ed52e45db2f5db9bf4efcea4ba8c64c3 (diff)
downloadbootstrap-37f4a25be436e8b25004d22541809032d8354600.tar.xz
bootstrap-37f4a25be436e8b25004d22541809032d8354600.zip
Better clearing on `.dl-horizontal` for empty `dd` elements
Instead of clearing the entire `.dl-horizontal`, we've moved the clearfix mixin to the `dd` level to solve two problems in one: empty `dd`s mid-list, and empty `dd` as the last child. Addresses a few old issues, including #2824, #3819, #3821, #4062, #6707, and #7180. Sorry that took so long :D.
Diffstat (limited to 'less')
-rw-r--r--less/type.less2
1 files changed, 1 insertions, 1 deletions
diff --git a/less/type.less b/less/type.less
index a74bdaeff..9a6811e3d 100644
--- a/less/type.less
+++ b/less/type.less
@@ -149,7 +149,6 @@ dd {
}
// Horizontal layout (like forms)
.dl-horizontal {
- .clearfix(); // Ensure dl clears floats if empty dd elements present
dt {
float: left;
width: (@component-offset-horizontal - 20);
@@ -158,6 +157,7 @@ dd {
.text-overflow();
}
dd {
+ .clearfix(); // Clear the floated `dt` if an empty `dd` is present
margin-left: @component-offset-horizontal;
}
}