This repository has been archived by the owner on Apr 6, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
/
button-group.plugin.css
63 lines (48 loc) · 1.81 KB
/
button-group.plugin.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
/** @define ButtonGroup */
/*! suit-button-group v2.2.0 | MIT License | github.com/suitcss */
/* Modifier: collapse button borders
========================================================================== */
/**
* Includes appropriate removal of `border-radius`.
* All browsers that support `border-radius` also support CSS 3 pseudo-classes.
*/
/**
* Vertical collapse
*/
.ButtonGroup--borderCollapse:not(.ButtonGroup--hz) > .ButtonGroup-item {
margin-top: calc(var(--border-width-Button) * -1px);
}
.ButtonGroup--borderCollapse:not(.ButtonGroup--hz) > .ButtonGroup-item:first-child {
margin-top: 0;
}
.ButtonGroup--borderCollapse:not(.ButtonGroup--hz) > .ButtonGroup-item:not(:first-child):not(:last-child) > .Button {
border-radius: 0;
}
.ButtonGroup--borderCollapse:not(.ButtonGroup--hz) > .ButtonGroup-item:first-child:not(:only-child) > .Button {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
.ButtonGroup--borderCollapse:not(.ButtonGroup--hz) > .ButtonGroup-item:last-child:not(:only-child) > .Button {
border-top-left-radius: 0;
border-top-right-radius: 0;
}
/**
* Horizontal collapse
*/
.ButtonGroup--borderCollapse.ButtonGroup--hz > .ButtonGroup-item {
margin-left: calc(var(--border-width-Button) * -1px);
}
.ButtonGroup--borderCollapse.ButtonGroup--hz > .ButtonGroup-item:first-child {
margin-left: 0;
}
.ButtonGroup--borderCollapse.ButtonGroup--hz > .ButtonGroup-item:not(:first-child):not(:last-child) > .Button {
border-radius: 0;
}
.ButtonGroup--borderCollapse.ButtonGroup--hz > .ButtonGroup-item:first-child:not(:only-child) > .Button {
border-bottom-right-radius: 0;
border-top-right-radius: 0;
}
.ButtonGroup--borderCollapse.ButtonGroup--hz > .ButtonGroup-item:last-child:not(:only-child) > .Button {
border-bottom-left-radius: 0;
border-top-left-radius: 0;
}