]> git.ipfire.org Git - thirdparty/bootstrap.git/commitdiff
Calculcate the top offset for custom control indicators 21034/head
authorMark Otto <markdotto@gmail.com>
Thu, 27 Oct 2016 21:41:12 +0000 (14:41 -0700)
committerMark Otto <markdotto@gmail.com>
Thu, 27 Oct 2016 21:41:12 +0000 (14:41 -0700)
Fixes #21023.

Uses some math functions to determine what the offset should be. This is helpful for those who customize the size of their indicators and still want them vertically centered.

scss/_custom-forms.scss

index e74f5c744a8f74b22eb232abac03202adb7e403e..18aedc66fa48166b7b30361cf5a00d822eabaf66 100644 (file)
@@ -61,7 +61,7 @@
 
 .custom-control-indicator {
   position: absolute;
-  top: .25rem;
+  top: (($line-height-base - $custom-control-indicator-size) / 2);
   left: 0;
   display: block;
   width: $custom-control-indicator-size;