Skip to content

Instantly share code, notes, and snippets.

@Antoine007
Created August 30, 2017 22:50
Show Gist options
  • Save Antoine007/6964af571964c4e696b2215db299e4cd to your computer and use it in GitHub Desktop.
Save Antoine007/6964af571964c4e696b2215db299e4cd to your computer and use it in GitHub Desktop.
https://stylepill-repo.herokuapp.com/page/component
/// Import button core styles
@import 'color';
/// VARIABLES
$btn-primary-font-color: map-get($color, primary);
$btn-primary-bg-color: rgba(0,0,0,0);
$btn-primary-border: 1px solid map-get($color, primary);
$btn-primary-font-color-hover: map-get($color, darkPrimary);
$btn-primary-border-hover: 1px solid map-get($color, darkPrimary);
$btn-primary-font-color-disabled: map-get($color, lightGray);
$btn-primary-border-disabled: 1px solid map-get($color, lightGray);
/// BUTTON CLASS
.me-btn {
transition: .1s background-color,.1s border-color,.1s color,.1s fill;
border-radius: 999em;
letter-spacing: 0;
font-weight: 400;
font-style: normal;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
/// BUTTON TYPE
&--primary {
color: $btn-primary-font-color;
background: $btn-primary-bg-color;
border: $btn-primary-border;
&:hover {
border: $btn-primary-border-hover;
color: $btn-primary-font-color-hover;
}
&:focus {
border: $btn-primary-border-hover;
color: $btn-primary-font-color-hover;
}
&:active {
border: $btn-primary-border-hover;
color: $btn-primary-font-color-hover;
}
&[disabled] {
border: $btn-primary-border-disabled;
color: $btn-primary-font-color-disabled;
opacity: .5;
cursor: default;
}
}
/// BUTTON SIZE
&--md {
font-size: 13px;
height: 37px;
padding: 0 16px;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment