Skip to content

Commit e1a95eb

Browse files
committed
Make button text accessible
This commit adds a color variable that contrasts with the action color to always ensure legibility for buttons. Closes #339
1 parent 9646664 commit e1a95eb

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

core/_buttons.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ button,
66
background-color: $action-color;
77
border: 0;
88
border-radius: var(--border-radius);
9-
color: inherit;
9+
color: $action-color--contrast;
1010
cursor: pointer;
1111
display: inline-block;
1212
font-family: var(--font-family-base);

core/_variables.scss

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,16 @@
22
$blue: #1565c0;
33
$blue-light: #3b83d5;
44
$gray: #333;
5+
$white: #fff;
56

67
// Font Colors
78
$font-color--base: $gray;
89
$action-color: $blue;
910
$action-color--alt: $blue-light;
11+
$action-color--contrast: $white;
1012

1113
// Background Colors
12-
$viewport-background-color: #fff;
14+
$viewport-background-color: $white;
1315

1416
:root {
1517
// Typography

0 commit comments

Comments
 (0)