diff options
author | Mark Otto <markdotto@gmail.com> | 2013-05-10 03:30:48 +0400 |
---|---|---|
committer | Mark Otto <markdotto@gmail.com> | 2013-05-10 03:30:48 +0400 |
commit | 1fdfee8de0e487f5d3710a94706e0a025d07919f (patch) | |
tree | c6976ea64cfa82124df62f790c18a1545bbe242f /less | |
parent | 8f9cc5ae81794cc25154ab21a845c9d77ef47e78 (diff) | |
parent | 9716b73f67de690d008cbfc8f1375ee85cd2539d (diff) |
Merge pull request #7837 from blakeembrey/input-group-radius
Remove input-group border radius resets
Diffstat (limited to 'less')
-rw-r--r-- | less/forms.less | 65 |
1 files changed, 16 insertions, 49 deletions
diff --git a/less/forms.less b/less/forms.less index 6162cd4f13..5db5f5cc3d 100644 --- a/less/forms.less +++ b/less/forms.less @@ -407,12 +407,8 @@ select:focus:invalid { .input-group-btn, .input-group input { display: table-cell; - /*margin: 0;*/ - border-radius: 0; - &.input-small { - border-radius: 0; - } - &.input-large { + + &:not(:first-child):not(:last-child) { border-radius: 0; } } @@ -435,40 +431,35 @@ select:focus:invalid { text-shadow: 0 1px 0 #fff; background-color: @gray-lighter; border: 1px solid #ccc; + border-radius: @border-radius-base; &.input-small { padding: @padding-small; font-size: @font-size-small; + border-radius: @border-radius-small; } - &.input-large { - padding: @padding-large; - font-size: @font-size-large; + &.input-large { + padding: @padding-large; + font-size: @font-size-large; + border-radius: @border-radius-large; } } // Reset rounded corners .input-group input:first-child, -.input-group-addon:first-child { - .border-left-radius(@border-radius-base); - &.input-small { - .border-left-radius(@border-radius-small); - } - &.input-large { - .border-left-radius(@border-radius-large); - } +.input-group-addon:first-child, +.input-group-btn:first-child > .btn:first-child, +.input-group-btn:first-child > .dropdown-toggle:first-child { + .border-right-radius(0); } .input-group-addon:first-child { border-right: 0; } .input-group input:last-child, -.input-group-addon:last-child { - .border-right-radius(@border-radius-base); - &.input-small { - .border-right-radius(@border-radius-small); - } - &.input-large { - .border-right-radius(@border-radius-large); - } +.input-group-addon:last-child, +.input-group-btn:last-child > .btn:last-child, +.input-group-btn:last-child > .dropdown-toggle { + .border-left-radius(0); } .input-group-addon:last-child { border-left: 0; @@ -483,7 +474,6 @@ select:focus:invalid { .input-group-btn > .btn { position: relative; float: left; // Collapse white-space - border-radius: 0; + .btn { margin-left: -1px; } @@ -494,29 +484,6 @@ select:focus:invalid { } } -// Prepended buttons -.input-group-btn:first-child { - // Round the left corners only - > .btn:first-child, - > .dropdown-toggle:first-child { - .border-left-radius(@border-radius-base); - &.btn-large { .border-left-radius(@border-radius-large); } - &.btn-small { .border-left-radius(@border-radius-small); } - } -} - -// Appended buttons -.input-group-btn:last-child { - // Round the right corners only - > .btn:last-child, - > .dropdown-toggle { - .border-right-radius(@border-radius-base); - &.btn-large { .border-right-radius(@border-radius-large); } - &.btn-small { .border-right-radius(@border-radius-small); } - } -} - - // Inline forms // -------------------------------------------------- |