Use em instead of fixed font sizes

This commit is contained in:
Alex D. 2021-02-11 20:44:04 +00:00
parent 1e2ef1d032
commit 58bd00d67b
Signed by: caskd
GPG Key ID: F92BA85F61F4C173
1 changed files with 6 additions and 7 deletions

View File

@ -1,7 +1,6 @@
@bg: #111; @bg: #111;
@fg-mono: contrast(@bg); @fg-mono: contrast(@bg);
@fg-color: #e11; @fg-color: #e11;
@font-size: 20px;
// Override defaults and things a user agent shouldn't choose // Override defaults and things a user agent shouldn't choose
* { * {
@ -27,9 +26,9 @@ img {
max-height: 100%; max-height: 100%;
} }
h1 { font-size: @font-size * 2 } h1 { font-size: 2em }
h2 { font-size: @font-size * 1.5 } h2 { font-size: 1.5em }
h3 { font-size: @font-size * 1.25 } h3 { font-size: 1.25em }
html { html {
background: @bg; /* Fallback */ background: @bg; /* Fallback */
@ -49,7 +48,7 @@ html {
average(@bg, @fg-color) 2% 4% average(@bg, @fg-color) 2% 4%
); );
color: @fg-mono; color: @fg-mono;
font-size: @font-size; font-size: 1em;
width: 100%; width: 100%;
min-width: 200px; min-width: 200px;
min-height: 200px; min-height: 200px;
@ -119,7 +118,7 @@ html {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
text-align: center; text-align: center;
font-size: @font-size * 1.5; font-size: 1.5em;
} }
} }
.body { .body {
@ -152,7 +151,7 @@ html {
display: inherit; display: inherit;
flex-direction: column; flex-direction: column;
.title { .title {
font-size: @font-size * 1.25; font-size: 1.25em;
} }
} }
} }