]> git.ipfire.org Git - thirdparty/bootstrap.git/commitdiff
Comment for #12794
authorMark Otto <otto@github.com>
Fri, 7 Mar 2014 07:50:55 +0000 (23:50 -0800)
committerMark Otto <otto@github.com>
Fri, 7 Mar 2014 07:51:07 +0000 (23:51 -0800)
less/button-groups.less

index afeb707162f9da3f24e8c1adca8bdf0c095832f6..ff95b0474e325eed8e5d5df8a674878754a1fd72 100644 (file)
 
 
 // Checkbox and radio options
+//
+// In order to support the browser's form validation feedback, powered by the
+// `required` attribute, we have to "hide" the inputs via `opacity`. We cannot
+// use `display: none;` or `visibility: hidden;` as that also hides the popover.
+// This way, we ensure a DOM element is visible to position the popover from.
+//
+// See https://github.com/twbs/bootstrap/pull/12794 for more.
+
 [data-toggle="buttons"] > .btn > input[type="radio"],
 [data-toggle="buttons"] > .btn > input[type="checkbox"] {
-  opacity: 0;
   position: absolute;
   z-index: -1;
+  opacity: 0;
 }