Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorysds <fellows3@gmail.com>2018-11-04 09:50:21 +0300
committerXhmikosR <xhmikosr@gmail.com>2018-11-04 09:50:21 +0300
commitea8f6c6ff322587c4bc1bb7609137575c8ebaa52 (patch)
treed71308a73f8c0577038dba987bd06a5f45bc70f2 /scss/_button-group.scss
parentd27509688d3af428bb342265e4e7cf4ace52b5fa (diff)
Button group refactoring and fixes (#25395)
Diffstat (limited to 'scss/_button-group.scss')
-rw-r--r--scss/_button-group.scss25
1 files changed, 8 insertions, 17 deletions
diff --git a/scss/_button-group.scss b/scss/_button-group.scss
index 5495170345..716cf5208a 100644
--- a/scss/_button-group.scss
+++ b/scss/_button-group.scss
@@ -22,14 +22,6 @@
z-index: 1;
}
}
-
- // Prevent double borders when buttons are next to each other
- .btn + .btn,
- .btn + .btn-group,
- .btn-group + .btn,
- .btn-group + .btn-group {
- margin-left: -$btn-border-width;
- }
}
// Optional: Group multiple button groups together for a toolbar
@@ -44,8 +36,10 @@
}
.btn-group {
- > .btn:first-child {
- margin-left: 0;
+ // Prevent double borders when buttons are next to each other
+ > .btn:not(:first-child),
+ > .btn-group:not(:first-child) {
+ margin-left: -$btn-border-width;
}
// Reset rounded corners
@@ -119,17 +113,14 @@
align-items: flex-start;
justify-content: center;
- .btn,
- .btn-group {
+ > .btn,
+ > .btn-group {
width: 100%;
}
- > .btn + .btn,
- > .btn + .btn-group,
- > .btn-group + .btn,
- > .btn-group + .btn-group {
+ > .btn:not(:first-child),
+ > .btn-group:not(:first-child) {
margin-top: -$btn-border-width;
- margin-left: 0;
}
// Reset rounded corners