1
0
mirror of https://github.com/nostalgic-css/NES.css.git synced 2025-08-31 09:41:47 +02:00

feat(badges): changes made that was asked by the reviewer

Removed box-sizing and border none, and classes that changed the size. Added cursor fallback and
size change by the font-size. Changed from span to a; display type; margin.

#211
This commit is contained in:
Igor Guastalla de Lima
2018-12-20 20:21:51 -02:00
parent f8a8e3184a
commit 911f281b47
2 changed files with 16 additions and 33 deletions

View File

@@ -36,27 +36,23 @@
}
@mixin setup($px) {
width: $px * 14;
height: $px;
font-size: $px * 1.2;
line-height: 1.5;
}
// Default style
.nes-badge {
$em: 0.75em;
width: $em * 14;
height: $em;
font-size: $em * 1.2;
position: relative;
box-sizing: border-box;
display: inline-flex;
align-items: center;
justify-content: center;
display: inline-block;
padding: 0.75em;
margin: 4px;
margin: 0.5em;
text-align: center;
white-space: nowrap;
vertical-align: middle;
cursor: $cursor-click-url;
cursor: $cursor-click-url, pointer;
user-select: none;
border: none;
@include setup(7px);
// Other styles
@@ -79,17 +75,4 @@
@include badge-style(nth($type, 2), nth($type, 3), false);
}
}
// Other sizes
// prettier-ignore
$sizes:
"small" 5px,
"medium" 7px,
"large" 9px;
@each $size in $sizes {
&.is-#{nth($size, 1)} {
@include setup(nth($size, 2));
}
}
}