1
0
Fork 0
mirror of https://github.com/twbs/bootstrap.git synced 2022-11-09 12:25:43 -05:00

Merge pull request #18787 from twbs/btn-vars

Add variables for spacing of .btn-toolbar and split-button dropdown toggles
This commit is contained in:
Mark Otto 2016-01-07 00:47:40 -08:00
commit 643bd8eaeb
2 changed files with 10 additions and 6 deletions

View file

@ -33,7 +33,7 @@
// Optional: Group multiple button groups together for a toolbar // Optional: Group multiple button groups together for a toolbar
.btn-toolbar { .btn-toolbar {
margin-left: -5px; // Offset the first child's margin margin-left: -$btn-toolbar-margin; // Offset the first child's margin
@include clearfix(); @include clearfix();
.btn-group, .btn-group,
@ -44,7 +44,7 @@
> .btn, > .btn,
> .btn-group, > .btn-group,
> .input-group { > .input-group {
margin-left: 5px; margin-left: $btn-toolbar-margin;
} }
} }
@ -104,12 +104,12 @@
// Give the line between buttons some depth // Give the line between buttons some depth
.btn-group > .btn + .dropdown-toggle { .btn-group > .btn + .dropdown-toggle {
padding-right: 8px; padding-right: $split-btn-dropdown-toggle-padding-x;
padding-left: 8px; padding-left: $split-btn-dropdown-toggle-padding-x;
} }
.btn-group > .btn-lg + .dropdown-toggle { .btn-group > .btn-lg + .dropdown-toggle {
padding-right: 12px; padding-right: $split-btn-lg-dropdown-toggle-padding-x;
padding-left: 12px; padding-left: $split-btn-lg-dropdown-toggle-padding-x;
} }
// The clickable button for toggling the menu // The clickable button for toggling the menu

View file

@ -271,6 +271,10 @@ $btn-padding-x-lg: 1.25rem !default;
$btn-padding-y-lg: .75rem !default; $btn-padding-y-lg: .75rem !default;
$btn-block-spacing-y: 5px !default; $btn-block-spacing-y: 5px !default;
$btn-toolbar-margin: 5px !default;
$split-btn-dropdown-toggle-padding-x: 8px !default;
$split-btn-lg-dropdown-toggle-padding-x: 12px !default;
// Allows for customizing button radius independently from global border radius // Allows for customizing button radius independently from global border radius
$btn-border-radius: $border-radius !default; $btn-border-radius: $border-radius !default;