mirror of
https://github.com/kidoman/embd
synced 2025-02-10 20:53:20 +01:00
45 lines
830 B
SCSS
45 lines
830 B
SCSS
@mixin button-size($size) {
|
|
$n: 0;
|
|
@if $size == xlarge {
|
|
$n: $xlarge-button-font-size;
|
|
}
|
|
@if $size == large {
|
|
$n: $large-button-font-size;
|
|
}
|
|
@if $size == medium {
|
|
$n: $medium-button-font-size;
|
|
}
|
|
@if $size == small {
|
|
$n: $small-button-font-size;
|
|
}
|
|
$button-font-size: $n;
|
|
$button-height: ms($ratio, $button-font-size) + 1;
|
|
$line-height: $button-height - 2;
|
|
|
|
@include font-size($button-font-size);
|
|
@include line-and-height($button-height);
|
|
|
|
a {
|
|
position:relative;
|
|
padding: 0 ms(0, $button-font-size);
|
|
}
|
|
|
|
&.icon-left {
|
|
a {
|
|
padding-left: $button-height;
|
|
&:before {
|
|
left: $button-font-size / 1.5;
|
|
}
|
|
}
|
|
}
|
|
|
|
&.icon-right {
|
|
a {
|
|
padding-right: $button-height;
|
|
&:after {
|
|
right: $button-font-size / 1.5;
|
|
}
|
|
}
|
|
}
|
|
}
|