Files
danbooru/app/javascript/src/styles/base/000_vars.scss
evazion 7034872132 css: use rem instead of em units instead for font sizes.
Use rem units for font sizes so that font sizes are relative to the root
<html> element, not the parent element.

Fixes an issue where the video duration indicator would be too small on
parent/child thumbnails in post show pages. This was because of nesting
issues with em units. Em units are relative to their parent element, so
if you had a parent element with a font size of 0.8em, and a child
element with a font size of 0.8em, then the final computed font size
would be 0.8*0.8 = 0.64em.
2021-10-25 05:16:59 -05:00

49 lines
1.2 KiB
SCSS

:root {
--text-xs: 0.5625rem; // 9px
--text-sm: 0.7875rem; // 12.6px
--text-md: 0.875rem; // 14px
--text-lg: 1.0208rem; // 16.3333px
--text-xl: 1.3125rem; // 21px
--text-xxl: 1.75rem; // 28px
--header-font: Tahoma, Verdana, Helvetica, sans-serif;
--body-font: Verdana, Helvetica, sans-serif;
--monospace-font: 0.85rem monospace; // 13.6px
}
$h1_padding: 0.8em 0 0.25em 0;
$h2_padding: 0.8em 0 0.25em 0;
$h3_padding: 0.8em 0 0.25em 0;
$h4_padding: 0.8em 0 0.25em 0;
// https://fontawesome.com/how-to-use/on-the-web/advanced/css-pseudo-elements
@mixin fa-solid-icon($content) {
display: inline-block;
font-style: normal;
font-variant: normal;
text-rendering: auto;
-webkit-font-smoothing: antialiased;
/* stylelint-disable-next-line font-family-no-missing-generic-family-keyword */
font-family: "Font Awesome 5 Free";
font-weight: 900;
content: $content;
}
@mixin active-link {
color: var(--link-color);
&:hover, &:focus {
background-color: var(--subnav-menu-background-color);
outline: none;
}
}
@mixin inactive-link {
color: var(--muted-text-color);
&:hover {
color: var(--link-hover-color);
background-color: var(--subnav-menu-background-color);
}
}