moved to less for styles

This commit is contained in:
2024-10-11 00:11:27 -05:00
parent 55aa163bc0
commit d87064b289
7 changed files with 2224 additions and 1936 deletions

13
src/app.less Normal file
View File

@@ -0,0 +1,13 @@
@import 'vars.less';
@import (css) url('https://fonts.googleapis.com/css2?family=Rubik:wght@600&display=swap');
body {
font-family: @fonts-sans;
margin: 0;
}
h1 {
margin: 0;
padding: 0;
}

View File

@@ -2,14 +2,14 @@
<h1><slot /></h1>
</header>
<style>
<style lang="less">
h1 {
text-align: center;
}
header {
background-color: var(--color-dark);
color: var(--color-light);
padding: var(--padding-md);
background-color: @color-dark;
color: @color-light;
padding: @padding-md;
}
</style>

View File

@@ -1,25 +1,5 @@
<script lang="ts">
import '../app.less';
</script>
<slot />
<style>
@import url('https://fonts.googleapis.com/css2?family=Rubik:wght@600&display=swap');
:global(:root) {
--color-accent-dark: #a8c3b5;
--color-accent-light: #558b6e;
--color-danger: #d64933;
--color-dark: #2e282a;
--color-light: #fbfbfb;
--fonts-sans: Rubik, Arial, sans-serif;
--padding-md: 0.5em 1em;
}
:global(body) {
margin: 0;
}
:global(h1) {
font-family: var(--fonts-sans);
margin: 0;
padding: 0;
}
</style>

12
src/vars.less Normal file
View File

@@ -0,0 +1,12 @@
// colors
@color-accent-dark: #a8c3b5;
@color-accent-light: #558b6e;
@color-danger: #d64933;
@color-dark: #2e282a;
@color-light: #fbfbfb;
// fonts
@fonts-sans: Rubik, Arial, sans-serif;
// layout
@padding-md: 0.5em 1em;