-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path_buttons.scss
More file actions
90 lines (82 loc) · 2.36 KB
/
_buttons.scss
File metadata and controls
90 lines (82 loc) · 2.36 KB
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
// ==========================================================================
// Button Pattern
// ==========================================================================
//
// Scales namespace variable
///
$scales-namespace: null !default;
//
// Available Variables
///
$btn-background-color: #d3d3d3 !default;
$btn-border-width: 0 !default;
$btn-border-color: #000 !default;
$btn-border-style: solid !default;
$btn-border-radius: 0 !default;
$btn-text-color: inherit !default;
$btn-font: inherit !default;
$btn-padding: .5em .75em !default;
$btn-hover-background-color: #c6c6c6 !default;
$btn-hover-text-color: inherit !default;
$btn-disabled-opacity: .5 !default;
$btn-disabled-background-color: $btn-background-color !default;
$btn-disabled-border-width: $btn-border-width !default;
$btn-disabled-border-color: $btn-border-color !default;
$btn-disabled-border-style: $btn-border-style !default;
$btn-disabled-text-color: $btn-text-color !default;
//
// Buttons are meant to be used on links, buttons, and submit inputs
///
//
// Main button class
///
.#{$scales-namespace}btn {
-webkit-appearance: none;
background-color: $btn-background-color;
border-width: $btn-border-width;
border-color: $btn-border-color;
border-style: $btn-border-style;
border-radius: $btn-border-radius;
color: $btn-text-color;
cursor: pointer;
display: inline-block;
font: $btn-font;
line-height: normal;
margin: 0;
overflow: visible;
padding: $btn-padding;
text-align: center;
text-decoration: none;
vertical-align: middle;
white-space: normal;
&:hover,
&:active,
&:focus {
text-decoration: none;
}
&:hover {
background-color: $btn-hover-background-color;
color: $btn-hover-text-color;
}
}
//
// Disabled button state
///
.#{$scales-namespace}btn.is-disabled,
.#{$scales-namespace}btn[disabled] {
opacity: $btn-disabled-opacity;
pointer-events: none;
// Avoiding conflict with disabled form inputs
background-color: $btn-disabled-background-color;
border-width: $btn-disabled-border-width;
border-color: $btn-disabled-border-color;
border-style: $btn-disabled-border-style;
color: $btn-disabled-text-color;
}
//
// Removes extra padding and border in Firefox when using `input type="submit"`
///
.#{$scales-namespace}btn::-moz-focus-inner {
border: 0;
padding: 0;
}